{"id":29072816,"url":"https://github.com/crisfeim/hummingbird-minimal-auth-example","last_synced_at":"2025-06-27T14:09:37.950Z","repository":{"id":300351084,"uuid":"1005867191","full_name":"crisfeim/hummingbird-minimal-auth-example","owner":"crisfeim","description":"🌐 A minimal Swift backend example for user registration, login, and authenticated data access using JWT tokens.","archived":false,"fork":false,"pushed_at":"2025-06-27T10:46:38.000Z","size":145,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-06-27T11:36:56.438Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Swift","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/crisfeim.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","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-06-21T01:22:10.000Z","updated_at":"2025-06-27T10:46:42.000Z","dependencies_parsed_at":"2025-06-27T11:38:37.439Z","dependency_job_id":null,"html_url":"https://github.com/crisfeim/hummingbird-minimal-auth-example","commit_stats":null,"previous_names":["crisfeim/backend-minimal-auth-example","crisfeim/hummingbird-minimal-auth-example"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/crisfeim/hummingbird-minimal-auth-example","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/crisfeim%2Fhummingbird-minimal-auth-example","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/crisfeim%2Fhummingbird-minimal-auth-example/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/crisfeim%2Fhummingbird-minimal-auth-example/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/crisfeim%2Fhummingbird-minimal-auth-example/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/crisfeim","download_url":"https://codeload.github.com/crisfeim/hummingbird-minimal-auth-example/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/crisfeim%2Fhummingbird-minimal-auth-example/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":262270427,"owners_count":23285165,"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":[],"created_at":"2025-06-27T14:09:37.396Z","updated_at":"2025-06-27T14:09:37.932Z","avatar_url":"https://github.com/crisfeim.png","language":"Swift","funding_links":[],"categories":[],"sub_categories":[],"readme":"# MinimalAuthExample\n\nA minimal Swift backend example for user registration, login, and authenticated data access using JWT tokens.\n\nFor the sake of simplicity, a file store has been used for data persistency.\n\nThis project was built to learn the basics of backend development and JWT authentication in Swift, using [Hummingbird](https://github.com/hummingbird-project/hummingbird) and [JWTKit](https://github.com/vapor/jwt-kit).\n\n## Features\n\n- ✅ User registration with hashed passwords (using Bcrypt)\n- ✅ User login with password verification\n- ✅ JWT-based authentication\n- ✅ Create and retrieve user-specific recipes\n- ✅ Tested use cases and HTTP endpoints\n\n## Endpoints\n\n- `POST /register`: Register a new user (returns JWT token)\n- `POST /login`: Authenticate a user (returns JWT token)\n- `POST /recipes`: Create a recipe (requires Bearer token)\n- `GET /recipes`: Fetch recipes for authenticated user\n\n## Notes\n\n- For simplicity, the project uses dependency injection via function closures (not protocols).\n- JSON files are stored in a custom path using `.cachesDirectory`.\n\n## License\n\nMIT\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcrisfeim%2Fhummingbird-minimal-auth-example","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcrisfeim%2Fhummingbird-minimal-auth-example","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcrisfeim%2Fhummingbird-minimal-auth-example/lists"}