---
title: "Create a variant"
method: POST
path: "/v0/projects/{project}/benchmarks/{benchmark}/variants"
tags: ["projects", "variants"]
---

# Create a variant

`POST /v0/projects/{project}/benchmarks/{benchmark}/variants`

## Request

- The document declares no server URL.
- Auth: none declared

Create a variant for a benchmark. The user must have `create` permissions for the project, or provide a valid project key for the project. A variant that already exists for the benchmark is a conflict, so this endpoint never returns an existing variant.

## Path parameters

- `benchmark` string, required
- `project` string, required

## Request body

- JsonNewVariant
  - `parameters` ParameterSet, required

## Response `201`

successful creation

- JsonVariant
  - `archived` string, date-time
  - `benchmark` string, uuid, required
  - `created` string, date-time, required
  - `modified` string, date-time, required
  - `parameters` ParameterSet, required
  - `uuid` string, uuid, required

## Other responses

- `4XX`: Error
- `5XX`: Error

## Changes

- **2026-09-23** `6b8d0bafd2dd`: 1 breaking, 1 warning
  - the `parameters/allOf[#/components/schemas/ParameterSet]/additionalProperties/anyOf[subschema #1]/` request property's minLength was increased from `0` to `1`
  - the `parameters/allOf[#/components/schemas/ParameterSet]/additionalProperties/anyOf[subschema #1]/` request property's maxLength was set to `64`
- **2026-09-18** `2ca549d2a218`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/bencherdev/apis/bencher-api/changes/v0/projects/:project/benchmarks/:benchmark/variants/post.md)

---

[API](https://skmtc.dev/bencherdev/apis/bencher-api.md) - [All operations](https://skmtc.dev/bencherdev/apis/bencher-api/llms.txt) - [OpenAPI document](https://skmtc.dev/bencherdev/apis/bencher-api/revisions/538b39b8d755?raw)
