Splunk Search

Update tokens and sources with JS

test365498
Path Finder

Hello,

I am trying to investigate how automated Splunk reporting can be. Is it possible to integrate a JS script to automatically update search queries in existing dashboards? Or perhaps clone dashboards?

At the moment I have hard coded sources and token for a dashboard, but as more teams start to use similar metrics, would like to automate the process to update tokens and source files in the search query. Is this possible? Does anyone have an example script?

Thank you

0 Karma

woodcock
Esteemed Legend

This can all be done through the REST API:

http://dev.splunk.com/restapi

test365498
Path Finder

Great, thank you. Do you have a good references or examples for using REST API to update tokens and source files in the search query?

0 Karma

woodcock
Esteemed Legend

You should be able to read and write any Knowledge Object but I have not done what you are asking.

0 Karma
Get Updates on the Splunk Community!

Built-in Service Level Objectives Management to Bridge the Gap Between Service & ...

Wednesday, May 29, 2024  |  11AM PST / 2PM ESTRegister now and join us to learn more about how you can ...

Get Your Exclusive Splunk Certified Cybersecurity Defense Engineer Certification at ...

We’re excited to announce a new Splunk certification exam being released at .conf24! If you’re headed to Vegas ...

Share Your Ideas & Meet the Lantern team at .Conf! Plus All of This Month’s New ...

Splunk Lantern is Splunk’s customer success center that provides advice from Splunk experts on valuable data ...