DHL integration for package tracking
General overview integration
We need to integrate to DHL using only one specific feature of theirs and it is the Tracking service.
We should be using the TrackingRequestKnown xsd.
Flows to be used
DHL Flows:
- Tracking Request Known
Authentication - specifics
There is no separate service for authentication you need Account Number and Password added to the ServiceHeader Element.
Account Number: 610344059
password: still waiting
Tracking request - specification
In the request we need to specify the AWBNumber which will be stored in our database in the field shipping_tracking_url.
Based on what we receive from DHL as response we need to process the statuses.
In the responses we will be getting there is going to be an element ServiceEvent Element
It contains field EventCode and it can have the following values described in the document below:
The values we are interested in are:
Code | Description |
---|---|
OK | Delivery |
ND | Not delivered |
Next step of the process will be to update this status in the orders.lazada table per order.
Schedule
This cron should be running once every 24 hours preferably at night.
It should be checking for orders with status dispatched and order_created_time is older then 2 days compared with current date.
Other - specifics
XSD schema below:
Outstanding questions