Last Updated: 21 November 2024 | Change Log
Use a stored card
Use a previously stored card to send a payments
request. This is for customer initiated transactions (CIT) only.
Additionally, to collect the CVC value, use the Checkout SDK to create a cvc session
and maintain a low PCI burden.
The request must contain:
customerAgreement.type
=cardOnFile
customerAgreement.storedCardUsage
=subsequent
If PSD2/SCA or other regional mandates apply you should follow the steps for enabling 3DS
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#
Use a previously stored Worldpay token for a customer initiated payment (CIT)
{ "transactionReference": "Memory265-13/08/1876", "merchant": { "entity": "default" }, "instruction": { "method": "card", "paymentInstrument": { "type": "token", "cvc": "333", "href": "https://try.access.developer.com/tokens/eyJrIjoxLCJkIjoialRBL0FFelBzcnZpNCtzRGNRemh0NzI0NE1rdUtjMUFJdjYxVnlibWZuUT0ifQ" }, "customerAgreement": { "type": "cardOnFile", "storedCardUsage": "subsequent" }, "narrative": { "line1": "trading name" }, "value": { "currency": "GBP", "amount": 42 } } }
Enable additional features
Feature | Description | Details |
---|---|---|
Fraud assessment | Prevent fraudulent transactions. | How to enable |
3DS authentication | Shift Liability to the issuer / for EEA countries this is required as part of SCA compliance. | How to enable |
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 3DS is enabled you will receive a 3dsDeviceDataRequired outcome and additionally, if prompted by the card issuer, a 3dsChallenged response.
If FraudSight is enabled, you can receive a fraudHighRisk response, stopping the transaction.
If
settlement.auto
is set totrue
, the outcome will besentForSettlement
. If set tofalse
it will beauthorized
with an addtional settlement action required.- If any of the AVS/CVC response riskFactors are marked as
notMatched
the payment will besentForCancellation
automatically.
- If any of the AVS/CVC response riskFactors are marked as
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
- 3DS authentication details - details on the 3DS authentication outcome (e.g. challenged)
- fraud assessment details - details on the fraud assessment outcome (e.g. lowRisk, review)
- Worldpay token creation - details of the card tokenized and the
token href
itself - paymentInstrument - details of the paymentInstrument used