EmailConversation
A Groove conversation initiated in an email channel.
To fetch a specific conversation by ID:
query Conversation {
node(id: "cnv_12345678") {
... on Conversation {
assigned {
at
agent {
id
name
}
team {
id
name
}
}
counts {
attachments
interactions
messages
notes
stateChanges
}
createdAt
deletedAt
drafts {
nodes {
id
}
}
followers {
nodes {
id
email
}
}
id
number
snoozed {
by { id }
until
}
starred
state
stateUpdatedAt
subject
systemUpdatedAt
tags {
nodes {
id
name
}
}
updatedAt
}
}
})
To fetch all conversations in a specific channel or folder:
query Conversations {
conversations(
filter: {
channel: "ch_4567890",
folder: "fol_8901234",
}
) {
nodes {
... on Conversation {
id
number
}
}
pageInfo {
hasNextPage
}
}
}
To find conversations in "all channels" that apply to a specific folder, omit the channel.
query Conversations {
conversations( filter: { folder: "fol_8901234" }) {
nodes {
... on Conversation {
id
number
}
}
pageInfo {
hasNextPage
}
}
}
By default, conversations are returned with the newest conversations first. To sort showing oldest first:
query Conversations {
conversations( orderBy: { field: UPDATED_AT, direction: ASC } ) {
nodes {
... on Conversation {
id
number
}
}
pageInfo {
hasNextPage
}
}
}
type EmailConversation implements Conversation, Node {
assigned: Assignment
channel: Channel!
contact: Contact
counts: ConversationCounts!
createdAt: DateTime!
customFieldValues(
after: String
before: String
filter: CustomFieldValuesFilter
first: Int
last: Int
): CustomFieldValueConnection
deletedAt: DateTime
drafts(
after: String
before: String
first: Int
last: Int
): DraftConnection
followers(
after: String
before: String
filter: AgentFilter
first: Int
last: Int
orderBy: AgentOrder
): AgentConnection
id: ID!
lastUnansweredUserMessageAt: DateTime!
mentions: [Mention!]!
number: Int!
searchSummary: SearchSummary
snoozed: Snooze
starred: Boolean!
state: ConversationState!
stateUpdatedAt: DateTime
subject: String
summaryMessage: SummaryMessage
systemUpdatedAt: DateTime!
tags(
after: String
before: String
filter: TagFilter
first: Int
last: Int
orderBy: TagOrder
): TagConnection
updatedAt: DateTime!
}
Fields
EmailConversation.assigned ● Assignment object common
The agents and/or teams that are assigned to the conversation.
EmailConversation.channel ● Channel! non-null interface common
The channel in which the conversation is happening.
EmailConversation.contact ● Contact object common
The primary contact associated with the conversation.
EmailConversation.counts ● ConversationCounts! non-null object common
The statistics about the messages and interactions in the conversation.
EmailConversation.createdAt ● DateTime! non-null scalar common
The date and time that the object was created.
EmailConversation.customFieldValues ● CustomFieldValueConnection object common
Lists all custom fields.
EmailConversation.customFieldValues.after●Stringscalar commonReturns the elements in the list that come after the specified cursor.
EmailConversation.customFieldValues.before ● String scalar common
Returns the elements in the list that come before the specified cursor.
EmailConversation.customFieldValues.filter ● CustomFieldValuesFilter input common
Filter custom field values.
EmailConversation.customFieldValues.first ● Int scalar common
Returns the first n elements from the list.
EmailConversation.customFieldValues.last ● Int scalar common
Returns the last n elements from the list.
EmailConversation.deletedAt ● DateTime scalar common
The date and time that the conversation was trashed.
EmailConversation.drafts ● DraftConnection object common
The current user's draft messages on the conversation.
EmailConversation.drafts.after●Stringscalar commonReturns the elements in the list that come after the specified cursor.
EmailConversation.drafts.before ● String scalar common
Returns the elements in the list that come before the specified cursor.
EmailConversation.drafts.first ● Int scalar common
Returns the first n elements from the list.
EmailConversation.drafts.last ● Int scalar common
Returns the last n elements from the list.
EmailConversation.followers ● AgentConnection object common
Lists all agents that are following the conversation.
EmailConversation.followers.after●Stringscalar commonReturns the elements in the list that come after the specified cursor.
EmailConversation.followers.before ● String scalar common
Returns the elements in the list that come before the specified cursor.
EmailConversation.followers.filter ● AgentFilter input common
The fields by which to filter the results.
EmailConversation.followers.first ● Int scalar common
Returns the first n elements from the list.
EmailConversation.followers.last ● Int scalar common
Returns the last n elements from the list.
EmailConversation.followers.orderBy ● AgentOrder input common
The field and direction by which to order the results.
EmailConversation.id ● ID! non-null scalar common
EmailConversation.lastUnansweredUserMessageAt ● DateTime! non-null scalar common
The date and time of the last unanswered user message.
EmailConversation.mentions ● [Mention!]! non-null object common
The mentions for the conversation.
EmailConversation.number ● Int! non-null scalar common
The ID of the conversation within the account.
EmailConversation.searchSummary ● SearchSummary object common
The comment that matched the given search keywords.
EmailConversation.snoozed ● Snooze object common
The agent that snoozed the conversation and when it is snoozed until.
EmailConversation.starred ● Boolean! non-null scalar common
True if the conversation is starred; false otherwise.
EmailConversation.state ● ConversationState! non-null enum common
The state of the conversation.
EmailConversation.stateUpdatedAt ● DateTime scalar common
The date and time that the conversation state was last updated.
EmailConversation.subject ● String scalar common
The subject of the conversation.
EmailConversation.summaryMessage ● SummaryMessage object common
The conversation summary, which is usually the first MessageChange in the conversation.
EmailConversation.systemUpdatedAt ● DateTime! non-null scalar common
The date and time that the conversation was last updated.
EmailConversation.tags ● TagConnection object common
Lists all tags.
EmailConversation.tags.after●Stringscalar commonReturns the elements in the list that come after the specified cursor.
EmailConversation.tags.before ● String scalar common
Returns the elements in the list that come before the specified cursor.
EmailConversation.tags.filter ● TagFilter input common
The fields by which to filter the results.
EmailConversation.tags.first ● Int scalar common
Returns the first n elements from the list.
EmailConversation.tags.last ● Int scalar common
Returns the last n elements from the list.
EmailConversation.tags.orderBy ● TagOrder input common
The field and direction by which to order the results.
EmailConversation.updatedAt ● DateTime! non-null scalar common
The date and time that the object was last updated.
Interfaces
Conversation interface common
A Groove conversation is a thread of messages (for example emails, chats, or notes) and associated actions or events (for example 'opened', 'snoozed', and 'assigned').
To fetch Messages/Ratings/StateChanges/etc. on a conversation, query the
Events connection (on the QueryRoot) with the conversation ID.
To fetch all possible fields:
query Conversation {
node(id: "cnv_12345678") {
__typename
... on Conversation {
assigned {
at
agent {
id
name
}
team {
id
name
}
}
counts {
attachments
interactions
messages
notes
stateChanges
}
createdAt
contact {
id
email
}
deletedAt
drafts {
nodes {
id
}
}
followers {
nodes {
id
email
}
}
id
number
snoozed {
by { id }
until
}
starred
state
stateUpdatedAt
summaryMessage {
id
bodyPlainText
}
subject
systemUpdatedAt
tags {
nodes {
id
name
}
}
updatedAt
... on FacebookConversation {
facebookId
}
... on TwitterConversation {
twitterId
}
... on WidgetConversation {
browser
referrer
pageTitle
pageUrl
platform
referrer
}
}
}
}
To search conversations matching a specific keyword:
query Conversations {
conversations(filter: { keywords: "rad" }) {
edges {
node {
... on Conversation {
id
number
searchSummary {
author {
__typename
... on Agent {
email
role
}
... on Contact {
email
}
}
body
forwarded
note
}
}
}
}
}
}
Node interface common
An object with an ID.
Member of
ConversationCreateEmailPayload object ● ConversationLogPayload object
Implemented by
CustomFieldSubjectType union