cursor-api  by zhx47

Proxy service for OpenAI API-compatible access to Cursor editor's AI

created 8 months ago
261 stars

Top 98.0% on sourcepulse

GitHubView on GitHub
Project Summary

This project provides a proxy service that transforms the AI capabilities of the Cursor editor into an OpenAI-compatible API. It allows users to leverage Cursor's AI features within other applications, targeting developers and researchers who wish to integrate advanced AI functionalities into their existing workflows.

How It Works

The service acts as a middleware, intercepting requests intended for OpenAI and forwarding them to Cursor's backend. It then translates Cursor's responses back into the OpenAI API format. This approach enables seamless integration by adhering to the widely adopted OpenAI API specification, simplifying the process of utilizing Cursor's AI models.

Quick Start & Requirements

  • Install/Run: docker run -d --name cursor-api -e x-cursor-checksum=xxxxxx -p 3000:3000 zhx47/cursor-api:latest
  • Prerequisites: Cursor editor installed and registered, WorkosCursorSessionToken obtained from browser developer tools (F12 -> Application -> Cookies).
  • Setup: Requires obtaining a session token.
  • Docs: cursorToApi (original project)

Highlighted Details

  • Converts Cursor AI to OpenAI-compatible API.
  • Supports Bearer Token authentication using WorkosCursorSessionToken.
  • Offers Docker deployment for production.
  • Based on the cursorToApi project.

Maintenance & Community

  • No specific contributors, sponsorships, or community links are mentioned in the README.

Licensing & Compatibility

  • License: MIT License.
  • Compatibility: Permissive license suitable for commercial use and integration with closed-source applications.

Limitations & Caveats

The project is intended for learning and research purposes and users must adhere to Cursor's terms of service. The WorkosCursorSessionToken must be kept confidential.

Health Check
Last commit

1 month ago

Responsiveness

Inactive

Pull Requests (30d)
0
Issues (30d)
0
Star History
29 stars in the last 90 days

Explore Similar Projects

Feedback? Help us improve.