from fastapi.security import OAuth2PasswordBearer oauth2 = OAuth2PasswordBearer( tokenUrl="token", scopes={ "account": "Read information about the current user.", "scm": "Scm Modules", }, )