Skip to main content
POST
Create Alert Rule

Authorizations

x-api-key
string
header
required

API key for authentication. Generate API keys from the RevRing dashboard.

Body

application/json

Create an alert rule. Needs webhookUrl, slackWebhookUrl or both.

name
string
required
Maximum string length: 100
metric
enum<string>
required

What to watch. See Alerts.

Available options:
call_failure_rate,
evaluation_fail_rate,
negative_sentiment_rate,
tool_error_rate,
webhook_failure_rate,
call_count
threshold
number
required

Percent (0-100) for rates; a number of calls for call_count

agentId
string | null

Only this agent's calls; null for all agents

comparator
enum<string>
default:above
Available options:
above,
below
windowMinutes
enum<integer>
default:60
Available options:
15,
60,
240,
1440
minCalls
integer
default:10

Rates are only judged with at least this many calls in the window

Required range: x >= 1
webhookUrl
string<uri> | null

https endpoint for JSON notifications (signed when you have a signing secret)

slackWebhookUrl
string<uri> | null

Slack incoming webhook URL (https://hooks.slack.com/...)

enabled
boolean
default:true

Response

Created

data
object