List contacts in a list
GET
/workspaces/{workspaceId}/lists/{listId}/contacts
This endpoint will return a list of contacts in the specified list.
路径参数
workspaceId
string
The unique identifier of the workspace.
listId
string
The ID of a list.
查询参数
limit
integer
Limits the number of results to return.
pageToken
string
The cursor that keeps track of the current position in the results.
reverse
boolean
Reverses the order in which the results are returned.
响应载荷
results
array of object
必填
显示子属性
results.accountIds
array of string
The list of account ids for the contact.
results.attributes
object
A map of key-value pairs, where the values are boolean, number, or string, or
a non-empty array of those, or null
results.companyRefs
array of string
The list of company references for the contact.
results.computedDisplayName
string
The computed display name for the contact. It can be derived, in the following order if available,
from the displayName attribute, the firstName attribute, the emailaddress identifier,
or the phonenumber identifier.
results.createdAt
string
必填
results.featuredIdentifiers
array of object
The list of identifiers for the contact.
显示子属性
results.featuredIdentifiers.key
string
必填
The identifier key. This can be from your custom identifier key or one of the built-in keys.
results.featuredIdentifiers.value
string
必填
The identifier value. This represents the actual value for the identifier.
results.id
string
必填
The unique identifier for the contact.
results.identifierCount
integer
The number of identifiers for the contact.
results.isAnonymous
boolean
Whether the contact is anonymous. A contact is anonymous if it has no identifiers,
or only has visitorid identifiers.
results.listIds
array of string
The list of list ids for the contact.
results.updatedAt
string
必填
results.workspaceId
string
Your workspace identifier.
nextPageToken
string
The token that can be passed as pageToken in URL to retrieve the next set of results. If missing, no more results to display.
代码示例
curl -X GET 'https://api.bird.com/workspaces/{workspaceId}/lists/{listId}/contacts' \
-H 'Authorization: AccessKey YOUR_ACCESS_KEY'Examples
Let's establish some of our data that will be used in the following examples:
- Workspace ID: a1405560-c8d3-4b1a-877d-3f449ad95352
- AccessKey: abcd
- List ID: 123e4567-e89b-12d3-a456-426614174000
List contacts from a list
In this example, we are listing all the contacts from a list given given the list ID.
代码示例
curl -X GET "https://api.bird.com/workspaces/a1405560-c8d3-4b1a-877d-3f449ad95352/lists/123e4567-e89b-12d3-a456-426614174000/contacts" \
-H "Content-Type: application/json" \
-H "Authorization: AccessKey abcd"代码示例
{
"results": [
{
"id": "12bd0e40-9361-4e32-8b26-99b4ab7eae09",
"computedDisplayName": "John",
"featuredIdentifiers": [
{
"key": "emailaddress",
"value": "contacts@bird.com"
}
],
"identifierCount": 1,
"attributes": {
"emailaddress": [
"contacts@bird.com"
],
"firstName": "John",
"initialReference": "32d6f4f9-7e9c-4271-bd83-9d6976808f2f",
"lastName": "Doe",
"timezone": "America/Sao_Paulo"
},
"listIds": [
"12bd0e40-9361-4e32-8b26-99b4ab7eae09"
],
"createdAt": "2024-11-26T15:00:00.000Z",
"updatedAt": "2024-11-26T15:00:00.000Z"
}
]
}