API reference / Operations by tag
automation
Automation rules, alerts, presets and run history.
17 operations. Base URL https://api.metrixed.com/v1; see authentication, errors and pagination.
Operations
| Method | Path | Summary |
|---|---|---|
| GET | /automation/alerts | List alerts (rules with kind=alert) |
| POST | /automation/alerts | Create alert |
| GET | /automation/catalog | Trigger kinds, action types, events, derived metrics, periods |
| GET | /automation/presets | Alert presets (cap near 90%, postback failure rate, CR drop, fraud spike) |
| POST | /automation/presets/{key}/apply | Create an alert from a preset; optional overrides name, value, cooldown_seconds, dry_run, actions |
| GET | /automation/rules | List AutomationRules |
| POST | /automation/rules | Create AutomationRule |
| GET | /automation/rules/{id} | Get AutomationRule |
| PATCH | /automation/rules/{id} | Update AutomationRule |
| DELETE | /automation/rules/{id} | Delete AutomationRule |
| GET | /automation/rules/{id}/runs | Run log of one rule |
| POST | /automation/rules/bulk/apply | Bulk edit apply |
| POST | /automation/rules/bulk/preview | Bulk edit preview |
| POST | /automation/rules/search | Search AutomationRules (advanced) |
| GET | /automation/runs | Run log across rules |
| GET | /automation/scheduled-actions | List scheduled actions (one-shot or cron) |
| POST | /automation/scheduled-actions | Create scheduled action |
GET /automation/alerts
List alerts (rules with kind=alert)
Operation getAutomationAlerts. Auth: API key (Bearer) or session cookie.
| Parameter | In | Type | Required | Description |
|---|---|---|---|---|
page | query | integer | no | |
page_size | query | integer | no | |
sort | query | string | no | field or -field |
include | query | string | no | comma-separated relationships |
filter | query | object (free-form) | no | |
q | query | string | no | free-text search |
| Status | Description | Body |
|---|---|---|
| 200 | ok | application/json AutomationRuleList |
| default | error | application/json Error |
curl 'https://api.metrixed.com/v1/automation/alerts?page=1&page_size=50' \
-H "Authorization: Bearer $DT_API_KEY" \
-H 'Accept: application/json'
Example 200 response:
{
"data": [
{}
],
"page": {}
}
POST /automation/alerts
Create alert
Operation postAutomationAlerts. Auth: API key (Bearer) or session cookie.
Request body (application/json, required): AutomationRuleCreate
| Field | Type | Flags | Description |
|---|---|---|---|
name | string | required | |
description | string | ||
kind | enum: rule, alert, scheduled_action | ||
trigger_kind | enum: metric_threshold, event, schedule, once | required | |
trigger | object (free-form) | metric_threshold: entity, metric, op, value, period, compare_to, denominator_metric, min_denominator, entity_ids | event: event, filters | schedule: cron, timezone | |
conditions | array of object (free-form) | ||
actions | array of object (free-form) | required | |
cooldown_seconds | integer | ||
dry_run | boolean | ||
status | enum: active, paused, done | ||
run_at | string (date-time) | ||
preset | string |
| Status | Description | Body |
|---|---|---|
| 201 | ok | application/json AutomationRule |
| default | error | application/json Error |
curl -X POST 'https://api.metrixed.com/v1/automation/alerts' \
-H "Authorization: Bearer $DT_API_KEY" \
-H 'Accept: application/json' \
-H 'Content-Type: application/json' \
--data-raw '{"name":"","trigger_kind":"metric_threshold","actions":[{}]}'
Example 201 response:
{
"external_ref": ""
}
GET /automation/catalog
Trigger kinds, action types, events, derived metrics, periods
Operation getAutomationCatalog. Auth: API key (Bearer) or session cookie.
curl 'https://api.metrixed.com/v1/automation/catalog' \
-H "Authorization: Bearer $DT_API_KEY" \
-H 'Accept: application/json'
Example 200 response:
{
"ok": false
}
GET /automation/presets
Alert presets (cap near 90%, postback failure rate, CR drop, fraud spike)
Operation getAutomationPresets. Auth: API key (Bearer) or session cookie.
curl 'https://api.metrixed.com/v1/automation/presets' \
-H "Authorization: Bearer $DT_API_KEY" \
-H 'Accept: application/json'
Example 200 response:
{
"ok": false
}
POST /automation/presets/{key}/apply
Create an alert from a preset; optional overrides name, value, cooldown_seconds, dry_run, actions
Operation postAutomationPresetsKeyApply. Auth: API key (Bearer) or session cookie.
| Parameter | In | Type | Required | Description |
|---|---|---|---|---|
key | path | string | yes |
| Status | Description | Body |
|---|---|---|
| 201 | ok | application/json AutomationRule |
| default | error | application/json Error |
curl -X POST 'https://api.metrixed.com/v1/automation/presets/<key>/apply' \
-H "Authorization: Bearer $DT_API_KEY" \
-H 'Accept: application/json'
Example 201 response:
{
"external_ref": ""
}
GET /automation/rules
List AutomationRules
Operation getAutomationRules. Auth: API key (Bearer) or session cookie.
| Parameter | In | Type | Required | Description |
|---|---|---|---|---|
page | query | integer | no | |
page_size | query | integer | no | |
sort | query | string | no | field or -field |
include | query | string | no | comma-separated relationships |
filter | query | object (free-form) | no | |
q | query | string | no | free-text search |
| Status | Description | Body |
|---|---|---|
| 200 | ok | application/json AutomationRuleList |
| default | error | application/json Error |
curl 'https://api.metrixed.com/v1/automation/rules?page=1&page_size=50' \
-H "Authorization: Bearer $DT_API_KEY" \
-H 'Accept: application/json'
Example 200 response:
{
"data": [
{}
],
"page": {}
}
POST /automation/rules
Create AutomationRule
Operation postAutomationRules. Auth: API key (Bearer) or session cookie.
Request body (application/json, required): AutomationRuleCreate
| Field | Type | Flags | Description |
|---|---|---|---|
name | string | required | |
description | string | ||
kind | enum: rule, alert, scheduled_action | ||
trigger_kind | enum: metric_threshold, event, schedule, once | required | |
trigger | object (free-form) | metric_threshold: entity, metric, op, value, period, compare_to, denominator_metric, min_denominator, entity_ids | event: event, filters | schedule: cron, timezone | |
conditions | array of object (free-form) | ||
actions | array of object (free-form) | required | |
cooldown_seconds | integer | ||
dry_run | boolean | ||
status | enum: active, paused, done | ||
run_at | string (date-time) | ||
preset | string |
| Status | Description | Body |
|---|---|---|
| 201 | ok | application/json AutomationRule |
| default | error | application/json Error |
curl -X POST 'https://api.metrixed.com/v1/automation/rules' \
-H "Authorization: Bearer $DT_API_KEY" \
-H 'Accept: application/json' \
-H 'Content-Type: application/json' \
--data-raw '{"name":"","trigger_kind":"metric_threshold","actions":[{}]}'
Example 201 response:
{
"external_ref": ""
}
GET /automation/rules/{id}
Get AutomationRule
Operation getAutomationRulesId. Auth: API key (Bearer) or session cookie.
| Parameter | In | Type | Required | Description |
|---|---|---|---|---|
id | path | string | yes |
| Status | Description | Body |
|---|---|---|
| 200 | ok | application/json AutomationRule |
| default | error | application/json Error |
curl 'https://api.metrixed.com/v1/automation/rules/<id>' \
-H "Authorization: Bearer $DT_API_KEY" \
-H 'Accept: application/json'
Example 200 response:
{
"external_ref": ""
}
PATCH /automation/rules/{id}
Update AutomationRule
Operation patchAutomationRulesId. Auth: API key (Bearer) or session cookie.
| Parameter | In | Type | Required | Description |
|---|---|---|---|---|
id | path | string | yes |
Request body (application/json, required): AutomationRuleUpdate
| Field | Type | Flags | Description |
|---|---|---|---|
name | string | ||
description | string | ||
kind | enum: rule, alert, scheduled_action | ||
trigger_kind | enum: metric_threshold, event, schedule, once | ||
trigger | object (free-form) | metric_threshold: entity, metric, op, value, period, compare_to, denominator_metric, min_denominator, entity_ids | event: event, filters | schedule: cron, timezone | |
conditions | array of object (free-form) | ||
actions | array of object (free-form) | ||
cooldown_seconds | integer | ||
dry_run | boolean | ||
status | enum: active, paused, done | ||
run_at | string (date-time) | ||
preset | string |
| Status | Description | Body |
|---|---|---|
| 200 | ok | application/json AutomationRule |
| default | error | application/json Error |
curl -X PATCH 'https://api.metrixed.com/v1/automation/rules/<id>' \
-H "Authorization: Bearer $DT_API_KEY" \
-H 'Accept: application/json' \
-H 'Content-Type: application/json' \
--data-raw '{"name":"","description":"","kind":"rule","trigger_kind":"metric_threshold"}'
Example 200 response:
{
"external_ref": ""
}
DELETE /automation/rules/{id}
Delete AutomationRule
Operation deleteAutomationRulesId. Auth: API key (Bearer) or session cookie.
| Parameter | In | Type | Required | Description |
|---|---|---|---|---|
id | path | string | yes |
curl -X DELETE 'https://api.metrixed.com/v1/automation/rules/<id>' \
-H "Authorization: Bearer $DT_API_KEY" \
-H 'Accept: application/json'
Example 204 response:
{
"ok": false
}
GET /automation/rules/{id}/runs
Run log of one rule
Operation getAutomationRulesIdRuns. Auth: API key (Bearer) or session cookie.
| Parameter | In | Type | Required | Description |
|---|---|---|---|---|
id | path | string | yes | |
page | query | integer | no | |
page_size | query | integer | no | |
sort | query | string | no | field or -field |
include | query | string | no | comma-separated relationships |
filter | query | object (free-form) | no | |
q | query | string | no | free-text search |
| Status | Description | Body |
|---|---|---|
| 200 | ok | application/json LogSearchResult |
| default | error | application/json Error |
curl 'https://api.metrixed.com/v1/automation/rules/<id>/runs?page=1&page_size=50' \
-H "Authorization: Bearer $DT_API_KEY" \
-H 'Accept: application/json'
Example 200 response:
{
"rows": [
{}
],
"next_cursor": "",
"has_more": false
}
POST /automation/rules/bulk/apply
Bulk edit apply
Operation postAutomationRulesBulkApply. Auth: API key (Bearer) or session cookie.
Request body (application/json, required): BulkPatch
| Field | Type | Flags | Description |
|---|---|---|---|
ids | array of string | required | |
patches | array of object | required |
| Status | Description | Body |
|---|---|---|
| 200 | ok | application/json BulkPreview |
| default | error | application/json Error |
curl -X POST 'https://api.metrixed.com/v1/automation/rules/bulk/apply' \
-H "Authorization: Bearer $DT_API_KEY" \
-H 'Accept: application/json' \
-H 'Content-Type: application/json' \
--data-raw '{"ids":[""],"patches":[{"field":"","value":{}}]}'
Example 200 response:
{
"affected": 0,
"changes": [
{}
],
"warnings": [
""
],
"token": ""
}
POST /automation/rules/bulk/preview
Bulk edit preview
Operation postAutomationRulesBulkPreview. Auth: API key (Bearer) or session cookie.
Request body (application/json, required): BulkPatch
| Field | Type | Flags | Description |
|---|---|---|---|
ids | array of string | required | |
patches | array of object | required |
| Status | Description | Body |
|---|---|---|
| 200 | ok | application/json BulkPreview |
| default | error | application/json Error |
curl -X POST 'https://api.metrixed.com/v1/automation/rules/bulk/preview' \
-H "Authorization: Bearer $DT_API_KEY" \
-H 'Accept: application/json' \
-H 'Content-Type: application/json' \
--data-raw '{"ids":[""],"patches":[{"field":"","value":{}}]}'
Example 200 response:
{
"affected": 0,
"changes": [
{}
],
"warnings": [
""
],
"token": ""
}
POST /automation/rules/search
Search AutomationRules (advanced)
Operation postAutomationRulesSearch. Auth: API key (Bearer) or session cookie.
Request body (application/json, required): SearchRequest
| Field | Type | Flags | Description |
|---|---|---|---|
filters | array of object | ||
search | string | ||
sort | array of object (free-form) | ||
page | integer | ||
page_size | integer | ||
include | array of string |
| Status | Description | Body |
|---|---|---|
| 200 | ok | application/json AutomationRuleList |
| default | error | application/json Error |
curl -X POST 'https://api.metrixed.com/v1/automation/rules/search' \
-H "Authorization: Bearer $DT_API_KEY" \
-H 'Accept: application/json' \
-H 'Content-Type: application/json' \
--data-raw '{"filters":[{}],"search":"","sort":[{}],"page":0}'
Example 200 response:
{
"data": [
{}
],
"page": {}
}
GET /automation/runs
Run log across rules
Operation getAutomationRuns. Auth: API key (Bearer) or session cookie.
| Parameter | In | Type | Required | Description |
|---|---|---|---|---|
page | query | integer | no | |
page_size | query | integer | no | |
sort | query | string | no | field or -field |
include | query | string | no | comma-separated relationships |
filter | query | object (free-form) | no | |
q | query | string | no | free-text search |
| Status | Description | Body |
|---|---|---|
| 200 | ok | application/json LogSearchResult |
| default | error | application/json Error |
curl 'https://api.metrixed.com/v1/automation/runs?page=1&page_size=50' \
-H "Authorization: Bearer $DT_API_KEY" \
-H 'Accept: application/json'
Example 200 response:
{
"rows": [
{}
],
"next_cursor": "",
"has_more": false
}
GET /automation/scheduled-actions
List scheduled actions (one-shot or cron)
Operation getAutomationScheduledActions. Auth: API key (Bearer) or session cookie.
| Parameter | In | Type | Required | Description |
|---|---|---|---|---|
page | query | integer | no | |
page_size | query | integer | no | |
sort | query | string | no | field or -field |
include | query | string | no | comma-separated relationships |
filter | query | object (free-form) | no | |
q | query | string | no | free-text search |
| Status | Description | Body |
|---|---|---|
| 200 | ok | application/json AutomationRuleList |
| default | error | application/json Error |
curl 'https://api.metrixed.com/v1/automation/scheduled-actions?page=1&page_size=50' \
-H "Authorization: Bearer $DT_API_KEY" \
-H 'Accept: application/json'
Example 200 response:
{
"data": [
{}
],
"page": {}
}
POST /automation/scheduled-actions
Create scheduled action
Operation postAutomationScheduledActions. Auth: API key (Bearer) or session cookie.
Request body (application/json, required): AutomationRuleCreate
| Field | Type | Flags | Description |
|---|---|---|---|
name | string | required | |
description | string | ||
kind | enum: rule, alert, scheduled_action | ||
trigger_kind | enum: metric_threshold, event, schedule, once | required | |
trigger | object (free-form) | metric_threshold: entity, metric, op, value, period, compare_to, denominator_metric, min_denominator, entity_ids | event: event, filters | schedule: cron, timezone | |
conditions | array of object (free-form) | ||
actions | array of object (free-form) | required | |
cooldown_seconds | integer | ||
dry_run | boolean | ||
status | enum: active, paused, done | ||
run_at | string (date-time) | ||
preset | string |
| Status | Description | Body |
|---|---|---|
| 201 | ok | application/json AutomationRule |
| default | error | application/json Error |
curl -X POST 'https://api.metrixed.com/v1/automation/scheduled-actions' \
-H "Authorization: Bearer $DT_API_KEY" \
-H 'Accept: application/json' \
-H 'Content-Type: application/json' \
--data-raw '{"name":"","trigger_kind":"metric_threshold","actions":[{}]}'
Example 201 response:
{
"external_ref": ""
}