@omnidim-ai/mcp-server 0.20.1 → 0.21.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/src/index.ts CHANGED
@@ -5,10 +5,11 @@
5
5
  import { readApiKey } from "./credentials.js";
6
6
  import { isInteractive, printInteractiveHelp, requestIdNote, startupBanner, trimLargeResponse, USER_AGENT } from "./helpers.js";
7
7
  import { beginSession, emitSessionCrash, emitSessionEnd, endSession, recordToolError, recordToolResult } from "./telemetry.js";
8
- import { registerProcedures } from "./procedures.js";
8
+ import { READ_GUIDE_INSTRUCTION, addGuideTool, callGuideTool, isGuideTool, registerProcedures } from "./procedures.js";
9
9
  import { keepReadOnlyTools, readOnlyMode, toolAnnotations } from "./tool-annotations.js";
10
10
  import { addShowWorkflow, toolMeta } from "./workflow-canvas.js";
11
11
  import { addDocsTools, callDocsTool, isDocsTool } from "./docs-tools.js";
12
+ import { flatInputSchema, nestBodyArgs } from "./flat-args.js";
12
13
  import { notifyUpdates } from "./update_notifier.js";
13
14
 
14
15
 
@@ -51,7 +52,7 @@ interface McpToolDefinition {
51
52
  * Server configuration
52
53
  */
53
54
  export const SERVER_NAME = "OmniDimension";
54
- export const SERVER_VERSION = "0.20.1"; // x-release-please-version
55
+ export const SERVER_VERSION = "0.21.1"; // x-release-please-version
55
56
  // Base URL for the API. Pinned to production; not env-overridable.
56
57
  export const API_BASE_URL = "https://omnidim.io/api/v1";
57
58
 
@@ -73,7 +74,9 @@ Conventions:
73
74
  - For details on one item, call get<Resource>(id) after listing.
74
75
  - Dispatching calls: run listPhoneNumbers first. If the account has numbers, pass the chosen one as from_number_id. If it has none, omit from_number_id and the platform's default number is used. Never guess a from_number_id.
75
76
  - Configure OMNIDIM_API_KEY in your MCP client config to authenticate.
76
- - API reference: https://docs.omnidim.io`;
77
+ - API reference: https://docs.omnidim.io
78
+
79
+ ${READ_GUIDE_INSTRUCTION}`;
77
80
 
78
81
  const server = new Server(
79
82
  { name: SERVER_NAME, version: SERVER_VERSION },
@@ -90,18 +93,15 @@ const toolDefinitionMap: Map<string, McpToolDefinition> = new Map([
90
93
 
91
94
  ["createSession", {
92
95
  name: "createSession",
93
- description: `Create a voice Session: a short-lived, single-conversation
94
- reservation that lets a client hold a live voice chat with your
95
- agent. This is step 1 of 2. Creating the Session does not start any
96
- audio on its own; it returns a \`ws_url\` that a client then connects
97
- to over WebSocket to actually talk.
98
-
99
- Call this endpoint from your server with your API key, and return
100
- only the \`ws_url\` to your client. The API key must never reach the
101
- browser. The \`ws_url\` is the only thing the client needs, and it is
102
- safe to hand out because it is single-use and expires. For how to
103
- connect and talk, see "Connect the client and talk" below the
104
- request details.
96
+ description: `Create a short-lived voice session and get a \`ws_url\` for one conversation.
97
+
98
+ This is step 1 of 2. Creating the session starts no audio. The client then
99
+ connects to \`ws_url\` over WebSocket to talk.
100
+
101
+ Call this endpoint from your server with your API key. Return only \`ws_url\`
102
+ to your client, and never the API key. The \`ws_url\` is single-use and
103
+ expires, so it is safe to hand to your client. For how to connect and talk,
104
+ see "Connect the client and talk" below the request details.
105
105
 
106
106
  (Tags: Sessions)`,
107
107
  inputSchema: {"type":"object","properties":{"requestBody":{"type":"object","required":["agent_id","type"],"properties":{"agent_id":{"type":"number","description":"ID of the agent the session talks to."},"type":{"type":"string","default":"voice","enum":["voice"],"description":"The session type. Only `voice` is supported."},"custom_variables":{"type":"object","additionalProperties":true,"description":"Per-session variables that personalize the conversation.\nSet server-side, so visitors cannot tamper with them.\nTwo reserved keys are read as instructions for this session\nand never reach the agent: `__languages` and\n`__post_call_actions`.\n","properties":{"__languages":{"oneOf":[{"type":"array","items":{"type":"string"}},{"type":"string"}],"description":"Languages this session runs in, replacing the agent's\nconfigured list. The first entry is the language the\nvisitor is greeted in. Send an array, or a pipe-separated\nstring such as `Hindi|English`.\n"},"__post_call_actions":{"allOf":[{"type":"object","additionalProperties":true,"description":"Post-call actions: email, webhook, Omni CRM, WhatsApp, workflow, Google Sheets, Slack, Salesforce, HubSpot or Zoho Bigin. On an agent, add them one at a time with addPostCallAction instead. Full shape: https://docs.omnidim.io/docs/per-call-post-call-actions"}],"description":"Post-call actions for this session only, in the same shape\nas `post_call_actions` on agent create. Email and webhook\nonly. They replace the agent's own post-call actions for\nthis session. Items that cannot be used are skipped and\nlisted in `post_call_actions_ignored`.\n"}}},"metadata":{"type":"object","additionalProperties":true,"description":"Key-value pairs stored on the session for your own\ntracking (e.g. CRM or lead IDs). Not shared with the\nagent; echoed back as `metadata` in the post-call\nwebhook so you can correlate results with your records.\n"}},"description":"The JSON request body."}},"required":["requestBody"]},
@@ -128,26 +128,22 @@ request details.
128
128
  }],
129
129
  ["createAgent", {
130
130
  name: "createAgent",
131
- description: `Create a new agent with the provided configuration. The full
132
- config supports transcriber, model, voice, web search, transfer,
133
- end-call conditions, post-call actions (email, webhook, Omni CRM,
134
- Cloud WhatsApp, or a workflow),
135
- ambient background track, initial ringing sound, and multilingual support.
136
-
137
- Leave out \`model\`, \`transcriber\` and \`voice\` unless you need a specific
138
- one: the agent then gets your organization's default language model,
139
- transcriber and voice, which always work. To choose one, pick from the
140
- LLM, STT and TTS providers lists, which show only the models your
141
- organization can use. Any other model is refused with a message naming
142
- the default to use instead.
143
-
144
- > **Voicemail detection is an access-gated feature** that we turn on per
145
- account. If it isn't enabled for yours yet,
146
- [request access](https://omnidim.io/contact-us?reason=product&lock=1)
147
- before configuring the \`voicemail\` object.
131
+ description: `Create an agent from a name and a context. Every other setting is optional.
132
+
133
+ Optional settings: transcriber, model, voice, web search, transfer,
134
+ end-call conditions, post-call actions (email, webhook, Omni CRM, Cloud
135
+ WhatsApp, or a workflow), ambient background track, initial ringing
136
+ sound and multilingual support.
137
+
138
+ Leave out \`model\`, \`transcriber\` and \`voice\` to get your organization's
139
+ defaults, which always work. To pick one, use the LLM, STT or TTS provider
140
+ list: it shows only the models your organization can use. Any other model is
141
+ refused, and the error names the default to use.
142
+
143
+ > **Voicemail detection is access-gated** and turned on per account. If it is off for yours, [request access](https://omnidim.io/contact-us?reason=product&lock=1) before you configure the \`voicemail\` object.
148
144
 
149
145
  (Tags: Agents)`,
150
- inputSchema: {"type":"object","properties":{"Idempotency-Key":{"type":"string","maxLength":255,"description":"Your own unique key for this agent, for example a fresh UUID.\nSend the same key when you retry. If the first request already\ncreated the agent, you get that agent back instead of a second\none, so a request that timed out is safe to repeat. The same key\nwith a different request body is refused. Keys are kept for 24\nhours.\n"},"requestBody":{"allOf":[{"type":"object","description":"Agent configuration.","properties":{"name":{"type":"string","description":"Name for the agent.","example":"Customer Support Agent"},"welcome_message":{"type":"string","description":"Initial message the agent will say when answering a call.","example":"Hello! How can I help you today?"},"is_welcome_message_dynamic":{"type":"boolean","description":"When true, the welcome message is treated as a directive the agent uses to generate a tailored greeting for each call, rather than being spoken word for word. When false, the welcome message is spoken exactly as written."},"is_welcome_message_interruption":{"type":"boolean","description":"Allow the caller to interrupt the welcome message. When false, the agent finishes speaking the welcome before listening."},"is_interruption_allowed":{"type":"boolean","description":"Global toggle for whether the caller can interrupt the agent mid-sentence at any point in the call."},"dynamic_variables":{"type":"object","description":"Key/value map used to substitute placeholders in the agent's\nprompt and welcome message at call time. Reference a variable\nin your prompt with `{{variable_name}}`. Useful for\npersonalising the same agent across many calls.\n","additionalProperties":{"type":"string"},"example":{"customer_name":"Jane Doe","order_id":"ORD-12345"}},"context_breakdown":{"type":"array","description":"List of context breakdowns, each containing `title`, `body`, and optional `is_enabled`.","items":{"type":"object","required":["title","body"],"properties":{"title":{"type":"string","description":"Title of the breakdown.","example":"Purpose"},"body":{"type":"string","description":"Body of the breakdown, the detailed prompt content.","example":"This agent helps customers with product inquiries and support issues."},"is_enabled":{"type":"boolean","default":true,"description":"Whether this section is included in the prompt."}}}},"call_type":{"type":"string","enum":["Incoming","Outgoing"],"description":"Call type of the assistant."},"timezone":{"type":"string","description":"IANA timezone for this agent, for example `Asia/Kolkata`. Sets the local date and time the agent works with during calls. If not set, the account timezone is used as fallback. Pass an empty string to clear it.","example":"America/New_York"},"transcriber":{"type":"object","description":"Configuration for the speech-to-text transcriber.","properties":{"provider":{"type":"string","description":"The speech-to-text provider to use: a `name` from the STT providers list, which returns the ones your organization can use. Leave it out to use your organization's default transcriber.","example":"deepgram_stream"},"model":{"type":"string","description":"Transcription model for the selected provider. For\n`deepgram_stream` this is `nova-3` or `nova-2`; other\nproviders take their own model identifiers.\n","example":"nova-3"},"language":{"type":"string","description":"Language code for the transcriber. Format and supported\nvalues depend on the provider (e.g. `en-US` for Deepgram,\n`hi-IN` for Sarvam). Applies regardless of which\n`provider` is selected.\n","example":"en-US"},"silence_timeout_ms":{"type":"integer","description":"Silence timeout in milliseconds.","example":400},"should_apply_noise_reduction":{"type":"boolean","description":"Reduce background noise on the inbound audio stream before transcription."},"interruption_min_words":{"type":"integer","minimum":1,"description":"Minimum number of words the caller must say before their speech is treated as an interruption.","example":2},"max_call_duration_in_sec":{"type":"integer","minimum":1,"description":"Hard upper bound on call length in seconds. The agent will end the call once this is reached.","example":600},"first_ideal_message":{"type":"string","description":"First nudge spoken when the caller goes silent past the\nidle threshold. Set `is_first_ideal_message_dynamic` to\n`true` to have the LLM regenerate this each time.\n"},"is_first_ideal_message_dynamic":{"type":"boolean","description":"When true, `first_ideal_message` is treated as a prompt and the LLM generates a fresh nudge each call."},"second_ideal_message":{"type":"string","description":"Second nudge spoken if silence continues after the first."},"is_second_ideal_message_dynamic":{"type":"boolean","description":"When true, `second_ideal_message` is treated as a prompt and the LLM generates a fresh nudge each call."},"numerals":{"type":"boolean","description":"Convert numbers from words to digits."},"punctuate":{"type":"boolean","description":"Add punctuation to the transcript."},"smart_format":{"type":"boolean","description":"Apply smart formatting to the transcript."},"diarize":{"type":"boolean","description":"Identify different speakers in the transcript."}}},"model":{"type":"object","description":"Configuration for the language model.","properties":{"model":{"type":"string","description":"The language model to use: a `name` from the LLM providers list, which returns exactly the models your organization can use. Leave it out to use your organization's default model.","example":"gpt-4.1-mini"},"temperature":{"type":"number","minimum":0,"maximum":1,"description":"Controls randomness in the model's output (0.0 to 1.0).","example":0.7}}},"voice":{"type":"object","description":"Configuration for the text-to-speech voice. `provider` and `voice_id` identify the voice together, so send both to change it. `provider` on its own is not accepted, and a `voice_id` on its own leaves the voice as it was. The other fields here apply independently. Leave out `provider` and `voice_id` to use your organization's default voice.","dependentRequired":{"provider":["voice_id"]},"properties":{"provider":{"type":"string","description":"The voice provider to use: the `service` of a voice from the voices list, which returns only voices your organization can use. Send `voice_id` alongside it. We recommend OmniDimension voices (list them with `provider=featured`) and Cartesia voices. An agent created without `voice` gets the platform default, a Cartesia voice, which every account can use.","example":"cartesia"},"voice_id":{"type":"string","description":"The provider's voice identifier, returned in the `name` field of the voices list (not the numeric `id`). Takes effect when `provider` is sent alongside it.","example":"faf0731e-dfb9-4cfc-8119-259a79b27e12"},"speech_speed":{"type":"number","minimum":0.5,"maximum":2,"default":1,"description":"Playback speed multiplier for the agent's voice. 1.0 is normal speed."}}},"web_search":{"type":"object","description":"Configuration for web search capabilities.","properties":{"enabled":{"type":"boolean","description":"Enable or disable web search functionality."},"provider":{"type":"string","enum":["DuckDuckGo","openAI"],"description":"The search provider to use.","example":"DuckDuckGo"}}},"post_call_actions":{"type":"object","additionalProperties":true,"description":"Post-call actions: email, webhook, Omni CRM, WhatsApp, workflow, Google Sheets, Slack, Salesforce, HubSpot or Zoho Bigin. On an agent, add them one at a time with addPostCallAction instead. Full shape: https://docs.omnidim.io/docs/per-call-post-call-actions"},"transfer":{"type":"object","description":"Conditional call transfer to a human agent or another number.","properties":{"enabled":{"type":"boolean"},"transfer_options":{"type":"array","description":"Where to transfer the call and under what condition. The first matching condition wins. In an agent update, sending this list replaces all saved options. Omit it to keep them unchanged, or send an empty array to clear them.","items":{"type":"object","required":["number","transfer_condition","transfer_message"],"properties":{"number":{"type":"string","description":"Primary phone number to transfer to. Include country code with leading `+`.","example":"+15551234567"},"type":{"type":"string","enum":["static","dynamic"],"default":"static","description":"`static` transfers to `number`. `dynamic` lets the agent\npick a number at runtime based on the conversation.\n"},"backup_numbers":{"type":"array","description":"Fallback numbers tried if the primary is unreachable.","items":{"type":"string"}},"transfer_condition":{"type":"string","description":"Natural-language condition that triggers this transfer option.","example":"Transfer if the customer asks to speak with a human."},"transfer_message":{"type":"string","description":"Message the agent says to the caller before executing the transfer.","example":"Please hold while I connect you to one of our agents."}}}}}},"end_call":{"type":"object","description":"Hang up automatically when a condition is met.","properties":{"enabled":{"type":"boolean"},"condition":{"type":"string","description":"Natural-language condition that triggers ending the call. Only evaluated when `enabled` is true.","example":"End the call once the customer's issue is resolved."},"message":{"type":"string","description":"What the agent says before hanging up.","example":"Thank you for contacting us. Have a great day!"},"message_type":{"type":"string","enum":["static","prompt"],"description":"`static` speaks `message` verbatim. `prompt` treats\n`message_prompt` as an LLM instruction and generates a\nfresh closing line each call (useful for matching the\ncaller's language and tone).\n"},"message_prompt":{"type":"string","description":"LLM prompt used to generate the closing line when `message_type` is `prompt`.","example":"End the call politely in the same language the user is speaking."}}},"background_track":{"type":"object","description":"Ambient background noise that plays under the agent's voice.","properties":{"enabled":{"type":"boolean","description":"Whether to mix the ambient track under the agent's audio."},"name":{"type":"string","enum":["call_center","filler","office","office_1","restaurant"],"description":"Ambient track to mix under the agent."},"volume":{"type":"number","minimum":0,"maximum":1,"default":0.2,"description":"Volume level on a 0–1 scale. Default 0.2."},"tts_volume_reduction":{"type":"number","minimum":0,"maximum":1,"description":"Amount to drop the agent's TTS volume while the ambient track plays, on a 0–1 scale. Helps the voice cut through without raising the overall mix."}}},"initial_ringing_sound_enabled":{"type":"boolean","description":"Plays a ringing tone after the call is picked up, until the agent starts speaking."},"voicemail":{"type":"object","description":"Voicemail / answering-machine handling for outbound calls. Set this with the nested object shown here; the agent object returns these values as the flat fields `voicemail_enabled` and `voicemail_message`. Voicemail detection is an access-gated feature. If it isn't enabled for your account, [request access](https://omnidim.io/contact-us?reason=product&lock=1).","properties":{"enabled":{"type":"boolean","description":"Detect voicemail and leave your message instead of speaking to a machine."},"message":{"type":"string","description":"Message to leave when voicemail is detected."}}},"languages":{"type":"array","description":"Languages the agent should support. Pass each language as a display-name string exactly as it appears in the dashboard's language picker. Unrecognized names are skipped.","items":{"type":"string"},"example":["English (India)","Hindi"]}}},{"type":"object","required":["name","context_breakdown"]}],"description":"The JSON request body."}},"required":["requestBody"]},
146
+ inputSchema: {"type":"object","properties":{"Idempotency-Key":{"type":"string","maxLength":255,"description":"Your own unique key for this agent, for example a fresh UUID.\nSend the same key when you retry. If the first request already\ncreated the agent, you get that agent back instead of a second\none, so a request that timed out is safe to repeat. The same key\nwith a different request body is refused. Keys are kept for 24\nhours.\n"},"requestBody":{"allOf":[{"type":"object","description":"Agent configuration.","properties":{"name":{"type":"string","description":"Name for the agent.","example":"Customer Support Agent"},"welcome_message":{"type":"string","description":"Initial message the agent will say when answering a call.","example":"Hello! How can I help you today?"},"is_welcome_message_dynamic":{"type":"boolean","description":"When true, the welcome message is treated as a directive the agent uses to generate a tailored greeting for each call, rather than being spoken word for word. When false, the welcome message is spoken exactly as written."},"is_welcome_message_interruption":{"type":"boolean","description":"Allow the caller to interrupt the welcome message. When false, the agent finishes speaking the welcome before listening."},"is_interruption_allowed":{"type":"boolean","description":"Global toggle for whether the caller can interrupt the agent mid-sentence at any point in the call."},"dynamic_variables":{"type":"object","description":"Key/value map used to substitute placeholders in the agent's\nprompt and welcome message at call time. Reference a variable\nin your prompt with `{{variable_name}}`. Useful for\npersonalising the same agent across many calls.\n","additionalProperties":{"type":"string"},"example":{"customer_name":"Jane Doe","order_id":"ORD-12345"}},"context_breakdown":{"type":"array","description":"The agent's prompt sections, each with `title`, `body` and optional `is_enabled`. Sending them replaces the whole list and rebuilds the prompt from the enabled sections in order: each `title` becomes a `# title` heading on its own line, with its `body` below it, the same layout the dashboard uses. A save without `context_breakdown` leaves the prompt unchanged.","items":{"type":"object","required":["title","body"],"properties":{"title":{"type":"string","description":"Title of the breakdown.","example":"Purpose"},"body":{"type":"string","description":"Body of the breakdown, the detailed prompt content.","example":"This agent helps customers with product inquiries and support issues."},"is_enabled":{"type":"boolean","default":true,"description":"Whether this section is included in the prompt."}}}},"call_type":{"type":"string","enum":["Incoming","Outgoing"],"description":"`Incoming` for an agent that answers calls, `Outgoing` for one that places them, spelled exactly so. Any other value, `incoming` included, saves as `Outgoing` and the response lists it in `warnings`."},"timezone":{"type":"string","description":"IANA timezone for this agent, for example `Asia/Kolkata`. Sets the local date and time the agent works with during calls. If not set, the account timezone is used as fallback. Pass an empty string to clear it.","example":"America/New_York"},"transcriber":{"type":"object","description":"Configuration for the speech-to-text transcriber.","properties":{"provider":{"type":"string","description":"The speech-to-text provider to use: a `name` from the STT providers list, which returns the ones your organization can use. Leave it out to use your organization's default transcriber.","example":"deepgram_stream"},"model":{"type":"string","description":"Transcription model for the selected provider. For\n`deepgram_stream` this is `nova-3` or `nova-2`. Saved only\nfor `deepgram_stream`, `cartesia` and `sarvam`, and only\nwhen `provider` is in the same request.\n","example":"nova-3"},"language":{"type":["string","array"],"items":{"type":"string"},"description":"Language code for the transcriber. Format and supported\nvalues depend on the provider (e.g. `en-US` for Deepgram,\n`hi-IN` for Sarvam). `soniox` takes a list of codes, such as\n`[\"en\", \"hi\"]`, and an empty list detects the language. Saved only when `provider` is in the\nsame request and is `deepgram_stream`, `cartesia`, `sarvam`,\n`azure` or `soniox`.\n","example":"en-US"},"silence_timeout_ms":{"type":"integer","description":"Silence timeout in milliseconds.","example":400},"should_apply_noise_reduction":{"type":"boolean","description":"Reduce background noise on the inbound audio stream before transcription."},"interruption_min_words":{"type":"integer","minimum":1,"description":"Minimum number of words the caller must say before their speech is treated as an interruption.","example":2},"max_call_duration_in_sec":{"type":"integer","minimum":1,"description":"Hard upper bound on call length in seconds. The agent will end the call once this is reached.","example":600},"first_ideal_message":{"type":"string","description":"First nudge spoken when the caller goes silent past the\nidle threshold. Set `is_first_ideal_message_dynamic` to\n`true` to have the LLM regenerate this each time.\n"},"is_first_ideal_message_dynamic":{"type":"boolean","description":"When true, `first_ideal_message` is treated as a prompt and the LLM generates a fresh nudge each call."},"second_ideal_message":{"type":"string","description":"Second nudge spoken if silence continues after the first."},"is_second_ideal_message_dynamic":{"type":"boolean","description":"When true, `second_ideal_message` is treated as a prompt and the LLM generates a fresh nudge each call."},"numerals":{"type":"boolean","description":"Convert numbers from words to digits."},"punctuate":{"type":"boolean","description":"Add punctuation to the transcript."},"smart_format":{"type":"boolean","description":"Apply smart formatting to the transcript."},"diarize":{"type":"boolean","description":"Identify different speakers in the transcript."}}},"model":{"type":"object","description":"Configuration for the language model.","properties":{"model":{"type":"string","description":"The language model to use: a `name` from the LLM providers list, which returns exactly the models your organization can use. Leave it out to use your organization's default model.","example":"gpt-4.1-mini"},"temperature":{"type":"number","minimum":0,"maximum":1,"description":"Controls randomness in the model's output (0.0 to 1.0).","example":0.7}}},"voice":{"type":"object","description":"Configuration for the text-to-speech voice. `provider` and `voice_id` identify the voice together, so send both to change it. `provider` on its own is not accepted, and a `voice_id` on its own leaves the voice as it was. The other fields here apply independently. Leave out `provider` and `voice_id` to use your organization's default voice.","dependentRequired":{"provider":["voice_id"]},"properties":{"provider":{"type":"string","description":"The voice provider to use: the `service` of a voice from the voices list, which returns only voices your organization can use. Send `voice_id` alongside it. We recommend OmniDimension voices (list them with `provider=featured`) and Cartesia voices. An agent created without `voice` gets the platform default, a Cartesia voice, which every account can use.","example":"cartesia"},"voice_id":{"type":"string","description":"The provider's voice identifier, returned in the `name` field of the voices list (not the numeric `id`). Takes effect when `provider` is sent alongside it.","example":"faf0731e-dfb9-4cfc-8119-259a79b27e12"},"speech_speed":{"type":"number","minimum":0.5,"maximum":2,"default":1,"description":"Playback speed multiplier for the agent's voice. 1.0 is normal speed."}}},"web_search":{"type":"object","description":"Configuration for web search capabilities.","properties":{"enabled":{"type":"boolean","description":"Enable or disable web search functionality."},"provider":{"type":"string","enum":["DuckDuckGo","openAI"],"description":"The search provider to use.","example":"DuckDuckGo"}}},"post_call_actions":{"type":"object","additionalProperties":true,"description":"Post-call actions: email, webhook, Omni CRM, WhatsApp, workflow, Google Sheets, Slack, Salesforce, HubSpot or Zoho Bigin. On an agent, add them one at a time with addPostCallAction instead. Full shape: https://docs.omnidim.io/docs/per-call-post-call-actions"},"transfer":{"type":"object","description":"Conditional call transfer to a human agent or another number.","properties":{"enabled":{"type":"boolean"},"transfer_options":{"type":"array","description":"Where to transfer the call and under what condition. The first matching condition wins. In an agent update, sending this list replaces all saved options. Omit it to keep them unchanged, or send an empty array to clear them.","items":{"type":"object","required":["number","transfer_condition","transfer_message"],"properties":{"number":{"type":"string","description":"Primary phone number to transfer to. Include country code with leading `+`.","example":"+15551234567"},"type":{"type":"string","enum":["static","dynamic"],"default":"static","description":"`static` transfers to `number`. `dynamic` lets the agent\npick a number at runtime based on the conversation.\n"},"backup_numbers":{"type":"array","description":"Fallback numbers tried if the primary is unreachable.","items":{"type":"string"}},"transfer_condition":{"type":"string","description":"Natural-language condition that triggers this transfer option.","example":"Transfer if the customer asks to speak with a human."},"transfer_message":{"type":"string","description":"Message the agent says to the caller before executing the transfer.","example":"Please hold while I connect you to one of our agents."}}}}}},"end_call":{"type":"object","description":"Hang up automatically when a condition is met.","properties":{"enabled":{"type":"boolean","description":"Turn ending the call on or off. Leave it out to keep the current setting. `false` also clears `condition` and `message`."},"condition":{"type":"string","description":"Natural-language condition that triggers ending the call. Only evaluated when `enabled` is true.","example":"End the call once the customer's issue is resolved."},"message":{"type":"string","description":"What the agent says before hanging up.","example":"Thank you for contacting us. Have a great day!"},"message_type":{"type":"string","enum":["static","prompt"],"description":"`static` speaks `message` verbatim. `prompt` treats\n`message_prompt` as an LLM instruction and generates a\nfresh closing line each call (useful for matching the\ncaller's language and tone).\n"},"message_prompt":{"type":"string","description":"LLM prompt used to generate the closing line when `message_type` is `prompt`.","example":"End the call politely in the same language the user is speaking."}}},"background_track":{"type":"object","description":"Ambient background noise that plays under the agent's voice.","properties":{"enabled":{"type":"boolean","description":"Whether to mix the ambient track under the agent's audio."},"name":{"type":"string","enum":["call_center","filler","office","office_1","restaurant"],"description":"Ambient track to mix under the agent."},"volume":{"type":"number","minimum":0,"maximum":1,"default":0.2,"description":"Volume level on a 0–1 scale. Default 0.2."},"tts_volume_reduction":{"type":"number","minimum":0,"maximum":1,"description":"Amount to drop the agent's TTS volume while the ambient track plays, on a 0–1 scale. Helps the voice cut through without raising the overall mix."}}},"initial_ringing_sound_enabled":{"type":"boolean","description":"Plays a ringing tone after the call is picked up, until the agent starts speaking."},"voicemail":{"type":"object","description":"Voicemail / answering-machine handling for outbound calls. Set this with the nested object shown here; the agent object returns these values as the flat fields `voicemail_enabled` and `voicemail_message`. Voicemail detection is an access-gated feature. If it isn't enabled for your account, [request access](https://omnidim.io/contact-us?reason=product&lock=1).","properties":{"enabled":{"type":"boolean","description":"Detect voicemail and leave your message instead of speaking to a machine."},"message":{"type":"string","description":"Message to leave when voicemail is detected."}}},"languages":{"type":"array","description":"Languages the agent should support. Pass each language as a display-name string exactly as it appears in the dashboard's language picker. Unrecognized names are skipped, and the request is refused when none is recognized. The order is not kept.","items":{"type":"string"},"example":["English (India)","Hindi"]}}},{"type":"object","required":["name","context_breakdown"]}],"description":"The JSON request body."}},"required":["requestBody"]},
151
147
  method: "post",
152
148
  pathTemplate: "/agents/create",
153
149
  executionParameters: [{"name":"Idempotency-Key","in":"header"}],
@@ -158,7 +154,16 @@ before configuring the \`voicemail\` object.
158
154
  }],
159
155
  ["getAgent", {
160
156
  name: "getAgent",
161
- description: `Get details of a specific agent by ID. The response also includes a \`can_publish\` boolean showing whether [version history](/docs/api-reference/agents/listAgentVersions) is turned on for the agent's organization.
157
+ description: `Get one agent by ID.
158
+
159
+ The response includes \`can_publish\`: whether [version
160
+ history](/docs/api-reference/agents/listAgentVersions) is on for the agent's
161
+ organization.
162
+
163
+ The response uses stored field names, such as \`context_title\` and
164
+ \`voice_external_id\`. \`updateAgent\` takes the names in its own request
165
+ body instead, such as \`context_breakdown[].title\` and \`voice.voice_id\`.
166
+
162
167
  (Tags: Agents)`,
163
168
  inputSchema: {"type":"object","properties":{"agent_id":{"type":"number","description":"The ID of the agent."}},"required":["agent_id"]},
164
169
  method: "get",
@@ -171,13 +176,14 @@ before configuring the \`voicemail\` object.
171
176
  }],
172
177
  ["updateAgent", {
173
178
  name: "updateAgent",
174
- description: `Update an existing agent. Send only the fields you want to change.
179
+ description: `Update an agent. Send only the fields you want to change.
180
+
181
+ \`post_call_actions\` replaces the agent's email, webhook, Omni CRM, Cloud WhatsApp and workflow actions as one set, but only if you send at least one of those types. Google Sheets, Slack, Salesforce, HubSpot and Zoho Bigin actions are replaced only when you send their key. Other actions are kept. If a sent action gives a variable key a new prompt, kept actions with the same key take that prompt too. To change one action alone, use \`/agents/{agent_id}/post-call-actions\`.
175
182
 
176
- \`post_call_actions\` replaces the agent's email, webhook, Omni CRM, Cloud WhatsApp and workflow actions as one set, but only when you send at least one of those types. Google Sheets, Slack, Salesforce, HubSpot and Zoho Bigin actions are replaced only when their key is sent, and kept otherwise. If a sent action gives a variable key a new prompt, kept actions that use the same key take the new prompt too. To add, change or remove one action without touching the others, use \`/agents/{agent_id}/post-call-actions\`.
183
+ > **Voicemail detection is access-gated** and turned on per account. If it is off for yours, [request access](https://omnidim.io/contact-us?reason=product&lock=1) before you configure the \`voicemail\` object.
177
184
 
178
- > **Voicemail detection is an access-gated feature** that we turn on per account. If it isn't enabled for yours yet, [request access](https://omnidim.io/contact-us?reason=product&lock=1) before configuring the \`voicemail\` object below.
179
185
  (Tags: Agents)`,
180
- inputSchema: {"type":"object","properties":{"agent_id":{"type":"number","description":"The ID of the agent."},"requestBody":{"type":"object","description":"Agent configuration.","properties":{"name":{"type":"string","description":"Name for the agent."},"welcome_message":{"type":"string","description":"Initial message the agent will say when answering a call."},"is_welcome_message_dynamic":{"type":"boolean","description":"When true, the welcome message is treated as a directive the agent uses to generate a tailored greeting for each call, rather than being spoken word for word. When false, the welcome message is spoken exactly as written."},"is_welcome_message_interruption":{"type":"boolean","description":"Allow the caller to interrupt the welcome message. When false, the agent finishes speaking the welcome before listening."},"is_interruption_allowed":{"type":"boolean","description":"Global toggle for whether the caller can interrupt the agent mid-sentence at any point in the call."},"dynamic_variables":{"type":"object","description":"Key/value map used to substitute placeholders in the agent's\nprompt and welcome message at call time. Reference a variable\nin your prompt with `{{variable_name}}`. Useful for\npersonalising the same agent across many calls.\n","additionalProperties":{"type":"string"}},"context_breakdown":{"type":"array","description":"List of context breakdowns, each containing `title`, `body`, and optional `is_enabled`.","items":{"type":"object","required":["title","body"],"properties":{"title":{"type":"string","description":"Title of the breakdown."},"body":{"type":"string","description":"Body of the breakdown, the detailed prompt content."},"is_enabled":{"type":"boolean","default":true,"description":"Whether this section is included in the prompt."}}}},"call_type":{"type":"string","enum":["Incoming","Outgoing"],"description":"Call type of the assistant."},"timezone":{"type":"string","description":"IANA timezone for this agent, for example `Asia/Kolkata`. Sets the local date and time the agent works with during calls. If not set, the account timezone is used as fallback. Pass an empty string to clear it."},"transcriber":{"type":"object","description":"Configuration for the speech-to-text transcriber.","properties":{"provider":{"type":"string","description":"The speech-to-text provider to use: a `name` from the STT providers list, which returns the ones your organization can use. Leave it out to use your organization's default transcriber."},"model":{"type":"string","description":"Transcription model for the selected provider. For\n`deepgram_stream` this is `nova-3` or `nova-2`; other\nproviders take their own model identifiers.\n"},"language":{"type":"string","description":"Language code for the transcriber. Format and supported\nvalues depend on the provider (e.g. `en-US` for Deepgram,\n`hi-IN` for Sarvam). Applies regardless of which\n`provider` is selected.\n"},"silence_timeout_ms":{"type":"number","description":"Silence timeout in milliseconds."},"should_apply_noise_reduction":{"type":"boolean","description":"Reduce background noise on the inbound audio stream before transcription."},"interruption_min_words":{"type":"number","minimum":1,"description":"Minimum number of words the caller must say before their speech is treated as an interruption."},"max_call_duration_in_sec":{"type":"number","minimum":1,"description":"Hard upper bound on call length in seconds. The agent will end the call once this is reached."},"first_ideal_message":{"type":"string","description":"First nudge spoken when the caller goes silent past the\nidle threshold. Set `is_first_ideal_message_dynamic` to\n`true` to have the LLM regenerate this each time.\n"},"is_first_ideal_message_dynamic":{"type":"boolean","description":"When true, `first_ideal_message` is treated as a prompt and the LLM generates a fresh nudge each call."},"second_ideal_message":{"type":"string","description":"Second nudge spoken if silence continues after the first."},"is_second_ideal_message_dynamic":{"type":"boolean","description":"When true, `second_ideal_message` is treated as a prompt and the LLM generates a fresh nudge each call."},"numerals":{"type":"boolean","description":"Convert numbers from words to digits."},"punctuate":{"type":"boolean","description":"Add punctuation to the transcript."},"smart_format":{"type":"boolean","description":"Apply smart formatting to the transcript."},"diarize":{"type":"boolean","description":"Identify different speakers in the transcript."}}},"model":{"type":"object","description":"Configuration for the language model.","properties":{"model":{"type":"string","description":"The language model to use: a `name` from the LLM providers list, which returns exactly the models your organization can use. Leave it out to use your organization's default model."},"temperature":{"type":"number","minimum":0,"maximum":1,"description":"Controls randomness in the model's output (0.0 to 1.0)."}}},"voice":{"type":"object","description":"Configuration for the text-to-speech voice. `provider` and `voice_id` identify the voice together, so send both to change it. `provider` on its own is not accepted, and a `voice_id` on its own leaves the voice as it was. The other fields here apply independently. Leave out `provider` and `voice_id` to use your organization's default voice.","dependentRequired":{"provider":["voice_id"]},"properties":{"provider":{"type":"string","description":"The voice provider to use: the `service` of a voice from the voices list, which returns only voices your organization can use. Send `voice_id` alongside it. We recommend OmniDimension voices (list them with `provider=featured`) and Cartesia voices. An agent created without `voice` gets the platform default, a Cartesia voice, which every account can use."},"voice_id":{"type":"string","description":"The provider's voice identifier, returned in the `name` field of the voices list (not the numeric `id`). Takes effect when `provider` is sent alongside it."},"speech_speed":{"type":"number","minimum":0.5,"maximum":2,"default":1,"description":"Playback speed multiplier for the agent's voice. 1.0 is normal speed."}}},"web_search":{"type":"object","description":"Configuration for web search capabilities.","properties":{"enabled":{"type":"boolean","description":"Enable or disable web search functionality."},"provider":{"type":"string","enum":["DuckDuckGo","openAI"],"description":"The search provider to use."}}},"post_call_actions":{"type":"object","additionalProperties":true,"description":"Post-call actions: email, webhook, Omni CRM, WhatsApp, workflow, Google Sheets, Slack, Salesforce, HubSpot or Zoho Bigin. On an agent, add them one at a time with addPostCallAction instead. Full shape: https://docs.omnidim.io/docs/per-call-post-call-actions"},"transfer":{"type":"object","description":"Conditional call transfer to a human agent or another number.","properties":{"enabled":{"type":"boolean"},"transfer_options":{"type":"array","description":"Where to transfer the call and under what condition. The first matching condition wins. In an agent update, sending this list replaces all saved options. Omit it to keep them unchanged, or send an empty array to clear them.","items":{"type":"object","required":["number","transfer_condition","transfer_message"],"properties":{"number":{"type":"string","description":"Primary phone number to transfer to. Include country code with leading `+`."},"type":{"type":"string","enum":["static","dynamic"],"default":"static","description":"`static` transfers to `number`. `dynamic` lets the agent\npick a number at runtime based on the conversation.\n"},"backup_numbers":{"type":"array","description":"Fallback numbers tried if the primary is unreachable.","items":{"type":"string"}},"transfer_condition":{"type":"string","description":"Natural-language condition that triggers this transfer option."},"transfer_message":{"type":"string","description":"Message the agent says to the caller before executing the transfer."}}}}}},"end_call":{"type":"object","description":"Hang up automatically when a condition is met.","properties":{"enabled":{"type":"boolean"},"condition":{"type":"string","description":"Natural-language condition that triggers ending the call. Only evaluated when `enabled` is true."},"message":{"type":"string","description":"What the agent says before hanging up."},"message_type":{"type":"string","enum":["static","prompt"],"description":"`static` speaks `message` verbatim. `prompt` treats\n`message_prompt` as an LLM instruction and generates a\nfresh closing line each call (useful for matching the\ncaller's language and tone).\n"},"message_prompt":{"type":"string","description":"LLM prompt used to generate the closing line when `message_type` is `prompt`."}}},"background_track":{"type":"object","description":"Ambient background noise that plays under the agent's voice.","properties":{"enabled":{"type":"boolean","description":"Whether to mix the ambient track under the agent's audio."},"name":{"type":"string","enum":["call_center","filler","office","office_1","restaurant"],"description":"Ambient track to mix under the agent."},"volume":{"type":"number","minimum":0,"maximum":1,"default":0.2,"description":"Volume level on a 0–1 scale. Default 0.2."},"tts_volume_reduction":{"type":"number","minimum":0,"maximum":1,"description":"Amount to drop the agent's TTS volume while the ambient track plays, on a 0–1 scale. Helps the voice cut through without raising the overall mix."}}},"initial_ringing_sound_enabled":{"type":"boolean","description":"Plays a ringing tone after the call is picked up, until the agent starts speaking."},"voicemail":{"type":"object","description":"Voicemail / answering-machine handling for outbound calls. Set this with the nested object shown here; the agent object returns these values as the flat fields `voicemail_enabled` and `voicemail_message`. Voicemail detection is an access-gated feature. If it isn't enabled for your account, [request access](https://omnidim.io/contact-us?reason=product&lock=1).","properties":{"enabled":{"type":"boolean","description":"Detect voicemail and leave your message instead of speaking to a machine."},"message":{"type":"string","description":"Message to leave when voicemail is detected."}}},"languages":{"type":"array","description":"Languages the agent should support. Pass each language as a display-name string exactly as it appears in the dashboard's language picker. Unrecognized names are skipped.","items":{"type":"string"}}}}},"required":["agent_id","requestBody"]},
186
+ inputSchema: {"type":"object","properties":{"agent_id":{"type":"number","description":"The ID of the agent."},"requestBody":{"type":"object","description":"Agent configuration.","properties":{"name":{"type":"string","description":"Name for the agent."},"welcome_message":{"type":"string","description":"Initial message the agent will say when answering a call."},"is_welcome_message_dynamic":{"type":"boolean","description":"When true, the welcome message is treated as a directive the agent uses to generate a tailored greeting for each call, rather than being spoken word for word. When false, the welcome message is spoken exactly as written."},"is_welcome_message_interruption":{"type":"boolean","description":"Allow the caller to interrupt the welcome message. When false, the agent finishes speaking the welcome before listening."},"is_interruption_allowed":{"type":"boolean","description":"Global toggle for whether the caller can interrupt the agent mid-sentence at any point in the call."},"dynamic_variables":{"type":"object","description":"Key/value map used to substitute placeholders in the agent's\nprompt and welcome message at call time. Reference a variable\nin your prompt with `{{variable_name}}`. Useful for\npersonalising the same agent across many calls.\n","additionalProperties":{"type":"string"}},"context_breakdown":{"type":"array","description":"The agent's prompt sections, each with `title`, `body` and optional `is_enabled`. Sending them replaces the whole list and rebuilds the prompt from the enabled sections in order: each `title` becomes a `# title` heading on its own line, with its `body` below it, the same layout the dashboard uses. A save without `context_breakdown` leaves the prompt unchanged.","items":{"type":"object","required":["title","body"],"properties":{"title":{"type":"string","description":"Title of the breakdown."},"body":{"type":"string","description":"Body of the breakdown, the detailed prompt content."},"is_enabled":{"type":"boolean","default":true,"description":"Whether this section is included in the prompt."}}}},"call_type":{"type":"string","enum":["Incoming","Outgoing"],"description":"`Incoming` for an agent that answers calls, `Outgoing` for one that places them, spelled exactly so. Any other value, `incoming` included, saves as `Outgoing` and the response lists it in `warnings`."},"timezone":{"type":"string","description":"IANA timezone for this agent, for example `Asia/Kolkata`. Sets the local date and time the agent works with during calls. If not set, the account timezone is used as fallback. Pass an empty string to clear it."},"transcriber":{"type":"object","description":"Configuration for the speech-to-text transcriber.","properties":{"provider":{"type":"string","description":"The speech-to-text provider to use: a `name` from the STT providers list, which returns the ones your organization can use. Leave it out to use your organization's default transcriber."},"model":{"type":"string","description":"Transcription model for the selected provider. For\n`deepgram_stream` this is `nova-3` or `nova-2`. Saved only\nfor `deepgram_stream`, `cartesia` and `sarvam`, and only\nwhen `provider` is in the same request.\n"},"language":{"type":["string","array"],"items":{"type":"string"},"description":"Language code for the transcriber. Format and supported\nvalues depend on the provider (e.g. `en-US` for Deepgram,\n`hi-IN` for Sarvam). `soniox` takes a list of codes, such as\n`[\"en\", \"hi\"]`, and an empty list detects the language. Saved only when `provider` is in the\nsame request and is `deepgram_stream`, `cartesia`, `sarvam`,\n`azure` or `soniox`.\n"},"silence_timeout_ms":{"type":"number","description":"Silence timeout in milliseconds."},"should_apply_noise_reduction":{"type":"boolean","description":"Reduce background noise on the inbound audio stream before transcription."},"interruption_min_words":{"type":"number","minimum":1,"description":"Minimum number of words the caller must say before their speech is treated as an interruption."},"max_call_duration_in_sec":{"type":"number","minimum":1,"description":"Hard upper bound on call length in seconds. The agent will end the call once this is reached."},"first_ideal_message":{"type":"string","description":"First nudge spoken when the caller goes silent past the\nidle threshold. Set `is_first_ideal_message_dynamic` to\n`true` to have the LLM regenerate this each time.\n"},"is_first_ideal_message_dynamic":{"type":"boolean","description":"When true, `first_ideal_message` is treated as a prompt and the LLM generates a fresh nudge each call."},"second_ideal_message":{"type":"string","description":"Second nudge spoken if silence continues after the first."},"is_second_ideal_message_dynamic":{"type":"boolean","description":"When true, `second_ideal_message` is treated as a prompt and the LLM generates a fresh nudge each call."},"numerals":{"type":"boolean","description":"Convert numbers from words to digits."},"punctuate":{"type":"boolean","description":"Add punctuation to the transcript."},"smart_format":{"type":"boolean","description":"Apply smart formatting to the transcript."},"diarize":{"type":"boolean","description":"Identify different speakers in the transcript."}}},"model":{"type":"object","description":"Configuration for the language model.","properties":{"model":{"type":"string","description":"The language model to use: a `name` from the LLM providers list, which returns exactly the models your organization can use. Leave it out to use your organization's default model."},"temperature":{"type":"number","minimum":0,"maximum":1,"description":"Controls randomness in the model's output (0.0 to 1.0)."}}},"voice":{"type":"object","description":"Configuration for the text-to-speech voice. `provider` and `voice_id` identify the voice together, so send both to change it. `provider` on its own is not accepted, and a `voice_id` on its own leaves the voice as it was. The other fields here apply independently. Leave out `provider` and `voice_id` to use your organization's default voice.","dependentRequired":{"provider":["voice_id"]},"properties":{"provider":{"type":"string","description":"The voice provider to use: the `service` of a voice from the voices list, which returns only voices your organization can use. Send `voice_id` alongside it. We recommend OmniDimension voices (list them with `provider=featured`) and Cartesia voices. An agent created without `voice` gets the platform default, a Cartesia voice, which every account can use."},"voice_id":{"type":"string","description":"The provider's voice identifier, returned in the `name` field of the voices list (not the numeric `id`). Takes effect when `provider` is sent alongside it."},"speech_speed":{"type":"number","minimum":0.5,"maximum":2,"default":1,"description":"Playback speed multiplier for the agent's voice. 1.0 is normal speed."}}},"web_search":{"type":"object","description":"Configuration for web search capabilities.","properties":{"enabled":{"type":"boolean","description":"Enable or disable web search functionality."},"provider":{"type":"string","enum":["DuckDuckGo","openAI"],"description":"The search provider to use."}}},"post_call_actions":{"type":"object","additionalProperties":true,"description":"Post-call actions: email, webhook, Omni CRM, WhatsApp, workflow, Google Sheets, Slack, Salesforce, HubSpot or Zoho Bigin. On an agent, add them one at a time with addPostCallAction instead. Full shape: https://docs.omnidim.io/docs/per-call-post-call-actions"},"transfer":{"type":"object","description":"Conditional call transfer to a human agent or another number.","properties":{"enabled":{"type":"boolean"},"transfer_options":{"type":"array","description":"Where to transfer the call and under what condition. The first matching condition wins. In an agent update, sending this list replaces all saved options. Omit it to keep them unchanged, or send an empty array to clear them.","items":{"type":"object","required":["number","transfer_condition","transfer_message"],"properties":{"number":{"type":"string","description":"Primary phone number to transfer to. Include country code with leading `+`."},"type":{"type":"string","enum":["static","dynamic"],"default":"static","description":"`static` transfers to `number`. `dynamic` lets the agent\npick a number at runtime based on the conversation.\n"},"backup_numbers":{"type":"array","description":"Fallback numbers tried if the primary is unreachable.","items":{"type":"string"}},"transfer_condition":{"type":"string","description":"Natural-language condition that triggers this transfer option."},"transfer_message":{"type":"string","description":"Message the agent says to the caller before executing the transfer."}}}}}},"end_call":{"type":"object","description":"Hang up automatically when a condition is met.","properties":{"enabled":{"type":"boolean","description":"Turn ending the call on or off. Leave it out to keep the current setting. `false` also clears `condition` and `message`."},"condition":{"type":"string","description":"Natural-language condition that triggers ending the call. Only evaluated when `enabled` is true."},"message":{"type":"string","description":"What the agent says before hanging up."},"message_type":{"type":"string","enum":["static","prompt"],"description":"`static` speaks `message` verbatim. `prompt` treats\n`message_prompt` as an LLM instruction and generates a\nfresh closing line each call (useful for matching the\ncaller's language and tone).\n"},"message_prompt":{"type":"string","description":"LLM prompt used to generate the closing line when `message_type` is `prompt`."}}},"background_track":{"type":"object","description":"Ambient background noise that plays under the agent's voice.","properties":{"enabled":{"type":"boolean","description":"Whether to mix the ambient track under the agent's audio."},"name":{"type":"string","enum":["call_center","filler","office","office_1","restaurant"],"description":"Ambient track to mix under the agent."},"volume":{"type":"number","minimum":0,"maximum":1,"default":0.2,"description":"Volume level on a 0–1 scale. Default 0.2."},"tts_volume_reduction":{"type":"number","minimum":0,"maximum":1,"description":"Amount to drop the agent's TTS volume while the ambient track plays, on a 0–1 scale. Helps the voice cut through without raising the overall mix."}}},"initial_ringing_sound_enabled":{"type":"boolean","description":"Plays a ringing tone after the call is picked up, until the agent starts speaking."},"voicemail":{"type":"object","description":"Voicemail / answering-machine handling for outbound calls. Set this with the nested object shown here; the agent object returns these values as the flat fields `voicemail_enabled` and `voicemail_message`. Voicemail detection is an access-gated feature. If it isn't enabled for your account, [request access](https://omnidim.io/contact-us?reason=product&lock=1).","properties":{"enabled":{"type":"boolean","description":"Detect voicemail and leave your message instead of speaking to a machine."},"message":{"type":"string","description":"Message to leave when voicemail is detected."}}},"languages":{"type":"array","description":"Languages the agent should support. Pass each language as a display-name string exactly as it appears in the dashboard's language picker. Unrecognized names are skipped, and the request is refused when none is recognized. The order is not kept.","items":{"type":"string"}}}}},"required":["agent_id","requestBody"]},
181
187
  method: "put",
182
188
  pathTemplate: "/agents/{agent_id}",
183
189
  executionParameters: [{"name":"agent_id","in":"path"}],
@@ -214,7 +220,12 @@ before configuring the \`voicemail\` object.
214
220
  }],
215
221
  ["addPostCallAction", {
216
222
  name: "addPostCallAction",
217
- description: `Add one post-call action to the agent. The agent's other actions are not changed. Send an \`Idempotency-Key\` header to make a retry safe: the same key and body return the action the first request added.
223
+ description: `Add one post-call action to an agent.
224
+
225
+ The agent's other actions stay as they are. Send an \`Idempotency-Key\` header
226
+ to retry safely: the same key and body return the action the first request
227
+ added.
228
+
218
229
  (Tags: Agents)`,
219
230
  inputSchema: {"type":"object","properties":{"agent_id":{"type":"number","description":"The ID of the agent."},"Idempotency-Key":{"type":"string","description":"Any unique string. A retry with the same key and body adds nothing new."},"requestBody":{"allOf":[{"type":"object","description":"One post-call action. `type` picks the channel; send the fields of\nthat channel plus any of the shared ones. `type` is required when\nadding an action; an update sends only the fields it changes.\n","properties":{"type":{"type":"string","enum":["email","webhook","omni_crm","cloud_whatsapp","workflow","google_sheets","slack","salesforce","hubspot","zoho_bigin"],"description":"The channel. It cannot change after the action is created:\ndelete it and add a new one. `google_sheets`, `slack`,\n`salesforce`, `hubspot` and `zoho_bigin` deliver through an\naccount connected in the dashboard: pass its id as\n`integration_id` (see List integrations).\n"},"integration_id":{"type":"integer","description":"`google_sheets`, `slack`, `salesforce`, `hubspot`, `zoho_bigin`\nonly, required: the id of your integration of that type.\n"},"spreadsheet_id":{"type":"string","description":"`google_sheets` only, required: the id in the sheet's URL, the\npart after `/d/`.\n","example":"1BxiMVs0XRA5nFMdKvBdBZjgmUUqptlbs74OgvE2upms"},"spreadsheet_name":{"type":"string","description":"`google_sheets` only: the sheet's name, for display."},"worksheet_name":{"type":"string","description":"`google_sheets` only: the tab to append to. Defaults to `Sheet1`.","example":"Calls"},"channel_id":{"type":"string","description":"`slack` only: the channel id. Send this or `channel_name`.","example":"C08RTQ1NY81"},"channel_name":{"type":"string","description":"`slack` only: the channel name. Send this or `channel_id`.","example":"sales"},"object_name":{"type":"string","description":"`salesforce`: `Lead` (default), `Contact`, `Account`,\n`Opportunity`, `Case`, `Task` or `Product`. `hubspot`, required:\n`contact`, `company`, `deal` or `ticket`. Both send a fixed set of\nfields for the chosen object, so they take no `extracted_variables`.\n"},"create_call_log":{"type":"boolean","description":"`zoho_bigin` only: log the call in Zoho Bigin. Defaults to true."},"update_contact":{"type":"boolean","description":"`zoho_bigin` only: update a matching contact with what the call captured. Defaults to true."},"create_contact":{"type":"boolean","description":"`zoho_bigin` only: create a contact when no contact matches. Defaults to true."},"action":{"type":"string","enum":["create","upsert"],"description":"`salesforce` only: `upsert` finds the record by the caller's number\nand updates it or creates it. `create` creates a new record every\ncall. Defaults to `create`.\n"},"match_field":{"type":"string","description":"`salesforce` only, with `upsert`: the phone field the caller's number is looked up in. Defaults to `Phone`.","example":"Phone"},"log_call":{"type":"boolean","description":"`salesforce` only: log the call on the record, with the summary and recording link. Defaults to false."},"add_note":{"type":"boolean","description":"`salesforce` only: add the call summary as a note on the record. Defaults to false."},"recipients":{"type":"array","description":"`email` only, required: the addresses to notify.","items":{"type":"string","format":"email"},"example":["support@acme-corp.io"]},"url":{"type":"string","format":"uri","description":"`webhook` only, required: the endpoint that receives a POST with the call payload.","example":"https://crm.acme-corp.io/omnidim-callback"},"phone_number_id":{"type":"integer","description":"`cloud_whatsapp` only, required: your Cloud WhatsApp number the message is sent from. Also send `template_id` or `templates`, or nothing is sent."},"template_id":{"type":"integer","description":"`cloud_whatsapp` only: an approved template on that number."},"template_variables":{"type":"array","description":"`cloud_whatsapp` only: which extracted variable fills each template placeholder.","items":{"type":"object","properties":{"index":{"type":"string","description":"The placeholder number, as a string.","example":"1"},"extracted_var":{"type":"string","description":"The key of the extracted variable whose value fills this placeholder.","example":"customer_name"}}}},"templates":{"type":"array","description":"`cloud_whatsapp` only: one or more templates to send.","items":{"type":"object","description":"One Cloud WhatsApp template to send after the call.","properties":{"template_id":{"type":"integer","description":"An approved template on the chosen number."},"usage_description":{"type":"string","description":"When this template should be sent. After the call, the model reads\nthese descriptions to choose which templates fit the conversation.\n","example":"Send when the caller books an appointment."},"always_send":{"type":"boolean","description":"Send this template after every call, whichever templates the model chooses."},"variable_mappings":{"type":"array","description":"How to fill each template placeholder.","items":{"type":"object","properties":{"index":{"type":"string","description":"The placeholder number, as a string.","example":"1"},"extracted_var":{"type":"string","description":"The extracted variable whose value fills this placeholder."},"static_value":{"type":"string","description":"A fixed value for this placeholder. When set, it is used\ninstead of the extracted variable.\n"},"mode":{"type":"string","enum":["variable","static"],"description":"Which input the dashboard shows for this placeholder. It\ndoes not change the value sent: a `static_value` is used\nfirst, then the extracted variable, then `fallback_value`.\n"},"fallback_value":{"type":"string","description":"The value to use when the variable is not extracted."}}}}}}},"workflow_id":{"type":"integer","description":"`workflow` only, required: the workflow to run. It must have a published version, or the action is skipped."},"include":{"type":"array","description":"Which sections to include.","items":{"type":"string","enum":["summary","extracted_variables","fullConversation","sentiment"]}},"extracted_variables":{"type":"array","description":"Variables the model should pull out of the conversation. A key\nalready used by another action on this agent must have the same\nprompt, or the request is refused with `400`. Other actions are\nnever changed to match.\n","items":{"type":"object","required":["key","prompt"],"properties":{"key":{"type":"string","description":"Unique identifier for the variable in the post-call payload.","example":"customer_issue"},"prompt":{"type":"string","description":"Instruction for the model on what to pull out of the conversation.","example":"Identify the main issue the customer is experiencing."}}}},"trigger_call_statuses":{"type":"array","description":"Call outcomes that fire this action. Omit to use the default\n(`completed`, `voicemail_detected`).\n","items":{"type":"string","enum":["completed","voicemail_detected","failed","no-answer","busy","canceled"]}}}},{"required":["type"]}],"description":"The JSON request body."}},"required":["agent_id","requestBody"]},
220
231
  method: "post",
@@ -253,7 +264,15 @@ before configuring the \`voicemail\` object.
253
264
  }],
254
265
  ["listIntegrations", {
255
266
  name: "listIntegrations",
256
- description: `List the integrations connected to your workspace, with each one's \`id\` and \`integration_type\`. Stored credentials (tokens, secrets, passwords, API keys, and the values of a custom API's headers and parameters) are never returned: they read \`********\`. When you create an integration, send the real values: \`********\` is refused. Accounts that sign in with OAuth (Google Sheets, Slack, HubSpot, Salesforce, Zoho Bigin) are connected in the dashboard.
267
+ description: `List your workspace integrations, with each one's \`id\` and
268
+ \`integration_type\`.
269
+
270
+ Stored credentials (tokens, secrets, passwords, API keys, and the values of
271
+ a custom API's headers and parameters) are never returned. They read
272
+ \`********\`. When you create an integration, send the real values: \`********\`
273
+ is refused. Accounts that sign in with OAuth (Google Sheets, Slack, HubSpot,
274
+ Salesforce, Zoho Bigin) are connected in the dashboard.
275
+
257
276
  (Tags: Integrations)`,
258
277
  inputSchema: {"type":"object","properties":{}},
259
278
  method: "get",
@@ -266,7 +285,13 @@ before configuring the \`voicemail\` object.
266
285
  }],
267
286
  ["createCustomApiIntegration", {
268
287
  name: "createCustomApiIntegration",
269
- description: `Save a call to your own HTTP endpoint as an integration. Attach it to an agent with \`attachAgentIntegration\`, and the agent calls the endpoint during a call when the conversation needs it, then uses the response in its reply. Parameters marked \`isLLMGenerated\` are filled in by the agent from the conversation.
288
+ description: `Save a call to your own HTTP endpoint as an integration.
289
+
290
+ Attach it to an agent with \`attachAgentIntegration\`. The agent calls the
291
+ endpoint during a call when the conversation needs it, then uses the
292
+ response in its reply. The agent fills parameters marked \`isLLMGenerated\`
293
+ from the conversation.
294
+
270
295
  (Tags: Integrations)`,
271
296
  inputSchema: {"type":"object","properties":{"requestBody":{"type":"object","required":["name","url","method"],"properties":{"name":{"type":"string","description":"A name for the integration."},"description":{"type":"string","description":"What the endpoint does. The agent reads this to decide\nwhen to call it, so say what it returns and when it is useful.\n"},"url":{"type":"string","format":"uri"},"method":{"type":"string","enum":["GET","POST","PUT","PATCH","DELETE"]},"headers":{"type":"array","description":"Fixed headers sent on every request.","items":{"type":"object","required":["key","value"],"properties":{"key":{"type":"string"},"value":{"type":"string"}}}},"query_params":{"type":"array","description":"Query string parameters.","items":{"type":"object","description":"One query or body parameter of a custom API. With `isLLMGenerated`\ntrue the agent fills the value from the conversation, guided by\n`description`. With it false, the text in `description` is sent as a\nfixed value.\n","required":["key"],"properties":{"key":{"type":"string","description":"The parameter name your endpoint expects."},"description":{"type":"string","description":"What the agent should put here, or the fixed value when `isLLMGenerated` is false."},"type":{"type":"string","enum":["string","number","boolean","object","array"],"default":"string"},"required":{"type":"boolean","description":"Whether the agent must supply this parameter."},"isLLMGenerated":{"type":"boolean","default":true,"description":"Let the agent fill this value from the conversation."},"children":{"type":"array","description":"Nested fields of an `object` or `array` body parameter. Query parameters have no children.","items":{"type":"object"}}}}},"body_params":{"type":"array","description":"Request body fields, sent as JSON. A GET request sends no\nbody. Every request with a body also carries the call's\n`from_number`, `to_number` and `call_sid`.\n","items":{"type":"object","description":"One query or body parameter of a custom API. With `isLLMGenerated`\ntrue the agent fills the value from the conversation, guided by\n`description`. With it false, the text in `description` is sent as a\nfixed value.\n","required":["key"],"properties":{"key":{"type":"string","description":"The parameter name your endpoint expects."},"description":{"type":"string","description":"What the agent should put here, or the fixed value when `isLLMGenerated` is false."},"type":{"type":"string","enum":["string","number","boolean","object","array"],"default":"string"},"required":{"type":"boolean","description":"Whether the agent must supply this parameter."},"isLLMGenerated":{"type":"boolean","default":true,"description":"Let the agent fill this value from the conversation."},"children":{"type":"array","description":"Nested fields of an `object` or `array` body parameter. Query parameters have no children.","items":{"type":"object"}}}}},"request_timeout":{"type":"number","default":10,"description":"Seconds to wait for your endpoint before the agent moves on."}},"description":"The JSON request body."}},"required":["requestBody"]},
272
297
  method: "post",
@@ -292,7 +317,11 @@ before configuring the \`voicemail\` object.
292
317
  }],
293
318
  ["attachAgentIntegration", {
294
319
  name: "attachAgentIntegration",
295
- description: `Attach one of your integrations to the agent. The agent can use it on its next call. Integrations already attached stay as they are.
320
+ description: `Attach an integration to an agent.
321
+
322
+ The agent can use it on its next call. Integrations already attached stay as
323
+ they are.
324
+
296
325
  (Tags: Integrations)`,
297
326
  inputSchema: {"type":"object","properties":{"agent_id":{"type":"number","description":"The ID of the agent."},"requestBody":{"type":"object","required":["integration_id"],"properties":{"integration_id":{"type":"number","description":"The integration's id, from `listIntegrations` or a create response."}},"description":"The JSON request body."}},"required":["agent_id","requestBody"]},
298
327
  method: "post",
@@ -318,7 +347,7 @@ before configuring the \`voicemail\` object.
318
347
  }],
319
348
  ["listAgentVersions", {
320
349
  name: "listAgentVersions",
321
- description: `List an agent's saved versions, newest first. Includes manual (named) versions, automatic versions, and system backups taken before a restore.
350
+ description: `List an agent's saved versions, newest first. Includes manual (named) versions and system backups taken before a restore. Nothing is saved automatically.
322
351
  (Tags: Agents)`,
323
352
  inputSchema: {"type":"object","properties":{"agent_id":{"type":"number","description":"The ID of the agent."},"pageno":{"type":"integer","minimum":1,"default":1,"description":"Page number for pagination."},"pagesize":{"type":"integer","minimum":1,"default":30,"maximum":150,"description":"Number of items per page (max 150)."},"search":{"type":"string","description":"Filter versions whose name matches this substring (case-insensitive)."},"kind":{"type":"string","enum":["manual","system"],"description":"Filter versions by kind."}},"required":["agent_id"]},
324
353
  method: "get",
@@ -370,7 +399,13 @@ before configuring the \`voicemail\` object.
370
399
  }],
371
400
  ["diffAgentVersion", {
372
401
  name: "diffAgentVersion",
373
- description: `Get a record-level diff for this version. By default it shows what changed in this version compared with the version before it. Use \`against=current\` to compare with the agent's live config (what restoring this version would change), or \`against=<number>\` to compare with another version.
402
+ description: `Get a record-level diff for one agent version.
403
+
404
+ By default it compares this version with the one before it. Use
405
+ \`against=current\` to compare with the live config, which shows what
406
+ restoring this version would change. Use \`against=<number>\` to compare with
407
+ another version.
408
+
374
409
  (Tags: Agents)`,
375
410
  inputSchema: {"type":"object","properties":{"agent_id":{"type":"number","description":"The ID of the agent."},"version_number":{"type":"number","description":"The version number, as returned in `version_number` from the list or save endpoints."},"against":{"type":"string","description":"What to compare against. Omit or `previous` for the version before this one (the default). `current` for the agent's live config. A version number to compare with that version."}},"required":["agent_id","version_number"]},
376
411
  method: "get",
@@ -383,7 +418,13 @@ before configuring the \`voicemail\` object.
383
418
  }],
384
419
  ["restoreAgentVersion", {
385
420
  name: "restoreAgentVersion",
386
- description: `Restore a version onto the live agent. Your current setup is saved first as a backup version, so restoring is undoable. Configuration is brought back; any knowledge files or integrations that were deleted since this version was saved can't be re-linked, and are reported in \`skipped\`.
421
+ description: `Restore a version onto the live agent.
422
+
423
+ Your current setup is saved first as a backup version, so restoring is
424
+ undoable. Configuration comes back. Knowledge files or integrations deleted
425
+ since this version was saved can't be re-linked. They are reported in
426
+ \`skipped\`.
427
+
387
428
  (Tags: Agents)`,
388
429
  inputSchema: {"type":"object","properties":{"agent_id":{"type":"number","description":"The ID of the agent."},"version_number":{"type":"number","description":"The version number, as returned in `version_number` from the list or save endpoints."},"requestBody":{"type":"object","properties":{},"description":"The JSON request body."}},"required":["agent_id","version_number"]},
389
430
  method: "post",
@@ -396,8 +437,9 @@ before configuring the \`voicemail\` object.
396
437
  }],
397
438
  ["dispatchCall", {
398
439
  name: "dispatchCall",
399
- description: `Initiate a call to a phone number using a specified agent. The
400
- phone number must include a country code with a leading plus.
440
+ description: `Start a call to a phone number with an agent.
441
+
442
+ The phone number must include a country code with a leading plus.
401
443
 
402
444
  (Tags: Calls)`,
403
445
  inputSchema: {"type":"object","properties":{"requestBody":{"type":"object","required":["agent_id","to_number"],"properties":{"agent_id":{"type":"number","description":"The ID of the agent that will handle the call."},"to_number":{"type":"string","description":"The phone number to call. Must include country code (e.g., +15551234567)."},"from_number_id":{"type":"number","description":"Id of a phone number on your account to place the call from (see the phone number list endpoint). Omit to use the platform's default number."},"call_context":{"type":"object","description":"Optional context information as key-value pairs to be passed to the agent during the call. Can contain any custom fields relevant to your use case.","additionalProperties":true},"metadata":{"type":"object","additionalProperties":true,"description":"Key-value pairs stored on the call for your own tracking\n(e.g. CRM or lead IDs). Not shared with the agent; echoed\nback as `metadata` in the post-call webhook so you can\ncorrelate results with your records.\n"},"__languages":{"oneOf":[{"type":"array","items":{"type":"string"}},{"type":"string"}],"description":"Languages this call runs in, replacing the agent's configured\nlist for this call only. The first entry is the language the\ncall opens in. Send an array, or a pipe-separated string such\nas `Hindi|English`. Names the platform does not recognize are\nskipped and listed in `languages_ignored`.\n"},"__post_call_actions":{"allOf":[{"type":"object","additionalProperties":true,"description":"Post-call actions: email, webhook, Omni CRM, WhatsApp, workflow, Google Sheets, Slack, Salesforce, HubSpot or Zoho Bigin. On an agent, add them one at a time with addPostCallAction instead. Full shape: https://docs.omnidim.io/docs/per-call-post-call-actions"}],"description":"Post-call actions for this call only, in the same shape as\n`post_call_actions` on agent create. Email and webhook only.\nThey replace the agent's own post-call actions for this call;\nthe agent is not changed. Items that cannot be used are\nskipped and listed in `post_call_actions_ignored`, and the\ncall still goes out. Can also be sent inside `call_context`.\n"}},"description":"The JSON request body."}},"required":["requestBody"]},
@@ -450,15 +492,15 @@ phone number must include a country code with a leading plus.
450
492
  }],
451
493
  ["createBulkCall", {
452
494
  name: "createBulkCall",
453
- description: `Create a new bulk-call campaign. Only name, phone_number_id and a
454
- contact_list are needed to dial a list now; every other field adds
455
- one behavior on top (drafts, rotation, filtering, scheduling,
456
- retries, dynamic feeding).
495
+ description: `Create a bulk-call campaign.
457
496
 
458
- The guide below the field reference walks the whole journey: the
459
- first campaign and its response, each behavior with a working
460
- request, every refusal message with its fix, and the endpoints that
461
- operate a campaign once it runs.
497
+ Only \`name\`, \`phone_number_id\` and a \`contact_list\` are needed to dial a
498
+ list now. Every other field adds one behavior: drafts, rotation, filtering,
499
+ scheduling, retries or dynamic feeding.
500
+
501
+ The guide below the field reference shows each behavior with a working
502
+ request, every refusal message with its fix, and the endpoints that operate
503
+ a running campaign.
462
504
 
463
505
  (Tags: Bulk calls)`,
464
506
  inputSchema: {"type":"object","properties":{"requestBody":{"type":"object","required":["name","phone_number_id"],"properties":{"name":{"type":"string","description":"Name of the bulk call campaign."},"phone_number_id":{"type":"string","description":"The number this campaign calls from. With a `rotation`, the\nrotation numbers dial instead and this one is the standby.\n"},"bot_id":{"type":"number","description":"Agent to run the campaign. Defaults to the agent attached\nto `phone_number_id`; required when the number has none.\n"},"save_as_draft":{"type":"boolean","default":false,"description":"Store the campaign without dialing; start it later with the\nstart endpoint. See Drafts in the guide below.\n"},"call_conditions":{"type":"array","description":"Dial only the contacts that match every condition; the rest\nare kept as `Skipped`. See Filtering in the guide below.\n","items":{"type":"object","required":["column","operator","value"],"properties":{"column":{"type":"string","description":"Key on the contact row to test."},"operator":{"type":"string","default":"equals","enum":["equals","not_equals","contains","greater_than","less_than"],"description":"`contains` is case-insensitive. `greater_than` and\n`less_than` compare numerically, and a row whose value\nis not a number fails the condition rather than\nerroring.\n"},"value":{"type":"string"}}}},"rotation":{"type":"object","description":"Rotate the campaign across several of your numbers, so no\nsingle number burns out. See Rotation in the guide below.\n","required":["numbers"],"properties":{"numbers":{"type":"array","minItems":1,"description":"The numbers to rotate across; each must be yours and\nlisted once.\n","items":{"type":"object","required":["phone_number_id"],"properties":{"phone_number_id":{"type":"number","description":"One of your numbers, from List phone numbers."},"sequence":{"type":"number","default":10,"description":"Rotation order. Lowest dials first."}}}},"strategy":{"type":"string","default":"fixed_count","enum":["fixed_count","cpr_threshold","both","none"],"description":"When to move to the next number: every\n`calls_per_number` calls, on low health score, both, or\nnever.\n"},"calls_per_number":{"type":"number","default":50,"description":"Calls before moving on. Used by `fixed_count` and `both`."},"health_threshold":{"type":"number","default":30,"description":"Health score below which a number is rotated away from.\nUsed by `cpr_threshold` and `both`.\n"},"fallback":{"type":"string","default":"pause","enum":["pause","continue_best"],"description":"When every number is unhealthy: `pause` the campaign,\nor `continue_best` with the healthiest one.\n"},"call_back_from_different_number":{"type":"boolean","default":false,"description":"When on, a repeat call to the same person goes out from\na different number than the one that called them last.\nNeeds two or more numbers in the pool.\n"}}},"skip_known_invalid_numbers":{"type":"boolean","default":false,"description":"When on, a contact is not dialed if the carrier said its\nnumber does not exist, in any campaign of your organization\nin the last 14 days. That contact shows as a failed call\nwith the reason `Invalid number` and is never retried.\n"},"is_dynamic":{"type":"boolean","default":false,"description":"A dynamic campaign stays alive accepting contacts via the\nadd-contact webhooks, and `contact_list` becomes optional.\n"},"contact_list":{"type":"array","description":"Who to call. Each row needs `phone_number`; any other key\nreaches the agent as context for that one call.\n","items":{"type":"object","required":["phone_number"],"properties":{"phone_number":{"type":"string","description":"Phone number in international format (e.g., +15551234567)."}},"additionalProperties":true}},"is_scheduled":{"type":"boolean","default":false,"description":"Whether the campaign should be scheduled for future execution."},"scheduled_datetime":{"type":"string","description":"Scheduled execution time in format `YYYY-MM-DD HH:MM:SS` (required if `is_scheduled` is true)."},"timezone":{"type":"string","default":"UTC","description":"Timezone for scheduled execution."},"concurrent_call_limit":{"type":"number","default":1,"minimum":1,"description":"Maximum number of concurrent calls allowed."},"enabled_reschedule_call":{"type":"boolean","default":false,"description":"Enable automatic call rescheduling. When enabled the system can reschedule unreachable calls."},"retry_config":{"type":"object","description":"Auto-retry configuration object containing retry settings.","properties":{"auto_retry":{"type":"boolean","default":false},"auto_retry_schedule":{"type":"string","enum":["immediately","next_day","scheduled_time"],"description":"When to retry failed calls."},"retry_schedule_days":{"type":"number","default":0,"minimum":0,"description":"Days to wait before a scheduled retry."},"retry_schedule_hours":{"type":"number","default":0,"minimum":0,"description":"Hours to wait before a scheduled retry."},"retry_limit":{"type":"number","default":1,"minimum":1,"maximum":10,"description":"Retry attempts, 1 to 10. To disable retries omit it and\nleave `auto_retry` false; never send `0`. Ignored when\n`retry_steps` is set.\n"},"retry_steps":{"type":"array","minItems":1,"maxItems":10,"description":"A different delay for each retry, in order: retry 1\nwaits for the first step, retry 2 for the second, and\nso on. When set, it replaces `auto_retry_schedule`,\n`retry_schedule_days`, `retry_schedule_hours` and\n`retry_limit`: a contact gets one retry per step. Each\ndelay is at most 30 days. A retry that falls outside\nthe campaign's daily calling hours waits until they\nopen again.\n\nA `days` step can also name a time of day with `at`:\n`{\"delay\": 1, \"unit\": \"days\", \"at\": \"10:00\"}` is 10:00\nthe next day, and `{\"delay\": 0, \"unit\": \"days\", \"at\":\n\"16:00\"}` the same day at 16:00. The date and time are\nread in the calling window's timezone,\n`daily_stop_timezone`; a campaign without a window\n(`enable_daily_hard_stop` off) uses its `timezone`.\nEach retry counts from the try before it; a time that\nhas already passed moves to the next day.\n","items":{"type":"object","required":["delay","unit"],"properties":{"delay":{"type":"number","minimum":0,"description":"How long to wait, in `unit`. `0` retries right away."},"unit":{"type":"string","enum":["minutes","hours","days"]},"at":{"type":"string","pattern":"^([01][0-9]|2[0-3]):[0-5][0-9]$","description":"Time of day, `HH:MM` (24-hour) in\n`daily_stop_timezone`, or in `timezone` when\n`enable_daily_hard_stop` is off. Only on a\n`days` step; `delay: 0` means the same day.\n"}}}},"retry_unanswered":{"type":"string","enum":["off","no_reply","no_reply_or_short","model"],"default":"off","description":"Also retry calls that connected but got no conversation.\n`no_reply`: the contact never spoke. `no_reply_or_short`:\nthe contact never spoke, or the call lasted at most\n`retry_unanswered_max_seconds`. `model`: the contact\nnever spoke, or post-call analysis read the transcript\nand found no real conversation. Retries follow the same\nschedule or steps as failed calls.\n"},"retry_unanswered_max_seconds":{"type":"number","default":10,"minimum":1,"maximum":120,"description":"Under `no_reply_or_short`, a call this long or shorter\n(in seconds) counts as unanswered.\n"}}}},"description":"The JSON request body."}},"required":["requestBody"]},
@@ -472,13 +514,12 @@ operate a campaign once it runs.
472
514
  }],
473
515
  ["addBulkCallContact", {
474
516
  name: "addBulkCallContact",
475
- description: `Push a single contact into a dynamic bulk-call campaign in real
476
- time. Dynamic campaigns are created from the dashboard (Bulk Call
477
- > Create New Campaign > Dynamic Campaign) and stay alive waiting
478
- for contacts, so this webhook is how you feed them from a CRM,
479
- form, or automation platform. The contact is queued immediately,
480
- and the campaign starts calling it as soon as it is within
481
- operating hours.
517
+ description: `Push one contact into a dynamic bulk-call campaign.
518
+
519
+ Dynamic campaigns are created from the dashboard (Bulk Call > Create New
520
+ Campaign > Dynamic Campaign) and wait for contacts. Use this webhook to feed
521
+ them from a CRM, form or automation platform. The contact is queued at once.
522
+ The campaign calls it as soon as it is within operating hours.
482
523
 
483
524
  (Tags: Bulk calls)`,
484
525
  inputSchema: {"type":"object","properties":{"campaign_id":{"type":"number","description":"ID of the dynamic campaign to add the contact to."},"requestBody":{"type":"object","required":["to_number"],"properties":{"to_number":{"type":"string","description":"Contact phone number in international format (e.g., +15551234567)."},"custom_variables":{"type":"object","description":"Key-value pairs passed to the agent as context for this\ncall, so the agent can reference them during the\nconversation (e.g. the contact's name or reason for the\ncall). Match these keys to the variables used in your\nagent's welcome message or prompt.\n","additionalProperties":true},"metadata":{"type":"object","description":"Key-value pairs stored on the contact for your own\ntracking (e.g. CRM or lead IDs). Not shared with the\nagent.\n","additionalProperties":true},"previous_from_number":{"type":"string","description":"The number that called this person last. With\n`call_back_from_different_number` on, the call goes out\nfrom another number in the pool.\n"}},"description":"The JSON request body."}},"required":["campaign_id","requestBody"]},
@@ -531,13 +572,17 @@ operating hours.
531
572
  }],
532
573
  ["listBulkCallLines", {
533
574
  name: "listBulkCallLines",
534
- description: `Per-contact results for a campaign: what happened on each call, the
535
- variables you sent with that contact, and a pointer to the recording.
575
+ description: `List per-contact results for a campaign.
576
+
577
+ Each row has what happened on the call, the variables you sent, and
578
+ \`call.recording_id\`.
536
579
 
537
580
  ## Paging
538
581
 
539
- There is one rule. Call it with no \`cursor\`, then keep passing back the
540
- \`next_cursor\` you were handed until it comes back \`null\`.
582
+ Call with no \`cursor\`. Then pass back the \`next_cursor\` you were given until
583
+ it is \`null\`. Rows come oldest first. \`pagesize\` defaults to 30 and goes up
584
+ to 150. Cursors are opaque, so never build one. No contact is skipped or
585
+ returned twice, even while the campaign dials.
541
586
 
542
587
  \`\`\`
543
588
  cursor = None
@@ -548,17 +593,10 @@ while True:
548
593
  if not cursor: break
549
594
  \`\`\`
550
595
 
551
- Each call returns a page of rows, oldest first: \`pagesize\` goes up to
552
- 150 and defaults to 30. Cursors are opaque, so pass back the string you
553
- were given and never build one. No contact is skipped or returned
554
- twice, even while the campaign is still dialing.
555
-
556
596
  ## Transcripts are not in the row
557
597
 
558
- Each row carries \`call.recording_id\`, not the conversation. Transcripts
559
- reach 212 KB, so carrying them here would make one page tens of
560
- megabytes. Fetch the one you want from
561
- \`GET /calls/logs/{recording_id}\`.
598
+ Transcripts reach 212 KB, so rows carry only \`call.recording_id\`. Fetch the
599
+ transcript from \`GET /calls/logs/{recording_id}\`.
562
600
 
563
601
  (Tags: Bulk calls)`,
564
602
  inputSchema: {"type":"object","properties":{"bulk_call_id":{"type":"number","description":"Id of the bulk call campaign."},"cursor":{"type":"string","description":"The `next_cursor` from your previous response. Omit it on the first\nrequest. Opaque: pass it back unchanged.\n"},"pagesize":{"type":"integer","minimum":1,"default":30,"maximum":150,"description":"Rows per page. Above 150 the request is refused."},"call_status":{"type":"string","enum":["Pending","In Progress","completed","voicemail_detected","no-answer","busy","Failed","Skipped","retry_scheduled","cancelled"],"description":"Return only contacts in this state."},"interaction_status":{"type":"string","description":"Return only contacts with this interaction outcome."},"search":{"type":"string","description":"An exact phone number, matched against the contact's number and the\nnumber that called it. Not a substring search.\n"},"include_total":{"type":"boolean","default":false,"description":"Add `total_records` to the response. It costs a count over the whole\nfiltered campaign, so it is off unless you ask. Ask for it once to\nfill a header, not on every page of a walk.\n"}},"required":["bulk_call_id"]},
@@ -590,13 +628,14 @@ the number's lifetime total across every cycle.
590
628
  }],
591
629
  ["addBulkCallNumber", {
592
630
  name: "addBulkCallNumber",
593
- description: `Add one of your numbers to the campaign's rotation pool. Works while the
594
- campaign is running, which is how you bring in a fresh number when the
595
- pool is running out of healthy ones.
631
+ description: `Add one of your numbers to the campaign's rotation pool.
632
+
633
+ It works while the campaign runs, so use it to bring in a fresh number when
634
+ healthy ones run low.
596
635
 
597
- The number must belong to you and must not already be in the pool. A
598
- number with no agent attached gets this campaign's agent attached
599
- automatically; a number attached to a **different** agent is refused.
636
+ The number must be yours and not already in the pool. A number with no agent
637
+ gets this campaign's agent attached. A number attached to a **different**
638
+ agent is refused.
600
639
 
601
640
  (Tags: Bulk calls)`,
602
641
  inputSchema: {"type":"object","properties":{"bulk_call_id":{"type":"number","description":"Id of the bulk call campaign."},"requestBody":{"type":"object","required":["phone_number_id"],"properties":{"phone_number_id":{"type":"number","description":"One of your numbers, from List phone numbers."}},"description":"The JSON request body."}},"required":["bulk_call_id","requestBody"]},
@@ -612,16 +651,13 @@ automatically; a number attached to a **different** agent is refused.
612
651
  name: "setBulkCallNumberActive",
613
652
  description: `Stop or resume dialing from one number in the pool.
614
653
 
615
- Pausing is what you want when a number starts going bad mid-campaign:
616
- dialing moves to the next number in sequence and the paused number keeps
617
- its history and counters. The last active number of a running campaign
618
- cannot be paused, since the campaign would have nothing to dial from.
654
+ Pause a number that goes bad mid-campaign. Dialing moves to the next number,
655
+ and the paused number keeps its history and counters. You cannot pause the
656
+ last active number of a running campaign.
619
657
 
620
- Send the state you want rather than a toggle, so retrying the same
621
- request is harmless.
658
+ Send the state you want, not a toggle, so a retry is harmless.
622
659
 
623
- \`assignment_id\` is the number's id **within this campaign's pool**, from
624
- List rotation pool. It is not the \`phone_number_id\`.
660
+ \`assignment_id\` is the number's id **within this campaign's pool**, from List rotation pool. It is not the \`phone_number_id\`.
625
661
 
626
662
  (Tags: Bulk calls)`,
627
663
  inputSchema: {"type":"object","properties":{"bulk_call_id":{"type":"number","description":"Id of the bulk call campaign."},"assignment_id":{"type":"number","description":"The `assignment_id` from List rotation pool."},"requestBody":{"type":"object","required":["is_active"],"properties":{"is_active":{"type":"boolean","description":"`false` pauses the number, `true` resumes it."}},"description":"The JSON request body."}},"required":["bulk_call_id","assignment_id","requestBody"]},
@@ -638,18 +674,14 @@ List rotation pool. It is not the \`phone_number_id\`.
638
674
  description: `Add up to 1000 contacts to a campaign in one request.
639
675
 
640
676
  This is the batch form of Add contact to dynamic campaign. Prefer it
641
- whenever you have more than a handful: one request of 500 contacts is
642
- far cheaper than 500 requests, on your side and ours.
677
+ whenever you have more than a handful of contacts.
643
678
 
644
- Repeated numbers are kept, not merged. If the same number appears twice
645
- with different variables, it is called twice, because two rows for one
646
- number usually means two real reasons to call.
679
+ Repeated numbers are kept, not merged. The same number with different
680
+ variables is called twice.
647
681
 
648
- Rows that fail validation are reported in \`rejected\` and the rest are
649
- still added, so a single bad number does not lose the batch. A row that
650
- is missing a column the campaign's \`call_conditions\` need is reported in
651
- \`rejected\`; the condition values themselves are not evaluated on this
652
- route.
682
+ Rows that fail validation are reported in \`rejected\`, and the rest are still
683
+ added. A row missing a column that the campaign's \`call_conditions\` need is
684
+ also rejected. The condition values are not evaluated on this route.
653
685
 
654
686
  (Tags: Bulk calls)`,
655
687
  inputSchema: {"type":"object","properties":{"campaign_id":{"type":"number","description":"Id of the bulk call campaign."},"requestBody":{"type":"object","required":["contacts"],"properties":{"contacts":{"type":"array","maxItems":1000,"description":"Each row needs `to_number`. Note this differs from the\n`contact_list` on Create bulk call, which uses\n`phone_number` and takes loose keys: here the variables go\nin an explicit `custom_variables` object.\n","items":{"type":"object","required":["to_number"],"properties":{"to_number":{"type":"string","description":"Number to call, in international format."},"custom_variables":{"type":"object","description":"Passed to the agent as context for this call, so it\ncan use them in the conversation.\n","additionalProperties":true},"metadata":{"type":"object","description":"Stored with the contact and returned on its row in\nBulk call results. Not shown to the agent.\n","additionalProperties":true},"previous_from_number":{"type":"string","description":"The number that called this person last. With\n`call_back_from_different_number` on, the call goes\nout from another number in the pool.\n"}}}}},"description":"The JSON request body."}},"required":["campaign_id","requestBody"]},
@@ -682,11 +714,11 @@ scheduled, or finished cannot be started.
682
714
  }],
683
715
  ["setBulkCallConcurrency", {
684
716
  name: "setBulkCallConcurrency",
685
- description: `Change how many calls the campaign places at once, including while it is
686
- running. Raise it to finish sooner, lower it if your team cannot keep up
687
- with transfers or your numbers are being answered less.
717
+ description: `Change how many calls the campaign places at once, even while it runs.
688
718
 
689
- The ceiling is your account's concurrency limit.
719
+ Raise it to finish sooner. Lower it if your team cannot keep up with
720
+ transfers or fewer calls are answered. The ceiling is your account's
721
+ concurrency limit.
690
722
 
691
723
  (Tags: Bulk calls)`,
692
724
  inputSchema: {"type":"object","properties":{"bulk_call_id":{"type":"number","description":"Id of the bulk call campaign."},"requestBody":{"type":"object","required":["concurrent_call_limit"],"properties":{"concurrent_call_limit":{"type":"number","minimum":1,"description":"Calls to place at once."}},"description":"The JSON request body."}},"required":["bulk_call_id","requestBody"]},
@@ -700,14 +732,14 @@ The ceiling is your account's concurrency limit.
700
732
  }],
701
733
  ["setBulkCallRotation", {
702
734
  name: "setBulkCallRotation",
703
- description: `Change how a campaign uses its number pool. Send only the fields you
704
- want to change. At least one field is required.
735
+ description: `Change how a campaign uses its number pool.
705
736
 
706
- This works while the campaign status is \`draft\`, \`scheduled\`,
707
- \`in_progress\`, \`waiting\`, \`paused\`, \`auto_paused\` or \`retry_scheduled\`.
708
- Any other status is refused with \`Cannot edit rotation for status:
709
- <status>\`. To change which numbers are in the pool, use the numbers
710
- endpoints.
737
+ Send only the fields you want to change. At least one field is required.
738
+
739
+ It works while the status is \`draft\`, \`scheduled\`, \`in_progress\`, \`waiting\`,
740
+ \`paused\`, \`auto_paused\` or \`retry_scheduled\`. Any other status is refused
741
+ with \`Cannot edit rotation for status: <status>\`. To change which numbers
742
+ are in the pool, use the numbers endpoints.
711
743
 
712
744
  (Tags: Bulk calls)`,
713
745
  inputSchema: {"type":"object","properties":{"bulk_call_id":{"type":"number","description":"Id of the bulk call campaign."},"requestBody":{"type":"object","properties":{"strategy":{"type":"string","enum":["fixed_count","cpr_threshold","both","none"],"description":"When to move to the next number: every `calls_per_number`\ncalls, on low health score, both, or never.\n"},"calls_per_number":{"type":"number","description":"Calls before moving on. Used by `fixed_count` and `both`."},"health_threshold":{"type":"number","description":"Health score below which a number is rotated away from.\nUsed by `cpr_threshold` and `both`.\n"},"fallback":{"type":"string","enum":["pause","continue_best"],"description":"When every number is unhealthy: `pause` the campaign, or\n`continue_best` with the healthiest one.\n"},"call_back_from_different_number":{"type":"boolean","description":"When on, a repeat call to the same person goes out from a\ndifferent number than the one that called them last. Needs\ntwo or more numbers in the pool. Must be `true` or `false`.\n"},"skip_known_invalid_numbers":{"type":"boolean","description":"When on, a contact is not dialed if the carrier said its\nnumber does not exist, in any campaign of your organization\nin the last 14 days. Must be `true` or `false`.\n"}},"description":"The JSON request body."}},"required":["bulk_call_id","requestBody"]},
@@ -721,29 +753,22 @@ endpoints.
721
753
  }],
722
754
  ["retryBulkCall", {
723
755
  name: "retryBulkCall",
724
- description: `Re-queue contacts that did not connect, without creating a new campaign.
756
+ description: `Re-queue contacts that did not connect, without a new campaign.
725
757
 
726
- Use it after a campaign finishes with more no-answers than you expected,
727
- or when the reason was on your side (a bad window, a number that was
728
- having a bad day). Retried contacts keep their original variables.
758
+ Use it after a campaign finishes with more no-answers than expected, or when
759
+ the cause was on your side. Retried contacts keep their original variables.
729
760
 
730
761
  The retry is refused in these cases:
731
762
 
732
- - The campaign status is not \`completed\`. The error is
733
- \`Cannot retry calls. Current status: <status>\`.
734
- - Auto retry is on and some contacts are still \`Pending\` or
735
- \`In Progress\`. The error is \`Cannot retry while calls are still in
736
- progress and auto retry is enabled\`.
737
- - A value in \`failure_reasons\` is not one of the allowed statuses. The
738
- error is \`Invalid failure reason(s)\` and lists the allowed values.
739
- - No contact matches. The error is \`No failed calls found to retry
740
- matching criteria\`.
741
-
742
- Each contact is retried from its latest call only. When the campaign has
763
+ - The status is not \`completed\`. The error is \`Cannot retry calls. Current status: <status>\`.
764
+ - Auto retry is on and some contacts are still \`Pending\` or \`In Progress\`. The error is \`Cannot retry while calls are still in progress and auto retry is enabled\`.
765
+ - A value in \`failure_reasons\` is not an allowed status. The error is \`Invalid failure reason(s)\` and lists the allowed values.
766
+ - No contact matches. The error is \`No failed calls found to retry matching criteria\`.
767
+
768
+ Each contact is retried from its latest call only. With
743
769
  \`skip_known_invalid_numbers\` on, contacts whose last call ended with the
744
- carrier saying the number does not exist are not retried. This endpoint
745
- retries calls that did not connect. It does not retry connected calls
746
- with no conversation.
770
+ carrier saying the number does not exist are skipped. Connected calls with
771
+ no conversation are not retried.
747
772
 
748
773
  (Tags: Bulk calls)`,
749
774
  inputSchema: {"type":"object","properties":{"bulk_call_id":{"type":"number","description":"Id of the bulk call campaign."},"requestBody":{"type":"object","properties":{"retry_strategy":{"type":"string","default":"all","description":"Which contacts to re-queue. `all` takes everything that did\nnot connect. `specific` re-queues only the statuses listed\nin `failure_reasons`.\n"},"failure_reasons":{"type":"array","description":"Statuses to re-queue. Read only when `retry_strategy` is\n`specific`; for example `no-answer` and `busy`. Ignored when\n`retry_strategy` is `all`.\n","items":{"type":"string","enum":["failed","Failed","no-answer","No Answer","busy","Busy","cancelled","canceled","voicemail_detected"]}}},"description":"The JSON request body."}},"required":["bulk_call_id"]},
@@ -757,9 +782,9 @@ with no conversation.
757
782
  }],
758
783
  ["setBulkCallDailyTimeControl", {
759
784
  name: "setBulkCallDailyTimeControl",
760
- description: `Restrict a campaign to a daily calling window, in the campaign's
761
- timezone. Outside the window the campaign holds rather than finishing,
762
- and resumes the next day.
785
+ description: `Limit a campaign to a daily calling window in its timezone.
786
+
787
+ Outside the window the campaign holds, then resumes the next day.
763
788
 
764
789
  (Tags: Bulk calls)`,
765
790
  inputSchema: {"type":"object","properties":{"bulk_call_id":{"type":"number","description":"Id of the bulk call campaign."},"requestBody":{"type":"object","required":["enable_daily_hard_stop","enable_daily_auto_start"],"properties":{"enable_daily_hard_stop":{"type":"boolean","description":"Stop dialing at `daily_stop_time` each day."},"daily_stop_time":{"type":"number","description":"Hour of day to stop, 0 to 23. Fractions are allowed, so\n`17.5` is 17:30. Required when the hard stop is on.\n"},"daily_stop_timezone":{"type":"string","description":"Timezone for the stop time."},"enable_daily_auto_start":{"type":"boolean","description":"Resume dialing at `daily_start_time` each day."},"daily_start_time":{"type":"number","description":"Hour of day to resume, 0 to 23. Required when auto start\nis on.\n"},"daily_start_timezone":{"type":"string","description":"Timezone for the start time."}},"description":"The JSON request body."}},"required":["bulk_call_id","requestBody"]},
@@ -879,15 +904,15 @@ from the OmniDimension number shop or imported your own.
879
904
  }],
880
905
  ["searchPhoneNumbers", {
881
906
  name: "searchPhoneNumbers",
882
- description: `Search the OmniDimension number shop for phone numbers available to buy
883
- in a region. Price and validity are flat per region, so every result
884
- shows the same \`monthly_rental_usd\` and \`validity_days\`, and that is the
885
- exact amount a purchase will charge.
907
+ description: `Search the OmniDimension number shop for numbers you can buy in a region.
908
+
909
+ Price and validity are flat per region. Every result shows the same
910
+ \`monthly_rental_usd\` and \`validity_days\`, and a purchase charges exactly
911
+ that.
886
912
 
887
- A region can have more than one carrier, each stocking different
888
- number series. Pass the \`carrier\` you want; the response names the
889
- carrier its results came from, and that is the carrier a purchase has
890
- to pass.
913
+ A region can have several carriers, each with different number series. Pass
914
+ the \`carrier\` you want. The response names the carrier its results came
915
+ from, and a purchase must pass that carrier.
891
916
 
892
917
  (Tags: Phone numbers)`,
893
918
  inputSchema: {"type":"object","properties":{"region":{"type":"string","enum":["IN","US"],"description":"Region to search in. `IN` and `US` both serve numbers. Which\nregions answer is configuration, so a region with no carrier\nenabled returns `404 not_available` rather than an empty list.\n"},"carrier":{"type":"string","description":"Which carrier's stock to search: carriers in a region do not sell\nthe same numbers. Required where a region has more than one\ncarrier; omitting it there returns `409 carrier_required` naming\nthe region's carriers and what each one stocks.\n"},"pattern":{"type":"string","description":"Digits or prefix to match within the number."},"page":{"type":"number","minimum":1,"default":1,"description":"Page of results to return."},"limit":{"type":"number","minimum":1,"maximum":150,"default":20,"description":"Results per page."}},"required":["region"]},
@@ -901,8 +926,9 @@ to pass.
901
926
  }],
902
927
  ["purchasePhoneNumber", {
903
928
  name: "purchasePhoneNumber",
904
- description: `Buy a phone number from the OmniDimension number shop. The monthly
905
- rental comes out of your wallet and the number is added to your
929
+ description: `Buy a phone number from the OmniDimension number shop.
930
+
931
+ The monthly rental comes out of your wallet. The number is added to your
906
932
  account, ready to attach to an agent.
907
933
 
908
934
  (Tags: Phone numbers)`,
@@ -917,9 +943,10 @@ account, ready to attach to an agent.
917
943
  }],
918
944
  ["releasePhoneNumber", {
919
945
  name: "releasePhoneNumber",
920
- description: `Give up a phone number and stop its rental, so it is not charged at the
921
- next renewal. Only a number currently allocated to the account can be
922
- released.
946
+ description: `Release a phone number and stop its rental.
947
+
948
+ It is not charged at the next renewal. Only a number currently allocated to
949
+ the account can be released.
923
950
 
924
951
  (Tags: Phone numbers)`,
925
952
  inputSchema: {"type":"object","properties":{"requestBody":{"type":"object","required":["phone_number"],"properties":{"phone_number":{"type":"string","description":"The number to release."}},"description":"The JSON request body."}},"required":["requestBody"]},
@@ -933,11 +960,12 @@ released.
933
960
  }],
934
961
  ["setPhoneNumberAutoRenew", {
935
962
  name: "setPhoneNumberAutoRenew",
936
- description: `Turn auto-renew off or back on for a number bought from the number shop.
937
- With auto-renew off, the number is not charged again: it keeps working
938
- until the end of the period already paid for and is then released. Turn
939
- it back on before that date and it renews as normal. Sending the value
940
- the number already has changes nothing and still succeeds.
963
+ description: `Turn auto-renew on or off for a number bought from the number shop.
964
+
965
+ With auto-renew off, the number is not charged again. It works until the end
966
+ of the period already paid for, then it is released. Turn auto-renew on
967
+ before that date and the number renews as normal. Sending the value the
968
+ number already has changes nothing and still succeeds.
941
969
 
942
970
  (Tags: Phone numbers)`,
943
971
  inputSchema: {"type":"object","properties":{"requestBody":{"type":"object","required":["phone_number","auto_renew"],"properties":{"phone_number":{"type":"string","description":"The number to switch."},"auto_renew":{"type":"boolean","description":"`false` stops renewal, `true` turns it back on. Must be a JSON boolean: a string such as `\"false\"`, a number, or a missing value is refused."}},"description":"The JSON request body."}},"required":["requestBody"]},
@@ -1029,15 +1057,15 @@ the number already has changes nothing and still succeeds.
1029
1057
  }],
1030
1058
  ["listVoices", {
1031
1059
  name: "listVoices",
1032
- description: `Retrieve the voices your organization can use, with filtering and
1033
- pagination. Use \`provider=featured\` for OmniDimension voices, the
1034
- recommended starting point, in the order the dashboard shows them.
1035
- Cartesia voices are the next choice.
1060
+ description: `List the voices your organization can use, with filters and pagination.
1036
1061
 
1037
- Each voice keeps its own \`service\`: save that as the agent's voice
1038
- provider. A provider your organization cannot use returns a 400.
1039
- Cartesia and ElevenLabs support filtering by name, language, accent,
1040
- and gender. Other providers support pagination only.
1062
+ Use \`provider=featured\` for OmniDimension voices in the order the dashboard
1063
+ shows them. They are the recommended start. Cartesia voices are next.
1064
+
1065
+ Each voice keeps its own \`service\`: save it as the agent's voice provider. A
1066
+ provider your organization cannot use returns a 400. Cartesia and ElevenLabs
1067
+ support filtering by name, language, accent and gender. Other providers
1068
+ support pagination only.
1041
1069
 
1042
1070
  (Tags: Providers)`,
1043
1071
  inputSchema: {"type":"object","properties":{"provider":{"type":"string","description":"Provider to list voices from. Omit to list every voice your organization can use.\n`featured` lists OmniDimension voices and is the recommended choice, followed by\n`cartesia`. A provider your organization cannot use returns a 400.\n"},"search":{"type":"string","description":"Substring match against voice name or description. Cartesia and ElevenLabs."},"language":{"type":"string","description":"ISO language code (e.g. `en`, `hi`, `es`). Cartesia and ElevenLabs."},"accent":{"type":"string","description":"Accent label (e.g. `american`, `british`). Cartesia and ElevenLabs."},"gender":{"type":"string","enum":["male","female"],"description":"Filter voices by gender. Cartesia and ElevenLabs."},"page":{"type":"integer","minimum":1,"default":1,"description":"1-indexed page number."},"page_size":{"type":"integer","minimum":1,"default":30,"maximum":100,"description":"Voices per page. Capped at 100."}}},
@@ -1103,26 +1131,26 @@ and gender. Other providers support pagination only.
1103
1131
  }],
1104
1132
  ["getAccountBalance", {
1105
1133
  name: "getAccountBalance",
1106
- description: `Read your organization's wallet: the remaining balance, the minutes
1107
- it buys at your rates, your plan, your concurrency headroom, and
1108
- whether auto-recharge will refill it.
1134
+ description: `Read your organization's wallet balance, plan and auto-recharge state.
1135
+
1136
+ The response also has the minutes the balance buys at your rates and your
1137
+ concurrency headroom.
1109
1138
 
1110
- Use it before a campaign, or on a schedule, so you find out you are
1111
- low on credit from this endpoint rather than from a call failing
1112
- with \`402 payment_required\`.
1139
+ Call it before a campaign, or on a schedule, so you learn about low credit
1140
+ here and not from a call failing with \`402 payment_required\`.
1113
1141
 
1114
- The response always describes the organization the API key belongs
1115
- to. There is no parameter for reading another account; resellers
1116
- read a client's figures through the Reseller endpoints.
1142
+ The response always describes the organization the API key belongs to. There
1143
+ is no parameter for another account. Resellers read a client's figures
1144
+ through the Reseller endpoints.
1117
1145
 
1118
- A balance at or below zero does not always mean calls will stop. An
1119
- organization on usage-based billing (\`plan.is_usage_based\`) keeps
1120
- placing calls and is metered to its payment method instead, so check
1121
- that flag before treating a zero balance as a stop condition.
1146
+ A balance at or below zero does not always stop calls. An organization on
1147
+ usage-based billing (\`plan.is_usage_based\`) keeps placing calls and is
1148
+ metered to its payment method. Check that flag before treating zero as a
1149
+ stop condition.
1122
1150
 
1123
- The API key's user needs Billing access in your organization. If
1124
- you get a \`403\`, an administrator can grant it when Billing is
1125
- enabled for your organization; when it is not, contact support.
1151
+ The API key's user needs Billing access in your organization. If you get a
1152
+ \`403\`, an administrator can grant it when Billing is enabled for your
1153
+ organization. When it is not, contact support.
1126
1154
 
1127
1155
  (Tags: Account)`,
1128
1156
  inputSchema: {"type":"object","properties":{}},
@@ -1136,12 +1164,13 @@ enabled for your organization; when it is not, contact support.
1136
1164
  }],
1137
1165
  ["listClonedVoices", {
1138
1166
  name: "listClonedVoices",
1139
- description: `Your cloned voices, oldest first, one cursor page at a time. Call it with
1140
- no \`cursor\`, then pass back the \`next_cursor\` you were handed until it is
1167
+ description: `List your cloned voices, oldest first, one cursor page at a time.
1168
+
1169
+ Call it with no \`cursor\`. Then pass back each \`next_cursor\` until it is
1141
1170
  \`null\`.
1142
1171
 
1143
- Once a voice is \`ready\`, its \`voice_id\` is the provider voice id to put
1144
- in an agent's \`voice.voice_id\` with \`voice.provider: cartesia\`.
1172
+ When a voice is \`ready\`, put its \`voice_id\` in an agent's \`voice.voice_id\`
1173
+ with \`voice.provider: cartesia\`.
1145
1174
 
1146
1175
  (Tags: Voice cloning)`,
1147
1176
  inputSchema: {"type":"object","properties":{"limit":{"type":"number","default":20,"maximum":100,"description":"Rows per page. Above 100 the request is refused."},"cursor":{"type":"string","description":"The `next_cursor` from your previous response. Omit it on the first\nrequest. Opaque: pass it back unchanged.\n"}}},
@@ -1196,9 +1225,11 @@ still \`processing\` cannot be deleted.
1196
1225
  }],
1197
1226
  ["getClonedVoiceSample", {
1198
1227
  name: "getClonedVoiceSample",
1199
- description: `Stream the generated mp3 sample of a cloned voice. Only the owner can
1200
- fetch it. \`404\` (\`sample_not_ready\`) when no sample exists yet. The
1201
- request needs your API key in the \`Authorization\` header.
1228
+ description: `Stream the generated mp3 sample of a cloned voice.
1229
+
1230
+ Only the owner can fetch it. Send your API key in the \`Authorization\`
1231
+ header. If no sample exists yet, the call returns \`404\`
1232
+ (\`sample_not_ready\`).
1202
1233
 
1203
1234
  (Tags: Voice cloning)`,
1204
1235
  inputSchema: {"type":"object","properties":{"voice_id":{"type":"number","description":"Id of the cloned voice."}},"required":["voice_id"]},
@@ -1225,7 +1256,11 @@ request needs your API key in the \`Authorization\` header.
1225
1256
  }],
1226
1257
  ["listWorkflowNodeTypes", {
1227
1258
  name: "listWorkflowNodeTypes",
1228
- description: `Search the node types a workflow can use, such as \`whatsapp\`, \`voice_ai\` or \`conditional\`. Call it first when you do not know which node to add. Then call \`getWorkflowNodeType\` for the settings of one type.
1259
+ description: `Search the node types a workflow can use.
1260
+
1261
+ Examples are \`whatsapp\`, \`voice_ai\` and \`conditional\`. Call it first when
1262
+ you do not know which node to add. Then call \`getWorkflowNodeType\` for one
1263
+ type's settings.
1229
1264
 
1230
1265
  (Tags: Workflows)`,
1231
1266
  inputSchema: {"type":"object","properties":{"q":{"type":"string","description":"Words to match against the type, label and description, such as `whatsapp`."},"category":{"type":"string","enum":["triggers","messaging","calls","flow","ai","crm","integrations"],"description":"Only types in this category."}}},
@@ -1239,7 +1274,11 @@ request needs your API key in the \`Authorization\` header.
1239
1274
  }],
1240
1275
  ["getWorkflowNodeType", {
1241
1276
  name: "getWorkflowNodeType",
1242
- description: `The settings one node type reads, with their types, required flags and outputs. Call it before you add or edit a node, because its \`fields\` are the keys of the node's \`config\`. Use \`detail=full\` only when you need help text and examples.
1277
+ description: `Get the settings one node type reads.
1278
+
1279
+ Call it before you add or edit a node. Its \`fields\` are the keys of the
1280
+ node's \`config\`. Use \`detail=full\` only when you need help text and
1281
+ examples.
1243
1282
 
1244
1283
  (Tags: Workflows)`,
1245
1284
  inputSchema: {"type":"object","properties":{"node_type":{"type":"string","description":"A node type from `listWorkflowNodeTypes`, such as `whatsapp`."},"detail":{"type":"string","enum":["minimal","full"],"default":"minimal","description":"`full` adds descriptions, examples and `output_example`."}},"required":["node_type"]},
@@ -1253,7 +1292,11 @@ request needs your API key in the \`Authorization\` header.
1253
1292
  }],
1254
1293
  ["listWorkflowFieldOptions", {
1255
1294
  name: "listWorkflowFieldOptions",
1256
- description: `The choices for one \`ref\` field of a node type, such as the phone numbers, agents or integrations in your account. Call it for every \`ref\` field and never guess an id. If it returns \`400 no_options\`, the field is not chosen from a list, so ask the user for the value.
1295
+ description: `List the choices for one \`ref\` field of a node type.
1296
+
1297
+ Examples are the phone numbers, agents or integrations in your account. Call
1298
+ it for every \`ref\` field and never guess an id. If it returns \`400
1299
+ no_options\`, the field is not a list choice, so ask the user for the value.
1257
1300
 
1258
1301
  (Tags: Workflows)`,
1259
1302
  inputSchema: {"type":"object","properties":{"node_type":{"type":"string","description":"A node type from `listWorkflowNodeTypes`, such as `whatsapp`."},"field":{"type":"string","description":"A field name from `getWorkflowNodeType`."},"depends":{"type":"number","description":"The value of the field this one depends on (`depends_on` in the node type), such as the chosen phone number id."}},"required":["node_type","field"]},
@@ -1267,7 +1310,9 @@ request needs your API key in the \`Authorization\` header.
1267
1310
  }],
1268
1311
  ["listWorkflows", {
1269
1312
  name: "listWorkflows",
1270
- description: `Your workflows, oldest first, one cursor page at a time. Use it to find a workflow id. Pass back \`next_cursor\` until it is \`null\`.
1313
+ description: `List your workflows, oldest first, one cursor page at a time.
1314
+
1315
+ Use it to find a workflow id. Pass back \`next_cursor\` until it is \`null\`.
1271
1316
 
1272
1317
  (Tags: Workflows)`,
1273
1318
  inputSchema: {"type":"object","properties":{"limit":{"type":"number","default":20,"minimum":1,"maximum":100,"description":"Rows per page."},"cursor":{"type":"string","description":"The `next_cursor` from the previous page. Omit it on the first request. Pass it back unchanged."}}},
@@ -1281,7 +1326,11 @@ request needs your API key in the \`Authorization\` header.
1281
1326
  }],
1282
1327
  ["createWorkflow", {
1283
1328
  name: "createWorkflow",
1284
- description: `Create a workflow with a draft. Without \`graph\`, the draft holds one \`trigger\` node, ready for \`editWorkflow\` ops. Pass \`graph\` only to start from a complete graph. The response carries the \`revision\` you need to edit.
1329
+ description: `Create a workflow with a draft.
1330
+
1331
+ Without \`graph\`, the draft holds one \`trigger\` node, ready for
1332
+ \`editWorkflow\` ops. Pass \`graph\` only to start from a complete graph. The
1333
+ response carries the \`revision\` you need to edit.
1285
1334
 
1286
1335
  (Tags: Workflows)`,
1287
1336
  inputSchema: {"type":"object","properties":{"requestBody":{"type":"object","required":["name"],"properties":{"name":{"type":"string","description":"A non-empty name."},"graph":{"type":"object","description":"A complete graph to start a workflow from, in the same shape `getWorkflow`\nreturns under `draft`. A workflow you read can be sent back as a new one.\nIt is built with the same checks as `editWorkflow` ops. Most callers skip it\nand build with `editWorkflow` instead.\n","required":["nodes","edges"],"properties":{"nodes":{"type":"array","items":{"type":"object","required":["id","type"],"properties":{"id":{"type":"string","description":"Lowercase letters, digits and underscores, starting with a letter. Later nodes read this node's output as `{{ context.<id>.<field> }}`."},"type":{"type":"string","description":"A node type from `listWorkflowNodeTypes`."},"label":{"type":"string"},"position":{"type":"object","properties":{"x":{"type":"number"},"y":{"type":"number"}}},"config":{"type":"object","additionalProperties":true,"description":"The node's settings. The fields come from `getWorkflowNodeType`."}}}},"edges":{"type":"array","items":{"type":"object","required":["from","to"],"properties":{"from":{"type":"string","description":"Id of the node the edge starts at."},"to":{"type":"string","description":"Id of the node the edge ends at."},"handle":{"type":"string","description":"The output of the `from` node. Omit it, or send `default`, for a plain node's only output."}}}}}}},"description":"The JSON request body."}},"required":["requestBody"]},
@@ -1295,7 +1344,11 @@ request needs your API key in the \`Authorization\` header.
1295
1344
  }],
1296
1345
  ["getWorkflow", {
1297
1346
  name: "getWorkflow",
1298
- description: `One workflow with its draft, status and \`revision\`. Call it before every edit to get the current \`revision\`. Use \`view=structure\` to see nodes and edges without config on a large workflow. Secrets read back as \`********\`.
1347
+ description: `Get one workflow with its draft, status and \`revision\`.
1348
+
1349
+ Call it before every edit to get the current \`revision\`. Use
1350
+ \`view=structure\` to see nodes and edges without config on a large workflow.
1351
+ Secrets read back as \`********\`.
1299
1352
 
1300
1353
  (Tags: Workflows)`,
1301
1354
  inputSchema: {"type":"object","properties":{"workflow_id":{"type":"number","description":"Id of the workflow."},"view":{"type":"string","enum":["structure","full"],"default":"full","description":"`structure` leaves node `config` out."}},"required":["workflow_id"]},
@@ -1309,7 +1362,10 @@ request needs your API key in the \`Authorization\` header.
1309
1362
  }],
1310
1363
  ["deleteWorkflow", {
1311
1364
  name: "deleteWorkflow",
1312
- description: `Delete a workflow. Its published version stops running. This cannot be undone, so confirm with the user first. To stop it without deleting, use \`deactivateWorkflow\`.
1365
+ description: `Delete a workflow and stop its published version.
1366
+
1367
+ This cannot be undone, so confirm with the user first. To stop it without
1368
+ deleting, use \`deactivateWorkflow\`.
1313
1369
 
1314
1370
  (Tags: Workflows)`,
1315
1371
  inputSchema: {"type":"object","properties":{"workflow_id":{"type":"number","description":"Id of the workflow."}},"required":["workflow_id"]},
@@ -1323,7 +1379,14 @@ request needs your API key in the \`Authorization\` header.
1323
1379
  }],
1324
1380
  ["editWorkflow", {
1325
1381
  name: "editWorkflow",
1326
- description: `Change the draft with a list of \`ops\`: add, update, move or delete nodes, and connect or disconnect them. The ops apply all together or not at all. You must send the \`revision\` from your last read. If you get \`409 revision_conflict\`, read the workflow again and retry. Secrets read back as \`********\`. Send them back unchanged to keep the stored value. This edits the draft only. Use \`publishWorkflow\` to make it live.
1382
+ description: `Change the draft with a list of \`ops\`.
1383
+
1384
+ Ops add, update, move or delete nodes, and connect or disconnect them. They
1385
+ apply all together or not at all. Send the \`revision\` from your last read.
1386
+ On \`409 revision_conflict\`, read the workflow again and retry.
1387
+
1388
+ Secrets read back as \`********\`. Send them back unchanged to keep the stored
1389
+ value. This edits the draft only. Use \`publishWorkflow\` to make it live.
1327
1390
 
1328
1391
  (Tags: Workflows)`,
1329
1392
  inputSchema: {"type":"object","properties":{"workflow_id":{"type":"number","description":"Id of the workflow."},"requestBody":{"type":"object","required":["revision","ops"],"properties":{"revision":{"type":"string","description":"The `draft.revision` from your last `getWorkflow` or edit."},"ops":{"type":"array","items":{"type":"object","description":"One edit to the draft. Set `op` and the fields that op uses.\n\n| `op` | Fields | Effect |\n|---|---|---|\n| `add_node` | `id`, `type`, `label?`, `config?`, `after?`, `handle?`, `position?` | Adds a node. With `after`, it also connects it to that node (on output `handle`). |\n| `update_node` | `id`, `config?`, `label?` | Merges `config` keys into the node. A `null` value removes a key. |\n| `move_node` | `id`, `position` | Moves a node on the canvas. |\n| `delete_node` | `id` | Deletes a node and its edges. |\n| `connect` | `from`, `to`, `handle?` | Adds an edge. |\n| `disconnect` | `from`, `to`, `handle?` | Removes an edge. |\n","required":["op"],"properties":{"op":{"type":"string","enum":["add_node","update_node","move_node","delete_node","connect","disconnect"]},"id":{"type":"string","description":"Node id. For `add_node`, lowercase letters, digits and underscores, starting with a letter. It must be new."},"type":{"type":"string","description":"`add_node`: a node type from `listWorkflowNodeTypes`."},"label":{"type":"string","description":"`add_node`, `update_node`: the name shown on the canvas."},"config":{"type":"object","additionalProperties":true,"description":"`add_node`, `update_node`: the node's settings. The fields come from\n`getWorkflowNodeType`. Send a secret back as `********` to keep the\nstored value.\n"},"after":{"type":"string","description":"`add_node`: id of the node to connect the new node to."},"handle":{"type":"string","description":"`add_node`, `connect`, `disconnect`: the output of the source node. Omit for the default output."},"position":{"type":"object","description":"`add_node`, `move_node`: canvas position. `add_node` places the node for you if you omit it.","properties":{"x":{"type":"number"},"y":{"type":"number"}}},"from":{"type":"string","description":"`connect`, `disconnect`: id of the node the edge starts at."},"to":{"type":"string","description":"`connect`, `disconnect`: id of the node the edge ends at."}}}},"name":{"type":"string","description":"Rename the workflow."}},"description":"The JSON request body."}},"required":["workflow_id","requestBody"]},
@@ -1337,7 +1400,10 @@ request needs your API key in the \`Authorization\` header.
1337
1400
  }],
1338
1401
  ["validateWorkflow", {
1339
1402
  name: "validateWorkflow",
1340
- description: `Check the draft and list what blocks publish. It changes nothing. Call it after your edits and fix every error before \`publishWorkflow\`.
1403
+ description: `Check the draft and list what blocks publish.
1404
+
1405
+ It changes nothing. Call it after your edits and fix every error before
1406
+ \`publishWorkflow\`.
1341
1407
 
1342
1408
  (Tags: Workflows)`,
1343
1409
  inputSchema: {"type":"object","properties":{"workflow_id":{"type":"number","description":"Id of the workflow."}},"required":["workflow_id"]},
@@ -1351,7 +1417,11 @@ request needs your API key in the \`Authorization\` header.
1351
1417
  }],
1352
1418
  ["publishWorkflow", {
1353
1419
  name: "publishWorkflow",
1354
- description: `Make the draft the live version. Real events then run it, unless the workflow is paused. Run \`validateWorkflow\` first: publish is refused while the draft has errors. Ask the user before you publish.
1420
+ description: `Make the draft the live version.
1421
+
1422
+ Real events then run it, unless the workflow is paused. Publish is refused
1423
+ while the draft has errors, so run \`validateWorkflow\` first. Ask the user
1424
+ before you publish.
1355
1425
 
1356
1426
  (Tags: Workflows)`,
1357
1427
  inputSchema: {"type":"object","properties":{"workflow_id":{"type":"number","description":"Id of the workflow."}},"required":["workflow_id"]},
@@ -1379,7 +1449,10 @@ request needs your API key in the \`Authorization\` header.
1379
1449
  }],
1380
1450
  ["deactivateWorkflow", {
1381
1451
  name: "deactivateWorkflow",
1382
- description: `Turn the published workflow off, so real events stop running it. The workflow and its draft stay. Use \`activateWorkflow\` to turn it back on.
1452
+ description: `Turn the published workflow off.
1453
+
1454
+ Real events stop running it. The workflow and its draft stay. Use
1455
+ \`activateWorkflow\` to turn it back on.
1383
1456
 
1384
1457
  (Tags: Workflows)`,
1385
1458
  inputSchema: {"type":"object","properties":{"workflow_id":{"type":"number","description":"Id of the workflow."}},"required":["workflow_id"]},
@@ -1393,9 +1466,14 @@ request needs your API key in the \`Authorization\` header.
1393
1466
  }],
1394
1467
  ["testWorkflow", {
1395
1468
  name: "testWorkflow",
1396
- description: `Runs the draft once with payload as the trigger data. Every node runs for real: WhatsApp messages, SMS, emails and calls go out and CRM records change. Ask the user before calling it, and use their own phone number or email in the payload.
1469
+ description: `Run the draft once with \`payload\` as the trigger data.
1470
+
1471
+ Every node runs for real: WhatsApp messages, SMS, emails and calls go out,
1472
+ and CRM records change. Ask the user first, and use their own phone number
1473
+ or email in the payload.
1397
1474
 
1398
- It returns an \`execution_id\` at once. Poll \`getWorkflowExecution\` for the result.
1475
+ It returns an \`execution_id\` at once. Poll \`getWorkflowExecution\` for the
1476
+ result.
1399
1477
 
1400
1478
  (Tags: Workflows)`,
1401
1479
  inputSchema: {"type":"object","properties":{"workflow_id":{"type":"number","description":"Id of the workflow."},"requestBody":{"type":"object","properties":{"payload":{"type":"object","additionalProperties":true,"description":"The trigger data. Nodes read it as `{{ context.<trigger id>.<field> }}`. See `output_example` of the trigger node type for its shape."}},"description":"The JSON request body."}},"required":["workflow_id"]},
@@ -1409,7 +1487,10 @@ It returns an \`execution_id\` at once. Poll \`getWorkflowExecution\` for the re
1409
1487
  }],
1410
1488
  ["getWorkflowExecution", {
1411
1489
  name: "getWorkflowExecution",
1412
- description: `One run of a workflow, with the result of each step. Use it to read the outcome of \`testWorkflow\`. A run is finished when \`state\` is \`completed\`, \`failed\` or \`cancelled\`.
1490
+ description: `Get one workflow run with the result of each step.
1491
+
1492
+ Use it to read the outcome of \`testWorkflow\`. The run is finished when
1493
+ \`state\` is \`completed\`, \`failed\` or \`cancelled\`.
1413
1494
 
1414
1495
  (Tags: Workflows)`,
1415
1496
  inputSchema: {"type":"object","properties":{"workflow_id":{"type":"number","description":"Id of the workflow."},"execution_id":{"type":"number","description":"The `execution_id` from `testWorkflow`."}},"required":["workflow_id","execution_id"]},
@@ -1423,10 +1504,11 @@ It returns an \`execution_id\` at once. Poll \`getWorkflowExecution\` for the re
1423
1504
  }],
1424
1505
  ["listWhatsappNumbers", {
1425
1506
  name: "listWhatsappNumbers",
1426
- description: `The WhatsApp numbers your API key can see, oldest first. Use it to find
1427
- a number id, then pass that id to the other routes. Each number carries
1428
- \`capabilities\`, which says what it can send. Archived numbers are left
1429
- out.
1507
+ description: `List the WhatsApp numbers your API key can see.
1508
+
1509
+ Numbers come oldest first, and archived ones are left out. Use it to find a
1510
+ number id for the other routes. Each number carries \`capabilities\`, which
1511
+ says what it can send.
1430
1512
 
1431
1513
  (Tags: WhatsApp)`,
1432
1514
  inputSchema: {"type":"object","properties":{"limit":{"type":"number","default":20,"minimum":1,"maximum":100,"description":"Rows per page."},"cursor":{"type":"string","description":"The `next_cursor` from the previous page. Omit it on the first request and pass it back unchanged."}}},
@@ -1440,19 +1522,21 @@ out.
1440
1522
  }],
1441
1523
  ["importWhatsappNumbers", {
1442
1524
  name: "importWhatsappNumbers",
1443
- description: `Connects numbers from your own WhatsApp Business Account with your Meta
1444
- access token. List them first with
1445
- [Preview numbers](/docs/api-reference/whatsapp/previewWhatsappNumbers),
1446
- then pass the ids you want.
1525
+ description: `Connect numbers from your WhatsApp Business Account with your Meta access
1526
+ token.
1447
1527
 
1448
- The token must never expire and must carry both WhatsApp permissions
1449
- (\`whatsapp_business_management\` and \`whatsapp_business_messaging\`). A
1450
- system user token does. Add \`app_secret\` to receive replies. Without
1451
- it the number can send but not receive.
1528
+ List the numbers first with [Preview
1529
+ numbers](/docs/api-reference/whatsapp/previewWhatsappNumbers), then pass the
1530
+ ids you want.
1452
1531
 
1453
- Connecting a number again updates it: send a new \`access_token\` or
1454
- \`app_secret\` the same way to change either. One number failing does
1455
- not stop the others. It is listed in \`failed\` with the reason.
1532
+ The token must never expire and must carry both
1533
+ \`whatsapp_business_management\` and \`whatsapp_business_messaging\`. A system
1534
+ user token does. Add \`app_secret\` to receive replies. Without it the number
1535
+ can send but not receive.
1536
+
1537
+ Connecting a number again updates it. Send a new \`access_token\` or
1538
+ \`app_secret\` to change either. One number failing does not stop the others.
1539
+ It is listed in \`failed\` with the reason.
1456
1540
 
1457
1541
  (Tags: WhatsApp)`,
1458
1542
  inputSchema: {"type":"object","properties":{"requestBody":{"type":"object","required":["waba_id","access_token","phone_number_ids"],"properties":{"waba_id":{"type":"string","description":"Your WhatsApp Business Account id, from WhatsApp Manager."},"access_token":{"type":"string","description":"A Meta access token that never expires, with both WhatsApp permissions. Stored, never returned."},"phone_number_ids":{"type":"array","minItems":1,"items":{"type":"string"},"description":"Meta's ids for the numbers to connect, as Preview numbers lists them."},"app_secret":{"type":"string","description":"Your Meta app's secret. Turns on replies. Stored, never returned."}},"description":"The JSON request body."}},"required":["requestBody"]},
@@ -1466,12 +1550,14 @@ not stop the others. It is listed in \`failed\` with the reason.
1466
1550
  }],
1467
1551
  ["previewWhatsappNumbers", {
1468
1552
  name: "previewWhatsappNumbers",
1469
- description: `Lists the numbers on your WhatsApp Business Account with their health,
1470
- and connects nothing. The access token is checked first, against the
1471
- same rules as connecting, so a preview that passes can connect.
1553
+ description: `List the numbers on your WhatsApp Business Account with their health.
1554
+ Connects nothing.
1555
+
1556
+ The access token is checked first, against the same rules as connecting, so
1557
+ a preview that passes can connect.
1472
1558
 
1473
- Connect a number with \`needs_migration\` or \`needs_registration\` only
1474
- after fixing it in WhatsApp Manager, or its sends fail.
1559
+ Fix a number with \`needs_migration\` or \`needs_registration\` in WhatsApp
1560
+ Manager before you connect it, or its sends fail.
1475
1561
 
1476
1562
  (Tags: WhatsApp)`,
1477
1563
  inputSchema: {"type":"object","properties":{"requestBody":{"type":"object","required":["waba_id","access_token"],"properties":{"waba_id":{"type":"string","description":"Your WhatsApp Business Account id, from WhatsApp Manager."},"access_token":{"type":"string","description":"A Meta access token that never expires, with both WhatsApp permissions."}},"description":"The JSON request body."}},"required":["requestBody"]},
@@ -1485,8 +1571,10 @@ after fixing it in WhatsApp Manager, or its sends fail.
1485
1571
  }],
1486
1572
  ["getWhatsappNumber", {
1487
1573
  name: "getWhatsappNumber",
1488
- description: `One number, with its status, quality and messaging limit, and what it
1489
- can send. A number in another workspace answers \`404\`.
1574
+ description: `Get one number with its status, quality, messaging limit and what it can
1575
+ send.
1576
+
1577
+ A number in another workspace answers \`404\`.
1490
1578
 
1491
1579
  (Tags: WhatsApp)`,
1492
1580
  inputSchema: {"type":"object","properties":{"number_id":{"type":"number","description":"Id of a WhatsApp number in your workspace, from\n[listWhatsappNumbers](/docs/api-reference/whatsapp/listWhatsappNumbers).\nA number in another workspace answers `404`.\n"}},"required":["number_id"]},
@@ -1500,10 +1588,10 @@ can send. A number in another workspace answers \`404\`.
1500
1588
  }],
1501
1589
  ["listWhatsappTemplates", {
1502
1590
  name: "listWhatsappTemplates",
1503
- description: `The number's message templates, as last synced, oldest first. Pass
1504
- \`status=approved\` to see exactly the templates a send accepts. Sync the
1505
- list with \`syncWhatsappTemplates\` first if a template you expect is
1506
- missing.
1591
+ description: `List the number's message templates, as last synced, oldest first.
1592
+
1593
+ Pass \`status=approved\` to see exactly the templates a send accepts. If a
1594
+ template you expect is missing, run \`syncWhatsappTemplates\` first.
1507
1595
 
1508
1596
  (Tags: WhatsApp)`,
1509
1597
  inputSchema: {"type":"object","properties":{"number_id":{"type":"number","description":"Id of a WhatsApp number in your workspace, from\n[listWhatsappNumbers](/docs/api-reference/whatsapp/listWhatsappNumbers).\nA number in another workspace answers `404`.\n"},"status":{"type":"string","description":"Show only templates with this review status, such as `approved`,\n`pending` or `rejected`. Lower-case; omit it for all.\n"},"limit":{"type":"number","default":20,"minimum":1,"maximum":100,"description":"Rows per page."},"cursor":{"type":"string","description":"The `next_cursor` from the previous page."}},"required":["number_id"]},
@@ -1517,10 +1605,11 @@ missing.
1517
1605
  }],
1518
1606
  ["syncWhatsappTemplates", {
1519
1607
  name: "syncWhatsappTemplates",
1520
- description: `Pull the number's templates and their review statuses from WhatsApp into
1521
- your list. Run it after you create or edit a template in Meta. It runs
1522
- at most once a minute per number: a second call inside that minute
1523
- answers \`429\`.
1608
+ description: `Pull the number's templates and review statuses from WhatsApp into your
1609
+ list.
1610
+
1611
+ Run it after you create or edit a template in Meta. It runs at most once a
1612
+ minute per number. A second call inside that minute answers \`429\`.
1524
1613
 
1525
1614
  (Tags: WhatsApp)`,
1526
1615
  inputSchema: {"type":"object","properties":{"number_id":{"type":"number","description":"Id of a WhatsApp number in your workspace, from\n[listWhatsappNumbers](/docs/api-reference/whatsapp/listWhatsappNumbers).\nA number in another workspace answers `404`.\n"}},"required":["number_id"]},
@@ -1534,10 +1623,11 @@ answers \`429\`.
1534
1623
  }],
1535
1624
  ["getWhatsappCalling", {
1536
1625
  name: "getWhatsappCalling",
1537
- description: `Whether calling is on for this number and whether it can be turned on,
1538
- with the list of checks. A failing check does not fail the request: the
1539
- response stays \`200\` and names the check that blocks. Meta Cloud numbers
1540
- only. Calling must be included in your plan.
1626
+ description: `Get whether calling is on for this number and whether it can be turned on.
1627
+
1628
+ The response lists the checks. A failing check does not fail the request: it
1629
+ stays \`200\` and names the check that blocks. Meta Cloud numbers only. Your
1630
+ plan must include calling.
1541
1631
 
1542
1632
  (Tags: WhatsApp)`,
1543
1633
  inputSchema: {"type":"object","properties":{"number_id":{"type":"number","description":"Id of a WhatsApp number in your workspace, from\n[listWhatsappNumbers](/docs/api-reference/whatsapp/listWhatsappNumbers).\nA number in another workspace answers `404`.\n"}},"required":["number_id"]},
@@ -1551,10 +1641,11 @@ only. Calling must be included in your plan.
1551
1641
  }],
1552
1642
  ["setWhatsappCalling", {
1553
1643
  name: "setWhatsappCalling",
1554
- description: `Turn calling on or off for a Meta Cloud number. A customer calls this
1555
- number; it does not place calls. Turning it on requires every blocking
1556
- check to pass, or the request answers \`409\`. Turning it off is always
1557
- allowed.
1644
+ description: `Turn calling on or off for a Meta Cloud number.
1645
+
1646
+ A customer calls this number. It does not place calls. Turning calling on
1647
+ needs every blocking check to pass, or the request answers \`409\`. Turning it
1648
+ off is always allowed.
1558
1649
 
1559
1650
  (Tags: WhatsApp)`,
1560
1651
  inputSchema: {"type":"object","properties":{"number_id":{"type":"number","description":"Id of a WhatsApp number in your workspace, from\n[listWhatsappNumbers](/docs/api-reference/whatsapp/listWhatsappNumbers).\nA number in another workspace answers `404`.\n"},"requestBody":{"type":"object","required":["enabled"],"properties":{"enabled":{"type":"boolean","description":"`true` to turn calling on, `false` to turn it off."}},"description":"The JSON request body."}},"required":["number_id","requestBody"]},
@@ -1568,10 +1659,10 @@ allowed.
1568
1659
  }],
1569
1660
  ["listWhatsappConversations", {
1570
1661
  name: "listWhatsappConversations",
1571
- description: `A number's inbox, newest activity first. Poll it with \`updated_since\`
1572
- for changes since your last call, or page it with \`cursor\`. There are no
1573
- event webhooks, so polling is how an integration learns about new
1574
- messages.
1662
+ description: `List a number's inbox, newest activity first.
1663
+
1664
+ There are no event webhooks, so poll with \`updated_since\` to learn about new
1665
+ messages. Page with \`cursor\`.
1575
1666
 
1576
1667
  (Tags: WhatsApp)`,
1577
1668
  inputSchema: {"type":"object","properties":{"number_id":{"type":"number","description":"Id of a WhatsApp number in your workspace, from\n[listWhatsappNumbers](/docs/api-reference/whatsapp/listWhatsappNumbers).\nA number in another workspace answers `404`.\n"},"filter":{"type":"string","enum":["all","unread","needs_person","agent","failed","window_closed","campaign_replies"],"default":"all","description":"`needs_person` is a person-owned or paused conversation. `window_closed` is one you can only reach with a template."},"q":{"type":"string","maxLength":200,"description":"Search the customer's name, phone number and message text."},"updated_since":{"type":"string","description":"An ISO 8601 date and time, such as `2026-10-01T09:00:00+00:00`. Returns\nconversations with a change at or after it. No offset means UTC.\n"},"limit":{"type":"number","default":20,"minimum":1,"maximum":100,"description":"Rows per page."},"cursor":{"type":"string","description":"The `next_cursor` from the previous page."}},"required":["number_id"]},
@@ -1585,8 +1676,9 @@ messages.
1585
1676
  }],
1586
1677
  ["getWhatsappConversation", {
1587
1678
  name: "getWhatsappConversation",
1588
- description: `One conversation: who owns it, the 24-hour window, whether the customer
1589
- opted out, and the unread count. Poll it while a person is answering.
1679
+ description: `Get one conversation: owner, 24-hour window, opt-out state and unread count.
1680
+
1681
+ Poll it while a person is answering.
1590
1682
 
1591
1683
  (Tags: WhatsApp)`,
1592
1684
  inputSchema: {"type":"object","properties":{"conversation_id":{"type":"string","description":"A conversation id: the number id, a dash, then the customer's phone\ndigits, such as `412-919876543210`. From\n[listWhatsappConversations](/docs/api-reference/whatsapp/listWhatsappConversations).\n"}},"required":["conversation_id"]},
@@ -1601,7 +1693,9 @@ opted out, and the unread count. Poll it while a person is answering.
1601
1693
  ["takeOverWhatsappConversation", {
1602
1694
  name: "takeOverWhatsappConversation",
1603
1695
  description: `Take the conversation from the agent, so it stops replying and your team
1604
- answers. Repeating it changes nothing. Hand it back with
1696
+ answers.
1697
+
1698
+ Repeating it changes nothing. Hand it back with
1605
1699
  \`handBackWhatsappConversation\` when the person is done.
1606
1700
 
1607
1701
  (Tags: WhatsApp)`,
@@ -1616,8 +1710,9 @@ answers. Repeating it changes nothing. Hand it back with
1616
1710
  }],
1617
1711
  ["handBackWhatsappConversation", {
1618
1712
  name: "handBackWhatsappConversation",
1619
- description: `Give the conversation back to the agent, and clear a pause. The agent
1620
- answers the customer's next message. Repeating it changes nothing.
1713
+ description: `Give the conversation back to the agent and clear any pause.
1714
+
1715
+ The agent answers the customer's next message. Repeating it changes nothing.
1621
1716
 
1622
1717
  (Tags: WhatsApp)`,
1623
1718
  inputSchema: {"type":"object","properties":{"conversation_id":{"type":"string","description":"A conversation id: the number id, a dash, then the customer's phone\ndigits, such as `412-919876543210`. From\n[listWhatsappConversations](/docs/api-reference/whatsapp/listWhatsappConversations).\n"}},"required":["conversation_id"]},
@@ -1631,9 +1726,10 @@ answers the customer's next message. Repeating it changes nothing.
1631
1726
  }],
1632
1727
  ["listWhatsappMessages", {
1633
1728
  name: "listWhatsappMessages",
1634
- description: `One conversation's messages, newest first. Poll forward with \`after\`
1635
- (the id of the newest message you already have) to get only new ones.
1636
- Page backward through history with \`cursor\`. Do not pass both.
1729
+ description: `List one conversation's messages, newest first.
1730
+
1731
+ Poll forward with \`after\`, the id of the newest message you have, to get
1732
+ only new ones. Page back through history with \`cursor\`. Do not pass both.
1637
1733
 
1638
1734
  (Tags: WhatsApp)`,
1639
1735
  inputSchema: {"type":"object","properties":{"conversation_id":{"type":"string","description":"The conversation to read."},"after":{"type":"number","description":"Return messages newer than this message id. `next_cursor` is null in this mode."},"limit":{"type":"number","default":20,"minimum":1,"maximum":100,"description":"Rows per page."},"cursor":{"type":"string","description":"The `next_cursor` from the previous page. Do not combine it with `after`."}},"required":["conversation_id"]},
@@ -1647,18 +1743,19 @@ Page backward through history with \`cursor\`. Do not pass both.
1647
1743
  }],
1648
1744
  ["sendWhatsappMessage", {
1649
1745
  name: "sendWhatsappMessage",
1650
- description: `Send one message through \`phone_number_id\` to a customer, in a text,
1651
- a template, an image or a document. Set \`type\` and the matching field.
1746
+ description: `Send a text, template, image or document message to a customer.
1747
+
1748
+ It goes out from \`phone_number_id\`. Set \`type\` and the field that matches
1749
+ it.
1652
1750
 
1653
- Outside the 24-hour window, only a template goes through. A text, image
1654
- or document send is refused with \`409 window_closed\`. A template send
1655
- works any time and can start a new conversation.
1751
+ Outside the 24-hour window, only a template goes through. Text, image and
1752
+ document sends are refused with \`409 window_closed\`. A template send works
1753
+ any time and can start a new conversation.
1656
1754
 
1657
- The send does not take the conversation over, so the agent keeps
1658
- answering. Set \`take_over: true\` to stop the agent and answer yourself.
1755
+ A send does not take the conversation over, so the agent keeps answering.
1756
+ Set \`take_over: true\` to stop the agent and answer yourself.
1659
1757
 
1660
- \`Idempotency-Key\` is required. The same key with the same body replays
1661
- the first answer instead of sending again.
1758
+ \`Idempotency-Key\` is required. The same key with the same body replays the first answer instead of sending again.
1662
1759
 
1663
1760
  (Tags: WhatsApp)`,
1664
1761
  inputSchema: {"type":"object","properties":{"Idempotency-Key":{"type":"string","maxLength":255,"description":"A unique string you choose, up to 255 characters. Required on this\nroute. The same key with the same body replays the first answer for\n24 hours instead of acting twice. A different body with the same key\nanswers `409`.\n"},"requestBody":{"type":"object","required":["phone_number_id","to","type"],"properties":{"phone_number_id":{"type":"number","description":"The number to send from."},"to":{"type":"string","description":"The customer's number in international format, such as `+15551234567`."},"type":{"type":"string","enum":["text","template","image","document"]},"text":{"type":"string","maxLength":4096,"description":"Required when `type` is `text`."},"template":{"type":"object","description":"Required when `type` is `template`.","required":["id"],"properties":{"id":{"type":"number","description":"An approved template on this number, from `listWhatsappTemplates`."},"params":{"type":"object","description":"One value per field in the template's `fields`. Keys are\nthose field keys. String, number or null values.\n","additionalProperties":true}}},"media":{"type":"object","description":"Required when `type` is `image` or `document`.","required":["media_id"],"properties":{"media_id":{"type":"string","description":"The `media_id` from `uploadWhatsappMedia`, uploaded within the last 24 hours."},"caption":{"type":"string","maxLength":1024}}},"reply_to":{"type":"number","description":"A message id in the same conversation to quote. Not allowed with a template."},"take_over":{"type":"boolean","default":false,"description":"Stop the agent answering this conversation and let a person run it."}},"description":"The JSON request body."}},"required":["Idempotency-Key","requestBody"]},
@@ -1672,9 +1769,11 @@ the first answer instead of sending again.
1672
1769
  }],
1673
1770
  ["getWhatsappMessage", {
1674
1771
  name: "getWhatsappMessage",
1675
- description: `One message with its \`timeline\`: the delivery and read steps, oldest
1676
- first. Poll it after a send to learn whether the message was delivered
1677
- and read. Also shows what the send cost once it is charged.
1772
+ description: `Get one message with its \`timeline\` of delivery and read steps, oldest
1773
+ first.
1774
+
1775
+ Poll it after a send to learn whether the message was delivered and read. It
1776
+ also shows what the send cost once charged.
1678
1777
 
1679
1778
  (Tags: WhatsApp)`,
1680
1779
  inputSchema: {"type":"object","properties":{"message_id":{"type":"number","description":"Id of a message, from `listWhatsappMessages` or a send response."}},"required":["message_id"]},
@@ -1703,10 +1802,10 @@ lists active opt-outs only.
1703
1802
  }],
1704
1803
  ["addWhatsappOptOut", {
1705
1804
  name: "addWhatsappOptOut",
1706
- description: `Stop every message you start to this customer from this number, until
1707
- the block is lifted. The response is \`201\` when the block is new and
1708
- \`200\` when the customer was already blocked, in which case the entry is
1709
- returned unchanged.
1805
+ description: `Block a customer from receiving messages you start from this number.
1806
+
1807
+ The block lasts until you lift it. The response is \`201\` for a new block. It
1808
+ is \`200\` with the entry unchanged if the customer was already blocked.
1710
1809
 
1711
1810
  (Tags: WhatsApp)`,
1712
1811
  inputSchema: {"type":"object","properties":{"number_id":{"type":"number","description":"Id of a WhatsApp number in your workspace, from\n[listWhatsappNumbers](/docs/api-reference/whatsapp/listWhatsappNumbers).\nA number in another workspace answers `404`.\n"},"requestBody":{"type":"object","required":["customer"],"properties":{"customer":{"type":"string","description":"The customer's number in international format, such as `+15551234567`."},"note":{"type":"string","maxLength":500,"description":"A note for your team."}},"description":"The JSON request body."}},"required":["number_id","requestBody"]},
@@ -1720,10 +1819,11 @@ returned unchanged.
1720
1819
  }],
1721
1820
  ["liftWhatsappOptOut", {
1722
1821
  name: "liftWhatsappOptOut",
1723
- description: `Lift a block you added, or a marketing block made in WhatsApp. The entry
1724
- stays in the list with \`active: false\`. A customer's own STOP cannot be
1725
- lifted over the API: only the customer lifting it in WhatsApp, or
1726
- messaging you again, brings them back.
1822
+ description: `Lift a block you added, or a marketing block made in WhatsApp.
1823
+
1824
+ The entry stays in the list with \`active: false\`. You cannot lift a
1825
+ customer's own STOP over the API. The customer must lift it in WhatsApp or
1826
+ message you again.
1727
1827
 
1728
1828
  (Tags: WhatsApp)`,
1729
1829
  inputSchema: {"type":"object","properties":{"number_id":{"type":"number","description":"Id of a WhatsApp number in your workspace, from\n[listWhatsappNumbers](/docs/api-reference/whatsapp/listWhatsappNumbers).\nA number in another workspace answers `404`.\n"},"opt_out_id":{"type":"number","description":"Id of an active opt-out entry, from `listWhatsappOptOuts`."}},"required":["number_id","opt_out_id"]},
@@ -1751,9 +1851,10 @@ messaging you again, brings them back.
1751
1851
  }],
1752
1852
  ["createWhatsappCampaign", {
1753
1853
  name: "createWhatsappCampaign",
1754
- description: `Create a campaign as a draft. It sends nothing until you launch it. Add
1755
- contacts and launch it in the next calls. Only an approved template can
1756
- be used, so every campaign starts with one. Scheduling is not offered.
1854
+ description: `Create a draft campaign from an approved template. It sends nothing until
1855
+ you launch it.
1856
+
1857
+ Add contacts and launch it with the next calls. Scheduling is not offered.
1757
1858
 
1758
1859
  (Tags: WhatsApp)`,
1759
1860
  inputSchema: {"type":"object","properties":{"requestBody":{"type":"object","required":["name","phone_number_id","template_id"],"properties":{"name":{"type":"string","maxLength":255},"phone_number_id":{"type":"number"},"template_id":{"type":"number","description":"An approved template on that number."},"campaign_mode":{"type":"string","enum":["broadcast","broadcast_reply"],"default":"broadcast","description":"`broadcast_reply` lets the agent answer replies. It needs an agent."},"agent_id":{"type":"number","description":"The agent that answers replies."},"data_source":{"type":"string","enum":["csv","webhook"],"default":"csv"},"is_dynamic":{"type":"boolean","default":false},"variable_mapping":{"type":"object","description":"Template field to contact field or static text.","additionalProperties":true}},"description":"The JSON request body."}},"required":["requestBody"]},
@@ -1767,9 +1868,11 @@ be used, so every campaign starts with one. Scheduling is not offered.
1767
1868
  }],
1768
1869
  ["getWhatsappCampaign", {
1769
1870
  name: "getWhatsappCampaign",
1770
- description: `One campaign with its counts and analytics: per-source figures and the
1771
- failed contacts grouped by reason. \`delivery_rate\` and \`read_rate\` are
1772
- null on a number that does not report receipts.
1871
+ description: `Get one campaign with its counts and analytics.
1872
+
1873
+ Analytics include per-source figures and failed contacts grouped by reason.
1874
+ \`delivery_rate\` and \`read_rate\` are null on a number that does not report
1875
+ receipts.
1773
1876
 
1774
1877
  (Tags: WhatsApp)`,
1775
1878
  inputSchema: {"type":"object","properties":{"campaign_id":{"type":"number","description":"Id of a WhatsApp campaign, from `listWhatsappCampaigns`."}},"required":["campaign_id"]},
@@ -1783,8 +1886,10 @@ null on a number that does not report receipts.
1783
1886
  }],
1784
1887
  ["listWhatsappCampaignContacts", {
1785
1888
  name: "listWhatsappCampaignContacts",
1786
- description: `Per-contact status for a campaign, oldest first. A contact that read the
1787
- message and then replied STOP counts as read and opted out.
1889
+ description: `List per-contact status for a campaign, oldest first.
1890
+
1891
+ A contact that read the message and then replied STOP counts as read and
1892
+ opted out.
1788
1893
 
1789
1894
  (Tags: WhatsApp)`,
1790
1895
  inputSchema: {"type":"object","properties":{"campaign_id":{"type":"number","description":"Id of a WhatsApp campaign, from `listWhatsappCampaigns`."},"status":{"type":"string","enum":["pending","sent","delivered","read","replied","failed","skipped","opted_out"],"description":"Show only contacts in this state."},"limit":{"type":"number","default":20,"minimum":1,"maximum":100,"description":"Rows per page."},"cursor":{"type":"string","description":"The `next_cursor` from the previous page."}},"required":["campaign_id"]},
@@ -1798,11 +1903,13 @@ message and then replied STOP counts as read and opted out.
1798
1903
  }],
1799
1904
  ["addWhatsappCampaignContacts", {
1800
1905
  name: "addWhatsappCampaignContacts",
1801
- description: `Add one contact, or up to 500 at once. On a draft they are stored for
1802
- launch. On a running campaign they are sent now. A contact already in
1803
- the campaign is skipped, so a retry is safe. Each contact needs a
1804
- \`phone_number\`; every other key is kept and can fill a template
1805
- parameter through \`variable_mapping\`.
1906
+ description: `Add one contact, or up to 500 at once, to a campaign.
1907
+
1908
+ On a draft they are stored for launch. On a running campaign they are sent
1909
+ now. A contact already in the campaign is skipped, so a retry is safe.
1910
+
1911
+ Each contact needs a \`phone_number\`. Every other key is kept and can fill a
1912
+ template parameter through \`variable_mapping\`.
1806
1913
 
1807
1914
  (Tags: WhatsApp)`,
1808
1915
  inputSchema: {"type":"object","properties":{"campaign_id":{"type":"number","description":"Id of a WhatsApp campaign, from `listWhatsappCampaigns`."},"requestBody":{"description":"One contact object, or an array of 1 to 500.","oneOf":[{"type":"object","description":"One contact. `phone_number` is required. Any other key is kept on the\ncontact and can fill a template parameter through `variable_mapping`.\n","required":["phone_number"],"properties":{"phone_number":{"type":"string","description":"The customer's number in international format, such as `+15551234567`."},"contact_name":{"type":"string","description":"A name for your team. `name` works too."}},"additionalProperties":true},{"type":"array","maxItems":500,"items":{"type":"object","description":"One contact. `phone_number` is required. Any other key is kept on the\ncontact and can fill a template parameter through `variable_mapping`.\n","required":["phone_number"],"properties":{"phone_number":{"type":"string","description":"The customer's number in international format, such as `+15551234567`."},"contact_name":{"type":"string","description":"A name for your team. `name` works too."}},"additionalProperties":true}}]}},"required":["campaign_id","requestBody"]},
@@ -1816,10 +1923,11 @@ parameter through \`variable_mapping\`.
1816
1923
  }],
1817
1924
  ["launchWhatsappCampaign", {
1818
1925
  name: "launchWhatsappCampaign",
1819
- description: `Start a draft campaign: every pending contact is queued once. Needs at
1820
- least one contact, unless the campaign's \`data_source\` is \`webhook\`. The
1821
- plan's monthly broadcast allowance and the wallet balance are checked
1822
- here. \`Idempotency-Key\` is required, so a retry does not start it twice.
1926
+ description: `Start a draft campaign and queue every pending contact once.
1927
+
1928
+ It needs at least one contact, unless \`data_source\` is \`webhook\`. Launch
1929
+ checks the plan's monthly broadcast allowance and the wallet balance.
1930
+ \`Idempotency-Key\` is required, so a retry does not start it twice.
1823
1931
 
1824
1932
  (Tags: WhatsApp)`,
1825
1933
  inputSchema: {"type":"object","properties":{"campaign_id":{"type":"number","description":"Id of a WhatsApp campaign, from `listWhatsappCampaigns`."},"Idempotency-Key":{"type":"string","maxLength":255,"description":"A unique string you choose, up to 255 characters. Required on this\nroute. The same key with the same body replays the first answer for\n24 hours instead of acting twice. A different body with the same key\nanswers `409`.\n"}},"required":["campaign_id","Idempotency-Key"]},
@@ -1833,8 +1941,10 @@ here. \`Idempotency-Key\` is required, so a retry does not start it twice.
1833
1941
  }],
1834
1942
  ["pauseWhatsappCampaign", {
1835
1943
  name: "pauseWhatsappCampaign",
1836
- description: `Stop sending until you resume. Only a running campaign can be paused. A
1837
- pause you make by hand is never resumed automatically.
1944
+ description: `Stop sending until you resume.
1945
+
1946
+ Only a running campaign can be paused. A pause you make by hand is never
1947
+ resumed automatically.
1838
1948
 
1839
1949
  (Tags: WhatsApp)`,
1840
1950
  inputSchema: {"type":"object","properties":{"campaign_id":{"type":"number","description":"Id of a WhatsApp campaign, from `listWhatsappCampaigns`."}},"required":["campaign_id"]},
@@ -1848,9 +1958,10 @@ pause you make by hand is never resumed automatically.
1848
1958
  }],
1849
1959
  ["resumeWhatsappCampaign", {
1850
1960
  name: "resumeWhatsappCampaign",
1851
- description: `Resume a paused campaign. Contacts still pending are sent; a contact
1852
- already sent is never sent again. The wallet and allowance are checked
1853
- again, so a resume can answer \`402\`.
1961
+ description: `Resume a paused campaign.
1962
+
1963
+ Pending contacts are sent. A contact already sent is never sent again.
1964
+ Resume checks the wallet and allowance again, so it can answer \`402\`.
1854
1965
 
1855
1966
  (Tags: WhatsApp)`,
1856
1967
  inputSchema: {"type":"object","properties":{"campaign_id":{"type":"number","description":"Id of a WhatsApp campaign, from `listWhatsappCampaigns`."}},"required":["campaign_id"]},
@@ -1880,6 +1991,7 @@ or already-canceled campaign cannot be canceled.
1880
1991
  ]);
1881
1992
  addShowWorkflow(toolDefinitionMap);
1882
1993
  addDocsTools(toolDefinitionMap);
1994
+ addGuideTool(toolDefinitionMap);
1883
1995
  if (readOnlyMode()) keepReadOnlyTools(toolDefinitionMap);
1884
1996
 
1885
1997
  /**
@@ -1898,7 +2010,7 @@ server.setRequestHandler(ListToolsRequestSchema, async () => {
1898
2010
  const toolsForClient: Tool[] = Array.from(toolDefinitionMap.values()).map(def => ({
1899
2011
  name: def.name,
1900
2012
  description: def.description,
1901
- inputSchema: def.inputSchema,
2013
+ inputSchema: flatInputSchema(def),
1902
2014
  annotations: toolAnnotations(def),
1903
2015
  _meta: toolMeta(def.name)
1904
2016
  }));
@@ -1914,7 +2026,8 @@ server.setRequestHandler(CallToolRequestSchema, async (request: CallToolRequest)
1914
2026
  return { content: [{ type: "text", text: `Error: Unknown tool requested: ${toolName}` }] };
1915
2027
  }
1916
2028
  if (isDocsTool(toolName)) return await callDocsTool(toolName, toolArgs ?? {});
1917
- return await executeApiTool(toolName, toolDefinition, toolArgs ?? {}, securitySchemes);
2029
+ if (isGuideTool(toolName)) return callGuideTool(toolArgs ?? {});
2030
+ return await executeApiTool(toolName, toolDefinition, nestBodyArgs(toolDefinition, toolArgs ?? {}), securitySchemes);
1918
2031
  });
1919
2032
 
1920
2033