GladysDevelopers

Refund a payment

Sends money back to the payer. Omit the amount to refund everything not already refunded. The Gladys fee is not returned.

Choose a TEST app to send requests from the playground.
post/payments/{reference}/refunds

Sends money back to the payer. Omit the amount to refund everything not already refunded. The Gladys fee is not returned.

Authorization

BearerAuth
headerAuthorizationBearer <token>

An access token from POST /oauth/token: client_credentials for your own app, or authorization_code for a user who connected it.

Path Parameters

reference*string

Payment reference

Header Parameters

Idempotency-Key?string

One value per action, resent unchanged on every retry. Will become required (400 IDEMPOTENCY_KEY_REQUIRED without it)

Request Body

Amount and reason

application/json
  1. body
amount?string
metadata?string
reason?string

Response Body

Created

application/json
  1. response
data?
error?
message?string
meta?
success?boolean
curl -X POST "https://example.com/payments/string/refunds" \  -H "Content-Type: application/json" \  -d '{}'
{  "error": {    "code": "string",    "details": {      "property1": "string",      "property2": "string"    },    "message": "string"  },  "message": "string",  "meta": {    "pagination": {      "next_cursor": "string",      "page": 0,      "per_page": 0,      "total_items": 0,      "total_pages": 0    }  },  "success": true,  "data": {    "amount": "1500.00",    "created_at": "string",    "currency": "string",    "environment": "LIVE",    "metadata": "string",    "payment_reference": "string",    "reason": "string",    "reference": "string"  }}