I am using splunk-sdk in my python code, I want to get latest sid of saved report each time it is refreshed.
I tried using saved_search.dispatch() but the sid which I get in output doesn't retrieves result in python throws URLencoded error.
Can someone help on this?
The dispatch endpoint launches a new search so that will not get what you're looking for. Try the search/v2/jobs/export endpoint (https://docs.splunk.com/Documentation/Splunk/9.4.0/RESTREF/RESTsearch#search.2Fv2.2Fjobs.2Fexport)