getUserList($session_id, $domain)
getUserList should be called when a user needs a list of e-mail accounts and attributes for a given domain. It can be retrieved via a soap request using the "getUserList" method to https://api.max.md/getUserList.php?wsdl.
Response
The response comes in a soap object containing five elements.
(string) code - A response code. This will be "000" if there is no error
(string) message - A description of the reponse code
(string) usage - A string containing the amount of bytes being used by all users in the domain
(string) quota - A string containing the total amount of bytes alloted in the domain
(string) is_audit - A number of 0, 1 or 2 indicating the audit status for this domain
0 - Audit is off
1 - Domain Audit is on
2 - User Audit is on
(array) userlist - An array of usernames in the domain
Sample Code (using NuSoap)
$soap = new soapclient("https://api.max.md/getUserList.php?wsdl",array( 'trace' => true, 'exceptions' => true, ));
$response= $soap->getUserList($session_id, $domain);
if ($response->code == '000') {
$user_array = $response->userlist;
$quota = $response->quota;
}else{
echo $response->message;
}
The xml for the WSDL can be found here