Models and keys

An agent on Waken is a harness (the program that runs the agent loop) calling a model with your own API key. You pay your model provider directly. Waken takes no cut and never sees your tokens bill.

Harnesses

HarnessWhat it isWorks with
claude-codeAnthropic's coding agent. The default.Anthropic (key or Claude subscription), OpenRouter, DeepSeek, Moonshot
codexOpenAI's Codex CLI.OpenAI, OpenRouter
openclawThe open source OpenClaw agent. Takes longer per message than the others.Anthropic, OpenAI, Google, DeepSeek, Moonshot, OpenRouter
cursorThe Cursor agent, in script mode. Needs a Cursor API key from your Cursor subscription.Cursor
hermesThe open source Hermes agent by Nous Research.OpenRouter, Anthropic, OpenAI, Google, DeepSeek, Moonshot
zeroclawThe open source ZeroClaw agent, a small and fast runtime with its own memory.OpenRouter, Anthropic, OpenAI, Google, DeepSeek, Moonshot

You can change the model or the harness of a running agent. Its files stay, the new harness receives the recent conversation, and a checkpoint is taken first so a rewind undoes the switch.

OpenRouter is the simplest way to try many models with one key: every harness supports it except Cursor, which runs on your Cursor subscription. We have run Claude Code, Codex, OpenClaw, Hermes and ZeroClaw against it with DeepSeek, Kimi, Gemini and GPT models. Direct connections to DeepSeek, Moonshot, Google and OpenAI are wired but less tested.

Getting a key

ProviderWhereEnvironment variable
Anthropicconsole.anthropic.com, Settings, API keysANTHROPIC_API_KEY
OpenAIplatform.openai.com, API keysOPENAI_API_KEY
OpenRouteropenrouter.ai, KeysOPENROUTER_API_KEY
Googleaistudio.google.com, Get API keyGEMINI_API_KEY
DeepSeekplatform.deepseek.com, API keysDEEPSEEK_API_KEY
Cursorcursor.com, Dashboard, IntegrationsCURSOR_API_KEY
Moonshot (Kimi)platform.moonshot.ai, API keysMOONSHOT_API_KEY

Most providers need a payment method or some credit before a key works. Give the agent its own key, with a spending limit at the provider if they offer one: you can then revoke it without touching anything else.

Using your Claude subscription

With Claude Code, an agent can run on your Claude Pro or Max subscription instead of an API key. Deploy it with auth: subscription and no key, then sign in once from the agent's Terminal tab: run claude, choose your Claude account, open the link it prints and paste the code back. The agent starts as soon as you are signed in, and its spend counter stays at zero.

Deploy on a subscription
# CLI
waken deploy --subscription
# API
curl -X POST https://api.waken.sh/agents \
-H "Authorization: Bearer $WAKEN_API_KEY" -H "Content-Type: application/json" \
-d '{"name": "my-agent", "model": {"provider": "anthropic", "auth": "subscription"}}'
  • You sign in inside Claude Code itself, through Anthropic's own flow. Waken never sees, stores or relays your Claude login: it lives in your agent's machine, encrypted at rest like everything else.
  • Your plan's limits apply: a session allowance that resets every five hours, and a weekly one. When the agent reaches them it pauses until the reset. Anthropic's advertised limits assume ordinary individual use, so an agent working all day will hit them.
  • This follows Anthropic's published conditions for hosting Claude Code. If they change, this option may change with them.
  • The Terminal tab works for every agent: a shell on the machine, as root, in its work folder. Your model key is never in that shell.

Choosing at deploy time

Terminal
# Claude Code on Anthropic (the default when ANTHROPIC_API_KEY is set)
waken deploy
# Codex on OpenAI
waken deploy --harness codex --provider openai
# Any harness on any OpenRouter model
export OPENROUTER_API_KEY=sk-or-...
waken deploy --harness claude-code --provider openrouter --model deepseek/deepseek-v3.2

With the API, pass a model object. The key travels in the request body and goes straight to the agent.

POST /agents
{
"name": "bookkeeper",
"harness": "claude-code",
"model": { "provider": "openrouter", "name": "deepseek/deepseek-v3.2", "api_key": "sk-or-..." }
}

Spend caps

Every agent has a spend cap, 5 dollars by default (spend_cap_usd). At the cap the agent stops cleanly and tells you. The cap is exact with Claude Code, which reports its cost. The other harnesses report tokens (or we estimate them), turned into dollars with an indicative price grid per model: a good guardrail, not an invoice, so also keep a limit on the key at your provider. GET /agents/{id}/usage shows the spend, the tokens, and whether it is estimated.

  • Your key lives in the agent's memory, never in our database, and the API never returns it. The volume that holds agent disks and checkpoints is encrypted at rest.
  • Deleting the agent deletes the key with it, checkpoints included.
Next: plans and limits