The currently supported event types are as follows:
order.paid
order.expired
order.failed
Please note that duplicate events MAY occur and in some occasions, may arrive out of order. We ask partners to de-dupe these events.
Order event defination:
Name | Type | Description |
---|---|---|
type | string | event type |
payload.id | string | order id |
payload.uid | string | optional custom order unique identifier, initialized when creating this order |
payload.user_id | string | optional user id who pays this order, initialized after user paid this order |
payload.wallet_id | string | optional wallet id from which to pay this order, initialized after user paid this order |
payload.amount.currency | string | currency code |
payload.amount.amount | string | currency amount, big interger in string representation |
payload.failed_message | string | optional failed reason for this order, initialized when the order failed |
payload.metadata | object | optional metadata for this order, initialized when creating this order |
payload.created_at | string | created time |
payload.updated_at | string | updated time |
Order Event samples:
{
"type": "order.paid",
"payload": {
"id": "92841860-481e-4ba4-9be2-12b1e497facf",
"uid": "order_1234",
"user_id": "6872198",
"wallet_id": "11b9ca57-0559-403a-bf8e-7bd1a31aff46",
"amount": {
"currency": "USDT",
"amount": "10000"
},
"metadata": {
"custom_key": "custom_value"
},
"created_at": "2024-02-14T12:00:00Z",
"updated_at": "2024-02-14T12:01:00Z"
}
}
{
"type": "order.expired",
"payload": {
"id": "92841860-481e-4ba4-9be2-12b1e497facf",
"uid": "order_1234",
"amount": {
"currency": "USDT",
"amount": "10000"
},
"metadata": {
"custom_key": "custom_value"
},
"created_at": "2024-02-14T12:00:00Z",
"updated_at": "2024-02-14T12:01:00Z"
}
}
{
"type": "order.failed",
"payload": {
"id": "92841860-481e-4ba4-9be2-12b1e497facf",
"uid": "order_1234",
"amount": {
"currency": "USDT",
"amount": "10000"
},
"metadata": {
"custom_key": "custom_value"
},
"failed_message": "insufficient balance",
"created_at": "2024-02-14T12:00:00Z",
"updated_at": "2024-02-14T12:01:00Z"
}
}