Chatbot Rules is a deterministic pattern-matching layer that sits in front of every inbound message across WhatsApp, Instagram, Web Chat and Email. You define rules with three matching modes — Exact (case-insensitive equality), Contains (substring), and Regex (full PCRE) — and a reply action. When a message arrives, the engine evaluates rules in priority order and fires the first match. If nothing matches, the message falls through to your flow, your AI agent, or the shared inbox queue.
Each rule is more than a keyword. It can be scoped by channel (only WhatsApp), by time window (only outside business hours), by language (only Hindi messages), or by contact segment (only new contacts in the last 7 days). This means a single rule library serves your entire surface area without leaking across contexts — your "pricing" rule for Indian visitors shows INR, your "pricing" rule for international shows USD.
Replies are not limited to text. A rule can fire a WhatsApp template (with header media), an interactive button message (up to three quick replies), an interactive list message (up to ten options), or a free-form message inside the 24-hour service window. On Instagram, the same rule sends a DM with quick-reply buttons. On Web Chat, it renders rich cards. One rule definition, multi-channel output — that is the point.
The whole layer is observable. Every rule has a hit counter, a 7-day trend, and a debug feed showing the last 20 messages it matched. Rules that never fire surface in a "stale" panel so you can clean up cruft. Conflicts (two rules with overlapping patterns) are flagged at save time. And every match emits an event you can wire into Flow Analytics to measure deflection by rule.