Querying ticket holders
ticketHolders returns the buyers (one row per platform user) who have purchased at least one ticket for a given event. Each holder carries their tickets and the buy orders that produced them — so this is the entry point for "who's coming?", "what did they pay?", and "what state is each order in?".
All examples require a JWT — get one from the homepage first. The API key needs the events:read scope.
List holders for an event
query listTicketHolders($eventId: UUID!, $first: Int) {
ticketHolders(eventId: $eventId, first: $first) {
totalCount
nodes {
id
issueTime
user {
id
name
email
}
}
pageInfo {
hasNextPage
endCursor
}
}
}
Default page size: 20. Max page size: 50.
The query takes eventId as a required argument (not as a where filter) — this is one of the few queries with a positional input.
Pull a holder with their tickets
Each holder's tickets list is the actual EventTicket rows issued to them. Each ticket links back to its ticketSpecification (the SKU) and exposes refund flags.
query holdersWithTickets($eventId: UUID!) {
ticketHolders(eventId: $eventId, first: 20) {
nodes {
id
issueTime
user {
id
name
email
}
tickets {
id
purchaseDate
isRefunded
isRefundInProgress
ticketSpecification {
id
name
price
}
eventDates {
id
isRedeemed
timeOfRedemption
}
}
}
}
}
Filter by buy-order state
buyOrders on a holder is itself filterable — by state. Use it to surface only paid orders, or only pending ones that haven't completed yet.
query holdersPaidOrders($eventId: UUID!, $state: BuyOrderState!) {
ticketHolders(eventId: $eventId, first: 20) {
nodes {
id
user { id name email }
buyOrders(where: { state: { eq: $state } }) {
id
state
comment
created
expires
chargeSessionId
eventTickets {
id
ticketSpecificationId
amount
}
}
}
}
}
BuyOrderState values: Pending, Paid, Expired.
Pull the buyer's avatar
The user field on a holder exposes a denormalized avatar string (URL to the user's avatar image), plus name fields and contact info.
query holderProfiles($eventId: UUID!) {
ticketHolders(eventId: $eventId, first: 20) {
nodes {
id
user {
id
firstname
lastname
name
email
callingCode
phoneNumber
avatar
}
}
}
}