---
url: https://docs.puppetflow.com/guide/mcp/cursor.md
---
# Connect Cursor

Cursor is configured with a fixed bearer header, so it uses a [Manual Access Token](/guide/mcp/connection-modes#manual-access-token). Create the token first, then:

1. Open **Customize > MCPs** in Cursor.
2. Create `~/.cursor/mcp.json` for a personal connection, or `.cursor/mcp.json` for the current project.
3. Add the following server:

```json
{
  "mcpServers": {
    "puppetflow": {
      "url": "https://your-puppetflow.example/api/mcp-server/http",
      "headers": {
        "Authorization": "Bearer ${env:PUPPETFLOW_MCP_TOKEN}"
      }
    }
  }
}
```

4. Replace the URL with the **Manual MCP endpoint** copied from Puppetflow.
5. Define `PUPPETFLOW_MCP_TOKEN` in Cursor's process environment with the generated `mcp_...` token as its value.
6. Restart Cursor, then check that `puppetflow` appears as connected under **Customize > MCPs**.

Project and global configurations are merged. A project entry takes precedence when both configurations use the same server name.

::: warning
Do not replace the environment variable with a raw token in a project-level `.cursor/mcp.json`. This file may be committed to the repository.
:::

If the connection fails, open **Output**, select **MCP Logs**, and check whether the environment variable was loaded.
