---
title: "Set the stock for a product"
method: PUT
path: "/api/v1/products/{id}/stock"
tags: ["ProductStock"]
---

# Set the stock for a product

`PUT /api/v1/products/{id}/stock`

## Path parameters

- `id` integer, required — The product ID

## Request body

- V1ProductStock
  - `id` integer
  - `stock` integer
  - `total_product_stock` integer

## Response `200`

The stock of a chosen product

- TempestResponseV1ProductStock
  - `meta` object, nullable
  - `links` TempestLink[], nullable
    - `rel` string, nullable
    - `href` string, nullable
  - `validation_result` TempestValidationError[], nullable
    - `member_names` string[], nullable
    - `error_message` string, nullable
  - `errors` object, nullable
  - `data` V1ProductStock
    - `id` integer
    - `stock` integer
    - `total_product_stock` integer

## Other responses

- `400` — Invalid Request
- `401` — Unauthorized
- `403` — Forbidden
- `404` — No product for that ID found
- `422` — Unprocessable product ID - The ID belongs to either a variant or a managed product

---

[API](https://skmtc.dev/ekm/apis/ekm-partner-api.md) · [All operations](https://skmtc.dev/ekm/apis/ekm-partner-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/ekm/ekm-partner-api/revisions/853bef073bb3/schema)
