E-Fulfilment Partners
Are you a warehouse partner shipping products for Easyship users? Connecting to Easyship's API can automate many of the manual tasks associated with processing orders and getting them out of the warehouse
Authentication
To connect to the Easyship API to operate on behalf of a customer, you will require their API Key and token in the header of your requests. You will need to make an individual call per client
Generating Pick & Pack Lists
You're able to make a call to the shipment
end point to pull down created orders. You can filter this request using a number of parameters like the platform it was generated on, or a single order number. For this scenario, we'll search for valid orders, after a certain point in time, using the shipment_state
and created_at_from
URL parameters.
The response you receive will contain the data you need to create a pick and pack list:
{
"total_pages": 2,
"current_page": 1,
"shipments": [
{
"created_at": "2016-12-15T08:35:11.938Z",
"updated_at": "2016-12-15T08:35:12.079Z",
"easyship_shipment_id": "ESTEST00000",
"destination_name": "Aloha Chen",
"destination_address_line_1": "300 Park Avenue",
"destination_address_line_2": null,
"destination_city": "New York",
"destination_state": "NY",
"destination_postal_code": "10022",
"destination_phone_number": "+1 234-567-890",
"destination_email_address": "[email protected]",
"platform_order_number": "#1234",
"platform_name": "Amazon",
"total_customs_value": 100,
"total_actual_weight": 1.2,
"total_dimensional_weight": 0.6,
"total_volumetric_weight": 1.2,
"is_insured": false,
"currency": "SGD",
"origin_country": {
"name": "Singapore",
"alpha2": "SG"
},
"destination_country": {
"name": "United States",
"alpha2": "US"
},
"items": [
{
"id": "a918ff21-fe35-4cf0-bf48-a9ff5335d20e",
"description": "Silk dress",
"sku": "test",
"width": 15,
"length": 20,
"height": 10,
"actual_weight": 1.2,
"dimensional_weight": 0.6,
"volumetric_weight": 1.2,
"declared_customs_value": 100,
"declared_currency": "SGD",
"origin_customs_value": 100,
"origin_currency": "SGD",
"category": "fashion"
},
{
"id": "0f921583-26d4-4341-bce7-0995237ffa5c",
"description": "Cotton dress",
"sku": "test2",
"width": 15,
"length": 20,
"height": 10,
"actual_weight": 1.2,
"dimensional_weight": 0.6,
"volumetric_weight": 1.2,
"declared_customs_value": 100,
"declared_currency": "SGD",
"origin_customs_value": 100,
"origin_currency": "SGD",
"category": "fashion"
}
],
"box": {
"name": null,
"length": 20,
"width": 15,
"height": 10
},
"selected_courier": {
"id": "2a17f7aa-51f7-4d36-bca8-e77c164cb52a",
"name": "DHL Express",
"min_delivery_time": 2,
"max_delivery_time": 3,
"shipment_charge": 284.9,
"fuel_surcharge": 32.05125,
"remote_area_surcharge": 0,
"shipment_charge_total": 316.95125,
"warehouse_handling_fee": 0,
"insurance_fee": 0,
"import_tax_charge": 0,
"import_duty_charge": 0,
"ddp_handling_fee": 0,
"total_charge": 316.95,
"is_above_threshold": false,
"effective_incoterms": "DDU",
"estimated_import_tax": 0,
"estimated_import_duty": 0,
"courier_does_pickup": false,
"courier_dropoff_url": "https://www.easyship.com/drop-off/dhl/hk",
"courier_remarks": null,
"payment_recipient": "Easyship"
},
"rates": [
{
"courier_id": "462e4de9-0762-4c71-9cad-d6495ce364fb",
"courier_name": "DHL Express",
"min_delivery_time": 2,
"max_delivery_time": 3,
"value_for_money_rank": 1,
"delivery_time_rank": 1,
"shipment_charge": 68.082,
"fuel_surcharge": 8.51025,
"remote_area_surcharge": null,
"shipment_charge_total": 76.59225,
"warehouse_handling_fee": 0,
"insurance_fee": 0,
"ddp_handling_fee": 0,
"import_tax_charge": 0,
"import_duty_charge": 0,
"total_charge": 76.59,
"is_above_threshold": false,
"effective_incoterms": "DDU",
"estimated_import_tax": 0,
"estimated_import_duty": 0,
"courier_does_pickup": true,
"courier_dropoff_url": null,
"tracking_rating": 3,
"easyship_rating": 4.4
"courier_remarks": null,
"payment_recipient": "Easyship"
}
]
}
]
}
Multiple items are grouped into a single shipment by the platform_order_number
. Within items, you will also receive the SKU (sku
) with any quantities and you'll need to store the easyship_shipment_id
to download or confirm the labels.
With this, you're able to create a pick and pack list before confirming the shipments and buying the labels (if they're not been bought already).
Confirming Shipments & Get Labels
Now that you have your easyship_shipment_id
, you can call the Label endpoint to confirm the shipment and purchase the label.
Retrieving Confirmed Shipments
When you issue
GET
request to theshipment/v1/shipments
resource with aneasyship_shipment_id
that has already been confirmed and had a label purchased, we will also return within the response:
label_state
label_url
tracking_number
tracking_page_url
{
"shipments": [
{
"easyship_shipment_id": "ESTEST00000",
}
]
}
You'll receive a response with the status of the label pending
, generated
, failed
or not generated
.
As the labels and customs documents are generated asynchronously, we will use the callback URL that you provide in your Easyship dashboard or the
company
endpoint, to notify you that they are ready.
The response below contains the shipping label in .pdf format, ready for you to download, print and attach to the packed order.
"message": "Your labels are being generated",
"total_cost": 76,
"available_balance": 924,
"labels": [
{
"labels": {
"easyship_shipment_id": "ESTEST00000",
"label_state": "generated",
"status": "success",
"label_url": "https://goeasyship.s3.amazonaws.com/ESTEST00000_label.pdf",
"tracking_number": '12345',
"tracking_page_url": 'https://www.easyship.com/shipment-tracking/ESHK0040989'
}
]
}
Mark as handed over
If you have multiple couriers making regular pickups at your warehouse, you don't need to request a new pickup. Instead, you can mark an item as directly handed over with the pickup / v1 / direct_handover
endpoint.
This is an important step as it will trigger the start of the tracking events for the order.
{
"easyship_shipment_ids": [
"ESUS3171766"
]
}
As a response, you'll receive a confirmation of the shipments being successfully marked.
{
"direct_handover": {
"easyship_shipment_ids": [
"ESUS3171766"
],
"pickup_state": "completed"
}
}
Updated over 6 years ago