Summary: Use API2Cart’s order.shipment.add method to push tracking numbers to any connected store with a single API call. For bulk fulfillment, use order.shipment.add.batch. The API normalizes carrier names and handles partial fulfillment across all platforms.
Adding shipment tracking information to orders is a critical step in fulfillment automation. When integrating with multiple eCommerce platforms, each store has its own rules for how tracking data should be submitted. API2Cart provides a unified approach through the order.shipment.add method that works consistently across all supported platforms.
How Shipment Tracking Works in API2Cart
The order.shipment.add method allows you to push tracking information to any connected store. The key parameters include:
order_id— the order to fulfilltracking_numbers— one or more tracking numbers from the carriercarrier_id— identifier of the shipping carrieritems— specific line items being shipped (for partial fulfillment)
Example API call:
POST https://api.api2cart.com/v1.1/order.shipment.add.json?api_key=YOUR_KEY&store_key=STORE_KEY&order_id=12345&tracking_numbers=1Z999AA10123456784&carrier_id=ups
Common Validation Issues
When shipment creation fails, it's usually due to one of these platform-specific reasons:
- Carrier name mismatch: Each platform has its own list of valid carrier identifiers. Use
cart.infoto retrieve the list of available carriers and their IDs for a specific store, then pass the correctcarrier_idin your shipment request - Order status conflict: Some platforms reject tracking updates on orders that are already marked as completed or cancelled. Check order status with
order.infobefore adding shipments - Partial fulfillment: When shipping only some items from a multi-item order, you must specify which
itemsare included in this shipment. Omitting items may result in the platform rejecting the request or marking the entire order as fulfilled
Batch Shipment Updates
For high-volume fulfillment, API2Cart provides order.shipment.add.batch which lets you submit multiple shipments in a single API call. This is useful when processing hundreds of orders from a warehouse management system.
The batch method accepts an array of shipment records and returns results for each, indicating success or failure with specific error details per item.
Tracking Shipment Events
Beyond adding initial tracking numbers, you can push delivery status updates using order.shipment.event.add. This method allows you to update the shipment status (e.g., "in transit", "out for delivery", "delivered") directly on the store.
To retrieve existing shipment data, use:
order.shipment.list— get all shipments for an orderorder.shipment.info— get details of a specific shipmentorder.shipment.event.list— get tracking event history
Best Practices
- Always verify the order exists and is in a fulfillable status before adding shipments
- Create a separate shipment per package — most platforms support only one tracking number per shipment
- For multi-package orders, create separate shipments per package with their own tracking numbers
- Set up webhooks for
order.updateevents to monitor when stores confirm fulfillment status changes
All shipment methods work identically across Shopify, WooCommerce, Magento, BigCommerce, PrestaShop, and the other 70+ platforms supported by API2Cart. See the API documentation for the full parameter reference.
Frequently Asked Questions
Does API2Cart normalize carrier names across platforms?
Yes. API2Cart handles the mapping between your carrier identifier and what each platform expects (e.g., "ups" vs "UPS"), reducing validation errors.
Can I ship only some items from an order?
Yes. Use the items parameter in order.shipment.add to specify which line items are included in the shipment. This creates a partial fulfillment.
How do I add multiple tracking numbers to one order?
Use order.shipment.tracking.add to add additional tracking numbers to an existing shipment, or create multiple shipments for multi-package orders.