Create a List

Use this endpoint to create and save a new list in Engage.

Endpoint and Methods

POST /_rest/v2/lists

Body

Required field:

  • listName

Optional field:

  • listDescription

Note: Any other fields in the body are ignored.

Sample Request

Copy
{
"listName": "Bob's List"
}

Sample Response

Code 201 Response

Response code 200 returns a list object upon successfully creating a list.

Copy
{
"listName": "Bob's List",
"listId": "51i8c0edotame81bb4cbf000",
"description": "List of Bob's contacts",
"customerId": 9999999,
"modifiedDate": "2019-06-18T00:14:03Z",
"modifiedBy": "sspeirs",
"createdDate": "2019-06-18T00:14:03Z",
"createdBy": "sspeirs",
"deleteFlag": "false",
"campaignRel": [
"4kk11065jkl0985bb48mf054"
],
"contactRel": [
"4kk11065jkl0985bb48mf054"
]
}

Code 401 Response

Response code 401 returns an error that the authorization token is invalid.

Copy
{
"message": "string",
"status": 401
}

Code 422 Response

Response code 422 returns a message that the listName parameter is required.

Copy
{
"message": "The 'listName' parameter is required",
"status": 422
}

Code 500 Response

Response code 500 returns an error during list creation.

Copy
{
"message": "Something went wrong during list creation",
"status": 500
}