{"id":27779291,"url":"https://github.com/raravi/login-server-express","last_synced_at":"2026-02-16T04:31:08.255Z","repository":{"id":45933765,"uuid":"258866024","full_name":"raravi/login-server-express","owner":"raravi","description":"An Express application for the Login Server","archived":false,"fork":false,"pushed_at":"2025-01-16T16:27:00.000Z","size":2916,"stargazers_count":0,"open_issues_count":8,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-04-27T14:04:19.668Z","etag":null,"topics":["authentication-backend","cors","express","express-rate-limit","login","nodejs","nodemailer"],"latest_commit_sha":null,"homepage":"https://www.npmjs.com/package/login-server-express","language":"JavaScript","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/raravi.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}},"created_at":"2020-04-25T20:18:22.000Z","updated_at":"2021-11-06T14:45:23.000Z","dependencies_parsed_at":"2024-04-23T01:33:56.519Z","dependency_job_id":"80eca4dc-4b51-477b-b155-7aad2150e700","html_url":"https://github.com/raravi/login-server-express","commit_stats":{"total_commits":61,"total_committers":2,"mean_commits":30.5,"dds":0.3770491803278688,"last_synced_commit":"c0761485af8b58f6a4bdab9d136cae46db6c0f70"},"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/raravi%2Flogin-server-express","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/raravi%2Flogin-server-express/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/raravi%2Flogin-server-express/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/raravi%2Flogin-server-express/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/raravi","download_url":"https://codeload.github.com/raravi/login-server-express/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":251676777,"owners_count":21626068,"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-backend","cors","express","express-rate-limit","login","nodejs","nodemailer"],"created_at":"2025-04-30T09:31:29.652Z","updated_at":"2026-02-16T04:31:08.180Z","avatar_url":"https://github.com/raravi.png","language":"JavaScript","funding_links":["https://ko-fi.com/Y8Y21VCIL"],"categories":[],"sub_categories":[],"readme":"# login-server-lambda\n\nAn Express application for the Login Server!\n\nThis module gives the Express backend server for the LOGIN functionality. It returns the express application which is set up with the following:\n\n## API endpoints\n\n1. `/login`: For login of users.\n2. `/register`: To register new users.\n3. `/validate`: To validate the email of new users.\n4. `/forgotpassword`: To send a reset mail to the registered email address of the user.\n5. `/resetpassword`: To handle reset password functionality.\n\n## CORS\n\nCORS is setup with:\n* **Access-Control-Allow-Origin**: Allows `http://localhost:3000` \u0026 `process.env.APP_CLIENTURL`.\n* **Access-Control-Allow-Methods**: `GET` / `POST` are allowed.\n* **Access-Control-Allow-Credentials**: set to `TRUE` (needed for sending `AUTHORIZATION` header).\n\n## Rate Limiter\n\nRate Limiting of each IP to 100 requests per 15 minutes.\n\n## MongoDB Connection\n\nConnect to MongoDB using Mongoose by specifying the Database in `process.env.APP_DB`.\n\n## Reset Password Mail\n\nThe Reset Password API endpoint will send out a mail if the details provided are correct. It uses `process.env.APP_EMAIL`, `process.env.APP_PASSWORD`, `process.env.APP_RESETEMAIL` \u0026 `process.env.APP_RESETLINK`.\n\n## User's Email Validation Mail\n\nThe Register API endpoint will send out a validation mail if the details provided are correct. It uses `process.env.APP_EMAIL`, `process.env.APP_PASSWORD`, `process.env.APP_RESETEMAIL` \u0026 `process.env.APP_VALIDATELINK`.\n\n## Environment Variables expected by the module\n\nThese variables should be stored in Environment Variables, and will be accessible to the module in the form `process.env.APP_DB`. Node.js platform will do this by default.\n\n* **APP_DB**: The MongoDB URI used to connect to the DB.\n* **APP_SECRETORKEY**: A Secret key for generating random strings to be used as JWTs (JSON Web Tokens).\n* **APP_EMAIL**: Email from which you want to send mail.\n* **APP_PASSWORD**: Password for the above APP_EMAIL.\n* **APP_RESETEMAIL**: The Email that is displayed in the 'From' field in the mail sent.\n* **APP_RESETLINK**: Link to reset password. For e.g., https://www.myapp.com/reset-password\n* **APP_VALIDATELINK**: Link to validate email for a new user. For e.g., https://www.myapp.com/validate-email\n* **APP_CLIENTURL**: The URL of your Client application which will connect to this server. For e.g., https://www.myapp.com\n\n## Usage\n\nFor a demo, check out the [repo](https://github.com/raravi/notes-server-lambda) of my Notes App!\n\n[![ko-fi](https://www.ko-fi.com/img/githubbutton_sm.svg)](https://ko-fi.com/Y8Y21VCIL)","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fraravi%2Flogin-server-express","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fraravi%2Flogin-server-express","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fraravi%2Flogin-server-express/lists"}