Storefront API does not allow to add a note to checkout

Storefront API does not allow to add a note to checkout

brianh20
Shopify Partner
10 0 1

You can't add a note to the Checkout object while performing a checkout with Shopify Storefront GraphQL API

Replies 6 (6)

vix
Shopify Staff
541 103 122

Hey - I'd suggest to use the cart in this case. This will allow you to add a note and pass to checkout! https://shopify.dev/api/storefront/unstable/mutations/cartNoteUpdate

To learn more visit the Shopify Help Center or the Community Blog.

brianh20
Shopify Partner
10 0 1

I attempted to use the cart part of the Storefront API but I did not find a way to turn a cart into a Checkout without actually moving all the items from one instance to the other. There is no mutation to turn a cart into a checkout so I am using the checkout directly.

 

The checkout does not have a notes property/mutation to add so I will need to add the note to the order, which I am not being able to create given that I have another open ticket about that here:

 

https://community.shopify.com/c/shopify-apis-and-sdks/can-t-find-quot-request-payment-processing-quo...

 

EbenHafkamp
Shopify Partner
15 1 5

Any movement on this? I am also unable to add a note and I also don't see using the cart api as an option as this was implemented after I started my project and there is no way of converting a cart into a checkout, meaning the developer is responsible for maintaining both copies and keeping them in sync which would be a nightmare.

EbenHafkamp
Shopify Partner
15 1 5

I got this working by using the new 

checkoutAttributesUpdateV2 mutation and returning the note as a top level field on checkout.
lokki54
Shopify Partner
53 0 13

Hi. Could you please share a mutation code?

brianh20
Shopify Partner
10 0 1
Yes, my friend. I know how you feel. You’re going to go down an intricate
rabbit hole now. It would have been nice if they at least made something
like ‘checkout from cart Id’. I wish you the best on your journey. Soon
you’ll find there’s a lot you can’t do without Shopify plus - like creating
gift cards; or the fact that if you want to use discount codes there is a
lot of logic you’ll have to implement yourself. There is no way to charge
without paying for Shopify plus unless you do the charges yourself
externally and mark them as paid; and you can’t do this on non-subscription
accounts because they’ll block them.