This tool extracts Protobuf definitions from the Cursor application.
Some of this projects code is based on the work from everestmz/cursor-rpc, but that repository's extractor doesn't work with the latest versions of Cursor. You can use the extracted proto file with the client found in the linked repository.
Just download proto from cursor/aiserver/v1
Before you begin, ensure you have the following installed:
- Go: Required to run the main extraction script.
- npm: Used to install necessary packages for preprocessing.
The script will automatically install the required npm
packages upon execution.
To run the extractor, simply execute the following command in your terminal:
go run main.go
In some cases it may show TypeError, that's okay as long as it generated a populated .proto file.
This extractor is compatible with the following versions of Cursor:
- Latest stable release (v1.2.4)
- Nightly builds
The extracted Protobuf files will be generated and placed inside the cursor/
directory within the project folder.