Closed LS2355 closed 11 months ago
When using vanilla JS, are you making these calls client-side or server-side?
Client side
Sony themselves block client-side calls with their CORS policy. To get this working, you'll probably need to set up an API layer in Node.js that uses psn-api, then have your React front-end call those API endpoints.
I can't seem to fetch any data when using react but if i just use plain vanilla JS it work great.
This one works great (vanilla JS)![idk](https://github.com/achievements-app/psn-api/assets/108366585/3e1debc8-434c-42a1-8bad-e071bf5c75cf)
but whenever i try to do the same thing in react i keep getting an 403 / forbidden error or an incorrect Npsso error. (the npsso is 100% correct)
if possible can you get back to me with a possible solution. Pretty sure i'm just messing up somewhere but i cant seem to find it
thing to note: I added a proxy to the package.json file it was :localhost://8080. just in case that is useful