---
title: "Create a dimension"
method: POST
path: "/instances/{instance_id}/dimensions"
tags: ["Private"]
deprecated: true
---

# Create a dimension

`POST /instances/{instance_id}/dimensions`

## Request

- Base URL: `https://api.beta.ons.gov.uk/v1`
- URL: `https://api.beta.ons.gov.uk/v1/instances/{instance_id}/dimensions`
- Auth: API key in header `Authorization`

> **Deprecated.**

Create a new dimension which is related to an instance

## Path parameters

- `instance_id` string, required

## Headers

- `If-Match` string

## Request body

- UpdateDimensionOptionRequest: A cached dimension. (Only used by the Private API)
  - `code` string
  - `codelist` string
  - `dimension` string: The name of the dimension
  - `instance_id` string: The unique identifier for the instance in which this dimension option is associated to
  - `label` string: The label for a option
  - `option` string: The option of the dimension
  - `order` integer: The numerical order for the dimension option

## Response `201`

Dimension was created

## Other responses

- `400`: Failed to process the request due to invalid request
- `404`: The instance was not found
- `409`: Failed to process the request due to a conflict
- `500`: Failed to process the request due to an internal error

---

[API](https://skmtc.dev/office-of-national-statistics/apis/dataset-api.md) - [All operations](https://skmtc.dev/office-of-national-statistics/apis/dataset-api/llms.txt) - [OpenAPI document](https://skmtc.dev/office-of-national-statistics/apis/dataset-api/revisions/a2947a13d675?raw)
