Skip to main content
QUERY
customerByExternalId(externalId: ID!): Customer

Arguments

externalId
ID!
required

Returns

id
ID!

Uniquely identifies a customer in Plain.

externalId
ID

Your system's ID for this customer.

fullName
String!

The full name of the customer.

shortName
String

An optional short name of the customer, typically their first name.

The customer's email address.

avatarUrl
String

The avatar URL of the customer.

assignedToUser

The user the customer is assigned to.

assignedAt

When the customer was assigned to a user.

customerGroupMemberships

A subquery to fetch the customer's group memberships.

Arguments
first
Int
after
String
last
Int
before
String

A subquery to fetch the customer's tenants.

Arguments
first
Int
after
String
last
Int
before
String
company

The company the customer belongs to.

isAnonymous
Boolean!

True when the customer was auto-created without a known identity (e.g. from an anonymous chat session). Anonymous customers may have limited profile data.

createdAt
createdBy
updatedAt
updatedBy
markedAsSpamAt

When the customer was marked as spam. Null if the customer has not been marked as spam.

markedAsSpamBy

The internal user or machine user who marked this customer as spam.

identities

All known channel identities for this customer (email, Discord, Slack, etc.).

status
deprecated
Use Thread.status instead
statusChangedAt
deprecated
Use Thread.statusChangedAt instead
lastIdleAt
deprecated
Use Thread.statusChangedAt instead
Query
Variables
Response