Overview
Using the Customer Chat API
15 methods for the visitor’s side of a chat.
Before you start
The Customer Chat API is the visitor’s side of a chat: what the chat window on a website calls. Start with Get an access token, then send it as Authorization: Bearer mlcc_… on every method: one POST to https://app.staging.mlive.chat/v1/customer/action/<method> each. Live updates come over the WebSocket.
Customer Chat API resources
| Resource | Methods |
|---|---|
| Authorization | Get an access token |
| Chats | Start a chat, Get a chat, List threads, End the chat |
| Events | Send an event, Upload a file |
| Customers | Update the customer, Set session fields, Update session fields |
| Configuration | Get the chat configuration |
| Other | Ask for a person, Rate the chat, Leave a message |
| Realtime | Get a WebSocket ticket |
Hearing about changes
Calls answer with the result; everything that happens in a chat after that arrives as a push on the WebSocket. Each method’s Specifics name the push it causes.