From 842a21052b62f4075d4c63c452a6db9cd2bbec7d Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Mon, 18 May 2026 23:35:02 +0000 Subject: [PATCH 1/2] Initial plan From dfe6072f065e90d0c56973c99405e69bd12e64c5 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Mon, 18 May 2026 23:40:08 +0000 Subject: [PATCH 2/2] Document OAuth support for HTTP MCP servers --- docs/copilot/reference/mcp-configuration.md | 31 +++++++++++++++++++++ 1 file changed, 31 insertions(+) diff --git a/docs/copilot/reference/mcp-configuration.md b/docs/copilot/reference/mcp-configuration.md index f41767550a..19e0293eec 100644 --- a/docs/copilot/reference/mcp-configuration.md +++ b/docs/copilot/reference/mcp-configuration.md @@ -129,9 +129,19 @@ Use this configuration for servers that communicate over HTTP. VS Code first tri | `type` | Yes | Server connection type | `"http"`, `"sse"` | | `url` | Yes | URL of the server | `"http://localhost:3000"`, `"https://api.example.com/mcp"` | | `headers` | No | HTTP headers for authentication or configuration | `{"Authorization": "Bearer ${input:api-token}"}` | +| `oauth` | No | OAuth configuration for authenticating with the server | `{"clientId": "12348411142.11062036567072"}` | In addition to servers available over the network, VS Code can connect to MCP servers listening for HTTP traffic on Unix sockets or Windows named pipes by specifying the socket or pipe path in the form `unix:///path/to/server.sock` or `pipe:///pipe/named-pipe` on Windows. You can specify subpaths by using a URL fragment, such as `unix:///tmp/server.sock#/mcp/subpath`. +The `oauth` object supports the following property: + +| Property | Type | Required | Description | +|----------|------|----------|-------------| +| `clientId` | string | Yes | The OAuth client ID to use when authenticating with the server. | + +> [!NOTE] +> When `oauth` is configured, VS Code handles the OAuth flow automatically. A browser window opens for authorization on the first connection to the server. +
Example remote server configuration @@ -150,6 +160,27 @@ This example shows the minimal configuration for a remote MCP server without aut
+
+Example HTTP server with OAuth + +This example shows the configuration for an MCP server that uses OAuth for authentication. On first use, VS Code opens a browser window to complete the OAuth flow. + +```json +{ + "servers": { + "slack": { + "type": "http", + "url": "https://mcp.slack.com/mcp", + "oauth": { + "clientId": "12348411142.11062036567072" + } + } + } +} +``` + +
+ ### Input variables for sensitive data Input variables let you define placeholders for configuration values, avoiding the need to hardcode sensitive information like API keys or passwords directly in the server configuration.