🦞 OpenClaw Bootcamp
DAY 05 / 16
🦞
OpenClaw Bootcamp · Day 5

Channels: Your Agent, Everywhere

Your agent is running and optimized. Now it needs a voice. Channels are how you talk to your agent — through Telegram, WhatsApp, Discord, iMessage, Slack, or the built-in WebChat. Today you connect them all.

Telegram · WhatsApp · Discord iMessage · Slack · WebChat One Agent, Any Surface
🦞 OpenClaw Bootcamp
DAY 05 / 16
What We Cover Today

Day 5 Agenda

📱

What Is a Channel?

The abstraction that lets one agent live on any messaging surface simultaneously.

✈️

Telegram Deep Dive

Bot commands, inline keyboards, group mode, and media handling beyond the Day 2 basics.

📷

WhatsApp

Meta Business API setup, phone number linking, and what works differently vs Telegram.

🎮

Discord

Bot creation, server permissions, slash commands, and multi-server support.

💬

iMessage & Slack

macOS-only iMessage bridge and the Slack workspace plugin — who each one is for.

🌐

WebChat

The built-in browser interface at port 18789. No setup needed — it’s already running.

🔒

Security & Access

Whitelisting, user IDs, and stopping strangers from talking to your agent.

🎯

Homework

Connect at least two channels and send your first cross-channel message before Day 6.

🦞 OpenClaw Bootcamp
DAY 05 / 16
Today’s Goal

By the end you will have three things

01
At least two channels connected and working — so your agent is reachable from more than one surface
02
A clear mental model of how channels plug into the Gateway and why they all share the same memory and context
03
Whitelisting configured so only you (and whoever you choose) can message your agent
🦞 OpenClaw Bootcamp
DAY 05 / 16
60-Second Recap

Day 4 Recap

What You Optimized
  • Dual-model setup: cheap model for heartbeat, premium for chat
  • Heartbeat extended to 60 minutes — half the API calls
  • Spending limits set on Anthropic and OpenAI dashboards
  • Cost monitoring active via Dashboard and CLI stats
The Result
  • Monthly cost down from ~$70 to ~$17
  • Same agent, same quality where it matters
  • Now ready to add channels without blowing the budget
🦞 OpenClaw Bootcamp
DAY 05 / 16
Core Concept

A Channel Is a Conversation Surface

A channel is any messaging interface connected to your Gateway. Your agent lives in the Gateway. Channels are just doors into it. One agent — many doors.

The Architecture

You send a message on Telegram. The Telegram adapter forwards it to the Gateway. The Gateway passes it to your AI model. The response comes back through the same adapter to your Telegram chat. WhatsApp, Discord, iMessage — identical flow, different adapter.

Why It Matters

All channels share the same memory, the same SOUL.md, the same model config. Switch from Telegram on your phone to Discord on your laptop mid-conversation and your agent remembers everything. Context is in the Gateway, not the channel.

🦞 OpenClaw Bootcamp
DAY 05 / 16
All Channels

Six Ways to Reach Your Agent

✈️

Telegram

Easiest to set up. Free API. Works on every platform. The default first channel for most users.

📷

WhatsApp

QR code scan links your existing WhatsApp account via Baileys. Most reach — 2B+ users worldwide.

🎮

Discord

Best for power users and communities. Slash commands, server integration, multi-channel threading.

💬

iMessage

macOS only. Your agent responds in the native Messages app. Zero extra apps on your phone.

📍

Slack

Plugin-based workspace integration. Ideal if you live in Slack at work.

🌐

WebChat

Built into the Dashboard at port 18789. Already running. No extra setup required.

🦞 OpenClaw Bootcamp
DAY 05 / 16
Architecture

How Channels Connect to the Gateway

✈️ Telegram  |  📷 WhatsApp  |  🎮 Discord  |  💬 iMessage
GATEWAY (port 18789)
Channel Adapters  ·  Session Manager  ·  Memory Router
🧠 AI Model
🧠 Memory
🧠 Tools

Each channel has an adapter that translates between the platform’s protocol and the Gateway’s internal message format. Your config and memory stay in the Gateway — channels are stateless.

🦞 OpenClaw Bootcamp
DAY 05 / 16
Day 2 Foundation

You Already Have Telegram

On Day 2 you set up Telegram as your first channel. Your bot is live and you’ve been messaging your agent from your phone. Today we go deeper.

BotFather token in credentials
Telegram adapter enabled in config
First message sent and received
What’s Next

Now we look at the full Telegram feature set: bot commands, group mode, media handling, and the parts most users miss on the first pass.

🦞 OpenClaw Bootcamp
DAY 05 / 16
Telegram

Beyond the Basics: Full Feature Set

Bot Commands

Register slash commands via BotFather (/setcommands). Your agent can respond to /status, /tasks, /briefing — whatever you define. Commands show as autocomplete suggestions in the Telegram UI.

Group Mode & Privacy Mode

Add your bot to a Telegram group. Telegram’s Privacy Mode (on by default) means bots only see messages that start with a /command or explicitly @mention the bot. OpenClaw respects this — it responds to commands and direct mentions only, without interrupting every group message.

Media Handling

Send photos, voice notes, documents, and locations to your agent. OpenClaw passes image data to vision-capable models. Voice notes are transcribed before processing. Your agent can send formatted replies with Markdown, inline keyboards, and file attachments.

Notifications

Your agent can send proactive messages to your Telegram chat at any time — not just in response to you. This is how heartbeat alerts, morning briefings, and task reminders reach you. No polling required on your end.

🦞 OpenClaw Bootcamp
DAY 05 / 16
Configuration

Telegram Config in openclaw.json

// ~/.openclaw/openclaw.json { "channels": { "telegram": { "enabled": true, "botToken": "$TELEGRAM_BOT_TOKEN", "dmPolicy": "pairing", "groups": { "*": { "requireMention": true } } } } }
Token Location

Set TELEGRAM_BOT_TOKEN as an env variable, or use the tokenFile config option to point to a file on disk. Never paste the literal token into openclaw.json.

dmPolicy

pairing is the default — unknown senders get a code and are blocked until approved via openclaw pairing approve telegram <code>. To find your user ID: message your bot, then run openclaw logs --follow and read the from.id field.

🦞 OpenClaw Bootcamp
DAY 05 / 16
WhatsApp

The 2 Billion User Channel

How It Works

OpenClaw connects to WhatsApp via Baileys — a linked-device protocol (the same method as WhatsApp Web). No Meta Business account required. Scan a QR code in your terminal and your agent runs as a linked device on your existing number.

Requirements
  • → An existing WhatsApp account (personal or business)
  • → Your phone to scan the QR code (one-time setup)
  • → No Meta approval, no paid API, no dedicated number
What Works

Text messages, images, documents, voice notes, and location sharing. Your agent can send messages proactively — the same heartbeat alert mechanism as Telegram. Delivery receipts and read indicators work normally.

Heads Up

Using Baileys on a personal account is technically against Meta’s ToS. Enforcement is rare at low message volumes. Never use it for customer-facing deployments. Session re-auth needed every 1–2 weeks.

🦞 OpenClaw Bootcamp
DAY 05 / 16
Configuration

WhatsApp Config in openclaw.json

// ~/.openclaw/openclaw.json { "channels": { "whatsapp": { "enabled": true, "dmPolicy": "pairing", "allowFrom": ["+1234567890"] } } }
Setup Steps
  • 01

    Install Plugin

    Run openclaw plugins install @openclaw/whatsapp

  • 02

    Link Account

    Run openclaw channels login --channel whatsapp and scan the QR code: WhatsApp → Settings → Linked Devices → Link a Device

  • 03

    Start Gateway

    Run openclaw gateway to bring the connection live

🦞 OpenClaw Bootcamp
DAY 05 / 16
Discord

For Power Users and Communities

Setup in Three Steps
  • 01

    Create Bot

    Go to discord.com/developers, create an application, add a Bot under the Bot tab. Copy the token.

  • 02

    Set Scopes & Permissions

    In OAuth2 → URL Generator, select bot scope (add applications.commands for slash commands). Then in the Bot Permissions section below, check: Send Messages, Read Message History, Embed Links.

  • 03

    Invite to Server

    Use the generated invite URL to add your bot to your server. Copy your Server (Guild) ID from Discord settings.

What Discord Adds
  • → Slash commands with autocomplete in any channel
  • → Thread-based conversations for long tasks
  • → Role-gated access (only @Members can use your agent)
  • → Embeds with formatted output and buttons
  • → Multiple server support — one agent, many servers
Developer Note

Enable the Message Content Intent in the Discord Developer Portal → Bot settings. Without it, your bot can’t read message text in servers — only DMs.

🦞 OpenClaw Bootcamp
DAY 05 / 16
Configuration

Discord Config in openclaw.json

// ~/.openclaw/openclaw.json { "channels": { "discord": { "enabled": true, "token": "$DISCORD_BOT_TOKEN", "dmPolicy": "pairing", "guilds": { "SERVER_ID": { "requireMention": true, "users": ["YOUR_USER_ID"] } } } } }
guilds map

Each server is keyed by its ID. Inside, set requireMention, users allowlist, and roles allowlist. Add a channels map to control which channels the bot can respond in.

Server ID

Right-click the server name in Discord → Copy Server ID (requires Developer Mode enabled in Discord settings). Use this as the key in your guilds map.

🦞 OpenClaw Bootcamp
DAY 05 / 16
iMessage

Your Agent in the Messages App

How It Works

OpenClaw connects via the imsg CLI tool (legacy) or BlueBubbles (recommended for new setups). The gateway communicates with the Messages app over JSON-RPC. Your agent responds from your own Apple ID — no bot account needed. Just text your own number.

Requirements & Limits
  • ! macOS only — no Windows or Linux
  • ! Mac must stay awake and running
  • ! Full Disk Access required for the Gateway process
  • Works from any iPhone/iPad via your number
  • No extra apps — native Messages integration
Enable in Config

Set channels.imessage.enabled: true in openclaw.json and grant Full Disk Access to the Gateway process in macOS System Settings → Privacy & Security → Full Disk Access.

🦞 OpenClaw Bootcamp
DAY 05 / 16
Slack

For Teams That Live in Slack

Plugin-Based Setup

Slack uses a Bolt app (Slack’s official SDK) as the adapter. Create a Slack app at api.slack.com/apps, enable Socket Mode, and add your App Token (xapp-…) and Bot Token (xoxb-…) to OpenClaw credentials. Socket Mode connects outbound — no public URL needed. (The Signing Secret is only needed if you use HTTP mode instead.)

What You Get
  • → DM your agent directly in Slack
  • → Mention @YourAgent in any channel
  • → Slash commands available workspace-wide
  • → Rich message formatting with Block Kit
  • → Agent can post to channels proactively

Slack is best for work contexts where you’re already in Slack all day. For personal use, Telegram is simpler to set up and maintain.

🦞 OpenClaw Bootcamp
DAY 05 / 16
WebChat

Already Running at Port 18789

The Dashboard you’ve been using since Day 2 has a built-in chat interface. No setup. No credentials. Open your browser and start talking.

localhost
:18789
Open in any browser on the machine running Gateway
Full Markdown rendering, code blocks, file uploads
Cost tab, memory viewer, heartbeat log — all in one UI
Best Use Case

Use WebChat for long-form tasks, reviewing memory, and debugging your agent’s behavior. Use mobile channels (Telegram, WhatsApp) for quick interactions on the go.

🦞 OpenClaw Bootcamp
DAY 05 / 16
Reference

Full Channel Block in openclaw.json

{ "channels": { "telegram": { "enabled": true, "botToken": "$TELEGRAM_BOT_TOKEN", "dmPolicy": "pairing" }, "whatsapp": { "enabled": false, "dmPolicy": "pairing", "allowFrom": ["+1234567890"] }, "discord": { "enabled": false, "token": "$DISCORD_BOT_TOKEN", "dmPolicy": "pairing" }, "imessage": { "enabled": false }, // macOS only "slack": { "enabled": false, "appToken": "$SLACK_APP_TOKEN", "botToken": "$SLACK_BOT_TOKEN" }, "webchat": { "enabled": true, "port": 18789 } // always on by default } }

Credentials should never be stored as literal strings in this file. Use environment variables, the tokenFile option, or SecretRef providers. WhatsApp session credentials are stored automatically under ~/.openclaw/credentials/whatsapp/. Restart the Gateway after any config change.

🦞 OpenClaw Bootcamp
DAY 05 / 16
Multi-Channel

One Agent, All Channels Simultaneously

You can enable every channel at once. Your agent handles conversations from Telegram, Discord, and WebChat in parallel. Each conversation is independent but all share the same memory.

What’s Shared
  • SOUL.md (same identity everywhere)
  • Long-term memory (MEMORY.md)
  • Model configuration (same AI model)
  • Heartbeat & scheduled tasks
What’s Per-Channel
  • Session context (conversation history)
  • Message format (Markdown vs plain text)
  • Media capabilities (what each platform supports)
  • Allowed user lists
🦞 OpenClaw Bootcamp
DAY 05 / 16
Formatting

Markdown Support Per Channel

ChannelBold / ItalicCode BlocksLinksMax Length
✈️ TelegramFull MarkdownSupportedInline URLs4,096 chars
📷 WhatsApp*bold*, _italic_, ~strike~Inline + block (```)URL only4,000 chars
🎮 DiscordFull MarkdownFenced blocksEmbeds2,000 chars
💬 iMessagePlain textPlain textPreviews autoNo hard limit
📍 Slackmrkdwn formatBlock KitRich links40,000 chars
🌐 WebChatFull MarkdownSyntax highlightClickableNo limit

OpenClaw automatically adapts response formatting to the channel. Your SOUL.md can instruct the agent to keep responses concise for mobile channels and more detailed for WebChat.

🦞 OpenClaw Bootcamp
DAY 05 / 16
Media & Files

What You Can Send Per Channel

Type✈ Telegram📷 WhatsApp🎮 Discord🌐 WebChat
Images✓ + vision AI✓ + vision AI✓ + vision AI✓ + vision AI
Voice Notes✓ transcribed✓ transcribed✓ via upload− not supported
Documents
LocationText onlyText only

Images are passed to vision-capable models (Sonnet, GPT-4o). Voice notes are transcribed via Whisper before the agent processes them. Your secondary (cheap) model is not used for vision tasks — these always go to your primary model.

🦞 OpenClaw Bootcamp
DAY 05 / 16
Security

Control Who Can Reach Your Agent

Default Risk

By default, dmPolicy is set to "pairing" — unknown senders get a short code and the bot ignores them until you approve via openclaw pairing approve <channel> <code>. Never set "open" on a public-facing bot.

Find Your Telegram User ID

Message your bot, then run openclaw logs --follow and read the from.id field. Add it to allowFrom in your config to allowlist yourself directly.

allowFrom & dmPolicy

Use allowFrom to whitelist specific user IDs or phone numbers per channel. Set dmPolicy: "allowlist" to restrict to that list only. iMessage is inherently private — only your Apple ID can trigger it.

WebChat Security

WebChat binds to localhost (127.0.0.1) by default. It is not reachable from other devices on your network. If you expose port 18789 externally, set a password in the webchat config block.

🦞 OpenClaw Bootcamp
DAY 05 / 16
Decision Guide

Which Channel for Which Use Case

Use CaseBest ChannelWhy
Quick on-the-go questionsTelegramFast, reliable, works everywhere
Already chat with people on WhatsAppWhatsAppNo context switching — same app
Long coding / research sessionsWebChatFull Markdown, no length limits, file uploads
Shared team assistantDiscord / SlackRole-gated, thread support, multi-user
iPhone-first, Mac always oniMessageNative app, no bot account, zero friction
Proactive alerts & briefingsTelegram or WhatsAppPush notifications land reliably on mobile

Most users end up with Telegram + WebChat as their daily pair. Telegram for mobile, WebChat for desktop work sessions.

🦞 OpenClaw Bootcamp
DAY 05 / 16
Before Day 6

Day 5 Homework

  • 01

    Verify Telegram is Secured

    Message your bot, then run openclaw logs --follow and grab your from.id. Add it to allowFrom in your Telegram config. Send a test message and confirm it works.

  • 02

    Connect a Second Channel

    Pick any channel you don’t already have: Discord, WhatsApp, iMessage (macOS), or Slack. Follow the setup steps and send your first message through it. Confirm the response comes back correctly.

  • 03

    Test Cross-Channel Memory

    Tell your agent something on Telegram (“remember that I prefer bullet-point summaries”). Then open WebChat and ask “what do you know about my formatting preferences?”. Confirm the memory carries over.

  • 04

    Send a Voice Note

    On Telegram or WhatsApp, send a voice note to your agent (any question, anything). Confirm the transcription and response come back correctly. This is how you’ll use your agent hands-free.

🦞 OpenClaw Bootcamp
DAY 05 / 16
🦞
Coming Up

Day 6: HEARTBEAT.md
Proactive Automation

Your agent can now reach you anywhere. On Day 6 we teach it to act without being asked. HEARTBEAT.md defines what your agent checks on a schedule, proactively, whether you’re online or asleep.

Scheduled Tasks Morning Briefings Full Automation