API is returning response in Postman but throwing error 403 while running on web browser

0
Hi, I am having an application where i am using mindsphere along with mendix. Here i have to show response coming from an API in one of my customize widget. I am able to get the response when i am running an api in postman but i am not getting response in my web browser when i am running my application. I am getting 403 status error. Though i tried to use CORS and added it in an extension of chrome as previously it was showing “Access to XMLHttpRequest has been blocked by CORS policy : No 'Access-Control-Allow-Origin' header is present on the requested response”. After using this i am getting 403 status error. Could anyone help me on this why i am facing this issue?    
asked
2 answers
0

It looks like its Mindsphere returning the 403 error, so I would ask whoever runs the API to check if they have it setup to allow CORS from your domain. If they haven’t, you’ll see CORS errors as you previously mentioned.

answered
0

The first idea I have is, that you have not grant your application access to the MindSphere API you are calling.

You can do this in the MindSphere Developer Cockpit.

Please select there your application and assign here the needed MindSphere API role

 

Hope this is helping.

Stefan

answered