{"openapi":"3.1.0","info":{"title":"Allerto API","version":"2026-09-21","description":"Voice agents that answer and place phone calls. Authenticate with `Authorization: Bearer alt_live_…` (or `alt_test_…` for test mode). Docs: https://api.allerto.cloud/docs"},"servers":[{"url":"https://api.allerto.cloud"}],"security":[{"bearer":[]}],"paths":{"/v1/me":{"get":{"summary":"The account and mode of this key","operationId":"getMe","responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object"}}}}}}},"/v1/agents":{"get":{"summary":"List agents","operationId":"listAgents","parameters":[{"name":"type","in":"query","schema":{"enum":["inbound","outbound"]}},{"name":"client","in":"query","schema":{"type":"string"}},{"name":"include_archived","in":"query","schema":{"enum":["true","false"]}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/AgentResource"}},"next_cursor":{"type":["string","null"]}}}}}}}},"post":{"summary":"Create an agent (as a draft)","operationId":"createAgent","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["config"],"properties":{"client":{"type":"string","description":"Client external_id or id (optional)"},"config":{"$ref":"#/components/schemas/Agent"}}}}}},"responses":{"201":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AgentResource"}}}},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid API key","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflict (revision, state, do-not-call)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/agents/schema":{"get":{"summary":"JSON Schema of the agent document","operationId":"getAgentSchema","responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object"}}}}}}},"/v1/agents/validate":{"post":{"summary":"Validate an agent document without saving it","operationId":"validateAgent","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"config":{"$ref":"#/components/schemas/Agent"}}}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"valid":{"type":"boolean"},"errors":{"type":"array"}}}}}}}}},"/v1/agents/{id}":{"get":{"summary":"Get an agent","operationId":"getAgent","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AgentResource"}}}},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid API key","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflict (revision, state, do-not-call)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/agents/{id}/draft":{"put":{"summary":"Save the draft","operationId":"saveAgentDraft","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["config","revision"],"properties":{"config":{"$ref":"#/components/schemas/Agent"},"revision":{"type":"integer"}}}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AgentResource"}}}},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid API key","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflict (revision, state, do-not-call)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/agents/{id}/publish":{"post":{"summary":"Publish the draft as a new immutable version","operationId":"publishAgent","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["revision"],"properties":{"revision":{"type":"integer"}}}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AgentResource"}}}},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid API key","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflict (revision, state, do-not-call)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/agents/{id}/archive":{"post":{"summary":"Archive an agent","operationId":"archiveAgent","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AgentResource"}}}},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid API key","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflict (revision, state, do-not-call)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/agents/{id}/mcp-token":{"put":{"summary":"Store the bearer token Allerto sends to the agent's MCP server (encrypted, never returned)","operationId":"setAgentMcpToken","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["token"],"properties":{"token":{"type":"string"}}}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AgentResource"}}}},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid API key","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflict (revision, state, do-not-call)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"delete":{"summary":"Remove the MCP token","operationId":"deleteAgentMcpToken","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AgentResource"}}}},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid API key","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflict (revision, state, do-not-call)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/agents/{id}/mcp-test":{"post":{"summary":"Connect to the agent's MCP server and list the tools the agent would get","operationId":"testAgentMcp","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"config":{"$ref":"#/components/schemas/Agent","description":"Optional: test this document instead of the draft"}}}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"url":{"type":"string"},"error":{"type":"string"},"tools":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string"},"description":{"type":"string"},"kind":{"enum":["read","action"],"description":"Tools not annotated readOnlyHint are actions: they need the person's explicit yes"},"parameters":{"type":"object"}}}}}}}}},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid API key","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflict (revision, state, do-not-call)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/agents/{id}/versions":{"get":{"summary":"List published versions","operationId":"listAgentVersions","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object"}},"next_cursor":{"type":["string","null"]}}}}}}}}},"/v1/agents/{id}/versions/{version}":{"get":{"summary":"Get a published version","operationId":"getAgentVersion","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid"}},{"name":"version","in":"path","required":true,"schema":{"type":"integer"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"version":{"type":"integer"},"config":{"$ref":"#/components/schemas/Agent"}}}}}},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid API key","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflict (revision, state, do-not-call)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/agents/{id}/preview":{"post":{"summary":"Render the first sentence and prompt with example or given inputs (no call)","operationId":"previewAgent","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid"}}],"requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"inputs":{"type":"object"},"version":{"oneOf":[{"const":"draft"},{"type":"integer"}]}}}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object"}}}},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid API key","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflict (revision, state, do-not-call)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/calls":{"post":{"summary":"Queue an outbound call","operationId":"createCall","parameters":[{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":200},"description":"Repeat a request safely: the same key returns the original result."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CallRequest"}}}},"responses":{"200":{"description":"Already queued with this Idempotency-Key","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Call"}}}},"202":{"description":"Queued","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Call"}}}},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid API key","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflict (revision, state, do-not-call)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"get":{"summary":"List calls in both directions, newest first","operationId":"listCalls","parameters":[{"name":"direction","in":"query","schema":{"type":"string"}},{"name":"agent","in":"query","schema":{"type":"string"}},{"name":"campaign","in":"query","schema":{"type":"string"}},{"name":"status","in":"query","schema":{"type":"string"}},{"name":"outcome","in":"query","schema":{"type":"string"}},{"name":"reference","in":"query","schema":{"type":"string"}},{"name":"since","in":"query","schema":{"type":"string"}},{"name":"cursor","in":"query","schema":{"type":"string"}},{"name":"limit","in":"query","schema":{"type":"integer"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Call"}},"next_cursor":{"type":["string","null"]}}}}}}}}},"/v1/calls/{id}":{"get":{"summary":"Get a call","operationId":"getCall","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Call"}}}},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid API key","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflict (revision, state, do-not-call)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/calls/{id}/transcript":{"get":{"summary":"Get the transcript of a call","operationId":"getCallTranscript","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object"}}}},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid API key","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflict (revision, state, do-not-call)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/calls/{id}/cancel":{"post":{"summary":"Cancel a queued outbound call","operationId":"cancelCall","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Call"}}}},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid API key","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflict (revision, state, do-not-call)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/campaigns":{"post":{"summary":"Create a campaign from a list of contacts","operationId":"createCampaign","parameters":[{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":200},"description":"Repeat a request safely: the same key returns the original result."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CampaignRequest"}}}},"responses":{"202":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Campaign"}}}},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid API key","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflict (revision, state, do-not-call)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"get":{"summary":"List campaigns","operationId":"listCampaigns","responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Campaign"}},"next_cursor":{"type":["string","null"]}}}}}}}}},"/v1/campaigns/{id}":{"get":{"summary":"Get a campaign with its progress","operationId":"getCampaign","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Campaign"}}}},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid API key","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflict (revision, state, do-not-call)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/campaigns/{id}/pause":{"post":{"summary":"Pause a campaign","operationId":"pauseCampaign","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Campaign"}}}},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid API key","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflict (revision, state, do-not-call)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/campaigns/{id}/resume":{"post":{"summary":"Resume a campaign","operationId":"resumeCampaign","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Campaign"}}}},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid API key","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflict (revision, state, do-not-call)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/campaigns/{id}/cancel":{"post":{"summary":"Cancel a campaign","operationId":"cancelCampaign","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Campaign"}}}},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid API key","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflict (revision, state, do-not-call)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/numbers":{"get":{"summary":"List the account's numbers","operationId":"listNumbers","responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object"}},"next_cursor":{"type":["string","null"]}}}}}}}}},"/v1/numbers/{id}":{"put":{"summary":"Route a number to an inbound agent","operationId":"routeNumber","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["agent"],"properties":{"agent":{"type":"string","format":"uuid"}}}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object"}}}},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid API key","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflict (revision, state, do-not-call)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/suppressions":{"get":{"summary":"List the do-not-call list","operationId":"listSuppressions","responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object"}},"next_cursor":{"type":["string","null"]}}}}}}}},"post":{"summary":"Add a number to the do-not-call list","operationId":"addSuppression","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["number"],"properties":{"number":{"type":"string"},"reason":{"type":"string"}}}}}},"responses":{"201":{"description":"OK","content":{"application/json":{"schema":{"type":"object"}}}},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid API key","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflict (revision, state, do-not-call)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/suppressions/{number}":{"delete":{"summary":"Remove a number from the do-not-call list","operationId":"removeSuppression","parameters":[{"name":"number","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object"}}}},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid API key","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflict (revision, state, do-not-call)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/webhook-secret":{"post":{"summary":"Create or rotate the account's webhook signing secret (shown once)","operationId":"rotateWebhookSecret","responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"secret":{"type":"string"}}}}}}}}},"/v1/events":{"get":{"summary":"Recent events and their delivery status","operationId":"listEvents","responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object"}},"next_cursor":{"type":["string","null"]}}}}}}}}},"/v1/clients":{"get":{"summary":"List clients","operationId":"listClients","responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object"}},"next_cursor":{"type":["string","null"]}}}}}}}},"post":{"summary":"Create a client (grouping for re-billing)","operationId":"createClient","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["name","external_id"],"properties":{"name":{"type":"string"},"external_id":{"type":"string"}}}}}},"responses":{"201":{"description":"OK","content":{"application/json":{"schema":{"type":"object"}}}},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid API key","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflict (revision, state, do-not-call)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/clients/{id}":{"delete":{"summary":"Delete a client: its agents are archived, queued calls cancelled and its login removed; call and usage history is kept","operationId":"deleteClient","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object"}}}},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid API key","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflict (revision, state, do-not-call)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/usage":{"get":{"summary":"Monthly usage and bill","operationId":"getUsage","parameters":[{"name":"period","in":"query","schema":{"type":"string","pattern":"^\\d{4}-\\d{2}$"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object"}}}}}}},"/v1/usage/records":{"get":{"summary":"One row per recorded call","operationId":"listUsageRecords","responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object"}},"next_cursor":{"type":["string","null"]}}}}}}}}}},"webhooks":{"call.completed":{"post":{"summary":"A call ended (answered or not), with its outcome and result","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Event"}}}},"responses":{"200":{"description":"Acknowledge with any 2xx"}}}},"call.attempt_failed":{"post":{"summary":"An outbound attempt was not answered; another attempt is scheduled","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Event"}}}},"responses":{"200":{"description":"Acknowledge with any 2xx"}}}}},"components":{"securitySchemes":{"bearer":{"type":"http","scheme":"bearer","description":"API key from the portal (Numbers and developers)"}},"schemas":{"Agent":{"$schema":"https://json-schema.org/draft/2020-12/schema","oneOf":[{"type":"object","properties":{"type":{"type":"string","const":"inbound"},"name":{"type":"string","minLength":2,"maxLength":100},"persona":{"type":"string","minLength":1,"maxLength":80},"language":{"default":"it","type":"string","enum":["it","en"]},"model":{"type":"string","enum":["gpt-live-1","gemini-3.8-live"]},"voice":{"type":"string","enum":["alloy","ash","ballad","beacon","bossa","cedar","cinder","coral","delta","echo","gleam","marin","meridian","quartz","ripple","sage","shimmer","stone","tempo","verse","vesper","willow","Achernar","Achird","Algenib","Algieba","Alnilam","Aoede","Autonoe","Callirrhoe","Charon","Despina","Enceladus","Erinome","Fenrir","Gacrux","Iapetus","Kore","Laomedeia","Leda","Orus","Puck","Pulcherrima","Rasalgethi","Sadachbia","Sadaltager","Schedar","Sulafat","Umbriel","Vindemiatrix","Zephyr","Zubenelgenubi"]},"customVoiceId":{"type":"string","pattern":"^voice_[A-Za-z0-9_-]+$"},"instructions":{"type":"string","minLength":10,"maxLength":12000},"result":{"default":[],"maxItems":40,"type":"array","items":{"type":"object","properties":{"key":{"type":"string","pattern":"^[a-z][a-z0-9_]{0,49}$"},"label":{"type":"string","minLength":1,"maxLength":100},"type":{"type":"string","enum":["text","number","boolean","select","date","phone","email"]},"required":{"default":false,"type":"boolean"},"options":{"default":[],"maxItems":30,"type":"array","items":{"type":"string","minLength":1,"maxLength":100}},"when":{"type":"object","properties":{"field":{"type":"string"},"equals":{"type":["string","number","boolean"]}},"required":["field","equals"],"additionalProperties":false},"description":{"type":"string","maxLength":500}},"required":["key","label","type"],"additionalProperties":false}},"delivery":{"default":{"mode":"sandbox","url":""},"type":"object","properties":{"mode":{"type":"string","enum":["sandbox","webhook","email","both"]},"url":{"default":"","type":"string","maxLength":2000},"email":{"type":"object","properties":{"to":{"minItems":1,"maxItems":10,"type":"array","items":{"type":"string","format":"email","pattern":"^(?:[A-Za-z0-9_'+\\-]+\\.)*[A-Za-z0-9_'+\\-]*[A-Za-z0-9_+-]@(?:[A-Za-z0-9][A-Za-z0-9\\-]*\\.)+[A-Za-z]{2,}$"}},"cc":{"default":[],"maxItems":10,"type":"array","items":{"type":"string","format":"email","pattern":"^(?:[A-Za-z0-9_'+\\-]+\\.)*[A-Za-z0-9_'+\\-]*[A-Za-z0-9_+-]@(?:[A-Za-z0-9][A-Za-z0-9\\-]*\\.)+[A-Za-z]{2,}$"}},"subject":{"default":"Nuova richiesta · {{client_name}}","type":"string","minLength":1,"maxLength":250,"pattern":"^[^\\r\\n]+$"},"introduction":{"default":"","type":"string","maxLength":3000},"aiSummary":{"default":false,"type":"boolean"}},"required":["to"]}},"required":["mode"]},"transfer":{"type":"object","properties":{"to":{"type":"string","pattern":"^\\+[1-9]\\d{6,14}$"},"when":{"type":"string","minLength":3,"maxLength":500},"hours":{"type":"object","properties":{"days":{"minItems":1,"maxItems":7,"type":"array","items":{"type":"integer","minimum":1,"maximum":7}},"from":{"type":"string","pattern":"^([01]\\d|2[0-3]):[0-5]\\d$"},"to":{"type":"string","pattern":"^([01]\\d|2[0-3]):[0-5]\\d$"}},"required":["days","from","to"],"additionalProperties":false},"announcement":{"type":"string","minLength":3,"maxLength":200},"musicUrl":{"type":"string","maxLength":500,"pattern":"^https:\\/\\/\\S+$"}},"required":["to"],"additionalProperties":false},"mcp":{"type":"object","properties":{"url":{"type":"string","maxLength":500,"pattern":"^https:\\/\\/\\S+$"},"tools":{"maxItems":20,"type":"array","items":{"type":"string","pattern":"^[A-Za-z_][A-Za-z0-9_.-]{0,63}$"}}},"required":["url"],"additionalProperties":false},"recording":{"type":"boolean"},"greeting":{"type":"string","minLength":10,"maxLength":1000},"review":{"default":"on_issues","type":"string","enum":["on_issues","always","never"]}},"required":["type","name","persona","instructions","greeting"],"additionalProperties":false},{"type":"object","properties":{"type":{"type":"string","const":"outbound"},"name":{"type":"string","minLength":2,"maxLength":100},"persona":{"type":"string","minLength":1,"maxLength":80},"language":{"default":"it","type":"string","enum":["it","en"]},"model":{"type":"string","enum":["gpt-live-1","gemini-3.8-live"]},"voice":{"type":"string","enum":["alloy","ash","ballad","beacon","bossa","cedar","cinder","coral","delta","echo","gleam","marin","meridian","quartz","ripple","sage","shimmer","stone","tempo","verse","vesper","willow","Achernar","Achird","Algenib","Algieba","Alnilam","Aoede","Autonoe","Callirrhoe","Charon","Despina","Enceladus","Erinome","Fenrir","Gacrux","Iapetus","Kore","Laomedeia","Leda","Orus","Puck","Pulcherrima","Rasalgethi","Sadachbia","Sadaltager","Schedar","Sulafat","Umbriel","Vindemiatrix","Zephyr","Zubenelgenubi"]},"customVoiceId":{"type":"string","pattern":"^voice_[A-Za-z0-9_-]+$"},"instructions":{"type":"string","minLength":10,"maxLength":12000},"result":{"default":[],"maxItems":40,"type":"array","items":{"type":"object","properties":{"key":{"type":"string","pattern":"^[a-z][a-z0-9_]{0,49}$"},"label":{"type":"string","minLength":1,"maxLength":100},"type":{"type":"string","enum":["text","number","boolean","select","date","phone","email"]},"required":{"default":false,"type":"boolean"},"options":{"default":[],"maxItems":30,"type":"array","items":{"type":"string","minLength":1,"maxLength":100}},"when":{"type":"object","properties":{"field":{"type":"string"},"equals":{"type":["string","number","boolean"]}},"required":["field","equals"],"additionalProperties":false},"description":{"type":"string","maxLength":500}},"required":["key","label","type"],"additionalProperties":false}},"delivery":{"default":{"mode":"sandbox","url":""},"type":"object","properties":{"mode":{"type":"string","enum":["sandbox","webhook","email","both"]},"url":{"default":"","type":"string","maxLength":2000},"email":{"type":"object","properties":{"to":{"minItems":1,"maxItems":10,"type":"array","items":{"type":"string","format":"email","pattern":"^(?:[A-Za-z0-9_'+\\-]+\\.)*[A-Za-z0-9_'+\\-]*[A-Za-z0-9_+-]@(?:[A-Za-z0-9][A-Za-z0-9\\-]*\\.)+[A-Za-z]{2,}$"}},"cc":{"default":[],"maxItems":10,"type":"array","items":{"type":"string","format":"email","pattern":"^(?:[A-Za-z0-9_'+\\-]+\\.)*[A-Za-z0-9_'+\\-]*[A-Za-z0-9_+-]@(?:[A-Za-z0-9][A-Za-z0-9\\-]*\\.)+[A-Za-z]{2,}$"}},"subject":{"default":"Nuova richiesta · {{client_name}}","type":"string","minLength":1,"maxLength":250,"pattern":"^[^\\r\\n]+$"},"introduction":{"default":"","type":"string","maxLength":3000},"aiSummary":{"default":false,"type":"boolean"}},"required":["to"]}},"required":["mode"]},"transfer":{"type":"object","properties":{"to":{"type":"string","pattern":"^\\+[1-9]\\d{6,14}$"},"when":{"type":"string","minLength":3,"maxLength":500},"hours":{"type":"object","properties":{"days":{"minItems":1,"maxItems":7,"type":"array","items":{"type":"integer","minimum":1,"maximum":7}},"from":{"type":"string","pattern":"^([01]\\d|2[0-3]):[0-5]\\d$"},"to":{"type":"string","pattern":"^([01]\\d|2[0-3]):[0-5]\\d$"}},"required":["days","from","to"],"additionalProperties":false},"announcement":{"type":"string","minLength":3,"maxLength":200},"musicUrl":{"type":"string","maxLength":500,"pattern":"^https:\\/\\/\\S+$"}},"required":["to"],"additionalProperties":false},"mcp":{"type":"object","properties":{"url":{"type":"string","maxLength":500,"pattern":"^https:\\/\\/\\S+$"},"tools":{"maxItems":20,"type":"array","items":{"type":"string","pattern":"^[A-Za-z_][A-Za-z0-9_.-]{0,63}$"}}},"required":["url"],"additionalProperties":false},"recording":{"type":"boolean"},"opening":{"type":"string","minLength":10,"maxLength":500},"inputs":{"default":[],"maxItems":20,"type":"array","items":{"type":"object","properties":{"key":{"type":"string","pattern":"^[a-z][a-z0-9_]{0,49}$"},"label":{"type":"string","minLength":1,"maxLength":100},"type":{"type":"string","enum":["text","number","boolean","select","date","phone","email"]},"required":{"default":false,"type":"boolean"},"options":{"default":[],"maxItems":30,"type":"array","items":{"type":"string","minLength":1,"maxLength":100}},"when":{"type":"object","properties":{"field":{"type":"string"},"equals":{"type":["string","number","boolean"]}},"required":["field","equals"],"additionalProperties":false},"description":{"type":"string","maxLength":500}},"required":["key","label","type"],"additionalProperties":false}},"calling":{"default":{"identityCheck":true,"hours":{"days":[1,2,3,4,5,6],"from":"09:00","to":"20:00"},"maxAttempts":3,"autoCallback":true},"type":"object","properties":{"callerId":{"type":"string","pattern":"^\\+[1-9]\\d{6,14}$"},"identityCheck":{"default":true,"type":"boolean"},"hours":{"default":{"days":[1,2,3,4,5,6],"from":"09:00","to":"20:00"},"type":"object","properties":{"days":{"default":[1,2,3,4,5,6],"minItems":1,"maxItems":7,"type":"array","items":{"type":"integer","minimum":1,"maximum":7}},"from":{"default":"09:00","type":"string","pattern":"^([01]\\d|2[0-3]):[0-5]\\d$"},"to":{"default":"20:00","type":"string","pattern":"^([01]\\d|2[0-3]):[0-5]\\d$"}},"additionalProperties":false},"maxAttempts":{"default":3,"type":"integer","minimum":1,"maximum":5},"autoCallback":{"default":true,"type":"boolean"}},"additionalProperties":false},"review":{"default":"never","type":"string","enum":["on_issues","always","never"]}},"required":["type","name","persona","instructions","opening"],"additionalProperties":false}]},"AgentField":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"key":{"type":"string","pattern":"^[a-z][a-z0-9_]{0,49}$"},"label":{"type":"string","minLength":1,"maxLength":100},"type":{"type":"string","enum":["text","number","boolean","select","date","phone","email"]},"required":{"default":false,"type":"boolean"},"options":{"default":[],"maxItems":30,"type":"array","items":{"type":"string","minLength":1,"maxLength":100}},"when":{"type":"object","properties":{"field":{"type":"string"},"equals":{"type":["string","number","boolean"]}},"required":["field","equals"],"additionalProperties":false},"description":{"type":"string","maxLength":500}},"required":["key","label","type"],"additionalProperties":false},"AgentResource":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"object":{"const":"agent"},"type":{"enum":["inbound","outbound"]},"name":{"type":"string"},"client":{"type":"object"},"revision":{"type":"integer","description":"Draft revision, required to save or publish"},"version":{"type":["integer","null"],"description":"Latest published version"},"status":{"enum":["draft","published","archived"]},"unpublished_changes":{"type":"boolean"},"draft":{"$ref":"#/components/schemas/Agent"},"published":{"oneOf":[{"$ref":"#/components/schemas/Agent"},{"type":"null"}]},"numbers":{"type":"array","items":{"type":"object"}},"mcp_token_set":{"type":"boolean","description":"Whether a bearer token for the agent's MCP server is stored (never returned)"}}},"CallRequest":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"agent":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},"client":{"type":"string","minLength":1,"maxLength":100},"purpose":{"type":"string","pattern":"^[a-z][a-z0-9_]{0,49}$"},"to":{"type":"string","pattern":"^\\+[1-9]\\d{6,14}$"},"inputs":{"type":"object","propertyNames":{"type":"string"},"additionalProperties":{"anyOf":[{"type":"string","maxLength":500},{"type":"number"},{"type":"boolean"}]}},"variables":{"type":"object","propertyNames":{"type":"string"},"additionalProperties":{"anyOf":[{"type":"string","maxLength":500},{"type":"number"},{"type":"boolean"}]}},"reference":{"type":"string","maxLength":200},"callback_url":{"type":"string","maxLength":2000},"scheduled_at":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"max_attempts":{"type":"integer","minimum":1,"maximum":5}},"required":["to"]},"CampaignRequest":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"agent":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},"name":{"type":"string","minLength":1,"maxLength":200},"contacts":{"minItems":1,"maxItems":5000,"type":"array","items":{"type":"object","properties":{"to":{"type":"string"},"inputs":{"type":"object","propertyNames":{"type":"string"},"additionalProperties":{"anyOf":[{"type":"string","maxLength":500},{"type":"number"},{"type":"boolean"}]}},"reference":{"type":"string","maxLength":200}},"required":["to"]}},"scheduled_at":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"max_attempts":{"type":"integer","minimum":1,"maximum":5},"max_concurrent":{"type":"integer","minimum":1,"maximum":20},"callback_url":{"type":"string","maxLength":2000}},"required":["agent","contacts"]},"Call":{"type":"object","description":"A call in either direction. Outbound calls exist from the moment they are queued.","properties":{"id":{"type":"string","format":"uuid"},"object":{"const":"call"},"direction":{"enum":["inbound","outbound"]},"livemode":{"type":"boolean"},"agent":{"type":["object","null"],"properties":{"id":{"type":"string"},"version":{"type":["integer","null"]},"name":{"type":["string","null"]}}},"client":{"type":"object","properties":{"id":{"type":"string"},"external_id":{"type":["string","null"]}}},"campaign_id":{"type":["string","null"]},"reference":{"type":["string","null"]},"to":{"type":["string","null"]},"from":{"type":["string","null"]},"inputs":{"type":"object"},"status":{"enum":["queued","dialing","in_progress","processing","needs_review","completed","failed","cancelled"]},"outcome":{"type":["string","null"],"enum":["completed","callback_requested","wrong_person","refused","do_not_call","hung_up","transferred","no_answer","busy","voicemail","suppressed","invalid_number","failed","cancelled",null]},"attempts":{"type":"integer"},"max_attempts":{"type":"integer"},"scheduled_at":{"type":["string","null"],"format":"date-time"},"next_attempt_at":{"type":["string","null"],"format":"date-time"},"answered_at":{"type":["string","null"],"format":"date-time"},"ended_at":{"type":["string","null"],"format":"date-time"},"duration_seconds":{"type":["integer","null"]},"callback_at":{"type":["string","null"],"format":"date-time"},"transfer":{"type":["object","null"],"description":"Set when the agent handed the call to the operator number of its transfer settings.","properties":{"to":{"type":"string"},"status":{"enum":["requested","dialing","answered","no_answer","busy","failed"]},"requested_at":{"type":["string","null"],"format":"date-time"},"ended_at":{"type":["string","null"],"format":"date-time"},"duration_seconds":{"type":["integer","null"],"description":"Time spent with the operator"}}},"ai_disclosed":{"type":["boolean","null"],"description":"Whether the agent said it is an AI in its first words (EU AI Act transparency); null when it never spoke"},"recording":{"type":["object","null"],"description":"The call's audio when the agent records calls (recording: true): a mono 8 kHz WAV, served to whoever may see the call","properties":{"url":{"type":"string"}}},"anonymized_at":{"type":["string","null"],"format":"date-time","description":"When the call's personal data was anonymised: 24 months after the call, the number, transcript, data, recording and sent payloads are removed"},"tool_calls":{"type":"array","description":"Calls the agent made to the tools of its MCP server during the conversation","items":{"type":"object","properties":{"name":{"type":"string"},"status":{"enum":["ok","error","confirmation_required","timeout","unknown_tool","limit"]},"arguments":{"type":"object"},"result":{"type":["string","null"]},"duration_ms":{"type":["integer","null"]},"at":{"type":["string","null"],"format":"date-time"}}}},"result":{"type":["object","null"],"properties":{"data":{"type":"object","description":"Values of the agent's result fields"},"issues":{"type":"array","items":{"type":"string"}},"summary":{"type":["string","null"]},"sentiment":{"type":["object","null"],"description":"The caller's sentiment, read from their words in the transcript (never from the voice). Null when the person did not speak or the call could not be analysed.","properties":{"label":{"type":"string","enum":["negative","neutral","positive"]},"score":{"type":"integer","minimum":-2,"maximum":2,"description":"Whole call: -2 very negative … 2 very positive"},"start":{"type":"integer","minimum":-2,"maximum":2},"end":{"type":"integer","minimum":-2,"maximum":2},"trend":{"type":"string","enum":["improving","stable","worsening"]},"emotions":{"type":"array","maxItems":3,"items":{"type":"object","properties":{"type":{"type":"string","enum":["frustration","anger","anxiety","confusion","satisfaction","gratitude"]},"intensity":{"type":"string","enum":["low","medium","high"]},"evidence":{"type":"string","description":"The caller's own words that show it"}}}}}}}},"retry_of":{"type":["string","null"]},"error":{"type":["string","null"]},"created_at":{"type":["string","null"],"format":"date-time"}}},"Campaign":{"type":"object","properties":{"id":{"type":"string"},"object":{"const":"campaign"},"name":{"type":"string"},"status":{"enum":["active","paused","cancelled","completed"]},"calls":{"type":"object","properties":{"total":{"type":"integer"},"by_status":{"type":"object"},"by_outcome":{"type":"object"}}}}},"Event":{"type":"object","properties":{"id":{"type":"string"},"type":{"enum":["call.completed","call.attempt_failed"]},"version":{"const":"2"},"livemode":{"type":"boolean"},"created_at":{"type":"string","format":"date-time"},"partner_id":{"type":"string"},"call":{"$ref":"#/components/schemas/Call"}}},"Error":{"type":"object","properties":{"error":{"type":"object","required":["code","message"],"properties":{"code":{"type":"string","description":"Stable, machine-readable code"},"message":{"type":"string"},"details":{}}}}}}}}