Skip to content
Impulse SoftwareDOCS
Get modules

ImpulseNotify

Verified for ImpulseNotify 0.5.0 ·

Rules, events & fallback

Rules are the heart of the module: events and optional conditions in, a channel cascade out. This is where “High-priority billing ticket → ops Telegram, else SMS after failure” or “Fraud order → Pushover at High priority” is expressed — no hook PHP to write. Rules live under Addons → ImpulseNotify → Rules.

One catalog defines every event a rule can match, its category, and the variables a template may use. Events come from WHMCS hooks, from events ImpulseCore relays, and from the module’s own scans:

Category Events (rule pattern) Source
Billing Invoice created, paid, payment reminder, cancelled, refunded (invoice.created, invoice.paid, invoice.reminder, invoice.cancelled, invoice.refunded) WHMCS hooks
Orders Order placed, paid, accepted, flagged as fraud (order.placed, order.paid, order.accepted, order.fraud) WHMCS hooks
Service Activated, suspended, unsuspended, terminated, upgraded/downgraded (service.created, service.suspended, service.unsuspended, service.terminated, service.upgraded) ImpulseCore
Service Service password changed (service.password_changed) WHMCS hook
Support Ticket opened, staff reply, client reply, closed (ticket.opened, ticket.admin_reply, ticket.user_reply, ticket.closed) WHMCS hooks
Support Response SLA breached (ticket.sla_breach) sla_scan cron
Domains Domain expiring at configured day thresholds (domain.expiring) domain_expiry_scan cron
Security Client login, client password changed, admin login (client.login, client.password_changed, admin.login) WHMCS hooks
Security Critical CVE detected, patch/reboot/rollback failed, patch/reboot completed, maintenance deferral cap reached (security.cve_critical, security.patch_failed, security.patch_completed, security.deferral_cap_reached) ImpulseCore Security & Maintenance

ImpulseCore relays WHMCS’s server-module create, suspend, unsuspend, terminate and package-change events, so service notices fire for services of any WHMCS server module — ImpulseNotify doesn’t need to know how a service was provisioned.

  • Domain expiry thresholds are configurable under Settings → General → Automation & thresholds (default 60, 30, 14, 7, 1 days). The scan covers active domains and sends each threshold once.
  • Ticket response SLA alerts activate as soon as you set a positive minute threshold under Settings → General → Automation & thresholds (0 = disabled by default). The scan raises an admin ticket.sla_breach alert, at most once a day per ticket, for tickets left in Open or Customer-Reply past that limit.
  • Clickable WHMCS links & raw totals: event variables include direct admin and client URLs (ticket.admin_url, ticket.client_url, invoice.admin_url, invoice.client_url, order.admin_url, service.admin_url, service.client_url, client.admin_url) for templates and rich chat embeds, plus raw numeric invoice.total_raw and order.total_raw for minimum-amount conditions.

On a fresh install (on the Dashboard → Quick Start panel) or any time under Rules → One-click starter rule packs, pick an enabled channel and apply a curated bundle in one click:

  • Solo Operator Essentials (1 rule) — new orders, paid invoices, fraud alerts, tickets, customer replies and suspensions in a single admin rule.
  • Support Desk Pack (2 rules) — urgent high-priority tickets & SLA breaches plus a second rule for all ticket opens and customer replies.
  • Billing & Fraud Pack (2 rules) — immediate fraud orders and refunds plus new orders and paid invoices.
  • Client Alerts Pack (1 rule) — billing, ticket replies, provisioning, suspensions and domain renewals for opted-in clients.

Click + Add rule for the four-step wizard (Trigger → Audience → Channel → Review & enable), or Advanced form for every field, including conditions and fallback hops:

  • Rule name — your label.
  • Events (multi-event checkboxes) — tick any combination of WHMCS events to bundle them into one rule without writing wildcards.
  • Single event / family pattern — alternatively pick an individual event or family glob: invoice.*, order.*, service.*, ticket.*, domain.*, security.*, or enter a custom fnmatch-style pattern.
  • Audience — Client resolves to the client’s verified contact for the channel’s type; Admin / operator fans out to matching Staff Recipients (or falls back to the channel’s default target).
  • Recipient (optional) — an explicit phone number, chat id, URL, email address, Pushover key or ntfy topic. It always wins; leave it empty to resolve automatically.
  • Channel (hop 0) — the enabled channel that sends immediately, plus up to two fallback hops.
  • Priority — an integer 0–100; lower runs first.
  • Enabled — tick to activate.

Expand Conditions & targeting (optional) on any rule to narrow exactly when and to whom it fires:

  • Minimum amount — fire only when an invoice or order total meets or exceeds a numeric amount (e.g. 100 for high-value orders).
  • Active hours window — HH:MM-HH:MM server time (including overnight windows such as 18:00-08:00 for after-hours escalation only).
  • Ticket priorities & departments — match only selected priorities (Low, Medium, High) and/or WHMCS ticket departments.
  • Product filter — match order and service events only for selected WHMCS products.
  • Target specific Staff Recipients — pick exact staff members instead of category fan-out.
  • Assigned ticket admin only — route ticket events exclusively to the Staff Recipient linked to the ticket’s assigned WHMCS admin.
  • Client IDs — limit a rule to comma-separated VIP client IDs.
  • Pushover priority override — override a Pushover channel’s default priority (-2 Silent through 1 High) for this rule only.

Every enabled rule whose pattern and conditions match an event fires — priority sets the order, not exclusivity. On an unlicensed install, creating a rule counts toward the 5-rule cap; editing, enabling, disabling and deleting rules always work.

Click Simulate on any rule row to open the read-only Rule simulator. Pick a sample event and click Run simulation to see:

  • the verdict (Would send or Would skip) and any blockers (disabled rule, failed condition, missing template, missing target),
  • the primary channel and masked resolved targets, and
  • the rendered message preview (including email subject when applicable).

Simulation writes nothing to the database, consumes no rate limit or daily send cap, and calls no external provider.

ImpulseNotify Rules tab showing the dry-run Rule Simulator with a green Would send verdict, masked recipient target, and rendered message preview above the Routing Rules table with multi-event badges, visual condition chips, and fallback cascades

A cascade has up to three hops. Hop 0 sends immediately; each fallback hop has a Wait:

  • Wait 0 — escalate only when the previous hop fails outright: the provider rejects it, or it is still failing after its retries.
  • Wait of 30 minutes or more — also escalate when a channel with delivery receipts (WhatsApp or SMS) reports sent but not delivered for that long.

Delivery anywhere in a cascade marks the remaining hops skipped, so a chain never double-delivers. A fallback hop can’t repeat the previous hop’s channel — retries already re-try the same channel. The fallback_escalate cron task (every 5 minutes) drives cascades for messages created in the last 48 hours.

Each hop resolves an address for its own channel type:

  • Client-audience rules look up the client’s verified contact for the new channel type and re-check consent for that channel.
  • Admin-audience staff fan-out supports cross-channel fallback: ImpulseNotify remembers which Staff Recipient each hop targeted and automatically looks up that same person’s address on the next channel type — so Telegram → SMS → Email or Pushover → SMS cascades work seamlessly. If the next channel has a configured default target (Slack, Discord, Teams, Webhook, Pushover, ntfy, or a channel Default admin recipient), it falls back there.
  • Explicit rule recipients are reused only when both channels share the same address kind (for example Webhook → Slack URL).

Every rule-routed message (except raw JSON Webhooks) is rendered from a template for its event × channel type × language. The language comes from the client’s contact, then Settings → General → Default language, then en. Bodies use named tokens such as {invoice.total} and {ticket.admin_url} — plain substitution validated against the event’s variable allowlist, never code execution.

Default templates ship out of the box for every emitted WHMCS and security event across Email (with subject), SMS, Telegram, Slack, Discord, Microsoft Teams, Pushover and ntfy — so rules deliver sensible, clean copy immediately after activation.

Manage all templates under Addons → ImpulseNotify → Templates:

  • Browse & filter by channel type, event family or search query.
  • Edit with clickable variable chips — click any {variable} chip allowed for that event to insert it into the body or email subject, with an instant live sample preview.
  • Strict validation — unknown placeholders are rejected before save.
  • Reset to default — restore any edited stock template back to its shipped copy at any time.
  • WhatsApp Meta template mapping — link any WHMCS event to an approved WhatsApp template name, category, and positional {{1}}–{{6}} slots, or click Browse Meta templates to inspect your WhatsApp Business Account catalog directly. Every new or renamed WhatsApp mapping starts pending until synced as approved from Meta. See WhatsApp onboarding.

ImpulseNotify Templates editor for ticket.opened on Telegram showing the message body textarea, clickable allowed variable chips, and a dark live sample preview rendering realistic ticket data and a clickable WHMCS admin URL

5. Audience resolution, staff routing & client contacts

Section titled “5. Audience resolution, staff routing & client contacts”

A client-audience rule resolves to the client’s own verified contact for the channel’s type. Clients hold WhatsApp, Telegram and SMS contacts, which they add and verify themselves on the client-area Notification Preferences page at index.php?m=impulsenotify. Under Settings → General → Client area navigation, you can toggle Show Notification Preferences link in client area sidebar so ImpulseNotify adds the sidebar link automatically whenever at least one client-facing channel is enabled. The page offers only channel types you have an enabled channel for.

  • Verification: the client requests a 6-digit code, valid for 10 minutes, with 5 attempts per code (rate-limited to 3 codes per contact per hour, 6 per hour / 12 per day per account, and 120 per hour across the install). Telegram users can instead click Connect Telegram, which links their chat directly via a one-time encrypted pairing link.
  • Consent: clients choose, per category and channel, what they receive. Transactional categories (Billing, Services, Support, Domains and Security) are on by default; Offers & news (marketing) is off unless opted in; Announcements (operator bulk and manual broadcasts) requires explicit opt-in on SMS and WhatsApp and defaults on for Telegram unless switched off. Order events count as transactional. A category a client has switched off is honoured even when a rule names an explicit recipient, and consent is re-checked right before delivery.
  • Who can change preferences: the account owner, a user with WHMCS’s Modify Master Account Profile permission, or an admin logged in as the client — who can opt the client out of anything but never into Offers & news or Announcements.

WHMCS Client Area Notification Preferences page showing verified Telegram and SMS contact cards, Connect Telegram button, WhatsApp phone input, and per-category toggle switches for Billing, Services, Support, Domains, Security, Offers & news, and Announcements

Open Staff Recipients → Client Contacts & Opt-ins for a searchable, read-only view of verified and pending client contacts alongside their explicit opt-in and STOP opt-out records. Filter by Client ID, channel (sms, whatsapp, telegram) or verification status. Phone numbers and chat IDs are always shown masked.

ImpulseNotify Client Contacts & Opt-ins sub-tab showing search filters by Client ID, channel, and verification status above a read-only table of masked client contacts, verified/unverified badges, and explicit opt-in and STOP opt-out badges

Admin audience, WHMCS admin import & rotations

Section titled “Admin audience, WHMCS admin import & rotations”

An admin-audience rule with no explicit recipient fans out to your Staff Recipients. Each recipient is a person or group with a name, optional link to a WHMCS admin account (tbladmins), one or more channels — Telegram, SMS, Email or Pushover — and an optional category filter (none ticked = every category).

  • Import WHMCS admin: use the toolbar selector on Staff Recipients to import any active WHMCS admin in one click — linking their WHMCS admin ID (enabling Assigned ticket admin only rules) and seeding their email address automatically.
  • Per-target Test: open Manage on any staff recipient and click Test beside any channel target to verify their address immediately.
  • Weekly on-call rotations: recipients sharing a rotation group take weekly turns by their rotation order (the ISO week number modulo the group’s size), and the current week’s on-call winner displays a green on call this week badge in the table. Recipients without a group always receive.
  • Solo-operator fallback: when no staff recipient matches, Webhook, Slack, Discord, Teams, Pushover and ntfy deliver to the channel’s saved destination, and Telegram, SMS and Email fall back to their optional Default admin recipient. On an unlicensed install, staff recipients are capped at 2.

ImpulseNotify Staff Recipients tab showing the one-click Import WHMCS admin toolbar selector and the staff table with masked Telegram, SMS, Email, and Pushover targets, event category pills, and a green on call this week rotation badge

Every message a rule produces becomes a durable queue row — nothing is fire-and-forget:

  • Duplicate protection — each queued message is keyed on the event, the record it’s about (an invoice, order or ticket), the client, rule, channel, recipient and UTC day, so double-fired hooks and re-run cron tasks collapse to one send. Repeatable same-day events — multiple ticket replies, distinct payment reminder stages, repeated logins and password changes — carry their own per-reply or per-request bucket so every genuine reply or login still delivers.
  • Retry backoff — temporary failures retry after 60s → 5m → 15m → 1h → 6h and are dead-lettered at attempt 6. Permanent failures, such as an invalid number, are marked failed without retrying.
  • Rate limits — a global per-minute, a per-channel per-minute and a per-client per-day ceiling (120, 60 and 20 by default, under Settings → General → Rate limits) for rule-routed messages; WHMCS Notification Provider sends get the global and per-channel ceilings. Messages over a limit are dropped, not queued — raise the ceilings before a large invoice run. Bulk sends wait in the queue for the next window instead of dropping.
  • Quiet hours — an optional nightly window that defers marketing-category messages only; transactional traffic is never held by global quiet hours (use a rule’s Active hours window for per-rule scheduling).
  • Kill switch — Pause ALL sends drops new events instead of queuing them; messages already queued wait until you switch it off.
  • Dry-run mode — rule-routed messages render and are logged as skipped (dry-run) without any provider being called. Any queued message that comes due while dry-run is on — including retries and bulk messages queued before you turned it on — is marked skipped and never sent.

The Manual Message tab sends without a rule — operator intent, not an event.

  • Single send: pick a channel, enter a recipient and a message. It’s queued and sent straight away (refused if the recipient has opted out). The text goes out literally — tokens aren’t substituted. Sending the same message again sends it again, but reloading the page after a send doesn’t.
  • Bulk send: choose an audience — all active clients, clients with an active service of a product, or clients with unpaid invoices — and a WhatsApp, Telegram or SMS channel. Preview is mandatory: it counts clients with a verified contact and valid Announcements consent on that channel type, lists the first ten, and reports excluded clients. Send queues one message per eligible recipient for queue_drain, which always drains transactional event alerts ahead of bulk rows, re-checks consent right before each send (honouring any STOP received in between), and paces bulk sends through the rate limits (waiting for the next window rather than dropping, using at most half a bucket).

On WhatsApp, single sends use the test.message template (hello_world has no room for custom text unless you replace it with an approved template carrying a {message} slot); bulk WhatsApp sends are refused if the test.message template has no text slot. Manual and bulk sends count toward the dev-mode daily cap.

Under Settings → General → Data retention & privacy:

  • Delivery-log retention — 90 days by default. The log stores masked recipients only.
  • Inbound callback retention — 30 days by default for processed provider callbacks such as delivery receipts and replies.
  • Redact message content — optionally clears rendered message content from finished queue rows; the daily prune clears rows about a day after they finish.

Settings → General → GDPR — Erase a client previews and then deletes a client’s notification contacts and consent records, and scrubs their queued and logged messages; you confirm by typing ERASE. Deleting a client in WHMCS triggers the same erasure automatically.

9. WHMCS native notification rules (optional)

Section titled “9. WHMCS native notification rules (optional)”

WHMCS’s own Notification Rules can also deliver through ImpulseNotify channels: the module registers as a WHMCS Notification Provider, so a rule under System Settings → Notifications can pick an ImpulseNotify channel and recipient (or leave recipient blank on Slack, Discord, Teams, Webhook, Pushover and ntfy). These sends use WHMCS’s notification text and need no ImpulseNotify template, and they bypass the addon’s rules, consent and staff routing. WhatsApp channels aren’t offered. Setup is in Installation & activation.