SDK Quickstart

PHP SDK Quickstart

Install khaleejiapi/sdk, configure your API key, and make your first authenticated API call.

1) Install

bash
composer require khaleejiapi/sdk

2) Environment variable setup

text
KHALEEJI_API_KEY=your_api_key_here

3) Minimal working example

php
<?php
use KhaleejiAPI\KhaleejiAPI;
$apiKey = getenv('KHALEEJI_API_KEY');
if (!$apiKey) {
throw new RuntimeException('Missing KHALEEJI_API_KEY');
}
$client = new KhaleejiAPI($apiKey);
$result = $client->validation->validateEmail('[email protected]');
echo $result['valid'];

Next steps

Test your key with a real endpoint from the API reference.

Use retries/rate-limit handling for production workloads.

Review authentication and rate limits before going live.