<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: can i run curl command in the search head in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/can-i-run-curl-command-in-the-search-head/m-p/448295#M168250</link>
    <description>&lt;P&gt;It's not clear what you want to accomplish.  You can make Splunk REST API calls directly in the search window using the &lt;CODE&gt;rest&lt;/CODE&gt; command.  For other REST APIs, use the REST API Modular Input app (&lt;A href="https://splunkbase.splunk.com/app/1546/"&gt;https://splunkbase.splunk.com/app/1546/&lt;/A&gt;).&lt;/P&gt;</description>
    <pubDate>Thu, 19 Jul 2018 10:20:58 GMT</pubDate>
    <dc:creator>richgalloway</dc:creator>
    <dc:date>2018-07-19T10:20:58Z</dc:date>
    <item>
      <title>can i run curl command in the search head</title>
      <link>https://community.splunk.com/t5/Splunk-Search/can-i-run-curl-command-in-the-search-head/m-p/448294#M168249</link>
      <description>&lt;P&gt;can i run curl command in the search head to access the rest api logs&lt;/P&gt;</description>
      <pubDate>Thu, 19 Jul 2018 07:38:03 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/can-i-run-curl-command-in-the-search-head/m-p/448294#M168249</guid>
      <dc:creator>Nadhiyaa</dc:creator>
      <dc:date>2018-07-19T07:38:03Z</dc:date>
    </item>
    <item>
      <title>Re: can i run curl command in the search head</title>
      <link>https://community.splunk.com/t5/Splunk-Search/can-i-run-curl-command-in-the-search-head/m-p/448295#M168250</link>
      <description>&lt;P&gt;It's not clear what you want to accomplish.  You can make Splunk REST API calls directly in the search window using the &lt;CODE&gt;rest&lt;/CODE&gt; command.  For other REST APIs, use the REST API Modular Input app (&lt;A href="https://splunkbase.splunk.com/app/1546/"&gt;https://splunkbase.splunk.com/app/1546/&lt;/A&gt;).&lt;/P&gt;</description>
      <pubDate>Thu, 19 Jul 2018 10:20:58 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/can-i-run-curl-command-in-the-search-head/m-p/448295#M168250</guid>
      <dc:creator>richgalloway</dc:creator>
      <dc:date>2018-07-19T10:20:58Z</dc:date>
    </item>
    <item>
      <title>Re: can i run curl command in the search head</title>
      <link>https://community.splunk.com/t5/Splunk-Search/can-i-run-curl-command-in-the-search-head/m-p/448296#M168251</link>
      <description>&lt;P&gt;Hi &lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/115079"&gt;@Nadhiyaa&lt;/a&gt;&lt;/P&gt;

&lt;P&gt;Yes, you can run the Curl Command on Search Head,&lt;/P&gt;

&lt;P&gt;CURL is a linux or Unix command which performs Get/Post/Delete Operations on given Endpoints, in our case Splunk end points.&lt;/P&gt;

&lt;P&gt;For Example:&lt;BR /&gt;
Curl -k -u admin:password &lt;A href="https://SearchHead_host:8089/servicesNS/admin/search/search/jobs/export" target="_blank"&gt;https://SearchHead_host:8089/servicesNS/admin/search/search/jobs/export&lt;/A&gt; -d search=“search index=_internal | head 3” -d output_mode=csv/xml/json&lt;/P&gt;

&lt;P&gt;when you execute the above the curl request on the search head, you will get the results of the above search exported into csv/xml/json files.&lt;/P&gt;

&lt;P&gt;you can do a lot with splunk end points, to start with look these docs.&lt;BR /&gt;
&lt;A href="http://docs.splunk.com/Documentation/Splunk/7.1.2/RESTREF/RESTprolog" target="_blank"&gt;http://docs.splunk.com/Documentation/Splunk/7.1.2/RESTREF/RESTprolog&lt;/A&gt;&lt;/P&gt;

&lt;P&gt;Thanks.&lt;/P&gt;

&lt;P&gt;Thanks&lt;/P&gt;</description>
      <pubDate>Tue, 29 Sep 2020 20:33:30 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/can-i-run-curl-command-in-the-search-head/m-p/448296#M168251</guid>
      <dc:creator>PowerPacked</dc:creator>
      <dc:date>2020-09-29T20:33:30Z</dc:date>
    </item>
  </channel>
</rss>

