The API documentation describes the API types and their purpose, along with high-level information on how the API works. Communication flows involve receiving events (e.g., a chat message, user update event), sending fire-and-forget requests, sending requests for information (request-response), and sending requests with the expectation of a success response. The API documentation outlines the only enforced protocols.
The login handshake protocol is explicitly detailed in the API documentation. It's the only protocol you need to follow for connection establishment. The demo code's message handler implements this handshake.
As opposed to getting the history of a chat channel or private messages (whispers), support tickets are handled differently. An initial request for a support ticket returns only a status (whether the request was successfully processed). After that, messages in the ticket thread will be sent in the same fashion as they were sent under the original session.
Clients can request channel history using dedicated API methods, either for a single batch or for paged results. The asset's demo typically fetches history after joining a channel. In the next release of the client asset, you'll be able to request chat history in batches and specify the range to fetch. For specific API calls, refer to the API documentation.
Clients can request information on a given channel by name using a specific API method, which retrieves details like channel users and the channel name from the server. See the API documentation for details.
Clients send chat messages to a channel using a specific API method. This method requires the recipient channel and the message content. This is generally a fire-and-forget request, with the client receiving an event as a direct consequence. Details about the specific message types and their parameters can be found in the API documentation.
Clients can attach persistent key-value pair metadata to themselves or to a specific channel using a dedicated API request. If no channel name is specified, metadata will be attached to the user. This metadata is exhaustive, meaning sending an empty list clears all existing metadata. This metadata is passed along with chat/whisper messages or channel info. Refer to the API documentation for specific request details.
The `UserInfo` model is used by the server to provide information about a user. It includes details such as a `Name` (username) and `DisplayId` (for private messages), along with `Metadata`. The `Whois` Unity API method can retrieve a user's Name and Display ID.
All server-generated timestamps within Five Minute Chat are in UTC (Coordinated Universal Time).
The API does not provide specific disconnect reason IDs directly to the client for every scenario (e.g., maximum CCU reached). However, you will be notified in the web dashboard if issues like persistent CCU overage start leading to connections being denied.