SDKs
PHP SDK
Install and use the MisarReach PHP SDK — lead finder, SSE job streaming, deals/pipeline CRM, and multi-channel outreach.
Official PHP SDK for MisarReach — lead finder (23 sources), multi-channel outreach, and CRM (deals, pipeline, sales agents). Authenticates with an mrk_ API key against https://api.misar.io/reach/api. Requires PHP 8.1+ (ext-curl, ext-json).
Install
composer require misarai/misarreach-phpConfigure
use MisarReach\Client;
$client = new Client('mrk_...');Lead search + SSE stream
// Start an async lead search
$job = $client->leads->search(['query' => 'saas founders', 'limit' => 25]);
// Stream job progress over Server-Sent Events
$client->leads->streamJob($job['jobId'], function (string $event, array $data, string $raw) {
match ($event) {
'progress' => printf("found: %d\n", $data['total_found'] ?? 0),
'complete' => print("done\n"),
'error' => printf("error: %s\n", $data['error'] ?? ''),
default => null,
};
});Deals & channels
$client->deals->create(['leadEmail' => 'cto@acme.com', 'value' => 5000]);
$pipeline = $client->pipeline->get();
$channels = $client->channels->status();
$client->channels->connectSms(['number' => '+1...']);Resources
leads · ads · autopilot · campaigns · channels · contacts · conversations · deals · pipeline · salesAgent · settings · workspaces.
Errors
Throws typed ApiError subclasses:
AuthError— 401 / 403NotFoundError— 404RateLimitError($balance,$freeRemaining,$upgrade) — 429NetworkError— transport failure / retries exhaustedApiError— any other non-2xx ($status,$code)
Retryable statuses (429, 500, 502, 503, 504) are retried with exponential backoff ($maxRetries, default 3).
See the API Reference and SSE stream.