Skip to main content

Refund

v1

Description

This webhook event notifies when the refund event is triggered on the Any of cancel .return or RTO flow.


Supported Type

  • Refund_Pending
  • Refund_Initiated
  • Refund_Done
  • Refund_Failed

Payload

refund_pending

{
"payload": {
"refund_information": [
{
"meta": {
"logo_url": {
"large": "https://cdn.fynd.com/v2/falling-surf-7c8bb8/fyprod/wrkr/payments/original/2qRUOzyNu-cod.png",
"small": "https://cdn.fynd.com/v2/falling-surf-7c8bb8/fyprod/wrkr/payments/original/2qRUOzyNu-cod.png"
},
"merchant_code": "",
"payment_gateway": null,
"payment_identifier": "COD"
},
"collect_by": "fynd",
"refund_by": "fynd",
"mode": "COD",
"name": "COD",
"amount": 101391
}
],
"merchant_refund_id": "16980501318051941643",
"forward_shipment_id": null,
"journey_type": "RETURN",
"order_id": "FY652CF24E0E8B96A1EC",
"payment_status": "refund_pending",
"merchant_order_id": "FY652CF24E0E8B96A1EC"
},
"meta": {
"event": {
"name": "refund",
"type": "refund_pending",
"version": "1"
},
"service": {
"name": "gringotts"
},
"company_id": 884,
"application_id": "000000000000000000000004",
"extension_id": null,
"trace_id": [],
"created_timestamp": 1700162803072,
"trace": "gringotts.12e11be8-84b6-11ee-b92c-96d30b47d8a8",
"timestamp": "2023-11-16T19:26:43.072121"
},
"merchant_order_id": "FY652CF24E0E8B96A1EC",
"partition_identifier": "FY652CF24E0E8B96A1EC"
}

refund_initiate

{
"event": {
"trace_id": [
"gringotts.c42c7e06-8705-4b41-bed3-42b1a3cb4570"
],
"name": "webhook_refund_status",
"type": "refund_initiate",
"version": "1",
"created_timestamp": 1692618678094,
"id": "86/gZnC35GuVhRj7DLn59U349wLInInrR8PwN9z+7mY=",
"category": "application"
},
"company_id": 13,
"application_id": "63a0490757475baff6154585",
"contains": [
"refund_initiate"
],
"payload": {
"order_id": "FY64DC599B0E460A635C",
"refund_information": [
{
"amount": 824,
"mode": "NB",
"name": "NB",
"collect_by": "fynd",
"refund_by": "fynd",
"payment_gateway": "razorpay",
"payment_identifier": "ICIC",
"transaction_timestamp": null,
"payout_details": {
# payment gateway response details
}
"refund_details": {
"amount": 824,
"unique_request_id": null,
"ref": null,
"bag_id": "16934317265101369912",
"success": false,
"status": "refund_pending",
"message": "None",
"transaction_id": null,
"payment_status": "refund_pending"
}
}
],
"merchant_refund_id": "16921625492931071795",
"forward_shipment_id": "16921624615451765515",
"journey_type": "CANCELLED_FYND"
}
}

Refund Failed

{
"payload": {
"refund_information": [
{
"refund_by": "fynd",
"meta": {
"code": "total",
"logo_url": {
"large": "https://cdn.fynd.com/v2/falling-surf-7c8bb8/fyprod/wrkr/payments/original/2qRUOzyNu-cod.png",
"small": "https://cdn.fynd.com/v2/falling-surf-7c8bb8/fyprod/wrkr/payments/original/2qRUOzyNu-cod.png"
},
"order_id": "1815205",
"current_status": "started",
"payment_gateway": "COD"
},
"mode": "COD",
"name": "COD",
"amount": 2999,
"collect_by": "fynd"
}
],
"order_id": "FY654707FC0E97B36E4C",
"forward_shipment_id": null,
"merchant_refund_id": "16994472698991031341",
"merchant_order_id": "FY654707FC0E97B36E4C",
"journey_type": "RETURN",
"payment_status": "refund_failed"
},
"meta": {
"event": {
"name": "refund",
"type": "refund_failed",
"version": "1"
},
"service": {
"name": "gringotts"
},
"company_id": 442,
"application_id": "5e2fafc88b352fdcbc49fa30",
"extension_id": null,
"trace_id": [],
"created_timestamp": 1700179115750,
"trace": "gringotts.0dfe4f3a-84dc-11ee-8092-26042a7edbbc",
"timestamp": "2023-11-16T23:58:35.750606"
},
"merchant_order_id": "FY654707FC0E97B36E4C",
"partition_identifier": "FY654707FC0E97B36E4C"
}

Refund Done

{
"payload": {
"merchant_order_id": "FY6554BE0D0EE92A66DA",
"payment_status": "refund_done",
"journey_type": "CANCELLED_FYND",
"refund_information": [
{
"refund_by": "fynd",
"name": "PartnerPay",
"refund_details": {
"ref": "rfnd_N1QIdW6qonjLDi",
"merchant_refund_id": "17001983497981536760",
"transaction_id": null,
"success": true,
"payment_status": "refund_done",
"pg_reference_id": "rfnd_N1QIdW6qonjLDi",
"error_traceback": null,
"journey_type": "CANCELLED_FYND",
"message": "data fetched",
"unique_request_id": "rfnd_N1QIdW6qonjLDi",
"status": "refund_done",
"amount": 82.05,
"payout_details": {
"id": "rfnd_N1QIdW6qonjLDi",
"entity": "refund",
"amount": 8205,
"currency": "INR",
"payment_id": "pay_N0kuNRBu8cVapb",
"notes": {
"merchant_refund_id": "17001983497981536760"
},
"receipt": "17001983497981536760",
"acquirer_data": {
"arn": null
},
"created_at": 1700198351,
"batch_id": "",
"status": "processed",
"speed_processed": "normal",
"speed_requested": "normal"
},
"bag_id": "17001983497981536760"
},
"collect_by": "fynd",
"amount": 82,
"mode": "PP",
"meta": {
"id": "FY6554BE0D0EE92A66DA",
"mode": "",
"logo_url": {
"large": "https://cdn.fynd.com/v2/falling-surf-7c8bb8/fyprod/wrkr/payments/original/Az7lv_ytK-netbanking.png",
"small": "https://cdn.fynd.com/v2/falling-surf-7c8bb8/fyprod/wrkr/payments/original/Az7lv_ytK-netbanking.png"
},
"payment_id": null
}
},
{
"refund_by": "seller",
"name": "gift_card",
"collect_by": "seller",
"amount": 616,
"mode": "GFTCRD",
"meta": {
"id": null,
"mode": "",
"logo_url": {
"large": "https://cdn.fynd.com/v2/falling-surf-7c8bb8/fyprod/wrkr/payments/original/chcb_6zwu-cod.png",
"small": "https://cdn.fynd.com/v2/falling-surf-7c8bb8/fyprod/wrkr/payments/original/chcb_6zwu-cod.png"
},
"gift_card": "GFTCRD",
"payment_id": "FY6554BE0D0EE92A66DA"
}
}
],
"order_id": "FY6554BE0D0EE92A66DA",
"forward_shipment_id": "17000524951591070296",
"merchant_refund_id": "17001983497981536760"
},
"meta": {
"event": {
"name": "refund",
"type": "refund_done",
"version": "1"
},
"service": {
"name": "gringotts"
},
"company_id": 46,
"application_id": "605884f889251331fe847d80",
"extension_id": null,
"trace_id": [],
"created_timestamp": 1700198352097,
"trace": "gringotts.d7bfd7c2-8508-11ee-9dc1-9a230b996ecb",
"timestamp": "2023-11-17T05:19:12.097091"
},
"merchant_order_id": "FY6554BE0D0EE92A66DA",
"partition_identifier": "FY6554BE0D0EE92A66DA"
}

Object Properties

Parent FieldFieldsField TypeDescriptionIs Required
order_idstringIt is the unique id of OrderYes
Refund InformationAmountintegerThe Amount to be refunded
ModestringPayment mode via which refund need to be done
NamestringThe Name of the Mode
Collect bystringWhom so ever collected the money
refund bystringWhomsoever will refund the money
Payment_gatewaystringVia which payment gateway refund need to be done
payment_identifierstringVia which payment identifier the refund need to be done
transaction_timestampdatetimeThe Date time for transaction timestamp
Refund_DetailsAmountintegerThe Amount to be refunded
Unique_request_idUnique request Id that is generated
refThe ref is the Id that we get as a response from payment gateway
bag_idUnique id of the bag
SuccessShow whether the transaction is success full or not
StatusShow what the current status of the transaction ( Pending , Success or failed
MessageThe message that we get from the gate way
Transaction_idThis is the unique transaction id
payment_StatusstringStatus of the payment .yes
merchant_refund_idThis is the unique id of orderyes
forward_shipment_idThis is the shipment idyes
journey_typestringStatus of the orderyes