# alerts

> Alert rules.

Alert rules.

- **Type:** list of object
- **Since:** manifest v1

## Example

```yaml
alerts:
  - name: api-errors
    when: logs(service=api, level=error) > 20/min
    notify:
      - email:ops@example.co.uk
```

## Each entry

An alert rule.

## Fields

| Field | Type | What it does |
| --- | --- | --- |
| [`name`](/docs/manifest/alerts/name/) * | [name](/docs/manifest/#name) | Rule name. |
| [`when`](/docs/manifest/alerts/when/) * | string | Condition, e.g. |
| [`environment`](/docs/manifest/alerts/environment/) | [name](/docs/manifest/#name) | Environment the rule applies to. |
| [`notify`](/docs/manifest/alerts/notify/) * | list of string | Where to send notifications. |

\* required
