Create a shipment
Start tracking a parcel. Tracking begins right after creation and updates arrive over time.
/shipmentsshipments:writeNeeds an active subscriptioncurl -X POST "https://track360.tdccommerce.com/api/v1/shipments" \
-H "Authorization: Bearer $API_KEY" \
-H "Content-Type: application/json" \
-H 'Idempotency-Key: order-10045-create' \
-d '{
"trackingNumber": "1Z999AA10123456784",
"carrierCode": "ups",
"externalOrderId": "ORD-10045",
"customerName": "Jane Doe",
"customerEmail": "[email protected]",
"service": "UPS Ground",
"note": "Leave at front desk",
"destinationCountry": "US",
"destinationPostalCode": "78701",
"metadata": {
"warehouse": "AUS-1"
}
}'{
"statusCode": 201,
"message": "Shipment created successfully",
"data": {
"id": "b7c1f2e4-3a58-4d0e-9f61-2c8d5a7e90ab",
"tracking_number": "1Z999AA10123456784",
"courier_code": "ups",
"order_number": "ORD-10045",
"order_date": null,
"created_at": "2026-10-20T14:32:08.417Z",
"update_at": "2026-10-20T14:32:08.417Z",
"delivery_status": "pending",
"archived": "tracking",
"updating": true,
"source": "API",
"destination_country": "US",
"destination_state": null,
"destination_city": null,
"origin_country": null,
"origin_state": null,
"origin_city": null,
"tracking_postal_code": null,
"tracking_ship_date": null,
"tracking_destination_country": "US",
"tracking_origin_country": null,
"tracking_key": null,
"tracking_courier_account": null,
"customer_name": "Jane Doe",
"customer_email": "[email protected]",
"customer_sms": null,
"recipient_postcode": "78701",
"order_id": "ORD-10045",
"title": null,
"logistics_channel": "UPS Ground",
"note": "Leave at front desk",
"label": null,
"signed_by": null,
"service_code": "UPS Ground",
"weight": null,
"weight_kg": null,
"product_type": null,
"pieces": null,
"dimension": null,
"previously": null,
"destination_track_number": null,
"exchange_number": null,
"scheduled_delivery_date": null,
"scheduled_address": null,
"substatus": null,
"status_info": null,
"latest_event": null,
"latest_checkpoint_time": null,
"transit_time": 1,
"origin_info": {
"courier_code": "ups",
"courier_phone": "1.800.742.5877",
"weblink": "https://www.ups.com/",
"tracking_link": "https://www.ups.com/track?tracknum=1Z999AA10123456784",
"reference_number": "ups",
"milestone_date": {
"inforeceived_date": null,
"pickup_date": null,
"outfordelivery_date": null,
"delivery_date": null,
"returning_date": null,
"returned_date": null
},
"pickup_date": null,
"departed_airport_date": null,
"arrived_abroad_date": null,
"customs_received_date": null,
"trackinfo": []
},
"destination_info": {
"courier_code": null,
"courier_phone": null,
"weblink": null,
"tracking_link": null,
"reference_number": null,
"milestone_date": {
"inforeceived_date": null,
"pickup_date": null,
"outfordelivery_date": null,
"delivery_date": null,
"returning_date": null,
"returned_date": null
},
"pickup_date": null,
"departed_airport_date": null,
"arrived_abroad_date": null,
"customs_received_date": null,
"trackinfo": []
},
"organizationId": "5d0e3b0a-7c1f-4e92-b6a8-3f4d2e1a9c70",
"trackingNumber": "1Z999AA10123456784",
"normalizedTrackingNumber": "1Z999AA10123456784",
"carrier": {
"id": "carr_ups",
"code": "ups",
"name": "United Parcel Service (UPS)"
},
"customerId": "0c4f6a52-9d1e-4b7a-8e33-5a2f1c6d9b04",
"status": "active",
"currentTrackingStatus": "pending",
"currentTrackingStatusAt": "2026-10-20T14:32:08.417Z",
"service": "UPS Ground",
"externalId": null,
"externalOrderId": "ORD-10045",
"originPostalCode": null,
"destinationPostalCode": "78701",
"metadata": {
"warehouse": "AUS-1",
"note": "Leave at front desk",
"customer_name": "Jane Doe",
"customer_email": "[email protected]"
},
"createdAt": "2026-10-20T14:32:08.417Z",
"updatedAt": "2026-10-20T14:32:08.417Z",
"archivedAt": null
}
}Request headers
Idempotency-KeystringOptional, up to 255 characters. Makes the request safe to retry; see Idempotency.
Request body (JSON)
trackingNumberstringrequired1 to 128 characters, at least one of them other than a space or hyphen. Stored as you send it; matched ignoring case, spaces and hyphens, so
1z999aa1 0123456784and1Z999AA10123456784are the same shipment.carrierCodestringUp to 64 characters, e.g.
ups,fedex,usps,dhl. Optional. The code is not checked against a list: one we do not recognize is accepted and tracked through a fallback provider, so check the spelling. Wins overcarrierIdwhen both are sent.carrierIdstringUp to 64 characters. A carrier record id (
carrier.idin a response). Used only whencarrierCodeis omitted.customerIdstringUp to 64 characters. An existing customer of your organization (
customerIdin a response); another organization's id is rejected withINVALID_CUSTOMER. Usually unnecessary: sendcustomerEmail,customerNameorcustomerPhoneand the customer is matched by email or created.customerNamestringUp to 255 characters, trimmed.
customerEmailstringA valid email, up to 255 characters. An empty string is accepted.
customerPhonestringUp to 64 characters, trimmed.
notestringUp to 1,000 characters, trimmed. Also copied into
metadata.note.servicestringUp to 128 characters, e.g.
UPS Ground.serviceCodestringUp to 128 characters.
externalIdstringYour own id for the shipment, up to 128 characters.
externalOrderIdstringYour order id, up to 128 characters.
GET /shipmentscan filter and search by it.originCountrystringUp to 128 characters. Free text; ISO 3166-1 alpha-2 such as
USis recommended.destinationCountrystringUp to 128 characters, same format as
originCountry.originPostalCodestringUp to 64 characters.
destinationPostalCodestringUp to 64 characters.
metadataobjectFree-form JSON object, up to 16 KB serialized. Keys such as
weight_kg,titleordestination_cityalso fill the matching top-level field of the Shipment.
Response
Errors
- 400
VALIDATION_ERRORA parameter or body field is missing, has the wrong type or is out of range.
details[].pathnames the field. - 400
INVALID_CUSTOMERcustomerIddoes not belong to your organization. - 402
ACTIVE_SUBSCRIPTION_REQUIREDThe organization has no active subscription.
- 402
SHIPMENT_LIMIT_REACHEDYou have used every shipment your plan includes for this billing period.
- 409
IDEMPOTENCY_KEY_MISMATCHThe
Idempotency-Keywas already used with a different body. - 409
IDEMPOTENCY_IN_PROGRESSA request with the same key and body is still being processed.
- 503
BILLING_SYNC_PENDINGYour billing period is being renewed. Retry after the
Retry-Afterheader (5 seconds). - 503
SHIPMENT_QUOTA_BUSYToo many shipments are being created at once for your organization. Retry after the
Retry-Afterheader (5 seconds).
Plus the general errors every request can get (401, 403, 429, 5xx).
Sending a tracking number you already track (same carrier) is not an error: you get the existing shipment back with status 201. Nothing is created, counted against your allowance or announced, and the new body is ignored. That also holds for an archived shipment.
Each newly created shipment uses one unit of your plan’s shipment allowance. Archiving or deleting it does not give the unit back.
A shipment created without carrierCode or carrierId shows carrier.code unknown until tracking identifies the carrier.