<?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: Correct way to use &amp;quot;add_file_member&amp;quot; endpoint if I need to share a file with a new ema in Dropbox API Support &amp; Feedback</title>
    <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Correct-way-to-use-quot-add-file-member-quot-endpoint-if-I-need/m-p/674533#M30415</link>
    <description>&lt;P&gt;The Dropbox OAuth app authorization flow is a way to have the user authorize the app to access their own Dropbox account. If your app is only meant for connecting to your own account, you would only need to process that flow once for your own account. You can store and re-use access tokens/refresh tokens for your own account. You would not need to expose that flow to other users.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Note that you should not expose any access tokens or refresh tokens for your own account to other users, e.g., keep your access tokens/refresh tokens on your server, and never send them to other users on your website front-end.&lt;/P&gt;</description>
    <pubDate>Wed, 05 Apr 2023 13:04:38 GMT</pubDate>
    <dc:creator>Greg-DB</dc:creator>
    <dc:date>2023-04-05T13:04:38Z</dc:date>
    <item>
      <title>Correct way to use "add_file_member" endpoint if I need to share a file with a new email</title>
      <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Correct-way-to-use-quot-add-file-member-quot-endpoint-if-I-need/m-p/674474#M30412</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;
&lt;P&gt;I am looking for a solution to my problem.&lt;/P&gt;
&lt;P&gt;I am still in a testing stage, so I am open to different solution.&lt;/P&gt;
&lt;P&gt;I need to share a file with only users who subscribe to a form. They subscribe on my website with their email and I add the email to the file requested.&lt;/P&gt;
&lt;P&gt;To do that I thought the "add_file_member" endpoint could be the solution.&lt;/P&gt;
&lt;P&gt;Actually I have two issues:&lt;/P&gt;
&lt;P&gt;1. Access need to be temporary (I thought to flush email at scheduling), so I am not sure if "add_file_member" could suites my needs. Maybe "get_temporary_link" could work better? Does "get_temporary_link" allows download only to authorized emails? How long does the link last?&lt;/P&gt;
&lt;P&gt;2. I was testing with the access token, but I did not get it lasts only for 4 hours. Still I do not need users to get OAuth, because I (the file owner) am the only one to give access to the file with the email provided. Does it sounds weird? Because I cannot find a simple solution that does not involve the user in an unnecessary authorization process since I am the one who has to give access and not them to log in.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Could you suggest a way to achieve what I want or point my errors?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thanks!&lt;/P&gt;</description>
      <pubDate>Wed, 05 Apr 2023 17:50:25 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Correct-way-to-use-quot-add-file-member-quot-endpoint-if-I-need/m-p/674474#M30412</guid>
      <dc:creator>lezan</dc:creator>
      <dc:date>2023-04-05T17:50:25Z</dc:date>
    </item>
    <item>
      <title>Re: Correct way to use "add_file_member" endpoint if I need to share a file with a new ema</title>
      <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Correct-way-to-use-quot-add-file-member-quot-endpoint-if-I-need/m-p/674490#M30413</link>
      <description>&lt;P&gt;1. &lt;A href="https://www.dropbox.com/developers/documentation/http/documentation#sharing-add_file_member" target="_blank"&gt;The /2/sharing/add_file_member endpoint&lt;/A&gt; allows you to share specific files with specific users. That access does not expire automatically, but you can programmatically revoke it whenever you need using &lt;A href="https://www.dropbox.com/developers/documentation/http/documentation#sharing-remove_folder_member" target="_blank"&gt;the /2/sharing/remove_folder_member endpoint&lt;/A&gt;.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Alternatively, &lt;A href="https://www.dropbox.com/developers/documentation/http/documentation#files-get_temporary_link" target="_blank"&gt;the /2/files/get_temporary_link endpoint&lt;/A&gt; returns a temporary direct link to the file data. You can pass that link to users to allow them to access the file data. These links automatically expire after four hours. These do not enforce access to only users with specific email addresses.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;2. This is the expected behavior for new access tokens. Dropbox is no longer offering the option for creating new long-lived access tokens. Dropbox is now issuing short-lived access tokens (and optional refresh tokens) instead of long-lived access tokens. You can find &lt;A href="https://dropbox.tech/developers/migrating-app-permissions-and-access-tokens#updating-access-token-type" target="_blank" rel="noopener noreferrer"&gt;more information on this migration here&lt;/A&gt;.&lt;BR /&gt;&lt;BR /&gt;Apps can still get long-term access by requesting "offline" access though, in which case the app receives a "refresh token" that can be used to retrieve new short-lived access tokens as needed, without further manual user intervention. You can find more information in the &lt;A href="https://developers.dropbox.com/oauth-guide" target="_blank" rel="noopener noreferrer"&gt;OAuth Guide&lt;/A&gt; and &lt;A href="https://www.dropbox.com/developers/documentation/http/documentation#authorization" target="_blank" rel="noopener noreferrer"&gt;authorization documentation&lt;/A&gt;. There's a basic outline of processing this flow in &lt;A href="https://dropbox.tech/developers/using-oauth-2-0-with-offline-access" target="_blank" rel="noopener noreferrer"&gt;this blog post&lt;/A&gt; which may serve as a useful example.&lt;/P&gt;</description>
      <pubDate>Wed, 05 Apr 2023 11:27:40 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Correct-way-to-use-quot-add-file-member-quot-endpoint-if-I-need/m-p/674490#M30413</guid>
      <dc:creator>Greg-DB</dc:creator>
      <dc:date>2023-04-05T11:27:40Z</dc:date>
    </item>
    <item>
      <title>Re: Correct way to use "add_file_member" endpoint if I need to share a file with a new ema</title>
      <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Correct-way-to-use-quot-add-file-member-quot-endpoint-if-I-need/m-p/674497#M30414</link>
      <description>&lt;P&gt;Hello @Greg-DB,&lt;/P&gt;&lt;P&gt;thanks for the fast reply.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I mostly get all, but still I do not quite understand OAuth process and why I need it.&lt;/P&gt;&lt;P&gt;Let me get you an idea about my needs and flow:&lt;/P&gt;&lt;P&gt;1. User land on a page and submit a form with his email.&lt;/P&gt;&lt;P&gt;2. I handle the request with an API function, make a call to the Dropbox endpoint and share the file (I am the owner of the file) with the new email.&lt;/P&gt;&lt;P&gt;3. Send an email to the user with the download link.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I do not want the user to login/using their credentials, that's need to be transparent to the final user. Doesn't OAuth implicitly require the user to follow a process with their credentials to be authorized?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks for the answer!&lt;/P&gt;</description>
      <pubDate>Wed, 05 Apr 2023 11:51:16 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Correct-way-to-use-quot-add-file-member-quot-endpoint-if-I-need/m-p/674497#M30414</guid>
      <dc:creator>lezan</dc:creator>
      <dc:date>2023-04-05T11:51:16Z</dc:date>
    </item>
    <item>
      <title>Re: Correct way to use "add_file_member" endpoint if I need to share a file with a new ema</title>
      <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Correct-way-to-use-quot-add-file-member-quot-endpoint-if-I-need/m-p/674533#M30415</link>
      <description>&lt;P&gt;The Dropbox OAuth app authorization flow is a way to have the user authorize the app to access their own Dropbox account. If your app is only meant for connecting to your own account, you would only need to process that flow once for your own account. You can store and re-use access tokens/refresh tokens for your own account. You would not need to expose that flow to other users.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Note that you should not expose any access tokens or refresh tokens for your own account to other users, e.g., keep your access tokens/refresh tokens on your server, and never send them to other users on your website front-end.&lt;/P&gt;</description>
      <pubDate>Wed, 05 Apr 2023 13:04:38 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Correct-way-to-use-quot-add-file-member-quot-endpoint-if-I-need/m-p/674533#M30415</guid>
      <dc:creator>Greg-DB</dc:creator>
      <dc:date>2023-04-05T13:04:38Z</dc:date>
    </item>
    <item>
      <title>Re: Correct way to use "add_file_member" endpoint if I need to share a file with a new ema</title>
      <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Correct-way-to-use-quot-add-file-member-quot-endpoint-if-I-need/m-p/674534#M30416</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://www.dropboxforum.com/t5/user/viewprofilepage/user-id/1659914"&gt;@lezan&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;&lt;P&gt;...&lt;/P&gt;&lt;P&gt;2. I handle the request with an API function, make a call to the Dropbox endpoint and share the file (I am the owner of the file) with the new email.&lt;/P&gt;&lt;P&gt;3. Send an email to the user with the download link.&lt;/P&gt;&lt;P&gt;...&lt;/P&gt;&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;Hi &lt;a href="https://www.dropboxforum.com/t5/user/viewprofilepage/user-id/1659914"&gt;@lezan&lt;/a&gt;,&lt;/P&gt;&lt;P&gt;Hm...&lt;img class="lia-deferred-image lia-image-emoji" src="https://www.dropboxforum.com/html/@9AD39CA637682E9616FBE31CDAF1B6C4/emoticons/1f914.png" alt=":thinking_face:" title=":thinking_face:" /&gt; Can you clarify, why actually do you need both ways? In point 2 you're inviting a Dropbox user to shared file. In point 3 you're sending to person download link. They are 2 different way to do the (almost) same thing. In point 2, a Dropbox account (identified with the supplied email) is expected from recipient and login is expected in this context (the file gets up in the recipient account). In point 3 recipient doesn't need any Dropbox account, but on further file' changes re-download is needed (for most recent file version) - automatic sync is impossible. That's it.&amp;nbsp;&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; Choose what best matches your idea.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://www.dropboxforum.com/t5/user/viewprofilepage/user-id/1659914"&gt;@lezan&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;&lt;P&gt;... Doesn't OAuth implicitly require the user to follow a process with their credentials to be authorized?&lt;/P&gt;&lt;P&gt;...&lt;/P&gt;&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;OAuth is needed for you, not to the recipient! It's the only way to receive refresh token and, in this context, long term access. Otherwise, as Greg noted before, your access token will always expire 4 hours or so after generation.&lt;/P&gt;&lt;P&gt;Hope this sheds some light.&lt;/P&gt;</description>
      <pubDate>Wed, 05 Apr 2023 13:05:54 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Correct-way-to-use-quot-add-file-member-quot-endpoint-if-I-need/m-p/674534#M30416</guid>
      <dc:creator>Здравко</dc:creator>
      <dc:date>2023-04-05T13:05:54Z</dc:date>
    </item>
    <item>
      <title>Re: Correct way to use "add_file_member" endpoint if I need to share a file with a new ema</title>
      <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Correct-way-to-use-quot-add-file-member-quot-endpoint-if-I-need/m-p/674549#M30417</link>
      <description>&lt;P&gt;Hello @Greg-DB,&lt;/P&gt;&lt;P&gt;thanks for clarify.&lt;/P&gt;&lt;P&gt;That's what I was trying to point it out before: I not making app to let users access their account, but I only need to share my own file with users who provide their email.&lt;/P&gt;&lt;P&gt;I take some time to find how to achieve what you mention and I will get back to Accept the solution.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Hello @Здравко,&lt;/P&gt;&lt;P&gt;I tried to simplify the process and I did not mentioned that I am using transactional emails templated with all information I need to send. So the URL it is just a small part of the information. An user subscribe providing his email and at this point I make the file available for download to him adding his email to my file. Then I send a transactional email with the URL and other information.&lt;/P&gt;&lt;P&gt;I am not requiring an user to login with a Dropbox account. They will not sync any file, just download it. Maybe the term "share" I used it is not the most accurate.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks for the support!&lt;/P&gt;</description>
      <pubDate>Wed, 05 Apr 2023 13:30:32 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Correct-way-to-use-quot-add-file-member-quot-endpoint-if-I-need/m-p/674549#M30417</guid>
      <dc:creator>lezan</dc:creator>
      <dc:date>2023-04-05T13:30:32Z</dc:date>
    </item>
  </channel>
</rss>

