public function members($status = 'subscribed', $opts = null) {

        $payload = array(
            'id' => $this->listId,
            'status' => $status
        );

        if (!is_null($opts)) {
            $payload['opts'] = $opts;
        }

        $apiCall = 'lists/members';
        $data = $this->requestMonkey($apiCall, $payload);
        $data = json_decode($data, true);
        if (isset($data['error']))
            throw new MailchimpAPIException($data);
        else
            return isset($data) ? $data : false;

    }
public function members($status = 'subscribed', $opts = null) {

        $payload = array(
            'id' => $this->listId,
            'status' => $status
        );

        if (!is_null($opts)) {
            $payload['opts'] = $opts;
        }

        $apiCall = 'lists/members';
        $data = $this->requestMonkey($apiCall, $payload);
        $data = json_decode($data, true);
        if (isset($data['error']))
            throw new MailchimpAPIException($data);
        else
            return isset($data) ? $data : false;

    }
public function members ( $ status = 'subscribed' , $ opts = null ) { $ payload = array ( 'id' => $ this -> listId , 'status' => $ status ) ; if ( ! is_null ( $ opts ) ) { $ payload [ 'opts' ] = $ opts ; } $ apiCall = 'lists/members' ; $ data = $ this -> requestMonkey ( $ apiCall , $ payload ) ; $ data = json_decode ( $ data , true ) ; if ( isset ( $ data [ 'error' ] ) ) throw new MailchimpAPIException ( $ data ) ; else return isset ( $ data ) ? $ data : false ; }
Get a list of members for a list

@link http://apidocs.mailchimp.com/api/2.0/lists/members.php
@param string $status optional 'subscribed', 'unsubscribed', 'cleaned'
@param array $opts optional
@return array
@throws InvalidArgumentException
Get a list of members for a list