Welcome to ShenZhenJia Knowledge Sharing Community for programmer and developer-Open, Learning and Share
menu search
person
Welcome To Ask or Share your Answers For Others

Categories

I want to exchange information with BigCommerce during application installation and send POST request for code from html page. But I keep getting blocked by CORS: " No 'Access-Control-Allow-Origin' header is present on the requested resource.". And I cannot find anything about it in BigCommerce API documentation.

Do somebody know, is it supported? Is there any way to call BigCommerce api from javascript in browser?

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
thumb_up_alt 0 like thumb_down_alt 0 dislike
418 views
Welcome To Ask or Share your Answers For Others

1 Answer

We do not support CORS. It is very insecure to try to call the API from javascript on in the browser directly. This exposes an API token which enables someone to have access to any data in the store available through basic authentication. This would include PII.

If you really need to call info from the API, please use a secure web service that returns very specific values to your script as opposed to calling it directly.


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
thumb_up_alt 0 like thumb_down_alt 0 dislike
Welcome to ShenZhenJia Knowledge Sharing Community for programmer and developer-Open, Learning and Share
...