2021-04-27

Strapi API integration - Authenticated Super Admin Unable to access custom routes beyond 'ads' and 'ads/:id'

Using: React, Node.js, Strapi, Postman.

I'm having trouble accessing custom routes that my authenticated user has access to view. As a super admin with all permissions in Strapi, I can send my Post request to /auth/local and I can log the JWT. I use the JWT in my get request to /ads or /ads/:id and I get the .json return data. If I try to access /ads/count or /brands, or /brands/:id, or any of the other routes, I get a "401 - unauthorized - you do not have the proper permissions". But I'm authenticated, and have access for everything in the Strapi backend.

I can't figure out the issue. If the issue is do to the header and fetch (as some posts here suggest), I'm unsure as to where to add that header and or how!

Any thoughts you have would be greatly appreciated.



from Recent Questions - Stack Overflow https://ift.tt/3sURxzI
https://ift.tt/eA8V8J

No comments:

Post a Comment