Use APIs to access the alerts generated from the alert
definitions.
About this task
The Process Admin Console contains two alert definitions
pages in which administrators can create alert definitions. However,
these pages do not display whether these alert definitions have triggered
an alert. You must create an application, service, or dashboard to
display or otherwise handle a triggered BPM alert. For example, you
could create a dashboard to display triggered alerts or have an application
create an email that contains information about the alert.
Procedure
In the application, service, or dashboard that displays
or handles alerts, use the following APIs:
- To retrieve a list of filtered alert definitions:
- JavaScript API:
BPMAlertDefinition[] getAlertDefinitions(String[] categoryFilter , Boolean checkAuthorization)
The
filter is to retrieve just process instance alert definitions, just
task alert definitions, or the alert definitions from both categories.
- REST API:
GET /rest/bpm/wle/v1/system/alertDefinitions[?categories={category1,category2,...}]
- To retrieve the specified alert definitions, the value
of what they are monitoring, and whether the alert definition has
triggered an alert:
- JavaScript API:
BPMAlertDefinitionStatusResponse getAlertDefinitionsStatus(String[] ids , Boolean checkAuthorization)
- REST API:
GET /rest/bpm/wle/v1/system/alertDefinitions/status[?ids={string}]