Shopify Flow is an ecommerce automation platform that enables you to automate tasks and processes within your store and across your apps.
I'm using the Shopify Flow app and am trying to create an automation that will either change the shipping fee or discount it when the order ships from two different locations. Our shipping rate is $10 but when the order is split between two locations, the customer gets charged $20. We would only like them to only be charged $10.
I set up a flow to access the order before it's completed by using Order Risk Analyzed as the trigger. It checks to see if the shipping fee is $20. The action is Update Order Metafield to change the price to $10.
Unfortunately this isn't working. I'm assuming my set-up for the metafields is incorrect, but I can't be sure.
Here's what it looks like.
And the details for Update Order Metafield
Thanks for any help!
Hi @KarebouDesign it would be helpful to know how is it not working, if there is an error or simply the metafield appears different from what expected.
A few points I noticed:
1) Order risk analyzed depends on a different set of events than order completion so I don't think it's guaranteed it will run before order completion.
2) Currently you are using liquid to define the namespace and key to the metafield you want to update or create.
In the namespace field what will populate is the list of all existing metafield namespaces, and in the key definition the current shipping cost of the order.
Especially the namespace part seems counterintuitive as namespace and key are identifiers used to group metafields together.
Usually I'd expect those 2 fields define a specific metafield you want to edit, so especially the namespace being an array of all existing namespaces might be an issue?
To learn more visit the Shopify Help Center or the Community Blog.
Hi @G-L thanks for your reply. The current set-up isn't throwing any errors, but it's also not changing the shipping rate which is what I meant by saying it wasn't working.
I was hoping to edit the existing shipping rate, not add a new metafield, but I don't think I'm going about it the right way. There are numerous posts in the forum about trying to fix the double shipping charge, but there doesn't seem to be a solution. If you can suggest an alternative method, I'd be happy to hear it!
Thank you
Find Global Growth Opportunities For Your Business with Shopify AcademyLearn how to exp...
By Shopify Feb 4, 2025Hey Community, happy February! Looking back to January, we kicked off the year with 8....
By JasonH Feb 3, 2025Expand into selling wholesale with Shopify Academy’s learning path, B2B on Shopify: Lau...
By Shopify Jan 28, 2025