<?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 Access Code not working when calling /oauth2/authorize with call back URL in Dropbox API Support &amp; Feedback</title>
    <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Access-Code-not-working-when-calling-oauth2-authorize-with-call/m-p/760184#M33203</link>
    <description>&lt;P&gt;&amp;nbsp;I have made an API which calls &lt;SPAN&gt;/oauth2/authorize to get access code which is used to get access token and refresh token, since this will be used in an automated process, when I call&amp;nbsp;&lt;SPAN&gt;/oauth2/authorize without callback url, the code I get it works by copying and using in&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;DIV&gt;&lt;SPAN&gt;&lt;SPAN&gt;/oauth2/token, but if I use it with callback URL it always returns "&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN&gt;response_body"&lt;/SPAN&gt;&lt;SPAN&gt;: &lt;/SPAN&gt;&lt;SPAN&gt;&lt;SPAN&gt;"{\"error\": \"invalid_grant\", \"error_description\": \"code has already been used\"}".&lt;BR /&gt;Call back url(&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN&gt;&lt;A href="http://localhost:5000/callback" target="_blank" rel="noopener"&gt;http://localhost:5000/callback&lt;/A&gt;&lt;/SPAN&gt;&lt;SPAN&gt;) is configured correctly, otherwise it should not be working when using code manually.&amp;nbsp;&lt;BR /&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="call back error.png" style="width: 800px;"&gt;&lt;img src="https://www.dropboxforum.com/t5/image/serverpage/image-id/45057i8141A2E0B8284CEA/image-size/large?v=v2&amp;amp;px=999" role="button" title="call back error.png" alt="call back error.png" /&gt;&lt;/span&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN&gt;&lt;SPAN&gt;&lt;SPAN&gt;&lt;A href="https://www.dropbox.com/oauth2/authorize?client_id=" target="_blank" rel="noopener"&gt;https://www.dropbox.com/oauth2/authorize?client_id=&lt;/A&gt;{&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN&gt;CLIENT_ID&lt;/SPAN&gt;&lt;SPAN&gt;}&amp;amp;token_access_type=offline&amp;amp;response_type=code&amp;amp;redirect_uri={&lt;/SPAN&gt;&lt;SPAN&gt;REDIRECT_URI&lt;/SPAN&gt;&lt;SPAN&gt;&lt;SPAN&gt;}&lt;BR /&gt;"grant_type":"&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN&gt;authorization_code"&lt;BR /&gt;&lt;BR /&gt;any assistance will be really helpful.&lt;BR /&gt;&lt;/SPAN&gt;&lt;/DIV&gt;</description>
    <pubDate>Wed, 27 Mar 2024 14:00:44 GMT</pubDate>
    <dc:creator>saqib-shafique</dc:creator>
    <dc:date>2024-03-27T14:00:44Z</dc:date>
    <item>
      <title>Access Code not working when calling /oauth2/authorize with call back URL</title>
      <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Access-Code-not-working-when-calling-oauth2-authorize-with-call/m-p/760184#M33203</link>
      <description>&lt;P&gt;&amp;nbsp;I have made an API which calls &lt;SPAN&gt;/oauth2/authorize to get access code which is used to get access token and refresh token, since this will be used in an automated process, when I call&amp;nbsp;&lt;SPAN&gt;/oauth2/authorize without callback url, the code I get it works by copying and using in&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;DIV&gt;&lt;SPAN&gt;&lt;SPAN&gt;/oauth2/token, but if I use it with callback URL it always returns "&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN&gt;response_body"&lt;/SPAN&gt;&lt;SPAN&gt;: &lt;/SPAN&gt;&lt;SPAN&gt;&lt;SPAN&gt;"{\"error\": \"invalid_grant\", \"error_description\": \"code has already been used\"}".&lt;BR /&gt;Call back url(&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN&gt;&lt;A href="http://localhost:5000/callback" target="_blank" rel="noopener"&gt;http://localhost:5000/callback&lt;/A&gt;&lt;/SPAN&gt;&lt;SPAN&gt;) is configured correctly, otherwise it should not be working when using code manually.&amp;nbsp;&lt;BR /&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="call back error.png" style="width: 800px;"&gt;&lt;img src="https://www.dropboxforum.com/t5/image/serverpage/image-id/45057i8141A2E0B8284CEA/image-size/large?v=v2&amp;amp;px=999" role="button" title="call back error.png" alt="call back error.png" /&gt;&lt;/span&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN&gt;&lt;SPAN&gt;&lt;SPAN&gt;&lt;A href="https://www.dropbox.com/oauth2/authorize?client_id=" target="_blank" rel="noopener"&gt;https://www.dropbox.com/oauth2/authorize?client_id=&lt;/A&gt;{&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN&gt;CLIENT_ID&lt;/SPAN&gt;&lt;SPAN&gt;}&amp;amp;token_access_type=offline&amp;amp;response_type=code&amp;amp;redirect_uri={&lt;/SPAN&gt;&lt;SPAN&gt;REDIRECT_URI&lt;/SPAN&gt;&lt;SPAN&gt;&lt;SPAN&gt;}&lt;BR /&gt;"grant_type":"&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN&gt;authorization_code"&lt;BR /&gt;&lt;BR /&gt;any assistance will be really helpful.&lt;BR /&gt;&lt;/SPAN&gt;&lt;/DIV&gt;</description>
      <pubDate>Wed, 27 Mar 2024 14:00:44 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Access-Code-not-working-when-calling-oauth2-authorize-with-call/m-p/760184#M33203</guid>
      <dc:creator>saqib-shafique</dc:creator>
      <dc:date>2024-03-27T14:00:44Z</dc:date>
    </item>
    <item>
      <title>Re: Access Code not working when calling /oauth2/authorize with call back URL</title>
      <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Access-Code-not-working-when-calling-oauth2-authorize-with-call/m-p/760226#M33204</link>
      <description>&lt;P&gt;Hi &lt;a href="https://www.dropboxforum.com/t5/user/viewprofilepage/user-id/1817437"&gt;@saqib-shafique&lt;/a&gt;,&lt;/P&gt;&lt;P&gt;As the error message says, you have tried your code more than once. &lt;img class="lia-deferred-image lia-image-emoji" src="https://www.dropboxforum.com/html/@FBF7D2AB59A0D6E861EBF6A36F93B7E2/emoticons/1f642.png" alt=":slightly_smiling_face:" title=":slightly_smiling_face:" /&gt; This code is for single time use only. Even more - if not some copy/paste mistake, your URL is incorrect. The ending ("grant_type":"authorization_code") has nothing to do there. If you cannot get in touch/understand with your error, post relevant code snippet letting the mistake reproduction here, so we may comment it. &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;</description>
      <pubDate>Wed, 27 Mar 2024 13:30:31 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Access-Code-not-working-when-calling-oauth2-authorize-with-call/m-p/760226#M33204</guid>
      <dc:creator>Здравко</dc:creator>
      <dc:date>2024-03-27T13:30:31Z</dc:date>
    </item>
  </channel>
</rss>

