Refund a payment intent
POST {{baseUrl}}/v1/paymentIntents/:id/refund
Body Params
idempotencyKey string (REQUIRED) Universally unique identifier (UUID v4) idempotency key. This key is utilized to ensure exactly-once execution of mutating requests.
destination object (REQUIRED) The destination of a crypto refund.
address string (REQUIRED) The blockchain address.
addressTag string The secondary identifier for a blockchain address. An example of this is the memo field on the Stellar network, which can be text, id, or hash format.
chain string (REQUIRED) A blockchain that a given currency is available on.
amount (REQUIRED) The source amount of the refund, it can be in either the original payment currency or the settlement currency.
- currency string (REQUIRED) Currency code.
toAmount (REQUIRED) The destination amount of the refund, it must be in the original payment currency.
amount string (REQUIRED) Magnitude of the amount, in units of the currency, with a
.
.currency string (REQUIRED) Currency code.
Request Body
{"idempotencyKey"=>"{{$guid}}", "destination"=>{"address"=>"0x8381470ED67C3802402dbbFa0058E8871F017A6F", "chain"=>"POLY", "addressTag"=>"123456789"}, "amount"=>{"currency"=>"USD"}, "toAmount"=>{"amount"=>"3.14", "currency"=>"USD"}}
HEADERS
Key | Datatype | Required | Description |
---|---|---|---|
Content-Type | string | ||
Accept | string |
RESPONSES
status: Created
{"data":{"id":"e02e0a19-823f-378b-a468-c713d669eb15","type":"refund","status":"pending","amount":{"amount":"3.14","currency":"USD"},"createDate":"2024-01-17T21:37:14.685264Z","updateDate":"2024-01-17T21:37:14.685264Z","merchantId":"dfee2397-f3d6-4676-8405-4dda7e1b5b0d","merchantWalletId":"1000594146","paymentIntentId":"513fee57-0557-448d-bee5-32e8e6518f25","settlementAmount":{"amount":"3.14","currency":"USD"},"depositAddress":{"chain":"POLY","address":"0x8381470ED67C3802402dbbFa0058E8871F017A6F","addressTag":"123456789"}}}