Forum Discussion

khalid12's avatar
khalid12
New member | Level 2
5 years ago

uploading folder with Chooser

is it possible to upload folder using chooser? if yes is there any resources? if no how to upload the folder from Dropbox into my web app any reference?

Regards

  • Greg-DB's avatar
    Greg-DB
    Icon for Dropbox Staff rankDropbox Staff

    The Dropbox Chooser does offer a 'folderselect' option so you can allow users to select folders from their Dropbox accounts. You can find information on that in the Chooser documentation:

     

    https://www.dropbox.com/developers/chooser

     

    That only supports "preview" links, but you can then modify those links, e.g., for direct access, as documented here:

     

    https://help.dropbox.com/files-folders/share/force-download

     

    Setting dl=1 or raw=1 as shown there on a link for a folder will result in a zip download of the folder and its contents when accessing that link, which you could download and unzip on your server if needed.

    • khalid12's avatar
      khalid12
      New member | Level 2

      Thanks a lot for reply.

      Is it possible to get the content of folder without downloading them?

      Is there a way to get the content of folder and put on another dropbox account with same folder stracture throught api?

       

      Regards

      • Greg-DB's avatar
        Greg-DB
        Icon for Dropbox Staff rankDropbox Staff

        If you want to get information about the contents of a shared link without downloading everything, you can use the Dropbox API endpoints /2/sharing/get_shared_link_metadata, to get information about the shared link, and /2/files/list_folder[/continue], to list the contents of the linked folder, if the shared link is for a folder.

         

        Unfortunately, the Dropbox API doesn't offer a way to add a folder from a Dropbox shared link directly to an account via the API, without downloading and re-uploading it. We'll consider this a feature request for a way to do so.