Skip to main content
Chatbase WhatsApp Automations send a customer an approved WhatsApp message template automatically when something happens in a tool your AI agent is connected to, such as a new order in your Shopify store. They’re for stores that want order messages on WhatsApp without sending them by hand. For example, a store can confirm every new order on WhatsApp, ask cash-on-delivery customers to confirm before shipping, or send a discount code for the next order when an order’s total is above a set amount. Each automation picks the right template for the order with rules. Rules are checked from top to bottom, and the first one whose conditions match sends its template. An optional fallback template covers orders that no rule matches.

WhatsApp automation types and triggers

Every automation has a type and a trigger:
  • The type is the tool the event comes from.
  • The trigger is the event inside that tool that starts the automation.
An AI agent can have one automation per trigger. Once it has an Order created automation, Add automation is disabled, and you change that automation instead of adding another.

Before you create a WhatsApp automation

  • Have permission to manage integrations. Owners and Members can create automations. Viewers can see them but not change them. See Roles and permissions.
  • Use a workspace without HIPAA compliance. WhatsApp Automations aren’t available on HIPAA-compliant workspaces. See HIPAA compliance.
  • Connect Shopify to your AI agent. See Shopify.
  • Connect a WhatsApp number to the same AI agent. See WhatsApp. The automation sends from this number.
  • Create and get approval for the templates you want to send, in the WhatsApp Business Account of that number. See WhatsApp Templates. Only approved templates can be picked.
  • Make sure orders have a phone number. The message goes to the phone number on the order, its customer, or its shipping or billing address, in that order. Orders without a valid phone number are skipped.

Create a WhatsApp automation

1

Open the Automation tab

Go to Channels → WhatsApp and open the Automation tab. Click Add automation.
The WhatsApp page's Automation tab with the Create your first automation empty state and an Add automation button
2

Check the type and trigger, and choose the phone number

The editor opens with Type set to Shopify and Trigger set to Order created. Under Phone number, choose the WhatsApp number the messages are sent from in Send from.
New automation editor showing Type Shopify, Trigger Order created and the Send from phone number
3

Add a rule and its conditions

Under Match & send, give the first rule a name that says what it matches, such as Match cash. Then add its conditions. For each condition, pick an order field in Variable, an operator in Condition, and type or pick a Value.
The Variable dropdown open, listing order fields grouped under Payment & money, Customer & address and Products
Choose Match all when every condition has to be true, or Match any when one is enough. Click Add condition for more. See Conditions for every field and operator.For Payment method, type the name of the payment method as Shopify shows it under Settings → Payments. The hint below the condition reminds you where to look, and Payment method condition shows how to find the exact name.
A rule named Match cash with one condition: Payment method contains cash, with the hint below it pointing to Settings > Payments in Shopify
4

Pick the template

Under Then, click Select template and pick an approved template.
The Select template dialog listing approved WhatsApp templates
Automations fill variables in the template’s body only. If a template has variables in its header, the automation can’t fill them, so pick a template whose header has no variables.
5

Fill in the template's variables

For each variable in the template, such as {{1}}, choose the order field that fills it, or Custom text to type a fixed value. See Template variables.
A template variable's dropdown open, listing order fields and Custom text
The Order Confirm template with {{1}} set to Customer first name and {{2}} set to Order number
The WhatsApp preview on the right shows the message with your choices filled in.
The WhatsApp preview showing Hello [Customer first name], We received your order [Order number]
6

Add more rules and a fallback (optional)

Click Add rule for more cases, and drag rules to change their order. The top-most rule that matches wins.To send something when no rule matches, turn on Send a fallback message, then pick its template and fill in its variables.
The fallback turned on with the Order Confirm template, {{1}} set to Custom text there and {{2}} set to Order number
Each template has an eye button next to its Preview. Click it to show that template in the WhatsApp preview. Otherwise, the preview shows the top-most rule’s template.
The WhatsApp preview showing Hello there after clicking the fallback's eye button
An automation needs at least one rule or the fallback.
7

Save & enable

Click Save & enable. The automation is saved, turned on, and you’re taken back to the list. It sends on the next order that comes in.
The Automation tab listing the Order created automation as Active

WhatsApp automation conditions

Conditions compare a field of the new Shopify order with the value you enter. How values are compared:
  • Text ignores upper and lower case and spaces around the value.
  • Lists (customer tags, discount codes, product titles, SKUs and vendors) match contains when any item contains your text, and does not contain when no item does.
  • Numbers never match when the order has no value for that field.
  • Payment status is picked from a list: Pending, Authorized, Partially paid, Paid, Partially refunded, Refunded, Voided.
  • Shipping country is picked from the country list. Currency is a currency code such as USD.
  • Shipping province/state matches either the name or the code, such as California or CA.
  • Customer phone is the number the message goes to, with a + and its country code, such as +14155550123. A number saved without a country code gets the code of the shipping or billing country. Use starts with and a country code to match customers in one country. The US and Canada share +1, so +1 matches both; add an area code, such as +1415, to match one area.

Payment method condition

Payment method matches the gateway name Shopify stores on the order, as plain text. For a manual payment method, the gateway name is the method’s name as it appears in Shopify admin under Settings → Payments → Manual payment methods, such as Cash on Delivery (COD) or Example Pay.
Shopify admin Payments settings, Manual payment methods: Cash on Delivery (COD) and Example Pay, both Active
Other gateways can store a different name from the one your checkout and admin show. Shopify’s test gateway, for example, shows as “(for testing) Bogus Gateway” on the order, but its gateway name is bogus. To see the gateway of an order, open the order and, in its Timeline, expand the payment line.
A Shopify order timeline with the payment expanded, showing Gateway (for testing) Bogus Gateway
Use contains with a short, distinctive word from the name, such as cash or bogus, when you’re not sure of the exact name. Use is when you know it, such as Example Pay.

WhatsApp automation template variables

The automation fills each variable in a template from the Shopify order, or from text you type. You can pick Customer first name, Customer full name, Customer email, Customer phone, Order number, Order summary, Items, Order total, Subtotal, Shipping fee, Payment method, Item count, Discount code, Shipping address, Shipping city, Shipping country or Custom text. The ones that need explaining: WhatsApp doesn’t allow line breaks inside a variable, so each value is a single line. To put the items on their own line, use Items and add the line breaks in the template’s text around it. If a rule matches but the order has no value for one of its variables, such as a guest checkout without a first name, that rule is skipped and the next rule is checked. The fallback is skipped the same way. To always send something, use Custom text or a field every order has.

What a WhatsApp automation does when a Shopify order comes in

  1. Each AI agent connected to the store checks its active Order created automation.
  2. Rules are checked from top to bottom. The first rule that matches and can fill all its variables sends its template.
  3. If no rule sends, the fallback sends, if it’s on and can fill its variables.
  4. The message goes to the phone number on the order. Each order gets at most one message per AI agent, even if Shopify sends the same order twice.

Manage your WhatsApp automations

The Automation tab lists each automation with its type, its trigger, when it was last updated and whether it’s Active. Use Category to show only one type.
The Category filter open with All and Shopify
When every trigger already has an automation, Add automation is disabled. Hover over it to see why.
A tooltip on the disabled Add automation button: Each trigger can have one automation. Edit the existing one instead.

Edit or pause an automation

Click an automation to edit it. Its saved rules start collapsed and show their names. Click a rule to expand it.
Match & send with two collapsed rules: Match cash and Match Example Pay
Use the Active switch next to Save changes to turn the automation off or back on, then click Save changes. You stay on the page after saving. Save changes stays disabled until you change something.
Edit automation header with the Active switch turned on next to the Save changes button

Delete an automation

Open the ⋯ menu on an automation and choose Delete, then confirm. Deleting can’t be undone. Deleting needs permission to delete integrations, which Owners and Members have.
The automation's menu open with Delete
Disconnecting Shopify from your AI agent deletes its Shopify automations.

Roles and permissions

What a workspace member can do with automations depends on their role’s Integrations permissions: A Viewer can open the Automation tab and every automation, but Add automation, Connect Shopify, Delete, the Active switch, Save & enable and Save changes are disabled. Hovering over them shows “You do not have the permission to complete this action.” Ask an Owner for a role with access to integrations. See Workspace roles.

Audit log

Creating, editing, turning on or off, and deleting an automation each add an entry to the workspace’s audit logs. The entry’s object type is Channel, its name is WhatsApp automation, and it records who made the change and when. Edit entries also record whether the automation is active.

HIPAA-compliant workspaces

WhatsApp Automations aren’t available on HIPAA-compliant workspaces. The Automation tab shows “Not available on HIPAA-compliant accounts.” instead of the list, and no automation sends on a HIPAA-compliant workspace. WhatsApp is blocked on these workspaces, and HIPAA compliance can’t be turned on while a WhatsApp number is connected. See HIPAA compliance.

Limits

  • One automation per trigger for each AI agent.
  • Up to 25 rules per automation and 10 conditions per rule.
  • Up to 50 variables in a template body.
  • Rule names, condition values and custom text can be up to 255 characters.

Example: confirm cash on delivery and Example Pay orders on WhatsApp

A store offers two manual payment methods, Cash on Delivery (COD) and Example Pay. It wants every order paid with either one confirmed on WhatsApp, greeting the customer by first name when the order has one. It uses one approved template, order_confirm:
The automation has two rules and a fallback, all with this template and {{2}} = Order number: What each order gets: The fallback sends to every order no rule sends to. To message only cash and Example Pay orders, turn the fallback off. So that orders without a first name still get a message, add a copy of each rule below it, with {{1}} set to Custom text there.

Troubleshooting

Check, in order:
  1. The automation is Active on the AI agent connected to the store.
  2. A rule’s conditions match the order, or the fallback is on. For Payment method, compare your value with the order’s gateway name. See Payment method condition.
  3. The order has a value for every variable the matching template uses. A missing value skips that rule or the fallback.
  4. The order has a valid phone number.
  5. The template is still approved in WhatsApp Manager, and its header has no variables.
  6. The workspace isn’t HIPAA-compliant. Automations don’t send there.
An automation checks its rules from top to bottom, and the first match wins. Drag the more specific rule above the general one.
The template picker lists only approved templates of the WhatsApp number in Send from. Check its status in WhatsApp Manager, or pick the number the template belongs to.

Frequently asked questions

Yes. Turn on the fallback and leave out the rules. The fallback then sends on every order.
Approved WhatsApp templates. WhatsApp requires businesses to start a conversation with an approved template, so every automation message uses one.
Yes. Save & enable creates it already active. To pause it, open it, turn off Active and save.
They’re deleted. After reconnecting, create them again.
No. Sending an automation message doesn’t use message credits. Meta bills template messages to your WhatsApp Business Account at its own rates.
In Activity > Conversations. Each message is added to the customer’s WhatsApp conversation, so you see it alongside any replies.
Owners and Members can create, edit and delete them. Viewers can see them, but every button that changes an automation is disabled. Custom roles need edit access to integrations to create or edit, and delete access to integrations to delete.
No. WhatsApp is blocked on HIPAA-compliant workspaces, so automations can’t be created, edited or sent there. The Automation tab shows “Not available on HIPAA-compliant accounts.”
Yes. Creating, editing, turning on or off, and deleting an automation each add an audit log entry with the object type Channel and the name WhatsApp automation. Audit logs are available on the Enterprise plan.

Next steps

WhatsApp Templates

Create and get approval for the templates your automations send.