5.6
Table Of Contents
- vCloud Air Platform Programmer's Guide
- Contents
- About this Programmer's Guide
- About the vCloud Air Platform APIs
- The VMware APIs for Cloud Automation
- XML Namespace Identifiers
- Overview of Object Types
- Link Relationships in the Object Types
- API Versioning
- Roles for the APIs for Cloud Automation
- Authentication and Authorization
- vCloud Air Platform APIs Schema Reference
- Java Code Samples for Cloud Automation
- About the Examples in this Programmer's Guide
- Hello vCloud Air : A RESTful Workflow
- Index
name="0001-example-vdc-1-public-api"
type="application/xml;class=vnd.vmware.vchs.vcloudsession"
href="https://vchs.vmware.com/api/vchs/compute/vchs-2/vdc/vdc-7/vcloudsession" />
</Vdc>
Request 3:
POST href=https://vchs.vmware.com/api/vchs/compute/vchs-2/vdc/vdc-7/vcloudsession
Accept: application/xml;version=5.6
Response 3:
201 Created
<VcloudSession name="example-1101-130711-1-session"
...>
<VdcLink
authorizationToken="d6eFLOqQYfuEn2MJTp7BQ2ISEO+ZYaEgTcqBy8wZQ6js="
authorizationHeader="x-vcloud-authorization"
rel="vcloudvdc"
name="example-1101-130711-1"
href="https://vcloud-examplehost1.example.com/api/vdc/vdc-7" />
</VcloudSession>
Request 4:
GET https://vcloud-examplehost1.vmware.com/api/versions
Response 4:
<SupportedVersions
...
"https://vcloud-examplehost1.vmware.com/api/versions/schema/versions.xsd">
<VersionInfo>
<Version>1.5</Version>
<LoginUrl>https://vcloud-examplehost1.example.com/api/sessions
</LoginUrl>
...
</VersionInfo>
<VersionInfo>
<Version>5.6</Version>
<LoginUrl>https://vcloud-examplehost1.example.com/api/sessions
</LoginUrl>
...
</VersionInfo>
</SupportedVersions>
Request 5:
GET href="https://vcloud-examplehost1.example.com/api/vdc/vdc-7"
authorizationHeader="x-vcloud-authorization"
authorizationToken="vcloud-auth-token"
Accept: application/*+xml;version=5.6
Response 5:
The response returns a virtual data center object and its attributes.
<Vdc
xmlns="http://www.vmware.com/vcloud/v1.5"
status="1"
name="0001-example-vdc-1-public-api"
id="urn:vcloud:vdc:vdc-7"
Chapter 2 Hello vCloud Air : A RESTful Workflow
VMware, Inc. 21