Offer Events
To send basic offer information to the merchants regarding the offer selected by the user on the Payment Page. Merchants can further use these events as per their requirement. Some use cases are as follows.
To display offer information on the merchant’s UI
To add validation against the offer information received in order status response
Coupon based offer events
Events would be sent when the user applies or removes a coupon available on the coupons screen.
Sample payload on coupon application and removal are as follows
{
offer_applied: true,
final_amount: 100,
error_message: null,
offer_details: [{
auto_apply: false,
offer_code: "HDFC10",
offer_type: ["instant_discount", "cashback"],
discount_amount: 50,
cashback_amount: 50,
ids: []
}]
}
Auto-Apply offer events
Events would be sent when the user selects / deselects a Payment instrument having an Offer.
For Addcard / UPI collect screen, events will be triggered once the user enters a valid card / vpa that has an offer.
Sample payload on offer application and removal are as follows
{
offer_applied: true,
final_amount: 100,
error_message: null,
offer_details: [{
auto_apply: true,
offer_code: "HDFC10",
offer_type: ["instant_discount", "cashback"],
discount_amount: 50,
cashback_amount: 50,
ids: []
}]
}
Fields and their definition
|
Field
|
Definition
|
Type
|
Possible Values
|
|---|---|---|---|
offer_applied
| This mentions whether the use has applied or removed an offer
| Boolean
| Row Item
|
final_amount
| This mentions the final amount user needs to pay after offer application
| Double
| Row Item
|
auto_apply
| This mentions whether the offer is auto-apply oe coupon based
| Boolean
| Row Item
|
offer_code
| Offer Code configured on the dashboard
| String
| Row Item
|
offer_type
| Benefit Type configured for the Offer
| String
| Row Item
|
discount_amount
| Discount amount applicable for the selected Offer
| Double
| Row Item
|
cashback_amount
| Cashback amount applicable for the selected offer
| Double
| Row Item
|

