Have your say in Community Polls: What was/is your greatest motivation to start your own business?

How can I effectively store and retrieve image paths in a Shopify app?

How can I effectively store and retrieve image paths in a Shopify app?

enam_ShopiDevs
Shopify Partner
4 1 2

Hello Everyone

 

I am building an app where I need to upload image files to the Shopify store with graphql. Then i need those images list to show. 

 

Now to reduce curl hit I am planning on saving the image path to the database. I found out that I only need the mid part of the location of a file that is this "X/XXXX/XXXX/XXXX/" part? Other parts of the URL I don't have to store in the database. 

 

Can anyone tell me if this part is gonna change for any store? Also, how can I retrieve it if the store does not have any images?

 

Thank You

If it is solved then please like and mark the solution as accepted. Check out these apps below...
Slider Revolution - Create sliders, theme sections, banners, videos, pages, advanced animation, and social feeds.
Essential Grid Gallery - Create photo galleries, video galleries, portfolio galleries, product gallery, collection gallery and more.
EasyDisplay: Product Showcase - Easily display collections, related products, discounts, recently viewed items, and best sellers
Replies 0 (0)