Global options

Global options can be used with any command:
OptionDescription
-v, --versionOutput the version number
-a, --api-key <key>API key for authentication (can also use CURSOR_API_KEY env var)
-p, --printPrint responses to console (for scripts or non-interactive use). Has access to all tools, including write and bash.
--output-format <format>Output format (only works with --print): text, json, or stream-json (default: stream-json)
-b, --backgroundStart in background mode (open composer picker on launch)
--fullscreenEnable fullscreen mode
--resume [chatId]Resume a chat session
-m, --model <model>Model to use
-f, --forceForce allow commands unless explicitly denied
-h, --helpDisplay help for command

Commands

CommandDescriptionUsage
loginAuthenticate with Cursorcursor-agent login
logoutSign out and clear stored authenticationcursor-agent logout
statusCheck authentication statuscursor-agent status
mcpManage MCP serverscursor-agent mcp
update|upgradeUpdate Cursor Agent to the latest versioncursor-agent update or cursor-agent upgrade
lsResume a chat sessioncursor-agent ls
resumeResume the latest chat sessioncursor-agent resume
help [command]Display help for commandcursor-agent help [command]
When no command is specified, Cursor Agent starts in interactive chat mode by default.

MCP

Manage MCP servers configured for Cursor Agent.
SubcommandDescriptionUsage
login <identifier>Authenticate with an MCP server configured in .cursor/mcp.jsoncursor-agent mcp login <identifier>
listList configured MCP servers and their statuscursor-agent mcp list
list-tools <identifier>List available tools and their argument names for a specific MCPcursor-agent mcp list-tools <identifier>
All MCP commands support -h, --help for command-specific help.

Arguments

When starting in chat mode (default behavior), you can provide an initial prompt: Arguments:
  • prompt — Initial prompt for the agent

Getting help

All commands support the global -h, --help option to display command-specific help.