OpenClaw with a custom provider

Add this provider to openclaw.json, and OpenClaw runs its agents on Claude, GPT, Gemini and Grok models through your AIGROW key.

Already have a code? Redeem it on API access, then create a key.

Your openclaw.json

{
  models: {
    providers: {
      aigrow: {
        baseUrl: "https://aigrow.gg/v1",
        apiKey: "ag_your_key_here",
        api: "openai-completions",
        models: [
          { id: "claude-opus-5.5", name: "Claude Opus 5.5", contextWindow: 1000000 },
        ],
      },
    },
  },
  agents: {
    defaults: { model: { primary: "aigrow/claude-opus-5.5" } },
  },
}

Swap ag_your_key_here for a key from API access.

What the film says
  1. Right now, every call to Claude or GPT costs you list price.
  2. The bill grows with every user you add.
  3. The same models. Up to 75% below list.
  4. One endpoint forClaude, GPT, Gemini and Grok
  5. $100 of API credit for $25. Savings vary by model. No model costs more than list.
  6. API creditClaude, GPT, Gemini and Grok models through one endpoint, on prepaid credit. $25. Start today.

Where the setting lives

The config
~/.openclaw/openclaw.json
The key, if you keep it out of the config
~/.openclaw/.env

Keep the key out of the config

Put the key in ~/.openclaw/.env, the file OpenClaw recommends for provider keys, and write ${AIGROW_API_KEY} as the apiKey.

# ~/.openclaw/.env
AIGROW_API_KEY=ag_your_key_here

# openclaw.json, in the aigrow provider
apiKey: "${AIGROW_API_KEY}",

More models

List every id you want under models, then switch with openclaw models set, for example openclaw models set aigrow/claude-opus-5.5.

{
  models: {
    providers: {
      aigrow: {
        baseUrl: "https://aigrow.gg/v1",
        apiKey: "ag_your_key_here",
        api: "openai-completions",
        models: [
          { id: "claude-opus-5.5", name: "Claude Opus 5.5", contextWindow: 1000000 },
          { id: "grok-4.7", name: "Grok 4.7", contextWindow: 500000 },
          { id: "gpt-6.1-sol", name: "GPT-6.1 Sol", contextWindow: 1050000 },
        ],
      },
    },
  },
  agents: {
    defaults: { model: { primary: "aigrow/claude-opus-5.5" } },
  },
}

Which model to use

Put the id in exactly as it is written here.

Claude Opus 5.5claude-opus-5.5
The default in every block on this page and a good main model for agent work. Context: 1,000,000 tokens.
Grok 4.7grok-4.7
For a Grok model. It costs less per token received than any Claude model here. Context: 500,000 tokens.
GPT-6.1 Solgpt-6.1-sol
For a GPT model. It costs less than Opus per token sent and per token received. Context: 1,050,000 tokens.
Claude Fable 5.2claude-fable-5.2
Costs more per token than Opus. Compare the two on the coding leaderboard before you switch. Context: 1,000,000 tokens.

The price list has every id and its credit rate, Claude API pricing has the list prices, and the coding leaderboard compares the models on coding prompts.

Check that it works

First the key on its own, then OpenClaw with it.

The key

Ask for the model list. It needs a valid key and costs nothing.

curl https://aigrow.gg/v1/models -H "Authorization: Bearer ag_your_key_here"

A working key gets the list back:

{
  "object": "list",
  "data": [
    { "id": "claude-opus-5.5", "object": "model", ... },
    { "id": "claude-fable-5.2", "object": "model", ... },
    { "id": "claude-fable-5.1", "object": "model", ... },
    { "id": "gpt-6-astra", "object": "model", ... },
    { "id": "claude-sonnet-5.5", "object": "model", ... },
    { "id": "gpt-6.1-sol", "object": "model", ... },
    { "id": "gpt-6.1-terra", "object": "model", ... },
    { "id": "grok-4.7", "object": "model", ... },
    { "id": "gemini-4-argon", "object": "model", ... },
    ...
  ],
  "has_more": false
}

OpenClaw

Run one turn from the terminal. agent exec reads the same config and needs no running OpenClaw Gateway.

openclaw agent exec "Reply with the word ready" --model aigrow/claude-opus-5.5

A working setup prints the reply and exits with code 0:

ready

When it fails

The OpenClaw errors first, then the answers the endpoint gives any tool.

The OpenClaw Gateway refuses to start after the edit
OpenClaw rejects a config with an unknown key, a wrong type or an invalid value. openclaw doctor names the exact problem, and openclaw doctor --fix applies the repairs it knows.
OpenClaw warns about ${AIGROW_API_KEY}
The variable is missing or empty, so the provider has no key. Set AIGROW_API_KEY in ~/.openclaw/.env or in the environment OpenClaw starts in.
openclaw models set says the provider is unknown
The provider has to be in models.providers first. Check that the id is aigrow in the config and in the model reference, as in aigrow/claude-opus-5.5.
My tool says 401 or authentication error
The key is missing or mistyped. Copy it again from API access on the dashboard, and make sure it is sent as the key, not as a model name. A revoked key fails the same way: create a new one and swap it in.
I get 402 or a message about credit
Your balance is empty. Open API access on the dashboard, redeem a code or buy another pack, and the next request goes through. Nothing else needs to change.
It says 404 or Unknown model
The model has to be one the endpoint serves, for example claude-opus-5.5. The provider’s own spellings work too (claude-opus-5-5, anthropic/claude-opus-5.5), but a dated id or any model outside the catalogue is rejected before the request is forwarded, and nothing is billed. Request GET /v1/models with your key for the live list, or read the ids on the price list.
Requests are rejected with 429
The endpoint asked you to slow down. Each 429 carries a retry-after header, and the OpenAI and Anthropic SDKs wait that long and retry on their own. In a loop of your own, wait the seconds it names or send fewer requests at once. A refused request is not billed.
The model is unavailable right now
A 404 that says the model is not available right now means that model is briefly unavailable. Your key and balance are fine. Retry in a moment or send the request to another model.
I get a 502 or 503
A temporary error, and it is never charged to your balance. Retry the request; if it keeps failing, reach us through the store and we will look into it.

What does not work through AIGROW

  • OpenClaw’s own cost figures. The block sets no prices, so OpenClaw counts every request at 0; the activity log on API access shows what each request cost.

  • Live web search inside the model. A web search tool sent with a request is answered from what the model already knows, with no live results. A tool that fetches pages on your own machine still works.

  • Any endpoint past these three: /v1/messages, /v1/chat/completions and /v1/models. The Responses API, embeddings and token counting answer 404.

  • Router fields such as models, route, provider and plugins. They are dropped, so a request always goes to the one model it names.

What a month of OpenClaw costs

OpenClaw is billed per token at the credit rates in the price list. An agent sends the whole conversation again with each step, so a long task costs more than its last message suggests; the activity log on API access shows what each request cost.

Cap what OpenClaw can spend

Give OpenClaw its own keyOn API access, under API keys, create a key named OpenClaw, so the cap applies to this tool alone.
Set a monthly capEnter an amount in dollars in the monthly cap field as you create the key, or set it later on the key’s row. An empty field means no cap.
What happens at the capOnce the key has spent its cap in the calendar month (UTC), the endpoint answers its requests with a 402 error that names the cap, and OpenClaw shows it. A request already running finishes, so a month can end a little above the cap. Raise the cap or wait for the 1st; your other keys keep working.

Questions about OpenClaw and a custom API

How do I add a custom provider to OpenClaw?
Add an entry under models.providers in ~/.openclaw/openclaw.json with baseUrl set to https://aigrow.gg/v1, api set to openai-completions, your key as apiKey and the model ids under models. Then set agents.defaults.model.primary to aigrow/claude-opus-5.5.
Where does OpenClaw keep its config?
In ~/.openclaw/openclaw.json, a JSON5 file, so comments and trailing commas are fine. OPENCLAW_CONFIG_PATH points OpenClaw at a file somewhere else, and the OpenClaw Gateway applies an edit to the file on its own.
Can I set it up without editing the file?
Yes. openclaw config set writes one value at a time, and the Config tab of the Control UI at http://127.0.0.1:18789 shows the same settings as a form.
Can I limit what OpenClaw spends?
Yes. Give OpenClaw its own key on API access and set a monthly cap on it. Once the key has spent its cap in a calendar month (UTC), its requests get a 402 error until the 1st of the next month, and your other keys keep working.

Sources: OpenClaw Custom providers · OpenClaw Configuration · OpenClaw Environment variables · OpenClaw models CLI · OpenClaw agent CLI. Read 28 October 2026.

Set up another tool

  • Claude CodeAnthropic protocol

    Four environment variables, in the shell or in settings.json.

  • ClineOpenAI protocol

    The OpenAI Compatible provider, four fields in the settings screen.

  • Roo CodeOpenAI protocol

    The OpenAI Compatible provider, the same fields as Cline.

  • Kilo CodeOpenAI protocol

    A custom provider in the Providers tab; the model list fills itself.

  • ContinueOpenAI protocol

    A models entry in config.yaml, with provider openai and an apiBase.

  • AiderOpenAI protocol

    OPENAI_API_BASE and OPENAI_API_KEY, then openai/ before the model id.

  • OpenCodeOpenAI protocol

    A provider block in opencode.json and the key through /connect.

  • ZedAnthropic and OpenAI protocols

    An Anthropic compatible provider for Claude, an OpenAI compatible one for GPT and Grok.

  • GooseOpenAI protocol

    The OpenAI provider with OPENAI_HOST, or a custom provider file.

  • Vercel AI SDKAnthropic and OpenAI protocols

    The OpenAI Compatible provider for every model, or the Anthropic provider for Claude.

  • OpenAI Agents SDKOpenAI protocol

    Your own AsyncOpenAI client, switched to chat completions, with tracing off.

  • LangChainAnthropic and OpenAI protocols

    ChatOpenAI with base_url for every model, or ChatAnthropic for Claude.

The API guide has the SDKs, curl, the endpoints and the error codes.

Paste the block and OpenClaw runs on your credit.

Buy a credit pack, redeem the code from your email on API access, create a key and put it in place of ag_your_key_here.