For AI agents: a documentation index is available at the root level at /llms.txt and /llms-full.txt. Append /llms.txt to any URL for a page-level index, or .md for the markdown version of any page.
Copy to LLMGithubGo to App
DocumentationIntegrationsBuilding Self-Improving AgentsSelf-hosting OpikSDK & API reference
DocumentationIntegrationsBuilding Self-Improving AgentsSelf-hosting OpikSDK & API reference
    • Overview
  • Python SDK
    • Reference
    • REST API Client
  • Typescript SDK
    • Overview
    • Opik TS
    • Prompts
    • Opik Query Language (OQL)
  • Rest API
    • Overview
        • PATCHBatch update experiments
        • GETFind experiments
        • POSTCreate experiment
        • POSTCreate experiment items
        • POSTDelete experiment items
        • POSTDelete experiments by id
        • POSTCreate and execute experiment
        • PUTRecord experiment items in bulk
        • GETFind Feedback Score names
        • GETFind experiment groups
        • GETFind experiment groups with aggregations
        • POSTFinish experiments
        • GETGet experiment by id
        • PATCHUpdate experiment by id
        • GETGet experiment item by id
        • POSTStream experiment items
        • POSTStream experiments
LogoLogo
Copy to LLMGithubGo to App
Rest APIAPI ReferenceExperiments

Create experiment

POST
/v1/private/experiments
POST
/api/v1/private/experiments
$curl -X POST http://localhost:5173/api/v1/private/experiments \
> -H "Content-Type: application/json" \
> -d '{
> "dataset_name": "string"
>}'
201Created
1{}
Create experiment
Was this page helpful?
Previous

Create experiment items

Next
Built with

Request

This endpoint expects an object.
dataset_namestring or nullRequired>=1 character
idstringOptionalformat: "uuid"
project_idstringOptionalformat: "uuid"

Project ID. Takes precedence over project_name when both are provided.

project_namestringOptionalformat: "(?s)^\s*(\S.*\S|\S)\s*$"

Project name. Creates project if it doesn’t exist. Ignored when project_id is provided.

namestringOptional
metadatamap from strings to any or list of objects or stringOptional
tagslist of stringsOptional
typeenumOptional
Allowed values:
evaluation_methodenumOptional
Allowed values:
optimization_idstringOptionalformat: "uuid"
statusenumOptional
Allowed values:
experiment_scoreslist of objectsOptional
prompt_versionobjectOptional
prompt_versionslist of objectsOptional
dataset_version_idstringOptionalformat: "uuid"
ID of the dataset version this experiment is linked to. If not provided at creation, experiment will be automatically linked to the latest version.

Response headers

Locationstring

Response

Created