EasyManua.ls Logo

VMware VCLOUD API 1.0 - API

VMware VCLOUD API 1.0 - API
212 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
vCloud API Programming Guide
22 VMware, Inc.
<Org .../>
<Org .../>
</OrgList>
Theresponseincludesanauthenticationtokensuppliedinthe x-vcloud-authorizationheader,andalist
oftheorganizationstowhichtheauthenticateduserhasaccess.EachOrghasaURL(initshrefattribute
value)thattheclientcanusetogetmoreinformationaboutobjectsthattheorganizationcontains.Formore
informationaboutauthentication,seeAuthentication”onpage 18.
Browsing an Organization
YoucanuseanHTTPGETrequestandoneoftheOrgURLsreturnedbytheloginrequesttodiscoverthe
contentsofanorganization,asshowninExample 22.(Foramorecompleteversionofthisexample,see
Example 31onpage 34.)
Example 2-2. List the Contents of an Organization
Request:
GET http://vcloud.example.com/api/v1.0/org/5
Response:
200 OK
Content-Type: application/vnd.vmware.vcloud.org+xml
...
<Org name="ExampleOrg" type="application/vnd.vmware.vcloud.org+xml"
href="http://vcloud.example.com/api/v1.0/org/5" ... >
<Link ... />
<Link rel="down" type="application/vnd.vmware.vcloud.catalog+xml"
href="http://vcloud.example.com/api/v1.0/catalog/32" name="MainCatalog"/>
<Link ... />
<Link rel="down" type="application/vnd.vmware.vcloud.vdc+xml"
href="http://vcloud.example.com/api/v1.0/vdc/5" name="ExampleVdc01"/>
<Link ... />
<Link rel="down" type="application/vnd.vmware.vcloud.network+xml"
href="http://vcloud.example.com/api/v1.0/network/14" name="IsolatedOrgNet"/>
<Link rel="down" type="application/vnd.vmware.vcloud.network+xml"
href="http://vcloud.example.com/api/v1.0/network/54" name="Internet"/>
<Description>Example Corp’s Primary Organization</Description>
</Org>
Linksintheresponsewhoserelattributehasavalueofdownarereferencestoobjectsthattheorganization
contains.Example 22showsthesubsetofthoseitemsthatyouwillneedforthisexercise:
AcatalognamedMainCatalog,atURLhttp://vcloud.example.com/api/v1.0/catalog/32,whereyoucan
lookforvApptemplates.
AvDCnamedExampleVdc01,atURLhttp://vcloud.example.com/api/v1.0/vdc/5,whereyoucandeploy
thevApp.
Twonetworks:onenamedInternet,atURLhttp://vcloud.example.com/api/v1.0/network/54,andone
namedIsolatedOrgNet,atURLhttp://vcloud.example.com/api/v1.0/network/14.Youcanconnect
connectthevApptoeitherofthesenetworks.
N
OTEThisexample,likeotherexamplesinthisguide,omitscertainrequiredHTTPheadersandothercontent
sothatitcanprovideaconcise,readablesubsetofanactualrequestandresponse.Formoreinformation,see
“A b o u t theExamples”onpage 19.

Table of Contents

Related product manuals