Splunk Enterprise

REST API - To include Time

VijaySrrie
Builder

Hi,  

I am using below REST API  

https://splunk-api-url:8089/servicesNS/nobody/appname/search/jobs/export?output_mode=json&count=1&search=|savedsearch%20savedsearchname%20|search%20ProjectCode=1NN

I need to include time in the above URL - Please let me know how to do it, in the saved search we have DateAndTime values, when I try to fetch the DateAndTime as I am fetching the Project Code its not working

https://splunk-api-url:8089/servicesNS/nobody/appname/search/jobs/export?output_mode=json&count=1&se...   

 

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

VijaySrrie
Builder

This one worked

https://splunk-api-url:8089/servicesNS/nobody/appname/search/jobs/export?output_mode=json&segmentation=none&latest_time=2020-07-15T00%3A05%3A00.000&earliest_time=2020-07-15T00%3A00%3A00.000&search=|savedsearch%20savedsearchname%20|search%20Code=XXX-10-12

View solution in original post

0 Karma

VijaySrrie
Builder

This one worked

https://splunk-api-url:8089/servicesNS/nobody/appname/search/jobs/export?output_mode=json&segmentation=none&latest_time=2020-07-15T00%3A05%3A00.000&earliest_time=2020-07-15T00%3A00%3A00.000&search=|savedsearch%20savedsearchname%20|search%20Code=XXX-10-12

0 Karma
Get Updates on the Splunk Community!

Introducing Splunk Enterprise 9.2

WATCH HERE! Watch this Tech Talk to learn about the latest features and enhancements shipped in the new Splunk ...

Adoption of RUM and APM at Splunk

    Unleash the power of Splunk Observability   Watch Now In this can't miss Tech Talk! The Splunk Growth ...

Routing logs with Splunk OTel Collector for Kubernetes

The Splunk Distribution of the OpenTelemetry (OTel) Collector is a product that provides a way to ingest ...