Skip to content
Dropbox OAuth Client
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Type Name Latest commit message Commit time
Failed to load latest commit information.

Dropbox OAuth Client for PHP

A modification of Abraham's TwitterOAuth library to work with Dropbox.

Slight fixes to abstract away the differences between the two site's implementation of the OAuth specifications. If you know how TwitterOAuth works, you'll have no problems implementing Dropbox with this one.


  • Updated to use API version 1
  • Files Put is now supported through ->put() call


  • Base functionality only, you can get files, not push files, yet.

Quick Links


Get Request Token and Redirect

$oauth = new DropboxOAuth($consumer_key,$consumer_secret);

$request = $oauth->getRequestToken($callback_url);

$url = $oauth->getAuthorizeURL($request);

Get Access Token

$oauth = new DropboxOAuth($consumer_key,$consumer_secret,$request['oauth_token'],$request['oauth_token_secret']);

$token = $oauth->getAccessToken();

Using the API

$oauth = new DropboxOAuth($consumer_key,$consumer_secret,$user_key,$user_secret);

$account = $oauth->get("");

$metadata = $oauth->get("");

$file = $oauth->pull("");

$upload = $oauth->put("","/path/to/file.txt");

Please note that ->pull() is used to ->get() without doing the automatic json_decode.

You can’t perform that action at this time.