Closed ulysses-ck closed 2 weeks ago
I tried also to change the redirect-url param in the url from /authorize
to /account/authorize
and gives an error about bad authorization.
Hi @ulysses-ck, sounds like you are using the old utility we have in @shopify/hydrogen@2023.10.0
which is causing miss-match with our documentation.
The old utility createCustomerClient__unstable
is unstable and subject to change. In this utility we hard coded /authorize
as redirect-url.
The newer version of hydrogen@2024.1.0 or later has stabilized api and uses /account/authorize
as default redirect-url.
I would suggest running npx shopify hydrogen upgrade
to update your project to the latest.
But also running npm create @shopify/hydrogen@latest
to get the latest skeleton code you can use to copy/view the relevant files for new customer account flows (ie. you would want all the app/routes/account*
routes, and also search for customerAccount.
for a few other files needed)
I really appreciate it! Thanks, I'll try to update and get everything working again.
What is the location of your example repository?
No response
Which package or tool is having this issue?
Hydrogen
What version of that package or tool are you using?
2023.10.0
What version of Remix are you using?
2.1.0
Steps to Reproduce
server.js
npx shopify hydrogen dev --customer-account-push__unstable
[domain-development]/account/login
Expected Behavior
Receive the code in non-www-domain.com/account/authorize and logged in successfully.
Actual Behavior
Receive the code in non-www-domain.com/authorize and not logged in.