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.

Unique user id from my mobile app in shopify order

Unique user id from my mobile app in shopify order

kylowrobelek
Shopify Partner
4 0 2

Hello,

 

When the user is redirected from my mobile app to shop (which cooperates with me), I pass UUID in that url.

If user purchased sth, I'd to pass that UUID to Order objects, so after some time I can check which items were bought thanks to my app - of course I can do it by shopify app.

 

So, can I achieve that? E.g. can "purchase paid" event be overrided by developer? Maybe some custom actions by ShopifyAPI can be added?

Replies 3 (3)

Umiko
Shopify Staff
42 8 14
Hi @kylowrobelek 👋

With the Admin API, you should be able to update `customAttributes` or `metafields` for an order with the `orderUpdate` mutation to store a custom UUID as needed. If the order has already been closed, the `orderOpen` mutation can be used as well. 
 
Hope that helps!

Umiko | API Support @ Shopify 
 - Was my reply helpful? Click Like to let me know! 
 - Was your question answered? Mark it as an Accepted Solution
 - To learn more visit Shopify.dev or the Shopify Web Design and Development Blog

kylowrobelek
Shopify Partner
4 0 2

Ok, but is there an option to do it by frontend side? E.g. I got UUID in a cookie and I want to pass it during Create Order Event.

mk7014
Visitor
1 0 0

You got solution or not if yes send me that solutions