Need to see if your shared folder is taking up space on your dropbox 👨‍💻? Find out how to check here.

Forum Discussion

arch2020's avatar
arch2020
Helpful | Level 5
6 years ago
Solved

Api error "LookupError" for sharing_create_shared_link_with_settings

Hi all, 

 

I am new to dropbox api. My problem is whenver I try to create an app folder from the app console, the connection never works and I keep receiving an error regarding to the path, see below:

 

ApiError: ApiError('187007dde9fb433ea831afd60b273b83', CreateSharedLinkWithSettingsError('path', LookupError('not_found', None)))

 

I am fully aware that app folder can only access the files inside the  the folder of the main app. Hence,  I embedded the file I want to access inside the app folder in dropbox . I am using the following code:

 

import dropbox

dbx = dropbox.Dropbox(<app token>)

shared_link_metadata = dbx.sharing_create_shared_link_with_settings("/Apps/App_Name/example.xlsx")
print (shared_link_metadata.url)

Any ideas on how to overcome this issue?

Your help is much appreciated, 

Thanks 

  • Hi arch2020,

    Try transform the path from "/Apps/App_Name/example.xlsx" to "/example.xlsx". Is this helps? 🤔

    Try to explain why. 😉

6 Replies

  • Здравко's avatar
    Здравко
    Legendary | Level 20
    6 years ago

    Hi arch2020,

    Try transform the path from "/Apps/App_Name/example.xlsx" to "/example.xlsx". Is this helps? 🤔

    Try to explain why. 😉

  • arch2020's avatar
    arch2020
    Helpful | Level 5
    6 years ago

    @

     

    It worked like magic. Thanks, it seems that with app folder, there is no need for referencing the name of the app, as the default location of the app, will always be the name of the app folder.  very grateful for your help, you saved me tons of tons and unnecessary hustle. 

  • Здравко's avatar
    Здравко
    Legendary | Level 20
    6 years ago

    arch2020 wrote:

     

    ..., it seems that with app folder, there is no need for referencing the name of the app, as the default location of the app, will always be the name of the app folder.  ...

    🙂 Almost exactly! 👍

    Actually, the app' folder forms a namespace that become a root folder for access from the application side. 😉

  • arch2020's avatar
    arch2020
    Helpful | Level 5
    6 years ago

    thanks that really helped me alot to get past through my novice hardship :). 

  • Greg-DB's avatar
    Greg-DB
    Icon for Dropbox Community Moderator rankDropbox Community Moderator
    6 years ago

    That's correct. You can also use files_list_folder and files_list_folder_continue to list the contents of any folder. For example, to list the contents of the root folder for your app, supply a path value of the empty string "". Then you can get the path values of any of the contents from the Metadata.path_lower value for the entry in the result.

About Discuss Dropbox Developer & API

Node avatar for Discuss Dropbox Developer & API
Make connections with other developers

The Dropbox Community team is active from Monday to Friday. We try to respond to you as soon as we can, usually within 2 hours.

If you need more help you can view your support options (expected response time for an email or ticket is 24 hours), or contact us on X, Facebook or Instagram.

For more info on available support options for your Dropbox plan, see this article.

If you found the answer to your question in this Community thread, please 'like' the post to say thanks and to let us know it was useful!