Skip to main content
POST
/
test_framework
/
v1
/
scenarios
cURL
curl --request POST \
  --url https://api.cekura.ai/test_framework/v1/scenarios/ \
  --header 'Content-Type: application/json' \
  --header 'X-CEKURA-API-KEY: <api-key>' \
  --data '
{
  "personality": 123,
  "agent": 123,
  "assistant_id": "<string>",
  "name": "<string>",
  "instructions": "<string>",
  "expected_outcome_prompt": "<string>",
  "metrics": [
    123
  ],
  "tags": [
    "<string>"
  ],
  "tool_ids": [
    "TOOL_DTMF",
    "TOOL_END_CALL",
    "TOOL_END_CALL_ONLY_ON_TRANSFER"
  ],
  "test_profile": 123,
  "inbound_phone_number": 123
}
'
{
  "id": 123,
  "name": "<string>",
  "agent": 123,
  "personality": 123,
  "personality_name": "<string>",
  "tags": [
    "<string>"
  ],
  "tool_ids": "<unknown>",
  "runs": [
    123
  ],
  "metrics": [
    123
  ],
  "metric_names": [
    "<string>"
  ],
  "phone_number": "<string>",
  "outbound_phone_number_data": {
    "id": 123,
    "number": "<string>",
    "phone_number_id": "<string>"
  },
  "first_message": "<string>",
  "inbound_phone_number": 123,
  "inbound_phone_number_data": {
    "id": 123,
    "number": "<string>",
    "phone_number_id": "<string>"
  },
  "instructions": "<string>",
  "simulation_description": "<string>",
  "information_fields": {},
  "expected_outcome_prompt": "<string>",
  "scenario_language": "af",
  "scenario_type": "instruction",
  "test_profile": 123,
  "test_profile_data": {
    "id": 123,
    "agent": 123,
    "name": "<string>",
    "information": {}
  }
}

Authorizations

X-CEKURA-API-KEY
string
header
required

API Key Authentication. It should be included in the header of each request.

Body

personality
integer
required

The personality of the evaluator

agent
integer

Agent ID Example: 2142

assistant_id
string

Alternative to agent ID - the assistant ID to use for this scenario Example: "asst_1234567890"

name
string

Name of the scenario

Maximum string length: 80
instructions
string

Scenario Instructions

expected_outcome_prompt
string

Expected Outcome Prompt Example: "The user should be able to complete the order"

metrics
integer[]

List of metric IDs to associate with this evaluator Example: [123, 456, 789]

tags
string[]

List of tags to associate with the evaluator Example: ["tag1", "tag2", "tag3"]

tool_ids
string[]

List of tool IDs to use for evaluator

Example:
[
"TOOL_DTMF",
"TOOL_END_CALL",
"TOOL_END_CALL_ONLY_ON_TRANSFER"
]
test_profile
integer

The test profile ID to use for the evaluator

inbound_phone_number
integer

The inbound phone number ID to use for the evaluator

Response

id
integer
name
string

Name of the evaluator

agent
integer

Agent ID Example: 2142

personality
integer

ID of the personality

personality_name
string

Name of the personality

tags
string[]

List of tags of the evaluators Example: ["tag1", "tag2", "tag3"]

tool_ids
any

List of tool IDs to associate with this scenario Example: ["TOOL_DTMF", "TOOL_END_CALL"]

runs
integer[]

List of run IDs Example: [123, 456, 789]

metrics
integer[]

List of metric IDs Example: [123, 456, 789]

metric_names
string[]

List of metric names Example: ["Metric 1", "Metric 2", "Metric 3"]

phone_number
string

Phone number eg: +17776666333

outbound_phone_number_data
object

Phone number used for outbound calls in this scenario Example: "+1234567890"

first_message
string

First message of the evaluator

inbound_phone_number
integer | null
inbound_phone_number_data
object

Phone number used for inbound calls in this scenario Example: "+1234567890"

instructions
string

Instructions of the evaluator

simulation_description
string

Simulation Description

information_fields
object

Information fields of the evaluator Example:

{
"user_name": "John Doe",
"user_email": "[email protected]",
}
expected_outcome_prompt
string

Expected outcome prompt of the evaluator Example: "The user should be able to complete the order"

scenario_language
enum<string>

Language of the scenario

  • af - Afrikaans
  • ar - Arabic
  • bg - Bulgarian
  • zh - Chinese Simplified
  • cs - Czech
  • da - Danish
  • nl - Dutch
  • en - English
  • fi - Finnish
  • fr - French
  • de - German
  • el - Greek
  • hi - Hindi
  • he - Hebrew
  • hu - Hungarian
  • id - Indonesian
  • it - Italian
  • ja - Japanese
  • ko - Korean
  • ms - Malay
  • multi - Multilingual
  • no - Norwegian
  • pl - Polish
  • pt - Portuguese
  • ro - Romanian
  • ru - Russian
  • sk - Slovak
  • es - Spanish
  • sv - Swedish
  • th - Thai
  • tr - Turkish
  • ta - Tamil
  • uk - Ukrainian
  • vi - Vietnamese
Available options:
af,
ar,
bg,
zh,
cs,
da,
nl,
en,
fi,
fr,
de,
el,
hi,
he,
hu,
id,
it,
ja,
ko,
ms,
multi,
no,
pl,
pt,
ro,
ru,
sk,
es,
sv,
th,
tr,
ta,
uk,
vi
scenario_type
enum<string>
default:instruction

Type of scenario (instruction, real_world_smart, or real_world_fixed)

  • instruction - Instruction
  • real_world_smart - Real World Smart
  • real_world_fixed - Real World Fixed
Available options:
instruction,
real_world_smart,
real_world_fixed
test_profile
integer | null
test_profile_data
object

Details of the test profile associated with this scenario Example:

{
"id": "<integer>",
"agent_id": "<integer>",
"name": "<string>",
"information": {
"user_name": "<string>",
"user_email": "<string>",
"order_id": "<string>",
},
}