Hi,
I'm at a dead end. I'm just playing around and wanting to index the JSON result of a cURL command. What do I do?
Is it possible to get the result of this cURL and have it indexed in Splunk?
Here's my working cURL.
One approach is to write the results of the curl commands to a file and have Splunk monitor that file. Or you could use the oneshot
command to index the results file.
You could set this up as a scripted input as per the docs page "Setting up a scripted input", this would result in the output of the command getting indexed.
Alternatively there will likely be a SplunkBase app for this, for example the Curl Command app or the Web Tools Add-on
One approach is to write the results of the curl commands to a file and have Splunk monitor that file. Or you could use the oneshot
command to index the results file.
I used Curl Command from splunkbase and used | collect
to index the result