Our Partner & Developer boards on the community are moving to a brand new home: the .dev community forums! While you can still access past discussions here, for all your future app and storefront building questions, head over to the new forums.

Get checkout ID connected to an order using graphQL

Get checkout ID connected to an order using graphQL

TjadiPeeters
Shopify Partner
2 0 4

Hi! 

 

When you are getting the orderName on the conversion page (following this tutorial: https://help.shopify.com/en/manual/orders/status-tracking/customize-order-status/add-conversion-trac...) it seems that sometimes you actually receive a checkoutId. This is pretty well documented in this ticket: 

https://community.shopify.com/c/shopify-apis-and-sdks/explanation-of-the-order-number-value-in-the-c...

 

So in certain cases we receive a checkout ID (# followed by a long integer). I am now looking for a way in which I can swap this checkout ID for the order ID at a later moment using the GraphQL API. This should be possible in one of two ways:

1 . When retrieving an order you can retrieve the checkout ID.

2. You can submit the checkout ID somewhere to get the appropriate order number.

 

I can see in the rest API that the checkout is included in the order object json ( https://shopify.dev/api/admin-rest/2022-10/resources/order), but for the GraphQL API I cannot find the same. How could I best go about this?

 

  

Replies 0 (0)