CreateBatchNumber
CreateBatchNumberCreates a new batch number.
Parameters:
| Parameter | Type | Description |
|---|---|---|
input | BatchNumberInput! | Batch data. |
Example Query:
mutation CreateBatchNumber($input: BatchNumberInput!) {
CreateBatchNumber(input: $input) {
id
label
barcode
}
}Example Variables:
{
"input": {
"label": "BATCH-A001",
"barcode": "1234567890",
"expiry_date": "2026-12-31",
"variant": { "id": 5001 }
}
}CreateBatchNumbers
CreateBatchNumbersCreates multiple batch numbers at once.
Parameters:
| Parameter | Type | Description |
|---|---|---|
input | [BatchNumberInput]! | List of batch data. |
UpdateBatchNumber
UpdateBatchNumberUpdates an existing batch number.
Parameters:
| Parameter | Type | Description |
|---|---|---|
id | Int! | ID of the batch number. |
input | BatchNumberInput! | Updated data. |
Example Query:
mutation UpdateBatchNumber($id: ID!, $input: BatchNumberInput!) {
UpdateBatchNumber(id: $id, input: $input) {
id
label
}
}UpdateBatchNumbers
UpdateBatchNumbersUpdates multiple batch numbers.
Parameters:
| Parameter | Type | Description |
|---|---|---|
input | [BatchNumberInput]! | List of updated batch data. |
DeleteBatchNumber
DeleteBatchNumberDeletes a batch number.
Parameters:
| Parameter | Type | Description |
|---|---|---|
id | Int! | ID of the batch number to delete. |
AllocateBatchNumber
AllocateBatchNumberAllocates batch numbers to specific stock levels (locations/bins).
Parameters:
| Parameter | Type | Description |
|---|---|---|
input | [BatchNumberStockLevelInput] | Allocation data. |
ImportProductsBatchNumbers
ImportProductsBatchNumbersImports batch numbers from a CSV file.
Parameters:
| Parameter | Type | Description |
|---|---|---|
file | TmpBucketFileInput! | Pre-signed file upload data. |
Example Query:
mutation ImportProductsBatchNumbers($file: TmpBucketFileInput!) {
ImportProductsBatchNumbers(file: $file)
}| Return Type | Description |
|---|---|
JSON | Import result with success/error details. |
Input Data Types
BatchNumberInput
BatchNumberInput| Field | Type | Description |
|---|---|---|
id | Int | ID. |
label | String | Batch/Lot number name. |
barcode | String | Associated barcode. |
expiry_date | Date | Expiration date of the batch. |
variant | VariantInput | Linked product variant. |
