<?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 Get UID from Host object in API / CLI Discussion</title>
    <link>https://community.checkpoint.com/t5/API-CLI-Discussion/Get-UID-from-Host-object/m-p/122608#M5952</link>
    <description>&lt;P&gt;Hello,&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am trying to get the UID from a host object&lt;/P&gt;&lt;P&gt;I tried the following mgmt_cli command from the smart console terminal and I keep getting the following error:&lt;/P&gt;&lt;P&gt;show host name "my_host" --format json | jq ".uid"&lt;/P&gt;&lt;P&gt;ERROR: the parameters of show-host command should be provided in pairs (key and value). You have provided an odd number of parameters which suggests that you are probably missing a parameter.&lt;/P&gt;&lt;P&gt;I am running Gaia R80.40 mgmt server&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Wed, 30 Jun 2021 13:41:21 GMT</pubDate>
    <dc:creator>bhaizlett123</dc:creator>
    <dc:date>2021-06-30T13:41:21Z</dc:date>
    <item>
      <title>Get UID from Host object</title>
      <link>https://community.checkpoint.com/t5/API-CLI-Discussion/Get-UID-from-Host-object/m-p/122608#M5952</link>
      <description>&lt;P&gt;Hello,&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am trying to get the UID from a host object&lt;/P&gt;&lt;P&gt;I tried the following mgmt_cli command from the smart console terminal and I keep getting the following error:&lt;/P&gt;&lt;P&gt;show host name "my_host" --format json | jq ".uid"&lt;/P&gt;&lt;P&gt;ERROR: the parameters of show-host command should be provided in pairs (key and value). You have provided an odd number of parameters which suggests that you are probably missing a parameter.&lt;/P&gt;&lt;P&gt;I am running Gaia R80.40 mgmt server&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 30 Jun 2021 13:41:21 GMT</pubDate>
      <guid>https://community.checkpoint.com/t5/API-CLI-Discussion/Get-UID-from-Host-object/m-p/122608#M5952</guid>
      <dc:creator>bhaizlett123</dc:creator>
      <dc:date>2021-06-30T13:41:21Z</dc:date>
    </item>
    <item>
      <title>Re: Get UID from Host object</title>
      <link>https://community.checkpoint.com/t5/API-CLI-Discussion/Get-UID-from-Host-object/m-p/122622#M5957</link>
      <description>&lt;P&gt;What if you just do the `&lt;SPAN&gt;show host name "my_host"` part? No format specifier, no pipeline.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;What about `show host name "my_host" --format json`, leaving off just the pipeline at the end?&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;I haven't used the API command line in SmartConsole, but I suspect it may not support pipelines.&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 30 Jun 2021 16:37:39 GMT</pubDate>
      <guid>https://community.checkpoint.com/t5/API-CLI-Discussion/Get-UID-from-Host-object/m-p/122622#M5957</guid>
      <dc:creator>Bob_Zimmerman</dc:creator>
      <dc:date>2021-06-30T16:37:39Z</dc:date>
    </item>
    <item>
      <title>Re: Get UID from Host object</title>
      <link>https://community.checkpoint.com/t5/API-CLI-Discussion/Get-UID-from-Host-object/m-p/122626#M5959</link>
      <description>&lt;P&gt;Bob thank you for your response, and yes if I remove the pipeline at the end it works no issues. Only when adding the pipeline I get the errors, is using the pipeline with jq not supported when using the smart console cli terminal?&lt;/P&gt;</description>
      <pubDate>Wed, 30 Jun 2021 18:19:48 GMT</pubDate>
      <guid>https://community.checkpoint.com/t5/API-CLI-Discussion/Get-UID-from-Host-object/m-p/122626#M5959</guid>
      <dc:creator>bhaizlett123</dc:creator>
      <dc:date>2021-06-30T18:19:48Z</dc:date>
    </item>
    <item>
      <title>Re: Get UID from Host object</title>
      <link>https://community.checkpoint.com/t5/API-CLI-Discussion/Get-UID-from-Host-object/m-p/122651#M5962</link>
      <description>&lt;P&gt;The CLI in SmartConsole is not a general purpose shell, thus that command will not work.&lt;BR /&gt;You need to do that command from an SSH/console connection in Expert mode.&lt;/P&gt;</description>
      <pubDate>Thu, 01 Jul 2021 00:34:37 GMT</pubDate>
      <guid>https://community.checkpoint.com/t5/API-CLI-Discussion/Get-UID-from-Host-object/m-p/122651#M5962</guid>
      <dc:creator>PhoneBoy</dc:creator>
      <dc:date>2021-07-01T00:34:37Z</dc:date>
    </item>
  </channel>
</rss>

