Skip to content

Remote MCP Server Support for Dynamic or On-Demand OAuth Token Grant #251452

Open
@Zane-XY

Description

@Zane-XY

With the release of VS Code 1.101, OAuth support was introduced for the remote MCP server. Currently, when starting the MCP server, the VS Code redirects to the OAuth grant application access page. After granting access, the token is stored and used for all subsequent tool calls.

However, in my use case, different tools may require different OAuth scopes, or some tools may call APIs with dynamic scope requirements. This means I often do not know the required scopes when initially creating the OAuth token, as the needed scopes may only become apparent at runtime.

Feature Request:
Is there a way to support dynamic or on-demand OAuth token grants, allowing the application to request additional scopes as needed during operation, rather than only at startup? This would greatly improve flexibility for tools with varying or unpredictable scope requirements.

Metadata

Metadata

Labels

info-neededIssue requires more information from poster

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions