Cursor AI agent

Cursor AI Agent in 10x

Setup

The simplest way to use Cursor with 10x Editor is:

Tools Menu -> Cursor

This assumes the Cursor CLI is installed and in the path. A terminal panel will open with Cursor running.

The first time Cursor is started in 10x it will prompt to install the 10x MCP server. This allows Cursor to communicate with 10x.

The MCP server is installed for the user so will apply to all Cursor instances, even those run outside of 10x.

CursorTerminalCommand Setting

If 10x can't find Cursor change the CursorTerminalCommand to use an absolute path to the Cursor agent exe.

Use this setting to pass in additional arguments to the Cursor exe.

If you run a modified Cursor exe change this setting to point at your exe.

Installing the 10x MCP server manually

The simplest way to install the MCP server is to start open a Cursor terminal with the tools menu. But if you want to install it manually add the following to your mcp.json file


%USERPROFILE%\.cursor\mcp.json

{
  "mcpServers": {
    "10xMCPServer": {
      "command": "cmd",
      "args": [
        "/c",
        "C:/Program Files/PureDevSoftware/10x/MCPServer/10xMCPServer.exe"
      ]
    }
  }
}


Restart any Cursor instances for it to take effect.

This wil install the MCP server at the user level so it will be avilable for all Cursor instances even if run outside of 10x.

Changing the Working Directory

By default terminals open in the workspace root directory. To change this set the "Terminal Directory" setting in the workspace settings.

Functionality

Once the 10x MCP server is installed Cursor will have full access to all 10x commands and python scripting.

Below is a list of some of the MCP tools available.


list_editors List all 10x Editor instances that can be connected to
connect_to Connect to a specific 10x Editor instance
read_current_buffer Read the currently open file
write_to_buffer Replace the currently open file
edit_range Replace a specific range in the currently open file
get_selection Get the currently selected text
get_current_file Get the file path of the currently open file
get_open_files Get a list of all open files
open_file Open a specific file
get_cursor_position Get the current cursor position
set_cursor_position Set the current cursor position
run_last_build Run the last build
debug_project Start the debugger
build_project Build the currently active project
rebuild_project Rebuild the currently active project
get_project_files Get a list of all files in the project
save_current_buffer Save the currently open file
search_in_file Find text in the currently open file
search_in_project Use Workspace Search to search for text in the workspace
find_file_by_name Use Workspace Search to find a file in the workspace by name
get_build_output Get the build output
get_build_results Get the build results (warnings and errors)
get_build_status Return if the build is still running
get_file_diagnostics Get warnings and errors for the current file (without doing a build)
execute_command Execute a 10x command or python statement
list_commands List all 10x commands

For a full list of tool use: /mcp and select 10x Editor, then View Tools

Usage

Below are some recommendations on how to use 10x with Cursor:

  • Add a .cursorrules file to tell Cursor how to best use 10x Editor.
  • In your .cursorrules file tell cursor to use the search_in_project tool instead of grep. This will significantly speed up Cursors ability to find things.
  • Prompt: "What does this file do?"
    Cursor reads the current buffer and gives a high-level summary, useful when jumping into unfamiliar code
  • Prompt: "Describe the current function"
    Cursor will look at the currently open file and the cursor position and analyise the function.
  • Prompt: "Add a documentation comment to the current function"
  • Prompt: "Connect to MyTestApp"
    Cursor will find a 10x instance with MyTestAppp workspace open and connect to that instance
  • Prompt: "Find all usages of MyFunction in the project"
  • Prompt: "What files are open?"
    Cursor uses get_open_files to give an overview of what you're working with
  • Prompt: "Refactor the current function to remove code duplication"
  • Prompt: "Build the project and fix any errors"
    Cursor runs build_project, reads get_build_results, opens the relevant files, and iterates until clean
  • Prompt: "The last build failed, what went wrong?"
    Cursor reads get_build_output and explains the errors
  • Prompt: "Start the debugger"
  • Prompt: "Write a test for the current function"
    Cursor reads the function and generates a test case alongside it
  • Prompt: "Find all TODO comments in the project and list them"