API Reference – Marketing API – Removing Contacts from Lists

Marketing API Method Documentation

©2009-2014 SocketLabs, Inc., Version 0.1, Last Edit: March 25, 2014

DELETE /lists/{listId}/contacts/{contactId}

Synopsis:

Removes a contact from a list (but leaves it on other lists).

Recommended Usage:

Use this method to take a contact off a list (but preserve it in your server’s collection of contacts with all its associated information).

This method takes two forms. The first accepts the contact integer ID (passed in the URL) and the second accepts an email address passed via the query string (NOTE: proper URL encoding must be used, e.g. somebody%40customerexample.com)

In either version, if the contact is not found on the list a 404 Not Found response will be issued.

Request Information

HTTP Method:

DELETE

URL:

https://api.socketlabs.com/marketing/v1/lists/{listId}/contacts/{contactId}

Response Format Types:

JSON or XML

Request Parameters:

For the first form of the method call, the list and contact ID values should be specified in the URL.

For the second form, the email address should be specified in the query string.

Example Request:

By integer ID:

DELETE /marketing/beta/lists/123/contacts/456 HTTP/1.1
Host: api.socketlabs.com
Authorization: Basic XXXXXXXXXXXXXXXXXXXx==
Cache-Control: no-cache

By email address in query string:

DELETE /marketing/beta/lists/123/contacts/?emailAddress=somebody%40customerexample.com HTTP/1.1
Host: api.socketlabs.com
Authorization: Basic XXXXXXXXXXXXXXXXXXXx==
Cache-Control: no-cache

Response Parameters

None.

Customers Who Trust in SocketLabs

You’re in good company when working with SocketLabs. Here are some companies who have also trusted SocketLabs.

Why SocketLabs?

What Our Customers Are Saying!