Dropbox

Interact with the Dropbox API

Component key: dropbox

Description#

Dropbox is a file sharing platform that allows teams to collaborate and share files with one another.

The Dropbox component allows you to interact with the Dropbox API. You can upload, download, list, and move files within a Dropbox account.

Authorization Methods#

Dropbox requires one of the following authorization methods:

Auth TypeKeyDescriptionFields
API Keyapi_keyAPI authorization based on an API key

API Key |  api_key

OAuth 2.0 - Authorization Codeoauth2OAuth 2.0 authorization using the authorization code grant type

Authorization URL |  auth_uri

Client ID |  client_id

Client Secret |  client_secret

Scopes |  scopes

Access Token URL |  token_uri

You can use an API key or OAuth 2.0 app to authenticate customers' Dropbox accounts. Information about generating Dropbox OAuth2 Tokens can be found on their developer documentation site. Further information about setting up an OAuth 2.0 credential for Dropbox can be found in our docs.

Actions#

Copy Object#

Copy a Folder or File from one path to another | key: copyObject

InputKeyNotesExample

From Path

string
/ Required
fromPathThe location of a source file within a Dropbox share. Include a leading /./path/to/source/file.txt

To Path

string
/ Required
toPathThe location of a destination file within a Dropbox share. Include a leading /./path/to/destination/file.txt

Output Example Payload#

{
"data": {
"metaData": {
"id": "exampleId"
}
}
}

Create Folder#

Create a Folder at the specified path | key: createFolder

InputKeyNotesExample

Path

string
/ Required
pathThe location of a file within a Dropbox share. Include a leading /./path/to/file.txt

Output Example Payload#

{
"data": {
"metaData": {
"id": "exampleId"
}
}
}

Delete Object#

Delete a Folder or File at the specified path | key: deleteObject

InputKeyNotesExample

Path

string
/ Required
pathThe location of a file within a Dropbox share. Include a leading /./path/to/file.txt

Output Example Payload#

{
"data": {
"metaData": {
"id": "exampleId"
}
}
}

Download File#

Download the file (< 150MB) at the specified path | key: downloadFile

InputKeyNotesExample

Path

string
/ Required
pathThe location of a file within a Dropbox share. Include a leading /./path/to/file.txt

Output Example Payload#

{
"data": {
"data": [
101,
120,
97,
109,
112,
108,
101
],
"type": "Buffer"
},
"contentType": "application/octet"
}

List Folder#

List Folder contents at the specified path | key: listFolder

InputKeyNotesExample

Directory Path

string
pathThe path to a directory within a Dropbox share. Include a leading /./path/to/my/directory/

Output Example Payload#

{
"data": [
{
"id": "exampleId",
"rev": "revision-1",
"size": 2048
}
]
}

Move Object#

Move a Folder or File from one path to another | key: moveObject

InputKeyNotesExample

From Path

string
/ Required
fromPathThe location of a source file within a Dropbox share. Include a leading /./path/to/source/file.txt

To Path

string
/ Required
toPathThe location of a destination file within a Dropbox share. Include a leading /./path/to/destination/file.txt

Output Example Payload#

{
"data": {
"metaData": {
"id": "exampleId"
}
}
}

Upload File#

Upload a file to the specified path | key: uploadFile

InputKeyNotesExample

File Contents

data
/ Required
fileContentsThe contents to write to a file. This can be a string of text, it can be binary data (like an image or PDF) that was generated in a previous step.My File Contents

Path

string
/ Required
pathThe location of a file within a Dropbox share. Include a leading /./path/to/file.txt

Output Example Payload#

{
"data": {
"metaData": {
"id": "exampleId"
}
}
}