Group the contacts you send deliveries to. A static list contains the members you add to it, and a dynamic list gets its members from a condition on contact properties. Lists can also be linked to IDs in external systems.
Get mailing lists
Returns all mailing lists of the account, sorted by name, with member counts and list health. Hidden lists and lists created automatically for single deliveries are not included, and dynamic lists are left out if dynamic lists are not enabled for the account. The import_* fields describe the latest import of the list, and import_status is set only while that import is waiting or running.
Get mailing lists › Request Body
include_deletedSet to 1 to include deleted mailing lists. Defaults to 0.
Get mailing lists › Responses
OK
succeedResponse status.
Array of mailing lists.
Get mailing list
Returns the settings and member count of one mailing list. Deleted lists are also returned: check deleted. To get several lists at once, use getMailingLists.
Get mailing list › Request Body
list_idMailing list ID.
smsReturn the number of members with an SMS number as members, instead of all members. Defaults to false.
Get mailing list › Responses
OK
succeedResponse status.
Mailing list info.
Create mailing list
Creates a regular, dynamic or segment list and returns its ID. A list with a condition is dynamic, and a list with a cem_segment is a segment list; neither can be self-service. Dynamic lists must be enabled for the account. Members of a new dynamic list are not added until you call requestTargetgroup.
Create mailing list › Request Body
nameMailing list name.
descShort description of the mailing list.
subsWhether the list is available for subscription on subscription sites. Cannot be true for dynamic or segment lists.
conditionDynamic list condition as a JSON string. Must be null for regular and segment lists.
Each condition has a contact property name, a value and a condition: = (equal), <> (not equal), ilike (contains), ilike-not (does not contain), in (in list), begins, begins-not, ends or ends-not.
cem_segmentLianaAutomation segment ID of a segment list, or -1 if the segment is not determined yet.
Must be null for regular and dynamic lists.
ext_idExternal ID of the mailing list.
ext_typeType of the external ID.
Create mailing list › Responses
OK
succeedResponse status.
resultMailing list ID.
Edit mailing list
Replaces all list settings: omitted optional parameters are reset, so self-service is turned off and the condition, site and segment are cleared. If new_name is empty, the list is not changed. To change only one setting, use editMailingListCondition or editMailingListSelfService.
Edit mailing list › Request Body
idMailing list ID.
new_nameMailing list name.
new_descShort description of the mailing list.
new_subsWhether the list is available for subscription on subscription sites. Cannot be true for dynamic or segment lists.
new_conditionDynamic list condition as a JSON string. Must be null for regular and segment lists.
Each condition has a contact property name, a value and a condition: = (equal), <> (not equal), ilike (contains), ilike-not (does not contain), in (in list), begins, begins-not, ends or ends-not.
cem_segmentLianaAutomation segment ID of a segment list, or -1 if the segment is not determined yet.
Must be null for regular and dynamic lists.
Edit mailing list › Responses
OK
succeedResponse status.
The list ID, or false if new_name is empty and the list was not changed.
Delete mailing list
Marks the list as deleted. A deleted list is no longer returned by getMailingLists unless include_deleted is set, and there is no endpoint to restore it. Memberships of deleted lists are removed permanently after 6 months.
Delete mailing list › Request Body
list_idMailing list ID.
Delete mailing list › Responses
OK
succeedResponse status.
resultReturns null.
Hide mailing list
Hides the list from getMailingLists, for example after an ad hoc delivery. The list and its members are kept and the list can still be fetched by ID. There is no endpoint to show a hidden list again.
Hide mailing list › Request Body
list_idMailing list ID.
Hide mailing list › Responses
OK
succeedResponse status.
resultReturns null.
Empty mailing list
Removes all active members from the list. Members who have unsubscribed from the list are kept, so truncating the list and adding them back does not subscribe them again. This protects unsubscribed contacts from being imported back to the list by accident, for example from external systems.
Empty mailing list › Request Body
list_idMailing list ID.
Empty mailing list › Responses
OK
succeedResponse status.
resultReturns null.
Set mailing list self-service
Turns self-service on or off for a regular list. Dynamic and segment lists cannot be self-service. If the account does not allow multiple self-service lists, self-service is turned off on all other lists. Returns the self-service state of every list of the account that is not deleted.
Set mailing list self-service › Responses
OK
succeedResponse status.
resultList IDs with their self-service states.
Get mailing list condition
Returns the condition of a dynamic list as a JSON string, or an empty value if the list has no condition.
Get mailing list condition › Request Body
list_idMailing list ID.
Get mailing list condition › Responses
OK
succeedResponse status.
resultDynamic list condition as a JSON string. Must be null for regular and segment lists.
Each condition has a contact property name, a value and a condition: = (equal), <> (not equal), ilike (contains), ilike-not (does not contain), in (in list), begins, begins-not, ends or ends-not.
Edit mailing list condition
Sets the condition of a dynamic list and returns the saved condition. Other list settings are not changed. Send an empty condition to remove it; setting a condition requires dynamic lists to be enabled for the account. The list members are not updated until you call requestTargetgroup.
Edit mailing list condition › Request Body
list_idMailing list ID.
conditionDynamic list condition as a JSON string. Must be null for regular and segment lists.
Each condition has a contact property name, a value and a condition: = (equal), <> (not equal), ilike (contains), ilike-not (does not contain), in (in list), begins, begins-not, ends or ends-not.
Edit mailing list condition › Responses
OK
succeedResponse status.
resultDynamic list condition as a JSON string. Must be null for regular and segment lists.
Each condition has a contact property name, a value and a condition: = (equal), <> (not equal), ilike (contains), ilike-not (does not contain), in (in list), begins, begins-not, ends or ends-not.
Update dynamic list members
Starts a background job that updates the members of a dynamic list from its condition and returns the job handle. The job replaces all current list members with the contacts who match the condition. Call this after creating a dynamic list or changing its condition. Nothing is changed if the condition is not enabled.
Update dynamic list members › Request Body
listMailing list ID.
Update dynamic list members › Responses
OK
succeedResponse status.
resultJob handle.
Recalculate mailing list health
Recalculates the health of one or more lists and returns the new values, with the list ID as the key and the health as the value. Health is from 0 to 100, where 100 is best, and is based mainly on greylisted addresses and bounces. Health is also recalculated after list imports and daily for lists with recent deliveries or greylisted addresses.
Recalculate mailing list health › Request Body
Mailing list ID or an array of mailing list IDs.
Recalculate mailing list health › Responses
OK
succeedResponse status.
Updated list health.
Find list by external ID
Returns the ID of the list that has the given external ID and type, or false if no list has it. External IDs are added with addMailingListExternalId or when creating the list. If several lists have the same external ID, only one of them is returned. Deleted lists are included, as deleting a list keeps its external IDs.
Find list by external ID › Request Body
ext_idExternal ID of the mailing list.
typeType of the external ID.
Find list by external ID › Responses
OK
succeedResponse status.
resultMailing list ID.
Get mailing list external ID
Returns the external ID of the given type for the list, or false if the list has none. If the list has several external IDs of the type, only one of them is returned.
Get mailing list external ID › Request Body
list_idMailing list ID.
typeType of the external ID.
Get mailing list external ID › Responses
OK
succeedResponse status.
resultExternal ID of the mailing list.
Add external ID to mailing list
Links an external ID, for example the ID of the list in another system, to the list. Use findListExternal to find the list by it later. Adding the same ID and type again does nothing, and a list can have several external IDs.
Add external ID to mailing list › Request Body
list_idMailing list ID.
ext_idExternal ID of the mailing list.
typeType of the external ID.
Add external ID to mailing list › Responses
OK
succeedResponse status.
resultReturns null.
Delete mailing list external ID
Removes all external IDs of the given type from the list. The list itself is not changed.
Delete mailing list external ID › Request Body
list_idMailing list ID.
typeType of the external ID.
Delete mailing list external ID › Responses
OK
succeedResponse status.
resultReturns null.