<?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: Initiate Script on Endpoint via API call in Cortex XDR Discussions</title>
    <link>https://live.paloaltonetworks.com/t5/cortex-xdr-discussions/initiate-script-on-endpoint-via-api-call/m-p/1220678#M7904</link>
    <description>&lt;P&gt;Hello &lt;a href="https://live.paloaltonetworks.com/t5/user/viewprofilepage/user-id/310428"&gt;@jmazzeo&lt;/a&gt;,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;A follow-up question on this: is there a way to upload a script to the script library using API call?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I checked and there seems no API call for that in the official docs or did I miss it?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thanks!&lt;/P&gt;</description>
    <pubDate>Mon, 17 Feb 2025 17:41:06 GMT</pubDate>
    <dc:creator>Sulivan</dc:creator>
    <dc:date>2025-02-17T17:41:06Z</dc:date>
    <item>
      <title>Initiate Script on Endpoint via API call</title>
      <link>https://live.paloaltonetworks.com/t5/cortex-xdr-discussions/initiate-script-on-endpoint-via-api-call/m-p/574105#M5940</link>
      <description>&lt;P&gt;Hi Everyone,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I've been running Powershell scripts on my endpoints from &lt;STRONG&gt;Action Center &amp;gt; Run Endpoint Script &amp;gt; Execute Commands&amp;nbsp;&lt;/STRONG&gt;in the XDR interface. It works well, however I need to specify a manual query to target the endpoints I want each time i.e. within a specific IP Range, 'Connected' vs 'Disconnected' etc. It gets cumbersome when having to re-run scripts several times or just pick out a few endpoints for testing.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Does anyone know if the API's allow you to run scripts? Ideally, could have a static set of parameters which includes the query to narrow down the endpoints. This way, could have several API links to kick off scripts with different target endpoint queries vs having to specify the query each time in the interface.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Also doesn't seem like you can save a manual query after you've built it, that would have been helpful as well.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Happy to hear any input you may have.&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Cortex Screen Shot.jpg" style="width: 999px;"&gt;&lt;img src="https://live.paloaltonetworks.com/t5/image/serverpage/image-id/56786i856BE4275225E07B/image-size/large/is-moderation-mode/true?v=v2&amp;amp;px=999" role="button" title="Cortex Screen Shot.jpg" alt="Cortex Screen Shot.jpg" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;Thanks&lt;/P&gt;</description>
      <pubDate>Tue, 23 Jan 2024 16:39:36 GMT</pubDate>
      <guid>https://live.paloaltonetworks.com/t5/cortex-xdr-discussions/initiate-script-on-endpoint-via-api-call/m-p/574105#M5940</guid>
      <dc:creator>cnogawaterfront</dc:creator>
      <dc:date>2024-01-23T16:39:36Z</dc:date>
    </item>
    <item>
      <title>Re: Initiate Script on Endpoint via API call</title>
      <link>https://live.paloaltonetworks.com/t5/cortex-xdr-discussions/initiate-script-on-endpoint-via-api-call/m-p/574930#M5979</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://live.paloaltonetworks.com/t5/user/viewprofilepage/user-id/258607"&gt;@cnogawaterfront&lt;/a&gt;, thanks for reaching us using the Live Community.&lt;/P&gt;
&lt;P&gt;The API allows you to run scripts on endpoints, you need to upload the script to the console, get the script UUID, and also get the Endpoint IDs where you need to run it.&lt;/P&gt;
&lt;P&gt;Here is the documentation:&amp;nbsp;&lt;A href="https://docs-cortex.paloaltonetworks.com/r/Cortex-XDR-REST-API/Run-Script" target="_blank"&gt;https://docs-cortex.paloaltonetworks.com/r/Cortex-XDR-REST-API/Run-Script&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;You can combine it with the Get-Endpoint Api to obtain the endpoint_id value:&amp;nbsp;&lt;A href="https://docs-cortex.paloaltonetworks.com/r/Cortex-XDR-REST-API/Get-Endpoint" target="_blank"&gt;https://docs-cortex.paloaltonetworks.com/r/Cortex-XDR-REST-API/Get-Endpoint&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Please let me know if this can work for you.&lt;/P&gt;</description>
      <pubDate>Tue, 30 Jan 2024 14:01:06 GMT</pubDate>
      <guid>https://live.paloaltonetworks.com/t5/cortex-xdr-discussions/initiate-script-on-endpoint-via-api-call/m-p/574930#M5979</guid>
      <dc:creator>jmazzeo</dc:creator>
      <dc:date>2024-01-30T14:01:06Z</dc:date>
    </item>
    <item>
      <title>Re: Initiate Script on Endpoint via API call</title>
      <link>https://live.paloaltonetworks.com/t5/cortex-xdr-discussions/initiate-script-on-endpoint-via-api-call/m-p/576879#M6043</link>
      <description>&lt;P&gt;Hi Jmazzeo, I'm getting a 404 error with both of those links unfortunately. I was able to find this one:&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;
&lt;P&gt;&lt;A href="https://cortex-panw.stoplight.io/docs/cortex-xdr/7223bea7d2bea-run-script" target="_blank"&gt;https://cortex-panw.stoplight.io/docs/cortex-xdr/7223bea7d2bea-run-script&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;Looks like the same thing you were referring to. I hadn't thought to upload the script, I've just been running it from the endpoint machines. Thanks for the help.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 09 Feb 2024 20:42:13 GMT</pubDate>
      <guid>https://live.paloaltonetworks.com/t5/cortex-xdr-discussions/initiate-script-on-endpoint-via-api-call/m-p/576879#M6043</guid>
      <dc:creator>cnogawaterfront</dc:creator>
      <dc:date>2024-02-09T20:42:13Z</dc:date>
    </item>
    <item>
      <title>Re: Initiate Script on Endpoint via API call</title>
      <link>https://live.paloaltonetworks.com/t5/cortex-xdr-discussions/initiate-script-on-endpoint-via-api-call/m-p/1220678#M7904</link>
      <description>&lt;P&gt;Hello &lt;a href="https://live.paloaltonetworks.com/t5/user/viewprofilepage/user-id/310428"&gt;@jmazzeo&lt;/a&gt;,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;A follow-up question on this: is there a way to upload a script to the script library using API call?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I checked and there seems no API call for that in the official docs or did I miss it?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thanks!&lt;/P&gt;</description>
      <pubDate>Mon, 17 Feb 2025 17:41:06 GMT</pubDate>
      <guid>https://live.paloaltonetworks.com/t5/cortex-xdr-discussions/initiate-script-on-endpoint-via-api-call/m-p/1220678#M7904</guid>
      <dc:creator>Sulivan</dc:creator>
      <dc:date>2025-02-17T17:41:06Z</dc:date>
    </item>
    <item>
      <title>Re: Initiate Script on Endpoint via API call</title>
      <link>https://live.paloaltonetworks.com/t5/cortex-xdr-discussions/initiate-script-on-endpoint-via-api-call/m-p/1220911#M7923</link>
      <description>&lt;P&gt;Hi!, no, there is no API to upload a script, you can call the scripts already uploaded to the console, or you can run snipped code using this API:&amp;nbsp;&lt;A href="https://cortex-panw.stoplight.io/docs/cortex-xdr/branches/main/083859c8c6729-run-snippet-code-script" target="_blank"&gt;https://cortex-panw.stoplight.io/docs/cortex-xdr/branches/main/083859c8c6729-run-snippet-code-script&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;You can find in that section on the left side, all the APIs for the supported script actions.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 19 Feb 2025 12:19:51 GMT</pubDate>
      <guid>https://live.paloaltonetworks.com/t5/cortex-xdr-discussions/initiate-script-on-endpoint-via-api-call/m-p/1220911#M7923</guid>
      <dc:creator>jmazzeo</dc:creator>
      <dc:date>2025-02-19T12:19:51Z</dc:date>
    </item>
  </channel>
</rss>

