---
title: "Build your first workflow - Workflow Suite"
description: "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."
canonical: "https://docs.workflow-suite.app/build-your-first-workflow"
---

# Build your first workflow

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`.

## 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](https://docs.workflow-suite.app/permissions-and-store-data-access.md).

## 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.

## 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](https://docs.workflow-suite.app/secrets.md).
4. Write the **Message**. Use the variable button on the right of the field to insert values of the event:

```liquid
{{ 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](https://docs.workflow-suite.app/test-preview-and-debug.md).

## 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.

> [!NOTE]
> **Change triggers start with the second change**
> A change trigger compares an event with what the app saw before. The first time the app sees a product there is nothing to compare with, so it remembers the product and starts nothing. When you turn the workflow on, the app reads your existing products in the background so that their next change already counts. See [Change triggers with before and after values](https://docs.workflow-suite.app/change-triggers.md).

## Next steps

- [Start from a template](https://docs.workflow-suite.app/start-from-a-template.md) - skip the blank canvas.
- [How a workflow runs: triggers, steps and runs](https://docs.workflow-suite.app/how-a-workflow-runs.md) - what happens between the event and the finished run.
- [Variables and the variable picker](https://docs.workflow-suite.app/variables.md) - read the event and earlier steps in any field.
