How to get all named users in ArcGIS Online

3323
11
06-07-2018 05:17 PM
JosephJose
New Contributor III

Am trying to find out how I can get list of all named users in ArcGIS Online account using REST request though I know it provides a visual interface in AdminTools for AGOL

Portal provides a community REST service. Is there something similar for AGOL?

0 Kudos
11 Replies
KellyGerrow
Esri Frequent Contributor

Hey Joseph,

Here is a script that requests all of the users in an ArcGIS Online organization and exports to a csv:

http://cloudygis.maps.arcgis.com/home/item.html?id=d3adb69578ba42e9baa0cc6950c08121 

It uses portal self users call to request the information through REST which is in the account helper script.

Rest Doc:

Users—ArcGIS REST API: Users, groups, and content | ArcGIS for Developers 

-Kelly

JosephJose
New Contributor III

Hi Kelly

Thanks but I can use the script as I don't have admin rights

Rest endpoint for Portal in my org is listed as https://<org>/arcgis/sharing/rest/community 

what would be the equivalent for AGOL? It would be normal default paths

0 Kudos
KellyGerrow
Esri Frequent Contributor

You just need the privilege to view other members in order to make the self users call. You may need admin privileges for other items in the script.:

Example:

https://cloudygis.maps.arcgis.com/sharing/rest/portals/self/users?f=json&token=<addtoken> 

or https://<yourorgurl>.maps.arcgis.com/sharing/rest/portals/self/users?f=json&token=<addtoken>

-Kelly

0 Kudos
ZandBakhtiari1
New Contributor II

Kelly Gerrow‌  Has this script been updated since you posted it?  It is throwing me a bunch of errors and is not a simple plug and play.  Is the Create_User_csv.py the only script that needs to be updated wit UN\PW?

0 Kudos
KellyGerrow
Esri Frequent Contributor

You will need enter the directory to write your csv when prompted, or you can hard code the directory on line 64 of the create user script.

What is the error message that you are getting?

0 Kudos
JosephJose
New Contributor III

Hi Kelly

Thanks that worked.

Extending on the above, is there an endpoint where we can check usage of ArcGISPro?

Thanks

0 Kudos
KellyGerrow
Esri Frequent Contributor

I'm not sure if this is available via API, but we may track last login. I've moved the branch over to the ArcGIS Pro Space.

What information are you looking to understand for ArcGIS Pro usage? How often you log in? All logins or all logins and their corresponding dates for you and your organization members?

0 Kudos
JosephJose
New Contributor III

I know this is available in the organization dashboard. It's not for me but for my TL. He wants all the info in the dashboard for ArcGISPro extracted and reported now don't ask me why. He comes from the vertica Analytics space

Now any info last login, extensions used, License level, etc would be helpful

0 Kudos
by Anonymous User
Not applicable

Hi all, is this 'script' available somewhere? I cannot access the 'cloudygis' portal and I don't even want to, but would welcome your solution. Seems like via Rest API I'm limited only to 100 users per request, which is again really cumbersome to work with if I need to export the status for all users... 
Thanks

0 Kudos