2017 © Pedro PelĂĄez
 

library simplemailchimp

A simple MailChimp API wrapper, SimpleMailChimp makes it easy to pass data back and forth between your website and your MailChimp account. This includes subscribing or unsubscribing users, getting a subscriber’s details and getting all the members of a particular list.

image

rapidwebltd/simplemailchimp

A simple MailChimp API wrapper, SimpleMailChimp makes it easy to pass data back and forth between your website and your MailChimp account. This includes subscribing or unsubscribing users, getting a subscriber’s details and getting all the members of a particular list.

  • Friday, March 23, 2018
  • by DivineOmega
  • Repository
  • 5 Watchers
  • 1 Stars
  • 82 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 10 Versions
  • 3 % Grown

The README.md

đŸ” SimpleMailChimp

SimpleMailChimp is a simplified wrapper for common MailChimp functionality., (*1)

Simple MailChimp usage, (*2)

Installation

To install this package, just use composer., (*3)

composer require rapidwebltd/simplemailchimp

If your framework does not already do so, you must add require_once "vendor/autoload.php" to any files in which you wish to use SimpleMailChimp., (*4)

Getting Started

In order to create a SimpleMailChimp object, call the getByAPIKey function from the SimpleMailChimpFactory and pass it your API key., (*5)

$simpleMailChimp = SimpleMailChimpFactory::getByAPIKey('API_KEY_GOES_HERE');

Subscribing a user to a list

To subscribe a user to a list call the subscribe function and pass through the MailChimp list id and the user's email., (*6)

$simpleMailChimp->subscribe('LIST_ID_GOES_HERE', 'example@example.com');

If successful it will return an array containing the subscriber's data., (*7)

Unsubscribing a user from a list

To unsubscribe a user from a list call the unsubscribe function and pass through the MailChimp list id and the user's email., (*8)

$simpleMailChimp->unsubscribe('LIST_ID_GOES_HERE', 'example@example.com');

If successful it will return an array containing the subscriber's data., (*9)

Getting a subscriber's details

To get the details of a specific subscriber from a list call the getSubscriberDetails function and pass through the MailChimp list id and the user's email., (*10)

$simpleMailChimp->getSubscriberDetails('LIST_ID_GOES_HERE', 'example@example.com');

If successful it will return an array containing the subscriber's data., (*11)

Checking to see if a subscriber is already on a list and subscribed

To see if a subscriber is already on a list and is subscribed call the isSubscribedToList function and pass through the MailChimp list id and the user's email., (*12)

$simpleMailChimp->isSubscribedToList('LIST_ID_GOES_HERE', 'example@example.com');

This function will return TRUE if the subscriber is found on the list AND is subscribed to it and return FALSE if either the user is not found on the list OR is in the list but set to unsubscribed., (*13)

Getting all the members of a list

To get all the members of a list call the getAllUsersInList function and pass through the MailChimp list id and a comma separated list of the specific fields you want to return. If no parameters are set it retrieves the member's email by default., (*14)

$simpleMailChimp->getAllUsersInList('LIST_ID_GOES_HERE');

Will return an array of emails belonging to members of the list specified., (*15)

$simpleMailChimp->getAllUsersInList('LIST_ID_GOES_HERE','email_address,status');

Will return an array of emails and the relevant statuses belonging to members of the list specified. Available parameters can be found on the MailChimp API documentation page (under 'Response body parameters' -> 'members' -> 'Show properties'): http://developer.mailchimp.com/documentation/mailchimp/reference/lists/members/#read-get_lists_list_id_members., (*16)

Note that this function returns all members of a list regardless of whether they are subscribed or not., (*17)

The Versions

23/03 2018

dev-master

9999999-dev

A simple MailChimp API wrapper, SimpleMailChimp makes it easy to pass data back and forth between your website and your MailChimp account. This includes subscribing or unsubscribing users, getting a subscriber’s details and getting all the members of a particular list.

  Sources   Download

LGPL3 LGPL-3.0-only

The Requires

 

library mailchimp php library mailchimp library php mailchimp library

30/01 2018

v1.0.8

1.0.8.0

A simple MailChimp API wrapper, SimpleMailChimp makes it easy to pass data back and forth between your website and your MailChimp account. This includes subscribing or unsubscribing users, getting a subscriber’s details and getting all the members of a particular list.

  Sources   Download

LGPL-3.0-only

The Requires

 

library mailchimp php library mailchimp library php mailchimp library

22/02 2017

v1.0.7

1.0.7.0

SimpleMailChimp is an v3 API wrapper that aims to simplify integration of basic MailChimp functionality.

  Sources   Download

LGPL3

The Requires

 

library mailchimp php library mailchimp library php mailchimp library

14/12 2016

v1.0.6

1.0.6.0

SimpleMailChimp is an v3 API wrapper that aims to simplify integration of basic MailChimp functionality.

  Sources   Download

LGPL3

The Requires

 

library mailchimp php library mailchimp library php mailchimp library

03/11 2016

v1.0.5

1.0.5.0

SimpleMailChimp is an v3 API wrapper that aims to simplify integration of basic MailChimp functionality.

  Sources   Download

LGPL3

The Requires

 

library mailchimp php library mailchimp library php mailchimp library

03/11 2016

v1.0.4

1.0.4.0

SimpleMailChimp is an v3 API wrapper that aims to simplify integration of basic MailChimp functionality.

  Sources   Download

LGPL3

The Requires

 

library mailchimp php library mailchimp library php mailchimp library

03/11 2016

v1.0.3

1.0.3.0

SimpleMailChimp is an v3 API wrapper that aims to simplify integration of basic MailChimp functionality.

  Sources   Download

LGPL3

The Requires

 

library mailchimp php library mailchimp library php mailchimp library

02/11 2016

v1.0.2

1.0.2.0

SimpleMailChimp is an v3 API wrapper that aims to simplify integration of basic MailChimp functionality.

  Sources   Download

LGPL3

The Requires

 

library mailchimp php library mailchimp library php mailchimp library

02/11 2016

v1.0.1

1.0.1.0

SimpleMailChimp is an v3 API wrapper that aims to simplify integration of basic MailChimp functionality.

  Sources   Download

LGPL3

The Requires

 

library mailchimp php library mailchimp library php mailchimp library

02/11 2016

v1.0

1.0.0.0

SimpleMailChimp is an v3 API wrapper that aims to simplify integration of basic MailChimp functionality.

  Sources   Download

LGPL3

The Requires

 

library mailchimp php library mailchimp library php mailchimp library