An open-source managed agent runtime for application backends.
Run OpenAI Codex, Claude Agent SDK, and OpenCode behind API endpoints in isolated AI agent sandboxes.
Try mosoo · Website · API Documentation · mosoo-agent-driver · mosoo-connector · mosoo-skills
mosoo provides a Cloudflare-native control plane to stream tool activity, inspect Run history, and keep Threads and files across executions. It is self-hostable in your own account.
Your application remains yours. Its backend owns product behavior and end-user access. mosoo focuses on Agent execution and lifecycle.
mosoo v1 targets research, data analysis, file processing, and report generation through Project key + harness/model + instructions + Input + optional files -> durable Session. The #582 release uses a configured Project model account (BYOK). Direct invocation is the primary path; a saved private Agent is an optional preset. Platform model supply and commercial billing are separate #636 work. Acceptance covers a single-turn ghFind repository evaluation and CSV analysis with durable follow-up, including recovery after runtime reclamation. Both use the same Session API and checkpoint gate. Project keys have shipped; the Session transition is not complete. See SPEC and remaining execution slices.
The durable Session contract can use the existing Thread API and conversation IDs. Compatible names and fields do not need a separate API migration. Moving shared Agent machines to isolated Sessions does require a verified transition for existing Cloud workloads; see the migration contract.
Cloud debug Previews have a separate target lifecycle: continue within 30 days of debugging activity, then clean up the Preview and start a new one on return. Formal and API-used Sessions retain their continuation contract. Existing Preview cleanup requires an approved inventory and backup plan; see Thread Lifecycle.
The unreleased /api/v2/projects/{projectId}/threads entry point accepts inline harness/model configuration or an explicit saved Agent preset, with optional userId. Project file upload and direct creation use the same Session kernel; inline execution creates no hidden Agent. Direct hosted acceptance and coordinated release are still pending. /api/v1 retains published/live selection and its existing identity contract. This version boundary changes configuration admission, not conversation IDs; see the API compatibility contract.
configure Agent + Skills + MCP + provider
-> preview and publish an Agent version
-> call it from a backend or the mosoo console
-> stream events, handle permission requests, inspect files and usage
-> continue a durable Thread across Runs
What works today across the Agent runtime and API:
- Agent runtime and control plane. Configure and run OpenAI Codex, Claude Agent SDK, and OpenCode behind one normalized runtime protocol.
- Agent API. Start, follow, continue, stop, archive, and delete Agent work from a trusted backend.
- AI agent sandboxes. Stream responses and tool activity, handle permission requests, cancel work, and inspect diagnostics in isolated execution environments.
- Durable work. Keep Threads, Runs, events, and managed files across individual executions.
- Agent observability. Inspect Run status, replayable activity, diagnostics, and usage estimates; this is operational visibility, not a compliance audit trail or provider bill.
mosoo is for developers extending Codex, Claude Agent SDK, OpenCode, or another coding agent into products and automations who do not want to operate a separate agent runtime, Sandbox service, session store, file pipeline, and Agent API for every integration.
mosoo is in Alpha. The managed runtime and Agent API surfaces above are shipped and covered by repository tests, but production reliability and external adoption have not been proven. Public APIs and product behavior may still change.
The fastest way to try mosoo is the hosted console at cloud.mosoo.ai. To run it yourself, self-host from a clean clone as below.
bun >= 1.4.0-canary.1just >= 1.51- A Docker-compatible daemon for Agent runtime and Sandbox flows
git clone --recurse-submodules https://github.com/langgenius/mosoo.git
cd mosoo
just setup
just devjust setup installs dependencies, initializes submodules, creates or completes apps/api/.dev.vars, installs Git hooks, and applies pending local D1 migrations. just dev reapplies pending migrations before starting the web and API development servers.
Local URLs:
- Web:
http://localhost:5173 - API:
http://localhost:8787
Minimum smoke:
curl http://localhost:5173/api/health
curl http://localhost:8787/api/healthAPI health is /api/health, not /health. The mosoo control-plane development login uses OTP; under local loopback origins, addresses ending with @mosoo.ai skip that OTP and log in directly.
If setup fails, start with the focused recipe: submodule issues use git submodule update --init, missing local secrets use just env-init, and D1 schema errors use just db-migrate. See CONTRIBUTING.md for the full workflow and verification expectations.
The unreleased #582 candidate uses an independent durable workspace for every new Session. Agent creation, import and Fork no longer select Pet/Cattle; existing shared Cloud Sessions retain their bindings until verified migration. See Session isolation for continuity and the 30-day Cloud Preview policy.
The final release uses one Session execution model, with direct harness invocation and optional Agent presets. Its one-time Cloud transition may make reviewed old Sessions read-only after 30 days without their own calls or file activity, preserving history and saved files even when the account remains active. Protected Sessions retain seamless continuation. Conversion, backup and rollback have a finite release procedure; they do not become a permanent migration product.
Codex Pet shows a published mosoo Agent integrated into an existing product backend through the Thread API. The same API can expose Agents backed by Claude Agent SDK or OpenCode.
Mosoo.Agent.as.API.mp4
- API documentation: mosoo.ai/docs
- Canonical product contract: docs/SPEC.md
- Current implementation architecture: docs/architecture.md
- Production SLO and incident policy: docs/operations/reliability.md
- PRD index and historical implementation contracts: docs/prd/README.md
The public landing page and blog live in the private langgenius/mosoo-website repository and are deployed separately on mosoo.ai.
- Bug reports and feature requests: GitHub Issues
- Product updates: mosoo.ai
Contributions are welcome. Read CONTRIBUTING.md for the development workflow, commit policy, and verification expectations. Contributions are covered by the Contributor License Agreement; CLA Assistant will prompt you on your first pull request.
mosoo is licensed under the Apache License 2.0.
