5.5

Table Of Contents
rel="entityResolver"
type="application/vnd.vmware.vcloud.entity+xml"
href="https://vcloud.example.com/api/entity/" />
</Session>
Because this user has limited rights, the response includes only a few link types:
org
A link to the user's organization. See “Retrieve a List of Organizations
Accessible to You,” on page 49.
queryList
A link to the set of typed queries you can run. See Chapter 9, “Using the
Query Service,” on page 289.
entity
A link to the entity resolver. See “Retrieve an Object as an Entity,” on
page 362.
An administrator would see a more extensive set of links in the returned Session object. See
“Example: Create a Login Session Using the Integrated Identity Provider,” on page 45.
Retrieve a List of Organizations Accessible to You
A successful login request returns a Session element, which contains a link to a list of all organizations that
you are permitted to access.
Every authenticated user has an associated Session object that contains one or more Link elements. The set
of Link elements in your Session is based on your role and privileges. Each of these elements includes a
URL that you can use with a GET request to explore a subset of objects in the cloud.
All Session elements include a link that you can use to retrieve an OrgList element. For an ordinary user,
this list includes just the organization to which the user logged in. For an organization administrator or
system administrator, the list includes all organizations in the cloud.
Prerequisites
Create a login session. See “Create a Login Session Using the Integrated Identity Provider,” on page 44.
Procedure
1 Retrieve the XML representation of your Session object.
Use a request like this one:
GET https://vcloud.example.com/api/session
2 Examine the contents of the Session element to locate the link to the organization list.
This link has the following form:
<Link
rel="down"
type="application/vnd.vmware.vcloud.orgList+xml"
href="https://vcloud.example.com/api/org"/>
3 Retrieve the list of organizations by making a GET request to the href value of the Link.
See “Example: Retrieve an Organization List,” on page 49.
Example: Retrieve an Organization List
Request:
GET https://vcloud.example.com/api/org
Chapter 3 Exploring a Cloud
VMware, Inc. 49