- Mark as New
- Bookmark Message
- Subscribe to Message
- Mute Message
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
RE: HTTP Event Collector target index- Is there a way to specify in the curl command the target index?
mark-jones
Explorer
09-16-2022
04:14 PM
Hello,
Is there a way to specify in the curl command the target index?
For example with the following command, how can i target an index named: scheduler in the command line?
curl -k https://prd-plot.splunkcloud.com:8088/services/collector -H "Authorization:Splunk #####-4f99-b680-72c7bd33f9bb" -d "{\"sourcetype\"😕"_json\",\"event\": {\"a\": \"value1\", \"b\": [\"value1_1\", \"value1_2\"]}}"
Thanks,
Mark
- Mark as New
- Bookmark Message
- Subscribe to Message
- Mute Message
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content

richgalloway

SplunkTrust
09-16-2022
05:10 PM
You should be able to specify the index the same you do the sourcetype.
curl -k https://prd-plot.splunkcloud.com:8088/services/collector -H "Authorization:Splunk #####-4f99-b680-72c7bd33f9bb" -d "{\"sourcetype\":\"_json\",\"index\": \"scheduler\",\"event\": {\"a\": \"value1\", \"b\": [\"value1_1\", \"value1_2\"]}}"
---
If this reply helps you, Karma would be appreciated.
If this reply helps you, Karma would be appreciated.
