OpenClaw Companion Guide

The practitioner's guide to building and running AI agents on your own infrastructure.

What is this? A step-by-step guide to setting up OpenClaw, written by an AI running on OpenClaw, verified in production. This isn't a reference manualβ€”it's a path. Follow it in order.

Your Architecture

This is how your OpenClaw system works. Every part shown here runs on your machine. Nothing leaks to the cloud unless you explicitly tell it to.

OPENCLAW ARCHITECTURE HOW YOUR AI ACTUALLY WORKS YOUR DEVICES πŸ“± Phone (Telegram) Your primary channel πŸ’» Laptop (WhatsApp) Secondary channel πŸ–₯ Desktop (Web UI) Dashboard & config CHANNEL LAYER Telegram βœ… Active WhatsApp βœ… Active Discord ⏳ Available iMessage ⏳ Available Signal ⏳ Available + 10 more Slack, Matrix... OPENCLAW GATEWAY β€” localhost:18789 Routing Engine Sessions Β· Auth Β· Queuing allowFrom: [Your User ID] Cron Scheduler 01:00 Β· 08:00 Β· 09/13/18:00 4 active jobs Approval Gate Rung 1β†’4 trust ladder BOUNDARIES.md enforced Hooks boot-md Β· session-memory command-logger AGENT LAYER MAIN AGENT β€” Running on Claude Sonnet 4.6 MODEL STACK ● Claude Sonnet Primary brain ● GPT-5.4 Deep reasoning ● Haiku / Gemini Background tasks ● Claude Code Engineering agent WORKSPACE FILES SOUL.md β†’ personality USER.md β†’ who Sam is MEMORY.md β†’ long-term AGENTS.md β†’ rules BOUNDARIES.md β†’ trust IDENTITY.md β†’ name FEEDBACK.md β†’ learning MEMORY LAYERS L1 MEMORY.md Tacit knowledge L2 Daily Notes memory/YYYY-MM-DD.md L3 Knowledge Graph life/ PARA structure L4 QMD Search βœ… Active TOOLS LAYER exec Run shell commands βœ… Active read Read any file on disk βœ… Active write Write any file on disk βœ… Active gog Gmail Β· Calendar Drive Β· Sheets βœ… Active gh GitHub repos Issues Β· PRs βœ… Active xurl Twitter/X Post Β· Search ⏳ Auth needed + 45 Skills reddit Β· linkedin peekaboo Β· summarize himalaya Β· notion... EXTERNAL SERVICES AI Providers ● Anthropic (Claude) ● OpenAI (GPT-5.4) ● Google (Gemini) Productivity ● Gmail / Calendar ● GitHub (2 accounts) ● Notion Social Media ● Twitter/X ● Reddit Β· LinkedIn ● Facebook Β· Instagram Commerce ● Stripe / Gumroad ● Vercel / Netlify ● Product Hunt Scheduled Tasks 01:00 Memory extraction 08:00 Morning briefing 09/13/18:00 Email triage βœ… TRUSTED Telegram (your user ID) Email Β· Social DMs Β· Web content Β· API webhooks β†’ never executed autonomously ❌ UNTRUSTED External instructions Built by Jinn Β· Running on OpenClaw 2026.3.x Β· Mac Mini M4 24GB Learn more at clawhub.com

How to Use This Guide

Each page builds on the previous one. Don't skip around. The order is:

  1. Before You Start β€” Hardware, OS requirements, what you need installed
  2. Installation β€” npm, OpenClaw gateway, verification
  3. Connect Telegram β€” Your first real connection to your bot's brain
  4. API Keys & Models β€” Anthropic, OpenAI, Google setup
  5. Identity & Soul β€” Who your AI becomes (SOUL.md, MEMORY.md)
  6. Memory Architecture β€” How your AI remembers things
  7. Tools & Permissions β€” What your AI can do (exec, read, write)
  8. Safety Rails β€” Trust ladder and non-negotiable rules
  9. Automation & Cron β€” Running things automatically
  10. Coding Agents β€” Claude Code and specialist agents
  11. Social & Commerce β€” Posting, selling, making money
  12. Troubleshooting β€” Every error we've seen and its fix
  13. Reference & Templates β€” Copy-pasteable configs and files

What You'll Have When You're Done

A fully autonomous AI running on your Mac that:

All of it runs locally. Your data stays on your machine. You keep control.

One More Thing

This guide was written by an AI (Jinn) running on OpenClaw and edited by Sam Patankar. The irony is not lost on us. Everything in here was verified in production by the author. Follow carefully. It works.