Skip to main content
PATCH
Update agent

Authorizations

Authorization
string
header
required

Your Yappr API key (e.g. ypr_live_...). Generate one in the dashboard under Settings → API Keys.

Path Parameters

id
string<uuid>
required

Body

application/json
name
string
description
string
system_prompt
string
flow_config
object

Replace the agent's flow graph (only valid when type='flow'). Each successful update writes a new flow_versions row, deduped by SHA-256 of the canonical JSON. type itself is immutable and rejected if present in the body.

voice
enum<string>

The persona the agent speaks in, and the only thing that selects between Yappr's two voice families — there is no separate engine field, and engine / engine_voice are rejected if you send them. Keren, Eitan, Hila, Ido, Boaz, Tali, Erez, Efrat are the second family, available to every workspace. Agents on these voices handle their own turn-taking and expressiveness, so temperature, vad_stop_secs, vad_start_secs and vad_confidence are rejected on them, and they cannot be used on a type='flow' agent. Any other name returns 400 listing every voice you may use. Naming a voice from the other family MOVES the agent onto it. The move is lossless in both directions: the first family's voice is kept aside while the agent is on the second, so switching back restores it.

Available options:
Michal,
Yonatan,
David,
Rachel,
Gil,
Noa,
Maya,
Adam,
Shira,
Avigail,
Amir,
Liat,
Omer,
Tamar,
Tom,
Benny,
Nir,
Natan,
Yael,
Dvora,
Yosef,
Shir,
Anat,
Ariel,
Roi,
Shlomo,
Dana,
Alon,
Ruth,
Yuval,
Keren,
Eitan,
Hila,
Ido,
Boaz,
Tali,
Erez,
Efrat
background_sound
enum<string> | null

Ambient background sound mixed under the agent's voice during calls. Null means silent (default).

Available options:
call_center,
open_office,
cafe,
outdoor
background_sound_volume
number
default:0.3

Volume of the background sound, 0.0–0.6. Capped to protect turn-taking.

Required range: 0 <= x <= 0.6
language
enum<string>
Available options:
he,
en
temperature
number
Required range: 0 <= x <= 2
greeting_message
string | null
agent_speaks_first
boolean
is_active
boolean
lead_memory_enabled
boolean
vad_stop_secs
number
Required range: 0.05 <= x <= 5
vad_start_secs
number
Required range: 0.05 <= x <= 2
vad_confidence
number
Required range: 0 <= x <= 1
silence_timeout_secs
number
Required range: 10 <= x <= 900
max_continuous_speech_secs
number
Required range: 0 <= x <= 300
max_call_duration_secs
number
Required range: 0 <= x <= 3600
webhook_url
string<uri> | null
webhook_events
enum<string>[]
Available options:
call.started,
call.answered,
call.ended,
call.failed,
call.no_answer,
call.dnc_blocked,
transcript.ready,
call.analyzed
webhook_headers
object | null

Custom HTTP headers sent with every webhook delivery for this agent (e.g. an auth token). Flat name → string-value map, or null to clear. Headers that would override request routing or HTTP framing (Host, Content-Length, Transfer-Encoding, Connection, Expect, Keep-Alive, TE, Trailer, Upgrade, Proxy-*) are rejected with 400.

Example:

Response

Updated agent

id
string<uuid>
name
string
type
enum<string>
default:prompt

prompt (default, legacy): a single system_prompt drives the call; the LLM decides when to call attached tools. flow: the call is driven by a flow_config graph of conversation, tool-call, and routing nodes. type is immutable post-create — to change types, create a new agent.

Available options:
prompt,
flow
flow_config
object | null

The flow graph. Required when type='flow', must be omitted/null when type='prompt'.

system_prompt
string
description
string | null
voice
enum<string>

The persona the agent speaks in, and the only thing that selects between Yappr's two voice families — there is no separate engine field, and engine / engine_voice are rejected if you send them. Keren, Eitan, Hila, Ido, Boaz, Tali, Erez, Efrat are the second family, available to every workspace. Agents on these voices handle their own turn-taking and expressiveness, so temperature, vad_stop_secs, vad_start_secs and vad_confidence are rejected on them, and they cannot be used on a type='flow' agent. Any other name returns 400 listing every voice you may use. Always the name the agent actually speaks in, whichever family it is on.

Available options:
Michal,
Yonatan,
David,
Rachel,
Gil,
Noa,
Maya,
Adam,
Shira,
Avigail,
Amir,
Liat,
Omer,
Tamar,
Tom,
Benny,
Nir,
Natan,
Yael,
Dvora,
Yosef,
Shir,
Anat,
Ariel,
Roi,
Shlomo,
Dana,
Alon,
Ruth,
Yuval,
Keren,
Eitan,
Hila,
Ido,
Boaz,
Tali,
Erez,
Efrat
background_sound
enum<string> | null

Ambient background sound mixed under the agent's voice during calls. Null means silent (default).

Available options:
call_center,
open_office,
cafe,
outdoor
background_sound_volume
number
default:0.3

Volume of the background sound, 0.0–0.6. Capped to protect turn-taking.

Required range: 0 <= x <= 0.6
language
enum<string>
Available options:
he,
en
temperature
number
Required range: 0 <= x <= 2
greeting_message
string | null
agent_speaks_first
boolean
vad_stop_secs
number
default:0.5

Seconds of silence before VAD confirms speech has stopped

Required range: 0.05 <= x <= 5
vad_start_secs
number
default:0.2

Seconds of speech before VAD confirms speech has started

Required range: 0.05 <= x <= 2
vad_confidence
number
default:0.7

Minimum confidence threshold for voice detection

Required range: 0 <= x <= 1
silence_timeout_secs
number
default:60

Seconds of caller silence before auto-hangup. Prevents idle calls wasting credits.

Required range: 10 <= x <= 900
max_continuous_speech_secs
number
default:120

Max seconds one party can speak non-stop before auto-hangup. Catches answering machines. 0 = disabled.

Required range: 0 <= x <= 300
max_call_duration_secs
number
default:600

Hard cap on total call duration regardless of activity. 0 = no cap of the agent's own; the platform still ends the call after 65 minutes (3900 s), with the disconnect reason Platform call limit reached.

Required range: 0 <= x <= 3600
lead_memory_enabled
boolean
default:true

When true, the matched lead's long-term memory context is injected into the system prompt at call time.

is_active
boolean
webhook_url
string<uri> | null
webhook_events
enum<string>[]

Events posted to webhook_url as {event, timestamp, agent_id, company_id, call_id, data}. call.failed and call.no_answer carry data.hangup_cause when the cause is known. For a call from a number in your own Telnyx account that Telnyx refused while it rang, call.failed has data.hangup_cause:

  • carrier_rejected — Telnyx refused the call (SIP 401, 403 or 407).
  • carrier_number_invalid — Telnyx could not route the number called (SIP 404, 484 or 604).

The SIP code is not in the webhook; the carrier account keeps the last one in last_error.sip_code. One Telnyx refused before it rang sends no webhook when POST /calls was placing it (the request answers 422); from the queue it sends call.failed with data.error_reason instead.

Available options:
call.started,
call.answered,
call.ended,
call.failed,
call.no_answer,
call.dnc_blocked,
transcript.ready,
call.analyzed
webhook_headers
object | null

Custom HTTP headers sent with every webhook delivery for this agent (e.g. an auth token). Flat name → string-value map, or null to clear. Headers that would override request routing or HTTP framing (Host, Content-Length, Transfer-Encoding, Connection, Expect, Keep-Alive, TE, Trailer, Upgrade, Proxy-*) are rejected with 400.

Example:
extraction_parameters
object[]

AI extraction parameters — after each call, values are extracted from the transcript and included in the call.analyzed webhook payload (and stored on the call log).

created_at
string<date-time>
updated_at
string<date-time>