---
title: "Create a benchmark suite task"
method: POST
path: "/factory/{factory_uid}/benchmarks/{suite_uid}/tasks"
tags: ["Factories", "Benchmarks"]
---

# Create a benchmark suite task

`POST /factory/{factory_uid}/benchmarks/{suite_uid}/tasks`

## Request

- Base URL: `https://app.warp.dev/api/v1`
- URL: `https://app.warp.dev/api/v1/factory/{factory_uid}/benchmarks/{suite_uid}/tasks`
- Auth: HTTP bearer

This adds a single hand-authored task to a suite, without needing
to resend the whole task list. A title, prompt, and success
criteria are required, and if a `source_run_id` is included, the
caller must have permission to read that run. Adding the exact
same task twice simply returns the existing one (so retrying is
safe), while reusing a title with different content is rejected
as a conflict — and on a `code.storage`-managed Factory, the task
is saved as a file and returned from that file.

## Path parameters

- `factory_uid` string, required
- `suite_uid` string, required

## Request body

- BenchmarkSuiteTaskCreateRequest
  - `title` string, required
  - `prompt` string, required
  - `success_criteria` string, required: Plain-text criteria the built-in Correctness scorer grades each trial against, as the authoritative requirements. The task prompt provides context only.
  - `source_run_id` string, nullable: Optional provenance. The caller must be able to read the run.
  - `tags` string[]
  - `starting_repo_refs` BenchmarkRepoRef[]
    - `code_forge` string, required
    - `owner` string, required
    - `repo` string, required
    - `ref` string

## Response `201`

Task created

- BenchmarkSuiteTask
  - `uid` string, uuid, required: Immutable public task identifier.
  - `title` string, required
  - `prompt` string, required
  - `success_criteria` string, required: Plain-text criteria the built-in Correctness scorer grades each trial against, as the authoritative requirements. The task prompt provides context only.
  - `source_run_id` string, nullable
  - `labels` object
  - `tags` string[]
  - `starting_repo_refs` BenchmarkRepoRef[]
    - `code_forge` string, required
    - `owner` string, required
    - `repo` string, required
    - `ref` string

## Other responses

- `400`: Invalid request
- `401`: Authentication required
- `403`: Factory access is not enabled for the authenticated principal
- `404`: Suite not found, or source_run_id is not a run the caller can read
- `409`: Another task in this suite already has this title with different content, or the Factory is file-managed and cannot be written through

## Changes

- **2026-10-21** `7ee3ba55debc`: 3 info
  - api tag `factory-benchmarks` added
  - api tag `benchmark` removed
  - api tag `factory` removed
- **2026-10-19** `2c45dcc0a13e`: 1 breaking
  - the request property `source_run_id` became not nullable
- **2026-10-15** `f4630aae17ba`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/warp/apis/oz-agent-api/changes/factory/:factory_uid/benchmarks/:suite_uid/tasks/post.md)

---

[API](https://skmtc.dev/warp/apis/oz-agent-api.md) - [All operations](https://skmtc.dev/warp/apis/oz-agent-api/llms.txt) - [OpenAPI document](https://skmtc.dev/warp/apis/oz-agent-api/revisions/4b5d145669be?raw)
