Getting Data In
Highlighted

Help to create a new data input via REST API, plz

New Member

I'm trying to configure splunk via REST API. Can anybody show working POST-request to create new data input? Just 1 complete example plz. Thanks.

Tags (3)
0 Karma
Highlighted

Re: Help to create a new data input via REST API, plz

Splunk Employee
Splunk Employee
curl -k -u admin:changeme -d "name=%2Ftmp%2Fthelog.log%0A" https://localhost:8089/services/data/inputs/monitor

After this request Splunk should index '/tmp/thelog.log'. Note that the argument is url-encoded.