Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/integeralex/flexhostmail
FlexHostMail is a Node.js package designed for secure email-based OTP (One-Time Password) verification systems. In this beta release, we introduce new functionalities and improvements to enhance your OTP implementation.
https://github.com/integeralex/flexhostmail
codecov codescene github-copilot gitkraken gitlens learn mailgun
Last synced: 4 months ago
JSON representation
FlexHostMail is a Node.js package designed for secure email-based OTP (One-Time Password) verification systems. In this beta release, we introduce new functionalities and improvements to enhance your OTP implementation.
- Host: GitHub
- URL: https://github.com/integeralex/flexhostmail
- Owner: IntegerAlex
- License: cc0-1.0
- Created: 2024-02-27T09:56:37.000Z (12 months ago)
- Default Branch: main
- Last Pushed: 2024-03-05T18:53:22.000Z (12 months ago)
- Last Synced: 2024-03-05T19:59:17.492Z (12 months ago)
- Topics: codecov, codescene, github-copilot, gitkraken, gitlens, learn, mailgun
- Language: JavaScript
- Homepage:
- Size: 119 KB
- Stars: 3
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Contributing: CONTRIBUTING.md
- License: LICENSE
Awesome Lists containing this project
README
# Email OTP Verification System
[](https://codescene.io/projects/50433)

[](https://www.bestpractices.dev/projects/8456)
## Project Purpose
This Node.js project provides a system for secure email OTP (One-Time Password) generation, sending, and verification. It is designed for demonstration and learning purposes.
It uses Fastify over Express : To focus on speed and efficiency, Fastify is optimized to handle a high volume of requests, making it an ideal choice for performance-critical applications where response time is a key factor.## Features
- **OTP Generation:** Generates secure, random OTP codes.
- **Email Integration:** Sends OTPs to users via email. Requires configuration with an email provider (Mailgun is supported).
- **OTP Storage & Validation:** Securely stores OTPs as hashes in Redis for fast retrieval and validation(Redis is Required).## Setup
### Prerequisites
- Node.js
- npm
- Mailgun account
- Running Redis instance### Instructions
1. Clone the repository.
2. Install dependencies: `npm install`.
3. Create a `.env` file (never committed to version control) with the following fields:```plaintext
MAILGUN_API_KEY=your_mailgun_api_key
REDISHOST=your_redis_hostname_or_ip
REDISPASSWORD=your_redis_password
MAILGUN_DOMAIN=your_mailgun_domain### Start
```bash
`node index.js`
``````zsh
`it listen to port localhost:9543` expose port according to your requirement
```[documentations](./docs.md)
### License