|
| 1 | +#### Remote MCP server with dynamic client registration |
| 2 | + |
| 3 | +Dynamic client registration is the preferred approach for any MCP server that |
| 4 | +supports it, as ToolHive handles all authentication setup automatically with |
| 5 | +minimal configuration required. Notion's remote MCP server is one example that |
| 6 | +supports this feature: |
| 7 | + |
| 8 | +1. Configuration settings: |
| 9 | + - **Server name**: `notion-remote` |
| 10 | + - **Server URL**: `https://mcp.notion.com/mcp` |
| 11 | + - **Transport**: Streamable HTTP |
| 12 | + - **Authorization method**: Dynamic Client Registration |
| 13 | + - **Callback port**: `45673` (or any available port on your system) |
| 14 | +1. When you install the server, ToolHive discovers the OAuth endpoints, |
| 15 | + registers a new client, and handles the authentication process. |
| 16 | +1. Your browser opens for authentication. After you authorize access, the remote |
| 17 | + MCP server appears in your server list with a "Running" status. |
| 18 | + |
| 19 | +#### Remote MCP server with OAuth2 authentication |
| 20 | + |
| 21 | +GitHub's remote MCP server requires manual OAuth configuration. You'll need to |
| 22 | +create a GitHub OAuth app and provide the details in ToolHive. |
| 23 | + |
| 24 | +First, create a GitHub OAuth app: |
| 25 | + |
| 26 | +1. Go to [GitHub Developer Settings](https://github.com/settings/developers) |
| 27 | +1. Click **New OAuth App** |
| 28 | +1. Fill in the application details: |
| 29 | + - **Application name**: Choose a descriptive name (e.g., "ToolHive GitHub |
| 30 | + MCP") |
| 31 | + - **Homepage URL**: Your application's homepage or `http://localhost` |
| 32 | + - **Authorization callback URL**: `http://localhost:45673/callback` (the port |
| 33 | + number must match the **Callback port** you will enter in ToolHive) |
| 34 | +1. Click **Register application** |
| 35 | +1. Copy the **Client ID** and generate a **Client secret** for use in ToolHive |
| 36 | + |
| 37 | +Configure the remote MCP server in ToolHive: |
| 38 | + |
| 39 | +1. Configuration settings: |
| 40 | + - **Server name**: `github-remote` |
| 41 | + - **Server URL**: `https://api.githubcopilot.com/mcp/` |
| 42 | + - **Transport**: Streamable HTTP |
| 43 | + - **Authorization method**: OAuth 2.0 |
| 44 | + - **Callback port**: `45673` (or any available port on your system) |
| 45 | + - **Authorize URL**: `https://github.com/login/oauth/authorize` |
| 46 | + - **Token URL**: `https://github.com/login/oauth/access_token` |
| 47 | + - **Client ID**: Your GitHub OAuth app client ID (e.g., |
| 48 | + `Og44jirLIaUgSiTDNGA3`) |
| 49 | + - **Client secret**: Your GitHub OAuth app client secret |
| 50 | + - **Scopes**: `repo,user:email` (comma-separated list of required |
| 51 | + permissions) |
| 52 | + - **PKCE**: Enable this option for enhanced security without requiring a |
| 53 | + client secret |
| 54 | +1. When you install the server, ToolHive opens your browser to authenticate with |
| 55 | + GitHub and authorize the application. |
| 56 | +1. After you authenticate successfully, the remote MCP server appears in your |
| 57 | + server list with a "Running" status. |
| 58 | + |
| 59 | +#### Remote MCP server with OIDC authentication |
| 60 | + |
| 61 | +GitHub's remote MCP server also supports OIDC authentication, which provides |
| 62 | +additional security features and standardized token handling. Use the same |
| 63 | +GitHub OAuth app from the previous example. |
| 64 | + |
| 65 | +1. Fill in the configuration form: |
| 66 | + - **Server name**: `github-remote` |
| 67 | + - **Server URL**: `https://api.githubcopilot.com/mcp/` |
| 68 | + - **Transport**: Streamable HTTP |
| 69 | + - **Authorization method**: OIDC |
| 70 | + - **Callback port**: `45673` (or any available port on your system) |
| 71 | + - **Issuer URL**: `https://github.com/login/oauth` |
| 72 | + - **Client ID**: Your GitHub OAuth app client ID (e.g., |
| 73 | + `Og44jirLIaUgSiTDNGA3`) |
| 74 | + - **Client secret**: Your GitHub OAuth app client secret (optional for PKCE) |
| 75 | + - **PKCE**: Enable this option for enhanced security without requiring a |
| 76 | + client secret |
| 77 | +1. When you install the server, ToolHive opens your browser to authenticate with |
| 78 | + GitHub using OIDC. |
| 79 | +1. After you authenticate successfully, the remote MCP server appears in your |
| 80 | + server list with a "Running" status. |
0 commit comments