Create variant
create_variantAdds a variant, such as a new size, to an existing product; specify every product option; new option values are added automatically.
Instructions
Adds a variant to an existing product, e.g. a new size. 'options' must name every product option; new option values are added automatically.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| ean | No | ||
| sku | No | ||
| upc | No | ||
| stock | No | Initial stocked quantity at location_id (or the only location) | |
| title | No | Defaults to the option values, e.g. 'M / Red' | |
| prices | Yes | ||
| weight | No | Grams | |
| barcode | No | ||
| options | No | Option title -> value, e.g. { Size: 'M', Color: 'Red' } | |
| product_id | Yes | ||
| location_id | No | Stock location for initial stock; defaults to the only one | |
| allow_backorder | No | Allow selling when out of stock | |
| manage_inventory | No | Track stock (default true) |