Need guidance in getting's products data from shopify store with private app using angular

Hamza8070
Visitor
1 0 0

shopifyerror.PNGHi! i am calling the "https://true-uk-staging.myshopify.com/admin/api/2021-10/products.json" when i hit in browser it shows me products data while when i hit the same url with http client in angular it gives me CORS error. I have also tried with passing credentials in header like api key with password and convert into base64 with basic space in header still gives CORS error.

i am following this link: https://shopify.dev/apps/auth/oauth

Reply 1 (1)

tewe
Shopify Partner
244 46 102

Hi @Hamza8070 ,

there are some tricks but in the end you can not call the Shopify APIs from the front end. So move the calls to the backend and they will succeed.


Regards
Thomas

• Was my reply helpful? Click Like to let me know!
• Was your question answered? Mark it as an Accepted Solution
• Check out our Price Updater App