List contacts in a list
client.list.listContacts(stringlistID, ListListContactsParams { limit, offset } query?, RequestOptionsoptions?): ListListContactsResponse { data, object, totalCount }
GET/v1/lists/{listId}/contacts
Returns a paginated list of contacts that belong to the specified list.
Required scopes: lists:read and contacts:read
Rate limit category: Search
Parameters
listID: string
Unique identifier of the list.
Returns
List contacts in a list
import Lightfield from 'lightfield';
const client = new Lightfield({
apiKey: 'My API Key',
});
const listListContactsResponse = await client.list.listContacts('listId');
console.log(listListContactsResponse.data);{
"data": [
{
"id": "id",
"createdAt": "createdAt",
"fields": {
"foo": {
"value": "string",
"valueType": "ADDRESS"
}
},
"httpLink": "httpLink",
"relationships": {
"foo": {
"cardinality": "cardinality",
"objectType": "objectType",
"values": [
"string"
]
}
},
"updatedAt": "updatedAt",
"externalId": "externalId"
}
],
"object": "object",
"totalCount": 0
}Returns Examples
{
"data": [
{
"id": "id",
"createdAt": "createdAt",
"fields": {
"foo": {
"value": "string",
"valueType": "ADDRESS"
}
},
"httpLink": "httpLink",
"relationships": {
"foo": {
"cardinality": "cardinality",
"objectType": "objectType",
"values": [
"string"
]
}
},
"updatedAt": "updatedAt",
"externalId": "externalId"
}
],
"object": "object",
"totalCount": 0
}