Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
115 changes: 85 additions & 30 deletions docs/logto-cloud/logto-mcp-server.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -21,48 +21,103 @@ More capabilities are coming soon, including sign-in experience configuration, R

## Set up in your AI application

### VS Code
### Claude Desktop

1. Open the command palette (`Command + Shift + P`), and select **MCP: Add Server...**.
2. Choose **HTTP** as the server type.
3. Enter the URL: `https://mcp.logto.io`. You can choose to install it to your workspace for better isolation and management.
4. When the OAuth flow starts, enter the App ID: `mcp-client`. Leave the App Secret empty and press Enter to skip.
5. You will be redirected to the Logto Cloud sign-in page. Sign in with your Logto Cloud account to connect.
1. Open **Settings** from the main menu, navigate to **Connectors**, and click **Add custom connector**.
2. Enter the name `Logto MCP Server` and the remote MCP server URL: `https://mcp.logto.io`.
3. Expand **Advanced settings** and enter the OAuth Client ID: `mcp-client`. Click **Add**.
4. In the **Connectors** list, find **Logto MCP Server** and click **Connect**.
5. You will be redirected to the Logto Cloud sign-in page. Sign in and authorize to connect.

### Cursor

1. Open the command palette (`Command + Shift + P`), and select **View: Open MCP Settings**.
2. In the **Installed MCP Servers** section, click the **Add Custom MCP** button.
3. In the `mcp.json` file that opens, add the following configuration:

```json
{
"mcpServers": {
"logto": {
"command": "npx",
"args": [
"mcp-remote",
"https://mcp.logto.io",
"--allow-http",
"--static-oauth-client-info",
"{ \"client_id\": \"mcp-client\", \"scope\": \"mcp:all\" }",
"--resource",
"https://mcp.logto.io/"
]
}
}
}
```
```json
{
"mcpServers": {
"Logto": {
"command": "npx",
"args": [
"mcp-remote",
"https://mcp.logto.io",
"--allow-http",
"--static-oauth-client-info",
"{ \"client_id\": \"mcp-client\", \"scope\": \"mcp:all\" }",
"--resource",
"https://mcp.logto.io/"
]
}
}
}
```

A Logto Cloud sign-in page will appear automatically. Sign in with your Logto Cloud account to connect.

### Claude Desktop
### OpenCode

1. Add the following configuration to your `opencode.json` file:

```json
{
"$schema": "https://opencode.ai/config.json",
"mcp": {
"Logto": {
"enabled": true,
"type": "remote",
"url": "https://mcp.logto.io",
"oauth": {
"clientId": "mcp-client"
}
}
}
}
```

2. Run the following command to authenticate:
```bash
opencode mcp auth Logto
```
Note that `Logto` corresponds to the MCP server name in your configuration file.

A browser window will open. Sign in with your Logto Cloud account to authorize and connect.

1. Open **Settings** from the main menu, navigate to **Connectors**, and click **Add custom connector**.
2. Enter the name `Logto MCP Server` and the remote MCP server URL: `https://mcp.logto.io`.
3. Expand **Advanced settings** and enter the OAuth Client ID: `mcp-client`. Click **Add**.
4. In the **Connectors** list, find **Logto MCP Server** and click **Connect**.
5. You will be redirected to the Logto Cloud sign-in page. Sign in and authorize to connect.
### VS Code

1. Open the command palette (`Command + Shift + P`), and select **MCP: Add Server...**.
2. Choose **HTTP** as the server type.
3. Enter the URL: `https://mcp.logto.io`. You can choose to install it to your workspace for better isolation and management.
4. When the OAuth flow starts, enter the App ID: `mcp-client`. Leave the App Secret empty and press Enter to skip.
5. You will be redirected to the Logto Cloud sign-in page. Sign in with your Logto Cloud account to connect.

### Windsurf

1. Open the command palette (`Command + Shift + P`) and select **Windsurf: MCP Marketplace**.
2. In the **Installed MCPs** section, click the settings icon on the right to create and open the `~/.codeium/windsurf/mcp_config.json` file.
3. Add the following [configuration](https://docs.windsurf.com/windsurf/cascade/mcp#mcp_config-json):

```json
{
"mcpServers": {
"Logto": {
"command": "npx",
"args": [
"mcp-remote",
"https://mcp.logto.io",
"--allow-http",
"--static-oauth-client-info",
"{ \"client_id\": \"mcp-client\", \"scope\": \"mcp:all\" }",
"--resource",
"https://mcp.logto.io/"
]
}
}
}
```

A Logto Cloud sign-in page will appear automatically. Sign in with your Logto Cloud account to connect.

### Other MCP clients

Expand Down
Loading