<?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: Delete a file using Java api v2 in Dropbox API Support &amp; Feedback</title>
    <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Delete-a-file-using-Java-api-v2/m-p/358482#M20431</link>
    <description>&lt;P&gt;Hi Greg,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am not able to use the same "delete" method using Dropbox V2 API.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Error:&lt;/P&gt;&lt;P&gt;Unknown error occured :String 'path' does not match pattern&lt;/P&gt;&lt;P&gt;I am getting this error, when i pass path as "id:somevalue" , whereas same is working from Dropbox API Explorer.&lt;/P&gt;</description>
    <pubDate>Fri, 02 Aug 2019 12:32:37 GMT</pubDate>
    <dc:creator>cgirecruitment1</dc:creator>
    <dc:date>2019-08-02T12:32:37Z</dc:date>
    <item>
      <title>Delete a file using Java api v2</title>
      <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Delete-a-file-using-Java-api-v2/m-p/168947#M6220</link>
      <description>&lt;P&gt;How do I delete a file using the java api v2. &amp;nbsp;I found DeleteArg, but it doesn't seem to do any thing??? &amp;nbsp;Thanks.&lt;/P&gt;</description>
      <pubDate>Wed, 29 May 2019 09:29:41 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Delete-a-file-using-Java-api-v2/m-p/168947#M6220</guid>
      <dc:creator>Dan R.23</dc:creator>
      <dc:date>2019-05-29T09:29:41Z</dc:date>
    </item>
    <item>
      <title>Re: Delete a file using Java api v2</title>
      <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Delete-a-file-using-Java-api-v2/m-p/168948#M6221</link>
      <description>&lt;P&gt;Hi Dan, you can use the &lt;A href="https://dropbox.github.io/dropbox-sdk-java/api-docs/v2.1.x/com/dropbox/core/v2/files/DbxUserFilesRequests.html#delete-java.lang.String-" target="_blank" rel="nofollow noreferrer"&gt;delete method in&amp;nbsp;DbxUserFilesRequests&lt;/A&gt;. For example:&lt;/P&gt;
&lt;PRE&gt;Metadata metadata = client.files().delete(path);&lt;/PRE&gt;
&lt;P&gt;Hope this helps!&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 28 Sep 2016 02:34:31 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Delete-a-file-using-Java-api-v2/m-p/168948#M6221</guid>
      <dc:creator>Greg-DB</dc:creator>
      <dc:date>2016-09-28T02:34:31Z</dc:date>
    </item>
    <item>
      <title>Re: Delete a file using Java api v2</title>
      <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Delete-a-file-using-Java-api-v2/m-p/168949#M6222</link>
      <description>&lt;P&gt;I found it.&lt;/P&gt;
&lt;PRE&gt;FileMetadata deleteFile = (FileMetadata) dbxClient.files()&lt;BR /&gt;.delete(oldVersionPath);&lt;BR /&gt;&lt;BR /&gt;thanks to my ide. Really would be cool if there was some documentation&lt;BR /&gt;and better examples for this api, or a search tool... Seems like there would&lt;BR /&gt;be by now.&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/PRE&gt;</description>
      <pubDate>Wed, 28 Sep 2016 02:37:49 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Delete-a-file-using-Java-api-v2/m-p/168949#M6222</guid>
      <dc:creator>Dan R.23</dc:creator>
      <dc:date>2016-09-28T02:37:49Z</dc:date>
    </item>
    <item>
      <title>Re: Delete a file using Java api v2</title>
      <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Delete-a-file-using-Java-api-v2/m-p/168950#M6223</link>
      <description>&lt;P&gt;Hey thanks Gregory, didn't see your response until i sent mine.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 28 Sep 2016 02:50:40 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Delete-a-file-using-Java-api-v2/m-p/168950#M6223</guid>
      <dc:creator>Dan R.23</dc:creator>
      <dc:date>2016-09-28T02:50:40Z</dc:date>
    </item>
    <item>
      <title>Re: Delete a file using Java api v2</title>
      <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Delete-a-file-using-Java-api-v2/m-p/220837#M11703</link>
      <description>&lt;P&gt;Hy!&lt;/P&gt;
&lt;P&gt;When I try to run my code it displays the following error:&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;"Exception in thread "Thread-2" java.lang.NoSuchMethodError: com.dropbox.core.DbxHost.getApi()Ljava/lang/String;
at com.dropbox.core.v2.files.DbxUserFilesRequests.delete(DbxUserFilesRequests.java:218)
at com.dropbox.core.v2.files.DbxUserFilesRequests.delete(DbxUserFilesRequests.java:248)"&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;My code:&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;public Metadata delete(String path) throws DeleteErrorException, DbxException{

Metadata metadata = null;

DbxRequestConfig config = new DbxRequestConfig(
"JavaTutorial/1.0", Locale.getDefault().toString());

try{

//DbxHost DEFAULT = new DbxHost("api.dropboxapi.com","content.dropboxapi.com","www.dropbox.com","notify.dropboxapi.com");

DbxClientV2 cli = new DbxClientV2(config, "&amp;lt;REDACTED&amp;gt;", DbxHost.Default);
metadata = cli.files().delete(path);

cli.files().delete(path);

JOptionPane.showMessageDialog(null, "apagado");

}catch(DbxException | HeadlessException erro){

JOptionPane.showMessageDialog(null, erro);

}

return metadata;

}&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 12 May 2017 20:51:18 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Delete-a-file-using-Java-api-v2/m-p/220837#M11703</guid>
      <dc:creator>MarcoLI</dc:creator>
      <dc:date>2017-05-12T20:51:18Z</dc:date>
    </item>
    <item>
      <title>Re: Delete a file using Java api v2</title>
      <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Delete-a-file-using-Java-api-v2/m-p/220937#M11714</link>
      <description>&lt;P&gt;&lt;a href="https://www.dropboxforum.com/t5/user/viewprofilepage/user-id/398304"&gt;@MarcoLI&lt;/a&gt;&amp;nbsp;I can't seem to reproduce this error. What version of the SDK do you have installed?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;In any case, a few things I noticed:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;- You don't need to redefine the&amp;nbsp;Dropbox hosts. (Though, you have it commented it out anyway.)&lt;/P&gt;
&lt;P&gt;- You don't need to pass in the&amp;nbsp;Dropbox hosts manually. You should just use &lt;A href="https://dropbox.github.io/dropbox-sdk-java/api-docs/v2.1.x/com/dropbox/core/v2/DbxClientV2.html#DbxClientV2-com.dropbox.core.DbxRequestConfig-java.lang.String-" target="_self"&gt;the DbxClientV2 constructor that doesn't take a DbxHost&lt;/A&gt;.&lt;/P&gt;
&lt;P&gt;- If you do pass it in explicitly, it should be &lt;A href="https://dropbox.github.io/dropbox-sdk-java/api-docs/v2.1.x/com/dropbox/core/DbxHost.html#DEFAULT" target="_self"&gt;DbxHost.DEFAULT&lt;/A&gt;, not&amp;nbsp;DbxHost.Default.&lt;/P&gt;
&lt;P&gt;- I redacted it from your post, but you should &lt;A href="https://dropbox.github.io/dropbox-sdk-java/api-docs/v2.1.x/com/dropbox/core/v2/auth/DbxUserAuthRequests.html#tokenRevoke--" target="_self"&gt;revoke that access token&lt;/A&gt;&amp;nbsp;since you posted it publicly.&lt;/P&gt;</description>
      <pubDate>Fri, 12 May 2017 21:03:52 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Delete-a-file-using-Java-api-v2/m-p/220937#M11714</guid>
      <dc:creator>Greg-DB</dc:creator>
      <dc:date>2017-05-12T21:03:52Z</dc:date>
    </item>
    <item>
      <title>Re: Delete a file using Java api v2</title>
      <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Delete-a-file-using-Java-api-v2/m-p/222245#M11846</link>
      <description>hi i've got the same issue have you found a solution yet?</description>
      <pubDate>Sun, 21 May 2017 16:43:51 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Delete-a-file-using-Java-api-v2/m-p/222245#M11846</guid>
      <dc:creator>wei-qiang</dc:creator>
      <dc:date>2017-05-21T16:43:51Z</dc:date>
    </item>
    <item>
      <title>Re: Delete a file using Java api v2</title>
      <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Delete-a-file-using-Java-api-v2/m-p/222410#M11884</link>
      <description>&lt;P&gt;&lt;a href="https://www.dropboxforum.com/t5/user/viewprofilepage/user-id/403684"&gt;@wei-qiang&lt;/a&gt;&amp;nbsp;We'll be happy to help with whatever issues you're having with the&amp;nbsp;Dropbox API. Please feel free to open a new thread with the relevant code and the full error/output you're getting:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;A href="https://www.dropboxforum.com/t5/forums/postpage/board-id/101000014" target="_self"&gt;https://www.dropboxforum.com/t5/forums/postpage/board-id/101000014&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 22 May 2017 18:14:25 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Delete-a-file-using-Java-api-v2/m-p/222410#M11884</guid>
      <dc:creator>Greg-DB</dc:creator>
      <dc:date>2017-05-22T18:14:25Z</dc:date>
    </item>
    <item>
      <title>Re: Delete a file using Java api v2</title>
      <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Delete-a-file-using-Java-api-v2/m-p/358482#M20431</link>
      <description>&lt;P&gt;Hi Greg,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am not able to use the same "delete" method using Dropbox V2 API.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Error:&lt;/P&gt;&lt;P&gt;Unknown error occured :String 'path' does not match pattern&lt;/P&gt;&lt;P&gt;I am getting this error, when i pass path as "id:somevalue" , whereas same is working from Dropbox API Explorer.&lt;/P&gt;</description>
      <pubDate>Fri, 02 Aug 2019 12:32:37 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Delete-a-file-using-Java-api-v2/m-p/358482#M20431</guid>
      <dc:creator>cgirecruitment1</dc:creator>
      <dc:date>2019-08-02T12:32:37Z</dc:date>
    </item>
    <item>
      <title>Re: Delete a file using Java api v2</title>
      <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Delete-a-file-using-Java-api-v2/m-p/358493#M20433</link>
      <description>&lt;P&gt;&lt;a href="https://www.dropboxforum.com/t5/user/viewprofilepage/user-id/1192872"&gt;@cgirecruitment1&lt;/a&gt;&amp;nbsp;You should be able to use the delete method with file IDs. Can you share the actual code and path parameter value you're using that's resulting in this error?&amp;nbsp;Thanks in advance!&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 02 Aug 2019 13:27:23 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Delete-a-file-using-Java-api-v2/m-p/358493#M20433</guid>
      <dc:creator>Greg-DB</dc:creator>
      <dc:date>2019-08-02T13:27:23Z</dc:date>
    </item>
    <item>
      <title>Re: Delete a file using Java api v2</title>
      <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Delete-a-file-using-Java-api-v2/m-p/358774#M20442</link>
      <description>&lt;P&gt;Yes. My code looks like this:&lt;/P&gt;&lt;P&gt;public String deleteFile(String path)&lt;BR /&gt;throws DbxException {&lt;/P&gt;&lt;P&gt;DbxRequestConfig requestConfig = DbxRequestConfig.newBuilder("Dropbox Documents Delete").build();&lt;BR /&gt;DbxClientV2 client = new DbxClientV2(requestConfig, "AccessToken");&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;FileMetadata fileMetadata = (FileMetadata) client.files().delete(path);&lt;BR /&gt;return fileMetadata.getId();&lt;BR /&gt;}&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Path Parameter:&amp;nbsp;&amp;nbsp;&lt;SPAN&gt;id:MWWBdvN6DaAAAAAAAAAAwA&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 05 Aug 2019 13:45:44 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Delete-a-file-using-Java-api-v2/m-p/358774#M20442</guid>
      <dc:creator>cgirecruitment1</dc:creator>
      <dc:date>2019-08-05T13:45:44Z</dc:date>
    </item>
    <item>
      <title>Re: Delete a file using Java api v2</title>
      <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Delete-a-file-using-Java-api-v2/m-p/358775#M20443</link>
      <description>The Error: String 'path' does not match pattern</description>
      <pubDate>Mon, 05 Aug 2019 13:46:43 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Delete-a-file-using-Java-api-v2/m-p/358775#M20443</guid>
      <dc:creator>cgirecruitment1</dc:creator>
      <dc:date>2019-08-05T13:46:43Z</dc:date>
    </item>
    <item>
      <title>Re: Delete a file using Java api v2</title>
      <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Delete-a-file-using-Java-api-v2/m-p/358788#M20445</link>
      <description>&lt;P&gt;&lt;a href="https://www.dropboxforum.com/t5/user/viewprofilepage/user-id/1192872"&gt;@cgirecruitment1&lt;/a&gt;&amp;nbsp;I see you opened a new thread for this so I'll follow up there:&amp;nbsp;&lt;A href="https://www.dropboxforum.com/t5/API-Support-Feedback/Delete-File-delete-path-not-working/m-p/358771#M20440" target="_blank"&gt;https://www.dropboxforum.com/t5/API-Support-Feedback/Delete-File-delete-path-not-working/m-p/358771#M20440&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 05 Aug 2019 14:21:21 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Delete-a-file-using-Java-api-v2/m-p/358788#M20445</guid>
      <dc:creator>Greg-DB</dc:creator>
      <dc:date>2019-08-05T14:21:21Z</dc:date>
    </item>
  </channel>
</rss>

