Other Usage

How to create one report to generate multiple emails based on results?

bamartinez
Explorer

I have a single report that features a list of devices broken up by the group that supports them. I want to have that single report run on a monthly basis - when it runs it should do the following:

  1. Report runs
  2. Device list is generated, so one column is Computer_Name, another column is Support_Team
  3. Upon generation, emails kick off to email@domain.com
  4. I need the body to be dependent on the Support_Team field
    1. i.e. all devices under Support_Team = Alpha should reference only Alpha's devices (email 1)
    2. All devices under Support_team = Bravo should reference only Bravo's devices (email 2)

Is this possible? Or is this a pipe-dream? Today I handle this by having 10 separate reports, 1 per Support_Team field.

Labels (1)
Tags (1)
0 Karma
1 Solution

ITWhisperer
SplunkTrust
SplunkTrust

If you set it up as an alert, you can trigger for each result, so you would have to arrange your search so that each result was for a different user and contained all the information for that user.

View solution in original post

0 Karma

ITWhisperer
SplunkTrust
SplunkTrust

If you set it up as an alert, you can trigger for each result, so you would have to arrange your search so that each result was for a different user and contained all the information for that user.

0 Karma

bamartinez
Explorer

That worked in that I was able to kick off 12 emails - 1 per Support_Team. 

However, the formatting of the CSV thats output is not legible.. its putting all of the data on one line.

0 Karma

ITWhisperer
SplunkTrust
SplunkTrust

Yes, you can't have your cake and eat it, as the saying goes!

0 Karma

bamartinez
Explorer

I ended up having 1 alert that triggers on a cron schedule - and when it triggers it kicks off 1 email per result.

That email has a tokenized variable which I then have used to direct WHERE the email goes, and also is used in generating a custom URL so from the email, someone can click that URL and be brought to a Splunk Dashboard containing the necessary data for said recipients.

0 Karma
Career Survey
First 500 qualified respondents will receive a $20 gift card! Tell us about your professional Splunk journey.
Get Updates on the Splunk Community!

.conf25 Global Broadcast: Don’t Miss a Moment

Hello Splunkers, .conf25 is only a click away.  Not able to make it to .conf25 in person? No worries, you can ...

Observe and Secure All Apps with Splunk

 Join Us for Our Next Tech Talk: Observe and Secure All Apps with SplunkAs organizations continue to innovate ...

What's New in Splunk Observability - August 2025

What's New We are excited to announce the latest enhancements to Splunk Observability Cloud as well as what is ...