Has anyone found either in python or via JSON where you can update a user's category?
Solved! Go to Solution.
The documentation for the User update() method indicates it now supports setting categories in the latest version of the ArcGIS API for Python.
Hi John, were you able to find a solution? I'm currently trying to update a user's category via python but my commands aren't working
Negative....that pattern remains unfilled. 😉
The documentation for the User update() method indicates it now supports setting categories in the latest version of the ArcGIS API for Python.
Well call me surprised. I was looking for that the other day and didn't see it. Outstanding news! Thanks for finding it and passing along the info Peter. 🙂
This works on the actual user but I am having issues getting it to actually add it to the categories listed in my Organization level Members page.
So in other words it indicates that it should work and it does sort of...but not really
@RobertWeber I am running into the same thing. It says it assigned the category in their profile settings but I don't see it as an option in the organization members tab filter side panel.
Have you found a workaround or solution to this?
user.update(categories = ["/Categories/States/Colorado"])
@TheisenThis finally started working for me. Seems like it just takes a minute at times for it to show in the org level categories.
Thanks Robert. I ended up finding something on Github that also worked using the UserManager helper class. Below is the code snippet I grabbed from that thread.
from arcgis.gis import GIS gis = GIS("home")
cat_users = gis.users.search(query='username:student_user_2')
print(cat_users)
gis.users.assign_categories(users=cat_users, categories=["/Categories/test"])