Credits and payouts using the Backoffice API with card details or registered cards
Learn how to make credits and payouts with the Backoffice API.
You can send a credit payment POST request from server to server. You will need to enter the card details, payment, and billing details. Make this request to the payments endpoint.
Or you can send a credit payment using a card registration from a COPYandPAY checkout. You will need the card registration ID. Make this request to the registrations endpoint.
Credit requests and payouts with card details
Example requests with card details
These example requests show a basic credit request, and then include the required parameters for payouts, such as Visa Original Credit Transfers (OCT), MasterCard Payment of Winnings with MCC 7995, and MasterCard Send payouts. These parameters are for Trust Payments and PAYSTRAX.
Replace the {channelId}
and the {auth_token}
with your values.
curl https://eu-test.oppwa.com/v1/payments \
-d "entityId={channelId}" \
-d "amount=100.00" \
-d "currency=EUR" \
-d "paymentBrand=VISA" \
-d "paymentType=CD" \
-d "card.number=4200000000000000" \
-d "card.holder=John Smith" \
-d "card.expiryMonth=02" \
-d "card.expiryYear=2027" \
-d "card.cvv=123" \
-d "merchantTransactionId=P175" \
-d "testMode=EXTERNAL" \
-H "Authorization: Bearer {auth_token}"
curl https://eu-test.oppwa.com/v1/payments \
-d "entityId={channelId}" \
-d "amount=100.00" \
-d "currency=EUR" \
-d "paymentBrand=VISA" \
-d "paymentType=CD" \
-d "merchant.city=Vancouver" \
-d "recipient.givenName=Jane" \
-d "recipient.surname=Smith" \
-d "recipient.state=QC" \
-d "recipient.country=CAN" \
-d "recipient.accountNumberType=RTN_AND_BANK_ACCOUNT" \
-d "recipient.accountNumber=1234567890" \
-d "customParameters[CreditSenderName]=John Smith" \
-d "customParameters[CreditSenderAddress]=Grillparzerstr 18|Munich|BAV|DEU|81675" \
-d "customParameters[CreditSenderCity]=Munich" \
-d "customParameters[CreditSenderState]=BAV" \
-d "customParameters[CreditSenderCountry]=DEU" \
-d "card.number=4200000000000000" \
-d "card.holder=John Smith" \
-d "card.expiryMonth=02" \
-d "card.expiryYear=2027" \
-d "card.cvv=123" \
-d "merchantTransactionId=P175" \
-d "testMode=EXTERNAL" \
-H "Authorization: Bearer {auth_token}"
curl https://eu-test.oppwa.com/v1/payments \
-d "entityId={channelId}" \
-d "amount=100.00" \
-d "currency=EUR" \
-d "paymentBrand=MASTER" \
-d "paymentType=CD" \
-d "customer.givenName=John" \
-d "customer.surname=Smith" \
-d "customer.phone=0123456789" \
-d "merchant.city=Vancouver" \
-d "recipient.givenName=Jane" \
-d "recipient.surname=Smith" \
-d "recipient.accountNumberType=RTN_AND_BANK_ACCOUNT" \
-d "recipient.accountNumber=1234567890" \
-d "customParameters[TransactionTypeIdentifier]=C55" \
-d "customParameters[DateOfFunds]=250901" \
-d "customParameters[AdditionalTrace]=ABC123" \
-d "customParameters[CreditSenderName]=John Smith" \
-d "customParameters[CreditSenderAddress]=Grillparzerstr 18|Munich|BAV|DEU|81675" \
-d "customParameters[CreditSenderCity]=Munich" \
-d "customParameters[CreditSenderState]=BAV" \
-d "customParameters[CreditSenderCountry]=DEU" \
-d "card.number=4200000000000000" \
-d "card.holder=John Smith" \
-d "card.expiryMonth=02" \
-d "card.expiryYear=2027" \
-d "card.cvv=123" \
-d "merchantTransactionId=P175" \
-d "testMode=EXTERNAL" \
-H "Authorization: Bearer {auth_token}"
curl https://eu-test.oppwa.com/v1/payments \
-d "entityId={channelId}" \
-d "amount=100.00" \
-d "currency=EUR" \
-d "paymentBrand=MASTER" \
-d "paymentType=CD" \
-d "merchant.city=Vancouver" \
-d "recipient.givenName=Jane" \
-d "recipient.surname=Smith" \
-d "recipient.state=QC" \
-d "recipient.country=CAN" \
-d "recipient.accountNumberType=RTN_AND_BANK_ACCOUNT" \
-d "recipient.accountNumber=1234567890" \
-d "recipient.birthDate=1985-01-01" \
-d "recipient.phone=0123456789" \
-d "customParameters[TransactionTypeIdentifier]=C55" \
-d "customParameters[DateOfFunds]=250901" \
-d "customParameters[AdditionalTrace]=ABC123" \
-d "customParameters[CreditSenderName]=John Smith" \
-d "customParameters[CreditSenderAddress]=Grillparzerstr 18|Munich|BAV|DEU|81675" \
-d "customParameters[CreditSenderCity]=Munich" \
-d "customParameters[CreditSenderState]=BAV" \
-d "customParameters[CreditSenderCountry]=DEU" \
-d "card.number=4200000000000000" \
-d "card.holder=John Smith" \
-d "card.expiryMonth=02" \
-d "card.expiryYear=2027" \
-d "card.cvv=123" \
-d "merchantTransactionId=P175" \
-d "testMode=EXTERNAL" \
-H "Authorization: Bearer {auth_token}"
From the payment response, store the id
of the successful request for future reference.
For a successful transaction, the response code is 200
.
Here is an example response for a successful basic credit transaction in a SERVER-TO-SERVER environment.
{
"id": "8ac7a4a192b3b5060192b471c0d82dfb",
"paymentType": "CD",
"paymentBrand": "VISA",
"amount": "100.00",
"currency": "EUR",
"descriptor": "7548.8324.7369 ECOMChannel ",
"merchantTransactionId": "P175",
"result": {
"code": "000.100.112",
"description": "Request successfully processed in 'Merchant in Connector Test Mode'"
},
"resultDetails": {
"ExtendedDescription": "Approved or completed successfully",
"clearingInstituteName": "Postbank P.O.S. Transact GmbH",
"ConnectorTxID1": "852105",
"ConnectorTxID3": "26K00001",
"AcquirerResponse": "00",
"reconciliationId": "P175",
"merchantAccountId": "8a8294184f1d2f31014f25d1b00609b9"
},
"card": {
"bin": "420000",
"last4Digits": "0042",
"holder": "John Smith",
"expiryMonth": "02",
"expiryYear": "2027"
},
"risk": {
"score": "0"
},
"buildNumber": "1a09c7f6b69eaea67758a3050d39aeeeeec97625@2024-10-21 15:02:36 +0000",
"timestamp": "2024-10-22 13:36:46+0000",
"ndc": "8ac7a4c890fc748b0190fe6ad56b0241_cf4d3a0aa0f342e3a5837f7af9b5d994",
"source": "OPP",
"paymentMethod": "CC",
"shortId": "7548.8324.7369"
}
For full details of how to interpret a transaction response, see Transaction results.
For the gateway documentation of the Backoffice API, see Gateway Backoffice API documentation for Payout. Note that the credit request is described as a payout because the most common use case for this request is to make a standalone refund to a customer when a regular refund is not possible.
Test credit and payout with card details
You can test this request at Gateway Playground Credit Payment with the parameters as shown in the sample data here.
entityId={channelId}
amount=100.00
currency=EUR
paymentBrand=VISA
paymentType=CD
card.number=4200000000000000
card.holder=John Smith
card.expiryMonth=02
card.expiryYear=2027
card.cvv=123
merchantTransactionId=P175
testMode=EXTERNAL
entityId={channelId}
amount=100.00
currency=EUR
paymentBrand=VISA
paymentType=CD
merchant.city=Vancouver
recipient.givenName=Jane
recipient.surname=Smith
recipient.state=QC
recipient.country=CAN
recipient.accountNumberType=RTN_AND_BANK_ACCOUNT
recipient.accountNumber=1234567890
customParameters[CreditSenderName]=John Smith
customParameters[CreditSenderAddress]=Grillparzerstr 18|Munich|BAV|DEU|81675
customParameters[CreditSenderCity]=Munich
customParameters[CreditSenderState]=BAV
customParameters[CreditSenderCountry]=DEU
card.number=4200000000000000
card.holder=John Smith
card.expiryMonth=02
card.expiryYear=2027
card.cvv=123
merchantTransactionId=P175
testMode=EXTERNAL
entityId={channelId}
amount=100.00
currency=EUR
paymentBrand=MASTER
paymentType=CD
customer.givenName=John
customer.surname=Smith
customer.phone=0123456789
merchant.city=Vancouver
recipient.givenName=Jane
recipient.surname=Smith
recipient.accountNumberType=RTN_AND_BANK_ACCOUNT
recipient.accountNumber=1234567890
customParameters[TransactionTypeIdentifier]=C55
customParameters[DateOfFunds]=250901
customParameters[AdditionalTrace]=ABC123
customParameters[CreditSenderName]=John Smith
customParameters[CreditSenderAddress]=Grillparzerstr 18|Munich|BAV|DEU|81675
customParameters[CreditSenderCity]=Munich
customParameters[CreditSenderState]=BAV
customParameters[CreditSenderCountry]=DEU
card.number=4200000000000000
card.holder=John Smith
card.expiryMonth=02
card.expiryYear=2027
card.cvv=123
merchantTransactionId=P175
testMode=EXTERNAL
entityId={channelId}
amount=100.00
currency=EUR
paymentBrand=MASTER
paymentType=CD
merchant.city=Vancouver
recipient.givenName=Jane
recipient.surname=Smith
recipient.state=QC
recipient.country=CAN
recipient.accountNumberType=RTN_AND_BANK_ACCOUNT
recipient.accountNumber=1234567890
recipient.birthDate=1985-01-01
recipient.phone=0123456789
customParameters[TransactionTypeIdentifier]=C55
customParameters[DateOfFunds]=250901
customParameters[AdditionalTrace]=ABC123
customParameters[CreditSenderName]=John Smith
customParameters[CreditSenderAddress]=Grillparzerstr 18|Munich|BAV|DEU|81675
customParameters[CreditSenderCity]=Munich
customParameters[CreditSenderState]=BAV
customParameters[CreditSenderCountry]=DEU
card.number=4200000000000000
card.holder=John Smith
card.expiryMonth=02
card.expiryYear=2027
card.cvv=123
merchantTransactionId=P175
testMode=EXTERNAL
Credits and payouts with registered cards
You can make a credit request using card details you previously registered, for example, for metered payments or one-click checkout. You will need the card token registrationId
but you do not need to add any other specific parameters or customer details to the request.
Example requests with registered card
These examples show basic credit request, and then include the required parameters for payouts, with Visa Original Credit Transfers (OCT), MasterCard Payment of Winnings with MCC 7995, and MasterCard Send payouts. These parameters are for Trust Payments and PAYSTRAX.
Replace the {channelId}
and the {auth_token}
with your values.
curl https://eu-test.oppwa.com/v1/registrations/{id}/payments \
-d "entityId={channelId}" \
-d "paymentType=CD" \
-d "amount=17.99" \
-d "currency=EUR" \
-d "merchantTransactionId=P175" \
-d "testMode=EXTERNAL" \
-H "Authorization: Bearer {auth_token}"
curl https://eu-test.oppwa.com/v1/registrations/{id}/payments \
-d "entityId={channelId}" \
-d "amount=100.00" \
-d "currency=EUR" \
-d "paymentBrand=VISA" \
-d "paymentType=CD" \
-d "merchant.city=Vancouver" \
-d "recipient.givenName=Jane" \
-d "recipient.surname=Smith" \
-d "recipient.state=QC" \
-d "recipient.country=CAN" \
-d "recipient.accountNumberType=RTN_AND_BANK_ACCOUNT" \
-d "recipient.accountNumber=1234567890" \
-d "customParameters[CreditSenderName]=John Smith" \
-d "customParameters[CreditSenderAddress]=Grillparzerstr 18|Munich|BAV|DEU|81675" \
-d "customParameters[CreditSenderCity]=Munich" \
-d "customParameters[CreditSenderState]=BAV" \
-d "customParameters[CreditSenderCountry]=DEU" \
-d "merchantTransactionId=P175" \
-d "testMode=EXTERNAL" \
-H "Authorization: Bearer {auth_token}"
curl https://eu-test.oppwa.com/v1/registrations/{id}/payments \
-d "entityId={channelId}" \
-d "amount=100.00" \
-d "currency=EUR" \
-d "paymentBrand=MASTER" \
-d "paymentType=CD" \
-d "customer.givenName=John" \
-d "customer.surname=Smith" \
-d "customer.phone=0123456789" \
-d "merchant.city=Vancouver" \
-d "recipient.givenName=Jane" \
-d "recipient.surname=Smith" \
-d "recipient.accountNumberType=RTN_AND_BANK_ACCOUNT" \
-d "recipient.accountNumber=1234567890" \
-d "customParameters[TransactionTypeIdentifier]=C55" \
-d "customParameters[DateOfFunds]=250901" \
-d "customParameters[AdditionalTrace]=ABC123" \
-d "customParameters[CreditSenderName]=John Smith" \
-d "customParameters[CreditSenderAddress]=Grillparzerstr 18|Munich|BAV|DEU|81675" \
-d "customParameters[CreditSenderCity]=Munich" \
-d "customParameters[CreditSenderState]=BAV" \
-d "customParameters[CreditSenderCountry]=DEU" \
-d "merchantTransactionId=P175" \
-d "testMode=EXTERNAL" \
-H "Authorization: Bearer {auth_token}"
curl https://eu-test.oppwa.com/v1/registrations/{id}/payments \
-d "entityId={channelId}" \
-d "amount=100.00" \
-d "currency=EUR" \
-d "paymentBrand=MASTER" \
-d "paymentType=CD" \
-d "merchant.city=Vancouver" \
-d "recipient.givenName=Jane" \
-d "recipient.surname=Smith" \
-d "recipient.state=QC" \
-d "recipient.country=CAN" \
-d "recipient.accountNumberType=RTN_AND_BANK_ACCOUNT" \
-d "recipient.accountNumber=1234567890" \
-d "recipient.birthDate=1985-01-01" \
-d "recipient.phone=0123456789" \
-d "customParameters[TransactionTypeIdentifier]=C55" \
-d "customParameters[DateOfFunds]=250901" \
-d "customParameters[AdditionalTrace]=ABC123" \
-d "customParameters[CreditSenderName]=John Smith" \
-d "customParameters[CreditSenderAddress]=Grillparzerstr 18|Munich|BAV|DEU|81675" \
-d "customParameters[CreditSenderCity]=Munich" \
-d "customParameters[CreditSenderState]=BAV" \
-d "customParameters[CreditSenderCountry]=DEU" \
-d "merchantTransactionId=P175" \
-d "testMode=EXTERNAL" \
-H "Authorization: Bearer {auth_token}"
From the payment response, store the id
of the successful request for future reference.
For a successful transaction, the response code is 200
.
Here is an example response for the successful basic credit test transaction with a registered card.
{
"id":"8ac7a4a09780fc6a01978219fe113f61",
"paymentType":"CD",
"amount":"17.99",
"currency":"EUR",
"descriptor":"0552.1149.6322 MOTOChannel ",
"merchantTransactionId":"P175",
"result":{
"code":"000.100.112",
"description":"Request successfully processed in 'Merchant in Connector Test Mode'"
},
"resultDetails":{
"ExtendedDescription":"Approved or completed successfully",
"clearingInstituteName":"Postbank P.O.S. Transact GmbH",
"ConnectorTxID1":"700676",
"ConnectorTxID3":"26K00001",
"AcquirerResponse":"00",
"reconciliationId":"P175",
"merchantAccountId":"8a8294184f1d2f31014f25d1b00609b9"
},
"risk":{
"score":"0"
},
"buildNumber":"e1ddd751d5b4a7bd89ed8838e38be61e687f3b56@2025-06-18 00:42:25 +0000",
"timestamp":"2025-06-18 08:13:51+0000",
"ndc":"8ac7a4c890fc748b0190fe6a7ad7023d_cde0a8b44ca04423be063deceabb763e",
"standingInstruction":{
"source":"MIT",
"type":"UNSCHEDULED",
"mode":"REPEATED"
},
"source":"OPP",
"paymentMethod":"CC",
"shortId":"0552.1149.6322"
}
Test credit with registered card
To try this in the gateway playground, see the section on Sending a subsequent payment in the Gateway Backoffice API documentation for Card on File. Use the payment type CD
and the set of parameters as shown in the following example.
entityId={channelId}
paymentType=CD
amount=17.99
currency=EUR
merchantTransactionId=P175
testMode=EXTERNAL
entityId={channelId}
amount=100.00
currency=EUR
paymentBrand=VISA
paymentType=CD
merchant.city=Vancouver
recipient.givenName=Jane
recipient.surname=Smith
recipient.state=QC
recipient.country=CAN
recipient.accountNumberType=RTN_AND_BANK_ACCOUNT
recipient.accountNumber=1234567890
customParameters[CreditSenderName]=John Smith
customParameters[CreditSenderAddress]=Grillparzerstr 18|Munich|BAV|DEU|81675
customParameters[CreditSenderCity]=Munich
customParameters[CreditSenderState]=BAV
customParameters[CreditSenderCountry]=DEU
merchantTransactionId=P175
testMode=EXTERNAL
entityId={channelId}
amount=100.00
currency=EUR
paymentBrand=MASTER
paymentType=CD
customer.givenName=John
customer.surname=Smith
customer.phone=0123456789
merchant.city=Vancouver
recipient.givenName=Jane
recipient.surname=Smith
recipient.accountNumberType=RTN_AND_BANK_ACCOUNT
recipient.accountNumber=1234567890
customParameters[TransactionTypeIdentifier]=C55
customParameters[DateOfFunds]=250901
customParameters[AdditionalTrace]=ABC123
customParameters[CreditSenderName]=John Smith
customParameters[CreditSenderAddress]=Grillparzerstr 18|Munich|BAV|DEU|81675
customParameters[CreditSenderCity]=Munich
customParameters[CreditSenderState]=BAV
customParameters[CreditSenderCountry]=DEU
merchantTransactionId=P175
testMode=EXTERNAL
entityId={channelId}
amount=100.00
currency=EUR
paymentBrand=MASTER
paymentType=CD
merchant.city=Vancouver
recipient.givenName=Jane
recipient.surname=Smith
recipient.state=QC
recipient.country=CAN
recipient.accountNumberType=RTN_AND_BANK_ACCOUNT
recipient.accountNumber=1234567890
recipient.birthDate=1985-01-01
recipient.phone=0123456789
customParameters[TransactionTypeIdentifier]=C55
customParameters[DateOfFunds]=250901
customParameters[AdditionalTrace]=ABC123
customParameters[CreditSenderName]=John Smith
customParameters[CreditSenderAddress]=Grillparzerstr 18|Munich|BAV|DEU|81675
customParameters[CreditSenderCity]=Munich
customParameters[CreditSenderState]=BAV
customParameters[CreditSenderCountry]=DEU
merchantTransactionId=P175
testMode=EXTERNAL
To obtain more information about a credit request in general, see the Gateway Backoffice API documentation for Payout, which is the SERVER-TO-SERVER version of this request.
Payout requests parameters table
The following table provides more details about the above parameters.
Key | Example Value | Value Format / Options | Mandatory |
---|---|---|---|
entityId | {channelId} | AN32 | Yes |
amount | 100.00 | N10.N2 | Yes |
currency | EUR | A3 | Yes |
merchantTransactionId | ABC123 | AN..255 | No, but recommended |
paymentBrand | MASTER | VISA, MASTER... | Yes |
paymentType | CD | CD | Yes |
customer.givenName | John | AN..50 | Yes for Mastercard Payment of Winnings - MCC 7995. |
customer.surname | Smith | AN..50 | Yes for Mastercard Payment of Winnings - MCC 7995. |
customer.phone customer.mobile | 0123456789 | AN..25 | Yes for Mastercard Payment of Winnings - MCC 7995. |
merchant.city | Vancouver | ANS13 | Yes |
recipient.givenName | Jane | AN48 | Yes |
recipient.surname | Smith | AN48 | Yes |
recipient.state | QC | ANS..3 | Yes for Visa OCTs and Mastercard Send to US and Canada |
recipient.country | CAN | A3 | Yes for Visa OCTs and Mastercard Send to US and Canada |
recipient. accountNumberType | RTN_AND_ BANK_ACCOUNT | Indicates type of recipient's account. Possible values are: OTHER RTN_AND_BANK_ACCOUNT IBAN EMAIL PHONE_NUMBER BAN_AND_BIC WALLET_ID SOCIAL_NETWORK_ID | Yes |
recipient.accountNumber | 1234567890 | ANS..50 | Yes |
customParameters[ TransactionTypeIdentifier] | C04 | Possible values are: C04 - Gaming Replay C07 - Moneysend General Person to Person Transfer C52 - Moneysend General Transfer to Own Account C53 - Moneysend Agent Cash Out C54 - Moneysend Payment of Own Credit Card Bill C55 - Moneysend Business Disbursement C56 - Moneysend Govt. Non Profit Disbursement C57 - Rapid Merchant Settlement C65 - General Business to Business Transfer | Yes for Mastercard Send Payment and Payment of Winnings transactions |
customParameters[ DateOfFunds] | 250901 | YYMMDD | Yes for Mastercard Send Payment and Payment of Winnings - MCC 7995 |
customParameters[ AdditionalTrace] | ABC123 | N19 (should be unique per transaction) | Yes for Mastercard Send Payment and Payment of Winnings - MCC 7995 |
customParameters[ CreditSenderName] | Jane Smith | AN..30 | Yes |
customParameters[ CreditSenderAddress] | Grillparzerstr 18| Munich|BAV| DEU|81675 | AN.. 35 Street|City|StateCode(US Only)|ISO3166 CountryCode|PostalCode | Yes |
customParameters[ CreditSenderCity] | Munich | AN..25 | Yes |
customParameters[ CreditSenderState] | BAV | AN3 | Yes |
customParameters[ CreditSenderCountry] | DEU | AN3 | Yes |