SetCustomerCommunicationPreferences

 

SetCustomerCommunicationPreferences

Initial Build xxxx.x
xWeb Web Method
Response Type return type

This method lets you set communication preferences for a specified customer.

Parameters

The request contains the following parameters:

Name Type Occurs Description
customerKey string (guid) 1..0 The customer key.
Preferences MailingListSetting 1..0 This is an array of as many MailingListSettings as you need to process. This is required. You can pass one MailingListSetting or multiple if you need to update more than one.

 

Response

This method returns a void response.

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>33d08c11-09ec-455d-a9f6-d308f8f2592d</ns:Token>

</ns:AuthorizationToken>

</soapenv:Header>

<soapenv:Body>

<ns:SetCustomerCommunicationPreferences>

<!--Optional:-->

<ns:customerKey>?</ns:customerKey>

<!--Optional:-->

<ns:preferences>

<!--Zero or more repetitions:-->

<ns:MailingListSetting>

<!--Optional:-->

<ns:mailing_list_key>?</ns:mailing_list_key>

<!--Optional:-->

<ns:mailing_list_name>?</ns:mailing_list_name>

<!--Optional:-->

<ns:mailing_list_category>?</ns:mailing_list_category>

<ns:status>?</ns:status>

<!--Optional:-->

<ns:email_key>?</ns:email_key>

<!--Optional:-->

<ns:address_key>?</ns:address_key>

<!--Optional:-->

<ns:phone_key>?</ns:phone_key>

<!--Optional:-->

<ns:fax_key>?</ns:fax_key>

</ns:MailingListSetting>

</ns:preferences>

</ns:SetCustomerCommunicationPreferences>

</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>

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

</soap:Body>

</soap:Envelope>

 

JSON Method

POST /xWeb/JSON/SetCustomerCommunicationPreferences

DATA: JSON{
    "SetCustomerCommunicationPreferences": {
        "customerKey": "FADFF57B-C6EF-4130-BE1E-07000A38056F",
        "preferences": [
            {
                "mailing_list_key": "b31c52e4-29c1-4a65-8c53-0626342c920d",
                "mailing_list_name": "Instructors - Online",
                "mailing_list_category": "Instructors",
                "status": "OptIn",
                "email_key": "abc320db-863f-441a-8ab4-5fc827fc33c2",
                "address_key": "0f37de1d-a608-4ebc-bad1-7beaa3102f60",
                "phone_key": "f46291d8-6b16-467f-97ef-fb16028a2b98",
                "fax_key": "bac08813-3231-4c42-942e-2e0d98608043"
            },
            {
                "mailing_list_key": "6cc179ee-99c3-4b6b-8bab-36574550a5e5",
                "mailing_list_name": "Accreditation",
                "mailing_list_category": "Email Opt-In",
                "status": "OptOut",
                "email_key": null,
                "address_key": null,
                "phone_key": null,
                "fax_key": null
            }
        ]
    }
}

 

SAMPLE RESULT
HTTP STATUS: 200
No data

 

 

Was this article helpful?
0 out of 0 found this helpful