Last Updated: 17 October 2024 | Change Log
Apple Pay
Make an Apple Pay payment by providing the encrypted payload (wallet token) in the payments
request.
Apple Pay is not yet supported when setting up a recurring payment.
Request
- Try https://try.access.worldpay.com/api/payments
- Live https://access.worldpay.com/api/payments
- Payload
- curl
- Python
- Java
- Node.js
- Go
- PHP
- Ruby
- C#
application/json
Provide the encrypted Apple Pay payload
{ "transactionReference": "Memory265-13/08/1876", "merchant": { "entity": "default" }, "instruction": { "method": "applepay", "paymentInstrument": { "type": "encrypted", "walletToken": "{\"version\": \"EC_v1\",\"data\": \"kdHd..GQ==\",\"signature\": \"MIAGCSqGSIb3DQEH...AAA\",\"header\": {\"transactionId\": \"d3b28af..f8\",\"ephemeralPublicKey\": \"MFkwE..Q==\",\"publicKeyHash\": \"dxCK..6o=\"}}" }, "narrative": { "line1": "trading name" }, "value": { "currency": "GBP", "amount": 42 } } }
Enable additional features
Feature | Description | |
---|---|---|
Fraud assessment | Prevent fraudulent transactions. | Not supported |
Auto Settlement | Request that payment authorizations are automatically sent for settlement (sometimes referred to as "capture"). | How to enable |
Financial Services (MCC 6012 / 6051) | If you provide financial services, debt repayment, or consumer bill payments, you should supply additional details in the authorization request for compliance reasons. | How to enable |
Response
Flow differences
API responses differ based on the features you have enabled:
- If
settlement.auto
is set totrue
, the outcome will besentForSettlement
. If set tofalse
it will beauthorized
with an addtional settlement action required.
See sequence diagrams to get a clear overview.
Payment response
The payment response contains the following details:
- riskFactors (avs/cvc) - if billing address & cvc are provided, these details are checked against the customer's issuing bank
- refusal code and description which gives additional context on the refusal
- paymentInstrument - details of the paymentInstrument used
View the full API Response schema