Context
Vercel just released the Chat SDK (beta, Feb 2026) — a unified TypeScript library for building bots across Slack, Discord, MS Teams, and more. It provides event-driven handlers, AI SDK streaming, universal JSX-based UI (renders to each platform native blocks), and pluggable state management.
agent-slack is currently command-driven (one-shot CLI calls). Chat SDK is event-driven (persistent listeners). These are complementary — combining them would unlock new capabilities without duplicating effort.
Proposed integration surface
1. New bot listen command (highest value)
Add a persistent bot mode that uses Chat SDK Slack adapter under the hood:
# Start a bot that responds to @mentions with an AI agent
agent-slack bot listen "#support" --ai-provider anthropic --model claude-sonnet-4-6
# Listen on multiple channels
agent-slack bot listen "#support" "#engineering" --ai-provider openai --model gpt-4
How it works internally:
import { Chat, createSlackAdapter } from "@vercel/chat-sdk";
import { getStoredAuth } from "../auth"; // reuse agent-slack zero-config auth
export async function botListen(channels: string[], opts: BotOpts) {
const { token, cookie } = await getStoredAuth();
const bot = new Chat({
userName: "agent-slack-bot",
adapters: {
slack: createSlackAdapter({ token }),
},
});
bot.onNewMention(async (thread, message) => {
// Use AI SDK to stream a response
const result = await generateText({
model: opts.aiProvider(opts.model),
prompt: message.text,
});
await thread.post(result.textStream); // streams token-by-token into Slack
});
bot.onSlashCommand("/ask", async (thread, command) => {
const result = await generateText({
model: opts.aiProvider(opts.model),
prompt: command.text,
});
await thread.post(result.textStream);
});
console.log(`Listening on ${channels.join(", ")}...`);
}
Why this matters: Today agent-slack users can only do one-shot CLI calls triggered by an external agent. This would let them spin up a persistent, event-driven bot that lives inside a channel — no separate project needed.
2. Streaming AI replies via message send
Currently message send posts a complete message. With Chat SDK streaming, we could progressively update a message as the AI generates tokens:
agent-slack message send "#general" --stream --ai-prompt "Summarize the last 10 messages in this channel"
Implementation sketch:
// 1. Post an initial placeholder message
const msg = await slack.postMessage(channel, "Thinking...");
// 2. Stream AI response, updating the message in-place
const stream = await agent.stream({ prompt });
for await (const chunk of stream) {
await slack.updateMessage(channel, msg.ts, chunk.accumulatedText);
}
This gives the same "typing" experience users see in ChatGPT/Claude, but inside Slack.
3. Rich Block Kit via Chat SDK JSX renderer
Chat SDK provides a JSX abstraction that renders to each platform native UI. agent-slack could use this to let agents send rich cards without hand-crafting Block Kit JSON:
agent-slack message send "#general" --card '{"title":"PR #42 Review","status":"approved","fields":{"author":"@alice","tests":"passing"}}'
Internally, agent-slack would use Chat SDK JSX renderer to convert this to Slack Block Kit.
4. Chat SDK adapter powered by agent-slack auth
agent-slack zero-config auth (extracting tokens from Slack Desktop/Chrome) is its biggest differentiator. This could be packaged as a Chat SDK adapter for local development:
import { Chat } from "@vercel/chat-sdk";
import { createAgentSlackAdapter } from "agent-slack/adapter";
const bot = new Chat({
adapters: { slack: createAgentSlackAdapter() }, // zero-config, no OAuth app setup
});
This would make Chat SDK usable for local prototyping without going through Slack OAuth app registration flow.
Implementation plan
- Add
@vercel/chat-sdk as an optional peer dependency (keep the CLI lightweight for users who don't need bot mode)
- Implement
agent-slack bot listen — wire agent-slack auth into Chat SDK Slack adapter
- Add
--stream flag to message send — use Chat SDK streaming post capability
- Export an adapter module (
agent-slack/adapter) for Chat SDK users who want zero-config auth
Open questions
- Should
bot listen require a standard bot token (xoxb-) or work with the browser-extracted tokens that agent-slack uses today?
- Should the AI provider be pluggable (AI SDK pattern) or opinionated (e.g. default to a specific provider)?
- Is there interest in packaging agent-slack auth as a standalone Chat SDK adapter?
Would love to hear thoughts on which of these would be most useful to prioritize.
Context
Vercel just released the Chat SDK (beta, Feb 2026) — a unified TypeScript library for building bots across Slack, Discord, MS Teams, and more. It provides event-driven handlers, AI SDK streaming, universal JSX-based UI (renders to each platform native blocks), and pluggable state management.
agent-slack is currently command-driven (one-shot CLI calls). Chat SDK is event-driven (persistent listeners). These are complementary — combining them would unlock new capabilities without duplicating effort.
Proposed integration surface
1. New
bot listencommand (highest value)Add a persistent bot mode that uses Chat SDK Slack adapter under the hood:
How it works internally:
Why this matters: Today agent-slack users can only do one-shot CLI calls triggered by an external agent. This would let them spin up a persistent, event-driven bot that lives inside a channel — no separate project needed.
2. Streaming AI replies via
message sendCurrently
message sendposts a complete message. With Chat SDK streaming, we could progressively update a message as the AI generates tokens:Implementation sketch:
This gives the same "typing" experience users see in ChatGPT/Claude, but inside Slack.
3. Rich Block Kit via Chat SDK JSX renderer
Chat SDK provides a JSX abstraction that renders to each platform native UI. agent-slack could use this to let agents send rich cards without hand-crafting Block Kit JSON:
Internally, agent-slack would use Chat SDK JSX renderer to convert this to Slack Block Kit.
4. Chat SDK adapter powered by agent-slack auth
agent-slack zero-config auth (extracting tokens from Slack Desktop/Chrome) is its biggest differentiator. This could be packaged as a Chat SDK adapter for local development:
This would make Chat SDK usable for local prototyping without going through Slack OAuth app registration flow.
Implementation plan
@vercel/chat-sdkas an optional peer dependency (keep the CLI lightweight for users who don't need bot mode)agent-slack bot listen— wire agent-slack auth into Chat SDK Slack adapter--streamflag tomessage send— use Chat SDK streaming post capabilityagent-slack/adapter) for Chat SDK users who want zero-config authOpen questions
bot listenrequire a standard bot token (xoxb-) or work with the browser-extracted tokens that agent-slack uses today?Would love to hear thoughts on which of these would be most useful to prioritize.