Alarm Management Open API Developer Guide
-
- UpdatedJan 30, 2025
- 3 minutes to read
- Yokohama
- Developer guides
Use the Alarm Management Open API to create and update data in the Events [em_event] table.
This developer guide provides information on how to extend the Alarm Management Open API to make various customizations.
Extending the Alarm Management Open API
The Alarm Management Open API can be extended by editing script includes.
TMFAlarmAPIConstants
: Contains constants and required parameter information.TMFAlarmAPIUtil
: Contains functions to handle API requests.AlarmAPIProcessorOOB
: Contains helper functions that support functions in TMFAlarmAPIUtil.AlarmAPIProcessor
: An empty script include file. Use this file to define any functions that you want to override from AlarmAPIProcessorOOB.
Extend the Alarm Management Open API to make the following customizations.
Required parameters
- getCreateEventSchema: Returns the validating schema for creating an event.
- getClearEventSchema: Returns the validating schema for clearing an event alarm.
- getPatchEventSchema: Returns the validating schema for patching an event.
Request body validation
verifyCreateEventPayload()
- Called byprocessCreateEvent()
.verifyClearEventPayload()
- Called byprocessClearEvent()
.verifyPatchEventPayload()
- Called byprocessPatchEvent()
.
Additional REST operations
To create additional operations beyond the existing GET, PATCH, and POST operations, create additional scripted REST resources for the Alarm Management Open API. The logic of the new scripted REST resources should be consistent with the existing operations. Define functions for the new operations in TMFAlarmAPIUtil.
Field mapping
When creating or updating records, the Alarm Management Open API maps request body parameters to event record fields. When retrieving records, the API maps record fields to response object attributes.
mapCreateAlarmObjectToEvent()
mapClearAlarmObjectToEvent()
mapPatchAlarmObjectToEvent()
modifyCreateEventResponse()
modifyClearEventResponse()
modifyPatchEventResponse()