Hi,
I'm trying to change user permissions and roles in vCenter with workflows.
For example, I want to copy the permissions from one folder to another. I found the correct object and method: VcAuthorizationManager.setEntityPermissions().
The problem is that I can't find a way to access the AuthorizationManager. AuthorisationManager is access via the content property of the ServiceContent Object and that object is returned by "RetrieveServiceInstance"-Method according to the documentation:
How do I call this mehtod? The documentataion does not make any sense to me since there is no ServiceInstance-Object in vCO and the ServiceContent-Object has no such method.
I would appreciate an example on how to use these objects.
Thanks,
Irene
Hi Irene
You can use the SdkConnection.authorizationManager (this represent the authorization manager for you vCenter)
SdkConnection reprensents a connection to a specific vCenter Server. You can get all SdkConnection for registered vCenter servers using VcPlugin.allSdkConnections. (VcPlugin is a scriptable object with static-like methods)
Hope this help.
Hi Irene
You can use the SdkConnection.authorizationManager (this represent the authorization manager for you vCenter)
SdkConnection reprensents a connection to a specific vCenter Server. You can get all SdkConnection for registered vCenter servers using VcPlugin.allSdkConnections. (VcPlugin is a scriptable object with static-like methods)
Hope this help.
Hi Cédric,
Thanks a lot! It works this way.
Too bad the documentation does not show AuthorizationManager as property of SdkConnection.
Irene
SdkConnection and VcPlugin are not objects existing in the VC API. They are part of the VC Plugin for vCO.
In vCO, go to Tools / API Explorer to view all available obejcts from vCO scripting.
Of course they are. I'm using API explorer as well as the online documentation.
But if you find AuthenticationManager in the API explorer you have no chance of finding it a property of SdkConnection because thats not in the documentation of AuthenticationManager. The "Property of" entry for "SdkConnection" is missing:
Would be nice to have that reference.
Regards,
Irene