Get contact list

				
					StructContactList[] contactList(string idSession, array filters)
			

Return contacts linked to the reseller account.

REQUIRED

  • idSession string (32)
    Session ID

 

OPTIONAL

  • filters array
    Search filters
  •  

    Available filter keys:

    • idContact (Contact ID)
    • firstName (Contact first name)
    • lastName (Contact last name)
    • bodyForm (Contact legal form)
    • bodyName (Organisation name)
    • isOwner (Is contact an owner?)

    For more information on filters for list functions, please consult the corresponding page.

An Array of StructContactList

$clientSOAP = new SoapClient('https://URL.wsdl');

$filters = array(
    'idContact' => ['NOT IN' => ['XX000', 'XX001']],
    'bodyForm' => ['=' => 'ORG'],
    'isOwner' => ['=' => 0]
);

try {
    $idSession = $clientSOAP->sessionOpen('XX000', 'xxxxxxxx');
    $arrayContactList = $clientSOAP->contactList($idSession, $filters);
    print_r($arrayContactList);

} catch (SoapFault $fault) {
    echo 'Exception : ' . $fault->getMessage() . "\n";
}

if (isset($idSession)) {
    $clientSOAP->sessionClose($idSession);
}