Does the BigCommerce API supports CORS?

不羁的心 提交于 2019-11-27 08:36:37

问题


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?


回答1:


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.



来源:https://stackoverflow.com/questions/35942220/does-the-bigcommerce-api-supports-cors

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!