Channels
FERAL connects to external messaging platforms through channels. Each channel bridges a platform’s API into the Brain’s session system, so users can talk to the agent from Telegram, Slack, Discord, or receive push notifications — all with the same capabilities as the web UI.ChannelManager Architecture
TheChannelManager is a singleton that registers, starts, and supervises channel adapters. Each adapter runs in its own asyncio task and translates platform-specific messages into FeralMessage objects.
Telegram Bot
Setup
- Create a bot via @BotFather and get the token.
- Store the token in the vault:
- Enable the channel in config:
- Start FERAL — the Telegram channel connects automatically.
Features
| Feature | Status |
|---|---|
| Text messages | Supported |
| Voice messages (transcribed via Whisper) | Supported |
| Photos (analyzed via vision) | Supported |
| Inline mode (use FERAL in any chat) | Supported |
| Group chats | Supported (mention-triggered) |
| SDUI cards rendered as Telegram messages | Supported |
Slack Integration
Setup
- Create a Slack app at api.slack.com/apps.
- Enable Socket Mode and add bot scopes:
chat:write,app_mentions:read,im:history. - Store tokens:
- Configure:
Thread Support
FERAL maintains session continuity per Slack thread. A new thread starts a new session; replies within a thread continue the same conversation context.Discord Gateway
Setup
- Create an application at discord.com/developers.
- Add a bot, enable Message Content Intent.
- Invite the bot to your server with
Send Messages+Read Message Historypermissions.
Slash Commands
FERAL auto-registers Discord slash commands on startup:| Command | Description |
|---|---|
/ask <question> | Ask the agent a question |
/remember <fact> | Store a fact in memory |
/status | Show agent status and uptime |
/voice | Join voice channel (experimental) |
Push Notifications
FERAL sends push notifications via Firebase Cloud Messaging (Android/web) and Apple Push Notification service (iOS) for proactive alerts, reminders, and task completions.Configuration
Sending Notifications
Push notifications are triggered by the Brain when proactive events fire (health alerts, reminders, task completions):Device Registration
Clients register their push tokens via the Brain API:Channel-Specific Formatting
Each adapter translates SDUI payloads into platform-native formatting:| SDUI Component | Telegram | Slack | Discord |
|---|---|---|---|
MetricCard | Bold text + emoji | Block Kit section | Embed field |
DataTable | Monospace text | Block Kit table | Code block |
FormCard | Inline keyboard | Modal | Button row |
ImageCard | Photo message | Image block | Embed image |
MarkdownCard | Markdown (subset) | mrkdwn | Markdown |
