Throughout this lesson, we’ll implement an OAuth application using Node.js. In the workspace to the right, there is a simple website built using Express framework. The application has three routes defined in app.js:
/— A public home page that has links to
/login— A public page that has a button to login and receives an access token
/secret— A protected route that will require an access token to view
Inside the root directory, there is db.js— our in-memory database that we will use for our application.
In the workspace on the right, we have a basic Express application with no authentication implemented.
Explore the project in the workspace to the right. You can run the web app by typing in the terminal:
Then, press the “Check Work” button to load the website.