Skip to content

Automate routine work with rules

Updated 4 min read
On this page/ How a rule works

Automations do the repetitive parts of support for you: they route, tag, assign and reply the moment a conversation matches your conditions. This guide walks through building one, then covers every option the rule builder offers. If you are new to Relaypoint, read Get to know Relaypoint first.

How a rule works

Every rule has three parts, always in this order:

  1. When: the trigger, such as a conversation is created or a customer replies.
  2. If: one or more conditions. All of them must match.
  3. Then: the actions Relaypoint performs, top to bottom.
The automation builder with a When, If and Then block filled in to route billing questions to the Finance team
A rule that sends billing questions to the Finance team

Rules run in the order they appear on the Automations page. A rule can stop later rules from running with the stop_processing action. Since version 2.4, rules run in under 200 ms on average.

Build your first rule

  1. Open the builder

    Go to Settings › Automations and select New automation.

  2. Name the rule

    Give it a name your team will recognise, e.g. Route billing questions to Finance.

  3. Pick a trigger

    Choose A conversation is created. Other triggers are listed in Triggers.

  4. Add conditions

    Add Subject contains invoice, refund, billing. Add a second condition Customer plan is Team or Business to skip free accounts.

  5. Choose actions and save

    Choose Assign to team › Finance, then select Save automation. The rule is on as soon as it's saved.


Reference

Triggers

Trigger Fires when Typical use
Conversation created A new email, chat or API message arrives Routing, tagging
Customer replied The customer answers an open conversation Reopen, notify the assignee
Conversation idle No reply for a set time (e.g. 48h) Reminders, auto-close
Tag added Someone adds a tag Escalations
Satisfaction received A CSAT rating comes in Follow up on low scores

Conditions

You can combine conditions on:

  • Message fields
    • Subject, body, sender address
    • Channel (email, chat, API)
  • Customer fields
    • Plan, country, language
    • Any custom attribute, such as account_tier
  • Time: business hours, weekday, or the conversation's age

Matching text

Text conditions are case-insensitive. contains matches any of a comma-separated list; matches takes a regular expression.

Regular expression flavour

Relaypoint uses RE2 syntax. Look-behind isn't supported.

A note on performance

Very long expressions are slower. Keep each one under 500 characters.

Actions

Assign to a person, a team, or round robin inside a team. Round robin skips people marked away.

Rules as code

Teams that keep their configuration in version control can export and import rules as YAML or JSON.

name: Route billing questions to Finance
trigger: conversation.created
conditions:
  all:
    - field: subject
      op: contains
      value: [invoice, refund, billing]
    - field: customer.plan
      op: in
      value: [team, business]
actions:
  - assign_team: finance
  - add_tag: billing

Examples

Auto-close conversations after 5 days of silence

Trigger Conversation idle with 5d, condition Status is Waiting, actions Send saved reply › Closing note then Close.

Escalate unhappy customers

Trigger Satisfaction received, condition Rating is 1 or 2, actions Add tag › escalation and Notify › Support leads.

Route by language

Trigger Conversation created, condition Customer language is German, action Assign to team › DACH support.

Good practice

Start with one rule that saves your team ten minutes a day. Add the next one only when the first has run for a week without surprises.

— The Relaypoint support team

  • Give every rule a descriptive name
  • Test on past conversations before you turn it on
  • Review rule hit counts once a month
  • Remove rules nobody remembers creating

Watch it in action

A short walkthrough of building and sharing a dashboard, recorded with dummy data:

Also good to know

Inline formatting the editor supports: bold, italic, strikethrough, inline code, highlight, H2O, x2, and math such as t_{reply} = t_{first} - t_{created}.

Need a hand?

Our team reviews rules for Business customers for free. Book a 20-minute session and we'll check your setup.

The Relaypoint inbox with seven open conversations, each tagged Billing, Bug, How-to or Feedback
Routed conversations land in the right view

Can a rule run on conversations that already exist?

Yes. Use Run on past conversations, choose a date range and confirm. Up to 10,000 conversations per run.

How many rules can I have?

Team workspaces can have 50 active rules; Business workspaces have no limit.

Still stuck?

Our support team answers within one business day.

Was this page helpful?