Extreme API with Python

Table Of Contents
Extreme API with Python
Page | 85
Part no.9036931-00 Rev AA February 2021
if emc_vars['family'] not in ["VSP Series", "Summit Series"]:
print "This type of device is not supported by this workflow ({})".format(emc_var
s['family'])
exit(0)
# This is one way to make sure the workflow is triggered from alarm
# This key is alarm context-specific
if 'alarmName' not in emc_vars:
print "This workflow must be executed within an Alarm"
exit(0)
# A not very useful script, just for illustration
print "You received an alarm that device {}, with the IP {} is {}.".format(emc_vars['
deviceNickName'], emc_vars['deviceIp'], emc_vars['message'])
After you have created this workflow, configure the rights and menus where this workflow can be
executed in the Details panel, in the Menus tab of the global workflow. Make sure no activities are
selected.
Next, select the Alarm menu. From the Alarms & Events XMC menu, select the alarm type you want to
modify. You can create a new alarm or edit an existing one, depending on the use case. In this example,
you will edit the existing Device Down alarm.