ALTELMA / laravel-mailchimp by ALTELMA

A packages provide you to connect with mailchimp API v3, so easiest.
2,303
5
2
Package Data
Maintainer Username: ALTELMA
Maintainer Contact: nrohtgnohp@gmail.com (ALTELMA)
Package Create Date: 2015-08-20
Package Last Update: 2022-03-11
Home Page:
Language: PHP
License: MIT
Last Refreshed: 2024-03-01 15:11:31
Package Statistics
Total Downloads: 2,303
Monthly Downloads: 152
Daily Downloads: 9
Total Stars: 5
Total Watchers: 2
Total Forks: 3
Total Open Issues: 0

Laravel MailChimp

Installation

require composer altelma/laravel-mailchimp --prefer-dist dev-master

or update your composer.json in root

{
  "require": {
    "altelma/laravel-mailchimp": "dev-master"
  }
}

After installation finish. add this to your config/app.php

providers => [
        LaravelMailChimp\MailChimpServiceProvider::class  
],

For optional if you want to use Alias class you can add this to config/app.php

aliases => [
      'MailChimp' => LaravelMailChimp\MailChimpFacde::class
]

Make sure you never use "MailChimp" or exists this in your project. After you finish config all run artisan to create config

php artisan vendor:publish

Usage

$mc = new MailChimp('Your API KEY');
$results = $mc->get('lists/your_directory_list/members');
echo json_decode($results);

// or
return reponse()-json($results);

// With Alias
$results = MailChimp::get('lists/your_directory_list/members');
echo json_decode($results);

// or
return reponse()-json($results);

Bug report

This package is not perfect right, but can be improve together. If you found bug or have any suggestion. Send that to me or new issue. Thank you to use it.