<?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: Issue in getting content of PDF/Doc etc in Dropbox API Support &amp; Feedback</title>
    <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Issue-in-getting-content-of-PDF-Doc-etc/m-p/530364#M25626</link>
    <description>&lt;P&gt;First, can you confirm that the "/test/BackcardHTTPS.pdf" file on Dropbox itself is not empty and does contain the expected data?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Then, can you inspect the API response? Check the status code; if it's not 200, then the call failed for some reason. You should also check the response headers for metadata, and response body for the file data, if the call succeeded. If it failed, there should be some error.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;By the way, you shouldn't post your access token like that. You should redact it from your image, and then &lt;A href="https://www.dropbox.com/developers/documentation/http/documentation#auth-token-revoke" target="_blank"&gt;revoke&lt;/A&gt; and replace it.&lt;/P&gt;</description>
    <pubDate>Thu, 01 Jul 2021 18:11:59 GMT</pubDate>
    <dc:creator>Greg-DB</dc:creator>
    <dc:date>2021-07-01T18:11:59Z</dc:date>
    <item>
      <title>Issue in getting content of PDF/Doc etc</title>
      <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Issue-in-getting-content-of-PDF-Doc-etc/m-p/530352#M25625</link>
      <description>&lt;P&gt;We are consuming dropbox api from our Delphi App.&lt;/P&gt;
&lt;P&gt;We are facing issue in getting PDF from dropbox(Upload,delete is working fine).&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="anandjpr_0-1625158442022.png" style="width: 400px;"&gt;&lt;img src="https://www.dropboxforum.com/t5/image/serverpage/image-id/24202i38283190707BB73C/image-size/medium?v=v2&amp;amp;px=400" role="button" title="anandjpr_0-1625158442022.png" alt="anandjpr_0-1625158442022.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Getting Blank PDF&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Except text file i am facing issue in getting file content(png,Doc,Pdf)&lt;BR /&gt;please suggest what wrong is happening there.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 08 Jul 2021 14:24:53 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Issue-in-getting-content-of-PDF-Doc-etc/m-p/530352#M25625</guid>
      <dc:creator>anandjpr</dc:creator>
      <dc:date>2021-07-08T14:24:53Z</dc:date>
    </item>
    <item>
      <title>Re: Issue in getting content of PDF/Doc etc</title>
      <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Issue-in-getting-content-of-PDF-Doc-etc/m-p/530364#M25626</link>
      <description>&lt;P&gt;First, can you confirm that the "/test/BackcardHTTPS.pdf" file on Dropbox itself is not empty and does contain the expected data?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Then, can you inspect the API response? Check the status code; if it's not 200, then the call failed for some reason. You should also check the response headers for metadata, and response body for the file data, if the call succeeded. If it failed, there should be some error.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;By the way, you shouldn't post your access token like that. You should redact it from your image, and then &lt;A href="https://www.dropbox.com/developers/documentation/http/documentation#auth-token-revoke" target="_blank"&gt;revoke&lt;/A&gt; and replace it.&lt;/P&gt;</description>
      <pubDate>Thu, 01 Jul 2021 18:11:59 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Issue-in-getting-content-of-PDF-Doc-etc/m-p/530364#M25626</guid>
      <dc:creator>Greg-DB</dc:creator>
      <dc:date>2021-07-01T18:11:59Z</dc:date>
    </item>
    <item>
      <title>Re: Issue in getting content of PDF/Doc etc</title>
      <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Issue-in-getting-content-of-PDF-Doc-etc/m-p/530368#M25627</link>
      <description>&lt;P&gt;I have checked&amp;nbsp; "&lt;SPAN&gt;BackcardHTTPS.pdf&lt;/SPAN&gt;" contain proper data.&lt;/P&gt;&lt;P&gt;And Api response is code is 200.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;When I am trying to read text file(*.txt) every thing is working fine.&lt;/P&gt;</description>
      <pubDate>Thu, 01 Jul 2021 18:29:38 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Issue-in-getting-content-of-PDF-Doc-etc/m-p/530368#M25627</guid>
      <dc:creator>anandjpr</dc:creator>
      <dc:date>2021-07-01T18:29:38Z</dc:date>
    </item>
    <item>
      <title>Re: Issue in getting content of PDF/Doc etc</title>
      <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Issue-in-getting-content-of-PDF-Doc-etc/m-p/530373#M25628</link>
      <description>&lt;P&gt;What about the rest of the response? What's in the headers and body?&lt;/P&gt;</description>
      <pubDate>Thu, 01 Jul 2021 18:49:05 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Issue-in-getting-content-of-PDF-Doc-etc/m-p/530373#M25628</guid>
      <dc:creator>Greg-DB</dc:creator>
      <dc:date>2021-07-01T18:49:05Z</dc:date>
    </item>
    <item>
      <title>Re: Issue in getting content of PDF/Doc etc</title>
      <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Issue-in-getting-content-of-PDF-Doc-etc/m-p/530473#M25630</link>
      <description>&lt;P&gt;&lt;STRONG&gt;Request Endpoint:&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;A href="https://content.dropboxapi.com/2/files/download" target="_blank" rel="noopener"&gt;https://content.dropboxapi.com/2/files/download&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;Request header:&lt;/STRONG&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;Authorization&amp;nbsp; :&amp;nbsp;Bearer &amp;lt;REDACTED&amp;gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;Dropbox-API-Arg :&amp;nbsp;{"path":"/test/BankcardHTTPS.pdf"}&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Please suggest why i am getting Blank PDF file.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 02 Jul 2021 13:45:53 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Issue-in-getting-content-of-PDF-Doc-etc/m-p/530473#M25630</guid>
      <dc:creator>anandjpr</dc:creator>
      <dc:date>2021-07-02T13:45:53Z</dc:date>
    </item>
    <item>
      <title>Re: Issue in getting content of PDF/Doc etc</title>
      <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Issue-in-getting-content-of-PDF-Doc-etc/m-p/530478#M25631</link>
      <description>&lt;P&gt;I am Sharing Sample Project code .&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Request you to please have a look and suggest what wrong happening there.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;Sample Code:&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;procedure TForm6.FormCreate(Sender: TObject);&lt;BR /&gt;var&lt;BR /&gt;url:string;&lt;BR /&gt;lParams: TStream;&lt;BR /&gt;FStream: TStream;&lt;BR /&gt;SaveDir,TempFile:AnsiString;&lt;BR /&gt;MyText: TStringlist;&lt;BR /&gt;req:string;&lt;BR /&gt;response:AnsiString;&lt;BR /&gt;Base64: string;&lt;/P&gt;
&lt;P&gt;Input: TStringStream;&lt;BR /&gt;Output: TFileStream;&lt;/P&gt;
&lt;P&gt;begin&lt;BR /&gt;try&lt;BR /&gt;FStream := TStringStream.Create;&lt;BR /&gt;MyText:= TStringlist.create();&lt;BR /&gt;try&lt;/P&gt;
&lt;P&gt;IdHTTP1.Request.CustomHeaders.Values['Dropbox-API-Arg'] :='{"path":"/test/BankcardHTTPS.pdf"}';&lt;BR /&gt;IdHTTP1.Request.CustomHeaders.Values['Authorization'] := 'Bearer &amp;lt;REDACTED&amp;gt;';&lt;BR /&gt;response:=IdHTTP1.Post('&lt;A href="https://content.dropboxapi.com/2/files/download',FStream" target="_blank" rel="noopener"&gt;https://content.dropboxapi.com/2/files/download',FStream&lt;/A&gt;);&lt;/P&gt;
&lt;P&gt;MyText.Add(response);&lt;BR /&gt;MyText.SaveToFile('.\BankcardHTTPS.pdf');&lt;/P&gt;
&lt;P&gt;except&lt;BR /&gt;on E: Exception do&lt;BR /&gt;begin&lt;BR /&gt;ShowMessage('Error: ' + E.Message);&lt;BR /&gt;end;&lt;BR /&gt;end;&lt;BR /&gt;finally&lt;BR /&gt;lParams.Free;&lt;BR /&gt;MyText.Free;&lt;BR /&gt;end;&lt;BR /&gt;end;&lt;/P&gt;</description>
      <pubDate>Fri, 02 Jul 2021 13:45:59 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Issue-in-getting-content-of-PDF-Doc-etc/m-p/530478#M25631</guid>
      <dc:creator>anandjpr</dc:creator>
      <dc:date>2021-07-02T13:45:59Z</dc:date>
    </item>
    <item>
      <title>Re: Issue in getting content of PDF/Doc etc</title>
      <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Issue-in-getting-content-of-PDF-Doc-etc/m-p/530509#M25632</link>
      <description>&lt;P&gt;Any Update.&lt;/P&gt;</description>
      <pubDate>Fri, 02 Jul 2021 10:50:37 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Issue-in-getting-content-of-PDF-Doc-etc/m-p/530509#M25632</guid>
      <dc:creator>anandjpr</dc:creator>
      <dc:date>2021-07-02T10:50:37Z</dc:date>
    </item>
    <item>
      <title>Re: Issue in getting content of PDF/Doc etc</title>
      <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Issue-in-getting-content-of-PDF-Doc-etc/m-p/530540#M25634</link>
      <description>&lt;P&gt;This shows your request headers and code, but not the response headers or body. Can you inspect the response headers/body?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Also, do not post your access token, since it enables access to your account. You should &lt;A href="https://www.dropbox.com/developers/documentation/http/documentation#auth-token-revoke" target="_blank"&gt;revoke&lt;/A&gt; it since you've posted it publicly.&lt;/P&gt;</description>
      <pubDate>Fri, 02 Jul 2021 13:47:42 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Issue-in-getting-content-of-PDF-Doc-etc/m-p/530540#M25634</guid>
      <dc:creator>Greg-DB</dc:creator>
      <dc:date>2021-07-02T13:47:42Z</dc:date>
    </item>
    <item>
      <title>Re: Issue in getting content of PDF/Doc etc</title>
      <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Issue-in-getting-content-of-PDF-Doc-etc/m-p/530556#M25635</link>
      <description>&lt;P&gt;Sorry i missed to share &lt;STRONG&gt;response&lt;/STRONG&gt; in last chat.&lt;/P&gt;&lt;P&gt;I have saved response in txt fine and sharing screenshot with you.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="anandjpr_1-1625237270274.png" style="width: 400px;"&gt;&lt;img src="https://www.dropboxforum.com/t5/image/serverpage/image-id/24212i1C742C8E68416535/image-size/medium?v=v2&amp;amp;px=400" role="button" title="anandjpr_1-1625237270274.png" alt="anandjpr_1-1625237270274.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 02 Jul 2021 14:47:54 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Issue-in-getting-content-of-PDF-Doc-etc/m-p/530556#M25635</guid>
      <dc:creator>anandjpr</dc:creator>
      <dc:date>2021-07-02T14:47:54Z</dc:date>
    </item>
    <item>
      <title>Re: Issue in getting content of PDF/Doc etc</title>
      <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Issue-in-getting-content-of-PDF-Doc-etc/m-p/530559#M25636</link>
      <description>&lt;P&gt;Thanks! That does show the raw PDF data, indicating that the Dropbox API call itself did succeed and return the file data.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;That being the case, it looks like the issue here is with writing that data to the local filesystem. As that's not related to the Dropbox API itself, I'm afraid I can't offer much help with that. You'll need to debug that part of your code, such as the "SaveToFile" method. For instance, make sure you have the right local path and that you have the permissions needed to write to that path.&lt;/P&gt;</description>
      <pubDate>Fri, 02 Jul 2021 15:03:46 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Issue-in-getting-content-of-PDF-Doc-etc/m-p/530559#M25636</guid>
      <dc:creator>Greg-DB</dc:creator>
      <dc:date>2021-07-02T15:03:46Z</dc:date>
    </item>
    <item>
      <title>Re: Issue in getting content of PDF/Doc etc</title>
      <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Issue-in-getting-content-of-PDF-Doc-etc/m-p/530565#M25637</link>
      <description>&lt;P&gt;Thank you for your response.&lt;/P&gt;</description>
      <pubDate>Fri, 02 Jul 2021 15:47:23 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Issue-in-getting-content-of-PDF-Doc-etc/m-p/530565#M25637</guid>
      <dc:creator>anandjpr</dc:creator>
      <dc:date>2021-07-02T15:47:23Z</dc:date>
    </item>
  </channel>
</rss>

