Event Management

This call displays the paged list of all the events from Mojo server or Arista Cloud Services. Only administrator can make changes or even edit it. You can also mark the events for deletion. They are retained in the database if marked.

JSON Table

Parameter Data Type Description
id long System-generated unique ID of the event.
majorType String The major event associated with the event. The applicable values are:

  • SYSTEM
  • SECURITY
  • PERFORMANCE
minorType int The minor event associated with the event. A subtype of one of the major event types.
textParams List of strings The description and summary parameters associated with the event.
deleted boolean A true or false value indicating whether the event is deleted.
startTime long The time when the event started. The time is displayed in the dd/mm/yyyy hh:mm:ss format on the console.
stopTime long The time when the event stopped. The time is displayed in the dd/mm/yyyy hh:mm:ss format on the console.
locationId application/json ID of the location in the hierarchal location tree. The value is of the type Location ID JSON.
vulnerable boolean A true or false value indicates whether the event has a vulnerability status.
readStatus String Acknowledgement or the read status of the event. The applicable values are:

  • READ
  • UNREAD
  • ACKNOWLEDGED
  • UNACKNOWLEDGED
eventSeverity String Severity level of the event. The applicable values are:

  • HIGH
  • MEDIUM
  • LOW
intermediateType String Intermediate type associated with the event. A subset of one of the following event types:

  • AD_HOC_NETWORK
  • BANDWIDTH
  • CONFIGURATION
  • COVERAGE
  • CRACKING
  • DOS
  • INTERFERENCE
  • MAC_SPOOFING
  • MAM_IN_THE_MIDDLE
  • MIS_CONFIGURED_AP
  • MISBEHAVING_CLIENTS
  • PREVENTION
  • RECONNAISSANCE
  • ROGUE_AP
  • SENSOR
  • SERVER
  • TROUBLESHOOTING

Copy Sample JSON
Sample JSON
[{
	"id": 8,
	"majorType": "SYSTEM",
	"minorType": 275,
	"textParams": ["1","192.168.8.15"],
	"deleted": false,
	"startTime": 1392458698959,
	"stopTime": 1392458698959,
	"locationId": {
		"type": "locallocationid",
		"id": 0
	},
	"vulnerable": false,
	"readStatus": "UNREAD",
	"eventSeverity": "LOW",
	"intermediateType": "SERVER"
},
{
	"id": 9,
	"majorType": "SYSTEM",
	"minorType": 276,
	"textParams": ["1","192.168.8.15"],
	"deleted": false,
	"startTime": 1392466981588,
	"stopTime": 1392466981588,
	"locationId": {
		"type": "locallocationid",
		"id": 0
	},
	"vulnerable": true,
	"readStatus": "UNREAD",
	"eventSeverity": "HIGH",
	"intermidateType": "SERVER"
}]
API Calls

/V5/events

/V5/events/{id}

/V5/events/groupby

/V5/events/{id}

/V5/events

Get Events

Description Fetches a paged list of events from the Arista Server or the Arista Cloud Services.
Who Can Execute? Superuser, Administrator, Operator, and Viewer.
Syntax
GET <Base_URL>/events/{startIndex}/{pageSize}
  • startIndex

    It is an integer value indicating the event number starting with which the event list has to be fetched and included in the response.

  • pageSize

    It is an integer value greater than zero indicating the maximum number of events to be fetched by the API call. Maximum page size is 1000.

Sample code
GET https://training.mojonetworks.com/new/webservice/v5/events/0/2?severity=HIGH
Request Body This API call does not require any request body parameters.
Response Body The API returns the guest user account and profile details in the response body.
The response is in the application/json format.

Get Event

Description This API is used to fetch details of an event based on the event ID from the Mojo Server or the Arista Cloud Services.
Who Can Execute? Superuser, Administrator, Operator, and Viewer.
Syntax
GET <Base_URL>/events/{id}?clusterlocationid=<value>
  • id

    It is the unique ID of the events whose details we need to fetch. It takes up integer value. For example 8.

  • clusterlocationId

    It is the value of this parameter that specifies the location in a server-cluster environment for which the event details have to be fetched. It takes up integer value.

Sample code
GET https://training.mojonetworks.com/new/webservice/events/8?clusterlocationid{“type”:”remotelocationid”,”id”:1,”childId”:1
Request Body This API call does not require any request body parameters.
Response Body If the API call is successful, the HTTP response status is 200.
The response body contains the details of the fetched event. The response is in the application/json format.

Get Events Grouped By Specified Field

Description Fetches a list of events, grouped by the specified field.
Who Can Execute? Superuser, Administrator, Operator, and Viewer.
Syntax
GET <Base_URL>/events/groupby?groupby=<value>
  • groupby

    A field applicable for the group by operation. It takes String value. Possible values are majorType, minorType, intermediateType, severity, vulnerable, readstatus, locationid.

Sample code
GET https://training.mojonetworks.com/new/webservice/V5/events/groupby?groupby=majorType
Request Body This API call does not require any request body parameters.
Response Body The API returns the guest user account and profile details in the response body.
The response is in the application/json format.A sample response JSON is as follows:

{
    "samples": [
        {
            "group": {
                "majorType": "SECURITY"
            },
            "count": 182
        },
        {
            "group": {
                "majorType": "SYSTEM"
            },
            "count": 33
        }
    ],
    "totalCount": 215
}

Update Event

Description This API is used to update the value of fields for the specified event in the Arista Server or Arista Cloud Services.
Who Can Execute? Superuser, Administrator, and Operator.
Syntax
POST <Base_URL>/events/{id}
  • id

    It is the ID of the event whose details have to be updated. It takes up integer values.
    For example, 8.

  • locationId

    It is an integer value specifying the location for which the field for the specified event
    must be updated.

  • deleted

    It is a boolean value specifying whether or not to delete the particular event.

  • readStatus

    It is a boolean value specifying the read status of the event.

  • vulnerable

    It is a boolean value specifying the vulnerability status of the event.

  • vulnerabilityNote

    It is a String value indicating the vulnerability note for the event.

  • acknowldegementNote

    It is a String value indicating the acknowledgment note for the performed action.

Sample code
POST https://training.mojonetworks.com/new/webservice/v5/events/1?
locationid=8&readStatus=true&vulnerable=false&vulnerabilitynote=settofalse
&acknowledgementnote=Updated
Request Body This API call does not require any request body parameters.
Response Body If the API call is successful, the HTTP response status is 204.
The response body does not contain any information.

Mark Events As Deleted

Description This API is used to mark a filtered set of events as deleted. This is soft delete and the event is not actually deleted from the system.
Who Can Execute? Superuser, Administrator, and Operator.
Syntax
POST <Base_URL>/events
  • markDeleted

    It is a boolean value specifying whether the events must be marked as deleted or not.

  • eventFilters

    It is used to filter the list of events that must be marked.

Sample code
POST https://training.mojonetworks.com/new/webservice/v5/events?markdeleted=true&eventId=4
Request Body This API call does not require any request body parameters.
Response Body The API returns the guest user account and profile details in the response body.
The response is in the application/json format.