PHPackages                             serkancelik17/hotel\_content\_api\_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. [API Development](/categories/api)
4. /
5. serkancelik17/hotel\_content\_api\_sdk

ActiveLibrary[API Development](/categories/api)

serkancelik17/hotel\_content\_api\_sdk
======================================

Hotelbeds Hotel-API SDK for PHP

v1.0.0(4y ago)04LGPL-2.1PHPPHP &gt;=5.5

Since May 25Pushed 4y agoCompare

[ Source](https://github.com/serkancelik17/hotel_content_api_sdk)[ Packagist](https://packagist.org/packages/serkancelik17/hotel_content_api_sdk)[ RSS](/packages/serkancelik17-hotel-content-api-sdk/feed)WikiDiscussions master Synced 3w ago

READMEChangelog (1)Dependencies (8)Versions (3)Used By (0)

hotel-api-sdk-php
=================

[](#hotel-api-sdk-php)

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

[](#introduction)

Hotelbeds SDK for PHP is a set of utilities whose main goal is to help in the development of PHP applications that use APItude, the Hotelbeds API. This is a composer library available on packagist.org repository.

License
-------

[](#license)

This softwared is licensed under the LGPL v2.1 license. Please refer to the file LICENSE for specific details and more license and copyright information.

Install
-------

[](#install)

Install from console with Composer utility:

```
composer require hotelbeds/hotel-api-sdk-php
```

Using Composer Dependency Manager with PHPStorm:

Testing
-------

[](#testing)

In the directory unit tests can find different tests that can be run with phpunit. There are different sets of tests: Availability and bookings.

```
.\vendor\bin\phpunit --testsuite availability
```

This testsuite execute: status of API, make availability on PMI destination, select one room and do checkrate and booking.

Using SDK
---------

[](#using-sdk)

### Overview

[](#overview)

The HotelApiClient class has different methods that implement the various calls HotelAPI:

- Availability
- CheckRate
- BookingConfirm
- BookingCancellation
- BookingList
- Status

Each method has a parameter that is ApiHelper type, there are four possible types:

- Availability
- CheckRate
- Booking
- BookingList

All responses each call can either iterate using PHP with objects or arrays. Internally converts the JSON response structure PHP associative arrays.

### Include library using autoload PSR-0

[](#include-library-using-autoload-psr-0)

```
