DEV Community

Discussion on: How to build an event management application in Node.js + React on Redis

 
imichaelowolabi profile image
Michael Owolabi

You're welcome.

Thread Thread
 
tikam02 profile image
Tikam Singh Alma

Btw, what to add in authorization header?

is it "token" or "authorization" : "token from login"

token : "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ1c2VyS2V5IjoidXNlcjphYmN"

or

authorization: "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ1c2VyS2V5IjoidXNlcjphYmN"

{
"error": true,
"message": "Unauthorized user."
}

Thread Thread
 
imichaelowolabi profile image
Michael Owolabi • Edited

Bearer token e.g. Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ1c2VyS2V5IjoidXNlcjp...

If you're testing via Postman just choose Bearer Token option in the Authorization header.
Image description

If curl: "Authorization: Bearer {token}"

Thread Thread
 
Sloan, the sloth mascot
Comment deleted