Nomod
Hosted Checkout/Create Refund

Create Refund

posthttps://api.nomod.com/v1/checkout/{id}/refund

Create refund.

curl -X POST 'https://api.nomod.com/v1/checkout/:id/refund' \
  -H 'X-API-KEY: $NOMOD_API_KEY' \
  -H 'Content-Type: application/json'

Path parameters

idstringrequired

Responses

refund_idstring <uuid>required

Unique refund ID

charge_idstring <uuid>required

Unique charge ID (payment ID) associated with the checkout session

statusobjectrequired

Refund status: pending, completed, failed * `pending` - pending * `completed` - completed * `failed` - failed

amountintegerrequired

Total refund amount in the major currency unit (e.g., USD, AED)

Min: 1

currencystringrequired

Currency code (ISO 4217 format, e.g., USD, INR, AED)

Max length: 3

refund_timestring <date-time>required

ISO timestamp of refund

reasonstring

Reason for refund (if provided)

reference_idstring

Reference ID passed in the request

metadataobject

A set of key-value pairs that merchants can attach to an object. This can be useful for storing additional information about the object in a structured format.Maximum of 40 pairs allowed. Keys must be alphanumeric and cannot contain square brackets ([ and ]). Keys must not exceed 24 characters, and values must not exceed 512 characters.

Example response

{
  "refund_id": "00000000-0000-0000-0000-000000000000",
  "charge_id": "00000000-0000-0000-0000-000000000000",
  "status": {
    "0": "p",
    "1": "e",
    "2": "n",
    "3": "d",
    "4": "i",
    "5": "n",
    "6": "g"
  },
  "amount": 1,
  "currency": "string",
  "refund_time": "2026-01-01T00:00:00Z",
  "reason": "string",
  "reference_id": "string",
  "metadata": {}
}