Skip to main content
Dispatching a call tells an agent to dial a number now. The agent places the call through its outbound connection, so the caller ID comes from that connection’s pool rather than from the request.

Prerequisites

Before you begin:
  • An outbound connection attached to the agent. Without one, dispatch fails. See Place calls from an agent.
  • The agent’s ID, from the create response or the project page.
  • An SLNG key for the API path. See How to set up.

Place one call

1

Open the test panel

Open the project and click Test agent. The panel opens on the Web session channel.
The Test agent panel with the Channel set to Web session and an Outbound call option

The Test agent panel. Switch the channel to Outbound call.

2

Switch to Outbound call

Set the Channel to Outbound call. A Number to call field appears. If the panel says telephony setup is needed, the agent has no outbound connection attached.
The Test agent panel in outbound call mode showing the Number to call field

The Outbound call channel, with a field for the number to call.

3

Enter the number and start the call

Enter the destination under Number to call in E.164 format and click Start call. The agent dials while you watch the transcript.
The Test agent panel with a number entered and the Start call button

A number entered and ready. Start call places the outbound call.

Use this to check an agent before you automate it. For anything repeated, use the API.

Personalize each call

If the agent’s system prompt or greeting uses {{variable}} placeholders, pass values for them in arguments. They override any defaults set on the agent, and the rendered prompt is stored with the call record.
Request
Values are strings, and the payload is bounded: The request rejects anything it does not recognize, so a misspelled field name returns an error rather than being ignored.

Dispatch calls from a list

The API accepts one call per request. When you process a contact list, control the request rate and retry 429 Too Many Requests responses. Limiting concurrent requests does not control how many requests you send within the rate-limit window. This example sends calls sequentially, waits between contacts, and honors the Retry-After header before retrying a rate-limited request. Set DISPATCH_INTERVAL_MS for the rate limit applied to your account.
dispatch-list.mjs
Run the script with your key and agent ID:
A failed contact does not stop the list. Review entries with a rejected status, fix the cause, then retry only those contacts.

Follow the call

Each dispatched call becomes a record you can read back: its status, the arguments you passed, the prompt after those arguments were filled in, and the transcript once the call ends. See Observability and usage.

Next steps