Step 3: Model + Channel Wiring

Connect your first AI model and messaging channel for end-to-end communication.

What You'll Do

Set up your AI model provider and connect at least one messaging channel (Telegram, Discord, etc.).

Configure AI Model

1. Get API Key

Choose one provider:

  • **Anthropic (Claude)**: [console.anthropic.com](https://console.anthropic.com)
  • **OpenAI (GPT)**: [platform.openai.com](https://platform.openai.com)
  • **Google (Gemini)**: [ai.google.dev](https://ai.google.dev)
  • 2. Set Environment Variable

    export ANTHROPIC_API_KEY="your-api-key-here"

    Or add to your `.env` file in the workspace.

    Connect a Channel

    Telegram (Recommended for Beginners)

  • Talk to [@BotFather](https://t.me/BotFather) on Telegram
  • Create a new bot with `/newbot`
  • Copy the bot token
  • Add to openclaw.json:
  • {

    "channels": {

    "telegram": {

    "token": "your-bot-token-here"

    }

    }

    }

  • Start OpenClaw Gateway:
  • openclaw gateway start

    Verification

    Send a message to your Telegram bot. You should receive a response from your OpenClaw assistant.

    Pass Criteria

    ✅ You can send and receive at least one message

    ✅ AI model responds correctly

    ✅ OpenClaw Gateway is running

    Next Step

    Move to [Step 4: Operational Setup](/step/4) to add memory and skills.