Since we're on a major migration process of this website, some component documents here are out of sync right now. In the meantime you may want to look at the early version of the new website
https://camel.apache.org/staging/
We would very much like to receive any feedback on the new site, please join the discussion on the Camel user mailing list.
Camel Dropbox componentAvailable as of Camel 2.14 The dropbox: component allows you to treat Dropbox remote folders as a producer or consumer of messages. Using the Dropbox Java Core API (reference version for this component is 1.7.x), this camel component has the following features:
Maven users will need to add the following dependency to their <dependency> <groupId>org.apache.camel</groupId> <artifactId>camel-dropbox</artifactId> <version>x.x.x</version> <!-- use the same version as your Camel core version --> </dependency> URI formatdropbox://[operation]?[options] Where operation is the specific action (typically is a CRUD action) to perform on Dropbox remote folder. Operations
Operations require additional options to work, some are mandatory for the specific operation. OptionsIn order to work with Dropbox API you need to obtain an accessToken and a clientIdentifier. Below are listed the mandatory options for all operations:
Del operationDelete files on Dropbox. Works only as Camel producer. Below are listed the options for this operation:
Samplesfrom("direct:start").to("dropbox://del?accessToken=XXX&clientIdentifier=XXX&remotePath=/root/folder1").to("mock:result"); from("direct:start").to("dropbox://del?accessToken=XXX&clientIdentifier=XXX&remotePath=/root/folder1/file1.tar.gz").to("mock:result"); Result Message HeadersThe following headers are set on message result:
Result Message BodyThe following objects are set on message body result:
Get (download) operationDownload files from Dropbox. Works as Camel producer or Camel consumer. Below are listed the options for this operation:
Samplesfrom("direct:start").to("dropbox://get?accessToken=XXX&clientIdentifier=XXX&remotePath=/root/folder1/file1.tar.gz").to("file:///home/kermit/?fileName=file1.tar.gz"); from("direct:start").to("dropbox://get?accessToken=XXX&clientIdentifier=XXX&remotePath=/root/folder1").to("mock:result"); from("dropbox://get?accessToken=XXX&clientIdentifier=XXX&remotePath=/root/folder1").to("file:///home/kermit/"); Result Message HeadersThe following headers are set on message result:
Result Message BodyThe following objects are set on message body result:
Move operationMove files on Dropbox between one folder to another. Works only as Camel producer. Below are listed the options for this operation:
Samplesfrom("direct:start").to("dropbox://move?accessToken=XXX&clientIdentifier=XXX&remotePath=/root/folder1&newRemotePath=/root/folder2").to("mock:result"); Result Message HeadersThe following headers are set on message result:
Result Message BodyThe following objects are set on message body result:
Put (upload) operationUpload files on Dropbox. Works as Camel producer. Below are listed the options for this operation:
Samplesfrom("direct:start").to("dropbox://put?accessToken=XXX&clientIdentifier=XXX&uploadMode=add&localPath=/root/folder1").to("mock:result"); from("direct:start").to("dropbox://put?accessToken=XXX&clientIdentifier=XXX&uploadMode=add&localPath=/root/folder1&remotePath=/root/folder2").to("mock:result"); Result Message HeadersThe following headers are set on message result:
Result Message BodyThe following objects are set on message body result:
Search operationSearch inside a remote Dropbox folder including its sub directories. Works as Camel producer and as Camel consumer. Below are listed the options for this operation:
Samplesfrom("dropbox://search?accessToken=XXX&clientIdentifier=XXX&remotePath=/XXX&query=XXX").to("mock:result"); from("direct:start").to("dropbox://search?accessToken=XXX&clientIdentifier=XXX&remotePath=/XXX").to("mock:result"); Result Message HeadersThe following headers are set on message result:
Result Message BodyThe following objects are set on message body result:
|