Order Completion Event

order.created.completed

This event is triggered when a subscriber completes the payment for an order and the same is confirmed by our payment gateway provider. An example curl to subscribe to this event:

curl --location 'https://api-prod-new.tagmango.com/integration/webhook' \
--header 'Accept: application/json, text/plain, */*' \
--header 'Accept-Language: en-US,en;q=0.9' \
--header 'Cache-Control: no-cache' \
--header 'Connection: keep-alive' \
--header 'Content-Type: application/json' \
--header 'x-api-key: <Your API Key>' \
--data '{
    "hookUrl": "<your webhook url>",
    "event": "order.created.completed",
    "mango": "<mango to be associated> (optional sends all events if not specified)",
}'

The webhook payload:

{
  "id": "abcd",
  "name": "Subscriber Name",
  "email": "subscriber@email.com",
  "phone": 123456789,
  "orderTime": "2023-11-20T18:30Z",
  "orderId": "abcd",
  "amount": 50,
  "gst": 0,
  "discount": 0,
  "coupon": "",
  "country": "IN",
  "amountPayable": 50,
  "mangoName": "Example Mango",
  "status": "completed",
  "customFields": []
}

Last updated