CallFire Solutions

Query Contact Lists

Follow

QUERY CONTACT LISTS

Lists existing contact lists

This operation queries for existing contact lists. Currently, it does not allow filtering and therefore it returns all contact lists.

REQUEST PARAMETERS

ParameterDemo ValueDescriptionData Type
QueryContactLists   ContactLists request by query object
MaxResults Max number of results to return limited to 1000 (default: 1000) long
FirstResult Start of next result set (default: 0) long

RESPONSE PARAMETERS

ParameterDescriptionData Type
ContactListQueryResult List of ContactLists returned from query  
TotalResults Results count long
ContactList List of Contacts  
Id   long
Name   string
Size   integer
Created   dateTime
Status [ACTIVE, VALIDATING, IMPORTING, IMPORT_FAILED, ERRORS, DELETED, PARSE_FAILED, COLUMN_TOO_LARGE] ContactListStatus

EXAMPLE


using RestSharp;

namespace [your-namespace]
{
    public class [your-class]
    {
        public string QueryContactList()
        {
            var client = new RestClient("https://www.callfire.com/api/1.1/rest/");
            client.Authenticator = new HttpBasicAuthenticator("YourLoginId", "password");

            var request = new RestRequest("contact/list", Method.GET);
            request.AddParameter("MaxResults", "5");
            request.AddParameter("FirstResult", "1");

            var response = client.Execute(request);
            string content = response.Content;
            return content;
        }
    }
}

The XML returned is:

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>

<r:ResourceList xmlns="http://api.callfire.com/data" xmlns:r="http://api.callfire.com/resource" totalResults="-1">

   <ContactList id="188611001">

     <Name>NewContactListTest2</Name>

     <Size>1</Size>

     <Created>2014-06-05T18:18:01Z</Created>

     <Status>ACTIVE</Status>

   </ContactList>

</r:ResourceList>

Have more questions? Submit a request

Comments