How to configure Audit Trail custom alerts
Audit Trail Alerting Management lets you proactively monitor the actions performed on your Scaleway resources. You can enable a set of preconfigured alerts or configure custom alerts based on your security and monitoring needs so Audit Trail notifies you of abnormal or sensitive behavior. This page explains how to set custom alerts.
Before you start
To complete the following actions, you must have:
- A Scaleway account logged in to the console (External link)
- Owner status or IAM permissions allowing you to view and manage Audit Trail
Configure a custom alert
-
In the Scaleway console (External link) side menu, go to Monitoring > Audit Trail.
-
Click the Region dropdown and select the region for which you want to create alerts.
-
Click the Alerts tab, then select Custom.
-
Click Create alert. The alert creation wizard opens.
-
Add a name and description for the alert.
-
Set a severity (e.g., info, error, warning).
-
Define a rule for the alert, using the visual builder or the code editor. The steps here assume that you are using the visual builder (for details on the code editor, see Use the code editor and CEL expressions):
- Select the type of event that you want to be alerted on (e.g., an event related to a product (Product name), an action (Method name), and so on).
- Select a function (is or is not).
- Select an event value from the dropdown (e.g., Instance, CreateAPIKey) or type a value in the freeform field.
For example, you can set up an alert that triggers when users are deleted.

-
If your alert requires multiple rules, click + Add to add another rule.
-
Configure the condition that triggers the alert:
-
Occurrence — Enter the number of times the condition must be met to trigger the alert. Example: Enter 5 to trigger an alert when 5 or more users are deleted.
-
Timeframe — Enter the time window used to evaluate occurrences. Example: Enter 10 to evaluate user deletion events within a 10-minute window.
-
-
Click Test alert to check if:
- the syntax of your alert configuration is valid
- there are currently any active events that match the alert rule you defined
-
Once your configuration syntax is valid, click Create custom alert. The Overview page of your alert opens, showing the details of your new active alert.
Use the code editor and CEL expressions
If you wish to define a custom alert by writing the alert expression yourself, use the code editor. The code editor uses the Common Expression Language (CEL), which lets you define the events that trigger an alert.
Example CEL expression for an alert that is triggered when delete operations are executed from a specific IP address:
(methodName.startsWith("Delete") && sourceIp == "192.0.2.1")Your alert expression is made up of:
- event types
- operators and/or functions
- event values
| Event types | Operators / Functions |
|---|---|
| The following event types are supported: - method_name - principal_id - product_name - project_id - resource_id - service_name - source_ip - status | Operators and functions can include the following: - Equality and inequality operators (defined for all types): ==, != Examples: method_name == "GetKey", status != 200 - Comparison operators (only for integers): <=, <, >, >= Example: status > 400 - Logical AND operator: && Example: method_name == "GetKey" && status != 200 - String functions (only for strings): contains, matches, startsWith, endsWith Example: method_name.contains("Delete"), source_ip.matches("127.0.*.1") |
Enable or disable a custom alert
You can enable or disable an existing custom alert in the following ways:
- from the Overview page of the custom alert
- from the Alert tab listing all your custom alerts (use this option to batch enable/disable multiple alerts at the same time)
To enable or disable an existing alert from its Overview page, follow these steps:
- In the Scaleway console (External link) side menu, go to Monitoring > Audit Trail.
- Click the Region dropdown and select the region where the alert has been created.
- Click the Alerts tab, then click Custom.
- Click more icon next to the alert that you want to enable/disable and select More info. The Overview page of the alert opens.
- Go to the Manage alert section and use the toggle to enable or disable your alert.
To enable or disable one or more existing alerts, use the Alert tab listing all your custom alerts:
- In the Scaleway console (External link) side menu, go to Monitoring > Audit Trail.
- Click the Region dropdown and select the region where the alert has been created.
- Click the Alerts tab, then click Custom.
- Check or uncheck Enabled to enable or disable your alert(s).
- Click Save changes at the bottom of the page to apply your configuration. A dialog box appears, confirming the action you are about to take. Click Save changes again.
Duplicate a custom alert to another region
- In the Scaleway console (External link) side menu, go to Monitoring > Audit Trail.
- Click the Region dropdown and select the region where the alert has been created.
- Click the Alerts tab, then click Custom.
- Click more icon next to the alert that you want to enable/disable and select Duplicate to other region(s). A dialog box opens.
- Review the details of the alert, select the Destination region, and click Duplicate.
Delete a custom alert
- In the Scaleway console (External link) side menu, go to Monitoring > Audit Trail.
- Click the Region dropdown and select the region where the alert has been created.
- Click the Alerts tab, then click Custom.
- Click more icon next to the alert that you want to delete and select Delete. A dialog box opens.
- Type
DELETEand click Delete alert to confirm the deletion of your alert.
Configure email address to receive notifications
The Alerting Management feature is linked to the notification manager. The email address set in the notification manager is where you will receive notifications when alerts are triggered.
For details on how to configure email addresses and notifications, see the related notification manager documentation.
Email notifications contain:
- details of the alert, such as:
- name of the alert
- time when the alert was triggered
- behavior detected
- severity
- recommended actions to help you with investigation and mitigation steps
- a link to check the Audit Trail page in the console
Related documentation
- Learn more about how to view your Audit Trail events.
- Learn how to activate preconfigured alerts.