Launch Chat Agents
Synthflow offers multiple ways to launch a chat agent: API integration, an embeddable chat widget, WhatsApp, and SMS.
Choose the channel based on where the conversation should happen:
- API for custom applications and backend-controlled chat sessions.
- Widget for a fast website or app embed managed by Synthflow.
- WhatsApp for Twilio-backed messaging on supported US-region workspaces.
- SMS for text conversations through your own Twilio number.
Region availability: WhatsApp and SMS channels are currently available for US-region workspaces only. EU support is not yet available because Twilio does not currently offer EU data residency for the WhatsApp and SMS Conversations APIs, which is required to meet GDPR data processing and storage requirements. EU support will be added once a compliant provider option is available. API and widget-based chat agents are available in all regions.
1. API Integration
After deploying your chat agent, you can start a new chat conversation programmatically using the API:
- Replace
{chat_id}with a unique UUID for the conversation. - Replace
{model_id}with the ID of your chat agent.
You can use this endpoint to send and receive messages, manage sessions, and integrate chat into any custom application.
2. Embeddable Chat Widget
Synthflow provides an out-of-the-box chat widget you can embed on your website or in your app:
- Create a chat agent in the Synthflow dashboard.
- Go to the chat agent’s Settings and Deployment tab.
- Copy the provided embed code.
- Paste the embed code into your website or application where you want the chat widget to appear.
The widget is fully managed by Synthflow, making it easy to add conversational AI to your site with minimal setup.
3. WhatsApp
Chat agents can send and receive messages over WhatsApp. This requires a connected Twilio account with a WhatsApp-enabled sender.
Connect your Twilio account
Navigate to Integrations > Twilio in the Synthflow dashboard and provide your Twilio SID and Auth credentials. See the Twilio integration guide for full setup instructions.
Enable a WhatsApp sender in Twilio
You need a WhatsApp-enabled sender in your Twilio account. If you don’t have one, follow Twilio’s WhatsApp documentation to register a sender.
Configure the sender webhooks
In the Twilio console, navigate to your WhatsApp sender and set the following webhook URLs:
If your sender is associated with a Twilio Messaging Service, the Messaging Service webhook URLs take priority and override the sender-level URLs. Either remove the sender from the Messaging Service, or set the same webhook URLs on the Messaging Service instead.
4. SMS
Chat agents can also communicate over SMS. Like WhatsApp, this requires your own Twilio account.
Connect your Twilio account
If you haven’t already, connect Twilio in Integrations > Twilio. See the Twilio integration guide.
Assign an SMS-capable number
Use a Twilio phone number that supports SMS. You can buy a number through Synthflow or import your own.
Configure the phone number webhooks
In the Twilio console, navigate to your phone number’s configuration and set the following:
If the phone number is part of a Twilio Messaging Service, the Messaging Service webhook URLs take priority over the phone number’s own URLs. Either remove the number from the Messaging Service, or set the same webhook URLs on the Messaging Service instead.
Both WhatsApp and SMS channels require you to connect your own Twilio account and use your own Twilio credentials. Synthflow supports the integration, but Twilio messaging usage is billed through your Twilio account.
Twilio charges for WhatsApp and SMS usage at their own rates. These costs are billed directly by Twilio and are separate from Synthflow’s standard platform fee, which still applies.
Conversation Lifecycle
Messaging channels share the same basic lifecycle controls: reminder timing, idle timeout, and outbound conversation setup. These settings matter most when you expect asynchronous user replies instead of real-time chat.
WhatsApp and SMS conversations support automatic idle reminders and timeouts. These settings are configured on the agent and apply per-conversation.
When a user stops responding, the lifecycle works as follows:
- After
reminder_after_idle_secondsof inactivity, the agent sends the configuredreminder_messageover the same channel. - If the user still does not respond within
allowed_idle_time_seconds(measured from the last user message), the conversation is automatically ended with anend_reasonofinactivity_timeout. - If the user replies at any point, the idle timer resets.
Minimum values are 60 seconds for both the reminder delay and the idle timeout. Values below 60 seconds are overridden to defaults (1 hour for reminders, 24 hours for timeout).
Starting an Outbound Conversation
You can initiate outbound WhatsApp and SMS conversations via the API. The endpoint creates a new conversation and sends the first message to the recipient.
Request Fields
Response
WhatsApp 24-Hour Session Window
WhatsApp enforces a 24-hour conversation window. If the recipient has messaged your sender within the last 24 hours, you can send a freeform initial_message. If the recipient has not messaged in the last 24 hours, you must use an approved Twilio Content Template — WhatsApp will reject freeform messages outside the session window.
Use initial_message for freeform messages within the window:
Use template for messages outside the 24-hour window (also works within it):
Template Object
Twilio Content Templates must be submitted for approval before use. Templates in pending or rejected status will cause the outbound message to fail. You can manage templates in the Twilio Content Editor.
SMS does not have a session window restriction — you can use initial_message for SMS outbound at any time.
Post-Conversation Webhook
When a chat conversation ends, Synthflow can send a webhook to a URL you configure on your agent. The payload includes the full transcript, individual turns, and routing metadata.
Payload Fields
Turn Object
Each entry in the turns array represents a single message:
Route Object
Present on WhatsApp and SMS conversations. Contains the provider and addressing details:
Example Payload
Frequently asked questions
What is pricing for chat?
Every 5 messages sent by Synthflow counts as 1 billable minute, charged at your plan’s per-minute rate. This is a platform-level fee. If you use SMS or WhatsApp through Twilio, standard Twilio messaging fees apply on top.
Does chat work for both prompt and flow designer agents?
Yes! You can use either a single prompt or a flow designer configuration for your chat agent.
How do I monitor chat agent performance?
Chat will be shortly integrated into the analytics platform.