Skip to main content

EmailChannel

A channel for email conversations.

To fetch your active mailboxes, you can issue this query:

query Channels {
channels {
nodes {
... on EmailChannel {
color
createdAt
forwardEmailAddress
fromName
id
name
signature
updatedAt
}
}
pageInfo {
hasNextPage
}
}
}

To fetch inactive mailboxes:

query Channels {
channels(filter: { state: UNCONFIRMED }) {
nodes {
... on EmailChannel {
id
name
}
}
}
}

To fetch accessible folders (paginated) for each of your mailboxes:

query Channels {
channels {
nodes {
... on EmailChannel {
id
name
folders {
nodes {
id
name
}
pageInfo {
hasNextPage
}
}
}
}
}
}

To fetch conversations in this mailbox, use the QueryRoot conversations field with a filter argument e.g.:

query Conversations {
conversations(filter: { channel_id: "ch_12345678" }) {
nodes {
... on Conversation {
id
number
}
}
pageInfo {
hasNextPage
}
}
}
type EmailChannel implements Channel, EmailInterface, Node {
aiDraftsChannels: [EmailChannel!]
aiDraftsKnowledgeBases: [KnowledgeBase!]
aiQualityRating: String
autoBccAddress: String
color: String!
conversationCount(
state: [ConversationState!]
): Int!
createdAt: DateTime!
customFields(
after: String
before: String
first: Int
last: Int
): CustomFieldConnection!
email: String
emailTemplates: [EmailTemplate!]!
errors: [ChannelErrorTypeUnion!]!
folders(
after: String
before: String
filter: FolderFilter
first: Int
last: Int
orderBy: FolderOrder
): FolderConnection
forwardEmailAddress: String!
fromName: String!
id: ID!
incomingEmailServer: IncomingServerTypeUnion
name: String!
outgoingEmailServer: OutgoingServerTypeUnion
permittedAgents(
after: String
agentIds: [ID!]
before: String
first: Int
last: Int
): AgentConnection!
pinnedSearches(
after: String
before: String
filter: PinnedSearchFilter
first: Int
last: Int
orderBy: PinnedSearchOrder
): PinnedSearchConnection
position: Int!
provider: String!
restriction: Restriction!
senderName: String
signature: String
state: ChannelState!
tags(
after: String
before: String
filter: TagFilter
first: Int
last: Int
orderBy: TagOrder
): TagConnection
threadingType: ThreadingType!
type: ChannelType!
updatedAt: DateTime!
useAgentName: Boolean
}

Fields

EmailChannel.aiDraftsChannels ● [EmailChannel!] list object common

List of mailbox IDs used for generating AI drafts.

EmailChannel.aiDraftsKnowledgeBases ● [KnowledgeBase!] list object common

List of knowledge base IDs used for generating AI drafts.

EmailChannel.aiQualityRating ● String scalar common

AI quality rating for the mailbox.

EmailChannel.autoBccAddress ● String scalar common

Auto BCC email address.

EmailChannel.color ● String! non-null scalar common

The color of the mailbox.

EmailChannel.conversationCount ● Int! non-null scalar common

The count of conversations in the channel.

EmailChannel.conversationCount.state ● [ConversationState!] list enum common

Filter by state.

EmailChannel.createdAt ● DateTime! non-null scalar common

The date and time that the object was created.

EmailChannel.customFields ● CustomFieldConnection! non-null object common

The custom fields belonging to the custom field category.

EmailChannel.customFields.after ● String scalar common

Returns the elements in the list that come after the specified cursor.

EmailChannel.customFields.before ● String scalar common

Returns the elements in the list that come before the specified cursor.

EmailChannel.customFields.first ● Int scalar common

Returns the first n elements from the list.

EmailChannel.customFields.last ● Int scalar common

Returns the last n elements from the list.

EmailChannel.email ● String scalar common

The email address associated with the mailbox.

EmailChannel.emailTemplates ● [EmailTemplate!]! non-null object common

Email template used for automated or manual email communication.

EmailChannel.errors ● [ChannelErrorTypeUnion!]! non-null union common

Represents errors that occurred during channel integration setup.

EmailChannel.folders ● FolderConnection object common

Lists all folders that are accessible to the authenticated agent. Each folder can be associated with one or more mailboxes.

EmailChannel.folders.after ● String scalar common

Returns the elements in the list that come after the specified cursor.

EmailChannel.folders.before ● String scalar common

Returns the elements in the list that come before the specified cursor.

EmailChannel.folders.filter ● FolderFilter input common

The fields by which to filter the results.

EmailChannel.folders.first ● Int scalar common

Returns the first n elements from the list.

EmailChannel.folders.last ● Int scalar common

Returns the last n elements from the list.

EmailChannel.folders.orderBy ● FolderOrder input common

The field and direction by which to order the results.

EmailChannel.forwardEmailAddress ● String! non-null scalar common

The forwarding email address associated with the mailbox.

EmailChannel.fromName ● String! non-null scalar common

The name that replies should be sent from.

EmailChannel.id ● ID! non-null scalar common

EmailChannel.incomingEmailServer ● IncomingServerTypeUnion union common

The custom server used to send out emails.

EmailChannel.name ● String! non-null scalar common

The name of the channel.

EmailChannel.outgoingEmailServer ● OutgoingServerTypeUnion union common

The custom server used to send out emails.

EmailChannel.permittedAgents ● AgentConnection! non-null object common

The agents permitted to access this channel.

EmailChannel.permittedAgents.after ● String scalar common

Returns the elements in the list that come after the specified cursor.

EmailChannel.permittedAgents.agentIds ● [ID!] list scalar common

Agents that needs to be included

EmailChannel.permittedAgents.before ● String scalar common

Returns the elements in the list that come before the specified cursor.

EmailChannel.permittedAgents.first ● Int scalar common

Returns the first n elements from the list.

EmailChannel.permittedAgents.last ● Int scalar common

Returns the last n elements from the list.

EmailChannel.pinnedSearches ● PinnedSearchConnection object common

Lists all folders that are accessible to the authenticated agent. Each folder can be associated with one or more mailboxes.

EmailChannel.pinnedSearches.after ● String scalar common

Returns the elements in the list that come after the specified cursor.

EmailChannel.pinnedSearches.before ● String scalar common

Returns the elements in the list that come before the specified cursor.

EmailChannel.pinnedSearches.filter ● PinnedSearchFilter input common

The fields by which to filter the results.

EmailChannel.pinnedSearches.first ● Int scalar common

Returns the first n elements from the list.

EmailChannel.pinnedSearches.last ● Int scalar common

Returns the last n elements from the list.

EmailChannel.pinnedSearches.orderBy ● PinnedSearchOrder input common

The field and direction by which to order the results.

EmailChannel.position ● Int! non-null scalar common

The position that the mailbox should appear at when listed.

EmailChannel.provider ● String! non-null scalar common

The provider.

EmailChannel.restriction ● Restriction! non-null object common

The agents or teams that are allowed to access this channel.

EmailChannel.senderName ● String scalar common

Customers see this name in the From field when they view conversations sent from this channel.

EmailChannel.signature ● String scalar common

The default signature on outgoing messages from the mailbox.

EmailChannel.state ● ChannelState! non-null enum common

The state of the channel.

EmailChannel.tags ● TagConnection object common

Lists all tags.

EmailChannel.tags.after ● String scalar common

Returns the elements in the list that come after the specified cursor.

EmailChannel.tags.before ● String scalar common

Returns the elements in the list that come before the specified cursor.

EmailChannel.tags.filter ● TagFilter input common

The fields by which to filter the results.

EmailChannel.tags.first ● Int scalar common

Returns the first n elements from the list.

EmailChannel.tags.last ● Int scalar common

Returns the last n elements from the list.

EmailChannel.tags.orderBy ● TagOrder input common

The field and direction by which to order the results.

EmailChannel.threadingType ● ThreadingType! non-null enum common

Whether to use the agent’s name in customer replies.

EmailChannel.type ● ChannelType! non-null enum common

The communication type of the channel.

EmailChannel.updatedAt ● DateTime! non-null scalar common

The date and time that the object was last updated.

EmailChannel.useAgentName ● Boolean scalar common

Whether to use the agent’s name in customer replies.

Interfaces

Channel interface common

A channel is a source of incoming conversations. It dictates how messages in those conversations are sent and received.

For example, an EmailChannel is a channel where messages are sent as email. To fetch all of them:

query Channels {
channels {
nodes {
... on Channel {
__typename
id
name
conversationCount
}
}
}
}

By default channels are sorted by their user-defined row-order, called their position. To sort by name instead:

query Channels {
channels( orderBy: { field: NAME, direction: ASC } ) {
nodes {
... on EmailChannel {
id
}
}
}
}

To find which agents have permission to view this channel:

query Channels {
channels {
nodes {
id
name
permittedAgents {
totalCount
nodes {
id
}
}
}
}
}

Only find channels where the user is granted access to view it:

query Channels {
channels(filter: { scope: CURRENT_USER }) {
nodes {
id
name
permittedAgents {
totalCount
nodes {
id
}
}
}
}
}

Find all channels the user is allowed to view. Admin users can always view all channels:

query Channels {
channels(filter: { scope: ALL }) {
nodes {
id
name
permittedAgents {
totalCount
nodes {
id
}
}
}
}
}

EmailInterface interface common

Node interface common

An object with an ID.

Member of

DemoEmailChannel object ● EmailChannel object ● EmailChannelCreatePayload object ● EmailChannelUpdatePayload object ● EmailInterface interface