<?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 GroupSelector in Dropbox API Support &amp; Feedback</title>
    <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/GroupSelector/m-p/582232#M27121</link>
    <description>&lt;P&gt;Hi there,&lt;/P&gt;
&lt;P&gt;&lt;BR /&gt;I have a fundamental misunderstanding of how to use 'GroupSelector'.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Code:&lt;/P&gt;
&lt;PRE&gt;dbt = dropbox.DropboxTeam(TOKEN)&lt;BR /&gt;members = dbt.team_groups_members_list(g.group_id)&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;Error:&amp;nbsp;ValidationError: expected type dropbox.team.GroupSelector or subtype, got string&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Ok fine, I need a GroupSelector type - but how do I actually initialize this?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If I do something like:&lt;/P&gt;
&lt;PRE&gt;&lt;SPAN&gt;gs &lt;/SPAN&gt;= dropbox.team.GroupSelector(g.group_id)&lt;/PRE&gt;
&lt;P&gt;Error: AssertionError: Invalid tag 'g:&amp;lt;group_id&amp;gt;'.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;But that doesn't make sense anyway, because to find a group it would need to be attached to a token. Like:&lt;/P&gt;
&lt;PRE&gt;&lt;SPAN&gt;gs &lt;/SPAN&gt;= dbt.GroupSelector(g.group_id)&lt;/PRE&gt;
&lt;P&gt;But no GroupSelector' class for DropboxTeam.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Have read the api, I understand that there is a GroupSelector class I need to use, I just don't know how to use it in practice. Cannot find any code examples anywhere which actually uses it. Can someone help me with this? Need an explanation rather than an API link, because I have read the API section and still makes no sese.&lt;/P&gt;
&lt;P&gt;&lt;BR /&gt;I have a clear misunderstanding here.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Cheers&lt;/P&gt;</description>
    <pubDate>Tue, 08 Mar 2022 20:45:12 GMT</pubDate>
    <dc:creator>TheWhistler1967</dc:creator>
    <dc:date>2022-03-08T20:45:12Z</dc:date>
    <item>
      <title>GroupSelector</title>
      <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/GroupSelector/m-p/582232#M27121</link>
      <description>&lt;P&gt;Hi there,&lt;/P&gt;
&lt;P&gt;&lt;BR /&gt;I have a fundamental misunderstanding of how to use 'GroupSelector'.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Code:&lt;/P&gt;
&lt;PRE&gt;dbt = dropbox.DropboxTeam(TOKEN)&lt;BR /&gt;members = dbt.team_groups_members_list(g.group_id)&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;Error:&amp;nbsp;ValidationError: expected type dropbox.team.GroupSelector or subtype, got string&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Ok fine, I need a GroupSelector type - but how do I actually initialize this?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If I do something like:&lt;/P&gt;
&lt;PRE&gt;&lt;SPAN&gt;gs &lt;/SPAN&gt;= dropbox.team.GroupSelector(g.group_id)&lt;/PRE&gt;
&lt;P&gt;Error: AssertionError: Invalid tag 'g:&amp;lt;group_id&amp;gt;'.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;But that doesn't make sense anyway, because to find a group it would need to be attached to a token. Like:&lt;/P&gt;
&lt;PRE&gt;&lt;SPAN&gt;gs &lt;/SPAN&gt;= dbt.GroupSelector(g.group_id)&lt;/PRE&gt;
&lt;P&gt;But no GroupSelector' class for DropboxTeam.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Have read the api, I understand that there is a GroupSelector class I need to use, I just don't know how to use it in practice. Cannot find any code examples anywhere which actually uses it. Can someone help me with this? Need an explanation rather than an API link, because I have read the API section and still makes no sese.&lt;/P&gt;
&lt;P&gt;&lt;BR /&gt;I have a clear misunderstanding here.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Cheers&lt;/P&gt;</description>
      <pubDate>Tue, 08 Mar 2022 20:45:12 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/GroupSelector/m-p/582232#M27121</guid>
      <dc:creator>TheWhistler1967</dc:creator>
      <dc:date>2022-03-08T20:45:12Z</dc:date>
    </item>
    <item>
      <title>Re: GroupSelector</title>
      <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/GroupSelector/m-p/582321#M27130</link>
      <description>&lt;P&gt;Hi &lt;a href="https://www.dropboxforum.com/t5/user/viewprofilepage/user-id/1524408"&gt;@TheWhistler1967&lt;/a&gt;,&lt;/P&gt;&lt;P&gt;Have you listed the available groups? 🧐 There should be correct id for every one entry, if any. &lt;img class="lia-deferred-image lia-image-emoji" src="https://www.dropboxforum.com/html/@41457EF40051AFF130FDBFE21B496926/emoticons/1f609.png" alt=":winking_face:" title=":winking_face:" /&gt;&lt;/P&gt;&lt;P&gt;Hope this gives direction.&lt;/P&gt;</description>
      <pubDate>Tue, 08 Mar 2022 15:32:45 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/GroupSelector/m-p/582321#M27130</guid>
      <dc:creator>Здравко</dc:creator>
      <dc:date>2022-03-08T15:32:45Z</dc:date>
    </item>
    <item>
      <title>Re: GroupSelector</title>
      <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/GroupSelector/m-p/582354#M27135</link>
      <description>&lt;P&gt;&lt;a href="https://www.dropboxforum.com/t5/user/viewprofilepage/user-id/1524408"&gt;@TheWhistler1967&lt;/a&gt; As Здравко mentioned, you can use the API to look up the existing group(s) to get the group ID(s). Then you can use that to build a &lt;A href="https://dropbox-sdk-python.readthedocs.io/en/latest/api/team.html#dropbox.team.GroupSelector" target="_self"&gt;GroupSelector&lt;/A&gt; as needed, like this:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="python"&gt;dbt = dropbox.DropboxTeam(TOKEN)

# just taking the first group as an example:
group = dbt.team_groups_list().groups[0]
group_selector = dropbox.team.GroupSelector.group_id(group.group_id)
members = dbt.team_groups_members_list(group_selector)&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;(Don't forget to implementation the pagination over &lt;A href="https://dropbox-sdk-python.readthedocs.io/en/latest/api/dropbox.html#dropbox.dropbox_client.DropboxTeam.team_groups_list" target="_self"&gt;team_groups_list&lt;/A&gt;/&lt;A href="https://dropbox-sdk-python.readthedocs.io/en/latest/api/dropbox.html#dropbox.dropbox_client.DropboxTeam.team_groups_list_continue" target="_self"&gt;team_groups_list_continue&lt;/A&gt; and &lt;A href="https://dropbox-sdk-python.readthedocs.io/en/latest/api/dropbox.html#dropbox.dropbox_client.DropboxTeam.team_groups_members_list" target="_self"&gt;team_groups_members_list&lt;/A&gt;/&lt;A href="https://dropbox-sdk-python.readthedocs.io/en/latest/api/dropbox.html#dropbox.dropbox_client.DropboxTeam.team_groups_members_list_continue" target="_self"&gt;team_groups_members_list_continue&lt;/A&gt;.)&lt;/P&gt;</description>
      <pubDate>Tue, 08 Mar 2022 18:31:08 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/GroupSelector/m-p/582354#M27135</guid>
      <dc:creator>Greg-DB</dc:creator>
      <dc:date>2022-03-08T18:31:08Z</dc:date>
    </item>
    <item>
      <title>Re: GroupSelector</title>
      <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/GroupSelector/m-p/582385#M27138</link>
      <description>&lt;P&gt;Thank you very much.&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;This was my problem, I didn't invoke &lt;STRONG&gt;.group_id&lt;/STRONG&gt;, eg.&lt;/P&gt;&lt;LI-CODE lang="python"&gt;group_selector = dropbox.team.GroupSelector(group.group_id)&lt;/LI-CODE&gt;&lt;P&gt;vs&lt;/P&gt;&lt;LI-CODE lang="python"&gt;group_selector = dropbox.team.GroupSelector.group_id(group.group_id)&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 08 Mar 2022 20:06:36 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/GroupSelector/m-p/582385#M27138</guid>
      <dc:creator>TheWhistler1967</dc:creator>
      <dc:date>2022-03-08T20:06:36Z</dc:date>
    </item>
  </channel>
</rss>

