# Alerts

> Choose which backup problems Clokeep reports, how serious each one is, and who hears about it on which channel.

Clokeep raises an alert when a backup fails, when a plan stops producing backups, or when an agent or a storage stops responding.

## Prerequisites

- The Admin role, to change the **Alerts** page. Every member sets their own alerts on their profile.

## The events

| Event | Raised when | Default severity |
| --- | --- | --- |
| **Backup run failed** | A backup run ends **Failed**. | Warning |
| **Backup partially failed** | A backup run ends **Partially completed**. | Warning |
| **Restore failed** | A restore run ends **Failed**, or a [restore batch](/docs/restores/bulk-restore) ends with failed or skipped accounts. A batch sends one alert, not one per account. | Critical |
| **Backup overdue** | The hourly check finds a plan with no successful backup in time for its schedule. | Critical |
| **Agent offline** | The hourly check finds an agent that stopped checking in. | Warning |
| **Storage unreachable** | The hourly connection test of an active storage fails. | Warning |
| **Backup missing from storage** | The hourly check finds a backup gone from its storage. | Critical |
| **Removed account backup released soon** | About a week before the last backup of a hosting account removed from Plesk or cPanel stops being kept. Sent once per account. Not sent while every plan holding the account's backups keeps all backups. See [Removed hosting accounts](/docs/backups/schedules-retention#removed-hosting-accounts). | Warning |

A run that you stop raises no alert. **Agent offline** is raised only for an **Active** server whose agent has checked in at least once.

## Who receives an alert

An alert goes to two kinds of destination:

- **Members** of your client. Every Admin receives alerts unless they switch them off. Operators and Viewers receive them once they switch them on. Roles are on [Users and roles](/docs/access/users-roles), and a Customer's alerts on [Client portal access](/docs/access/client-portal#alerts-for-a-customer).
- **Shared destinations** set on the **Alerts** page: extra email addresses, a Discord channel, and an SMS or Viber number when Clokeep has switched those on for your client.

Each member and each destination has a minimum severity. An alert reaches them only if its severity is at least that.

Clokeep has no webhook for your own tools: the Discord **Webhook URL** is the only one it takes. To follow runs from a script, use the API. See [Run a backup through the API](/docs/developers/run-backup).

## Set up the shared destinations

<Steps>
<Step title="Open the Alerts page">
As an Admin, open **Settings** and choose **Alerts**.
</Step>
<Step title="Choose the channels">
- **Send alerts** is the master switch. When it is off, nothing is delivered on any channel.
- Under **Email**, **Enabled** sends alerts by email. **Minimum severity** filters them, and **Additional recipients** takes shared mailboxes or an on-call alias. With **Enabled** off, members get no alert emails either.
- Under **Discord**, switch on **Enabled** and paste the channel's **Webhook URL**. It is stored encrypted: leave it blank later to keep it.
- **SMS** and **Viber** sections appear only when Clokeep has switched them on for your client. Each takes an **On-call number** in international format, starting with `+`.
</Step>
<Step title="Save and test">
Click **Save changes**. Then click **Send test alert**. It sends an Info test alert to every channel that is switched on and has a destination, whatever its minimum severity. Members' own channels do not receive it.

While **Send alerts** is off, the test sends nothing either. A **Nothing was sent** message says "Alerts are switched off. Turn on Send alerts and save, then send the test again."
</Step>
</Steps>

## Set how serious each event is

Under **Events** on the **Alerts** page, each event has a severity: **Default** (the default in the table above), **Info**, **Warning** or **Critical**. Pick **Off** to never send that event. Click **Save changes**.

The severity decides who hears about the event. For example, an SMS number set to **Critical** receives **Backup overdue** but not **Backup run failed**, unless you raise that event to **Critical**.

## Choose your own alerts

Every member chooses for themselves:

<Steps>
<Step title="Open your profile">
Open the user menu at the top right and click **Profile**. Find the section **Alerts for** followed by your client's name.
</Step>
<Step title="Choose what you receive">
- **Send me backup alerts**: on by default for Admins.
- **Notify me about**: **Warning and above** by default.
- **Channels**: **Email** by default. **SMS** and **Viber** need a number in the field below. A greyed-out channel is not enabled on the **Alerts** page or not switched on for your client.
</Step>
<Step title="Save">
Click **Save changes**.
</Step>
</Steps>

## When a plan is overdue

Every hour, Clokeep checks each plan that is enabled, has a schedule and runs on an **Active** server. A plan is overdue once its schedule has come due twice since its last successful backup. One missed run is tolerated, and the second raises **Backup overdue**.

For example, a plan runs daily at 02:00. Its last successful backup finished on Monday at 02:10, and Tuesday's run failed. From Wednesday 02:00, the plan is overdue.

- Only **Completed** and **Partially completed** runs count as successful. Failed and cancelled runs do not.
- The schedule's own **Timezone** applies.
- A new plan is not flagged before its schedule has come due twice since you created it.

The check looks for missing backups, not for failures. It catches an agent that stopped, a storage that refuses uploads and runs that keep failing alike.

## Repeated alerts

While a problem lasts, each hourly check finds it again. Clokeep does not repeat the alert every time: it waits before sending it again, and waits less for more severe alerts. Each failed run raises its own alert. When a problem clears and later comes back, you hear about it at once.

## Next steps

<CardGroup cols="2">
<Card title="Run and stop a backup" href="/docs/backups/run-stop" icon="play">
Open a failed run and read its logs.
</Card>
<Card title="Browse a backup" href="/docs/restores/browse" icon="book">
Open a backup and see what it holds before you restore it.
</Card>
</CardGroup>
