⚠️ This lesson is retired and might contain outdated information.

JSON Web Token (JWT) Introduction

Kent C. Dodds
InstructorKent C. Dodds
Share this video with your friends

Social Share Links

Send Tweet

A basic introduction to the mechanics of JWTs and the application we will be building in this lesson series.

Man 1: [00:00] This is an introductory video on JSON Web Tokens, also known as JWTs. A JOT is an encoded JSON object, digitally signed by the server, which the client sends with every request to identify the user. A JWT here is a token.

[00:14] We have some identification information about this token, we have the payload of the token represented by this blue string of characters, and then we have the signed secret piece of the token.

[00:29] The server has signed this token with the term secret. Let's say it was signed with the term secrets, this is no longer valid, because this doesn't decode properly. That's how the server knows that the token is legitimate.

[00:47] In this series, we are going to be building this app, get random user info, and you'll be required to log in. Then, when you get a random user, every request will send the token over the wire to the server. The server will decode that token to validate that it's legitimate, and then send back the response if it is legitimate.

[01:09] We'll be using Node.js on the back end for our JWT implementation, and we'll use Angular.js on the front end. I'll show you how to use the tools that Angular gives you to use JWTs, and that's what our series is going to be all about.