Managed agents on any model
coreloop is an independent implementation of the Claude Managed Agents API. Change the base URL, add your own provider keys, and your agent code runs unchanged on the model you choose.
from anthropic import Anthropic
client = Anthropic(base_url="https://api.coreloop.run")
agent = client.beta.agents.create(
name="Code Reviewer",
model="openrouter/moonshotai/kimi-k3",
system="You review pull requests.",
tools=[{"type": "agent_toolset_20260401"}],
)How it works
Code written against the Claude Managed Agents beta works without changes.
1
Point your SDK at coreloop
Swap the base URL to api.coreloop.run. Endpoints, request shapes, and the event stream match the Managed Agents beta.
2
Add provider keys
OpenRouter, OpenAI, Anthropic, Google, or a Codex subscription. Tokens bill to your own accounts.
3
Run sessions
The pi harness executes the agent loop in a sandboxed container. Sessions persist and can run for hours.
Features
The runtime is the same whichever model a session uses.
Sandboxed execution
Each session runs in an isolated container with bash and a filesystem.
Persistent sessions
Event history is stored, so you can disconnect and resume later.
Event streaming
Server-sent events for messages, tool calls, and status.
MCP servers
Connect your own tools over MCP.
Interrupt and steer
Send a message mid-run and the agent picks it up on the next turn.
Traces
coreloop records every tool call and token for inspection or export.
Get access
coreloop is in beta. Sessions bill to your own provider accounts.