<?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 Re: Best approach for Dropbox-API-Select-Admin for files endpoints using Team credentials for Busine in Dropbox API Support &amp; Feedback</title>
    <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Best-approach-for-Dropbox-API-Select-Admin-for-files-endpoints/m-p/549367#M26143</link>
    <description>&lt;P&gt;Dropbox doesn't have an official best practice/recommendation for this, nor a "Default" option like you described, but I'll pass this along as a feature request. I can't promise if or when that might be implemented though.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;So, you can do whatever works best for your app. I suggest something like option 2, but instead of rechecking on a schedule, just catch the relevant &lt;A href="https://www.dropbox.com/developers/documentation/http/documentation#error-handling" target="_self"&gt;error&lt;/A&gt; if/when the admin ID is no longer valid and then get a current admin ID and retry the call.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Also, there is &lt;A href="https://www.dropbox.com/developers/documentation/http/teams#team-token-get_authenticated_admin" target="_self"&gt;the /2/team/token/get_authenticated_admin endpoint&lt;/A&gt; to check which admin authorized a particular access token, so that may be a good value to start with.&lt;/P&gt;</description>
    <pubDate>Thu, 07 Oct 2021 14:31:50 GMT</pubDate>
    <dc:creator>Greg-DB</dc:creator>
    <dc:date>2021-10-07T14:31:50Z</dc:date>
    <item>
      <title>Best approach for Dropbox-API-Select-Admin for files endpoints using Team credentials for Business</title>
      <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Best-approach-for-Dropbox-API-Select-Admin-for-files-endpoints/m-p/549321#M26142</link>
      <description>&lt;P&gt;Hi guys,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I'm currently integrating with Dropbox Business. I have Team credentials with "team_id"... And I don't want to work on behalf on specific user/admin. My main goal is actually to work with files (upload/download/rename/delete) that are in Team Folders - used and managed by different users/admins.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;My dev business account is actually on Team Spaces, and I already know that I need to:&lt;/P&gt;&lt;P&gt;&amp;nbsp;- call&amp;nbsp;team/namespaces/list - to get shared folders namespace ID&lt;/P&gt;&lt;P&gt;&amp;nbsp;- use&amp;nbsp;Dropbox-API-Path-Root header to identity on which Team Folder root I want to work on&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;But additionally to work with files - I need to use User Endpoints - which requires me to use&amp;nbsp;Dropbox-API-Select-Admin. I already know that I can call "team/members/list_v2" - and pick an admin account to be used on behalf with user endpoints. And this is where my doubts start.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;1. I could leave it dynamic - and before any call to User Endpoints - I can always call "team/members/list_v2" - and just get first admin. I don't have to worry about storing/checking admin "member_id" - but I don't like to duplicate the amount of calls to API - before making a call to user endpoints I have to make another call to get admin member id.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;2. I could make a call once - and store/cache the admin member id - to reuse it in following calls. But in this case what would be best expiation timestamp to look for admin again - whatever it will be - what if cached admin account is downgraded to user or just leave the company... etc.. No matter if I re-check admin once per week, day or hour... In between the selected admin account might no longer be admin.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;3. I can make it fixed - and just use 1'st admin, and if admin changes/leaves company - I will tell my customers that they need to refresh integration and pick another admin... I guess dummiest solution, since I can call&amp;nbsp;"team/members/list_v2" myself - and this can be automated... Just writting it down, but definitelly not sth to use.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;In my opinion the best option would be to use sth like "Dropbox-API-Select-Admin: Default" - but it doesn't exists.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;What is the best or recommended approach in this situation?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 07 Oct 2021 10:46:48 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Best-approach-for-Dropbox-API-Select-Admin-for-files-endpoints/m-p/549321#M26142</guid>
      <dc:creator>wojwal</dc:creator>
      <dc:date>2021-10-07T10:46:48Z</dc:date>
    </item>
    <item>
      <title>Re: Best approach for Dropbox-API-Select-Admin for files endpoints using Team credentials for Busine</title>
      <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Best-approach-for-Dropbox-API-Select-Admin-for-files-endpoints/m-p/549367#M26143</link>
      <description>&lt;P&gt;Dropbox doesn't have an official best practice/recommendation for this, nor a "Default" option like you described, but I'll pass this along as a feature request. I can't promise if or when that might be implemented though.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;So, you can do whatever works best for your app. I suggest something like option 2, but instead of rechecking on a schedule, just catch the relevant &lt;A href="https://www.dropbox.com/developers/documentation/http/documentation#error-handling" target="_self"&gt;error&lt;/A&gt; if/when the admin ID is no longer valid and then get a current admin ID and retry the call.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Also, there is &lt;A href="https://www.dropbox.com/developers/documentation/http/teams#team-token-get_authenticated_admin" target="_self"&gt;the /2/team/token/get_authenticated_admin endpoint&lt;/A&gt; to check which admin authorized a particular access token, so that may be a good value to start with.&lt;/P&gt;</description>
      <pubDate>Thu, 07 Oct 2021 14:31:50 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Best-approach-for-Dropbox-API-Select-Admin-for-files-endpoints/m-p/549367#M26143</guid>
      <dc:creator>Greg-DB</dc:creator>
      <dc:date>2021-10-07T14:31:50Z</dc:date>
    </item>
  </channel>
</rss>

