1

I am in production and I run into a CORS error when fetching data from my Payment Platform with the following error

Failed to load https://www.pesapal.com/api/QueryPaymentDetails?oauth_signature_method=HMAC-SHA1&oauth_timestamp=1513397234&pesapal_merchant_reference=JUB-1513395508&pesapal_transaction_tracking_id=2cb419c1-bdc8-43d7-b573-d2cffd199a82: No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'https://tiip.co.tz' is therefore not allowed access.`

How can I deal resolve this in Production for a REACTJS application created through create-react-app

Ramesh sambu
  • 3,577
  • 2
  • 24
  • 39
dadidaochieng
  • 105
  • 13
  • 2
    Possible duplicate of https://stackoverflow.com/questions/43462367/how-to-overcome-the-cors-issue-in-reactjs – Ramesh sambu Dec 16 '17 at 04:15
  • 1
    This API should be used by a server, query from a browser would have the CORS issue. As long as the API provider doesn't allow your web app calling it you have no choice but to do a proxy API yourself. – Thomas Wang Dec 16 '17 at 04:19
  • Thanks Gentlemen, I have to move the API call to the server – dadidaochieng Dec 28 '17 at 08:55

0 Answers0