Post purchase extension shouldRender doesn't get the customerId

Shopify Partner
12 0 2

We're building a post purchase app that needs to render if the customer has previously purchased one of the items in the lineItems of the order. The problem is that when you extend 


The variable inputData.initialPurchase.customerId returns null. We could move this to a dynamic order status extension but then we run the risk of not being able to run background processes in time before the window is closed. It seems like it must be a fairly quick fix for Shopify since that variable is already included in inputData.initialPurchase but is just not populated. I'm not anticipating a super quick turnaround, but if you could let me know when you think it may get fixed, that would be very helpful!

Reply 1 (1)

Shopify Staff
7 1 1

Hi there - thanks for letting us know about this. As far as I know that's actually a bug, customerId is supposed to be populated whenever possible. Our team is looking into it, and I'll make sure to let you know once we make progress on it. Thanks!

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