zmts / supra-api-nodejs

❤️ Node.js REST API boilerplate
MIT License
335 stars 89 forks source link

Access Denied during Logout #5

Closed Leeibrah closed 5 years ago

Leeibrah commented 5 years ago

Hello,

I am getting the error: "message": "Access denied, don't have permissions." when trying to logout.

I have my added the "refreshToken": "my_refresh_token" under the JSON application body and I don't understand why I am getting the above error message. Let me know what I am missing or what I am doing wrong on my postman.

Thanks.

zmts commented 5 years ago

Hi! You forget access token in authorization header Bearer jwt... /auth/logout requires authorization https://github.com/zmts/supra-api-nodejs/blob/master/permissions/BaseRoleAccess.js

Leeibrah commented 5 years ago

It worked perfectly with the Bearer Token. Thanks.