Select to view content in your preferred language

getting Portal user's groups in SOI/SOE

1033
4
04-20-2021 06:35 AM
PetrDiviš
New Contributor III

Hello,

Is there a way to get from Enterprise SDK's IServerUserInfo.Roles groups that are not on server but on the parent Portal? otherwise the SDK does not offer any other method.

I know there is a REST API on portal, but for that i would need to get a token for portal in SOI, which is not possible.

Thanks for help!

0 Kudos
4 Replies
LorenzMeyer1
Occasional Contributor

Hi

Did you find a solution for this problem? Getting the role names from portal in a SOE/SOI (IServerUserInfo)?

Thanks

0 Kudos
PetrDiviš
New Contributor III

no

0 Kudos
LorenzMeyer1
Occasional Contributor

Checkout the https://developers.arcgis.com/enterprise-sdk/api-reference/net/esriSOESupport/ServerUtilities/#serve...

With this, you should be able to get the group names the user belongs to.

0 Kudos
PetrDiviš
New Contributor III
You are right, but you have to be using and implementing Enterprise SDK, we are using ArcObjects for Server and the groups are on portal. But I opened the ServerUtilities in DLL viewer and they have pretty standard way of getting the groups from portal REST api with the help of properties.GetProperty("OwningSystemPrivateURL") and appending the "/sharing/rest/community/users/"
So basically the way we are doing it anyway.


0 Kudos