PHPackages                             gonebusy/gonebusy-php-client - 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. gonebusy/gonebusy-php-client

ActiveLibrary[API Development](/categories/api)

gonebusy/gonebusy-php-client
============================

This is a PHP client for communicating with the full Gonebusy API

v0.1.3(8y ago)123MITPHPPHP &gt;=5.6.0

Since Nov 18Pushed 8y ago3 watchersCompare

[ Source](https://github.com/gonebusy/gonebusy-php-client)[ Packagist](https://packagist.org/packages/gonebusy/gonebusy-php-client)[ Docs](https://www.gonebusy.com)[ RSS](/packages/gonebusy-gonebusy-php-client/feed)WikiDiscussions master Synced 2mo ago

READMEChangelog (10)Dependencies (4)Versions (15)Used By (0)

[![Build Status](https://camo.githubusercontent.com/c5899233bfd6741792b6e5375be861d83b97942376613f56f13de4cb5f9185fd/68747470733a2f2f7472617669732d63692e6f72672f676f6e65627573792f676f6e65627573792d7068702d636c69656e742e7376673f6272616e63683d6d6173746572)](https://travis-ci.org/gonebusy/gonebusy-php-client)[![PHP version](https://camo.githubusercontent.com/d27ef13670123eb0db9d4a2c017d3ec9c4b27fb87978983bfc04d6bb948219ca/68747470733a2f2f62616467652e667572792e696f2f70682f676f6e6562757379253246676f6e65627573792d7068702d636c69656e742e737667)](https://badge.fury.io/ph/gonebusy%2Fgonebusy-php-client)

PHP SDK for the Gonebusy REST API
=================================

[](#php-sdk-for-the-gonebusy-rest-api)

Sandbox
-------

[](#sandbox)

We have a Sandbox environment to play with!

To point at the Sandbox, just use [sandbox.gonebusy.com](https://sandbox.gonebusy.com) instead of where you see beta.gonebusy.com referenced, including where to create an account to retrieve your API Key.

The Sandbox environment is completely separate from the Live site - that includes meaning your Sandbox API Key will not work in the Live environment.

How to Use
----------

[](#how-to-use)

### Summary of Gonebusy objects

[](#summary-of-gonebusy-objects)

(more info on the [Developer Portal](https://gonebusy.github.io/api/)):

- A **User** is required to perform operations.
- A **Resource** (WHO) performs Services and is needed for all scheduling operations. *Each User is assigned a default Resource (her/himself) automatically.*
- A **Service** (WHAT) is performed by Resources according to a Schedule. *Services are assigned a **Pricing Model**.**Services can be assigned a **Category** as well.*
- A **Schedule** (WHEN) defines when a Service is performed by a Resource. Pieces of a Schedule are called **Time Windows**.
- Finally, a **Booking** is placed (at a particular Time Window) in a Schedule, linking it to a Resource-Service combo.
- A **Search** of users and services can be performed.

### API Key

[](#api-key)

If testing with Sandbox, [Signup/Logon](https://sandbox.gonebusy.com/login) at .

If using Production site, [Signup/Logon](https://beta.gonebusy.com/login) at .

Once logged in, navigate to the API Key page and request an API key.

### Initialization/Authentication

[](#initializationauthentication)

In order to setup authentication and initialization of the API client, you need the following information.

ParameterDescriptionauthorizationSet Authorization to "Token *your API key*"API client can be initialized as following.

```
// Configuration parameters and credentials
$authorization = "Token "; // Set Authorization to "Token "

$client = new GonebusyLib\GonebusyClient($authorization);
```

---

How to Build
------------

[](#how-to-build)

### Composer Install

[](#composer-install)

```
> composer install
Loading composer repositories with package information
Installing dependencies (including require-dev) from lock file
  - Installing apimatic/jsonmapper (v1.2.0)
    Loading from cache

  [ ... snip ... ]

  - Installing squizlabs/php_codesniffer (2.9.0)
    Downloading: 100%

symfony/yaml suggests installing symfony/console (For validating YAML files using the lint command)
sebastian/global-state suggests installing ext-uopz (*)
phpunit/php-code-coverage suggests installing ext-xdebug (^2.5.1)
phpunit/phpunit suggests installing ext-xdebug (*)
phpunit/phpunit suggests installing phpunit/php-invoker (~1.1)
Generating autoload files
```

### \[For Windows Users Only\] Configuring CURL Certificate Path in php.ini

[](#for-windows-users-only-configuring-curl-certificate-path-in-phpini)

CURL used to include a list of accepted CAs, but no longer bundles ANY CA certs. So by default it will reject all SSL certificates as unverifiable. You will have to get your CA's cert and point curl at it. The steps are as follows:

1. Download the certificate bundle (.pem file) from  on to your system.
2. Add curl.cainfo = "PATH\_TO/cacert.pem" to your php.ini file located in your php installation. “PATH\_TO” must be an absolute path containing the .pem file.

```
[curl]
; A default value for the CURLOPT_CAINFO option. This is required to be an
; absolute path.
;curl.cainfo =
```

How to Test
-----------

[](#how-to-test)

Unit tests in this SDK can be run using PHPUnit. The test cases are located in the test/Controllers/ dir.

1. Make sure you've installed the dependencies using composer including the `require-dev` dependencies.
2. Run `vendor/bin/phpunit` from command line to execute the test suite. See  for info on test output format as well as more command-line options.
3. Optionally, to check the code standards you may run `vendor/bin/phpcs` (See `phpcs.xml`). (No output means no problems.)

---

Class Reference
---------------

[](#class-reference)

### List of Controllers

[](#list-of-controllers)

- [BookingsController](#bookings_controller)
- [CategoriesController](#categories_controller)
- [PricingModelsController](#pricing_models_controller)
- [ResourcesController](#resources_controller)
- [SchedulesController](#schedules_controller)
- [SearchController](#search_controller)
- [ServicesController](#services_controller)
- [UsersController](#users_controller)

### [![Class: ](https://camo.githubusercontent.com/ec8022a6fb768aa7d81b8226237aadf63b8a726efab75a8314b224e54194c885/68747470733a2f2f617069646f63732e696f2f696d672f636c6173732e706e67 ".BookingsController")](https://camo.githubusercontent.com/ec8022a6fb768aa7d81b8226237aadf63b8a726efab75a8314b224e54194c885/68747470733a2f2f617069646f63732e696f2f696d672f636c6173732e706e67) BookingsController

[](#-bookingscontroller)

#### Get singleton instance

[](#get-singleton-instance)

The singleton instance of the `BookingsController` class can be accessed from the API Client.

```
$bookings = $client->getBookings();
```

#### [![Method: ](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67 ".BookingsController.getBookings")](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67) getBookings

[](#-getbookings)

> Return list of Bookings.

```
function getBookings(
        $authorization,
        $page = 1,
        $perPage = 10,
        $states = null,
        $userId = null)
```

#### Parameters

[](#parameters)

ParameterTagsDescriptionauthorization`Required`A valid API key, in the format 'Token API\_KEY'page`Optional` `DefaultValue`Page offset to fetch.perPage`Optional` `DefaultValue`Number of results to return per page.states`Optional`Comma-separated list of Booking states to retrieve only Bookings in those states. Leave blank to retrieve all Bookings.userId`Optional`Retrieve Bookings for Resources/Services owned by this User Id. You must be authorized to manage this User Id.bookerId`Optional`Retrieve Bookings made by Booker Id.#### Example Usage

[](#example-usage)

```
$authorization = 'Authorization';
$page = 1;
$perPage = 10;
$states = 'states';
$userId = 131;

$result = $bookings->getBookings($authorization, $page, $perPage, $states, $userId);
```

#### Errors

[](#errors)

Error CodeError Description401Unauthorized/Missing Token403Forbidden404Not Found0Unexpected error#### [![Method: ](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67 ".BookingsController.createBooking")](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67) createBooking

[](#-createbooking)

> Create a Booking with params

```
function createBooking(
        $authorization,
        $createBookingBody = null)
```

#### Parameters

[](#parameters-1)

ParameterTagsDescriptionauthorization`Required`A valid API key, in the format 'Token API\_KEY'createBookingBody`Optional`the content of the request#### Example Usage

[](#example-usage-1)

```
$authorization = 'Authorization';
$createBookingBody = new CreateBookingBody();

$result = $bookings->createBooking($authorization, $createBookingBody);
```

#### Errors

[](#errors-1)

Error CodeError Description400Bad Request401Unauthorized/Missing Token403Forbidden422Unprocessable Entity0Unexpected error#### [![Method: ](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67 ".BookingsController.getBookingById")](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67) getBookingById

[](#-getbookingbyid)

> Return a Booking by id.

```
function getBookingById(
        $authorization,
        $id)
```

#### Parameters

[](#parameters-2)

ParameterTagsDescriptionauthorization`Required`A valid API key, in the format 'Token API\_KEY'id`Required`TODO: Add a parameter description#### Example Usage

[](#example-usage-2)

```
$authorization = 'Authorization';
$id = 'id';

$result = $bookings->getBookingById($authorization, $id);
```

#### Errors

[](#errors-2)

Error CodeError Description400Bad Request401Unauthorized/Missing Token403Forbidden404Not Found0Unexpected error#### [![Method: ](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67 ".BookingsController.updateBookingById")](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67) updateBookingById

[](#-updatebookingbyid)

> Update a Booking by id

```
function updateBookingById(
        $authorization,
        $id,
        $updateBookingByIdBody = null)
```

#### Parameters

[](#parameters-3)

ParameterTagsDescriptionauthorization`Required`A valid API key, in the format 'Token API\_KEY'id`Required`TODO: Add a parameter descriptionupdateBookingByIdBody`Optional`the content of the request#### Example Usage

[](#example-usage-3)

```
$authorization = 'Authorization';
$id = 'id';
$updateBookingByIdBody = new UpdateBookingByIdBody();

$result = $bookings->updateBookingById($authorization, $id, $updateBookingByIdBody);

#### Errors

| Error Code | Error Description |
|------------|-------------------|
| 400 | Bad Request |
| 401 | Unauthorized/Missing Token |
| 403 | Forbidden |
| 404 | Not Found |
| 422 | Unprocessable Entity |
| 0 | Unexpected error |

#### ![Method: ](https://apidocs.io/img/method.png ".BookingsController.cancelBookingById") cancelBookingById

> Cancel a Booking by id

```php
function cancelBookingById(
        $authorization,
        $id,
        $cancelRecurring = null,
        $date = null,
        $endDate = null)
```

#### Parameters

[](#parameters-4)

ParameterTagsDescriptionauthorization`Required`A valid API key, in the format 'Token API\_KEY'id`Required`TODO: Add a parameter descriptioncancelRecurring`Optional`When a recurring booking, one of: \['instance', 'all', 'infinite'\]date`Optional`If a recurring booking, the date of an instance to cancel. Several formats are supported: '2014-10-31', 'October 31, 2014'endDate`Optional`If recurring, cancel up to :end\_date or leave blank for infinite booking. Several formats are supported: '2014-10-31', 'October 31, 2014'.#### Example Usage

[](#example-usage-4)

```
$authorization = 'Authorization';
$id = 'id';
$cancelRecurring = 'cancel_recurring';
$date = date("D M d, Y G:i");
$endDate = date("D M d, Y G:i");

$result = $bookings->cancelBookingById($authorization, $id, $cancelRecurring, $date, $endDate);
```

#### Errors

[](#errors-3)

Error CodeError Description400Bad Request401Unauthorized/Missing Token403Forbidden404Not Found0Unexpected error[Back to List of Controllers](#list_of_controllers)

### [![Class: ](https://camo.githubusercontent.com/ec8022a6fb768aa7d81b8226237aadf63b8a726efab75a8314b224e54194c885/68747470733a2f2f617069646f63732e696f2f696d672f636c6173732e706e67 ".CategoriesController")](https://camo.githubusercontent.com/ec8022a6fb768aa7d81b8226237aadf63b8a726efab75a8314b224e54194c885/68747470733a2f2f617069646f63732e696f2f696d672f636c6173732e706e67) CategoriesController

[](#-categoriescontroller)

#### Get singleton instance

[](#get-singleton-instance-1)

The singleton instance of the `CategoriesController` class can be accessed from the API Client.

```
$categories = $client->getCategories();
```

#### [![Method: ](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67 ".CategoriesController.getCategories")](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67) getCategories

[](#-getcategories)

> Return list of Categories.

```
function getCategories(
        $authorization,
        $page = 1,
        $perPage = 10,
        $userId = null)
```

#### Parameters

[](#parameters-5)

ParameterTagsDescriptionauthorization`Required`A valid API key, in the format 'Token API\_KEY'page`Optional` `DefaultValue`Page offset to fetch.perPage`Optional` `DefaultValue`Number of results to return per page.userId`Optional`Retrieve Categories of all services provided by this User Id. You must be authorized to manage this User Id.#### Example Usage

[](#example-usage-5)

```
$authorization = 'Authorization';
$page = 1;
$perPage = 10;
$userId = 131;

$result = $categories->getCategories($authorization, $page, $perPage, $userId);
```

#### Errors

[](#errors-4)

Error CodeError Description400Bad Request401Unauthorized/Missing Token403Forbidden0Unexpected error#### [![Method: ](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67 ".CategoriesController.createCategory")](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67) createCategory

[](#-createcategory)

> Create a Category

```
function createCategory(
        $authorization,
        $createCategoryBody = null)
```

#### Parameters

[](#parameters-6)

ParameterTagsDescriptionauthorization`Required`A valid API key, in the format 'Token API\_KEY'createCategoryBody`Optional`the content of the request#### Example Usage

[](#example-usage-6)

```
$authorization = 'Authorization';
$createCategoryBody = new CreateCategoryBody();

$result = $categories->createCategory($authorization, $createCategoryBody);
```

#### Errors

[](#errors-5)

Error CodeError Description400Bad Request401Unauthorized/Missing Token403Forbidden422Unprocessable Entity0Unexpected error#### [![Method: ](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67 ".CategoriesController.getCategoryById")](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67) getCategoryById

[](#-getcategorybyid)

> Return a Category by id.

```
function getCategoryById(
        $authorization,
        $id)
```

#### Parameters

[](#parameters-7)

ParameterTagsDescriptionauthorization`Required`A valid API key, in the format 'Token API\_KEY'id`Required`TODO: Add a parameter description#### Example Usage

[](#example-usage-7)

```
$authorization = 'Authorization';
$id = 'id';

$result = $categories->getCategoryById($authorization, $id);
```

#### Errors

[](#errors-6)

Error CodeError Description400Bad Request401Unauthorized/Missing Token403Forbidden404Not Found0Unexpected error[Back to List of Controllers](#list_of_controllers)

### [![Class: ](https://camo.githubusercontent.com/ec8022a6fb768aa7d81b8226237aadf63b8a726efab75a8314b224e54194c885/68747470733a2f2f617069646f63732e696f2f696d672f636c6173732e706e67 ".PricingModelsController")](https://camo.githubusercontent.com/ec8022a6fb768aa7d81b8226237aadf63b8a726efab75a8314b224e54194c885/68747470733a2f2f617069646f63732e696f2f696d672f636c6173732e706e67) PricingModelsController

[](#-pricingmodelscontroller)

#### Get singleton instance

[](#get-singleton-instance-2)

The singleton instance of the `PricingModelsController` class can be accessed from the API Client.

```
$pricingModels = $client->getPricingModels();
```

#### [![Method: ](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67 ".PricingModelsController.getPricingModels")](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67) getPricingModels

[](#-getpricingmodels)

> Return list of PricingModels.

```
function getPricingModels(
        $authorization,
        $page = 1,
        $perPage = 10,
        $userId = null)
```

#### Parameters

[](#parameters-8)

ParameterTagsDescriptionauthorization`Required`A valid API key, in the format 'Token API\_KEY'page`Optional` `DefaultValue`Page offset to fetch.perPage`Optional` `DefaultValue`Number of results to return per page.userId`Optional`Retrieve PricingModels owned only by this User Id. You must be authorized to manage this User Id.#### Example Usage

[](#example-usage-8)

```
$authorization = 'Authorization';
$page = 1;
$perPage = 10;
$userId = 131;

$result = $pricingModels->getPricingModels($authorization, $page, $perPage, $userId);
```

#### Errors

[](#errors-7)

Error CodeError Description401Unauthorized/Missing Token403Forbidden404Not Found0Unexpected error#### [![Method: ](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67 ".PricingModelsController.createPricingModel")](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67) createPricingModel

[](#-createpricingmodel)

> Create a PricingModel with params

```
function createPricingModel(
        $authorization,
        $createPricingModelBody = null)
```

#### Parameters

[](#parameters-9)

ParameterTagsDescriptionauthorization`Required`A valid API key, in the format 'Token API\_KEY'createPricingModelBody`Optional`the content of the request#### Example Usage

[](#example-usage-9)

```
$authorization = 'Authorization';
$createPricingModelBody = new CreatePricingModelBody();

$result = $pricingModels->createPricingModel($authorization, $createPricingModelBody);
```

#### Errors

[](#errors-8)

Error CodeError Description400Bad Request401Unauthorized/Missing Token403Forbidden422Unprocessable Entity0Unexpected error#### [![Method: ](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67 ".PricingModelsController.getPricingModelById")](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67) getPricingModelById

[](#-getpricingmodelbyid)

> Return a PricingModel by id.

```
function getPricingModelById(
        $authorization,
        $id)
```

#### Parameters

[](#parameters-10)

ParameterTagsDescriptionauthorization`Required`A valid API key, in the format 'Token API\_KEY'id`Required`TODO: Add a parameter description#### Example Usage

[](#example-usage-10)

```
$authorization = 'Authorization';
$id = 'id';

$result = $pricingModels->getPricingModelById($authorization, $id);
```

#### Errors

[](#errors-9)

Error CodeError Description400Bad Request401Unauthorized/Missing Token403Forbidden404Not Found0Unexpected error#### [![Method: ](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67 ".PricingModelsController.updatePricingModelById")](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67) updatePricingModelById

[](#-updatepricingmodelbyid)

> Update a PricingModel by id, with params

```
function updatePricingModelById(
        $authorization,
        $id,
        $updatePricingModelByIdBody = null)
```

#### Parameters

[](#parameters-11)

ParameterTagsDescriptionauthorization`Required`A valid API key, in the format 'Token API\_KEY'id`Required`TODO: Add a parameter descriptionupdatePricingModelByIdBody`Optional`the content of the request#### Example Usage

[](#example-usage-11)

```
$authorization = 'Authorization';
$id = 'id';
$updatePricingModelByIdBody = new UpdatePricingModelByIdBody();

$result = $pricingModels->updatePricingModelById($authorization, $id, $updatePricingModelByIdBody);
```

#### Errors

[](#errors-10)

Error CodeError Description400Bad Request401Unauthorized/Missing Token403Forbidden404Not Found422Unprocessable Entity0Unexpected error[Back to List of Controllers](#list_of_controllers)

### [![Class: ](https://camo.githubusercontent.com/ec8022a6fb768aa7d81b8226237aadf63b8a726efab75a8314b224e54194c885/68747470733a2f2f617069646f63732e696f2f696d672f636c6173732e706e67 ".ResourcesController")](https://camo.githubusercontent.com/ec8022a6fb768aa7d81b8226237aadf63b8a726efab75a8314b224e54194c885/68747470733a2f2f617069646f63732e696f2f696d672f636c6173732e706e67) ResourcesController

[](#-resourcescontroller)

#### Get singleton instance

[](#get-singleton-instance-3)

The singleton instance of the `ResourcesController` class can be accessed from the API Client.

```
$resources = $client->getResources();
```

#### [![Method: ](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67 ".ResourcesController.getResources")](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67) getResources

[](#-getresources)

> Return list of Resources.

```
function getResources(
        $authorization,
        $page = 1,
        $perPage = 10,
        $userId = null)
```

#### Parameters

[](#parameters-12)

ParameterTagsDescriptionauthorization`Required`A valid API key, in the format 'Token API\_KEY'page`Optional` `DefaultValue`Page offset to fetch.perPage`Optional` `DefaultValue`Number of results to return per page.userId`Optional`Retrieve Resources owned only by this User Id. You must be authorized to manage this User Id.#### Example Usage

[](#example-usage-12)

```
$authorization = 'Authorization';
$page = 1;
$perPage = 10;
$userId = 89;

$result = $resources->getResources($authorization, $page, $perPage, $userId);
```

#### Errors

[](#errors-11)

Error CodeError Description401Unauthorized/Missing Token403Forbidden404Not Found0Unexpected error#### [![Method: ](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67 ".ResourcesController.createResource")](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67) createResource

[](#-createresource)

> Create a Resource with params

```
function createResource(
        $authorization,
        $createResourceBody = null)
```

#### Parameters

[](#parameters-13)

ParameterTagsDescriptionauthorization`Required`A valid API key, in the format 'Token API\_KEY'createResourceBody`Optional`the content of the request#### Example Usage

[](#example-usage-13)

```
$authorization = 'Authorization';
$createResourceBody = new CreateResourceBody();

$result = $resources->createResource($authorization, $createResourceBody);
```

#### Errors

[](#errors-12)

Error CodeError Description400Bad Request401Unauthorized/Missing Token403Forbidden422Unprocessable Entity0Unexpected error#### [![Method: ](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67 ".ResourcesController.getResourceThings")](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67) getResourceThings

[](#-getresourcethings)

> Return all Resource Things.

```
function getResourceThings(
        $authorization,
        $page = 1,
        $perPage = 10)
```

#### Parameters

[](#parameters-14)

ParameterTagsDescriptionauthorization`Required`A valid API key, in the format 'Token API\_KEY'page`Optional` `DefaultValue`Page offset to fetch.perPage`Optional` `DefaultValue`Number of results to return per page.#### Example Usage

[](#example-usage-14)

```
$authorization = 'Authorization';
$page = 1;
$perPage = 10;

$result = $resources->getResourceThings($authorization, $page, $perPage);
```

#### Errors

[](#errors-13)

Error CodeError Description400Bad Request401Unauthorized/Missing Token403Forbidden0Unexpected error#### [![Method: ](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67 ".ResourcesController.getResourceById")](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67) getResourceById

[](#-getresourcebyid)

> Return a Resource by id.

```
function getResourceById(
        $authorization,
        $id)
```

#### Parameters

[](#parameters-15)

ParameterTagsDescriptionauthorization`Required`A valid API key, in the format 'Token API\_KEY'id`Required`TODO: Add a parameter description#### Example Usage

[](#example-usage-15)

```
$authorization = 'Authorization';
$id = 'id';

$result = $resources->getResourceById($authorization, $id);
```

#### Errors

[](#errors-14)

Error CodeError Description400Bad Request401Unauthorized/Missing Token403Forbidden404Not Found0Unexpected error#### [![Method: ](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67 ".ResourcesController.updateResourceById")](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67) updateResourceById

[](#-updateresourcebyid)

> Update a Resource by id, with params

```
function updateResourceById(
        $authorization,
        $id,
        $updateResourceByIdBody = null)
```

#### Parameters

[](#parameters-16)

ParameterTagsDescriptionauthorization`Required`A valid API key, in the format 'Token API\_KEY'id`Required`TODO: Add a parameter descriptionupdateResourceByIdBody`Optional`the content of the request#### Example Usage

[](#example-usage-16)

```
$authorization = 'Authorization';
$id = 'id';
$updateResourceByIdBody = new UpdateResourceByIdBody();

$result = $resources->updateResourceById($authorization, $id, $updateResourceByIdBody);
```

#### Errors

[](#errors-15)

Error CodeError Description400Bad Request401Unauthorized/Missing Token403Forbidden404Not Found422Unprocessable Entity0Unexpected error#### [![Method: ](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67 ".ResourcesController.deleteResourceById")](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67) deleteResourceById

[](#-deleteresourcebyid)

> Delete a Resource by id

```
function deleteResourceById(
        $authorization,
        $id)
```

#### Parameters

[](#parameters-17)

ParameterTagsDescriptionauthorization`Required`A valid API key, in the format 'Token API\_KEY'id`Required`TODO: Add a parameter description#### Example Usage

[](#example-usage-17)

```
$authorization = 'Authorization';
$id = 'id';

$result = $resources->deleteResourceById($authorization, $id);
```

#### Errors

[](#errors-16)

Error CodeError Description400Bad Request401Unauthorized/Missing Token403Forbidden404Not Found0Unexpected error[Back to List of Controllers](#list_of_controllers)

### [![Class: ](https://camo.githubusercontent.com/ec8022a6fb768aa7d81b8226237aadf63b8a726efab75a8314b224e54194c885/68747470733a2f2f617069646f63732e696f2f696d672f636c6173732e706e67 ".SchedulesController")](https://camo.githubusercontent.com/ec8022a6fb768aa7d81b8226237aadf63b8a726efab75a8314b224e54194c885/68747470733a2f2f617069646f63732e696f2f696d672f636c6173732e706e67) SchedulesController

[](#-schedulescontroller)

#### Get singleton instance

[](#get-singleton-instance-4)

The singleton instance of the `SchedulesController` class can be accessed from the API Client.

```
$schedules = $client->getSchedules();
```

#### [![Method: ](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67 ".SchedulesController.getSchedules")](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67) getSchedules

[](#-getschedules)

> Return all Schedules that your account has access to. Includes Schedules for your own User as well as any Users for which you are the Account Manager.

```
function getSchedules(
        $authorization,
        $page = 1,
        $perPage = 10,
        $userId = null)
```

#### Parameters

[](#parameters-18)

ParameterTagsDescriptionauthorization`Required`A valid API key, in the format 'Token API\_KEY'page`Optional` `DefaultValue`Page offset to fetch.perPage`Optional` `DefaultValue`Number of results to return per page.userId`Optional`Retrieve Schedules owned only by this User Id. You must be authorized to manage this User Id.#### Example Usage

[](#example-usage-18)

```
$authorization = 'Authorization';
$page = 1;
$perPage = 10;
$userId = 89;

$result = $schedules->getSchedules($authorization, $page, $perPage, $userId);
```

#### Errors

[](#errors-17)

Error CodeError Description400Bad Request401Unauthorized/Missing Token403Forbidden404Not Found0Unexpected error#### [![Method: ](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67 ".SchedulesController.createSchedule")](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67) createSchedule

[](#-createschedule)

> Create a Schedule with params.

```
function createSchedule(
        $authorization,
        $createScheduleBody = null)
```

#### Parameters

[](#parameters-19)

ParameterTagsDescriptionauthorization`Required`A valid API key, in the format 'Token API\_KEY'createScheduleBody`Optional`the content of the request#### Example Usage

[](#example-usage-19)

```
$authorization = 'Authorization';
$createScheduleBody = new CreateScheduleBody();

$result = $schedules->createSchedule($authorization, $createScheduleBody);
```

#### Errors

[](#errors-18)

Error CodeError Description400Bad Request401Unauthorized/Missing Token403Forbidden404Not Found422Unprocessable Entity0Unexpected error#### [![Method: ](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67 ".SchedulesController.getScheduleById")](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67) getScheduleById

[](#-getschedulebyid)

> Return a Schedule by id.

```
function getScheduleById(
        $authorization,
        $id)
```

#### Parameters

[](#parameters-20)

ParameterTagsDescriptionauthorization`Required`A valid API key, in the format 'Token API\_KEY'id`Required`TODO: Add a parameter description#### Example Usage

[](#example-usage-20)

```
$authorization = 'Authorization';
$id = 'id';

$result = $schedules->getScheduleById($authorization, $id);
```

#### Errors

[](#errors-19)

Error CodeError Description400Bad Request401Unauthorized/Missing Token403Forbidden404Not Found410Gone0Unexpected error#### [![Method: ](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67 ".SchedulesController.deleteScheduleById")](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67) deleteScheduleById

[](#-deleteschedulebyid)

> Delete a Schedule

```
function deleteScheduleById(
        $authorization,
        $id)
```

#### Parameters

[](#parameters-21)

ParameterTagsDescriptionauthorization`Required`A valid API key, in the format 'Token API\_KEY'id`Required`TODO: Add a parameter description#### Example Usage

[](#example-usage-21)

```
$authorization = 'Authorization';
$id = 'id';

$result = $schedules->deleteScheduleById($authorization, $id);
```

#### Errors

[](#errors-20)

Error CodeError Description400Bad Request401Unauthorized/Missing Token403Forbidden404Not Found0Unexpected error#### [![Method: ](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67 ".SchedulesController.createScheduleTimeWindow")](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67) createScheduleTimeWindow

[](#-createscheduletimewindow)

> Add a TimeWindow to a Schedule.

```
function createScheduleTimeWindow(
        $authorization,
        $id,
        $createScheduleTimeWindowBody = null)
```

#### Parameters

[](#parameters-22)

ParameterTagsDescriptionauthorization`Required`A valid API key, in the format 'Token API\_KEY'id`Required`TODO: Add a parameter descriptioncreateScheduleTimeWindowBody`Optional`the content of the request#### Example Usage

[](#example-usage-22)

```
$authorization = 'Authorization';
$id = 'id';
$createScheduleTimeWindowBody = new CreateScheduleTimeWindowBody();

$result = $schedules->createScheduleTimeWindow($authorization, $id, $createScheduleTimeWindowBody);
```

#### Errors

[](#errors-21)

Error CodeError Description400Bad Request401Unauthorized/Missing Token403Forbidden404Not Found422Unprocessable Entity0Unexpected error#### [![Method: ](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67 ".SchedulesController.updateScheduleTimeWindowById")](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67) updateScheduleTimeWindowById

[](#-updatescheduletimewindowbyid)

> Update a TimeWindow for a Schedule.

```
function updateScheduleTimeWindowById(
        $authorization,
        $id,
        $timeWindowId,
        $updateScheduleTimeWindowByIdBody = null)
```

#### Parameters

[](#parameters-23)

ParameterTagsDescriptionauthorization`Required`A valid API key, in the format 'Token API\_KEY'id`Required`TODO: Add a parameter descriptiontimeWindowId`Required`TODO: Add a parameter descriptionupdateScheduleTimeWindowByIdBody`Optional`the content of the request#### Example Usage

[](#example-usage-23)

```
$authorization = 'Authorization';
$id = 'id';
$timeWindowId = 'time_window_id';
$updateScheduleTimeWindowByIdBody = new UpdateScheduleTimeWindowByIdBody();

$result = $schedules->updateScheduleTimeWindowById($authorization, $id, $timeWindowId, $updateScheduleTimeWindowByIdBody);
```

#### Errors

[](#errors-22)

Error CodeError Description400Bad Request401Unauthorized/Missing Token403Forbidden404Not Found422Unprocessable Entity0Unexpected error#### [![Method: ](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67 ".SchedulesController.deleteScheduleTimeWindowById")](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67) deleteScheduleTimeWindowById

[](#-deletescheduletimewindowbyid)

> Delete a TimeWindow from a Schedule

```
function deleteScheduleTimeWindowById(
        $authorization,
        $id,
        $timeWindowId)
```

#### Parameters

[](#parameters-24)

ParameterTagsDescriptionauthorization`Required`A valid API key, in the format 'Token API\_KEY'id`Required`TODO: Add a parameter descriptiontimeWindowId`Required`TODO: Add a parameter description#### Example Usage

[](#example-usage-24)

```
$authorization = 'Authorization';
$id = 'id';
$timeWindowId = 'time_window_id';

$result = $schedules->deleteScheduleTimeWindowById($authorization, $id, $timeWindowId);
```

#### Errors

[](#errors-23)

Error CodeError Description400Bad Request401Unauthorized/Missing Token403Forbidden404Not Found0Unexpected error[Back to List of Controllers](#list_of_controllers)

### [![Class: ](https://camo.githubusercontent.com/ec8022a6fb768aa7d81b8226237aadf63b8a726efab75a8314b224e54194c885/68747470733a2f2f617069646f63732e696f2f696d672f636c6173732e706e67 ".SearchController")](https://camo.githubusercontent.com/ec8022a6fb768aa7d81b8226237aadf63b8a726efab75a8314b224e54194c885/68747470733a2f2f617069646f63732e696f2f696d672f636c6173732e706e67) SearchController

[](#-searchcontroller)

#### Get singleton instance

[](#get-singleton-instance-5)

The singleton instance of the `SearchController` class can be accessed from the API Client.

```
$search = $client->getSearch();
```

#### [![Method: ](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67 ".SearchController.searchQuery")](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67) searchQuery

[](#-searchquery)

> Search for Providers and Provided Services.

```
function searchQuery(
        $authorization,
        $query)
```

#### Parameters

[](#parameters-25)

ParameterTagsDescriptionauthorization`Required`A valid API key, in the format 'Token API\_KEY'query`Required`TODO: Add a parameter description#### Example Usage

[](#example-usage-25)

```
$authorization = 'Authorization';
$query = 'query';

$result = $search->searchQuery($authorization, $query);
```

#### Errors

[](#errors-24)

Error CodeError Description400Bad Request401Unauthorized/Missing Token0Unexpected error[Back to List of Controllers](#list_of_controllers)

### [![Class: ](https://camo.githubusercontent.com/ec8022a6fb768aa7d81b8226237aadf63b8a726efab75a8314b224e54194c885/68747470733a2f2f617069646f63732e696f2f696d672f636c6173732e706e67 ".ServicesController")](https://camo.githubusercontent.com/ec8022a6fb768aa7d81b8226237aadf63b8a726efab75a8314b224e54194c885/68747470733a2f2f617069646f63732e696f2f696d672f636c6173732e706e67) ServicesController

[](#-servicescontroller)

#### Get singleton instance

[](#get-singleton-instance-6)

The singleton instance of the `ServicesController` class can be accessed from the API Client.

```
$services = $client->getServices();
```

#### [![Method: ](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67 ".ServicesController.getServices")](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67) getServices

[](#-getservices)

> Return list of Services.

```
function getServices(
        $authorization,
        $page = 1,
        $perPage = 10,
        $userId = null)
```

#### Parameters

[](#parameters-26)

ParameterTagsDescriptionauthorization`Required`A valid API key, in the format 'Token API\_KEY'page`Optional` `DefaultValue`Page offset to fetch.perPage`Optional` `DefaultValue`Number of results to return per page.userId`Optional`Retrieve Services provided by the User specified by Id. You must be authorized to manage this User Id.#### Example Usage

[](#example-usage-26)

```
$authorization = 'Authorization';
$page = 1;
$perPage = 10;
$userId = 89;

$result = $services->getServices($authorization, $page, $perPage, $userId);
```

#### Errors

[](#errors-25)

Error CodeError Description401Unauthorized/Missing Token403Forbidden404Not Found0Unexpected error#### [![Method: ](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67 ".ServicesController.createService")](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67) createService

[](#-createservice)

> Create a Service with params.

```
function createService(
        $authorization,
        $createServiceBody = null)
```

#### Parameters

[](#parameters-27)

ParameterTagsDescriptionauthorization`Required`A valid API key, in the format 'Token API\_KEY'createServiceBody`Optional`the content of the request#### Example Usage

[](#example-usage-27)

```
$authorization = 'Authorization';
$createServiceBody = new CreateServiceBody();

$result = $services->createService($authorization, $createServiceBody);
```

#### Errors

[](#errors-26)

Error CodeError Description400Bad Request401Unauthorized/Missing Token403Forbidden404Not Found422Unprocessable Entity0Unexpected error#### [![Method: ](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67 ".ServicesController.getServiceAvailableSlotsById")](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67) getServiceAvailableSlotsById

[](#-getserviceavailableslotsbyid)

> Return available times for a Service.

```
function getServiceAvailableSlotsById(
        $authorization,
        $id,
        $date = null,
        $endDate = null,
        $startDate = null)
```

#### Parameters

[](#parameters-28)

ParameterTagsDescriptionauthorization`Required`A valid API key, in the format 'Token API\_KEY'id`Required`TODO: Add a parameter descriptiondate`Optional`Date to check for availability. Either this field or a date range employing start\_date and end\_date must be supplied. If date is provided, start\_date/end\_date are ignored. Several formats are supported: '2014-10-31', 'October 31, 2014'.endDate`Optional`End Date of a range to check for availability. If supplied, date must not be supplied and start\_date must be supplied. Several formats are supported: '2014-10-31', 'October 31, 2014'.startDate`Optional`Start Date of a range to check for availability. If supplied, date must not be supplied and end\_date must be supplied. Several formats are supported: '2014-10-31', 'October 31, 2014'.#### Example Usage

[](#example-usage-28)

```
$authorization = 'Authorization';
$id = 'id';
$date = date("D M d, Y G:i");
$endDate = date("D M d, Y G:i");
$startDate = date("D M d, Y G:i");

$result = $services->getServiceAvailableSlotsById($authorization, $id, $date, $endDate, $startDate);
```

#### Errors

[](#errors-27)

Error CodeError Description400Bad Request401Unauthorized/Missing Token403Forbidden404Not Found0Unexpected error#### [![Method: ](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67 ".ServicesController.getServiceById")](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67) getServiceById

[](#-getservicebyid)

> Return a Service by id.

```
function getServiceById(
        $authorization,
        $id)
```

#### Parameters

[](#parameters-29)

ParameterTagsDescriptionauthorization`Required`A valid API key, in the format 'Token API\_KEY'id`Required`TODO: Add a parameter description#### Example Usage

[](#example-usage-29)

```
$authorization = 'Authorization';
$id = 'id';

$result = $services->getServiceById($authorization, $id);
```

#### Errors

[](#errors-28)

Error CodeError Description400Bad Request401Unauthorized/Missing Token403Forbidden404Not Found0Unexpected error#### [![Method: ](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67 ".ServicesController.updateServiceById")](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67) updateServiceById

[](#-updateservicebyid)

> Update a Service with params.

```
function updateServiceById(
        $authorization,
        $id,
        $updateServiceByIdBody = null)
```

#### Parameters

[](#parameters-30)

ParameterTagsDescriptionauthorization`Required`A valid API key, in the format 'Token API\_KEY'id`Required`TODO: Add a parameter descriptionupdateServiceByIdBody`Optional`the content of the request#### Example Usage

[](#example-usage-30)

```
$authorization = 'Authorization';
$id = 'id';
$updateServiceByIdBody = new UpdateServiceByIdBody();

$result = $services->updateServiceById($authorization, $id, $updateServiceByIdBody);
```

#### Errors

[](#errors-29)

Error CodeError Description400Bad Request401Unauthorized/Missing Token403Forbidden404Not Found422Unprocessable Entity0Unexpected error#### [![Method: ](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67 ".ServicesController.deleteServiceById")](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67) deleteServiceById

[](#-deleteservicebyid)

> Delete a Service by id

```
function deleteServiceById(
        $authorization,
        $id)
```

#### Parameters

[](#parameters-31)

ParameterTagsDescriptionauthorization`Required`A valid API key, in the format 'Token API\_KEY'id`Required`TODO: Add a parameter description#### Example Usage

[](#example-usage-31)

```
$authorization = 'Authorization';
$id = 'id';

$result = $services->deleteServiceById($authorization, $id);
```

#### Errors

[](#errors-30)

Error CodeError Description400Bad Request401Unauthorized/Missing Token403Forbidden404Not Found0Unexpected error[Back to List of Controllers](#list_of_controllers)

### [![Class: ](https://camo.githubusercontent.com/ec8022a6fb768aa7d81b8226237aadf63b8a726efab75a8314b224e54194c885/68747470733a2f2f617069646f63732e696f2f696d672f636c6173732e706e67 ".UsersController")](https://camo.githubusercontent.com/ec8022a6fb768aa7d81b8226237aadf63b8a726efab75a8314b224e54194c885/68747470733a2f2f617069646f63732e696f2f696d672f636c6173732e706e67) UsersController

[](#-userscontroller)

#### Get singleton instance

[](#get-singleton-instance-7)

The singleton instance of the `UsersController` class can be accessed from the API Client.

```
$users = $client->getUsers();
```

#### [![Method: ](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67 ".UsersController.getUsers")](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67) getUsers

[](#-getusers)

> Return all Users that your account has access to. Includes your own User as well as any Users for which you are the Account Manager.

```
function getUsers(
        $authorization,
        $page = 1,
        $perPage = 10)
```

#### Parameters

[](#parameters-32)

ParameterTagsDescriptionauthorization`Required`A valid API key, in the format 'Token API\_KEY'page`Optional` `DefaultValue`Page offset to fetch.perPage`Optional` `DefaultValue`Number of results to return per page.#### Example Usage

[](#example-usage-32)

```
$authorization = 'Authorization';
$page = 1;
$perPage = 10;

$result = $users->getUsers($authorization, $page, $perPage);
```

#### Errors

[](#errors-31)

Error CodeError Description400Bad Request401Unauthorized/Missing Token403Forbidden0Unexpected error#### [![Method: ](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67 ".UsersController.createUser")](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67) createUser

[](#-createuser)

> Create a User

```
function createUser(
        $authorization,
        $createUserBody = null)
```

#### Parameters

[](#parameters-33)

ParameterTagsDescriptionauthorization`Required`A valid API key, in the format 'Token API\_KEY'createUserBody`Optional`the content of the request#### Example Usage

[](#example-usage-33)

```
$authorization = 'Authorization';
$createUserBody = new CreateUserBody();

$result = $users->createUser($authorization, $createUserBody);
```

#### Errors

[](#errors-32)

Error CodeError Description400Bad Request401Unauthorized/Missing Token403Forbidden422Unprocessable Entity0Unexpected error#### [![Method: ](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67 ".UsersController.getUserById")](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67) getUserById

[](#-getuserbyid)

> Return a User by id.

```
function getUserById(
        $authorization,
        $id)
```

#### Parameters

[](#parameters-34)

ParameterTagsDescriptionauthorization`Required`A valid API key, in the format 'Token API\_KEY'id`Required`TODO: Add a parameter description#### Example Usage

[](#example-usage-34)

```
$authorization = 'Authorization';
$id = 'id';

$result = $users->getUserById($authorization, $id);
```

#### Errors

[](#errors-33)

Error CodeError Description400Bad Request401Unauthorized/Missing Token403Forbidden404Not Found0Unexpected error#### [![Method: ](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67 ".UsersController.updateUserById")](https://camo.githubusercontent.com/501a7bfa57a34ebbde43bfe00d7218a47c0a18eae15acb62480b8716f604ee87/68747470733a2f2f617069646f63732e696f2f696d672f6d6574686f642e706e67) updateUserById

[](#-updateuserbyid)

> Update a User by id, with params.

```
function updateUserById(
        $authorization,
        $id,
        $updateUserByIdBody = null)
```

#### Parameters

[](#parameters-35)

ParameterTagsDescriptionauthorization`Required`A valid API key, in the format 'Token API\_KEY'id`Required`TODO: Add a parameter descriptionupdateUserByIdBody`Optional`the content of the request#### Example Usage

[](#example-usage-35)

```
$authorization = 'Authorization';
$id = 'id';
$updateUserByIdBody = new UpdateUserByIdBody();

$result = $users->updateUserById($authorization, $id, $updateUserByIdBody);
```

#### Errors

[](#errors-34)

Error CodeError Description400Bad Request401Unauthorized/Missing Token403Forbidden404Not Found422Unprocessable Entity0Unexpected error[Back to List of Controllers](#list_of_controllers)

###  Health Score

25

—

LowBetter than 37% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity6

Limited adoption so far

Community12

Small or concentrated contributor base

Maturity56

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 64.1% 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

Every ~16 days

Recently: every ~22 days

Total

14

Last Release

3248d ago

PHP version history (2 changes)v0.0.2PHP &gt;=5.4.0

v0.0.8PHP &gt;=5.6.0

### Community

Maintainers

![](https://www.gravatar.com/avatar/891d9c42ee27140c0e3118b02bfad9bef8b082c383308ab9e1e196cabd6dff82?d=identicon)[alexagranov](/maintainers/alexagranov)

---

Top Contributors

[![jorgeorpinel](https://avatars.githubusercontent.com/u/1477535?v=4)](https://github.com/jorgeorpinel "jorgeorpinel (116 commits)")[![alexagranov](https://avatars.githubusercontent.com/u/125607?v=4)](https://github.com/alexagranov "alexagranov (65 commits)")

---

Tags

gonebusyphpphp-sdksdkapisdkGoneBusy API

###  Code Quality

TestsPHPUnit

Code StylePHP\_CodeSniffer

### Embed Badge

![Health badge](/badges/gonebusy-gonebusy-php-client/health.svg)

```
[![Health](https://phpackages.com/badges/gonebusy-gonebusy-php-client/health.svg)](https://phpackages.com/packages/gonebusy-gonebusy-php-client)
```

###  Alternatives

[bandwidth/sdk

Bandwidth's set of APIs

16948.8k1](/packages/bandwidth-sdk)[messagemedia/messages-sdk

The MessageMedia Messages API provides a number of endpoints for building powerful two-way messaging applications.

13390.6k](/packages/messagemedia-messages-sdk)

PHPackages © 2026

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