Skip to content

Commit

Permalink
Dropbox connectors: fix broken how-to instructions (#443)
Browse files Browse the repository at this point in the history
  • Loading branch information
Paul-Cornell authored Jan 23, 2025
1 parent e86c72d commit a7be5f3
Show file tree
Hide file tree
Showing 6 changed files with 41 additions and 25 deletions.
Binary file added img/connectors/dropbox-app-folder.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added img/connectors/dropbox-app-subfolder.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
6 changes: 3 additions & 3 deletions snippets/general-shared-text/dropbox-api-placeholders.mdx
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
- `<name>` (_required_) - A unique name for this connector.
- `<token>` - The value of your access token
- `<remote-url>` - The remote URL to the target folder
- Set `recursive` to `true` to recursively process data from subfolders within the target folder. The default is `false` if not otherwise specified.
- `<token>` - The value of the access token for the Dropbox app that is associated with the target app folder.
- `<remote-url>` - The remote URL to the target subfolder inside of the app folder for the Dropbox app.
- Set `recursive` to `true` to recursively process data from subfolders within the target subfolder. The default is `false` if not otherwise specified.
4 changes: 2 additions & 2 deletions snippets/general-shared-text/dropbox-cli-api.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -10,5 +10,5 @@ import AdditionalIngestDependencies from '/snippets/general-shared-text/ingest-d

The following environment variables:

- `DROPBOX_ACCESS_TOKEN` - The value of your access token, represented by `--token` (CLI) or `token` (Python).
- `DROPBOX_REMOTE_URL` - The remote URL to the target folder, represented by `--remote-url` (CLI) or `remote_url` (Python).
- `DROPBOX_REMOTE_URL` - The remote URL to the target subfolder inside of the app folder for the Dropbox app, represented by `--remote-url` (CLI) or `remote_url` (Python).
- `DROPBOX_ACCESS_TOKEN` - The value of the access token for the Dropbox app that is associated with the target app folder, represented by `--token` (CLI) or `token` (Python).
6 changes: 3 additions & 3 deletions snippets/general-shared-text/dropbox-platform.mdx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Fill in the following fields:

- **Name** (_required_): A unique name for this connector.
- **Data URL** (_required_): The URL to the target Dropbox directory, starting with `dropbox://`.
- **Recursive** (source connector only): Check this box to also process all subfolders and their files within the directory.
- **Access token** : A Dropbox access token for the target account.
- **Data URL** (_required_): The URL to the target subfolder inside of the app folder for the Dropbox app, starting with `dropbox://`.
- **Recursive** (source connector only): Check this box to also process all child folders and their files within the subfolder.
- **Access token** : The access token for the Dropbox app that is associated with the target app folder.
50 changes: 33 additions & 17 deletions snippets/general-shared-text/dropbox.mdx
Original file line number Diff line number Diff line change
@@ -1,20 +1,36 @@
<iframe
width="560"
height="315"
src="https://www.youtube.com/embed/yY9uuSe2UC4"
title="YouTube video player"
frameborder="0"
allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture"
allowfullscreen
></iframe>
1. A [Dropbox account](https://www.dropbox.com/try/teams).
2. A Dropbox app for your Dropbox account. To create a Dropbox app, do the following:

- A [Dropbox account](https://www.dropbox.com/try/teams).
- A target source or destination [folder](https://help.dropbox.com/create-upload/creating-using-folders-on-dropbox) in your Dropbox account.
- A Dropbox app for your Dropbox account. To learn how to create an app, click the **App Console** tab on the [Getting Started](https://www.dropbox.com/developers/reference/getting-started) page.
- Permission for your Dropbox app to read from, and write to, the target folder in your Dropbox account as needed. To do this:
a) # to the [Dropbox Developers](https://www.dropbox.com/developers) portal with the same credentials as your Dropbox account.<br/>
b) Open your [App Console](https://www.dropbox.com/developers/apps).<br/>
c) Click **Create app**.<br/>
d) For **Choose an API**, select **Scoped access**.<br/>
e) For **Choose the type of access you need**, select **App folder**.<br/>
f) Enter a name for your app, and then click **Create app**.<br/>
g) On the app's **Permissions** tab, under **Files and folders**, check the boxes labelled **files.content.read** or **files.content.write** or both,
depending on whether you want to read files, write files, or both. Then click **Submit**.<br/>
h) On the app's **Settings** tab, note the value of the **App folder name** field. This is the name of the app folder that Dropbox will create under the `Apps` top-level folder in your Dropbox
account that the Dropbox app will use for access. If you change the value of **App folder name** field here, Dropbox will create an app folder with that name under the `Apps` top-level folder instead.<br/>
i) Under **OAuth 2**, next to **Generated access token**, click **Generate**. Copy the value of this access token. You should only click **Generate** after you have completed all of the preceding steps first.
This is because the access token is scoped to the specific app folder and settings at the time the access token is generated. If you change the app folder name or any of the permissions later,
you should regenerate the access token.<br/>

- On the **Permissions** tab of your Dropbox app, check the boxes **files.content.read** or **files.content.write** or both. [Learn more](https://developers.dropbox.com/oauth-guide).
- On the **Settings** tab of your Dropbox app, for **App folder name**, set the name of the target folder in your Dropbox account for your Dropbox app to have access to.
- Note the remote URL to the target folder, which takes the format `dropbox://<path/to/folder/in/account>`.
3. The app folder that your Dropbox app will use for access can be found in your Dropbox account under the `Apps` top-level folder. For example, if the value of the **App folder name**
field above is `my-folder`, then the app folder that your Dropbox app will use for access can be found under `https://dropbox.com/home/Apps/my-folder`

- An [access token](https://dropbox.tech/developers/generate-an-access-token-for-your-own-account) for your Dropbox account. Save this token in a secure location. Do not share it with others.
![The my-folder app folder under the Apps top-level folder](/img/connectors/dropbox-app-folder.png)

<Warning>
Your Dropbox app will _not_ have access to upload or download files from the root of the app folder. Instead, you _must_ create a subfolder inside of the app folder for your Dropbox
app to upload or download files from. You will use the name of that subfolder when specifying your remote URL in the next step. For example, if your Dropbox app uses an app folder named `my-folder`
for access within the `Apps` top-level folder, and you create a subfolder named `data` within the `my-folder` app folder, then the subfolder that your Dropbox app will upload and download files from
can be found under `https://dropbox.com/home/Apps/my-folder/data`

![The data subfolder under the my-folder subfolder](/img/connectors/dropbox-app-subfolder.png)
</Warning>

4. Note the remote URL to your subfolder inside of the app folder, which takes the format `dropbox://<subfolder-name>`. For example,
if your Dropbox app uses an app folder named `my-folder` for access within the `Apps` top-level folder, and you create a subfolder named `data` within the `my-folder` app folder, then
the remote URL is `dropbox://data`

![The data subfolder under the my-folder subfolder](/img/connectors/dropbox-app-subfolder.png)

0 comments on commit a7be5f3

Please # to comment.