GetAudienceList

Initial Build

2014.01

xWEB

Web Method

Response Type

XML results

Use this method to obtain a list of Audience records, including the query header key and the description. See also, GetAudienceDefinition and GetAudienceList.

Parameters

This request requires no parameters.

Response

The request returns a list of all audience records in the system. Each record is delineated by a the Result element and a count of the included records is displayed at the top of the results.

Name Description Type Notes
Results Container for the list of results XML element Includes the record return field that indicates the total number of audience records returned from the system.
Result

Container for a single audience record

XML  
qrh_key Query header key. A unique key that represents the audience query. key  
qrh_description The audience query description. string

This field appears in the Load an Existing Audience list on the Audience page.

Sample Request

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ns="http://www.avectra.com/2005/">

<soapenv:Header>

<ns:AuthorizationToken>

<!--Optional:-->

<ns:Token>?</ns:Token>

</ns:AuthorizationToken>

</soapenv:Header>

<soapenv:Body>

<ns:GetAudienceDefinition>

<!--Optional:-->

<ns:qrh_key>fe63106d-a70f-4f0c-a380-8e3eaa908888</ns:qrh_key>

</ns:GetAudienceDefinition>

</soapenv:Body>

</soapenv:Envelope>

Sample Response

<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">

<soap:Header>

<AuthorizationToken xmlns="http://www.avectra.com/2005/">

<Token>?</Token>

</AuthorizationToken>

</soap:Header>

<soap:Body>

<GetAudienceDefinitionResponse xmlns="http://www.avectra.com/2005/">

<GetAudienceDefinitionResult>

<qrh_key>fe63106d-a70f-4f0c-a380-8e3eaa908888</qrh_key>

<qrh_description>Sample Audience Definition</qrh_description>

<Parameters>

<QueryParameter>

<Name>7e351c63-c179-431e-8fb2-d1d796e15ecb_a</Name>

<Description>[Individual::Last Name] Begins With [Enter Value] (Ask At Run-Time)</Description>

<Operator>Equals</Operator>

<ColumnName>ind_last_name</ColumnName>

<ColumnDescription>Last Name</ColumnDescription>

<ControlClass>TextBox</ControlClass>

<DataType>nvarchar</DataType>

<IsExtended>false</IsExtended>

<IsNullable>false</IsNullable>

<TableAlias/>

<TableDescription>Individual</TableDescription>

<TableName>co_individual</TableName>

<ListOptions/>

</QueryParameter>

</Parameters>

<Columns>

<QueryColumn>

<Name>ind_last_name</Name>

<Description>Last Name</Description>

<DataType>nvarchar</DataType>

<TableAlias/>

<TableDescription>Individual</TableDescription>

<TableName>co_individual</TableName>

</QueryColumn>

<QueryColumn>

<Name>ind_first_name</Name>

<Description>First Name</Description>

<DataType>nvarchar</DataType>

<TableAlias/>

<TableDescription>Individual</TableDescription>

<TableName>co_individual</TableName>

</QueryColumn>

<QueryColumn>

<Name>ind_mid_name</Name>

<Description>Middle Name</Description>

<DataType>nvarchar</DataType>

<TableAlias/>

<TableDescription>Individual</TableDescription>

<TableName>co_individual</TableName>

</QueryColumn>

<QueryColumn>

<Name>cst_org_name_dn</Name>

<Description>Organization Name</Description>

<DataType>nvarchar</DataType>

<TableAlias/>

<TableDescription>Customer</TableDescription>

<TableName>co_customer</TableName>

</QueryColumn>

<QueryColumn>

<Name>cst_eml_address_dn</Name>

<Description>Primary E-Mail</Description>

<DataType>av_email</DataType>

<TableAlias/>

<TableDescription>Customer</TableDescription>

<TableName>co_customer</TableName>

</QueryColumn>

<QueryColumn>

<Name>adr_line1</Name>

<Description>Address Line 1</Description>

<DataType>nvarchar</DataType>

<TableAlias/>

<TableDescription>Address</TableDescription>

<TableName>co_address</TableName>

</QueryColumn>

<QueryColumn>

<Name>adr_city_state_code</Name>

<Description>City, State, Post Code</Description>

<DataType>nvarchar</DataType>

<TableAlias/>

<TableDescription>Address</TableDescription>

<TableName>co_address</TableName>

</QueryColumn>

<QueryColumn>

<Name>cst_no_email_flag</Name>

<Description>Do Not Contact by Email</Description>

<DataType>av_flag</DataType>

<TableAlias/>

<TableDescription>Customer</TableDescription>

<TableName>co_customer</TableName>

</QueryColumn>

</Columns>

</GetAudienceDefinitionResult>

</GetAudienceDefinitionResponse>

</soap:Body>

</soap:Envelope>

   

JSON Method

POST /xWeb/JSON/GetAudienceList

Copy
DATA: JSON
{
    "GetAudienceList" : null
}

 

Copy
SAMPLE RESULT
HTTP STATUS: 200
DATA: JSON
{
    "Results": {
        "@recordReturn": "13",
        "Result": [
            {
                "qrh_key": null,
                "qrh_description": null
            },
            {
                "qrh_key": "7bb59cc2-f436-4afa-9656-1eb66398946f",
                "qrh_description": "132657 Test"
            },
            {
                "qrh_key": "5422fc70-8c85-4dec-9235-ac96913de7bf",
                "qrh_description": "Floyd''''''''''''''''s Audience"
            },
            {
                "qrh_key": "4cffcd8e-06a4-4bcf-a670-512d3f577920",
                "qrh_description": "Floyd''''''''''''''''''''''''''''''''s Audience"
            },
            {
                "qrh_key": "ac8b56bb-9ce4-42bd-bbc8-91187aadbe15",
                "qrh_description": "jls_test1O"
            },
            {
                "qrh_key": "814ece46-cc6d-48ee-8a7f-002f0e95498f",
                "qrh_description": "jls_testD2OExclude"
            },
            {
                "qrh_key": "97d174ab-1dde-4591-b603-bc33b2ccd53b",
                "qrh_description": "jls_testD2OKeep"
            },
            {
                "qrh_key": "1441f933-0326-401f-b15b-373e8c03e3f7",
                "qrh_description": "jls_testD3OAddKeep"
            },
            {
                "qrh_key": "a9442795-7193-4feb-8477-9ecddcd9ff4b",
                "qrh_description": "jls_testSO2Add"
            },
            {
                "qrh_key": "8307daa8-7670-4f6e-a014-8f25d241aa30",
                "qrh_description": "jls_testSO2Exclude"
            },
            {
                "qrh_key": "c862c9a3-0d2c-43d1-aca4-8b7d9b5f5bc7",
                "qrh_description": "MayankQ3"
            },
            {
                "qrh_key": "dd3c9bd9-0a94-486d-9912-f4e4e99469f2",
                "qrh_description": "Random"
            },
            {
                "qrh_key": "8fdad6ea-572b-4f60-8731-312d8055f36a",
                "qrh_description": "Test_1"
            }
        ]
    }
}