Remove A User; Group Administration; Import A Group - VMware VCLOUD API 1.0 - API Programming Manual

Table of Contents

Advertisement

Response:
200 OK
Content-Type: application/vnd.vmware.admin.user+xml
...
<User name="user@example.com" type="application/vnd.vmware.admin.user+xml"
<Link rel="edit" type="application/vnd.vmware.admin.user+xml"
<Link rel="remove" href="http://vcloud.example.com/api/v1.0/admin/user/85"/>
<FullName>Example User Full Name</FullName>
<EmailAddress>user@example.com</EmailAddress>
<Role type="application/vnd.vmware.admin.role+xml"
<IsEnabled>false</IsEnabled>
</User>

Remove a User

Before you can remove a user, you must disable the User object by changing the value of its IsEnabled 
element to false, as shown in Example
where rel="remove". An administrator can use this link remove the user from the organization, as shown in 
Example
6‐28.
Example 6-28. Remove a User
Request:
DELETE http://vcloud.example.com/api/v1.0/admin/user/85
Response:
204 No Content

Group Administration

Groups must be imported from LDAP. You cannot use the vCloud API to add or remove group members, or 
change the name of the group. Instead, you must make the changes in the source LDAP database and then 
import the group again.

Import a Group

To import a group from an LDAP directory service, POST an empty Group body to the organization's add URL 
for groups. The value of the name attribute in the request body must match the value of the group's name 
attribute in LDAP.
Example 6-29. Import a Group from LDAP
Request:
POST http://vcloud.example.com/api/v1.0/admin/org/26/groups
Content-Type: application/vnd.vmware.admin.group+xml
<Group name="Engineering" xmlns="http://www.vmware.com/vcloud/v1">
<Role type="application/vnd.vmware.admin.role+xml" name="vApp Wrangler"
</Group>
VMware, Inc.
href="http://vcloud.example.com/api/v1.0/admin/user/85" ...>
href="http://vcloud.example.com/api/v1.0/admin/user/85"/>
href="http://vcloud.example.com/api/v1.0/admin/role/105"/>
6‐27. After it has been disabled, the User element contains a link 
href="http://vcloud.example.com/api/v1.0/admin/role/102"/>
Chapter 6 Administrative Operations
113

Advertisement

Table of Contents
loading

Table of Contents