latestSwagger 2.02026-08-101561322.2 MB

3e4029d19684

Lists

Assign contacts to a list

<a class="try-sandbox-link" href="https://sandbox.textmagic.com/#/Lists/assignContactsToList" target="_blank">Try in sandbox</a><br>> Unlike all other PUT requests, this command does not need old contact IDs to be submitted. For example, if you have a list with contacts 150, 151 and 152 and you want to add contact ID 153, you only need to submit 153 as a parameter of PUT /api/v2/lists/{id}/contacts.

put/api/v2/lists/{id}/contacts

Path parameters

idinteger required

Request body

contactsstring required

Comma-separated array of Contacts IDs.

Example request

{
  "contacts": "318,454,30091"
}

Response

Returned when successful.

idinteger required

Resource ID.

hrefstring required

A link to this resource. If you want to fetch it, just GET this address.

Example response

{
  "id": 515,
  "href": "/api/v2/entity_name/1"
}