fw4/whise-webservices

This package is abandoned and no longer maintained. The author suggests using the fw4/whise-api package instead.

PHP library for implementing WHISE Webservices

1.1.5 2022-12-20 10:36 UTC

This package is auto-updated.

Last update: 2022-12-20 10:37:16 UTC


README

PHP client for the Whise webservices.

⚠️ The Whise webservices are deprecated and will be shut down September 2022. It's strongly recommended to use the Whise API instead.

Installation

composer require fw4/whise-webservices

Usage

$client = new \Whise\WebServices('12345');
$estates = $client->getEstateList([
    'CountryID' => 1
]);
foreach ($estates as $estate) var_dump($estate->id);

It's also possible to construct requests through objects:

$request = new \Whise\Request\GetEstateListRequest();
$request->countryID = 1;
$request->zipList = [1000];

$client = new \Whise\WebServices('12345');
$estates = $client->getEstates($request);
foreach ($estates as $estate) var_dump($estate->id);

Properties on both requests and responses are implemented case insensitively.

Pagination

When iterating over a response containing multiple objects, sequential pagination requests will automatically be sent in the background.

Due to unresolved bugs in the webservices, counting some responses might return an incorrect amount.