Splunk Enterprise

Is there a REST API for Splunk to get list of Indexers (Peer Nodes) ?

pankajm89
New Member

Hi, I am writing to Splunk from C# code and need to get a list of Indexers so i can write load balancing logic myself. Is there a REST API i can use to query the master node and get list of Indexers ?

Tags (1)
0 Karma

dineshraj9
Builder

Yes, use the below endpoint to get the list of indexers from any search head -

| rest /servicesNS/-/-/search/distributed/peers splunk_server=local | table title host_fqdn

OR

curl -s -k -u admin:password https://<search_head>:8089/servicesNS/-/-/search/distributed/peers
0 Karma
Get Updates on the Splunk Community!

.conf25 Registration is OPEN!

Ready. Set. Splunk! Your favorite Splunk user event is back and better than ever. Get ready for more technical ...

Detecting Cross-Channel Fraud with Splunk

This article is the final installment in our three-part series exploring fraud detection techniques using ...

Splunk at Cisco Live 2025: Learning, Innovation, and a Little Bit of Mr. Brightside

Pack your bags (and maybe your dancing shoes)—Cisco Live is heading to San Diego, June 8–12, 2025, and Splunk ...