Chat API
Use the PolyAI Chat API to power Webchat.
Use the Chat API to integrate PolyAI agents into existing systems, and use its endpoints to get programmatic access to your automated chat interactions. This API structures non-voice web integration conversations, messages, and chat sessions using a simple set of REST endpoints.
The Chat API can power multiple Webchat integrations, including WhatsApp, email, and in-app widgets.
Chatting with the API
-
Initiate conversation: Send a POST
/chat/create
request with required headers. -
Send and receive messages: Use the
/chat/respond
endpoint for ongoing interaction.
Endpoints
Base URLs
The Chat API is available in the following regions:
Region | URL |
---|---|
US | https://api.us-1.platform.polyai.app |
UK | https://api.uk-1.platform.polyai.app |
EUW | https://api.euw-1.platform.polyai.app |
API path format
All endpoints follow this structure:
-
account_id
: Your PolyAI account ID, e.g.,ACCOUNT-12345678
. -
project_id
: Your PolyAI project ID, e.g.,PROJECT-87654321
.