---
title: "Set Data Product Status"
method: PUT
path: "/api/products/v2/{id}/status"
tags: ["Data Products"]
---

# Set Data Product Status

`PUT /api/products/v2/{id}/status`

Sets the status of a data product. Only accessible to the provider who owns the data product. Admins on the other hand can set the state to any data product. Only specific transitions are allowed.

## Path parameters

- `id` string, uuid, required

## Query parameters

- `actingRole` 'PROVIDER' | 'ADMIN'

## Request body

- 'DRAFT' | 'ACTIVE'

## Response `200`

OK

- DataProductDto
  - `id` string, uuid, required
  - `dataSourceSystemCode` string — Code of data source system from which this product originates
  - `dataSourceSystem` DataSourceSystemDto
    - `id` string, uuid, required
    - `code` string — Stable technical code of the source
    - `name` TranslationDto
      - `de` string
      - `fr` string
      - `it` string
    - `dataProvider` DataProviderDto, required
      - `id` string, uuid, required
      - `code` string — Stable technical code of the provider
      - `name` TranslationDto
        - `de` string
        - `fr` string
        - `it` string
      - `uid` string — UID of the data provider
    - `legalBasis` TranslationDto, required
      - `de` string
      - `fr` string
      - `it` string
  - `restClient` RestClientDto
    - `id` string, uuid
    - `code` string — Stable technical code of the rest client
    - `displayName` string — Human-readable name of the REST client, intended for display in user interfaces
    - `url` string — Base URL of the external API accessed by this REST client
  - `restClientPathTemplate` string — Template for the path where the data product is fetched from
  - `restClientRequestTemplate` string — Template of the request body for fetching the data product
  - `restClientMethodCode` 'POST' | 'GET'
  - `flowCode` 'UID_BASED_PRE_VALIDATION' | 'UID_BASED_POST_VALIDATION' | 'BUR_BASED_PRE_VALIDATION' | 'BUR_BASED_POST_VALIDATION' | 'UNBOUND_UID_BASED_POST_VALIDATION' | 'UNBOUND_BUR_BASED_POST_VALIDATION'
  - `name` TranslationDto
    - `de` string
    - `fr` string
    - `it` string
  - `description` TranslationDto
    - `de` string
    - `fr` string
    - `it` string
  - `links` LinkDto[] — List of relevant product links
    - `url` string
    - `displayText` string
  - `extendedDescription` TranslationDto
    - `de` string
    - `fr` string
    - `it` string
  - `deprecatedSince` string, date-time
  - `stateCode` union, required — State of the data product
    - 'DRAFT' | 'ACTIVE'
    - object
  - `restClientChangeDetectionPathTemplate` string — Template for the path for retrieving updates to the data product
  - `consentRequired` boolean, required — If a consent is required for this data product

## Other responses

- `401` — Not Authorized
- `403` — Not Allowed
- `404` — The resource or element was not found
- `500` — Internal server error: unexpected error

## Changes

- **2026-08-13** `a0609096db65` — 1 info
  - added the required property `consentRequired` to the response with the `200` status
- **2026-08-11** `52c1637abca0` — 2 warning, 2 info
  - added the new `UNBOUND_BUR_BASED_POST_VALIDATION` enum value to the `flowCode` response property for the response status `200`
  - added the new `UNBOUND_UID_BASED_POST_VALIDATION` enum value to the `flowCode` response property for the response status `200`
  - removed the `UNBOUND_POST_VALIDATION` enum value from the `flowCode` response property for the response status `200`
  - added the required property `dataSourceSystem/legalBasis` to the response with the `200` status
- **2026-07-13** `bf09fcfe746c` — 1 warning, 1 info
  - removed the optional property `technicalDescription` from the response with the `200` status
  - added the optional property `extendedDescription` to the response with the `200` status
- **2026-07-09** `73b93bab6c7b` — 1 warning, 1 info
  - removed the optional property `extendedDescription` from the response with the `200` status
  - added the optional property `technicalDescription` to the response with the `200` status
- **2026-07-08** `4f907e176481` — 1 warning, 2 info
  - removed the optional property `technicalDescription` from the response with the `200` status
  - added the optional property `extendedDescription` to the response with the `200` status
  - added the optional property `restClient/displayName` to the response with the `200` status

[Full history](https://skmtc.dev/agridata/apis/agridata-ch-api/changes/api/products/v2/:id/status/put.md)

---

[API](https://skmtc.dev/agridata/apis/agridata-ch-api.md) · [All operations](https://skmtc.dev/agridata/apis/agridata-ch-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/agridata/agridata-ch-api/revisions/5760204210ed/schema)
