Skip to content

Event management service

The event management service provides resources for updating existing events, either with new status information or with text annotations. To create an event, use the create events resource.

Resource list

POST /v1/event-management/annotate

Creates or updates the annotation field of one or more events.

To create an event, use the create events resource.

Info

To obtain values for the occurrenceId and annotationId fields, display the details of the event to annotate in an events console.

Fields

Field Required? Type Description
annotations Yes Array

One or more event annotation specifications.

The remaining fields of this table specify an annotation.

eventId Yes String The identifier of an event.
occurrenceId Yes String The occurrence identifier of an event.
annotationId No String

The identifier of an event annotation.

For updates, this field is required.

annotation Yes Object

The text of an annotation.

For updates, the content of this field replaces the existing content of an event annotation.

Status codes

  • 200 (full or partial success; see response message)
  • 500 (missing or invalid authentication key)

Example

curl https://YOUR-API-ENDPOINT/v1/event-management/annotate \
  -H "content-type: application/json" \
  -H "zenoss-api-key: YOUR-API-KEY" \
  -X POST -s -S -d \
'{
  "annotations": [
    {
      "eventId": "AAAABWRDWOPER3lzOFI2tSCG49g=",
      "occurrenceId": "AAAABWRDWOPER3lzOFI2tSCG49g=:1",
      "annotation": "my sample annotation"
    },
    {
      "eventId": "AAAEDBRDWOPER3lzOFI2tSCG49g=",
      "occurrenceId": "GOLABWRDWOPER3lzOFI2tSCG49g=:16",
      "annotationId": "4cVf7RnzENAbMLXdt8Qu",
      "annotation": "my sample annotation update"
    }
  ]
}'
{
  "annotationResponses": [
    {
      "eventId": "AAAABWRDWOPER3lzOFI2tSCG49g=",
      "occurrenceId": "AAAABWRDWOPER3lzOFI2tSCG49g=:1",
      "annotationId": "3BDeyX0rnToJgKvEEaPk",
      "success": true
    },
    {
      "eventId": "AAAEDBRDWOPER3lzOFI2tSCG49g=",
      "occurrenceId": "GOLABWRDWOPER3lzOFI2tSCG49g=:16",
      "success": true
    }
  ]
}

POST /v1/event-management/status

Update the status of one or more events.

To create an event, use the create events resource.

Info

To obtain values for the occurrenceId and annotationId fields, display the details of the event to update in an events console.

Fields

Field Required? Type Description
statuses Yes Array

One or more event status specifications.

The remaining fields of this table specify an event status.

eventId Yes String The identifier of an event.
occurrenceId Yes String The occurrence identifier of an event.
acknowledged No Boolean

The acknowledgement state of the event, acknowledged (true) or not acknowledged (false).

This field or the statusWrapper field must be present in a status specification.

statusWrapper No Object

The status of the event. This object contains one key-value pair; the key is status and the value is one of the following:

EM_STATUS_DEFAULT
Unknown at this time
EM_STATUS_OPEN
Known to be in progress at this time
EM_STATUS_SUPPRESSED
Should be ended
EM_STATUS_CLOSED
Known to be ended

This field or the acknowledged field must be present in a status specification.

Status codes

  • 200 (full or partial success; see response message)
  • 500 (missing or invalid authentication key)

Example

curl https://YOUR-API-ENDPOINT/v1/event-management/status \
  -H "content-type: application/json" \
  -H "zenoss-api-key: YOUR-API-KEY" \
  -X POST -s -S -d \
'{
  "statuses": [
    {
      "eventId": "AAAABWRDWOPER3lzOFI2tSCG49g=",
      "occurrenceId": "AAAABWRDWOPER3lzOFI2tSCG49g=:1",
      "acknowledged": true
    },
    {
      "eventId": "AAAAEVBDWOPER3lzOFI2tSCG49g=",
      "occurrenceId": "AAAABFNJDWOPER3lzOFI2tSCG49g=:134",
      "statusWrapper": {
        "status": "EM_STATUS_SUPPRESSED"
      }
    }
  ]
}'
{
  "statusResponses": [
    {
      "eventId": "AAAABWRDWOPER3lzOFI2tSCG49g=",
      "occurrenceId": "AAAABWRDWOPER3lzOFI2tSCG49g=:1",
      "success": true
    },
    {
      "eventId": "AAAAEVBDWOPER3lzOFI2tSCG49g=",
      "occurrenceId": "AAAABFNJDWOPER3lzOFI2tSCG49g=:134",
      "success": true
    }
  ]
}