From ae8f4fc6796660b77ec584731236e6582c62abea Mon Sep 17 00:00:00 2001 From: Daniel Mikusa Date: Fri, 19 Sep 2025 13:36:15 -0400 Subject: [PATCH] Honor client supplied scopes during registration (#1860) Co-authored-by: Jeremiah Lowin <153965+jlowin@users.noreply.github.com> --- src/fastmcp/server/auth/oauth_proxy.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/fastmcp/server/auth/oauth_proxy.py b/src/fastmcp/server/auth/oauth_proxy.py index 6b64bda49..f7e7e92da 100644 --- a/src/fastmcp/server/auth/oauth_proxy.py +++ b/src/fastmcp/server/auth/oauth_proxy.py @@ -407,7 +407,7 @@ class OAuthProxy(OAuthProvider): redirect_uris=client_info.redirect_uris or [AnyUrl("http://localhost")], grant_types=client_info.grant_types or ["authorization_code", "refresh_token"], - scope=self._default_scope_str, + scope=client_info.scope or self._default_scope_str, token_endpoint_auth_method="none", allowed_redirect_uri_patterns=self._allowed_client_redirect_uris, )