Retrieving situation status information
These examples show how to retrieve situation status information. You can retrieve information about current statuses, or you can retrieve a history of the statuses.
- To retrieve current situation status information, use the
GET /situations/status
endpoint. For details, see Request current situation statuses. - To retrieve situation status history, use the
GET /situations/status/history
endpoint. For details, see Request situation status history.
You can filter your results by including certain situation status attributes in the request. For more information, see Filter results by attributes.
Request current situation statuses
Current situation status attributes collect status information on situations and policies that are running.
GET /situations/status
endpoint, as follows:-
Use the following path to request the current status of all defined situations:
The result of this request is a list of current statuses for all defined situations.https://host:port/api/v1/situations/status
- To request the status of a specific situation, include the name parameter,
set to the unique identifier given to the situation or
policy:
The result of this request is only the status for the specified situation. By default, the results for the situation are not included in the response.https://host:port/api/v1/situations/status?name=situation_name
To retrieve the results for a situation status, include the includeResults parameter, set totrue
:https://host:port/api/v1/situations/status?name=situation_name&includeResults=true
- You can also filter the results by various attributes, as shown in the following
examples:
https://host:port/api/v1/situations/status?node=node_name
https://host:port/api/v1/situations/status?originnode=origin_node_name
https://host:port/api/v1/situations/status?atomize=display_item
You can combine the attribute query parameters in a single request as needed. For more information, see Filter results by attributes.https://host:port/api/v1/situations/status?deltastat=situation_status
Request situation status history
To retrieve situation status history, use the GET /situations/status/history
endpoint.
When using this endpoint, you must specify the time from when to retrieve the history by including the required time value query parameter timeFrom and the optional parameter timeTill. For more information about using the time value parameters, see Using time values for requests.
The following examples show how to retrieve situation status history:
-
Use the following path to request the status history of all defined situations since a certain time:
The result of this request is a list of status history for all defined situations from the time specified.https://host:port/api/v1/situations/status/history?timeFrom=YYYMMDDHHMMSS
To include an end time, also include the timeTill parameter in the request:https://host:port/api/v1/situations/status/history?timeFrom=YYYMMDDHHMMSS&timeTill=YYYMMDDHHMMSS
- To request the status history for a specific situation, include the name
parameter, set to the unique identifier given to the situation or
policy:
The result of this request is the status history for the specified situation. By default, the results for the situation are not included in the response.https://host:port/api/v1/situations/status/history?name=situation_name&timeFrom=YYYMMDDHHMMSS
To retrieve the results for a situation status, include the includeResults parameter, set totrue
:https://host:port/api/v1/situations/status/history?name=situation_name&timeFrom=YYYMMDDHHMMSS&includeResults=true
- You can also filter the results by various attributes, as shown in the following
examples:
https://host:port/api/v1/situations/status/history?timeFrom=YYYMMDDHHMMSS&node=node_name
https://host:port/api/v1/situations/status/history?timeFrom=YYYMMDDHHMMSS&originnode=origin_node_name
https://host:port/api/v1/situations/status/history?timeFrom=YYYMMDDHHMMSS&atomize=display_item
You can combine the attribute query parameters in a single request as needed. For more information, see Filter results by attributes.https://host:port/api/v1/situations/status/history?timeFrom=YYYMMDDHHMMSS&deltastat=situation_status
Filter results by attributes
When requesting situation status information using GET /situations/status
or
GET /situations/status/history
, you can filter the results by available attributes
that you specify using query parameters.
Parameter | Description | Location in TEP |
---|---|---|
name | Situation name. The unique identifier given to the situation or policy. | Message Log view, Name field |
node | Node. The name of the managed system where the situation is distributed and monitored. Use
/system/nodes to get information about all nodes on the system. |
Message Log view, Node field |
originnode | Origin node. The name of the managed system where the situation was triggered. Use
/system/nodes to get information about all nodes on the system. |
Message Log view, Origin Node field |
atomize | Display Item. For multiple-row attribute groups, this attribute enables the situation to
continue to test all rows in the data sampling and open events. Only columns from tables that are specified in the main formula and are eligible for ATOMIZE are processed. For example, the
following specification requests that only the columns from table REALTHDA that
are eligible for ATOMIZE are included in the results:
Tip: You can use the
GET /system/tables?name=REALTHDA endpoint to
identify columns that are eligible for ATOMIZE, as indicated by "ATOMIZE":
true . |
Message Log view, Display Item field |
deltastat | Situation status. The possible values are as follows:
|
Message Log view, Status field |