
Chat SDK adds native Slack agent support
Quick Answer
Vercel AI's Chat SDK now supports native Slack agents through a new adapter, enabling full messaging experiences including suggested prompts, streaming replies, and built-in feedback buttons.
Quick Take
Vercel AI's Chat SDK now supports native Slack agents through a new adapter, enabling full messaging experiences including suggested prompts, streaming replies, and built-in feedback buttons. This integration allows developers to create interactive Slack bots that enhance user engagement and streamline communication.
Key Points
- The Slack adapter supports agent conversations and suggested prompts.
- Streaming replies are token-by-token via Slack's streaming API.
- Feedback buttons are included for user interaction on replies.
- The adapter automatically pins prompts when an agent thread opens.
- Use Chat SDK transcripts for building AI conversation history.
📖 Reader Mode
~2 min readYou can now build native Slack agents with Chat SDK's Slack adapter.
The adapter supports the full Slack agent messaging experience, from agent conversations in the Messages tab to suggested prompts, rotating status messages, token-by-token streamed replies, and native feedback buttons.
lib/bot.ts
import { Chat } from "chat";
import { createSlackAdapter } from "@chat-adapter/slack";
const bot = new Chat({
userName: "mybot",
adapters: {
slack: createSlackAdapter({
agentView: true,
suggestedPrompts: {
title: "Welcome! What can I do for you?",
prompts: [
{ title: "Catch me up", message: "What did I miss today?" },
{ title: "Draft a message", message: "Help me draft a message" },
],
},
loadingMessages: ["Thinking...", "Digging through the archives..."],
feedbackButtons: true,
}),
},
});
Configure your native Slack agent in Chat SDK
Here's what the adapter gives you:
Suggested prompts, per thread: Pass a static payload or an async resolver that receives the thread context, including what the user is currently viewing under
agent_view. Prompts are pinned automatically whenever an agent thread opens.Native streaming with a fallback: Streamed replies render token-by-token via Slack's streaming API, including task and plan cards. If a workspace doesn't support streaming (e.g., GovSlack), the adapter switches to post-and-edit mid-stream without losing content.
Built-in feedback: Set
feedbackButtons: trueand every streamed reply ends with Slack's native thumbs-up and thumbs-down buttons. Clicks dispatch through the regularbot.onActionflow with a positive or negative value.
One thing to know: under agent_view, Slack threads each user message individually, so channel history only returns the user's side of a DM. Use Chat SDK transcripts to build AI conversation history instead.
Read the documentation to get started, or begin with one of our templates.
— Originally published at vercel.com
Want this in your inbox every morning?
Daily brief at your local 8am — bilingual EN/中文, free.
More from Vercel AI
See more →
The Agent Stack
The Agent Stack by Vercel AI provides essential building blocks for creating production-grade agents, enabling seamless integration across multiple AI models and secure operations. It features components like AI Gateway for model routing, Workflow SDK for durable execution, and Vercel Connect for scoped access, streamlining agent development and deployment across various platforms.

