Dashboards & Visualizations

python script execution from search template

assadabbas
Loves-to-Learn Lots

My app is working fine with advanced xml but as per requirements of splunk 8.0 I have to shift to simple xml. This search works fine 

<searchTemplate>| script base64 __EXECUTE__ "$input$" "$operation$"</searchTemplate>

where base64 refers to a python script path and it takes two arguments as input e.g "abc" "encode".  Output is displayed using

<searchPostProcess> table answer | rename answer as Answer</searchPostProcess>

If i replace <searchTemplate> and <searchPostProcess> with just <search>, the script is not executed and no results are displayed.

Please help me figuring out how to accomplish get the desired output with <search>.

Labels (1)
0 Karma

assadabbas
Loves-to-Learn Lots

I have also tried using <search><query> as well but it did not work

0 Karma
Get Updates on the Splunk Community!

Introducing the Splunk Community Dashboard Challenge!

Welcome to Splunk Community Dashboard Challenge! This is your chance to showcase your skills in creating ...

Get the T-shirt to Prove You Survived Splunk University Bootcamp

As if Splunk University, in Las Vegas, in-person, with three days of bootcamps and labs weren’t enough, now ...

Wondering How to Build Resiliency in the Cloud?

IT leaders are choosing Splunk Cloud as an ideal cloud transformation platform to drive business resilience,  ...