List participant conversations by ID
GET
/workspaces/{workspaceId}/participants/{conversationParticipantId}/conversations
List conversations of a participant by specifying their participant ID. A participant ID can be the ID of a user, an agent, a contact, an access key, and so on. This will return a maximum of 100 conversations per page, with 10 as default. You can use the limit and pageToken query parameters to paginate the results. Learn more about pagination in the Common API Usage pagination section.
Parámetros de consulta
limit
integer
pageToken
string
reverse
boolean
channelId
string
The channel ID
status
string
The status of a conversation
Possible values: active, closed, deleted
Cuerpo de la respuesta
results
array of object
obligatorio
List of conversations.
Mostrar atributos secundarios
results.accessibility
string
obligatorio
Possible values: open, invite-only, request-to-join, private
results.activeParticipantCount
integer
obligatorio
results.assigneeId
string
results.attributes
object
results.category
string
results.channelId
string
obligatorio
results.createdAt
string
obligatorio
results.description
string
results.directory
string
results.featuredParticipants
array of object
obligatorio
Mostrar atributos secundarios
results.featuredParticipants.avatarUrl
string
results.featuredParticipants.contact
object
Mostrar atributos secundarios
results.featuredParticipants.contact.identifierKey
string
obligatorio
results.featuredParticipants.contact.identifierValue
string
obligatorio
results.featuredParticipants.contact.platformAddress
string
results.featuredParticipants.contact.platformAddressSelector
string
results.featuredParticipants.conversationId
string
results.featuredParticipants.createdAt
string
results.featuredParticipants.displayName
string
results.featuredParticipants.id
string
obligatorio
results.featuredParticipants.resourceUri
string
results.featuredParticipants.status
string
Possible values: invited, pending, active, inactive
results.featuredParticipants.type
string
obligatorio
Possible values: user, contact, agent, flow, bot, accessKey, channel, connector, collaborationAutomation
results.featuredParticipants.updatedAt
string
results.hasDraft
boolean
results.id
string
obligatorio
results.inbox
object
Mostrar atributos secundarios
results.inbox.id
string
obligatorio
results.inbox.identifier
string
obligatorio
results.inbox.ownerId
string
obligatorio
results.inbox.ownerType
string
obligatorio
Possible values: user, group
results.inbox.type
string
obligatorio
Possible values: personal, shared, support
results.initiatingParticipant
object
Mostrar atributos secundarios
results.initiatingParticipant.avatarUrl
string
results.initiatingParticipant.contact
object
Mostrar atributos secundarios
results.initiatingParticipant.contact.identifierKey
string
obligatorio
results.initiatingParticipant.contact.identifierValue
string
obligatorio
results.initiatingParticipant.contact.platformAddress
string
results.initiatingParticipant.contact.platformAddressSelector
string
results.initiatingParticipant.conversationId
string
results.initiatingParticipant.createdAt
string
results.initiatingParticipant.displayName
string
results.initiatingParticipant.id
string
obligatorio
results.initiatingParticipant.resourceUri
string
results.initiatingParticipant.status
string
Possible values: invited, pending, active, inactive
results.initiatingParticipant.type
string
obligatorio
Possible values: user, contact, agent, flow, bot, accessKey, channel, connector, collaborationAutomation
results.initiatingParticipant.updatedAt
string
results.lastMessage
object
Mostrar atributos secundarios
results.lastMessage.createdAt
string
obligatorio
results.lastMessage.draft
boolean
obligatorio
results.lastMessage.id
string
obligatorio
results.lastMessage.preview
object
obligatorio
Mostrar atributos secundarios
results.lastMessage.preview.text
string
results.lastMessage.recipients
array of object
Mostrar atributos secundarios
results.lastMessage.recipients.contactAnnotation
object
Annotations add extra information to a sender or receiver. For email messages, the name annotation overrides the display name.
Mostrar atributos secundarios
results.lastMessage.recipients.contactAnnotation.name
string
results.lastMessage.recipients.countryCode
string
results.lastMessage.recipients.id
string
The ID of the contact.
results.lastMessage.recipients.identifierKey
string
The identifier key for finding the contact (e.g. emailaddress, phonenumber). For WhatsApp channels with BSUID support, use whatsappbsuid to send to a contact by their Business-Scoped User ID.
results.lastMessage.recipients.identifierValue
string
The identifier value for finding the contact.
results.lastMessage.recipients.identifiers
array of object
Additional identifiers to augment the contact during resolution.
Mostrar atributos secundarios
results.lastMessage.recipients.identifiers.identifierKey
string
obligatorio
The identifier key for finding the contact (e.g. emailaddress, phonenumber).
results.lastMessage.recipients.identifiers.identifierValue
string
obligatorio
The identifier value for finding the contact.
results.lastMessage.recipients.platformAddress
string
The resolved platform address used to deliver the message (e.g. phone number or email address).
results.lastMessage.recipients.platformAddressSelector
string
An expression that defines how we resolve the platform address from a contact. Optional override for the default resolution logic.
results.lastMessage.recipients.receiverExpression
string
results.lastMessage.recipients.receiverValue
string
results.lastMessage.recipients.type
string
The type of the receiver (e.g. to, cc, bcc for email).
results.lastMessage.sender
object
Mostrar atributos secundarios
results.lastMessage.sender.email
string
results.lastMessage.sender.name
string
results.lastMessage.sender.avatarUrl
string
results.lastMessage.sender.contact
object
Mostrar atributos secundarios
results.lastMessage.sender.contact.identifierKey
string
obligatorio
results.lastMessage.sender.contact.identifierValue
string
obligatorio
results.lastMessage.sender.contact.platformAddress
string
results.lastMessage.sender.contact.platformAddressSelector
string
results.lastMessage.sender.conversationId
string
results.lastMessage.sender.createdAt
string
results.lastMessage.sender.displayName
string
results.lastMessage.sender.id
string
obligatorio
results.lastMessage.sender.resourceUri
string
results.lastMessage.sender.status
string
Possible values: invited, pending, active, inactive
results.lastMessage.sender.type
string
obligatorio
Possible values: user, contact, agent, flow, bot, accessKey, channel, connector, collaborationAutomation
results.lastMessage.sender.updatedAt
string
results.lastMessage.status
string
obligatorio
Possible values: accepted, processing, sent, sending_failed, delivered, delivery_failed, deleted
results.lastMessage.type
string
obligatorio
Possible values: text, html, image, file, gif, location, carousel, list, section, authentication, action, comment
results.lastMessageIncomingAt
string
results.lastMessageOutgoingAt
string
results.name
string
obligatorio
results.participants
array of object
Mostrar atributos secundarios
results.participants.contact
object
Mostrar atributos secundarios
results.participants.contact.identifierKey
string
obligatorio
results.participants.contact.identifierValue
string
obligatorio
results.participants.contact.platformAddress
string
results.participants.contact.platformAddressSelector
string
results.participants.id
string
obligatorio
results.participants.type
string
obligatorio
Possible values: user, contact, agent, flow, bot, accessKey, channel, connector, collaborationAutomation
results.pendingParticipantCount
integer
results.platformStyle
string
obligatorio
Possible values: direct, email, direct-multiple, direct-threaded, group-multiple
results.privateAttributes
string
results.read
boolean
results.referral
object
Mostrar atributos secundarios
results.referral.caption
string
results.referral.mediaType
string
results.referral.mediaUrl
string
results.referral.sourceId
string
obligatorio
results.referral.sourceType
string
results.referral.sourceUrl
string
results.referral.text
string
results.referral.timestamp
string
results.referral.title
string
results.referral.username
string
results.resource
object
Mostrar atributos secundarios
results.resource.id
string
obligatorio
results.resource.type
string
obligatorio
Possible values: task, task-conversation, reimbursement, sales-lead, sales-opportunity, sales-account, expense, project
results.resourceUri
string
results.starred
boolean
results.status
string
obligatorio
Possible values: deleted, active, closed, spam, archived
results.style
string
obligatorio
Possible values: default, directMessage, chatChannel, personalInbox, resource, groupInbox, support
results.summary
string
results.tags
array of string
results.updatedAt
string
obligatorio
results.visibility
string
obligatorio
Possible values: public, private, direct, group
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.
total
integer
totalType
string
Possible values: ``, equal, greaterThanOrEqual
Ejemplo de código
curl -X GET 'https://api.bird.com/workspaces/{workspaceId}/participants/{conversationParticipantId}/conversations' \
-H 'Authorization: AccessKey YOUR_ACCESS_KEY'Examples
Ejemplo de código
curl "https://api.bird.com/workspaces/a1405560-c8d3-4b1a-877d-3f449ad95352/participants/8f0b5377-2edc-4116-a8e8-6a475f245a04/conversations?channelId=7b0eb8a0-606b-59f1-bd90-43cacb048146" \
-H "Authorization: AccessKey abcd"Ejemplo de código
{
"results": [
{
"id": "bace24af-cebb-4bd5-a1e6-f7cff24abadf",
"name": "Re: About your refund request",
"description": "",
"status": "active",
"visibility": "private",
"accessibility": "open",
"featuredParticipants": [
{
"id": "8f0b5377-2edc-4116-a8e8-6a475f245a04",
"type": "contact",
"status": "active",
"displayName": "John Doe",
"avatarUrl": "",
"contact": {
"identifierKey": "emailaddress",
"identifierValue": "john.doe@bird.com",
"platformAddress": "john.doe@bird.com"
}
}
],
"activeParticipantCount": 1,
"pendingParticipantCount": 0,
"initiatingParticipant": {
"id": "8f0b5377-2edc-4116-a8e8-6a475f245a04",
"type": "contact",
"status": "active",
"displayName": "John Doe",
"avatarUrl": "",
"contact": {
"identifierKey": "emailaddress",
"identifierValue": "john.doe@bird.com",
"platformAddress": "john.doe@bird.com"
}
},
"channelId": "7b0eb8a0-606b-59f1-bd90-43cacb048146",
"lastMessage": {
"id": "0ff78529-eb64-400d-8522-c45ae2170885",
"type": "html",
"preview": {
"text": "That's right 👍"
},
"recipients": null,
"status": "delivered",
"sender": {
"id": "8f0b5377-2edc-4116-a8e8-6a475f245a04",
"type": "contact",
"status": "active",
"displayName": "John Doe",
"avatarUrl": "",
"contact": {
"identifierKey": "emailaddress",
"identifierValue": "john.doe@bird.com",
"platformAddress": "john.doe@bird.com"
}
},
"createdAt": "2024-11-27T14:47:59.577Z"
},
"createdAt": "2024-11-27T14:47:59.577Z",
"updatedAt": "2024-11-27T14:47:59.577Z",
"platformStyle": "email"
}
]
}Note: if there are more than 10 conversations, the results may be paginated. Please refer to Pagination on how to use nextPageToken.