cancel
Showing results for 
Search instead for 
Did you mean: 

SAP CPI HTTP Endpoint CORS problem

raulhuerta
Discoverer
0 Kudos

I'm trying to expose a HTTP endpoint from CPI that can be called from an AJAX call in the frontend.

When I try to call it, the browser shows the following error in the console:

Access to XMLHttpRequest at 'https://<CPI endpoint>' from origin '<frontend url>' has been blocked by CORS policy: Response to preflight request doesn't pass access control check: No 'Access-Control-Allow-Origin' header is present on the requested resource.

I have been trying to set all Access-Control headers in a content modifier but they don't show up in the response if i performed a OPTIONS request.

Is there a way I can properly return the expected headers to the browser in this CPI integration flow?

View Entire Topic
Naveen
Active Participant
0 Kudos

Dear All,

We are also facing same issues , when we are trying to bypass CORS issue by using API managment there is no success .

We want to display CPI data in Fiori app but unable to do because of CORS issue.

Regards

Naveen Jain