<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic gis.users.search() in Admin Tools Questions</title>
    <link>https://community.esri.com/t5/admin-tools-questions/gis-users-search/m-p/866059#M106</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&amp;nbsp; How could we retrieve just usernames from&amp;nbsp;&lt;/P&gt;&lt;BLOCKQUOTE class="jive_macro_quote jive-quote jive_text_macro"&gt;&lt;P&gt;gis.users.search()&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;list? I am trying to compare users between Azure active directory and built-in users. I just need the usernames but not the entire list comprehension. Thanks&amp;nbsp;&lt;IMG src="https://community.esri.com/legacyfs/online/emoticons/happy.png" /&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;-Naresh Aligeti&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;python api portal&lt;/P&gt;&lt;DIV style="color: #d4d4d4; background-color: #1e1e1e; font-weight: normal; font-size: 14px;"&gt;&lt;A href="https://community.esri.com/t5/tag/portal for arcgis adminstration/tg-p"&gt;#portal for arcgis adminstration&lt;/A&gt;‌&lt;/DIV&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 11 Sep 2018 22:24:47 GMT</pubDate>
    <dc:creator>NareshAligeti2</dc:creator>
    <dc:date>2018-09-11T22:24:47Z</dc:date>
    <item>
      <title>gis.users.search()</title>
      <link>https://community.esri.com/t5/admin-tools-questions/gis-users-search/m-p/866059#M106</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&amp;nbsp; How could we retrieve just usernames from&amp;nbsp;&lt;/P&gt;&lt;BLOCKQUOTE class="jive_macro_quote jive-quote jive_text_macro"&gt;&lt;P&gt;gis.users.search()&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;list? I am trying to compare users between Azure active directory and built-in users. I just need the usernames but not the entire list comprehension. Thanks&amp;nbsp;&lt;IMG src="https://community.esri.com/legacyfs/online/emoticons/happy.png" /&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;-Naresh Aligeti&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;python api portal&lt;/P&gt;&lt;DIV style="color: #d4d4d4; background-color: #1e1e1e; font-weight: normal; font-size: 14px;"&gt;&lt;A href="https://community.esri.com/t5/tag/portal for arcgis adminstration/tg-p"&gt;#portal for arcgis adminstration&lt;/A&gt;‌&lt;/DIV&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 11 Sep 2018 22:24:47 GMT</pubDate>
      <guid>https://community.esri.com/t5/admin-tools-questions/gis-users-search/m-p/866059#M106</guid>
      <dc:creator>NareshAligeti2</dc:creator>
      <dc:date>2018-09-11T22:24:47Z</dc:date>
    </item>
    <item>
      <title>Re: gis.users.search()</title>
      <link>https://community.esri.com/t5/admin-tools-questions/gis-users-search/m-p/866060#M107</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Naresh,&lt;/P&gt;&lt;P&gt;Try&amp;nbsp;&lt;/P&gt;&lt;PRE class="language-python line-numbers"&gt;&lt;CODE&gt;&lt;SPAN class="punctuation token"&gt;[&lt;/SPAN&gt;user&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;username &lt;SPAN class="keyword token"&gt;for&lt;/SPAN&gt; user &lt;SPAN class="keyword token"&gt;in&lt;/SPAN&gt; gis&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;users&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;search&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;]&lt;/SPAN&gt;&lt;SPAN class="line-numbers-rows"&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;which should return you a list of usernames instead of User objects.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 12 Sep 2018 23:24:11 GMT</pubDate>
      <guid>https://community.esri.com/t5/admin-tools-questions/gis-users-search/m-p/866060#M107</guid>
      <dc:creator>Anonymous User</dc:creator>
      <dc:date>2018-09-12T23:24:11Z</dc:date>
    </item>
    <item>
      <title>Re: gis.users.search()</title>
      <link>https://community.esri.com/t5/admin-tools-questions/gis-users-search/m-p/866061#M108</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;That worked, thanks Atma.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 14 Sep 2018 04:19:36 GMT</pubDate>
      <guid>https://community.esri.com/t5/admin-tools-questions/gis-users-search/m-p/866061#M108</guid>
      <dc:creator>NareshAligeti2</dc:creator>
      <dc:date>2018-09-14T04:19:36Z</dc:date>
    </item>
    <item>
      <title>Re: gis.users.search()</title>
      <link>https://community.esri.com/t5/admin-tools-questions/gis-users-search/m-p/866062#M109</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks for the posted thread, this is helping me as well.&amp;nbsp; I have a question to add&amp;nbsp;to Naresh's question, I am having a hard time finding an example.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I need a list of user emails from a specific role in our Org.&amp;nbsp; The added query parameter is not selecting users in the 'UMN Student' role,&amp;nbsp; all users are returned:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;users = gis.users.search(query='role: UMN Student')&lt;BR /&gt;[users.email for users in gis.users.search()]&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Any tips for a newbie?&amp;nbsp; Thanks!&lt;/P&gt;&lt;P&gt;Kate&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 15 Jan 2019 22:00:42 GMT</pubDate>
      <guid>https://community.esri.com/t5/admin-tools-questions/gis-users-search/m-p/866062#M109</guid>
      <dc:creator>KateCarlson</dc:creator>
      <dc:date>2019-01-15T22:00:42Z</dc:date>
    </item>
    <item>
      <title>Re: gis.users.search()</title>
      <link>https://community.esri.com/t5/admin-tools-questions/gis-users-search/m-p/866063#M110</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I have have a partial answer to my question now, I need to query the roles we have created by using the role ID that Esri designates when created.&amp;nbsp; Anyone know how to determine the role ID without have to contact Esri support?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks-&lt;BR /&gt;Kate&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 16 Jan 2019 15:35:21 GMT</pubDate>
      <guid>https://community.esri.com/t5/admin-tools-questions/gis-users-search/m-p/866063#M110</guid>
      <dc:creator>KateCarlson</dc:creator>
      <dc:date>2019-01-16T15:35:21Z</dc:date>
    </item>
    <item>
      <title>Re: gis.users.search()</title>
      <link>https://community.esri.com/t5/admin-tools-questions/gis-users-search/m-p/866064#M111</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;DIV class="" style="color: #222222; background-color: #ffffff; font-size: small;"&gt;&lt;SPAN&gt;Found some local help on this one as well, posted in case anyone else has similar inquiry.&amp;nbsp; Below code will query roles and IDs for your Org.&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV class="" style="color: #222222; background-color: #ffffff; font-size: small;"&gt; &lt;/DIV&gt;&lt;DIV class="" style="color: #222222; background-color: #ffffff; font-size: small;"&gt;&lt;SPAN&gt;roles = gis.users.roles.all()&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV class="" style="color: #222222; background-color: #ffffff; font-size: small;"&gt;&lt;SPAN&gt;for role in roles:&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV class="" style="color: #222222; background-color: #ffffff; font-size: small;"&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; print(&lt;A data-saferedirecturl="https://www.google.com/url?q=http://role.name&amp;amp;source=gmail&amp;amp;ust=1547745177053000&amp;amp;usg=AFQjCNFrf3DbUpYmTsHZEEEl7Hr7pnRnXw" href="http://role.name/" style="color: #1155cc;" target="_blank"&gt;role.name&lt;/A&gt;, role.role_id)&lt;/SPAN&gt;&lt;/DIV&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 16 Jan 2019 17:48:48 GMT</pubDate>
      <guid>https://community.esri.com/t5/admin-tools-questions/gis-users-search/m-p/866064#M111</guid>
      <dc:creator>KateCarlson</dc:creator>
      <dc:date>2019-01-16T17:48:48Z</dc:date>
    </item>
  </channel>
</rss>

