Skip to main content

15.1.5.3 Events API

EventResourceApi provides query and management operations on events.

Method List

MethodHTTPDescription
apiV1EventsGetGET /api/v1/eventsPaginated query of the event list
apiV1EventsIdGetGET /api/v1/events/{id}Get a single event by ID
apiV1EventsIdAcknowledgePutPUT /api/v1/events/{id}/acknowledgeAcknowledge an event
apiV1EventsIdResolvePutPUT /api/v1/events/{id}/resolveResolve an event

Query Event List

Returns a paginated list of events with optional filtering by time range, status, severity, and element.

Parameters

NameTypeRequiredDescription
fromlongNoStart time, Unix millisecond timestamp
tolongNoEnd time, Unix millisecond timestamp
statusstringNoEvent status: active, acknowledged, resolved
severitystringNoSeverity level: critical, warning, info
elementIdstringNoFilter by element ID
pageNumintegerNoPage number
pageSizeintegerNoRecords per page

Example

// Query unacknowledged critical events in the last 24 hours
// EventResourceApi eventApi = apiClient.buildClient(EventResourceApi.class);
// {QUERY_PARAMS_CLASS} params = new {QUERY_PARAMS_CLASS}()
// .from(System.currentTimeMillis() - 86400_000L)
// .status("active")
// .severity("critical");
// PageOfEventDTO events = eventApi.apiV1EventsGet(params);
// System.out.println("Critical events: " + events.getTotal());
note

For the complete method signatures and parameters, refer to the OpenAPI spec file (idmp-v1.0.14.1.json) included in the SDK package, or browse the Swagger UI at /swagger-ui.html on your IDMP server.