|
| 1 | +--- |
| 2 | +title: MCP servers |
| 3 | +--- |
| 4 | + |
| 5 | +import Tabs from "@theme/Tabs"; |
| 6 | +import TabItem from "@theme/TabItem"; |
| 7 | + |
| 8 | +# MCP server |
| 9 | + |
| 10 | +Swan provides MCP ([Model Context Protocol](https://modelcontextprotocol.io/)) servers that give AI assistants direct access to Swan's GraphQL API schema and documentation. Use them to generate accurate GraphQL queries and get answers about Swan's API. |
| 11 | + |
| 12 | +:::note |
| 13 | +Swan's MCP servers only support the Streamable HTTP transport protocol. |
| 14 | +::: |
| 15 | + |
| 16 | +## GraphQL schema server |
| 17 | + |
| 18 | +**URL**: `https://mcp.swan.io/graphql/mcp` |
| 19 | + |
| 20 | +This server lets AI assistants explore Swan's GraphQL schema to help you write queries, mutations, and understand type relationships. |
| 21 | + |
| 22 | +### Setup {#graphql-setup} |
| 23 | + |
| 24 | +<Tabs groupId="mcp-config"> |
| 25 | +<TabItem value="cursor" label="Cursor"> |
| 26 | + |
| 27 | +Add to your Cursor MCP configuration file: |
| 28 | +- **macOS/Linux**: `~/.cursor/mcp.json` |
| 29 | +- **Windows**: `%USERPROFILE%\.cursor\mcp.json` |
| 30 | + |
| 31 | +```json |
| 32 | +{ |
| 33 | + "mcpServers": { |
| 34 | + "swan-graphql": { |
| 35 | + "url": "https://mcp.swan.io/graphql/mcp" |
| 36 | + } |
| 37 | + } |
| 38 | +} |
| 39 | +``` |
| 40 | + |
| 41 | +After saving the configuration, enable the server in **Cursor Settings** > **MCP**. |
| 42 | + |
| 43 | +Refer to [Cursor's MCP documentation](https://docs.cursor.com/context/model-context-protocol) for more information. |
| 44 | + |
| 45 | +</TabItem> |
| 46 | +<TabItem value="claude-desktop" label="Claude Desktop"> |
| 47 | + |
| 48 | +Add to your Claude Desktop configuration file: |
| 49 | +- **macOS**: `~/Library/Application Support/Claude/claude_desktop_config.json` |
| 50 | +- **Linux**: `~/.config/Claude/claude_desktop_config.json` |
| 51 | +- **Windows**: `%APPDATA%\Claude\claude_desktop_config.json` |
| 52 | + |
| 53 | +```json |
| 54 | +{ |
| 55 | + "mcpServers": { |
| 56 | + "swan-graphql": { |
| 57 | + "url": "https://mcp.swan.io/graphql/mcp" |
| 58 | + } |
| 59 | + } |
| 60 | +} |
| 61 | +``` |
| 62 | + |
| 63 | +Restart Claude Desktop after saving the configuration. |
| 64 | + |
| 65 | +Refer to [Claude Desktop's MCP guide](https://modelcontextprotocol.io/quickstart/user) for more information. |
| 66 | + |
| 67 | +</TabItem> |
| 68 | +<TabItem value="claude-code" label="Claude Code"> |
| 69 | + |
| 70 | +Run the following command: |
| 71 | + |
| 72 | +```bash |
| 73 | +claude mcp add --transport http swan-graphql https://mcp.swan.io/graphql/mcp |
| 74 | +``` |
| 75 | + |
| 76 | +Refer to [Claude Code's MCP documentation](https://docs.anthropic.com/en/docs/claude-code/mcp) for more information. |
| 77 | + |
| 78 | +</TabItem> |
| 79 | +<TabItem value="other" label="Other clients"> |
| 80 | + |
| 81 | +Use the following settings to configure any MCP-compatible client: |
| 82 | + |
| 83 | +- **URL**: `https://mcp.swan.io/graphql/mcp` |
| 84 | +- **Transport**: Streamable HTTP |
| 85 | + |
| 86 | +Refer to your client's documentation and the [Model Context Protocol specification](https://modelcontextprotocol.io/) for setup instructions. |
| 87 | + |
| 88 | +</TabItem> |
| 89 | +</Tabs> |
| 90 | + |
| 91 | +### Available tools {#graphql-tools} |
| 92 | + |
| 93 | +| Tool | Description | Example prompts | |
| 94 | +|------|-------------|-----------------| |
| 95 | +| `search-graphql-schema` | Searches the schema using keywords to find relevant types, fields, and operations. | • "Find all types related to payments"<br/>• "What fields are available for accounts?"<br/>• "Show me SEPA credit transfer mutations"<br/>• "Search for card-related types" | |
| 96 | +| `introspect-graphql-type` | Gets detailed information about specific GraphQL types, including fields and related types. | • "What is the Account type?"<br/>• "Show me all fields on the Transaction type"<br/>• "How do I create a SEPA credit transfer?"<br/>• "Explain the AccountMembership type and its relationships" | |
| 97 | + |
| 98 | +## Documentation server |
| 99 | + |
| 100 | +**URL**: `https://mcp.swan.io/docs/mcp` |
| 101 | + |
| 102 | +This server lets AI assistants search Swan's documentation to help you find guides, concepts, and integration information. |
| 103 | + |
| 104 | +### Setup {#docs-setup} |
| 105 | + |
| 106 | +<Tabs groupId="mcp-config-docs"> |
| 107 | +<TabItem value="cursor" label="Cursor"> |
| 108 | + |
| 109 | +Add to your Cursor MCP configuration file: |
| 110 | +- **macOS/Linux**: `~/.cursor/mcp.json` |
| 111 | +- **Windows**: `%USERPROFILE%\.cursor\mcp.json` |
| 112 | + |
| 113 | +```json |
| 114 | +{ |
| 115 | + "mcpServers": { |
| 116 | + "swan-docs": { |
| 117 | + "url": "https://mcp.swan.io/docs/mcp" |
| 118 | + } |
| 119 | + } |
| 120 | +} |
| 121 | +``` |
| 122 | + |
| 123 | +After saving the configuration, enable the server in **Cursor Settings** > **MCP**. |
| 124 | + |
| 125 | +Refer to [Cursor's MCP documentation](https://docs.cursor.com/context/model-context-protocol) for more information. |
| 126 | + |
| 127 | +</TabItem> |
| 128 | +<TabItem value="claude-desktop" label="Claude Desktop"> |
| 129 | + |
| 130 | +Add to your Claude Desktop configuration file: |
| 131 | +- **macOS**: `~/Library/Application Support/Claude/claude_desktop_config.json` |
| 132 | +- **Linux**: `~/.config/Claude/claude_desktop_config.json` |
| 133 | +- **Windows**: `%APPDATA%\Claude\claude_desktop_config.json` |
| 134 | + |
| 135 | +```json |
| 136 | +{ |
| 137 | + "mcpServers": { |
| 138 | + "swan-docs": { |
| 139 | + "url": "https://mcp.swan.io/docs/mcp" |
| 140 | + } |
| 141 | + } |
| 142 | +} |
| 143 | +``` |
| 144 | + |
| 145 | +Restart Claude Desktop after saving the configuration. |
| 146 | + |
| 147 | +Refer to [Claude Desktop's MCP guide](https://modelcontextprotocol.io/quickstart/user) for more information. |
| 148 | + |
| 149 | +</TabItem> |
| 150 | +<TabItem value="claude-code" label="Claude Code"> |
| 151 | + |
| 152 | +Run the following command: |
| 153 | + |
| 154 | +```bash |
| 155 | +claude mcp add --transport http swan-docs https://mcp.swan.io/docs/mcp |
| 156 | +``` |
| 157 | + |
| 158 | +Refer to [Claude Code's MCP documentation](https://docs.anthropic.com/en/docs/claude-code/mcp) for more information. |
| 159 | + |
| 160 | +</TabItem> |
| 161 | +<TabItem value="other" label="Other clients"> |
| 162 | + |
| 163 | +Use the following settings to configure any MCP-compatible client: |
| 164 | + |
| 165 | +- **URL**: `https://mcp.swan.io/docs/mcp` |
| 166 | +- **Transport**: Streamable HTTP |
| 167 | + |
| 168 | +Refer to your client's documentation and the [Model Context Protocol specification](https://modelcontextprotocol.io/) for setup instructions. |
| 169 | + |
| 170 | +</TabItem> |
| 171 | +</Tabs> |
| 172 | + |
| 173 | +### Available tools {#docs-tools} |
| 174 | + |
| 175 | +| Tool | Description | Example prompts | |
| 176 | +|------|-------------|-----------------| |
| 177 | +| `search-documentation` | Searches Swan's documentation to find relevant guides and information. | • "How do I onboard a company account holder?"<br/>• "What are the card spending limits?"<br/>• "Explain SEPA Direct Debit mandates"<br/>• "Find information about account memberships" | |
| 178 | + |
| 179 | +## Next steps |
| 180 | + |
| 181 | +- [Learn about Swan's GraphQL API](../graphql.mdx) |
| 182 | +- [Explore the API with API Explorer](./api-explorer.mdx) |
| 183 | +- [Test your integration in Sandbox](./sandbox-users.mdx) |
0 commit comments