PHPackages                             hpdc/sdk - 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. [Authentication &amp; Authorization](/categories/authentication)
4. /
5. hpdc/sdk

ActiveLibrary[Authentication &amp; Authorization](/categories/authentication)

hpdc/sdk
========

Simple PHP SDK for implementing OAuth authentication with the HPDC API.

v11.6(3y ago)135MITPHPPHP ^8.1

Since Mar 15Pushed 3y agoCompare

[ Source](https://github.com/HPDCollaborative/php-sdk)[ Packagist](https://packagist.org/packages/hpdc/sdk)[ RSS](/packages/hpdc-sdk/feed)WikiDiscussions master Synced 3d ago

READMEChangelog (3)Dependencies (2)Versions (10)Used By (0)

HPD Collaborative PHP SDK
=========================

[](#hpd-collaborative-php-sdk)

The PHP SDK is designed to allow for HPD Collaborative API Partners to easily integrate OAuth authentication used by our API into their PHP applications.

**YOU MUST BE AN EXISTING API PARTNER TO USE THE API**

Once you've received access to the API as a Partner, you can then begin integrating OAuth authentication and token access with this SDK, or you can roll your own using the SDK as a guide.

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

[](#installation)

The SDK uses composer to manage dependencies so you'll need to ensure you have a working knowledge of composer to install and integrate it into your application.

To install the SDK run:

```
composer require hpdc/sdk
```

This will download the SDK into your vendor directory and set up autoloading with the PSR-4 autoloading convention.

Usage
-----

[](#usage)

Below is an example of integrating the Authentication SDK into a given controller. This example is a Laravel Controller, but integrating into the framework of your choice should be very similar.

The example is documented on each method, and keep in mind the SDK requires PHP &gt; 7.0 so you may or may not be able to type hint classes automatically depending on your framework.

```
