post
https://partner.gupshup.io/partner/bizgate/app//payment/refund
Initiates a refund for a completed WhatsApp Pay transaction on the app, using the reference details supplied in the JSON body.
Request parameters
Path parameters
| Key | Description | Values | Data Type | Required/Optional |
|---|---|---|---|---|
| appId | Identifier of the WhatsApp app the call acts on. | 6f414190-d45c-4671-bca1-fb6c3018cb13 | String | Required |
Body
| Key | Description | Values | Data Type | Required/Optional |
|---|---|---|---|---|
| reference_id | Reference id of the original transaction to refund | reference-id-07 | — | Required |
| payment_config_id | Name of the payment configuration the transaction was taken through | Gupshup-testing | — | Required |
| amount | Amount to refund. All three of its fields are enforced by the provider. | — | — | Required |
| speed | Processing speed. Optional — omit it and the provider applies its default. The speed actually applied is reported back as speed_processed, which may differ. | normal | — | Optional |
Sample cURL — Payment refund.
curl --request POST \
--url 'https://partner.gupshup.io/partner/bizgate/app/6f414190-d45c-4671-bca1-fb6c3018cb13/payment/refund' \
--header 'Authorization: Bearer <UT>' \
--header 'Accept: application/json' \
--header 'Content-Type: application/json' \
--data '{
"reference_id" : "YOUR_TRANSACTION_REFERENCE_ID",
"payment_config_id" : "YOUR_PAYMENT_CONFIG_ID",
"amount" : {
"offset" : 100,
"currency" : "INR",
"value" : 100
}
}'Sample success response (200)
{
"status": "success",
"data": {
"id": "refund-id",
"status": "pending",
"speed_processed": "normal"
}
}Recent Requests
Log in to see full request history
| Time | Status | User Agent | |
|---|---|---|---|
Retrieving recent requests… | |||
Loading…