__meta
works across positional, mapped, and GraphQL action tags. Add it inline; Mechanic moves the value into the action’s meta - no block syntax needed.
__perform_event: false
skips the follow-up mechanic/actions/perform event, this can be your event history quieter.
They can be used alongside each other.
Examples
{%- assign meta = hash -%}
{%- assign meta["source"] = "cache" -%}
{%- assign meta["trace"] = "abc123-random" -%}
{% action "cache", "set", "foo", "bar", __meta: meta, __perform_event: false %}
{%- assign meta = hash -%}
{%- assign meta["tagged_by"] = "thing" -%}
{% action "shopify", __meta: meta %}
mutation {
tagsAdd(id: "gid://shopify/Customer/1234567890", tags: ["vip"]) {
node { id }
userErrors { field message }
}
}
{% endaction %}