Authorization Manager Fetch User Privilege On Entities

Authorization Manager Fetch User Privilege On Entities
Get the list of effective privileges for a user, either granted explicitly, or through group membership.

Get the list of effective privileges for a user, either granted explicitly, or through group membership.

This API is implemented only by vCenter Server.

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


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

Show optional properties

{
    "entities": [
        {}
    ],
    "userName": "string"
}
{
    "entities": [
        {
            "_typeName": "string",
            "type": "string",
            "value": "string"
        }
    ],
    "userName": "string"
}
array of object
entities
Required

are the entities to retrieve privileges on

Required privileges: System.View

string
userName
Required

is the user to retrieve privileges for

Authentication
This operation uses the following authentication methods.
Responses
200

the privilege check result for each entity

[
    {
        "_typeName": "string",
        "entity": {
            "_typeName": "string",
            "type": "string",
            "value": "string"
        },
        "privileges": [
            "string"
        ]
    }
]
array of object
Optional

This class is used to provide the list of effective privileges set on a given managed entity for a user.


Code Samples
COPY
                    curl -X POST -H 'Authorization: <value>' -H 'Content-Type: application/json' -d '{"entities":["object"],"userName":"string"}' https://{api_host}/sdk/vim25/{release}/AuthorizationManager/{moId}/FetchUserPrivilegeOnEntities