Search for customers.


This method allows you to search the customer database using flexible search terms. This method searches the customer database (aka recurring billing) not the transactions history. To search the transaction history for a specific customer, use either the searchTransactions or getCustomerHistory method.

Use as many or as few search terms as you like. With MatchAll set to “true,” all terms must match to return a result. If the search does not yield the desired results, try broadening your search by eliminating terms, or change MatchAll to “false.”

Valid field names for search are:

  • custid - Customer Reference Number
  • customerid - Customer ID
  • fname - First Name
  • lname - Last Name
  • company - Company
  • address - Address
  • address2 - Address 2
  • city - City
  • state - State
  • zip - Zip
  • country - Country
  • phone - Phone
  • fax - Fax
  • email - Email
  • url - URL
  • notes - Notes
  • schedule - Schedule (1=Daily,2=Weekly,3=Bi-Weekly,4=Monthly,5=Bi-Monthly,6=Quarterly,7=Bi-Annually,8=Annually,9=First of Month, 10=Last Day of Month)
  • numleft - Number of Transactions Left
  • start - Start
  • next - Next
  • expiration - Expiration
  • amount - Amount
  • sendreceipt - Send Receipt
  • source - Source
  • receiptnote - Receipt Note
  • paytype - Payment Type
  • orderid - Order ID
  • description - Description
  • enabled - Enabled (1=enabled,0=disabled)

See also runCustomerTransaction, enableCustomer, disableCustomer, deleteCustomer, searchcustomerscustom, searchCustomerID, getCustomer, getCustomerHistory, addCustomer, addCustomerPaymentMethod, deleteCustomerPaymentMethod, updateCustomer, quickUpdateCustomer


CustomerSearchResult searchCustomers ( ueSecurityToken Token, SearchParam Search, boolean MatchAll, integer Start, integer Limit )


Type Name Description
ueSecurityToken Token Merchant security token: used to identify merchant and validate transaction.
SearchParam Search Array of search parameters.
boolean MatchAll If set to “true,” only results matching all search criteria will be returned, if set to “false,” results matching any of the search criteria will be returned.
integer Start Start position, defaults to 0 (first customer found).
integer Limit Maximum number of customers to return in result.

Return Value

CustomerSearchResult Returns results of customer search based on parameters set.



For directions on how to set up the WSDL link, create “$token” and “$client”, go to PHP Soap How-to.

try { 
  $this->assertTrue($res->CustomersMatched>0 && $res->CustomersReturned>0); 
catch (SoapFault $e) { 
  die("Search Customers failed :" .$e->getMessage()); 


Dim matchAll As Boolean
        matchAll = True
        Dim search(0) As usaepay.SearchParam
        search(0) = New usaepay.SearchParam()
        search(0).Field = "Amount"
        search(0).Type = "equals"
        search(0).Value = "10.00"
        Dim response As usaepay.CustomerSearchResult = New usaepay.CustomerSearchResult
        response = client.searchCustomers(token, search, matchAll, "0", "10")


Boolean matchAll;
            matchAll = true;
            string[] fields = new string[3];
            usaepay.SearchParam[] search = new usaepay.SearchParam[2];
            search[0] = new usaepay.SearchParam();
            search[0].Field = "amount";
            search[0].Type = "gt";
            search[0].Value = "10.00";
            usaepay.CustomerSearchResult response = new usaepay.CustomerSearchResult();
                response = client.searchCustomers(token, search, matchAll, "0", "10");
            catch (Exception err)
developer/soap-1.1/methods/searchcustomers.txt · Last modified: 2010/10/21 15:37 by irina

Page Tools