# Dropbox (/integrations/dropbox)





{/* MANUAL-CONTENT-START:intro */}

Use [Dropbox](https://dropbox.com/) to upload and download files, list folder contents, search files and folders, create folders, and manage shared links. The actions also move or rename files and folders. Delete File/Folder moves them to the trash. Select a connected Dropbox credential and the path or item identifier required by the action.

{/* MANUAL-CONTENT-END */}

## OAuth scopes [#oauth-scopes]

Sim requests these scopes when someone connects a Dropbox account. For a self-hosted deployment, register your own app with the provider using the settings below. See [Integrations and OAuth](/platform/self-hosting/integrations-oauth) for setup.

| Setting | Value |
| - | - |
| Redirect URI | `<NEXT_PUBLIC_APP_URL>/api/auth/oauth2/callback/dropbox` |
| Environment variables | `DROPBOX_CLIENT_ID`, `DROPBOX_CLIENT_SECRET` |

| Scope | Description |
| - | - |
| `account_info.read` | View Dropbox account information |
| `files.metadata.read` | View file and folder names, sizes, and dates |
| `files.metadata.write` | Modify file and folder metadata |
| `files.content.read` | Download and read Dropbox files |
| `files.content.write` | Upload, copy, move, and delete files in Dropbox |
| `sharing.read` | View shared files and folders |
| `sharing.write` | Share files and folders with others |

## Use the block [#usage-instructions]

Upload and download files, list folder contents, search files and folders, create folders, manage shared links, and move items between folders or to the trash.

## Actions [#actions]

### Dropbox Upload File [#dropbox-upload-file]

Upload a file to Dropbox

<ReferenceDetails>
  #### Input [#input]

  | Parameter | Type | Required | Description |
  | - | - | - | - |
  | `path` | string | Yes | The path in Dropbox where the file should be saved (e.g., /folder/document.pdf) |
  | `file` | file | No | The file to upload (UserFile object) |
  | `fileName` | string | No | Optional filename (used if path is a folder) |
  | `mode` | string | No | Write mode: add (default) or overwrite |
  | `autorename` | boolean | No | If true, rename the file if there is a conflict |
  | `mute` | boolean | No | If true, don't notify the user about this upload |

  #### Output [#output]

  | Parameter | Type | Description |
  | - | - | - |
  | `file` | object | The uploaded file metadata |
  | ↳ `id` | string | Unique identifier for the file |
  | ↳ `name` | string | Name of the file |
  | ↳ `path_display` | string | Display path of the file |
  | ↳ `path_lower` | string | Lowercase path of the file |
  | ↳ `size` | number | Size of the file in bytes |
  | ↳ `client_modified` | string | Client modification time |
  | ↳ `server_modified` | string | Server modification time |
  | ↳ `rev` | string | Revision identifier |
  | ↳ `content_hash` | string | Content hash for the file |
</ReferenceDetails>

### Dropbox Download File [#dropbox-download-file]

Download a file from Dropbox with metadata

<ReferenceDetails>
  #### Input [#input-1]

  | Parameter | Type | Required | Description |
  | - | - | - | - |
  | `path` | string | Yes | The path of the file to download (e.g., /folder/document.pdf) |

  #### Output [#output-1]

  | Parameter | Type | Description |
  | - | - | - |
  | `file` | file | Downloaded file stored in execution files |
  | `metadata` | json | The file metadata |
  | `temporaryLink` | string | Temporary link to download the file (valid for \~4 hours) |
</ReferenceDetails>

### Dropbox List Folder [#dropbox-list-folder]

List the contents of a folder in Dropbox

<ReferenceDetails>
  #### Input [#input-2]

  | Parameter | Type | Required | Description |
  | - | - | - | - |
  | `path` | string | Yes | The path of the folder to list (use "" for root) |
  | `recursive` | boolean | No | If true, list contents recursively |
  | `includeDeleted` | boolean | No | If true, include deleted files/folders |
  | `includeMediaInfo` | boolean | No | If true, include media info for photos/videos |
  | `limit` | number | No | Maximum number of results to return (default: 500) |

  #### Output [#output-2]

  | Parameter | Type | Description |
  | - | - | - |
  | `entries` | array | List of files and folders in the directory |
  | ↳ `id` | string | Unique identifier |
  | ↳ `name` | string | Name of the file/folder |
  | ↳ `path_display` | string | Display path |
  | ↳ `size` | number | Size in bytes (files only) |
  | `cursor` | string | Cursor for pagination |
  | `hasMore` | boolean | Whether there are more results |
</ReferenceDetails>

### Dropbox Create Folder [#dropbox-create-folder]

Create a new folder in Dropbox

<ReferenceDetails>
  #### Input [#input-3]

  | Parameter | Type | Required | Description |
  | - | - | - | - |
  | `path` | string | Yes | The path where the folder should be created (e.g., /new-folder) |
  | `autorename` | boolean | No | If true, rename the folder if there is a conflict |

  #### Output [#output-3]

  | Parameter | Type | Description |
  | - | - | - |
  | `folder` | object | The created folder metadata |
  | ↳ `id` | string | Unique identifier for the folder |
  | ↳ `name` | string | Name of the folder |
  | ↳ `path_display` | string | Display path of the folder |
  | ↳ `path_lower` | string | Lowercase path of the folder |
</ReferenceDetails>

### Dropbox Delete [#dropbox-delete]

Delete a file or folder in Dropbox (moves to trash)

<ReferenceDetails>
  #### Input [#input-4]

  | Parameter | Type | Required | Description |
  | - | - | - | - |
  | `path` | string | Yes | The path of the file or folder to delete |

  #### Output [#output-4]

  | Parameter | Type | Description |
  | - | - | - |
  | `metadata` | object | Metadata of the deleted item |
  | ↳ `name` | string | Name of the deleted item |
  | ↳ `path_display` | string | Display path |
  | `deleted` | boolean | Whether the deletion was successful |
</ReferenceDetails>

### Dropbox Copy [#dropbox-copy]

Copy a file or folder in Dropbox

<ReferenceDetails>
  #### Input [#input-5]

  | Parameter | Type | Required | Description |
  | - | - | - | - |
  | `fromPath` | string | Yes | The source path of the file or folder to copy |
  | `toPath` | string | Yes | The destination path for the copied file or folder |
  | `autorename` | boolean | No | If true, rename the file if there is a conflict at destination |

  #### Output [#output-5]

  | Parameter | Type | Description |
  | - | - | - |
  | `metadata` | object | Metadata of the copied item |
  | ↳ `id` | string | Unique identifier |
  | ↳ `name` | string | Name of the copied item |
  | ↳ `path_display` | string | Display path |
  | ↳ `size` | number | Size in bytes (files only) |
</ReferenceDetails>

### Dropbox Move [#dropbox-move]

Move or rename a file or folder in Dropbox

<ReferenceDetails>
  #### Input [#input-6]

  | Parameter | Type | Required | Description |
  | - | - | - | - |
  | `fromPath` | string | Yes | The source path of the file or folder to move |
  | `toPath` | string | Yes | The destination path for the moved file or folder |
  | `autorename` | boolean | No | If true, rename the file if there is a conflict at destination |

  #### Output [#output-6]

  | Parameter | Type | Description |
  | - | - | - |
  | `metadata` | object | Metadata of the moved item |
  | ↳ `id` | string | Unique identifier |
  | ↳ `name` | string | Name of the moved item |
  | ↳ `path_display` | string | Display path |
  | ↳ `size` | number | Size in bytes (files only) |
</ReferenceDetails>

### Dropbox Get Metadata [#dropbox-get-metadata]

Get metadata for a file or folder in Dropbox

<ReferenceDetails>
  #### Input [#input-7]

  | Parameter | Type | Required | Description |
  | - | - | - | - |
  | `path` | string | Yes | The path of the file or folder to get metadata for |
  | `includeMediaInfo` | boolean | No | If true, include media info for photos/videos |
  | `includeDeleted` | boolean | No | If true, include deleted files in results |

  #### Output [#output-7]

  | Parameter | Type | Description |
  | - | - | - |
  | `metadata` | object | Metadata for the file or folder |
  | ↳ `id` | string | Unique identifier |
  | ↳ `name` | string | Name of the item |
  | ↳ `path_display` | string | Display path |
  | ↳ `path_lower` | string | Lowercase path |
  | ↳ `size` | number | Size in bytes (files only) |
  | ↳ `client_modified` | string | Client modification time (files only) |
  | ↳ `server_modified` | string | Server modification time (files only) |
  | ↳ `rev` | string | Revision identifier (files only) |
  | ↳ `content_hash` | string | Content hash (files only) |
</ReferenceDetails>

### Dropbox Create Shared Link [#dropbox-create-shared-link]

Create a shareable link for a file or folder in Dropbox

<ReferenceDetails>
  #### Input [#input-8]

  | Parameter | Type | Required | Description |
  | - | - | - | - |
  | `path` | string | Yes | The path of the file or folder to share |
  | `requestedVisibility` | string | No | Visibility: public, team\_only, or password |
  | `linkPassword` | string | No | Password for the shared link (only if visibility is password) |
  | `expires` | string | No | Expiration date in ISO 8601 format (e.g., 2025-12-31T23:59:59Z) |

  #### Output [#output-8]

  | Parameter | Type | Description |
  | - | - | - |
  | `sharedLink` | object | The created shared link |
  | ↳ `url` | string | The shared link URL |
  | ↳ `name` | string | Name of the shared item |
  | ↳ `path_lower` | string | Lowercase path of the shared item |
  | ↳ `expires` | string | Expiration date if set |
  | ↳ `link_permissions` | object | Permissions for the shared link |
</ReferenceDetails>

### Dropbox List Shared Links [#dropbox-list-shared-links]

List shared links for a path, or for the entire account if no path is given

<ReferenceDetails>
  #### Input [#input-9]

  | Parameter | Type | Required | Description |
  | - | - | - | - |
  | `path` | string | No | Path to list shared links for. If omitted, lists all shared links. |
  | `directOnly` | boolean | No | If true, only return links directly to the path, not parent folder links |
  | `cursor` | string | No | Cursor from a previous call to fetch the next page of results |

  #### Output [#output-9]

  | Parameter | Type | Description |
  | - | - | - |
  | `links` | array | Shared links applicable to the path argument |
  | ↳ `url` | string | The shared link URL |
  | ↳ `name` | string | Name of the shared item |
  | ↳ `path_lower` | string | Lowercase path of the shared item |
  | ↳ `expires` | string | Expiration date if set |
  | `hasMore` | boolean | Whether there are more results |
  | `cursor` | string | Cursor for pagination (only returned when no path is given) |
</ReferenceDetails>

### Dropbox Search [#dropbox-search]

Search for files and folders in Dropbox

<ReferenceDetails>
  #### Input [#input-10]

  | Parameter | Type | Required | Description |
  | - | - | - | - |
  | `query` | string | Yes | The search query |
  | `path` | string | No | Dropbox folder path to limit search scope (e.g., /folder/subfolder) |
  | `fileExtensions` | string | No | Comma-separated list of file extensions to filter by (e.g., pdf,xlsx) |
  | `maxResults` | number | No | Maximum number of results to return (default: 100) |

  #### Output [#output-10]

  | Parameter | Type | Description |
  | - | - | - |
  | `matches` | array | Search results |
  | ↳ `match_type` | object | Type of match: filename, content, or both |
  | ↳ `metadata` | object | File or folder metadata |
  | `hasMore` | boolean | Whether there are more results |
  | `cursor` | string | Cursor for pagination |
</ReferenceDetails>

### Dropbox List Revisions [#dropbox-list-revisions]

List the revision history for a file in Dropbox (files only, not folders)

<ReferenceDetails>
  #### Input [#input-11]

  | Parameter | Type | Required | Description |
  | - | - | - | - |
  | `path` | string | Yes | The path of the file to list revisions for |
  | `limit` | number | No | Maximum number of revisions to return, 1-100 (default: 10) |
  | `beforeRev` | string | No | Only return revisions before this one. Pass the rev of the last revision from a previous call to fetch the next page. |

  #### Output [#output-11]

  | Parameter | Type | Description |
  | - | - | - |
  | `entries` | array | The revisions for the file, most recent first |
  | ↳ `id` | string | Unique identifier for this revision |
  | ↳ `name` | string | Name of the file |
  | ↳ `path_display` | string | Display path |
  | ↳ `rev` | string | Revision identifier, pass to Restore |
  | ↳ `size` | number | Size of this revision in bytes |
  | ↳ `server_modified` | string | Server modification time |
  | `isDeleted` | boolean | Whether the file identified by the latest revision is deleted or moved |
  | `hasMore` | boolean | Whether there are more revisions available |
</ReferenceDetails>

### Dropbox Restore [#dropbox-restore]

Restore a specific revision of a file to the given path

<ReferenceDetails>
  #### Input [#input-12]

  | Parameter | Type | Required | Description |
  | - | - | - | - |
  | `path` | string | Yes | The path to save the restored file to |
  | `rev` | string | Yes | The revision identifier to restore (from Dropbox List Revisions) |

  #### Output [#output-12]

  | Parameter | Type | Description |
  | - | - | - |
  | `metadata` | object | Metadata of the restored file |
  | ↳ `id` | string | Unique identifier for the file |
  | ↳ `name` | string | Name of the file |
  | ↳ `path_display` | string | Display path of the file |
  | ↳ `path_lower` | string | Lowercase path of the file |
  | ↳ `size` | number | Size of the file in bytes |
  | ↳ `rev` | string | Revision identifier of the restored file |
  | ↳ `server_modified` | string | Server modification time |
</ReferenceDetails>
