Getting startedBuild your first workflow

Build your first workflow

Copy page

Create a workflow from a blank canvas: choose a trigger, add a condition and an action, test it as a preview, save it and turn it on.

This guide builds a small workflow from a blank canvas: when a product gets the tag clearance, post a message to Slack. It uses a product trigger on purpose, so it works on every store without an extra approval. The same steps apply to any other workflow.

1. Create the workflow

  1. Open Workflows in the app menu.
  2. Select Create blank workflow. The editor opens with an empty canvas.
  3. Type a name into Workflow name, for example Clearance tag to Slack.
A blank workflow named Untitled workflow 2: the Run manually trigger alone on the canvas, the button 1 problem in the toolbar and the trigger panel with Change trigger
A new blank workflow. The trigger sits at the top, the side panel shows its settings.

2. Choose the trigger

  1. Select the trigger at the top of the canvas, then Change trigger.
  2. In Choose what starts this workflow, search for product tags added and pick Product tags added.
  3. If a banner says This trigger needs a permission, select Open Permissions and grant read access to products. See Permissions and store data access.
The Choose what starts this workflow window: a search box, the Show unverified triggers checkbox, the Manual and schedule group with Run manually, On a schedule, Incoming webhook and Started by another workflow, and the Products group, each trigger with a Verified badge
Change trigger opens the trigger picker. Search, or browse the groups.

3. Add a condition

  1. Press + under the trigger. The Add a step window opens.
  2. Pick Condition.
  3. In the side panel, choose the Field with the variable picker: event.payload.added_tags. Set Comparison to contains and Value to clearance.

When the rules match, the run continues on the Then branch, otherwise on the Otherwise branch. An empty branch ends the run.

The Add a step window: a search box, the group Conditions and flow with Condition, Repeat for each, Wait, Start another workflow and Fail the run, and the start of the Actions group with Shopify, Get Shopify data and Send email
The Add a step window. Condition is the first entry.

4. Add the action

  1. Press + on the Then branch.
  2. Search for slack and pick Send Slack message.
  3. In Webhook URL, write {{ secrets.SLACK_WEBHOOK_URL }}. Create that secret on the Secrets page with your Slack incoming webhook URL. See Secrets.
  4. Write the Message. Use the variable button on the right of the field to insert values of the event:
{{ event.payload.title }} is now on clearance.

5. Test it

  1. Select Test in the toolbar above the canvas.
  2. The sample event of the trigger is used; you can edit it under Event (JSON). Keep Preview (nothing is changed) and select Run preview.
  3. The canvas marks the path the run took. Select a step to see what it returned.

In a preview the Slack message is not sent: the step reports what it would have sent. Choose Run for real when you want to see the message arrive. See Test, preview and debug.

The canvas after Run preview: the trigger, the condition, Tag the order and Tell the team on Slack carry a green check, the Test panel shows the edited event
After Run preview the steps that ran are marked green. Select a step to see what it returned.

6. Save and turn it on

  1. The button next to the undo and redo arrows reads No problems when every step is filled in. If it shows a number of problems, select it: each problem opens the step it belongs to.
  2. Select Save in the bar at the top of the admin.
  3. Select Turn on. The badge next to the name changes from Off to On.

From now on the workflow runs whenever a tag is added to a product. Open Run history to see each run.

The workflow turned on: the On badge next to the name and the trigger panel of Product variant price changed reading Ready
Turned on. A change trigger reads your existing products once, so the first change is not missed; the panel says Preparing while it does and Ready when it is done.

Next steps