{"id":35213484,"url":"https://github.com/sreekarnv/fastauth","last_synced_at":"2026-02-19T03:03:48.073Z","repository":{"id":331007647,"uuid":"1119868437","full_name":"sreekarnv/fastauth","owner":"sreekarnv","description":"Production-ready authentication library for FastAPI with OAuth 2.0,   RBAC, session management, and comprehensive account features.   Includes JWT tokens, email verification, password reset, and   auto-generated documentation.","archived":false,"fork":false,"pushed_at":"2026-01-16T22:48:27.000Z","size":2075,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-01-18T05:12:22.949Z","etag":null,"topics":["fastapi","fastapi-auth","jwt-authentication","oauth2","python","sqlalchemy"],"latest_commit_sha":null,"homepage":"https://sreekarnv.github.io/fastauth/","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/sreekarnv.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2025-12-20T02:14:13.000Z","updated_at":"2026-01-16T22:47:25.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/sreekarnv/fastauth","commit_stats":null,"previous_names":["sreekarnv/fastauth"],"tags_count":5,"template":false,"template_full_name":null,"purl":"pkg:github/sreekarnv/fastauth","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sreekarnv%2Ffastauth","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sreekarnv%2Ffastauth/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sreekarnv%2Ffastauth/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sreekarnv%2Ffastauth/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/sreekarnv","download_url":"https://codeload.github.com/sreekarnv/fastauth/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sreekarnv%2Ffastauth/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28618858,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-20T23:49:58.628Z","status":"ssl_error","status_checked_at":"2026-01-20T23:47:29.996Z","response_time":117,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["fastapi","fastapi-auth","jwt-authentication","oauth2","python","sqlalchemy"],"created_at":"2025-12-29T20:59:48.253Z","updated_at":"2026-02-19T03:03:48.065Z","avatar_url":"https://github.com/sreekarnv.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# FastAuth\n\n[![PyPI](https://img.shields.io/pypi/v/sreekarnv-fastauth)](https://pypi.org/project/sreekarnv-fastauth/)\n[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)\n[![CI](https://github.com/sreekarnv/fastauth/actions/workflows/ci.yml/badge.svg)](https://github.com/sreekarnv/fastauth/actions/workflows/ci.yml)\n[![codecov](https://codecov.io/gh/sreekarnv/fastauth/branch/main/graph/badge.svg)](https://codecov.io/gh/sreekarnv/fastauth)\n[![Python 3.11+](https://img.shields.io/badge/python-3.11%2B-blue)](https://www.python.org/downloads/)\n\n**NextAuth-inspired pluggable authentication for FastAPI.**\n\nFastAuth gives you a complete auth system — credentials, OAuth, email verification, password reset, RBAC, and JWT — without locking you into any particular database or ORM.\n\n---\n\n## Features\n\n- **Multiple providers** — email/password, Google OAuth, GitHub OAuth\n- **Pluggable adapters** — SQLAlchemy (SQLite, PostgreSQL, MySQL) or bring your own\n- **JWT \u0026 database sessions** — stateless tokens or server-side sessions\n- **Cookie delivery** — HttpOnly, Secure, SameSite out of the box\n- **Email flows** — verification and password reset with customizable transports\n- **RBAC** — roles and fine-grained permissions on any route\n- **Event hooks** — intercept sign-in/sign-up and modify JWT payloads\n- **RS256 / JWKS** — rotate keys and expose a JWKS endpoint for microservices\n- **CLI** — scaffold a project, check dependencies, generate secrets\n\n---\n\n## Install\n\n```bash\npip install \"sreekarnv-fastauth[standard]\"\n```\n\n| Extra | Includes |\n|-------|----------|\n| `standard` | FastAPI, JWT (joserfc), SQLAlchemy, Argon2 |\n| `oauth` | httpx (Google, GitHub OAuth) |\n| `email` | aiosmtplib, Jinja2 |\n| `redis` | redis-py async |\n| `postgresql` | asyncpg |\n| `cli` | typer, rich |\n| `all` | everything |\n\n---\n\n## Quick start\n\n```python\nfrom contextlib import asynccontextmanager\nfrom fastapi import Depends, FastAPI\nfrom fastauth import FastAuth, FastAuthConfig\nfrom fastauth.adapters.sqlalchemy import SQLAlchemyAdapter\nfrom fastauth.api.deps import require_auth\nfrom fastauth.providers.credentials import CredentialsProvider\n\nadapter = SQLAlchemyAdapter(engine_url=\"sqlite+aiosqlite:///./auth.db\")\n\nauth = FastAuth(FastAuthConfig(\n    secret=\"change-me\",           # fastauth generate-secret\n    providers=[CredentialsProvider()],\n    adapter=adapter.user,\n    token_adapter=adapter.token,\n))\n\n@asynccontextmanager\nasync def lifespan(app: FastAPI):\n    await adapter.create_tables()\n    yield\n\napp = FastAPI(lifespan=lifespan)\nauth.mount(app)  # registers /auth/signup, /auth/signin, /auth/signout, …\n\n@app.get(\"/dashboard\")\nasync def dashboard(user=Depends(require_auth)):\n    return {\"hello\": user[\"email\"]}\n```\n\n```bash\nuvicorn main:app --reload\n```\n\n---\n\n## Documentation\n\nFull documentation at **[sreekarnv.github.io/fastauth](https://sreekarnv.github.io/fastauth)**\n\n- [Installation](https://sreekarnv.github.io/fastauth/getting-started/installation/)\n- [Quick Start](https://sreekarnv.github.io/fastauth/getting-started/quick-start/)\n- [Configuration](https://sreekarnv.github.io/fastauth/getting-started/configuration/)\n- [How it Works](https://sreekarnv.github.io/fastauth/concepts/how-it-works/)\n- [Guides](https://sreekarnv.github.io/fastauth/guides/basic/)\n- [API Reference](https://sreekarnv.github.io/fastauth/api/fastauth/)\n\n---\n\n## License\n\nMIT License - see [LICENSE](./LICENSE) for details.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsreekarnv%2Ffastauth","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsreekarnv%2Ffastauth","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsreekarnv%2Ffastauth/lists"}