For agents
Note:
You're an agent? Start here. Humans should use For humans and app.molar.it instead.
This path is for AI coding agents (Cursor, Claude Code, Codex, Windsurf, etc.) that need to register, connect MCP, and run scenarios without a human driving the browser first.
What agents can do today
| Capability | Before human verifies | After verify (claimed) |
|---|---|---|
| MCP read/run (scenarios, runs) | ✅ Limited scopes & rate caps | ✅ Full Free-tier scopes |
molar init, scenarios validate/compile | ✅ | ✅ |
Local clones (molar clone …) | ✅ | ✅ |
| Cloud clones via MCP | ❌ | ✅ (within plan entitlements) |
Debugger AI (mcp:debug) | ❌ | ❌ on Free — Team+ or BYOK |
| High-risk explore/act scopes | ❌ | ❌ — requires explicit OAuth consent |
Note:
Agent signup availability: POST https://api.molar.it/api/v1/agent-signup returns 503 when agent signup is disabled in production. If you hit 503, ask your human to sign up at app.molar.it and mint a PAT at Settings → API Tokens instead.
0. Read the index
Fetch docs.molar.it/llms.txt — canonical URLs for every public doc page, agent-first ordering.
1. Self-serve signup
Register without a pre-existing account:
molar agent signup \
--human-email alex@example.com \
--name "QA Assistant" \
--note-to-human "Please verify me so I can run checkout scenarios." \
--harness claude-code
Or via API: POST https://api.molar.it/api/v1/agent-signup
Full request/response reference: Agent self-serve signup.
Before human verification: token scopes are limited to mcp:read and mcp:run. Cloud clones, debugger AI, and high-risk explore/act scopes stay blocked until verify.
2. Human verification
The overseer (human_email) receives a 6-digit code (15-minute expiry). Submit it:
molar agent signup verify --code 483921
# or: POST /api/v1/agent-signup/verify
Check status anytime: molar agent signup status
After verify, scopes expand to the Free tier (mcp:read, mcp:write, mcp:run, mcp:clone:write, mcp:trace:read). The human shares the code from their email — there is no dashboard approval UI yet.
3. Connect MCP
| Transport | Endpoint | When |
|---|---|---|
| Remote HTTP | https://api.molar.it/mcp | Default — Cursor, Claude Code, Windsurf |
| Local stdio | molar mcp serve | Air-gapped; add --cloud-access for cloud tools via PAT |
One-click install: mcp.molar.it
Details: MCP server setup
4. Scaffold and run
molar init --json
molar agent init --json # credentials + connectivity (never prompts)
molar docs --json # task-oriented command routing
molar scenarios validate && molar scenarios compile
molar run # requires Guard runner — run molar doctor first
molar verify "app loads" --url http://localhost:3000 --json
verify automatically selects the authenticated local CloakBrowser daemon for
localhost/private targets and needs no hosted token. Its JSON includes
execution_mode plus owner-only screenshot, WebM, and HAR evidence paths. Use
--execution hosted for cloud execution or --execution local to force local
execution on a public URL.
Generate scenarios from a URL (MCP, not CLI):
- Call
molar_generate_scenarios_from_urlwith a project ID, authorized URL, and intent. - Poll
molar_get_task; usemolar_live_viewwhile the task is in verified replay. - Require terminal
completed,result.success: true, andverifiedon each selected flow. - Download the project-scoped
molar_md,playwright, andmanifestartifacts and validate their SHA-256 values. - Run the compiled Playwright with a fresh identity before committing or separately publishing the source.
For complex sign-up flows, use auth_context plus agent-comms/Clones for email verification, OTP, authentication, and test payments. Never put those values in the intent or scenario source. Retrying the same exact request resolves to the same durable task; stalled workers resume from checkpoints.
molar_run_scenarios executes scenarios after authoring. URL authoring itself never publishes a pull request.
Project config: .molar.md · Compiler: Scenario compiler
5. Credentials
| Method | Use |
|---|---|
Agent signup api_key | Stored in ~/.config/molar/config.toml after signup |
MOLAR_TOKEN env var | CI and scripts |
| Dashboard PAT | Human-minted at Settings → API Tokens — preferred for CI |
molar login --token molar_pat_xxxx validates against GET /api/v1/me and saves credentials locally.
Shipped CLI commands (today)
| Command | Purpose |
|---|---|
molar agent signup | Self-serve registration |
molar agent signup verify | Submit 6-digit code |
molar agent signup status | Claim status and scope restrictions |
molar agent init --json | Zero-config credential + connectivity check |
molar docs [--json] | TesterArmy-style task-oriented command routing |
molar init --json | Scaffold .molar/, .molar.md, AGENTS.md |
molar login --json | Save PAT to config (never prompts with --json) |
molar whoami --json | Confirm authenticated identity |
molar verify "<claim>" --url <u> [--execution auto|local|hosted] --json | Browser-backed claim verification; private targets auto-run locally |
molar scenarios validate / compile | Lint and compile .molar.md |
molar run | Execute compiled scenarios (via Guard runner) |
molar clone <kind> --start|--stop | Local Stripe/Twilio/email/auth/S3 clones |
molar trace open | Open a trace in the browser |
molar mcp serve | Local stdio MCP server |
molar doctor | Dependency health check |
molar upgrade | Self-update |
Every failing path with --json returns { ok: false, error: { code, message, hint } }.
Full reference: CLI reference
Per-product MCP entry points
| Product | Start with | Key tools |
|---|---|---|
| Cartographer | Cartographer MCP tools | molar_generate_scenarios_from_url, molar_compile_scenario |
| Guard | Guard quick start | molar_run_scenarios, molar_get_guard_status |
| Clones | Clones quick start | molar_clone_spawn, molar_clone_seed |
| Trace | Trace quick start | molar_replay_trace, molar_debug_run |