custom_sender()) to send alerts from Netdata health checks to Flashduty On-call. Each alert on one chart of one host maps to one Flashduty alert: an escalation from WARNING to CRITICAL merges into it, and the CLEAR notification from Netdata recovers it.
This integration works with the open-source Netdata Agent, including Docker deployments and Parent/Child streaming setups. It needs neither a Netdata Cloud account nor a paid plan.
In Flashduty On-call
You can obtain an integration push URL in either of the following ways.
Use a dedicated integration
Choose this method when you do not need to route alerts to different channels.Expand
Expand
- In the Flashduty console, select Channel and open a channel
- Select Configuration → Integrations → Private integration, then click Add an integration
- Select Netdata, then click Save
- Open the generated integration card and copy the Push URL
Use a shared integration
Choose this method when you need to route alerts to different channels based on the payload.Expand
Expand
- In the Flashduty console, select Integration Center → Alert Events
- Select Netdata and enter an integration name
- Configure the default route and select a channel; after creation, add more rules under Route if needed
- Click Save and copy the generated Push URL
Prerequisites
- Network: the host running the Netdata Agent must be able to reach the Flashduty push URL (for example
https://api.flashcat.cloud). - curl: the notification script sends requests with
curl. The official Netdata packages and Docker image already include it. - Permissions: you need to be able to edit files in the Netdata configuration directory (usually
/etc/netdata).
In Netdata
1
Open the notification configuration file
Go to the Netdata configuration directory and open For a Docker deployment, enter the container first and run the same commands:
health_alarm_notify.conf with edit-config:2
Add the Flashduty notification
Append the template below to the end of the file, replace
FLASHDUTY_PUSH_URL with the full push URL of your Flashduty integration (including the integration_key parameter), and save the file.- Appending to the end of the file overrides the
custom_sender()function and variables of the same name in the default configuration. DEFAULT_RECIPIENT_CUSTOMroutes alerts for every role (sysadmin,webmaster,dba, and so on) to this notification. The value is not sent to Flashduty; any non-empty string works.- Each field is encoded separately with
--data-urlencode, so quotes, spaces, and non-ASCII text in alert descriptions do not break the request.
3
Send a test notification
Run the test command that ships with Netdata as the For a Docker deployment:For a static installation (
netdata user:/opt/netdata), the script is at /opt/netdata/usr/libexec/netdata/plugins.d/alarm-notify.sh.The test command sends WARNING, CRITICAL, and CLEAR notifications in turn. When each prints # OK, the push URL and integration key are correct. Flashduty recognizes these as test notifications (alert test_alarm on chart test.chart) and only returns success without creating an alert.Alert Key
Flashduty builds the Alert Key from the
host, chart, and alarm fields.
hostis the host name that raised the alert. When a Parent node evaluates alerts for a Child node,hostis the Child’s host name.chartis the chart instance of the alert, for exampledisk_space./ordisk_space./data. When one alert template applies to several mount points, network interfaces, or containers, eachchartproduces its own alert.alarmis the alert name, that is, thealarmortemplatevalue in thehealth.dconfiguration.
alarm_id in Netdata notifications is unique only within one Agent (the test command, for example, sends alarm_id 1 on every Agent), so Flashduty does not use it.
Status and severity
Netdata sends notifications only for the WARNING, CRITICAL, and CLEAR states.
When an alert rises from WARNING to CRITICAL, Flashduty opens a new Critical alert and keeps the Warning alert open. When it drops from CRITICAL to WARNING, the event merges into the existing Critical alert. The CLEAR notification closes both.
Netdata sends CLEAR only when an alert changes from WARNING or CRITICAL to CLEAR.
Labels
The alert title is
<host>: <summary>. Older Netdata versions that do not send summary use the alert name instead.
FAQ
Is the Netdata Cloud webhook notification supported?
Is the Netdata Cloud webhook notification supported?
No. The Netdata Cloud webhook notification requires a Space on a paid plan, and its alert notifications carry no node (host) field, so alerts with the same name and chart on different hosts cannot be told apart. Flashduty rejects such requests with
missing host. Configure the custom notification on this page on each Agent (or on the Parent node) instead.If both Parent and Child run health checks, do I get duplicate alerts?
If both Parent and Child run health checks, do I get duplicate alerts?
The same alert sent by the Parent and the Child has the same
host, chart, and alarm, so it merges into one Flashduty alert rather than creating two. To reduce the number of notifications, enable alert notifications on the Parent only.What if the test command does not print # OK?
What if the test command does not print # OK?
HTTP error code 000: the host cannot connect to Flashduty. Check DNS, proxy, and firewall settingsHTTP error code 4xx: check thatFLASHDUTY_PUSH_URLis complete, theintegration_keyis correct, and thehost,chart,alarm, andstatusfields in the template are unchangedcustom_sender() is not configured: the template was not appended to the end of the file, or the file is not/etc/netdata/health_alarm_notify.conf
NETDATA_ALARM_NOTIFY_DEBUG=1 before the test command to see the full curl command and the response from Flashduty.What if an alert does not recover?
What if an alert does not recover?
Make sure the template keeps
status=${status} and old_status=${old_status}, and that the host, chart, and alarm fields are unchanged. If an alert’s role is set to silent in the Netdata alert configuration, none of its notifications, including CLEAR, are sent.After netdatacli reload-health or a Netdata restart, alerts are evaluated again from UNINITIALIZED. If the alert condition no longer holds at that point, Netdata moves straight to CLEAR without sending a notification, and you need to close the matching Flashduty alert by hand. Keep this in mind when you change the threshold of an active alert.