All Apps and Add-ons

Alert Manager: Creating incidents from SPL

Olli1919
Path Finder

Hi fellow Alert Manager Users,

 

is it possible to create alert manager incidents from SPL instead of from the custom alert action? This would allow for easier testing, being able to manually create incidents, not needing to schedule a search.

I tried the following, not diving into the code so far, but this did not work out:

 

| makeresults count=1 
| eval index="alerts", auto_assign_owner="unassigned", impact="low", urgency="low", title="testTitle", owner="unassigned", append_incident=1, auto_previous_resolve=0, auto_subsequent_resolve=0, auto_suppress_resolve=0, auto_ttl_resove=0, display_fields="test", category="testCategory", subcategory="testSubcategory", tags="testTag", notification_scheme="testScheme"
| sendalert alert_manager param.index="alerts" param.auto_assign_owner="unassigned" param.impact="low" param.urgency="low" param.title="testTitle" param.owner="unassigned" param.append_incident=1 param.auto_previous_resolve=0 param.auto_subsequent_resolve=0 param.auto_suppress_resolve=0 param.auto_ttl_resove=0 param.display_fields="test" param.category="testCategory" param.subcategory="testSubcategory" param.tags="testTag" param.notification_scheme="testScheme"

 

It fails with the error:

 

File "/opt/splunk/etc/apps/alert_manager/bin/alert_manager.py", line 570, in <module>
log.debug("Parsed savedsearch settings: expiry={} digest_mode={}".format(savedSearch['content']['alert.expires'], savedSearch['content']['alert.digest_mode']))
KeyError: 'content'

 

 

Thanks!

Labels (2)
0 Karma
Get Updates on the Splunk Community!

.conf25 Registration is OPEN!

Ready. Set. Splunk! Your favorite Splunk user event is back and better than ever. Get ready for more technical ...

Detecting Cross-Channel Fraud with Splunk

This article is the final installment in our three-part series exploring fraud detection techniques using ...

Splunk at Cisco Live 2025: Learning, Innovation, and a Little Bit of Mr. Brightside

Pack your bags (and maybe your dancing shoes)—Cisco Live is heading to San Diego, June 8–12, 2025, and Splunk ...