fastapi-cloudauth
fastapi-cloudauth supports simple integration between FastAPI and cloud authentication services (AWS Cognito, Auth0, Firebase Authentication).
What it is and what it does
fastapi-cloudauth is a FastAPI integration library that standardizes JWT token verification and user claim extraction for three major cloud authentication providers: AWS Cognito, Auth0, and Firebase Authentication. It wraps the token validation logic (signature verification, expiration checks, audience claims) and provides FastAPI dependency injection helpers to protect endpoints with scope-based authorization and to inject authenticated user information into route handlers.
The package depends on fastapi, python-jose (for JWT handling), and requests (for fetching public keys). It supports extracting both access tokens (for scope-based authorization) and ID tokens (for full user profile data), and allows custom Pydantic models to extend the default claims. However, the package has been abandoned since January 2022 with no maintenance activity, meaning it will not receive updates for breaking changes in FastAPI, security patches, or new authentication standards.
Use it for:
- Protect FastAPI endpoints with AWS Cognito access tokens and scope-based authorization.
- Integrate Auth0 authentication into FastAPI applications with custom claim extraction via Pydantic models.
- Verify Firebase ID tokens in FastAPI routes and extract user identity information.
- Implement scope-based access control (all-scopes or any-scope matching) across multiple cloud providers.
- Extract and validate user profile data (email, username, custom fields) from JWT claims in dependency injection.
Worth the install?
AI-flagged interpretation of the facts on this page — verify before relying
Integrates FastAPI applications with cloud authentication services (AWS Cognito, Auth0, Firebase Authentication) to verify JWT tokens, validate scopes, and extract user claims.
No. While the package is low-friction to install and permissively licensed, it is abandoned (last release January 2022, no commits since May 2023). FastAPI, python-jose, and authentication standards have evolved; the package will not receive security patches or compatibility fixes. For new projects, use actively maintained alternatives or implement token verification directly with current versions of FastAPI and python-jose.
Install
fastapi-cloudauth on PyPI
pip
pip install fastapi-cloudauthuv
uv add fastapi-cloudauthpoetry
poetry add fastapi-cloudauthInstalling fastapi-cloudauth
Before you install
Low install friction with three straightforward runtime dependencies. However, the package is abandoned—last release was 2022-01-06, over 1681 days ago, with no recent commits. Security patches and compatibility updates for FastAPI or authentication standards will not be forthcoming.
License in practice
MIT license is permissive; you may use, modify, and distribute this package freely in commercial or private projects without restriction.
Quickstart
pip install fastapi-cloudauth
from fastapi import FastAPI, Depends
from fastapi_cloudauth.cognito import Cognito
app = FastAPI()
auth = Cognito(region="us-east-1", userPoolId="pool-id", client_id="client-id")
@app.get("/", dependencies=[Depends(auth.scope(["read:users"]))])
def secure():
return "Hello"
Requires environment variables (REGION, USERPOOLID, APPCLIENTID for Cognito; DOMAIN, CUSTOMAPI for Auth0; PROJECT_ID for Firebase) and valid tokens from the respective cloud authentication service.
Verify before relying
- Whether the package remains compatible with current versions of FastAPI, python-jose, and requests given its abandoned status.
- Whether dependency versions are pinned or if breaking changes in FastAPI's dependency injection have affected the package since 2022.
Package facts
| License | MIT (permissive) |
| Python support | supports the current Python release (>=3.6.2,<4.0) |
| Install friction | low — pure-Python wheel |
| Runtime dependencies | 3 — fastapi, python-jose, requests |
| Maintenance | abandoned — 1,681 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 125,504/month — #11,811 on PyPI (30-day window, as of 2026-08-14) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-14) |
Evidence: fastapi_cloudauth-0.4.3-py3-none-any.whl
Keywords: FastAPI, authentication, Auth0, AWS Cognito, Firebase Authentication
Tags
More Security packages
Provides Python bindings to the FreeDesktop.org…
permissive · top 1,000 on PyPI
msalMSAL for Python handles OAuth2 and OpenID…
permissive · top 1,000 on PyPI
joserfcjoserfc implements JOSE standards (JWS, JWE,…
permissive · top 1,000 on PyPI
AuthlibAuthlib provides a complete implementation of…
permissive · top 1,000 on PyPI
argon2-cffi-bindingsProvides low-level CFFI bindings to the…
permissive · top 1,000 on PyPI
adalADAL for Python authenticates applications with…
permissive · top 1,000 on PyPI
axioms-fastapiAdds OAuth2/OIDC JWT token validation and…
permissive · top 15,000 on PyPI
fastapi-auth0Integrates Auth0 authentication into FastAPI…
permissive · top 15,000 on PyPI
fastapi-cognitoDecodes, validates, and parses AWS Cognito JWT…
permissive · top 15,000 on PyPI
propelauth-fastapiIntegrates PropelAuth's authentication and…
permissive · top 15,000 on PyPI
fastapi-loginAdds session and token-based user…
permissive · top 15,000 on PyPI
Flask-CognitoFlask-Cognito integrates AWS Cognito JWT…
permissive · top 15,000 on PyPI
firebase-adminFirebase Admin Python SDK provides server-side…
permissive · top 1,000 on PyPI
auth0-api-pythonVerifies Auth0-issued access tokens and secures…
permissive · top 15,000 on PyPI
cognitojwtDecodes and verifies Amazon Cognito JWT tokens…
permissive · top 15,000 on PyPI
firebase-functionsFirebase Functions Python SDK lets you write…
permissive · top 15,000 on PyPI