Webhooks
order_assigned
This event is triggered every time an order is assigned to a driver.
Specific Data for this message
JSON Field | Type | Description |
---|---|---|
order_uuid | string | The UUID of the order |
partners_unique_internal_order_id | string | The order's unique ID on your system. This can be set when creating orders. |
account_uuid | string | The UUID of the store |
agent_uuid | string | The UUID of the driver |
agent_partners_external_identifier | string | The driver's unique ID on your system. This can be set when creating a driver. |
agent_partner_data | hash | The driver's data on your system. |
order_account_partners_external_identifier | string | The store's unique ID on your system. This can be set when setting up a store. |
order_account_business_partners_external_identifier | string | The business's unique ID on your system. This can be set when setting up a business. |
order_custom_fields | hash or null | If you passed through a hash of custom fields to the order creation API (custom_fields ), this will then be passed back to you here. |
published_at | integer, unix timestamp | The time the event occurred |
Example Webhook Payload
{
"data": {
"order_uuid": "6992dc85d681",
"partners_unique_internal_order_id": "ac730930-a545-4a54-8ad9-5f60737d8a1c",
"account_uuid": "73f4c9af9f79",
"agent_uuid": "7183bb9f1a65",
"agent_partners_external_identifier": "webhook-driver-1-partners-external-identifier",
"agent_partner_data": {
"example": 456
},
"order_account_partners_external_identifier": "partners-external-identifier-account",
"order_account_business_partners_external_identifier": "",
"order_custom_fields": {
"example": 123,
"sms_opt_in": true,
"anything_else_that": "was_passed_through_when_creating_an_order"
},
"published_at": 1651157722.2628822
},
"environment": "production",
"event_name": "order_assigned",
"created_at": "2022-04-28T14:55:22.333+00:00",
"event_uuid": "a18a4c70-e1e0-4024-a44f-b189835eb970",
"metadata": {
"sent_at": "2022-04-28T14:55:22.350+00:00",
"delivery_attempt": 1
}
}