github.com/10XDev/rclone@v1.52.3-0.20200626220027-16af9ab76b2a/docs/content/dropbox.md (about)

     1  ---
     2  title: "Dropbox"
     3  description: "Rclone docs for Dropbox"
     4  ---
     5  
     6  {{< icon "fab fa-dropbox" >}} Dropbox
     7  ---------------------------------
     8  
     9  Paths are specified as `remote:path`
    10  
    11  Dropbox paths may be as deep as required, eg
    12  `remote:directory/subdirectory`.
    13  
    14  The initial setup for dropbox involves getting a token from Dropbox
    15  which you need to do in your browser.  `rclone config` walks you
    16  through it.
    17  
    18  Here is an example of how to make a remote called `remote`.  First run:
    19  
    20       rclone config
    21  
    22  This will guide you through an interactive setup process:
    23  
    24  ```
    25  n) New remote
    26  d) Delete remote
    27  q) Quit config
    28  e/n/d/q> n
    29  name> remote
    30  Type of storage to configure.
    31  Choose a number from below, or type in your own value
    32  [snip]
    33  XX / Dropbox
    34     \ "dropbox"
    35  [snip]
    36  Storage> dropbox
    37  Dropbox App Key - leave blank normally.
    38  app_key>
    39  Dropbox App Secret - leave blank normally.
    40  app_secret>
    41  Remote config
    42  Please visit:
    43  https://www.dropbox.com/1/oauth2/authorize?client_id=XXXXXXXXXXXXXXX&response_type=code
    44  Enter the code: XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX_XXXXXXXXXX
    45  --------------------
    46  [remote]
    47  app_key =
    48  app_secret =
    49  token = XXXXXXXXXXXXXXXXXXXXXXXXXXXXX_XXXX_XXXXXXXXXXXXXXXXXXXXXXXXXXXXX
    50  --------------------
    51  y) Yes this is OK
    52  e) Edit this remote
    53  d) Delete this remote
    54  y/e/d> y
    55  ```
    56  
    57  You can then use it like this,
    58  
    59  List directories in top level of your dropbox
    60  
    61      rclone lsd remote:
    62  
    63  List all the files in your dropbox
    64  
    65      rclone ls remote:
    66  
    67  To copy a local directory to a dropbox directory called backup
    68  
    69      rclone copy /home/source remote:backup
    70  
    71  ### Dropbox for business ###
    72  
    73  Rclone supports Dropbox for business and Team Folders.
    74  
    75  When using Dropbox for business `remote:` and `remote:path/to/file`
    76  will refer to your personal folder.
    77  
    78  If you wish to see Team Folders you must use a leading `/` in the
    79  path, so `rclone lsd remote:/` will refer to the root and show you all
    80  Team Folders and your User Folder.
    81  
    82  You can then use team folders like this `remote:/TeamFolder` and
    83  `remote:/TeamFolder/path/to/file`.
    84  
    85  A leading `/` for a Dropbox personal account will do nothing, but it
    86  will take an extra HTTP transaction so it should be avoided.
    87  
    88  ### Modified time and Hashes ###
    89  
    90  Dropbox supports modified times, but the only way to set a
    91  modification time is to re-upload the file.
    92  
    93  This means that if you uploaded your data with an older version of
    94  rclone which didn't support the v2 API and modified times, rclone will
    95  decide to upload all your old data to fix the modification times.  If
    96  you don't want this to happen use `--size-only` or `--checksum` flag
    97  to stop it.
    98  
    99  Dropbox supports [its own hash
   100  type](https://www.dropbox.com/developers/reference/content-hash) which
   101  is checked for all transfers.
   102  
   103  #### Restricted filename characters
   104  
   105  | Character | Value | Replacement |
   106  | --------- |:-----:|:-----------:|
   107  | NUL       | 0x00  | ␀           |
   108  | /         | 0x2F  | /           |
   109  | DEL       | 0x7F  | ␡           |
   110  | \         | 0x5C  | \           |
   111  
   112  File names can also not end with the following characters.
   113  These only get replaced if they are the last character in the name:
   114  
   115  | Character | Value | Replacement |
   116  | --------- |:-----:|:-----------:|
   117  | SP        | 0x20  | ␠           |
   118  
   119  Invalid UTF-8 bytes will also be [replaced](/overview/#invalid-utf8),
   120  as they can't be used in JSON strings.
   121  
   122  {{< rem autogenerated options start" - DO NOT EDIT - instead edit fs.RegInfo in backend/dropbox/dropbox.go then run make backenddocs" >}}
   123  ### Standard Options
   124  
   125  Here are the standard options specific to dropbox (Dropbox).
   126  
   127  #### --dropbox-client-id
   128  
   129  Dropbox App Client Id
   130  Leave blank normally.
   131  
   132  - Config:      client_id
   133  - Env Var:     RCLONE_DROPBOX_CLIENT_ID
   134  - Type:        string
   135  - Default:     ""
   136  
   137  #### --dropbox-client-secret
   138  
   139  Dropbox App Client Secret
   140  Leave blank normally.
   141  
   142  - Config:      client_secret
   143  - Env Var:     RCLONE_DROPBOX_CLIENT_SECRET
   144  - Type:        string
   145  - Default:     ""
   146  
   147  ### Advanced Options
   148  
   149  Here are the advanced options specific to dropbox (Dropbox).
   150  
   151  #### --dropbox-chunk-size
   152  
   153  Upload chunk size. (< 150M).
   154  
   155  Any files larger than this will be uploaded in chunks of this size.
   156  
   157  Note that chunks are buffered in memory (one at a time) so rclone can
   158  deal with retries.  Setting this larger will increase the speed
   159  slightly (at most 10% for 128MB in tests) at the cost of using more
   160  memory.  It can be set smaller if you are tight on memory.
   161  
   162  - Config:      chunk_size
   163  - Env Var:     RCLONE_DROPBOX_CHUNK_SIZE
   164  - Type:        SizeSuffix
   165  - Default:     48M
   166  
   167  #### --dropbox-impersonate
   168  
   169  Impersonate this user when using a business account.
   170  
   171  - Config:      impersonate
   172  - Env Var:     RCLONE_DROPBOX_IMPERSONATE
   173  - Type:        string
   174  - Default:     ""
   175  
   176  #### --dropbox-encoding
   177  
   178  This sets the encoding for the backend.
   179  
   180  See: the [encoding section in the overview](/overview/#encoding) for more info.
   181  
   182  - Config:      encoding
   183  - Env Var:     RCLONE_DROPBOX_ENCODING
   184  - Type:        MultiEncoder
   185  - Default:     Slash,BackSlash,Del,RightSpace,InvalidUtf8,Dot
   186  
   187  {{< rem autogenerated options stop >}}
   188  
   189  ### Limitations ###
   190  
   191  Note that Dropbox is case insensitive so you can't have a file called
   192  "Hello.doc" and one called "hello.doc".
   193  
   194  There are some file names such as `thumbs.db` which Dropbox can't
   195  store.  There is a full list of them in the ["Ignored Files" section
   196  of this document](https://www.dropbox.com/en/help/145).  Rclone will
   197  issue an error message `File name disallowed - not uploading` if it
   198  attempts to upload one of those file names, but the sync won't fail.
   199  
   200  If you have more than 10,000 files in a directory then `rclone purge
   201  dropbox:dir` will return the error `Failed to purge: There are too
   202  many files involved in this operation`.  As a work-around do an
   203  `rclone delete dropbox:dir` followed by an `rclone rmdir dropbox:dir`.
   204  
   205  ### Get your own Dropbox App ID ###
   206  
   207  When you use rclone with Dropbox in its default configuration you are using rclone's App ID. This is shared between all the rclone users.
   208  
   209  Here is how to create your own Dropbox App ID for rclone:
   210  
   211  1. Log into the [Dropbox App console](https://www.dropbox.com/developers/apps/create) with your Dropbox Account (It need not
   212  to be the same account as the Dropbox you want to access)
   213  
   214  2. Choose an API => Usually this should be `Dropbox API`
   215  
   216  3. Choose the type of access you want to use => `Full Dropbox` or `App Folder`
   217  
   218  4. Name your App. The app name is global, so you can't use `rclone` for example
   219  
   220  5. Click the button `Create App`
   221  
   222  5. Fill `Redirect URIs` as `http://localhost:53682/`
   223  
   224  6. Find the `App key` and `App secret` Use these values in rclone config to add a new remote or edit an existing remote.