advanced-register

Tools

Node.js MongoDB Dotenv Express JWT Nodemailer Uuid

Start api

Once you have downloaded the source code of the api, follow these steps.

  • Install the dependencies with the npm install command.
npm install
  • Change the file name file.txt on .env

  • Fill in the empty variables in the file .env with your data.

PORT=5000
URL_DB=mongodb+srv://YOURUSERNAME:YOURPASSWORD@cluster...
URL_API=http://localhost:5000
URL_CL=https://google.com
JWT_ACCESS_SECRET=ACCESS_SECRET
JWT_REFRESH_SECRET=REFRESH_SECRET
SMTP_HOST=smtp.gmail.com
SMTP_PORT=587

# Do not forget that before you specify your mail as mail for mailing, you must configure it. (example: IMAP for gmail)
SMTP_EMAIL=
SMTP_PASS=
  • Launch the api using the npm run start command.

If you have followed all the instructions correctly, the api should work.