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

# Connect your AI client to a gateway

> A 5-minute walkthrough for end users: paste your MCP Manager gateway URL into Claude, Claude Code, Cursor, or VS Code, authorize in the browser, pick your gateway, and start using its tools.

This walkthrough connects an AI client to a **MCP Manager** gateway: add the gateway URL to the client, authorize once in the browser, and the gateway's tools are ready.

<Info>
  For many AI clients — Claude or ChatGPT on a team or enterprise plan — adding an MCP server is a privileged action that not every member can perform. In those setups an administrator connects the gateway once so it's available to the whole team. This walkthrough is that connection, whether you're doing it for yourself or on behalf of others. Connecting requires the **Authenticate via OAuth** capability, and you'll only ever reach the gateways your team membership grants. See the [Connection Experience](/features/connection-experience) for what the gateway does on the other side.
</Info>

## What you'll need

* A gateway URL. Open the gateway on the [Gateways](https://app.mcpmanager.ai/settings/gateways) page and copy its URL from the overview — it includes the gateway ID in the path, which pins the connection to that specific gateway.
* An MCP-capable client: Claude Code, Cursor, VS Code, or Claude.ai.
* An MCP Manager account (you'll sign in during the flow).

## Step 1: Add the gateway URL to your client

Pick your client and add the gateway as an MCP server. Replace `<your-gateway-id>` with the value from the URL you copied — the placeholder is intentionally not a valid URL, so a forgotten substitution fails loudly instead of connecting to the wrong place.

<Tabs>
  <Tab title="Claude Code">
    Run one command:

    ```bash terminal theme={null}
    claude mcp add --transport http mcp-manager "https://app.mcpmanager.ai/gateway/v1/mcp/<your-gateway-id>"
    ```
  </Tab>

  <Tab title="Cursor">
    Add the server to your `mcp.json`:

    ```json mcp.json theme={null}
    {
      "mcpServers": {
        "mcp-manager": {
          "url": "https://app.mcpmanager.ai/gateway/v1/mcp/<your-gateway-id>"
        }
      }
    }
    ```
  </Tab>

  <Tab title="VS Code">
    Create `.vscode/mcp.json`:

    ```json .vscode/mcp.json theme={null}
    {
      "servers": {
        "mcp-manager": {
          "type": "http",
          "url": "https://app.mcpmanager.ai/gateway/v1/mcp/<your-gateway-id>"
        }
      }
    }
    ```
  </Tab>

  <Tab title="Claude.ai">
    In **Customize → Connectors**, choose **Add custom connector**, then enter a name and your gateway URL (`https://app.mcpmanager.ai/gateway/v1/mcp/<your-gateway-id>`).
  </Tab>
</Tabs>

<Note>
  A gateway URL you saved earlier in the `?gateway=<your-gateway-id>` query form still works — there's nothing to change. The path form above is preferred because some clients (Claude Code among them) compare connectors by URL with the query string stripped, which can collapse multiple gateways into one; the path form keeps each gateway distinct.
</Note>

## Step 2: Authorize in the browser

The first time your client connects, it opens MCP Manager in a browser to authorize.

```mermaid theme={null}
%%{init: {'theme':'base','themeVariables':{'fontFamily':'Lato, sans-serif','lineColor':'#6a6b76','primaryColor':'#e0e2e8','primaryTextColor':'#12141d','primaryBorderColor':'#6a6b76','edgeLabelBackground':'#ffffff','textColor':'#12141d'}}}%%
flowchart TD
  S["🔑<br/>Sign in<br/>(one-time code or your identity provider)"] --> I{"Any server needs<br/>your identity?"}
  I -->|"Yes"| W["🔑<br/>Authorize each one in turn:<br/>OAuth approval, or paste a token"]
  I -->|"No"| A["Allow"]
  W --> A
  A --> C["✅<br/>Connected — tools ready"]
  classDef trust fill:#2fedb4,color:#062b4c,stroke:#059669,stroke-width:1.5px;
  class S,W,C trust;
```

<Steps>
  <Step title="Sign in">
    MCP Manager either sends a one-time code to your work email, or — if your domain is set up with an identity provider — sends you to that provider to log in and back. Enter the code or complete the provider's login.
  </Step>

  <Step title="Bring an identity for any server that needs one">
    MCP Manager checks whether any server in the gateway needs you to authenticate with the downstream service, and walks you through them one at a time. For each, you can reuse an identity you've already added t MCP Manager or set up a new one:

    * If the server supports OAuth, it's a quick web-based approval — for example, clicking **Approve** on the provider's page.
    * If the server uses header-based auth, such as a GitHub personal access token, MCP Manager prompts you to paste the header values.

    Servers configured with a shared identity need nothing from you.
  </Step>

  <Step title="Allow">
    Review what the gateway includes and click **Allow**. (When servers need your identity, the button reads **Next** and steps you through them first.) Your client lands back connected.
  </Step>
</Steps>

## Step 3: Use the tools

Return to your client and ask it to do something the gateway's tools cover — for example, search a connected knowledge base or list your assigned issues. The tools appear automatically; there's nothing else to configure.

<Check>
  Your client is connected through a governed gateway, and every call you make is logged. When your administrator adds or removes tools, they show up or disappear on your next session restart. If they unassign a server from the gateway, its tools stop working right away. And if they add a new server that requires authentication, you won't be able to use its tools until you disconnect and reconnect — reconnecting runs the authorize flow above and adds a step to provide that server's identity.
</Check>

## Further reading

<CardGroup cols={2}>
  <Card title="Build a team gateway" icon="users" href="/tutorials/team-gateway">
    The administrator side: how the gateway you just connected to is built and scoped.
  </Card>

  <Card title="Connection Experience" icon="plug-circle-check" href="/features/connection-experience">
    What MCP Manager does during the authorize flow, and why there's no half-connected state.
  </Card>

  <Card title="Gateway Deployment Strategies" icon="sitemap" href="/deployment/gateway-deployment-strategies">
    How administrators distribute gateway URLs across an organization.
  </Card>

  <Card title="Run a headless agent" icon="robot" href="/tutorials/headless-agent">
    Connect from a script or CI job with a token instead of a browser.
  </Card>
</CardGroup>
