latestOpenAPI 3.0.3raw.githubusercontent.com2026-08-207311,8115.6 MB

c36ed1cbdbb5

alerting-v2

Create a rule

Spaces method and path for this operation:

<div><span class="operation-verb post">post</span>&nbsp;<span class="operation-path">/s/{space_id}/api/alerting/v2/rules</span></div>

Refer to Spaces for more information.

Creates a rule with a server-generated identifier. To create or replace a rule with a client-supplied identifier, use PUT /api/alerting/v2/rules/.<br/><br/>[Required authorization] Route required privileges: manage_alerting-v2-rules.

post/api/alerting/v2/rules

Headers

kbn-xsrfstring required
Example:true

A required header to protect against CSRF attacks

Request body

time_fieldstring

Time field used for the lookback window range filter.

Response

Returns the newly created rule.

created_atstring required

ISO timestamp when the rule was created.

created_bystring nullable required

User who created the rule.

enabledboolean required

Whether the rule is enabled.

idstring required

Unique rule identifier.

time_fieldstring

Time field used for the lookback window range filter.

updated_atstring required

ISO timestamp when the rule was last updated.

updated_bystring nullable required

User who last updated the rule.

versionstring

The saved object version token of the rule, used for optimistic concurrency control.