Skip to main content
Alert rules trigger notifications whenever Argus detects a condition matching the rule’s criteria — for example, a new issue being created or an error rate crossing a threshold. You configure each rule with at least one delivery channel: an email address, a webhook URL, or both. You can create multiple rules per project to route notifications to different people or services.

Authentication

All alert endpoints require an active session. Requests without a valid session cookie return 401 Unauthorized.

List Alert Rules

Retrieve all alert rules configured for a project, ordered by creation date descending.

Path Parameters

projectId
string
required
The ID of the project whose alert rules you want to list.

Example Request

Example Response


Create an Alert Rule

Add a new alert rule to a project. You must provide at least one delivery channel (notifyEmail or webhookUrl).

Path Parameters

projectId
string
required
The ID of the project to add the alert rule to.

Request Body

name
string
required
A descriptive name for the alert rule, e.g. "Notify on-call for new errors".
type
string
The trigger condition. Accepted values:
  • NEW_ISSUE — fires when a new unique issue is first seen. This is the default.
  • ERROR_RATE — fires when the error rate exceeds a threshold within a time window. Requires threshold and windowMinutes.
Defaults to NEW_ISSUE.
notifyEmail
string
The email address to send alert notifications to. Must be a valid email address. At least one of notifyEmail or webhookUrl is required.
webhookUrl
string
A URL to POST alert payloads to. Must be a valid URL. At least one of notifyEmail or webhookUrl is required.
threshold
integer
For ERROR_RATE rules only: the number of errors that must occur within windowMinutes to trigger the alert. Must be a positive integer.
windowMinutes
integer
For ERROR_RATE rules only: the rolling time window in minutes. Must be a positive integer.
enabled
boolean
Whether the rule is active. Defaults to true. Set to false to create a rule in a disabled state.

Example Request — Email notification on new issue

Example Request — Webhook on error rate spike

Example Response


Update an Alert Rule

Update any subset of fields on an existing alert rule. You only need to include the fields you want to change.

Path Parameters

projectId
string
required
The ID of the project the alert rule belongs to.
id
string
required
The ID of the alert rule to update.

Request Body

All fields are optional. Supply only the fields you want to change. The same field rules from Create an Alert Rule apply.

Example Request — Disable an alert

Example Response


Delete an Alert Rule

Permanently remove an alert rule from a project. This action is irreversible.

Path Parameters

projectId
string
required
The ID of the project the alert rule belongs to.
id
string
required
The ID of the alert rule to delete.

Example Request

Example Response

Response Codes

StatusMeaning
200Request succeeded.
201Alert rule created successfully.
400Validation error — check that at least one delivery channel is provided.
401Not authenticated — no valid session.
404Project or alert rule not found.