Delete a Subscriber Profile Attribute

This page contains information about deleting a subscriber profile attribute using the SOAP API.

Why Delete a Subscriber Profile Attribute 

You can remove subscriber profile attributes with this call when you no longer want to use or retain this information.

How to Delete a Subscriber Profile Attribute 

Use the sample code below as a model to create your own API call. Use the SOAP request to validate that you’ve included all applicable information.

Sample Java Code (Axis 1.4) 

1public void testDeleteAttributeForSubscriber() throws RemoteException {
2        Soap_PortType stub = init();
3        ConfigureRequestMsg configureRequestMsg = new ConfigureRequestMsg();
4        PropertyDefinition definition = new PropertyDefinition();
5        //create special Attribute under profile management, this attribute holds html content
6        definition.setName("SamplePropertyDefinition");
7        definition.setPropertyType(PropertyType.value1);
8        //Set ClientID to create attribute on sub-account
9        ConfigureOptions options = new ConfigureOptions();
10        ClientID clientID = new ClientID();
11        clientID.setID(232538);
12        options.setClient(clientID);  //this creates attribute in sub-account
13        //definition.setClient(clientID); //this creates attribute in parent-account
14        configureRequestMsg.setOptions(options);
15        configureRequestMsg.setAction("delete");
16        APIObject[] objects = {definition};
17        configureRequestMsg.setConfigurations(objects);
18        //API call to delete to Attribute....
19        ConfigureResponseMsg responseMsg = stub.configure(configureRequestMsg);
20        assertNotNull(responseMsg.getOverallStatusMessage());
21    }

SOAP Request 

1<s:Body xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
2     <ConfigureRequestMsg xmlns="http://exacttarget.com/wsdl/partnerAPI">
3          <Action>delete</Action>
4          <Options>
5              <Client>
6                  <ID>232538</ID>
7                  <!--SubAccount-->
8              </Client>
9          </Options>
10          <Configurations>
11              <Configuration xsi:type="PropertyDefinition">
12                  <Name>Subject_Revoooo</Name>
13              </Configuration>
14          </Configurations>
15    </ConfigureRequestMsg>
16</s:Body>