auth-service-prodio is a simple service to handle auth user journeys. It supports both email based auth and mobile otp based auth.
- Signup/Register Account
- Verify Account
- Regenerate OTP/verification token
- Login
- List Accounts
- Forgot Password
- Reset Password
- Unregister/Deactivate Account
- Clone this repository on your server
git clone https://github.com/ProdioDesignWorks/auth-service-prodio.git - Navigate to your repo
cd auth-service-prodio - Install dependencies
npm install - Start service
node .ornpm startornode server/server.js - Open
http://localhost:3005/explorer/in your browser - If you've pm2 installed then use this
pm2 start server/server.js --name="AUTH_SERVICE"
auth-service-prodio uses loopback as the core framework for developing API's, so all customisations, configurations, middlewares and db connectors can be used which you would have used in loopback.
Open config.js file in the config folder. Auth service provides 4 configuration option as below:
- authType(String) - can be one of
EMAILfor email, password based auth orOTPfor mobile otp based auth. - otpDigits(Integer) - Mandatory for OTP based auth. Number of digits of otp to be generated if OTP based auth.
- encryptionKey(String) - Mandatory for EMAIL based auth. Secured key using which the password and verification tokens are to be encrypted.
- securedPassword(Boolean) - Mandatory for EMAIL based auth. If set to true all passwords will be checked to have minimum 8 characters, combination of uppercase, lowercase, number and special characters.