Triggers (Automations)
An automation ties a trigger to a sequence of steps: when this event happens on the server, the bot does that. Everything is composed visually, with no code.
Two ways to write the same thing
Section titled “Two ways to write the same thing”An automation is a graph. Two views work on it, and nothing is ever converted by force:
- Étapes (Steps): the automation reads as a sequence of sentences - Quand …, Si …, Alors …. This is the default view.
- Graphe (Graph): a canvas of connected blocks, with a palette. It takes over on automations that cannot be expressed linearly - a loop, a switch - and Kotbo says so: This automation uses blocks that cannot be written as steps.
Creating an automation
Section titled “Creating an automation”The New automation button offers to start from a ready-made template or from scratch.
| Template | What it does |
|---|---|
| Welcome message | Greet every arrival in a channel and grant their starting role. |
| Watch fresh accounts | Flag to the staff any arrival whose Discord account is under a week old. |
| Block invitations | Time out anyone posting an invitation link to another server. |
| Level reward | Congratulate a member publicly when they level up. |
| Ticket greeting | Post the guidelines as soon as a support ticket opens. |
Templates are ready to use - you only pick the channels and roles.
The triggers
Section titled “The triggers”An automation has a single trigger.
| Trigger | When it fires |
|---|---|
| Arrivée d’un membre | A member joins the server. |
| Départ d’un membre | A member leaves the server. |
| Rôle attribué / Rôle retiré | A role is added to or removed from a member. |
| Message envoyé | On every message posted by a human. |
| Réaction ajoutée | A member reacts to a message. |
| Arrivée en vocal / Départ du vocal | A member joins or leaves a voice channel. |
| Ticket créé | A support ticket is opened. |
| Sanction appliquée | A sanction is issued. |
| Passage de niveau | A member gains a level. |
| Planification | At a fixed time, on a recurring schedule. |
| Pari tranché / Pari annulé | A referee names the winning side, or the stakes are returned. |
| Dette de clan creusée / soldée | A member stakes points they do not hold, or finishes repaying. |
Scheduling
Section titled “Scheduling”The Planification trigger is set either through the guided choice - every hour, every day, every week, every month, with the hour and the day - or through an advanced pattern: a five-field cron pattern.
The time is interpreted in the server’s time zone, set from the dashboard home.
The steps
Section titled “The steps”Every trigger exposes values - the member, the message, the channel - that the following steps can use.
Actions
Section titled “Actions”Posting: Envoyer un message, Envoyer un embed, Envoyer un message privé (no effect if the member’s DMs are closed).
On a member: Ajouter un rôle, Retirer un rôle, Changer le surnom, Exclure temporairement, Expulser, Bannir (permanently or for a given duration).
On a message: Supprimer un message, Réagir à un message, Épingler un message, Ouvrir un fil.
Finally, Ouvrir un ticket opens a support ticket on a member’s behalf.
Conditions and flow control
Section titled “Conditions and flow control”- Si: only run the rest in certain cases. A condition reads as all these conditions or at least one condition, and is arranged into Alors / Sinon (Then / Otherwise).
- Aiguillage: compares a text value against a list of cases.
- Pour chaque: walks a list and runs the loop body for every element.
- Attendre: suspends the run. It resumes even after a bot restart.
The available tests cover Possède le rôle, Salon est, Texte contient, Texte est égal à, Comparer two numbers, ET / OU, NON, plus the length of a text or the size of a list.
Values
Section titled “Values”The data blocks provide a Texte, a Nombre, a Booléen, a Texte composé (in which context values are inserted), Un rôle or Un salon from the server, and the properties of the member, the message, the channel or the server.
In the Steps view, channels, roles and texts are typed straight onto the card, without creating a data block.
Saving
Section titled “Saving”Kotbo validates the graph before saving and lists the issues to fix: Start by placing a trigger block, A field of this step is still empty, N step(s) still need to be completed before saving. When everything is right: The graph is valid.
A saved automation starts paused; the switch on its card enables it.
Following what runs
Section titled “Following what runs”The list filters by All, Active or Paused, and every card shows its number of runs, its success rate and its last run.
The Runs tab lists the passes with their status - Running, Waiting, Completed, Failed, Cancelled - and the number of blocks visited. Click a run to replay it on the graph: the path is replayed step by step, with the inputs and outputs recorded at each block.
Managing the list
Section titled “Managing the list”Every card offers Edit, Duplicate, Pause or Enable, and Delete.