cursor-mcp

v1.2.3
io.github.qmediat/cursor-mcp Checked 1 hour ago Published 16 days ago

Cursor's agent (cursor-agent CLI) through MCP: any model your plan offers, resumable sessions.

These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.

cursor_agent

Execute a prompt using Cursor's AI agent with any model id the installed cursor-agent accepts (Composer, Claude, GPT, Gemini, Grok families on your plan; run cursor_models for ids). Modes: 'agent' (tools, terminal, search), 'plan' (design-focused), 'ask' (read-only). In headless mode cursor-agent only PROPOSES file changes unless the server operator set CURSOR_ALLOW_YOLO=true (then --force applies them; CURSOR_SANDBOX=enabled confines them). The result lists the files changed and the model used; a client that sends a progress token gets a progress notification per tool call.

ParameterTypeDescription
prompt *stringThe prompt or task for the Cursor agent. Supports natural language instructions for code generation, review, debugging, and more.
modestringAgent mode. 'agent' = full capabilities (file edit, terminal, search). 'plan' = design-focused, asks clarifying questions. 'ask' = read-only exploration. Default: agent.
modelstringAI model id as cursor-agent accepts it, passed through to --model (any id cursor_models lists; e.g. a Composer, Claude, GPT, Gemini or Grok id on your plan). Default: auto (Cursor picks the model). Wa…
timeout_secondsintegerMaximum execution time in seconds (10-3600). Default: 600 (10 minutes).
workspacestringWorking directory for the agent. Affects file search scope and project context. Default: server's current working directory.

cursor_reply

Continue an existing Cursor agent session. Send a follow-up message in the same conversation context. Requires a session_id from a previous cursor_agent call.

ParameterTypeDescription
prompt *stringFollow-up message to send in an existing Cursor agent session.
session_id *stringSession ID from a previous cursor-agent call. Use cursor-sessions to list available sessions.
modelstringOverride the model for this reply (any id cursor_models lists). If omitted, uses the session's original model.
timeout_secondsintegerMaximum execution time in seconds (10-3600). Default: 600 (10 minutes).

cursor_models

List the model ids the installed cursor-agent offers (its `models` command), or a known list when it offers none. Pricing is on cursor.com/docs/models-and-pricing. Use an id with cursor_agent's 'model' parameter.

cursor_sessions

List Cursor agent sessions created during this MCP server instance. Shows session IDs, models, and prompts. Use session IDs with cursor_reply to continue a conversation.

cursor_health

Check Cursor CLI installation, authentication, and server configuration. Run this first to verify everything is set up correctly.