Status Change Notification Webhooks
This section explains how to configure webhooks in our system, detailing the structure and format of the notification data we send.
Webhook Structure and Data
We send webhook notifications as an HTTP request to a URL that you provide. This URL acts as the receiving endpoint for your system. The data we send in these notifications is called the payload. We can customize this payload to include any additional information you may need.
Customizable Notifications
You have control over which events trigger a notification. You can specify the exact delivery statuses you want to be notified about. This ensures you only receive relevant updates.
Secure Communication
To ensure secure communication, you can include custom headers in the webhook requests. These headers can be used to configure various dynamic authentication mechanisms, such as:
- Basic Auth
- JWT (JSON Web Tokens)
- OAuth2
- Gcloud Auth
By using these methods, you can ensure that only authorized systems receive and process your webhook notifications.
Once configured, our webhook service will automatically send these updates, keeping your system constantly synchronized with events from our service.
Example Flow
- The client provides their URL (endpoint).
- Our system detects a relevant status change.
- A
POSTrequest is made to the client's endpoint with a JSON-structuredpayload.
Payload
The request content will have the following format:
{
"status_id": 0,
"identifier": 0,
"summary_id": 0,
"status_date": "2019-08-24",
"status_name": "string",
"carrier_code": "string",
"carrier_name": "string",
"imported_id": "string",
"tracking_url": "string",
"dead_line_date": "2019-08-24",
"tracking_number": "string",
"status_information": "string"
}
Payload Data
Here is the meaning of each field included in the payload, as well as the expected data type for each one.
| Field | Description | Data Type |
|---|---|---|
| status_id | Enviame Status ID | integer |
| identifier | Delivery ID | integer |
| summary_id | Manifest ID, generated by Enviame | integer |
| status_date | Delivery status change date | string <date> |
| status_name | Name of the status the delivery is in | string <date> |
| carrier_code | Carrier code | string |
| carrier_name | Carrier name | string |
| imported_id | Delivery number or reference used when creating the delivery | string |
| tracking_url | Delivery URL on the Enviame platform | string |
| dead_line_date | Commitment date | string <date> |
| tracking_number | Tracking number | string |
| status_information | Complementary information about the delivery status | string |
Delivery Statuses
| status_id | status_name | status_code |
|---|---|---|
| 1 | Created | PENDING |
| 2 | Processing | PENDING |
| 3 | Sent to Carrier | PENDING |
| 4 | Rejected by Courier | PENDING |
| 5 | Ready for dispatch | CREATED |
| 6 | At origin facility | IN_ORIGIN |
| 7 | In transit | IN_TRANSIT |
| 8 | At destination facility | IN_DESTINATION |
| 9 | Out for delivery | DISPATCHED |
| 10 | Delivered | DELIVERED_DOM |
| 11 | Available for pickup | DELIVERED_PUDO |
| 12 | Deleted | DELETED |
| 13 | Picked up by customer | PICKED_UP |
| 14 | Return | RETURNED |
| 15 | Do not translate | JUNK |
| 16 | Picked up by courier | PICK_UP_CARRIER |
| 17 | Address not found | ADDRESS_NOT_FOUND |
| 18 | Rejected by recipient | REJECTED_CLIENT |
| 19 | No one home | NO_ONE_HOME |
| 20 | Damaged shipment | DAMAGED_SHIPMENT |
| 22 | Lost shipment | LOST_SHIPMENT |
| 23 | Pending | AWAITING |
| 24 | Lost | LOST |
| 25 | Transport without access | NO_ACCESS |
| 26 | Ready for dispatch - Printed | CREATED |
| 27 | Delivery could not be completed | NOT_DELIVERED |
| 29 | Expired | EXPIRED |
| 30 | Return delivered | RETURN_DELIVERED |
| 31 | Return picked up by carrier | RETURN_pickup |
| 32 | Return not picked up by carrier | RETURN_notpickup |
| 33 | Return out for delivery | return_dispatched |
| 34 | Resolved and sending to recipient | SOLUTION_GENERATED |
| 35 | Unknown recipient | UNKNOWN_CLIENT |
| 36 | Management in progress | PROCESS_RUNNING |
| 37 | Pending - requires solution | PENDING_SOLUTION_NEEDED |
| 38 | Presumably lost | ALLEGEDLY_LOST_SHIPMENT |
| 39 | Recipient changed address | CLIENT_CHANGED_ADDRESS |
| 40 | Shipment detained | SHIPMENT_DETAINED |
| 41 | Failed delivery | DELIVERY_FAILED |
| 43 | Return canceled | RETURN_CANCELED |
| 44 | Return to sender | RETURNED_TO_SHIPPER |
| 45 | Admitted at branch/agency | RECEIVED_AT_PU_POINT |
| 46 | Incorrect address | INCORRECT_ADDRESS |
| 47 | Assigned | CREATED |
| 48 | Lost - No movement | LOST_NO_MOVEMENT |
| 49 | Voided | CANCELED |
| 50 | Partial delivery | PARTIALLY_DELIVERED |
| 51 | Service breach | BREACH_OF_SERVICE |
| 52 | Out of coverage | NO_COVERAGE |
| 53 | Not picked up - Seller issue | FAILED_PICKUP_SELLER_ISSUE |
| 54 | About to expire | SOON_TO_EXPIRE |
| 55 | Initiate return | RETURN_START |
| 56 | Expired in store | EXPIRED_IN_STORE |
| 57 | Delivered to carrier | DELIVERED_TO_CARRIER |
| 62 | Ready for dispatch | CREATED |
| 63 | Ready for dispatch - Printed | CREATED |
| 64 | Force majeure delay | DELAY_DUE_TO_FORCE_MAJEURE |
| 65 | Package ready for pickup | CREATED |
| 66 | To be delivered to fulfillment | BE_DELIVERED_WMS |
| 67 | Delivered to fulfillment | DELIVERED_WMS |
| 68 | Assigned to courier | CREATED |
| 71 | Partial return | PARTIALLY_RETURNED |
| 75 | Manifest confirmed | ENVIAME_CLOSED_SUMMARY |
| 76 | Recipient refuses to pay | CLIENT_DONT_PAY |
| 77 | Blocked | BLOCKED |
| 79 | Ready for auction | PENDING |
| 80 | Auctioned | PENDING |
| 81 | Not picked up - Seller absent or closed | FAILED_PICKUP_SELLER_ISSUE |
| 82 | Damaged packaging | DAMAGED_PACKAGING |
| 83 | Shipment seized | SHIPMENT_SEIZED |
| 84 | Lost - Non-compensable | LOST_SHIPMENT_NOT_COMPENSABLE |
| 85 | Shipment audited | SHIPPING_AUDITED |
| 86 | Order prepared by fulfillment | Prepared_by_WMS |
| 87 | Rejected by sender | REJECTED_SELLER |
| 88 | Operator management delay | DELAY_COURIER |
| 90 | Delivered - Pending confirmation | DELIVERED_PENDING_CONFIRMATION |
| 91 | Courier at pickup point | AT_PICKUP_POINT |
| 92 | Wrong package size | WRONG_SIZE |
| 93 | Reassigning courier | LOOK_NEW_DELIVERY |
| 94 | Rejected by recipient - Pending confirmation | REJECTED_CLIENT_PENDING |
| 95 | Canceled by seller | CANCELED_BY_SELLER |
| 96 | Return aborted | ABORTED_RETURN |
| 97 | Failed delivery (direct) | DELIVERY_FAILED |
| 98 | Delivery could not be returned | NOT_RETURNED |
| 99 | Rejected by rule condition | REJECTED BY RULE |
| 100 | Canceled by operator - No pickup | CANCELED_BY_COURIER |
| 101 | Available for pickup at Copec point | DELIVERED_PUDO_CENCO |
| 102 | Admitted at point | RECIEVED_AT_PU_POINT_CENCO |
| 103 | Canceled by customer | CANCELED_CLIENT |
| 104 | Canceled - Delay | CANCELED_DELAY |
| 105 | Product rejected by customer (direct) | PRODUCT_REJECTED_BY_CUSTOMER |
| 106 | First failed attempt - Retry | FIRST_FAILED_ATTEMPT |
| 107 | Second failed attempt - Cancellation (direct) | SECOND_FAILED_ATTEMPT |
| 109 | Packaging repair | Arreglo de embalaje |
| 111 | Documentation uploaded successfully | DOCUMENT_ACCEPTED |
| 112 | Documentation upload error | DOCUMENT_REJECTED |
| 113 | Exchange completed | EXCHANGE_OK |
| 114 | Created in FLEX | Created_Flex |
| 115 | Return picked up at Copec point | Return_Copec |