Comprehensive tutorial series for OpenClaw AI agent gateway
The OpenClaw Gateway is the always-on process that connects your AI agent to messaging channels, manages sessions, and orchestrates tool execution.
openclaw.json~30 minutes for all sections
node --version)The Gateway is a single, always-on Node.js process that:
┌─────────────┐ ┌─────────────┐ ┌─────────────┐
│ Telegram │────▶│ Gateway │────▶│ LLM API │
│ Discord │◀────│ (port │◀────│ (OpenAI, │
│ WhatsApp │ │ 18789) │ │ Claude) │
└─────────────┘ └─────────────┘ └─────────────┘
│
▼
┌─────────────┐
│ Workspace │
│ (files, │
│ memory) │
└─────────────┘
OpenClaw uses JSON5 format (comments and trailing commas allowed):
// ~/.openclaw/openclaw.json
{
// This is a comment!
gateway: {
port: 18789, // trailing comma OK
},
}
The Gateway supports hot reload for safe changes:
Send SIGHUP to reload:
kill -HUP $(pgrep -f "openclaw gateway")
Or use the CLI:
openclaw gateway restart
# Install
npm install -g openclaw
# Initialize configuration
openclaw init
# Start gateway
openclaw gateway
# In another terminal, check status
openclaw status
Start with Installation →