| title | Platform Adapters | |
|---|---|---|
| description | Platform-specific adapters that connect your bot to any messaging platform. | |
| type | overview | |
| prerequisites |
|
Adapters handle webhook verification, message parsing, and API calls for each platform. Install only the adapters you need. Browse all available adapters — including community-built ones — on the Adapters page.
Ready to build your own? Follow the building guide.
| Feature | Slack | Teams | Google Chat | Discord | Telegram | GitHub | Linear | |
|---|---|---|---|---|---|---|---|---|
| Post message | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ |
| Edit message | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ |
| Delete message | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ❌ |
| File uploads | ✅ | ✅ | ❌ | ✅ | ❌ | ❌ | ✅ Images, audio, docs | |
| Streaming | ✅ Native | ❌ | ❌ | ❌ | ||||
| Scheduled messages | ✅ Native | ❌ | ❌ | ❌ | ❌ | ❌ | ❌ | ❌ |
| Feature | Slack | Teams | Google Chat | Discord | Telegram | GitHub | Linear | |
|---|---|---|---|---|---|---|---|---|
| Card format | Block Kit | Adaptive Cards | Google Chat Cards | Embeds | Markdown + inline keyboard buttons | GFM Markdown | Markdown | WhatsApp templates |
| Buttons | ✅ | ✅ | ✅ | ✅ | ❌ | ❌ | ✅ Interactive replies | |
| Link buttons | ✅ | ✅ | ✅ | ✅ | ❌ | ❌ | ❌ | |
| Select menus | ✅ | ❌ | ✅ | ❌ | ❌ | ❌ | ❌ | ❌ |
| Tables | ✅ Block Kit | ✅ GFM | ✅ GFM | ✅ GFM | ✅ GFM | ❌ | ||
| Fields | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | |
| Images in cards | ✅ | ✅ | ✅ | ✅ | ❌ | ✅ | ❌ | ✅ |
| Modals | ✅ | ❌ | ❌ | ❌ | ❌ | ❌ | ❌ | ❌ |
| Feature | Slack | Teams | Google Chat | Discord | Telegram | GitHub | Linear | |
|---|---|---|---|---|---|---|---|---|
| Slash commands | ✅ | ❌ | ❌ | ✅ | ❌ | ❌ | ❌ | ❌ |
| Mentions | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ❌ |
| Add reactions | ✅ | ❌ | ✅ | ✅ | ✅ | ✅ | ✅ | ❌ |
| Remove reactions | ✅ | ❌ | ✅ | ✅ | ✅ | ❌ | ||
| Typing indicator | ❌ | ✅ | ❌ | ✅ | ✅ | ❌ | ❌ | |
| DMs | ✅ | ✅ | ✅ | ✅ | ✅ | ❌ | ❌ | ✅ |
| Ephemeral messages | ✅ Native | ❌ | ✅ Native | ❌ | ❌ | ❌ | ❌ | ❌ |
| Feature | Slack | Teams | Google Chat | Discord | Telegram | GitHub | Linear | |
|---|---|---|---|---|---|---|---|---|
| Fetch messages | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ||
| Fetch single message | ✅ | ❌ | ❌ | ❌ | ❌ | ❌ | ||
| Fetch thread info | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ❌ |
| Fetch channel messages | ✅ | ✅ | ✅ | ✅ | ✅ | ❌ | ||
| List threads | ✅ | ✅ | ✅ | ✅ | ❌ | ✅ | ❌ | ❌ |
| Fetch channel info | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ❌ | ❌ |
| Post channel message | ✅ | ✅ | ✅ | ✅ | ✅ | ❌ | ❌ | ✅ |
Each adapter implements a standard interface that the Chat class uses to route events and send messages. When a webhook arrives:
- The adapter verifies the request signature
- Parses the platform-specific payload into a normalized
Message - Routes to your handlers via the
Chatclass - Converts outgoing messages from markdown/AST/cards to the platform's native format
Register multiple adapters and your event handlers work across all of them:
import { Chat } from "chat";
import { createSlackAdapter } from "@chat-adapter/slack";
import { createTeamsAdapter } from "@chat-adapter/teams";
import { createGoogleChatAdapter } from "@chat-adapter/gchat";
import { createRedisState } from "@chat-adapter/state-redis";
const bot = new Chat({
userName: "mybot",
adapters: {
slack: createSlackAdapter(),
teams: createTeamsAdapter(),
gchat: createGoogleChatAdapter(),
},
state: createRedisState(),
});
// This handler fires for mentions on any platform
bot.onNewMention(async (thread) => {
await thread.subscribe();
await thread.post("Hello!");
});Each adapter auto-detects credentials from environment variables, so you only need to pass config when overriding defaults.
The examples above use Redis for state. See [State Adapters](/docs/state) for all available options.Each adapter creates a webhook handler accessible via bot.webhooks.<name>.