POST
/
calls
curl --request POST \
  --url https://api.prod.usesimple.ai/api/v1/calls \
  --header 'Authorization: <api-key>' \
  --header 'Content-Type: application/json' \
  --data '{
  "to_number": "+12345678900",
  "from_number_id": "123e4567-e89b-12d3-a456-426614174000",
  "record": false,
  "language": "en",
  "prompt": "Hello, I'\''m calling to confirm your appointment",
  "boost_keywords": [
    "appointment",
    "schedule",
    "morning"
  ],
  "agent_id": "123e4567-e89b-12d3-a456-426614174000",
  "params": {
    "appointment_type": "morning",
    "customer_id": "123456"
  },
  "analyzers": [
    {
      "prompt": "<string>",
      "title": "<string>",
      "output_config": {
        "type": "string",
        "properties": {}
      }
    }
  ]
}'
{
  "success": true,
  "status": "<string>",
  "uuid": "<string>",
  "record": true,
  "language": "en",
  "answered_by": "voicemail",
  "analyzers": [
    {
      "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
      "prompt": "<string>",
      "output_config": {
        "type": "string",
        "properties": {}
      }
    }
  ],
  "analysis_results": [
    {
      "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
      "analyzer_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
      "prompt": "<string>",
      "output_config": {},
      "result": {}
    }
  ]
}

The simplest way to use Simple AI is to use the create-call endpoint with just a prompt and an array of tools. If you need more control you shoudl use “agents”.

Authorizations

Authorization
string
header
required

Body

application/json

Request to initiate an AI phone call

to_number
string
required

The phone number to call in E.164 format

Example:

"+12345678900"

prompt
string | null
required

The prompt to use for the AI call. Required if agent_id is not provided

Example:

"Hello, I'm calling to confirm your appointment"

from_number_id
string

The UUID of the phone number to use for the outbound call. If not provided, a phone number will be automatically selected.

Example:

"123e4567-e89b-12d3-a456-426614174000"

record
boolean
default:false

Whether to record the call or not

language
enum<string>

The language to use for the call - English (en) or Spanish (es)

Available options:
en,
es,
ar
boost_keywords
string[] | null

Keywords to emphasize during the conversation

Example:
["appointment", "schedule", "morning"]
agent_id
string | null

ID of the pre-configured agent to handle the call. Required if prompt is not provided. Cannot be used together with analyzers - use the agent's analyzers instead.

Example:

"123e4567-e89b-12d3-a456-426614174000"

params
object | null

Additional parameters to pass to the call. These will be subtituted into the prompt for all keys with {{params.key}}

Example:
{
  "appointment_type": "morning",
  "customer_id": "123456"
}
analyzers
object[] | null

List of analyzers to run after the call. Can only be provided when agent_id is not provided. If using an agent, use the agent's analyzers instead.

Response

200
application/json
Successful Response
success
boolean
required
status
string
required
uuid
string
required
language
enum<string>
required
Available options:
en,
es,
ar
record
boolean
answered_by
enum<string>

Indicates how the call was answered - by a human, voicemail, or if there was no answer

Available options:
voicemail,
human,
no_answer,
unknown
analyzers
object[]

List of analyzers configured for this call

analysis_results
object[]

Results from analyzers that have completed