Kimi K3 in OpenClaw
Before you start. Create an account (you get $2 to try), then open Token Management → Create token and copy the key. The key starts with sk-. Endpoint: https://microquickjs.com/v1. Model ID: Kimi-K3.
OpenClaw's onboarding default is moonshot/kimi-k3 on Moonshot's own API at $3 / $15. The same model on ainetcafe is $2.10 / $10.50 with $0.30 cached input, and OpenClaw's memory and system prompt hit the cache on every turn. You do not need a plugin: OpenClaw lets you register any OpenAI-compatible endpoint as a custom provider.
Option A: plugin (one command)
openclaw plugins install npm:openclaw-ainetcafe-provider --force --accept-capabilities
export AINETCAFE_API_KEY="sk-..."
openclaw models list --provider ainetcafe --refresh
openclaw agent --local --model ainetcafe/Kimi-K3 --thinking low -m "Say OK"
openclaw gateway restart # if a gateway is already running
--force is needed because npm is outside ClawHub review; the plugin's source is public on GitHub (one 70-line file plus a manifest). It registers provider ainetcafe with the same model definition as Option B, adds the --ainetcafe-api-key onboarding flag, and was tested on OpenClaw 2026.9.4 on 17 September: a plain turn and an exec tool-call turn both completed with winnerProvider: ainetcafe. Prefer Option B if you do not want a plugin at all.
Option B: config only
1. Export the key
export AINETCAFE_API_KEY="sk-..." # add to your shell profile, or put it under env.vars in the config
2. Add the provider to ~/.openclaw/openclaw.json
Merge this into your existing config (JSON5, comments allowed). If the file does not exist yet, this is a complete one.
{
agents: {
defaults: {
model: { primary: "ainetcafe/Kimi-K3" },
models: { "ainetcafe/Kimi-K3": { alias: "Kimi K3 (ainetcafe)" } },
},
},
models: {
mode: "merge",
providers: {
ainetcafe: {
baseUrl: "https://microquickjs.com/v1",
apiKey: "${AINETCAFE_API_KEY}",
api: "openai-completions",
models: [
{
id: "Kimi-K3",
name: "Kimi K3 (ainetcafe)",
reasoning: true,
input: ["text", "image"],
cost: { input: 2.1, output: 10.5, cacheRead: 0.3, cacheWrite: 0 },
contextWindow: 262144,
maxTokens: 65536,
compat: {
supportsReasoningEffort: true,
supportedReasoningEfforts: ["low", "high", "max"],
supportsStore: false,
supportsDeveloperRole: false,
supportsStrictMode: false,
maxTokensField: "max_tokens",
requiresReasoningContentOnAssistantMessages: true,
},
},
],
},
},
},
}
What the fields do: reasoning: true lets /think and --thinking pick a level; supportedReasoningEfforts maps those to K3's low / high / max; requiresReasoningContentOnAssistantMessages keeps K3's reasoning_content in the replayed history, which K3 needs for multi-step tool loops; cost makes OpenClaw's spend estimates right. contextWindow is 256K on the standard plan; set it to 1048576 if we have enabled 1M context for your account.
3. Check and run
openclaw models list --provider ainetcafe
# ainetcafe/Kimi-K3 text+image 262k default,configured
openclaw agent --local --thinking low -m "Say OK"
# OK
openclaw gateway restart # if the gateway is already running, so it picks up the new provider
This is exactly what we ran on 17 September against OpenClaw 2026.9.4: the plain turn returned in one attempt (winnerProvider: ainetcafe, fallbackUsed: false), and a turn that required the exec tool made one tool call with zero failures.
Non-interactive setup
For scripts and CI, OpenClaw's onboarding accepts a custom base URL directly:
openclaw onboard --non-interactive --accept-risk --skip-health \
--mode local \
--custom-base-url "https://microquickjs.com/v1" \
--custom-api-key "$AINETCAFE_API_KEY" \
--custom-model-id "Kimi-K3"
That path registers a generic custom provider without the compat block above; for long tool loops, prefer the explicit config.
Why K3 fits OpenClaw
- OpenClaw ships forty-plus tools and long-running sessions; K3 keeps structured tool calls stable across long loops (402 of 408 schema cases in Moonshot's verifier, streaming and non-streaming).
- Its system prompt and memory are re-sent every turn. With prompt caching that context bills at $0.30 per million instead of $2.10.
- Vision is on: browser screenshots and image attachments go straight to the model (
input: ["text", "image"]).
Verify the key first
Thirty seconds now saves an hour of guessing later. Run this in a terminal; you should see a short reply and a usage block.
curl https://microquickjs.com/v1/chat/completions \
-H "Authorization: Bearer $AINETCAFE_API_KEY" \
-H "Content-Type: application/json" \
-d '{"model":"Kimi-K3","messages":[{"role":"user","content":"Say OK"}],"max_tokens":5}'If something goes wrong
| Symptom | Cause | Fix |
|---|---|---|
| 401 Invalid token | Key copied with a space, or key from another site | Re-copy from Token Management on microquickjs.com |
| 403 quota / insufficient balance | Wallet at zero or plan quota used up | Top up in Wallet, or wait for the weekly plan reset |
| 404 model not found | Model ID typed differently | Use exactly Kimi-K3 (case matters) |
Provider missing from models list | Config not picked up by a running gateway | openclaw gateway restart, or openclaw models list --refresh |
| 429 | Rate limit for your tier | Reduce concurrency; limits rise with spend, or ask for a committed plan |
| Tool loop breaks after the first call | compat block missing, so reasoning_content is dropped on replay | Use the explicit config above, not only the onboarding shortcut |
Still stuck? Email [email protected] with the request ID from the error body.