Using Synthetic's Anthropic-Compatible API with OpenClaw

This page explains how to configure OpenClaw to use Synthetic's API, which is compatible with Anthropic's Messages API format. It covers obtaining an API key, running onboarding, and setting the base URL.

Read this when

  • You want to use Synthetic as a model provider
  • You need a Synthetic API key or base URL setup

Synthetic provides endpoints that work with Anthropic's API format. OpenClaw includes it as the synthetic provider and relies on the Anthropic Messages API.

PropertyValue
Providersynthetic
AuthSYNTHETIC_API_KEY
APIAnthropic Messages
Base URLhttps://api.synthetic.new/anthropic

Getting started

Get an API key

Obtain a SYNTHETIC_API_KEY from your Synthetic account, or the onboarding process will ask for one.

Run onboarding

openclaw onboard --auth-choice synthetic-api-key

Verify the default model

The default model during onboarding is:

synthetic/hf:MiniMaxAI/MiniMax-M3

Warning

OpenClaw's Anthropic client automatically adds /v1 to the base URL, so supply https://api.synthetic.new/anthropic (not /anthropic/v1). If Synthetic updates its base URL, override models.providers.synthetic.baseUrl.

Config example

{
  env: { SYNTHETIC_API_KEY: "sk-..." },
  agents: {
    defaults: {
      model: { primary: "synthetic/hf:MiniMaxAI/MiniMax-M3" },
      models: { "synthetic/hf:MiniMaxAI/MiniMax-M3": { alias: "MiniMax M3" } },
    },
  },
  models: {
    mode: "merge",
    providers: {
      synthetic: {
        baseUrl: "https://api.synthetic.new/anthropic",
        apiKey: "${SYNTHETIC_API_KEY}",
        api: "anthropic-messages",
        models: [
          {
            id: "hf:MiniMaxAI/MiniMax-M3",
            name: "MiniMax M3",
            reasoning: true,
            input: ["text", "image"],
            cost: { input: 0, output: 0, cacheRead: 0, cacheWrite: 0 },
            contextWindow: 262144,
            maxTokens: 65536,
          },
        ],
      },
    },
  },
}

Built-in catalog

Every Synthetic model uses cost 0 (input/output/cache). Check Synthetic's current model list to see what's available.

Model IDContext windowMax tokensReasoningInput
hf:MiniMaxAI/MiniMax-M3262,14465,536yestext + image
hf:moonshotai/Kimi-K2.7-Code262,1448,192yestext + image
hf:nvidia/NVIDIA-Nemotron-3-Super-120B-A12B-NVFP4262,1448,192yestext
hf:openai/gpt-oss-120b131,0728,192yestext
hf:Qwen/Qwen3.6-27B262,14481,920yestext + image
hf:zai-org/GLM-4.7-Flash196,608131,072yestext
hf:zai-org/GLM-5.2524,288131,072yestext

Tip

Model references follow the pattern synthetic/<modelId>. Run openclaw models list --provider synthetic to list all models accessible on your account.

Model allowlist

If you turn on a model allowlist (agents.defaults.modelPolicy.allow), include every Synthetic model you intend to use. Models missing from the allowlist are not shown to the agent.

Base URL override

If Synthetic changes its API endpoint, update the base URL:

{
  models: {
    providers: {
      synthetic: {
        baseUrl: "https://new-api.synthetic.new/anthropic",
      },
    },
  },
}

OpenClaw still appends /v1 automatically.