Create Shipment
POST/api/purchase-order-shipments
Create a new shipment for an open purchase order. If shipment_lines is omitted, creates a shipment for all remaining unshipped quantity.
Authentication: Requires Bearer token.
Fields:
- purchase_order_id (required): ID of the purchase order (must not be draft, not fully shipped)
- shipment_date (required): Date of shipment in Y-m-d format
- shipping_method_id (optional): System shipping method ID
- tracking (optional): Tracking number, max 255 characters
- shipment_lines (optional): Array of line quantities to ship. If omitted, ships everything remaining
- shipment_lines[].purchase_order_line_id (conditional): PO line ID. Required without purchase_order_line_reference
- shipment_lines[].purchase_order_line_reference (conditional): PO line reference code. Required without purchase_order_line_id
- shipment_lines[].quantity (required): Quantity to ship (must not exceed unfulfilled quantity)
Errors:
- 422: AWD purchase orders use 'Mark as Shipped' instead
- 400: Purchase order is not open (draft)
Request
Responses
- 200
- 401
- 403
- 422
- 429
OK
Response Headers
Content-Type
Unauthenticated — the bearer token is missing, revoked, expired, or malformed. Never retry automatically; fix the credential. See the Errors guide.
Forbidden — the token lacks a required scope, the endpoint is not available to API tokens, or the user behind the token lacks the permission. A human must adjust the token scopes or user permissions; do not retry.
Unprocessable Entity
Response Headers
Content-Type
Rate limited — platform limit is 1,000 requests/min; individual tokens may carry lower limits. Honor the Retry-After header before retrying. See the Rate Limits guide.