# Create a shipment (/api/shipments/create-order-shipment)

`POST https://api.comecero.com/api/v1/orders/{order_id}/shipments`

Records a parcel sent for the order: the items and quantities in it, and the carrier and tracking number. Each item is marked fulfilled once all of its units have shipped. When that makes the whole order fulfilled, any pending (authorized) payment is captured (money moves) and the `order:fulfilled` event fires. The `shipment:created` event fires and the customer is sent the shipment email. Needs a secret or trusted token. Limited tokens get `403`.

## Parameters

- `order_id` (path, required): The order id.
- `expand` (query): Comma-separated child objects to return in full instead of as a URL, for example `customer,payments`. Use dot notation for nested objects (`items.product`), up to four levels deep. A single object takes up to 12 paths; a list takes up to 2, applied to every item. Extra paths are dropped without an error. See [Expanding objects](https://docs.comecero.com/docs/basic-concepts/expanding-objects).

Request body: the `shipment_request` schema.

Responses: 201, 400, 401, 403, 404, 500.

Full schemas: operation `create_order_shipment` in /openapi.json.