{ "openapi": "3.1.0", "info": { "title": "Bluejay API", "description": "Bluejay API", "version": "0.1.0" }, "paths": { "/v1/send-text": { "post": { "summary": "Recieve Text Processor", "description": "Process text input and return a response.", "operationId": "recieve_text_processor_v1_send_text_post", "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/TextProcessorRequest" } } }, "required": true }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": {} } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } }, "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ] } }, "/v1/api-keys": { "post": { "summary": "Create Api Key", "operationId": "create_api_key_v1_api_keys_post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CreateKeyIn" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/KeyOut" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/api-keys/{key_id}": { "delete": { "summary": "Revoke Key", "operationId": "revoke_key_v1_api_keys__key_id__delete", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "key_id", "in": "path", "required": true, "schema": { "type": "string", "title": "Key Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "204": { "description": "Successful Response" }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/generate-test-scenarios": { "post": { "summary": "Generate Test Scenarios", "description": "Generates test scenarios for a given simulation.\n\nAccepts a SimulationRequest with the following structure:\n{\n name: string;\n agent: Agent;\n promptId?: string;\n knowledgeBaseId?: string;\n scenarios: TestScenarioRequest[];\n callAllocation: {\n goalAdherence: { [key: string]: number };\n systemIntegrity: { [key: string]: number };\n customerPersonas: { [key: string]: number };\n workflowAdherence: { [key: string]: number };\n workflowAdherenceV2: { [key: string]: number };\n expectedToolCalls: [{name: string, output: string}, {name: string, output: string}, ...];\n customPrompt: {prompt: string, count: number};\n transcriptGeneration: [{transcript: string, success_criteria?: string, use_specific_utterances?: boolean}, ...];\n // For transcriptGeneration:\n // - transcript: Required. The transcript text to analyze\n // - success_criteria: Optional. If not provided, will be auto-generated from transcript\n // - If use_specific_utterances is true (default): customer utterances extracted and stored as JSON string in scenario description\n // - If use_specific_utterances is false: persona intent description generated in natural language\n csvCallAllocation: [{intent: string, success_criteria: string, count: number}, ...];\n // For csvCallAllocation:\n // - intent: Required. The customer intent/description for the scenario\n // - success_criteria: Required. The success criteria for the scenario\n // - count: Required. Number of scenarios to generate with this intent and success criteria\n };\n selectedProperties: {\n [category: string]: string[];\n };\n customerTraits?: [\n {name: string, data_type: \"boolean\" | \"string\" | \"date\" | \"number\"}\n ];\n}", "operationId": "generate_test_scenarios_v1_generate_test_scenarios_post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": {} } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/move-regen-test-scenarios": { "post": { "summary": "Move Regen Test Scenarios Endpoint", "description": "Regenerates test scenarios with a new goal while preserving scenario descriptions.\n\nAccepts a request with the following structure:\n{\n agent: Agent;\n promptId?: string;\n knowledgeBaseId?: string;\n scenarios: TestScenario[];\n newGoal: string;\n}", "operationId": "move_regen_test_scenarios_endpoint_v1_move_regen_test_scenarios_post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": {} } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/regen-test-scenarios": { "post": { "summary": "Regen Test Scenarios Endpoint", "description": "Regenerates test scenarios based on custom instructions while preserving style and structure.\n\nAccepts a request with the following structure:\n{\n agent: Agent;\n promptId?: string;\n knowledgeBaseId?: string;\n scenarios: TestScenario[];\n instructions: string;\n persona?: CustomerPersona;\n}", "operationId": "regen_test_scenarios_endpoint_v1_regen_test_scenarios_post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": {} } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/create-simulation": { "post": { "summary": "Create Simulation", "description": "Create a new simulation with the provided details.\n\nReturns the simulation id and a status code.", "operationId": "create_simulation_v1_create_simulation_post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SimulationRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SimulationResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/get-all-simulations": { "get": { "summary": "Get All Simulations", "description": "Get all simulations for a user.", "operationId": "get_all_simulations_v1_get_all_simulations_get", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/GetSimulationsResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/get-simulations-by-agent/{agent_id}": { "get": { "summary": "Get Simulations By Agent", "description": "Get all simulations for a specific agent.", "operationId": "get_simulations_by_agent_v1_get_simulations_by_agent__agent_id__get", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "agent_id", "in": "path", "required": true, "schema": { "type": "string", "title": "Agent Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/GetSimulationsResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/get-simulation-runs/{simulation_id}": { "get": { "summary": "Get Simulation Runs", "description": "Get all simulation runs for a specific simulation.", "operationId": "get_simulation_runs_v1_get_simulation_runs__simulation_id__get", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "simulation_id", "in": "path", "required": true, "schema": { "type": "string", "title": "Simulation Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/GetSimulationRunsResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/generate-digital-humans": { "post": { "summary": "Generate Digital Humans", "description": "Given an agent this endpoint generates digital humans to test that agent based on varying simulation types.", "operationId": "generate_digital_humans_v1_generate_digital_humans_post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/DigitalHumanRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/src__main__DigitalHumanResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/queue-simulation-run": { "post": { "summary": "Queue Simulation Run Endpoint", "description": "Queue a simulation run for processing.", "operationId": "queue_simulation_run_endpoint_v1_queue_simulation_run_post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/src__main__SimulationRunRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/src__main__SimulationRunResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/check-queue-simulation-run/{simulation_run_id}": { "post": { "summary": "Check Queue Simulation Run", "operationId": "check_queue_simulation_run_v1_check_queue_simulation_run__simulation_run_id__post", "parameters": [ { "name": "simulation_run_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Simulation Run Id" } }, { "name": "X-Webhook-Secret", "in": "header", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "X-Webhook-Secret" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": {} } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/create-schedule": { "post": { "summary": "Create Schedule", "operationId": "create_schedule_v1_create_schedule_post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CreateCronJobRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CreateCronJobResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/update-schedule/{schedule_id}": { "put": { "summary": "Update Schedule", "operationId": "update_schedule_v1_update_schedule__schedule_id__put", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "schedule_id", "in": "path", "required": true, "schema": { "type": "string", "title": "Schedule Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/UpdateCronJobRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/UpdateCronJobResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/delete-schedule/{schedule_id}": { "delete": { "summary": "Delete Schedule", "operationId": "delete_schedule_v1_delete_schedule__schedule_id__delete", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "schedule_id", "in": "path", "required": true, "schema": { "type": "string", "title": "Schedule Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/DeleteCronJobResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/retrieve-simulation-results/{simulation_run_id}": { "get": { "summary": "Retrieve Simulation Results", "description": "Retrieve the results of a simulation run.\n\nReturns the simulation run details and associated test cases.", "operationId": "retrieve_simulation_results_v1_retrieve_simulation_results__simulation_run_id__get", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "simulation_run_id", "in": "path", "required": true, "schema": { "type": "string", "title": "Simulation Run Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SimulationResultsResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/retrieve-simulation-result/{test_result_id}": { "get": { "summary": "Retrieve Simulation Result", "description": "Retrieve a single test result and its associated custom metrics.\n\nArgs:\n test_result_id: the ID of the test result to retrieve.\n\nReturns:\n the test result along with its custom metric results.", "operationId": "retrieve_simulation_result_v1_retrieve_simulation_result__test_result_id__get", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "test_result_id", "in": "path", "required": true, "schema": { "type": "string", "title": "Test Result Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SingleSimulationResultResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/generate-translated-transcript/{test_result_id}": { "post": { "summary": "Generate Translated Transcript", "description": "Generate a translated transcript for a given audio file.\n\nArgs:\n test_result_id: the ID of the test result to generate a translated transcript for.\n\nReturns:\n a dictionary with the status, message, and translated transcript url.", "operationId": "generate_translated_transcript_v1_generate_translated_transcript__test_result_id__post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "test_result_id", "in": "path", "required": true, "schema": { "type": "string", "title": "Test Result Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": {} } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/generate-custom-metrics": { "post": { "summary": "Generate Custom Metrics", "description": "Generate custom metrics for a given agent based on its description and knowledge base.", "operationId": "generate_custom_metrics_v1_generate_custom_metrics_post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/GenerateCustomMetricsRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": {} } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/generate-customer-personas": { "post": { "summary": "Generate Customer Personas", "description": "Generate custom personas for a given agent based on its description and knowledge base.", "operationId": "generate_customer_personas_v1_generate_customer_personas_post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/GenerateCustomPersonasRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": {} } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/ping": { "get": { "summary": "Pong", "operationId": "pong_v1_ping_get", "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": {} } } } }, "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ] } }, "/v1/compare-experiment-runs": { "post": { "summary": "Compare Experiment Runs", "description": "Compare multiple experiment runs and generate a summary of differences", "operationId": "compare_experiment_runs_v1_compare_experiment_runs_post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ComparisonRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ComparisonResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/end-conversations": { "post": { "summary": "End Conversations", "description": "End multiple running conversations by marking them in Redis for the LiveKit agent to terminate.\n\nThis endpoint:\n1. Checks that each test result exists and is in RUNNING status\n2. Writes control objects to Redis for the LiveKit agent to pick up\n3. Schedules a 30-second fallback watchdog for each conversation\n4. Returns which conversations were successfully marked for ending and which failed\n\nThe fallback watchdog ensures that if LiveKit fails to respond, the conversation\nstatus will be updated after 30 seconds to prevent it from appearing stuck forever.", "operationId": "end_conversations_v1_end_conversations_post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/EndConversationsRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/EndConversationsResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/regenerate-test-scenarios-from-community": { "post": { "tags": [ "Regeneration" ], "summary": "Regenerate Test Scenarios From Community", "operationId": "regenerate_test_scenarios_from_community_v1_regenerate_test_scenarios_from_community_post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": {} } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/add-agent": { "post": { "tags": [ "Agents" ], "summary": "Add Agent", "description": "Add a new agent to the system.\n\nReturns the agent id and a status code.", "operationId": "add_agent_v1_add_agent_post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/AgentRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/AgentResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/update-agent": { "post": { "tags": [ "Agents" ], "summary": "Update Agent", "description": "Update an existing agent in the system.", "operationId": "update_agent_v1_update_agent_post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/AgentUpdateRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/AgentUpdateResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/update-agent-by-external-id": { "put": { "tags": [ "Agents" ], "summary": "Update Agent By External Id", "description": "Update an existing agent in the system by external ID.", "operationId": "update_agent_by_external_id_v1_update_agent_by_external_id_put", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/AgentUpdateWithExternalIdRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/AgentUpdateResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/agents/{agent_id}": { "get": { "tags": [ "Agents" ], "summary": "Get Agent", "description": "Get an agent by ID.", "operationId": "get_agent_v1_agents__agent_id__get", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "agent_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Agent Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/AgentPydantic" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/agent-by-external-id/{external_id}": { "get": { "tags": [ "Agents" ], "summary": "Get Agent By External Id", "description": "Get an agent by external ID.", "operationId": "get_agent_by_external_id_v1_agent_by_external_id__external_id__get", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "external_id", "in": "path", "required": true, "schema": { "type": "string", "title": "External Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/AgentPydantic" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/all-agents": { "get": { "tags": [ "Agents" ], "summary": "Get All Agents", "description": "Get all your agents.", "operationId": "get_all_agents_v1_all_agents_get", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "type": "array", "items": { "$ref": "#/components/schemas/AgentPydantic" }, "title": "Response Get All Agents V1 All Agents Get" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/agent/{agent_id}": { "delete": { "tags": [ "Agents" ], "summary": "Delete Agent", "description": "Delete an agent by ID.", "operationId": "delete_agent_v1_agent__agent_id__delete", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "agent_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Agent Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/AgentResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/generate-http-webhook-key": { "post": { "tags": [ "Agents" ], "summary": "Generate Http Webhook Key", "description": "Generate a new signing key for an HTTP agent's webhook", "operationId": "generate_http_webhook_key_v1_generate_http_webhook_key_post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/AgentWebhookKeyRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/AgentWebhookKeyResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/get-http-webhook-key": { "post": { "tags": [ "Agents" ], "summary": "Get Http Webhook Key", "description": "Get the signing key for an HTTP agent's webhook", "operationId": "get_http_webhook_key_v1_get_http_webhook_key_post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/AgentWebhookKeyRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/AgentWebhookKeyResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/create-folder": { "post": { "tags": [ "Folders" ], "summary": "Create Folder", "description": "Create a new folder for organizing agents.\n\nReturns the created folder details.", "operationId": "create_folder_v1_create_folder_post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/FolderCreateRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/FolderResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/all-folders": { "get": { "tags": [ "Folders" ], "summary": "Get All Folders", "description": "Get all folders for the authenticated user's organization.\n\nReturns a list of all folders with their details.", "operationId": "get_all_folders_v1_all_folders_get", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "type": "array", "items": { "$ref": "#/components/schemas/FolderResponse" }, "title": "Response Get All Folders V1 All Folders Get" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/folder/{folder_id}": { "get": { "tags": [ "Folders" ], "summary": "Get Folder", "description": "Get a specific folder by ID.\n\nReturns the folder details if it exists and belongs to the user's organization.", "operationId": "get_folder_v1_folder__folder_id__get", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "folder_id", "in": "path", "required": true, "schema": { "type": "string", "format": "uuid", "title": "Folder Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/FolderResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } }, "delete": { "tags": [ "Folders" ], "summary": "Delete Folder", "description": "Delete a folder.\n\nNote: This will set the folder_id to NULL for all agents in this folder.\nReturns the deleted folder ID and status.", "operationId": "delete_folder_v1_folder__folder_id__delete", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "folder_id", "in": "path", "required": true, "schema": { "type": "string", "format": "uuid", "title": "Folder Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/FolderDeleteResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/folders/move-agent": { "put": { "tags": [ "Folders" ], "summary": "Move Agent To Folder", "description": "Move an agent to a folder or disassociate it from any folder.\n\n- If folder_id is provided: Associates the agent with that folder\n- If folder_id is null: Disassociates the agent from any folder\n\nBoth the agent and folder (if provided) must belong to the user's organization.", "operationId": "move_agent_to_folder_v1_folders_move_agent_put", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/MoveAgentRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/MoveAgentResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/update-folder/{folder_id}": { "put": { "tags": [ "Folders" ], "summary": "Update Folder", "description": "Update a folder's name.\n\nReturns the updated folder details.", "operationId": "update_folder_v1_update_folder__folder_id__put", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "folder_id", "in": "path", "required": true, "schema": { "type": "string", "format": "uuid", "title": "Folder Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/FolderUpdateRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/FolderResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/get-agents-by-folder/{folder_id}": { "get": { "tags": [ "Folders" ], "summary": "Get Agents By Folder", "description": "Get all agents in a specific folder.\n\nReturns a list of agent IDs and names in the folder.", "operationId": "get_agents_by_folder_v1_get_agents_by_folder__folder_id__get", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "folder_id", "in": "path", "required": true, "schema": { "type": "string", "format": "uuid", "title": "Folder Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "type": "array", "items": { "$ref": "#/components/schemas/AgentPydantic" }, "title": "Response Get Agents By Folder V1 Get Agents By Folder Folder Id Get" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/simulation/{simulation_id}": { "delete": { "tags": [ "Simulations" ], "summary": "Delete Simulation", "description": "Delete a specific simulation by ID.", "operationId": "delete_simulation_v1_simulation__simulation_id__delete", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "simulation_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Simulation Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/DeleteSimulationResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } }, "put": { "tags": [ "Simulations" ], "summary": "Update Simulation", "description": "update a specific simulation by id.\n\nonly fields provided in the request body will be updated.", "operationId": "update_simulation_v1_simulation__simulation_id__put", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "simulation_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Simulation Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/src__api__simulations__UpdateSimulationRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SimulationPydantic" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } }, "get": { "tags": [ "Simulations" ], "summary": "Get Simulation", "description": "Get a specific simulation by ID.", "operationId": "get_simulation_v1_simulation__simulation_id__get", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "simulation_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Simulation Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SimulationPydantic" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/simulation/{simulation_id}/add-digital-humans": { "post": { "tags": [ "Simulations" ], "summary": "Add Digital Humans To Simulation", "description": "add existing digital humans to a simulation without replacing existing associations.", "operationId": "add_digital_humans_to_simulation_v1_simulation__simulation_id__add_digital_humans_post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "simulation_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Simulation Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/AddDigitalHumansToSimulationRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/AddDigitalHumansToSimulationResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/simulation/{simulation_id}/remove-digital-humans": { "post": { "tags": [ "Simulations" ], "summary": "Remove Digital Humans From Simulation", "description": "remove digital humans from a simulation (unlink only); idempotent for missing links.", "operationId": "remove_digital_humans_from_simulation_v1_simulation__simulation_id__remove_digital_humans_post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "simulation_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Simulation Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/RemoveDigitalHumansFromSimulationRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/RemoveDigitalHumansFromSimulationResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/simulation-result/{simulation_result_id}": { "delete": { "tags": [ "Simulation Runs" ], "summary": "Delete Simulation Result", "description": "Delete a single simulation result (one row in run details) by ID.", "operationId": "delete_simulation_result_v1_simulation_result__simulation_result_id__delete", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "simulation_result_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Simulation Result Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/DeleteSimulationResultResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/simulation-run/{simulation_run_id}": { "delete": { "tags": [ "Simulation Runs" ], "summary": "Delete Simulation Run", "description": "Delete a single simulation run by ID. This will also delete all associated test results.", "operationId": "delete_simulation_run_v1_simulation_run__simulation_run_id__delete", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "simulation_run_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Simulation Run Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/DeleteSimulationRunResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/create-custom-metric": { "post": { "tags": [ "Custom Metrics" ], "summary": "Create Custom Metric", "description": "Create a new custom metric.", "operationId": "create_custom_metric_v1_create_custom_metric_post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CreateCustomMetricRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CustomMetricResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/create-custom-metrics": { "post": { "tags": [ "Custom Metrics" ], "summary": "Create Custom Metrics", "description": "Create multiple custom metrics synchronously using a single bulk insert.", "operationId": "create_custom_metrics_v1_create_custom_metrics_post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CreateCustomMetricsBulkRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CreateCustomMetricsBulkResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/custom-metric/{metric_id}": { "get": { "tags": [ "Custom Metrics" ], "summary": "Get Custom Metric", "description": "Get a specific custom metric by ID.", "operationId": "get_custom_metric_v1_custom_metric__metric_id__get", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "metric_id", "in": "path", "required": true, "schema": { "type": "string", "format": "uuid", "title": "Metric Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CustomMetricResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } }, "delete": { "tags": [ "Custom Metrics" ], "summary": "Delete Custom Metric", "description": "Delete a specific custom metric by ID.", "operationId": "delete_custom_metric_v1_custom_metric__metric_id__delete", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "metric_id", "in": "path", "required": true, "schema": { "type": "string", "format": "uuid", "title": "Metric Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/src__models__custom_metric__CustomMetric" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/custom-metrics": { "get": { "tags": [ "Custom Metrics" ], "summary": "Get Custom Metrics", "description": "Get all custom metrics, optionally filtered by agent, with pagination.", "operationId": "get_custom_metrics_v1_custom_metrics_get", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "agent_id", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Agent Id" } }, { "name": "page", "in": "query", "required": false, "schema": { "type": "integer", "default": 1, "title": "Page" } }, { "name": "page_size", "in": "query", "required": false, "schema": { "type": "integer", "default": 50, "title": "Page Size" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CustomMetricsListResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/custom-metrics-by-agent/{agent_id}": { "get": { "tags": [ "Custom Metrics" ], "summary": "Get Custom Metrics By Agent", "description": "Get all custom metrics for an agent.\n\n**DEPRECATED**: This endpoint is deprecated. Please use GET /custom-metrics?agent_id={agent_id} instead,\nwhich supports pagination and additional features.", "operationId": "get_custom_metrics_by_agent_v1_custom_metrics_by_agent__agent_id__get", "deprecated": true, "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "agent_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Agent Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CustomMetricsListResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/update-custom-metric/{metric_id}": { "put": { "tags": [ "Custom Metrics" ], "summary": "Update Custom Metric", "description": "Update a specific custom metric by ID.", "operationId": "update_custom_metric_v1_update_custom_metric__metric_id__put", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "metric_id", "in": "path", "required": true, "schema": { "type": "string", "format": "uuid", "title": "Metric Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/UpdateCustomMetricRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CustomMetricResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/update-custom-metrics": { "put": { "tags": [ "Custom Metrics" ], "summary": "Bulk Update Custom Metrics", "description": "Bulk update custom metrics: apply the same patch to each metric in metric_ids.\nOnly keys present in updates are applied; each key's value (including null) is written.", "operationId": "bulk_update_custom_metrics_v1_update_custom_metrics_put", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/BulkUpdateCustomMetricsRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/BulkUpdateCustomMetricsResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/create-alert": { "post": { "tags": [ "Alerts" ], "summary": "Create Alert", "description": "Create a new alert with optional agent associations", "operationId": "create_alert_v1_create_alert_post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CreateAlertRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/AlertResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/update-alert/{alert_id}": { "put": { "tags": [ "Alerts" ], "summary": "Update Alert", "description": "Update an existing alert", "operationId": "update_alert_v1_update_alert__alert_id__put", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "alert_id", "in": "path", "required": true, "schema": { "type": "string", "format": "uuid", "title": "Alert Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/UpdateAlertRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/AlertResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/alert/{alert_id}": { "delete": { "tags": [ "Alerts" ], "summary": "Delete Alert", "description": "Delete an alert and its agent associations", "operationId": "delete_alert_v1_alert__alert_id__delete", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "alert_id", "in": "path", "required": true, "schema": { "type": "string", "format": "uuid", "title": "Alert Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/DeleteAlertResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/weekly-notifications": { "post": { "tags": [ "Weekly notifications" ], "summary": "Post Weekly Notifications", "description": "Upsert weekly digest notification targets (and optionally UTC weekly schedule) for the current org.", "operationId": "post_weekly_notifications_v1_weekly_notifications_post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/WeeklyNotificationsBody" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/WeeklyNotificationsPostResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/create-customer-persona": { "post": { "tags": [ "Customer Personas" ], "summary": "Create Customer Persona", "description": "Create a new customer persona.", "operationId": "create_customer_persona_v1_create_customer_persona_post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CreateCustomerPersonaRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CustomerPersonaPydantic" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/customer-personas-by-agent/{agent_id}": { "get": { "tags": [ "Customer Personas" ], "summary": "Get Customer Personas By Agent", "description": "Get all customer personas for an agent.", "operationId": "get_customer_personas_by_agent_v1_customer_personas_by_agent__agent_id__get", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "agent_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Agent Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "type": "array", "items": { "$ref": "#/components/schemas/CustomerPersonaPydantic" }, "title": "Response Get Customer Personas By Agent V1 Customer Personas By Agent Agent Id Get" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/customer-persona/{persona_id}": { "get": { "tags": [ "Customer Personas" ], "summary": "Get Customer Persona", "description": "Get a specific customer persona by ID.", "operationId": "get_customer_persona_v1_customer_persona__persona_id__get", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "persona_id", "in": "path", "required": true, "schema": { "type": "string", "format": "uuid", "title": "Persona Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CustomerPersonaPydantic" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } }, "delete": { "tags": [ "Customer Personas" ], "summary": "Delete Customer Persona", "description": "Delete a specific customer persona by ID.", "operationId": "delete_customer_persona_v1_customer_persona__persona_id__delete", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "persona_id", "in": "path", "required": true, "schema": { "type": "string", "format": "uuid", "title": "Persona Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CustomerPersonaPydantic" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/update-customer-persona/{persona_id}": { "put": { "tags": [ "Customer Personas" ], "summary": "Update Customer Persona", "description": "Update a specific customer persona by ID.", "operationId": "update_customer_persona_v1_update_customer_persona__persona_id__put", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "persona_id", "in": "path", "required": true, "schema": { "type": "string", "format": "uuid", "title": "Persona Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/UpdateCustomerPersonaRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CustomerPersonaPydantic" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/metrics-lab/evaluate-conversation": { "post": { "tags": [ "Metrics Lab" ], "summary": "Evaluate Conversation", "description": "Queue a conversation (call or test_result) for evaluation in the metrics lab.", "operationId": "evaluate_conversation_v1_metrics_lab_evaluate_conversation_post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/EvaluateConversationRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/EvaluateConversationResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/metrics-lab/lab": { "post": { "tags": [ "Metrics Lab" ], "summary": "Create Lab", "description": "Create a new lab.", "operationId": "create_lab_v1_metrics_lab_lab_post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CreateLabRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/LabResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/metrics-lab/lab/{lab_id}": { "put": { "tags": [ "Metrics Lab" ], "summary": "Update Lab", "description": "Update a specific lab by ID.", "operationId": "update_lab_v1_metrics_lab_lab__lab_id__put", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "lab_id", "in": "path", "required": true, "schema": { "type": "string", "format": "uuid", "title": "Lab Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/UpdateLabRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/LabResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } }, "delete": { "tags": [ "Metrics Lab" ], "summary": "Delete Lab", "description": "Delete a specific lab by ID.", "operationId": "delete_lab_v1_metrics_lab_lab__lab_id__delete", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "lab_id", "in": "path", "required": true, "schema": { "type": "string", "format": "uuid", "title": "Lab Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/DeleteLabResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/metrics-lab/lab/{lab_id}/metrics": { "post": { "tags": [ "Metrics Lab" ], "summary": "Add Metrics To Lab", "description": "Add metrics to an existing lab.", "operationId": "add_metrics_to_lab_v1_metrics_lab_lab__lab_id__metrics_post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "lab_id", "in": "path", "required": true, "schema": { "type": "string", "format": "uuid", "title": "Lab Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/AddMetricsToLabRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/AddMetricsToLabResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/metrics-lab/lab/{lab_id}/conversations": { "post": { "tags": [ "Metrics Lab" ], "summary": "Add Conversations To Lab", "description": "Add conversations to an existing lab.", "operationId": "add_conversations_to_lab_v1_metrics_lab_lab__lab_id__conversations_post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "lab_id", "in": "path", "required": true, "schema": { "type": "string", "format": "uuid", "title": "Lab Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/AddConversationsToLabRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/AddConversationsToLabResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } }, "delete": { "tags": [ "Metrics Lab" ], "summary": "Remove Conversations From Lab", "description": "Remove one or more conversations from an existing lab.", "operationId": "remove_conversations_from_lab_v1_metrics_lab_lab__lab_id__conversations_delete", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "lab_id", "in": "path", "required": true, "schema": { "type": "string", "format": "uuid", "title": "Lab Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/RemoveConversationsFromLabRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": {} } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/metrics-lab/lab/{lab_id}/human-evaluation": { "put": { "tags": [ "Metrics Lab" ], "summary": "Create Or Update Human Evaluation", "description": "Create or update a human evaluation for a lab metric result.", "operationId": "create_or_update_human_evaluation_v1_metrics_lab_lab__lab_id__human_evaluation_put", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "lab_id", "in": "path", "required": true, "schema": { "type": "string", "format": "uuid", "title": "Lab Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CreateOrUpdateHumanEvaluationRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HumanEvaluationResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/metrics-lab/lab/{lab_id}/metric-revisions": { "post": { "tags": [ "Metrics Lab" ], "summary": "Create Metric Revision", "description": "Create a new metric revision for a lab. Revision number is auto-incremented by DB trigger.", "operationId": "create_metric_revision_v1_metrics_lab_lab__lab_id__metric_revisions_post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "lab_id", "in": "path", "required": true, "schema": { "type": "string", "format": "uuid", "title": "Lab Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CreateMetricRevisionRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/MetricRevisionResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/metrics-lab/lab/{lab_id}/settings": { "put": { "tags": [ "Metrics Lab" ], "summary": "Update Lab Settings", "description": "Update lab settings, merging with existing settings to avoid overwriting other settings.", "operationId": "update_lab_settings_v1_metrics_lab_lab__lab_id__settings_put", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "lab_id", "in": "path", "required": true, "schema": { "type": "string", "format": "uuid", "title": "Lab Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/UpdateLabSettingsRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/UpdateLabSettingsResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/generate-goals": { "post": { "tags": [ "Goals" ], "summary": "Generate Goals Endpoint", "description": "Generate high-level goals for a given agent based on its description and knowledge base.", "operationId": "generate_goals_endpoint_v1_generate_goals_post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/GenerateGoalsRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": {} } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/traces/{trace_id}": { "post": { "tags": [ "Traces" ], "summary": "Get Trace", "operationId": "get_trace_v1_traces__trace_id__post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "trace_id", "in": "path", "required": true, "schema": { "type": "string", "title": "Trace Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": {} } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/spans/{trace_id}/{span_id}": { "post": { "tags": [ "Traces" ], "summary": "Get Span", "operationId": "get_span_v1_spans__trace_id___span_id__post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "trace_id", "in": "path", "required": true, "schema": { "type": "string", "title": "Trace Id" } }, { "name": "span_id", "in": "path", "required": true, "schema": { "type": "string", "title": "Span Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": {} } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/traces": { "get": { "tags": [ "Traces" ], "summary": "Get All Traces", "description": "Get all traces for the authenticated user's organization.", "operationId": "get_all_traces_v1_traces_get", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "limit", "in": "query", "required": false, "schema": { "type": "integer", "maximum": 100, "minimum": 1, "description": "Number of traces to return", "default": 50, "title": "Limit" }, "description": "Number of traces to return" }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": {} } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/phone-numbers": { "get": { "tags": [ "Phone Numbers" ], "summary": "Get Phone Numbers", "description": "Return phone number under an org", "operationId": "get_phone_numbers_v1_phone_numbers_get", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "type": "array", "items": { "$ref": "#/components/schemas/PhoneNumberResponse" }, "title": "Response Get Phone Numbers V1 Phone Numbers Get" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/phone-numbers/add": { "post": { "tags": [ "Phone Number Management" ], "summary": "Add Phone Number", "operationId": "add_phone_number_v1_phone_numbers_add_post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/AddPhoneNumberRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/AddPhoneNumberResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/phone-numbers/{phone_number}/release": { "delete": { "tags": [ "Phone Number Management" ], "summary": "Release Phone Number", "operationId": "release_phone_number_v1_phone_numbers__phone_number__release_delete", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "phone_number", "in": "path", "required": true, "schema": { "type": "string", "title": "Phone Number" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ReleasePhoneNumberResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/integrations/retell": { "post": { "tags": [ "retell" ], "summary": "Handle Webhook", "description": "Handle Retell webhook events. Signature verification runs before any business logic\n(including the call_analysis wait path) so unauthenticated clients cannot elicit 200s.", "operationId": "handle_webhook_v1_integrations_retell_post", "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": {} } } } }, "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ] } }, "/v1/integrations/bland": { "post": { "tags": [ "bland" ], "summary": "Handle Webhook", "operationId": "handle_webhook_v1_integrations_bland_post", "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": {} } } } }, "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ] } }, "/v1/integrations/vapi": { "post": { "tags": [ "vapi" ], "summary": "Handle Webhook", "description": "Handle VAPI webhook events.", "operationId": "handle_webhook_v1_integrations_vapi_post", "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": {} } } } }, "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ] } }, "/v1/integrations/vapi/sync": { "post": { "tags": [ "vapi" ], "summary": "Sync Vapi Agents", "description": "Trigger an async sync of all Vapi assistants into Bluejay agents.\n\nAdmins may pass organization_id to sync any org.\nNon-admins are restricted to their own org.", "operationId": "sync_vapi_agents_v1_integrations_vapi_sync_post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SyncVapiAgentsRequest", "default": { "dry_run": true } } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": {} } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/integrations/vapi/sync-agent": { "post": { "tags": [ "vapi" ], "summary": "Sync Single Agent From Vapi", "description": "Trigger an async sync of a single Vapi agent's name and prompt from Vapi.", "operationId": "sync_single_agent_from_vapi_v1_integrations_vapi_sync_agent_post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SyncSingleAgentFromVapiRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": {} } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/queue-sms-simulation-run": { "post": { "tags": [ "Text Simulations" ], "summary": "Queue Sms Simulation Run", "operationId": "queue_sms_simulation_run_v1_queue_sms_simulation_run_post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/src__text_agents__sms_text_agent_api__SimulationRunRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/src__text_agents__sms_text_agent_api__SimulationRunResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/receive-text-message": { "post": { "tags": [ "Text Simulations" ], "summary": "Receive Text Message", "operationId": "receive_text_message_v1_receive_text_message_post", "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": {} } } } }, "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ] } }, "/v1/queue-http-text-simulation-run": { "post": { "tags": [ "HTTP Text Agent" ], "summary": "Queue Http Simulation Run", "description": "Queue a new simulation run and test results for HTTP text agent.\nTakes simulation_id, optional prompt_id, knowledge_base_id, and digital_human_ids.\nIf digital_human_ids is not provided, uses all digital humans for the simulation.\nReturns simulation_run_id (experiment_run_id) and simulation_result_ids (array of test result IDs).", "operationId": "queue_http_simulation_run_v1_queue_http_text_simulation_run_post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HttpSimulationRunRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HttpSimulationRunResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/send-http-text-message": { "post": { "tags": [ "HTTP Text Agent" ], "summary": "Send Http Text Message", "description": "Receive a text message via HTTP, process it through the lambda, and send response to webhook.\nUses simulation_result_id (test_result_id) for Redis operations and evaluations.", "operationId": "send_http_text_message_v1_send_http_text_message_post", "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HttpTextMessageRequest" } } }, "required": true }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HttpTextMessageResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } }, "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ] } }, "/v1/call-webhook": { "post": { "tags": [ "Twilio SIP Webhook" ], "summary": "Handle Call Webhook", "description": "Handle call webhook events\n\nWebhook is triggered when a call is made via Twilio Programmable SIP domain.", "operationId": "handle_call_webhook_v1_call_webhook_post", "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": {} } } } }, "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ] } }, "/v1/generate-signing-key": { "post": { "tags": [ "Webhook Management" ], "summary": "Generate Signing Key", "description": "Generate a new signing key for a webhook", "operationId": "generate_signing_key_v1_generate_signing_key_post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/WebhookKeyRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/WebhookKeyResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/get-signing-key": { "post": { "tags": [ "Webhook Management" ], "summary": "Get Signing Key", "description": "Get the signing key for a webhook", "operationId": "get_signing_key_v1_get_signing_key_post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/WebhookKeyRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/WebhookKeyResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/integrations": { "get": { "tags": [ "Integration Keys" ], "summary": "Get Integrations", "description": "Return integration metadata for the authenticated org.\nSecret fields are returned as null with companion _set booleans.", "operationId": "get_integrations_v1_integrations_get", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": {} } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } }, "patch": { "tags": [ "Integration Keys" ], "summary": "Patch Integrations", "description": "Update integration fields. Secret fields are encrypted before storage.\nSend null to clear a field. Only include fields that changed.\nPrefer POST /update-integrations for a typed, agent-style contract.", "operationId": "patch_integrations_v1_integrations_patch", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": {} } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/get-integration-key": { "post": { "tags": [ "Integration Keys" ], "summary": "Get Integration Key", "description": "Decrypt and return a single integration secret field.", "operationId": "get_integration_key_v1_get_integration_key_post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/IntegrationKeyRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/IntegrationKeyResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/update-integrations": { "post": { "tags": [ "Integration Keys" ], "summary": "Update Integrations", "description": "Update integration fields for the authenticated org (middleware encrypts secrets before DB write).\nSame semantics as PATCH /integrations: only send fields to change; null clears a field.", "operationId": "update_integrations_v1_update_integrations_post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/IntegrationsUpdateResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/create-digital-human": { "post": { "tags": [ "Digital Humans" ], "summary": "Create Digital Human", "description": "Create a new digital human.", "operationId": "create_digital_human_v1_create_digital_human_post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CreateDigitalHumanRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/src__models__digital_humans__digital_human_response__DigitalHumanResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/digital-human/{digital_human_id}": { "get": { "tags": [ "Digital Humans" ], "summary": "Get Digital Human", "description": "Get a digital human by ID.", "operationId": "get_digital_human_v1_digital_human__digital_human_id__get", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "digital_human_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Digital Human Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/src__models__digital_humans__digital_human_response__DigitalHumanResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } }, "delete": { "tags": [ "Digital Humans" ], "summary": "Delete Digital Human", "description": "Delete a digital human by ID.", "operationId": "delete_digital_human_v1_digital_human__digital_human_id__delete", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "digital_human_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Digital Human Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/DigitalHumanResponseData" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/digital-humans-by-simulation/{simulation_id}": { "get": { "tags": [ "Digital Humans" ], "summary": "Get Digital Humans By Simulation", "description": "Get digital humans by simulation ID.", "operationId": "get_digital_humans_by_simulation_v1_digital_humans_by_simulation__simulation_id__get", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "simulation_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Simulation Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/DigitalHumansListResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/update-digital-human/{digital_human_id}": { "put": { "tags": [ "Digital Humans" ], "summary": "Update Digital Human", "description": "Update a digital human by ID.", "operationId": "update_digital_human_v1_update_digital_human__digital_human_id__put", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "digital_human_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Digital Human Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/UpdateDigitalHumanRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/src__models__digital_humans__digital_human_response__DigitalHumanResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/generate-objectives": { "post": { "tags": [ "Digital Humans" ], "summary": "Generate Objectives Endpoint", "description": "Generate objectives for a test case from its intent.", "operationId": "generate_objectives_endpoint_v1_generate_objectives_post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/GenerateObjectivesRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/GenerateObjectivesResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/generate-intent-summary": { "post": { "tags": [ "Digital Humans" ], "summary": "Generate Intent Summary Endpoint", "description": "Generate intent summary for a test case (only if intent exceeds character limit).", "operationId": "generate_intent_summary_endpoint_v1_generate_intent_summary_post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/GenerateIntentSummaryRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/GenerateIntentSummaryResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/generate-prompt-summary": { "post": { "tags": [ "Digital Humans" ], "summary": "Generate Prompt Summary Endpoint", "description": "Generate prompt summary for a prompt (only if prompt exceeds character limit).", "operationId": "generate_prompt_summary_endpoint_v1_generate_prompt_summary_post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/GeneratePromptSummaryRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/GeneratePromptSummaryResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/generate-formatted-transcript": { "post": { "tags": [ "Digital Humans" ], "summary": "Generate Formatted Transcript Endpoint", "description": "Take a raw transcript and return the structured transcript, derived utterances, and speaks_first.", "operationId": "generate_formatted_transcript_endpoint_v1_generate_formatted_transcript_post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/GenerateFormattedTranscriptRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/GenerateFormattedTranscriptResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/create-customer-trait": { "post": { "tags": [ "Customer Traits" ], "summary": "Create Customer Trait", "description": "Create a new customer trait definition for an agent.\n\nArgs:\n trait_request: The trait creation request data\n request: FastAPI request object\n auth: Authentication credentials\n\nReturns:\n CustomerTraitResponse with the created trait details", "operationId": "create_customer_trait_v1_create_customer_trait_post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CreateCustomerTraitRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CustomerTraitResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/customer-trait/{trait_id}": { "get": { "tags": [ "Customer Traits" ], "summary": "Get Customer Trait", "description": "Get a specific customer trait by ID.\n\nArgs:\n trait_id: UUID of the customer trait\n request: FastAPI request object\n auth: Authentication credentials\n\nReturns:\n CustomerTraitResponse with the trait details", "operationId": "get_customer_trait_v1_customer_trait__trait_id__get", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "trait_id", "in": "path", "required": true, "schema": { "type": "string", "format": "uuid", "title": "Trait Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CustomerTraitResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } }, "delete": { "tags": [ "Customer Traits" ], "summary": "Delete Customer Trait", "description": "Delete a customer trait definition.\n\nArgs:\n trait_id: UUID of the customer trait to delete\n request: FastAPI request object\n auth: Authentication credentials\n\nReturns:\n DeleteCustomerTraitResponse confirming the deletion", "operationId": "delete_customer_trait_v1_customer_trait__trait_id__delete", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "trait_id", "in": "path", "required": true, "schema": { "type": "string", "format": "uuid", "title": "Trait Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/DeleteCustomerTraitResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/customer-traits": { "get": { "tags": [ "Customer Traits" ], "summary": "Get Customer Traits", "description": "Get all customer traits, optionally filtered by agent_id.\n\nArgs:\n request: FastAPI request object\n agent_id: Optional agent ID to filter traits by\n auth: Authentication credentials\n\nReturns:\n CustomerTraitsListResponse with list of traits and total count", "operationId": "get_customer_traits_v1_customer_traits_get", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "agent_id", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Agent Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CustomerTraitsListResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/update-customer-trait/{trait_id}": { "put": { "tags": [ "Customer Traits" ], "summary": "Update Customer Trait", "description": "Update a customer trait definition.\n\nArgs:\n trait_id: UUID of the customer trait to update\n trait_request: The trait update request data\n request: FastAPI request object\n auth: Authentication credentials\n\nReturns:\n CustomerTraitResponse with the updated trait details", "operationId": "update_customer_trait_v1_update_customer_trait__trait_id__put", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "trait_id", "in": "path", "required": true, "schema": { "type": "string", "format": "uuid", "title": "Trait Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/UpdateCustomerTraitRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CustomerTraitResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/generate-trait-values": { "post": { "tags": [ "Customer Traits" ], "summary": "Generate Trait Values Endpoint", "description": "Generate trait values for each scenario for a single trait.\n\nRequest:\n - scenarios: list of scenario descriptions (intents), one per scenario\n - traits: exactly one trait (name + data_type)\n\nResponse:\n - dict mapping scenario index -> list of trait dicts\n - each trait dict has:\n {\n \"name\": , # same as the input trait name\n \"data_type\": , # normalized data type string\n \"value\": , # value for that scenario + trait\n }\n\nFrontend mapping:\n - for scenario index i:\n const traitsForScenario = res[i]; // array of trait dicts\n const value = traitsForScenario.find(t => t.name === traitName)?.value;", "operationId": "generate_trait_values_endpoint_v1_generate_trait_values_post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/GenerateTraitValuesRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "type": "object", "additionalProperties": { "type": "array", "items": { "type": "object", "additionalProperties": true } }, "title": "Response Generate Trait Values Endpoint V1 Generate Trait Values Post" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/create-community": { "post": { "tags": [ "Communities" ], "summary": "Create Community", "description": "Create a new community.", "operationId": "create_community_v1_create_community_post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CreateCommunityRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CommunityResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/community/{community_id}": { "get": { "tags": [ "Communities" ], "summary": "Get Community", "description": "Get a specific community by ID.", "operationId": "get_community_v1_community__community_id__get", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "community_id", "in": "path", "required": true, "schema": { "type": "string", "format": "uuid", "title": "Community Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CommunityResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } }, "delete": { "tags": [ "Communities" ], "summary": "Delete Community", "description": "Delete a specific community by ID.", "operationId": "delete_community_v1_community__community_id__delete", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "community_id", "in": "path", "required": true, "schema": { "type": "string", "format": "uuid", "title": "Community Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CommunityResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/communities": { "get": { "tags": [ "Communities" ], "summary": "Get Communities", "description": "Get all communities, optionally filtered by digital human (test case).", "operationId": "get_communities_v1_communities_get", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "digital_human_id", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Digital Human Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CommunitiesListResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/update-community/{community_id}": { "put": { "tags": [ "Communities" ], "summary": "Update Community", "description": "Update a specific community by ID.", "operationId": "update_community_v1_update_community__community_id__put", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "community_id", "in": "path", "required": true, "schema": { "type": "string", "format": "uuid", "title": "Community Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/UpdateCommunityRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CommunityResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/add-to-community/{community_id}": { "put": { "tags": [ "Communities" ], "summary": "Add Digital Humans To Community", "description": "Add digital humans to an existing community without replacing the current list.", "operationId": "add_digital_humans_to_community_v1_add_to_community__community_id__put", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "community_id", "in": "path", "required": true, "schema": { "type": "string", "format": "uuid", "title": "Community Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/AddToCommunityRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CommunityResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/subscription/signup": { "post": { "tags": [ "Subscription" ], "summary": "Signup", "description": "Create subscription: Stripe customer + Metronome customer + contract.", "operationId": "signup_v1_subscription_signup_post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SignupRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SignupResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/subscription/start-trial": { "post": { "tags": [ "Subscription" ], "summary": "Start Trial", "description": "Start a 7-day free trial only. Call this when a new account is created.", "operationId": "start_trial_v1_subscription_start_trial_post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StartTrialRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SignupResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/subscription/active-package": { "get": { "tags": [ "Subscription" ], "summary": "Get Active Package", "description": "Get the user's active package ID from their Metronome contract.", "operationId": "get_active_package_v1_subscription_active_package_get", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ActivePackageResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/subscription/cancel": { "post": { "tags": [ "Subscription" ], "summary": "Cancel Subscription", "description": "Cancel subscription self-serve by ending the active Metronome contract\nat the end of the current billing period (updateEndDate).", "operationId": "cancel_subscription_v1_subscription_cancel_post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CancelResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/evaluate-call": { "post": { "tags": [ "Evaluate" ], "summary": "Evaluate", "description": "Submit a call or chat for evaluation.\n\nReturns an eval ID that can be used to track evaluation status.", "operationId": "evaluate_v1_evaluate_call_post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "anyOf": [ { "$ref": "#/components/schemas/CallRequestUsingAgentId" }, { "$ref": "#/components/schemas/CallRequestUsingExternalAgentId" } ], "title": "Call Data" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/EvaluateCallResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/evaluate": { "post": { "tags": [ "Evaluate" ], "summary": "Evaluate", "description": "Submit a call or chat for evaluation.\n\nReturns an eval ID that can be used to track evaluation status.", "operationId": "evaluate_v1_evaluate_post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "anyOf": [ { "$ref": "#/components/schemas/CallRequestUsingAgentId" }, { "$ref": "#/components/schemas/CallRequestUsingExternalAgentId" } ], "title": "Call Data" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/EvaluateCallResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/integrations/ElevenLabs": { "post": { "tags": [ "ElevenLabs" ], "summary": "Handle Webhook", "operationId": "handle_webhook_v1_integrations_ElevenLabs_post", "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": {} } } } }, "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ] } }, "/v1/agents/{agent_id}/prompts": { "get": { "tags": [ "Prompts" ], "summary": "Get Prompt By Label Agent Scoped", "description": "retrieve a single prompt by label under /agents/{agent_id}/prompts?label=... .\n\n- if label is missing -> 400\n- if label resolves to 0 -> 404; >1 -> 400 ambiguous (except latest which should be unique)", "operationId": "get_prompt_by_label_agent_scoped_v1_agents__agent_id__prompts_get", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "agent_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Agent Id" } }, { "name": "label", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Label" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/PromptResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/agents/{agent_id}/prompts/versions": { "post": { "tags": [ "Prompts" ], "summary": "Create Prompt Version Agent Scoped", "description": "create a new prompt version under /agents/{agent_id}/prompts/versions.", "operationId": "create_prompt_version_agent_scoped_v1_agents__agent_id__prompts_versions_post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "agent_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Agent Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CreatePromptVersionBody" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/PromptResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } }, "get": { "tags": [ "Prompts" ], "summary": "List Prompt Versions", "description": "list prompt versions with optional filters (label, version).", "operationId": "list_prompt_versions_v1_agents__agent_id__prompts_versions_get", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "agent_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Agent Id" } }, { "name": "label", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Label" } }, { "name": "version", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Version" } }, { "name": "limit", "in": "query", "required": false, "schema": { "type": "integer", "default": 50, "title": "Limit" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "type": "array", "items": { "$ref": "#/components/schemas/PromptResponse" }, "title": "Response List Prompt Versions V1 Agents Agent Id Prompts Versions Get" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } }, "delete": { "tags": [ "Prompts" ], "summary": "Delete Prompt Version By Label Agent Scoped", "description": "delete a prompt version by label.\n\n- if label is production -> 400 (must move production first)\n- if label resolves to 0 -> 404; >1 -> 400 ambiguous (except latest which should be unique)\n- if deleting latest, reassign latest to highest remaining version\n- cannot delete if it is the only version", "operationId": "delete_prompt_version_by_label_agent_scoped_v1_agents__agent_id__prompts_versions_delete", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "agent_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Agent Id" } }, { "name": "label", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Label" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": {} } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/agents/{agent_id}/prompts/promote": { "post": { "tags": [ "Prompts" ], "summary": "Promote Production Label Agent Scoped", "description": "Move the production label to the latest prompt version, or to the version identified by prompt_id.", "operationId": "promote_production_label_agent_scoped_v1_agents__agent_id__prompts_promote_post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "agent_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Agent Id" } }, { "name": "prompt_id", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string", "format": "uuid" }, { "type": "null" } ], "description": "If set, attach the production label to this prompt version; otherwise attach to the latest version.", "title": "Prompt Id" }, "description": "If set, attach the production label to this prompt version; otherwise attach to the latest version." }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/PromptResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/agents/{agent_id}/prompts/versions/{version}": { "get": { "tags": [ "Prompts" ], "summary": "Get Prompt Version Agent Scoped", "operationId": "get_prompt_version_agent_scoped_v1_agents__agent_id__prompts_versions__version__get", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "agent_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Agent Id" } }, { "name": "version", "in": "path", "required": true, "schema": { "type": "integer", "title": "Version" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/PromptResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } }, "delete": { "tags": [ "Prompts" ], "summary": "Delete Prompt Version Agent Scoped", "description": "delete a specific prompt version; cannot delete production; cannot delete only version.\n\nif deleting latest, reassign latest to highest remaining version.\nreturns metadata about the deletion.", "operationId": "delete_prompt_version_agent_scoped_v1_agents__agent_id__prompts_versions__version__delete", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "agent_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Agent Id" } }, { "name": "version", "in": "path", "required": true, "schema": { "type": "integer", "title": "Version" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": {} } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/agents/{agent_id}/prompts/{prompt_id}": { "get": { "tags": [ "Prompts" ], "summary": "Get Prompt By Id", "operationId": "get_prompt_by_id_v1_agents__agent_id__prompts__prompt_id__get", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "agent_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Agent Id" } }, { "name": "prompt_id", "in": "path", "required": true, "schema": { "type": "string", "format": "uuid", "title": "Prompt Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/PromptResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } }, "delete": { "tags": [ "Prompts" ], "summary": "Delete Prompt By Id Agent Scoped", "operationId": "delete_prompt_by_id_agent_scoped_v1_agents__agent_id__prompts__prompt_id__delete", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "agent_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Agent Id" } }, { "name": "prompt_id", "in": "path", "required": true, "schema": { "type": "string", "format": "uuid", "title": "Prompt Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": {} } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/agents/{agent_id}/prompts/versions/{version}/labels": { "get": { "tags": [ "Prompts" ], "summary": "List Prompt Version Labels Agent Scoped", "operationId": "list_prompt_version_labels_agent_scoped_v1_agents__agent_id__prompts_versions__version__labels_get", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "agent_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Agent Id" } }, { "name": "version", "in": "path", "required": true, "schema": { "type": "integer", "title": "Version" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/LabelListResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } }, "post": { "tags": [ "Prompts" ], "summary": "Add Prompt Version Labels Agent Scoped", "operationId": "add_prompt_version_labels_agent_scoped_v1_agents__agent_id__prompts_versions__version__labels_post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "agent_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Agent Id" } }, { "name": "version", "in": "path", "required": true, "schema": { "type": "integer", "title": "Version" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/LabelDeltaRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/LabelListResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } }, "delete": { "tags": [ "Prompts" ], "summary": "Remove Prompt Version Labels Agent Scoped", "operationId": "remove_prompt_version_labels_agent_scoped_v1_agents__agent_id__prompts_versions__version__labels_delete", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "agent_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Agent Id" } }, { "name": "version", "in": "path", "required": true, "schema": { "type": "integer", "title": "Version" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/LabelDeltaRequest", "default": { "labels": [], "override_label": false } } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/LabelListResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/agents/{agent_id}/knowledge-bases": { "get": { "tags": [ "Knowledge Bases" ], "summary": "Get Knowledge Base By Label Agent Scoped", "description": "retrieve a single knowledge base by label: /agents/{agent_id}/knowledge-bases?label=... .\n\n- if label is missing -> 400\n- if label resolves to 0 -> 404; >1 -> 400 ambiguous (except latest which should be unique)", "operationId": "get_knowledge_base_by_label_agent_scoped_v1_agents__agent_id__knowledge_bases_get", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "agent_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Agent Id" } }, { "name": "label", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Label" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/KnowledgeBaseResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/agents/{agent_id}/knowledge-bases/versions": { "post": { "tags": [ "Knowledge Bases" ], "summary": "Create Knowledge Base Version Agent Scoped", "operationId": "create_knowledge_base_version_agent_scoped_v1_agents__agent_id__knowledge_bases_versions_post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "agent_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Agent Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CreateKnowledgeBaseVersionBody" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/KnowledgeBaseResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } }, "get": { "tags": [ "Knowledge Bases" ], "summary": "List Knowledge Base Versions", "operationId": "list_knowledge_base_versions_v1_agents__agent_id__knowledge_bases_versions_get", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "agent_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Agent Id" } }, { "name": "label", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Label" } }, { "name": "version", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Version" } }, { "name": "limit", "in": "query", "required": false, "schema": { "type": "integer", "default": 50, "title": "Limit" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "type": "array", "items": { "$ref": "#/components/schemas/KnowledgeBaseResponse" }, "title": "Response List Knowledge Base Versions V1 Agents Agent Id Knowledge Bases Versions Get" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } }, "delete": { "tags": [ "Knowledge Bases" ], "summary": "Delete Knowledge Base Version By Label Agent Scoped", "description": "delete a knowledge base version by label.\n\n- if label is production -> 400 (must move production first)\n- if label resolves to 0 -> 404; >1 -> 400 ambiguous (except latest which should be unique)\n- if deleting latest, reassign latest to highest remaining version\n- cannot delete if it is the only version", "operationId": "delete_knowledge_base_version_by_label_agent_scoped_v1_agents__agent_id__knowledge_bases_versions_delete", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "agent_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Agent Id" } }, { "name": "label", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Label" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": {} } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/agents/{agent_id}/knowledge-bases/versions/{version}": { "get": { "tags": [ "Knowledge Bases" ], "summary": "Get Knowledge Base Version Agent Scoped", "operationId": "get_knowledge_base_version_agent_scoped_v1_agents__agent_id__knowledge_bases_versions__version__get", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "agent_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Agent Id" } }, { "name": "version", "in": "path", "required": true, "schema": { "type": "integer", "title": "Version" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/KnowledgeBaseResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } }, "delete": { "tags": [ "Knowledge Bases" ], "summary": "Delete Knowledge Base Version Agent Scoped", "description": "delete a specific knowledge base version; cannot delete production; cannot delete only version.\n\nif deleting latest, reassign latest to highest remaining version.\nreturns metadata about the deletion.", "operationId": "delete_knowledge_base_version_agent_scoped_v1_agents__agent_id__knowledge_bases_versions__version__delete", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "agent_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Agent Id" } }, { "name": "version", "in": "path", "required": true, "schema": { "type": "integer", "title": "Version" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": {} } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/agents/{agent_id}/knowledge-bases/{kb_id}": { "get": { "tags": [ "Knowledge Bases" ], "summary": "Get Knowledge Base By Id", "operationId": "get_knowledge_base_by_id_v1_agents__agent_id__knowledge_bases__kb_id__get", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "agent_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Agent Id" } }, { "name": "kb_id", "in": "path", "required": true, "schema": { "type": "string", "format": "uuid", "title": "Kb Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/KnowledgeBaseResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } }, "delete": { "tags": [ "Knowledge Bases" ], "summary": "Delete Knowledge Base By Id Agent Scoped", "operationId": "delete_knowledge_base_by_id_agent_scoped_v1_agents__agent_id__knowledge_bases__kb_id__delete", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "agent_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Agent Id" } }, { "name": "kb_id", "in": "path", "required": true, "schema": { "type": "string", "format": "uuid", "title": "Kb Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": {} } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/agents/{agent_id}/knowledge-bases/versions/{version}/labels": { "get": { "tags": [ "Knowledge Bases" ], "summary": "List Knowledge Base Version Labels Agent Scoped", "operationId": "list_knowledge_base_version_labels_agent_scoped_v1_agents__agent_id__knowledge_bases_versions__version__labels_get", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "agent_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Agent Id" } }, { "name": "version", "in": "path", "required": true, "schema": { "type": "integer", "title": "Version" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/LabelListResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } }, "post": { "tags": [ "Knowledge Bases" ], "summary": "Add Knowledge Base Version Labels Agent Scoped", "operationId": "add_knowledge_base_version_labels_agent_scoped_v1_agents__agent_id__knowledge_bases_versions__version__labels_post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "agent_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Agent Id" } }, { "name": "version", "in": "path", "required": true, "schema": { "type": "integer", "title": "Version" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/LabelDeltaRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/LabelListResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } }, "delete": { "tags": [ "Knowledge Bases" ], "summary": "Remove Knowledge Base Version Labels Agent Scoped", "operationId": "remove_knowledge_base_version_labels_agent_scoped_v1_agents__agent_id__knowledge_bases_versions__version__labels_delete", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "agent_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Agent Id" } }, { "name": "version", "in": "path", "required": true, "schema": { "type": "integer", "title": "Version" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/LabelDeltaRequest", "default": { "labels": [], "override_label": false } } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/LabelListResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/agents/{agent_id}/labels": { "post": { "tags": [ "Labels" ], "summary": "Create Label", "description": "create a free-standing label for an agent (not attached to any prompt or knowledge base).", "operationId": "create_label_v1_agents__agent_id__labels_post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "agent_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Agent Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CreateLabelBody" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/LabelPydantic" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } }, "get": { "tags": [ "Labels" ], "summary": "List Labels", "description": "list all free-standing labels for an agent; filter by substring with q.", "operationId": "list_labels_v1_agents__agent_id__labels_get", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "agent_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Agent Id" } }, { "name": "q", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Q" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "type": "array", "items": { "$ref": "#/components/schemas/LabelPydantic" }, "title": "Response List Labels V1 Agents Agent Id Labels Get" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/agents/{agent_id}/labels/{label_id}": { "get": { "tags": [ "Labels" ], "summary": "Get Label By Id", "operationId": "get_label_by_id_v1_agents__agent_id__labels__label_id__get", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "agent_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Agent Id" } }, { "name": "label_id", "in": "path", "required": true, "schema": { "type": "string", "title": "Label Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/LabelPydantic" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } }, "put": { "tags": [ "Labels" ], "summary": "Update Label", "description": "rename a free-standing label; reserved labels are not allowed as targets.", "operationId": "update_label_v1_agents__agent_id__labels__label_id__put", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "agent_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Agent Id" } }, { "name": "label_id", "in": "path", "required": true, "schema": { "type": "string", "title": "Label Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/UpdateLabelBody" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/LabelPydantic" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } }, "delete": { "tags": [ "Labels" ], "summary": "Delete Label", "description": "delete a free-standing label; cannot delete reserved labels; cannot delete if associated.", "operationId": "delete_label_v1_agents__agent_id__labels__label_id__delete", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "agent_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Agent Id" } }, { "name": "label_id", "in": "path", "required": true, "schema": { "type": "string", "title": "Label Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": {} } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/workflow": { "post": { "tags": [ "Workflows" ], "summary": "Create Workflow V2", "description": "Create a workflows_v2 row with a React Flow graph definition.", "operationId": "create_workflow_v2_v1_workflow_post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CreateWorkflowV2Request" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/WorkflowV2Response" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } }, "get": { "tags": [ "Workflows" ], "summary": "List Workflows V2", "description": "List all workflows_v2 for the authenticated user's organization.", "operationId": "list_workflows_v2_v1_workflow_get", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "agent_id", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "description": "If set, only workflows linked to this agent (agent must be in your org).", "title": "Agent Id" }, "description": "If set, only workflows linked to this agent (agent must be in your org)." }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/WorkflowsV2ListResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/workflow/{workflow_id}/duplicate": { "post": { "tags": [ "Workflows" ], "summary": "Duplicate Workflow V2", "description": "Create a new workflows_v2 row copying definition, description, and agent links from the source.", "operationId": "duplicate_workflow_v2_v1_workflow__workflow_id__duplicate_post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "workflow_id", "in": "path", "required": true, "schema": { "type": "string", "format": "uuid", "title": "Workflow Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/DuplicateWorkflowV2Request" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/WorkflowV2Response" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/workflow/{workflow_id}": { "get": { "tags": [ "Workflows" ], "summary": "Get Workflow V2", "description": "Get one workflows_v2 by ID (organization must match).", "operationId": "get_workflow_v2_v1_workflow__workflow_id__get", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "workflow_id", "in": "path", "required": true, "schema": { "type": "string", "format": "uuid", "title": "Workflow Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/WorkflowV2Response" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } }, "put": { "tags": [ "Workflows" ], "summary": "Update Workflow V2", "description": "Update name, description, agent links, and/or definition (React Flow graph).", "operationId": "update_workflow_v2_v1_workflow__workflow_id__put", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "workflow_id", "in": "path", "required": true, "schema": { "type": "string", "format": "uuid", "title": "Workflow Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/UpdateWorkflowV2Request" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/WorkflowV2Response" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } }, "delete": { "tags": [ "Workflows" ], "summary": "Delete Workflow V2", "description": "Delete a workflows_v2 row.", "operationId": "delete_workflow_v2_v1_workflow__workflow_id__delete", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "workflow_id", "in": "path", "required": true, "schema": { "type": "string", "format": "uuid", "title": "Workflow Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/DeleteWorkflowV2Response" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/retrieve-call-logs": { "get": { "tags": [ "Call Logs" ], "summary": "Retrieve Call Logs Index", "operationId": "retrieve_call_logs_index_v1_retrieve_call_logs_get", "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": {} } } } }, "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ] } }, "/v1/retrieve-call-logs/{agent_id}": { "get": { "tags": [ "Call Logs" ], "summary": "Retrieve Call Logs", "description": "Retrieve call logs for a specific agent given the agent ID.\nReturns a list of call objects, each with an additional \"evaluations\" field\ncontaining a list of evaluations joined via call_id.", "operationId": "retrieve_call_logs_v1_retrieve_call_logs__agent_id__get", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "agent_id", "in": "path", "required": true, "schema": { "type": "string", "title": "Agent Id" } }, { "name": "label", "in": "query", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "description": "Label of the agent to filter by", "title": "Label" }, "description": "Label of the agent to filter by" }, { "name": "page_size", "in": "query", "required": false, "schema": { "type": "integer", "maximum": 100, "minimum": 1, "description": "Max calls per page", "default": 20, "title": "Page Size" }, "description": "Max calls per page" }, { "name": "page", "in": "query", "required": false, "schema": { "type": "integer", "minimum": 1, "description": "Page number (1-based)", "default": 1, "title": "Page" }, "description": "Page number (1-based)" }, { "name": "last", "in": "query", "required": false, "schema": { "enum": [ "1day", "3days", "7days", "30days", "90days", "all" ], "type": "string", "description": "Last X days to filter by", "default": "1day", "title": "Last" }, "description": "Last X days to filter by" }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/RetrieveCallLogsResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/retrieve-call-log": { "get": { "tags": [ "Call Logs" ], "summary": "Retrieve Call Log Index", "operationId": "retrieve_call_log_index_v1_retrieve_call_log_get", "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": {} } } } }, "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ] } }, "/v1/retrieve-call-log/{call_id}": { "get": { "tags": [ "Call Logs" ], "summary": "Retrieve Call Log", "description": "Retrieve call logs for a specific agent given the agent ID.\nReturns a list of call objects, each with an additional \"evaluations\" field\ncontaining a list of evaluations joined via call_id.", "operationId": "retrieve_call_log_v1_retrieve_call_log__call_id__get", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "call_id", "in": "path", "required": true, "schema": { "type": "string", "title": "Call Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/RetrieveCallLogResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/call-log": { "delete": { "tags": [ "Call Logs" ], "summary": "Delete Call Log Index", "operationId": "delete_call_log_index_v1_call_log_delete", "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": {} } } } }, "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ] } }, "/v1/call-log/{call_id}": { "delete": { "tags": [ "Call Logs" ], "summary": "Delete Call Log", "description": "Delete a specific call log given its ID.\nValidates that the user has access to the call log by checking organization membership.\n\nArgs:\n call_id: The ID of the call to delete\n recording_only: If True, only delete the recording file and clear recording fields.\n If False (default), delete the entire call log.", "operationId": "delete_call_log_v1_call_log__call_id__delete", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "call_id", "in": "path", "required": true, "schema": { "type": "string", "title": "Call Id" } }, { "name": "recording_only", "in": "query", "required": false, "schema": { "type": "boolean", "description": "If true, only delete the recording file and clear recording fields. If false, delete the entire call log including all data.", "default": false, "title": "Recording Only" }, "description": "If true, only delete the recording file and clear recording fields. If false, delete the entire call log including all data." }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/DeleteCallLogResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/call-logs": { "delete": { "tags": [ "Call Logs" ], "summary": "Bulk Delete Call Logs", "description": "Delete multiple call logs given their IDs.\nValidates that the user has access to all call logs by checking organization membership.\n\nArgs:\n body: Request body containing a list of call IDs to delete", "operationId": "bulk_delete_call_logs_v1_call_logs_delete", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/BulkDeleteCallLogsRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/BulkDeleteCallLogsResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/update-log/{call_id}": { "put": { "tags": [ "Call Logs" ], "summary": "Update Log", "description": "Update a specific call log given its ID.", "operationId": "update_log_v1_update_log__call_id__put", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "call_id", "in": "path", "required": true, "schema": { "type": "string", "title": "Call Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/UpdateCallLogRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/UpdateLogResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/update-simulation-result": { "post": { "tags": [ "Simulation Results" ], "summary": "Update Simulation Result", "operationId": "update_simulation_result_v1_update_simulation_result_post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/src__api__update_simulation_result__UpdateSimulationRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/UpdateSimulationResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/re-evaluate/{call_id}": { "post": { "tags": [ "Re-evaluate" ], "summary": "Re Evaluate", "description": "Re-evaluate a call.", "operationId": "re_evaluate_v1_re_evaluate__call_id__post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "call_id", "in": "path", "required": true, "schema": { "type": "string", "format": "uuid", "title": "Call Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ReEvaluateCallResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/re-evaluate-simulation-result/{simulation_result_id}": { "post": { "tags": [ "Re-evaluate" ], "summary": "Re Evaluate Simulation Result", "description": "Re-evaluate a simulation result.", "operationId": "re_evaluate_simulation_result_v1_re_evaluate_simulation_result__simulation_result_id__post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "simulation_result_id", "in": "path", "required": true, "schema": { "type": "integer", "title": "Simulation Result Id" } }, { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ReEvaluateSimulationResultResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/translate-transcript": { "post": { "tags": [ "Translation" ], "summary": "Translate a call transcript", "description": "Translates all utterances in a simulation or production conversation transcript to the specified target language using Google Translate API.", "operationId": "translate_transcript_v1_translate_transcript_post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "anyOf": [ { "$ref": "#/components/schemas/TranslateSimulationTranscriptRequest" }, { "$ref": "#/components/schemas/TranslateObservabilityTranscriptRequest" } ], "title": "Translate Request" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/TranslateTranscriptResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/optimize/metric-prompt": { "post": { "tags": [ "Optimize" ], "summary": "Optimize Metric Prompt", "description": "Accept a custom metric prompt and return an optimized version using an LLM.\nThe optimized prompt is clearer, more precise, and easier for evaluators to apply consistently.", "operationId": "optimize_metric_prompt_v1_optimize_metric_prompt_post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/OptimizeMetricPromptRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/OptimizeMetricPromptResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/v1/optimize/metric-prompt-with-diff": { "post": { "tags": [ "Optimize" ], "summary": "Optimize Metric Prompt With Diff", "description": "Optimize a metric prompt using human vs AI evaluation comparisons.\nevaluation_diffs is required and must not be empty.", "operationId": "optimize_metric_prompt_with_diff_v1_optimize_metric_prompt_with_diff_post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "X-API-Key", "in": "header", "required": true, "schema": { "type": "string" }, "description": "API key required to authenticate requests." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/OptimizeMetricPromptWithDiffRequest" } } } }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/OptimizeMetricPromptResponse" } } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } } }, "components": { "schemas": { "AccentType": { "type": "string", "enum": [ "multilingual", "american", "american2", "southern", "italian", "indian", "british", "australian", "mexican", "spanish", "portuguese", "french", "turkish", "japanese", "hindi", "arabic", "russian", "chinese", "german" ], "title": "AccentType", "description": "Enum for accent options." }, "ActivePackageResponse": { "properties": { "package_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Package Id", "description": "Active package ID if available" }, "has_active_contract": { "type": "boolean", "title": "Has Active Contract", "description": "Whether the user has an active contract" }, "access_ends_at": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Access Ends At", "description": "ISO 8601 timestamp when access ends, from Metronome contract ending_before (e.g. cancel at period end or trial end). Null if open-ended or not returned." } }, "type": "object", "required": [ "has_active_contract" ], "title": "ActivePackageResponse" }, "ActualToolCallDetail": { "properties": { "parameters": { "anyOf": [ { "additionalProperties": true, "type": "object" }, { "type": "null" } ], "title": "Parameters", "description": "Parameters passed to the tool" }, "output": { "anyOf": [ {}, { "type": "null" } ], "title": "Output", "description": "Output returned by the tool" }, "start_offset_ms": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Start Offset Ms", "description": "When the tool was called relative to conversation start, in milliseconds" } }, "type": "object", "title": "ActualToolCallDetail" }, "AddConversationsToLabRequest": { "properties": { "lab_id": { "type": "string", "title": "Lab Id", "description": "Lab ID (UUID as string)" }, "conversations": { "items": { "$ref": "#/components/schemas/ConversationItem" }, "type": "array", "minItems": 1, "title": "Conversations", "description": "List of conversations to add to the lab" } }, "type": "object", "required": [ "lab_id", "conversations" ], "title": "AddConversationsToLabRequest", "description": "Request model for adding conversations to an existing lab" }, "AddConversationsToLabResponse": { "properties": { "added_count": { "type": "integer", "title": "Added Count", "description": "Number of conversations successfully added" }, "skipped_count": { "type": "integer", "title": "Skipped Count", "description": "Number of conversations that were skipped (already existed)" }, "added_conversation_ids": { "items": { "additionalProperties": true, "type": "object" }, "type": "array", "title": "Added Conversation Ids", "description": "List of conversation identifiers that were added" }, "message": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Message", "description": "Human-readable message about the operation" } }, "type": "object", "required": [ "added_count", "skipped_count", "added_conversation_ids" ], "title": "AddConversationsToLabResponse", "description": "Response model for adding conversations to a lab" }, "AddDigitalHumansToSimulationRequest": { "properties": { "digital_human_ids": { "items": { "type": "integer" }, "type": "array", "title": "Digital Human Ids", "description": "array of existing digital human IDs to add to the simulation" } }, "type": "object", "required": [ "digital_human_ids" ], "title": "AddDigitalHumansToSimulationRequest", "description": "request body for adding existing digital humans to a simulation." }, "AddDigitalHumansToSimulationResponse": { "properties": { "message": { "type": "string", "title": "Message", "description": "success message" } }, "type": "object", "required": [ "message" ], "title": "AddDigitalHumansToSimulationResponse", "description": "response body for adding digital humans to a simulation." }, "AddMetricsToLabRequest": { "properties": { "lab_id": { "type": "string", "title": "Lab Id", "description": "Lab ID (UUID as string)" }, "metric_ids": { "items": { "type": "string" }, "type": "array", "minItems": 1, "title": "Metric Ids", "description": "List of custom metric IDs (UUIDs as strings) to add to the lab" }, "evaluate_conversations": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Evaluate Conversations", "description": "Whether to evaluate conversations in the lab with the newly added metrics (copies existing evaluations where found, queues new evaluations only for metrics without results)", "default": false } }, "type": "object", "required": [ "lab_id", "metric_ids" ], "title": "AddMetricsToLabRequest", "description": "Request model for adding metrics to an existing lab" }, "AddMetricsToLabResponse": { "properties": { "added_count": { "type": "integer", "title": "Added Count", "description": "Number of metrics successfully added" }, "skipped_count": { "type": "integer", "title": "Skipped Count", "description": "Number of metrics that were skipped (already existed)" }, "added_metric_ids": { "items": { "type": "string" }, "type": "array", "title": "Added Metric Ids", "description": "List of metric IDs that were added" }, "evaluation_triggered": { "type": "boolean", "title": "Evaluation Triggered", "description": "Whether evaluations were triggered for existing conversations", "default": false }, "evaluation_count": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Evaluation Count", "description": "Number of conversations that were evaluated (if evaluation_triggered is true)" }, "message": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Message", "description": "Human-readable message about the operation" } }, "type": "object", "required": [ "added_count", "skipped_count", "added_metric_ids" ], "title": "AddMetricsToLabResponse", "description": "Response model for adding metrics to a lab" }, "AddPhoneNumberRequest": { "properties": { "area_code": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Area Code", "description": "Optional US area code to bias phone number search (e.g. 415)" } }, "type": "object", "title": "AddPhoneNumberRequest", "description": "Request schema for auto-purchasing a Twilio number for an organization." }, "AddPhoneNumberResponse": { "properties": { "phone_number": { "type": "string", "title": "Phone Number", "description": "Purchased E.164 phone number" }, "twilio_sid": { "type": "string", "title": "Twilio Sid", "description": "Twilio IncomingPhoneNumber SID" }, "organization_id": { "type": "string", "format": "uuid", "title": "Organization Id", "description": "Organization ID" }, "purchase_date": { "type": "string", "format": "date", "title": "Purchase Date", "description": "Date when purchased" }, "price": { "type": "integer", "title": "Price", "description": "Stored price in cents" } }, "type": "object", "required": [ "phone_number", "twilio_sid", "organization_id", "purchase_date", "price" ], "title": "AddPhoneNumberResponse", "description": "Response schema after auto-purchasing and storing a phone number." }, "AddToCommunityRequest": { "properties": { "digital_human_ids": { "items": { "type": "integer" }, "type": "array", "title": "Digital Human Ids", "description": "List of digital human (test case) IDs to add to this community" } }, "type": "object", "required": [ "digital_human_ids" ], "title": "AddToCommunityRequest" }, "AgentMode": { "type": "string", "enum": [ "VOICE", "TEXT" ], "title": "AgentMode", "description": "Enum representing the mode of agent" }, "AgentPydantic": { "properties": { "id": { "anyOf": [ { "type": "string" }, { "type": "integer" }, { "type": "null" } ], "title": "Id" }, "name": { "type": "string", "title": "Name" }, "agent_description": { "type": "string", "title": "Agent Description" }, "knowledge_base": { "type": "string", "title": "Knowledge Base" }, "organization_id": { "type": "string", "title": "Organization Id" }, "goals": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Goals" }, "mode": { "$ref": "#/components/schemas/AgentMode" }, "type": { "anyOf": [ { "$ref": "#/components/schemas/AgentType" }, { "type": "null" } ] }, "connection_type": { "anyOf": [ { "$ref": "#/components/schemas/ConnectionType" }, { "type": "null" } ] }, "phone_number": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Phone Number" }, "websocket_url": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Websocket Url" }, "redact_pii": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Redact Pii" }, "folder_id": { "anyOf": [ { "type": "string", "format": "uuid" }, { "type": "null" } ], "title": "Folder Id" }, "created_at": { "anyOf": [ { "type": "string", "format": "date-time" }, { "type": "null" } ], "title": "Created At" }, "keyterms": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Keyterms" }, "voice_provider": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Voice Provider" }, "provider_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Provider Id" }, "websocket_username": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Websocket Username" }, "websocket_password": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Websocket Password" }, "external_agent_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "External Agent Id" }, "sip_uri": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Sip Uri" }, "custom_sip_headers": { "anyOf": [ { "additionalProperties": true, "type": "object" }, { "type": "null" } ], "title": "Custom Sip Headers" }, "sip_username": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Sip Username" }, "sip_password": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Sip Password" }, "simulation_notifications": { "additionalProperties": true, "type": "object", "title": "Simulation Notifications" }, "livekit_agent_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Livekit Agent Name" }, "livekit_metadata": { "anyOf": [ { "additionalProperties": true, "type": "object" }, { "type": "null" } ], "title": "Livekit Metadata" }, "pipecat_agent_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Pipecat Agent Name" }, "pipecat_agent_configuration": { "anyOf": [ { "additionalProperties": true, "type": "object" }, { "type": "null" } ], "title": "Pipecat Agent Configuration" }, "pipecat_room_properties": { "anyOf": [ { "additionalProperties": true, "type": "object" }, { "type": "null" } ], "title": "Pipecat Room Properties" }, "http_webhook": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Http Webhook" }, "http_webhook_key": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Http Webhook Key" }, "enable_outbound_call_auto_start": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Enable Outbound Call Auto Start" } }, "type": "object", "required": [ "name", "agent_description", "knowledge_base", "organization_id", "mode" ], "title": "AgentPydantic" }, "AgentRequest": { "properties": { "name": { "type": "string", "title": "Name", "description": "Name of the agent" }, "system_prompt": { "type": "string", "title": "System Prompt", "description": "System prompt for the agent" }, "knowledge_base": { "type": "string", "title": "Knowledge Base", "description": "Knowledge base of the agent" }, "phone_number": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Phone Number", "description": "Phone number associated with the agent" }, "goals": { "items": { "type": "string" }, "type": "array", "title": "Goals", "description": "List of goals for the agent" }, "type": { "anyOf": [ { "$ref": "#/components/schemas/AgentType" }, { "type": "null" } ], "description": "INBOUND: Agent receives incoming calls from customers\nOUTBOUND: Agent makes outgoing calls to customers", "default": "INBOUND" }, "connection_type": { "anyOf": [ { "$ref": "#/components/schemas/ConnectionType" }, { "type": "null" } ], "description": "Connection type of the agent (Livekit, Websocket, etc.)" }, "mode": { "anyOf": [ { "$ref": "#/components/schemas/AgentMode" }, { "type": "null" } ], "description": "Modality of the agent", "default": "VOICE" }, "keyterms": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Keyterms", "description": "List of keyterms for the agent" }, "external_agent_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "External Agent Id", "description": "External agent ID for the agent" }, "folder": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Folder", "description": "Name of the folder to put the agent in" }, "websocket_url": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Websocket Url", "description": "WebSocket URL for real-time communication" }, "websocket_username": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Websocket Username", "description": "Username for WebSocket authentication" }, "websocket_password": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Websocket Password", "description": "Password for WebSocket authentication" }, "sip_uri": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Sip Uri", "description": "SIP URI for VoIP calls" }, "sip_username": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Sip Username", "description": "Username for SIP authentication" }, "sip_password": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Sip Password", "description": "Password for SIP authentication" }, "custom_sip_headers": { "anyOf": [ { "additionalProperties": { "type": "string" }, "type": "object" }, { "type": "null" } ], "title": "Custom Sip Headers", "description": "Custom headers for SIP requests (Do not include `X-` prefix for the headers, these get added automatically)" }, "redact_pii": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Redact Pii", "description": "Enable/disable PII redaction", "default": false }, "livekit_agent_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Livekit Agent Name", "description": "LiveKit agent name" }, "livekit_metadata": { "anyOf": [ { "additionalProperties": true, "type": "object" }, { "type": "null" } ], "title": "Livekit Metadata", "description": "LiveKit metadata" }, "pipecat_agent_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Pipecat Agent Name", "description": "Pipecat agent name" }, "pipecat_agent_configuration": { "anyOf": [ { "additionalProperties": true, "type": "object" }, { "type": "null" } ], "title": "Pipecat Agent Configuration", "description": "Pipecat agent configuration" }, "pipecat_room_properties": { "anyOf": [ { "additionalProperties": true, "type": "object" }, { "type": "null" } ], "title": "Pipecat Room Properties", "description": "Pipecat room properties" }, "http_webhook": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Http Webhook", "description": "HTTP webhook URL for text agent communication" }, "voice_provider": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Voice Provider", "description": "Voice provider for the agent" }, "provider_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Provider Id", "description": "Provider ID for the agent" }, "enable_outbound_call_auto_start": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Enable Outbound Call Auto Start", "description": "Automatically initiate an outbound call when a test result reaches READY state" } }, "type": "object", "required": [ "name", "system_prompt", "knowledge_base", "goals" ], "title": "AgentRequest" }, "AgentResponse": { "properties": { "agent_id": { "type": "integer", "title": "Agent Id", "description": "ID of the created agent" }, "status": { "type": "string", "title": "Status", "description": "Status of the response", "default": "200" }, "http_webhook_key": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Http Webhook Key", "description": "Signing key for HTTP webhook (only provided if http_webhook was set)" } }, "type": "object", "required": [ "agent_id" ], "title": "AgentResponse" }, "AgentType": { "type": "string", "enum": [ "INBOUND", "OUTBOUND" ], "title": "AgentType", "description": "Enum representing the type of agent" }, "AgentUpdateRequest": { "properties": { "agent_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Agent Id", "description": "ID of the agent to be updated" }, "external_agent_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "External Agent Id", "description": "External agent ID for the agent" }, "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Name", "description": "Name of the agent" }, "system_prompt": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "System Prompt", "description": "System prompt for the agent" }, "knowledge_base": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Knowledge Base", "description": "Knowledge base of the agent" }, "phone_number": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Phone Number", "description": "Phone number associated with the agent" }, "goals": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Goals", "description": "List of goals for the agent" }, "type": { "anyOf": [ { "$ref": "#/components/schemas/AgentType" }, { "type": "null" } ], "description": "INBOUND: Agent receives incoming calls from customers\nOUTBOUND: Agent makes outgoing calls to customers" }, "connection_type": { "anyOf": [ { "$ref": "#/components/schemas/ConnectionType" }, { "type": "null" } ], "description": "Connection type of the agent (Livekit, Websocket, etc.)" }, "mode": { "anyOf": [ { "$ref": "#/components/schemas/AgentMode" }, { "type": "null" } ], "description": "Modality of the agent" }, "keyterms": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Keyterms", "description": "List of keyterms for the agent" }, "folder": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Folder", "description": "Name of the folder to put the agent in" }, "websocket_url": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Websocket Url", "description": "WebSocket URL for real-time communication" }, "websocket_username": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Websocket Username", "description": "Username for WebSocket authentication" }, "websocket_password": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Websocket Password", "description": "Password for WebSocket authentication" }, "sip_uri": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Sip Uri", "description": "SIP URI for VoIP calls" }, "sip_username": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Sip Username", "description": "Username for SIP authentication" }, "sip_password": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Sip Password", "description": "Password for SIP authentication" }, "custom_sip_headers": { "anyOf": [ { "additionalProperties": { "type": "string" }, "type": "object" }, { "type": "null" } ], "title": "Custom Sip Headers", "description": "Custom headers for SIP requests (Do not include `X-` prefix for the headers, these get added automatically)" }, "redact_pii": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Redact Pii", "description": "Enable/disable PII redaction" }, "livekit_agent_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Livekit Agent Name", "description": "LiveKit agent name" }, "livekit_metadata": { "anyOf": [ { "additionalProperties": true, "type": "object" }, { "type": "null" } ], "title": "Livekit Metadata", "description": "LiveKit metadata" }, "pipecat_agent_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Pipecat Agent Name", "description": "Pipecat agent name" }, "pipecat_agent_configuration": { "anyOf": [ { "additionalProperties": true, "type": "object" }, { "type": "null" } ], "title": "Pipecat Agent Configuration", "description": "Pipecat agent configuration" }, "pipecat_room_properties": { "anyOf": [ { "additionalProperties": true, "type": "object" }, { "type": "null" } ], "title": "Pipecat Room Properties", "description": "Pipecat room properties" }, "http_webhook": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Http Webhook", "description": "HTTP webhook URL for text agent communication" }, "voice_provider": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Voice Provider", "description": "Voice provider for the agent" }, "provider_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Provider Id", "description": "Provider ID for the agent" }, "enable_outbound_call_auto_start": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Enable Outbound Call Auto Start", "description": "Automatically initiate an outbound call when a test result reaches READY state" } }, "type": "object", "required": [ "agent_id" ], "title": "AgentUpdateRequest" }, "AgentUpdateResponse": { "properties": { "agent": { "$ref": "#/components/schemas/AgentUpdateRequest", "description": "Updated agent details" }, "status": { "type": "string", "title": "Status", "description": "Status of the response", "default": "200" }, "http_webhook_key": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Http Webhook Key", "description": "Signing key for HTTP webhook (only provided if http_webhook was set)" } }, "type": "object", "required": [ "agent" ], "title": "AgentUpdateResponse" }, "AgentUpdateWithExternalIdRequest": { "properties": { "external_agent_id": { "type": "string", "title": "External Agent Id", "description": "External agent ID for the agent" }, "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Name", "description": "Name of the agent" }, "system_prompt": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "System Prompt", "description": "System prompt for the agent" }, "knowledge_base": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Knowledge Base", "description": "Knowledge base of the agent" }, "phone_number": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Phone Number", "description": "Phone number associated with the agent" }, "goals": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Goals", "description": "List of goals for the agent" }, "type": { "anyOf": [ { "$ref": "#/components/schemas/AgentType" }, { "type": "null" } ], "description": "INBOUND: Agent receives incoming calls from customers\nOUTBOUND: Agent makes outgoing calls to customers" }, "connection_type": { "anyOf": [ { "$ref": "#/components/schemas/ConnectionType" }, { "type": "null" } ], "description": "Connection type of the agent (Livekit, Websocket, etc.)" }, "mode": { "anyOf": [ { "$ref": "#/components/schemas/AgentMode" }, { "type": "null" } ], "description": "Modality of the agent" }, "keyterms": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Keyterms", "description": "List of keyterms for the agent" }, "folder": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Folder", "description": "Name of the folder to put the agent in" }, "websocket_url": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Websocket Url", "description": "WebSocket URL for real-time communication" }, "websocket_username": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Websocket Username", "description": "Username for WebSocket authentication" }, "websocket_password": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Websocket Password", "description": "Password for WebSocket authentication" }, "sip_uri": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Sip Uri", "description": "SIP URI for VoIP calls" }, "sip_username": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Sip Username", "description": "Username for SIP authentication" }, "sip_password": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Sip Password", "description": "Password for SIP authentication" }, "custom_sip_headers": { "anyOf": [ { "additionalProperties": { "type": "string" }, "type": "object" }, { "type": "null" } ], "title": "Custom Sip Headers", "description": "Custom headers for SIP requests" }, "redact_pii": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Redact Pii", "description": "Enable/disable PII redaction" }, "livekit_agent_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Livekit Agent Name", "description": "LiveKit agent name" }, "livekit_metadata": { "anyOf": [ { "additionalProperties": true, "type": "object" }, { "type": "null" } ], "title": "Livekit Metadata", "description": "LiveKit metadata" }, "pipecat_agent_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Pipecat Agent Name", "description": "Pipecat agent name" }, "pipecat_agent_configuration": { "anyOf": [ { "additionalProperties": true, "type": "object" }, { "type": "null" } ], "title": "Pipecat Agent Configuration", "description": "Pipecat agent configuration" }, "pipecat_room_properties": { "anyOf": [ { "additionalProperties": true, "type": "object" }, { "type": "null" } ], "title": "Pipecat Room Properties", "description": "Pipecat room properties" }, "http_webhook": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Http Webhook", "description": "HTTP webhook URL for text agent communication" }, "voice_provider": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Voice Provider", "description": "Voice provider for the agent" }, "provider_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Provider Id", "description": "Provider ID for the agent" }, "enable_outbound_call_auto_start": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Enable Outbound Call Auto Start", "description": "Automatically initiate an outbound call when a test result reaches READY state" } }, "type": "object", "required": [ "external_agent_id" ], "title": "AgentUpdateWithExternalIdRequest" }, "AgentWebhookKeyRequest": { "properties": { "agent_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Agent Id", "description": "ID of the agent" }, "external_agent_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "External Agent Id", "description": "External ID of the agent" } }, "type": "object", "title": "AgentWebhookKeyRequest", "description": "Request model for creating/getting an agent webhook key" }, "AgentWebhookKeyResponse": { "properties": { "signing_key": { "type": "string", "title": "Signing Key", "description": "Signing key" }, "message": { "type": "string", "title": "Message", "description": "Message" } }, "type": "object", "required": [ "signing_key", "message" ], "title": "AgentWebhookKeyResponse", "description": "Response model for agent webhook key" }, "AlertResponse": { "properties": { "id": { "type": "string", "title": "Id", "description": "Unique identifier for the alert" }, "name": { "type": "string", "title": "Name", "description": "Name of the alert" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Description", "description": "Description of the alert" }, "is_enabled": { "type": "boolean", "title": "Is Enabled", "description": "Whether the alert is enabled" }, "organization_id": { "type": "string", "title": "Organization Id", "description": "Organization ID" }, "entity_type": { "$ref": "#/components/schemas/EntityType", "description": "Type of entity being monitored" }, "entity_field": { "type": "string", "title": "Entity Field", "description": "The specific field/metric being monitored" }, "operator": { "$ref": "#/components/schemas/Operator", "description": "Comparison operator" }, "comparison_value": { "type": "string", "title": "Comparison Value", "description": "Value to compare against" }, "notification_channels": { "items": {}, "type": "array", "title": "Notification Channels", "description": "Notification channels configuration" }, "last_triggered_at": { "anyOf": [ { "type": "string", "format": "date-time" }, { "type": "null" } ], "title": "Last Triggered At", "description": "When the alert was last triggered" }, "trigger_count": { "type": "integer", "title": "Trigger Count", "description": "Number of times triggered" }, "created_by": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Created By", "description": "User who created the alert" }, "applies_to_all_agents": { "type": "boolean", "title": "Applies To All Agents", "description": "Whether the alert applies to all agents" }, "agents": { "anyOf": [ { "items": { "type": "integer" }, "type": "array" }, { "type": "null" } ], "title": "Agents", "description": "Associated agent IDs" }, "created_at": { "type": "string", "format": "date-time", "title": "Created At", "description": "When the alert was created" }, "updated_at": { "anyOf": [ { "type": "string", "format": "date-time" }, { "type": "null" } ], "title": "Updated At", "description": "When the alert was last updated" }, "threshold_time_interval": { "type": "integer", "title": "Threshold Time Interval", "description": "Time window in seconds for the alert (e.g. 600 for 10 minutes)" }, "min_events": { "type": "integer", "title": "Min Events", "description": "The minimum number of events for the alert" }, "in_alert": { "type": "boolean", "title": "In Alert", "description": "Whether the alert is in alert" }, "source_scope": { "type": "string", "title": "Source Scope", "description": "Which data source fires this alert: 'all', 'observability', or 'simulation'", "default": "all" } }, "type": "object", "required": [ "id", "name", "is_enabled", "organization_id", "entity_type", "entity_field", "operator", "comparison_value", "notification_channels", "trigger_count", "applies_to_all_agents", "created_at", "threshold_time_interval", "min_events", "in_alert" ], "title": "AlertResponse", "description": "Response model for alert operations" }, "AudioQualityType": { "type": "string", "enum": [ "high", "medium", "low", "horrible" ], "title": "AudioQualityType", "description": "Enum for audio quality options." }, "BackgroundNoiseType": { "type": "string", "enum": [ "none", "office", "talking", "traffic", "cafe", "park", "tv" ], "title": "BackgroundNoiseType", "description": "Enum for background noise options." }, "BulkDeleteCallLogsRequest": { "properties": { "call_ids": { "items": { "type": "string" }, "type": "array", "title": "Call Ids", "description": "List of call IDs to delete" } }, "type": "object", "required": [ "call_ids" ], "title": "BulkDeleteCallLogsRequest" }, "BulkDeleteCallLogsResponse": { "properties": { "message": { "type": "string", "title": "Message", "description": "Success message" }, "deleted_count": { "type": "integer", "title": "Deleted Count", "description": "Number of calls successfully deleted" }, "status": { "type": "string", "title": "Status", "description": "Status of the response", "default": "200" } }, "type": "object", "required": [ "message", "deleted_count" ], "title": "BulkDeleteCallLogsResponse" }, "BulkUpdateCustomMetricsRequest": { "properties": { "metric_ids": { "items": { "type": "string" }, "type": "array", "title": "Metric Ids", "description": "UUIDs of custom metrics to update" }, "updates": { "$ref": "#/components/schemas/CustomMetricUpdates", "description": "Fields to update (only present keys are applied; value including null is written)" } }, "type": "object", "required": [ "metric_ids", "updates" ], "title": "BulkUpdateCustomMetricsRequest", "description": "Request for bulk updating custom metrics (same patch applied to each metric)." }, "BulkUpdateCustomMetricsResponse": { "properties": { "success": { "type": "boolean", "title": "Success", "description": "Whether the operation succeeded", "default": true }, "message": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Message", "description": "Human-readable summary; frontend falls back to 'Updated N custom metric(s)' if missing" }, "updated": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Updated", "description": "Number of metrics updated" } }, "type": "object", "title": "BulkUpdateCustomMetricsResponse", "description": "Response for bulk update (success, message, updated count)." }, "CallDirection": { "type": "string", "enum": [ "INBOUND", "OUTBOUND" ], "title": "CallDirection", "description": "Enum representing the direction of a call." }, "CallInterface": { "type": "string", "enum": [ "PHONE", "WEB" ], "title": "CallInterface", "description": "Enum representing the interface used for a call." }, "CallLog": { "properties": { "id": { "type": "string", "title": "Id", "description": "Unique identifier for the call" }, "agent_id": { "type": "string", "title": "Agent Id", "description": "ID of the agent associated with the call" }, "external_agent_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "External Agent Id", "description": "External ID of the agent associated with the call" }, "recording_url": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Recording Url", "description": "URL to the recording file (supported formats: .mp4, .wav, .m4a)" }, "start_time_utc": { "type": "string", "title": "Start Time Utc", "description": "When the call started, in UTC" }, "participants": { "items": { "$ref": "#/components/schemas/ParticipantResponse" }, "type": "array", "title": "Participants", "description": "List of call participants" }, "call_direction": { "$ref": "#/components/schemas/CallDirection", "description": "Direction of the call from the Agent's perspective (INBOUND or OUTBOUND)", "default": "INBOUND" }, "interface": { "$ref": "#/components/schemas/CallInterface", "description": "Interface used for the call", "default": "PHONE" }, "status": { "$ref": "#/components/schemas/CallStatus", "description": "Current status of the call" }, "created_at": { "type": "string", "format": "date-time", "title": "Created At", "description": "When this request was created (defaults to now in UTC)" }, "transcript_url": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Transcript Url", "description": "URL to the transcript file (supported formats: .txt, .json)" }, "tool_calls": { "anyOf": [ { "items": { "$ref": "#/components/schemas/ToolCall" }, "type": "array" }, { "type": "null" } ], "title": "Tool Calls", "description": "List of tool calls made during the call" }, "events": { "anyOf": [ { "items": { "$ref": "#/components/schemas/Event" }, "type": "array" }, { "type": "null" } ], "title": "Events", "description": "List of events that occurred during the call" }, "tags": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Tags", "description": "List of tags associated with the call" }, "duration_ms": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Duration Ms", "description": "Duration of the call in milliseconds", "default": 0 }, "evaluations": { "anyOf": [ { "items": { "$ref": "#/components/schemas/Evaluation" }, "type": "array" }, { "type": "null" } ], "title": "Evaluations", "description": "List of evaluations associated with the call" }, "annotations": { "anyOf": [ { "items": {}, "type": "array" }, { "type": "null" } ], "title": "Annotations", "description": "Annotations associated with the call" }, "metadata": { "anyOf": [ { "additionalProperties": true, "type": "object" }, { "type": "null" } ], "title": "Metadata", "description": "Additional metadata associated with the call" }, "custom_metrics": { "anyOf": [ { "items": {}, "type": "array" }, { "type": "null" } ], "title": "Custom Metrics", "description": "Please use the custom metrics in the evaluations instead", "deprecated": true }, "conversation_ended_by": { "anyOf": [ { "$ref": "#/components/schemas/ParticipantRole" }, { "type": "null" } ], "description": "Which participant role ended the conversation: 'USER' or 'AGENT'" } }, "type": "object", "required": [ "id", "agent_id", "recording_url", "start_time_utc", "participants", "status" ], "title": "CallLog" }, "CallRequestUsingAgentId": { "properties": { "agent_id": { "type": "string", "title": "Agent Id", "description": "ID of the agent associated with the call" }, "recording_url": { "anyOf": [ { "type": "string", "maxLength": 2083, "minLength": 1, "format": "uri" }, { "type": "null" } ], "title": "Recording Url", "description": "URL to the recording file (supported formats: .mp3, .mp4, .wav, .m4a)" }, "recording_base64": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Recording Base64", "description": "Base64 encoded recording file in data URL format (supported formats: .mp3, .mp4, .wav, .m4a)" }, "start_time_utc": { "type": "string", "format": "date-time", "title": "Start Time Utc", "description": "When the call started, in UTC ([python] log: datetime.now(timezone.utc) at call start)" }, "participants": { "items": { "$ref": "#/components/schemas/Participant" }, "type": "array", "maxItems": 2, "minItems": 2, "title": "Participants", "description": "List of call participants" }, "call_direction": { "anyOf": [ { "$ref": "#/components/schemas/CallDirection" }, { "type": "null" } ], "description": "Direction of the call from the Agent's perspective (INBOUND or OUTBOUND)", "default": "INBOUND" }, "interface": { "anyOf": [ { "$ref": "#/components/schemas/CallInterface" }, { "type": "null" } ], "description": "Interface used for the call", "default": "PHONE" }, "transcript_url": { "anyOf": [ { "type": "string", "maxLength": 2083, "minLength": 1, "format": "uri" }, { "type": "null" } ], "title": "Transcript Url", "description": "URL to the transcript file (supported formats: .json)" }, "transcript": { "anyOf": [ { "items": { "$ref": "#/components/schemas/TranscriptEntryRequest" }, "type": "array" }, { "type": "null" } ], "title": "Transcript", "description": "Transcript of the call in text format" }, "tool_calls": { "anyOf": [ { "items": { "$ref": "#/components/schemas/ToolCall" }, "type": "array" }, { "type": "null" } ], "title": "Tool Calls", "description": "List of tool calls made during the call" }, "events": { "anyOf": [ { "items": { "$ref": "#/components/schemas/Event" }, "type": "array" }, { "type": "null" } ], "title": "Events", "description": "List of events that occurred during the call" }, "tags": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Tags", "description": "List of tags associated with the call" }, "trace_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Trace Id", "description": "Trace ID of the call" }, "created_at": { "anyOf": [ { "type": "string", "format": "date-time" }, { "type": "null" } ], "title": "Created At", "description": "When this request was created (defaults to now in UTC)" }, "metadata": { "anyOf": [ { "additionalProperties": true, "type": "object" }, { "type": "null" } ], "title": "Metadata", "description": "Additional metadata associated with the evaluation" }, "webhook_tag": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Webhook Tag", "description": "Tag of the webhook to send the evaluation to" }, "custom_metrics": { "anyOf": [ { "items": { "type": "string", "format": "uuid" }, "type": "array" }, { "type": "null" } ], "title": "Custom Metrics", "description": "List of additional custom metrics to be used in the call" }, "custom_metric_tags": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Custom Metric Tags", "description": "Specify one or more tags to include all custom metrics associated with those tags. This allows you to run groups of related custom metrics without listing each individually." }, "label": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Label", "description": "Label of the agent to use for the evaluation (determines which prompt and knowledge base to use and defaults to the `production` label if not provided)" }, "enable_phrase_latencies": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Enable Phrase Latencies", "description": "Whether to enable phrase-level latency tracking for this call" }, "conversation_ended_by": { "anyOf": [ { "$ref": "#/components/schemas/ParticipantRole" }, { "type": "null" } ], "description": "Which participant role ended the conversation: 'USER' or 'AGENT'" }, "multichannel": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Multichannel", "description": "Whether the participants of the call are on different audio channels", "default": false } }, "type": "object", "required": [ "agent_id", "start_time_utc", "participants" ], "title": "Call Request Using Bluejay Agent ID" }, "CallRequestUsingExternalAgentId": { "properties": { "external_agent_id": { "type": "string", "title": "External Agent Id", "description": "The external ID of your agent to associate with the call" }, "recording_url": { "anyOf": [ { "type": "string", "maxLength": 2083, "minLength": 1, "format": "uri" }, { "type": "null" } ], "title": "Recording Url", "description": "URL to the recording file (supported formats: .mp3, .mp4, .wav, .m4a)" }, "recording_base64": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Recording Base64", "description": "Base64 encoded recording file in data URL format (supported formats: .mp3, .mp4, .wav, .m4a)" }, "start_time_utc": { "type": "string", "format": "date-time", "title": "Start Time Utc", "description": "When the call started, in UTC ([python] log: datetime.now(timezone.utc) at call start)" }, "participants": { "items": { "$ref": "#/components/schemas/Participant" }, "type": "array", "maxItems": 2, "minItems": 2, "title": "Participants", "description": "List of call participants" }, "call_direction": { "anyOf": [ { "$ref": "#/components/schemas/CallDirection" }, { "type": "null" } ], "description": "Direction of the call from the Agent's perspective (INBOUND or OUTBOUND)", "default": "INBOUND" }, "interface": { "anyOf": [ { "$ref": "#/components/schemas/CallInterface" }, { "type": "null" } ], "description": "Interface used for the call", "default": "PHONE" }, "transcript_url": { "anyOf": [ { "type": "string", "maxLength": 2083, "minLength": 1, "format": "uri" }, { "type": "null" } ], "title": "Transcript Url", "description": "URL to the transcript file (supported formats: .json)" }, "transcript": { "anyOf": [ { "items": { "$ref": "#/components/schemas/TranscriptEntryRequest" }, "type": "array" }, { "type": "null" } ], "title": "Transcript", "description": "Transcript of the call in text format" }, "tool_calls": { "anyOf": [ { "items": { "$ref": "#/components/schemas/ToolCall" }, "type": "array" }, { "type": "null" } ], "title": "Tool Calls", "description": "List of tool calls made during the call" }, "events": { "anyOf": [ { "items": { "$ref": "#/components/schemas/Event" }, "type": "array" }, { "type": "null" } ], "title": "Events", "description": "List of events that occurred during the call" }, "tags": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Tags", "description": "List of tags associated with the call" }, "trace_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Trace Id", "description": "Trace ID of the call" }, "created_at": { "anyOf": [ { "type": "string", "format": "date-time" }, { "type": "null" } ], "title": "Created At", "description": "When this request was created (defaults to now in UTC)" }, "metadata": { "anyOf": [ { "additionalProperties": true, "type": "object" }, { "type": "null" } ], "title": "Metadata", "description": "Additional metadata associated with the evaluation" }, "webhook_tag": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Webhook Tag", "description": "Tag of the webhook to send the evaluation to" }, "custom_metrics": { "anyOf": [ { "items": { "type": "string", "format": "uuid" }, "type": "array" }, { "type": "null" } ], "title": "Custom Metrics", "description": "List of additional custom metrics to be used in the call" }, "custom_metric_tags": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Custom Metric Tags", "description": "Specify one or more tags to include all custom metrics associated with those tags. This allows you to run groups of related custom metrics without listing each individually." }, "label": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Label", "description": "Label of the agent to use for the evaluation (determines which prompt and knowledge base to use)", "default": "production" }, "enable_phrase_latencies": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Enable Phrase Latencies", "description": "Whether to enable phrase-level latency tracking for this call" }, "conversation_ended_by": { "anyOf": [ { "$ref": "#/components/schemas/ParticipantRole" }, { "type": "null" } ], "description": "Which participant role ended the conversation: 'USER' or 'AGENT'" }, "multichannel": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Multichannel", "description": "Whether the participants of the call are on different audio channels", "default": false } }, "type": "object", "required": [ "external_agent_id", "start_time_utc", "participants" ], "title": "Call Request Using External Agent ID" }, "CallStatus": { "type": "string", "enum": [ "INITIALIZING", "QUEUED", "EVALUATING", "COMPLETED", "INCOMPLETED" ], "title": "CallStatus", "description": "Enum representing the possible states of a call." }, "CancelResponse": { "properties": { "success": { "type": "boolean", "title": "Success", "description": "Whether the cancel request was accepted" }, "message": { "type": "string", "title": "Message", "description": "Response message for the frontend" } }, "type": "object", "required": [ "success", "message" ], "title": "CancelResponse" }, "CommunitiesListResponse": { "properties": { "communities": { "items": { "$ref": "#/components/schemas/CommunityResponse" }, "type": "array", "title": "Communities", "description": "List of communities" }, "total_count": { "type": "integer", "title": "Total Count", "description": "Total number of communities" } }, "type": "object", "required": [ "communities", "total_count" ], "title": "CommunitiesListResponse", "description": "Response model for listing communities" }, "CommunityResponse": { "properties": { "id": { "type": "string", "title": "Id", "description": "Unique identifier for the community" }, "title": { "type": "string", "title": "Title", "description": "Title of the community" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Description", "description": "Description of the community" }, "created_at": { "type": "string", "format": "date-time", "title": "Created At", "description": "When this community was created" }, "digital_human_ids": { "items": { "type": "integer" }, "type": "array", "title": "Digital Human Ids", "description": "List of digital human (test case) IDs associated with this community" } }, "type": "object", "required": [ "id", "title", "created_at" ], "title": "CommunityResponse", "description": "Response model for community operations" }, "ComparisonRequest": { "properties": { "experiment_run_ids": { "items": { "type": "integer" }, "type": "array", "title": "Experiment Run Ids", "description": "List of experiment run IDs to compare" } }, "type": "object", "required": [ "experiment_run_ids" ], "title": "ComparisonRequest", "description": "Pydantic model for experiment run comparison request" }, "ComparisonResponse": { "properties": { "summary": { "type": "string", "title": "Summary", "description": "AI-generated comparison summary of the experiment runs" }, "status": { "type": "string", "title": "Status", "description": "Status of the response", "default": "200" } }, "type": "object", "required": [ "summary" ], "title": "ComparisonResponse", "description": "Pydantic model for experiment run comparison response" }, "ConnectionType": { "type": "string", "enum": [ "SMS", "HTTP_WEBHOOK", "PHONE", "SIP", "WEBSOCKET", "LIVEKIT", "PIPECAT" ], "title": "ConnectionType", "description": "Enum representing the connection type of the agent" }, "ContextualInterruptionConfig": { "properties": { "type": { "type": "string", "const": "contextual", "title": "Type", "description": "Type discriminator for contextual interruption" }, "contextual_prompt": { "type": "string", "title": "Contextual Prompt", "description": "Contextual prompt for LLM-based interruptions" } }, "type": "object", "required": [ "type", "contextual_prompt" ], "title": "Contextual", "description": "Contextual/LLM-based interruption configuration." }, "ConversationItem": { "properties": { "call_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Call Id", "description": "Call ID (UUID as string)" }, "test_result_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Test Result Id", "description": "Test result ID" } }, "type": "object", "title": "ConversationItem", "description": "Model for a conversation in create lab request" }, "ConversationRequest": { "properties": { "type": { "type": "string", "enum": [ "test_result", "call" ], "title": "Type", "description": "Type of conversation: 'test_result' or 'call'" }, "id": { "type": "string", "title": "Id", "description": "ID of the conversation (test_result_id or call_id as string)" } }, "type": "object", "required": [ "type", "id" ], "title": "ConversationRequest", "description": "Pydantic model for conversation in evaluate-conversation request" }, "CreateAlertRequest": { "properties": { "name": { "type": "string", "title": "Name", "description": "Name of the alert" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Description", "description": "Description of the alert" }, "is_enabled": { "type": "boolean", "title": "Is Enabled", "description": "Whether the alert is enabled", "default": true }, "entity_type": { "$ref": "#/components/schemas/EntityType", "description": "Type of entity being monitored" }, "entity_field": { "type": "string", "title": "Entity Field", "description": "The specific field/metric being monitored" }, "operator": { "$ref": "#/components/schemas/Operator", "description": "Comparison operator" }, "comparison_value": { "type": "string", "title": "Comparison Value", "description": "Value to compare against" }, "notification_channels": { "items": { "$ref": "#/components/schemas/NotificationChannelRequest" }, "type": "array", "title": "Notification Channels", "description": "Notification channels configuration" }, "applies_to_all_agents": { "type": "boolean", "title": "Applies To All Agents", "description": "Whether the alert applies to all agents", "default": true }, "agent_ids": { "anyOf": [ { "items": { "type": "integer" }, "type": "array" }, { "type": "null" } ], "title": "Agent Ids", "description": "Agent IDs to associate with this alert (only used when applies_to_all_agents=False)" }, "threshold_time_interval": { "type": "integer", "title": "Threshold Time Interval", "description": "Time window in seconds for the alert (e.g. 600 for 10 minutes)", "default": 600 }, "min_events": { "type": "integer", "title": "Min Events", "description": "The minimum number of events for the alert", "default": 10 }, "source_scope": { "$ref": "#/components/schemas/SourceScope", "description": "Which data source fires this alert: 'all', 'observability', or 'simulation'", "default": "all" } }, "type": "object", "required": [ "name", "entity_type", "entity_field", "operator", "comparison_value" ], "title": "CreateAlertRequest", "description": "Request model for creating an alert" }, "CreateCommunityRequest": { "properties": { "title": { "type": "string", "title": "Title", "description": "Title of the community" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Description", "description": "Description of the community" }, "digital_human_ids": { "anyOf": [ { "items": { "type": "integer" }, "type": "array" }, { "type": "null" } ], "title": "Digital Human Ids", "description": "List of digital human (test case) IDs to associate this community with" } }, "type": "object", "required": [ "title" ], "title": "CreateCommunityRequest" }, "CreateCronJobRequest": { "properties": { "simulation_id": { "type": "string", "title": "Simulation Id", "description": "The unique identifier for the associated simulation." }, "schedule": { "anyOf": [ { "$ref": "#/components/schemas/EveryNMinutesSchedule" }, { "$ref": "#/components/schemas/EveryNHoursSchedule" }, { "$ref": "#/components/schemas/DailySchedule" }, { "$ref": "#/components/schemas/WeeklySchedule" }, { "$ref": "#/components/schemas/MonthlySchedule" }, { "$ref": "#/components/schemas/CronSchedule" } ], "title": "Schedule", "description": "The schedule for the cron job." }, "enabled": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Enabled", "description": "Whether the cron job should be enabled upon creation.", "default": true } }, "type": "object", "required": [ "simulation_id", "schedule" ], "title": "CreateCronJobRequest" }, "CreateCronJobResponse": { "properties": { "id": { "type": "string", "title": "Id", "description": "The unique identifier for the created cron job." }, "simulation_id": { "type": "string", "title": "Simulation Id", "description": "The unique identifier for the associated simulation." }, "cron_expression": { "type": "string", "title": "Cron Expression", "description": "The cron expression defining the job schedule." }, "enabled": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Enabled", "description": "Whether the cron job is enabled." } }, "type": "object", "required": [ "id", "simulation_id", "cron_expression" ], "title": "CreateCronJobResponse" }, "CreateCustomMetricRequest": { "properties": { "agent_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Agent Id", "description": "ID of the agent this metric belongs to (deprecated, use agent_ids instead)", "deprecated": true }, "agent_ids": { "anyOf": [ { "items": { "type": "integer" }, "type": "array" }, { "type": "null" } ], "title": "Agent Ids", "description": "List of agent IDs to associate this metric with" }, "name": { "type": "string", "title": "Name", "description": "Name of the custom metric" }, "description": { "type": "string", "title": "Description", "description": "Description of what this metric measures" }, "response_type": { "$ref": "#/components/schemas/src__models__custom_metric__ResponseType", "description": "Type of response expected" }, "min_value": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "title": "Min Value", "description": "Minimum value for quantitative metrics" }, "max_value": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "title": "Max Value", "description": "Maximum value for quantitative metrics" }, "category": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Category", "description": "Category for organizing metrics" }, "tags": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Tags", "description": "Tags for categorizing the metric" }, "scoring_guidance": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Scoring Guidance", "description": "Guidance on how to score this metric" }, "eval_route": { "anyOf": [ { "$ref": "#/components/schemas/EvalRoute" }, { "type": "null" } ], "description": "Route for evaluating the metric", "default": "AUTO" }, "model": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Model", "description": "Model to use for text evaluation of the metric" }, "audio_model": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Audio Model", "description": "Model to use for audio evaluation of the metric" }, "temperature": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "title": "Temperature", "description": "Temperature for evaluating the metric" }, "enum_options": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Enum Options", "description": "Options for enum metrics" }, "allow_not_applicable": { "type": "boolean", "title": "Allow Not Applicable", "description": "Whether this metric allows 'not applicable' responses.", "default": false } }, "type": "object", "required": [ "name", "description", "response_type" ], "title": "CreateCustomMetricRequest", "description": "Request model for creating a custom metric" }, "CreateCustomMetricsBulkRequest": { "properties": { "metrics": { "items": { "$ref": "#/components/schemas/CreateCustomMetricRequest" }, "type": "array", "title": "Metrics", "description": "List of custom metrics to create" } }, "type": "object", "required": [ "metrics" ], "title": "CreateCustomMetricsBulkRequest", "description": "Request model for creating multiple custom metrics" }, "CreateCustomMetricsBulkResponse": { "properties": { "metrics": { "items": { "$ref": "#/components/schemas/CustomMetricResponse" }, "type": "array", "title": "Metrics", "description": "List of created custom metrics" } }, "type": "object", "required": [ "metrics" ], "title": "CreateCustomMetricsBulkResponse", "description": "Response model for bulk creating custom metrics" }, "CreateCustomerPersonaRequest": { "properties": { "agent_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Agent Id", "description": "ID of the agent this persona belongs to" }, "name": { "type": "string", "title": "Name", "description": "Name of the customer persona" }, "description": { "type": "string", "title": "Description", "description": "Description of the customer persona" }, "goal": { "type": "string", "title": "Goal", "description": "Goal of the customer persona" } }, "type": "object", "required": [ "name", "description", "goal" ], "title": "CreateCustomerPersonaRequest" }, "CreateCustomerTraitRequest": { "properties": { "agent_id": { "type": "integer", "title": "Agent Id", "description": "ID of the agent this trait belongs to" }, "name": { "type": "string", "title": "Name", "description": "Name of the trait" }, "data_type": { "$ref": "#/components/schemas/TraitDataType", "description": "Data type of the trait" }, "default_value": { "anyOf": [ {}, { "type": "null" } ], "title": "Default Value", "description": "Default value for this trait (will be converted based on data_type)" } }, "type": "object", "required": [ "agent_id", "name", "data_type" ], "title": "CreateCustomerTraitRequest", "description": "Request model for creating a customer trait definition." }, "CreateDigitalHumanRequest": { "properties": { "simulation_ids": { "anyOf": [ { "items": { "type": "integer" }, "type": "array" }, { "type": "null" } ], "title": "Simulation Ids", "description": "List of simulation IDs to associate with this digital human" }, "simulation_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Simulation Id", "description": "ID of the associated simulation. Use simulation_ids instead.", "deprecated": true }, "digital_human": { "$ref": "#/components/schemas/DigitalHumanRequestData", "description": "The digital human data" } }, "type": "object", "required": [ "digital_human" ], "title": "CreateDigitalHumanRequest", "description": "Request model for creating a digital human." }, "CreateKeyIn": { "properties": { "scope": { "type": "string", "title": "Scope" }, "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Name" } }, "type": "object", "required": [ "scope" ], "title": "CreateKeyIn" }, "CreateKnowledgeBaseVersionBody": { "properties": { "kb_text": { "type": "string", "title": "Kb Text" }, "commit_message": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Commit Message" }, "labels": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Labels" }, "metadata": { "anyOf": [ { "additionalProperties": true, "type": "object" }, { "type": "null" } ], "title": "Metadata" } }, "type": "object", "required": [ "kb_text" ], "title": "CreateKnowledgeBaseVersionBody" }, "CreateLabRequest": { "properties": { "name": { "type": "string", "maxLength": 255, "minLength": 1, "title": "Name", "description": "Name of the lab" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Description", "description": "Description of the lab" }, "tags": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Tags", "description": "Tags for the lab" }, "conversations": { "items": { "$ref": "#/components/schemas/ConversationItem" }, "type": "array", "title": "Conversations", "description": "List of conversations to associate with the lab" }, "metric_ids": { "items": { "type": "string" }, "type": "array", "title": "Metric Ids", "description": "List of custom metric IDs (UUIDs as strings) to associate with the lab" } }, "type": "object", "required": [ "name", "conversations", "metric_ids" ], "title": "CreateLabRequest", "description": "Request model for creating a lab" }, "CreateLabelBody": { "properties": { "label_text": { "type": "string", "title": "Label Text", "description": "text for the label" } }, "type": "object", "required": [ "label_text" ], "title": "CreateLabelBody" }, "CreateMetricRevisionRequest": { "properties": { "custom_metric_id": { "type": "string", "title": "Custom Metric Id", "description": "Custom metric ID (UUID as string)" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Description", "description": "Description of the metric revision" }, "scoring_guidance": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Scoring Guidance", "description": "Scoring guidance for the metric revision" }, "eval_route": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Eval Route", "description": "Evaluation route (e.g., 'AUDIO', 'TEXT', 'AUTO')" }, "model": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Model", "description": "Model to use for evaluation" }, "temperature": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "title": "Temperature", "description": "Temperature for evaluation (0-2)" }, "allow_not_applicable": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Allow Not Applicable", "description": "Whether to allow 'not applicable' responses" } }, "type": "object", "required": [ "custom_metric_id" ], "title": "CreateMetricRevisionRequest", "description": "Request model for creating a metric revision" }, "CreateOrUpdateHumanEvaluationRequest": { "properties": { "custom_metric_id": { "type": "string", "title": "Custom Metric Id", "description": "Custom metric ID (UUID as string)" }, "call_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Call Id", "description": "Call ID (UUID as string)" }, "test_result_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Test Result Id", "description": "Test result ID" }, "human_response_value": { "type": "string", "title": "Human Response Value", "description": "Human evaluation response value" }, "human_reasoning": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Human Reasoning", "description": "Human evaluator's reasoning for the score" } }, "type": "object", "required": [ "custom_metric_id", "human_response_value" ], "title": "CreateOrUpdateHumanEvaluationRequest", "description": "Request model for creating or updating a human evaluation" }, "CreatePromptVersionBody": { "properties": { "prompt_text": { "type": "string", "title": "Prompt Text" }, "commit_message": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Commit Message" }, "labels": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Labels" }, "metadata": { "anyOf": [ { "additionalProperties": true, "type": "object" }, { "type": "null" } ], "title": "Metadata" } }, "type": "object", "required": [ "prompt_text" ], "title": "CreatePromptVersionBody", "description": "body for agent-scoped create version endpoint (agent_id in path)." }, "CreateWorkflowV2Request": { "properties": { "name": { "type": "string", "maxLength": 255, "minLength": 1, "title": "Name", "description": "Name of the workflow" }, "agent_ids": { "anyOf": [ { "items": { "type": "integer" }, "type": "array" }, { "type": "null" } ], "title": "Agent Ids", "description": "Owning agents (must belong to your organization). Omit or null for org-only workflow." }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Description", "description": "Human-readable description of the workflow" }, "definition": { "additionalProperties": true, "type": "object", "title": "Definition", "description": "React Flow graph. Omitted `nodes` / `edges` default to []. With no `single` or `options` nodes, the graph is stored as a draft (only multiple-start is rejected). Once there is content, export rules apply (paths, branch_options, etc.)." } }, "type": "object", "required": [ "name", "definition" ], "title": "CreateWorkflowV2Request", "description": "Create a workflow; ``definition`` is a React Flow graph (``nodes``, ``edges``, optional ``viewport``).", "examples": [ { "agent_ids": [], "definition": { "edges": [ { "source": "wf-start", "target": "n-greet" } ], "nodes": [ { "data": { "id": "wf-start" }, "deletable": false, "draggable": true, "id": "wf-start", "position": { "x": 100, "y": 50 }, "type": "start" }, { "data": { "id": "n-greet", "message": "Hi, how can I help?", "speaker": "agent", "turn": 0, "type": "contextual" }, "id": "n-greet", "position": { "x": 200, "y": 180 }, "type": "single" } ] }, "description": "Password reset IVR", "name": "Support reset flow" } ] }, "CronSchedule": { "properties": { "frequency": { "type": "string", "const": "cron", "title": "Frequency" }, "expression": { "type": "string", "title": "Expression", "description": "Cron expression" } }, "type": "object", "required": [ "frequency", "expression" ], "title": "CronSchedule" }, "CustomMetricResponse": { "properties": { "id": { "type": "string", "title": "Id", "description": "Unique identifier for the custom metric" }, "name": { "type": "string", "title": "Name", "description": "Name of the custom metric" }, "description": { "type": "string", "title": "Description", "description": "Description of what this metric measures" }, "response_type": { "$ref": "#/components/schemas/src__models__custom_metric__ResponseType", "description": "Type of response expected" }, "agent_ids": { "items": { "type": "integer" }, "type": "array", "title": "Agent Ids", "description": "List of agent IDs this metric belongs to" }, "min_value": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "title": "Min Value", "description": "Minimum value for quantitative metrics" }, "max_value": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "title": "Max Value", "description": "Maximum value for quantitative metrics" }, "category": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Category", "description": "Category for organizing metrics" }, "tags": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Tags", "description": "Tags for categorizing the metric" }, "scoring_guidance": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Scoring Guidance", "description": "Guidance on how to score this metric" }, "created_at": { "type": "string", "format": "date-time", "title": "Created At", "description": "When this metric was created" }, "eval_route": { "anyOf": [ { "$ref": "#/components/schemas/EvalRoute" }, { "type": "null" } ], "description": "Route for evaluating the metric" }, "model": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Model", "description": "Model to use for text evaluation of the metric" }, "audio_model": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Audio Model", "description": "Model to use for audio evaluation of the metric" }, "temperature": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "title": "Temperature", "description": "Temperature for evaluating the metric" }, "enum_options": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Enum Options", "description": "Options for enum metrics" }, "allow_not_applicable": { "type": "boolean", "title": "Allow Not Applicable", "description": "Whether this metric allows 'not applicable' responses.", "default": false } }, "type": "object", "required": [ "id", "name", "description", "response_type", "created_at" ], "title": "CustomMetricResponse", "description": "Response model for custom metric operations" }, "CustomMetricUpdates": { "properties": { "tags": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Tags" }, "agent_ids": { "anyOf": [ { "items": { "type": "integer" }, "type": "array" }, { "type": "null" } ], "title": "Agent Ids" }, "eval_route": { "anyOf": [ { "$ref": "#/components/schemas/EvalRoute" }, { "type": "null" } ] }, "model": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Model" }, "audio_model": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Audio Model" }, "temperature": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "title": "Temperature" }, "allow_not_applicable": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Allow Not Applicable" } }, "type": "object", "title": "CustomMetricUpdates", "description": "Patch payload; only keys that are present are applied; each value (including null) is written." }, "CustomMetricsListResponse": { "properties": { "metrics": { "items": { "$ref": "#/components/schemas/CustomMetricResponse" }, "type": "array", "title": "Metrics", "description": "List of custom metrics" }, "total_count": { "type": "integer", "title": "Total Count", "description": "Total number of metrics across all pages" }, "page": { "type": "integer", "title": "Page", "description": "Current page number" }, "page_size": { "type": "integer", "title": "Page Size", "description": "Requested number of items per page" }, "items_in_page": { "type": "integer", "title": "Items In Page", "description": "Actual number of items in current page" }, "total_pages": { "type": "integer", "title": "Total Pages", "description": "Total number of pages" } }, "type": "object", "required": [ "metrics", "total_count", "page", "page_size", "items_in_page", "total_pages" ], "title": "CustomMetricsListResponse", "description": "Response model for listing custom metrics" }, "CustomerPersonaPydantic": { "properties": { "id": { "anyOf": [ { "type": "string", "format": "uuid" }, { "type": "null" } ], "title": "Id" }, "created_at": { "anyOf": [ { "type": "string", "format": "date-time" }, { "type": "null" } ], "title": "Created At" }, "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Name" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Description" }, "goal": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Goal" }, "org_id": { "anyOf": [ { "type": "string", "format": "uuid" }, { "type": "null" } ], "title": "Org Id" } }, "type": "object", "title": "CustomerPersonaPydantic", "description": "Pydantic version of CustomerPersona for validation and serialization." }, "CustomerPersonaRequest": { "properties": { "name": { "type": "string", "title": "Name", "description": "Name of the customer persona" }, "description": { "type": "string", "title": "Description", "description": "Description of the customer persona" }, "goal": { "type": "string", "title": "Goal", "description": "Goal or objective of the customer persona" }, "num_calls": { "type": "integer", "title": "Num Calls", "description": "Number of calls that matched the customer persona" } }, "type": "object", "required": [ "name", "description", "goal", "num_calls" ], "title": "CustomerPersonaRequest", "description": "Pydantic model for customer persona in simulation" }, "CustomerTraitResponse": { "properties": { "id": { "type": "string", "title": "Id", "description": "Unique identifier for the customer trait" }, "agent_id": { "type": "integer", "title": "Agent Id", "description": "ID of the agent this trait belongs to" }, "name": { "type": "string", "title": "Name", "description": "Name of the trait" }, "data_type": { "$ref": "#/components/schemas/TraitDataType", "description": "Data type of the trait" }, "default_value": { "anyOf": [ {}, { "type": "null" } ], "title": "Default Value", "description": "Default value for this trait (stored as JSONB)" }, "created_at": { "type": "string", "format": "date-time", "title": "Created At", "description": "When the trait was created" } }, "type": "object", "required": [ "id", "agent_id", "name", "data_type", "created_at" ], "title": "CustomerTraitResponse", "description": "Response model for customer trait operations." }, "CustomerTraitsListResponse": { "properties": { "traits": { "items": { "$ref": "#/components/schemas/CustomerTraitResponse" }, "type": "array", "title": "Traits", "description": "List of customer traits" }, "total_count": { "type": "integer", "title": "Total Count", "description": "Total number of traits" } }, "type": "object", "required": [ "traits", "total_count" ], "title": "CustomerTraitsListResponse", "description": "Response model for listing customer traits." }, "DailySchedule": { "properties": { "frequency": { "type": "string", "const": "daily", "title": "Frequency" }, "time": { "type": "string", "pattern": "^\\d{2}:\\d{2}$", "title": "Time", "description": "HH:MM 24hr time" } }, "type": "object", "required": [ "frequency", "time" ], "title": "DailySchedule" }, "DeleteAlertResponse": { "properties": { "message": { "type": "string", "title": "Message", "description": "Success message" }, "deleted_alert_id": { "type": "string", "title": "Deleted Alert Id", "description": "ID of the deleted alert" } }, "type": "object", "required": [ "message", "deleted_alert_id" ], "title": "DeleteAlertResponse", "description": "Response model for deleting an alert" }, "DeleteCallLogResponse": { "properties": { "message": { "type": "string", "title": "Message", "description": "Success message" }, "status": { "type": "string", "title": "Status", "description": "Status of the response", "default": "200" } }, "type": "object", "required": [ "message" ], "title": "DeleteCallLogResponse" }, "DeleteCronJobResponse": { "properties": { "status": { "type": "string", "enum": [ "success", "error" ], "title": "Status", "description": "The status of the delete operation." }, "message": { "type": "string", "title": "Message", "description": "A message providing additional details about the operation." } }, "type": "object", "required": [ "status", "message" ], "title": "DeleteCronJobResponse" }, "DeleteCustomerTraitResponse": { "properties": { "message": { "type": "string", "title": "Message", "description": "Success message" }, "deleted_trait_id": { "type": "string", "title": "Deleted Trait Id", "description": "ID of the deleted trait" } }, "type": "object", "required": [ "message", "deleted_trait_id" ], "title": "DeleteCustomerTraitResponse", "description": "Response model for deleting a customer trait." }, "DeleteLabResponse": { "properties": { "message": { "type": "string", "title": "Message", "description": "Success message" }, "deleted_lab_id": { "type": "string", "title": "Deleted Lab Id", "description": "ID of the deleted lab" } }, "type": "object", "required": [ "message", "deleted_lab_id" ], "title": "DeleteLabResponse", "description": "Response model for deleting a lab" }, "DeleteSimulationResponse": { "properties": { "message": { "type": "string", "title": "Message", "description": "Success message" }, "deleted_simulation_id": { "type": "integer", "title": "Deleted Simulation Id", "description": "ID of the deleted simulation" } }, "type": "object", "required": [ "message", "deleted_simulation_id" ], "title": "DeleteSimulationResponse", "description": "Response model for deleting a simulation" }, "DeleteSimulationResultResponse": { "properties": { "message": { "type": "string", "title": "Message", "description": "Success message" }, "deleted_simulation_result_id": { "type": "integer", "title": "Deleted Simulation Result Id", "description": "ID of the deleted simulation result" } }, "type": "object", "required": [ "message", "deleted_simulation_result_id" ], "title": "DeleteSimulationResultResponse", "description": "Response model for the delete simulation result API (customer-facing)." }, "DeleteSimulationRunResponse": { "properties": { "message": { "type": "string", "title": "Message", "description": "Success message" }, "deleted_simulation_run_id": { "type": "integer", "title": "Deleted Simulation Run Id", "description": "ID of the deleted simulation run" } }, "type": "object", "required": [ "message", "deleted_simulation_run_id" ], "title": "DeleteSimulationRunResponse", "description": "Response model for deleting a simulation run." }, "DeleteWorkflowV2Response": { "properties": { "message": { "type": "string", "title": "Message", "description": "Success message" }, "deleted_workflow_id": { "type": "string", "title": "Deleted Workflow Id", "description": "ID of the deleted workflow" } }, "type": "object", "required": [ "message", "deleted_workflow_id" ], "title": "DeleteWorkflowV2Response", "description": "Delete confirmation." }, "DigitalHumanRequest": { "properties": { "agent_id": { "type": "string", "title": "Agent Id", "description": "ID of the agent to be used to generate the digital humans" }, "simulation_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Simulation Id", "description": "Optionally attach the digital humans to a simulation" }, "prompt_id": { "anyOf": [ { "type": "string", "format": "uuid" }, { "type": "null" } ], "title": "Prompt Id", "description": "Prompt UUID associated with the simulation" }, "knowledge_base_id": { "anyOf": [ { "type": "string", "format": "uuid" }, { "type": "null" } ], "title": "Knowledge Base Id", "description": "Knowledge base UUID associated with the simulation" }, "goal_adherence": { "anyOf": [ { "items": { "$ref": "#/components/schemas/GoalAdherence" }, "type": "array" }, { "type": "null" } ], "title": "Goal Adherence", "description": "List of goal adherence scenarios" }, "workflow_adherence": { "anyOf": [ { "additionalProperties": { "type": "integer" }, "type": "object" }, { "type": "null" } ], "title": "Workflow Adherence", "description": "Dictionary of workflow IDs and their counts" }, "workflow_adherence_v2": { "anyOf": [ { "additionalProperties": { "type": "integer" }, "type": "object" }, { "type": "null" } ], "title": "Workflow Adherence V2", "description": "Dictionary of workflow_v2 IDs and their counts (uses new graph definition format). Counts are capped at 200 paths per workflow." }, "replay_transcript": { "anyOf": [ { "items": { "anyOf": [ { "$ref": "#/components/schemas/ReplayTranscriptFromText" }, { "$ref": "#/components/schemas/ReplayTranscriptFromConversation" } ] }, "type": "array" }, { "type": "null" } ], "title": "Replay Transcript", "description": "List of transcript replays to generate digital humans from" }, "customer_personas": { "anyOf": [ { "items": { "$ref": "#/components/schemas/CustomerPersonaRequest" }, "type": "array" }, { "type": "null" } ], "title": "Customer Personas", "description": "List of customer personas to be used in the simulation" }, "load_testing": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Load Testing", "description": "Number of load testing calls", "default": 0 }, "red_teaming": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Red Teaming", "description": "Number of red teaming calls", "default": 0 }, "traits": { "anyOf": [ { "items": { "$ref": "#/components/schemas/Trait" }, "type": "array" }, { "type": "null" } ], "title": "Traits", "description": "List of traits to apply to all generated digital humans" }, "num_runs": { "anyOf": [ { "type": "integer", "minimum": 1.0 }, { "type": "null" } ], "title": "Num Runs", "description": "Number of runs per digital human per simulation run (run count).", "default": 1 } }, "type": "object", "required": [ "agent_id" ], "title": "DigitalHumanRequest", "description": "Pydantic model for digital humans (simulation type) request" }, "DigitalHumanRequestData": { "properties": { "intent": { "type": "string", "title": "Intent", "description": "Description of the digital human. Leave empty when enriched_playback is set; the agent uses playback instead.", "default": "" }, "success_criteria": { "type": "string", "title": "Success Criteria", "description": "Success criteria. Leave empty when enriched_playback is set; the agent uses playback instead.", "default": "" }, "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Name", "description": "Name of the digital human" }, "tag": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Tag", "description": "Tag for categorizing the digital human" }, "language": { "anyOf": [ { "$ref": "#/components/schemas/LanguageType" }, { "type": "null" } ], "description": "Language the digital human speaks", "default": "en" }, "accent": { "anyOf": [ { "$ref": "#/components/schemas/AccentType" }, { "type": "null" } ], "description": "Accent of the digital human" }, "gender": { "anyOf": [ { "$ref": "#/components/schemas/GenderType" }, { "type": "null" } ], "description": "Gender of the digital human" }, "background_noise": { "anyOf": [ { "$ref": "#/components/schemas/BackgroundNoiseType" }, { "type": "null" } ], "description": "Type of background noise", "default": "none" }, "voice_speed": { "anyOf": [ { "$ref": "#/components/schemas/VoiceSpeedType" }, { "type": "null" } ], "description": "Speed of the digital human's voice", "default": "normal" }, "audio_quality": { "anyOf": [ { "$ref": "#/components/schemas/AudioQualityType" }, { "type": "null" } ], "description": "Audio quality of the digital human's voice", "default": "high" }, "fluency": { "anyOf": [ { "$ref": "#/components/schemas/FluencyType" }, { "type": "null" } ], "description": "Fluency level of the digital human's speech", "default": "native" }, "verbosity": { "anyOf": [ { "$ref": "#/components/schemas/VerbosityType" }, { "type": "null" } ], "description": "Verbosity level of the digital human's responses", "default": "medium" }, "phone_number": { "type": "string", "title": "Phone Number", "description": "Phone number for the digital human" }, "outbound_text_number": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Outbound Text Number", "description": "Outbound text number" }, "background_noise_volume": { "anyOf": [ { "type": "number", "maximum": 1.0, "minimum": 0.0 }, { "type": "null" } ], "title": "Background Noise Volume", "description": "Volume of background noise", "default": 0.8 }, "expected_tool_calls": { "anyOf": [ { "items": { "$ref": "#/components/schemas/ExpectedToolCall" }, "type": "array" }, { "type": "null" } ], "title": "Expected Tool Calls", "description": "Expected tool call outputs" }, "allow_end_call_tool": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Allow End Call Tool", "description": "Allow the digital human to end the tool call", "default": true }, "endpointing_delay": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "title": "Endpointing Delay", "description": "Delay for endpointing", "default": 1.5 }, "creativity": { "anyOf": [ { "type": "number", "maximum": 2.0, "minimum": 0.0 }, { "type": "null" } ], "title": "Creativity", "description": "How creative the digital human is (Model temperature)", "default": 0.7 }, "hangup_phrases": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Hangup Phrases", "description": "Phrases that trigger hangup" }, "hangup_instructions": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Hangup Instructions", "description": "Freeform instructions for how/when to hang up" }, "allow_silence_tool": { "type": "boolean", "title": "Allow Silence Tool", "description": "Allow the digital human to use the silence tool", "default": false }, "silence_tool_instructions": { "type": "string", "title": "Silence Tool Instructions", "description": "Tool instructions; use \"default\" for built-in behavior or custom text", "default": "default" }, "silence_timeout": { "anyOf": [ { "type": "integer", "minimum": 15.0 }, { "type": "null" } ], "title": "Silence Timeout", "description": "Silence timeout in seconds" }, "role_description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Role Description", "description": "Description of the role for the digital human" }, "traits": { "anyOf": [ { "items": { "$ref": "#/components/schemas/Trait" }, "type": "array" }, { "type": "null" } ], "title": "Traits", "description": "List of traits associated with this digital human" }, "interruptions": { "anyOf": [ { "$ref": "#/components/schemas/SimpleInterruptionConfig" }, { "$ref": "#/components/schemas/KeywordsInterruptionConfig" }, { "$ref": "#/components/schemas/ContextualInterruptionConfig" }, { "type": "null" } ], "title": "Interruptions", "description": "Interruption configuration for the digital human" }, "scripted_responses": { "anyOf": [ { "items": { "$ref": "#/components/schemas/ScriptedResponse" }, "type": "array" }, { "type": "null" } ], "title": "Scripted Responses", "description": "List of scripted responses for the digital human" }, "speaks_first_config": { "anyOf": [ { "$ref": "#/components/schemas/SpeaksFirstConfig" }, { "type": "null" } ], "description": "Speaks first configuration for the digital human" }, "original_transcript": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Original Transcript", "description": "Original transcript text to replay. When provided (and formatted_transcript not provided), utterances are extracted via LLM and used as the intent." }, "formatted_transcript": { "anyOf": [ { "items": { "additionalProperties": { "type": "string" }, "type": "object" }, "type": "array" }, { "type": "null" } ], "title": "Formatted Transcript", "description": "Pre-computed structured transcript as [{role, utterance}]. When provided, skips the format-transcript LLM call." }, "enriched_playback": { "anyOf": [ { "items": { "additionalProperties": true, "type": "object" }, "type": "array" }, { "type": "null" } ], "title": "Enriched Playback", "description": "Optional enriched playback stored as JSONB: a list of turn objects" }, "always_on_mode": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Always On Mode", "description": "Whether always-on mode is enabled", "default": false }, "always_on_active": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Always On Active", "description": "When true, this DH actively receives calls on phone_number. Defaults to True when phone_number is set." }, "num_runs": { "anyOf": [ { "type": "integer", "minimum": 1.0 }, { "type": "null" } ], "title": "Num Runs", "description": "Number of times this digital human is run per simulation run (run count).", "default": 1 }, "livekit_metadata": { "anyOf": [ { "additionalProperties": true, "type": "object" }, { "type": "null" } ], "title": "Livekit Metadata", "description": "LiveKit-specific configuration and metadata for this digital human" } }, "type": "object", "required": [ "phone_number" ], "title": "DigitalHumanRequestData", "description": "Digital human data model for requests (without id and created_at)." }, "DigitalHumanResponseData": { "properties": { "id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Id", "description": "Unique identifier for the digital human" }, "intent": { "type": "string", "title": "Intent", "description": "Description of the digital human" }, "success_criteria": { "type": "string", "title": "Success Criteria", "description": "Success criteria for the digital human" }, "tag": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Tag", "description": "Tag for categorizing the digital human" }, "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Name", "description": "Name of the digital human" }, "language": { "anyOf": [ { "$ref": "#/components/schemas/LanguageType" }, { "type": "null" } ], "description": "Language of the digital human" }, "accent": { "anyOf": [ { "$ref": "#/components/schemas/AccentType" }, { "type": "null" } ], "description": "Accent of the digital human" }, "gender": { "anyOf": [ { "$ref": "#/components/schemas/GenderType" }, { "type": "null" } ], "description": "Gender of the digital human" }, "background_noise": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Background Noise", "description": "Type of background noise" }, "voice_speed": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Voice Speed", "description": "Speed of the digital human's voice" }, "audio_quality": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Audio Quality", "description": "Audio quality of the digital human's voice" }, "fluency": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Fluency", "description": "Fluency level of the digital human's speech" }, "verbosity": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Verbosity", "description": "Verbosity level of the digital human's responses" }, "phone_number": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Phone Number", "description": "Phone number for the digital human" }, "outbound_text_number": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Outbound Text Number", "description": "Outbound text number" }, "websocket_url": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Websocket Url", "description": "WebSocket URL for real-time communication" }, "background_noise_volume": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "title": "Background Noise Volume", "description": "Volume of background noise" }, "expected_tool_calls": { "anyOf": [ { "items": { "$ref": "#/components/schemas/ExpectedToolCall" }, "type": "array" }, { "type": "null" } ], "title": "Expected Tool Calls", "description": "Expected tool calls" }, "allow_end_call_tool": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Allow End Call Tool", "description": "Allow the digital human to end the tool call", "default": true }, "endpointing_delay": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "title": "Endpointing Delay", "description": "Delay for endpointing" }, "creativity": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "title": "Creativity", "description": "Temperature setting" }, "hangup_phrases": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Hangup Phrases", "description": "Phrases that trigger hangup" }, "hangup_instructions": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Hangup Instructions", "description": "Freeform instructions for how/when to hang up" }, "allow_silence_tool": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Allow Silence Tool", "description": "Allow the digital human to use the silence tool", "default": false }, "silence_tool_instructions": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Silence Tool Instructions", "description": "Tool instructions; \"default\" for built-in behavior or a custom string.", "default": "default" }, "silence_timeout": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Silence Timeout", "description": "Silence timeout in seconds" }, "role_description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Role Description", "description": "Description of the role for the digital human" }, "created_at": { "anyOf": [ { "type": "string", "format": "date-time" }, { "type": "null" } ], "title": "Created At", "description": "When this digital human was created" }, "traits": { "anyOf": [ { "items": { "$ref": "#/components/schemas/Trait" }, "type": "array" }, { "type": "null" } ], "title": "Traits", "description": "List of traits associated with this digital human" }, "interruptions": { "anyOf": [ { "additionalProperties": true, "type": "object" }, { "type": "null" } ], "title": "Interruptions", "description": "Interruption configuration for the digital human" }, "scripted_responses": { "anyOf": [ { "items": { "$ref": "#/components/schemas/ScriptedResponse" }, "type": "array" }, { "type": "null" } ], "title": "Scripted Responses", "description": "List of scripted responses for the digital human" }, "speaks_first_config": { "anyOf": [ { "$ref": "#/components/schemas/SpeaksFirstConfig" }, { "type": "null" } ], "description": "Speaks first config: speaks_first, mode (custom|ai_generated), message (when custom)" }, "original_transcript": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Original Transcript", "description": "The original transcript text attached to this digital human" }, "formatted_transcript": { "anyOf": [ { "items": { "additionalProperties": { "type": "string" }, "type": "object" }, "type": "array" }, { "type": "null" } ], "title": "Formatted Transcript", "description": "Structured transcript as [{\"role\": \"USER\"|\"AGENT\", \"utterance\": \"...\"}]" }, "enriched_playback": { "anyOf": [ { "items": { "additionalProperties": true, "type": "object" }, "type": "array" }, { "type": "null" } ], "title": "Enriched Playback", "description": "Optional enriched playback stored as JSONB: a list of turn objects" }, "livekit_metadata": { "anyOf": [ { "additionalProperties": true, "type": "object" }, { "type": "null" } ], "title": "Livekit Metadata", "description": "LiveKit-specific configuration and metadata for this digital human" } }, "type": "object", "required": [ "intent", "success_criteria" ], "title": "DigitalHumanResponseData", "description": "Response model for digital human data." }, "DigitalHumansListResponse": { "properties": { "digital_humans": { "items": { "$ref": "#/components/schemas/DigitalHumanResponseData" }, "type": "array", "title": "Digital Humans", "description": "List of digital humans" }, "total": { "type": "integer", "title": "Total", "description": "Total number of digital humans" }, "simulation_id": { "type": "integer", "title": "Simulation Id", "description": "ID of the simulation" } }, "type": "object", "required": [ "digital_humans", "total", "simulation_id" ], "title": "DigitalHumansListResponse", "description": "Response model for listing digital humans by simulation." }, "DigitalHumansSettings": { "properties": { "default_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Default Name", "description": "Default name for the digital human", "default": "random" }, "default_caller_number": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Default Caller Number", "description": "Default caller phone number for the digital human", "default": "random" }, "default_language": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Default Language", "description": "Default language for the digital human", "default": "random" }, "default_background_noise": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Default Background Noise", "description": "Background noise to be used in the simulation", "default": "none" }, "first_message": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "First Message", "description": "First message to be spoken by the digital human", "default": "ai_generated" }, "num_runs": { "anyOf": [ { "type": "integer", "minimum": 1.0 }, { "type": "null" } ], "title": "Num Runs", "description": "Number of runs per digital human per simulation run (run count).", "default": 1 } }, "type": "object", "title": "DigitalHumansSettings", "description": "Pydantic model for digital humans settings in simulation" }, "DuplicateWorkflowV2Request": { "properties": { "name": { "anyOf": [ { "type": "string", "maxLength": 255, "minLength": 1 }, { "type": "null" } ], "title": "Name", "description": "Name for the copy. Omit or null for \"Copy of {original name}\"." } }, "type": "object", "title": "DuplicateWorkflowV2Request", "description": "Duplicate an existing workflow (new row, same definition and agent links)." }, "EndConversationsRequest": { "properties": { "test_result_ids": { "items": { "type": "integer" }, "type": "array", "minItems": 1, "title": "Test Result Ids", "description": "List of test result IDs to end" } }, "type": "object", "required": [ "test_result_ids" ], "title": "EndConversationsRequest", "description": "Pydantic model for ending multiple conversations" }, "EndConversationsResponse": { "properties": { "success": { "type": "boolean", "title": "Success", "description": "Whether the operation was successful" }, "ended_count": { "type": "integer", "title": "Ended Count", "description": "Number of conversations marked for ending" }, "test_result_ids": { "items": { "type": "integer" }, "type": "array", "title": "Test Result Ids", "description": "Test result IDs that were processed" }, "failed_ids": { "anyOf": [ { "items": { "type": "integer" }, "type": "array" }, { "type": "null" } ], "title": "Failed Ids", "description": "Test result IDs that failed to process (if any)" }, "message": { "type": "string", "title": "Message", "description": "Status message" } }, "type": "object", "required": [ "success", "ended_count", "test_result_ids", "message" ], "title": "EndConversationsResponse", "description": "Response for end conversations request" }, "EntityType": { "type": "string", "enum": [ "standard_metric", "custom_goal", "custom_metric" ], "title": "EntityType", "description": "Enum representing the entity types for alerts." }, "EvalRoute": { "type": "string", "enum": [ "AUDIO", "TEXT", "AUTO" ], "title": "EvalRoute", "description": "Enum representing the evaluation route of a call." }, "EvaluateCallResponse": { "properties": { "status": { "type": "string", "title": "Status" }, "call_id": { "type": "string", "title": "Call Id" }, "message": { "type": "string", "title": "Message" } }, "type": "object", "required": [ "status", "call_id", "message" ], "title": "EvaluateCallResponse" }, "EvaluateConversationRequest": { "properties": { "lab_id": { "type": "string", "format": "uuid", "title": "Lab Id", "description": "Lab ID (UUID) for the evaluation" }, "conversation": { "$ref": "#/components/schemas/ConversationRequest", "description": "Conversation to evaluate" }, "metrics": { "$ref": "#/components/schemas/MetricsRequest", "description": "Metrics to use for evaluation" } }, "type": "object", "required": [ "lab_id", "conversation", "metrics" ], "title": "EvaluateConversationRequest", "description": "Pydantic model for evaluate-conversation request" }, "EvaluateConversationResponse": { "properties": { "status": { "type": "string", "title": "Status", "description": "Status of the operation" }, "message": { "type": "string", "title": "Message", "description": "Response message" }, "conversation_id": { "type": "string", "title": "Conversation Id", "description": "ID of the conversation" }, "conversation_type": { "type": "string", "title": "Conversation Type", "description": "Type of conversation" }, "metrics": { "items": { "$ref": "#/components/schemas/MetricEvaluationItem" }, "type": "array", "title": "Metrics", "description": "List of metrics with their evaluation IDs" } }, "type": "object", "required": [ "status", "message", "conversation_id", "conversation_type", "metrics" ], "title": "EvaluateConversationResponse", "description": "Pydantic model for evaluate-conversation response" }, "Evaluation": { "properties": { "id": { "type": "string", "title": "Id", "description": "Unique identifier for the evaluation result" }, "created_at": { "type": "string", "format": "date-time", "title": "Created At", "description": "When this evaluation result was created (defaults to now in UTC)" }, "hallucination": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Hallucination", "description": "Whether the agent exhibited hallucination during the call" }, "hallucination_reasoning": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Hallucination Reasoning", "description": "Reasoning behind the hallucination, if applicable" }, "redundancy": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Redundancy", "description": "Whether the agent exhibited redundancy during the call" }, "redundancy_reasoning": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Redundancy Reasoning", "description": "Reasoning behind the redundancy, if applicable" }, "agent_speak_percentage": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "title": "Agent Speak Percentage", "description": "Percentage of the call where the agent was speaking" }, "avg_agent_latency": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "title": "Avg Agent Latency", "description": "Average latency of the agent's responses during the call" }, "latency": { "anyOf": [ { "$ref": "#/components/schemas/Latency" }, { "type": "null" } ], "description": "Latency metrics for the agent's responses" }, "filler_ignored_latency": { "anyOf": [ { "$ref": "#/components/schemas/FillerIgnoredLatency" }, { "type": "null" } ], "description": "Filler ignored latency metrics" }, "num_turns": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Num Turns", "description": "Total number of turns taken by the agent during the call" }, "call_summary": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Call Summary", "description": "Summary of the call, if applicable" }, "custom_evals": { "anyOf": [ { "items": {}, "type": "array" }, { "additionalProperties": true, "type": "object" }, { "type": "null" } ], "title": "Custom Evals", "description": "List of custom evaluations performed during the call" }, "custom_evals_success_rate": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "title": "Custom Evals Success Rate", "description": "Success rate of the custom evaluations performed during the call" }, "goal_success": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Goal Success", "description": "Whether the goal was successfully achieved during the call" }, "goal_reasoning": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Goal Reasoning", "description": "Reasoning behind the goal success, if applicable" }, "pronunciation_score": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "title": "Pronunciation Score", "description": "Pronunciation score of the agent during the call" }, "pronunciation_reasoning": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Pronunciation Reasoning", "description": "Reasoning behind the pronunciation score, if applicable" }, "custom_metrics": { "anyOf": [ { "items": { "$ref": "#/components/schemas/src__models__api_custom_metric__CustomMetric" }, "type": "array" }, { "type": "null" } ], "title": "Custom Metrics", "description": "Custom metrics associated with the evaluation" } }, "type": "object", "required": [ "agent_speak_percentage", "avg_agent_latency" ], "title": "Evaluation", "description": "Pydantic model for evaluation result" }, "EvaluationDiffItem": { "properties": { "call_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Call Id", "description": "Call ID for call conversations." }, "test_result_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Test Result Id", "description": "Test result ID for test_result conversations." }, "human_value": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Human Value", "description": "Human evaluator's response (e.g. Pass/Fail, score)." }, "ai_value": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Ai Value", "description": "AI evaluator's response." }, "human_reasoning": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Human Reasoning", "description": "Human evaluator's reasoning." }, "ai_reasoning": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Ai Reasoning", "description": "AI evaluator's reasoning." } }, "type": "object", "title": "EvaluationDiffItem", "description": "One human vs AI evaluation comparison for a conversation." }, "Event": { "properties": { "title": { "type": "string", "title": "Title", "description": "Title of the event" }, "start_offset_ms": { "type": "integer", "title": "Start Offset Ms", "description": "Start offset of the event in milliseconds" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Description", "description": "Description of the event" }, "end_offset_ms": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "End Offset Ms", "description": "End offset of the event in milliseconds" }, "tags": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Tags", "description": "List of tags associated with the event" }, "metadata": { "anyOf": [ { "additionalProperties": true, "type": "object" }, { "type": "null" } ], "title": "Metadata", "description": "Additional metadata associated with the event" } }, "type": "object", "required": [ "title", "start_offset_ms" ], "title": "Event", "description": "Pydantic model for event data" }, "EveryNHoursSchedule": { "properties": { "frequency": { "type": "string", "const": "every_n_hours", "title": "Frequency" }, "interval": { "type": "integer", "maximum": 23.0, "exclusiveMinimum": 0.0, "title": "Interval", "description": "Repeat every N hours (max 23)" } }, "type": "object", "required": [ "frequency", "interval" ], "title": "EveryNHoursSchedule" }, "EveryNMinutesSchedule": { "properties": { "frequency": { "type": "string", "const": "every_n_minutes", "title": "Frequency" }, "interval": { "type": "integer", "maximum": 59.0, "exclusiveMinimum": 0.0, "title": "Interval", "description": "Repeat every N minutes (max 59)" } }, "type": "object", "required": [ "frequency", "interval" ], "title": "EveryNMinutesSchedule" }, "ExpectedToolCall": { "properties": { "name": { "type": "string", "title": "Name", "description": "Name of the expected tool call" }, "parameters": { "anyOf": [ { "additionalProperties": true, "type": "object" }, { "type": "null" } ], "title": "Parameters", "description": "Expected parameters passed to the tool call" }, "output": { "anyOf": [ {}, { "type": "null" } ], "title": "Output", "description": "Expected output returned by the tool call" } }, "type": "object", "required": [ "name" ], "title": "ExpectedToolCall", "description": "Represents an expected tool call during a conversation." }, "ExpectedToolCallDetail": { "properties": { "parameters": { "anyOf": [ { "additionalProperties": true, "type": "object" }, { "type": "null" } ], "title": "Parameters", "description": "Expected parameters" }, "output": { "anyOf": [ {}, { "type": "null" } ], "title": "Output", "description": "Expected output" } }, "type": "object", "title": "ExpectedToolCallDetail" }, "FillerIgnoredLatency": { "properties": { "avg_filler_ignored_latency": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "title": "Avg Filler Ignored Latency", "description": "Average filler ignored latency", "default": 0 }, "p50_filler_ignored_latency": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "title": "P50 Filler Ignored Latency", "description": "50th percentile filler ignored latency", "default": 0 }, "p90_filler_ignored_latency": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "title": "P90 Filler Ignored Latency", "description": "90th percentile filler ignored latency", "default": 0 }, "p95_filler_ignored_latency": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "title": "P95 Filler Ignored Latency", "description": "95th percentile filler ignored latency", "default": 0 }, "p99_filler_ignored_latency": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "title": "P99 Filler Ignored Latency", "description": "99th percentile filler ignored latency", "default": 0 } }, "type": "object", "title": "FillerIgnoredLatency" }, "FluencyType": { "type": "string", "enum": [ "beginner", "intermediate", "native" ], "title": "FluencyType", "description": "Enum for fluency level options." }, "FolderCreateRequest": { "properties": { "name": { "type": "string", "title": "Name", "description": "Name of the folder" } }, "type": "object", "required": [ "name" ], "title": "FolderCreateRequest" }, "FolderDeleteResponse": { "properties": { "folder_id": { "type": "string", "format": "uuid", "title": "Folder Id", "description": "ID of the deleted folder" }, "status": { "type": "string", "title": "Status", "description": "Status of the deletion", "default": "success" } }, "type": "object", "required": [ "folder_id" ], "title": "FolderDeleteResponse" }, "FolderResponse": { "properties": { "id": { "type": "string", "format": "uuid", "title": "Id", "description": "ID of the folder" }, "name": { "type": "string", "title": "Name", "description": "Name of the folder" }, "organization_id": { "type": "string", "title": "Organization Id", "description": "Organization ID" }, "created_at": { "type": "string", "title": "Created At", "description": "Timestamp when the folder was created" } }, "type": "object", "required": [ "id", "name", "organization_id", "created_at" ], "title": "FolderResponse" }, "FolderUpdateRequest": { "properties": { "name": { "type": "string", "title": "Name", "description": "New name for the folder" } }, "type": "object", "required": [ "name" ], "title": "FolderUpdateRequest" }, "GenderType": { "type": "string", "enum": [ "male", "female" ], "title": "GenderType", "description": "Enum for gender options." }, "GenerateCustomMetricsRequest": { "properties": { "agent_id": { "type": "string", "title": "Agent Id", "description": "ID of the agent to generate metrics for" }, "prompt_id": { "anyOf": [ { "type": "string", "format": "uuid" }, { "type": "null" } ], "title": "Prompt Id", "description": "Prompt UUID associated with the agent" }, "knowledge_base_id": { "anyOf": [ { "type": "string", "format": "uuid" }, { "type": "null" } ], "title": "Knowledge Base Id", "description": "Knowledge base UUID associated with the agent" }, "count": { "type": "integer", "title": "Count", "description": "Number of custom metrics to generate", "default": 5 }, "custom_prompt": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Custom Prompt", "description": "Custom instructions for metric generation" } }, "type": "object", "required": [ "agent_id" ], "title": "GenerateCustomMetricsRequest" }, "GenerateCustomPersonasRequest": { "properties": { "agent_id": { "type": "string", "title": "Agent Id", "description": "ID of the agent to generate personas for" }, "prompt_id": { "anyOf": [ { "type": "string", "format": "uuid" }, { "type": "null" } ], "title": "Prompt Id", "description": "Prompt UUID associated with the agent" }, "knowledge_base_id": { "anyOf": [ { "type": "string", "format": "uuid" }, { "type": "null" } ], "title": "Knowledge Base Id", "description": "Knowledge base UUID associated with the agent" }, "count": { "type": "integer", "title": "Count", "description": "Number of custom personas to generate", "default": 5 }, "custom_prompt": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Custom Prompt", "description": "Custom instructions for persona generation" } }, "type": "object", "required": [ "agent_id" ], "title": "GenerateCustomPersonasRequest" }, "GenerateFormattedTranscriptRequest": { "properties": { "original_transcript": { "type": "string", "title": "Original Transcript", "description": "Raw transcript in any format" } }, "type": "object", "required": [ "original_transcript" ], "title": "GenerateFormattedTranscriptRequest" }, "GenerateFormattedTranscriptResponse": { "properties": { "formatted_transcript": { "items": { "additionalProperties": { "type": "string" }, "type": "object" }, "type": "array", "title": "Formatted Transcript", "description": "Structured transcript: [{\"role\": \"USER\"|\"AGENT\", \"utterance\": \"...\"}]" }, "description": { "type": "string", "title": "Description", "description": "JSON-encoded list of user utterances (the intent/description field)" }, "speaks_first_config": { "anyOf": [ { "$ref": "#/components/schemas/SpeaksFirstConfig" }, { "type": "null" } ], "description": "Speaks first configuration derived from the transcript" } }, "type": "object", "required": [ "formatted_transcript", "description" ], "title": "GenerateFormattedTranscriptResponse" }, "GenerateGoalsRequest": { "properties": { "agent_id": { "type": "string", "title": "Agent Id", "description": "ID of the agent to generate goals for" }, "count": { "type": "integer", "title": "Count", "description": "Number of goals to generate", "default": 5 }, "prompt_id": { "anyOf": [ { "type": "string", "format": "uuid" }, { "type": "null" } ], "title": "Prompt Id", "description": "ID of the prompt to use for goal generation" }, "knowledge_base_id": { "anyOf": [ { "type": "string", "format": "uuid" }, { "type": "null" } ], "title": "Knowledge Base Id", "description": "ID of the knowledge base to use for goal generation" }, "custom_prompt": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Custom Prompt", "description": "Custom instructions for goal generation" } }, "type": "object", "required": [ "agent_id" ], "title": "GenerateGoalsRequest", "description": "Request model for generating goals" }, "GenerateIntentSummaryRequest": { "properties": { "test_case_id": { "type": "integer", "title": "Test Case Id", "description": "ID of the test case" } }, "type": "object", "required": [ "test_case_id" ], "title": "GenerateIntentSummaryRequest", "description": "Request model for generating intent summary." }, "GenerateIntentSummaryResponse": { "properties": { "intent_summary": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Intent Summary", "description": "The generated intent summary, or null if intent is short" }, "test_case_id": { "type": "integer", "title": "Test Case Id", "description": "ID of the test case" }, "skipped": { "type": "boolean", "title": "Skipped", "description": "True if summary was skipped because intent is short", "default": false } }, "type": "object", "required": [ "test_case_id" ], "title": "GenerateIntentSummaryResponse", "description": "Response model for generating intent summary." }, "GenerateObjectivesRequest": { "properties": { "test_case_id": { "type": "integer", "title": "Test Case Id", "description": "ID of the test case" } }, "type": "object", "required": [ "test_case_id" ], "title": "GenerateObjectivesRequest", "description": "Request model for generating objectives." }, "GenerateObjectivesResponse": { "properties": { "objectives": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Objectives", "description": "The generated objectives as a formatted string" }, "test_case_id": { "type": "integer", "title": "Test Case Id", "description": "ID of the test case" } }, "type": "object", "required": [ "test_case_id" ], "title": "GenerateObjectivesResponse", "description": "Response model for generating objectives." }, "GeneratePromptSummaryRequest": { "properties": { "prompt_id": { "type": "string", "title": "Prompt Id", "description": "ID of the prompt (UUID)" } }, "type": "object", "required": [ "prompt_id" ], "title": "GeneratePromptSummaryRequest", "description": "Request model for generating prompt summary." }, "GeneratePromptSummaryResponse": { "properties": { "prompt_summary": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Prompt Summary", "description": "The generated prompt summary, or null if prompt is short" }, "prompt_id": { "type": "string", "title": "Prompt Id", "description": "ID of the prompt" }, "skipped": { "type": "boolean", "title": "Skipped", "description": "True if summary was skipped because prompt is short", "default": false } }, "type": "object", "required": [ "prompt_id" ], "title": "GeneratePromptSummaryResponse", "description": "Response model for generating prompt summary." }, "GenerateTraitValuesRequest": { "properties": { "scenarios": { "items": { "type": "string" }, "type": "array", "title": "Scenarios", "description": "List of intents (one per scenario) to generate values for" }, "traits": { "items": { "$ref": "#/components/schemas/TraitInput" }, "type": "array", "title": "Traits", "description": "List of traits (name + data_type) to generate values for" }, "agent_prompt": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Agent Prompt", "description": "Optional agent description for context" }, "knowledge_base": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Knowledge Base", "description": "Optional knowledge base text for context" } }, "type": "object", "required": [ "scenarios", "traits" ], "title": "GenerateTraitValuesRequest", "description": "Request: list of scenarios and list of traits; values are generated per scenario per trait." }, "GetSimulationRunsResponse": { "properties": { "simulation_runs": { "items": { "$ref": "#/components/schemas/SimulationRunRes" }, "type": "array", "title": "Simulation Runs", "description": "List of simulation runs" } }, "type": "object", "title": "GetSimulationRunsResponse" }, "GetSimulationsResponse": { "properties": { "simulations": { "items": { "$ref": "#/components/schemas/SimulationRes" }, "type": "array", "title": "Simulations", "description": "List of simulations" } }, "type": "object", "title": "GetSimulationsResponse" }, "GoalAdherence": { "properties": { "goal": { "type": "string", "title": "Goal", "description": "Description of the goal" }, "num_calls": { "type": "integer", "title": "Num Calls", "description": "Number of calls that adhered to the goal" } }, "type": "object", "required": [ "goal", "num_calls" ], "title": "GoalAdherence", "description": "Pydantic model for goal adherence in simulation" }, "HTTPValidationError": { "properties": { "detail": { "items": { "$ref": "#/components/schemas/ValidationError" }, "type": "array", "title": "Detail" } }, "type": "object", "title": "HTTPValidationError" }, "HttpSimulationRunRequest": { "properties": { "simulation_id": { "type": "string", "title": "Simulation Id", "description": "ID of the simulation to be run" }, "prompt_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Prompt Id", "description": "Prompt UUID associated with this run" }, "knowledge_base_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Knowledge Base Id", "description": "Knowledge base UUID associated with this run" }, "digital_human_ids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Digital Human Ids", "description": "Digital human IDs to be used in the simulation" } }, "type": "object", "required": [ "simulation_id" ], "title": "HttpSimulationRunRequest", "description": "Request model for HTTP simulation run" }, "HttpSimulationRunResponse": { "properties": { "simulation_run_id": { "type": "string", "title": "Simulation Run Id", "description": "ID of the created simulation run (experiment_run)" }, "simulation_result_ids": { "items": { "type": "string" }, "type": "array", "title": "Simulation Result Ids", "description": "IDs of the created simulation results (test results)" }, "agent_id": { "type": "string", "title": "Agent Id", "description": "ID of the agent associated with the simulation run" }, "status": { "type": "string", "title": "Status", "description": "Status of the response", "default": "success" } }, "type": "object", "required": [ "simulation_run_id", "simulation_result_ids", "agent_id" ], "title": "HttpSimulationRunResponse", "description": "Response model for HTTP simulation run" }, "HttpTextMessageRequest": { "properties": { "message": { "type": "string", "title": "Message", "description": "Text message to send" }, "simulation_result_id": { "type": "string", "title": "Simulation Result Id", "description": "ID of the simulation result (test result)" }, "end_conversation": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "End Conversation", "description": "If true, skip lambda and end/evaluate the conversation", "default": false }, "end_turn": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "End Turn", "description": "If true, process the message now; if false, stack it for later", "default": true }, "message_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Message Id", "description": "Unique message ID for deduping within a conversation" } }, "type": "object", "required": [ "message", "simulation_result_id" ], "title": "HttpTextMessageRequest", "description": "Request model for HTTP text message" }, "HttpTextMessageResponse": { "properties": { "simulation_result_id": { "type": "string", "title": "Simulation Result Id", "description": "Simulation result ID" }, "status": { "type": "string", "title": "Status", "description": "Status of the response", "default": "success" }, "end_conversation": { "type": "boolean", "title": "End Conversation", "description": "Whether the conversation has ended", "default": false } }, "type": "object", "required": [ "simulation_result_id" ], "title": "HttpTextMessageResponse", "description": "Response model for HTTP text message" }, "HumanEvaluationResponse": { "properties": { "success": { "type": "boolean", "title": "Success", "description": "Whether the operation was successful" }, "message": { "type": "string", "title": "Message", "description": "Response message" } }, "type": "object", "required": [ "success", "message" ], "title": "HumanEvaluationResponse", "description": "Response model for human evaluation operations" }, "IntegrationKeyRequest": { "properties": { "field": { "type": "string", "title": "Field", "description": "The secret field name to retrieve" } }, "type": "object", "required": [ "field" ], "title": "IntegrationKeyRequest" }, "IntegrationKeyResponse": { "properties": { "value": { "type": "string", "title": "Value", "description": "The decrypted plaintext value" } }, "type": "object", "required": [ "value" ], "title": "IntegrationKeyResponse" }, "IntegrationsUpdateResponse": { "properties": { "success": { "type": "boolean", "title": "Success", "description": "Whether the update succeeded", "default": true }, "message": { "type": "string", "title": "Message", "description": "Human-readable result message" }, "status": { "type": "string", "title": "Status", "description": "Status code string for clients", "default": "200" }, "integrations": { "additionalProperties": true, "type": "object", "title": "Integrations", "description": "Current integration row with secrets masked (same shape as GET /integrations)" } }, "type": "object", "required": [ "message", "integrations" ], "title": "IntegrationsUpdateResponse" }, "KeyOut": { "properties": { "id": { "type": "string", "title": "Id" }, "api_key": { "type": "string", "title": "Api Key" }, "scope": { "type": "string", "title": "Scope" }, "name": { "type": "string", "title": "Name" }, "created_at": { "type": "string", "title": "Created At" }, "revoked": { "type": "boolean", "title": "Revoked" } }, "type": "object", "required": [ "id", "api_key", "scope", "name", "created_at", "revoked" ], "title": "KeyOut" }, "KeywordResponse": { "properties": { "keyword": { "type": "string", "title": "Keyword", "description": "The keyword to listen for and interrupt on" }, "response": { "type": "string", "title": "Response", "description": "Response to say when keyword is detected" }, "probability": { "type": "number", "maximum": 1.0, "minimum": 0.0, "title": "Probability", "description": "Probability of responding (0.0-1.0) - defaults to 1.0", "default": 1.0 } }, "type": "object", "required": [ "keyword", "response" ], "title": "KeywordResponse", "description": "Model for a keyword response configuration." }, "KeywordsInterruptionConfig": { "properties": { "type": { "type": "string", "const": "keywords", "title": "Type", "description": "Type discriminator for keywords interruption (required)" }, "keyword_responses": { "items": { "$ref": "#/components/schemas/KeywordResponse" }, "type": "array", "title": "Keyword Responses", "description": "Array of keyword response objects, each with keyword, response, and optional probability" } }, "type": "object", "required": [ "type", "keyword_responses" ], "title": "Keywords", "description": "Keywords-based interruption configuration." }, "KnowledgeBaseResponse": { "properties": { "id": { "anyOf": [ { "type": "string", "format": "uuid" }, { "type": "null" } ], "title": "Id", "description": "the id of the knowledge base" }, "kb_text": { "type": "string", "title": "Kb Text", "description": "the knowledge base content" }, "commit_message": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Commit Message" }, "labels": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Labels", "description": "labels associated with the knowledge base" }, "metadata": { "anyOf": [ { "additionalProperties": true, "type": "object" }, { "type": "null" } ], "title": "Metadata", "description": "arbitrary JSON metadata" }, "version": { "type": "integer", "title": "Version", "description": "the version number of the knowledge base" }, "agent_id": { "type": "integer", "title": "Agent Id", "description": "id of the agent that owns this knowledge base" } }, "type": "object", "required": [ "kb_text", "version", "agent_id" ], "title": "KnowledgeBaseResponse", "description": "response model for knowledge base without created_at." }, "LabResponse": { "properties": { "id": { "type": "string", "title": "Id", "description": "Unique identifier of the lab" }, "name": { "type": "string", "title": "Name", "description": "Name of the lab" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Description", "description": "Description of the lab" }, "created_at": { "type": "string", "format": "date-time", "title": "Created At", "description": "When the lab was created" }, "updated_at": { "anyOf": [ { "type": "string", "format": "date-time" }, { "type": "null" } ], "title": "Updated At", "description": "When the lab was last updated" } }, "type": "object", "required": [ "id", "name", "created_at" ], "title": "LabResponse", "description": "Response model for lab operations" }, "LabelDeltaRequest": { "properties": { "labels": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Labels" }, "override_label": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Override Label", "default": false } }, "type": "object", "title": "LabelDeltaRequest", "description": "request body for add/remove label operations.\n\nlabels: list of labels to add or remove. empty/null means no-op for add,\nand clear-all for remove (callers decide the semantics).\noverride_label: when true, adding an existing label moves its association\nto the requested resource; when false, conflicts return 409." }, "LabelListResponse": { "properties": { "labels": { "items": { "type": "string" }, "type": "array", "title": "Labels" } }, "type": "object", "title": "LabelListResponse", "description": "response wrapper for just a list of labels." }, "LabelPydantic": { "properties": { "id": { "anyOf": [ { "type": "string", "format": "uuid" }, { "type": "null" } ], "title": "Id" }, "created_at": { "anyOf": [ { "type": "string", "format": "date-time" }, { "type": "null" } ], "title": "Created At" }, "agent_id": { "type": "integer", "title": "Agent Id" }, "label_text": { "type": "string", "title": "Label Text" }, "prompt_id": { "anyOf": [ { "type": "string", "format": "uuid" }, { "type": "null" } ], "title": "Prompt Id" }, "knowledge_base_id": { "anyOf": [ { "type": "string", "format": "uuid" }, { "type": "null" } ], "title": "Knowledge Base Id" }, "color": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Color" } }, "type": "object", "required": [ "agent_id", "label_text" ], "title": "LabelPydantic", "description": "Represents a label record stored in the `labels` table." }, "LanguageType": { "type": "string", "enum": [ "en", "es", "pt", "ja", "tr", "hi", "ar", "ru", "zh", "ml", "fr", "yue", "vi", "de" ], "title": "LanguageType", "description": "Enum for supported language types." }, "Latency": { "properties": { "avg_agent_latency": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "title": "Avg Agent Latency", "description": "Average latency", "default": 0 }, "max_agent_latency": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "title": "Max Agent Latency", "description": "Maximum latency", "default": 0 }, "p50_agent_latency": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "title": "P50 Agent Latency", "description": "50th percentile latency", "default": 0 }, "p90_agent_latency": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "title": "P90 Agent Latency", "description": "90th percentile latency", "default": 0 }, "p95_agent_latency": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "title": "P95 Agent Latency", "description": "95th percentile latency", "default": 0 }, "p99_agent_latency": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "title": "P99 Agent Latency", "description": "99th percentile latency", "default": 0 } }, "type": "object", "title": "Latency" }, "MatchType": { "type": "string", "enum": [ "exact", "context" ], "title": "MatchType", "description": "Enum for scripted response match types." }, "MetricEvaluationItem": { "properties": { "type": { "type": "string", "title": "Type", "description": "Type of metric: 'custom_metric' or 'custom_metric_revision'" }, "id": { "type": "string", "title": "Id", "description": "Metric ID (custom_metric_id or custom_metric_revision_id)" }, "eval_id": { "type": "string", "title": "Eval Id", "description": "Evaluation ID (lab_annotate_ai_evaluation_id or lab_ai_evaluation_id)" } }, "type": "object", "required": [ "type", "id", "eval_id" ], "title": "MetricEvaluationItem", "description": "Pydantic model for a single metric evaluation item in response" }, "MetricRevisionResponse": { "properties": { "id": { "type": "string", "title": "Id", "description": "Revision ID (UUID as string)" }, "lab_id": { "type": "string", "title": "Lab Id", "description": "Lab ID (UUID as string)" }, "custom_metric_id": { "type": "string", "title": "Custom Metric Id", "description": "Custom metric ID (UUID as string)" }, "revision_number": { "type": "integer", "title": "Revision Number", "description": "Revision number (auto-incremented)" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Description", "description": "Description of the metric revision" }, "scoring_guidance": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Scoring Guidance", "description": "Scoring guidance for the metric revision" }, "eval_route": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Eval Route", "description": "Evaluation route" }, "model": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Model", "description": "Model to use for evaluation" }, "temperature": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "title": "Temperature", "description": "Temperature for evaluation" }, "allow_not_applicable": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Allow Not Applicable", "description": "Whether to allow 'not applicable' responses" }, "created_at": { "type": "string", "format": "date-time", "title": "Created At", "description": "When the revision was created" } }, "type": "object", "required": [ "id", "lab_id", "custom_metric_id", "revision_number", "created_at" ], "title": "MetricRevisionResponse", "description": "Response model for metric revision operations" }, "MetricsRequest": { "properties": { "type": { "type": "string", "enum": [ "custom_metric", "custom_metric_revision" ], "title": "Type", "description": "Type of metrics: 'custom_metric' or 'custom_metric_revision'" }, "custom_metric_ids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Custom Metric Ids", "description": "List of custom metric IDs (required when type is 'custom_metric')" }, "custom_metric_revision_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Custom Metric Revision Id", "description": "Custom metric revision ID (required when type is 'custom_metric_revision')" } }, "type": "object", "required": [ "type" ], "title": "MetricsRequest", "description": "Pydantic model for metrics in evaluate-conversation request" }, "MonthlySchedule": { "properties": { "frequency": { "type": "string", "const": "monthly", "title": "Frequency" }, "day_of_month": { "type": "integer", "maximum": 31.0, "minimum": 1.0, "title": "Day Of Month" }, "time": { "type": "string", "pattern": "^\\d{2}:\\d{2}$", "title": "Time" } }, "type": "object", "required": [ "frequency", "day_of_month", "time" ], "title": "MonthlySchedule" }, "MoveAgentRequest": { "properties": { "agent_id": { "type": "integer", "title": "Agent Id", "description": "ID of the agent to move" }, "folder_id": { "anyOf": [ { "type": "string", "format": "uuid" }, { "type": "null" } ], "title": "Folder Id", "description": "ID of the target folder (null to disassociate from any folder)" } }, "type": "object", "required": [ "agent_id" ], "title": "MoveAgentRequest" }, "MoveAgentResponse": { "properties": { "agent_id": { "type": "integer", "title": "Agent Id", "description": "ID of the agent" }, "folder_id": { "anyOf": [ { "type": "string", "format": "uuid" }, { "type": "null" } ], "title": "Folder Id", "description": "ID of the folder (null if disassociated)" }, "status": { "type": "string", "title": "Status", "description": "Status of the operation", "default": "success" } }, "type": "object", "required": [ "agent_id" ], "title": "MoveAgentResponse" }, "NotificationChannelRequest": { "properties": { "type": { "type": "string", "title": "Type", "description": "Type of notification: 'email', 'slack', or 'webhook'" }, "target": { "type": "string", "title": "Target", "description": "Target for the notification (email address, slack channel, webhook URL)" } }, "type": "object", "required": [ "type", "target" ], "title": "NotificationChannelRequest", "description": "Notification channel configuration" }, "OccurrenceMode": { "type": "string", "enum": [ "always", "first_n" ], "title": "OccurrenceMode", "description": "Enum for scripted response occurrence modes." }, "Operator": { "type": "string", "enum": [ "equals", "not_equals", "greater_than", "less_than", "greater_than_or_equal", "less_than_or_equal", "contains", "not_contains" ], "title": "Operator", "description": "Enum representing the comparison operators for alerts." }, "OptimizeMetricPromptRequest": { "properties": { "name": { "type": "string", "minLength": 1, "title": "Name", "description": "The name of the custom metric to optimize." }, "prompt": { "type": "string", "minLength": 1, "title": "Prompt", "description": "The current evaluation system prompt to optimize." }, "additional_instructions": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Additional Instructions", "description": "Additional instructions for the optimization." } }, "type": "object", "required": [ "name", "prompt" ], "title": "OptimizeMetricPromptRequest", "description": "Request body for optimizing a metric prompt (no evaluation diffs)." }, "OptimizeMetricPromptResponse": { "properties": { "optimized_prompt": { "type": "string", "title": "Optimized Prompt", "description": "The optimized version of the custom metric prompt." } }, "type": "object", "required": [ "optimized_prompt" ], "title": "OptimizeMetricPromptResponse", "description": "Response containing the optimized prompt." }, "OptimizeMetricPromptWithDiffRequest": { "properties": { "name": { "type": "string", "minLength": 1, "title": "Name", "description": "The name of the custom metric to optimize." }, "prompt": { "type": "string", "minLength": 1, "title": "Prompt", "description": "The current evaluation system prompt to optimize." }, "additional_instructions": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Additional Instructions", "description": "Additional instructions for the optimization." }, "evaluation_diffs": { "anyOf": [ { "items": { "$ref": "#/components/schemas/EvaluationDiffItem" }, "type": "array" }, { "type": "null" } ], "title": "Evaluation Diffs", "description": "List of human vs AI evaluation comparisons. Required and must not be empty." }, "diff_prompt": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Diff Prompt", "description": "System/instruction for how to use evaluation_diffs. If omitted, a default is used." } }, "type": "object", "required": [ "name", "prompt" ], "title": "OptimizeMetricPromptWithDiffRequest", "description": "Request body for optimizing a metric prompt using evaluation diffs." }, "Participant": { "properties": { "role": { "$ref": "#/components/schemas/ParticipantRole" }, "spoke_first": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Spoke First", "description": "Only provide if you would like to override the auto-detected spoke first behavior." }, "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Name" }, "phone_number": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Phone Number" } }, "type": "object", "required": [ "role" ], "title": "Participant", "description": "Represents a participant in a call." }, "ParticipantResponse": { "properties": { "role": { "$ref": "#/components/schemas/ParticipantRole", "description": "Role of the participant in the call" }, "spoke_first": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Spoke First", "description": "Whether the participant spoke first in the call" }, "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Name", "description": "Name of the participant" }, "phone_number": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Phone Number", "description": "Phone number of the participant (if applicable)" } }, "type": "object", "required": [ "role" ], "title": "ParticipantResponse", "description": "Pydantic model for participant data" }, "ParticipantRole": { "type": "string", "enum": [ "AGENT", "USER" ], "title": "ParticipantRole", "description": "Enum representing the role of a participant in a call." }, "PhoneNumberResponse": { "properties": { "id": { "type": "integer", "title": "Id", "description": "Unique identifier for the phone number record" }, "created_at": { "type": "string", "format": "date-time", "title": "Created At", "description": "Timestamp when the record was created" }, "phone_number": { "type": "string", "title": "Phone Number", "description": "The phone number in text format" }, "purchase_date": { "type": "string", "format": "date", "title": "Purchase Date", "description": "Date when the phone number was purchased" }, "price": { "type": "integer", "title": "Price", "description": "Price of the phone number in cents or smallest currency unit" }, "organization_id": { "type": "string", "format": "uuid", "title": "Organization Id", "description": "Organization ID" } }, "type": "object", "required": [ "id", "created_at", "phone_number", "purchase_date", "price", "organization_id" ], "title": "PhoneNumberResponse", "description": "Response schema for phone number data.\nBased on the database table structure with columns:\n- id: int8 (primary key)\n- created_at: timestamptz\n- phone_number: text\n- purchase_date: date\n- price: int8\n- organization_id: uuid" }, "PromptResponse": { "properties": { "id": { "anyOf": [ { "type": "string", "format": "uuid" }, { "type": "null" } ], "title": "Id", "description": "the id of the prompt" }, "prompt_text": { "type": "string", "title": "Prompt Text", "description": "the prompt content" }, "commit_message": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Commit Message" }, "labels": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Labels", "description": "labels associated with the prompt" }, "metadata": { "anyOf": [ { "additionalProperties": true, "type": "object" }, { "type": "null" } ], "title": "Metadata", "description": "arbitrary JSON metadata" }, "version": { "type": "integer", "title": "Version", "description": "the version number of the prompt" }, "agent_id": { "type": "integer", "title": "Agent Id", "description": "id of the agent that owns this prompt" } }, "type": "object", "required": [ "prompt_text", "version", "agent_id" ], "title": "PromptResponse", "description": "response model for prompt without created_at." }, "ReEvaluateCallResponse": { "properties": { "status": { "type": "string", "title": "Status" }, "call_id": { "type": "string", "title": "Call Id" }, "message": { "type": "string", "title": "Message" } }, "type": "object", "required": [ "status", "call_id", "message" ], "title": "ReEvaluateCallResponse" }, "ReEvaluateSimulationResultResponse": { "properties": { "status": { "type": "string", "title": "Status" }, "simulation_result_id": { "type": "integer", "title": "Simulation Result Id" }, "message": { "type": "string", "title": "Message" } }, "type": "object", "required": [ "status", "simulation_result_id", "message" ], "title": "ReEvaluateSimulationResultResponse" }, "ReleasePhoneNumberResponse": { "properties": { "phone_number": { "type": "string", "title": "Phone Number", "description": "Released E.164 phone number" }, "released": { "type": "boolean", "title": "Released", "description": "Whether the Twilio release was performed" } }, "type": "object", "required": [ "phone_number", "released" ], "title": "ReleasePhoneNumberResponse", "description": "Response schema after releasing a Twilio number." }, "RemoveConversationsFromLabRequest": { "properties": { "lab_id": { "type": "string", "title": "Lab Id", "description": "Lab ID (UUID as string)" }, "conversations": { "items": { "$ref": "#/components/schemas/ConversationItem" }, "type": "array", "minItems": 1, "title": "Conversations", "description": "List of conversations to remove from the lab" } }, "type": "object", "required": [ "lab_id", "conversations" ], "title": "RemoveConversationsFromLabRequest", "description": "Request model for removing conversations from a lab" }, "RemoveDigitalHumansFromSimulationRequest": { "properties": { "digital_human_ids": { "items": { "type": "integer" }, "type": "array", "title": "Digital Human Ids", "description": "array of digital human IDs to remove from this simulation" } }, "type": "object", "required": [ "digital_human_ids" ], "title": "RemoveDigitalHumansFromSimulationRequest", "description": "request body for removing digital humans from a simulation (unlink only)." }, "RemoveDigitalHumansFromSimulationResponse": { "properties": { "message": { "type": "string", "title": "Message", "description": "success message" } }, "type": "object", "required": [ "message" ], "title": "RemoveDigitalHumansFromSimulationResponse", "description": "response body for removing digital humans from a simulation (does not delete the digital humans)." }, "ReplayTranscriptFromConversation": { "properties": { "conversation_id": { "type": "string", "title": "Conversation Id", "description": "ID of an existing conversation log to retrieve transcript from" }, "success_criteria": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Success Criteria", "description": "Success criteria for the scenario (auto-generated if not provided)" }, "mode": { "type": "string", "enum": [ "strict", "smart", "persona" ], "title": "Mode", "description": "Mode for transcript replay: 'strict' (extract specific utterances), 'smart' (balanced approach - default), or 'persona' (generate persona intent)", "default": "smart" } }, "type": "object", "required": [ "conversation_id" ], "title": "Replay Transcript From Conversation ID", "description": "Replay transcript by referencing an existing conversation ID" }, "ReplayTranscriptFromText": { "properties": { "transcript": { "type": "string", "title": "Transcript", "description": "The transcript text to analyze and replay" }, "success_criteria": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Success Criteria", "description": "Success criteria for the scenario (auto-generated if not provided)" }, "mode": { "type": "string", "enum": [ "strict", "smart", "persona" ], "title": "Mode", "description": "Mode for transcript replay: 'strict' (extract specific utterances), 'smart' (balanced approach - default), or 'persona' (generate persona intent)", "default": "smart" } }, "type": "object", "required": [ "transcript" ], "title": "Replay Transcript From Text", "description": "Replay transcript by providing the transcript text directly" }, "RetrieveCallLogResponse": { "properties": { "call_log": { "$ref": "#/components/schemas/CallLog", "description": "Details of the retrieved call log" }, "status": { "type": "string", "title": "Status", "description": "Status of the response", "default": "200" } }, "type": "object", "required": [ "call_log" ], "title": "RetrieveCallLogResponse" }, "RetrieveCallLogsResponse": { "properties": { "call_logs": { "items": { "$ref": "#/components/schemas/CallLog" }, "type": "array", "title": "Call Logs", "description": "List of calls retrieved from the database" }, "total_count": { "type": "integer", "title": "Total Count", "description": "Total number of calls for this agent" }, "page": { "type": "integer", "title": "Page", "description": "Current page (1-based)" }, "page_size": { "type": "integer", "title": "Page Size", "description": "Page size" }, "total_pages": { "type": "integer", "title": "Total Pages", "description": "Total number of pages" } }, "type": "object", "required": [ "total_count", "page", "page_size", "total_pages" ], "title": "RetrieveCallLogsResponse" }, "ScriptedResponse": { "properties": { "match_type": { "$ref": "#/components/schemas/MatchType", "description": "Type of match: 'exact' or 'context'" }, "match_phrase": { "type": "string", "title": "Match Phrase", "description": "The phrase to match against" }, "response_type": { "$ref": "#/components/schemas/src__models__digital_humans__enums__ResponseType", "description": "Type of response: 'phrase', 'silence', or 'dtmf'" }, "response_value": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Response Value", "description": "The response text (required if response_type is 'phrase' or 'dtmf', optional for 'silence')" }, "occurrence_mode": { "$ref": "#/components/schemas/OccurrenceMode", "description": "When to apply: 'always' or 'first_n'" }, "occurrence_n": { "anyOf": [ { "type": "integer", "exclusiveMinimum": 0.0 }, { "type": "null" } ], "title": "Occurrence N", "description": "Number of times to apply (required if occurrence_mode is 'first_n', must be > 0)" }, "silence_duration": { "anyOf": [ { "type": "integer", "exclusiveMinimum": 0.0 }, { "type": "null" } ], "title": "Silence Duration", "description": "Duration in seconds for silence period (only used when response_type is 'silence', must be > 0 if provided)" } }, "type": "object", "required": [ "match_type", "match_phrase", "response_type", "occurrence_mode" ], "title": "ScriptedResponse", "description": "Model for a scripted response configuration." }, "SignupRequest": { "properties": { "payment_method_id": { "type": "string", "title": "Payment Method Id", "description": "Stripe payment method ID" }, "package_id": { "type": "string", "title": "Package Id", "description": "Metronome Package ID" } }, "type": "object", "required": [ "payment_method_id", "package_id" ], "title": "SignupRequest" }, "SignupResponse": { "properties": { "success": { "type": "boolean", "title": "Success", "description": "Whether the signup was successful" }, "message": { "type": "string", "title": "Message", "description": "Response message" } }, "type": "object", "required": [ "success", "message" ], "title": "SignupResponse" }, "SimpleInterruptionConfig": { "properties": { "type": { "type": "string", "enum": [ "none", "low", "medium", "high" ], "title": "Type", "description": "Interruption level: none, low, medium, or high" } }, "type": "object", "required": [ "type" ], "title": "Default", "description": "Simple interruption configuration with predefined levels." }, "SimulationPydantic": { "properties": { "id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Id" }, "agent_id": { "type": "integer", "title": "Agent Id" }, "name": { "type": "string", "title": "Name" }, "created_at": { "anyOf": [ { "type": "string", "format": "date-time" }, { "type": "null" } ], "title": "Created At" }, "settings": { "anyOf": [ { "additionalProperties": true, "type": "object" }, { "type": "null" } ], "title": "Settings" }, "type": { "$ref": "#/components/schemas/SimulationType" }, "max_concurrent": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Max Concurrent" }, "max_turns": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Max Turns" }, "ringing_timeout": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Ringing Timeout" }, "tags": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Tags" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Description" }, "pinned": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Pinned" }, "always_on": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Always On" } }, "type": "object", "required": [ "agent_id", "name", "type" ], "title": "SimulationPydantic" }, "SimulationRequest": { "properties": { "agent_id": { "type": "string", "title": "Agent Id", "description": "ID of the agent to be used in the simulation" }, "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Name", "description": "Name of the simulation" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Description", "description": "Description of the simulation" }, "prompt_id": { "anyOf": [ { "type": "string", "format": "uuid" }, { "type": "null" } ], "title": "Prompt Id", "description": "Optional default prompt UUID for this simulation" }, "knowledge_base_id": { "anyOf": [ { "type": "string", "format": "uuid" }, { "type": "null" } ], "title": "Knowledge Base Id", "description": "Optional default knowledge base UUID for this simulation" }, "sequential_calling": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Sequential Calling", "description": "Whether to run the simulation with sequential calling", "default": false }, "max_concurrent": { "anyOf": [ { "type": "integer", "maximum": 500.0, "exclusiveMinimum": 0.0 }, { "type": "null" } ], "title": "Max Concurrent", "description": "Maximum number of concurrent calls in the simulation (max 500)" }, "hangup_on_transfer": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Hangup On Transfer", "description": "Whether to hang up the call on transfer", "default": false }, "max_call_duration": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Max Call Duration", "description": "Maximum duration of each call (default is 10). Units specified by max_call_duration_units", "default": 10 }, "max_call_duration_units": { "anyOf": [ { "type": "string", "enum": [ "minutes", "seconds" ] }, { "type": "null" } ], "title": "Max Call Duration Units", "description": "Units for max_call_duration: 'minutes' (default) or 'seconds'", "default": "minutes" }, "ringing_timeout": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Ringing Timeout", "description": "Ringing timeout in seconds for SIP trunks (default 300s)", "default": 300 }, "digital_humans_settings": { "anyOf": [ { "$ref": "#/components/schemas/DigitalHumansSettings" }, { "type": "null" } ], "description": "Settings for digital humans in the simulation" }, "selected_custom_metrics": { "anyOf": [ { "items": { "type": "string", "format": "uuid" }, "type": "array" }, { "type": "null" } ], "title": "Selected Custom Metrics", "description": "Custom metric IDs to enable for this simulation" }, "custom_metrics_failing_threshold": { "anyOf": [ { "type": "integer", "maximum": 100.0, "minimum": 0.0 }, { "type": "null" } ], "title": "Custom Metrics Failing Threshold", "description": "Score threshold below which a custom metric is considered failing (0-100)" }, "custom_metrics_passing_threshold": { "anyOf": [ { "type": "integer", "maximum": 100.0, "minimum": 0.0 }, { "type": "null" } ], "title": "Custom Metrics Passing Threshold", "description": "Score threshold at or above which a custom metric is considered passing (0-100)" }, "always_on": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Always On", "description": "When true, simulation has always-on digital humans configured", "default": false } }, "type": "object", "required": [ "agent_id" ], "title": "SimulationRequest", "description": "Pydantic model for simulation request" }, "SimulationRes": { "properties": { "id": { "type": "integer", "title": "Id", "description": "ID of the simulation" }, "name": { "type": "string", "title": "Name", "description": "Name of the simulation" }, "agent_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Agent Id", "description": "ID of the agent associated with the simulation" }, "created_at": { "type": "string", "format": "date-time", "title": "Created At", "description": "When the simulation was created" }, "settings": { "anyOf": [ { "additionalProperties": true, "type": "object" }, { "type": "null" } ], "title": "Settings", "description": "Settings of the simulation" } }, "type": "object", "required": [ "id", "name", "created_at" ], "title": "SimulationRes" }, "SimulationResponse": { "properties": { "simulation_id": { "type": "integer", "title": "Simulation Id", "description": "ID of the created simulation" }, "status": { "type": "string", "title": "Status", "description": "Status of the response", "default": "200" } }, "type": "object", "required": [ "simulation_id" ], "title": "SimulationResponse" }, "SimulationResultResponse": { "properties": { "id": { "type": "integer", "title": "Id", "description": "ID of the simulation result" }, "digital_human_id": { "type": "integer", "title": "Digital Human Id", "description": "ID of the digital human associated with the simulation result" }, "result": { "anyOf": [ { "additionalProperties": true, "type": "object" }, { "type": "null" } ], "title": "Result", "description": "Result of the simulation run" }, "duration": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Duration", "description": "Duration of the simulation run in milliseconds" }, "start_time": { "anyOf": [ { "type": "string", "format": "date-time" }, { "type": "null" } ], "title": "Start Time", "description": "Start time of the simulation run" }, "end_time": { "anyOf": [ { "type": "string", "format": "date-time" }, { "type": "null" } ], "title": "End Time", "description": "End time of the simulation run" }, "custom_metrics": { "anyOf": [ { "additionalProperties": true, "type": "object" }, { "items": {}, "type": "array" }, { "type": "null" } ], "title": "Custom Metrics", "description": "Custom metrics associated with the simulation result" }, "status": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Status", "description": "Current status of the simulation result" }, "latency": { "anyOf": [ { "additionalProperties": true, "type": "object" }, { "items": {}, "type": "array" }, { "type": "null" } ], "title": "Latency", "description": "Average latency of the simulation run" }, "events": { "anyOf": [ { "items": { "$ref": "#/components/schemas/Event" }, "type": "array" }, { "type": "null" } ], "title": "Events", "description": "Events of the simulation run" }, "transcript_url": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Transcript Url", "description": "URL to the transcript file of the simulation run" }, "audio_url": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Audio Url", "description": "URL to the audio file of the simulation run" }, "evaluations": { "anyOf": [ { "items": { "$ref": "#/components/schemas/Evaluation" }, "type": "array" }, { "type": "null" } ], "title": "Evaluations", "description": "Evaluations of the simulation result" }, "tool_calls": { "anyOf": [ { "items": { "$ref": "#/components/schemas/ToolCallComparisonGroup" }, "type": "array" }, { "type": "null" } ], "title": "Tool Calls", "description": "Expected vs actual tool calls grouped by tool name" } }, "type": "object", "required": [ "id", "digital_human_id" ], "title": "SimulationResultResponse" }, "SimulationResultsResponse": { "properties": { "simulation_run": { "$ref": "#/components/schemas/SimulationRunResultResponse", "description": "Details of the simulation run" }, "simulation_results": { "anyOf": [ { "items": { "$ref": "#/components/schemas/SimulationResultResponse" }, "type": "array" }, { "type": "null" } ], "title": "Simulation Results", "description": "List of results from the simulation run" }, "status": { "type": "string", "title": "Status", "description": "Status of the response", "default": "200" } }, "type": "object", "required": [ "simulation_run" ], "title": "SimulationResultsResponse" }, "SimulationRunRes": { "properties": { "id": { "type": "integer", "title": "Id", "description": "ID of the simulation run" }, "experiment_id": { "type": "integer", "title": "Experiment Id", "description": "ID of the simulation associated with the run" }, "summary": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Summary", "description": "Summary of the simulation run" }, "tests_passed": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Tests Passed", "description": "Number of tests that passed in the simulation run" }, "tests_failed": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Tests Failed", "description": "Number of tests that failed in the simulation run" }, "total_tests": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Total Tests", "description": "Total number of tests in the simulation run" }, "tests_completed": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Tests Completed", "description": "Number of tests that were completed in the simulation run" }, "tests_incompleted": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Tests Incompleted", "description": "Number of tests that were not completed in the simulation run" }, "curr_step_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Curr Step Id", "description": "Current step ID of the simulation run" }, "created_at": { "type": "string", "format": "date-time", "title": "Created At", "description": "When the simulation run was created" }, "status": { "$ref": "#/components/schemas/SimulationRunStatus", "description": "Current status of the simulation run" }, "phone_number": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Phone Number", "description": "Phone number of the simulation run" } }, "type": "object", "required": [ "id", "experiment_id", "created_at", "status" ], "title": "SimulationRunRes" }, "SimulationRunResultResponse": { "properties": { "id": { "type": "string", "title": "Id", "description": "ID of the simulation run" }, "simulation_id": { "type": "string", "title": "Simulation Id", "description": "ID of the simulation associated with the run" }, "summary": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Summary", "description": "Summary of the simulation run" }, "status": { "anyOf": [ { "$ref": "#/components/schemas/SimulationRunStatus" }, { "type": "null" } ], "description": "Current status of the simulation run" }, "total_tests": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Total Tests", "description": "Total number of tests in the simulation run" }, "tests_passed": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Tests Passed", "description": "Number of tests that passed in the simulation run" }, "tests_failed": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Tests Failed", "description": "Number of tests that failed in the simulation run" }, "tests_completed": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Tests Completed", "description": "Number of tests that were completed in the simulation run" }, "tests_incompleted": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Tests Incompleted", "description": "Number of tests that were not completed in the simulation run" }, "created_at": { "type": "string", "format": "date-time", "title": "Created At", "description": "When the simulation run was created" } }, "type": "object", "required": [ "id", "simulation_id", "created_at" ], "title": "SimulationRunResultResponse" }, "SimulationRunStatus": { "type": "string", "enum": [ "INITIALIZING", "RUNNING", "COMPLETED", "INCOMPLETED", "INSUFFICIENT_FUNDS" ], "title": "SimulationRunStatus", "description": "Enum representing the possible states of a simulation run." }, "SimulationType": { "type": "string", "enum": [ "sequential", "parallel", "max_concurrent" ], "title": "SimulationType" }, "SingleSimulationResultResponse": { "properties": { "simulation_result": { "$ref": "#/components/schemas/SimulationResultResponse", "description": "The requested simulation result" }, "status": { "type": "string", "title": "Status", "description": "Status of the response", "default": "200" } }, "type": "object", "required": [ "simulation_result" ], "title": "SingleSimulationResultResponse" }, "SourceScope": { "type": "string", "enum": [ "all", "observability", "simulation" ], "title": "SourceScope", "description": "Allowed data source scope for when an alert fires: all, observability only, or simulation only." }, "SpeaksFirstConfig": { "properties": { "speaks_first": { "type": "boolean", "title": "Speaks First", "description": "Whether the digital human speaks first in the call" }, "mode": { "anyOf": [ { "type": "string", "enum": [ "custom", "ai_generated" ] }, { "type": "null" } ], "title": "Mode", "description": "When speaks_first is true: 'custom' (user-provided message) or 'ai_generated' (no message)" }, "message": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Message", "description": "When mode is 'custom', the message the digital human says first" } }, "type": "object", "required": [ "speaks_first" ], "title": "SpeaksFirstConfig", "description": "Configuration for whether the digital human speaks first and how.\nStored as JSONB in Supabase (speaks_first_config)." }, "StartTrialRequest": { "properties": { "payment_method_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Payment Method Id", "description": "Optional Stripe payment method ID; trial can start without a card" } }, "type": "object", "title": "StartTrialRequest" }, "SyncSingleAgentFromVapiRequest": { "properties": { "agent_id": { "type": "integer", "title": "Agent Id" } }, "type": "object", "required": [ "agent_id" ], "title": "SyncSingleAgentFromVapiRequest" }, "SyncVapiAgentsRequest": { "properties": { "organization_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Organization Id" }, "dry_run": { "type": "boolean", "title": "Dry Run", "default": true } }, "type": "object", "title": "SyncVapiAgentsRequest" }, "TextProcessorRequest": { "properties": { "redis_key": { "type": "string", "title": "Redis Key", "description": "redis key for conversation history" }, "test_case_id": { "type": "string", "title": "Test Case Id", "description": "ID of the test case" }, "response_format": { "type": "string", "enum": [ "chirp", "text" ], "title": "Response Format", "description": "response format", "default": "chirp" } }, "type": "object", "required": [ "redis_key", "test_case_id" ], "title": "TextProcessorRequest", "description": "Pydantic model for text processor request body" }, "ToolCall": { "properties": { "name": { "type": "string", "title": "Name", "description": "Name of the tool called" }, "start_offset_ms": { "type": "integer", "minimum": 0.0, "title": "Start Offset Ms", "description": "Start offset of the tool call in milliseconds" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Description", "description": "Description of the tool call" }, "parameters": { "anyOf": [ { "additionalProperties": true, "type": "object" }, { "type": "null" } ], "title": "Parameters", "description": "Parameters passed to the tool call" }, "output": { "anyOf": [ {}, { "type": "null" } ], "title": "Output", "description": "Output returned by the tool call" } }, "type": "object", "required": [ "name", "start_offset_ms" ], "title": "ToolCall", "description": "Represents a tool call during a conversation." }, "ToolCallComparisonGroup": { "properties": { "name": { "type": "string", "title": "Name", "description": "Tool name" }, "expected": { "items": { "$ref": "#/components/schemas/ExpectedToolCallDetail" }, "type": "array", "title": "Expected", "description": "Expected invocations of this tool" }, "actual": { "items": { "$ref": "#/components/schemas/ActualToolCallDetail" }, "type": "array", "title": "Actual", "description": "Actual invocations of this tool during the simulation" } }, "type": "object", "required": [ "name" ], "title": "ToolCallComparisonGroup" }, "Trait": { "properties": { "trait_name": { "type": "string", "title": "Trait Name", "description": "Name of the trait" }, "trait_data_type": { "$ref": "#/components/schemas/TraitDataType", "description": "Data type of the trait" }, "value": { "title": "Value", "description": "Value of the trait (stored as JSONB)" }, "is_sip_header": { "type": "boolean", "title": "Is Sip Header", "description": "Whether this trait is a SIP header", "default": false } }, "type": "object", "required": [ "trait_name", "trait_data_type", "value" ], "title": "Trait", "description": "Model for a single trait." }, "TraitDataType": { "type": "string", "enum": [ "BOOLEAN", "STRING", "DATE", "NUMBER" ], "title": "TraitDataType", "description": "Enum for trait data types." }, "TraitInput": { "properties": { "name": { "type": "string", "title": "Name", "description": "Name of the trait" }, "data_type": { "$ref": "#/components/schemas/TraitDataType", "description": "Data type of the trait (BOOLEAN, STRING, NUMBER, DATE)" } }, "type": "object", "required": [ "name", "data_type" ], "title": "TraitInput", "description": "One trait to generate values for." }, "TranscriptEntryRequest": { "properties": { "start_offset_ms": { "type": "integer", "title": "Start Offset Ms", "description": "Start offset of the utterance in milliseconds" }, "end_offset_ms": { "type": "integer", "title": "End Offset Ms", "description": "End offset of the utterance in milliseconds" }, "speaker": { "$ref": "#/components/schemas/ParticipantRole", "description": "Identifier for the speaker (e.g., 'AGENT', 'USER')" }, "utterance": { "type": "string", "title": "Utterance", "description": "Transcribed text of the utterance" }, "filler_utterance": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Filler Utterance", "description": "Whether the utterance is a filler utterance" } }, "type": "object", "required": [ "start_offset_ms", "end_offset_ms", "speaker", "utterance" ], "title": "TranscriptEntryRequest" }, "TranslateObservabilityTranscriptRequest": { "properties": { "conversation_id": { "type": "string", "title": "Conversation Id", "description": "ID of the production conversation (call_id) to translate" }, "target_language": { "type": "string", "maxLength": 10, "minLength": 2, "title": "Target Language", "description": "Target language code (e.g., 'en', 'es', 'fr', 'de'). Defaults to 'en' (English).", "default": "en" } }, "type": "object", "required": [ "conversation_id" ], "title": "Translate Observability Transcript", "description": "Translate a production conversation transcript by providing the conversation ID" }, "TranslateSimulationTranscriptRequest": { "properties": { "simulation_result_id": { "type": "integer", "title": "Simulation Result Id", "description": "ID of the simulation result (test_result) to translate" }, "target_language": { "type": "string", "maxLength": 10, "minLength": 2, "title": "Target Language", "description": "Target language code (e.g., 'en', 'es', 'fr', 'de'). Defaults to 'en' (English).", "default": "en" } }, "type": "object", "required": [ "simulation_result_id" ], "title": "Translate Simulation Transcript", "description": "Translate a simulation transcript by providing the simulation result ID" }, "TranslateTranscriptResponse": { "properties": { "translated_transcript_url": { "type": "string", "title": "Translated Transcript Url", "description": "URL to the translated transcript file" }, "target_language": { "type": "string", "title": "Target Language", "description": "The target language used for translation" }, "success": { "type": "boolean", "title": "Success", "description": "Whether the translation was successful", "default": true } }, "type": "object", "required": [ "translated_transcript_url", "target_language" ], "title": "TranslateTranscriptResponse", "description": "Response model for translated transcript." }, "UpdateAlertRequest": { "properties": { "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Name", "description": "Name of the alert" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Description", "description": "Description of the alert" }, "is_enabled": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Is Enabled", "description": "Whether the alert is enabled" }, "entity_type": { "anyOf": [ { "$ref": "#/components/schemas/EntityType" }, { "type": "null" } ], "description": "Type of entity being monitored" }, "entity_field": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Entity Field", "description": "The specific field/metric being monitored" }, "operator": { "anyOf": [ { "$ref": "#/components/schemas/Operator" }, { "type": "null" } ], "description": "Comparison operator" }, "comparison_value": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Comparison Value", "description": "Value to compare against" }, "notification_channels": { "anyOf": [ { "items": { "$ref": "#/components/schemas/NotificationChannelRequest" }, "type": "array" }, { "type": "null" } ], "title": "Notification Channels", "description": "Notification channels configuration" }, "applies_to_all_agents": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Applies To All Agents", "description": "Whether the alert applies to all agents" }, "agent_ids": { "anyOf": [ { "items": { "type": "integer" }, "type": "array" }, { "type": "null" } ], "title": "Agent Ids", "description": "Agent IDs to associate with this alert" }, "threshold_time_interval": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Threshold Time Interval", "description": "Time window in seconds for the alert (e.g. 600 for 10 minutes)" }, "min_events": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Min Events", "description": "Minimum number of events to trigger the alert" }, "source_scope": { "anyOf": [ { "$ref": "#/components/schemas/SourceScope" }, { "type": "null" } ], "description": "Which data source fires this alert: 'all', 'observability', or 'simulation'" } }, "type": "object", "title": "UpdateAlertRequest", "description": "Request model for updating an alert" }, "UpdateCallLogRequest": { "properties": { "tool_calls": { "anyOf": [ { "items": { "$ref": "#/components/schemas/ToolCall" }, "type": "array" }, { "type": "null" } ], "title": "Tool Calls", "description": "List of tool calls to update" }, "events": { "anyOf": [ { "items": { "$ref": "#/components/schemas/Event" }, "type": "array" }, { "type": "null" } ], "title": "Events", "description": "List of events to update" }, "metadata": { "anyOf": [ { "additionalProperties": true, "type": "object" }, { "type": "null" } ], "title": "Metadata", "description": "Metadata to update" }, "reevaluate": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Reevaluate", "description": "Whether to reevaluate the log", "default": false } }, "type": "object", "title": "UpdateCallLogRequest" }, "UpdateCommunityRequest": { "properties": { "title": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Title", "description": "Title of the community" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Description", "description": "Description of the community" }, "digital_human_ids": { "anyOf": [ { "items": { "type": "integer" }, "type": "array" }, { "type": "null" } ], "title": "Digital Human Ids", "description": "List of digital human (test case) IDs to associate this community with (replaces existing associations)" } }, "type": "object", "title": "UpdateCommunityRequest" }, "UpdateCronJobRequest": { "properties": { "schedule": { "anyOf": [ { "$ref": "#/components/schemas/EveryNMinutesSchedule" }, { "$ref": "#/components/schemas/EveryNHoursSchedule" }, { "$ref": "#/components/schemas/DailySchedule" }, { "$ref": "#/components/schemas/WeeklySchedule" }, { "$ref": "#/components/schemas/MonthlySchedule" }, { "$ref": "#/components/schemas/CronSchedule" }, { "type": "null" } ], "title": "Schedule", "description": "The new schedule for the cron job." }, "enabled": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Enabled", "description": "Whether to enable or disable the cron job." } }, "type": "object", "title": "UpdateCronJobRequest" }, "UpdateCronJobResponse": { "properties": { "id": { "type": "string", "title": "Id", "description": "The unique identifier for the updated cron job." }, "simulation_id": { "type": "string", "title": "Simulation Id", "description": "The unique identifier for the associated simulation." }, "cron_expression": { "type": "string", "title": "Cron Expression", "description": "The cron expression defining the job schedule." }, "enabled": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Enabled", "description": "Whether the cron job is enabled." }, "created_at": { "type": "string", "title": "Created At", "description": "The timestamp when the cron job was created." } }, "type": "object", "required": [ "id", "simulation_id", "cron_expression", "created_at" ], "title": "UpdateCronJobResponse" }, "UpdateCustomMetricRequest": { "properties": { "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Name", "description": "Name of the custom metric" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Description", "description": "Description of what this metric measures" }, "response_type": { "anyOf": [ { "$ref": "#/components/schemas/src__models__custom_metric__ResponseType" }, { "type": "null" } ], "description": "Type of response expected" }, "agent_ids": { "anyOf": [ { "items": { "type": "integer" }, "type": "array" }, { "type": "null" } ], "title": "Agent Ids", "description": "List of agent IDs to associate this metric with (replaces existing associations)" }, "min_value": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "title": "Min Value", "description": "Minimum value for quantitative metrics" }, "max_value": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "title": "Max Value", "description": "Maximum value for quantitative metrics" }, "category": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Category", "description": "Category for organizing metrics" }, "tags": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Tags", "description": "Tags for categorizing the metric" }, "scoring_guidance": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Scoring Guidance", "description": "Guidance on how to score this metric" }, "eval_route": { "anyOf": [ { "$ref": "#/components/schemas/EvalRoute" }, { "type": "null" } ], "description": "Route for evaluating the metric", "default": "AUTO" }, "model": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Model", "description": "Model to use for text evaluation of the metric" }, "audio_model": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Audio Model", "description": "Model to use for audio evaluation of the metric" }, "temperature": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "title": "Temperature", "description": "Temperature for evaluating the metric" }, "enum_options": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Enum Options", "description": "Options for enum metrics" }, "allow_not_applicable": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Allow Not Applicable", "description": "Whether this metric allows 'not applicable' responses." } }, "type": "object", "title": "UpdateCustomMetricRequest", "description": "Request model for updating a custom metric" }, "UpdateCustomerPersonaRequest": { "properties": { "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Name", "description": "Name of the customer persona" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Description", "description": "Description of the customer persona" }, "goal": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Goal", "description": "Goal of the customer persona" } }, "type": "object", "title": "UpdateCustomerPersonaRequest" }, "UpdateCustomerTraitRequest": { "properties": { "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Name", "description": "Name of the trait" }, "data_type": { "anyOf": [ { "$ref": "#/components/schemas/TraitDataType" }, { "type": "null" } ], "description": "Data type of the trait" }, "default_value": { "anyOf": [ {}, { "type": "null" } ], "title": "Default Value", "description": "Default value for this trait (will be converted based on data_type)" } }, "type": "object", "title": "UpdateCustomerTraitRequest", "description": "Request model for updating a customer trait definition." }, "UpdateDigitalHumanRequest": { "properties": { "intent": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Intent", "description": "Description of the digital human" }, "success_criteria": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Success Criteria", "description": "Success criteria for the digital human" }, "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Name", "description": "Name of the digital human" }, "tag": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Tag", "description": "Tag for categorizing the digital human" }, "language": { "anyOf": [ { "$ref": "#/components/schemas/LanguageType" }, { "type": "null" } ], "description": "Language the digital human speaks", "default": "en" }, "accent": { "anyOf": [ { "$ref": "#/components/schemas/AccentType" }, { "type": "null" } ], "description": "Accent of the digital human" }, "gender": { "anyOf": [ { "$ref": "#/components/schemas/GenderType" }, { "type": "null" } ], "description": "Gender of the digital human" }, "background_noise": { "anyOf": [ { "$ref": "#/components/schemas/BackgroundNoiseType" }, { "type": "null" } ], "description": "Type of background noise", "default": "none" }, "voice_speed": { "anyOf": [ { "$ref": "#/components/schemas/VoiceSpeedType" }, { "type": "null" } ], "description": "Speed of the digital human's voice", "default": "normal" }, "audio_quality": { "anyOf": [ { "$ref": "#/components/schemas/AudioQualityType" }, { "type": "null" } ], "description": "Audio quality of the digital human's voice" }, "fluency": { "anyOf": [ { "$ref": "#/components/schemas/FluencyType" }, { "type": "null" } ], "description": "Fluency level of the digital human's speech" }, "verbosity": { "anyOf": [ { "$ref": "#/components/schemas/VerbosityType" }, { "type": "null" } ], "description": "Verbosity level of the digital human's responses" }, "phone_number": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Phone Number", "description": "Phone number for the digital human" }, "outbound_text_number": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Outbound Text Number", "description": "Outbound text number" }, "background_noise_volume": { "anyOf": [ { "type": "number", "maximum": 1.0, "minimum": 0.0 }, { "type": "null" } ], "title": "Background Noise Volume", "description": "Volume of background noise", "default": 0.8 }, "expected_tool_calls": { "anyOf": [ { "items": { "$ref": "#/components/schemas/ExpectedToolCall" }, "type": "array" }, { "type": "null" } ], "title": "Expected Tool Calls", "description": "Expected tool call outputs" }, "allow_end_call_tool": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Allow End Call Tool", "description": "Allow the digital human to end the tool call" }, "endpointing_delay": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "title": "Endpointing Delay", "description": "Delay for endpointing", "default": 1.5 }, "creativity": { "anyOf": [ { "type": "number", "maximum": 2.0, "minimum": 0.0 }, { "type": "null" } ], "title": "Creativity", "description": "How creative the digital human is (Model temperature)", "default": 0.7 }, "hangup_phrases": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Hangup Phrases", "description": "Phrases that trigger hangup" }, "hangup_instructions": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Hangup Instructions", "description": "Freeform instructions for how/when to hang up" }, "allow_silence_tool": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Allow Silence Tool", "description": "Allow the digital human to use the silence tool", "default": null }, "silence_tool_instructions": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Silence Tool Instructions", "description": "Tool instructions; set to \"default\" for built-in behavior or custom text", "default": null }, "silence_timeout": { "anyOf": [ { "type": "integer", "minimum": 15.0 }, { "type": "null" } ], "title": "Silence Timeout", "description": "Silence timeout in seconds" }, "simulation_ids": { "anyOf": [ { "items": { "type": "integer" }, "type": "array" }, { "type": "null" } ], "title": "Simulation Ids", "description": "Array of simulation IDs to associate with this digital human. If provided, completely replaces existing associations." }, "traits": { "anyOf": [ { "items": { "$ref": "#/components/schemas/Trait" }, "type": "array" }, { "type": "null" } ], "title": "Traits", "description": "List of traits associated with this digital human. If provided, completely replaces existing traits." }, "interruptions": { "anyOf": [ { "$ref": "#/components/schemas/SimpleInterruptionConfig" }, { "$ref": "#/components/schemas/KeywordsInterruptionConfig" }, { "$ref": "#/components/schemas/ContextualInterruptionConfig" }, { "type": "null" } ], "title": "Interruptions", "description": "Interruption configuration for the digital human. If provided, completely replaces existing interruption config." }, "scripted_responses": { "anyOf": [ { "items": { "$ref": "#/components/schemas/ScriptedResponse" }, "type": "array" }, { "type": "null" } ], "title": "Scripted Responses", "description": "List of scripted responses for the digital human. If provided, completely replaces existing scripted responses." }, "role_description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Role Description", "description": "Description of the role for the digital human" }, "speaks_first_config": { "anyOf": [ { "$ref": "#/components/schemas/SpeaksFirstConfig" }, { "type": "null" } ], "description": "Speaks first configuration for the digital human. If provided, completely replaces existing speaks first config." }, "original_transcript": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Original Transcript", "description": "Original transcript text. If changed from the current value, utterances are re-extracted and the intent is regenerated." }, "formatted_transcript": { "anyOf": [ { "items": { "additionalProperties": { "type": "string" }, "type": "object" }, "type": "array" }, { "type": "null" } ], "title": "Formatted Transcript", "description": "Pre-computed structured transcript as [{role, utterance}]. When provided alongside original_transcript, skips the LLM formatting call." }, "enriched_playback": { "anyOf": [ { "items": { "additionalProperties": true, "type": "object" }, "type": "array" }, { "type": "null" } ], "title": "Enriched Playback", "description": "Optional enriched playback stored as JSONB: a list of turn objects" }, "num_runs": { "anyOf": [ { "type": "integer", "minimum": 1.0 }, { "type": "null" } ], "title": "Num Runs", "description": "Number of times this digital human is run per simulation run (run count)." }, "livekit_metadata": { "anyOf": [ { "additionalProperties": true, "type": "object" }, { "type": "null" } ], "title": "Livekit Metadata", "description": "LiveKit-specific configuration and metadata for this digital human. If provided, completely replaces existing metadata." }, "always_on_mode": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Always On Mode", "description": "Whether always-on mode is enabled for this digital human" }, "always_on_active": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Always On Active", "description": "When true, this DH actively receives calls on phone_number; when false, number is assigned but inactive" }, "override_conflict": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Override Conflict", "description": "When true, allows activation to replace an existing always-on active DH using the same phone number.", "default": false } }, "type": "object", "title": "UpdateDigitalHumanRequest", "description": "Request model for updating a digital human - contains only the digital human data." }, "UpdateLabRequest": { "properties": { "name": { "anyOf": [ { "type": "string", "maxLength": 255, "minLength": 1 }, { "type": "null" } ], "title": "Name", "description": "New name for the lab" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Description", "description": "New description for the lab" } }, "type": "object", "title": "UpdateLabRequest", "description": "Request model for updating a lab" }, "UpdateLabSettingsRequest": { "properties": { "fuzzy_alignment": { "anyOf": [ { "additionalProperties": true, "type": "object" }, { "type": "null" } ], "title": "Fuzzy Alignment", "description": "Fuzzy alignment settings (nested object)" } }, "additionalProperties": true, "type": "object", "title": "UpdateLabSettingsRequest", "description": "Request model for updating lab settings" }, "UpdateLabSettingsResponse": { "properties": { "success": { "type": "boolean", "title": "Success", "description": "Indicates if the operation was successful" }, "message": { "type": "string", "title": "Message", "description": "A descriptive message about the operation" } }, "type": "object", "required": [ "success", "message" ], "title": "UpdateLabSettingsResponse", "description": "Response model for updating lab settings" }, "UpdateLabelBody": { "properties": { "label_text": { "type": "string", "title": "Label Text", "description": "new text for the label" } }, "type": "object", "required": [ "label_text" ], "title": "UpdateLabelBody" }, "UpdateLogResponse": { "properties": { "message": { "type": "string", "title": "Message", "description": "Success message" }, "status": { "type": "string", "title": "Status", "description": "Status of the response", "default": "200" } }, "type": "object", "required": [ "message" ], "title": "UpdateLogResponse" }, "UpdateSimulationResponse": { "properties": { "status": { "type": "string", "title": "Status", "description": "Status of the response", "default": "success" }, "message": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Message", "description": "Optional message providing additional information about the response" } }, "type": "object", "title": "UpdateSimulationResponse" }, "UpdateWorkflowV2Request": { "properties": { "name": { "anyOf": [ { "type": "string", "maxLength": 255, "minLength": 1 }, { "type": "null" } ], "title": "Name", "description": "New name for the workflow" }, "agent_ids": { "anyOf": [ { "items": { "type": "integer" }, "type": "array" }, { "type": "null" } ], "title": "Agent Ids", "description": "Set owning agents, or null to clear agent links (must belong to your organization when set)." }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Description", "description": "New description (set empty string to clear if your client sends it)" }, "definition": { "anyOf": [ { "additionalProperties": true, "type": "object" }, { "type": "null" } ], "title": "Definition", "description": "Full React Flow definition to persist when provided." } }, "type": "object", "title": "UpdateWorkflowV2Request", "description": "Partial update for workflows_v2." }, "ValidationError": { "properties": { "loc": { "items": { "anyOf": [ { "type": "string" }, { "type": "integer" } ] }, "type": "array", "title": "Location" }, "msg": { "type": "string", "title": "Message" }, "type": { "type": "string", "title": "Error Type" } }, "type": "object", "required": [ "loc", "msg", "type" ], "title": "ValidationError" }, "VerbosityType": { "type": "string", "enum": [ "low", "medium", "high" ], "title": "VerbosityType", "description": "Enum for verbosity level options." }, "VoiceSpeedType": { "type": "string", "enum": [ "slowest", "slow", "normal", "fast", "fastest" ], "title": "VoiceSpeedType", "description": "Enum for voice speed options." }, "WebhookKeyRequest": { "properties": { "webhook_id": { "type": "string", "format": "uuid", "title": "Webhook Id", "description": "ID of the webhook" } }, "type": "object", "required": [ "webhook_id" ], "title": "WebhookKeyRequest", "description": "Request model for creating a webhook" }, "WebhookKeyResponse": { "properties": { "signing_key": { "type": "string", "title": "Signing Key", "description": "Signing key" }, "message": { "type": "string", "title": "Message", "description": "Message" } }, "type": "object", "required": [ "signing_key", "message" ], "title": "WebhookKeyResponse", "description": "Response model for creating a webhook" }, "WeeklyNotificationTarget": { "properties": { "type": { "type": "string", "enum": [ "email", "slack" ], "title": "Type", "description": "Channel type" }, "target": { "type": "string", "minLength": 1, "title": "Target", "description": "Email address or Slack channel ID" } }, "type": "object", "required": [ "type", "target" ], "title": "WeeklyNotificationTarget" }, "WeeklyNotificationsBody": { "properties": { "targets": { "items": { "$ref": "#/components/schemas/WeeklyNotificationTarget" }, "type": "array", "title": "Targets", "description": "List of notification targets (alarm-style). Required to avoid accidentally overwriting with an empty list." }, "preferred_send_time_utc": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Preferred Send Time Utc", "description": "UTC clock time when the weekly job runs, HH:MM:SS (e.g. 17:00:00). Must be sent together with day_of_week unless using clear_schedule." }, "day_of_week": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Day Of Week", "description": "UTC weekday for the weekly instant: 0=Monday .. 6=Sunday (cron-style in UTC)." }, "clear_schedule": { "type": "boolean", "title": "Clear Schedule", "description": "If true, reset weekly send to the default (Monday 9:00 AM PST → UTC); still updates targets. Do not send with preferred_send_time_utc or day_of_week.", "default": false } }, "additionalProperties": false, "type": "object", "required": [ "targets" ], "title": "WeeklyNotificationsBody" }, "WeeklyNotificationsPostResponse": { "properties": { "success": { "type": "boolean", "title": "Success", "default": true }, "first_generate_at_utc": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "First Generate At Utc", "description": "From summaries-cron: first generate job fire (ISO UTC), if registered." }, "first_notify_at_utc": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "First Notify At Utc", "description": "From summaries-cron: first notify job fire (ISO UTC), if registered." }, "deferred": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Deferred", "description": "True if first fire was deferred by at least one week for lead-time safety." } }, "type": "object", "title": "WeeklyNotificationsPostResponse" }, "WeeklySchedule": { "properties": { "frequency": { "type": "string", "const": "weekly", "title": "Frequency" }, "day_of_week": { "type": "string", "enum": [ "monday", "tuesday", "wednesday", "thursday", "friday", "saturday", "sunday" ], "title": "Day Of Week" }, "time": { "type": "string", "pattern": "^\\d{2}:\\d{2}$", "title": "Time" } }, "type": "object", "required": [ "frequency", "day_of_week", "time" ], "title": "WeeklySchedule" }, "WorkflowV2Response": { "properties": { "id": { "type": "string", "title": "Id", "description": "Workflow ID" }, "organization_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Organization Id", "description": "Owning organization ID (set by middleware on create)" }, "agent_ids": { "items": { "type": "integer" }, "type": "array", "title": "Agent Ids", "description": "Linked agent ids when the workflow is agent-scoped", "default": [] }, "name": { "type": "string", "title": "Name", "description": "Name of the workflow" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Description", "description": "Description" }, "definition": { "additionalProperties": true, "type": "object", "title": "Definition", "description": "Stored React Flow graph (`start` / `single` / `options` nodes)." }, "created_at": { "type": "string", "format": "date-time", "title": "Created At", "description": "Creation timestamp" } }, "type": "object", "required": [ "id", "name", "definition", "created_at" ], "title": "WorkflowV2Response", "description": "Single workflows_v2 row." }, "WorkflowsV2ListResponse": { "properties": { "workflows": { "items": { "$ref": "#/components/schemas/WorkflowV2Response" }, "type": "array", "title": "Workflows", "description": "Workflows" }, "total_count": { "type": "integer", "title": "Total Count", "description": "Number of workflows returned" } }, "type": "object", "required": [ "workflows", "total_count" ], "title": "WorkflowsV2ListResponse", "description": "List workflows_v2 for the organization." }, "src__api__simulations__UpdateSimulationRequest": { "properties": { "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Name", "description": "updated simulation name" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Description", "description": "human‑readable description of the simulation" }, "prompt_id": { "anyOf": [ { "type": "string", "format": "uuid" }, { "type": "null" } ], "title": "Prompt Id", "description": "optional default prompt UUID for this simulation" }, "knowledge_base_id": { "anyOf": [ { "type": "string", "format": "uuid" }, { "type": "null" } ], "title": "Knowledge Base Id", "description": "optional default knowledge base UUID for this simulation" }, "max_concurrent": { "anyOf": [ { "type": "integer", "maximum": 500.0, "exclusiveMinimum": 0.0 }, { "type": "null" } ], "title": "Max Concurrent", "description": "maximum number of concurrent runs (max 500)" }, "hangup_on_transfer": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Hangup On Transfer", "description": "whether to hang up the call on transfer" }, "max_call_duration": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Max Call Duration", "description": "maximum duration of each call. units specified by max_call_duration_units" }, "max_call_duration_units": { "anyOf": [ { "type": "string", "enum": [ "minutes", "seconds" ] }, { "type": "null" } ], "title": "Max Call Duration Units", "description": "units for max_call_duration: 'minutes' or 'seconds'" }, "max_turns": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Max Turns", "description": "maximum number of turns per simulation run" }, "ringing_timeout": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Ringing Timeout", "description": "ringing timeout in seconds before abandoning" }, "digital_humans_settings": { "anyOf": [ { "additionalProperties": true, "type": "object" }, { "type": "null" } ], "title": "Digital Humans Settings", "description": "settings for digital humans in the simulation" }, "selected_custom_metrics": { "anyOf": [ { "items": { "type": "string", "format": "uuid" }, "type": "array" }, { "type": "null" } ], "title": "Selected Custom Metrics", "description": "array of custom metric IDs to be saved in settings" }, "custom_metrics_failing_threshold": { "anyOf": [ { "type": "integer", "maximum": 100.0, "minimum": 0.0 }, { "type": "null" } ], "title": "Custom Metrics Failing Threshold", "description": "score threshold below which a custom metric is considered failing (0-100)" }, "custom_metrics_passing_threshold": { "anyOf": [ { "type": "integer", "maximum": 100.0, "minimum": 0.0 }, { "type": "null" } ], "title": "Custom Metrics Passing Threshold", "description": "score threshold at or above which a custom metric is considered passing (0-100)" }, "tags": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Tags", "description": "array of tags for the simulation" }, "pinned": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Pinned", "description": "whether the simulation is pinned" } }, "type": "object", "title": "UpdateSimulationRequest", "description": "request body for updating a simulation.\n\nall fields are optional; only provided fields will be updated." }, "src__api__update_simulation_result__UpdateSimulationRequest": { "properties": { "simulation_result_id": { "type": "string", "title": "Simulation Result Id", "description": "Simulation result ID provided via SIP for the specific call" }, "events": { "anyOf": [ { "items": { "$ref": "#/components/schemas/Event" }, "type": "array" }, { "type": "null" } ], "title": "Events", "description": "List of events that occurred during the call" }, "tool_calls": { "anyOf": [ { "items": { "$ref": "#/components/schemas/ToolCall" }, "type": "array" }, { "type": "null" } ], "title": "Tool Calls", "description": "List of tool calls made during the call" }, "recorded_transcript": { "anyOf": [ { "items": { "$ref": "#/components/schemas/TranscriptEntryRequest" }, "type": "array" }, { "type": "null" } ], "title": "Recorded Transcript", "description": "Recorded transcript of the call (utilized to analyze STT accuracy)" }, "tags": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Tags", "description": "List of tags associated with the call" }, "metadata": { "anyOf": [ { "additionalProperties": true, "type": "object" }, { "type": "null" } ], "title": "Metadata", "description": "Additional metadata associated with the call" } }, "type": "object", "required": [ "simulation_result_id" ], "title": "UpdateSimulationRequest" }, "src__main__DigitalHumanResponse": { "properties": { "digital_humans": { "items": {}, "type": "array", "title": "Digital Humans", "description": "List of digital humans created for the simulation" }, "status": { "type": "string", "title": "Status", "description": "Status of the response", "default": "200" }, "success": { "type": "boolean", "title": "Success", "description": "Whether the generation succeeded", "default": true }, "test_scenarios": { "anyOf": [ { "items": {}, "type": "array" }, { "type": "null" } ], "title": "Test Scenarios", "description": "Scenario view of created digital humans (includes original_transcript and formatted_transcript for transcript replays)" }, "warning": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Warning", "description": "Warning message if the request was modified (e.g. truncated due to exceeding the max limit)" } }, "type": "object", "title": "DigitalHumanResponse" }, "src__main__SimulationRunRequest": { "properties": { "simulation_id": { "type": "string", "title": "Simulation Id", "description": "ID of the simulation to be run" }, "prompt_id": { "anyOf": [ { "type": "string", "format": "uuid" }, { "type": "null" } ], "title": "Prompt Id", "description": "Prompt UUID associated with this run" }, "knowledge_base_id": { "anyOf": [ { "type": "string", "format": "uuid" }, { "type": "null" } ], "title": "Knowledge Base Id", "description": "Knowledge base UUID associated with this run" }, "digital_human_ids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Digital Human Ids", "description": "Digital human IDs to be used in the simulation" }, "phone_number": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Phone Number", "description": "Optional phone number to be used in this simulation run (overrides the agent phone number)" }, "sip_uri": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Sip Uri", "description": "Optional SIP URI to be used in this simulation run (overrides the agent SIP URI)" }, "livekit_agent_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Livekit Agent Name", "description": "Optional agent name to be used by user's livekit, an empty string will use the default agent" }, "livekit_metadata": { "anyOf": [ { "additionalProperties": true, "type": "object" }, { "type": "null" } ], "title": "Livekit Metadata", "description": "metadata to be passed to the livekit room" }, "pipecat_agent_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Pipecat Agent Name", "description": "Pipecat agent name" }, "pipecat_agent_configuration": { "anyOf": [ { "additionalProperties": true, "type": "object" }, { "type": "null" } ], "title": "Pipecat Agent Configuration", "description": "Pipecat agent configuration" }, "pipecat_room_properties": { "anyOf": [ { "additionalProperties": true, "type": "object" }, { "type": "null" } ], "title": "Pipecat Room Properties", "description": "Pipecat room properties" } }, "type": "object", "required": [ "simulation_id" ], "title": "SimulationRunRequest", "description": "Pydantic model for simulation run request" }, "src__main__SimulationRunResponse": { "properties": { "simulation_run_id": { "type": "string", "title": "Simulation Run Id", "description": "ID of the created simulation run" }, "simulation_result_ids": { "items": { "type": "string" }, "type": "array", "title": "Simulation Result Ids", "description": "IDs of the created simulation results (test results)" }, "agent_id": { "type": "string", "title": "Agent Id", "description": "ID of the agent associated with the simulation run" }, "status": { "type": "string", "title": "Status", "description": "Status of the response", "default": "success" } }, "type": "object", "required": [ "simulation_run_id", "simulation_result_ids", "agent_id" ], "title": "SimulationRunResponse" }, "src__models__api_custom_metric__CustomMetric": { "properties": { "name": { "type": "string", "title": "Name", "description": "The name of the custom metric" }, "description": { "type": "string", "title": "Description", "description": "The description of the custom metric" }, "response_type": { "type": "string", "title": "Response Type", "description": "The response type of the custom metric" }, "response_value": { "type": "string", "title": "Response Value", "description": "The response value of the custom metric" }, "reasoning": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Reasoning", "description": "The reasoning of the custom metric" }, "min_value": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "title": "Min Value", "description": "The minimum value of the custom metric" }, "max_value": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "title": "Max Value", "description": "The maximum value of the custom metric" }, "category": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Category", "description": "The category of the custom metric" }, "tags": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Tags", "description": "The tags of the custom metric" }, "scoring_guidance": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Scoring Guidance", "description": "The scoring guidance of the custom metric" }, "enum_options": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Enum Options", "description": "The enum options of the custom metric" } }, "type": "object", "required": [ "name", "description", "response_type", "response_value" ], "title": "Custom Metric" }, "src__models__custom_metric__CustomMetric": { "properties": { "agent_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Agent Id" }, "name": { "type": "string", "title": "Name" }, "description": { "type": "string", "title": "Description" }, "response_type": { "$ref": "#/components/schemas/src__models__custom_metric__ResponseType" }, "min_value": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "title": "Min Value" }, "max_value": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "title": "Max Value" }, "created_at": { "anyOf": [ { "type": "string", "format": "date-time" }, { "type": "null" } ], "title": "Created At" }, "id": { "anyOf": [ { "type": "string", "format": "uuid" }, { "type": "null" } ], "title": "Id", "description": "Unique identifier for the custom metric" }, "category": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Category" }, "tags": { "items": { "type": "string" }, "type": "array", "title": "Tags" }, "scoring_guidance": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Scoring Guidance" }, "eval_route": { "anyOf": [ { "$ref": "#/components/schemas/EvalRoute" }, { "type": "null" } ], "default": "AUTO" }, "model": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Model" }, "audio_model": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Audio Model" }, "temperature": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "title": "Temperature" }, "enum_options": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Enum Options" }, "organization_id": { "anyOf": [ { "type": "string", "format": "uuid" }, { "type": "null" } ], "title": "Organization Id" }, "allow_not_applicable": { "type": "boolean", "title": "Allow Not Applicable", "default": false } }, "type": "object", "required": [ "name", "description", "response_type" ], "title": "CustomMetric", "description": "Represents a custom metric entry in the database." }, "src__models__custom_metric__ResponseType": { "type": "string", "enum": [ "pass_fail", "yes_no", "qualitative", "quantitative", "json", "enum" ], "title": "ResponseType", "description": "Enum representing the possible response types for custom metrics." }, "src__models__digital_humans__digital_human_response__DigitalHumanResponse": { "properties": { "digital_human": { "$ref": "#/components/schemas/DigitalHumanResponseData", "description": "The digital human data" }, "simulation_ids": { "anyOf": [ { "items": { "type": "integer" }, "type": "array" }, { "type": "null" } ], "title": "Simulation Ids", "description": "List of simulation IDs associated with this digital human" }, "simulation_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Simulation Id", "description": "ID of the associated simulation. Use simulation_ids instead.", "deprecated": true } }, "type": "object", "required": [ "digital_human" ], "title": "DigitalHumanResponse", "description": "Response model for digital human operations with clear separation of digital human data and simulation context." }, "src__models__digital_humans__enums__ResponseType": { "type": "string", "enum": [ "phrase", "silence", "dtmf" ], "title": "ResponseType", "description": "Enum for scripted response types." }, "src__text_agents__sms_text_agent_api__SimulationRunRequest": { "properties": { "simulation_id": { "type": "string", "title": "Simulation Id", "description": "ID of the simulation to be run" }, "prompt_id": { "anyOf": [ { "type": "string", "format": "uuid" }, { "type": "null" } ], "title": "Prompt Id", "description": "Prompt UUID associated with this run" }, "knowledge_base_id": { "anyOf": [ { "type": "string", "format": "uuid" }, { "type": "null" } ], "title": "Knowledge Base Id", "description": "Knowledge base UUID associated with this run" }, "digital_human_ids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Digital Human Ids", "description": "Digital human IDs to be used in the simulation" }, "terminate_overlapping_simulations": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Terminate Overlapping Simulations", "description": "If true, all overlapping conversations with same pair of phone numbers will be ended", "default": false } }, "type": "object", "required": [ "simulation_id" ], "title": "SimulationRunRequest", "description": "Pydantic model for simulation run request" }, "src__text_agents__sms_text_agent_api__SimulationRunResponse": { "properties": { "simulation_run_id": { "type": "string", "title": "Simulation Run Id", "description": "ID of the created simulation run" }, "simulation_result_ids": { "items": { "type": "string" }, "type": "array", "title": "Simulation Result Ids", "description": "IDs of the created simulation results (test results)" }, "agent_id": { "type": "string", "title": "Agent Id", "description": "ID of the agent associated with the simulation run" }, "status": { "type": "string", "title": "Status", "description": "Status of the response", "default": "success" }, "terminated_conversations": { "anyOf": [ { "items": { "additionalProperties": true, "type": "object" }, "type": "array" }, { "type": "null" } ], "title": "Terminated Conversations", "description": "List of conversations that were terminated due to overlapping phone numbers" } }, "type": "object", "required": [ "simulation_run_id", "simulation_result_ids", "agent_id" ], "title": "SimulationRunResponse" }, "WebhookSimulationResultEvaluated": { "$defs": { "CustomMetric": { "properties": { "name": { "description": "The name of the custom metric", "title": "Name", "type": "string" }, "description": { "description": "The description of the custom metric", "title": "Description", "type": "string" }, "response_type": { "description": "The response type of the custom metric", "title": "Response Type", "type": "string" }, "response_value": { "description": "The response value of the custom metric", "title": "Response Value", "type": "string" }, "reasoning": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "The reasoning of the custom metric", "title": "Reasoning" }, "min_value": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "The minimum value of the custom metric", "title": "Min Value" }, "max_value": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "The maximum value of the custom metric", "title": "Max Value" }, "category": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "The category of the custom metric", "title": "Category" }, "tags": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "The tags of the custom metric", "title": "Tags" }, "scoring_guidance": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "The scoring guidance of the custom metric", "title": "Scoring Guidance" }, "enum_options": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "The enum options of the custom metric", "title": "Enum Options" } }, "required": [ "name", "description", "response_type", "response_value" ], "title": "Custom Metric", "type": "object" }, "Evaluation": { "description": "Pydantic model for evaluation result", "properties": { "id": { "description": "Unique identifier for the evaluation result", "title": "Id", "type": "string" }, "created_at": { "description": "When this evaluation result was created (defaults to now in UTC)", "format": "date-time", "title": "Created At", "type": "string" }, "hallucination": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "Whether the agent exhibited hallucination during the call", "title": "Hallucination" }, "hallucination_reasoning": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Reasoning behind the hallucination, if applicable", "title": "Hallucination Reasoning" }, "redundancy": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "Whether the agent exhibited redundancy during the call", "title": "Redundancy" }, "redundancy_reasoning": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Reasoning behind the redundancy, if applicable", "title": "Redundancy Reasoning" }, "agent_speak_percentage": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "description": "Percentage of the call where the agent was speaking", "title": "Agent Speak Percentage" }, "avg_agent_latency": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "description": "Average latency of the agent's responses during the call", "title": "Avg Agent Latency" }, "latency": { "anyOf": [ { "$ref": "#/components/schemas/Latency" }, { "type": "null" } ], "description": "Latency metrics for the agent's responses" }, "filler_ignored_latency": { "anyOf": [ { "$ref": "#/components/schemas/FillerIgnoredLatency" }, { "type": "null" } ], "description": "Filler ignored latency metrics" }, "num_turns": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "description": "Total number of turns taken by the agent during the call", "title": "Num Turns" }, "call_summary": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Summary of the call, if applicable", "title": "Call Summary" }, "custom_evals": { "anyOf": [ { "items": {}, "type": "array" }, { "additionalProperties": true, "type": "object" }, { "type": "null" } ], "description": "List of custom evaluations performed during the call", "title": "Custom Evals" }, "custom_evals_success_rate": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Success rate of the custom evaluations performed during the call", "title": "Custom Evals Success Rate" }, "goal_success": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "Whether the goal was successfully achieved during the call", "title": "Goal Success" }, "goal_reasoning": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Reasoning behind the goal success, if applicable", "title": "Goal Reasoning" }, "pronunciation_score": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Pronunciation score of the agent during the call", "title": "Pronunciation Score" }, "pronunciation_reasoning": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Reasoning behind the pronunciation score, if applicable", "title": "Pronunciation Reasoning" }, "custom_metrics": { "anyOf": [ { "items": { "$ref": "#/components/schemas/CustomMetric" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "Custom metrics associated with the evaluation", "title": "Custom Metrics" } }, "required": [ "agent_speak_percentage", "avg_agent_latency" ], "title": "Evaluation", "type": "object" }, "Event": { "description": "Pydantic model for event data", "properties": { "title": { "description": "Title of the event", "title": "Title", "type": "string" }, "start_offset_ms": { "description": "Start offset of the event in milliseconds", "title": "Start Offset Ms", "type": "integer" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Description of the event", "title": "Description" }, "end_offset_ms": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "description": "End offset of the event in milliseconds", "title": "End Offset Ms" }, "tags": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "description": "List of tags associated with the event", "title": "Tags" }, "metadata": { "anyOf": [ { "additionalProperties": true, "type": "object" }, { "type": "null" } ], "default": null, "description": "Additional metadata associated with the event", "title": "Metadata" } }, "required": [ "title", "start_offset_ms" ], "title": "Event", "type": "object" }, "FillerIgnoredLatency": { "properties": { "avg_filler_ignored_latency": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": 0, "description": "Average filler ignored latency", "title": "Avg Filler Ignored Latency" }, "p50_filler_ignored_latency": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": 0, "description": "50th percentile filler ignored latency", "title": "P50 Filler Ignored Latency" }, "p90_filler_ignored_latency": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": 0, "description": "90th percentile filler ignored latency", "title": "P90 Filler Ignored Latency" }, "p95_filler_ignored_latency": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": 0, "description": "95th percentile filler ignored latency", "title": "P95 Filler Ignored Latency" }, "p99_filler_ignored_latency": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": 0, "description": "99th percentile filler ignored latency", "title": "P99 Filler Ignored Latency" } }, "title": "FillerIgnoredLatency", "type": "object" }, "Latency": { "properties": { "avg_agent_latency": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": 0, "description": "Average latency", "title": "Avg Agent Latency" }, "max_agent_latency": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": 0, "description": "Maximum latency", "title": "Max Agent Latency" }, "p50_agent_latency": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": 0, "description": "50th percentile latency", "title": "P50 Agent Latency" }, "p90_agent_latency": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": 0, "description": "90th percentile latency", "title": "P90 Agent Latency" }, "p95_agent_latency": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": 0, "description": "95th percentile latency", "title": "P95 Agent Latency" }, "p99_agent_latency": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": 0, "description": "99th percentile latency", "title": "P99 Agent Latency" } }, "title": "Latency", "type": "object" }, "TestResultStatus": { "description": "Enum representing the possible states of a test result.", "enum": [ "INITIALIZING", "QUEUED", "READY", "DISPATCHED", "RUNNING", "CONVERSATION_ENDED", "EVALUATING", "COMPLETED", "INCOMPLETED", "REJECTED", "INSUFFICIENT_FUNDS" ], "title": "TestResultStatus", "type": "string" }, "ToolCall": { "description": "Represents a tool call during a conversation.", "properties": { "name": { "description": "Name of the tool called", "title": "Name", "type": "string" }, "start_offset_ms": { "description": "Start offset of the tool call in milliseconds", "minimum": 0, "title": "Start Offset Ms", "type": "integer" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Description of the tool call", "title": "Description" }, "parameters": { "anyOf": [ { "additionalProperties": true, "type": "object" }, { "type": "null" } ], "default": null, "description": "Parameters passed to the tool call", "title": "Parameters" }, "output": { "anyOf": [ {}, { "type": "null" } ], "default": null, "description": "Output returned by the tool call", "title": "Output" } }, "required": [ "name", "start_offset_ms" ], "title": "ToolCall", "type": "object" } }, "description": "Represents a simulation result evaluated event.", "properties": { "type": { "default": "simulation_result_evaluated", "description": "Type of webhook payload", "title": "Type", "type": "string" }, "id": { "description": "The ID of the simulation result", "title": "Id", "type": "integer" }, "digital_human_id": { "description": "The ID of the digital human", "title": "Digital Human Id", "type": "integer" }, "status": { "$ref": "#/components/schemas/TestResultStatus", "default": "COMPLETED", "description": "The status of the simulation result" }, "simulation_run_id": { "description": "The ID of the simulation run that this simulation result belongs to", "title": "Simulation Run Id", "type": "integer" }, "simulation_id": { "description": "The ID of the simulation that this simulation result belongs to", "title": "Simulation Id", "type": "integer" }, "agent_id": { "description": "The ID of the agent that this simulation result belongs to", "title": "Agent Id", "type": "integer" }, "folder_id": { "anyOf": [ { "format": "uuid", "type": "string" }, { "type": "null" } ], "default": null, "description": "The ID of the folder that the agent belongs to", "title": "Folder Id" }, "result": { "anyOf": [ { "additionalProperties": true, "type": "object" }, { "type": "null" } ], "deprecated": true, "description": "Please use the evaluations instead", "title": "Result" }, "custom_metrics": { "anyOf": [ { "items": { "$ref": "#/components/schemas/CustomMetric" }, "type": "array" }, { "type": "null" } ], "deprecated": true, "description": "Please use the custom metrics in the evaluations instead", "title": "Custom Metrics" }, "evaluations": { "anyOf": [ { "items": { "$ref": "#/components/schemas/Evaluation" }, "type": "array" }, { "type": "null" } ], "description": "The evaluations of the simulation result", "title": "Evaluations" }, "created_at": { "anyOf": [ { "format": "date-time", "type": "string" }, { "type": "null" } ], "default": null, "description": "The creation time of the simulation result", "title": "Created At" }, "start_time": { "anyOf": [ { "format": "date-time", "type": "string" }, { "type": "null" } ], "default": null, "description": "The start time of the simulation result", "title": "Start Time" }, "end_time": { "anyOf": [ { "format": "date-time", "type": "string" }, { "type": "null" } ], "default": null, "description": "The end time of the simulation result", "title": "End Time" }, "duration": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "description": "The duration of the simulation result", "title": "Duration" }, "latency": { "anyOf": [ { "items": { "type": "number" }, "type": "array" }, { "type": "null" } ], "description": "The latency of the simulation result", "title": "Latency" }, "events": { "anyOf": [ { "items": { "$ref": "#/components/schemas/Event" }, "type": "array" }, { "type": "null" } ], "description": "The events of the simulation result", "title": "Events" }, "tool_calls": { "anyOf": [ { "items": { "$ref": "#/components/schemas/ToolCall" }, "type": "array" }, { "type": "null" } ], "description": "The tool calls of the simulation result", "title": "Tool Calls" }, "tags": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "description": "The tags of the simulation result", "title": "Tags" }, "metadata": { "anyOf": [ { "additionalProperties": true, "type": "object" }, { "type": "null" } ], "description": "The metadata of the simulation result", "title": "Metadata" } }, "required": [ "id", "digital_human_id", "simulation_run_id", "simulation_id", "agent_id" ], "title": "Simulation Result Evaluated", "type": "object" }, "CustomMetric": { "properties": { "name": { "description": "The name of the custom metric", "title": "Name", "type": "string" }, "description": { "description": "The description of the custom metric", "title": "Description", "type": "string" }, "response_type": { "description": "The response type of the custom metric", "title": "Response Type", "type": "string" }, "response_value": { "description": "The response value of the custom metric", "title": "Response Value", "type": "string" }, "reasoning": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "The reasoning of the custom metric", "title": "Reasoning" }, "min_value": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "The minimum value of the custom metric", "title": "Min Value" }, "max_value": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "The maximum value of the custom metric", "title": "Max Value" }, "category": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "The category of the custom metric", "title": "Category" }, "tags": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "The tags of the custom metric", "title": "Tags" }, "scoring_guidance": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "The scoring guidance of the custom metric", "title": "Scoring Guidance" }, "enum_options": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "The enum options of the custom metric", "title": "Enum Options" } }, "required": [ "name", "description", "response_type", "response_value" ], "title": "Custom Metric", "type": "object" }, "TestResultStatus": { "description": "Enum representing the possible states of a test result.", "enum": [ "INITIALIZING", "QUEUED", "READY", "DISPATCHED", "RUNNING", "CONVERSATION_ENDED", "EVALUATING", "COMPLETED", "INCOMPLETED", "REJECTED", "INSUFFICIENT_FUNDS" ], "title": "TestResultStatus", "type": "string" }, "WebhookObservabilityCallEvaluated": { "$defs": { "CallDirection": { "description": "Enum representing the direction of a call.", "enum": [ "INBOUND", "OUTBOUND" ], "title": "CallDirection", "type": "string" }, "CallInterface": { "description": "Enum representing the interface used for a call.", "enum": [ "PHONE", "WEB" ], "title": "CallInterface", "type": "string" }, "CallStatus": { "description": "Enum representing the possible states of a call.", "enum": [ "INITIALIZING", "QUEUED", "EVALUATING", "COMPLETED", "INCOMPLETED" ], "title": "CallStatus", "type": "string" }, "CustomMetric": { "properties": { "name": { "description": "The name of the custom metric", "title": "Name", "type": "string" }, "description": { "description": "The description of the custom metric", "title": "Description", "type": "string" }, "response_type": { "description": "The response type of the custom metric", "title": "Response Type", "type": "string" }, "response_value": { "description": "The response value of the custom metric", "title": "Response Value", "type": "string" }, "reasoning": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "The reasoning of the custom metric", "title": "Reasoning" }, "min_value": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "The minimum value of the custom metric", "title": "Min Value" }, "max_value": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "The maximum value of the custom metric", "title": "Max Value" }, "category": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "The category of the custom metric", "title": "Category" }, "tags": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "The tags of the custom metric", "title": "Tags" }, "scoring_guidance": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "The scoring guidance of the custom metric", "title": "Scoring Guidance" }, "enum_options": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "The enum options of the custom metric", "title": "Enum Options" } }, "required": [ "name", "description", "response_type", "response_value" ], "title": "Custom Metric", "type": "object" }, "Evaluation": { "description": "Pydantic model for evaluation result", "properties": { "id": { "description": "Unique identifier for the evaluation result", "title": "Id", "type": "string" }, "created_at": { "description": "When this evaluation result was created (defaults to now in UTC)", "format": "date-time", "title": "Created At", "type": "string" }, "hallucination": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "Whether the agent exhibited hallucination during the call", "title": "Hallucination" }, "hallucination_reasoning": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Reasoning behind the hallucination, if applicable", "title": "Hallucination Reasoning" }, "redundancy": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "Whether the agent exhibited redundancy during the call", "title": "Redundancy" }, "redundancy_reasoning": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Reasoning behind the redundancy, if applicable", "title": "Redundancy Reasoning" }, "agent_speak_percentage": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "description": "Percentage of the call where the agent was speaking", "title": "Agent Speak Percentage" }, "avg_agent_latency": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "description": "Average latency of the agent's responses during the call", "title": "Avg Agent Latency" }, "latency": { "anyOf": [ { "$ref": "#/components/schemas/Latency" }, { "type": "null" } ], "description": "Latency metrics for the agent's responses" }, "filler_ignored_latency": { "anyOf": [ { "$ref": "#/components/schemas/FillerIgnoredLatency" }, { "type": "null" } ], "description": "Filler ignored latency metrics" }, "num_turns": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "description": "Total number of turns taken by the agent during the call", "title": "Num Turns" }, "call_summary": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Summary of the call, if applicable", "title": "Call Summary" }, "custom_evals": { "anyOf": [ { "items": {}, "type": "array" }, { "additionalProperties": true, "type": "object" }, { "type": "null" } ], "description": "List of custom evaluations performed during the call", "title": "Custom Evals" }, "custom_evals_success_rate": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Success rate of the custom evaluations performed during the call", "title": "Custom Evals Success Rate" }, "goal_success": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "Whether the goal was successfully achieved during the call", "title": "Goal Success" }, "goal_reasoning": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Reasoning behind the goal success, if applicable", "title": "Goal Reasoning" }, "pronunciation_score": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Pronunciation score of the agent during the call", "title": "Pronunciation Score" }, "pronunciation_reasoning": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Reasoning behind the pronunciation score, if applicable", "title": "Pronunciation Reasoning" }, "custom_metrics": { "anyOf": [ { "items": { "$ref": "#/components/schemas/CustomMetric" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "Custom metrics associated with the evaluation", "title": "Custom Metrics" } }, "required": [ "agent_speak_percentage", "avg_agent_latency" ], "title": "Evaluation", "type": "object" }, "Event": { "description": "Pydantic model for event data", "properties": { "title": { "description": "Title of the event", "title": "Title", "type": "string" }, "start_offset_ms": { "description": "Start offset of the event in milliseconds", "title": "Start Offset Ms", "type": "integer" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Description of the event", "title": "Description" }, "end_offset_ms": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "description": "End offset of the event in milliseconds", "title": "End Offset Ms" }, "tags": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "description": "List of tags associated with the event", "title": "Tags" }, "metadata": { "anyOf": [ { "additionalProperties": true, "type": "object" }, { "type": "null" } ], "default": null, "description": "Additional metadata associated with the event", "title": "Metadata" } }, "required": [ "title", "start_offset_ms" ], "title": "Event", "type": "object" }, "FillerIgnoredLatency": { "properties": { "avg_filler_ignored_latency": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": 0, "description": "Average filler ignored latency", "title": "Avg Filler Ignored Latency" }, "p50_filler_ignored_latency": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": 0, "description": "50th percentile filler ignored latency", "title": "P50 Filler Ignored Latency" }, "p90_filler_ignored_latency": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": 0, "description": "90th percentile filler ignored latency", "title": "P90 Filler Ignored Latency" }, "p95_filler_ignored_latency": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": 0, "description": "95th percentile filler ignored latency", "title": "P95 Filler Ignored Latency" }, "p99_filler_ignored_latency": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": 0, "description": "99th percentile filler ignored latency", "title": "P99 Filler Ignored Latency" } }, "title": "FillerIgnoredLatency", "type": "object" }, "Latency": { "properties": { "avg_agent_latency": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": 0, "description": "Average latency", "title": "Avg Agent Latency" }, "max_agent_latency": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": 0, "description": "Maximum latency", "title": "Max Agent Latency" }, "p50_agent_latency": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": 0, "description": "50th percentile latency", "title": "P50 Agent Latency" }, "p90_agent_latency": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": 0, "description": "90th percentile latency", "title": "P90 Agent Latency" }, "p95_agent_latency": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": 0, "description": "95th percentile latency", "title": "P95 Agent Latency" }, "p99_agent_latency": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": 0, "description": "99th percentile latency", "title": "P99 Agent Latency" } }, "title": "Latency", "type": "object" }, "ParticipantResponse": { "description": "Pydantic model for participant data", "properties": { "role": { "$ref": "#/components/schemas/ParticipantRole", "description": "Role of the participant in the call" }, "spoke_first": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "Whether the participant spoke first in the call", "title": "Spoke First" }, "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Name of the participant", "title": "Name" }, "phone_number": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Phone number of the participant (if applicable)", "title": "Phone Number" } }, "required": [ "role" ], "title": "ParticipantResponse", "type": "object" }, "ParticipantRole": { "description": "Enum representing the role of a participant in a call.", "enum": [ "AGENT", "USER" ], "title": "ParticipantRole", "type": "string" }, "ToolCall": { "description": "Represents a tool call during a conversation.", "properties": { "name": { "description": "Name of the tool called", "title": "Name", "type": "string" }, "start_offset_ms": { "description": "Start offset of the tool call in milliseconds", "minimum": 0, "title": "Start Offset Ms", "type": "integer" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Description of the tool call", "title": "Description" }, "parameters": { "anyOf": [ { "additionalProperties": true, "type": "object" }, { "type": "null" } ], "default": null, "description": "Parameters passed to the tool call", "title": "Parameters" }, "output": { "anyOf": [ {}, { "type": "null" } ], "default": null, "description": "Output returned by the tool call", "title": "Output" } }, "required": [ "name", "start_offset_ms" ], "title": "ToolCall", "type": "object" } }, "description": "Represents an observability call evaluated event.", "properties": { "id": { "description": "Unique identifier for the call", "title": "Id", "type": "string" }, "agent_id": { "description": "ID of the agent associated with the call", "title": "Agent Id", "type": "string" }, "external_agent_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "External ID of the agent associated with the call", "title": "External Agent Id" }, "recording_url": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "description": "URL to the recording file (supported formats: .mp4, .wav, .m4a)", "title": "Recording Url" }, "start_time_utc": { "description": "When the call started, in UTC", "title": "Start Time Utc", "type": "string" }, "participants": { "description": "List of call participants", "items": { "$ref": "#/components/schemas/ParticipantResponse" }, "title": "Participants", "type": "array" }, "call_direction": { "$ref": "#/components/schemas/CallDirection", "default": "INBOUND", "description": "Direction of the call from the Agent's perspective (INBOUND or OUTBOUND)" }, "interface": { "$ref": "#/components/schemas/CallInterface", "default": "PHONE", "description": "Interface used for the call" }, "status": { "$ref": "#/components/schemas/CallStatus", "description": "Current status of the call" }, "created_at": { "description": "When this request was created (defaults to now in UTC)", "format": "date-time", "title": "Created At", "type": "string" }, "transcript_url": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "URL to the transcript file (supported formats: .txt, .json)", "title": "Transcript Url" }, "tool_calls": { "anyOf": [ { "items": { "$ref": "#/components/schemas/ToolCall" }, "type": "array" }, { "type": "null" } ], "description": "List of tool calls made during the call", "title": "Tool Calls" }, "events": { "anyOf": [ { "items": { "$ref": "#/components/schemas/Event" }, "type": "array" }, { "type": "null" } ], "description": "List of events that occurred during the call", "title": "Events" }, "tags": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "description": "List of tags associated with the call", "title": "Tags" }, "duration_ms": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": 0, "description": "Duration of the call in milliseconds", "title": "Duration Ms" }, "evaluations": { "anyOf": [ { "items": { "$ref": "#/components/schemas/Evaluation" }, "type": "array" }, { "type": "null" } ], "description": "List of evaluations associated with the call", "title": "Evaluations" }, "annotations": { "anyOf": [ { "items": {}, "type": "array" }, { "type": "null" } ], "default": null, "description": "Annotations associated with the call", "title": "Annotations" }, "metadata": { "anyOf": [ { "additionalProperties": true, "type": "object" }, { "type": "null" } ], "default": null, "description": "Additional metadata associated with the call", "title": "Metadata" }, "custom_metrics": { "anyOf": [ { "items": {}, "type": "array" }, { "type": "null" } ], "default": null, "deprecated": true, "description": "Please use the custom metrics in the evaluations instead", "title": "Custom Metrics" }, "conversation_ended_by": { "anyOf": [ { "$ref": "#/components/schemas/ParticipantRole" }, { "type": "null" } ], "default": null, "description": "Which participant role ended the conversation: 'USER' or 'AGENT'" }, "type": { "default": "observability_call_evaluated", "description": "Type of webhook payload", "title": "Type", "type": "string" } }, "required": [ "id", "agent_id", "recording_url", "start_time_utc", "participants", "status" ], "title": "Observability Call Evaluated", "type": "object" }, "WebhookSimulationResultEnded": { "$defs": { "TestResultStatus": { "description": "Enum representing the possible states of a test result.", "enum": [ "INITIALIZING", "QUEUED", "READY", "DISPATCHED", "RUNNING", "CONVERSATION_ENDED", "EVALUATING", "COMPLETED", "INCOMPLETED", "REJECTED", "INSUFFICIENT_FUNDS" ], "title": "TestResultStatus", "type": "string" } }, "description": "Represents a simulation result ended event.", "properties": { "type": { "default": "simulation_ended", "description": "Type of webhook payload", "title": "Type", "type": "string" }, "id": { "description": "The ID of the simulation result", "title": "Id", "type": "integer" }, "digital_human_id": { "description": "The ID of the digital human", "title": "Digital Human Id", "type": "integer" }, "status": { "$ref": "#/components/schemas/TestResultStatus", "default": "CONVERSATION_ENDED", "description": "The status of the simulation result" }, "simulation_run_id": { "description": "The ID of the simulation run that this simulation result belongs to", "title": "Simulation Run Id", "type": "integer" }, "created_at": { "anyOf": [ { "format": "date-time", "type": "string" }, { "type": "null" } ], "default": null, "description": "The creation time of the simulation result", "title": "Created At" }, "start_time": { "anyOf": [ { "format": "date-time", "type": "string" }, { "type": "null" } ], "default": null, "description": "The start time of the simulation result", "title": "Start Time" }, "end_time": { "anyOf": [ { "format": "date-time", "type": "string" }, { "type": "null" } ], "default": null, "description": "The end time of the simulation result", "title": "End Time" }, "duration": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "description": "The duration of the simulation result", "title": "Duration" } }, "required": [ "id", "digital_human_id", "simulation_run_id" ], "title": "Simulation Ended", "type": "object" }, "WebhookCustomMetric": { "properties": { "name": { "description": "The name of the custom metric", "title": "Name", "type": "string" }, "description": { "description": "The description of the custom metric", "title": "Description", "type": "string" }, "response_type": { "description": "The response type of the custom metric", "title": "Response Type", "type": "string" }, "response_value": { "description": "The response value of the custom metric", "title": "Response Value", "type": "string" }, "reasoning": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "The reasoning of the custom metric", "title": "Reasoning" }, "min_value": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "The minimum value of the custom metric", "title": "Min Value" }, "max_value": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "The maximum value of the custom metric", "title": "Max Value" }, "category": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "The category of the custom metric", "title": "Category" }, "tags": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "The tags of the custom metric", "title": "Tags" }, "scoring_guidance": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "The scoring guidance of the custom metric", "title": "Scoring Guidance" }, "enum_options": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "The enum options of the custom metric", "title": "Enum Options" } }, "required": [ "name", "description", "response_type", "response_value" ], "title": "Custom Metric", "type": "object" }, "WebhookOutboundSimulationStarted": { "$defs": { "DigitalHuman": { "properties": { "id": { "description": "The ID of the digital human", "title": "Id", "type": "integer" }, "name": { "description": "The name of the digital human", "title": "Name", "type": "string" }, "phone_number": { "description": "The phone number of the digital human", "title": "Phone Number", "type": "string" }, "associated_simulation_result_ids": { "description": "The IDs of the simulation results that were created for this digital human", "items": { "type": "integer" }, "title": "Associated Simulation Result Ids", "type": "array" } }, "required": [ "id", "name", "phone_number" ], "title": "Digital Human", "type": "object" } }, "description": "Represents an outbound simulation started event.", "properties": { "type": { "default": "outbound_simulation_started", "description": "Type of webhook payload", "title": "Type", "type": "string" }, "agent_id": { "description": "The ID of the agent that this simulation belongs to", "title": "Agent Id", "type": "integer" }, "simulation_id": { "description": "The ID of the simulation", "title": "Simulation Id", "type": "integer" }, "simulation_run_id": { "description": "The ID of the simulation run", "title": "Simulation Run Id", "type": "integer" }, "digital_humans": { "description": "The digital humans that were run for this simulation run", "items": { "$ref": "#/components/schemas/DigitalHuman" }, "title": "Digital Humans", "type": "array" } }, "required": [ "agent_id", "simulation_id", "simulation_run_id", "digital_humans" ], "title": "Outbound Simulation Started", "type": "object" }, "DigitalHuman": { "properties": { "id": { "description": "The ID of the digital human", "title": "Id", "type": "integer" }, "name": { "description": "The name of the digital human", "title": "Name", "type": "string" }, "phone_number": { "description": "The phone number of the digital human", "title": "Phone Number", "type": "string" }, "associated_simulation_result_ids": { "description": "The IDs of the simulation results that were created for this digital human", "items": { "type": "integer" }, "title": "Associated Simulation Result Ids", "type": "array" } }, "required": [ "id", "name", "phone_number" ], "title": "Digital Human", "type": "object" } }, "securitySchemes": { "apiKeyAuth": { "type": "apiKey", "in": "header", "name": "X-API-Key", "description": "API key required to authenticate requests." } } }, "webhooks": { "events_webhook": { "post": { "summary": "Webhook: events_webhook", "description": "Upon an event on the platform, we'll send you the results to the URL you registered within the dashboard", "requestBody": { "required": true, "content": { "application/json": { "schema": { "oneOf": [ { "$ref": "#/components/schemas/WebhookSimulationResultEvaluated" }, { "$ref": "#/components/schemas/WebhookObservabilityCallEvaluated" }, { "$ref": "#/components/schemas/WebhookSimulationResultEnded" }, { "$ref": "#/components/schemas/WebhookOutboundSimulationStarted" } ], "discriminator": { "propertyName": "type", "mapping": { "simulation_result_evaluated": "#/components/schemas/WebhookSimulationResultEvaluated", "observability_call_evaluated": "#/components/schemas/WebhookObservabilityCallEvaluated", "simulation_ended": "#/components/schemas/WebhookSimulationResultEnded", "outbound_simulation_started": "#/components/schemas/WebhookOutboundSimulationStarted" } } } } } }, "responses": { "200": { "description": "Webhook received successfully" } } } } }, "security": [ { "apiKeyAuth": [] } ], "servers": [ { "url": "https://api.getbluejay.ai", "description": "Production server" } ] }