Events
API call for monitoring of event information:
Event
Display information about events.
Event Using GET Method
If the query size is less than 2048 characters, use the GET method.
URL: https://vmanage-ip-address/dataservice/events?query=query
Method: GET
Request Parameters
Name | Required | Description | Parameter Type | Data Type |
---|---|---|---|---|
query | Optional | Query to filter data returned | Query | String (json) |
Event Using POST Method
If the query size is more than 2048 characters, use the POST method. This is the recommended method.
URL: https://vmanage-ip-address/dataservice/events
Method: POST
Request Parameters
Name | Required | Description | Parameter Type | Data Type |
---|---|---|---|---|
query | Optional | Query to filter data returned | Body | String (json) |
Response Content Type: application/json
Response Object: See Response Object, below.
Example
Get 10,000 events from the previous six hours using the query below:
{ "query": { "condition": "AND", "rules": [ { "value": [ "6" ], "field": "entry_time", "type": "date", "operator": "last_n_hours" } ] }, "size": 10000 }
Get critical events from the previous three hours:
{ "query": { "condition": "AND", "rules": [ { "value": [ "3" ], "field": "entry_time", "type": "date", "operator": "last_n_hours" }, { "value": [ "critical" ], "field": "severity_level", "type": "string", "operator": "in" } ] } }
Supported Fields
Displays list of fields and corresponding data type for the event.
URL: https://vmanage-ip-address/dataservice/events/fields
Method: GET
Response Object for Events API Calls
Events API call responses have the following format:
{ "header": { "generatedOn": timestamp, milliseconds (UNIX time format), "viewKeys": { "uniqueKey": ["key"] }, "fields": [ properties and types ], }, "data": [ array of objects ] }
Additional Information
Using the vManage REST APIs
vManage Aggregation Query
vManage Simple Query