Splunk Enterprise Security

How do I call a non-Splunk REST API in an Event Action?

dpanych
Communicator

Microsoft Exchange Online has an API available to return Message Details of an email. There's currently an app in Splunkbase that indexes the Exchange Online emails (indexed data includes Sender, Recipient, Subject, MessageTraceId, etc.). I want to develop something that utilizes Microsoft's MessageTraceDetail API and returns the detail when used as an Event Action. The MessageTraceDetail API requires two inputs, Recipient and MessageTraceId, which each Message event contains. What I'm trying to create is an Event Action for each of those events, so when there's a suspicious message that we want to inspect in Splunk, we expand the event, click Event Action, and have an option to query the message against the MessageTraceDetail API (button could read something like "Get-MessageTraceDetail".

Here's what the MessageTraceDetail API looks like:

https://reports.office365.com/ecp/reportingwebservice/reporting.svc/MessageTraceDetail?$format=json&... eq '$_EMAIL_FIELD_FROM_SPLUNK_$' and MessageTraceId eq guid'$_ID_FIELD_FROM_SPLUNK_$'

What's the best way to develop something that would return the results from that API? Is there a way to display it as a popup window that parses it in json format?

0 Karma
Get Updates on the Splunk Community!

Built-in Service Level Objectives Management to Bridge the Gap Between Service & ...

Wednesday, May 29, 2024  |  11AM PST / 2PM ESTRegister now and join us to learn more about how you can ...

Get Your Exclusive Splunk Certified Cybersecurity Defense Engineer at Splunk .conf24 ...

We’re excited to announce a new Splunk certification exam being released at .conf24! If you’re headed to Vegas ...

Share Your Ideas & Meet the Lantern team at .Conf! Plus All of This Month’s New ...

Splunk Lantern is Splunk’s customer success center that provides advice from Splunk experts on valuable data ...