REST API - set

vcenter namespaces access: set

Set new access control on the namespace for the subject on given domain.

Request:

HTTP request

PUT https://{server}/api/vcenter/namespaces/instances/{namespace}/access/{domain}/{subject}

?type={value}
{
    "role""EDIT"
}

Path Parameters

Name Type Description
Required
namespace string Identifier for the namespace.
domain string The domain of the subject.
subject string The principal for this operation.

Body Parameters:

Name Type Description
bold = required
- set_spec Information about the new access control to be assigned.
-.role string Role to be assigned.

Lists the default roles which can be associated with a subject on a domain on the namespace. Value is one of:
EDIT: This role allows modification of the namespace.
VIEW: This is a read-only role on the namespace.

Query Parameters:

Name Type Description
bold = required
type string Lists the types of subjects who can be associated with a role on the namespace. Value is one of:
USER: Single user.
GROUP: Group of users.The type of subject (user or group).

Response:

HTTP Status Code: 204

Headers:

None

Type:

None

Errors:

HTTP Status Code Type Description
500 error if the system reports an error while responding to the request.
400 not_allowed_in_current_state if the namespace is marked for deletion or the associated cluster is being disabled.
404 not_found if namespace cannot be located.
400 unsupported if the specified principal on given domain is not associated with the namespace.
401 unauthenticated if the user can not be authenticated.
403 unauthorized if the user does not have Namespaces.Configure privilege or the namespace identifier begins with "vmware-system" prefix.