Platform O&M/Cloud Monitoring/Monitoring and Alarm/SNS/ZWatch Operations/Alarm Operations
PUTAlarm OperationsSince 2.3SynchronousAuth Required
ChangeAlarmState
ChangeAlarmState
Execution Availability
Try It Out
Submit a mock request using the current auth context and example-driven inputs.
Path Parameters
Request Inputs
Path Parameters
uuidStringRequiredThe resource UUID.
Body Fields
changealarmstateObjectRequiredchangealarmstate request body object.
stateEventStringRequiredThe state event.
systemTagsListOptional. The system tags.
userTagsListOptional. The user tags.
Responses
Endpoint
PUT/zstack/v1/zwatch/alarms/{uuid}/actions
/zstack/v1/zwatch/alarms/{uuid}/actions
Request Example
curl -X PUT 'http://{host}/zstack/v1/zwatch/alarms/{uuid}/actions' -H 'Authorization: OAuth {sessionUuid}' -H 'Content-Type: application/json;charset=UTF-8' -d '{"changealarmstate":{"stateEvent":"<stateEvent>"},"systemTags":["<systemTags>"],"userTags":["<userTags>"]}'
Response Example
200{ "inventory": { "uuid": "3b57de3128b545a18bb7da2f086f6362", "name": "VM CPU Alarm", "comparisonOperator": "LessThanOrEqualTo", "period": 60.0, "namespace": "ZStack/VM", "metricName": "org.zstack.zwatch.datatype.Metric@565e1ebe", "threshold": 30.0, "repeatInterval": 1800.0, "status": "Alarm", "state": "Enabled", "createDate": "Jul 6, 2018 1:50:57 PM", "lastOpDate": "Jul 6, 2018 1:50:57 PM", "labels": [ { "uuid": "61f43f3a05f74ef39b5b2c30354a5246", "key": "VMUuid", "operator": "\u003d", "value": "23958e475ae34735a4ca0b808df0cf50" } ], "actions": [ { "alarmUuid": "f01eb4d0ec1d4cdc81dc478c87f9fceb", "actionType": "sns", "actionUuid": "c9d79c14e37a4ebb83cf0d76fb7b8dbc" } ] } }Change History
This API has no change history records yet.
