@svpino: Here is how to build and distribute your agent via Slack, Teams, Discord, WhatsApp, or Telegram. This is for those of y…
Summary
A developer advocate shows how to distribute AI agents across Slack, Teams, Discord, WhatsApp, and Telegram using CopilotKit's Channels SDK, which handles platform-specific integrations and native UI rendering.
View Cached Full Text
Cached at: 08/05/26, 12:16 AM
Here is how to build and distribute your agent via Slack, Teams, Discord, WhatsApp, or Telegram.
This is for those of you who are building an agent.
The most popular solution I’ve seen so far is to build a specific integration for each channel.
This takes a ton of work because each platform is different and you need to maintain all those integrations.
Using the Channels SDK from @CopilotKit will make your life way easier.
The flow looks like this:
- Build your agent.
- Create a channel in CopilotKit Intelligence.
- Add the specific platform adapter you want to support.
- Copy and paste the runtime snippet into your app.
- Your agent is now live in that channel.
Basically, their Channels SDK handles all the plumbing that lets you integrate your agents across every messaging platform.
You know the rest from here:
Anyone on that channel can mention the agent directly to ask a question or assign work to it.
Your agent will always get the context of the conversation where the work is happening.
By the way, your agents keep full functionality here: they can use tools, retain memory across conversations, render native UI on each platform, and request human approval before important actions.
GitHub Repository: https://github.com/CopilotKit/channels-sdk…
Thanks to the team for partnering with me on this post.
CopilotKit/channels-sdk
Source: https://github.com/CopilotKit/channels-sdk
Channels SDK
Bring any AI agent into Slack, Microsoft Teams, and the channels where work happens — with native, interactive UI.
https://github.com/user-attachments/assets/73d70014-fad1-4ee6-9c0c-97e5e949a04e
Your agent keeps its tools, model, and business logic. Channels gives it a native place to work with people.
Your agent belongs where work happens
Channels connects an AG-UI-compatible agent to the communication platforms your team already uses. The agent can understand the conversation, stream a response, call tools, work with files, render interactive UI, and pause for human approval.
| Bring your agent | Render native UI | Keep people in control |
|---|---|---|
| Use CopilotKit’s built-in agent or connect LangGraph, CrewAI, Mastra, Pydantic AI, Google ADK, and other AG-UI agents. | Describe a message once and render it as native Slack Block Kit, Teams Adaptive Cards, and platform-specific UI. | Put buttons, choices, and approval gates directly into the conversation before an agent acts. |
One interaction, native to every channel
| Slack | Microsoft Teams | Discord |
|---|---|---|
![]() | ![]() | ![]() |
Channels is built for a world where the same agent can meet users across every communication surface. Managed connections for Slack and Microsoft Teams are available through CopilotKit Intelligence, with more channels on the way.
Try it before you build it
Experience a real Channels agent in Slack or Microsoft Teams without configuring an app, runtime, or provider credentials.
Try Channels →
Choose a platform, join the experience, and see how an agent handles context, tool use, and native channel UI.
Build your first Channel
Your agent and application logic run in your infrastructure. CopilotKit Intelligence manages the platform connection and delivers each turn to your long-running Channels process.
Fastest path: let your coding agent drive
Building a Channels agent spans a project, an agent, a managed Channel, a provider app, and a long-running runtime. One guide walks your agent through all of it.
npx copilotkit@latest channels setup
That installs the channels-setup skill, prints a prompt, and copies it to your clipboard. Paste it into your coding agent.
The skill is a pointer — it fetches the workflow from copilotkit.ai/channels-guide.md when your agent needs it, so the steps are current even if the installed skill is months old. The guide asks which platform you want, Slack or Microsoft Teams, and which agent framework.
Your agent drives the Slack and Intelligence consoles itself, in your own signed-in session. If it has no browser or computer-use tool yet, it will ask you to add one first — that is the intended path, not a fallback. You type the secrets; it does the clicking.
Or install the Slack setup skill on disk
Skip the hosted guide and put the Slack workflow directly in the coding agent you are already running in:
npx copilotkit@latest skills install --skill setup-slack-channel -y
-y installs that one skill without opening a picker. The skill is scoped to Slack — for Microsoft Teams, use the guide above.
The CLI covers the Intelligence side: copilotkit channels add --adapter slack declares the Channel and attaches the adapter, and copilotkit channels status compares your configuration, your code, and the server. What stays in the browser is the provider side — creating the Slack app and installing it into a workspace — plus issuing the project API key. No CLI flag accepts a credential value, so the bot token and signing secret stay in your .env and with you.
Unknown option '--skill'? An oldercopilotkit— globally installed or left in the npx cache — is shadowing the current CLI. Keep the@latest; that is what forces npx to fetch the current version instead of reusing what it already has.
The steps below are the same path, done by hand.
1. Configure the connection
Create a Channel in CopilotKit Intelligence and connect Slack. Keep the Channel Code and project-scoped Intelligence API key for the next steps.
You need Node.js 22 or later and a long-running Node process or container.
2. Install the SDK
npm install @copilotkit/channels @copilotkit/runtime
npm install --save-dev tsx typescript @types/node
npm pkg set type=module
Channels and Runtime ship together as a tested pair. Upgrade both packages together.
3. Create the listener
The example below uses CopilotKit’s built-in agent. Replace makeAgent with any AG-UI-compatible agent factory without changing the Channel lifecycle.
// channel.ts
import { createServer } from "node:http";
import { createChannel } from "@copilotkit/channels";
import {
BuiltInAgent,
CopilotKitIntelligence,
CopilotRuntime,
} from "@copilotkit/runtime/v2";
import { createCopilotNodeListener } from "@copilotkit/runtime/v2/node";
function required(name: string): string {
const value = process.env[name];
if (!value) throw new Error(`Missing required environment variable: ${name}`);
return value;
}
function makeAgent(threadId: string) {
const agent = new BuiltInAgent({ model: "openai:gpt-5.4-mini" });
agent.threadId = threadId;
return agent;
}
const channel = createChannel({
name: required("CHANNEL_CODE"),
identifyUser: "platform",
agent: makeAgent,
});
channel.onMessage(async ({ thread, message }) => {
await thread.runAgent({
prompt: message.contentParts?.length
? [
...(message.text
? [{ type: "text" as const, text: message.text }]
: []),
...message.contentParts,
]
: message.text,
context: [{ description: "Originating platform", value: message.platform }],
});
});
const intelligence = new CopilotKitIntelligence({
apiKey: required("INTELLIGENCE_API_KEY"),
});
const runtime = new CopilotRuntime({
agents: {},
intelligence,
identifyUser: () => ({
id: "channels-runtime",
name: "Channels Runtime",
}),
channels: [channel],
});
const listener = createCopilotNodeListener({
runtime,
basePath: "/api/copilotkit",
});
const channels = listener.channels;
if (!channels) throw new Error("Channels control surface was not created.");
const server = createServer(listener);
const shutdown = async () => {
await channels.stop();
if (server.listening) server.close();
};
process.once("SIGINT", shutdown);
process.once("SIGTERM", shutdown);
await channels.ready({ timeoutMs: 30_000 });
const status = channels.status();
if (status.overall !== "online") {
throw new Error(`Channel is not online: ${JSON.stringify(status)}`);
}
const port = Number(process.env.PORT ?? 3000);
server.listen(port, () => {
console.log(`Channel online; lifecycle server listening on :${port}`);
});
4. Start it
# .env
OPENAI_API_KEY=<openai-api-key>
INTELLIGENCE_API_KEY=<project-api-key>
CHANNEL_CODE=<channel-code-from-intelligence>
PORT=3000
node --env-file=.env --import tsx channel.ts
When Intelligence reports Online, invite the app to a Slack channel and mention it. Your agent now receives the conversation and responds in the thread.
Want Microsoft Teams, a different agent framework, interactive approvals, files, or production deployment guidance? Continue in the Channels documentation.
Rather have your agent do it? Run
npx copilotkit@latest channels setupfrom Fastest path above. The guide covers this same setup plus the provider and verification steps.
How it works
Every turn follows the same path:
- A person messages your app in Slack or Microsoft Teams.
- CopilotKit Intelligence receives the platform event and delivers it to your Channels process.
- Channels runs your agent over AG-UI, executes tools, and renders the result.
- Intelligence sends native platform UI back into the conversation.
| You run | CopilotKit Intelligence manages |
|---|---|
| Your agent, model credentials, tools, and business logic | Slack and Microsoft Teams platform credentials |
| The long-running Channels listener | Platform ingress and credentialed delivery |
| Application state, deployment, and logs | Runtime registration, health, and reconnects |
The SDK is open source and MIT licensed. CopilotKit Intelligence can be hosted by CopilotKit or self-hosted for enterprise deployments.
See a complete Channels app
OpenTag is an open-source, self-hosted on-call triage assistant built with Channels.
Use it to study a complete application with:
- a Python LangGraph agent connected over AG-UI
- native Slack and Microsoft Teams experiences
- file-aware prompts and generative UI
- human approval before Linear or Notion writes
- a production-shaped Node runtime and agent service
Explore the OpenTag source →
Developer resources
| I want to… | Start here |
|---|---|
| Experience Channels without setup | Try Channels |
| Build a Channel with my coding agent | npx copilotkit@latest channels setup |
| Build my first Channel | Channels documentation |
| Inspect the SDK implementation | Channels source in CopilotKit |
| Install the package | @copilotkit/channels on npm |
| Study a complete application | OpenTag |
| Connect an existing agent | AG-UI integrations |
| Understand the protocol | AG-UI |
License
MIT © CopilotKit
Atai Barkai (@ataiiam): 🚀 Introducing the 𝙲𝚑𝚊𝚗𝚗𝚎𝚕𝚜 𝚂𝙳𝙺
Bring any Agent to any Channel. Slack, MS Teams, WhatsApp, and more.
A significant jump from the state of the art across every dimension.
With support for: → Generative UI → Streaming replies → User-based auth → Per-user learning
Similar Articles
Show HN: The Channels SDK – Bring Any Agent to Any Channel (Slack, MS Teams)
CopilotKit announces Channels SDK, an open-source toolkit that lets developers connect any AG-UI-compatible AI agent to Slack, Microsoft Teams, and Discord with native interactive UI, tool calling, and human approval gates.
Channels SDK
Channels SDK enables developers to deploy AI agents to Slack and Teams without the usual production headaches.
Agents are meant to be shared, but existing tooling is not fit for purpose
The author discusses the difficulty of sharing AI agent workflows across teams and introduces Nairi, a tool for deploying Claude Code-backed agents in Slack with shared access.
@caspar_br: For agents to spread through a company they have to meet people where work already happens. Fleet is built around this:…
Fleet is a platform that lets you build and deploy AI agents directly inside Slack, Teams, email, and other tools so they can be used where people already work.
Bring your own Agent to MS Teams
Microsoft’s new Teams TypeScript SDK lets developers expose existing AI agents or bots as Teams apps with a three-line HTTP server adapter, enabling shared agent logic across Slack and Teams.


