2.1 KiB
2.1 KiB
Re-authorise with :
Bearer YTM2ZGQ1NzUtOWFmNS01MjMyLTg5MjYtM2NkZjA5ZDU2ZGU1
step 1
Payee Account?
{
"description": "Silver Carpenter Inc. account.",
"receivingAccountServiceKey": "T_S_7c8551db-2aa0-489d-b80e-d1a8d42e4bfb"
}
/payment-instruments/worldpay-merchants Save a worldpay receiving account. created instrument
{
"key": "66ef4cd0-aa02-444f-b4bd-81cce3f6674e",
"ID": "5ad9fde20a791abf542f8598"
}
step 2
/receivables/rtps Create a Request to Pay (RTP).
{
"amount": {
"value": 100,
"currency": "GBP"
},
"counterparty": {
"userID": "5ad9fe6c0a791abf542f859c"
},
"transactionDetails": {
"orderDescription": "A can of juice"
},
"payeeInstrument": {
"key": "66ef4cd0-aa02-444f-b4bd-81cce3f6674e",
"ID": "5ad9fde20a791abf542f8598"
}
}
That generates:
{
"requestToPayID": "5ad9fec20a791abf542f859f"
}
step 3
create a card /payment-instruments/cards Save card details.
{
"payer": {
"email": "a@b.com",
"firstName": "Bob",
"lastName": "Minion"
},
"card": {
"nameOnCard": "John E Doe",
"PAN": "4444333322221111",
"expiryDate": "01-20",
"startDate": "01-00",
"issueNumber": 1,
"CV2": "134",
"address": {
"address1": "Flat 20",
"address2": "Victoria House",
"address3": "15 The Street",
"town": "Christchurch",
"county": "Dorset",
"postcode": "BH23 6AA",
"phoneNumber": "+44 123 1110000"
}
}
}
created
{
"cardUsageKey": "c1de7a81-2181-472d-b552-9a2e8aab9307",
"cardID": "5ada05fa0a791abf542f85a9"
}
step 4
post /payables/rtps/5ad9fec20a791abf542f859f/atps
{
"payerInstrument": {
"ID": "5ada05fa0a791abf542f85a9",
"key": "c1de7a81-2181-472d-b552-9a2e8aab9307"
},
"amount": {
"value": 100,
"currency": "GBP"
}
}
result
{
"transaction": {
"id": "1c63f278-edc7-47d9-ac3b-4574e9828a6f"
},
"additionalInfo": {
"cardSchemeName": "VISA CREDIT",
"riskScore": "1"
},
"atpID": "5ada06fc0a791abf542f85b9"
}