Edit Filters and Actions of a Service Insight Notification
Use this API to edit the filters and actions of a Junos Space Service Insight notification.
URI
https://[host]//api/juniper/serviceinsight/notification-management/notifications/{id}/ editFilterAndAction (HTTP method = PUT)
URI Parameters
Parameter | Type | Required | Description |
---|---|---|---|
id | Integer | Yes | ID of the notification for which filters and actions are to be edited |
Consumes
- application/vnd.juniper.serviceinsight.notification-management.editFiltersAndActions +xml;version=1
- application/vnd.juniper.serviceinsight.notification-management.editFiltersAndActions +json;version=1
Request Elements
Element | Type | Description |
---|---|---|
notification | notification | Service Insight notification for which filters and actions must be edited |
emails | Collection of e-mail IDs to which the notification must be flagged | |
String | E-mail ID to which the notification must be flagged | |
snmpTraps | snmpTraps | Collection of SNMP traps for sending the notification |
snmpTrap | snmpTrap | An SNMP trap |
uri | String | URI of the SNMP trap |
href | String | Link to the SNMP trap |
filters | filters | Filter used by Service Insight to send the notification |
organization | String | Organization used in the filter |
deviceGroup | String | Device group used in the filter |
deviceName | String | Device name used in the filter |
serialNumber | String | Serial number of the device used in the filter |
hasTheWords | String | String used in the filter An object is filtered and a notification sent when the object contains the words in this element |
doesnotHaveTheWords | String | Strings used in the filter An object is filtered when the object does not contain the words in this element |
tag | String | Tag used in the filter |
Produces
- application/vnd.juniper.serviceinsight.notification-management.editFiltersAndActions +xml;version=1
- application/vnd.juniper.serviceinsight.notification-management.editFiltersAndActions +json;version=1
Response Elements
Element | Type | Description |
---|---|---|
msg | String | Status message of the edit filters and actions job |
Sample Input
Sample XML Input
<notification> <filter> <organization uri="/api/juniper/serviceinsight/organization-management/organization/11789"/> <deviceGroup uri="/api/juniper/serviceinsight/device-group-management/deviceGroup/1234"/> <deviceName>xyz</deviceName> <serialNumber>12133</serialNumber> </filter> <snmpTraps> <snmpTrap uri="="/api/juniper/servicenow/global-setting-management/snmp-configuration-management /snmpConfiguration/98304"/> </snmpTraps> <emails> <email>abc@test.com</email> </emails> </notification>
Sample JSON Input
{ "notification": { "filter": { "organization": { "@uri": "/api/juniper/serviceinsight/organization-management/organization/11789" }, "deviceGroup": { "@uri": "/api/juniper/serviceinsight/device-group-management/deviceGroup/1234" } }, "snmpTraps": { "snmpTrap": {“@uri”:”="/api/juniper/servicenow/global-setting-management/snmp-configuration- management/snmpConfiguration/98304” } }, "emails": { "email": "abc@test.com" } } }
Sample Output
Sample XML Output
<serviceinsightmsg> <msg>Filters and Actions edited</msg> </serviceinsightmsg>
Sample JSON Output
{ “serviceinsightmsg”: { “msg” : “Filters and Actions Edited” } }