Orders API
The Carriyo Orders API manages the customer order lifecycle from creation through fulfillment handoff. Create orders with line items and delivery details, split them across fulfillment locations, and cancel or update them before they ship.
Before you start
- Every request carries
Authorization: Bearer <token>,x-api-keyandtenant-id; see the Authentication API. merchantis the merchant's identifier, an uppercase code such asACME, not its display name.- Automatic allocation is off until the tenant's order management settings exist with
enable_automatic_order_allocation; until then every order is created inopen. - Allocation needs at least one location whose fulfillment coverage includes the delivery or collection address.
Order references
Every endpoint that takes an order in the path accepts either order_id, Carriyo's identifier, or partner_order_reference, your own. The value is matched against order_id first, then partner_order_reference; to keep the two from colliding, a partner_order_reference equal to an existing order_id is rejected with 400, so avoid partner references that could look like Carriyo ids. Fulfillment orders in the path work the same way with fulfillment_order_id and partner_fulfillment_order_reference; when more than one fulfillment order on the order carries the reference you pass, the request fails with 400, so use the id instead.
Idempotency
Write endpoints accept an optional Idempotency-Key request header for safe request replay when your integration retries after uncertain network outcomes. Replayed responses include Idempotent-Replayed: true. See Idempotency for the full contract.
Orders
A customer order: the line items, customer and addresses, payment, and the fulfillment orders that carry the items to the customer.
Related: How orders move through their statuses
12 operations · 1 object
The Order object
The Order object represents a customer order in Carriyo — line items the customer purchased, shipping and billing addresses, payment, and the references that tie back to your e-commerce or OMS system.
An Order doesn't directly book a shipment. Instead, Carriyo splits the Order into one or more fulfillment orders allocated across your locations, and each fulfillment order produces one or more Shipments. For the full relationship model, see the Domain model.
Properties
- Current status of the order: -
open- Order created, not yet allocated -partially_allocated- Some items allocated to fulfillment locations -allocated- All items allocated to fulfillment locations -on_hold- Order is held and cannot be updated or fulfilled until the hold is released -processing- One or more fulfillment orders are being processed (picked, packed, shipped or partially fulfilled) -fulfilled- All items have been fulfilled -cancelled- Order has been cancelled -closed- Order is complete and closedValues:openpartially_allocatedallocatedon_holdprocessingfulfilledcancelledclosed - Why the order or its items were cancelled:
customer_cancellation(the customer asked),auto_allocation_failed(no location could be allocated),inventory_out_of_stock,staff_error,payment_issueorother.Values:customer_cancellationauto_allocation_failedinventory_out_of_stockstaff_errorpayment_issueother
Related
- Create order — POST /orders
- List orders — GET /orders
- Get order — GET /orders/{order_id}
- Update order — PUT /orders/{order_id}
- E-commerce orders guide — full integration walkthrough
/ordersCreate order
Creates an order with its line items, customer and delivery details, and allocates it to fulfillment locations.
Behavior
What happens
- Carriyo validates the request and creates the order.
- Fulfillment orders come from your
fulfillment_orders, or from automatic allocation when you omit them. Allocation completes before the response. - With inventory management enabled, stock is reserved for the allocated items.
- The
ORDER_CREATEwebhook fires.
The response status is derived from the fulfillment orders: allocated when every fulfillment order has a location, partially_allocated when only some do, and open when none has one. A hold rule can return the order on_hold.
Validation problems on line items, addresses or fulfillment orders do not reject the request. They are recorded in error_details on the created order.
Line items
Each line is resolved against the product catalog by product_ref, then sku, then product_id. The response carries Carriyo's product_id and the product's inventory_key on every resolved line.
Delivery method
Each fulfillment order has one delivery_method:
DELIVERYusesdelivery_addressanddelivery_schedule.COLLECTIONusescustomer_collection_addressandcustomer_collection_schedule.DIGITALneeds neither.
The top-level delivery fields are request-only conveniences and are not stored on the order itself. They are copied onto the fulfillment orders Carriyo creates when you omit fulfillment_orders. To set them per fulfillment order, put them inside each entry.
An entry without its own delivery fields inherits the top-level delivery_method, delivery_type and delivery_option, then the top-level address and schedule for its method. Fields the entry sets always win. This inheritance happens on create only.
Allocation
- Manual. A
fulfillment_ordersentry that names a location is left as sent. - Automatic. Entries with no location, and every fulfillment order when you omit
fulfillment_orders, are allocated by the engine, providedenable_automatic_order_allocationis on in the order management settings;DIGITALentries are never allocated. Stock counts only when inventory management is enabled. Radius coverage needscoordson the reference address.
With automatic allocation off, entries that name a location are allocated and the rest are open with fulfillment_location_missing in their error_details.
When no candidate can supply an item:
- with the order management setting
allow_partial_order_allocationon, the unsupplied items move to a separate fulfillment order whose items arecancelled, and the order still reportsallocated; - otherwise the fulfillment order stays as it was, with
auto_allocation_failedin itserror_detailsand anallocation_failure_reasonon each item. A coverage miss reportsOUT_OF_STOCK.
Errors
400—partner_order_referencealready exists in the tenant or equals an existingorder_id.400— the merchant is unknown.400— the account's order quota is exhausted.
Headers
| Name | Value | Required | Description |
|---|---|---|---|
| Authorization | Bearer YOUR-ACCESS-TOKEN | Yes | OAuth 2.0 bearer token obtained from `POST /oauth/token`. |
| x-api-key | YOUR-API-KEY | Yes | Your tenant's API key, issued in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| tenant-id | YOUR-TENANT-ID | Yes | Your Carriyo tenant ID, shown in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| Content-Type | application/json | Yes | Media type of the request body. |
Header parameters
| Name | Type | Required | Description |
|---|---|---|---|
| Idempotency-Key | string | No | Optional client-generated key that identifies one logical operation. Reuse the same key when retrying with the same payload. Replays the stored response. See [Idempotency](/api/idempotency/). |
Request body
application/jsonSchema: create-order-requestrequiredResponses
order- Current status of the order: -
open- Order created, not yet allocated -partially_allocated- Some items allocated to fulfillment locations -allocated- All items allocated to fulfillment locations -on_hold- Order is held and cannot be updated or fulfilled until the hold is released -processing- One or more fulfillment orders are being processed (picked, packed, shipped or partially fulfilled) -fulfilled- All items have been fulfilled -cancelled- Order has been cancelled -closed- Order is complete and closedValues:openpartially_allocatedallocatedon_holdprocessingfulfilledcancelledclosed - Why the order or its items were cancelled:
customer_cancellation(the customer asked),auto_allocation_failed(no location could be allocated),inventory_out_of_stock,staff_error,payment_issueorother.Values:customer_cancellationauto_allocation_failedinventory_out_of_stockstaff_errorpayment_issueother
Need the full machine-readable spec? Download the OpenAPI document →
/ordersList orders
Returns a page of orders matching the search and filter parameters.
Behavior
search_string matches substrings of the order id and partner order reference.
Each request through the API counts one against the account's monthly order-list quota, a separate allowance from the order quota. The counter resets each calendar month, and a request that fails with a server error is not counted.
Errors
429— the monthly order-list quota is exhausted; the message states the limit.
Related: Order status codes
Query parameters
| Name | Type | Required | Description |
|---|---|---|---|
| search_string | string | No | The search string to find orders using order data such as order id and partner order reference. |
| merchant | string | No | The merchant parameter filters orders for a given merchant. This parameter can be used multiple times to filter results for multiple merchants. |
| creation_date_from | string | No | The start date in ISO 8601 format to filter the results using order creation date. |
| creation_date_to | string | No | The end date in ISO 8601 format to filter the results using order creation date. |
| update_date_from | string | No | The start date in ISO 8601 format to filter results, returning orders that were either created OR updated during this time period. |
| update_date_to | string | No | The end date in ISO 8601 format to filter results, returning orders that were either created OR updated during this time period. |
| page | string | No | The page number of the result set, starting from 0. Defaults to the first page (page 0). |
| page_size | string | No | The number of results to be included in the response, ranging from 10 to 100. Defaults to page size of 10. |
Headers
| Name | Value | Required | Description |
|---|---|---|---|
| Authorization | Bearer YOUR-ACCESS-TOKEN | Yes | OAuth 2.0 bearer token obtained from `POST /oauth/token`. |
| x-api-key | YOUR-API-KEY | Yes | Your tenant's API key, issued in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| tenant-id | YOUR-TENANT-ID | Yes | Your Carriyo tenant ID, shown in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
Responses
Need the full machine-readable spec? Download the OpenAPI document →
/orders/{orderReference}Get order
Returns an order by order_id or partner_order_reference, with its fulfillment orders and line items.
Related: Order status codes
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
| orderReference | string | Yes | Carriyo `order_id` or your own `partner_order_reference`. The value is matched against `order_id` first, then `partner_order_reference`; if neither matches, the response is 404. |
Headers
| Name | Value | Required | Description |
|---|---|---|---|
| Authorization | Bearer YOUR-ACCESS-TOKEN | Yes | OAuth 2.0 bearer token obtained from `POST /oauth/token`. |
| x-api-key | YOUR-API-KEY | Yes | Your tenant's API key, issued in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| tenant-id | YOUR-TENANT-ID | Yes | Your Carriyo tenant ID, shown in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
Responses
order- Current status of the order: -
open- Order created, not yet allocated -partially_allocated- Some items allocated to fulfillment locations -allocated- All items allocated to fulfillment locations -on_hold- Order is held and cannot be updated or fulfilled until the hold is released -processing- One or more fulfillment orders are being processed (picked, packed, shipped or partially fulfilled) -fulfilled- All items have been fulfilled -cancelled- Order has been cancelled -closed- Order is complete and closedValues:openpartially_allocatedallocatedon_holdprocessingfulfilledcancelledclosed - Why the order or its items were cancelled:
customer_cancellation(the customer asked),auto_allocation_failed(no location could be allocated),inventory_out_of_stock,staff_error,payment_issueorother.Values:customer_cancellationauto_allocation_failedinventory_out_of_stockstaff_errorpayment_issueother
Need the full machine-readable spec? Download the OpenAPI document →
/orders/{orderReference}Update order
Applies a partial update to an order; line_items and fulfillment_orders are replaced as whole arrays.
Behavior
Preconditions. The order must not be cancelled or on hold. Orders in processing, fulfilled or closed can still be updated.
What happens. The changes below are applied and the ORDER_UPDATE webhook fires.
Simple fields
These change only when present in the request; an empty string is ignored, not applied:
partner_order_reference,order_date,merchant,language,sales_channeltaxes_included,duties_includedbilling_address,customerpayment,discount_applications,shipping_lines
custom_attributes is merged per key, and a null value removes the key.
The order stores no delivery address of its own; delivery details live inside each fulfillment_orders entry. To change where a fulfillment order delivers after allocation, use its address endpoint.
Line items
line_items, when present, replaces the whole list. Include every line item you want to keep. To remove an item after allocation, cancel it on its fulfillment order.
Fulfillment orders
fulfillment_orders, when present, replaces the whole list too:
- A fulfillment order left out of the request is removed, even when it has fulfilled items; its pending reservations are released.
- One matched by
fulfillment_order_idorpartner_fulfillment_order_referenceis updated. - One with no match is created. Without a location it is left
openwithfulfillment_location_missingin itserror_details; update never runs the allocation engine.
Within a fulfillment order, send only line items in open or allocated status. fulfilled, cancelled and closed items are preserved automatically; one that is re-sent is not rejected but added again as a new pending item alongside the preserved one. Quantity reductions are recorded in removed_quantities.
A fulfillment order line item that matches no order line item is recorded in the fulfillment order's error_details rather than rejected.
Inventory
With inventory management enabled, reservations follow the allocation changes:
- stock is reserved for new fulfillment order allocations;
- stock is released for removed allocations;
- reservations are adjusted for quantity changes.
Errors
400— the order iscancelled.400— the order is on hold.400— another update changed the order first; re-read and retry.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
| orderReference | string | Yes | Carriyo `order_id` or your own `partner_order_reference`. The value is matched against `order_id` first, then `partner_order_reference`; if neither matches, the response is 404. |
Headers
| Name | Value | Required | Description |
|---|---|---|---|
| Authorization | Bearer YOUR-ACCESS-TOKEN | Yes | OAuth 2.0 bearer token obtained from `POST /oauth/token`. |
| x-api-key | YOUR-API-KEY | Yes | Your tenant's API key, issued in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| tenant-id | YOUR-TENANT-ID | Yes | Your Carriyo tenant ID, shown in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| Content-Type | application/json | Yes | Media type of the request body. |
Header parameters
| Name | Type | Required | Description |
|---|---|---|---|
| Idempotency-Key | string | No | Optional client-generated key that identifies one logical operation. Reuse the same key when retrying with the same payload. Replays the stored response. See [Idempotency](/api/idempotency/). |
Request body
application/jsonSchema: update-order-requestrequired- Full replacement with preservation rules. ⚠️ Critical: Any fulfillment order NOT included in this array will be PERMANENTLY REMOVED. For each FO's line_items: - Only include items with pending statuses (
open,allocated,pick_in_progress,picked,pack_in_progress) - Items with terminal statuses (fulfilled,cancelled,closed) are automatically preserved
Responses
order- Current status of the order: -
open- Order created, not yet allocated -partially_allocated- Some items allocated to fulfillment locations -allocated- All items allocated to fulfillment locations -on_hold- Order is held and cannot be updated or fulfilled until the hold is released -processing- One or more fulfillment orders are being processed (picked, packed, shipped or partially fulfilled) -fulfilled- All items have been fulfilled -cancelled- Order has been cancelled -closed- Order is complete and closedValues:openpartially_allocatedallocatedon_holdprocessingfulfilledcancelledclosed - Why the order or its items were cancelled:
customer_cancellation(the customer asked),auto_allocation_failed(no location could be allocated),inventory_out_of_stock,staff_error,payment_issueorother.Values:customer_cancellationauto_allocation_failedinventory_out_of_stockstaff_errorpayment_issueother
error-responseNeed the full machine-readable spec? Download the OpenAPI document →
/orders/{orderReference}/cancelCancel order
Cancels an order and every fulfillment order on it.
Behavior
Preconditions. The order must be open, partially_allocated, allocated or on_hold; cancelling a held order releases the hold. For an order in processing, fulfilled or closed the request succeeds but nothing changes: the unchanged order is returned and the ORDER_CANCEL webhook still fires, so check status in the response.
What happens.
- Every fulfillment order line item becomes
cancelledwith thecancellation_reasonyou supply. - Open picks are cancelled.
- The order status becomes
cancelled. - The
ORDER_CANCELwebhook fires.
Order line item quantities are left as they were.
Inventory. With inventory management enabled and a fulfillment_location set on the fulfillment order, reserved is reduced by the cancelled quantity.
Errors
400— the order is alreadycancelled.
Related: Order status codes
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
| orderReference | string | Yes | Carriyo `order_id` or your own `partner_order_reference`. The value is matched against `order_id` first, then `partner_order_reference`; if neither matches, the response is 404. |
Headers
| Name | Value | Required | Description |
|---|---|---|---|
| Authorization | Bearer YOUR-ACCESS-TOKEN | Yes | OAuth 2.0 bearer token obtained from `POST /oauth/token`. |
| x-api-key | YOUR-API-KEY | Yes | Your tenant's API key, issued in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| tenant-id | YOUR-TENANT-ID | Yes | Your Carriyo tenant ID, shown in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| Content-Type | application/json | Yes | Media type of the request body. |
Header parameters
| Name | Type | Required | Description |
|---|---|---|---|
| Idempotency-Key | string | No | Optional client-generated key that identifies one logical operation. Reuse the same key when retrying with the same payload. Replays the stored response. See [Idempotency](/api/idempotency/). |
Request body
application/jsonSchema: cancel-order-request- Why the order or its items were cancelled:
customer_cancellation(the customer asked),auto_allocation_failed(no location could be allocated),inventory_out_of_stock,staff_error,payment_issueorother.Values:customer_cancellationauto_allocation_failedinventory_out_of_stockstaff_errorpayment_issueother
Responses
order- Current status of the order: -
open- Order created, not yet allocated -partially_allocated- Some items allocated to fulfillment locations -allocated- All items allocated to fulfillment locations -on_hold- Order is held and cannot be updated or fulfilled until the hold is released -processing- One or more fulfillment orders are being processed (picked, packed, shipped or partially fulfilled) -fulfilled- All items have been fulfilled -cancelled- Order has been cancelled -closed- Order is complete and closedValues:openpartially_allocatedallocatedon_holdprocessingfulfilledcancelledclosed - Why the order or its items were cancelled:
customer_cancellation(the customer asked),auto_allocation_failed(no location could be allocated),inventory_out_of_stock,staff_error,payment_issueorother.Values:customer_cancellationauto_allocation_failedinventory_out_of_stockstaff_errorpayment_issueother
error-responseNeed the full machine-readable spec? Download the OpenAPI document →
/orders/{orderReference}/redactRedact order
Anonymises the personal data on an order and on the dropoff side of every linked shipment. The change is irreversible.
Behavior
Preconditions. None. The order can be in any status, including on hold.
Webhooks. No webhook fires.
Related: What redaction removes
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
| orderReference | string | Yes | Carriyo `order_id` or your own `partner_order_reference`. The value is matched against `order_id` first, then `partner_order_reference`; if neither matches, the response is 404. |
Headers
| Name | Value | Required | Description |
|---|---|---|---|
| Authorization | Bearer YOUR-ACCESS-TOKEN | Yes | OAuth 2.0 bearer token obtained from `POST /oauth/token`. |
| x-api-key | YOUR-API-KEY | Yes | Your tenant's API key, issued in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| tenant-id | YOUR-TENANT-ID | Yes | Your Carriyo tenant ID, shown in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
Header parameters
| Name | Type | Required | Description |
|---|---|---|---|
| Idempotency-Key | string | No | Optional client-generated key that identifies one logical operation. Reuse the same key when retrying with the same payload. Replays the stored response. See [Idempotency](/api/idempotency/). |
Responses
order- Current status of the order: -
open- Order created, not yet allocated -partially_allocated- Some items allocated to fulfillment locations -allocated- All items allocated to fulfillment locations -on_hold- Order is held and cannot be updated or fulfilled until the hold is released -processing- One or more fulfillment orders are being processed (picked, packed, shipped or partially fulfilled) -fulfilled- All items have been fulfilled -cancelled- Order has been cancelled -closed- Order is complete and closedValues:openpartially_allocatedallocatedon_holdprocessingfulfilledcancelledclosed - Why the order or its items were cancelled:
customer_cancellation(the customer asked),auto_allocation_failed(no location could be allocated),inventory_out_of_stock,staff_error,payment_issueorother.Values:customer_cancellationauto_allocation_failedinventory_out_of_stockstaff_errorpayment_issueother
Need the full machine-readable spec? Download the OpenAPI document →
/orders/{orderReference}/activityList order activity
Returns a paginated timeline of everything that has happened to an order.
Behavior
Each entry comes from one of three sources:
- Change logs — field-level edits, in
changes. - System logs — API calls and internal events, with timing and response code.
- Notifications — customer notifications, in
notification, withrequest_typeNOTIFICATION.
A change log and the system log that caused it merge into one entry. A system log with no change log appears on its own, without changes.
Housekeeping fields that change on every write, such as update_date and update_source, are left out of changes.
Related: Order webhook events
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
| orderReference | string | Yes | Carriyo `order_id` or your own `partner_order_reference`. The value is matched against `order_id` first, then `partner_order_reference`; if neither matches, the response is 404. |
Query parameters
| Name | Type | Required | Description |
|---|---|---|---|
| page_num | integer | No | Page of the timeline to return. Values below 1 fall back to 1. |
| rows_per_page | integer | No | Entries per page. Values above 100 are capped at 100. |
| sort | string | No | Orders entries by timestamp. Defaults to newest first. |
| source | array | No | Filters entries by what triggered them. Comma-separated, any match: `source=user,api`. - `all`: no filtering (default) - `user`: Dashboard and Fulfillment App activity - `api`: direct API calls - `webhook`: webhook deliveries and retries - `system`: everything else, such as carrier callbacks and internal services Unrecognized values are ignored. |
Headers
| Name | Value | Required | Description |
|---|---|---|---|
| Authorization | Bearer YOUR-ACCESS-TOKEN | Yes | OAuth 2.0 bearer token obtained from `POST /oauth/token`. |
| x-api-key | YOUR-API-KEY | Yes | Your tenant's API key, issued in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| tenant-id | YOUR-TENANT-ID | Yes | Your Carriyo tenant ID, shown in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
Responses
activity-responseNeed the full machine-readable spec? Download the OpenAPI document →
/orders/{orderReference}/on-holdHold order
Puts an order on hold so that it cannot be updated or fulfilled until the hold is released.
Behavior
Preconditions. The order must be open, partially_allocated or allocated and not already on hold. A fulfillment order already on hold does not block the call; its hold is absorbed and released together with the order hold.
What happens.
- The order status becomes
on_hold, and everyopenorallocatedfulfillment order on it showson_holdtoo. on_hold_detailsrecords the hold; an earlier hold moves intohistory.- While the hold is active, updating the order and every fulfillment order operation except cancel return
400. - Cancelling a held order releases the hold.
- The
ORDER_ON_HOLDwebhook fires.
Errors
400— the order is notopen,partially_allocatedorallocated.400— the order is already on hold.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
| orderReference | string | Yes | Carriyo `order_id` or your own `partner_order_reference`. The value is matched against `order_id` first, then `partner_order_reference`; if neither matches, the response is 404. |
Headers
| Name | Value | Required | Description |
|---|---|---|---|
| Authorization | Bearer YOUR-ACCESS-TOKEN | Yes | OAuth 2.0 bearer token obtained from `POST /oauth/token`. |
| x-api-key | YOUR-API-KEY | Yes | Your tenant's API key, issued in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| tenant-id | YOUR-TENANT-ID | Yes | Your Carriyo tenant ID, shown in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| Content-Type | application/json | Yes | Media type of the request body. |
Header parameters
| Name | Type | Required | Description |
|---|---|---|---|
| Idempotency-Key | string | No | Optional client-generated key that identifies one logical operation. Reuse the same key when retrying with the same payload. Replays the stored response. See [Idempotency](/api/idempotency/). |
Request body
application/jsonSchema: on-hold-requestResponses
order- Current status of the order: -
open- Order created, not yet allocated -partially_allocated- Some items allocated to fulfillment locations -allocated- All items allocated to fulfillment locations -on_hold- Order is held and cannot be updated or fulfilled until the hold is released -processing- One or more fulfillment orders are being processed (picked, packed, shipped or partially fulfilled) -fulfilled- All items have been fulfilled -cancelled- Order has been cancelled -closed- Order is complete and closedValues:openpartially_allocatedallocatedon_holdprocessingfulfilledcancelledclosed - Why the order or its items were cancelled:
customer_cancellation(the customer asked),auto_allocation_failed(no location could be allocated),inventory_out_of_stock,staff_error,payment_issueorother.Values:customer_cancellationauto_allocation_failedinventory_out_of_stockstaff_errorpayment_issueother
error-responseNeed the full machine-readable spec? Download the OpenAPI document →
/orders/{orderReference}/release-on-holdRelease order hold
Releases an active hold on an order and returns it to the status derived from its fulfillment orders.
Behavior
Preconditions. The order must be on_hold.
What happens.
- The order returns to
open,partially_allocatedorallocatedas derived from its fulfillment orders. - Any hold on the order's individual fulfillment orders is released as well.
on_hold_detailsis kept with the release details.- The
ORDER_RELEASE_ON_HOLDwebhook fires.
Errors
400— the order is noton_hold.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
| orderReference | string | Yes | Carriyo `order_id` or your own `partner_order_reference`. The value is matched against `order_id` first, then `partner_order_reference`; if neither matches, the response is 404. |
Headers
| Name | Value | Required | Description |
|---|---|---|---|
| Authorization | Bearer YOUR-ACCESS-TOKEN | Yes | OAuth 2.0 bearer token obtained from `POST /oauth/token`. |
| x-api-key | YOUR-API-KEY | Yes | Your tenant's API key, issued in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| tenant-id | YOUR-TENANT-ID | Yes | Your Carriyo tenant ID, shown in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| Content-Type | application/json | Yes | Media type of the request body. |
Header parameters
| Name | Type | Required | Description |
|---|---|---|---|
| Idempotency-Key | string | No | Optional client-generated key that identifies one logical operation. Reuse the same key when retrying with the same payload. Replays the stored response. See [Idempotency](/api/idempotency/). |
Request body
application/jsonSchema: release-on-hold-requestResponses
order- Current status of the order: -
open- Order created, not yet allocated -partially_allocated- Some items allocated to fulfillment locations -allocated- All items allocated to fulfillment locations -on_hold- Order is held and cannot be updated or fulfilled until the hold is released -processing- One or more fulfillment orders are being processed (picked, packed, shipped or partially fulfilled) -fulfilled- All items have been fulfilled -cancelled- Order has been cancelled -closed- Order is complete and closedValues:openpartially_allocatedallocatedon_holdprocessingfulfilledcancelledclosed - Why the order or its items were cancelled:
customer_cancellation(the customer asked),auto_allocation_failed(no location could be allocated),inventory_out_of_stock,staff_error,payment_issueorother.Values:customer_cancellationauto_allocation_failedinventory_out_of_stockstaff_errorpayment_issueother
error-responseNeed the full machine-readable spec? Download the OpenAPI document →
/orders/{orderReference}/fulfillFulfill entire order
Fulfills every pending item on the order in one call, whichever fulfillment orders they sit on.
Behavior
Preconditions. Neither the order nor any of its fulfillment orders may be on hold, and at least one item must be pending. Pending covers open, allocated, pick_in_progress, picked and pack_in_progress.
Items in a pick or pack. Pending pick_in_progress and pack_in_progress items are fulfilled too, but the pick or pack that holds them stays open. Completing that pick later skips those items, and completing that pack fails with 400 and leaves the pack completed.
Scope
Every fulfillment order with pending items is fulfilled in full. Fulfillment orders with nothing pending are skipped, so an order that was already part fulfilled or part cancelled can still be completed in one call.
You cannot select items; every pending item is fulfilled. To fulfill one fulfillment order, or part of one, use the fulfillment order endpoint instead.
The order status is recalculated and the ORDER_FULFILL webhook fires.
Shipments
Each fulfillment order that requires shipping becomes its own shipment, created and confirmed with the carrier. Two query parameters change that:
create_draft_shipment=trueleaves the shipments as drafts for review before booking.skip_shipping=truefulfills without creating any shipment.
If a shipment cannot be created, the fulfillment order is still fulfilled and records shipment_creation_failed in its error_details; retry it with the ship endpoint. If the carrier booking fails, the shipment is left in error with the reason in its own error_details; fix the cause and reprocess the shipment.
When items close
A fulfillment order requires shipping when its delivery method is DELIVERY, or COLLECTION from a location other than the one fulfilling it. Items close automatically only when it does not require shipping and the order did not come from Shopify. With skip_shipping=true on one that does require shipping, the items stay fulfilled for you to close yourself.
Payment split
When the order carries a payment, the order total and the amount to collect on delivery are split across the shipments:
- by item value;
- by quantity when items have no prices;
- evenly when there is neither.
The last shipment takes the rounding remainder. With no payment on the order, each shipment carries a zeroed payment: no currency, total_amount 0 and pending_amount 0.
Inventory
With inventory management enabled and stock_reduction_timing set to ON_ORDER_FULFILLED, on_hand and reserved are reduced by the fulfilled quantity.
Errors
400— the order or any of its fulfillment orders is on hold.400— nothing is pending.
Related: What fulfilling produces
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
| orderReference | string | Yes | Carriyo `order_id` or your own `partner_order_reference`. The value is matched against `order_id` first, then `partner_order_reference`; if neither matches, the response is 404. |
Query parameters
| Name | Type | Required | Description |
|---|---|---|---|
| create_draft_shipment | boolean | No | If true, creates draft shipments instead of immediately booking with a carrier. |
| skip_shipping | boolean | No | If true, fulfills the order without creating any shipment. |
Headers
| Name | Value | Required | Description |
|---|---|---|---|
| Authorization | Bearer YOUR-ACCESS-TOKEN | Yes | OAuth 2.0 bearer token obtained from `POST /oauth/token`. |
| x-api-key | YOUR-API-KEY | Yes | Your tenant's API key, issued in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| tenant-id | YOUR-TENANT-ID | Yes | Your Carriyo tenant ID, shown in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| Content-Type | application/json | Yes | Media type of the request body. |
Header parameters
| Name | Type | Required | Description |
|---|---|---|---|
| Idempotency-Key | string | No | Optional client-generated key that identifies one logical operation. Reuse the same key when retrying with the same payload. Replays the stored response. See [Idempotency](/api/idempotency/). |
Request body
application/jsonSchema: fulfill-order-requestResponses
order- Current status of the order: -
open- Order created, not yet allocated -partially_allocated- Some items allocated to fulfillment locations -allocated- All items allocated to fulfillment locations -on_hold- Order is held and cannot be updated or fulfilled until the hold is released -processing- One or more fulfillment orders are being processed (picked, packed, shipped or partially fulfilled) -fulfilled- All items have been fulfilled -cancelled- Order has been cancelled -closed- Order is complete and closedValues:openpartially_allocatedallocatedon_holdprocessingfulfilledcancelledclosed - Why the order or its items were cancelled:
customer_cancellation(the customer asked),auto_allocation_failed(no location could be allocated),inventory_out_of_stock,staff_error,payment_issueorother.Values:customer_cancellationauto_allocation_failedinventory_out_of_stockstaff_errorpayment_issueother
error-responseNeed the full machine-readable spec? Download the OpenAPI document →
/orders/{orderReference}/unfulfillUnfulfill entire order
Reverses every fulfillment on the order in one call, returning its items to allocated status.
Behavior
Preconditions. Neither the order nor any of its fulfillment orders may be on hold, at least one item must be fulfilled, and the order must not have come from the Mirakl Connect connector.
Scope. Fulfillment orders with nothing fulfilled are skipped, so a part fulfilled order can be taken back in one call. To reverse a single fulfillment, use the fulfillment order endpoint instead.
What happens. For every fulfillment on the order, Carriyo:
- Cancels the associated shipments, if not already cancelled. A shipment that can no longer be cancelled does not stop the call; its items still return to
allocated. - Returns the line items to
allocated. - Clears their fulfillment id, shipment ids and partner reference.
- Merges items that share the same id and status.
- Recalculates the order status.
The ORDER_UNFULFILL webhook fires once for the whole call.
Inventory. With inventory management enabled, on_hand is increased by the unfulfilled quantity; reserved is not changed and stock_reduction_timing is not consulted.
Errors
400— the order or any of its fulfillment orders is on hold.400— nothing on the order is fulfilled.400— the order came from the Mirakl Connect connector.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
| orderReference | string | Yes | Carriyo `order_id` or your own `partner_order_reference`. The value is matched against `order_id` first, then `partner_order_reference`; if neither matches, the response is 404. |
Headers
| Name | Value | Required | Description |
|---|---|---|---|
| Authorization | Bearer YOUR-ACCESS-TOKEN | Yes | OAuth 2.0 bearer token obtained from `POST /oauth/token`. |
| x-api-key | YOUR-API-KEY | Yes | Your tenant's API key, issued in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| tenant-id | YOUR-TENANT-ID | Yes | Your Carriyo tenant ID, shown in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
Header parameters
| Name | Type | Required | Description |
|---|---|---|---|
| Idempotency-Key | string | No | Optional client-generated key that identifies one logical operation. Reuse the same key when retrying with the same payload. Replays the stored response. See [Idempotency](/api/idempotency/). |
Responses
order- Current status of the order: -
open- Order created, not yet allocated -partially_allocated- Some items allocated to fulfillment locations -allocated- All items allocated to fulfillment locations -on_hold- Order is held and cannot be updated or fulfilled until the hold is released -processing- One or more fulfillment orders are being processed (picked, packed, shipped or partially fulfilled) -fulfilled- All items have been fulfilled -cancelled- Order has been cancelled -closed- Order is complete and closedValues:openpartially_allocatedallocatedon_holdprocessingfulfilledcancelledclosed - Why the order or its items were cancelled:
customer_cancellation(the customer asked),auto_allocation_failed(no location could be allocated),inventory_out_of_stock,staff_error,payment_issueorother.Values:customer_cancellationauto_allocation_failedinventory_out_of_stockstaff_errorpayment_issueother
error-responseNeed the full machine-readable spec? Download the OpenAPI document →
/orders/bulk/importBulk import orders
Creates or updates several orders in one request; each row is processed independently.
Behavior
Per row.
- A row whose
partner_order_referenceis new creates an order. A create behaves exactly as Create order, including allocation, reservation and theORDER_CREATEwebhook. - A row matching an existing order updates it when the order is
open,partially_allocatedorallocated; any other status rejects the row. An update behaves exactly as Update order, including theORDER_UPDATEwebhook. - Rows that share a
partner_order_referencewithin the same request are all rejected.
Processing continues past failed rows.
Limits. The request takes up to 20 orders by default. The limit is configurable per tenant, so chunk larger imports client-side.
Result per row. The response has one entry per row. A rejected row carries the error in reason and no order.
Errors
400— the request body is malformed.400— the request exceeds the row limit.
Headers
| Name | Value | Required | Description |
|---|---|---|---|
| Authorization | Bearer YOUR-ACCESS-TOKEN | Yes | OAuth 2.0 bearer token obtained from `POST /oauth/token`. |
| x-api-key | YOUR-API-KEY | Yes | Your tenant's API key, issued in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| tenant-id | YOUR-TENANT-ID | Yes | Your Carriyo tenant ID, shown in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| Content-Type | application/json | Yes | Media type of the request body. |
Header parameters
| Name | Type | Required | Description |
|---|---|---|---|
| Idempotency-Key | string | No | Optional client-generated key that identifies one logical operation. Reuse the same key when retrying with the same payload. Replays the stored response. See [Idempotency](/api/idempotency/). |
Request body
application/jsonSchema: bulk-order-import-requestrequiredResponses
An array of bulk-order-import-response. Each item has the following fields:
Need the full machine-readable spec? Download the OpenAPI document →
Fulfillment Orders
A group of line items from one order fulfilled from one location with one delivery method. Every operation here except merge takes the order reference followed by the fulfillment order reference.
Related: How fulfillment orders, shipments and collections relate
15 operations · 0 objects
/orders/{orderReference}/fulfillment-orders/{fulfillmentOrderReference}/fulfillFulfill fulfillment order
Marks the items of a fulfillment order as fulfilled and creates a shipment for them.
Behavior
Preconditions. Neither the fulfillment order nor its order may be on hold, and every named item must be pending. Pending covers open, allocated, pick_in_progress, picked and pack_in_progress.
Items in a pick or pack. A pick_in_progress or pack_in_progress item can be fulfilled, but the pick or pack that holds it stays open. Completing that pick later skips the item, and completing that pack fails with 400 and leaves the pack completed.
What to send
line_items names the items by id, each with a quantity no greater than the quantity still pending. Omit it, or send no body, to fulfill every pending item at its full quantity, including items in a pick or pack. To fulfill every pending item across the whole order, use the order endpoint instead.
The items are marked fulfilled under a new fulfillment id, the order status is recalculated and the FULFILLMENT_ORDER_FULFILL webhook fires.
Shipments
When the fulfillment order requires shipping, its items become one shipment, created and confirmed with the carrier. Two query parameters change that:
create_draft_shipment=trueleaves it as a draft for review before booking.skip_shipping=truefulfills without creating a shipment at all.
If the shipment cannot be created, the fulfillment order is still fulfilled and records shipment_creation_failed in its error_details; retry it with the ship endpoint. If the carrier booking fails, the shipment is left in error with the reason in its own error_details; fix the cause and reprocess the shipment.
When items close
A fulfillment order requires shipping when its delivery method is DELIVERY, or COLLECTION from a location other than the one fulfilling it. Items close automatically only when it does not require shipping and the order did not come from Shopify. With skip_shipping=true on one that does require shipping, the items stay fulfilled for you to close yourself.
Payment split
There is no split: the shipment carries the full order payment, both the order total and the amount to collect on delivery. Only the order endpoint distributes payment across shipments.
Inventory
With inventory management enabled and stock_reduction_timing set to ON_ORDER_FULFILLED, on_hand and reserved are reduced by the fulfilled quantity.
Errors
400—line_itemsis empty.400—line_itemsis omitted and nothing on the fulfillment order is pending.400— an item is not in a pending status.400— a quantity exceeds what is pending.400— the fulfillment order or its order is on hold.
Related: What fulfilling produces
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
| orderReference | string | Yes | Carriyo `order_id` or your own `partner_order_reference`. The value is matched against `order_id` first, then `partner_order_reference`; if neither matches, the response is 404. |
| fulfillmentOrderReference | string | Yes | Carriyo `fulfillment_order_id` or your own `partner_fulfillment_order_reference`. The value is matched against `fulfillment_order_id` first, then `partner_fulfillment_order_reference`. A partner reference shared by more than one fulfillment order on the order returns 400. A value matching neither returns 404. |
Query parameters
| Name | Type | Required | Description |
|---|---|---|---|
| create_draft_shipment | boolean | No | If true, creates a draft shipment instead of immediately booking with a carrier. |
| skip_shipping | boolean | No | If true, fulfills the order without creating a shipment. |
Headers
| Name | Value | Required | Description |
|---|---|---|---|
| Authorization | Bearer YOUR-ACCESS-TOKEN | Yes | OAuth 2.0 bearer token obtained from `POST /oauth/token`. |
| x-api-key | YOUR-API-KEY | Yes | Your tenant's API key, issued in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| tenant-id | YOUR-TENANT-ID | Yes | Your Carriyo tenant ID, shown in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| Content-Type | application/json | Yes | Media type of the request body. |
Header parameters
| Name | Type | Required | Description |
|---|---|---|---|
| Idempotency-Key | string | No | Optional client-generated key that identifies one logical operation. Reuse the same key when retrying with the same payload. Replays the stored response. See [Idempotency](/api/idempotency/). |
Request body
application/jsonSchema: create-fulfillment-requestResponses
order- Current status of the order: -
open- Order created, not yet allocated -partially_allocated- Some items allocated to fulfillment locations -allocated- All items allocated to fulfillment locations -on_hold- Order is held and cannot be updated or fulfilled until the hold is released -processing- One or more fulfillment orders are being processed (picked, packed, shipped or partially fulfilled) -fulfilled- All items have been fulfilled -cancelled- Order has been cancelled -closed- Order is complete and closedValues:openpartially_allocatedallocatedon_holdprocessingfulfilledcancelledclosed - Why the order or its items were cancelled:
customer_cancellation(the customer asked),auto_allocation_failed(no location could be allocated),inventory_out_of_stock,staff_error,payment_issueorother.Values:customer_cancellationauto_allocation_failedinventory_out_of_stockstaff_errorpayment_issueother
error-responseNeed the full machine-readable spec? Download the OpenAPI document →
/orders/{orderReference}/fulfillment-orders/{fulfillmentOrderReference}/unfulfillUnfulfill fulfillment order
Reverses selected fulfillments on a fulfillment order, returning their items to allocated status.
Behavior
Preconditions. Neither the fulfillment order nor its order may be on hold, and the order must not have come from the Mirakl Connect connector.
What to send. fulfillment_ids lists the fulfillments to reverse. Each must belong to the fulfillment order. To reverse every fulfillment on the order, use the order endpoint instead.
What happens. For each fulfillment, Carriyo:
- Cancels the associated shipments, if not already cancelled. A shipment that can no longer be cancelled does not stop the call; its items still return to
allocated. - Returns the line items to
allocated. - Clears their fulfillment id, shipment ids and partner reference.
- Merges items that share the same id and status.
- Recalculates the order status.
The FULFILLMENT_ORDER_UNFULFILL webhook fires once for the whole call.
Inventory. With inventory management enabled, on_hand is increased by the unfulfilled quantity; reserved is not changed and stock_reduction_timing is not consulted.
Errors
400— a fulfillment id does not exist on the fulfillment order.400— the fulfillment order or its order is on hold.400— the order came from the Mirakl Connect connector.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
| orderReference | string | Yes | Carriyo `order_id` or your own `partner_order_reference`. The value is matched against `order_id` first, then `partner_order_reference`; if neither matches, the response is 404. |
| fulfillmentOrderReference | string | Yes | Carriyo `fulfillment_order_id` or your own `partner_fulfillment_order_reference`. The value is matched against `fulfillment_order_id` first, then `partner_fulfillment_order_reference`. A partner reference shared by more than one fulfillment order on the order returns 400. A value matching neither returns 404. |
Headers
| Name | Value | Required | Description |
|---|---|---|---|
| Authorization | Bearer YOUR-ACCESS-TOKEN | Yes | OAuth 2.0 bearer token obtained from `POST /oauth/token`. |
| x-api-key | YOUR-API-KEY | Yes | Your tenant's API key, issued in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| tenant-id | YOUR-TENANT-ID | Yes | Your Carriyo tenant ID, shown in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| Content-Type | application/json | Yes | Media type of the request body. |
Header parameters
| Name | Type | Required | Description |
|---|---|---|---|
| Idempotency-Key | string | No | Optional client-generated key that identifies one logical operation. Reuse the same key when retrying with the same payload. Replays the stored response. See [Idempotency](/api/idempotency/). |
Request body
application/jsonSchema: unfulfill-fulfillment-requestrequiredResponses
order- Current status of the order: -
open- Order created, not yet allocated -partially_allocated- Some items allocated to fulfillment locations -allocated- All items allocated to fulfillment locations -on_hold- Order is held and cannot be updated or fulfilled until the hold is released -processing- One or more fulfillment orders are being processed (picked, packed, shipped or partially fulfilled) -fulfilled- All items have been fulfilled -cancelled- Order has been cancelled -closed- Order is complete and closedValues:openpartially_allocatedallocatedon_holdprocessingfulfilledcancelledclosed - Why the order or its items were cancelled:
customer_cancellation(the customer asked),auto_allocation_failed(no location could be allocated),inventory_out_of_stock,staff_error,payment_issueorother.Values:customer_cancellationauto_allocation_failedinventory_out_of_stockstaff_errorpayment_issueother
error-responseNeed the full machine-readable spec? Download the OpenAPI document →
/orders/{orderReference}/fulfillment-orders/mergeMerge fulfillment orders
Moves line items from one fulfillment order into another.
Behavior
Preconditions.
- Neither fulfillment order may contain fulfilled items or have active picks.
- Neither fulfillment order nor the order may be on hold.
- Both must share the same
fulfillment_location,delivery_type, delivery method anddelivery_option.
What to send.
sourcenames the fulfillment order and, inline_items, the items and quantities to move; a partial quantity moves and the source keeps the remainder.destinationnames the fulfillment order to receive them.
What happens.
- A moved item merges into a matching destination item, or is added as
allocatedoropendepending on whether the destination has a location. - If every item leaves the source, the source fulfillment order is removed.
- The order status is recalculated and the
FULFILLMENT_ORDER_MERGEwebhook fires.
Inventory. Inventory is unchanged; items are only moved between fulfillment orders.
Errors
400— the source or destination contains fulfilled items.400— the source or destination has active picks.400— the source or destination, or the order, is on hold.400— the two differ infulfillment_location,delivery_type, delivery method ordelivery_option.
Related: Splits and merges
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
| orderReference | string | Yes | Carriyo `order_id` or your own `partner_order_reference`. The value is matched against `order_id` first, then `partner_order_reference`; if neither matches, the response is 404. |
Headers
| Name | Value | Required | Description |
|---|---|---|---|
| Authorization | Bearer YOUR-ACCESS-TOKEN | Yes | OAuth 2.0 bearer token obtained from `POST /oauth/token`. |
| x-api-key | YOUR-API-KEY | Yes | Your tenant's API key, issued in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| tenant-id | YOUR-TENANT-ID | Yes | Your Carriyo tenant ID, shown in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| Content-Type | application/json | Yes | Media type of the request body. |
Header parameters
| Name | Type | Required | Description |
|---|---|---|---|
| Idempotency-Key | string | No | Optional client-generated key that identifies one logical operation. Reuse the same key when retrying with the same payload. Replays the stored response. See [Idempotency](/api/idempotency/). |
Request body
application/jsonSchema: merge-fulfillment-order-requestrequiredResponses
order- Current status of the order: -
open- Order created, not yet allocated -partially_allocated- Some items allocated to fulfillment locations -allocated- All items allocated to fulfillment locations -on_hold- Order is held and cannot be updated or fulfilled until the hold is released -processing- One or more fulfillment orders are being processed (picked, packed, shipped or partially fulfilled) -fulfilled- All items have been fulfilled -cancelled- Order has been cancelled -closed- Order is complete and closedValues:openpartially_allocatedallocatedon_holdprocessingfulfilledcancelledclosed - Why the order or its items were cancelled:
customer_cancellation(the customer asked),auto_allocation_failed(no location could be allocated),inventory_out_of_stock,staff_error,payment_issueorother.Values:customer_cancellationauto_allocation_failedinventory_out_of_stockstaff_errorpayment_issueother
error-responseNeed the full machine-readable spec? Download the OpenAPI document →
/orders/{orderReference}/fulfillment-orders/{fulfillmentOrderReference}/splitSplit fulfillment order
Moves selected line items from a fulfillment order into a new fulfillment order.
Behavior
Preconditions. Neither the fulfillment order nor its order may be on hold, and the fulfillment order must have no active picks. Only items in open or allocated status qualify.
What to send. line_items names the items and quantities to move.
fulfillment_location, by partner location id or code, orlocation_idsets the new fulfillment order's location. Omitted, the new fulfillment order takes the original's location.partner_fulfillment_order_referencesets your reference on the new fulfillment order. Send one: when you omit it the source's reference is copied, and a reference shared by two fulfillment orders can no longer address either.
What happens.
- The new fulfillment order gets its own
fulfillment_order_idand inherits the delivery details of the original. - Moved items are
allocatedwhen a location is set andopenotherwise. - The original's quantities are reduced, and items whose quantity reaches zero are removed.
- The order status is recalculated and the
FULFILLMENT_ORDER_SPLITwebhook fires.
Inventory. With inventory management enabled and a different location supplied, reservations for the moved items move to the new location.
Errors
400— an item isfulfilled,cancelledorclosed.400— a quantity exceeds what the item has.400— the fulfillment order or its order is on hold.400— the fulfillment order has active picks.
Related: Splits and merges
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
| orderReference | string | Yes | Carriyo `order_id` or your own `partner_order_reference`. The value is matched against `order_id` first, then `partner_order_reference`; if neither matches, the response is 404. |
| fulfillmentOrderReference | string | Yes | Carriyo `fulfillment_order_id` or your own `partner_fulfillment_order_reference`. The value is matched against `fulfillment_order_id` first, then `partner_fulfillment_order_reference`. A partner reference shared by more than one fulfillment order on the order returns 400. A value matching neither returns 404. |
Headers
| Name | Value | Required | Description |
|---|---|---|---|
| Authorization | Bearer YOUR-ACCESS-TOKEN | Yes | OAuth 2.0 bearer token obtained from `POST /oauth/token`. |
| x-api-key | YOUR-API-KEY | Yes | Your tenant's API key, issued in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| tenant-id | YOUR-TENANT-ID | Yes | Your Carriyo tenant ID, shown in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| Content-Type | application/json | Yes | Media type of the request body. |
Header parameters
| Name | Type | Required | Description |
|---|---|---|---|
| Idempotency-Key | string | No | Optional client-generated key that identifies one logical operation. Reuse the same key when retrying with the same payload. Replays the stored response. See [Idempotency](/api/idempotency/). |
Request body
application/jsonSchema: split-fulfillment-requestrequiredResponses
order- Current status of the order: -
open- Order created, not yet allocated -partially_allocated- Some items allocated to fulfillment locations -allocated- All items allocated to fulfillment locations -on_hold- Order is held and cannot be updated or fulfilled until the hold is released -processing- One or more fulfillment orders are being processed (picked, packed, shipped or partially fulfilled) -fulfilled- All items have been fulfilled -cancelled- Order has been cancelled -closed- Order is complete and closedValues:openpartially_allocatedallocatedon_holdprocessingfulfilledcancelledclosed - Why the order or its items were cancelled:
customer_cancellation(the customer asked),auto_allocation_failed(no location could be allocated),inventory_out_of_stock,staff_error,payment_issueorother.Values:customer_cancellationauto_allocation_failedinventory_out_of_stockstaff_errorpayment_issueother
error-responseNeed the full machine-readable spec? Download the OpenAPI document →
/orders/{orderReference}/fulfillment-orders/{fulfillmentOrderReference}/shipShip fulfillment order
Creates a shipment for selected items of a fulfillment order.
Behavior
Preconditions. Neither the fulfillment order nor its order may be on hold, and the fulfillment order must have a delivery or collection address. Items must be allocated, pick_in_progress, picked, pack_in_progress or fulfilled.
What to send. line_items names the items and quantities to ship; their status does not change. The body takes the same fields as Create shipment; omit the carrier account to let automation rules choose.
What happens.
- Carriyo creates the shipment.
- It confirms the shipment with the carrier, unless
create_draft_shipment=trueleaves it as a draft for review before booking. - The shipment id is linked to the items.
- The
FULFILLMENT_ORDER_SHIP_LINE_ITEMSwebhook fires.
If the carrier booking fails, the shipment is left in error with the reason in its error_details; fix the cause and reprocess the shipment.
Inventory. Inventory is unchanged; it moves on fulfill and cancel.
Errors
400— an item isopen,cancelledorclosed.400— a quantity exceeds what is available.400— the fulfillment order has no delivery or collection address.400— the fulfillment order or its order is on hold.
Related: What fulfilling produces
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
| orderReference | string | Yes | Carriyo `order_id` or your own `partner_order_reference`. The value is matched against `order_id` first, then `partner_order_reference`; if neither matches, the response is 404. |
| fulfillmentOrderReference | string | Yes | Carriyo `fulfillment_order_id` or your own `partner_fulfillment_order_reference`. The value is matched against `fulfillment_order_id` first, then `partner_fulfillment_order_reference`. A partner reference shared by more than one fulfillment order on the order returns 400. A value matching neither returns 404. |
Query parameters
| Name | Type | Required | Description |
|---|---|---|---|
| create_draft_shipment | boolean | No | If true, creates a draft shipment instead of immediately booking with a carrier. |
Headers
| Name | Value | Required | Description |
|---|---|---|---|
| Authorization | Bearer YOUR-ACCESS-TOKEN | Yes | OAuth 2.0 bearer token obtained from `POST /oauth/token`. |
| x-api-key | YOUR-API-KEY | Yes | Your tenant's API key, issued in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| tenant-id | YOUR-TENANT-ID | Yes | Your Carriyo tenant ID, shown in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| Content-Type | application/json | Yes | Media type of the request body. |
Header parameters
| Name | Type | Required | Description |
|---|---|---|---|
| Idempotency-Key | string | No | Optional client-generated key that identifies one logical operation. Reuse the same key when retrying with the same payload. Replays the stored response. See [Idempotency](/api/idempotency/). |
Request body
application/jsonSchema: ship-fo-line-items-requestResponses
order- Current status of the order: -
open- Order created, not yet allocated -partially_allocated- Some items allocated to fulfillment locations -allocated- All items allocated to fulfillment locations -on_hold- Order is held and cannot be updated or fulfilled until the hold is released -processing- One or more fulfillment orders are being processed (picked, packed, shipped or partially fulfilled) -fulfilled- All items have been fulfilled -cancelled- Order has been cancelled -closed- Order is complete and closedValues:openpartially_allocatedallocatedon_holdprocessingfulfilledcancelledclosed - Why the order or its items were cancelled:
customer_cancellation(the customer asked),auto_allocation_failed(no location could be allocated),inventory_out_of_stock,staff_error,payment_issueorother.Values:customer_cancellationauto_allocation_failedinventory_out_of_stockstaff_errorpayment_issueother
error-responseNeed the full machine-readable spec? Download the OpenAPI document →
/orders/{orderReference}/fulfillment-orders/{fulfillmentOrderReference}/update-locationUpdate fulfillment order location
Reassigns a fulfillment order to a different location.
Behavior
Preconditions. Neither the fulfillment order nor its order may be on hold, and the fulfillment order must have no active picks.
What to send. fulfillment_location identifies the new location by partner_location_id or partner_location_code, resolved in that order. location_id is accepted as a flat alternative. Omit both to remove the current assignment.
What happens.
- Assigning a location: the fulfillment order's location is replaced,
openitems becomeallocated, and any earlier allocation failure is cleared. - Removing it:
allocateditems becomeopenandfulfillment_location_missingis recorded inerror_details. - The order status is recalculated and the
FULFILLMENT_ORDER_UPDATE_LOCATIONwebhook fires.
Inventory. With inventory management enabled, reservations are released at the old location and taken at the new one. Stock at the new location is not checked; the reservation is taken regardless.
Errors
400— the fulfillment order has active picks.400— the fulfillment order or its order is on hold.400— no location is assigned and none is supplied.404— the location cannot be resolved.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
| orderReference | string | Yes | Carriyo `order_id` or your own `partner_order_reference`. The value is matched against `order_id` first, then `partner_order_reference`; if neither matches, the response is 404. |
| fulfillmentOrderReference | string | Yes | Carriyo `fulfillment_order_id` or your own `partner_fulfillment_order_reference`. The value is matched against `fulfillment_order_id` first, then `partner_fulfillment_order_reference`. A partner reference shared by more than one fulfillment order on the order returns 400. A value matching neither returns 404. |
Headers
| Name | Value | Required | Description |
|---|---|---|---|
| Authorization | Bearer YOUR-ACCESS-TOKEN | Yes | OAuth 2.0 bearer token obtained from `POST /oauth/token`. |
| x-api-key | YOUR-API-KEY | Yes | Your tenant's API key, issued in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| tenant-id | YOUR-TENANT-ID | Yes | Your Carriyo tenant ID, shown in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| Content-Type | application/json | Yes | Media type of the request body. |
Header parameters
| Name | Type | Required | Description |
|---|---|---|---|
| Idempotency-Key | string | No | Optional client-generated key that identifies one logical operation. Reuse the same key when retrying with the same payload. Replays the stored response. See [Idempotency](/api/idempotency/). |
Request body
application/jsonSchema: update-location-requestrequiredResponses
order- Current status of the order: -
open- Order created, not yet allocated -partially_allocated- Some items allocated to fulfillment locations -allocated- All items allocated to fulfillment locations -on_hold- Order is held and cannot be updated or fulfilled until the hold is released -processing- One or more fulfillment orders are being processed (picked, packed, shipped or partially fulfilled) -fulfilled- All items have been fulfilled -cancelled- Order has been cancelled -closed- Order is complete and closedValues:openpartially_allocatedallocatedon_holdprocessingfulfilledcancelledclosed - Why the order or its items were cancelled:
customer_cancellation(the customer asked),auto_allocation_failed(no location could be allocated),inventory_out_of_stock,staff_error,payment_issueorother.Values:customer_cancellationauto_allocation_failedinventory_out_of_stockstaff_errorpayment_issueother
error-responseNeed the full machine-readable spec? Download the OpenAPI document →
/orders/{orderReference}/fulfillment-orders/{fulfillmentOrderReference}/update-delivery-methodUpdate fulfillment order delivery method
Switches a fulfillment order between DELIVERY, COLLECTION and DIGITAL, setting the matching address and schedule in one call.
Behavior
Preconditions. The order must be open, partially_allocated or allocated, and neither it nor the fulfillment order may be on hold. delivery_method is required.
What each method sets. The body's address, scheduled_from, scheduled_to and delivery_option are stored according to the new delivery_method:
DELIVERY—addressbecomesdelivery_address;scheduled_fromandscheduled_tobecomedelivery_schedule;delivery_optionis applied. The collection address and schedule are cleared.COLLECTION—addressbecomescustomer_collection_address;scheduled_fromandscheduled_tobecomecustomer_collection_schedule. The delivery address, delivery schedule anddelivery_optionare cleared.DIGITAL— the address and schedule are left as they are anddelivery_optionis cleared.
Whichever method you set, delivery_type is taken from the body, so omitting it clears the existing value.
What happens. The fulfillment order is updated and the FULFILLMENT_ORDER_UPDATE_DELIVERY_METHOD webhook fires.
Errors
400— the order is notopen,partially_allocatedorallocated.400— the fulfillment order or its order is on hold.400—delivery_methodis missing.400—delivery_optiondoes not exist.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
| orderReference | string | Yes | Carriyo `order_id` or your own `partner_order_reference`. The value is matched against `order_id` first, then `partner_order_reference`; if neither matches, the response is 404. |
| fulfillmentOrderReference | string | Yes | Carriyo `fulfillment_order_id` or your own `partner_fulfillment_order_reference`. The value is matched against `fulfillment_order_id` first, then `partner_fulfillment_order_reference`. A partner reference shared by more than one fulfillment order on the order returns 400. A value matching neither returns 404. |
Headers
| Name | Value | Required | Description |
|---|---|---|---|
| Authorization | Bearer YOUR-ACCESS-TOKEN | Yes | OAuth 2.0 bearer token obtained from `POST /oauth/token`. |
| x-api-key | YOUR-API-KEY | Yes | Your tenant's API key, issued in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| tenant-id | YOUR-TENANT-ID | Yes | Your Carriyo tenant ID, shown in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| Content-Type | application/json | Yes | Media type of the request body. |
Header parameters
| Name | Type | Required | Description |
|---|---|---|---|
| Idempotency-Key | string | No | Optional client-generated key that identifies one logical operation. Reuse the same key when retrying with the same payload. Replays the stored response. See [Idempotency](/api/idempotency/). |
Request body
application/jsonSchema: update-fulfillment-order-delivery-method-requestrequired- How the order is delivered to the customer: -
DELIVERY: standard delivery to the customer's address (usesdelivery_addressanddelivery_schedule). -COLLECTION: customer collects the order from a specified location (usescustomer_collection_addressandcustomer_collection_schedule). -DIGITAL: no physical delivery; the order is fulfilled digitally.Values:DELIVERYCOLLECTIONDIGITAL
Responses
order- Current status of the order: -
open- Order created, not yet allocated -partially_allocated- Some items allocated to fulfillment locations -allocated- All items allocated to fulfillment locations -on_hold- Order is held and cannot be updated or fulfilled until the hold is released -processing- One or more fulfillment orders are being processed (picked, packed, shipped or partially fulfilled) -fulfilled- All items have been fulfilled -cancelled- Order has been cancelled -closed- Order is complete and closedValues:openpartially_allocatedallocatedon_holdprocessingfulfilledcancelledclosed - Why the order or its items were cancelled:
customer_cancellation(the customer asked),auto_allocation_failed(no location could be allocated),inventory_out_of_stock,staff_error,payment_issueorother.Values:customer_cancellationauto_allocation_failedinventory_out_of_stockstaff_errorpayment_issueother
error-responseNeed the full machine-readable spec? Download the OpenAPI document →
/orders/{orderReference}/fulfillment-orders/{fulfillmentOrderReference}/update-addressUpdate fulfillment order address
Replaces the address on a fulfillment order according to its current delivery_method.
Behavior
Preconditions. The fulfillment order must be open or allocated, and neither it nor its order may be on hold. address is required.
What happens.
DELIVERYandDIGITAL:addressreplacesdelivery_address.COLLECTION:addressreplacescustomer_collection_address.- Allocation is not re-run and reservations are unchanged, even when the new address is outside the current location's coverage; use Allocate fulfillment order if the new address needs a different location.
- The
FULFILLMENT_ORDER_UPDATE_ADDRESSwebhook fires.
To change the method itself, use the delivery-method endpoint first.
Errors
400—addressis missing.400— the fulfillment order is notopenorallocated.400— the fulfillment order or its order is on hold.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
| orderReference | string | Yes | Carriyo `order_id` or your own `partner_order_reference`. The value is matched against `order_id` first, then `partner_order_reference`; if neither matches, the response is 404. |
| fulfillmentOrderReference | string | Yes | Carriyo `fulfillment_order_id` or your own `partner_fulfillment_order_reference`. The value is matched against `fulfillment_order_id` first, then `partner_fulfillment_order_reference`. A partner reference shared by more than one fulfillment order on the order returns 400. A value matching neither returns 404. |
Headers
| Name | Value | Required | Description |
|---|---|---|---|
| Authorization | Bearer YOUR-ACCESS-TOKEN | Yes | OAuth 2.0 bearer token obtained from `POST /oauth/token`. |
| x-api-key | YOUR-API-KEY | Yes | Your tenant's API key, issued in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| tenant-id | YOUR-TENANT-ID | Yes | Your Carriyo tenant ID, shown in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| Content-Type | application/json | Yes | Media type of the request body. |
Header parameters
| Name | Type | Required | Description |
|---|---|---|---|
| Idempotency-Key | string | No | Optional client-generated key that identifies one logical operation. Reuse the same key when retrying with the same payload. Replays the stored response. See [Idempotency](/api/idempotency/). |
Request body
application/jsonSchema: update-fulfillment-order-address-requestrequiredResponses
order- Current status of the order: -
open- Order created, not yet allocated -partially_allocated- Some items allocated to fulfillment locations -allocated- All items allocated to fulfillment locations -on_hold- Order is held and cannot be updated or fulfilled until the hold is released -processing- One or more fulfillment orders are being processed (picked, packed, shipped or partially fulfilled) -fulfilled- All items have been fulfilled -cancelled- Order has been cancelled -closed- Order is complete and closedValues:openpartially_allocatedallocatedon_holdprocessingfulfilledcancelledclosed - Why the order or its items were cancelled:
customer_cancellation(the customer asked),auto_allocation_failed(no location could be allocated),inventory_out_of_stock,staff_error,payment_issueorother.Values:customer_cancellationauto_allocation_failedinventory_out_of_stockstaff_errorpayment_issueother
error-responseNeed the full machine-readable spec? Download the OpenAPI document →
/orders/{orderReference}/fulfillment-orders/{fulfillmentOrderReference}/update-scheduleUpdate fulfillment order schedule
Replaces the delivery or collection window of a fulfillment order with the supplied scheduled_from and scheduled_to.
Behavior
Preconditions. Neither the fulfillment order nor its order may be on hold. There is no status precondition.
What happens. The window is replaced and the FULFILLMENT_ORDER_UPDATE_SCHEDULE webhook fires.
Errors
400— the fulfillment order or its order is on hold.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
| orderReference | string | Yes | Carriyo `order_id` or your own `partner_order_reference`. The value is matched against `order_id` first, then `partner_order_reference`; if neither matches, the response is 404. |
| fulfillmentOrderReference | string | Yes | Carriyo `fulfillment_order_id` or your own `partner_fulfillment_order_reference`. The value is matched against `fulfillment_order_id` first, then `partner_fulfillment_order_reference`. A partner reference shared by more than one fulfillment order on the order returns 400. A value matching neither returns 404. |
Headers
| Name | Value | Required | Description |
|---|---|---|---|
| Authorization | Bearer YOUR-ACCESS-TOKEN | Yes | OAuth 2.0 bearer token obtained from `POST /oauth/token`. |
| x-api-key | YOUR-API-KEY | Yes | Your tenant's API key, issued in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| tenant-id | YOUR-TENANT-ID | Yes | Your Carriyo tenant ID, shown in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| Content-Type | application/json | Yes | Media type of the request body. |
Header parameters
| Name | Type | Required | Description |
|---|---|---|---|
| Idempotency-Key | string | No | Optional client-generated key that identifies one logical operation. Reuse the same key when retrying with the same payload. Replays the stored response. See [Idempotency](/api/idempotency/). |
Request body
application/jsonSchema: update-fulfillment-order-schedule-requestrequiredResponses
order- Current status of the order: -
open- Order created, not yet allocated -partially_allocated- Some items allocated to fulfillment locations -allocated- All items allocated to fulfillment locations -on_hold- Order is held and cannot be updated or fulfilled until the hold is released -processing- One or more fulfillment orders are being processed (picked, packed, shipped or partially fulfilled) -fulfilled- All items have been fulfilled -cancelled- Order has been cancelled -closed- Order is complete and closedValues:openpartially_allocatedallocatedon_holdprocessingfulfilledcancelledclosed - Why the order or its items were cancelled:
customer_cancellation(the customer asked),auto_allocation_failed(no location could be allocated),inventory_out_of_stock,staff_error,payment_issueorother.Values:customer_cancellationauto_allocation_failedinventory_out_of_stockstaff_errorpayment_issueother
error-responseNeed the full machine-readable spec? Download the OpenAPI document →
/orders/{orderReference}/fulfillment-orders/{fulfillmentOrderReference}/update-partner-referencesUpdate fulfillment order partner references
Sets your references on a fulfillment order or on its individual fulfillments.
Behavior
Preconditions. Neither the fulfillment order nor its order may be on hold, and the fulfillment order must have no active picks.
What to send. Send one of:
partner_fulfillment_order_reference, your reference for the fulfillment order.fulfillments, a list offulfillment_idandpartner_fulfillment_referencepairs that set references on already fulfilled items.
When both are present only partner_fulfillment_order_reference is applied.
What happens. Nothing else on the fulfillment order changes. The FULFILLMENT_ORDER_UPDATE_PARTNER_FULFILLMENT_ORDER_REFERENCE webhook fires when the fulfillment order reference changed, and the FULFILLMENT_ORDER_UPDATE_PARTNER_FULFILLMENT_REFERENCES webhook when fulfillment references changed.
Errors
400— the fulfillment order has active picks.400— the fulfillment order or its order is on hold.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
| orderReference | string | Yes | Carriyo `order_id` or your own `partner_order_reference`. The value is matched against `order_id` first, then `partner_order_reference`; if neither matches, the response is 404. |
| fulfillmentOrderReference | string | Yes | Carriyo `fulfillment_order_id` or your own `partner_fulfillment_order_reference`. The value is matched against `fulfillment_order_id` first, then `partner_fulfillment_order_reference`. A partner reference shared by more than one fulfillment order on the order returns 400. A value matching neither returns 404. |
Headers
| Name | Value | Required | Description |
|---|---|---|---|
| Authorization | Bearer YOUR-ACCESS-TOKEN | Yes | OAuth 2.0 bearer token obtained from `POST /oauth/token`. |
| x-api-key | YOUR-API-KEY | Yes | Your tenant's API key, issued in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| tenant-id | YOUR-TENANT-ID | Yes | Your Carriyo tenant ID, shown in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| Content-Type | application/json | Yes | Media type of the request body. |
Header parameters
| Name | Type | Required | Description |
|---|---|---|---|
| Idempotency-Key | string | No | Optional client-generated key that identifies one logical operation. Reuse the same key when retrying with the same payload. Replays the stored response. See [Idempotency](/api/idempotency/). |
Request body
application/jsonSchema: update-fulfillment-order-partner-references-requestrequiredResponses
order- Current status of the order: -
open- Order created, not yet allocated -partially_allocated- Some items allocated to fulfillment locations -allocated- All items allocated to fulfillment locations -on_hold- Order is held and cannot be updated or fulfilled until the hold is released -processing- One or more fulfillment orders are being processed (picked, packed, shipped or partially fulfilled) -fulfilled- All items have been fulfilled -cancelled- Order has been cancelled -closed- Order is complete and closedValues:openpartially_allocatedallocatedon_holdprocessingfulfilledcancelledclosed - Why the order or its items were cancelled:
customer_cancellation(the customer asked),auto_allocation_failed(no location could be allocated),inventory_out_of_stock,staff_error,payment_issueorother.Values:customer_cancellationauto_allocation_failedinventory_out_of_stockstaff_errorpayment_issueother
error-responseNeed the full machine-readable spec? Download the OpenAPI document →
/orders/{orderReference}/fulfillment-orders/{fulfillmentOrderReference}/cancelCancel fulfillment order line items
Cancels selected line items of a fulfillment order.
Behavior
Preconditions. Only items in open or allocated status qualify; unfulfill a fulfilled item first. Cancellation is allowed while the fulfillment order or its order is on hold.
What to send. line_items names the items and quantities to cancel, and cancellation_reason is recorded on each.
What happens.
- Each cancelled item's status becomes
cancelledwith the reason. - The fulfillment order's picks are cancelled when nothing is left to pick.
- When every item is cancelled the fulfillment order becomes
cancelledand its hold is released. - The order status is recalculated and the
FULFILLMENT_ORDER_CANCEL_LINE_ITEMSwebhook fires.
Inventory. With inventory management enabled and a fulfillment_location set on the fulfillment order, reserved is reduced by the cancelled quantity.
Errors
400— an item isfulfilled,closedor alreadycancelled.400— a quantity exceeds what the item has.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
| orderReference | string | Yes | Carriyo `order_id` or your own `partner_order_reference`. The value is matched against `order_id` first, then `partner_order_reference`; if neither matches, the response is 404. |
| fulfillmentOrderReference | string | Yes | Carriyo `fulfillment_order_id` or your own `partner_fulfillment_order_reference`. The value is matched against `fulfillment_order_id` first, then `partner_fulfillment_order_reference`. A partner reference shared by more than one fulfillment order on the order returns 400. A value matching neither returns 404. |
Headers
| Name | Value | Required | Description |
|---|---|---|---|
| Authorization | Bearer YOUR-ACCESS-TOKEN | Yes | OAuth 2.0 bearer token obtained from `POST /oauth/token`. |
| x-api-key | YOUR-API-KEY | Yes | Your tenant's API key, issued in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| tenant-id | YOUR-TENANT-ID | Yes | Your Carriyo tenant ID, shown in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| Content-Type | application/json | Yes | Media type of the request body. |
Header parameters
| Name | Type | Required | Description |
|---|---|---|---|
| Idempotency-Key | string | No | Optional client-generated key that identifies one logical operation. Reuse the same key when retrying with the same payload. Replays the stored response. See [Idempotency](/api/idempotency/). |
Request body
application/jsonSchema: cancel-fo-line-items-request- Why the order or its items were cancelled:
customer_cancellation(the customer asked),auto_allocation_failed(no location could be allocated),inventory_out_of_stock,staff_error,payment_issueorother.Values:customer_cancellationauto_allocation_failedinventory_out_of_stockstaff_errorpayment_issueother
Responses
order- Current status of the order: -
open- Order created, not yet allocated -partially_allocated- Some items allocated to fulfillment locations -allocated- All items allocated to fulfillment locations -on_hold- Order is held and cannot be updated or fulfilled until the hold is released -processing- One or more fulfillment orders are being processed (picked, packed, shipped or partially fulfilled) -fulfilled- All items have been fulfilled -cancelled- Order has been cancelled -closed- Order is complete and closedValues:openpartially_allocatedallocatedon_holdprocessingfulfilledcancelledclosed - Why the order or its items were cancelled:
customer_cancellation(the customer asked),auto_allocation_failed(no location could be allocated),inventory_out_of_stock,staff_error,payment_issueorother.Values:customer_cancellationauto_allocation_failedinventory_out_of_stockstaff_errorpayment_issueother
error-responseNeed the full machine-readable spec? Download the OpenAPI document →
/orders/{orderReference}/fulfillment-orders/{fulfillmentOrderReference}/on-holdHold fulfillment order
Puts a single fulfillment order on hold without affecting the rest of the order.
Behavior
Preconditions. The fulfillment order must be open or allocated and not already on hold, and its order must not be on hold.
What happens.
- The fulfillment order status becomes
on_hold; the order status is unchanged. on_hold_detailsrecords the hold; an earlier hold moves intohistory.- While the hold is active, every operation on that fulfillment order except cancel and release returns
400. - The
FULFILLMENT_ORDER_ON_HOLDwebhook fires.
Errors
400— the fulfillment order is notopenorallocated.400— the fulfillment order is already on hold.400— the order is on hold.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
| orderReference | string | Yes | Carriyo `order_id` or your own `partner_order_reference`. The value is matched against `order_id` first, then `partner_order_reference`; if neither matches, the response is 400. |
| fulfillmentOrderReference | string | Yes | Carriyo `fulfillment_order_id` or your own `partner_fulfillment_order_reference`. The value is matched against `fulfillment_order_id` first, then `partner_fulfillment_order_reference`. A partner reference shared by more than one fulfillment order on the order returns 400. A value matching neither returns 400. |
Headers
| Name | Value | Required | Description |
|---|---|---|---|
| Authorization | Bearer YOUR-ACCESS-TOKEN | Yes | OAuth 2.0 bearer token obtained from `POST /oauth/token`. |
| x-api-key | YOUR-API-KEY | Yes | Your tenant's API key, issued in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| tenant-id | YOUR-TENANT-ID | Yes | Your Carriyo tenant ID, shown in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| Content-Type | application/json | Yes | Media type of the request body. |
Header parameters
| Name | Type | Required | Description |
|---|---|---|---|
| Idempotency-Key | string | No | Optional client-generated key that identifies one logical operation. Reuse the same key when retrying with the same payload. Replays the stored response. See [Idempotency](/api/idempotency/). |
Request body
application/jsonSchema: on-hold-requestResponses
order- Current status of the order: -
open- Order created, not yet allocated -partially_allocated- Some items allocated to fulfillment locations -allocated- All items allocated to fulfillment locations -on_hold- Order is held and cannot be updated or fulfilled until the hold is released -processing- One or more fulfillment orders are being processed (picked, packed, shipped or partially fulfilled) -fulfilled- All items have been fulfilled -cancelled- Order has been cancelled -closed- Order is complete and closedValues:openpartially_allocatedallocatedon_holdprocessingfulfilledcancelledclosed - Why the order or its items were cancelled:
customer_cancellation(the customer asked),auto_allocation_failed(no location could be allocated),inventory_out_of_stock,staff_error,payment_issueorother.Values:customer_cancellationauto_allocation_failedinventory_out_of_stockstaff_errorpayment_issueother
error-responseNeed the full machine-readable spec? Download the OpenAPI document →
/orders/{orderReference}/fulfillment-orders/{fulfillmentOrderReference}/release-on-holdRelease fulfillment order hold
Releases an active hold on a single fulfillment order and returns it to the status derived from its line items.
Behavior
Preconditions. The fulfillment order must be on_hold and its order must not be on hold.
What happens.
- The fulfillment order returns to
openorallocatedas derived from its line items. on_hold_detailsis kept with the release details.- The
FULFILLMENT_ORDER_RELEASE_ON_HOLDwebhook fires.
Errors
400— the fulfillment order is noton_hold.400— the order is on hold; release the order instead.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
| orderReference | string | Yes | Carriyo `order_id` or your own `partner_order_reference`. The value is matched against `order_id` first, then `partner_order_reference`; if neither matches, the response is 400. |
| fulfillmentOrderReference | string | Yes | Carriyo `fulfillment_order_id` or your own `partner_fulfillment_order_reference`. The value is matched against `fulfillment_order_id` first, then `partner_fulfillment_order_reference`. A partner reference shared by more than one fulfillment order on the order returns 400. A value matching neither returns 400. |
Headers
| Name | Value | Required | Description |
|---|---|---|---|
| Authorization | Bearer YOUR-ACCESS-TOKEN | Yes | OAuth 2.0 bearer token obtained from `POST /oauth/token`. |
| x-api-key | YOUR-API-KEY | Yes | Your tenant's API key, issued in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| tenant-id | YOUR-TENANT-ID | Yes | Your Carriyo tenant ID, shown in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| Content-Type | application/json | Yes | Media type of the request body. |
Header parameters
| Name | Type | Required | Description |
|---|---|---|---|
| Idempotency-Key | string | No | Optional client-generated key that identifies one logical operation. Reuse the same key when retrying with the same payload. Replays the stored response. See [Idempotency](/api/idempotency/). |
Request body
application/jsonSchema: release-on-hold-requestResponses
order- Current status of the order: -
open- Order created, not yet allocated -partially_allocated- Some items allocated to fulfillment locations -allocated- All items allocated to fulfillment locations -on_hold- Order is held and cannot be updated or fulfilled until the hold is released -processing- One or more fulfillment orders are being processed (picked, packed, shipped or partially fulfilled) -fulfilled- All items have been fulfilled -cancelled- Order has been cancelled -closed- Order is complete and closedValues:openpartially_allocatedallocatedon_holdprocessingfulfilledcancelledclosed - Why the order or its items were cancelled:
customer_cancellation(the customer asked),auto_allocation_failed(no location could be allocated),inventory_out_of_stock,staff_error,payment_issueorother.Values:customer_cancellationauto_allocation_failedinventory_out_of_stockstaff_errorpayment_issueother
Need the full machine-readable spec? Download the OpenAPI document →
/orders/{orderReference}/fulfillment-orders/{fulfillmentOrderReference}/allocateAllocate fulfillment order
Runs allocation for a single fulfillment order and, unless dry_run is true, applies the result to the order.
Behavior
Preconditions. The fulfillment order must be open or allocated, neither it nor its order may be on hold, and its delivery_method must not be DIGITAL.
What to send
Two body flags decide whether a result is accepted:
allow_partial_order_allocationis read from the request only; omitted, partial results are accepted.allow_order_splittingdefaults to the order management setting of the same name; a value in the request overrides it.
What comes back
The response lists the proposed fulfillment orders: one per allocated location, plus one open fulfillment order holding any items that could not be allocated. committed says whether the result was applied.
When the result is applied
With dry_run false and the result accepted, committed is true and Carriyo:
- gives the existing fulfillment order the first proposal, keeping its
fulfillment_order_id; - creates a new fulfillment order for each further proposal;
- moves inventory reservations to the allocated locations when inventory management is enabled;
- recalculates the order status.
The FULFILLMENT_ORDER_ALLOCATE webhook fires only when the result is committed.
When nothing is saved
committed is false when dry_run is true or the result is rejected. A result is rejected when:
- it contains no items;
- items remain unallocated while
allow_partial_order_allocationis false; - it spans more than one location while
allow_order_splittingis false.
Errors
400— the fulfillment order is notopenorallocated.400— the fulfillment order or its order is on hold.400— itsdelivery_methodisDIGITAL.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
| orderReference | string | Yes | Carriyo `order_id` or your own `partner_order_reference`. The value is matched against `order_id` first, then `partner_order_reference`; if neither matches, the response is 404. |
| fulfillmentOrderReference | string | Yes | Carriyo `fulfillment_order_id` or your own `partner_fulfillment_order_reference`. The value is matched against `fulfillment_order_id` first, then `partner_fulfillment_order_reference`. A partner reference shared by more than one fulfillment order on the order returns 400. A value matching neither returns 404. |
Query parameters
| Name | Type | Required | Description |
|---|---|---|---|
| dry_run | boolean | No | If true, returns the proposed allocation without saving anything. |
Headers
| Name | Value | Required | Description |
|---|---|---|---|
| Authorization | Bearer YOUR-ACCESS-TOKEN | Yes | OAuth 2.0 bearer token obtained from `POST /oauth/token`. |
| x-api-key | YOUR-API-KEY | Yes | Your tenant's API key, issued in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| tenant-id | YOUR-TENANT-ID | Yes | Your Carriyo tenant ID, shown in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| Content-Type | application/json | Yes | Media type of the request body. |
Header parameters
| Name | Type | Required | Description |
|---|---|---|---|
| Idempotency-Key | string | No | Optional client-generated key that identifies one logical operation. Reuse the same key when retrying with the same payload. Replays the stored response. See [Idempotency](/api/idempotency/). |
Request body
application/jsonSchema: allocate-fulfillment-order-requestResponses
allocation-responseerror-responseNeed the full machine-readable spec? Download the OpenAPI document →
/orders/{orderReference}/fulfillment-orders/{fulfillmentOrderReference}/available-locationsList available locations
Lists the fulfillment locations the allocation engine would evaluate for a fulfillment order, with stock availability per item. Nothing is saved.
Behavior
Locations are sorted by availability (AVAILABLE, then PARTIALLY_AVAILABLE, then UNAVAILABLE), then by how many requested items they can supply, then by location_code. current marks the location currently assigned to the fulfillment order.
Errors
400— the fulfillment order has active picks.400— the fulfillment order has no line items.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
| orderReference | string | Yes | Carriyo `order_id` or your own `partner_order_reference`. The value is matched against `order_id` first, then `partner_order_reference`; if neither matches, the response is 404. |
| fulfillmentOrderReference | string | Yes | Carriyo `fulfillment_order_id` or your own `partner_fulfillment_order_reference`. The value is matched against `fulfillment_order_id` first, then `partner_fulfillment_order_reference`. A partner reference shared by more than one fulfillment order on the order returns 400. A value matching neither returns 404. |
Headers
| Name | Value | Required | Description |
|---|---|---|---|
| Authorization | Bearer YOUR-ACCESS-TOKEN | Yes | OAuth 2.0 bearer token obtained from `POST /oauth/token`. |
| x-api-key | YOUR-API-KEY | Yes | Your tenant's API key, issued in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| tenant-id | YOUR-TENANT-ID | Yes | Your Carriyo tenant ID, shown in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
Responses
available-locations-responseerror-responseNeed the full machine-readable spec? Download the OpenAPI document →
Order Allocation Rules
Rules that decide how an order is split into fulfillment orders across your fulfillment locations, evaluated in sequence.
Related: How the allocation engine chooses locations
6 operations · 0 objects
/order-allocation-rulesCreate order allocation rule
Creates an order allocation rule.
Behavior
A new rule takes the sequence you send; nothing appends it last, and a lower sequence pre-empts existing rules because the lowest matched sequence wins. Duplicate sequences are not rejected; a duplicate name is.
Headers
| Name | Value | Required | Description |
|---|---|---|---|
| Authorization | Bearer YOUR-ACCESS-TOKEN | Yes | OAuth 2.0 bearer token obtained from `POST /oauth/token`. |
| x-api-key | YOUR-API-KEY | Yes | Your tenant's API key, issued in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| tenant-id | YOUR-TENANT-ID | Yes | Your Carriyo tenant ID, shown in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| Content-Type | application/json | Yes | Media type of the request body. |
Request body
application/jsonrequiredResponses
Need the full machine-readable spec? Download the OpenAPI document →
/order-allocation-rulesList order allocation rules
Lists the order allocation rules configured for the merchant, ordered by evaluation priority (sequence).
Headers
| Name | Value | Required | Description |
|---|---|---|---|
| Authorization | Bearer YOUR-ACCESS-TOKEN | Yes | OAuth 2.0 bearer token obtained from `POST /oauth/token`. |
| x-api-key | YOUR-API-KEY | Yes | Your tenant's API key, issued in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| tenant-id | YOUR-TENANT-ID | Yes | Your Carriyo tenant ID, shown in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
Responses
Need the full machine-readable spec? Download the OpenAPI document →
/order-allocation-rules/{rule_id}Get order allocation rule
Returns a single order allocation rule by its rule_id.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
| rule_id | string | Yes | Allocation rule ID. |
Headers
| Name | Value | Required | Description |
|---|---|---|---|
| Authorization | Bearer YOUR-ACCESS-TOKEN | Yes | OAuth 2.0 bearer token obtained from `POST /oauth/token`. |
| x-api-key | YOUR-API-KEY | Yes | Your tenant's API key, issued in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| tenant-id | YOUR-TENANT-ID | Yes | Your Carriyo tenant ID, shown in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
Responses
Need the full machine-readable spec? Download the OpenAPI document →
/order-allocation-rules/{rule_id}Update order allocation rule
Replaces an order allocation rule.
Behavior
The request body fully replaces the existing rule; fields you omit are reset to defaults. The rule's evaluation priority is managed separately with Update rule sequence.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
| rule_id | string | Yes | Allocation rule ID. |
Headers
| Name | Value | Required | Description |
|---|---|---|---|
| Authorization | Bearer YOUR-ACCESS-TOKEN | Yes | OAuth 2.0 bearer token obtained from `POST /oauth/token`. |
| x-api-key | YOUR-API-KEY | Yes | Your tenant's API key, issued in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| tenant-id | YOUR-TENANT-ID | Yes | Your Carriyo tenant ID, shown in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| Content-Type | application/json | Yes | Media type of the request body. |
Request body
application/jsonrequiredResponses
Need the full machine-readable spec? Download the OpenAPI document →
/order-allocation-rules/{rule_id}Delete order allocation rule
Deletes an order allocation rule.
Behavior
Orders that would have matched this rule fall through to the next matching rule in evaluation order.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
| rule_id | string | Yes | Allocation rule ID. |
Headers
| Name | Value | Required | Description |
|---|---|---|---|
| Authorization | Bearer YOUR-ACCESS-TOKEN | Yes | OAuth 2.0 bearer token obtained from `POST /oauth/token`. |
| x-api-key | YOUR-API-KEY | Yes | Your tenant's API key, issued in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| tenant-id | YOUR-TENANT-ID | Yes | Your Carriyo tenant ID, shown in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
Responses
Need the full machine-readable spec? Download the OpenAPI document →
/order-allocation-rules/sequencesUpdate rule sequence
Sets the priority order in which allocation rules are evaluated.
Behavior
Send only the rules to move; rules not in the body are untouched.
Errors
400— none of the rule ids resolve.
Headers
| Name | Value | Required | Description |
|---|---|---|---|
| Authorization | Bearer YOUR-ACCESS-TOKEN | Yes | OAuth 2.0 bearer token obtained from `POST /oauth/token`. |
| x-api-key | YOUR-API-KEY | Yes | Your tenant's API key, issued in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| tenant-id | YOUR-TENANT-ID | Yes | Your Carriyo tenant ID, shown in the Carriyo Dashboard. Required on every request except `POST /oauth/token`. |
| Content-Type | application/json | Yes | Media type of the request body. |
Request body
application/jsonrequiredResponses
Need the full machine-readable spec? Download the OpenAPI document →