Authorization Manager Has Privilege On Entity

Authorization Manager Has Privilege On Entity

Check whether a session holds a set of privileges on a managed entity.

If the session does not exist, false is returned for all privileges.

This API is implemented only by vCenter Server.

Required privileges: System.View

Request
URI
POST
https://{vcenter-host}/sdk/vim25/{release}/AuthorizationManager/{moId}/HasPrivilegeOnEntity
COPY
Path Parameters
string
moId
Required

The unique identifier for the managed object to which the method attaches; the serialized managed object reference for a request has the form moType/moId, in this case AuthorizationManager/{moId}.

string
release
Required

The vSphere release schema. The current specification covers vSphere 8.0.2.0 APIs.


Request Body
HasPrivilegeOnEntityRequestType of type(s) application/json
Required
{
    "entity": {
        "_typeName": "string",
        "type": "string",
        "value": "string"
    },
    "sessionId": "string",
    "privId": [
        "string"
    ]
}
entity
Required

Reference to an instance of the ManagedEntity managed object.

string
sessionId
Required

The session ID to check privileges for. A sesssion ID can be obtained from UserSession.key.

array of string
privId
Optional

The array of privilege IDs to check.

Authentication
This operation uses the following authentication methods.
Responses
200

a boolean value for each privilege indicating whether the session holds the privilege.

Returns Array of boolean of type(s) application/json
[
    {}
]