/php-mailerlite

A PHP library for working w/ the MailerLite API.

Primary LanguagePHPMIT LicenseMIT

MailerLite

A PHP package for working w/ the MailerLite API.

Install

Normal install via Composer.

Usage

use Travis\MailerLite;

$apikey = 'YOURAPIKEY';
$listid = 'YOURLISTID';

try
{
	$test = MailerLite::run($apikey, 'post', 'groups/'.$listid.'/subscribers', [
		'name' => 'Paul Tarsus',
		'email' => 'paul@tarsus.net',
	]);
}
catch (\Exception $e)
{
	echo $e->getMessage();
}

See the API Guide for additional methods.