Shopify Automation: From Flow Recipes to a Cross-System Agent
Where Shopify Flow fits, when an AI agent on the Admin API earns its place, and how to build a governable low-stock reorder agent.

What is Shopify automation, and where does it stop?
Shopify automation is running store tasks without hands-on work. Inside the store, that means Shopify Flow, a free rule-based engine that fires an action when an event happens. For decisions that span Shopify, your payment processor and your ops channel, you need an agent on the Shopify Admin API that drafts a decision a person approves. Major is where that agent gets built: it reasons about the logic once, then ships it as a governed app that runs the same way every night.
Flow is good at what it does. Tag a customer who spends over $500. Hold an order that trips a fraud signal. Post to Slack when inventory drops below a threshold. It runs on the Basic, Grow, Advanced and Plus plans, and it connects out to tools like Slack, Google Sheets, Klaviyo and Asana.
The boundary is judgment and scope. A rule cannot weigh 30-day sell-through against a supplier's lead time and decide how many units to buy. It cannot read a Stripe Radar score, check the customer's chargeback history and decide whether to ship. Here is how the three common options compare:
- Shopify Flow: in-store events and actions, fixed rules, no cross-system reasoning.
- iPaaS tools (Zapier, Make, MESA): moves data between Shopify and other apps, still rule-based steps, no judgment.
- Major: an agent reads Shopify, Stripe and Slack together, drafts the decision, and builds a deterministic app for the repeatable part. State, approvals and audit live in the app.
Keep Flow for in-store rules. Use an agent where a person currently opens three tabs to decide.
Which Shopify workflows are worth an agent?
Three patterns earn the effort.
Low-stock reorder drafting. Input: live inventory and recent orders. Output: a per-SKU reorder proposal a buyer approves. The agent computes sell-through and days of cover, nets out stock already inbound, and proposes a quantity that clears the supplier's lead time plus a buffer. Flow can tell you a SKU crossed a threshold. It cannot tell you to buy 400 units because one supplier ships in three days and another in three weeks.
High-risk order triage. Input: a new order plus its payment signals. The agent reads the Radar risk level, the shipping-versus-billing mismatch, the customer's order history and prior chargebacks, then posts one recommendation: ship, hold or cancel. It assembles the context a human would gather by hand. The hard part is idempotency. Shopify webhooks can arrive more than once, so an agent without memory can act on the same order twice.
Abandoned-cart drafting. A canned recovery email is a Flow or Klaviyo job. The agent version reads what was in the cart, whether the shopper is a repeat customer and current stock, then drafts a message that reflects those facts, or recommends sending nothing to someone who bought the same item yesterday. A marketer approves the draft before it goes out.
What you need from the Shopify Admin API
The Admin GraphQL API reads and writes store data. A custom app in the Shopify admin issues an access token directly, and a public app gets one through OAuth. Every request carries it in the X-Shopify-Access-Token header. You will mostly touch Product and its variants, InventoryLevel, Order and Customer. Pin an API version in the request path, for example 2025-07.
Two gotchas matter in practice. First, rate limiting uses a calculated query cost on a leaky bucket of points, not a request count. A query that fans out through connections is expensive, so a naive nightly job that pulls every field on every order throttles itself. Read extensions.cost.throttleStatus in each response and back off. Second, Shopify supports each API version for a fixed window, so an integration left alone eventually breaks on an unsupported version. Schedule upgrades, and rehearse inventory writes on a development store.
For triggers, register webhooks such as orders/create and inventory_levels/update instead of polling.
Build the low-stock reorder agent on Major
On Major, the Reorder-Drafter is a predictable agent that builds a governed app for the reorder logic, then runs that app on a schedule. The model reasons about the calculation once. After that, the nightly run is code.
- Connectors: Shopify for
Product,InventoryLeveland 30-dayOrderreads, Slack for the approval card in#buying, and optionally Gmail to email the supplier after approval. - The app that holds state: tables for reorder thresholds, supplier lead times, processed order IDs and every approval. The sell-through and days-of-cover math runs here as deterministic code, so the same inputs give the same numbers every night.
- The agent's judgment: proposing a quantity for flagged SKUs when lead times, inbound stock and seasonality pull in different directions, and writing the short rationale a buyer reads.
- The trigger: a nightly workflow in the store's timezone. Webhook-driven triage uses the same app with an
orders/createroute that checks the processed-ID table before acting. - Governance: the Shopify credential is scoped to read inventory and orders, so the agent cannot place orders or move money. The credential stays behind the proxy and the agent never reads it. RBAC controls who can approve a reorder, and the audit log records who approved what and when.
The reorder card is a proposal. A buyer approves or edits it with one click, and only then does the app write a draft purchase order or send the supplier email. Money-moving steps stay with a person by design.
This is where the cost argument shows up. A model-only agent re-derives the workflow on every run, and its token spend grows with usage. Here the model spends tokens up front to design the app, then only on the judgment calls. Cost is front-loaded and then flat, and the logic is code you can read.
Build your Shopify agent on Major
What this guide does not cover
This is a build guide for cross-system automation. It does not teach Liquid themes, checkout UI extensions or the Storefront API for headless builds. It assumes marketing sends stay in Klaviyo or your email tool. It also stops short of unattended ordering and refunds, since every money-moving step here is drafted for a human to approve.
Start building on Major
Build the Shopify reorder-drafter, the order-triage agent or the cart-recovery drafter on Major, with scoped Shopify credentials, approvals in Slack and an audit trail on every action. Keep Flow for your in-store rules and put the cross-system judgment in an app you govern.
Related articles
Frequently asked questions
- What is Shopify automation?
- Shopify automation is running store tasks without manual work. Its default form is Shopify Flow, a rule-based engine that fires in-store actions like tagging orders, sending notifications, and routing fulfillment. The next step up is an AI agent on the Shopify Admin API that reasons across Shopify and other systems to draft decisions a human approves. Major is where that second kind gets built: the agent reasons once, then runs the logic as a deployed app with scoped Admin API access.
- Is Shopify Flow free, and is it only on Plus?
- Shopify Flow is a free app and it is not Plus-only, running on the Basic, Grow, Advanced, and Plus plans. A few actions, such as sending an HTTP request, need Grow or higher, and custom partner-app tasks are gated behind Plus. The gating bites when automation has to reach outside Shopify. On Major, the app the agent builds calls Shopify and every other connected system through the same credential proxy, with no plan tier in between.
- What can Shopify Flow not do?
- Flow runs fixed rules inside Shopify. It cannot make judgment calls that weigh several variables, such as how much of a SKU to reorder given sell-through and supplier lead time, and it does not reason across outside systems like Stripe or roll up data across multiple stores. Major covers that gap: the agent does the weighing once, then encodes the reorder or rollup logic as code so the same calculation runs identically every night.
- How do you automate Shopify orders across systems?
- Use the Shopify Admin GraphQL API to read Orders and Inventory and register webhooks like orders/create so your logic reacts to events. To cross into payments or ops, add an agent that reads a Stripe Radar risk score alongside the order and posts a recommendation to Slack, keeping any money-moving step behind human approval. On Major, that path is one app with Shopify and payment credentials held behind a proxy and every action logged.
- Can an agent handle reorders or refunds automatically?
- An agent can draft them, and the money-moving action should stay human-approved. It can compute a reorder quantity or prepare a refund and route it for one-click approval, with the reasoning and audit trail attached. Major supports that split, with RBAC deciding who can approve a refund and the approval recorded against the Shopify order. If your store only needs order tagging, Flow is the simpler answer.
- How do you keep a Shopify agent from processing the same order twice?
- Store what it has already handled outside the model. Shopify webhooks can be delivered more than once, and a model's context window does not carry over between runs, so an agent with no memory can re-refund or re-reorder against the same order ID. The fix is a persistent record of processed IDs checked before any write. Major gives the agent a managed database inside the app it builds for exactly this.