Reporting

How to disable schedules for all searches for a particular user?

twinspop
Influencer

I'm attempting with 2 REST calls: 1 to get the list of searches, and 1 to POST is_scheduled = 0.

The list curl command I'm using is:

curl -sku admin:pass https://localhost:8089/servicesNS/baduser/-/saved/searches?count=0

Then I'd like to step through each returned with this curl template:

curl -sku admin:pass https://localhost:8089/servicesNS/baduser/$APP/saved/searches/$SEARCHNAME -d is_scheduled=0

But Splunk is cloning the search, not disabling the schedule. I get the original, and a private copy with no schedule.

I'm missing something basic about the way the API works. Help?

0 Karma

twinspop
Influencer

The list command is borked. It lists all searches baduser can see. Not what baduser owns. Bah!

0 Karma

twinspop
Influencer

Partial answer: If I use nobody in the username slot in the POST command, it works.

0 Karma
Get Updates on the Splunk Community!

Stay Connected: Your Guide to May Tech Talks, Office Hours, and Webinars!

Take a look below to explore our upcoming Community Office Hours, Tech Talks, and Webinars this month. This ...

They're back! Join the SplunkTrust and MVP at .conf24

With our highly anticipated annual conference, .conf, comes the fez-wearers you can trust! The SplunkTrust, as ...

Enterprise Security Content Update (ESCU) | New Releases

Last month, the Splunk Threat Research Team had two releases of new security content via the Enterprise ...