<?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: Upload file with special characters will get INVALID_PATH error with non-json format in Dropbox API Support &amp; Feedback</title>
    <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Upload-file-with-special-characters-will-get-INVALID-PATH-error/m-p/465985#M23778</link>
    <description>&lt;P&gt;Yes, depending on the kind of error, the response may be plain text or JSON. You should check the 'Content-Type' response header to check what it is.&amp;nbsp;For example, in this sample you shared it's "text/plain; charset=utf-8". You can find &lt;A href="https://www.dropbox.com/developers/documentation/http/documentation#error-handling" target="_self"&gt;more information on the different kinds of errors the&amp;nbsp;Dropbox API may return in the documentation here.&lt;/A&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Please also refer to &lt;A href="https://www.dropbox.com/developers/reference/json-encoding" target="_self"&gt;this document for information on how to properly encode special characters&lt;/A&gt; in parameters when calling content-download and content-upload endpoints like this.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;You can also refer to &lt;A href="https://help.dropbox.com/installs-integrations/sync-uploads/files-not-syncing" target="_self"&gt;this article&lt;/A&gt; for information on reserved and ignored paths in general.&lt;/P&gt;</description>
    <pubDate>Fri, 30 Oct 2020 14:18:58 GMT</pubDate>
    <dc:creator>Greg-DB</dc:creator>
    <dc:date>2020-10-30T14:18:58Z</dc:date>
    <item>
      <title>Upload file with special characters will get INVALID_PATH error with non-json format</title>
      <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Upload-file-with-special-characters-will-get-INVALID-PATH-error/m-p/465905#M23773</link>
      <description>&lt;P&gt;When trying to upload a file with special character to dropbox, dropbox server will response http code 400 and the error message is non-json format with error response "&lt;FONT color="#FF0000"&gt;Error in call to API function "files/upload": Invalid path: INVALID_PATH&lt;/FONT&gt;". This kind of error message is not well defined in API documents.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Does it is expected behavior and will it possible to align the error behavior to another json-style error response.&lt;/P&gt;
&lt;P&gt;Or is there a official document to defined non-json format style error.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Example:&lt;/P&gt;
&lt;P&gt;&lt;FONT color="#0000FF"&gt;curl -v -X POST &lt;A href="https://content.dropboxapi.com/2/files/upload" target="_blank" rel="noopener"&gt;https://content.dropboxapi.com/2/files/upload&lt;/A&gt; --header "Authorization: Bearer access_token" --header "Dropbox-API-Arg: {\"path\": \"/folder1/�}�֌W\",\"mode\": \"add\",\"autorename\": false,\"mute\": false}" --header "Content-Type: application/octet-stream" --data-binary &lt;a href="https://www.dropboxforum.com/t5/user/viewprofilepage/user-id/61275"&gt;@test&lt;/a&gt;.pdf&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;gt; POST /2/files/upload HTTP/1.1&lt;BR /&gt;&amp;gt; Host: content.dropboxapi.com&lt;BR /&gt;&amp;gt; User-Agent: curl/7.54.0&lt;BR /&gt;&amp;gt; Accept: */*&lt;BR /&gt;&amp;gt; Authorization: Bearer access_token&lt;BR /&gt;&amp;gt; Dropbox-API-Arg: {"path": "/folder1/�}�֌W","mode": "add","autorename": false,"mute": false}&lt;BR /&gt;&amp;gt; Content-Type: application/octet-stream&lt;BR /&gt;&amp;gt; Content-Length: 0&lt;BR /&gt;&amp;gt;&lt;BR /&gt;&amp;lt; HTTP/1.1 400 Bad Request&lt;BR /&gt;&amp;lt; Server: envoy&lt;BR /&gt;&amp;lt; Date: Fri, 30 Oct 2020 08:29:00 GMT&lt;BR /&gt;&amp;lt; Content-Type: text/plain; charset=utf-8&lt;BR /&gt;&amp;lt; Content-Security-Policy: sandbox allow-forms allow-scripts&lt;BR /&gt;&amp;lt; X-Dropbox-Request-Id: 5a99ff1dacac40da8df0f9439dc8c4f4&lt;BR /&gt;&amp;lt; X-Robots-Tag: noindex, nofollow, noimageindex&lt;BR /&gt;&amp;lt; Strict-Transport-Security: max-age=31536000; includeSubDomains&lt;BR /&gt;&amp;lt; X-Robots-Tag: noindex, nofollow, noimageindex&lt;BR /&gt;&amp;lt; Vary: Accept-Encoding&lt;BR /&gt;&amp;lt; Transfer-Encoding: chunked&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT color="#FF0000"&gt;Error in call to API function "files/upload": Invalid path: INVALID_PATH&lt;/FONT&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 30 Oct 2020 10:47:28 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Upload-file-with-special-characters-will-get-INVALID-PATH-error/m-p/465905#M23773</guid>
      <dc:creator>Cloud</dc:creator>
      <dc:date>2020-10-30T10:47:28Z</dc:date>
    </item>
    <item>
      <title>Re: Upload file with special characters will get INVALID_PATH error with non-json format</title>
      <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Upload-file-with-special-characters-will-get-INVALID-PATH-error/m-p/465985#M23778</link>
      <description>&lt;P&gt;Yes, depending on the kind of error, the response may be plain text or JSON. You should check the 'Content-Type' response header to check what it is.&amp;nbsp;For example, in this sample you shared it's "text/plain; charset=utf-8". You can find &lt;A href="https://www.dropbox.com/developers/documentation/http/documentation#error-handling" target="_self"&gt;more information on the different kinds of errors the&amp;nbsp;Dropbox API may return in the documentation here.&lt;/A&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Please also refer to &lt;A href="https://www.dropbox.com/developers/reference/json-encoding" target="_self"&gt;this document for information on how to properly encode special characters&lt;/A&gt; in parameters when calling content-download and content-upload endpoints like this.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;You can also refer to &lt;A href="https://help.dropbox.com/installs-integrations/sync-uploads/files-not-syncing" target="_self"&gt;this article&lt;/A&gt; for information on reserved and ignored paths in general.&lt;/P&gt;</description>
      <pubDate>Fri, 30 Oct 2020 14:18:58 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Upload-file-with-special-characters-will-get-INVALID-PATH-error/m-p/465985#M23778</guid>
      <dc:creator>Greg-DB</dc:creator>
      <dc:date>2020-10-30T14:18:58Z</dc:date>
    </item>
  </channel>
</rss>

