You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Since mid 2021, there's no longer long-lived access token :
In the past, the Dropbox API used only long-lived access tokens.
These are now deprecated, but will remain available as an option in the Developer
console for compatibility until mid 2021.
In the documentation, it explains there's multiple important elements :
The App Key
The App Secret
The Authorization Code
The Refresh Token
We'll need the app_key, app_secret and refresh_token to call an endpoint giving us a newly generated access_token making this package a hundred percent useful.
Here's how I proceed :
You will still need to authorize the access to the Dropbox App manually using this link :
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
-
As indicated in the issue spatie/ray#86
Since mid 2021, there's no longer
long-lived access token
:Dropbox OAuth Link
In the documentation, it explains there's multiple important elements :
We'll need the
app_key
,app_secret
andrefresh_token
to call an endpoint giving us a newly generatedaccess_token
making this package a hundred percent useful.Here's how I proceed :
You will still need to authorize the access to the Dropbox App manually using this link :
https://www.dropbox.com/oauth2/authorize?client_id<YOUR_APP_KEY>&response_type=code&token_access_type=offline
This will give you the
authorization_code
needed to retrieve arefresh_token
with this curl request :curl https://api.dropbox.com/oauth2/token -d code=<ACCESS_CODE> -d grant_type=authorization_code -u <APP_KEY>:<APP_SECRET>
Giving you access to the
refresh_token
needed in theDROPBOX_REFRESH_TOKEN
indicated below . The other elements are available in your Dropbox App..env.example
config/filesystems.php
app/Providers/DropboxServiceProvider.php
A PR in code and documentation should be interesting. Should I PR this ? The previous code is also indicated in the Laravel 10 Documentation - Custom Filesystems
Beta Was this translation helpful? Give feedback.
All reactions