*** id: 952fc9a5-3b75-45a5-adb7-d48ceab0f0fb title: Chat sidebar-title: Overview position: 0 slug: /node/reference/chat description: >- Access the Chat API for building real-time chat applications. Subscribe to channels, send messages, and track member presence in chat rooms. max-toc-depth: 3 ---------------- [chat-client-1]: /docs/server-sdk/v3/node/reference/chat/client [chat-client]: /docs/server-sdk/v3/node/reference/chat/client/events Access the Chat API Consumer. You can instantiate a [Chat.Client][chat-client-1] to subscribe to Chat events. Please check [Chat Events][chat-client] for the full list of events that a [Chat.Client][chat-client-1] can subscribe to. #### Example The following example logs the messages sent to the "welcome" channel. ```javascript import { Chat } from "@signalwire/realtime-api"; const chatClient = new Chat.Client({ project: "", token: "", }); chatClient.on("message", (m) => console.log(m)); await chatClient.subscribe("welcome"); ``` ## Classes The main Chat client for sending messages, managing members, and subscribing to chat events. Represents a member in a chat channel with properties for identity and state. Represents a chat message with content, sender information, and metadata.