Retrieve observed events
GET /support/ems/events
Introduced In: 9.6
Retrieves a collection of observed events.
Related ONTAP commands
-
event log show
Parameters
Name | Type | In | Required | Description |
---|---|---|---|---|
time |
string |
query |
False |
Filter by time |
message.name |
string |
query |
False |
Filter by message.name |
message.severity |
string |
query |
False |
Filter by message.severity |
parameters.name |
string |
query |
False |
Filter by parameters.name |
parameters.value |
string |
query |
False |
Filter by parameters.value |
index |
integer |
query |
False |
Filter by index |
log_message |
string |
query |
False |
Filter by log_message |
node.uuid |
string |
query |
False |
Filter by node.uuid |
node.name |
string |
query |
False |
Filter by node.name |
source |
string |
query |
False |
Filter by source |
filter.name |
string |
query |
False |
Filter the collection returned using an event filter
|
fields |
array[string] |
query |
False |
Specify the fields to return. |
max_records |
integer |
query |
False |
Limit the number of records returned. |
return_records |
boolean |
query |
False |
The default is true for GET calls. When set to false, only the number of records is returned.
|
return_timeout |
integer |
query |
False |
The number of seconds to allow the call to execute before returning. When iterating over a collection, the default is 15 seconds. ONTAP returns earlier if either max records or the end of the collection is reached.
|
order_by |
array[string] |
query |
False |
Order results by specified fields and optional [asc |
Response
Status: 200, Ok
Name | Type | Description |
---|---|---|
_links |
||
num_records |
integer |
Number of records |
records |
array[records] |
Example response
{
"_links": {
"next": {
"href": "/api/resourcelink"
},
"self": {
"href": "/api/resourcelink"
}
},
"num_records": 1,
"records": [
{
"_links": {
"action": [
{
"confirmation_message": {
"arguments": [
{
"code": "string",
"message": "string"
}
],
"code": "4",
"message": "entry doesn't exist"
},
"description": {
"arguments": [
{
"code": "string",
"message": "string"
}
],
"code": "4",
"message": "entry doesn't exist"
},
"href": "/api/resourcelink",
"method": "PATCH",
"name": "schedule",
"parameters": [
{
"description": {
"arguments": [
{
"code": "string",
"message": "string"
}
],
"code": "4",
"message": "entry doesn't exist"
},
"enum": [
"value-1",
"value-2"
],
"format": "date-time",
"help": {
"arguments": [
{
"code": "string",
"message": "string"
}
],
"code": "4",
"message": "entry doesn't exist"
},
"in": "body",
"maxItems": 0,
"maxLength": 0,
"maximum": 0,
"minItems": 0,
"minLength": 0,
"minimum": 0,
"multipleOf": 0,
"name": "schedule-at",
"optional": [
"end-time"
],
"pattern": "string",
"title": {
"arguments": [
{
"code": "string",
"message": "string"
}
],
"code": "4",
"message": "entry doesn't exist"
},
"type": "string",
"validation_error_message": {
"arguments": [
{
"code": "string",
"message": "string"
}
],
"code": "4",
"message": "entry doesn't exist"
}
}
],
"title": {
"arguments": [
{
"code": "string",
"message": "string"
}
],
"code": "4",
"message": "entry doesn't exist"
}
}
],
"self": {
"href": "/api/resourcelink"
}
},
"creation_time": "string",
"history": [
{
"log_message": "string",
"state": "resolving",
"update_time": "string"
}
],
"index": 1,
"last_update_time": "string",
"log_message": "string",
"message": {
"_links": {
"self": {
"href": "/api/resourcelink"
}
},
"name": "callhome.spares.low",
"severity": "emergency"
},
"node": {
"_links": {
"self": {
"href": "/api/resourcelink"
}
},
"name": "node1",
"uuid": "1cd8a442-86d1-11e0-ae1c-123478563412"
},
"num_occurrences": 0,
"parameters": [
{
"name": "numOps",
"value": 123
}
],
"source": "string",
"state": "resolving",
"time": "string",
"uuid": "1cd8a442-86d1-11e0-ae1c-123478563412"
}
]
}
Error
Status: Default
ONTAP Error Response Codes
Error Code | Description |
---|---|
983093 |
The provided filter is unknown. |
Also see the table of common errors in the Response body overview section of this documentation.
Name | Type | Description |
---|---|---|
error |
Example error
{
"error": {
"arguments": [
{
"code": "string",
"message": "string"
}
],
"code": "4",
"message": "entry doesn't exist",
"target": "uuid"
}
}
Definitions
See Definitions
href
Name | Type | Description |
---|---|---|
href |
string |
_links
Name | Type | Description |
---|---|---|
next |
||
self |
arguments
Name | Type | Description |
---|---|---|
code |
string |
Argument code |
message |
string |
Message argument |
confirmation_message
Confirmation message that is presented in user facing applications, confirming the action to take.
Name | Type | Description |
---|---|---|
arguments |
array[arguments] |
Message arguments |
code |
string |
Unique message code. |
message |
string |
User message. |
description
Description of the action is presented in user facing applications.
Name | Type | Description |
---|---|---|
arguments |
array[arguments] |
Message arguments |
code |
string |
Unique message code. |
message |
string |
User message. |
description
Description of the parameter that is presented in user facing applications.
Name | Type | Description |
---|---|---|
arguments |
array[arguments] |
Message arguments |
code |
string |
Unique message code. |
message |
string |
User message. |
help
Help message of the parameter that is presented in user facing applications.
Name | Type | Description |
---|---|---|
arguments |
array[arguments] |
Message arguments |
code |
string |
Unique message code. |
message |
string |
User message. |
items
If the type of the parameter is an array, this specifies the type of items in the form of a JSON object where other properties applicable to that type can be included.
properties
If the type of the parameter is an object, this specifies what properties make up the object in the form of a JSON array where multiple parameters can be embedded within a single parameter. It is primarily used as a schema for an array type parameter.
title
Title of the parameter that is presented in user facing applications.
Name | Type | Description |
---|---|---|
arguments |
array[arguments] |
Message arguments |
code |
string |
Unique message code. |
message |
string |
User message. |
validation_error_message
Error message that is presented in user facing applications, in cases where parameter validation fails.
Name | Type | Description |
---|---|---|
arguments |
array[arguments] |
Message arguments |
code |
string |
Unique message code. |
message |
string |
User message. |
value
Specifies the current value(s) for the parameter encoded in the appropriate JSON type.
parameters
Name | Type | Description |
---|---|---|
description |
Description of the parameter that is presented in user facing applications. |
|
enum |
array[string] |
Specifies the possible values of the parameter. |
exclusiveMaximum |
boolean |
Specifies whether the "maximum" value is excluded in the parameter value range. |
exclusiveMinimum |
boolean |
Specifies whether the "minimum" value is excluded in the parameter value range. |
format |
string |
An optional modifier that serves as a hint at the content and format of the parameter. |
help |
Help message of the parameter that is presented in user facing applications. |
|
in |
string |
Specifies where the parameter is placed when invoking the action. |
items |
If the type of the parameter is an array, this specifies the type of items in the form of a JSON object where other properties applicable to that type can be included. |
|
maxItems |
integer |
Specifies the maximum length of an array type parameter. |
maxLength |
integer |
Specifies the maximum length of a string type parameter. |
maximum |
integer |
Specifies the maximum value of the parameter. |
minItems |
integer |
Specifies the minimum length of an array type parameter. |
minLength |
integer |
Specifies the minimum length of a string type parameter. |
minimum |
integer |
Specifies the minimum value of the parameter. |
multipleOf |
number |
Specifies that a number type parameter must be the multiple of this number. |
name |
string |
Parameter name. |
optional |
array[string] |
By default, all properties of an object type parameter are mandatory. This property specifies the list of optional properties. |
pattern |
string |
Specifies a regular expression template for a string type parameter. |
properties |
If the type of the parameter is an object, this specifies what properties make up the object in the form of a JSON array where multiple parameters can be embedded within a single parameter. It is primarily used as a schema for an array type parameter. |
|
title |
Title of the parameter that is presented in user facing applications. |
|
type |
string |
Parameter type. |
uniqueItems |
boolean |
Specifies whether the "maximum" value is excluded in the parameter value range. |
validation_error_message |
Error message that is presented in user facing applications, in cases where parameter validation fails. |
|
value |
Specifies the current value(s) for the parameter encoded in the appropriate JSON type. |
request_body_template
JSON object describing the structure of the request body if arguments must be provided in the body when invoking the action. A JSON string value that takes the form of {parameter-name} must be substituted by user input values encoded as the appropriate JSON type. The following table gives examples where the parameter type is a string, an integer, and an array:
request_body_template value | parameter value | request body |
---|---|---|
{"name": "{user-name}"} |
user-name="Joe" |
{"name": "Joe"} |
{"retry count": "{count}"} |
count=10 |
{"retry_count": 10} |
{"domains": "{dns-names}"} |
dns-names=["dns-1", "dns-2"] |
{"domains": ["dns-1", "dns-2"]} |
Only JSON string values that start with a '{' and end with a '}' should be considered for parameter substitutions. A JSON string value such as "{user-name} is the syntax" should be treated as a literal string with no parameter substitution to be performed. Double curly braces '{{' and '}}' are used to escape parameter substitutions, therefore double curly braces must be converted to single curly braces. For example, "{{user-name}}" is converted to the JSON string value "{user-name}". Note that this rule only applies if a JSON string starts with '{{' and ends with '}}'. The following table provides examples of when parameter substitutions must not be performed:
request_body_template value | request body |
---|---|
{"name": "{user-name} is bad"} |
{"name": "{user-name} is bad"} |
{"name": "{{user-name}}"} |
{"name": "{user-name}"} |
{"name": "{{user-name}} is bad"} |
{"name": "{{user-name}} is bad"} |
{"name": "{{{{user-name}}}}"} |
{"name": "{{user-name}}"} |
title
Title of the action that is presented in user facing applications.
Name | Type | Description |
---|---|---|
arguments |
array[arguments] |
Message arguments |
code |
string |
Unique message code. |
message |
string |
User message. |
action
Name | Type | Description |
---|---|---|
confirmation_message |
Confirmation message that is presented in user facing applications, confirming the action to take. |
|
description |
Description of the action is presented in user facing applications. |
|
href |
string |
URI on which to perform the action, using the HTTP method specified in the method property. |
method |
string |
HTTP verb, such as PATCH, POST, used to perform the action. |
name |
string |
Name of the action. |
parameters |
array[parameters] |
Parameter list for the action. |
request_body_template |
JSON object describing the structure of the request body if arguments must be provided in the body when invoking the action. A JSON string value that takes the form of {parameter-name} must be substituted by user input values encoded as the appropriate JSON type. The following table gives examples where the parameter type is a string, an integer, and an array: |
| request_body_template value | parameter value | request body
| {"name": "{user-name}"} | user-name="Joe" | {"name": "Joe"}
| {"retry count": "{count}"} | count=10 | {"retry_count": 10}
| {"domains": "{dns-names}"} | dns-names=["dns-1", "dns-2"] | {"domains": ["dns-1", "dns-2"]}
Only JSON string values that start with a '{' and end with a '}' should be considered for parameter substitutions. A JSON string value such as "{user-name} is the syntax" should be treated as a literal string with no parameter substitution to be performed. Double curly braces '{{' and '}}' are used to escape parameter substitutions, therefore double curly braces must be converted to single curly braces. For example, "{{user-name}}" is converted to the JSON string value "{user-name}". Note that this rule only applies if a JSON string starts with '{{' and ends with '}}'. The following table provides examples of when parameter substitutions must not be performed: |
| request_body_template value | request body
| {"name": "{user-name} is bad"} | {"name": "{user-name} is bad"}
| {"name": "{{user-name}}"} | {"name": "{user-name}"}
| {"name": "{{user-name}} is bad"} | {"name": "{{user-name}} is bad"}
| {"name": "{{{{user-name}}}}"} | {"name": "{{user-name}}"}
title |
Title of the action that is presented in user facing applications. |
self
Name | Type | Description |
---|---|---|
href |
string |
_links
Name | Type | Description |
---|---|---|
action |
array[action] |
Actions that can be performed to remediate the issue that the event instance is reporting. To perform an action, send a request to the |
self |
action
Some automatic remediation actions included in the action
link relations are links to the event instance itself, while others are to other public REST APIs. In cases where the action
link points to the event instance itself, this property is used in a PATCH request body to trigger a remediation action. The value included as the value of the property depends on each remediation action.
history
Name | Type | Description |
---|---|---|
log_message |
string |
A formatted text string about the update. |
state |
string |
State of the event instance when the update is raised. |
update_time |
string |
Timestamp of the update. |
_links
Name | Type | Description |
---|---|---|
self |
message
Name | Type | Description |
---|---|---|
_links |
||
name |
string |
Message name of the event. Returned by default. |
severity |
string |
Severity of the event. Returned by default. |
node
Name | Type | Description |
---|---|---|
_links |
||
name |
string |
|
uuid |
string |
parameters
Name | Type | Description |
---|---|---|
name |
string |
Name of parameter |
value |
string |
Value of parameter |
records
Name | Type | Description |
---|---|---|
_links |
||
action |
Some automatic remediation actions included in the |
|
actionable |
boolean |
Indicates whether the event instance currently has actions that can be performed. |
creation_time |
string |
Timestamp of the event creation. |
history |
array[history] |
History of updates to the event instance. |
index |
integer |
Index of the event. Returned by default. |
last_update_time |
string |
Timestamp of the last update to the event instance. |
log_message |
string |
A formatted text string populated with parameter details. Returned by default. When changing the state of an event instance, include the 'state' property and this property in a PATCH request. The value of this property should describe why the state is changed. |
message |
||
node |
||
num_occurrences |
integer |
Number of times the event has repeatedly reported the issue. |
parameters |
array[parameters] |
A list of parameters provided with the EMS event. |
source |
string |
Source |
state |
string |
Indicates the event state. A stateful event tracks the state changes of a system condition and reflects the current system condition. This property and the 'action' property are mutually exclusive in a PATCH request. The state of an event instance can be changed to 'resolved' or 'closed' by sending a PATCH request with this property along with the 'log_message' property describing the reason. An event instance changes its state to 'resolving' only as a result of the user triggering an automatic remediation action, which is done by invoking an action specified in the 'action' link relation. |
stateful |
boolean |
Indicates whether the event is stateful. A stateful event tracks the state changes of a system condition and reflects the current system condition while a stateless event simply reports a certain system condition that has occurred sometime in the past. |
time |
string |
Timestamp of the event. Returned by default. |
uuid |
string |
The UUID that uniquely identifies the event instance. |
error_arguments
Name | Type | Description |
---|---|---|
code |
string |
Argument code |
message |
string |
Message argument |
returned_error
Name | Type | Description |
---|---|---|
arguments |
array[error_arguments] |
Message arguments |
code |
string |
Error code |
message |
string |
Error message |
target |
string |
The target parameter that caused the error. |