Before using Amazon Pay you need to register at https://pay.amazon.com/de/signup. On this page you can configure a notify URL. Therefore follow the menu steps Settings – Integration settings – Settings for instant notifications – Modify. Enter the Integrator URL
AmazonAPANotify.aspx and save it.
The second step is generating a MWS Auth Token. Therefore go to the webpage https://developer.amazonservices.co.uk/gp/mws/registration/register.html and enter the following data:
Developer name: Computop Ltd
Developer account number: 8662-2365-9858
Then submit the received MWS Authorisation Token on a secure way to for configuration.
The basic payment process with Amazon consists of several steps:
Step | Description |
---|---|
Display Button-Widget | The Amazon button widget must be properly implemented on the page of the webshop and must be called for each payment/login process. Afterwards a redirect to Amazon occurs. Within the redirect data from Amazon (AccessToken, TokenType, Expiry, Scope) is delivered. |
Initialize payment via | With the delivered data from the button widget from Amazon (AccessToken, TokenType, Expiry, Scope) the payment process via |
Load and display address and wallet widgets | Both widgets must be integrated in the shop directly. The widgets communicate directly with the shop. It is recommended to firstly call the address widget, to buffer the „OrderReferenceID“ (OrderReferenceId is generated by address widget – and can be read out via JavaScript with„orderReference.getAmazonOrderReferenceId()“) and to execute immediately a call of AmazonAPA.aspx with Eventtoken „SOD“ and the „orderReferenceID“ via the Thus the wallet only shows valid payment methods for this order. Each modification of delivery address (if the customer selects a different address for shipping than the standard address within the widget) involves an „OnAddressSelect“– whereupon your systems must react. |
Request new shipping information | After an „OnAddressSelect“ a further call of AmazonAPA.aspx via Now call the AmazonAPA.aspx with Eventtoken SOD, to transfer the possible new total amount for this order. |
Finalize the purchase | The purchase confirmation is completed via The call with Eventtoken „SCO“ is preferred, because the following steps are easier due to the automatic provision of the final delivery address (with all address details). Nevertheless after getting the response of finalizing the order a further call of AmazonAPA.aspx with Eventtoken „GOD“ should be made, in order to notice possible delivery address changes. After finalizing the order there already doesn’t exits a pecuniary claim against the customer. Subsequently your systems also must execute authorizations and captures. |
Confirmation flow | Due to Multi-factor Authentication it is necessary after a succesful confirmation of an order to start a new Javascript call, the ConfirmationFlow. With this AmazonPay can handle the Multi-factor Authentication if required. The changes for Multi-Factor Authentication (MFA) needed, only effect the EUR and UK Amazon Platforms. |
Authorisation | The authorization of amount payable must be done within 180 days. Authorizations are valid for 30 days and expire afterwards. After expiry the amount payable can be reauthorized (within 180 days after the order). In the response to an authorization with Amazon you receive a unique For an initialized Amazon order up to ten authorizations can be submitted simultaneously. Per order lifecycle up to a maximum of 50 authorizations can be submitted. Peculiarity for authorizations with Amazon: There are two different authorization types: Synchronous and asynchronous authorization. Synchronous authorizations always give a clear answer about the authorization result immediately, thus OK or FAILED. Asynchronous authorizations are followed up by a notify, which gives an answer about the authorization result after a definable maximum time period (the notify can be returned earlier). The maximum time period between submitting the authorization and the latest allowed status message per notify can be configured for each |
Capture | Authorizations can be captured synchronous within seven days starting from the time of authorization. This means the capture gets an „OK“ from Amazon immediately. Between seven and thirty days after authorization the captures are asynchronous and produce a notify to your notify-URL (simultaneously extended risk assessments are started at Amazon). Please ensure to start the delivery only after receiving the notify. For an authorization a capture ≤ authorization amount can be submitted. The „XID“ of the underlying authorization must be submitted to If a capture < authorization was submitted, the difference amount can be authorized again immediately. The |
Conclude order process after dispatch | After end of the order process (e.g. after shipment of the last article or after successful last capture) it is recommended, to close the process at Amazon. If the process is not closed, the customer will see an open order in his backend of Amazon Pay. Please use therefore the Eventtoken „COR“. After closing of this process captures on open authorizations as well as credits are still possible – but no further authorizations related to an order process. |
Close an authorization | If an article cannot be delivered anymore (or did no longer have to be delivered) existing authorizations that are not captured can be closed. Therefore use the Eventtoken „RAN“. |
Credits | According to Amazon credits can issue without time limit. This can be up to a maximum of one year in the case of |
The following example code shows how to integrate the button widget:
|
Notice: Because has no influence on the widget code, we recommend you to follow the documentation of Amazon Pay.
In this case the following parameters must be completed within the Widget:
Parameter | Description | Value |
---|---|---|
YOUR_SELLER_ID | SellerId issued by Amazon | |
Type | The parameter Type is an optional parameter for defining the button layout of the button widget. | Permissible values: LwA, Login, PwA, Pay, A |
Color | The parameter Color defines the color of the button widget | Permissible values: Gold, LightGray, DarkGray |
Size | The parameter Size defines the size of the button widget | Permissible values for normal display resolution: small, medium Permissible values for Retina Displays: large, x-large |
Language | The parameter Language is optionally used for defining the language of the checkout process. This is helpful especially within a multilingual shop environment. Without submitting the parameter Language Amazon automatically uses the most suitable language for checkout. | Permissible values: en-GB, de-DE, fr-FR, it-IT, es-ES |
Scope | The parameter Scope defines the scope of return parameters after the customer login as well as the contents of the consent form for the customer. Example: scope=payments:shipping_address returns the purchaser’s delivery address. | Permissible values: profile, profil:user_id, payments:widget, payments:shipping_address, payments:billing_address |
Further information can be found in the documentation from Amazon Pay.
The following example code shows how to implement the address book widget:
|
|
The option to logout is usually a link which removes all user data from the website and then re-displays the login page via the amazon.Login.logout() method. Use the following codes for this:
|
Further information can be found in the documentation from Amazon Pay.
Due to Multi Factor Authentication it is necessary after a succesful confirmation of an order to start a new call, the ConfirmationFlow.
The following example code shows how to implement the Javscript function for that:
|
For Amazon Pay there are numerous possible actions whose selection is controlled at the interface via the EventToken parameter.
The following table gives an overview of possible Eventtoken for AmazonAPA.aspx:
|
conditio Process flow for Amazon Pay within |
This action should be triggered by clicked the "Buy Now" button. When MFA is required, the Confirmation Flow (see Javascript above) shows the credit card issuer’s MFA challenge to the buyer. After the buyer interacts with the Confirmation Flow (for example, completes the MFA challenge), the buyer is returned to the merchant’s site (for example, order confirmation page). The merchant should be able to handle the redirection (URLSuccess / URLFailure) with the result of the MFA Challenge.
In case of amazonstatus=Success the purchase is completed. In case of amazonstatus=Failure or amazonStatus=Abandoned the customer is redirected to the URLFailure and the merchant should cancel the order by calling reverse,aspx (see below in chapter "Amazon Pay reverse an authorization"). The customer can be redirected to select a different payment method or in case of Abandoned to replace the order and complete the MFA challange.
Instead of the one-step solution with EventToken=SCO the process can be splitted into EventToken=SOD and EventToken=COD followed by the Confirmation Flow.
Process flow for Multi-factor authentication with Amazon Pay (amazonstatus=Success) Process flow for failed Multi-factor authentication with Amazon Pay (amazonstatus=Failure or Abandoned) |
In order to initialize a payment with Amazon Pay, please use the following URL:
|
|
Encrypted parameters for initializing an Amazon Pay payment
|
Response parameters after initializing an Amazon Pay payment
In order to confirm the order details of a payment with Amazon Pay with the function „SetOrderDetails“, please visit the following URL:
|
The following tables describe the transfer parameters and return values which are exchanged via the socket connection. The server-to-server communication process is described in the manual Programming basics.
|
Encrypted parameters for calling SetOrderDetails and SetOrderDetailsAndConfirmOrder for an Amazon Pay payment
Notice: You can combine calling SetOrderDetails and ConfirmOrderDetails, if you are using EventToken <SCO> for SetOrderDetailsAndConfirmOrder.
|
Response parameters after SetOrderDetails and SetOrderDetailsAndConfirmOrder for an Amazon Pay payment
In order to request the order details of a payment with Amazon Pay with the function „GetOrderDetails“, please visit the following URL:
|
The following tables describe the transfer parameters and return values which are exchanged via the socket connection. The server-to-server communication process is described in the manual Programming basics.
|
Encrypted parameters for calling GetOrderDetails for an Amazon Pay payment
|
Response parameters after GetOrderDetails of an Amazon Pay payment
In order to confirm the order details of a payment with Amazon Pay with the function „ConfirmOrderDetails“, please visit the following URL:
|
The following tables describe the transfer parameters and return values which are exchanged via the socket connection. The server-to-server communication process is described in the manual Programming basics.
|
Encrypted parameters for calling ConfirmOrderDetails for an Amazon Pay payment
|
Response parameters after ConfirmOrderDetails of an Amazon Pay payment
In case of an error (e.g. if Amazon refuses the payment) you get a notify to your specified URLNotify with following parameters:
|
Response parameters to URLNotify after ConfirmOrderDetails for an Amazon Pay payment
In order to authorize a payment with Amazon Pay, please visit the following URL:
|
The following tables describe the transfer parameters and return values which are exchanged via the socket connection. The server-to-server communication process is described in the manual Programming basics.
|
Encrypted parameters for authorizing an Amazon Pay payment
|
Response parameters after authorization of an Amazon Pay payment
After an authorization you get a notify to your specified URLNotify with following parameters:
|
Response parameters to URLNotify after authorization of an Amazon Pay payment
In order to capture an authorized payment with Amazon Pay, please visit the following URL:
|
The following tables describe the transfer parameters and return values which are exchanged via the socket connection. The server-to-server communication process is described in the manual Programming basics.
|
Encrypted parameters for capturing an authorized Amazon Pay payment
|
Response parameters after capturing an authorized Amazon Pay payment
After a capture you get a notify to your specified URLNotify with following parameters:
|
Response parameters to URLNotify after capturing an authorized Amazon Pay payment
In order to credit a captured payment with Amazon Pay, please visit the following URL:
|
The following tables describe the transfer parameters and return values which are exchanged via the socket connection. The server-to-server communication process is described in the manual Programming basics.
|
Encrypted parameters for crediting an Amazon Pay payment
|
Response parameters after crediting an authorized Amazon Pay payment
After a credit you get a notify to your specified URLNotify with following parameters:
|
Response parameters to URLNotify after credit of an Amazon Pay payment
In order to close an order with Amazon Pay with the function „CloseOrder“, please visit the following URL:
|
The following tables describe the transfer parameters and return values which are exchanged via the socket connection. The server-to-server communication process is described in the manual Programming basics.
|
Encrypted parameters for closing an Amazon Pay payment
|
Response parameters after closing an Amazon Pay payment
In order to reverse a complete order with Amazon Pay with the function „CancelOrderReference“, please visit the following URL:
|
The following tables describe the transfer parameters and return values which are exchanged via the socket connection. The server-to-server communication process is described in the manual Programming basics.
|
Encrypted parameters for reversal of an Amazon Pay payment
|
Response parameters after reversing an Amazon Pay payment
Notice: If you are reversing an order completely, you will get also a notify like for an incorrect order as described above.
In order to reverse a single authorization with Amazon Pay with the function „CancelAuthorize“, please visit the following URL:
|
The following tables describe the transfer parameters and return values which are exchanged via the socket connection. The server-to-server communication process is described in the manual Programming basics.
|
Encrypted parameters for reverse an Amazon Pay authorization
|
Response parameters after reversal of an Amazon Pay authorization
Notice: If you reverse an authorization you will also get a notify similar to the above described notify for authorization.
In order to request the details of an authorization with Amazon Pay, please visit the following URL:
|
The following tables describe the transfer parameters and return values which are exchanged via the socket connection. The server-to-server communication process is described in the manual Programming basics.
|
Encrypted parameters for requesting details of an Amazon Pay authorization
|
Response parameters for requesting details of an Amazon Pay authorization
In order to request the details of a capture with Amazon Pay, please visit the following URL:
|
The following tables describe the transfer parameters and return values which are exchanged via the socket connection. The server-to-server communication process is described in the manual Programming basics.
|
Encrypted parameters for requesting details of an Amazon Pay capture
|
Response parameters for requesting details of an Amazon Pay capture
In order to request the details of a credit with Amazon Pay, please visit the following URL:
|
The following tables describe the transfer parameters and return values which are exchanged via the socket connection. The server-to-server communication process is described in the manual Programming basics.
|
Encrypted parameters for requesting details of an Amazon Pay credit
|
Response parameters for requesting details of an Amazon Pay credit
Basic information about using Batch files and about their structure you can find inside the separate manual for the Batch manager. Within batch processing not alle functions are available which are usually available for the online interface.
This section describes the parameters which must be transferred within the data set (Record) for executing a payment with Amazon Pay and which information can be found within the response file about the payment status.
For Amazon Pay the transactions AUTHORIZE, CAPTURE, CREDIT, COR, REVERSE and RAN are possible via Batch. Batch versions X.0; X.1; 1.X and 2.X are supported.
Following table gives an overview of all batch versions that are possible for a specific action an their specialities:
|
Description of the possible batch versions
The structure for a payment with Amazon Pay within a Batch file to be submitted is the following:
|
Example for Master MID function:
|
The following table describes the individual fields and values used within the data set (record) within the batch file:
|
Description of fields within the record for Batch files
The record area within the response file for Batch transactions looks the following way:
|
The following table describes the response parameters which the Batch Manager saves in the Record area for each transaction (standard parameters not explained here, such as <TransID> or <RefNR> correspond to the call as specified above):
|
Description of result parameters within the record for Batch files