Skip to main content

PHP SDK

The jetemail/jetemail-php package is the official PHP SDK for JetEmail transactional email (MIT license, PHP 8.1+). Create a transactional API key in the dashboard: OutboundKeys → Add API key. Use that key with the SDK.
For Laravel projects, use the dedicated Laravel SDK which includes Mail driver integration and webhook support.

Installation

Package on Packagist: jetemail/jetemail-php.

Quick start

Use a from address on a verified domain (see Getting started).

Constructor

$client->email->send(options)

Send a single email. Response shape: ['id' => string, 'response' => string].

$client->batch->send(emails)

Send up to 100 emails in one request. Returns summary (total, successful, failed) and results per message.

Attachments

Error handling

Common status codes: 400 invalid request, 401 bad/missing API key, 500 server error.
For additional examples and the full option list, see the Packagist package page. REST details: API reference.