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

# MCP Compatible Clients

> Give Claude, Cursor, and your favorite AI tools real crypto wallet capabilities in under 5 minutes.

The Agent Wallet MCP server works with any MCP-compatible client. Pick your tool below and you'll be connected in under five minutes.

**Server details for all clients:**

| Property  | Value                                    |
| --------- | ---------------------------------------- |
| URL       | `https://wallet-mcp.fd.xyz`              |
| Transport | Streamable HTTP                          |
| Auth      | OAuth PKCE (browser-based authorization) |

## Claude Desktop

<Warning>
  Claude Desktop (and Claude.ai web) currently have client-side restrictions that limit Agent Wallet MCP functionality. For the full Agent Wallet experience without restrictions, we recommend [Claude Code](#claude-code), Cursor, or any other MCP-compatible client. The configuration below is documented for completeness, but capabilities may be reduced.
</Warning>

Edit your Claude Desktop config file:

* **macOS:** `~/Library/Application Support/Claude/claude_desktop_config.json`
* **Windows:** `%APPDATA%\Claude\claude_desktop_config.json`

```json theme={"theme":{"light":"github-light","dark":"one-dark-pro"}}
{
  "mcpServers": {
    "finance-district": {
      "type": "streamable-http",
      "url": "https://wallet-mcp.fd.xyz"
    }
  }
}
```

Restart Claude Desktop. On first connection, your browser opens for OAuth authorization. Sign in with your [District Pass](/overview/district-pass) (if you aren't already) and authorize the client to access your Finance District account. Once authorized, the connection persists across sessions.

**Verify:** Ask Claude "What Finance District tools do you have?"

## Cursor

Open Cursor Settings → MCP Servers → Add new server:

```json theme={"theme":{"light":"github-light","dark":"one-dark-pro"}}
{
  "mcpServers": {
    "finance-district": {
      "type": "streamable-http",
      "url": "https://wallet-mcp.fd.xyz"
    }
  }
}
```

Restart Cursor after saving. The browser-based OAuth flow will trigger on first connection.

**Verify:** In Cursor's AI chat, ask "What Finance District wallet tools are available?"

## Windsurf

Open Windsurf Settings → MCP Configuration:

```json theme={"theme":{"light":"github-light","dark":"one-dark-pro"}}
{
  "mcpServers": {
    "finance-district": {
      "type": "streamable-http",
      "url": "https://wallet-mcp.fd.xyz"
    }
  }
}
```

## Claude Code

Claude Code supports MCP servers directly from the command line:

```bash theme={"theme":{"light":"github-light","dark":"one-dark-pro"}}
claude mcp add finance-district --transport http https://wallet-mcp.fd.xyz
```

This only registers the server — it does **not** authenticate. `claude mcp list` will show `finance-district` as `! Needs authentication`. To complete authorization, either:

* Run `/mcp` inside Claude Code, select **finance-district**, and choose **Authenticate**, or
* Ask the agent to use a wallet tool — the browser OAuth flow triggers on first use.

After you authorize, the status flips to `✔ Connected` and Claude Code can use wallet tools in your coding sessions.

## n8n

n8n supports MCP servers as tools for AI Agent nodes:

1. Open your n8n workflow
2. Add or configure an **AI Agent** node
3. In the agent's tool configuration, add an MCP server
4. Set the server URL to `https://wallet-mcp.fd.xyz` with Streamable HTTP transport
5. Configure OAuth authorization — sign in with your District Pass when prompted

The agent node can then use wallet capabilities as tools within your n8n workflows.

## Custom MCP Client

For developers building their own MCP client or integrating into a custom agent framework, you'll need to handle both the OAuth PKCE authentication flow and **client registration** with the Agent Wallet MCP server.

### Client Registration

Before an MCP client can authenticate, it must be registered with the authorization server. The Agent Wallet MCP server supports two registration methods:

<AccordionGroup>
  <Accordion title="CIMD — Client ID Metadata Document (Preferred)">
    CIMD lets your client publish its metadata (name, redirect URIs, grant types) as a JSON document at a publicly accessible URL. The authorization server fetches this document to verify your client's identity during the OAuth flow.

    **How it works:**

    1. You host a JSON metadata document at a URL you control (e.g., `https://your-app.com/.well-known/oauth-client`)
    2. Your client uses that URL as its `client_id` in the OAuth flow
    3. The authorization server fetches the document to validate the client

    This is the **recommended approach** — no registration step is needed on our side, and you maintain full control of your client metadata.

    See the [MCP Authorization specification](https://modelcontextprotocol.io/specification/2025-03-26/basic/authorization) for the full metadata document schema.
  </Accordion>

  <Accordion title="DCR — Dynamic Client Registration">
    DCR ([RFC 7591](https://datatracker.ietf.org/doc/html/rfc7591)) allows clients to register programmatically by posting their metadata to a registration endpoint. The server responds with a `client_id` that the client uses for subsequent OAuth flows.

    DCR on the Agent Wallet MCP server is **restricted to whitelisted clients**. If you need DCR access for your custom client, [reach out to us on Discord](https://discord.gg/fdxyz) to request whitelisting.
  </Accordion>
</AccordionGroup>

<Note>
  Popular MCP clients — Claude Desktop, Cursor, Windsurf, Claude Code, and n8n —
  are already registered and work out of the box. Client registration only
  applies when you're building a custom MCP client or integrating the Agent
  Wallet MCP server into your own agent framework.
</Note>

### Code Example

```typescript theme={"theme":{"light":"github-light","dark":"one-dark-pro"}}
import { Client } from "@modelcontextprotocol/sdk/client/index.js";
import { StreamableHTTPClientTransport } from "@modelcontextprotocol/sdk/client/streamableHttp.js";

const transport = new StreamableHTTPClientTransport(
  new URL("https://wallet-mcp.fd.xyz"),
);

const client = new Client({
  name: "my-agent",
  version: "1.0.0",
});

await client.connect(transport);

// Discover available tools
const { tools } = await client.listTools();
console.log(
  "Available tools:",
  tools.map((t) => t.name),
);

// Call a tool
const result = await client.callTool({
  name: "getWalletOverview",
  arguments: {},
});
```

The MCP SDK's Streamable HTTP transport handles the OAuth PKCE flow natively. See the [MCP SDK documentation](https://modelcontextprotocol.io/docs) for full implementation details.

## Troubleshooting

**Browser window doesn't open for authentication**

* Ensure your MCP client supports OAuth PKCE with Streamable HTTP transport
* Some older MCP client versions may not support remote server authentication — update to the latest version

**Connection drops after a while**

* OAuth tokens refresh automatically. If the refresh fails, restart your client to trigger a new authentication flow

**Tools aren't showing up**

* Verify the server URL is exactly `https://wallet-mcp.fd.xyz`
* Verify the transport type is set to `streamable-http` (not `sse` or `stdio`)
* Restart your MCP client after adding the configuration
