/php-mailjet

A PHP package for working w/ the Mailjet API.

Primary LanguagePHPMIT LicenseMIT

Mailjet

A PHP library for working w/ the Mailjet API.

Install

Normal install via Composer.

Usage

Call the run method:

use Travis\Mailjet;

$apikey_public = 'your-api-key-public';
$apikey_secret = 'your-api-key-secret';
$list_id = 'your-contact-list-id';

// add new subscriber
$test = Mailjet::run($apikey_public, $apikey_secret, 'contactslist/'.$list_id.'/managecontact', 'post', [
	'name' => 'Jack Bauer',
	'email' => 'jbauer@foobar.net',
	'action' => 'addforce',
]);