> ## Knowledge Base Index
> Fetch the complete knowledge base index at: https://help.accounteditor.com/sitemap.xml
> Use this file to discover available pages before exploring further.
> Pure-Markdown content can be obtained by appending a '.md' suffix to the content URLs listed in the sitemap (without the trailing slash).

# Advanced automation patterns

Once you have a few workflows running, the problems change. They stop being "it does not work" and become "it works, but not when I need it to". These are the patterns that avoid that, and the mistakes that cause it.

## Timing is the whole game

Account Editor triggers fire **after** a customer has changed something. Actions apply **from now on**.

That gives you two jobs, and they need different timing:

* **Prevent an edit** — Run the workflow: At order creation — Why: The restriction is in place before the customer opens their order
* **React to an edit** — Run the workflow: On the Account Editor trigger — Why: The change has already happened; you are responding

**The commonest mistake** is putting a restriction on an Account Editor trigger. By the time it runs, the customer has already made the change you wanted to stop.

## Use tags as memory

Flow has no memory between runs. Tags give it one.

* **Do this once only** — Add a tag when the workflow runs, and check for it first
* **Hand off between workflows** — One workflow tags, another reacts to the tag
* **Let staff see what happened** — Tag the order so your team knows a rule fired

Without the "check first" step, a workflow on **Order updated** can run every time anything touches the order.

## Narrow the trigger before you add conditions

**Order product changed** fires for any item change. The specific triggers — **Product added**, **Product removed**, **Product quantity increased**, **Product quantity decreased**, **Product variant swapped** — each fire for one.

Picking the narrower trigger is cheaper than filtering afterwards, and it makes the workflow readable six months later.

## Layer restrictions rather than using the blunt one

**Disallow customer edits** stops everything. That is right for a fraud flag, and wrong for most other cases.

If a customer must not change their address but may still cancel, use **Disable shipping address editing** alone. A customer who can still do something is less likely to email you.

## Keep store-wide rules out of Flow

If a rule applies to every order, it belongs in Account Editor's own settings, not a workflow.

* **No editing on tagged orders** — **Settings → Editing restrictions**
* **No editing on high-risk orders** — **Settings → Editing restrictions**
* **No editing on orders over $500** — Flow — Account Editor cannot express it
* **No editing for one customer segment** — Flow

Settings are visible in one place and survive someone deleting a workflow.

## Good to know

**Flow cannot undo an edit.** An action stops future changes. It does not reverse one already made. If reversal matters, hold the order instead.

**Actions apply to one order.** They never change store behaviour.

**One hold per order.** Shopify allows a single hold. If Account Editor is holding an order for its editing window, another feature cannot hold it separately, and **Release Order Holds** will not free it while a reason remains.

**Test with a real order.** Flow's test run does not exercise Account Editor's side. Place an order and make the change yourself.

**Workflows fail quietly.** A trigger whose feature is turned off simply never fires. Nothing warns you. Check the feature first when a workflow goes silent.

## Troubleshooting

* **A restriction arrives too late** — Why: It runs on an Account Editor trigger — Fix: Move it to order creation
* **A workflow runs repeatedly** — Why: No tag check to stop it — Fix: Tag on first run, and check for the tag
* **Two workflows fight** — Why: Both act on the same order — Fix: Combine them, or tag so only one runs
* **A hold will not release** — Why: Another feature still needs it — Fix: One hold per order
* **A trigger stopped firing** — Why: Its feature was turned off — Fix: Turn the feature back on
* **It works in test but not live** — Why: Flow's test does not run Account Editor's part — Fix: Test with a real order

## FAQ

### Should a rule live in Flow or in Account Editor?

Account Editor if it applies to every order. Flow if it depends on conditions Account Editor cannot see, like order value or a customer segment.

### How do I stop a workflow running twice?

Tag the order when it runs, and check for that tag before doing anything. Flow has no memory of its own.

### Can I undo an edit a customer already made?

No. Flow only prevents future changes. To catch edits before dispatch, hold orders during the editing window instead.

### Why does my workflow work in testing but not on real orders?

Flow's test run does not exercise the Account Editor half. Place a real test order and make the change yourself.

### How many workflows is too many?

Whatever you cannot explain to a colleague. If two workflows can act on the same order, they will eventually collide.

## Related articles

* [Account Editor triggers and actions in Shopify Flow](/en/article/account-editor-triggers-and-actions-in-shopify-flow-1hhwi38/)
* [Things you can automate](/en/article/things-you-can-automate-1tzi5b1/)
* [Shopify Flow isn't firing](/en/article/shopify-flow-isnt-firing-7txrlb/)
* [Which orders can be edited](/en/article/which-orders-can-be-edited-1bis0nl/)
