Skip to content

Automations

Build your first automation

Step by step from an empty editor to a tested automation. When a critical security incident is created, it notifies the information security officer, creates a task on a board and sends a mail to the management.

For
Admins
Time
15 min
You need
The permission automation.manage for tenant automations. Administrators have it.

This guide builds a complete automation for Brandt & Söhne. Whenever someone records a security incident with the severity Kritisch (critical), three things should happen within seconds:

  1. Tom Keller, the information security officer, gets a notification in the bell and by e-mail, with a link to the incident.
  2. A task “Assess incident” appears on the general board, assigned to Tom, with high priority.
  3. The management gets a mail to management@example.com.

Along the way you use every part of the editor: a trigger, a condition, three kinds of step, placeholders and the test run. The same steps work for any other source; only the fields differ.

  • You need the permission automation.manage. Administrators have it. Without it, build the same thing as one of your own automations under My profileAutomations; it can then notify only you and cannot send mail.
  • The source in this example is Sicherheitsvorfälle (security incidents) from the information security area. Any source you may read works the same way.
  • The cron job AUTOMATION_EVENTS must be switched on, or the automation will not react to new records. If it is off, the editor tells you so. See Run automations for the tenant.
  1. Open SettingsOperationsAutomations and click New automation.

  2. Under Name, enter Critical security incident. Under Description, write what it is for, so that the other administrators know: Tells the ISO right away and creates a task on the general board.

  3. Leave Runs as empty. The automation then runs as you, with your rights. If someone else is responsible for incidents, pick that person instead. The automation can then only do what that person could do.

  4. In the card When, pick the trigger A record is created.

    The card When with the four triggers and an empty data source
    A new automation starts with the trigger. The data source comes next.
  5. Under Data source, pick Sicherheitsvorfälle. The text below the picker says which fields the source offers.

    The trigger A record is created with the data source Sicherheitsvorfälle
    The card's heading now reads A record is created · Sicherheitsvorfälle.

Without a condition, the automation would run for every new incident. This one should only run for critical ones.

  1. In the card Only if, click Condition.

  2. Pick the field Schwere (severity), the comparison is and the value Kritisch.

    The card Only if with the condition Schwere is Kritisch
    One condition. The heading of the card reads it back.

For more than one condition, click Condition again. With two or more, a selector appears above them: all of them must hold, at least one, none or not all. Group nests conditions inside each other, for “status is open and (impact at least 4 or likelihood at least 4)”. Conditions explains all of it.

The steps live in the card Then. They run from top to bottom.

  1. Click Step and pick Notify.

    The menu of the Step button with Notify, Send mail, Run an action and If / else
    The four kinds of step that ship with nexxus.
  2. Under To, leave the box with the name of the person it runs as unticked (here Jana Brandt, who it runs as) and pick Tom Keller under Further people.

  3. Under Notify by, pick Bell and e-mail. A critical incident should not wait for the daily digest.

  4. Under Title, type Critical incident: and then open the menu Insert placeholder (the braces next to the field). Pick Record name. The title now reads Critical incident: {{record.title}}, and every notification carries the name of the incident that triggered it.

    The placeholder menu next to the title, with the name, link and id of the record and every field of the source
    Insert placeholder offers the fixed values and every field of the source.
  5. Under Text, write Detected on {{record.detectedAt}}. Please assess within one hour: {{record.link}}. {{record.link}} becomes a link that opens the incident.

  6. Click Step again and pick Run an action. Under Action, pick Aufgabe anlegen (workspaceItem.create) (create a task).

  7. Fill in the fields of the action. Name is required: Assess incident: {{record.title}}. With Field you add the others:

    • Board: the number of the board. It is the number at the end of the board’s address, /workspace/board/2.
    • Priorität (priority): high. The allowed values are critical, high, normal, low and minor, written in lower case.
    • Zuständig (assignee): the number of the person. The person pickers show it in brackets, [3] Tom Keller.
    The step Run an action with the action Aufgabe anlegen and the fields Name, Board, Priorität and Zuständig
    An action runs without asking, with the rights of the person the automation runs as.
  8. Click Step a third time and pick Send mail. Under To, enter management@example.com. Several addresses are separated by commas. Fill in Subject and Text; both take placeholders too.

    The card Then with three steps: Notify, Run an action and Send mail
    The finished card Then. The arrows on each step move it up or down; the bin removes it.
  1. Read the sentence under In one sentence at the bottom of the editor. It describes the whole automation. If it says what you meant, the automation is built the way you meant it.

    The sentence In one sentence below the editor
    The sentence is written by the server and is in German for now: when a record in Sicherheitsvorfälle is created, and only if Schwere is Kritisch, notify one person, create a task and send a mail.
  2. Open the tab Test run and click Start test run. nexxus tries the automation against your real data without saving or changing anything. Actions only pass their pre-check, and notifications and mails are only prepared.

    The result says how often the automation would have run in the last 7 days, shows the steps for up to 3 matching records, and lists the notifications that would go out.

    The test run: it would have run 3 times in the last 7 days, the steps for three incidents and the notification that would go out
    Each step shows test: nothing was changed. The preview gathers the three sample incidents in one notification.
  3. Go back to the tab Edit and click Create automation. It is switched on right away.

From now on, every critical incident starts a run. You find each run with the result of every step in the tab History; see Test run and history.

  • Within seconds. nexxus notes every saved change to a record and the job AUTOMATION_EVENTS hands it to the automations listening to that source, every 2 seconds. A change that is rolled back triggers nothing, and imports trigger nothing.
  • The condition is checked when the run starts, not when the record was saved. If someone corrects the severity within those seconds, the automation sees the corrected value.
  • One run per record. Ten critical incidents created at once give ten runs and ten notifications for Tom. Triggers that find several records in one go, a schedule or a condition, gather them into one notification per person instead; see Steps and placeholders.
  • A failed step stops the run. If the task cannot be created, the mail is not sent. The history shows which step failed and why. Five failed runs in a row pause the automation.
What you seeWhat it means
Record triggers do not run yet: a superadmin has to switch on the cron job “AUTOMATION_EVENTS” (Settings › Operations › Maintenance › Cron Jobs).The automation is saved but does not react to new records until the job is on.
A condition still lacks its value.A condition row has a field and a comparison but no value.
A notification needs someone to receive it.The step Notify has nobody under To.
It does not run like this in the test runA step would fail with the current form. The message below says why.
A run in the history shows failedThe failed step carries the reason, in German. Priorität ‘HIGH’ gibt es nicht. Erlaubt: critical, high, normal, low, minor means the priority was written in capitals; the allowed values follow. Fix the step and click Save.
The history shows the notify step as succeeded with Niemand, der die Meldung bekommen darf.Nobody under To may read the record, or the people are deactivated. The step counts as done, but no notification went out. Check the rights of the recipients.