---
title: "Create experiment on a dataset"
method: POST
path: "/v1/datasets/{dataset_id}/experiments"
tags: ["experiments"]
---

# Create experiment on a dataset

`POST /v1/datasets/{dataset_id}/experiments`

## Path parameters

- `dataset_id` string, required

## Request body

- CreateExperimentRequestBody — Details of the experiment to be created
  - `name` string, nullable — Name of the experiment (if omitted, a random name will be generated)
  - `description` string, nullable — An optional description of the experiment
  - `metadata` object, nullable — Metadata for the experiment
  - `version_id` string, nullable — ID of the dataset version over which the experiment will be run (if omitted, the latest version will be used)
  - `splits` string[], nullable — List of dataset split identifiers (GlobalIDs or names) to filter by
  - `repetitions` integer — Number of times the experiment should be repeated for each example

## Response `200`

Experiment retrieved successfully

- CreateExperimentResponseBody
  - `data` Experiment, required
    - `id` string, required — The ID of the experiment
    - `dataset_id` string, required — The ID of the dataset associated with the experiment
    - `dataset_version_id` string, required — The ID of the dataset version associated with the experiment
    - `name` string, required — The name of the experiment
    - `description` string, nullable, required — The description of the experiment
    - `repetitions` integer, required — Number of times the experiment is repeated
    - `metadata` object, required — Metadata of the experiment
    - `project_name` string, nullable, required — The name of the project associated with the experiment
    - `created_at` string, date-time, required — The creation timestamp of the experiment
    - `updated_at` string, date-time, required — The last update timestamp of the experiment
    - `example_count` integer, required — Number of examples in the experiment
    - `successful_run_count` integer, required — Number of successful runs in the experiment
    - `failed_run_count` integer, required — Number of failed runs in the experiment
    - `missing_run_count` integer, required — Number of missing (not yet executed) runs in the experiment

## Other responses

- `403` — Forbidden
- `404` — Dataset or DatasetVersion not found
- `422` — Validation Error

---

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