# Product update with variants

URL: https://shoptet.dev/news/api/product-update-with-variants

February 4, 2021 · One min read
Pavel Husa

We have enhanced the [Product update](https://api.docs.shoptet.com/shoptet-api/openapi/products/updateproduct) endpoint to support variants. Now it is possible to specify the most important variant parameters including variant parameters.

It is important to mention the variant must always be identified by `code` (even for products without variants, the `code` must be provided, if array `variants[]` is used). If the `code` is not provided or does not exist, a new variant will be created.

It is also possible to change the `code` itself – item `newCode` is to be used.

For complete list of request items, check [Product update](https://api.docs.shoptet.com/shoptet-api/openapi/products/updateproduct) in the API documentation, section "Request Body schema".

**Tags:**
- [API](/news/tags/api/)
