---
title: "Create an alert"
description: "A rule (what to watch, the filter) times channels. mode instant sends each matching mention as it happens; daily sends one digest at schedule.hour in schedule.timezone; weekly sends one a week on schedule.weekday (0 Sunday to 6 Saturday)."
canonical: https://docs.mentio.dev/api/alerts/create-alert
markdown: https://docs.mentio.dev/api/alerts/create-alert.mdx
---

# Create an alert

`POST /v1/alerts`

A rule (what to watch, the filter) times channels. mode instant sends each matching mention as it happens; daily sends one digest at schedule.hour in schedule.timezone; weekly sends one a week on schedule.weekday (0 Sunday to 6 Saturday).

## Body

- `name` (required): string
- `enabled`: boolean
- `mode`: string
- `filter`: object
- `schedule`: Required for daily and weekly alerts (weekly ones also need schedule.weekday).
- `event`: Custom event name for webhook payloads; null for the mode default.
- `channelIds`: Channel ids from GET /v1/channels.

## Responses

- 201: The created rule
- 400: A daily or weekly rule without a schedule (or a weekly one without a weekday), or an unknown channel
- 401: Missing or invalid API key

Full schemas: https://api.mentio.dev/v1/openapi.json. Conventions: https://docs.mentio.dev/conventions.mdx
