Validates shipment details and returns all available rates.
Stallion Express API (3.0)
Access to the sandbox environment can be provided upon request. (Not all rates are available in the Sandbox environment). API token can be found under "Account Settings > API Token".
Shipment details
Limit the results to specific postage types
- Mock serverhttps://stallionexpress.redocly.app/_mock/stallionexpress-v3/rates
- Production server (uses live data)https://ship.stallionexpress.ca/api/v3/rates
- Sandbox server (uses test data)https://sandbox.stallionexpress.ca/api/v3/rates
- curl
- JavaScript
- Node.js
- Python
- Java
- C#
- PHP
- Go
- Ruby
- R
- Payload
curl -i -X POST \
https://stallionexpress.redocly.app/_mock/stallionexpress-v3/rates \
-H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
-H 'Content-Type: application/json' \
-d '{
"name": "Pramod Thomson",
"address1": "30 Clearview Dr",
"address2": "Lot 2",
"city": "Rock Springs",
"province_code": "WY",
"postal_code": "82901",
"country_code": "US",
"email": "test@stallionexpress.ca",
"phone": 11231231234,
"weight_unit": "lbs",
"weight": 0.6,
"length": 9,
"width": 12,
"height": 1,
"size_unit": "cm",
"package_contents": "Two pair of socks",
"value": 10,
"currency": "CAD",
"package_type": "Parcel",
"postage_types": [],
"signature_confirmation": true,
"insured": true,
"region": null
}'{ "success": true, "rates": [ { … } ] }
- Mock serverhttps://stallionexpress.redocly.app/_mock/stallionexpress-v3/shipments
- Production server (uses live data)https://ship.stallionexpress.ca/api/v3/shipments
- Sandbox server (uses test data)https://sandbox.stallionexpress.ca/api/v3/shipments
- curl
- JavaScript
- Node.js
- Python
- Java
- C#
- PHP
- Go
- Ruby
- R
- Payload
curl -i -X GET \
'https://stallionexpress.redocly.app/_mock/stallionexpress-v3/shipments?from_date=string&to_date=string&ship_code=string&to_name=string&tracking_code=string&order_id=string&batch_id=string&closeout_id=string&status=unpaid&limit=0&page=0' \
-H 'Authorization: Bearer <YOUR_TOKEN_HERE>'{ "data": [ null ], "links": null, "meta": null }
The shipment object that needs to be created. Note that size fields are required for any shipments with the package type of Parcel.
Default pdf. Set the format of the returned label.
Default false. Set to true to create a Stallion FBA label.
Set to true to apply Stallion Protection for tracked shipments only.
Optional field. Can be used to explicitly set customs declaration for international shipments. Leave empty if unsure.
- Mock serverhttps://stallionexpress.redocly.app/_mock/stallionexpress-v3/shipments
- Production server (uses live data)https://ship.stallionexpress.ca/api/v3/shipments
- Sandbox server (uses test data)https://sandbox.stallionexpress.ca/api/v3/shipments
- curl
- JavaScript
- Node.js
- Python
- Java
- C#
- PHP
- Go
- Ruby
- R
- Payload
curl -i -X POST \
https://stallionexpress.redocly.app/_mock/stallionexpress-v3/shipments \
-H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
-H 'Content-Type: application/json' \
-d '{
"name": "Pramod Thomson",
"address1": "30 Clearview Dr",
"address2": "Lot 2",
"city": "Rock Springs",
"province_code": "WY",
"postal_code": "82901",
"country_code": "US",
"email": "test@stallionexpress.ca",
"phone": 11231231234,
"order_id": "1234-1233",
"weight_unit": "lbs",
"weight": 0.6,
"length": 9,
"width": 12,
"height": 1,
"size_unit": "cm",
"package_contents": "Two pair of socks",
"value": 10,
"currency": "CAD",
"package_type": "Parcel",
"signature_confirmation": false,
"postage_type": "USPS First Class Mail",
"label_format": "pdf",
"is_fba": false,
"insured": true,
"customs_lines": [
null
],
"region": null
}'{ "success": true, "label": "base64_label", "tracking_code": "9400111969000940000011", "message": "Shipment successfully completed", "shipment": null, "rate": { "postage_type": "USPS First Class Mail", "package_type": "Parcel", "trackable": true, "base_rate": 10, "add_ons": [ … ], "rate": 10, "tax": 0, "total": 0, "currency": "CAD", "delivery_days": "2" } }
Send one or all of: ship_code, tracking_code, and order_id as a post parameter to create the return label for a previous shipment.
- Mock serverhttps://stallionexpress.redocly.app/_mock/stallionexpress-v3/shipments/return-label
- Production server (uses live data)https://ship.stallionexpress.ca/api/v3/shipments/return-label
- Sandbox server (uses test data)https://sandbox.stallionexpress.ca/api/v3/shipments/return-label
- curl
- JavaScript
- Node.js
- Python
- Java
- C#
- PHP
- Go
- Ruby
- R
- Payload
curl -i -X POST \
https://stallionexpress.redocly.app/_mock/stallionexpress-v3/shipments/return-label \
-H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
-H 'Content-Type: application/json' \
-d '{
"ship_code": "210907WY78",
"tracking_code": "940002312332",
"order_id": "40011"
}'{ "success": true, "label": "base64_label", "tracking_code": "9400111969000940000011", "message": "Shipment successfully completed", "shipment": null, "rate": { "postage_type": "USPS First Class Mail", "package_type": "Parcel", "trackable": true, "base_rate": 10, "add_ons": [ … ], "rate": 10, "tax": 0, "total": 0, "currency": "CAD", "delivery_days": "2" } }
- Mock serverhttps://stallionexpress.redocly.app/_mock/stallionexpress-v3/track
- Production server (uses live data)https://ship.stallionexpress.ca/api/v3/track
- Sandbox server (uses test data)https://sandbox.stallionexpress.ca/api/v3/track
- curl
- JavaScript
- Node.js
- Python
- Java
- C#
- PHP
- Go
- Ruby
- R
- Payload
curl -i -X GET \
'https://stallionexpress.redocly.app/_mock/stallionexpress-v3/track?ship_code=string&tracking_code=string&order_id=string' \
-H 'Authorization: Bearer <YOUR_TOKEN_HERE>'{ "success": true, "status": "Postage Expired", "events": [ null ], "details": { "ship_code": 2012121234, "destination": "Toronto ON, CA", "tracking": "123123123123123123", "url": "https://carrier.com/track/9400111969000940000011", "carrier_phone": "12312341234" } }
- Mock serverhttps://stallionexpress.redocly.app/_mock/stallionexpress-v3/shipments/{ship_code}
- Production server (uses live data)https://ship.stallionexpress.ca/api/v3/shipments/{ship_code}
- Sandbox server (uses test data)https://sandbox.stallionexpress.ca/api/v3/shipments/{ship_code}
- curl
- JavaScript
- Node.js
- Python
- Java
- C#
- PHP
- Go
- Ruby
- R
- Payload
curl -i -X GET \
'https://stallionexpress.redocly.app/_mock/stallionexpress-v3/shipments/{ship_code}' \
-H 'Authorization: Bearer <YOUR_TOKEN_HERE>'{ "success": true, "label": "base64_label", "tracking_code": "9400111969000940000011", "message": "Shipment successfully completed", "shipment": null, "rate": { "postage_type": "USPS First Class Mail", "package_type": "Parcel", "trackable": true, "base_rate": 10, "add_ons": [ … ], "rate": 10, "tax": 0, "total": 0, "currency": "CAD", "delivery_days": "2" } }
- Mock serverhttps://stallionexpress.redocly.app/_mock/stallionexpress-v3/shipments/{ship_code}/void
- Production server (uses live data)https://ship.stallionexpress.ca/api/v3/shipments/{ship_code}/void
- Sandbox server (uses test data)https://sandbox.stallionexpress.ca/api/v3/shipments/{ship_code}/void
- curl
- JavaScript
- Node.js
- Python
- Java
- C#
- PHP
- Go
- Ruby
- R
- Payload
curl -i -X GET \
'https://stallionexpress.redocly.app/_mock/stallionexpress-v3/shipments/{ship_code}/void' \
-H 'Authorization: Bearer <YOUR_TOKEN_HERE>'{ "success": true, "message": false }