Enable user to be logged in on Checkout page using custom storefront

Enable user to be logged in on Checkout page using custom storefront

davebeauchemin
Shopify Partner
5 0 1

Hi Shopify Devs team,

 

I came across a problem and I can't find any solution, It's been asked by someone else 2 years ago (see: https://github.com/Shopify/storefront-api-examples/issues/80).

 

By using a custom storefront with a Shopify headless on a Basic/Shopify/Advanced plan (not Shopify Plus), there is no way for us to log in to the customer on the checkout page with the Storefront API. This doesn't work for me because by using a custom storefront we implemented your sign-up and sign-in process you provided with the Storefront API to create and log in the customer.

 

If navigating on the custom storefront (here it's a web application), adding items to your cart, and then deciding to log in or sign up (here we would get the customerAccessToken key) and click on the Checkout button, you would now be redirected to the checkout page hosted on Shopify and would expect to be already logged in... Then comes in the annoying link "Already have an account? Login" which make it confusing if you are logged in or not. By using a custom storefront I blocked all pages from the Shopify Online Store to redirect to the web application so even if the customer wants to log in again from the checkout page he can't because the online store is password protected.

 

Hence why I am asking the Shopify Devs team if it would be possible to implement an easy way to read the accessToken on the checkout page and then display all related information about the current customer without displaying the link "Already have an account? Log in"? 

 

Hope we can find a solution ASAP to this since headless is becoming more and more popular without having to switch to the Shopify Plus plan.

Replies 0 (0)