Our Partner & Developer boards on the community are moving to a brand new home: the .dev community forums! While you can still access past discussions here, for all your future app and storefront building questions, head over to the new forums.

Re: How to test Product recommendations app extension during development?

Solved

How to test Product recommendations app extension during development?

suchintan
Shopify Partner
3 0 1

Hi,

 

I want to build a shopify app with my own product recommendation algorithm. Now I'm trying to test the recommendations API I just built. 

 

After creating a new shopify app and finishing all steps from the POS recommendations doc, (the three endpoints built in local service, spinning up my local development service (`npm run dev`) and setting up POS product recommendations extension with the correct URL),  I go to the product details page (`{store_name}.myshopify.com/products/{product_name}`). However, I don't see that my recommendations endpoint gets hit at all. I do see this API call `https://{store_name}.myshopify.com/recommendations/products?section_id=template--xxx__product-recomm... from the store preview page though.

 

Any advice how I could hook up my own recommendation API and test product recommendations extension?

Accepted Solution (1)

ShopifyDevSup
Shopify Staff
1453 238 527

This is an accepted solution.

Hi @suchintan,

 

The POS product recommendations extension allows merchants to lookup recommendations on the Shopify Point of Sale application's product page, or add a tile to their POS's home screen. That recommendations endpoint should only be used by Shopify when someone looks up a product in the POS.

 

Are you trying to add your app's functionality to the Shopify web admin, or on a liquid based theme extension for customers to see from the storefront?

 

Developer Support @ Shopify
- Was this reply helpful? Click Like to let us know!
- Was your question answered? Mark it as an Accepted Solution
- To learn more visit Shopify.dev or the Shopify Web Design and Development Blog

View solution in original post

Replies 2 (2)

ShopifyDevSup
Shopify Staff
1453 238 527

This is an accepted solution.

Hi @suchintan,

 

The POS product recommendations extension allows merchants to lookup recommendations on the Shopify Point of Sale application's product page, or add a tile to their POS's home screen. That recommendations endpoint should only be used by Shopify when someone looks up a product in the POS.

 

Are you trying to add your app's functionality to the Shopify web admin, or on a liquid based theme extension for customers to see from the storefront?

 

Developer Support @ Shopify
- Was this reply helpful? Click Like to let us know!
- Was your question answered? Mark it as an Accepted Solution
- To learn more visit Shopify.dev or the Shopify Web Design and Development Blog

suchintan
Shopify Partner
3 0 1

thank you. yeah i figured out that I should develop a theme extension and call my own API.

 

I really wish that the default storefront product recommendation could be plugged with my API so that I don't have to build the frontend part.