@tsed/platform-mcp 8.43.2 → 8.43.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -58,7 +58,11 @@ export class PlatformMcpAuthService {
|
|
|
58
58
|
return await verifyBearerToken($ctx.request.headers.authorization, options);
|
|
59
59
|
}
|
|
60
60
|
catch (error) {
|
|
61
|
-
return bearerAuthChallengeResponse(error,
|
|
61
|
+
return bearerAuthChallengeResponse(error, {
|
|
62
|
+
...options,
|
|
63
|
+
// tell the client which scopes to request: the required ones, or the supported ones when none is enforced
|
|
64
|
+
requiredScopes: auth.requiredScopes?.length ? auth.requiredScopes : auth.scopesSupported
|
|
65
|
+
});
|
|
62
66
|
}
|
|
63
67
|
}
|
|
64
68
|
/**
|