---
title: "Create a test set from a previous test run"
method: POST
path: "/test_framework/test-sets/create_from_run/"
tags: ["test_framework"]
---

# Create a test set from a previous test run

`POST /test_framework/test-sets/create_from_run/`

Promote a completed test run into a labeled test set by attaching the specified metrics. Existing metric scores from the run are copied as the initial 'actual' values; the caller provides 'expected' values for review. Returns the created or existing test set.

## Request body

- SchemaPostCreateFromRunRequest
  - `run_id` integer, required — ID of the run to create test set from
  - `project` integer — ID of the project that owns the run
  - `name` string — Optional name for the test set. If not provided, run ID will be used
  - `metrics` MetricWithFeedback[], required — List of metrics with optional notes to include in the test set
    - unknown

## Response `200`

- TestSetDetail
  - `id` integer
  - `agent` integer
  - `name` string — Name of the test set Example: `"Test Set 1"`
  - `transcript` string — Full text transcript of the call. Example:

---

[API](https://skmtc.net/cekura/apis/cekura-api.md) · [All operations](https://skmtc.net/cekura/apis/cekura-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/cekura/cekura-api/versions/d08e85615b58/schema)
