Last active
September 22, 2020 11:09
-
-
Save zorem/b2625243f80dff3f3d0c2deae0502d4e to your computer and use it in GitHub Desktop.
With this endpoint you can list all tracking info added to an order. You will need to pass order id and you’ll get respond with array of tracking numbers added to that order,
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
GET /wp-json/wc-ast/v3/orders/<order_id>/shipment-trackings/ | |
curl -X GET https://your-domain.com/wp-json/wc-ast/v3/orders/<order_id>/shipment-trackings | |
-u consumer_key:consumer_secret | |
//JSON response: | |
{ | |
"tracking_id": "feb9bde4475fda92cc9408607b7ecb66", | |
"tracking_provider": "Fedex", | |
"tracking_link": "http://www.fedex.com/Tracking?action=track&tracknumbers=12345678", | |
"tracking_number": "12345678", | |
"date_shipped": "2019-03-08", | |
"_links": { | |
"self": [ | |
{ | |
"href": "https://your-domain.com/wp-json/wc/v1/orders/340/shipment-trackings" | |
} | |
], | |
"collection": [ | |
{ | |
"href": "https://your-domain.com/wp-json/wc/v1/orders/340/shipment-trackings" | |
} | |
], | |
"up": [ | |
{ | |
"href": "https://your-domain.com/wp-json/wc/v1/orders/340" | |
} | |
] | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment