View raw JSON
{
"type": "object",
"required": [
"body"
],
"properties": {
"body": {
"type": "object",
"$schema": "https://json-schema.org/draft/2020-12/schema",
"required": [
"connection"
],
"~standard": {
"vendor": "zod",
"version": 1,
"jsonSchema": {}
},
"properties": {
"country": {
"type": "string",
"const": "US",
"default": "US",
"description": "ISO 3166-1 alpha-2 country code. Phase 1 supports 'US' only."
},
"connection": {
"type": "object",
"required": [
"instructions"
],
"properties": {
"llm": {
"type": "object",
"required": [
"model"
],
"properties": {
"model": {
"type": "string",
"minLength": 1,
"description": "Managed LLM (e.g. \"openai/gpt-4o\")."
}
},
"description": "The model the hosted assistant runs.",
"additionalProperties": false
},
"tts": {
"type": "object",
"required": [
"voiceId"
],
"properties": {
"voiceId": {
"type": "string",
"minLength": 1,
"description": "TTS voice — an `id` from /list-voices."
}
},
"description": "Text-to-speech voice selection.",
"additionalProperties": false
},
"name": {
"type": "string",
"maxLength": 120,
"minLength": 1,
"description": "Human-readable persona name (1–120 characters)."
},
"language": {
"type": "string",
"maxLength": 35,
"minLength": 2,
"description": "BCP-47 language tag (e.g. \"en\", \"es\") — see /list-languages."
},
"disclosure": {
"type": "string",
"maxLength": 1000,
"description": "The AI/TCPA notice spoken first when compliance is on. Leave empty and a standard org-named default is used."
},
"callControl": {
"type": "object",
"properties": {
"endCall": {
"type": "boolean",
"description": "Allow the assistant to hang up the call (default on)."
},
"sendDtmf": {
"type": "boolean",
"description": "Allow the assistant to press keypad digits, e.g. to navigate an IVR (default on)."
}
},
"description": "Which live-call actions the assistant may take (signaling only).",
"additionalProperties": false
},
"instructions": {
"type": "string",
"maxLength": 10000,
"minLength": 1,
"description": "System prompt for the number's AI persona (how it speaks and what it does on calls). REQUIRED — every number has exactly one connection."
},
"smsAutoReply": {
"type": "boolean",
"description": "Auto-answer inbound SMS with the assistant (default off)."
},
"complianceEnabled": {
"type": "boolean",
"description": "When true (the default), the disclosure is spoken as the line's first, uninterruptible utterance and the do-not-message tool is exposed."
}
},
"description": "The number's AI persona — REQUIRED. Created and attached internally; update it later via /update-numbers/{id}.",
"additionalProperties": false
},
"phoneNumber": {
"anyOf": [
{
"type": "object",
"properties": {
"areaCode": {
"type": "string",
"pattern": "^\\d{3}$",
"description": "Preferred 3-digit area code (e.g. '415'). Local numbers only. Omit to take any available number."
},
"numberType": {
"type": "string",
"const": "local",
"default": "local"
}
},
"additionalProperties": false
},
{
"type": "object",
"required": [
"numberType"
],
"properties": {
"numberType": {
"type": "string",
"const": "toll_free"
}
},
"additionalProperties": false
}
],
"default": {
"numberType": "local"
}
}
},
"additionalProperties": false
}
},
"additionalProperties": false
}