Scopes missing in /docs at each endpoint padlock
See original GitHub issueDescribe the bug Scopes are missing if we select padlock symbol next to each api endpoint while trying to authorize. they do appear when we select authorize button at the top.
To Reproduce use below azure scheme
azure_scheme = SingleTenantAzureAuthorizationCodeBearer(
app_client_id=settings.APP_CLIENT_ID,
tenant_id=settings.TENANT_ID,
scopes={
f'api://{settings.APP_CLIENT_ID}/user_impersonation': 'user_impersonation',
}
)
use this scheme as a dependency to your endpoint
app.include_router(api_router, prefix=settings.API_V1_STR, dependencies=[Security(azure_scheme, scopes=['user_impersonation'])])
go to /docs
you can see scopes when you click authorize button
if you click on padlock below scopes are missing
and unable to authorize as I am getting below error…
Issue Analytics
- State:
- Created 10 months ago
- Comments:5 (4 by maintainers)
Top Results From Across the Web
Show required OAuth scopes on each endpoint #5062 - GitHub
The API I am documenting has a lot of scopes available. However, a single endpoint usually only requires one scope. Currently a padlock...
Read more >Working with OAuth2 scopes | Apigee X - Google Cloud
If Apigee is not configured to check for scope (the <Scope> element is missing from the VerifyAccessToken policy or it is empty), then...
Read more >Scopes - Auth0
When an app requests permission to access a resource through an authorization server , it uses the scope parameter to specify what access...
Read more >Using OAuth 2.0 to Access Google APIs | Authorization
Refer to the documentation for each Google API for the scopes required for ... The Google OAuth 2.0 endpoint supports web server applications...
Read more >OAuth API verification FAQs - Google Cloud Platform Console ...
All apps that access Google APIs must verify that they accurately represent ... For a complete list of Google APIs, see OAuth 2.0...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
@Pkumar-1988 , we have to wait for FastAPI maintainers (tiangolo specifically) to respond first. If they accept and merge, I’ll have to edit how we handle scopes in this package, since Azure don’t accept and respond with the same kind of scopes (unfortunately).
In other words: I have no idea, it is in FastAPIs hands now. 😊
wow… that was too quick… thank you for the PR… do you know when it will be pushed to artifactory