Come join our live training webinar every other Wednesday at 11am PST and hear LogicMonitor experts explain best practices and answer common questions. We understand these are uncertain times, and we are here to help!
Note that LogicMonitor has a REST API equivalent for this function.
Escalation Chains define the set of users who are notified at each stage of an alert’s lifecycle. An Escalation Chain consists of destination stages. When an alert is routed to an escalation chain (via a matching alert rule) notifications are sent to the stages defined in the Escalation Chain. You can use the updateEscalatingChain RPC to update existing escalation chains programmatically.
Note: As with all our API calls, authentication is required.
Update an Escalation Chain
https://account.logicmonitor.com/santaba/rpc/updateEscalatingChain?c=accountName&u=user&p=password&id=escalationChainId&name=escalationChainName&description=escalationChainDescription&enableThrottling=trueOrFalse&throttlingPeriod=10&throttlingAlerts=20&useTimeBased=trueOrFalse&destination=[{"type":"simple","stages":[[{"addr":"oncall0","method":"","comment":"","type":"group"}]]}]&ccdestination=[]
NOTE: The above URL has been URL-decoded for readability.
Request Parameters: You can include the following as query parameters in an updateEscalatingChain request:
The JSON string for a non-timebased (simple) escalation chain requires the following values (Note: destination and ccdestination objects must be URL encoded in your request):
------------- Sample Destination (URL decoded for readability) -------------
destination=[{"type":"simple","stages":[[{"addr":"oncall0","method":"","comment":"","type":"group"}]]}] ----------------------------------------------------------------------------
The JSON string for a time-based escalation chain requires the following values (Note: this object must be URL encoded in your request):
------------Sample Destination (URL decoded for readability) --------------
destination=[ {"type":"timebased","period":{"weekdays":"1|2|3","start":0,"end":1440}, "stages":[[{"addr":"oncall0","method":"","comment":"","type":"group"}]]}, {"type":"timebased","period":{"weekdays":"1|2|3|4|5|6|7","start":360,"end":1050}, "stages":[[{"addr":"oncall0","method":"","comment":"","type":"group"}]]}] ----------------------------------------------------------------------------
All outputs will be in the format: { [status], [data], [errmsg] }, where status is the status of the response, errmsg is the error message associated with the response, and the data object includes the following:
curl "https://apiAccount.logicmonitor.com/santaba/rpc/updateEscalatingChain?c=apiAccount&u=apiUser&p=example&id=19&name=MyEscalationChain&enableThrottling=false&destination=%5B%7B%22type%22%3A%22simple%22%2C%22stages%22%3A%5B%5B%7B%22addr%22%3A%22sarah%22%2C%22method%22%3A%22email%22%2C%22comment%22%3A%22%22%2C%22type%22%3A%22admin%22%7D%5D%2C%5B%7B%22addr%22%3A%22Roger%22%2C%22method%22%3A%22email%22%2C%22comment%22%3A%22%22%2C%22type%22%3A%22admin%22%7D%5D%5D%7D%5D"
Response:
{ "status": 200, "data": { "id": 19, "throttlingPeriod": 10, "throttlingAlerts": 20, "description": "", "ccdestination": [], "name": "MyEscalationChain", "enableThrottling": false, "inAlerting": false, "destination": [{ "type": "simple", "stages": [ [{ "addr": "sarah", "method": "email", "comment": "", "type": "admin" }], [{ "addr": "Roger", "method": "email", "comment": "", "type": "admin" }] ] }] }, "errmsg": "OK" }
In This Article