One call puts an existing agent in Discord, Slack, or Telegram.

Pass an Anvia agent and a platform adapter to createChannelAgent() and start the service. The bridge handles sessions, streaming, splitting, and approvals, so the agent itself does not change.

From bot token to running assistant.

The service owns the adapter lifecycle. You own the agent, its memory, and its tools.

  1. 01

    Build the agent

    Use the Anvia agent your product already runs.

  2. 02

    Create an adapter

    Discord over Gateway, Slack over Socket Mode, or Telegram with long polling or webhooks.

  3. 03

    Bridge them

    createChannelAgent() connects the agent with streaming and interaction options.

  4. 04

    Start and stop

    Start the service, and stop it cleanly on SIGTERM.

Chat mechanics, handled.

Sessions per sender

DMs and mentions by default, with a conversation session for each sender.

Streaming replies

Replies stream by editing a placeholder message, and long answers are split for the platform.

Native approvals

Paused approvals render as Discord buttons, Slack Block Kit, or Telegram inline keyboards, with text replies as a fallback.

Survives restarts

A SQLite interaction store keeps paused approvals and questions across restarts.

Run an Anvia agent on Telegram.

Swap the adapter for Discord or Slack. The rest stays the same.

assistant.ts
1import { createChannelAgent } from '@anvia/channel-agent'2import { telegram } from '@anvia/telegram'34const channel = telegram({ token: process.env.TELEGRAM_BOT_TOKEN! })5const service = createChannelAgent({6  channel,7  agent,8  streaming: { placeholder: 'Thinking…' },9})1011await service.start()1213process.once('SIGTERM', () => {14  void service.stop()15})

Channels is in beta and its packages are not published to npm yet. Only one interaction can be pending per conversation and sender, and Slack has no typing indicator.

Build it.

Start from the guide, run the example, or look at what else Anvia handles.

Anvia