Dedicated to the Hydrogen framework, headless commerce, and building custom storefronts using the Storefront API.
We're moving the community! Starting July 7, the current community will be read-only for approx. 2 weeks. You can browse content, but posting will be temporarily unavailable. Learn more
I am building a custom Frontend for my store on top on StoreFront GraphQL API. For some purpose, I need the cart token whenever the cart is updated (i.e. lineitems are updated).
When adding line items, I get back a checkout response which has an ID - a base64 string which is something like gid://shopify/Checkout/<someID>?key=<somekey>.
Is the cart token in that URL? Otherwise how can the cart token be obtained?
Couldn't you listen for and handle the checkout creation webhook? That would pass along the cart token and everything else, right?