From the course: Microsoft Entra ID for JavaScript Developers
Unlock this course with a free trial
Join today to access over 25,300 courses taught by industry experts.
Author an API
From the course: Microsoft Entra ID for JavaScript Developers
Author an API
- [Instructor] I have two app registrations here, a web app that is going to call a web API. So now let's write a Node.js project for the web API that is going to validate an incoming access token. So I have some starter code in Start.zip which I've unzipped in WebAPI. This WebApp project, ignore it for now. This is the same project from the previous chapter. Just ignore it for now. We'll dive into that in a moment when we modify this to be able to call the web API. But first, let's focus on the WebAPI project. So the WebAPI project over here, as you see has got a .vscode folder where debugging is set up. There's a package.json and server.js. Let me go ahead and do a npm install and let's go dive into VS Code where we can see exactly what is contained in this project. As you can see that I am exposing the API on port 8081. I'm not even bothering to do HTTPS over here, although in production you certainly should. But this is just demo code. So just to avoid that complexity, I have put…
Practice while you learn with exercise files
Download the files the instructor uses to teach the course. Follow along and learn by watching, listening and practicing.