Switch Suppliers
POST/api/v2/inventory-allocations/switch-suppliers
Bulk updates the supplier on one or more inventory allocations. Each assignment is validated against supplier_products so the chosen supplier must already be configured for the allocation's product. Allocations not in planned or awaiting_receipt status are skipped.
orders:writeGrant this scope to your token under Settings → Developer → Personal Access Tokens.
Body:
assignments(required, array, min 1) — List of allocation/supplier pairs to apply.assignments.*.allocation_id(required, integer, exists ininventory_allocations) — ID of the allocation to update.assignments.*.supplier_id(required, integer, exists insuppliers) — ID of the supplier to assign.
Behavior:
- Assignments where the new supplier matches the current supplier are counted as
skipped(no-op). - Assignments referencing an allocation that is no longer in
planned/awaiting_receiptare counted asskipped. - Assignments where the supplier is not configured for the product return per-row errors and do NOT update the allocation.
- The endpoint is best-effort per row; partial success is normal (e.g., 3 updated, 1 skipped, 1 error).
Request
Responses
- 200
- 401
- 403
- 422
- 429
OK
Response Headers
Unauthenticated — the bearer token is missing, revoked, expired, or malformed. Never retry automatically; fix the credential. See the Errors guide.
Forbidden — the token lacks a required scope, the endpoint is not available to API tokens, or the user behind the token lacks the permission. A human must adjust the token scopes or user permissions; do not retry.
Unprocessable Entity
Response Headers
Rate limited — platform limit is 1,000 requests/min; individual tokens may carry lower limits. Honor the Retry-After header before retrying. See the Rate Limits guide.