updateInventoryItemsStep - Medusa Core Workflows Reference

This documentation provides a reference to the updateInventoryItemsStep. It belongs to the @medusajs/medusa/core-flows package.

This step updates one or more inventory items.

src/workflows/my-workflow.ts
1import { createWorkflow } from "@medusajs/framework/workflows-sdk"2import { updateInventoryItemsStep } from "@medusajs/medusa/core-flows"3
4const myWorkflow = createWorkflow(5  "my-workflow",6  () => {7    const data = updateInventoryItemsStep({8      "id": "id_vs6et3mu1AkGXePDZr"9    })10  }11)

Input#

UpdateInventoryItemsStepInputUpdateInventoryItemsStepInput
The data to update the inventory items.
idstring
The ID of the inventory item to update.
skunull | stringOptional
The SKU of the inventory item.
origin_countrynull | stringOptional
The origin country of the inventory item.
mid_codenull | stringOptional
The MID code of the inventory item.
materialnull | stringOptional
The material of the inventory item.
weightnull | numberOptional
The weight of the inventory item.
lengthnull | numberOptional
The length of the inventory item.
heightnull | numberOptional
The height of the inventory item.
widthnull | numberOptional
The width of the inventory item.
titlenull | stringOptional
The title of the inventory item.
descriptionnull | stringOptional
The description of the inventory item.
thumbnailnull | stringOptional
The thumbnail of the inventory item.
metadatanull | Record<string, unknown>Optional
Holds custom data in key-value pairs.
hs_codenull | stringOptional
The HS code of the inventory item.
requires_shippingbooleanOptional
Whether the inventory item requires shipping.

Output#

InventoryItemDTO[]InventoryItemDTO[]
InventoryItemDTOInventoryItemDTO
The inventory item details.
Was this page helpful?
Ask Anything
FAQ
What is Medusa?
How can I create a module?
How can I create a data model?
How do I create a workflow?
How can I extend a data model in the Product Module?
Recipes
How do I build a marketplace with Medusa?
How do I build digital products with Medusa?
How do I build subscription-based purchases with Medusa?
What other recipes are available in the Medusa documentation?
Chat is cleared on refresh
Line break