Add a metafield to customer

Topic summary

A user wants to automatically assign customers to one of two metaobjects (“warm colors” or “cool colors”) based on their favorite color selection from a registration form.

Proposed Solution:

  • Set up a Shopify Flow workflow with a “Customer Created” or “Customer Updated” trigger
  • Add conditions to check the selected color (e.g., red/orange/yellow → “Warm Colors”; blue/green/purple → “Cool Colors”)
  • Use “Update Customer Metafield” action to assign the appropriate metaobject

Important Limitation:
Flow doesn’t natively support metaobject references yet, so implementation may require:

  • A custom Shopify Function
  • A third-party app like Mechanic

Open Question:
One responder asked whether the user is using Customer Accounts or Legacy Customer Accounts, which may affect the implementation approach. The discussion remains ongoing with no final resolution yet.

Summarized with AI on October 31. AI used: claude-sonnet-4-5-20250929.

From a registration form where I ask for the customer’s favorite color, I want to automatically assign them an existing metaobject (from a list of two choices: “warm colors” and “cool colors”).

Example: The customer selects the color red, and the “color group” metafield displays “warm colors.”

How is this possible with Flow?

Hi @tj56

You can automate this by setting up a workflow that checks the selected color and assigns the correct metaobject reference. Here’s how:

  1. Trigger: Use the “Customer Created” or “Customer Updated” trigger (depending on when the color is chosen).
  2. Condition: Add a condition that checks the customer’s selected color. If the color is red, orange, or yellow, assign “Warm Colors”; if blue, green, or purple, assign “Cool Colors.”
  3. Action: Use the “Update Customer Metafield” action to set the correct metaobject reference based on the condition.

Since Flow doesn’t directly support metaobject references yet, you might need a custom Shopify Function or an app like Mechanic to handle it

Hello :waving_hand:

Quick question: are you using Customer Accounts or Legacy Customer Accounts?