Simulate a Card Transaction Authorization Reversal - EEA
Ssimulate a retail location’s reversal of a card authorization.
The retail location where a card was used for a purchase can send a reversal through the card network to cancel a previous authorization request. This can occur when the transaction is not completed within the time required by the card issuer. When Rapyd receives a request for reversal from the card network, it reverses the transaction and sends you a webhook. Use this method in the sandbox.
This method triggers Card Issuing Reversal Webhook . This method moves the reversed funds in the wallet from on-hold balance to available balance. See Wallet Balance Types.
This method applies to cards issued in the European Economic Area (EEA). For cards issued outside the EEA, see Simulate a Card Transaction Authorization Reversal - Non-EEA.
Prerequisites:
amount
The amount of the reversal, in units of the currency defined in
currency
. Decimal. If omitted, the reversal is for the entire amount of the authorization.
authorization_id
ID of the authorization. String starting with cardauth_. Use the value of
id
in the response to Simulate a Card Transaction Authorization Request - EEA.
card_id
ID of the card. String starting with card_.
currency
The currency of the reversal. Three-letter ISO 4217 code.
/v1/issuing/cards/reversal
Authorization Reversal - Full
curl -X post https://sandboxapi.rapyd.net/v1/issuing/cards/reversal -H 'access_key: your-access-key-here' -H 'Content-Type: application/json' -H 'idempotency: your-idempotency-parameter-here' -H 'salt: your-random-string-here' -H 'signature: your-calculated-signature-here' -H 'timestamp: your-unix-timestamp-here' -d '{ "card_id": "card_c0acb5d35a78fcf4473bc98b1cda8cf9", "authorization_id": "cardauth_8f9260135a9a029f9655bb386363eaf4" } '
{ "status": { "error_code": "", "status": "SUCCESS", "message": "", "response_code": "", "operation_id": "4747ff6f-9c68-499d-b451-9c46354657bf" }, "data": { "id": "cardauth_d69434cc27bfcd8e5c793f1d810bb46e", "card_id": "card_c0acb5d35a78fcf4473bc98b1cda8cf9", "card_transaction_id": "cit_81a60ea4b79a4de37fc18d226dbc1279", "amount": 7, "currency_code": "USD", "txn_type": "REVERSAL", "auth_response": { "code": "00", "message": "APPROVED_OR_COMPLETED_SUCCESSFULLY" }, "is_remote_auth": false, "remote_auth_endpoint": "", "remote_auth_response": null, "transaction_amount": 7, "transaction_currency_code": "USD", "fx_rate": null, "merchant_category_code": "", "merchant_name_location": "TEST MERCHANT", "merchant_identification_code": "#RAPYD SANDBOX#" } }
Authorization Reversal - Partial
curl -X post https://sandboxapi.rapyd.net/v1/issuing/cards/reversal -H 'access_key: your-access-key-here' -H 'Content-Type: application/json' -H 'idempotency: your-idempotency-parameter-here' -H 'salt: your-random-string-here' -H 'signature: your-calculated-signature-here' -H 'timestamp: your-unix-timestamp-here' -d '{ "card_id": "card_c0acb5d35a78fcf4473bc98b1cda8cf9", "amount": 5, "currency": "USD", "authorization_id": "cardauth_a5a869a6f202d05af2eb24a068dd9639" } '
{ "status": { "error_code": "", "status": "SUCCESS", "message": "", "response_code": "", "operation_id": "d94270ed-b649-4478-9fd3-c93c063ea218" }, "data": { "id": "cardauth_9b0b328ca26e95ff17deceebd9cba9b0", "card_id": "card_c0acb5d35a78fcf4473bc98b1cda8cf9", "card_transaction_id": "cit_9f9eef4866bf656420e6fa0486e419ca", "amount": 3, "currency_code": "USD", "txn_type": "REVERSAL", "auth_response": { "code": "00", "message": "APPROVED_OR_COMPLETED_SUCCESSFULLY" }, "is_remote_auth": false, "remote_auth_endpoint": "", "remote_auth_response": null, "transaction_amount": 3, "transaction_currency_code": "USD", "fx_rate": null, "merchant_category_code": "", "merchant_name_location": "TEST MERCHANT", "merchant_identification_code": "#RAPYD SANDBOX#" } }