Skip to main content

AI Voice Agents API

Use AI agent endpoints to create, list, read, update, pause, activate, and delete customer-scoped voice agents. Every request requires a MiniVoice API key. The API key determines the customer, so requests must not include customer_id.

Endpoints​

EndpointMethodPurpose
/v1/ai/agentsGETList AI agents for the authenticated customer.
/v1/ai/agentsPOSTCreate an AI agent.
/v1/ai/agents/:idGETRead one AI agent.
/v1/ai/agents/:idPATCHUpdate one AI agent.
/v1/ai/agents/:idDELETESoft-delete one AI agent.
/v1/ai/agents/:id/activatePOSTSet an agent active.
/v1/ai/agents/:id/pausePOSTSet an agent paused.

Create Request​

curl -sS https://api.minivoice.eu/v1/ai/agents \
-X POST \
-H 'Authorization: Bearer $MINIVOICE_API_KEY' \
-H 'Content-Type: application/json' \
-d '{
"name": "Sales Receptionist",
"description": "Answers new inbound sales calls for a software company.",
"greeting": "Thanks for calling Acme Software. Are you calling about sales or support?",
"instructions": "Ask one question at a time. If the caller wants sales, collect company name and team size. If the caller wants support, transfer to the support destination.",
"model": "gpt-4.1-mini",
"voice": "nova",
"language": "en",
"runtime_limits": {
"max_turns": 10,
"max_call_seconds": 420,
"silence_timeout_ms": 3000,
"turn_recording_max_seconds": 10
},
"fallback_message": "I am having trouble continuing. I will connect you with the team."
}'

Create Response​

{
"data": {
"id": "agent_20260707T120000.000000000",
"name": "Sales Receptionist",
"status": "active",
"is_active": true,
"model": "gpt-4.1-mini",
"voice": "nova",
"language": "en",
"greeting": "Thanks for calling Acme Software. Are you calling about sales or support?",
"instructions": "Ask one question at a time. If the caller wants sales, collect company name and team size. If the caller wants support, transfer to the support destination.",
"business_profile": "Answers new inbound sales calls for a software company.",
"behavior_config": {
"campaign_mode": false,
"max_turn_latency_ms": 8000,
"runtime_limits": {
"max_turns": 10,
"max_call_seconds": 420,
"silence_timeout_ms": 3000,
"turn_recording_max_seconds": 10
},
"fallback_message": "I am having trouble continuing. I will connect you with the team."
},
"tool_config": {
"type": "",
"target": "",
"message": "I am having trouble continuing. I will connect you with the team.",
"hangup_tool_description": "",
"transfer_tool_description": "",
"transfer_destinations": []
},
"description": "Answers new inbound sales calls for a software company.",
"campaign_mode": false,
"runtime_limits": {
"max_turns": 10,
"max_call_seconds": 420,
"silence_timeout_ms": 3000,
"turn_recording_max_seconds": 10
},
"created_at": "2026-07-07T12:00:00Z",
"updated_at": "2026-07-07T12:00:00Z"
}
}

Parameters​

FieldTypeRequiredDescription
namestringyes on createAgent name. Must be at most 120 characters.
descriptionstringnoPublic response field also returned as business_profile. Must be at most 1000 characters.
greetingstringnoFirst message spoken to the caller. Alias for greeting_message. Must be at most 500 characters.
instructionsstringnoAgent prompt. Alias for system_prompt in requests, but public responses use instructions. Must be at most 8000 characters.
modelstringnoDefaults to gpt-4.1-mini. Must be one of the public model allowlist.
voicestringnoDefaults to alloy. Must be one of the public voice allowlist.
languagestringnoDefaults to en. Must match a short language code such as en or en-US.
runtime_limits.max_turnsintegernoDefaults to 5. Valid range is 1 to 20.
runtime_limits.max_call_secondsintegernoDefaults to 180. Valid range is 30 to 1800.
runtime_limits.silence_timeout_msintegernoDefaults to 3000. Valid range is 1000 to 15000.
runtime_limits.turn_recording_max_secondsintegernoDefaults to 10. Valid range is 2 to 30.
max_turn_latency_msintegernoDefaults to 8000. Valid range is 1000 to 60000.
is_activebooleannoDefaults to true on create. Paused agents cannot be used for DID routing or outbound AI calls.

Do not include customer_id or secret/provider configuration in public agent requests. The API key supplies customer scope, and unsupported configuration fields return unsupported_field.

Update Example​

curl -sS https://api.minivoice.eu/v1/ai/agents/agent_20260707T120000.000000000 \
-X PATCH \
-H 'Authorization: Bearer $MINIVOICE_API_KEY' \
-H 'Content-Type: application/json' \
-d '{
"greeting": "Thanks for calling Acme Software. How can I route your call?",
"runtime_limits": {
"max_turns": 8,
"max_call_seconds": 300
}
}'

PATCH preserves existing values for fields you omit. To pause without changing the rest of the agent, use the dedicated pause endpoint.

Pause and Activate​

curl -sS https://api.minivoice.eu/v1/ai/agents/agent_20260707T120000.000000000/pause \
-X POST \
-H 'Authorization: Bearer $MINIVOICE_API_KEY'
curl -sS https://api.minivoice.eu/v1/ai/agents/agent_20260707T120000.000000000/activate \
-X POST \
-H 'Authorization: Bearer $MINIVOICE_API_KEY'

List Example​

curl -sS 'https://api.minivoice.eu/v1/ai/agents?limit=25' \
-H 'Authorization: Bearer $MINIVOICE_API_KEY'
{
"count": 1,
"data": [
{
"id": "agent_20260707T120000.000000000",
"name": "Sales Receptionist",
"status": "active",
"is_active": true,
"model": "gpt-4.1-mini",
"voice": "nova",
"language": "en"
}
]
}

Common Error​

{
"error": {
"code": "invalid_model",
"message": "model is not supported",
"allowed_values": [
"gpt-realtime-2",
"gpt-4.1-mini",
"gpt-4.1",
"gpt-4o-mini",
"gpt-4o"
]
}
}

Testing​

Create an agent with a short receptionist prompt. Fetch it by ID and verify that the response includes instructions but not an internal system_prompt field. Pause the agent and confirm that using it for a DID route or outbound AI call fails as unavailable. Activate it again before testing live calls.