Sharing information between Shopify Site and Blog Site

Solved
Highlighted
Tourist
12 1 1

Hello!
We are currently developing a React application that utilizes the Shopify Storefront API to display information about products. However, we would also like to share information about the current user, such as their email address (if logged in), or their session cookie (if not logged in), as we would like to display a "cart" icon on our React app that contains all of the products from the user's Shopify cart. Is this possible?

0 Likes
Highlighted
Shopify Staff
Shopify Staff
493 98 88

This is an accepted solution.

Hi @jpraninPF 

 

If you are utilizing the Storefront API in your app, you can pull user information and session data from this. The Storefront API lets you create an access token when a user logs in. The cart will need to be created by you using the checkout object. 

Vix | Developer Support @ Shopify
 - Was my reply helpful? Click Like to let me know! 
 - Was your question answered? Click Accept as Solution 


0 Likes