Skip to main content
Dropbox logo

Dropbox

Overview

Dropbox offers effortless cloud storage paired with effective file-sharing and collaboration tools. Simplify your file management by seamlessly integrating Dropbox with Superblocks for automation.

Setting up Dropbox

Create an access token

To begin, you'll need a Dropbox API access token. Follow these steps to create a token:

  1. Log in to your Dropbox account
  2. Go to the Dropbox Developer Console
  3. Click on Create App to create a new Dropbox app for your integration
  4. Choose an API and and access type then click Create app
  5. On the Settings tab, scroll down to OAuth 2 and copy/paste the Superblocks Callback URL into the Redirect URIs
  6. Copy/paste the the App key and App secret into the Client ID and Client Secret fields of your integration configuration
  7. Go to the Permissions tab and configure the scopes you want to request and copy/paste them into your integration configuration
  8. To generate a shared token, click Connect to Dropbox or uncheck the shared token option so Application users will be prompted to log in

Learn more about Dropbox API authentication and access control to tailor your integration to your specific needs.

Note: This integration currently only supports endpoints via the https://content.dropboxapi.com URL.

Add integration

Once you have an access token, you're ready to set up your Superblocks integration.

  1. In the web app, navigate to the Integrations page
  2. Click on the Dropbox tile
  3. Name the integration
  4. Paste your credentials into the relevant fields
  5. Optionally, add more configurations to set credentials for different environments
  6. Click Create
success

Dropbox connected Now you can use Dropbox in any Application, Workflow, or Scheduled Job.

Use Dropbox in APIs

Once your Dropbox integration is created, you can start creating steps in Application backend APIs, Workflows, and Scheduled Jobs to call Dropbox API actions. Dropbox actions are REST requests. To learn more about REST requests in Superblocks, see the Building REST requests guide.

Supported actions

Download a file

Dropbox API docs: [download](https://www.dropbox.com/developers/documentation/http/documentation#files-download) Specify the file to download with the `Dropbox-API-Arg` header. It expects a JSON object that specifies the format. For example, By path: `{ "path": "/Homework/math/Prime_Numbers.txt" }` By ID: `{ "path": "id:a4ayc_80_OEAAAAAAAAAYa" }` scope: `files.content.read` Download a file from a user's Dropbox.

Download a folder as a zip file

[download_zip](https://www.dropbox.com/developers/documentation/http/documentation#files-download_zip) scope: `files.content.read` Download a folder from the user's Dropbox, as a zip file. The folder must be less than 20 GB in size and have fewer than 10,000 total files. The input cannot be a single file. Any single file must be less than 4GB in size.

Export a file

[export](https://www.dropbox.com/developers/documentation/http/documentation#files-export) scope: `files.content.read` Export a file from a user's Dropbox. This route only supports exporting files that cannot be downloaded directly and whose `ExportResult.file_metadata` has `ExportInfo.export_as` populated.

Get a preview for a file

[get_preview](https://www.dropbox.com/developers/documentation/http/documentation#files-get_preview) scope: `files.content.read` Get a preview for a file. Currently, PDF previews are generated for files with the following extensions: .ai, .doc, .docm, .docx, .eps, .gdoc, .gslides, .odp, .odt, .pps, .ppsm, .ppsx, .ppt, .pptm, .pptx, .rtf. HTML previews are generated for files with the following extensions: .csv, .ods, .xls, .xlsm, .gsheet, .xlsx. Other formats will return an unsupported extension error.

Get a thumbnail for an image

[get_thumbnail](https://www.dropbox.com/developers/documentation/http/documentation#files-get_thumbnail) scope: `files.content.read` Get a thumbnail for a file.

Get thumbnails for a list of images

[get_thumbnail_batch](https://www.dropbox.com/developers/documentation/http/documentation#files-get_thumbnail_batch) scope: `files.content.read` Get thumbnails for a list of images. We allow up to 25 thumbnails in a single batch. This method currently supports files with the following file extensions: jpg, jpeg, png, tiff, tif, gif and bmp. Photos that are larger than 20MB in size won't be converted to a thumbnail.

Upload a new file

Dropbox API docs: [upload](https://www.dropbox.com/developers/documentation/http/documentation#files-upload) To upload a file, use the `Dropbox-API-Arg` header. This header expects a JSON object that specifies these parameteres: `{"path": "/Homework/math/Matrices.txt", "mode": "add", "autorename": true, "mute": false, "strict_conflict": false}` scope: `files.content.write` Create a new file with the contents provided in the request. Do not use this to upload a file larger than 150 MB. Instead, create an upload session with `upload_session/start`. Calls to this endpoint will count as data transport calls for any Dropbox Business teams with a limit on the number of data transport calls allowed per month. For more information, see the [Data transport limit page](https://www.dropbox.com/developers/reference/data-transport-limit).

Append more data to an upload session

[upload_session/append](https://www.dropbox.com/developers/documentation/http/documentation#files-upload_session-append) scope: `files.content.write` Append more data to an upload session. When the parameter close is set, this call will close the session. A single request should not upload more than 150 MB. The maximum size of a file one can upload to an upload session is 350 GB. Calls to this endpoint will count as data transport calls for any Dropbox Business teams with a limit on the number of data transport calls allowed per month. For more information, see the [Data transport limit page](https://www.dropbox.com/developers/reference/data-transport-limit).

Finish an upload session

[upload_session/finish](https://www.dropbox.com/developers/documentation/http/documentation#files-upload_session-finish) scope: `files.content.write` Finish an upload session and save the uploaded data to the given file path. A single request should not upload more than 150 MB. The maximum size of a file one can upload to an upload session is 350 GB. Calls to this endpoint will count as data transport calls for any Dropbox Business teams with a limit on the number of data transport calls allowed per month. For more information, see the [Data transport limit page](https://www.dropbox.com/developers/reference/data-transport-limit).

Start an upload session

[upload_session/start](https://www.dropbox.com/developers/documentation/http/documentation#files-upload_session-start) scope: `files.content.write` Upload sessions allow you to upload a single file in one or more requests, for example where the size of the file is greater than 150 MB. This call starts a new upload session with the given data. You can then use `upload_session/append:2` to add more data and `upload_session/finish` to save all the data to a file in Dropbox. A single request should not upload more than 150 MB. The maximum size of a file one can upload to an upload session is 350 GB. An upload session can be used for a maximum of 48 hours. Attempting to use an `UploadSessionStartResult.session_id` with `upload_session/append:2` or `upload_session/finish` more than 48 hours after its creation will return a `UploadSessionLookupError.not_found`. Calls to this endpoint will count as data transport calls for any Dropbox Business teams with a limit on the number of data transport calls allowed per month. For more information, see the [Data transport limit page](https://www.dropbox.com/developers/reference/data-transport-limit).

Download a shared link's file

[get_shared_link_file](https://www.dropbox.com/developers/documentation/http/documentation#sharing-get_shared_link_file) scope: `sharing.read` Download the shared link's file from a user's Dropbox.
and more

Generic HTTP Request

Every SaaS integration in Superblocks comes with a built in Generic HTTP Request Action. This is a powerful action you can use to call Dropbox API endpoints not in the Superblocks supported actions.

To use this action simply add the method, path, required query parameters, and body for the desired endpoint.

info

Learn more about REST requests in Superblocks in our Building REST requests guide.

Generic HTTP Requests use the authentication set up and base URL you've configured for your integration, making it an easy for your team to extend Superblocks Integrations to meet their needs.