Authorization Manager Has User Privilege On Entities

Authorization Manager Has User Privilege On Entities

Checks if a user holds a certain set of privileges on a number of managed entities.

Privileges may be granted to users through their respective group membership. If a privilege is granted to a group it is implicitly granted to its members.

This API is implemented only by vCenter Server.

Request
URI
POST
https://{vcenter-host}/sdk/vim25/{release}/AuthorizationManager/{moId}/HasUserPrivilegeOnEntities
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.3.0 APIs.


Request Body
HasUserPrivilegeOnEntitiesRequestType of type(s) application/json
Required

Show optional properties

{
    "entities": [
        {
            "type": "string",
            "value": "string"
        }
    ],
    "userName": "string"
}
{
    "entities": [
        {
            "_typeName": "string",
            "type": "string",
            "value": "string"
        }
    ],
    "userName": "string",
    "privId": [
        "string"
    ]
}
entities
Required

are the managed objects to check privileges on. If they refer to managed objects that are not managed entities the privilege check will be done on the root folder.

Required privileges: System.View

string
userName
Required

is the name of the user to check privileges for. Both UPN and PreWindows2000LogonName user name formats are supported.

array of string
privId
Optional

is the set of privileges to check for

Authentication
This operation uses the following authentication methods.
Responses
200

the privilege check result

Returns Array of EntityPrivilege of type(s) application/json
[
    {
        "_typeName": "string",
        "entity": {
            "_typeName": "string",
            "type": "string",
            "value": "string"
        },
        "privAvailability": [
            {
                "_typeName": "string",
                "privId": "string",
                "isGranted": false
            }
        ]
    }
]