CallFire Solutions

Query Labels

Follow

QUERY LABELS

Returns all defined labels

This operation returns a list of all defined label names. The labels may be associated with broadcasts or numbers.

REQUEST PARAMETERS

ParameterDemo ValueDescriptionData Type
QueryLabels     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
LabelQueryResult    
TotalResults Results count long
Label    
Name   string

EXAMPLE


using RestSharp;

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

            var request = new RestRequest("label", Method.GET);
            request.AddParameter("MaxResults", "3");
            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="5">

    <Label>

       <Name>BroadcastLabel-1</Name>

    </Label>

    <Label>

       <Name>BroadcastLabel-2</Name>

    </Label>

    <Label>

       <Name>New BroadcastLabel-3</Name>

    </Label>

</r:ResourceList>

Have more questions? Submit a request

Comments