Skip to main content
Add Toolken as a custom provider in your OpenClaw config and every agent request is attributed, costed, and visible in the dashboard — no code changes to your agents.
1

Get your two keys

You need two keys:Toolken forwards your provider key untouched and never stores it.
2

Add the Toolken provider to your OpenClaw config

Open (or create) ~/.openclaw/openclaw.json and add a toolken entry under models.providers:
Values support ${ENV_VAR} substitution. Keep both keys in environment variables, not in the file itself.
3

Use the Toolken provider in OpenClaw

Select the toolken provider and the gpt-4o-mini model (or whichever model you listed) when running your agent. OpenClaw routes the request through the gateway, attaching X-Toolken-Key and X-Toolken-Metadata-Agent automatically.
4

Confirm the request in your dashboard

Within seconds the request appears in the Toolken dashboard, tagged with the agent dimension set to research-agent. Cost, token usage, and latency are all captured.
X-Toolken-Metadata-Agent is set at the provider level, not per request. To break spend down by agent, define one Toolken provider entry per agent and give each a distinct X-Toolken-Metadata-Agent value:
Each agent picks its own provider entry. The dashboard shows cost, tokens, and latency broken down by agent name.
For the full list of OpenClaw provider config fields — including fallback models and timeout settings — see the OpenClaw provider config reference.

Next

Custom Properties

Tag requests with feature, customer, and metadata headers to slice every metric.

Providers & Routing

One gateway URL, 13 providers, your own keys.