告警与响应相关接口/告警模板
PUTAlerting起始版本 1.0同步需要认证
更新告警模板
更新消息模板名称内容。
调试可用性
在线调试
使用当前认证信息和示例参数提交 Mock 请求。
路径参数
请求参数
路径参数
templateIdString必填模板ID。
请求体字段
nameString必填资源名称。
示例: Updated Template
contentString必填新模板内容。
示例: # Updated: {{.AlertName}}
响应状态
请求地址
PUT/api/v1/alerting/templates/{templateId}
/api/v1/alerting/templates/{templateId}
请求示例
curl -X PUT '{host}/api/v1/alerting/templates/{templateId}' -H 'Authorization: Bearer {token}' -H 'Content-Type: application/json' -d '{"name":"Updated Template","content":"# Updated: {{.AlertName}}"}'
响应示例
200{
"uuid": "tmpl-001",
"name": "Default Email Template",
"format": "markdown",
"content": "# Alert: {{.AlertName}}",
"source": "builtin",
"createDate": "example",
"lastOpDate": "example"
}变更历史
此 API 暂无变更历史记录。
