Enter the following commands at a terminal prompt:
mkdir stepup-auth cd stepup-auth touch server.js
npm init to create the Node.js application, accepting all the defaults.
In addition to
pug, you will be using the following external modules:
express-session- to manage the login state of the user
body-parser- to parse
dotenv- to store your Vonage API key and secret and the name of your application in a
nexmo- the Node Server SDK
Install these dependencies by running the following
npm command at a terminal prompt:
npm install express express-session pug body-parser dotenv @vonage/server-sdk
Note: This tutorial assumes that you have Node.js installed and are running in a Unix-like environment. The terminal commands for Windows environments might be different.
Step-up AuthenticationAdd an extra layer of security when users perform sensitive tasks