In order to better align with normal business hours, how can Threshold Profiles be Enabled and Disabled through automated or scripted means?
There is no current way to set Business Hours on the raise of Threshold Events. To get around this limitation we can leverage REST web services present on the Data Aggregator to accomplish this task.
All supported Performance Management releases
The high level steps for this process are:
Where ever we see <DA_Host> replace it with the real Data Aggregator Host Name or IP Address.
A: Use the following URL in a browser, or via GET in a REST client, to see all Event Profiles.
http://<DA_Host>:8581/rest/eventprofiles
Identify the ID for the Event Profile.
B: Using the ID for the Event Profile found in step A launch the following URL in a browser, or via a GET call in a REST client. Replace <ID> with the ID number identified.
http://<DA_Host>:8581/rest/eventprofiles/<ID>
In this output note the entry for the state of the Profile: <Enabled>true</Enabled> or <Enabled>false</Enabled>.
C: In a REST API, run a PUT call using the following URL. Replace <ID> with the ID number identified.
http://<DA_Host>:8581/rest/eventprofiles/<ID>
<EventProfile version="2.0.0">
<Enabled>true</Enabled>
</EventProfile>
Confirm a "Status: 200 OK" success response is returned from the PUT call.
Run the GET call for the ID to confirm the value has been updated. The change should also be reflected in an updated web page for the related Event Profile in the PM web UI.
r22.2 Documentation for REST web services.
https://techdocs.broadcom.com/us/en/ca-enterprise-software/it-operations-management/performance-management/22-2/apis/data-aggregator-rest-webservices.html