sendpulse/rest-api
Official PHP client for the SendPulse REST API, supporting API key and OAuth auth. Manage bulk email campaigns, transactional SMTP, SMS, CRM contacts and chatbots through a typed, ergonomic service layer with optional PSR-18 and PSR-16 adapters. Requires PHP 8.3+ and ext-curl/ext-json.
/crm/v1/* and chatbot endpoints /chatbots/*; previously every call returned 404.rawurlencode() in all generated operations; values containing #, ?, / or + no longer corrupt the request URI.ForbiddenException added — HTTP 403 (tariff or permission restriction) is now thrown as ForbiddenException instead of AuthException; the two can be caught and handled independently.SendPulseExceptionInterface added — NetworkException and ProtocolException now implement this marker interface alongside the SendPulseException hierarchy; a single catch (SendPulseExceptionInterface $e) block covers all six SDK exception classes.ResponseValidator now throws ProtocolException when the API returns a JSON primitive (true, a number, a string) instead of silently returning [].Complete rewrite. See docs/upgrading.md for the migration guide.
new Sendpulse\RestApi\Client(apiKey: '...') instead of the old ApiClient class.clientId + clientSecret) and API key (apiKey) are now named constructor arguments; the old positional (API_USER_ID, API_SECRET, $storage) signature is gone.get()/post()/put()/patch()/delete() calls replaced by typed facades (emailService(), smtpService(), etc.).ApiClientException replaced by a typed hierarchy: AuthException, RateLimitException, ApiException, NetworkException, ProtocolException.FileStorage/SessionStorage/MemcachedStorage removed; use FileTokenStorage, InMemoryTokenStorage, or bring your own via TokenStorage interface.emailService(), smtpService(), smsService(), crmService(), chatbotService().TokenStorage interface with FileTokenStorage (atomic, flock-based) and InMemoryTokenStorage.Psr16TokenStorage) and PSR-18 HTTP adapter (Http\Adapter\Psr18Adapter).401 — cached token is invalidated and a fresh one is fetched before retrying once.ApiClient API unchanged.smtpSendEmail response handling.How can I help you explore Laravel packages today?