> ## Documentation Index
> Fetch the complete documentation index at: https://docs.raisegate.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Connect a client

> Claude Code, Cursor, Claude Desktop, and custom agents.

Issue keys with `npm run partner-api:key -- --org <slug> --user <member-email> --name <name>` (see [Authentication](/authentication)). The key acts for that member. Use a dedicated key per person and per assistant or agent so usage and revocation are isolated.

<Tabs>
  <Tab title="Claude Code">
    ```bash theme={"theme":{"light":"github-light-default","dark":"vesper"}}
    claude mcp add --transport http raisegate https://app.raisegate.com/api/mcp \
     --header "Authorization: Bearer rg_live_..."
    ```
  </Tab>

  <Tab title="Cursor / Windsurf">
    Clients that accept a URL with headers:

    ```json theme={"theme":{"light":"github-light-default","dark":"vesper"}}
    {
     "mcpServers": {
      "raisegate": {
       "url": "https://app.raisegate.com/api/mcp",
       "headers": { "Authorization": "Bearer rg_live_..." }
      }
     }
    }
    ```
  </Tab>

  <Tab title="Claude Desktop">
    Clients that only launch local servers can reach the remote endpoint through the `mcp-remote` bridge:

    ```json theme={"theme":{"light":"github-light-default","dark":"vesper"}}
    {
     "mcpServers": {
      "raisegate": {
       "command": "npx",
       "args": [
        "-y",
        "mcp-remote",
        "https://app.raisegate.com/api/mcp",
        "--header",
        "Authorization:${RAISEGATE_AUTH}"
       ],
       "env": { "RAISEGATE_AUTH": "Bearer rg_live_..." }
      }
     }
    }
    ```
  </Tab>

  <Tab title="TypeScript SDK">
    ```ts theme={"theme":{"light":"github-light-default","dark":"vesper"}}
    import { Client } from "@modelcontextprotocol/sdk/client/index.js";
    import { StreamableHTTPClientTransport } from "@modelcontextprotocol/sdk/client/streamableHttp.js";

    const client = new Client({ name: "my-agent", version: "1.0.0" });
    await client.connect(
     new StreamableHTTPClientTransport(new URL("https://app.raisegate.com/api/mcp"), {
      requestInit: { headers: { Authorization: `Bearer ${process.env.RAISEGATE_API_KEY}` } },
     }),
    );
    const { tools } = await client.listTools();
    const inbox = await client.callTool({
     name: "list_leads",
     arguments: { decision: "unreviewed" },
    });
    ```
  </Tab>
</Tabs>

<Check>
  A missing, unknown, revoked or expired key is rejected before the MCP handshake with HTTP `401`.
</Check>
