Titus version of the PHP SDK for the Nitrapi RESTful API.
- PHP 7.3 or higher
- Composer
Edit the composer.json and execute composer.phar update
{
"require": {
"tituskirch/nitrapi-php-lib": "dev-main",
}
}
<?php
require_once '../vendor/autoload.php';
try {
$api = new \Nitrapi\Nitrapi("<accesss token>");
var_dump($api->getServices());
} catch(\Exception $e) {
var_dump("API Error: " . $e->getMessage());
}