3-D Secure


3D-Secure provides an additional security measure for customers and merchants. Customers with 3D-Secure activated on their credit card will be redirected via HTML FORM POST to a webpage hosted by their bank and asked to enter a PIN, verifying their identity.

Linking to eWAY

Below are the specifications for using 3-D Secure, including descriptions of the fields sent to and returned by our payment gateway.

Sample code is available from within MYeWAY, along with many other free resources for our development partners.


3-D Secure
The gateway URL is https://www.eway.com.au/gateway_3d/payment.asp

Transaction request
Field Name Maximum Length Required?
ewayCustomerID 8 Required
ewayTotalAmount 12 Required
ewayCustomerFirstName 50  
ewayCustomerLastName 50  
ewayCustomerEmail 50  
ewayCustomerAddress 255  
ewayCustomerPostcode 6  
ewayCustomerinvoiceDescription 10000  
ewayCustomerInvoiceRef 50  
ewayCardholdersName 50  
ewayCardNumber 20  
ewayCardExpiryMonth 2  
ewayCardExpiryYear 2  
ewayURL 255 Required
ewayAutoRedirect 1  
ewaySiteTitle 255  
ewayTrxnNumber 16  
ewayOption1 255  
ewayOption2 255  
ewayOption3 255  

Sample HTML

<table border="1" width="70%" cellspacing="0" cellpadding="5" bordercolor="
#000080">
  <tr>
    <td width="22%" valign="top">
      <p class="subtitle">
        <a href="http:
//www.eway.com.au" target="_blank">
        <img alt="eWAY - a total e commerce solution" border="0" height="91" src="http://www.eway.com.au/_images/common/eway_logos/eway_logo.png" width="200" /></a>
      </p>
    </td>
    <td width="78%" valign="top" bgcolor="#ffffff">
      <form method="post" action="#">
        <input type="hidden" name="ewayCustomerID" value="87654321" />
        <input type="hidden" name="ewayTotalAmount" value="10" />
        <input type="hidden" name="ewayCustomerFirstName" value="Roxarne" />
        <input type="hidden" name="ewayCustomerLastName" value="Paton" />
        <input type="hidden" name="ewayCustomerEmail" value="customer@theirsite.com.au" />
        <input type="hidden" name="ewayCustomerAddress" value="18 Mayne Street Parkes NSW" />
        <input type="hidden" name="ewayCustomerPostcode" value="2870" />
        <input type="hidden" name="ewayCustomerInvoiceDescription" value="ASP code e-postcard" />
        <input type="hidden" name="ewayCustomerInvoiceRef" value="webactive002" />
        <input type="hidden" name="ewayURL" value="http://www.yoursite.com.au/eway/result.asp" />
        <input type="hidden" name="ewaySiteTitle" value="WebActive" />
        <input type="submit" value="Process Secure Credit Card Transaction using eWAY" name="submit" />
      </form>
    </td>
  </tr>
</table>

Transaction response
Field name Maximum length
ewayTrxnError 100
ewayTrxnStatus 6
ewayTrxnNumber 16
ewayResponseCode 16
ewayResponseText 16
ewayTrxnReference 50
ewayTrxnOption1 255
ewayTrxnOption2 255
ewayTrxnOption3 255
ewayAuthCode 6
ewayReturnAmount 12

Sent to eWAY
Field Name Description
ewayCustomerID Your unique eWAY Customer ID assigned to you when you join eWAY. Eg. 12345678
ewayTotalAmount The total amount in cents for the transaction. Eg. $10.65 = 1065
ewayCustomerFirstName The customer's first name.
ewayCustomerLastName The customer's last name.
ewayCustomerEmail The customer's email address. Note: This field must be populated for them to receive an eWAY email receipt.
ewayCustomerAddress The customer's address. This can be either the postal or billing address.
ewayCustomerPostcode The customer's postcode. This can be either the postal or billing postcode.
ewayCustomerInvoiceDescription The description of what products or services the customer is paying for.
ewayCustomerInvoiceRef Your internal invoice or order number for the transaction.
ewayURL The address of the webpage on your server that you want the customer transferred to after the transaction is processed.
ewayAutoRedirect Whether you wish for the customer to be automatically redirected back to your site or have to click a continue button. Setting as "1" will be automatic. Any other value will require a button click.
ewaySiteTitle The title to appear on the payment page. Eg: "Acme Corporation's Payment System".
ewayTrxnNumber You may assign your own transaction number to this field if you wish. Note: This field is returned as ewayTrxnReference.
ewayOption1 This field is not stored at eWAY but is returned in the XML back to your website or application.
ewayOption2 This field is not stored at eWAY but is returned in the XML back to your website or application.
ewayOption3 This field is not stored at eWAY but is returned in the XML back to your website or application.


Received from eWAY
Field Name Description
ewayTrxnError In a valid transaction, this will be the 2 digit response code and response text from the bank. In an invalid transaction this will explain why the transaction is invalid.
ewayTrxnStatus This field returns a Boolean "True" or "False" and should be used to determine the result page you display to the customer.
ewayTrxnNumber This is the eWAY Transaction Number for this transaction.
ewayTrxnOption1 This field is not stored at eWAY but is returned in the XML back to your website or application.
ewayTrxnOption2 This field is not stored at eWAY but is returned in the XML back to your website or application.
ewayTrxnOption3 This field is not stored at eWAY but is returned in the XML back to your website or application.
ewayReturnAmount This can be used to ensure that the correct amount was charged for this transaction.
ewayAuthCode If the transaction was successful, this is the bank authorisation code for the transaction.
ewayTrxnReference If you passed a number in ewayTrxnNumber this will be returned in this field.