{"id":28374637,"url":"https://github.com/the-y9/fastapi-authentication-starter-pack","last_synced_at":"2026-04-25T23:34:10.668Z","repository":{"id":290311772,"uuid":"960400349","full_name":"the-y9/FastAPI-Authentication-Starter-Pack","owner":"the-y9","description":"FastAPI starter for handling user signup and login using Pydantic models and clean service-based architecture.","archived":false,"fork":false,"pushed_at":"2025-05-09T07:28:53.000Z","size":23,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-06-05T22:49:52.310Z","etag":null,"topics":["authentication","fastapi","pydantic"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/the-y9.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"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}},"created_at":"2025-04-04T11:19:42.000Z","updated_at":"2025-05-09T07:28:56.000Z","dependencies_parsed_at":null,"dependency_job_id":"39c084ed-60f3-48c7-b77a-9ca1b924a41d","html_url":"https://github.com/the-y9/FastAPI-Authentication-Starter-Pack","commit_stats":null,"previous_names":["the-y9/fastapi"],"tags_count":0,"template":true,"template_full_name":null,"purl":"pkg:github/the-y9/FastAPI-Authentication-Starter-Pack","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/the-y9%2FFastAPI-Authentication-Starter-Pack","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/the-y9%2FFastAPI-Authentication-Starter-Pack/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/the-y9%2FFastAPI-Authentication-Starter-Pack/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/the-y9%2FFastAPI-Authentication-Starter-Pack/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/the-y9","download_url":"https://codeload.github.com/the-y9/FastAPI-Authentication-Starter-Pack/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/the-y9%2FFastAPI-Authentication-Starter-Pack/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":261940342,"owners_count":23233521,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","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":["authentication","fastapi","pydantic"],"created_at":"2025-05-29T22:10:41.394Z","updated_at":"2026-04-25T23:34:10.585Z","avatar_url":"https://github.com/the-y9.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# 🔐 FastAPI Authentication Starter Pack\n\nA minimal yet powerful FastAPI starter for handling user **signup** and **login** using Pydantic models and clean service-based architecture.\n\n---\n\n## 📦 Features\n\n- 🚀 Easy-to-use user signup and login endpoints  \n- 🧱 Separation of concerns via `services` and `models`  \n- 🔄 Async route handling  \n- ⚙️ Ready for JWT/token integration (extendable)  \n\n---\n\n## 📁 Project Structure\n\n```\nproject-root/\n├── backend/\n│   ├── services/\n│   │   └── auth_service.py     # Authentication logic lives here\n│   ├── models.py               # Pydantic models for request validation\n│   ├── routes/\n│   │   └── auth_routes.py      # API routes for login and signup\n│   └── main.py                 # FastAPI app instance\n```\n\n---\n\n## 📥 Installation\n\n1. **Clone this starter pack:**\n```bash\ngit clone https://github.com/your-username/fastapi-auth-starter.git\ncd fastapi-auth-starter\n```\n\n2. **Install dependencies:**\n```bash\npip install fastapi uvicorn\n```\n\n---\n\n## 🛠️ Usage\n\n### 🚀 Run the app\n\n```bash\nuvicorn backend.main:app --reload\n```\n\n---\n\n## 🧩 API Endpoints\n\n### 🔑 `POST /user-login`\n\nAuthenticate an existing user.\n\n**Request Example:**\n```json\n{\n  \"username\": \"johndoe\",\n  \"password\": \"mypassword\"\n}\n```\n\n**Success Response:**\n```json\n{\n  \"message\": \"Login successful\"\n}\n```\n\n---\n\n### ✍️ `POST /user-signup`\n\nRegister a new user.\n\n**Request Example:**\n```json\n{\n  \"username\": \"janedoe\",\n  \"email\": \"jane@example.com\",\n  \"password\": \"secure123\"\n}\n```\n\n**Success Response:**\n```json\n{\n  \"response\": \"User registered successfully\"\n}\n```\n\n---\n\n## 🧱 How It Works\n\n### 1. **Routes**\nDefined in `auth_routes.py` using FastAPI's `APIRouter`.\n\n### 2. **Services**\n`auth_service.py` handles core authentication logic (e.g. DB checks, hashing).\n\n### 3. **Models**\n`UserLogin` and `UserSignup` Pydantic models validate incoming requests.\n\n---\n\n## ⚙️ Ready to Extend\n\n- Add JWT authentication with `python-jose`\n- Use SQLAlchemy or Tortoise ORM for persistent storage\n- Integrate password hashing with `passlib`\n\n---\n\n## 📫 Contributing\n\nFeel free to fork, improve, and make PRs. This is meant to be a clean, extendable base.\n\n---\n\n## 📝 License\n\nMI\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fthe-y9%2Ffastapi-authentication-starter-pack","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fthe-y9%2Ffastapi-authentication-starter-pack","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fthe-y9%2Ffastapi-authentication-starter-pack/lists"}