create_by 写入当前 client_key。X-Client-Key: ********************X-Timestamp: ********************X-Sign: ********************{
"title": "Database CPU High",
"detail": "CPU usage remains above 90% for 10 minutes",
"severity": "S0",
"service_id": "svc_1",
"assign": {
"type": "1",
"value": ""
},
"labels": [
{
"label_id": "label_env",
"label_value": "prod"
}
],
"attachments": [
{
"url": "https://example.com/screenshot.png",
"name": "screenshot"
}
],
"source": "openapi"
}curl --location --request POST '/api/incident/create' \
--header 'X-Client-Key: <api-key>' \
--header 'X-Timestamp: <api-key>' \
--header 'X-Sign: <api-key>' \
--header 'Content-Type: application/json' \
--data-raw '{
"title": "Database CPU High",
"detail": "CPU usage remains above 90% for 10 minutes",
"severity": "S0",
"service_id": "svc_1",
"assign": {
"type": "1",
"value": ""
},
"labels": [
{
"label_id": "label_env",
"label_value": "prod"
}
],
"attachments": [
{
"url": "https://example.com/screenshot.png",
"name": "screenshot"
}
],
"source": "openapi"
}'{
"code": 0,
"msg": "OK",
"data": {
"incident_id": "string"
}
}