Dropbox API Support & Feedback
Find help with the Dropbox API from other developers.
I'm using the most recent NuGet package for my VS 2019 project. My app has worked consistently for several years now. But recently I have logged errors when invoking the client.Files.UploadAsync() method. The underlying exception appears as The request was aborted: Could not create SSL/TLS secure channel. I have debugged my code and can see an access token is being provided so the API call is correctly authenticated.
These errors are spotty, and don't happen consistently. At first I thought there was an issue with my WebView2 control I use in order to ensure that OAuth2 is properly functioning. But that has been eliminated, as I can verify that the access token is there. Now doing some additional troubleshooting and code changes I am getting back an error stating the access token has expired.
Did something recently change in terms of the API endpoint and its behavior?
Great, I'm glad to hear that fixed it.
And yes, the refresh token doesn't change or expire, and can be re-used multiple times. When you pass it to the DropboxClient like this, the client will automatically perform the refresh to get a new short-lived access token whenever needed, without you needing to do anything extra. (Note that just like with long-lived access tokens though, refresh tokens can be revoked on demand by the app or user.)
Quick follow-up to this long thread
I was still running into the expired access token exception, but this was because of the method overload I was using for instantiating the DropboxClient. I was using this:
client = new DropboxClient(Properties.Settings.Default.AccessToken, Properties.Settings.Default.RefreshToken, Properties.Settings.Default.DropboxApiKey, Properties.Settings.Default.DropboxApiPwd, config);
Apparently referencing the access token value (even an old/expired one) was throwing a monkey wrench into the works. So I changed this to:
client = new DropboxClient(Properties.Settings.Default.RefreshToken, Properties.Settings.Default.DropboxApiKey, Properties.Settings.Default.DropboxApiPwd, config);
await client.RefreshAccessToken(null);
Leaving out the access token argument and forcing an access token refresh appears to have cleaned things up. There are a lot of method overloads for creating a new DropboxClient instance, and I got lost in the sauce. But all fine now.
Thanks again for all of the timely, helpful feedback. Honestly most API service providers aren't anywhere as responsive and supportive as I've experience on here!
Hi there!
If you need more help you can view your support options (expected response time for a ticket is 24 hours), or contact us on X or Facebook.
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!