cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Announcements
What’s new: end-to-end encryption, Replay and Dash updates. Find out more about these updates, new features and more here.

Dropbox API Support & Feedback

Find help with the Dropbox API from other developers.

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Re: files.listFolder error code -999 cancelled

files.listFolder error code -999 cancelled

ShinehahGnolaum
Helpful | Level 7
Go to solution

I have the following code:

 

    let client = DropboxClient(accessToken: "<ACCESS_TOKEN>")
        
        print("!!! client=", client)
        
        client.files.listFolder(path: "").response {
            
            response, error in
            
            if let result = response {
                
                print("Folder contents:")
                
                for entry in result.entries {
                    
                    print(entry.name)
                    
                }
                
            } else {
                
                print(error!)
                
            }
            
        }
            
    }

I'm getting the following messages in my debug window:

 

!!! client= SwiftyDropbox.DropboxClient
Error Domain=NSURLErrorDomain Code=-999 "cancelled" UserInfo={NSErrorFailingURLStringKey=https://api.dropbox.com/2/files/list_folder, NSLocalizedDescription=cancelled, NSErrorFailingURLKey=https://api.dropbox.com/2/files/list_folder}
2018-08-02 01:14:51.190174-0500 Gnolaum[38319:28928969] Task <DB6BC310-C929-4503-9903-DA5EBBAA9638>.<1> finished with error - code: -999

What does that error mean and how do I fix it?

1 Accepted Solution

Accepted Solutions

Greg-DB
Dropbox Staff
Go to solution

[Cross-linking for reference: https://github.com/dropbox/SwiftyDropbox/issues/227 ]

It sounds like you already found this thread which should offer some insight:

https://www.dropboxforum.com/t5/API-Support-Feedback/999-quot-cancelled-quot-Error/m-p/192322#M24501 

Let me know if you're still having trouble.

By the way, you should never post your access token publicly. I redacted them from your posts, but for the sake of security, you should disable that access token. You can do so by revoking access to the app entirely, if the access token is for your account, here:

https://www.dropbox.com/account/connected_apps

Or, you can disable just this access token using the API:

https://www.dropbox.com/developers/documentation/http/documentation#auth-token-revoke or https://dropbox.github.io/dropbox-api-v2-explorer/#auth_token/revoke or https://dropbox.github.io/SwiftyDropbox/api-docs/latest/Classes/AuthRoutes.html#/s:FC13SwiftyDropbox...

Also, in the future, please refrain from posting the same question to us in multiple places, as it makes it harder to keep track of. Thanks!

View solution in original post

2 Replies 2

Greg-DB
Dropbox Staff
Go to solution

[Cross-linking for reference: https://github.com/dropbox/SwiftyDropbox/issues/227 ]

It sounds like you already found this thread which should offer some insight:

https://www.dropboxforum.com/t5/API-Support-Feedback/999-quot-cancelled-quot-Error/m-p/192322#M24501 

Let me know if you're still having trouble.

By the way, you should never post your access token publicly. I redacted them from your posts, but for the sake of security, you should disable that access token. You can do so by revoking access to the app entirely, if the access token is for your account, here:

https://www.dropbox.com/account/connected_apps

Or, you can disable just this access token using the API:

https://www.dropbox.com/developers/documentation/http/documentation#auth-token-revoke or https://dropbox.github.io/dropbox-api-v2-explorer/#auth_token/revoke or https://dropbox.github.io/SwiftyDropbox/api-docs/latest/Classes/AuthRoutes.html#/s:FC13SwiftyDropbox...

Also, in the future, please refrain from posting the same question to us in multiple places, as it makes it harder to keep track of. Thanks!

ShinehahGnolaum
Helpful | Level 7
Go to solution
OK. Thank you for your patience and your help.
Need more support?