Can I create a flow to tag orders with the product vendor/s ordered? mine isn't working!

Topic summary

A user is attempting to create a Shopify Flow that automatically tags orders with the vendor names of purchased products. Their initial setup tags every order with all vendor tags, even when products aren’t from those vendors.

Solution Provided:

  • Use a liquid variable in the “Add Order Tags” action: {% for line_item in order.lineItems %}{{ line_item.product.vendor }}{% endfor %}
  • Add a “Check if” condition to verify vendor is not empty/exists before tagging
  • Access this through: Order > lineItems > Product > vendor in the Check step

Follow-up Questions:

  • The original poster wants to tag only specific vendors (5 out of 20 total) and asks how to write conditional statements for this
  • Another user reports the solution may not be working and questions if the liquid code is outdated

Status: The discussion remains open with unresolved questions about selective vendor filtering and potential code compatibility issues.

Summarized with AI on November 11. AI used: claude-sonnet-4-5-20250929.

Thank you so much for your helpful reply. I can’t see how to add the Check if “Vendor is not empty and exists” .

Also I only want to add the vendor name as a tag for some vendors (about 5) but we have about 20 all together.

Could it be done without the check if and using an if statement in the Add Order tags? How would you write this if statement for specific vendors?

Start When: Order Created
Do This: Add Order Tags
{% for lineitems_item in order.lineitems %} {{lineitems_item.product.vendor}},{% endorfor %}}}

Really appreciate your help!

1 Like