跳转到主要内容
SLO 与服务质量相关接口/SLO
POSTSLO起始版本 1.0同步需要认证

创建预算告警

创建燃烧速率告警配置SLO目标。

调试可用性

在线调试

使用当前认证信息和示例参数提交 Mock 请求。

路径参数

请求参数

路径参数

  • sloIdString必填

    SLO唯一标识。

请求体字段

  • configObject必填

    配置信息。

    • idString

      资源ID。

      示例: alert-cfg-001

    • sloIdString

      SLO唯一标识。

      示例: slo-xyz789

    • consumedPctThresholdLong

      已使用比例阈值。

      示例: 80

    • severityString

      告警级别。

      示例: warning

    • notificationChannelsList

      通知渠道列表。

      示例: item1,item2

响应状态

200 OK

该 API 成功时返回以下响应结构。

  • idString

    资源ID。

    示例: alert-cfg-001

  • sloIdString

    SLO唯一标识。

    示例: slo-xyz789

  • consumedPctThresholdLong

    已使用比例阈值。

    示例: 80

  • severityString

    告警级别。

    示例: warning

  • notificationChannelsList

    通知渠道列表。

    示例: item1,item2

请求地址

POST/api/v1/slo/objectives/{sloId}/budget-alerts

/api/v1/slo/objectives/{sloId}/budget-alerts

操作 ID

CreateBudgetAlert

永久链接

请求示例

curl -X POST '{host}/api/v1/slo/objectives/{sloId}/budget-alerts' -H 'Authorization: Bearer {token}' -H 'Content-Type: application/json' -d '{"config":{"id":"alert-cfg-001","sloId":"slo-xyz789","consumedPctThreshold":80.0,"severity":"warning","notificationChannels":"item1,item2"}}'

响应示例

200
{
  "id": "alert-cfg-001",
  "sloId": "slo-xyz789",
  "consumedPctThreshold": 80.0,
  "severity": "warning",
  "notificationChannels": []
}

变更历史

此 API 暂无变更历史记录。

查看全部变更历史