Skip to main content

Editors & Clients

Cursor with Verdictan

Give Cursor's agent Verdictan tools, such as searching request history or linting a policy, through the Verdictan MCP endpoint. This adds tools only: Cursor's own model traffic keeps going to Cursor, not through your gateway.

Before you start​

  • An agent with a publication that has a resolved public hostname. See Gateway Setup for IDEs.
  • An active Access Key or Gateway Key for the MCP client. See API Tokens for IDEs.
  • Cursor installed on the developer's machine.

Configure Cursor​

  1. Make the token available to the Cursor process:

    export VERDICTAN_MCP_TOKEN="<client-api-token>"
  2. Add a verdictan entry under mcpServers in .cursor/mcp.json (this project) or ~/.cursor/mcp.json (all projects), next to any servers already there:

    .cursor/mcp.json
    {
      "mcpServers": {
        "verdictan": {
          "url": "https://<published-hostname>/mcp",
          "headers": {
            "Authorization": "Bearer ${env:VERDICTAN_MCP_TOKEN}"
          }
        }
      }
    }

    The file names the variable, not the token, so it is safe to commit.

  3. Start Cursor from an environment that has VERDICTAN_MCP_TOKEN. An app launched from the desktop may not see variables from your shell.

  4. Open Customize in the sidebar and check that verdictan is enabled and lists tools.

See Cursor's MCP documentation for config locations and transports.

Verify​

  1. Check that the verdictan server lists tools such as history_search and policy_lint, in Customize or with the Cursor CLI:

    agent mcp list
    agent mcp list-tools verdictan
  2. Ask the agent:

    Use Verdictan history_search to find my recent test request.
    Do not change any configuration.

    An empty result without an error means the tool ran. An authentication or authorization error means it did not.

This proves MCP access only. verdictan events tail shows model decisions, so Cursor chat requests do not appear there with this setup.

Model-traffic boundary​

MCP does not change the model endpoint for Cursor chat, agent, or Tab. That traffic goes to Cursor's endpoints and does not pass through Verdictan. Don't point Cursor's network proxy setting at the Verdictan model API: it is not an HTTP proxy. Route model traffic only if your Cursor version documents a custom OpenAI-compatible endpoint, and confirm it: send one request, then look for its event with verdictan events tail --since 10m.

Troubleshooting​

SymptomCauseFix
The verdictan server shows an errorThe URL points to 127.0.0.1:41002 or an unpublished hostname. A local listener returns 404 with mcp_publication_required.Use the agent's published hostname.
401 from the serverVERDICTAN_MCP_TOKEN is empty in the Cursor process, or the value is not a vdt_ tokenStart Cursor from a shell that exports it, and check the token in the Console.
Connected, but a tool call failsThe token has no access to the publication, or the policy config limits the toolCheck the token's limits and the mcp section of the policy config.
No Cursor chat events in verdictan events tailCursor chat does not go through the gatewayExpected with this setup.

For endpoint and event problems, see IDE Integration Troubleshooting.

Next steps​