createInventoryLevelsWorkflow - Medusa Core Workflows Reference
This documentation provides a reference to the createInventoryLevelsWorkflow
. It belongs to the @medusajs/medusa/core-flows
package.
This workflow creates one or more inventory levels. It's used by the Create Inventory Level API Route.
You can use this workflow within your own customizations or custom workflows, allowing you to create inventory levels in your custom flows.
Source CodeExamples#
Steps#
Workflow hook
Step conditioned by when
View step details
Input#
CreateInventoryLevelsWorkflowInput
CreateInventoryLevelsWorkflowInputThe data to create the inventory levels.
CreateInventoryLevelsWorkflowInput
CreateInventoryLevelsWorkflowInputinventory_levels
CreateInventoryLevelInput[]The inventory levels to create.
inventory_levels
CreateInventoryLevelInput[]Output#
InventoryLevelDTO[]
InventoryLevelDTO[]
InventoryLevelDTO[]
InventoryLevelDTO[]id
stringThe ID of the inventory level.
id
stringinventory_item_id
stringThe associated inventory item's ID.
inventory_item_id
stringlocation_id
stringThe associated location's ID.
location_id
stringstocked_quantity
numberThe stocked quantity of the inventory level.
stocked_quantity
numberreserved_quantity
numberThe reserved quantity of the inventory level.
reserved_quantity
numberincoming_quantity
numberThe incoming quantity of the inventory level.
incoming_quantity
numberavailable_quantity
numberThe available quantity of the inventory level.
available_quantity
numbermetadata
null | Record<string, unknown>Holds custom data in key-value pairs.
metadata
null | Record<string, unknown>created_at
string | DateThe creation date of the inventory level.
created_at
string | Dateupdated_at
string | DateThe update date of the inventory level.
updated_at
string | Datedeleted_at
null | string | DateThe deletion date of the inventory level.
deleted_at
null | string | DateWas this page helpful?