Download the PHP package joshbannon/overdrive-client without Composer

On this page you can find all versions of the php package joshbannon/overdrive-client. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package overdrive-client

OverDrive PHP Client

The OverDrive PHP Client provides an easy way to use overdrive.com to query library and patron information, place checkouts and holds, check availability, and download titles. OverDrive did an exceptional job making a robust, easy to use api, but they didn't provide a reference client library. You can use this library in your PHP based discovery layer, or just treat it as a starting point for a project in another language.

This client is fairly feature complete, but it isn't perfect. Desired enhancements could include additional exception cases and perhaps async methods that return promises. That was the originally intended path, but the client proved to be pretty performant even with serial calls, so that work was never completed.

There are also many small features that might be useful to some organizations, but were never added due to lack of need. For instance, the patron's password is not currently used because most organizations ask OverDrive to ignore the pin/password. Search is also just barely stubbed out because it's expected that you are doing your own searching locally.

If you'd like to help out and submit a pull request, it would be welcome.

Additional test methods would also be welcome. Currently testing consists of a small functional suite that serves to spot check features and demonstrate the basic use of the client.

Using the Client

The library is broken up into a "Library Client" and a "Patron Client". The library client queries basic item information like the number of copies owned and the number available, the formats available for an item, and meta-data for an item like description and cover images.

The patron client (OverDrivePatronAPIClient) extends the library client (OverDriveLibraryAPIClient). It needs all the standard configuration for the library client and additionally requires the patron's barcode and an email address. The patron client can checkout and return titles, create and release holds, and download checked out titles.

A "Factory" class is also included in the package largely as a reference. It depends on the global $config and $cache that was available in an experimental VuFind branch. It may be useful in your project with minor tweaks.

Installing the client

The recommended method is to use composer Composer.

Next, run the Composer command to install the client:

After installing, you need to require Composer's autoloader:

Acknowledgments

This package was based on the Douglas County Libraries' experimental e-content-enabled VuFind project. It would not have been possible without their support.

The OverDrive client depends on a number of other packages. In particular it uses the excellent Guzzle package to handle HTTP connections. I found the Guzzle project to be useful not only for its fantastic capabilities, but also as a guide to project structure. PHP is not really my forte these days, and I made heavy use of their readme.md and composer.json as a template for my own project.

Code Quality Analysis

I thought this was a really useful tool, so I'll leave a link here to help you decide whether to use this library in your project. It rightfully points out that I have a bunch of debug helpers commented out, and that I have a number of TODO items.

SensioLabsInsight


All versions of overdrive-client with dependencies

PHP Build Version
Package Version
Requires php Version >=5.5.0
guzzlehttp/guzzle Version >=6.0.0
alekseykorzun/memcached-wrapper-php Version >=v2.0.0
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package joshbannon/overdrive-client contains the following files

Loading the files please wait ....