PHPackages                             arbor-education/arbor-sdk-php - 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. arbor-education/arbor-sdk-php

ActiveLibrary[API Development](/categories/api)

arbor-education/arbor-sdk-php
=============================

Arbor Education PHP SDK

6.0.3(2mo ago)116.8k↓33.9%6Apache-2.0PHPPHP &gt;=8.1.0CI passing

Since Apr 24Pushed 1mo ago1 watchersCompare

[ Source](https://github.com/arbor-education/sis-sdk-php)[ Packagist](https://packagist.org/packages/arbor-education/arbor-sdk-php)[ Docs](https://github.com/arbor-education/sis-sdk-php)[ RSS](/packages/arbor-education-arbor-sdk-php/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (10)Dependencies (20)Versions (64)Used By (0)

Arbor SDK
=========

[](#arbor-sdk)

Arbor Education SDK library.

Introduction
------------

[](#introduction)

PHP SDK is a library which simplifies the process of integrating the Arbor REST API with your own software.

Rather than handling XML and making HTTP requests in your code, you can simply include the SDK and use getters and setters on models in order to access data from Arbor. PHP SDK includes hundreds of models as well as a gateway pattern for querying the API via a query model.

SDK supports and requires any PSR 18 based HTTP client. Make sure to install one prior to using the SDK.

Requirements
------------

[](#requirements)

- PHP 8.1 or higher
- [Composer](https://getcomposer.org/download)

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

[](#installation)

Simply download the project and run `composer install` from the root of the project to use as standalone for testing purposes.

Find the latest version on Packagist [Arbor Education - PHP SDK](https://packagist.org/packages/arbor-education/arbor-sdk-php) and install it with composer directly in your project `composer require arbor-education/arbor-sdk-php`

Once setup use the `examples/config-dist.php` to create your own config. For this you will need your apps credentials added on [Arbor Education - Developers Portal](https://developers-portal.arbor.sc) in order to be able to make requests to a sandbox environment.

Usage
-----

[](#usage)

The `PsrRestGateway` class is a gateway implementation for interacting with REST APIs using PSR-compliant HTTP clients. It provides methods for CRUD operations, bulk creation, querying, and handling API responses.

In the `examples/example-bootstrap` you will find the configuration needed to make requests, either using it directly from `examples/config.php` or using your own configuration. The entire `examples` directory is focused on helping you develop your app faster. Scripts written represent some of the most frequently used queries.

Example
-------

[](#example)

When initializing the `PsrRestGateway` you will need to pass the `Arbor\Api\Gateway\HttpClient\HttpClientInterface`.

```
$httpClient = new \Arbor\Api\Gateway\HttpClient\HttpClient(
    new \Arbor\Api\Gateway\HttpClient\TypedRequestFactory(),
    null,
    null,
    $config['api']['baseUrl'],
    $config['api']['auth']['user'],
    $config['api']['auth']['password']
);

$api = new \Arbor\Api\Gateway\PsrRestGateway(
    $httpClient,
    new \Arbor\Model\Hydrator(),
    new \Arbor\Filter\CamelCaseToDash(),
    new \Arbor\Filter\PluralizeFilter(),
);
```

This will create a new instance of the `PsrRestGateway` which you can use to interact with the Arbor API. It will try to find any existing installed PSR-18 HTTP client, or you can pass your own implementation of `Psr\Http\Client\ClientInterface` to the `HttpClient` class.

This will set the default gateway for all models, allowing you to use the SDK without needing to pass the gateway instance every time you want to retrieve or manipulate a model.

```
\Arbor\Model\ModelBase::setDefaultGateway($api);
```

Use `Arbor\Api\Gateway\PsrRestGateway` to make GET, POST, PUT and DELETE requests and use `Arbor\Query\Query` to add filters to your requests.

#### Multipart upload request

[](#multipart-upload-request)

Use the `upload()` method to submit files as `multipart/form-data`.

```
use Arbor\Api\Gateway\UploadFile;

$fileContent = file_get_contents('/path/to/document.pdf');

$response = $api->upload(
    '/rest-v2/documents/upload',
    new UploadFile(name: 'file', contents: $fileContent, filename: 'document.pdf')
);
```

For large files, pass a PSR-7 stream to avoid loading the entire file into memory:

```
// $streamFactory can be any PSR-17 StreamFactoryInterface implementation
$stream = $streamFactory->createStreamFromFile('/path/to/large-video.mp4');

$response = $api->upload(
    '/rest-v2/documents/upload',
    new UploadFile(name: 'file', contents: $stream, filename: 'large-video.mp4')
);
```

#### GET request:

[](#get-request)

```
$student = \Arbor\Model\Student::retrieve(16);
```

or use [examples/student-retrieve.php](https://github.com/arbor-education/sis-sdk-php/blob/master/examples/student-retrieve.php) to see how to retrieve a record.

#### POST request:

[](#post-request)

use [examples/staff-create.php](https://github.com/arbor-education/sis-sdk-php/blob/master/examples/staff-create.php) to see how to create a new record.

#### PUT request:

[](#put-request)

use [examples/staff-create.php](https://github.com/arbor-education/sis-sdk-php/blob/master/examples/staff-update.php) to see how to update an existing record.

#### DELETE request:

[](#delete-request)

```
$api->delete($staff->getPerson()); // assuming that you are deleting your newly created staff record
```

#### Query filters:

[](#query-filters)

List of filters can be found in `Arbor\Query\Query`

```
$query = new \Arbor\Query\Query(Arbor\Resource\ResourceType::ARBOR_MODEL);
$query->addPropertyFilter(ArborModel::PROPERTY_NAME, OPERATOR, $value);
$query->addPropertyFilter(ArborModel::PROPERTY_NAME, SECOND_OPERATOR, $value);
...

$records = \Arbor\Model\ArborModel::query($query); // will return an array of records

foreach ($records as $record) {
    // e.g. $record->getDisplayName();
}
```

Check `examples` directory to see usages of filters.

###  Health Score

61

—

FairBetter than 99% of packages

Maintenance89

Actively maintained with recent releases

Popularity32

Limited adoption so far

Community23

Small or concentrated contributor base

Maturity86

Battle-tested with a long release history

 Bus Factor3

3 contributors hold 50%+ of commits

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

Every ~60 days

Recently: every ~84 days

Total

55

Last Release

61d ago

Major Versions

1.1.0 → 2.0.02017-07-09

2.4.1 → 3.0.02019-02-14

3.0.2 → 4.0.02020-03-23

4.9.0 → 5.0.02023-05-23

5.6.2 → 6.0.02025-07-26

PHP version history (4 changes)1.0.0PHP &gt;=5.3.0

2.0.0PHP &gt;=5.4.0

4.0.2PHP &gt;=7.1.0

6.0.0PHP &gt;=8.1.0

### Community

Maintainers

![](https://www.gravatar.com/avatar/05ace5e8872f342734c0424a5d7e6436c39386cf978d4c1675d3d4a9af2fecdb?d=identicon)[igorvuckovic](/maintainers/igorvuckovic)

---

Top Contributors

[![nemke](https://avatars.githubusercontent.com/u/198133?v=4)](https://github.com/nemke "nemke (41 commits)")[![georgemilojevic](https://avatars.githubusercontent.com/u/19748173?v=4)](https://github.com/georgemilojevic "georgemilojevic (31 commits)")[![cvele](https://avatars.githubusercontent.com/u/644800?v=4)](https://github.com/cvele "cvele (27 commits)")[![AnthonyPorthouse](https://avatars.githubusercontent.com/u/5079595?v=4)](https://github.com/AnthonyPorthouse "AnthonyPorthouse (13 commits)")[![gecbla](https://avatars.githubusercontent.com/u/4783902?v=4)](https://github.com/gecbla "gecbla (13 commits)")[![darkovesic](https://avatars.githubusercontent.com/u/4470598?v=4)](https://github.com/darkovesic "darkovesic (10 commits)")[![aaronlinley](https://avatars.githubusercontent.com/u/3930364?v=4)](https://github.com/aaronlinley "aaronlinley (4 commits)")[![davorzdralo](https://avatars.githubusercontent.com/u/1256799?v=4)](https://github.com/davorzdralo "davorzdralo (4 commits)")[![idstef](https://avatars.githubusercontent.com/u/10683550?v=4)](https://github.com/idstef "idstef (4 commits)")[![SaleStojkovic](https://avatars.githubusercontent.com/u/15819434?v=4)](https://github.com/SaleStojkovic "SaleStojkovic (4 commits)")[![dutekvejin](https://avatars.githubusercontent.com/u/119709?v=4)](https://github.com/dutekvejin "dutekvejin (2 commits)")[![NickGraham101](https://avatars.githubusercontent.com/u/34914709?v=4)](https://github.com/NickGraham101 "NickGraham101 (2 commits)")[![MiroslavArbor](https://avatars.githubusercontent.com/u/38004393?v=4)](https://github.com/MiroslavArbor "MiroslavArbor (2 commits)")[![robert-john-small](https://avatars.githubusercontent.com/u/17810485?v=4)](https://github.com/robert-john-small "robert-john-small (2 commits)")[![dusanbulovan](https://avatars.githubusercontent.com/u/36958423?v=4)](https://github.com/dusanbulovan "dusanbulovan (2 commits)")[![IsaacStarkie](https://avatars.githubusercontent.com/u/110821478?v=4)](https://github.com/IsaacStarkie "IsaacStarkie (1 commits)")[![aldjordje](https://avatars.githubusercontent.com/u/38102310?v=4)](https://github.com/aldjordje "aldjordje (1 commits)")[![nikolaposa](https://avatars.githubusercontent.com/u/6012807?v=4)](https://github.com/nikolaposa "nikolaposa (1 commits)")[![zoranarbor](https://avatars.githubusercontent.com/u/26870781?v=4)](https://github.com/zoranarbor "zoranarbor (1 commits)")[![thomasbuckle-uk](https://avatars.githubusercontent.com/u/69787238?v=4)](https://github.com/thomasbuckle-uk "thomasbuckle-uk (1 commits)")

---

Tags

rest-apisdksissdklibraryREST APImisarbor

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/arbor-education-arbor-sdk-php/health.svg)

```
[![Health](https://phpackages.com/badges/arbor-education-arbor-sdk-php/health.svg)](https://phpackages.com/packages/arbor-education-arbor-sdk-php)
```

###  Alternatives

[openai-php/client

OpenAI PHP is a supercharged PHP API client that allows you to interact with the Open AI API

5.8k22.6M232](/packages/openai-php-client)[getbrevo/brevo-php

Official Brevo provided RESTFul API V3 php library

963.1M35](/packages/getbrevo-brevo-php)[swisnl/json-api-client

A PHP package for mapping remote JSON:API resources to Eloquent like models and collections.

211473.2k12](/packages/swisnl-json-api-client)[wordpress/php-ai-client

A provider agnostic PHP AI client SDK to communicate with any generative AI models of various capabilities using a uniform API.

26236.6k14](/packages/wordpress-php-ai-client)[mozex/anthropic-php

Anthropic PHP is a supercharged community-maintained PHP API client that allows you to interact with Anthropic API.

46365.1k13](/packages/mozex-anthropic-php)[deepseek-php/deepseek-php-client

deepseek PHP client is a robust and community-driven PHP client library for seamless integration with the Deepseek API, offering efficient access to advanced AI and data processing capabilities.

47073.9k5](/packages/deepseek-php-deepseek-php-client)

PHPackages © 2026

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