Giter Site home page Giter Site logo

avisingh017 / return_journey Goto Github PK

View Code? Open in Web Editor NEW
0.0 1.0 0.0 232 KB

A registration system that generates OTPs and sends them to users' phone numbers using Twilio. After opt validation and IP validation, the user registers.

Home Page: https://returnjourney.netlify.app/

JavaScript 85.69% HTML 13.64% CSS 0.67%
bcrypt expressjs ipinfo mongodb nodejs reactjs twilio twilio-sms-api

return_journey's Introduction

Registration System with Phone Number Verification and IP Address Validation

This project implements a registration system that includes phone number verification using Twilio, OTP (One-Time Password) generation, and IP address validation. The system is built using the following technologies:

Features

Feature Description
Phone Number Verification Users enter a phone number and receive an OTP for verification.
OTP Generation and Expiry OTP is generated and valid for 5 minutes.
IP Address Validation User registration is allowed only for users from India (IND).

Tech Stack

Technology Description
React Frontend framework for UI development.
Node.js Backend runtime environment.
Express Web application framework for Node.js.
MongoDB Database for storing user data.
Twilio SMS service for OTP generation.
ipinfo IP address validation and location info.
bcrypt Hashing user phoneNumber while registration.

Installation

  1. Clone the repository:

    git clone https://github.com/yourusername/registration-system.git
    
  2. Install dependencies for both the frontend (React) and backend (Node.js):

    cd registration-system/frontend
    npm install
    
    cd ../backend
    npm install
    
  3. Configure Twilio and ipinfo API credentials:

Create a Twilio account and obtain the Account SID and Auth Token.

  • Sign up for an ipinfo account and obtain the API key.
  • Set up environment variables:

In the backend directory, create a .env file with the following content and fill in the appropriate values:

TWILIO_ACCOUNT_SID=<YOUR_TWILIO_ACCOUNT_SID>
TWILIO_AUTH_TOKEN=<YOUR_TWILIO_AUTH_TOKEN>
TWILIO_PHONE_NUMBER=<YOUR_TWILIO_PHONE_NUMBER>

# MongoDB configuration
MONGO_URI=mongodb://localhost:27017/registration_system
  1. Start the frontend and backend servers:
    # Start the frontend (React)
    cd frontend
    npm start
    
    # Start the backend (Node.js and Express)
    cd ../backend
    npm start
    

Usage

  • Access the application at http://localhost:3000 in your web browser.
  • Enter your phone number for verification.
  • Click "Generate OTP" to receive a one-time password via SMS.
  • Enter the received OTP within the given time frame (5 minutes).
  • Complete the registration process with a valid IP address (restricted to IND).

Contributing

Contributions are welcome! Feel free to open an issue or create a pull request.

Deployed link

https://returnjourney.netlify.app/

return_journey's People

Contributors

avisingh017 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.