Skip to content
BleemeoBleemeo

Create a recording rule

POST
/v1/recordingrule/
curl --request POST \
--url https://example.com/v1/recordingrule/ \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{ "name": "example", "query": "example", "unit": 0, "agent_type": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "default_threshold_high_critical": 1, "default_threshold_high_warning": 1, "default_threshold_low_critical": 1, "default_threshold_low_warning": 1, "active": true, "deactivated_at": "2026-04-15T12:00:00Z" }'

Create a new recording rule.

A ModelSerializer that takes an additional fields argument that controls which fields should be displayed.

object
id
required
string format: uuid
account
required
string format: uuid
name
required
string
<= 100 characters
query
required
string
<= 1000 characters
unit
  • 0 - No unit
  • 1 - %
  • 2 - byte
  • 3 - bit
  • 4 - io/s
  • 5 - /s
  • 6 - second
  • 7 - Custom
  • 8 - day
  • 9 - °C
  • 10 - byte/s
  • 11 - bit/s
  • 12 - Hz
  • 13 - W
integer
>= -2147483648 <= 2147483647
Allowed values: 0 1 2 3 4 5 6 7 8 9 10 11 12 13
agent_type
string format: uuid
nullable
metric_resolution_second
required
integer
default_threshold_high_critical
Threshold high critical
number format: double
nullable
default_threshold_high_warning
Threshold high warning
number format: double
nullable
default_threshold_low_critical
Threshold low critical
number format: double
nullable
default_threshold_low_warning
Threshold low warning
number format: double
nullable
active
boolean
created_at
required
string format: date-time
deactivated_at
string format: date-time
nullable
Media typeapplication/json

A ModelSerializer that takes an additional fields argument that controls which fields should be displayed.

object
id
required
string format: uuid
account
required
string format: uuid
name
required
string
<= 100 characters
query
required
string
<= 1000 characters
unit
  • 0 - No unit
  • 1 - %
  • 2 - byte
  • 3 - bit
  • 4 - io/s
  • 5 - /s
  • 6 - second
  • 7 - Custom
  • 8 - day
  • 9 - °C
  • 10 - byte/s
  • 11 - bit/s
  • 12 - Hz
  • 13 - W
integer
>= -2147483648 <= 2147483647
Allowed values: 0 1 2 3 4 5 6 7 8 9 10 11 12 13
agent_type
string format: uuid
nullable
metric_resolution_second
required
integer
default_threshold_high_critical
Threshold high critical
number format: double
nullable
default_threshold_high_warning
Threshold high warning
number format: double
nullable
default_threshold_low_critical
Threshold low critical
number format: double
nullable
default_threshold_low_warning
Threshold low warning
number format: double
nullable
active
boolean
created_at
required
string format: date-time
deactivated_at
string format: date-time
nullable

Example

{
"unit": 0
}