Skip to content
MrIvoryMrIvory
Connect processor Merchant panel

Money out

Refund

POST /pgui/services/paymentServices/refund/initiate — JSON. You can also refund from the panel sales report.

Request

FieldRequiredNotes
APP_IDYesYour APP_ID
TXN_IDYesThe sale TXN_ID
ORDER_IDYesMust match that sale
AMOUNTNoMinor units. Omit to refund whatever is still unrefunded
HASHYesInclude AMOUNT in the hash only if you send it
JSON
{
  "APP_ID": "1000221129001154",
  "TXN_ID": "16-digit sale id",
  "ORDER_ID": "S2S-001",
  "AMOUNT": "500",
  "HASH": "<128 hex>"
}

Rules this server enforces

  • Sale must exist for that APP_ID and ORDER_ID, kind SALE. Else 302.
  • Sale must be RESPONSE_CODE=000 and STATUS=Captured. Else 016.
  • AMOUNT must be a positive integer. Else 016.
  • Sum of refunds cannot exceed the sale amount. Else 013.

Response

Success is 000 + Captured. TXN_ID is a new refund id. ORDER_ID stays the sale order. Message text includes that order id.

JSON
{
  "RESPONSE_CODE": "000",
  "STATUS": "Captured",
  "TXN_ID": "new refund id",
  "ORDER_ID": "S2S-001",
  "AMOUNT": "500",
  "CURRENCY_CODE": "784",
  "HASH": "…"
}

There is no void API on this sandbox.

Refunds call the sale’s assigned adapter (plugin.refund). Missing keys fail closed except the sandbox simulator. See Processors.