order

order.shipment.add

Add a shipment to the order.

post/order.shipment.add.json

Request

  • Base URL: https://api.api2cart.com/v1.1
  • URL: https://api.api2cart.com/v1.1/order.shipment.add.json
  • Auth: API key in header x-api-key and API key in header x-store-key

Request body

order_idstring

Defines the order for which the shipment will be created

warehouse_idstring

This parameter is used for selecting a warehouse where you need to set/modify a product quantity.

store_idstring

Store Id

shipment_providerstring

Defines company name that provide tracking of shipment

shipping_methodstring

Define shipping method

tracking_linkstring

Defines custom tracking link

is_shippedboolean

Defines shipment's status

send_notificationsboolean

Send notifications to customer after shipment was created

adjust_stockboolean

This parameter is used for adjust stock.

check_process_statusboolean

Disable or enable check process status. Please note that the response will be slower due to additional requests to the store.

tracking_providerstring

Defines name of the company which provides shipment tracking

admin_commentstring

Specifies admin's order comment

mail_classstring

Mail class for the shipment (e.g., priority, express).

ship_datestring

Ship date.

weightnumber

Weight

weight_unitstring

Weight Unit

lengthnumber

Defines product's length

widthnumber

Defines product's width

heightnumber

Defines product's height

dimensions_unitstring

Weight Unit

shipping_label_costnumber

Cost of the shipping label.

shipping_label_currencystring

Currency code for the shipping label cost (3-letter ISO code).

revenue_eligibilityboolean

Revenue eligibility flag.

ship_from_countrystring

Country code the shipment is sent from (2-letter ISO code).

ship_to_countrystring

Country code the shipment is sent to (2-letter ISO code).

incotermstring

International commercial term for the shipment (e.g., DAP, DDP).

duty_amountnumber

Duty amount for international shipment.

duty_currencystring

Currency code for the duty amount (3-letter ISO code).

enable_cacheboolean

If the value is 'true' and order exist in our cache, we will use order.info from cache to prepare shipment items.

use_latest_api_versionboolean

Use the latest platform API version

idempotency_keystring

A unique identifier associated with a specific request. Repeated requests with the same <strong>idempotency_key</strong> return a cached response without re-executing the business logic. <strong>Please note that the cache lifetime is 15 minutes.</strong>

Example request

{
  "warehouse_id": "1",
  "store_id": "1",
  "shipment_provider": "UPS",
  "shipping_method": "flatrate_flatrate",
  "tracking_link": "http://example.com?someParam=value",
  "is_shipped": true,
  "send_notifications": true,
  "adjust_stock": true,
  "tracking_provider": "Custom tracker",
  "admin_comment": "Test admin comment",
  "mail_class": "priority",
  "ship_date": "2025-03-15 10:00:00",
  "weight": 23.69,
  "weight_unit": "lb",
  "length": 56.12,
  "width": 56.12,
  "height": 56.12,
  "dimensions_unit": "cm",
  "shipping_label_currency": "USD",
  "revenue_eligibility": true,
  "ship_from_country": "US",
  "ship_to_country": "GB",
  "incoterm": "DAP",
  "duty_currency": "USD",
  "enable_cache": true,
  "use_latest_api_version": true,
  "idempotency_key": "098f6bcd4621d373cade4e832627b4f6"
}

Response

successful operation

return_codeinteger
return_messagestring

Changes

No recorded changes to this operation across all 1 revision of this API.