KashierDevelopersKashier Developers

Reverse an order

curl -X PUT "https://test-api.kashier.io/v3/payment/reversal/string" \  -H "Content-Type: application/json" \  -d '{    "apiOperation": "REVERSAL"  }'
{  "response": {},  "transactionId": "string",  "messages": {    "en": "string",    "ar": "string"  },  "status": "string",  "provider": {    "type": "string",    "version": "string"  }}

Reverses a transaction at the rail level. This is the card-present and BNPL undo — for an ordinary online card sale reach for void (before settlement) or refund (after) instead, which is almost always what you want.

The same operation as PUT /v3/orders/{orderId} with apiOperation: REVERSAL. The checkout host forwards to this exact route without authenticating.

Send your secret key in the Authorization header.

Kashier has not published the request fields for reversal beyond apiOperation, so only that one is described here. Anything else you send is forwarded as-is.

Authorization

secretKey
Authorization<token>

Merchant secret key used to identify the merchant, obtained from Kashier's dashboard. Pass the raw secret key value in the Authorization header (NOT a "Bearer" token).

In: header

Path Parameters

orderId*string

Kashier's order id.

Request Body

application/json

The same body the checkout host forwards for a reversal.

TypeScript Definitions

Use the request body type in TypeScript.

Reverse a transaction on the order. Reversal is the rail-level undo used mainly by card-present and BNPL flows; for an ordinary online card sale you want VOID (before settlement) or REFUND (after).

Kashier has not published the field list beyond apiOperation, so any additional fields are passed through as sent.

Response Body

application/json

application/json

application/json

application/json

application/json

application/json

PUT
/v3/payment/reversal/{orderId}