PHPackages                             leoamsena/dropbox-api - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [API Development](/categories/api)
4. /
5. leoamsena/dropbox-api

ActiveLibrary[API Development](/categories/api)

leoamsena/dropbox-api
=====================

A minimal implementation of Dropbox API v2

1.6.6(7y ago)048MITPHPPHP ^7.0

Since Dec 28Pushed 7y agoCompare

[ Source](https://github.com/leoamsena/EditedDropboxAPI)[ Packagist](https://packagist.org/packages/leoamsena/dropbox-api)[ Docs](https://github.com/spatie/dropbox-api)[ RSS](/packages/leoamsena-dropbox-api/feed)WikiDiscussions master Synced today

READMEChangelog (1)Dependencies (2)Versions (2)Used By (0)

A minimal implementation of Dropbox API v2
==========================================

[](#a-minimal-implementation-of-dropbox-api-v2)

[![Latest Version on Packagist](https://camo.githubusercontent.com/3ca9ad2c0d29e96d737a1fbb1de5009060bfd99114f8710a2b5a480db7f29808/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f7370617469652f64726f70626f782d6170692e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/spatie/dropbox-api)[![Build Status](https://camo.githubusercontent.com/5c39ac5f07aeaf645034155bcaa3db6655769ce75b0a148cb99ddb3bb1282aa7/68747470733a2f2f696d672e736869656c64732e696f2f7472617669732f7370617469652f64726f70626f782d6170692f6d61737465722e7376673f7374796c653d666c61742d737175617265)](https://travis-ci.org/spatie/dropbox-api)[![StyleCI](https://camo.githubusercontent.com/dbcf5c7ab78c44c1cf900f149cda5ec343eab43a1d40a10f193543d959265233/68747470733a2f2f7374796c6563692e696f2f7265706f732f38383632313238392f736869656c643f6272616e63683d6d6173746572)](https://styleci.io/repos/88621289)[![Quality Score](https://camo.githubusercontent.com/bfdf62f939620ebee6f6749c637eb4e135de4f99dfac379f7f41bb5420b9973f/68747470733a2f2f696d672e736869656c64732e696f2f7363727574696e697a65722f672f7370617469652f64726f70626f782d6170692e7376673f7374796c653d666c61742d737175617265)](https://scrutinizer-ci.com/g/spatie/dropbox-api)[![Total Downloads](https://camo.githubusercontent.com/714c253398314e9e4f159473da3339cff992cc4a221d28bb609bb6bbf1fe903e/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f7370617469652f64726f70626f782d6170692e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/spatie/dropbox-api)

This is a minimal PHP implementation of the [Dropbox API v2](https://www.dropbox.com/developers/documentation/http/overview). It contains only the methods needed for [our flysystem-dropbox adapter](https://github.com/spatie/flysystem-dropbox). We are open however to PRs that add extra methods to the client.

Here are a few examples on how you can use the package:

```
$client = new Spatie\Dropbox\Client($authorizationToken);

//create a folder
$client->createFolder($path);

//list a folder
$client->listFolder($path);

//get a temporary link
$client->getTemporaryLink($path);
```

Installation
------------

[](#installation)

You can install the package via composer:

```
composer require spatie/dropbox-api
```

Usage
-----

[](#usage)

The first thing you need to do is get an authorization token at Dropbox. Unlike [other companies](https://google.com) Dropbox has made this very easy. You can just generate a token in the [App Console](https://www.dropbox.com/developers/apps) for any Dropbox API app. You'll find more info at [the Dropbox Developer Blog](https://blogs.dropbox.com/developers/2014/05/generate-an-access-token-for-your-own-account/).

With an authorization token you can instantiate a `Spatie\Dropbox\Client`.

```
$client = new Spatie\Dropbox\Client($authorizationToken);
```

Look in [the source code of `Spatie\Dropbox\Client`](https://github.com/spatie/dropbox-api/blob/master/src/Client.php) to discover the methods you can use.

If you do not find your favorite method, you can directly use the `contentEndpointRequest` and `rpcEndpointRequest` functions.

```
public function contentEndpointRequest(string $endpoint, array $arguments, $body): ResponseInterface

public function rpcEndpointRequest(string $endpoint, array $parameters): array
```

Here's an example:

```
$client->rpcEndpointRequest('search', ['path' => '', 'query' => 'bat cave']);
```

Changelog
---------

[](#changelog)

Please see [CHANGELOG](CHANGELOG.md) for more information what has changed recently.

Testing
-------

[](#testing)

```
composer test
```

Contributing
------------

[](#contributing)

Please see [CONTRIBUTING](CONTRIBUTING.md) for details.

Security
--------

[](#security)

If you discover any security related issues, please email  instead of using the issue tracker.

Postcardware
------------

[](#postcardware)

You're free to use this package (it's [MIT-licensed](LICENSE.md)), but if it makes it to your production environment we highly appreciate you sending us a postcard from your hometown, mentioning which of our package(s) you are using.

Our address is: Spatie, Samberstraat 69D, 2060 Antwerp, Belgium.

We publish all received postcards [on our company website](https://spatie.be/en/opensource/postcards).

Credits
-------

[](#credits)

- [Alex Vanderbist](https://github.com/AlexVanderbist)
- [Freek Van der Herten](https://github.com/freekmurze)
- [All Contributors](../../contributors)

Support us
----------

[](#support-us)

Spatie is a webdesign agency based in Antwerp, Belgium. You'll find an overview of all our open source projects [on our website](https://spatie.be/opensource).

Does your business depend on our contributions? Reach out and support us on [Patreon](https://www.patreon.com/spatie). All pledges will be dedicated to allocating workforce on maintenance and new awesome stuff.

License
-------

[](#license)

The MIT License (MIT). Please see [License File](LICENSE.md) for more information.

###  Health Score

25

—

LowBetter than 37% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity8

Limited adoption so far

Community6

Small or concentrated contributor base

Maturity55

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Unknown

Total

1

Last Release

2689d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/94ec9cfb62f3f1ee4a916ee18d5fb7306baaed8c7bef91109eb2de9f40842b50?d=identicon)[leoamsena](/maintainers/leoamsena)

---

Top Contributors

[![leoamsena](https://avatars.githubusercontent.com/u/23142222?v=4)](https://github.com/leoamsena "leoamsena (5 commits)")

---

Tags

spatieapidropboxv2Dropbox-API

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/leoamsena-dropbox-api/health.svg)

```
[![Health](https://phpackages.com/badges/leoamsena-dropbox-api/health.svg)](https://phpackages.com/packages/leoamsena-dropbox-api)
```

###  Alternatives

[spatie/dropbox-api

A minimal implementation of Dropbox API v2

3116.0M36](/packages/spatie-dropbox-api)[spatie/flysystem-dropbox

Flysystem Adapter for the Dropbox v2 API

3644.6M68](/packages/spatie-flysystem-dropbox)[kunalvarma05/dropbox-php-sdk

Dropbox PHP API V2 SDK (Unofficial)

3633.0M18](/packages/kunalvarma05-dropbox-php-sdk)[srmklive/flysystem-dropbox-v2

Flysystem Adapter for Dropbox API v2

20179.1k9](/packages/srmklive-flysystem-dropbox-v2)[spatie/packagist-api

Fetch package info from Packagist

1301.8M11](/packages/spatie-packagist-api)[spatie/laravel-tinker-tools

Use short class names in an Artisan tinker session

13850.2k](/packages/spatie-laravel-tinker-tools)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
