{"id":23237839,"url":"https://github.com/fsobh/auth","last_synced_at":"2025-04-05T21:23:48.517Z","repository":{"id":268343818,"uuid":"901664704","full_name":"fsobh/auth","owner":"fsobh","description":"A Golang authentication service API, supporting both HTTP/2 and gRPC protocols","archived":false,"fork":false,"pushed_at":"2025-02-03T04:02:41.000Z","size":18791,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-02-12T01:17:05.167Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Go","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/fsobh.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}},"created_at":"2024-12-11T04:52:28.000Z","updated_at":"2025-02-03T04:02:45.000Z","dependencies_parsed_at":"2024-12-16T07:37:55.182Z","dependency_job_id":"4396c591-6aca-4565-b139-8d320e96d52b","html_url":"https://github.com/fsobh/auth","commit_stats":null,"previous_names":["fsobh/auth"],"tags_count":0,"template":true,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fsobh%2Fauth","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fsobh%2Fauth/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fsobh%2Fauth/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fsobh%2Fauth/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/fsobh","download_url":"https://codeload.github.com/fsobh/auth/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247402093,"owners_count":20933194,"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":"2024-12-19T04:15:10.263Z","updated_at":"2025-04-05T21:23:48.499Z","avatar_url":"https://github.com/fsobh.png","language":"Go","readme":"\n\u003cp align=\"left\"\u003e\u003ch1 align=\"left\"\u003eAuthentication service\u003c/h1\u003e\u003c/p\u003e\n\n- Supports **HTTP/2** and **gRPC** protocols.\n- PostgreSQL database with **sqlc** for type-safe queries.\n- Redis queue for background tasks.\n\n\n\n\n\u003cdiv style=\"width: 900px\"\u003e\n\u003cimg src=\"doc/dbml.svg\" align=\"center\"  alt=\"db diagram\" width=\"70%\"\u003e\n\u003c/div\u003e\n\n\n## 🔗 Table of Contents\n\n- [📍 Overview](#-overview)\n- [👾 Features](#-features)\n- [📁 Project Structure](#-project-structure)\n    - [📂 Project Index](#-project-index)\n- [🚀 Getting Started](#-getting-started)\n    - [☑️ Prerequisites](#-prerequisites)\n    - [⚙️ Installation](#-installation)\n    - [🤖 Usage](#🤖-usage)\n    - [🧪 Testing](#🧪-testing)\n- [📌 Project Roadmap](#-project-roadmap)\n- [🔰 Contributing](#-contributing)\n- [🎗 License](#-license)\n- [🙌 Acknowledgments](#-acknowledgments)\n\n---\n\n## 📍 Overview\n\nA Golang authentication service API, supporting both HTTP/2 and gRPC protocols.\nThe service is designed to provide user authentication and authorization features,\nincluding user registration, login, and email verification.\nThe service is built\nusing a PostgreSQL database with sqlc for type-safe queries and a Redis queue for background tasks. \n\n---\n\n## 👾 Features\n\n- **User Registration**: Register a new user with a unique email, username, and password.\n- **Email Verification**: Sends a verification email to a user's email address. **User creation will rollback if verification email fails to send (using transactional queries with callbacks)**\n- **User Login**: Authenticate a user with a valid email and password.\n- **User Update**: Update a user's profile information, including their email, username, and password.\n\n\n---\n\n## 📁 Project Structure\n\n```sh\n└── auth/\n    ├── db\n    │   ├── migration\n    │   ├── query\n    │   └── sqlc\n    ├── doc\n    │   ├── db.dbml\n    │   ├── statik\n    │   └── swagger\n    ├── gapi\n    │   ├── authorization.go\n    │   ├── converter.go\n    │   ├── error.go\n    │   ├── logger.go\n    │   ├── metadata.go\n    │   ├── rpc_create_user.go\n    │   ├── rpc_login_user.go\n    │   ├── rpc_update_user.go\n    │   ├── rpc_verify_email.go\n    │   └── server.go\n    ├── go.mod\n    ├── go.sum\n    ├── main.go\n    ├── makefile\n    ├── pb\n    │   ├── rpc_create_user.pb.go\n    │   ├── rpc_login_user.pb.go\n    │   ├── rpc_update_user.pb.go\n    │   ├── rpc_verify_email.pb.go\n    │   ├── service_auth.pb.go\n    │   ├── service_auth.pb.gw.go\n    │   ├── service_auth_grpc.pb.go\n    │   └── user.pb.go\n    ├── proto\n    │   ├── google\n    │   ├── protoc-gen-openapiv2\n    │   ├── rpc_create_user.proto\n    │   ├── rpc_login_user.proto\n    │   ├── rpc_update_user.proto\n    │   ├── rpc_verify_email.proto\n    │   ├── service_auth.proto\n    │   └── user.proto\n    ├── sqlc.yaml\n    ├── token\n    │   ├── jwt_maker.go\n    │   ├── maker.go\n    │   ├── paseto_asym_maker.go\n    │   ├── paseto_maker.go\n    │   ├── payload.go\n    │   ├── jwt_maker_test.go\n    │   ├── paseto_asym_maker_test.go\n    │   └── paseto_test.go\n    ├── util\n    │   ├── config.go\n    │   ├── password.go\n    │   └── random.go\n    ├── val\n    │   └── validator.go\n    └── worker\n        ├── distributor.go\n        ├── logger.go\n        ├── processor.go\n        └── task_send_verify_email.go\n```\n\n\n### 📂 Project Index\n\u003cdetails open\u003e\n\t\u003csummary\u003e\u003cb\u003e\u003ccode\u003eAUTH/\u003c/code\u003e\u003c/b\u003e\u003c/summary\u003e\n\t\u003cdetails\u003e \u003c!-- __root__ Submodule --\u003e\n\t\t\u003csummary\u003e\u003cb\u003e__root__\u003c/b\u003e\u003c/summary\u003e\n\t\t\u003cblockquote\u003e\n\t\t\t\u003ctable\u003e\n\t\t\t\u003ctr\u003e\n\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/makefile'\u003emakefile\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ makefile with commands for local development\u003c/code\u003e\u003c/td\u003e\n\t\t\t\u003c/tr\u003e\n\t\t\t\u003ctr\u003e\n\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/main.go'\u003emain.go\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ Main entry point for API service\u003c/code\u003e\u003c/td\u003e\n\t\t\t\u003c/tr\u003e\n\t\t\t\u003ctr\u003e\n\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/go.mod'\u003ego.mod\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ Go mod file\u003c/code\u003e\u003c/td\u003e\n\t\t\t\u003c/tr\u003e\n\t\t\t\u003ctr\u003e\n\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/go.sum'\u003ego.sum\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ Go sum file\u003c/code\u003e\u003c/td\u003e\n\t\t\t\u003c/tr\u003e\n\t\t\t\u003ctr\u003e\n\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/sqlc.yaml'\u003esqlc.yaml\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ Sqlc V2 configuration file\u003c/code\u003e\u003c/td\u003e\n\t\t\t\u003c/tr\u003e\n\t\t\t\u003c/table\u003e\n\t\t\u003c/blockquote\u003e\n\t\u003c/details\u003e\n\t\u003cdetails\u003e \u003c!-- worker Submodule --\u003e\n\t\t\u003csummary\u003e\u003cb\u003eworker\u003c/b\u003e\u003c/summary\u003e\n\t\t\u003cblockquote\u003e\n\t\t\t\u003ctable\u003e\n\t\t\t\u003ctr\u003e\n\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/worker/processor.go'\u003eprocessor.go\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ Task processor for Redis queue - picks up tasks from the queue to process and run them\u003c/code\u003e\u003c/td\u003e\n\t\t\t\u003c/tr\u003e\n\t\t\t\u003ctr\u003e\n\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/worker/task_send_verify_email.go'\u003etask_send_verify_email.go\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ Redis queue task for sending out the verification email to new users\u003c/code\u003e\u003c/td\u003e\n\t\t\t\u003c/tr\u003e\n\t\t\t\u003ctr\u003e\n\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/worker/logger.go'\u003elogger.go\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ Logger for the Redis queue\u003c/code\u003e\u003c/td\u003e\n\t\t\t\u003c/tr\u003e\n\t\t\t\u003ctr\u003e\n\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/worker/distributor.go'\u003edistributor.go\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ Redis task distributor interface - distributes the tasks into appropriate queues\u003c/code\u003e\u003c/td\u003e\n\t\t\t\u003c/tr\u003e\n\t\t\t\u003c/table\u003e\n\t\t\u003c/blockquote\u003e\n\t\u003c/details\u003e\n\t\u003cdetails\u003e \u003c!-- proto Submodule --\u003e\n\t\t\u003csummary\u003e\u003cb\u003eproto\u003c/b\u003e\u003c/summary\u003e\n\t\t\u003cblockquote\u003e\n\t\t\t\u003ctable\u003e\n\t\t\t\u003ctr\u003e\n\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/proto/user.proto'\u003euser.proto\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ proto buff specification for `User` object serialization\u003c/code\u003e\u003c/td\u003e\n\t\t\t\u003c/tr\u003e\n\t\t\t\u003ctr\u003e\n\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/proto/rpc_update_user.proto'\u003erpc_update_user.proto\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ proto buff specification for `Update user` request / response serialization\u003c/code\u003e\u003c/td\u003e\n\t\t\t\u003c/tr\u003e\n\t\t\t\u003ctr\u003e\n\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/proto/rpc_create_user.proto'\u003erpc_create_user.proto\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ proto buff specification for `Create user` request / response serialization\u003c/code\u003e\u003c/td\u003e\n\t\t\t\u003c/tr\u003e\n\t\t\t\u003ctr\u003e\n\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/proto/service_auth.proto'\u003eservice_auth.proto\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ proto buff specification for API service \u003c/code\u003e\u003c/td\u003e\n\t\t\t\u003c/tr\u003e\n\t\t\t\u003ctr\u003e\n\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/proto/rpc_verify_email.proto'\u003erpc_verify_email.proto\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ proto buff specification for `Verify email` request / response serialization\u003c/code\u003e\u003c/td\u003e\n\t\t\t\u003c/tr\u003e\n\t\t\t\u003ctr\u003e\n\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/proto/rpc_login_user.proto'\u003erpc_login_user.proto\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ proto buff specification for `Login user` request / response serialization\u003c/code\u003e\u003c/td\u003e\n\t\t\t\u003c/tr\u003e\n\t\t\t\u003c/table\u003e\n\t\t\t\u003cdetails\u003e\n\t\t\t\t\u003csummary\u003e\u003cb\u003eprotoc-gen-openapiv2\u003c/b\u003e\u003c/summary\u003e\n\t\t\t\t\u003cblockquote\u003e\n\t\t\t\t\t\u003cdetails\u003e\n\t\t\t\t\t\t\u003csummary\u003e\u003cb\u003eoptions\u003c/b\u003e\u003c/summary\u003e\n\t\t\t\t\t\t\u003cblockquote\u003e\n\t\t\t\t\t\t\t\u003ctable\u003e\n\t\t\t\t\t\t\t\u003ctr\u003e\n\t\t\t\t\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/proto/protoc-gen-openapiv2/options/openapiv2.proto'\u003eopenapiv2.proto\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ REPLACE-ME\u003c/code\u003e\u003c/td\u003e\n\t\t\t\t\t\t\t\u003c/tr\u003e\n\t\t\t\t\t\t\t\u003ctr\u003e\n\t\t\t\t\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/proto/protoc-gen-openapiv2/options/annotations.proto'\u003eannotations.proto\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ REPLACE-ME\u003c/code\u003e\u003c/td\u003e\n\t\t\t\t\t\t\t\u003c/tr\u003e\n\t\t\t\t\t\t\t\u003c/table\u003e\n\t\t\t\t\t\t\u003c/blockquote\u003e\n\t\t\t\t\t\u003c/details\u003e\n\t\t\t\t\u003c/blockquote\u003e\n\t\t\t\u003c/details\u003e\n\t\t\t\u003cdetails\u003e\n\t\t\t\t\u003csummary\u003e\u003cb\u003egoogle\u003c/b\u003e\u003c/summary\u003e\n\t\t\t\t\u003cblockquote\u003e\n\t\t\t\t\t\u003cdetails\u003e\n\t\t\t\t\t\t\u003csummary\u003e\u003cb\u003eapi\u003c/b\u003e\u003c/summary\u003e\n\t\t\t\t\t\t\u003cblockquote\u003e\n\t\t\t\t\t\t\t\u003ctable\u003e\n\t\t\t\t\t\t\t\u003ctr\u003e\n\t\t\t\t\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/proto/google/api/httpbody.proto'\u003ehttpbody.proto\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ REPLACE-ME\u003c/code\u003e\u003c/td\u003e\n\t\t\t\t\t\t\t\u003c/tr\u003e\n\t\t\t\t\t\t\t\u003ctr\u003e\n\t\t\t\t\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/proto/google/api/field_behavior.proto'\u003efield_behavior.proto\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ REPLACE-ME\u003c/code\u003e\u003c/td\u003e\n\t\t\t\t\t\t\t\u003c/tr\u003e\n\t\t\t\t\t\t\t\u003ctr\u003e\n\t\t\t\t\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/proto/google/api/http.proto'\u003ehttp.proto\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ REPLACE-ME\u003c/code\u003e\u003c/td\u003e\n\t\t\t\t\t\t\t\u003c/tr\u003e\n\t\t\t\t\t\t\t\u003ctr\u003e\n\t\t\t\t\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/proto/google/api/annotations.proto'\u003eannotations.proto\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ REPLACE-ME\u003c/code\u003e\u003c/td\u003e\n\t\t\t\t\t\t\t\u003c/tr\u003e\n\t\t\t\t\t\t\t\u003c/table\u003e\n\t\t\t\t\t\t\u003c/blockquote\u003e\n\t\t\t\t\t\u003c/details\u003e\n\t\t\t\t\u003c/blockquote\u003e\n\t\t\t\u003c/details\u003e\n\t\t\u003c/blockquote\u003e\n\t\u003c/details\u003e\n\t\u003cdetails\u003e \u003c!-- doc Submodule --\u003e\n\t\t\u003csummary\u003e\u003cb\u003edoc\u003c/b\u003e\u003c/summary\u003e\n\t\t\u003cblockquote\u003e\n\t\t\t\u003ctable\u003e\n\t\t\t\u003ctr\u003e\n\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/doc/db.dbml'\u003edb.dbml\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ Database markup version of the database schema\u003c/code\u003e\u003c/td\u003e\n\t\t\t\u003c/tr\u003e\n\t\t\t\u003c/table\u003e\n\t\t\t\u003cdetails\u003e\n\t\t\t\t\u003csummary\u003e\u003cb\u003estatik\u003c/b\u003e\u003c/summary\u003e\n\t\t\t\t\u003cblockquote\u003e\n\t\t\t\t\t\u003ctable\u003e\n\t\t\t\t\t\u003ctr\u003e\n\t\t\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/doc/statik/statik.go'\u003estatik.go\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ Serves static swagger specification page\u003c/code\u003e\u003c/td\u003e\n\t\t\t\t\t\u003c/tr\u003e\n\t\t\t\t\t\u003c/table\u003e\n\t\t\t\t\u003c/blockquote\u003e\n\t\t\t\u003c/details\u003e\n\t\t\t\u003cdetails\u003e\n\t\t\t\t\u003csummary\u003e\u003cb\u003eswagger\u003c/b\u003e\u003c/summary\u003e\n\t\t\t\t\u003cblockquote\u003e\n\t\t\t\t\t\u003ctable\u003e\n\t\t\t\t\t\u003ctr\u003e\n\t\t\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/doc/swagger/swagger-initializer.js'\u003eswagger-initializer.js\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ cloned from \u003ca href=\"https://github.com/swagger-api/swagger-ui/tree/master/dist\"\u003eswagger-ui\u003c/a\u003e\u003c/code\u003e\u003c/td\u003e\n\t\t\t\t\t\u003c/tr\u003e\n\t\t\t\t\t\u003ctr\u003e\n\t\t\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/doc/swagger/swagger-ui-standalone-preset.js'\u003eswagger-ui-standalone-preset.js\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ cloned from \u003ca href=\"https://github.com/swagger-api/swagger-ui/tree/master/dist\"\u003eswagger-ui\u003c/a\u003e\u003c/code\u003e\u003c/td\u003e\n\t\t\t\t\t\u003c/tr\u003e\n\t\t\t\t\t\u003ctr\u003e\n\t\t\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/doc/swagger/auth.swagger.json'\u003eauth.swagger.json\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ cloned from \u003ca href=\"https://github.com/swagger-api/swagger-ui/tree/master/dist\"\u003eswagger-ui\u003c/a\u003e\u003c/code\u003e\u003c/td\u003e\n\t\t\t\t\t\u003c/tr\u003e\n\t\t\t\t\t\u003ctr\u003e\n\t\t\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/doc/swagger/swagger-ui-es-bundle.js'\u003eswagger-ui-es-bundle.js\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ cloned from \u003ca href=\"https://github.com/swagger-api/swagger-ui/tree/master/dist\"\u003eswagger-ui\u003c/a\u003e\u003c/code\u003e\u003c/td\u003e\n\t\t\t\t\t\u003c/tr\u003e\n\t\t\t\t\t\u003ctr\u003e\n\t\t\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/doc/swagger/swagger-ui-bundle.js'\u003eswagger-ui-bundle.js\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ cloned from \u003ca href=\"https://github.com/swagger-api/swagger-ui/tree/master/dist\"\u003eswagger-ui\u003c/a\u003e\u003c/code\u003e\u003c/td\u003e\n\t\t\t\t\t\u003c/tr\u003e\n\t\t\t\t\t\u003ctr\u003e\n\t\t\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/doc/swagger/index.css'\u003eindex.css\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ cloned from \u003ca href=\"https://github.com/swagger-api/swagger-ui/tree/master/dist\"\u003eswagger-ui\u003c/a\u003e\u003c/code\u003e\u003c/td\u003e\n\t\t\t\t\t\u003c/tr\u003e\n\t\t\t\t\t\u003ctr\u003e\n\t\t\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/doc/swagger/swagger-ui-es-bundle-core.js'\u003eswagger-ui-es-bundle-core.js\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ cloned from \u003ca href=\"https://github.com/swagger-api/swagger-ui/tree/master/dist\"\u003eswagger-ui\u003c/a\u003e\u003c/code\u003e\u003c/td\u003e\n\t\t\t\t\t\u003c/tr\u003e\n\t\t\t\t\t\u003ctr\u003e\n\t\t\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/doc/swagger/swagger-ui.js'\u003eswagger-ui.js\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ cloned from \u003ca href=\"https://github.com/swagger-api/swagger-ui/tree/master/dist\"\u003eswagger-ui\u003c/a\u003e\u003c/code\u003e\u003c/td\u003e\n\t\t\t\t\t\u003c/tr\u003e\n\t\t\t\t\t\u003ctr\u003e\n\t\t\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/doc/swagger/swagger-ui.css'\u003eswagger-ui.css\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ cloned from \u003ca href=\"https://github.com/swagger-api/swagger-ui/tree/master/dist\"\u003eswagger-ui\u003c/a\u003e\u003c/code\u003e\u003c/td\u003e\n\t\t\t\t\t\u003c/tr\u003e\n\t\t\t\t\t\u003ctr\u003e\n\t\t\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/doc/swagger/index.html'\u003eindex.html\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ cloned from \u003ca href=\"https://github.com/swagger-api/swagger-ui/tree/master/dist\"\u003eswagger-ui\u003c/a\u003e\u003c/code\u003e\u003c/td\u003e\n\t\t\t\t\t\u003c/tr\u003e\n\t\t\t\t\t\u003ctr\u003e\n\t\t\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/doc/swagger/oauth2-redirect.html'\u003eoauth2-redirect.html\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ cloned from \u003ca href=\"https://github.com/swagger-api/swagger-ui/tree/master/dist\"\u003eswagger-ui\u003c/a\u003e\u003c/code\u003e\u003c/td\u003e\n\t\t\t\t\t\u003c/tr\u003e\n\t\t\t\t\t\u003c/table\u003e\n\t\t\t\t\u003c/blockquote\u003e\n\t\t\t\u003c/details\u003e\n\t\t\u003c/blockquote\u003e\n\t\u003c/details\u003e\n\t\u003cdetails\u003e \u003c!-- gapi Submodule --\u003e\n\t\t\u003csummary\u003e\u003cb\u003egapi\u003c/b\u003e\u003c/summary\u003e\n\t\t\u003cblockquote\u003e\n\t\t\t\u003ctable\u003e\n\t\t\t\u003ctr\u003e\n\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/gapi/metadata.go'\u003emetadata.go\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ Helper to capture metadata of gRPC gateway requests\u003c/code\u003e\u003c/td\u003e\n\t\t\t\u003c/tr\u003e\n\t\t\t\u003ctr\u003e\n\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/gapi/logger.go'\u003elogger.go\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ Logger file for gRPC \u0026 HTTP requests\u003c/code\u003e\u003c/td\u003e\n\t\t\t\u003c/tr\u003e\n\t\t\t\u003ctr\u003e\n\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/gapi/authorization.go'\u003eauthorization.go\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ Validates token format for incoming authorized calls\u003c/code\u003e\u003c/td\u003e\n\t\t\t\u003c/tr\u003e\n\t\t\t\u003ctr\u003e\n\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/gapi/rpc_update_user.go'\u003erpc_update_user.go\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ Function that is called to update a user record when the api endpoint is invoked \u003c/code\u003e\u003c/td\u003e\n\t\t\t\u003c/tr\u003e\n\t\t\t\u003ctr\u003e\n\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/gapi/rpc_verify_email.go'\u003erpc_verify_email.go\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ Function that is called to verify a new users email when the api endpoint is invoked\u003c/code\u003e\u003c/td\u003e\n\t\t\t\u003c/tr\u003e\n\t\t\t\u003ctr\u003e\n\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/gapi/error.go'\u003eerror.go\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ Helper to handle generic errors (invalid request params, unauthorized calls)\u003c/code\u003e\u003c/td\u003e\n\t\t\t\u003c/tr\u003e\n\t\t\t\u003ctr\u003e\n\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/gapi/rpc_login_user.go'\u003erpc_login_user.go\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ Function that is called to log a user into their account when the api endpoint is invoked\u003c/code\u003e\u003c/td\u003e\n\t\t\t\u003c/tr\u003e\n\t\t\t\u003ctr\u003e\n\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/gapi/converter.go'\u003econverter.go\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ Helper to sanitize User database objects from sensitive data (like password)\u003c/code\u003e\u003c/td\u003e\n\t\t\t\u003c/tr\u003e\n\t\t\t\u003ctr\u003e\n\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/gapi/rpc_create_user.go'\u003erpc_create_user.go\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ Function that is called to create a new user account when the api endpoint is invoked\u003c/code\u003e\u003c/td\u003e\n\t\t\t\u003c/tr\u003e\n\t\t\t\u003ctr\u003e\n\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/gapi/server.go'\u003eserver.go\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ Initializes a new Server to run\u003c/code\u003e\u003c/td\u003e\n\t\t\t\u003c/tr\u003e\n\t\t\t\u003c/table\u003e\n\t\t\u003c/blockquote\u003e\n\t\u003c/details\u003e\n\t\u003cdetails\u003e \u003c!-- val Submodule --\u003e\n\t\t\u003csummary\u003e\u003cb\u003eval\u003c/b\u003e\u003c/summary\u003e\n\t\t\u003cblockquote\u003e\n\t\t\t\u003ctable\u003e\n\t\t\t\u003ctr\u003e\n\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/val/validator.go'\u003evalidator.go\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ Helper to validate string format for email, names, passwords, etc... \u003c/code\u003e\u003c/td\u003e\n\t\t\t\u003c/tr\u003e\n\t\t\t\u003c/table\u003e\n\t\t\u003c/blockquote\u003e\n\t\u003c/details\u003e\n\t\u003cdetails\u003e \u003c!-- pb Submodule --\u003e\n\t\t\u003csummary\u003e\u003cb\u003epb\u003c/b\u003e\u003c/summary\u003e\n\t\t\u003cblockquote\u003e\n\t\t\t\u003ctable\u003e\n\t\t\t\u003ctr\u003e\n\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/pb/user.pb.go'\u003euser.pb.go\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ Code generated by protoc-gen-go\u003c/code\u003e\u003c/td\u003e\n\t\t\t\u003c/tr\u003e\n\t\t\t\u003ctr\u003e\n\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/pb/service_auth_grpc.pb.go'\u003eservice_auth_grpc.pb.go\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ Code generated by protoc-gen-go\u003c/code\u003e\u003c/td\u003e\n\t\t\t\u003c/tr\u003e\n\t\t\t\u003ctr\u003e\n\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/pb/rpc_login_user.pb.go'\u003erpc_login_user.pb.go\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ Code generated by protoc-gen-go\u003c/code\u003e\u003c/td\u003e\n\t\t\t\u003c/tr\u003e\n\t\t\t\u003ctr\u003e\n\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/pb/rpc_update_user.pb.go'\u003erpc_update_user.pb.go\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ Code generated by protoc-gen-go\u003c/code\u003e\u003c/td\u003e\n\t\t\t\u003c/tr\u003e\n\t\t\t\u003ctr\u003e\n\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/pb/rpc_create_user.pb.go'\u003erpc_create_user.pb.go\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ Code generated by protoc-gen-go\u003c/code\u003e\u003c/td\u003e\n\t\t\t\u003c/tr\u003e\n\t\t\t\u003ctr\u003e\n\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/pb/service_auth.pb.go'\u003eservice_auth.pb.go\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ Code generated by protoc-gen-go\u003c/code\u003e\u003c/td\u003e\n\t\t\t\u003c/tr\u003e\n\t\t\t\u003ctr\u003e\n\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/pb/service_auth.pb.gw.go'\u003eservice_auth.pb.gw.go\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ Code generated by protoc-gen-go\u003c/code\u003e\u003c/td\u003e\n\t\t\t\u003c/tr\u003e\n\t\t\t\u003ctr\u003e\n\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/pb/rpc_verify_email.pb.go'\u003erpc_verify_email.pb.go\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ Code generated by protoc-gen-go\u003c/code\u003e\u003c/td\u003e\n\t\t\t\u003c/tr\u003e\n\t\t\t\u003c/table\u003e\n\t\t\u003c/blockquote\u003e\n\t\u003c/details\u003e\n\t\u003cdetails\u003e \u003c!-- util Submodule --\u003e\n\t\t\u003csummary\u003e\u003cb\u003eutil\u003c/b\u003e\u003c/summary\u003e\n\t\t\u003cblockquote\u003e\n\t\t\t\u003ctable\u003e\n\t\t\t\u003ctr\u003e\n\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/util/password.go'\u003epassword.go\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ Helper to hash \u0026 compare passwords\u003c/code\u003e\u003c/td\u003e\n\t\t\t\u003c/tr\u003e\n\t\t\t\u003ctr\u003e\n\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/util/config.go'\u003econfig.go\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ Server configs read from app.env\u003c/code\u003e\u003c/td\u003e\n\t\t\t\u003c/tr\u003e\n\t\t\t\u003ctr\u003e\n\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/util/random.go'\u003erandom.go\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ Random generator utility\u003c/code\u003e\u003c/td\u003e\n\t\t\t\u003c/tr\u003e\n\t\t\t\u003c/table\u003e\n\t\t\u003c/blockquote\u003e\n\t\u003c/details\u003e\n\t\u003cdetails\u003e \u003c!-- db Submodule --\u003e\n\t\t\u003csummary\u003e\u003cb\u003edb\u003c/b\u003e\u003c/summary\u003e\n\t\t\u003cblockquote\u003e\n\t\t\t\u003cdetails\u003e\n\t\t\t\t\u003csummary\u003e\u003cb\u003esqlc\u003c/b\u003e\u003c/summary\u003e\n\t\t\t\t\u003cblockquote\u003e\n\t\t\t\t\t\u003ctable\u003e\n\t\t\t\t\t\u003ctr\u003e\n\t\t\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/db/sqlc/models.go'\u003emodels.go\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ Code generated by sqlc\u003c/code\u003e\u003c/td\u003e\n\t\t\t\t\t\u003c/tr\u003e\n\t\t\t\t\t\u003ctr\u003e\n\t\t\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/db/sqlc/db.go'\u003edb.go\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ Code generated by sqlc\u003c/code\u003e\u003c/td\u003e\n\t\t\t\t\t\u003c/tr\u003e\n\t\t\t\t\t\u003ctr\u003e\n\t\t\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/db/sqlc/verify_email.sql.go'\u003everify_email.sql.go\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ Code generated by sqlc\u003c/code\u003e\u003c/td\u003e\n\t\t\t\t\t\u003c/tr\u003e\n\t\t\t\t\t\u003ctr\u003e\n\t\t\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/db/sqlc/user.sql.go'\u003euser.sql.go\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ Code generated by sqlc\u003c/code\u003e\u003c/td\u003e\n\t\t\t\t\t\u003c/tr\u003e\n\t\t\t\t\t\u003ctr\u003e\n\t\t\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/db/sqlc/querier.go'\u003equerier.go\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ Code generated by sqlc \u003c/code\u003e\u003c/td\u003e\n\t\t\t\t\t\u003c/tr\u003e\n\t\t\t\t\t\u003ctr\u003e\n\t\t\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/db/sqlc/tx_verify_email.go'\u003etx_verify_email.go\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ Transactional write to the database to update user records across tables when email is verified\u003c/code\u003e\u003c/td\u003e\n\t\t\t\t\t\u003c/tr\u003e\n\t\t\t\t\t\u003ctr\u003e\n\t\t\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/db/sqlc/store.go'\u003estore.go\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ SQLStore provides all functions to execute db queries and transactions. Also used to Mock DB for tests\u003c/code\u003e\u003c/td\u003e\n\t\t\t\t\t\u003c/tr\u003e\n\t\t\t\t\t\u003ctr\u003e\n\t\t\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/db/sqlc/tx_create_user.go'\u003etx_create_user.go\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ Transactional write that creates a user in the database. This transaction has a callback that executes only when the database write is successful. We use this call back to send out the verification email upon sign up \u003c/code\u003e\u003c/td\u003e\n\t\t\t\t\t\u003c/tr\u003e\n\t\t\t\t\t\u003ctr\u003e\n\t\t\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/db/sqlc/sessions.sql.go'\u003esessions.sql.go\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ Code generated by sqlc\u003c/code\u003e\u003c/td\u003e\n\t\t\t\t\t\u003c/tr\u003e\n\t\t\t\t\t\u003c/table\u003e\n\t\t\t\t\u003c/blockquote\u003e\n\t\t\t\u003c/details\u003e\n\t\t\t\u003cdetails\u003e\n\t\t\t\t\u003csummary\u003e\u003cb\u003equery\u003c/b\u003e\u003c/summary\u003e\n\t\t\t\t\u003cblockquote\u003e\n\t\t\t\t\t\u003ctable\u003e\n\t\t\t\t\t\u003ctr\u003e\n\t\t\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/db/query/user.sql'\u003euser.sql\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ Queries \u0026 annotations pertaining to users for sqlc to generate application database code\u003c/code\u003e\u003c/td\u003e\n\t\t\t\t\t\u003c/tr\u003e\n\t\t\t\t\t\u003ctr\u003e\n\t\t\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/db/query/sessions.sql'\u003esessions.sql\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ Queries \u0026 annotations pertaining to sessions for sqlc to generate application database code\u003c/code\u003e\u003c/td\u003e\n\t\t\t\t\t\u003c/tr\u003e\n\t\t\t\t\t\u003ctr\u003e\n\t\t\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/db/query/verify_email.sql'\u003everify_email.sql\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ Queries \u0026 annotations pertaining to verifying emails for sqlc to generate application database code\u003c/code\u003e\u003c/td\u003e\n\t\t\t\t\t\u003c/tr\u003e\n\t\t\t\t\t\u003c/table\u003e\n\t\t\t\t\u003c/blockquote\u003e\n\t\t\t\u003c/details\u003e\n\t\t\t\u003cdetails\u003e\n\t\t\t\t\u003csummary\u003e\u003cb\u003emigration\u003c/b\u003e\u003c/summary\u003e\n\t\t\t\t\u003cblockquote\u003e\n\t\t\t\t\t\u003ctable\u003e\n\t\t\t\t\t\u003ctr\u003e\n\t\t\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/db/migration/000001_init_schema.up.sql'\u003e000001_init_schema.up.sql\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ Initial database schema for migrate up to use\u003c/code\u003e\u003c/td\u003e\n\t\t\t\t\t\u003c/tr\u003e\n\t\t\t\t\t\u003ctr\u003e\n\t\t\t\t\t\t\u003ctd\u003e\u003cb\u003e\u003ca href='https://github.com/fsobh/auth/blob/master/db/migration/000001_init_schema.down.sql'\u003e000001_init_schema.down.sql\u003c/a\u003e\u003c/b\u003e\u003c/td\u003e\n\t\t\t\t\t\t\u003ctd\u003e\u003ccode\u003e❯ Initial drop database schema for migrate down to use\u003c/code\u003e\u003c/td\u003e\n\t\t\t\t\t\u003c/tr\u003e\n\t\t\t\t\t\u003c/table\u003e\n\t\t\t\t\u003c/blockquote\u003e\n\t\t\t\u003c/details\u003e\n\t\t\u003c/blockquote\u003e\n\t\u003c/details\u003e\n\u003c/details\u003e\n\n---\n## 🚀 Getting Started\n\n### ☑️ Prerequisites\n\nBefore getting started with auth, ensure your runtime environment meets the following requirements:\n\n- **Programming Language:** Go\n- **Package Manager:** Go modules\n- **Containerization:** Docker\n\n\n### ⚙️ Installation\n\nInstall auth using the following methods:\n\n\n\n1. Clone the auth repository:\n```sh\n❯ git clone https://github.com/fsobh/auth\n```\n\n2. Navigate to the project directory:\n```sh\n❯ cd auth\n```\n\n3. Install the project dependencies:\n\n\n**Using `go modules`** \u0026nbsp; [\u003cimg align=\"center\" src=\"https://img.shields.io/badge/Go-00ADD8.svg?style={badge_style}\u0026logo=go\u0026logoColor=white\" /\u003e](https://golang.org/)\n\n```sh\n❯ go mod tidy\n```\n\n\n\n\n### 🤖 Usage\n**Steps 1 and 2 are essential for the service to run**\n\n1. **Update `app.env` with your environment variables**\n\n   |        Name        | Description\n   |:------------------:| :---: \n   | PASETO_PRIVATE_KEY | private key (Paseto V2)   \n   | PASETO_PUBLIC_KEY | public key (Paseto V2)     \n   | SES_FROM_EMAIL     | Verified AWS SES email address\n2. **Update the `.env` file with your AWS account credentials**\n\n   |        Name        | Description\n      |:------------------:| :---: \n   | AWS_ACCESS_KEY_ID | AWS IAM access key   \n   | AWS_SECRET_ACCESS_KEY | AWS IAM secret key     \n   | AWS_DEFAULT_REGION     | AWS region\n\n3. Run the following command to start the service:\n```sh\n❯ docker compose up  \n```\n\n\n[//]: # (### 🧪 Testing)\n\n[//]: # (Run the test suite using the following command:)\n\n[//]: # (**Using `go modules`** \u0026nbsp; [\u003cimg align=\"center\" src=\"https://img.shields.io/badge/Go-00ADD8.svg?style={badge_style}\u0026logo=go\u0026logoColor=white\" /\u003e]\u0026#40;https://golang.org/\u0026#41;)\n\n[//]: # ()\n[//]: # (```sh)\n\n[//]: # (❯ go test ./...)\n\n[//]: # (```)\n\n\n---\n## 📌 Project Roadmap\n\n- [X] **`Task 1`**: \u003cstrike\u003eAuthentication + sessions.\u003c/strike\u003e\n- [X] **`Task 2`**: \u003cstrike\u003eAdd unit tests.\u003c/strike\u003e\n- [X] **`Task 3`**: \u003cstrike\u003eUpgrade db driver from lib/pq to pgx/v5.\u003c/strike\u003e\n- [X] **`Task 4`**: \u003cstrike\u003eAdd RBAC.\u003c/strike\u003e\n- [ ] **`Task 5`**: Add OAuth2 support.\n- [ ] **`Task 6`**: Add Github actions to auto deploy.\n\n---\n\n## 🔰 Contributing\n\n- **💬 [Join the Discussions](https://github.com/fsobh/auth/discussions)**: Share your insights, provide feedback, or ask questions.\n- **🐛 [Report Issues](https://github.com/fsobh/auth/issues)**: Submit bugs found or log feature requests for the `auth` project.\n- **💡 [Submit Pull Requests](https://github.com/fsobh/auth/blob/main/CONTRIBUTING.md)**: Review open PRs, and submit your own PRs.\n\n\u003cdetails closed\u003e\n\u003csummary\u003eContributing Guidelines\u003c/summary\u003e\n\n1. **Fork the Repository**: Start by forking the project repository to your github account.\n2. **Clone Locally**: Clone the forked repository to your local machine using a git client.\n   ```sh\n   git clone https://github.com/fsobh/auth\n   ```\n3. **Create a New Branch**: Always work on a new branch, giving it a descriptive name.\n   ```sh\n   git checkout -b new-feature-x\n   ```\n4. **Make Your Changes**: Develop and test your changes locally.\n5. **Commit Your Changes**: Commit with a clear message describing your updates.\n   ```sh\n   git commit -m 'Implemented new feature x.'\n   ```\n6. **Push to github**: Push the changes to your forked repository.\n   ```sh\n   git push origin new-feature-x\n   ```\n7. **Submit a Pull Request**: Create a PR against the original project repository. Clearly describe the changes and their motivations.\n8. **Review**: Once your PR is reviewed and approved, it will be merged into the main branch. Congratulations on your contribution!\n\u003c/details\u003e\n\n\u003cdetails closed\u003e\n\u003csummary\u003eContributor Graph\u003c/summary\u003e\n\u003cbr\u003e\n\u003cp align=\"left\"\u003e\n   \u003ca href=\"https://github.com{/fsobh/auth/}graphs/contributors\"\u003e\n      \u003cimg src=\"https://contrib.rocks/image?repo=fsobh/auth\"\u003e\n   \u003c/a\u003e\n\u003c/p\u003e\n\u003c/details\u003e\n\n---\n\n## 🎗 License\n- This project is licensed under the MIT License. See the [LICENSE](./LICENSE) file for details.\n\n---\n\n## 🙌 Acknowledgments\n\n- [Zero log](https://github.com/rs/zerolog)\n- [sqlc](https://github.com/sqlc-dev/sqlc-gen-go)\n- [proto buf](https://github.com/golang/protobuf)\n- [mockdb](https://pkg.go.dev/github.com/tmaiaroto/discfg/storage/mockdb)\n- [statik](https://github.com/rakyll/statik)\n- [asynq](https://github.com/hibiken/asynq)\n\n---\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffsobh%2Fauth","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ffsobh%2Fauth","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffsobh%2Fauth/lists"}