Inventory__initialize Stock
Requires a signed-in staff user. Needs the `inventory__Stock` `create` permission. Send the `x-tenant` header (the gateway sets it from your API key).
inventory__initializeStock(input: InitializeStockInput!): InventoryStock!Requires a signed-in staff user. Needs the inventory__Stock create permission. Send the x-tenant header (the gateway sets it from your API key).
Arguments
input*Returns
- inventory__initializeStock
_id*ID!allowBackorder*Boolean!archivedAt?DateTimeA date-time string at UTC, such as 2019-12-03T09:54:33Z, compliant with the date-time format.
available*Int!createdAt?DateTimeA date-time string at UTC, such as 2019-12-03T09:54:33Z, compliant with the date-time format.
lifecycleStatus*InventoryStockLifecycleStatus!ACTIVEARCHIVEDlowStockThreshold*Int!onHand*Int!productId*ID!reserved*Int!sku?Stringstatus*InventoryStockStatus!BACKORDERIN_STOCKLOW_STOCKNOT_TRACKEDOUT_OF_STOCKtenant*String!trackInventory*Boolean!updatedAt?DateTimeA date-time string at UTC, such as 2019-12-03T09:54:33Z, compliant with the date-time format.
variantKey?Stringmutation Inventory__initializeStock($input: InitializeStockInput!) { inventory__initializeStock(input: $input) { _id allowBackorder archivedAt available createdAt lifecycleStatus lowStockThreshold onHand }}{ "input": { "productId": "1", "quantity": 0 }}{ "data": { "inventory__initializeStock": { "_id": "1", "allowBackorder": true, "archivedAt": "<DateTime>", "available": 10, "createdAt": "<DateTime>", "lifecycleStatus": "ACTIVE", "lowStockThreshold": 10, "onHand": 10 } }}Inventory__detach Collection From Products MUTATION
Removes one collection from products, leaving their other collections intact. Requires a signed-in staff user. Needs the `inventory__Product` `update` permission. Send the `x-tenant` header (the gateway sets it from your API key).
Inventory__load Demo Products MUTATION
Requires a signed-in staff user. Needs the `inventory__Product` `create` permission. Send the `x-tenant` header (the gateway sets it from your API key).