<?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 Do we have rest APIs for vsphere client or EXSi host? I don't have vcentre server, I am using vsphere hypervisor and vsphere client? Do I need to buy vcenter and then can I use rest apis of vcentre to perform vm operations? in vSphere Command-Line Interface Discussions</title>
    <link>https://communities.vmware.com/t5/vSphere-Command-Line-Interface/Do-we-have-rest-APIs-for-vsphere-client-or-EXSi-host-I-don-t/m-p/1390103#M684</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi All,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks in advance.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I want to automate EXSi steps like creating vlna, VMs and adding vSwitches and etc.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I don't have vcentre server purchased. Do I need it for this?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;When I tried to login to EXSi using exsi login creds using rest api, I am getting below response.&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&lt;SPAN&gt;curl -v -X POST --header 'Content-Type: application/json' --header 'Accept: application/json' --header 'vmware-use-header-authn: test' --header 'vmware-api-session-id: null' -u 'root123' -p 'abc@123' '&lt;/SPAN&gt;&lt;A class="jive-link-external-small" href="https://exsitest.com/rest/com/vmware/cis/session" rel="nofollow"&gt;https://exsitest.com/rest/com/vmware/cis/session&lt;/A&gt;&lt;SPAN&gt;' --insecure&lt;/SPAN&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;Enter host password for user 'root':&lt;/P&gt;&lt;P&gt;* Rebuilt URL to: alef@123/&lt;/P&gt;&lt;P&gt;*&amp;nbsp;&amp;nbsp; Trying 0.0.0.123...&lt;/P&gt;&lt;P&gt;* Immediate connect fail for 0.0.0.123: Invalid argument&lt;/P&gt;&lt;P&gt;* Closing connection 0&lt;/P&gt;&lt;P&gt;curl: (7) Couldn't connect to server&lt;/P&gt;&lt;P&gt;*&amp;nbsp;&amp;nbsp; Trying 192.168.51.202...&lt;/P&gt;&lt;P&gt;* Connected to exsitest.com (192.168.51.202) port 443 (#1)&lt;/P&gt;&lt;P&gt;* found 148 certificates in /etc/ssl/certs/ca-certificates.crt&lt;/P&gt;&lt;P&gt;* found 592 certificates in /etc/ssl/certs&lt;/P&gt;&lt;P&gt;* ALPN, offering http/1.1&lt;/P&gt;&lt;P&gt;* SSL connection using TLS1.2 / ECDHE_RSA_AES_256_GCM_SHA384&lt;/P&gt;&lt;P&gt;* server certificate verification SKIPPED&lt;/P&gt;&lt;P&gt;* server certificate status verification SKIPPED&lt;/P&gt;&lt;P&gt;* common name: localhost.localdomain (does not match 'exsitest.com')&lt;/P&gt;&lt;P&gt;* server certificate expiration date OK&lt;/P&gt;&lt;P&gt;* server certificate activation date OK&lt;/P&gt;&lt;P&gt;* certificate public key: RSA&lt;/P&gt;&lt;P&gt;* certificate version: #3&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;* subject: C=US,ST=California,L=Palo Alto,O=VMware\, Inc,OU=VMware ESX Server Default Certificate,&lt;/SPAN&gt;&lt;A class="jive-link-email-small" href="mailto:EMAIL=ssl-certificates@vmware.com"&gt;EMAIL=ssl-certificates@vmware.com&lt;/A&gt;&lt;SPAN&gt;,CN=localhost.localdomain,1.2.840.113549.1.9.2=#1321313534323337333434342c35363464373736313732363532303439366536333265&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;* start date: Fri, 16 Nov 2018 13:04:04 GMT&lt;/P&gt;&lt;P&gt;* expire date: Fri, 17 May 2030 13:04:04 GMT&lt;/P&gt;&lt;P&gt;* issuer: O=VMware Installer&lt;/P&gt;&lt;P&gt;* compression: NULL&lt;/P&gt;&lt;P&gt;* ALPN, server did not agree to a protocol&lt;/P&gt;&lt;P&gt;* Server auth using Basic with user 'root'&lt;/P&gt;&lt;P&gt;&amp;gt; POST /rest/com/vmware/cis/session HTTP/1.1&lt;/P&gt;&lt;P&gt;&amp;gt; Host: exsitest.com&lt;/P&gt;&lt;P&gt;&amp;gt; Authorization: Basic cm9vdDphbGVmQDEyMw==&lt;/P&gt;&lt;P&gt;&amp;gt; User-Agent: curl/7.47.0&lt;/P&gt;&lt;P&gt;&amp;gt; Content-Type: application/json&lt;/P&gt;&lt;P&gt;&amp;gt; Accept: application/json&lt;/P&gt;&lt;P&gt;&amp;gt; vmware-use-header-authn: test&lt;/P&gt;&lt;P&gt;&amp;gt; vmware-api-session-id: null&lt;/P&gt;&lt;P&gt;&amp;gt; &lt;/P&gt;&lt;P&gt;&amp;lt; &lt;STRONG&gt;HTTP/1.1 400 Bad Request&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&amp;lt; Date: Tue, 20 Nov 2018 13:14:38 GMT&lt;/P&gt;&lt;P&gt;&amp;lt; Connection: close&lt;/P&gt;&lt;P&gt;&amp;lt; Content-Type: text/plain; charset=utf-8&lt;/P&gt;&lt;P&gt;&amp;lt; X-Frame-Options: DENY&lt;/P&gt;&lt;P&gt;&amp;lt; Content-Length: 0&lt;/P&gt;&lt;P&gt;&amp;lt; &lt;/P&gt;&lt;P&gt;* Closing connection 1&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;PS: I read somewhere in the document that for vsphere automation, I can use vCli and soapAPIs for Linux. Is that the final option if I decided to not to buy the vcentre license for now. Please confirm my this understanding and let me know if there are any other options available.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Latif&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 20 Nov 2018 13:21:43 GMT</pubDate>
    <dc:creator>latifshaikh</dc:creator>
    <dc:date>2018-11-20T13:21:43Z</dc:date>
    <item>
      <title>Do we have rest APIs for vsphere client or EXSi host? I don't have vcentre server, I am using vsphere hypervisor and vsphere client? Do I need to buy vcenter and then can I use rest apis of vcentre to perform vm operations?</title>
      <link>https://communities.vmware.com/t5/vSphere-Command-Line-Interface/Do-we-have-rest-APIs-for-vsphere-client-or-EXSi-host-I-don-t/m-p/1390103#M684</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi All,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks in advance.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I want to automate EXSi steps like creating vlna, VMs and adding vSwitches and etc.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I don't have vcentre server purchased. Do I need it for this?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;When I tried to login to EXSi using exsi login creds using rest api, I am getting below response.&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&lt;SPAN&gt;curl -v -X POST --header 'Content-Type: application/json' --header 'Accept: application/json' --header 'vmware-use-header-authn: test' --header 'vmware-api-session-id: null' -u 'root123' -p 'abc@123' '&lt;/SPAN&gt;&lt;A class="jive-link-external-small" href="https://exsitest.com/rest/com/vmware/cis/session" rel="nofollow"&gt;https://exsitest.com/rest/com/vmware/cis/session&lt;/A&gt;&lt;SPAN&gt;' --insecure&lt;/SPAN&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;Enter host password for user 'root':&lt;/P&gt;&lt;P&gt;* Rebuilt URL to: alef@123/&lt;/P&gt;&lt;P&gt;*&amp;nbsp;&amp;nbsp; Trying 0.0.0.123...&lt;/P&gt;&lt;P&gt;* Immediate connect fail for 0.0.0.123: Invalid argument&lt;/P&gt;&lt;P&gt;* Closing connection 0&lt;/P&gt;&lt;P&gt;curl: (7) Couldn't connect to server&lt;/P&gt;&lt;P&gt;*&amp;nbsp;&amp;nbsp; Trying 192.168.51.202...&lt;/P&gt;&lt;P&gt;* Connected to exsitest.com (192.168.51.202) port 443 (#1)&lt;/P&gt;&lt;P&gt;* found 148 certificates in /etc/ssl/certs/ca-certificates.crt&lt;/P&gt;&lt;P&gt;* found 592 certificates in /etc/ssl/certs&lt;/P&gt;&lt;P&gt;* ALPN, offering http/1.1&lt;/P&gt;&lt;P&gt;* SSL connection using TLS1.2 / ECDHE_RSA_AES_256_GCM_SHA384&lt;/P&gt;&lt;P&gt;* server certificate verification SKIPPED&lt;/P&gt;&lt;P&gt;* server certificate status verification SKIPPED&lt;/P&gt;&lt;P&gt;* common name: localhost.localdomain (does not match 'exsitest.com')&lt;/P&gt;&lt;P&gt;* server certificate expiration date OK&lt;/P&gt;&lt;P&gt;* server certificate activation date OK&lt;/P&gt;&lt;P&gt;* certificate public key: RSA&lt;/P&gt;&lt;P&gt;* certificate version: #3&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;* subject: C=US,ST=California,L=Palo Alto,O=VMware\, Inc,OU=VMware ESX Server Default Certificate,&lt;/SPAN&gt;&lt;A class="jive-link-email-small" href="mailto:EMAIL=ssl-certificates@vmware.com"&gt;EMAIL=ssl-certificates@vmware.com&lt;/A&gt;&lt;SPAN&gt;,CN=localhost.localdomain,1.2.840.113549.1.9.2=#1321313534323337333434342c35363464373736313732363532303439366536333265&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;* start date: Fri, 16 Nov 2018 13:04:04 GMT&lt;/P&gt;&lt;P&gt;* expire date: Fri, 17 May 2030 13:04:04 GMT&lt;/P&gt;&lt;P&gt;* issuer: O=VMware Installer&lt;/P&gt;&lt;P&gt;* compression: NULL&lt;/P&gt;&lt;P&gt;* ALPN, server did not agree to a protocol&lt;/P&gt;&lt;P&gt;* Server auth using Basic with user 'root'&lt;/P&gt;&lt;P&gt;&amp;gt; POST /rest/com/vmware/cis/session HTTP/1.1&lt;/P&gt;&lt;P&gt;&amp;gt; Host: exsitest.com&lt;/P&gt;&lt;P&gt;&amp;gt; Authorization: Basic cm9vdDphbGVmQDEyMw==&lt;/P&gt;&lt;P&gt;&amp;gt; User-Agent: curl/7.47.0&lt;/P&gt;&lt;P&gt;&amp;gt; Content-Type: application/json&lt;/P&gt;&lt;P&gt;&amp;gt; Accept: application/json&lt;/P&gt;&lt;P&gt;&amp;gt; vmware-use-header-authn: test&lt;/P&gt;&lt;P&gt;&amp;gt; vmware-api-session-id: null&lt;/P&gt;&lt;P&gt;&amp;gt; &lt;/P&gt;&lt;P&gt;&amp;lt; &lt;STRONG&gt;HTTP/1.1 400 Bad Request&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&amp;lt; Date: Tue, 20 Nov 2018 13:14:38 GMT&lt;/P&gt;&lt;P&gt;&amp;lt; Connection: close&lt;/P&gt;&lt;P&gt;&amp;lt; Content-Type: text/plain; charset=utf-8&lt;/P&gt;&lt;P&gt;&amp;lt; X-Frame-Options: DENY&lt;/P&gt;&lt;P&gt;&amp;lt; Content-Length: 0&lt;/P&gt;&lt;P&gt;&amp;lt; &lt;/P&gt;&lt;P&gt;* Closing connection 1&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;PS: I read somewhere in the document that for vsphere automation, I can use vCli and soapAPIs for Linux. Is that the final option if I decided to not to buy the vcentre license for now. Please confirm my this understanding and let me know if there are any other options available.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Latif&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 20 Nov 2018 13:21:43 GMT</pubDate>
      <guid>https://communities.vmware.com/t5/vSphere-Command-Line-Interface/Do-we-have-rest-APIs-for-vsphere-client-or-EXSi-host-I-don-t/m-p/1390103#M684</guid>
      <dc:creator>latifshaikh</dc:creator>
      <dc:date>2018-11-20T13:21:43Z</dc:date>
    </item>
    <item>
      <title>Re: Do we have rest APIs for vsphere client or EXSi host? I don't have vcentre server, I am using vsphere hypervisor and vsphere client? Do I need to buy vcenter and then can I use rest apis of vcentre to perform vm operations?</title>
      <link>https://communities.vmware.com/t5/vSphere-Command-Line-Interface/Do-we-have-rest-APIs-for-vsphere-client-or-EXSi-host-I-don-t/m-p/1390104#M685</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;No, there is no REST API with ESXi standalone. Furthermore, if you want to do automating of these things, you need vCenter Server anyhow, which does contain a &lt;STRONG&gt;​partial&lt;/STRONG&gt;​ REST API.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 20 Nov 2018 13:23:30 GMT</pubDate>
      <guid>https://communities.vmware.com/t5/vSphere-Command-Line-Interface/Do-we-have-rest-APIs-for-vsphere-client-or-EXSi-host-I-don-t/m-p/1390104#M685</guid>
      <dc:creator>daphnissov</dc:creator>
      <dc:date>2018-11-20T13:23:30Z</dc:date>
    </item>
    <item>
      <title>Re: Do we have rest APIs for vsphere client or EXSi host? I don't have vcentre server, I am using vsphere hypervisor and vsphere client? Do I need to buy vcenter and then can I use rest apis of vcentre to perform vm operations?</title>
      <link>https://communities.vmware.com/t5/vSphere-Command-Line-Interface/Do-we-have-rest-APIs-for-vsphere-client-or-EXSi-host-I-don-t/m-p/1390105#M686</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks for the quick reply, really appreciated.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Could you please clear one of my understanding that, now I have left with 2 options if I don't buy vcentre software and want to do automation on debian server,&lt;/P&gt;&lt;P&gt;1. I can make a use of soap APIs, (Probably using pyvmomi python library)&lt;/P&gt;&lt;P&gt;2. I can use vSphere CLI for vSphere 6.7 (Which is in perl, so need to know perl first in order to make use of it)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks again,&lt;/P&gt;&lt;P&gt;Latif&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 20 Nov 2018 13:40:51 GMT</pubDate>
      <guid>https://communities.vmware.com/t5/vSphere-Command-Line-Interface/Do-we-have-rest-APIs-for-vsphere-client-or-EXSi-host-I-don-t/m-p/1390105#M686</guid>
      <dc:creator>latifshaikh</dc:creator>
      <dc:date>2018-11-20T13:40:51Z</dc:date>
    </item>
  </channel>
</rss>

