AdminCreateProductVariant

Properties#

titlestring
The variant's title.
The variant's prices.
skustringOptional
The variant's SKU.
eanstringOptional
The variant's EAN.
upcstringOptional
The variant's UPC.
barcodestringOptional
The variant's barcode.
hs_codestringOptional
The variant's HS code.
mid_codestringOptional
The variant's MID code.
allow_backorderbooleanOptional
Whether the variant can be ordered even if it's out of stock.
manage_inventorybooleanOptional
Whether Medusa manages the variant's inventory. If disabled, the variant is always considered in stock.
variant_ranknumberOptional
The variant's ranking among its sibling variants.
weightnumberOptional
The variant's weight.
lengthnumberOptional
The variant's length.
heightnumberOptional
The variant's height.
widthnumberOptional
The variant's width.
origin_countrystringOptional
The variant's origin country.
materialstringOptional
The variant's material.
metadataRecord<string, unknown>Optional
Key-value pairs of custom data.
inventory_itemsAdminCreateProductVariantInventoryKit[]Optional
The variant's inventory items. It's only available if manage_inventory is enabled.
optionsRecord<string, string>Optional
The variant's values for the associated product's options.
Was this page helpful?
Edit this page
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