A wrapper for LockLizard Enterprise v4 API, to make the API slightly more paletable.
- Parses LockLizard's utterly bizzare response format, returning associative arrays
- Automatically chunks requests that contain more than 200 IDs
- Fakes some helpful methods not in the LockLizard API, for instance replacing access rules instead of just adding or removing
- Throw exceptions on errors
- Write tests
- Improve send and sendPost methods?
- Possibly add some more methods via screen scraping of the admin? It's not possible to get the number of activations via the API...
<?php
$api = new LockLizardAdminAPI($server_url, $username, $password);
$customers = $api->listCustomer('email', '[email protected]');
// $customers = [
// 'status' => 'OK', 'data' => [
// 'id' => 'xxx',
// 'name' => 'xxx',
// 'email' => 'xxx',
// 'company_name' => 'xxx',
// 'valid_from' => 'xxx',
// 'expires_at' => 'xxx',
// 'licenses' => 'xxx',
// 'active' => 'xxx',
// 'registered' => 'xxx'
// ]
// ];
?>
Check out the code - it's pretty well commented.
Released under MIT license