Skip to main content
Agent37 provides four managed services for stock templates and custom images. You do not need your own provider keys or accounts.
These managed services are intended only for agents and applications running inside Agent37-hosted instances. Requests from outside this hosting environment may be denied.
LLM and Brave are APIs; Composio and Perflo are MCP servers. Configure the LLM URL as your model client’s base URL. Register Composio and Perflo with your MCP client.

Credentials in your instance

Every Agent37 instance boots with credentials already in its environment. Your image does not receive them from you, does not store them, and does not need to ask for them: That token opens all four services. This applies to any image, including one you built yourself from scratch: the platform injects these at container create, not the image. Those six are the contract, alongside the three switches in Not using them. A container’s environment carries other AGENT37_-prefixed variables that are runtime internals; they change without notice, so build against the six above.

Spend workspace credit with the starter token

The starter token is the instance credential now named AGENT37_MANAGED_TOKEN. AGENT37_STARTER_TOKEN and OPENCLAW_STARTER_TOKEN are older aliases for the same value; use AGENT37_MANAGED_TOKEN in new code. Send it as Authorization: Bearer on each managed request, as the examples below show. Read it from the instance environment on every boot. To let an instance spend:
  1. Fund the workspace wallet, or use its available signup credit.
  2. Grant the instance budget headroom, which defaults to zero. At create, "budget": { "credit_micros": 1000000 } grants $1 of one-time headroom. For an existing instance, use the request below.
  3. Call a managed service with the instance token. Agent37 charges the workspace wallet and counts the usage against that instance’s budget automatically.
Run this from your backend with your workspace API key to grant an existing instance $1 of one-time headroom. Set INSTANCE_ID to the id returned when you created the instance:
The sk_live_... workspace key manages budgets; the instance token authorizes managed-service usage. The token does not contain money, and granting headroom does not add funds to the wallet. Both wallet funds and instance headroom must be available for a paid call to succeed. Run the service examples below inside the instance, where the environment variables are set.
Paste this into your coding agent

LLM router

Agent37’s LLM router uses OpenRouter and passes through the reported inference cost with no Agent37 markup. Choose any supported paid model from its catalog; you do not need your own OpenRouter account or API key. The cost draws on the same workspace wallet as the other services. Set an OpenAI-compatible client’s base URL to $AGENT37_LLM_PROXY_URL and its API key to $AGENT37_MANAGED_TOKEN. The router exposes GET /llm/v1/models and POST /llm/v1/chat/completions. It is a plain HTTP API, not an MCP server. List the available models:
Send a completion:
"default" is a fast, low-cost model we pick and keep current. To choose another model, replace "default" with an exact data[].id from the model list, using its OpenRouter provider/model name. Listing models is free. Set "stream": true for streaming completions. Free models and models without tool support are rejected, because agents need tools. This model list belongs to the router. The Agent API model list on your instance’s URL describes the models configured in that instance’s agent harness. Call Brave Search with POST $AGENT37_BRAVE_PROXY_URL, the same bearer token, and a JSON body. It is an HTTP API, not an MCP server. Each call costs $0.005 (5,000 micros).
query is required. count is optional and is clamped to 1 through 20. Optional string fields are country, searchLang, uiLang, safesearch, and freshness. The response is Brave’s JSON search result, with web results under web.results.

Integrations

A Composio MCP server, scoped to this instance’s own entity, at $AGENT37_COMPOSIO_MCP_URL with the same bearer token. It speaks streamable HTTP.
Some MCP clients append /mcp to whatever URL you give them. That lands on https://api.agent37.com/mcp/composio/mcp, which is the same server, so register the URL as-is either way. It exposes a handful of meta-tools rather than hundreds of individual ones, so it costs very little context: the agent searches the catalog for what it needs, then executes it. The tool names and their behavior are Composio’s surface, documented in Composio’s meta-tools reference. Billing is ours and is simple: discovery (searching tools, fetching schemas) is free; executing tools and managing connections bills per tool call, with a batch execute capped at 50 calls.
The connection-management meta-tool lets the agent start its own OAuth connections from inside the instance. Driving the integrations API from your backend is the alternative, not the prerequisite.
POST and DELETE only. A GET returns 405 by design, because proxying the optional server-push stream would hold one open connection per instance. Well-behaved MCP clients treat 405 as “this server has no server-push stream” and carry on, but some probe the older SSE transport and report the server as failed. If your client offers an explicit transport setting, set it to streamable HTTP.
A pay-per-call MCP server at $AGENT37_PERFLO_MCP_URL, same bearer token, streamable HTTP. It fronts Perflo’s catalog of roughly 490 vendors: web scrapes, people and company lookups, enrichment, generation, phone numbers and calls. The agent buys one call at a time, typically for a cent. There are no vendor accounts to create, no keys to hold, and no subscriptions.
Four tools: Discovery is free; spend and pay are the two that cost anything, and each is charged at the exact amount Perflo reports, with no markup. The spend draws on the instance budget and then the workspace wallet, like every managed service, and lands under perflo in GET /v1/instances/{id}/usage and GET /v1/usage. A spend answers once its charge is final, which is usually about ten seconds, so the agent sees one ordinary tool call rather than a job to poll. A call still running after 240 seconds comes back as a task id instead, to collect with get_task_result when it finishes.
Two categories are switched off on purpose, gift cards and one paid-social group, because an agent moving that kind of money on your balance is not what this is for. With those gone the most expensive single call in the catalog is about $3.50, and a refused call costs nothing.
The agent37-hermes and agent37-openclaw templates register this server themselves at boot from the environment, so their agents simply have the tools. To keep an instance’s agent out of paid tools entirely, switch them off at create (Not using them). A custom image registers the server like any other MCP server:
mcp.json
New instances have the tools already. An instance created before 2026-09-27 needs one POST /v1/instances/{id}/update, which pulls the current image, and then it does too.

Wiring an agent to both

Two config blocks, using pi as the example. Neither contains a credential; both reference the environment variable instead:
A complete, runnable image doing exactly this lives at agent37-platform/pi-agent-image. It stays here as the worked example of the pattern; Pi itself no longer needs it, since agent37-pi is a system template with the managed model already wired.
Reference the variable, never copy its value. The token is reissued, and the previous one revoked immediately, on create, start, restart, update, resize, migrate, and recovery. A config written once with the literal token baked in keeps working until the first restart and then fails with 401 forever, because your config file is on the persistent volume and survives the rotation. If your agent cannot read env vars from its config, have the entrypoint rewrite that file from $AGENT37_MANAGED_TOKEN on every boot, unconditionally. Write-if-absent is the bug.

Budgets

Paid calls across all four services debit the workspace wallet within the instance budget. LLM calls pass through OpenRouter inference cost with no markup; Brave calls cost $0.005 each; billable Composio tool calls cost $0.000114 each; Perflo passes through its reported charge with no markup. Check spend with GET /v1/instances/{id}/usage. Budget or wallet refusals are a 402:
insufficient_balance is the other type, meaning the workspace wallet is empty rather than the instance cap being reached.
An instance created without a budget has a cap of zero, and paid managed calls return 402. Pass one at create, or PATCH /v1/instances/{id}/budget with monthly_cap_micros. Agents often surface this badly: a 402 from the model endpoint can look like a hang rather than an error. If a new instance’s agent does nothing, read GET /v1/instances/{id}/budget first.

Filesystem rules for a custom image

/home/node is a persistent volume bind-mounted over your image at runtime. The volume is created empty, and nothing is ever copied out of the image into it, so anything your image writes under that path is unreachable from the running container. This catches people twice, because npm’s default global prefix is under /home/node:
Put binaries in /usr/local, and put config your agent reads at startup somewhere outside /home too, or have the entrypoint write it into the volume on every boot. Files your agent creates at runtime under /home/node persist normally across restarts and image updates.

Not using them

Nothing obliges your image to touch these endpoints. To run on your own model, ignore the proxy variables and point your agent at your own provider, as in Build a custom image. To skip integrations or paid tools, leave that MCP server out of your agent’s config. Unused endpoints are never billed, because billing is per call. On a stock template, where we write the agent’s config at every boot, the switch is an environment variable you set at create:
Set to false, the template leaves that server or plugin out, so the agent never sees those tools. The other services keep working, and turning one back on is an env edit plus a restart. Leaving all three on costs nothing until the agent calls one.