Skip to content
You're viewing documentation for v2026.11.8-beta. It may be out of date.Go to latest
TimescaleDB Enterprise
Esc
↑↓navigate↵open⌘Jpreview

Change global alert rules

Partial: only the listed rules and the fields present change. Null resets a severity or a threshold to its default. The values that result for each service must be valid, else 400 names the service. Regenerates and reloads the rule file, so a change takes effect immediately.

PUT/api/v1/alert-rules
Authorization
tse_sessionAPI key · cookierequired
Request body
requiredapplication/json
rulesAlertRuleUpdate[]required
Show properties
Array of AlertRuleUpdate
enabledboolean | null

Omit to keep; null resets to the default (on)

namestringrequired
severitystring | null

Omit to keep; null resets to the rule default

Allowed:warningcritical
thresholdinteger<int64> | null

Omit to keep; null resets to the default

Responses
200

OK

rulesAlertRuleSetting[]required
Show properties
Array of AlertRuleSetting
configurablebooleanrequired

False for the heartbeat

defaultSeveritystringrequired

warning or critical; empty for the heartbeat

enabledbooleanrequired
groupstringrequired
Allowed:infrastructuredatabaseconsole
namestringrequired
scopestringrequired

service rules can be overridden per database service

Allowed:serviceconsole
severitystringrequired

The global severity; empty for the heartbeat

summarystringrequired
thresholdAlertRuleThreshold | nullrequired

null when the rule has no threshold

Show properties
Any of:
AlertRuleThreshold
defaultinteger<int64>required

The shipped default

labelstringrequired

What the number means

maxinteger<int64>required
mininteger<int64>required
unitstringrequired
Allowed:percenthourssecondsdays
valueinteger<int64>required

The global value

null
null
default

Error

codestring

Stable code of the refusal, when the route has codes

detailsstring[]

Additional detail, e.g. per-field validation failures

errorstringrequired

Human-readable error message

Request
curl -X PUT 'https://console.example.com/api/v1/alert-rules' \
  -H 'Cookie: tse_session=YOUR_API_KEY' \
  -H 'Accept: application/json' \
  -H 'Content-Type: application/json' \
  -d '{
  "rules": [
    {
      "enabled": true,
      "name": "string",
      "severity": "warning",
      "threshold": 0
    }
  ]
}'
Response
{
  "rules": [
    {
      "configurable": true,
      "defaultSeverity": "string",
      "enabled": true,
      "group": "infrastructure",
      "name": "string",
      "scope": "service",
      "severity": "string",
      "summary": "string",
      "threshold": {
        "default": 0,
        "label": "string",
        "max": 0,
        "min": 0,
        "unit": "percent",
        "value": 0
      }
    }
  ]
}