---
title: "Update a product option value"
method: PUT
path: "/products/{product_id}/option-values/{id}"
---

# Update a product option value

`PUT /products/{product_id}/option-values/{id}`

## Request

- Base URL: `https://api.ecommerceapi.uk/v1`
- URL: `https://api.ecommerceapi.uk/v1/products/{product_id}/option-values/{id}`
- Auth: HTTP basic

Updates an existing product option value.

## Path parameters

- `product_id` integer, required
- `id` integer, required

## Request body

- ProductOptionValueUpdate
  - `name` string: The updated name of the product option value.
  - `sortOrder` integer: Optional sort order of the product option value. Values with a lower number appear first.

## Response `200`

Product option value updated successfully.

- ProductOptionValue
  - `id` integer: Unique identifier for the product option value.
  - `name` string: The name of the product option value.
  - `option` integer: The ID of the product option that this value is assigned to.
  - `sortOrder` integer: The sort order of the product option value. Values with a lower number appear first.

---

[API](https://skmtc.dev/ecommerceapi/apis/product-option-values.md) - [All operations](https://skmtc.dev/ecommerceapi/apis/product-option-values/llms.txt) - [OpenAPI document](https://skmtc.dev/ecommerceapi/apis/product-option-values/revisions/b3cc4975d481?raw)
