Overview

Cursor is an AI-powered IDE that supports MCP (Model Context Protocol) for enhanced code intelligence and tool integration. Through Portkey’s MCP Gateway, you can seamlessly connect any MCP server to Cursor without managing infrastructure or authentication.

Key Benefits

  • Secure Authentication: Portkey handles OAuth flows and token management.
  • Unified Authentication: Single oauth token to rule them all
  • Team Collaboration: Share MCP server configurations, manage access permissions, and ensure everyone on your team has the tools they need—configured correctly, every time.
  • Complete Observability: See every request, track latency, monitor errors, and understand usage patterns.

Prerequisites

Before you begin, ensure you have:
  1. Cursor IDE installed (version X.X or later)
  2. Portkey account with workspace access
  3. MCP server registered in Portkey’s MCP Hub

Quick Setup

Step 1: Get Your MCP Server URL

  1. Log in to Portkey Dashboard
  2. Navigate to MCP HubYour Servers
  3. Copy your server URL:
    https://mcp.portkey.ai/:workspace-id/:server-id/mcp
    

Step 2: Open Cursor MCP Settings

  1. Open Cursor IDE
  2. Use keyboard shortcut: Cmd/Ctrl + Shift + P
  3. Type and select: View: Open MCP settings
  4. Click “Add a new MCP server”

Step 3: Configure Your Server

Add this configuration to your MCP settings JSON:
{
  "mcpServers": {
    "your-server-name": {
      "url": "https://mcp.portkey.ai/:workspace-id/:server-id/mcp"
    }
  }
}

Step 4: Authentication

Portkey handles all authentication flows automatically:
  1. First Connection: When Cursor first connects to an authenticated MCP server, Portkey will:
    • Open your browser for OAuth authorization (if required)
    • Store credentials securely
    • Maintain session state
  2. Subsequent Connections: Authentication tokens are refreshed automatically
  3. Team Access: Workspace members share the same authentication scope based on your Portkey settings

Configuration Examples

Single Server Setup

{
  "mcpServers": {
    "linear-integration": {
      "url": "https://mcp.portkey.ai/ws-abc123/linear-def456/mcp"
    }
  }
}

Multiple Servers Setup

{
  "mcpServers": {
    "linear": {
      "url": "https://mcp.portkey.ai/ws-abc123/linear-def456/mcp"
    },
    "github": {
      "url": "https://mcp.portkey.ai/ws-abc123/github-ghi789/mcp"
    },
    "slack": {
      "url": "https://mcp.portkey.ai/ws-abc123/slack-jkl012/mcp"
    }
  }
}

Support

Need help? We’re here for you: