TutorialsQuickstartAPI Reference

Setup guides for tools and automation workflows.

How to Use ToksHub with OpenClaw

Connect OpenClaw to a single API boundary so agent workflows and application traffic share the same operational surface.

Step 1: Get Your API Key

  1. Go to the dashboard
  2. Sign up or log in to your account
  3. Navigate to API Keys Create New Key
  4. Copy the key

Step 2: Install OpenClaw

macOS / Linux / WSL2

curl -fsSL https://openclaw.ai/install.sh | bash

Windows (PowerShell)

iwr -useb https://openclaw.ai/install.ps1 | iex

Verify the installation:

openclaw --version

Step 3: Configure OpenClaw with ToksHub

Option A: Non-interactive (recommended)

Run onboarding with ToksHub as the custom provider in one command:

openclaw onboard \
  --auth-choice custom-api-key \
  --custom-base-url https://api.tokshub.com/v1 \
  --custom-api-key sk-your-key \
  --custom-compatibility openai \
  --install-daemon

Windows (PowerShell):

openclaw onboard   --auth-choice custom-api-key   --custom-base-url https://api.tokshub.com/v1   --custom-api-key sk-your-key   --custom-compatibility openai   --install-daemon

Option B: Interactive wizard

Run the configuration wizard and select a custom provider when prompted:

openclaw config
  1. Model/auth provider → select Custom
  2. Base URLhttps://api.tokshub.com/v1
  3. API key → paste your ToksHub key
  4. Compatibilityopenai

Step 4: Verify the Gateway

Check that the OpenClaw Gateway is running and connected:

openclaw gateway status

Then open the dashboard:

openclaw dashboard

Step 5: Start Coding

Run OpenClaw in any project directory:

# Explain the codebase
openclaw message "Explain what this project does"

# Generate new functionality
openclaw message "Add rate limiting to the API endpoints"

# Debug issues
openclaw message "Find the source of this memory leak"

Advanced: Switch Models

List available models from ToksHub:

openclaw models list --provider custom

Set a default model:

openclaw models set gpt-4.1

Or call GET /v1/models directly for the full list:

curl https://api.tokshub.com/v1/models \
  -H "Authorization: Bearer sk-your-key"

Troubleshooting

  • Gateway not starting — Verify --custom-base-url has no trailing slash; run openclaw gateway status for details
  • Invalid API key — Use your ToksHub key, not a direct provider key; re-run openclaw config to update the stored credential
  • Outage — Check status
OpenClaw Setup Guide — ToksHub