---
title: "Create scenario"
method: POST
path: "/simulate/scenarios/create/"
tags: ["Scenarios"]
---

# Create scenario

`POST /simulate/scenarios/create/`

## Request

- Base URL: `http://localhost:8000`
- URL: `http://localhost:8000/simulate/scenarios/create/`
- Auth: one of:
  - API key in header `X-Api-Key`
  - API key in header `X-Secret-Key`

Creates a new scenario (dataset, script, or graph kind). Returns 202 with processing status.

## Request body

- ScenarioCreateRequest
  - `name` string, required
  - `description` string
  - `dataset_id` string, uuid
  - `kind` 'graph' | 'script' | 'dataset'
  - `script_url` string, uri, nullable
  - `agent_definition_id` string, uuid
  - `agent_definition_version_id` string, uuid, nullable
  - `custom_instruction` string
  - `no_of_rows` integer
  - `generate_graph` boolean
  - `graph` object, nullable
  - `source_type` 'agent_definition' | 'prompt'
  - `prompt_template_id` string, uuid, nullable
  - `prompt_version_id` string, uuid, nullable
  - `add_persona_automatically` boolean
  - `personas` string[]
  - `custom_columns` ColumnDefinition[]
    - `name` string, required
    - `data_type` 'text' | 'boolean' | 'integer' | 'float' | 'json' | 'array' | 'image' | 'images' | 'datetime' | 'audio' | 'document' | 'others' | 'persona', required
    - `description` string, required
  - `agent_name` string
  - `agent_prompt` string
  - `voice_provider` string
  - `voice_name` string
  - `model` string
  - `llm_temperature` number
  - `initial_message` string
  - `max_call_duration_in_minutes` integer
  - `interrupt_sensitivity` number
  - `conversation_speed` number
  - `finished_speaking_sensitivity` number
  - `initial_message_delay` integer

## Response `202`

Accepted

- ScenarioCreateResponse
  - `message` string
  - `scenario` ScenarioResponse
    - `id` string, uuid
    - `name` string, required: Name of the scenario
    - `description` string, nullable: Optional description of the scenario
    - `source` string, required: Source content or reference for the scenario
    - `scenario_type` 'graph' | 'script' | 'dataset': Type of scenario (graph, script, or dataset)
    - `scenario_type_display` string
    - `source_type` 'agent_definition' | 'prompt': Source type for the scenario: agent_definition or prompt
    - `source_type_display` string
    - `organization` string, uuid: Organization this scenario belongs to
    - `dataset` string, uuid, nullable: Dataset associated with this scenario (only for dataset type scenarios)
    - `dataset_rows` string
    - `dataset_column_config` string
    - `graph` string
    - `agent` string
    - `prompt_template` string, uuid, nullable: Prompt template associated with this scenario (only for prompt source type)
    - `prompt_template_detail` string
    - `prompt_version` string, uuid, nullable: Prompt version associated with this scenario (only for prompt source type)
    - `prompt_version_detail` string
    - `created_at` string, date-time
    - `updated_at` string, date-time
    - `deleted` boolean
    - `status` 'NotStarted' | 'Queued' | 'Running' | 'Completed' | 'Editing' | 'Inactive' | 'Failed' | 'PartialRun' | 'ExperimentEvaluation' | 'Uploading' | 'PartialExtracted' | 'Processing' | 'Deleting' | 'PartialCompleted' | 'OptimizationEvaluation' | 'Error' | 'Cancelled': Status of the scenario
    - `deleted_at` string, date-time, nullable
    - `agent_type` string
  - `status` 'processing'

## Other responses

- `400`: Bad Request
- `500`: Internal Server Error
- `default`: Default error response

---

[API](https://skmtc.dev/futureagi/apis/future-agi-management-api.md) · [All operations](https://skmtc.dev/futureagi/apis/future-agi-management-api/llms.txt) · [OpenAPI document](https://skmtc.dev/futureagi/apis/future-agi-management-api/revisions/c8684118e142?raw)
