Generated API client for the EasySQL API — the client package of the PHP SDK.
🤖 Generated — src/Client.php, src/Models/ and docs/API.md are produced by
scripts/generate.php from the OpenAPI spec at /openapi.json. Do not edit them by hand;
regenerate with make generate from the repository root. CI (make check) fails when the
generated files differ from a fresh regeneration.
The hand-written runtime in src/Exceptions/ and src/Http/ (required by the generated
client) is never overwritten by the generator.
composer require clearsoft/easysql-clientRequirements: PHP >= 8.2, ext-json, guzzlehttp/guzzle ^7.0.
use Clearsoft\EasySQL\Client\Client;
$client = new Client([
'base_url' => 'https://api.easysql.net',
'access_token' => 'your-access-token',
]);
$user = $client->me();
$connection = $client->getConnection('conn_abc123');With automatic token refresh:
use Clearsoft\EasySQL\Client\Http\EasySQLClient;
$client = new EasySQLClient([
'base_url' => 'https://api.easysql.net',
'access_token' => $accessToken,
'refresh_token' => $refreshToken,
]);
$client->setTokenStore(new MyTokenStore()); // implements Http\TokenStoreInterfaceSee docs/API.md for the full endpoint reference.