GetActiveCustomerList - accountsIQ/API-Wiki GitHub Wiki
The GetActiveCustomerList
function retrieves a list of arrays containing the active customers from an entity.
public WSResult2OfArrayOfCustomer GetActiveCustomerList(string token)
Public Function GetActiveCustomerList(ByVal token As String) As WSResult2OfArrayOfCustomer
Parameter | Type | Description |
---|---|---|
token | String | The session token retrieved during authentication. |
Integration_1_1 ws = new Integration_1_1();
String auth = ws.Login(entityID, partnerKey, userKey);
if (auth != null)
{
// Get the list of active customers
accountsIQ.WSResult2OfArrayOfCustomer cuslist = ws.GetActiveCustomerList(auth);
Assert.IsNotNull(cuslist.Result);
if (cuslist.Status == OperationStatus.Success)
{
foreach (Customer c in cuslist.Result)
{
// Do something with each customer
}
}
else
{
// Use the ErrorCode field to pinpoint the problem
}
}
Dim ws As New Integration_1_1
Dim auth As String = ws.Login(entityID, partnerKey, userKey)
If (Not auth Is Nothing) Then
' Get the list of active customers
Dim cuslist As WSResult2OfArrayOfCustomer = ws.GetActiveCustomerList(auth)
Assert.IsNotNull(cuslist.Result)
If (cuslist.Status = OperationStatus.Success) Then
Dim c As Customer
For Each c In cuslist.Result
' Do something with each customer
Next
End If
Else Then
'Use the ErrorCode field to pinpoint the problem
End If
End If
##See Also