Splunk Enterprise

Splunk Rest API response in JSON format

Eshwar
Engager

Hi Community,

We are in the process of sending the alerts from Splunk to another application via REST API but response of the REST API is displaying in XML format as our other application would have expect  JSON format however we tried using Postman application as well but the response is same in XML so can any one suggest  JSON response REST API to get the alert details?

Regards,

Eshwar

Labels (2)
0 Karma

Stormy
New Member

Inorder to get the response in json you want to add ?output_mode=json at the end of your rest api call url.
Or you can add it as part of the payload.

0 Karma

yallami
Explorer

Hi, did you find a solution?

0 Karma

richgalloway
SplunkTrust
SplunkTrust

Try specifying output_mode=json.  See https://docs.splunk.com/Documentation/Splunk/9.1.3/RESTUM/RESTusing#Encoding_schemes

---
If this reply helps you, Karma would be appreciated.
0 Karma

Eshwar
Engager

Hi @richgalloway ,

We had tried giving the output_mode parameter for Rest point but still we can see xml  response.

0 Karma
Get Updates on the Splunk Community!

Splunk Observability Cloud’s AI Assistant in Action Series: Analyzing and ...

This is the second post in our Splunk Observability Cloud’s AI Assistant in Action series, in which we look at ...

Elevate Your Organization with Splunk’s Next Platform Evolution

 Thursday, July 10, 2025  |  11AM PDT / 2PM EDT Whether you're managing complex deployments or looking to ...

Splunk Answers Content Calendar, June Edition

Get ready for this week’s post dedicated to Splunk Dashboards! We're celebrating the power of community by ...