Agents
Create a new agent
Create a new agent using a secret key
POST
/api/v1/service/projects/{project_id}/agentsCreate a new agent using a secret key
Authorization
BearerAuth AuthorizationBearer <token>
In: header
Path Parameters
project_id*Project Id
Format
uuidRequest Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
curl -X POST "https://example.com/api/v1/service/projects/497f6eca-6276-4993-bfeb-53cbbbba6f08/agents" \ -H "Content-Type: application/json" \ -d '{ "name": "string", "agent_type": "single_prompt" }'{ "name": "string", "prompt": "string", "hangup_prompt": "string", "is_hangup_prompt_enabled": false, "welcome_message": "string", "agent_type": "single_prompt", "workflow_id": "03e70e31-d7a4-4401-a629-6a4b6096cdfe", "config": {}, "call_configuration": { "call_provider": "exotel", "final_message": "string", "final_message_language_id": "de48a4d4-8ae3-4265-98cd-d24b3b656723", "hangup_on_user_silence": 7, "total_call_timeout": 1800, "ambient_sound": { "enabled": false, "sound_type": "light_rain", "volume": 0.5 }, "voicemail_detection": false, "voicemail_message_enabled": false, "voicemail_message": "string", "keypad_input_detection": { "enabled": false, "timeout_secs": 2, "termination_key_enabled": false, "termination_key": "#", "digit_limit_enabled": false, "digit_limit": 5 }, "ivr_navigation": { "enabled": false, "goal": "string" }, "timezone": "UTC", "availability": { "inbound": { "enabled": false, "days": [ { "day": "monday", "enabled": false, "start": "09:00", "end": "17:00" } ] }, "outbound": { "enabled": false, "days": [ { "day": "monday", "enabled": false, "start": "09:00", "end": "17:00" } ] } }, "unavailable_message": "string", "is_noise_cancellation_enabled": false, "noise_cancellation_filter": "RNN", "strategies": {} }, "status": "draft", "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08", "user_id": "a169451c-8525-4352-b8ca-070dd449a1a5", "created_at": "2019-08-24T14:15:22Z", "updated_at": "2019-08-24T14:15:22Z", "is_active": true, "knowledge_bases": [], "function_tools": [], "guardrails": [ { "name": "string", "response": "string", "threshold": 0, "utterances": [ { "text": "string" } ] } ], "structured_output": [ { "name": "string", "description": "", "method": "ai_extraction", "structured_schema": { "type": "boolean", "description": "string", "properties": { "property1": {}, "property2": {} }, "required": [ "string" ], "items": {}, "minimum": 0, "maximum": 0 } } ], "estimated_cost": {}, "language": { "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08", "name": "string", "code": "string" }}