Gazebo
    ServicesAgentsVaultsDocsWritingPricing
    Log inSign up
    Log in
    GazeboWritingConnect Cursor to Gazebo: OAuth and Credential Retrieval

    Connect Cursor to Gazebo: OAuth and Credential Retrieval

    Connect Cursor through OAuth or a manual agent token, verify retrieval permissions, and understand which credentials reach the runtime.

    July 5, 2026·4 min

    Quick answer: Connect Cursor to Gazebo to approve and record access to selected service credentials. OAuth and manual agent-token setup are different paths; successful retrieval returns the actual provider key to Cursor's runtime and potentially its host or model context.

    Decide what access Cursor needs

    Start with the provider credential, not the editor settings. Use a test environment and restricted provider permissions where available. A key stored in .env is not inherently full-account, and moving a broad key to Gazebo does not narrow its permissions.

    Gazebo adds named retrieval identities, central access policies and retrieval history across services. That can be useful when several agents need different credentials. It does not execute Cursor's later Stripe, GitHub or Vercel requests.

    For the maintained setup instructions, use the Cursor MCP guide. The following steps explain the decisions and verification behind that connection.

    Option 1 — Connect with OAuth

    Add a remote MCP server in Cursor using:

    https://app.gazebohq.com/api/mcp
    

    Use Cursor's sign-in flow. In Gazebo, authenticate, explicitly approve only the service keys this connection needs and choose an access deadline. Do not add a manual agent-token header to this OAuth setup.

    The endpoint is shared; it is the authenticated connection and its policies that determine retrieval access. Registering an OAuth client does not itself grant access to keys.

    Cursor Desktop has a tested Gazebo OAuth path. See the client compatibility guide for the recorded environment and evidence limits, rather than assuming every Cursor execution surface behaves identically.

    Option 2 — Use a manual agent token

    Create a named agent at Gazebo Agents, configure its retrieval policies and protect the resulting agent token. An account API token is not an MCP agent token.

    Cursor's documented project configuration is .cursor/mcp.json; global configuration is ~/.cursor/mcp.json. For remote HTTP, a secret-free template can use:

    {
      "mcpServers": {
        "gazebo": {
          "url": "https://app.gazebohq.com/api/mcp",
          "headers": {
            "Authorization": "Bearer ${env:GAZEBO_AGENT_TOKEN}"
          }
        }
      }
    }
    

    Set the variable in the environment inherited by Cursor. A desktop app launched from a launcher may not inherit your terminal's variables. Cursor's envFile option applies to stdio servers, not remote HTTP servers.

    The template can be shared without a resolved secret. The actual token cannot: someone possessing it may retrieve credentials permitted by its policy. See MCP configuration security.

    Verify identity before retrieving anything

    Ask Cursor to call get_identity without fetching a credential. Check the returned identity, allowed services, declared-method policies and, for OAuth, approved key names.

    Next, use a service containing a fictional test value. Substitute that service and key name in this illustrative call:

    get_credential({ service: "your-test-service", key_name: "api_key", method: "GET" })
    

    OAuth requires the approved key_name. Ask Cursor not to display the value, then inspect the matching retrieval event with list_audit_events. Not displaying a value does not mean Cursor's runtime or host never received it.

    Finally, revoke the test grant or agent and confirm a fresh retrieval fails without reconnecting. Revocation does not invalidate a provider key already returned; use provider controls for that.

    Keep project boundaries explicit

    Use names such as cursor-billing-staging and avoid sharing one identity across unrelated work. A profile name is a useful label, not proof of a particular developer, task or session.

    A project-specific configuration is not a sandbox. Global MCP entries, other enabled tools, readable files and inherited credentials may remain available. Telling Cursor “use project A” is not a security boundary; disable unrelated access and use appropriate runtime separation.

    Troubleshoot without assuming the cause

    Connection failure: check the client-specific configuration, endpoint and authentication mode. Distinguish an expired or revoked connection from a tool-level policy denial.

    Retrieval denied: check the service, key name and declared method against the intended policy. Do not widen access merely to make an unexplained request succeed.

    No retrieval event: first establish whether a retrieval was attempted. A connection problem, an identity-only check or no tool invocation can explain an empty log; it is not proof that Cursor found a key elsewhere.

    Unexpected provider activity: compare retrieval events with Cursor/runtime and provider records. Retrieval time alone does not prove who performed a later operation or what data they accessed.

    What this setup does—and does not—change

    Gazebo manages which configured credentials Cursor can retrieve and records retrieval decisions. Its method parameter is release-policy context, not a way to make a write-capable key read-only. Tool-result handling, retention and model exposure depend on Cursor's deployment and settings; a separate display panel is not an isolation guarantee.

    Use narrow provider permissions, trusted tools and appropriate execution controls alongside retrieval policy.


    Last reviewed: 8 November 2026. Independent editorial; not affiliated with or endorsed by Cursor. Configuration references: Cursor's MCP documentation.

    Frequently asked questions

    Why not just put API keys in Cursor's .env file?

    Environment files can be read by authorised tools or processes and may be shared accidentally. Provider keys are not inherently full-account. Gazebo adds central retrieval permissions and history, but successful retrieval still delivers the configured key to Cursor's runtime and potentially its host or model context.

    How do I connect my services to Gazebo before setting up Cursor?

    Configure the service credentials you intend to use in Gazebo, preferably test or provider-restricted keys. Then approve the relevant keys through Cursor's OAuth connection, or configure retrieval policies for a manual agent identity. Moving a key into Gazebo does not narrow its provider permissions.

    How do I create a Cursor-specific access profile?

    For manual authentication, create a named agent in Gazebo and configure its retrieval policies, then protect its agent token. For OAuth, use Cursor's sign-in flow and explicitly approve selected service keys. Both use the shared hosted endpoint; an account API token is not an MCP agent token.

    What do I paste into Cursor's MCP settings?

    Use https://app.gazebohq.com/api/mcp and follow the OAuth flow or a separate manual agent-token setup. Cursor supports project .cursor/mcp.json and global ~/.cursor/mcp.json. Its documented remote header interpolation uses ${env:NAME}; do not commit the resolved token or assume remote envFile support.

    How do I scope access differently across multiple projects?

    Use identities and provider credentials with access appropriate to each project, and review global MCP entries and other available tools. A prompt selecting one profile is not isolation. Disable unrelated access or use suitable runtime separation when a stronger boundary is needed.

    What happens to my Cursor agent's access if I revoke its profile?

    Revoking the profile immediately blocks future credential retrieval with that Gazebo identity. Provider keys already received remain usable within their provider permissions until restricted, revoked or expired there.

    Give your agents the access they need

    Scoped credential retrieval, access logs, and revocable agent access — for your AI tools.

    Get started free

    Agent pages

    Cursor

    Service pages

    StripeVercelCloudflareLinear

    Related reading

    Claude Code API Credentials: Setup and Access BoundariesMCP Config Security: Protect API Keys and Bearer TokensSecret Scanning for AI Codebases: Limits and Gaps
    ← Back to writing
    Gazebo

    Credential management for AI agents. Control credential retrieval, review access logs, and revoke an agent’s future retrieval without rotating shared API keys.

    Gazebo

    • Account
    • Demo
    • Pricing

    Explore

    • Services
    • Agents
    • Vaults

    Developers

    • Docs
    • SDK
    • CLI
    • API
    • MCP

    Content

    • Writing
    • Topics
    • Blog

    Company

    • About
    • Contact
    • hello@gazebohq.com

    © 2026 Gazebo. All rights reserved.

    PrivacyTermsSecurity