You are here

function MCAPI::listMembers in Mailchimp 6

Same name and namespace in other branches
  1. 5.2 MCAPI.class.php \MCAPI::listMembers()
  2. 5 MCAPI.class.php \MCAPI::listMembers()
  3. 6.2 MCAPI.class.php \MCAPI::listMembers()
  4. 7 MCAPI.class.php \MCAPI::listMembers()

Get all of the list members for a list that are of a particular status

Related

@example mcapi_listMembers.php

@returnf string email Member email address @returnf date timestamp timestamp of their associated status(date subscribed, unsubscribed, or cleaned)

Parameters

string $id the list id to connect to:

string $status the status to get members for - one of(subscribed, unsubscribed, or cleaned), defaults to subscribed:

integer $start optional for large data sets, the page number to start at - defaults to 1st page of data (page 0):

integer $limit optional for large data sets, the number of results to return - defaults to 100, upper limit set at 15000:

Return value

array Array of list member structs (see Returned Fields for details)

File

./MCAPI.class.php, line 856

Class

MCAPI

Code

function listMembers($id, $status = 'subscribed', $start = 0, $limit = 100) {
  $params = array();
  $params["id"] = $id;
  $params["status"] = $status;
  $params["start"] = $start;
  $params["limit"] = $limit;
  return $this
    ->callServer("listMembers", $params);
}