# Shipping API For Ecommerce Developers | Easyship Documentation ## Guides - [Sandbox](https://developers.easyship.com/docs/sandbox.md): The sandbox environment allows you to test all of the APIs. The data, rates and labels are for illustrative purposes only. - [How to connect Easyship users to your platform](https://developers.easyship.com/docs/how-to-authorize-easyship-user.md): This guide is for platforms as partner apps on Easyship to connect existing Easyship users or new signed up users. - [How to Automate your Shipments](https://developers.easyship.com/docs/how-to-automate-your-shipments.md) - [How to Create a Return Shipment](https://developers.easyship.com/docs/how-to-create-a-return-shipment.md) - [How to Display Rates at Checkout](https://developers.easyship.com/docs/how-to-display-rates-at-checkout.md) - [How to Track a Shipment](https://developers.easyship.com/docs/how-to-track-a-shipment.md) - [How to Validate Addresses](https://developers.easyship.com/docs/how-to-validate-addresses.md) - [HS Codes, Address Validation and T&Ds Features](https://developers.easyship.com/docs/hs-codes-address-validation-and-tds-features.md) - [Overview Flow Guide](https://developers.easyship.com/docs/overview-flow-guide.md) - [Easyship - Shipping MCP](https://developers.easyship.com/docs/easyship-mcp-server.md) ## API Reference - [Changelog](https://developers.easyship.com/reference/changelog.md) - [Errors](https://developers.easyship.com/reference/errors.md) - [Overview](https://developers.easyship.com/reference/introduction.md) - [Migrate from v1 to v2024](https://developers.easyship.com/reference/migrate-from-v1-to-v2024.md): This guide highlights changes required for migrating APIs from v1 (legacy version) to v2024-09 (latest version) - [Migrate from v2023 to v2024](https://developers.easyship.com/reference/migrate-from-v2023-to-v2024.md) - [Rate Limit](https://developers.easyship.com/reference/rate-limit.md) - [Register an App](https://developers.easyship.com/reference/register-an-app.md) - [Scopes](https://developers.easyship.com/reference/scopes.md) - [Retrieve info for the Access Token](https://developers.easyship.com/reference/oauth2_token_info.md): Retrieve an OAuth 2 Access Token information. - [Introspect an Access Token](https://developers.easyship.com/reference/oauth2_token_introspect.md): Introspect an OAuth 2 Access Token using another Access Token. - [Revoke an Access Token](https://developers.easyship.com/reference/oauth2_token_revoke.md): Revoke an OAuth 2 Access Token using your Client Credentials. - [Retrieve an Access Token](https://developers.easyship.com/reference/oauth2_token.md): Retrieve an OAuth 2 Access Token. There are two ways of accessing the child companies: 1. **Client Credentials Grant** with a `enterprise.child_company::access` scope and a custom header `X_EASYSHIP_COMPANY_ID` in each request to our Public API. 2. A custom **Delegated Account Grant**, that will generate access and refresh tokens associated with a specific child company defined in the `easyship_company_id`. - [Create a Company](https://developers.easyship.com/reference/companies_create.md): Create a new company in specific organization. Required authorization scope: `enterprise.company:write` - [Delete a Company](https://developers.easyship.com/reference/companies_delete.md): Delete a company. Required authorization scope: `enterprise.company:write` - [List all Companies](https://developers.easyship.com/reference/companies_index.md): List all companies which belong to organisation. Required authorization scope: `enterprise.company:read` - [Update a Company](https://developers.easyship.com/reference/companies_update.md): Update a company. Required authorization scope: `enterprise.company:write` - [Create a Company Onboarding](https://developers.easyship.com/reference/company_onboardings_create.md): Create a Company Onboarding. Required authorization scope: `enterprise.company:write` - [Get a Company Onboarding](https://developers.easyship.com/reference/company_onboardings_show.md): Retrieve a Company Onboarding. Required authorization scope: `enterprise.company:read` - [Downgrade a Subscription](https://developers.easyship.com/reference/downgrade_subscription_create.md): Switch a specific child company to the free-tier subscription plan. The free-tier plan takes effect upon expiration of the current plan period. Required authorization scope: `enterprise.company:write` - [List all Companies of the Organization](https://developers.easyship.com/reference/organization_companies_index.md): Retrieve a list of companies from a specific organization. Required authorization scope: `enterprise.company:read` - [List all Organizations](https://developers.easyship.com/reference/organizations_index.md): Retrieve a list of organizations (groups of child companies) that are a part of your group. Required authorization scope: `enterprise.organization:read` - [Create a Shipping Rule](https://developers.easyship.com/reference/organizations_shipping_rules_create.md): Create a shipping rule for a specific organization. Required authorization scope: `enterprise.shipping_rule:write` - [List all Shipping Rules](https://developers.easyship.com/reference/organizations_shipping_rules_index.md): Retrieve a list of an organization's shipping rules. Required authorization scope: `enterprise.shipping_rule:read` - [Activate a Shipping Rule](https://developers.easyship.com/reference/shipping_rule_activate-1.md): Activate specific shipping rule. Required authorization scope: `enterprise.shipping_rule:write` - [Deactivate a Shipping Rule](https://developers.easyship.com/reference/shipping_rule_deactivate-1.md): Deactivate specific shipping rule. Required authorization scope: `enterprise.shipping_rule:write` - [List all Platform Names](https://developers.easyship.com/reference/shipping_rule_platforms_index-1.md): Retrieve a list of available platform names for shipping rules. Required authorization scope: `enterprise.shipping_rule:read` - [Delete a Shipping Rule](https://developers.easyship.com/reference/shipping_rules_delete-1.md): Delete a shipping rule. Required authorization scope: `enterprise.shipping_rule:write` The path does not include the `organization_id` path parameter used for 'List all Shipping Rules' and 'Create a Shipping Rule' actions. - [Get a Shipping Rule](https://developers.easyship.com/reference/shipping_rules_show-1.md): Retrieve a shipping rule. Required authorization scope: `enterprise.shipping_rule:read` The path does not include the `organization_id` path parameter used for 'List all Shipping Rules' and 'Create a Shipping Rule' actions. - [Update a Shipping Rule](https://developers.easyship.com/reference/shipping_rules_update-1.md): Update a shipping rule. Required authorization scope: `enterprise.shipping_rule:write` The path does not include the `organization_id` path parameter used for 'List all Shipping Rules' and 'Create a Shipping Rule' actions. - [Create Action for a Shipping Rule](https://developers.easyship.com/reference/shipping_rule_action_create-1.md): Create an action for a shipping rule. Required authorization scope: `enterprise.shipping_rule:write` - [Delete Action of a Shipping Rule](https://developers.easyship.com/reference/shipping_rule_action_delete-1.md): Delete shipping rule action. Required authorization scope: `enterprise.shipping_rule:write` - [List all Actions for a Shipping Rule](https://developers.easyship.com/reference/shipping_rule_action_index-1.md): List actions for a shipping rule. Required authorization scope: `enterprise.shipping_rule:read` - [Update Action of a Shipping Rule](https://developers.easyship.com/reference/shipping_rule_action_update-1.md): Update shipping rule action. Required authorization scope: `enterprise.shipping_rule:write` - [Create Condition for a Shipping Rule](https://developers.easyship.com/reference/shipping_rule_condition_create-1.md): Create condition for a shipping rule. Required authorization scope: `enterprise.shipping_rule:write` - [Delete Condition of a Shipping Rule](https://developers.easyship.com/reference/shipping_rule_condition_delete-1.md): Delete shipping rule condition. Required authorization scope: `enterprise.shipping_rule:write` - [List all Conditions for a Shipping Rule](https://developers.easyship.com/reference/shipping_rule_condition_index-1.md): List conditions of a shipping rule. Required authorization scope: `enterprise.shipping_rule:read` - [Update Condition of the Shipping Rule](https://developers.easyship.com/reference/shipping_rule_condition_update-1.md): Update shipping rule condition. Required authorization scope: `enterprise.shipping_rule:write` - [Activate a Webhook](https://developers.easyship.com/reference/organizations_webhooks_activate.md): Activates a single webhook for your organization. Required authorization scope: `enterprise.webhook:write` - [Create a Webhook](https://developers.easyship.com/reference/organizations_webhooks_create.md): Create a single webhook for specific organization. Required authorization scope: `enterprise.webhook:write` - [Deactivate a Webhook](https://developers.easyship.com/reference/organizations_webhooks_deactivate.md): Deactivates a single webhook for your organization. Required authorization scope: `enterprise.webhook:write` - [Delete a Webhook](https://developers.easyship.com/reference/organizations_webhooks_delete.md): Delete a single webhook from your organization. Required authorization scope: `enterprise.webhook:write` - [List all Webhooks](https://developers.easyship.com/reference/organizations_webhooks_index.md): List all webhooks which belong to specific organisation. Required authorization scope: `enterprise.webhook:read` - [Get a Webhook](https://developers.easyship.com/reference/organizations_webhooks_show.md): Retrieve details of a specific webhook in the organization. Required authorization scope: `enterprise.webhook:read` - [Test a Webhook](https://developers.easyship.com/reference/organizations_webhooks_test.md): Test a single webhook in the organization. (The company ID of the organization owner will be included in the `X-EASYSHIP-COMPANY-ID` header.) Required authorization scope: `enterprise.webhook:write` - [Update a Webhook](https://developers.easyship.com/reference/organizations_webhooks_update.md): Update a single webhook in the organization. Required authorization scope: `enterprise.webhook:write` - [Authorize user on Easyship](https://developers.easyship.com/reference/oauth2_authorize.md): Redirect a user for authentication on Easyship. The endpoint is part of [OAuth 2.0 Authorization Code](https://developers.easyship.com/docs/how-to-authorize-easyship-user) flow. > 🚧 Warning > > This endpoint uses **auth.easyship.com** domain. The full URL, without query params, is `https://auth.easyship.com/oauth2/authorize`. > *This docs platform does not fully support OpenAPI and uses/displays the global URL instead of the correct one.* After successful authentication, the user will be redirected back to `redirect_uri` with a `code` (and `state`) parameter in the query string. The `code` can then be exchanged for an access token using the [OAuth2 Token endpoint](https://developers.easyship.com/reference/oauth2_token-1) with `AUTHORIZATION_CODE` request body. - [Retrieve info for the Access Token](https://developers.easyship.com/reference/oauth2_token_info-1.md): Retrieve an OAuth 2 Access Token information. - [Introspect an Access Token](https://developers.easyship.com/reference/oauth2_token_introspect-1.md): Introspect an OAuth 2 Access Token using another Access Token. - [Revoke an Access Token](https://developers.easyship.com/reference/oauth2_token_revoke-1.md): Revoke an OAuth 2 Access Token using your Client Credentials. - [Create an Access Token](https://developers.easyship.com/reference/oauth2_token-1.md): Retrieve an OAuth 2 Access Token. The endpoint is part of [OAuth 2.0 Authorization Code](https://developers.easyship.com/docs/how-to-authorize-easyship-user) flow. Refresh tokens are for one-time use only. A new refresh token is always issued with a new access token. - [Information about the Account](https://developers.easyship.com/reference/account_show.md): Retrieve information about current account Properties below would display only when the access token includes the corresponding scopes. | Property | Required API Scope | | -------- | ------------------ | | `billing_address` | `public.address:read` | | `credit` | `public.credit:read` | | `payment_sources` | `public.payment_source:read` | - [Create an App Access](https://developers.easyship.com/reference/app_access_create.md): Create a temporary app access redirect token Required authorization scope: `public.app_access:write` - [Activate Assets](https://developers.easyship.com/reference/asset_activate_create.md): Activate specific uploaded asset and define other assets of the same type as inactive. Required authorization scope: `public.asset:write` - [Deactivate Assets](https://developers.easyship.com/reference/asset_deactivate_create.md): Deactivate specific uploaded asset. Required authorization scope: `public.asset:write` - [Create an Asset](https://developers.easyship.com/reference/assets_create.md): Create an asset. > You can store up to five assets for each type. > Allowed file types: png or jpeg. Required authorization scope: `public.asset:write` - [Delete an Asset](https://developers.easyship.com/reference/assets_delete.md): Delete an asset. Required authorization scope: `public.asset:write` - [List all Assets](https://developers.easyship.com/reference/assets_index.md): Retrieve a list of assets. Required authorization scope: `public.asset:read` - [Update an Asset](https://developers.easyship.com/reference/assets_update.md): Update an asset. Required authorization scope: `public.asset:write` - [Create a Redirect](https://developers.easyship.com/reference/redirects_create.md): Create a redirect to the Easyship Dashboard. Required authorization scope: `public.redirect:write` - [List Account Settings](https://developers.easyship.com/reference/settings_index.md): Retrieve account settings. Required authorization scope: `public.setting:read` - [Update Multiple Account Settings](https://developers.easyship.com/reference/settings_update.md): Update multiple account settings. Required authorization scope: `public.setting:write` - [Activate an Address](https://developers.easyship.com/reference/address_activate_create.md): Activate specific address Required authorization scope: `public.address:write` - [Deactivate an Address](https://developers.easyship.com/reference/address_deactivate_create.md): Deactivate specific address. If the address is default for the company, the first active address will be set as default. Required authorization scope: `public.address:write` - [Create an Address](https://developers.easyship.com/reference/addresses_create.md): Create a new address. Required authorization scope: `public.address:write` - [List all Addresses](https://developers.easyship.com/reference/addresses_index.md): Retrieve a list of all addresses ordered by date of creation. Required authorization scope: `public.address:read` - [Update an Address](https://developers.easyship.com/reference/addresses_update.md): Update an address in your account. Required authorization scope: `public.address:write` - [Validate a single domestic (US) address](https://developers.easyship.com/reference/addresses_validation_domestic.md): Create a domestic address validation for US addresses. This endpoint is specifically for US addresses. The `country_alpha2` parameter is optional and will be ignored if provided. Required authorization scope: `public.address_validation_domestic:write` > This API requires an updated contract with Easyship. Get in touch with your account manager or Easyship Support Team. > **Note:** Calls to this endpoint count towards your API usage allowance. You can monitor your current usage in the [Subscription section](https://app.easyship.com/account/subscription) of your account. - [Validate a single address](https://developers.easyship.com/reference/addresses_validation.md): Create an address validation. Required authorization scope: - `public.address_validation:write` for international addresses. - `public.address_validation_domestic:write` for US addresses. See the [Domestic Address Validation](https://developers.easyship.com/2024-09/addresses/validations_domestic) endpoint for more details. > This API requires an updated contract with Easyship. Get in touch with your account manager or Easyship Support Team. > **Note:** Calls to this endpoint count towards your API usage allowance. You can monitor your current usage in the [Subscription section](https://app.easyship.com/account/subscription) of your account. - [List Analytics Sale Channels Data](https://developers.easyship.com/reference/analytics_sale_channels_index.md): Retrieve sales analytics. Required authorization scope: `public.analytics:read` - [List Shipment Analytics within a Date Range](https://developers.easyship.com/reference/analytics_shipment_shipped_index.md): Retrieve data on whether the company has made any shipments within specified period. Required authorization scope: `public.analytics:read` - [List Analytics Shipment Status Data](https://developers.easyship.com/reference/analytics_shipment_status_index.md): Retrieve shipment status. Possible statuses: - Label Pending - Label Rejected - Label Ready - Pickup/Drop-off in Progress - In Transit to Customer - Failed Delivery Attempt - Exception Required authorization scope: `public.analytics:read` - [List Analytics Shipments Data](https://developers.easyship.com/reference/analytics_shipments_index.md): Retrieve analytics shipments data. Required authorization scope: `public.analytics:read` - [List Analytics Top Couriers Data](https://developers.easyship.com/reference/analytics_top_couriers_index.md): Retrieve analytics top couriers data. Required authorization scope: `public.analytics:read` - [List Analytics Top Shipments Destinations](https://developers.easyship.com/reference/analytics_top_shipments_destinations_index.md): Retrieve a company top shipments destinations country. Required authorization scope: `public.analytics:read` - [Get Auto Recharge Credit Settings](https://developers.easyship.com/reference/credit_auto_recharge_show.md): Show the auto recharge settings for the company. Required authorization scope: `public.payment:read` - [Update Auto Recharge Credit Settings](https://developers.easyship.com/reference/credit_auto_recharge_update.md): Update the settings for auto recharging your credit when your account balance falls below the threshold specified through this endpoint. This endpoint is in beta (subject to change). Please get in touch with customer support to enable it. Required authorization scope: `public.payment:write` - [Create a Batch of Addresses](https://developers.easyship.com/reference/batch_addresses_create.md): Create a batch of addresses. Required authorization scopes: `public.batch:write`, `public.address:write` - [List all Batch Items](https://developers.easyship.com/reference/batch_items_index.md): Retrieve a list of all batches ordered by date of creation. Required authorization scope: `public.batch:read` - [Create a Batch of Labels](https://developers.easyship.com/reference/batch_labels_create.md): Create a batch of labels. Required authorization scopes: `public.batch:write`, `public.label:write` Labels confirm a shipment created with the Shipment API. Calling **Batch Labels** will confirm shipments with selected courier service and begin generating the label and shipping documents if your account balance is sufficient. > You can enter a `courier_service_id` to assign a specific courier service in case your shipment has no assigned courier yet, or you need to overwrite the one suggested by default. Your shipment will be confirmed. If there is no assigned courier service and you leave the `courier_service_id` field blank, we will automatically assign the best value for money courier to your shipment. ## Asynchronous response The label and shipping documents will be generated asynchronously. If you specified a `Callback URL` through the Easyship dashboard, this URL will be called when the documents are ready. Whilst these documents are being generated, the `label_state` will be set to `pending`. The possible states are `not_created`, `pending`, `failed` and `generated`. - [Create a Batch of Shipments](https://developers.easyship.com/reference/batch_shipments_create.md): Create a batch of shipments and schedule it for processing. Required authorization scopes: `public.batch:write`, `public.shipment:write` and `public.label:write` if a label(s) will be created during the batch processing. - [List all Batches](https://developers.easyship.com/reference/batches_index.md): Retrieve a list of all batches ordered by date of creation. Required authorization scope: `public.batch:read` - [Get a Batch](https://developers.easyship.com/reference/batches_show.md): Retrieve a batch by its ID. Required authorization scope: `public.batch:read` - [Download Billing Document](https://developers.easyship.com/reference/billing_documents_download.md): Download the Billing Document in PDF format. Required authorization scope: `public.billing_document:read` - [List all Billing Documents](https://developers.easyship.com/reference/billing_documents_index.md): Retrieve a list of all billing documents within range. Pagination of this endpoint is not indexed. `count` on the response body will always be `null`. Required authorization scope: `public.billing_document:read` - [List all Billing Document's Transaction Records](https://developers.easyship.com/reference/billing_documents_transactions_index.md): Retrieve a list of all billing document's transactions. Pagination of this endpoint is not indexed. `count` on the response body will always be `null`. Required authorization scope: `public.transaction_record:read` - [Create a Box](https://developers.easyship.com/reference/boxes_create.md): Create a box. Required authorization scope: `public.box:write` - [Delete a Box](https://developers.easyship.com/reference/boxes_delete.md): Delete a box from your account. Required authorization scope: `public.box:write` - [List all Boxes](https://developers.easyship.com/reference/boxes_index.md): Retrieve a list of available courier boxes and your custom boxes. Required authorization scope: `public.box:read` This request returns box types specified with a `slug` when creating a shipment via the API or dashboard. > In Easyship API terms, `slug` is a string field used by the `box` object. Slugs contain dimensions of corresponding box types: when you create a shipment, we will get dimensions based on the `slug` provided. - [Update a Box](https://developers.easyship.com/reference/boxes_update.md): Update a box in your account. Required authorization scope: `public.box:write` - [List all Countries](https://developers.easyship.com/reference/countries_index.md): Retrieve a list of countries. Required authorization scope: `public.reference:read` Available filtering parameters: by Alpha-2 country code or continent. - [List all Estimated Delivery Dates for a Courier Service](https://developers.easyship.com/reference/courier_service_estimated_delivery_dates_index.md): Retrieve a list of estimated delivery dates for a specific courier service. Required authorization scope: `public.courier_service:read` Easyship builds estimation model based on shipments delivered within last 12 months. If you use Link Your Own Rates (LYOC) scheme, LYOC couriers are excluded from the calculation. - [List all Courier Services](https://developers.easyship.com/reference/courier_services_index.md): Retrieve a list of active courier services available with your account. Required authorization scope: `public.courier_service:read` - [List Available Pickup Slots](https://developers.easyship.com/reference/courier_services_pickup_slots_index.md): Retrieve a list of pickup slots in local time for the coming seven days. Required authorization scope: `public.pickup:read` - [List all Courier Services of a Courier](https://developers.easyship.com/reference/courier_courier_services_index.md): Retrieve a list of courier services for selected courier. Required authorization scope: `public.courier_service:read` - [List all LYOC](https://developers.easyship.com/reference/courier_lyoc_index.md): LYOC (Link Your Own Courier) allows merchants to connect their existing courier accounts — such as DHL, UPS, FedEx, or Royal Mail — to Easyship, enabling shipments to be rated and labeled using their own negotiated rates. Use this endpoint to discover which couriers can be linked for a given country and the supported methods of connection. Each result includes a `creation` object that indicates how the courier can be linked for that country: `creation.api: true` means you can link programmatically via `POST /2024-09/courier_accounts`; `creation.ui: true` means linking is available through the Easyship Dashboard; `creation.contact: true` means you need to contact Easyship sales to arrange linkage. Filter by `country_alpha2` (ISO 3166-1 Alpha-2, e.g. `GB`) or `country_id`. Both are optional — omitting both returns all available LYOC couriers. If both are provided, `country_id` takes precedence. Required authorization scope: `public.courier:read` - [Create a Courier](https://developers.easyship.com/reference/couriers_create.md): Creates a new courier. - `201` status when created successfully. - `202` status when created but requiring additional verification. Required authorization scope: `public.courier:write` - [Delete a Courier](https://developers.easyship.com/reference/couriers_delete.md): Delete a LYOC courier. Required authorization scope: `public.courier:write` - [List all Couriers](https://developers.easyship.com/reference/couriers_index.md): Retrieve a list of active couriers. Required authorization scope: `public.courier:read` - [Get a Courier](https://developers.easyship.com/reference/couriers_show.md): Retrieve details of a couriers. Required authorization scope: `public.courier:read` - [Update a Courier](https://developers.easyship.com/reference/couriers_update.md): Updates a courier. Required authorization scope: `public.courier:write` - [Confirm Credit Top-up](https://developers.easyship.com/reference/credit_confrim_3ds_create.md): Easyship integrate with Stripe Payment Intent to collect credit card payments. Ref: https://stripe.com/docs/payments/payment-intents The confirmation process includes the collection of payment and creation of a transaction record (credit) in your account. Should the payment intent not have undergone 3D Secure, you'll receive a status code 202, indicating the need to process 3D Secure. Required authorization scope: `public.payment:write` - [Refund a Credit](https://developers.easyship.com/reference/credit_refund_create.md): Refund your credit. Required authorization scope: `public.payment:write` - [Add credit](https://developers.easyship.com/reference/credits_create.md): Top up your credit. In case your payment source (credit card) requires 3D validation use the Stripe SDK. To detect any fraudulent activities and initiate Radar and 3D Secure, integrate `handleCardAction` from Stripe.js. Reference: https://stripe.com/docs/js/payment_intents/handle_card_action Example: ```html ``` > If you are using an authorized bank account as your payment method, the transaction might take around 1 to 3 days to complete. Required authorization scope: `public.payment:write` - [Get credit](https://developers.easyship.com/reference/credits_show.md): Retrieve your credit balance. Required authorization scope: `public.credit:read` - [Tracking Updates](https://developers.easyship.com/reference/efulfillment_tracking_update.md): Update the shipment tracking number and create tracking events. Required authorization scopes: `public.shipment:write`, `public.efulfillment:write` > This endpoint is only available to eFulfillment clients with shipments fulfilled at one of Easyship's integrated warehouses. > You will need to specify `tracking_number` for initial request for a shipment. Further updates of a shipment with the same `easyship_shipment_id` don't need to have the `tracking number` unless you change it. For `events`, specify the `primary_status` field from the list: * `InTransit` * `OutForDelivery` * `AttemptFail` * `Delivered` * `Exception` #### Example request for an initial setup of a shipment ```json { "easyship_shipment_id": "ESHK10017799", "tracking_number": "ABCD1234", "events": [ { "primary_status": "InTransit" } ] } ``` #### Example request for a shipment status update This example has optional `event_time` and `event_time_zone`. ```json { "easyship_shipment_id": "ESHK10017799", "events": [ { "primary_status": "OutForDelivery", "event_time": "2020-04-29T03:38:00", "event_time_zone": "-04:00" } ] } ``` #### Example request for a complete update ```json { "easyship_shipment_id": "ESHK10017799", "events": [ { "primary_status": "OutForDelivery", "location": "Brooklyn, NY", "city": "Brooklyn", "country_alpha2": "US", "state": "NY", "zip": "11201", "handler": "UPS", "message": "On UPS vehicle for delivery", "event_time": "2020-04-29T03:38:00", "event_time_zone": "-04:00" } ] } ``` - [Warehouse State Updates](https://developers.easyship.com/reference/efulfillment_warehouse_state_update.md): Update the warehouse state of one or multiple shipments. Required authorization scope: `public.shipment:write`, `public.efulfillment:write` > This endpoint is only available to eFulfillment clients with shipments fulfilled at one of Easyship's integrated warehouses. > If a shipment contains the `metadata` object, it will persist unless you change existing keys or create new ones: in this case, corresponding keys will be updated or added. The `warehouse_state` field has the following possible statuses:
| warehouse_state | Description |
|---|---|
created | An order has been created in the warehouse management system and is ready to be fulfilled. Note: This update is not needed if a success response is sent when Easyship sends the label callback. |
failed | The order creation was rejected for an internal reason by the WMS. This can happen if the order information doesn't meet the WMS' requirements, or a product SKU is not defined in your WMS. A message can be added using the message parameter. This will allow the client and Easyship to understand the reason for rejection. |
packed | The order has been processed and packed and is waiting to be handed over to the courier |
shipped | The order has been handed over to the courier and has left the warehouse. Note: This status update will trigger the following:
|
cancellation_requested | A cancellation request has been sent to the warehouse management system. It is awaiting confirmation by the warehouse. Note: This status is set by clients requesting a cancellation through the dashboard. It should not be set by a warehouse. |
cancelled | The order has been cancelled in the warehouse management system. Note: This status update will trigger Easyship to cancel the shipment. |
cancelled_no_stock | The order has been cancelled in the warehouse management system because the products are out of stock. Note: This status update will trigger Easyship to cancel the shipment. |
backorder_no_stock | The order is set as backorder because of the products are out of stock. It may be packed and shipped at a later date. |
returned | The package was returned by the courier or by the receiver, and received at the warehouse. |