documentation
Search…
Backoffice Operations
You can perform different types of backoffice operations using our Server-to-Server REST API.

Quick links

Note: Backoffice operations can be performed against initial payments that were generated using COPYandPAY or Server-to-Server. The referencedPaymentId is the value return in the id JSON field.

Capture (CP) an authorization

A capture is used to request clearing for previously authorized funds. A capture request is performed against a previous preauthorization (PA) payment by referencing its payment.id and sending a POST request over HTTPS to the /v1/payments/{id} endpoint. Captures can be for full or partial amounts. Note that a capture is a one-time event. Once a capture (even partial) has been performed, the preauthorization is not valid anymore for future captures.
Capture (CP) Request
Response
1
curl https://test.oppwa.com/v1/payments/{id} \
2
-d "entityId=8a8294174e918ca6014e9c6f5ae12a9c" \
3
-d "amount=1.00" \
4
-d "currency=BRL" \
5
-d "paymentType=CP" \
6
-d "testMode=EXTERNAL" \
7
-H "Authorization: Bearer OGE4Mjk0MTcyODFiOGVlMzAxMjgyOTkwNjZmNTBjZGJ8ZGVtbw=="
Copied!
1
{
2
"id":"8a8294496242ba5301625069d1b27e3d",
3
"paymentType":"CP",
4
"amount":"1.00",
5
"currency":"BRL",
6
"descriptor":"123 Usage",
7
"merchantTransactionId":"Order Number 123",
8
"result":{
9
"code":"000.100.112",
10
"description":"Request successfully processed in 'Merchant in Connector Test Mode'"
11
},
12
"customer":{
13
"merchantCustomerId":"12345678909"
14
},
15
"buildNumber":"[email protected] 13:31:26 +0000",
16
"timestamp":"2018-03-23 01:12:17+0000",
17
"ndc":"8a8294174e918ca6014e9c6f5ae12a9c_9bba1957b8e2492485f25fea121a0842"
18
}
Copied!

Refund (RF) a payment

A refund is performed against a previous payment, referencing its payment.id by sending a POST request over HTTPS to the /v1/payments/{id} endpoint. A refund can be performed against debit (DB) or captured preauthorization (PA->CP) payment types. Where supported, the amount field can be used to process a partial or full amount.
Refund (RF) Request
Response
1
curl https://test.oppwa.com/v1/payments/{id} \
2
-d "entityId=8a8294174e918ca6014e9c6f5ae12a9c" \
3
-d "amount=1.00" \
4
-d "currency=BRL" \
5
-d "paymentType=RF" \
6
-d "testMode=EXTERNAL" \
7
-H "Authorization: Bearer OGE4Mjk0MTcyODFiOGVlMzAxMjgyOTkwNjZmNTBjZGJ8ZGVtbw=="
Copied!
1
{
2
"id":"8a82944a6242c8f00162506ec4b30d44",
3
"paymentType":"RF",
4
"amount":"1.00",
5
"currency":"BRL",
6
"descriptor":"123 Usage",
7
"merchantTransactionId":"Order Number 123",
8
"result":{
9
"code":"000.100.112",
10
"description":"Request successfully processed in 'Merchant in Connector Test Mode'"
11
},
12
"customer":{
13
"merchantCustomerId":"12345678909"
14
}, "buildNumber":"a21e2790973ffee19[email protected] 13:31:26 +0000",
15
"timestamp":"2018-03-23 01:17:41+0000",
16
"ndc":"8a8294174e918ca6014e9c6f5ae12a9c_29f945aaf03d4d10908622d4a66e6632"}
Copied!
Allowed Refund timelines
Country
Connector
Refund timeline (days after purchase)
Argentina
First Data
1 year from the original purchase.
Argentina
Prisma
90 days, it is recommended to do it in the same month.
Argentina
Mercadopago
90 days.
Brazil
Cielo
Visa: 300 days Master: 180 days.
Brazil
Stone
Credit: 350 days Debit: 90 days.
Brazil
Rede
90 days.
Brazil
Mercadopago
120 days.
Chile
Transbank
11 months.
Colombia
Redeban
120 days.
Colombia
Credibanco
10 months
México
Openpay/BBVA
180 days, recommended to be done in the same month.
México
Banorte
90 days.
Perú
Niubiz
Via API: 6 months. Via Niubiz: 1 year.

Reverse (RV) a payment

A reversal is performed against a previous payment, referencing its payment.id by sending a POST request over HTTPS to the /v1/payments/{id} endpoint. A reversal can be sent against debit (DB) or preauthorization (PA) payment types. When reversing a card payment and if sent within 72 hours of the original request, a reversal causes an authorization reversal request to be sent the card issuer to clear the funds held against the authorization.
Reversal (RV) Request
Response
1
curl https://test.oppwa.com/v1/payments/{id} \
2
-d "entityId=8a8294174e918ca6014e9c6f5ae12a9c" \
3
-d "paymentType=RV" \
4
-d "testMode=EXTERNAL" \
5
-H "Authorization: Bearer OGE4Mjk0MTcyODFiOGVlMzAxMjgyOTkwNjZmNTBjZGJ8ZGVtbw=="
Copied!
1
{
2
"id":"8a82944a6242c8f00162505f33cf77ef",
3
"paymentType":"RV",
4
"amount":"1.00",
5
"currency":"MXN",
6
"descriptor":"7861.8263.2098 MX_CC_Initial 123 Usage",
7
"merchantTransactionId":"Order Number 321",
8
"result":{
9
"code":"000.100.112",
10
"description":"Request successfully processed in 'Merchant in Connector Test Mode'"
11
},
12
13
"buildNumber":"[email protected] 13:31:26 +0000",
14
"timestamp":"2018-03-23 01:00:40+0000",
15
"ndc":"8a8294174e918ca6014e9c6f5ae12a9c_2d815eace88a4243ad4f1b1345408c76"
16
}
Copied!
Note: A full reversal does not require the amount or currency to be sent. If the acquirer supports it, partial reversals are also possible. In this latter case amount and currency must be specified in the request.
Last modified 7mo ago