Cursor Agent
Options and boundaries
Default:
cursor-agent --print --workspace <abs-dir> "<prompt>"
,
mode/model omitted, text output, parent wait 15m. Print alone can write.
"Plan" / "read-only plan" adds
; "ask" / "Q&A" adds
.
Both block. "Use <model>" adds
. "Interactive" / "TUI" omits print.
"Resume <id>" adds
; "continue" adds
; both block.
"Worktree [name]" adds
; record the printed path.
"JSON" / "stream-json" selects that print format. Ambiguity is
.
Workspace trust needs the user's named authorization for this run; a coding
request is not trust. On
, or before
,
apply
references/trust-integrations.md
. Trust recovery adds only an
authorized
, not force/yolo. Force, sandbox disabled, approve-mcps,
and worker desktop/credential controls need their own named waivers.
Auto-review is explicit opt-in, not a trust or permission bypass.
1. Resolve
Fix workspace, prompt, mode, session/worktree, output, and wait.
Check binary and
cursor-agent status --format json
without exposing secrets.
Missing binary → follow
; missing auth →
unless login was requested. Resolve trust before running.
Record
cmd | workspace | mode | session | worktree | trust | waiver | wait | evidence | terminal
.
Done when target, binary, auth, trust, and authorized options are fixed.
2. Run
Build argv and quote the prompt literally. Text/json may be quiet until
exit; silence is not a hang. Wait until exit or the recorded deadline;
kill only this run's PID at that deadline. Nonzero exit: capture stderr,
inspect the tree, report
, not a retry with added force.
For JSON/stream output, follow
.
For resume, continue, or persist, follow
.
For worktrees/parallel runs, follow
.
For a TUI or other command syntax, follow
.
For login, MCP, plugins, workers, or Bedrock, apply the matching branch in
references/trust-integrations.md
. On rejected syntax, use scoped
.
Done when the process exits, an intended live session is recorded, or an
authorization gate/failure is reported.
3. Verify and report
Inspect status and diff; CLI text is unverified. Run the narrowest covering
tests for edited executable code. Plan/ask must leave the tree unchanged.
Check each worktree and any integrated tree. Clean up only sessions and clean
worktrees this run created unless kept; preserve shell integration, MCP,
plugins, and workers. Report command, mode, session/worktree, waivers, wait,
and outcome evidence. Done when each outcome is observed or blocked with evidence.