Bulk create bins
Operation ID: bulkCreateBins
Group: Inventory › Bins
Open in the interactive reference
POST /inventory/bins/bulk
Retry-safe: A write that accepts Idempotency-Key: repeating a request with the same key replays the stored answer instead of executing twice.
Creates multiple bins in one request. Every bin is checked the same way as on POST inventory/bins. If any bin can't be created, none are. The response lists the new bins' ids and codes in the order you sent them.
The duplicate check also compares the bins in the request with each other. Two bins with the same binCode or barcode are duplicates.
To create a single bin, use POST inventory/bins.
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
Api-Version |
header | string · v1 | yes | The API version this request targets, named by its public identifier. Required on every request; omitting it, or naming a version this company does not have, is answered with 400. This document describes version v1. |
Idempotency-Key |
header | string | no | An opaque caller-chosen string (1-255 characters) that makes this request safe to retry. Repeating the same key with an identical request body replays the original response instead of re-executing - but only once that original request succeeded; a failed attempt re-executes on retry. Repeating the key with a different body is answered with 422. A key still in flight is answered with 409 - as is a key whose original request was interrupted before it finished, for a few minutes afterwards, until that attempt is presumed dead. A completed response stays replayable for 24 hours. The key is scoped to the caller, not to the action: reusing it for a different action is answered with 409 or 422 rather than treated independently. On read actions this header is ignored. On write actions that cannot offer the guarantee it is answered with 400 IDEMPOTENCY_NOT_SUPPORTED rather than silently ignored. |
Request body
Required, application/json: bulkCreateBinsInput.
| Field | Type | Required | Description |
|---|---|---|---|
bins |
array<object> | yes | The bins to create. If any entry is invalid, nothing is created and the whole call fails. Example: [{"binCode":"A-01-1","locationId":"f5272ae0-0f0b-47d2-b78a-2158fec2cc32","aisle":"A","rack":"01","shelfLevel":"1","isPickingBin":true},{"binCode":"A-01-2","locationId":"f5272ae0-0f0b-47d2-b78a-2158fec2cc32","aisle":"A","rack":"01","shelfLevel":"2","isPickingBin":true}]. |
bins[].binCode |
string | yes | The short code that identifies the bin, for example 'A-01-1'. Required. It is unique within the tenant, not per warehouse, and cannot be changed after the bin is created. |
bins[].locationId |
string | yes | The unique identifier for the warehouse the bin is in. Required. It cannot be changed after the bin is created. See id on GET inventory/warehouses/:id. |
bins[].barcode |
string | no | The barcode printed on the bin label. It is unique within the tenant and cannot be changed after the bin is created. |
bins[].aisle |
string | no | The aisle in the warehouse layout. |
bins[].rack |
string | no | The rack within the aisle. |
bins[].shelfLevel |
string | no | The shelf level within the rack. |
bins[].zone |
string | no | The logical zone of the bin, as your tenant names them. For example 'Picking', 'Storage' or 'Quarantine'. |
bins[].itemPosition |
string | no | The position within the shelf, where a bin is subdivided further. |
bins[].isPickingBin |
boolean | no | Whether the bin is a picking location, a fast-access place stock is taken from to fulfill shipments. |
bins[].isReceivingBin |
boolean | no | Whether the bin stages newly received goods before they are put away. |
bins[].isProductionBin |
boolean | no | Whether the bin feeds or receives production. |
bins[].maxQuantity |
number | no | The largest number of units the bin will hold, above zero. Leave it out for no quantity limit. It is meaningful only when everything in the bin is counted in the same unit. |
bins[].maxWeight |
decimal | no | The largest weight the bin will hold, in maxWeightUnit, above zero. Send it together with maxWeightUnit, or leave both out for no weight limit. |
bins[].maxWeightUnit |
string | no | The unit maxWeight is given in. Accepted values: 'G', 'Kg', 'Lbs'. Send it together with maxWeight, or leave both out. |
bins[].maxVolume |
decimal | no | The largest volume the bin will hold, in maxVolumeUnit, above zero. Send it together with maxVolumeUnit, or leave both out for no volume limit. |
bins[].maxVolumeUnit |
string | no | The unit maxVolume is given in. Accepted values: 'L'. Send it together with maxVolume, or leave both out. |
bins[].capacityCheckMode |
string | no | What happens when a movement would exceed a limit. Accepted values: 'HardBlock', which refuses the movement, and 'SoftWarning', which allows it and flags it. |
bins[].tempZone |
string | no | The temperature zone the bin belongs to, as your tenant names them. For example 'Ambient', 'Chilled' or 'Frozen'. |
bins[].tempMin |
decimal | no | The lowest temperature kept in the bin, in degrees Celsius. It must not be above tempMax. |
bins[].tempMax |
decimal | no | The highest temperature kept in the bin, in degrees Celsius. |
bins[].supportsPerishable |
boolean | no | Whether perishable stock may be kept in the bin. |
bins[].active |
boolean | no | Whether the bin may be chosen for new movements. Defaults to true. |
{
"bins": [
{
"binCode": "A-01-1",
"locationId": "f5272ae0-0f0b-47d2-b78a-2158fec2cc32",
"aisle": "A",
"rack": "01",
"shelfLevel": "1",
"isPickingBin": true
},
{
"binCode": "A-01-2",
"locationId": "f5272ae0-0f0b-47d2-b78a-2158fec2cc32",
"aisle": "A",
"rack": "01",
"shelfLevel": "2",
"isPickingBin": true
}
]
}
Response
200 Success
Under data (bulkCreateBinsOutput):
| Field | Type | Required | Description |
|---|---|---|---|
created |
array<object> | yes | The created bins, in the same order as the input. Match entries to inputs by index. Example: [{"id":"8e1c40a7-5b93-4d26-a0f8-3c74e19b5d02","binCode":"A-01-1"},{"id":"f0472b19-8c35-4e61-b7a2-6d05e83c1947","binCode":"A-01-2"}]. |
created[].id |
string | yes | The unique identifier for the created bin. |
created[].binCode |
string | no | The bin's code. |
{
"data": {
"created": [
{
"id": "8e1c40a7-5b93-4d26-a0f8-3c74e19b5d02",
"binCode": "A-01-1"
},
{
"id": "f0472b19-8c35-4e61-b7a2-6d05e83c1947",
"binCode": "A-01-2"
}
]
},
"diagnostics": [
{
"code": "<code>",
"message": "<message>",
"severity": "error",
"path": [
"<path>"
],
"details": "<details>"
}
]
}
Response headers
Idempotency-Replayed— Present andtrueonly when this response replays a previously stored one for the same Idempotency-Key, rather than reflecting a live execution. Absent on a live response - never sent asfalse.
Errors
| Code | Status |
|---|---|
REFERENCE_NOT_FOUND |
400 |
DUPLICATE_CODE |
400 |
WAREHOUSE_NOT_BIN_TRACKABLE |
400 |
UNKNOWN_VALUE |
400 |
INCOMPLETE_LIMIT |
400 |
NON_POSITIVE_LIMIT |
400 |
INVALID_RANGE |
400 |
IDEMPOTENCY_KEY_CONFLICT |
409 |
IDEMPOTENCY_PAYLOAD_MISMATCH |
422 |
Statuses
400— Invalid request or business failure. Codes: REFERENCE_NOT_FOUND, DUPLICATE_CODE, WAREHOUSE_NOT_BIN_TRACKABLE, UNKNOWN_VALUE, INCOMPLETE_LIMIT, NON_POSITIVE_LIMIT, INVALID_RANGE401— The request carries no valid access token.403— Not authorized404— Not found409— The Idempotency-Key is still being processed by another request.422— The Idempotency-Key was already used with a different request payload.429— Too many requests from this client address. The response has no body and noRetry-Afterheader.500— Internal server error