Skip to main content

GraphQL Types

This page documents all GraphQL types available in the Boards API. Types are organized by domain: Boards, Generations, Generators, and Users.

Type Overview

TypeDescription
BoardA collection of generations
BoardMemberA user's membership in a board
BoardRoleEnum for member permissions
GenerationAn AI-generated artifact
GenerationStatusEnum for generation states
ArtifactTypeEnum for content types
ArtifactLineageInput artifact relationship
AncestryNodeNode in ancestry tree
DescendantNodeNode in descendants tree
AdditionalFileExtra files from generation
GeneratorInfoAvailable generator metadata
UserUser account information

Board Types

Board

A board is a collection of AI-generated content. Boards can be public or private, and support collaborative access through board members.

type Board {
id: UUID!
tenantId: UUID!
ownerId: UUID!
title: String!
description: String
isPublic: Boolean!
settings: JSON!
metadata: JSON!
createdAt: DateTime!
updatedAt: DateTime!

# Resolved fields
owner: User!
members: [BoardMember!]!
generations(limit: Int = 50, offset: Int = 0): [Generation!]!
generationCount: Int!
}

Fields

FieldTypeDescription
idUUID!Unique identifier
tenantIdUUID!Tenant the board belongs to
ownerIdUUID!ID of the board owner
titleString!Board title
descriptionStringOptional description
isPublicBoolean!Whether the board is publicly visible
settingsJSON!Board-specific settings
metadataJSON!Additional metadata
createdAtDateTime!Creation timestamp
updatedAtDateTime!Last update timestamp
ownerUser!The user who owns the board
members[BoardMember!]!Users with access to this board
generations[Generation!]!Generations in this board (paginated)
generationCountInt!Total number of generations

Example Query

query GetBoard($id: UUID!) {
board(id: $id) {
id
title
description
isPublic
owner {
displayName
avatarUrl
}
members {
user {
displayName
}
role
}
generationCount
generations(limit: 10) {
id
thumbnailUrl
artifactType
}
}
}

BoardMember

Represents a user's membership in a board with their assigned role.

type BoardMember {
id: UUID!
boardId: UUID!
userId: UUID!
role: BoardRole!
invitedBy: UUID
joinedAt: DateTime!

# Resolved fields
user: User!
inviter: User
}

Fields

FieldTypeDescription
idUUID!Unique identifier
boardIdUUID!ID of the board
userIdUUID!ID of the member user
roleBoardRole!Member's permission level
invitedByUUIDID of user who sent the invite
joinedAtDateTime!When the user joined
userUser!The member's user object
inviterUserUser who invited this member

BoardRole

Enumeration of possible board member roles.

enum BoardRole {
VIEWER
EDITOR
ADMIN
}
ValueDescription
VIEWERCan view board content
EDITORCan view and create generations
ADMINFull access including member management

Generation Types

Generation

A generation represents an AI-generated artifact (image, video, audio, text, etc.) with its input parameters, output files, and lineage information.

type Generation {
id: UUID!
tenantId: UUID!
boardId: UUID!
userId: UUID!

# Generation details
generatorName: String!
artifactType: ArtifactType!

# Storage
storageUrl: String
thumbnailUrl: String
additionalFiles: [AdditionalFile!]!

# Parameters and metadata
inputParams: JSON!
outputMetadata: JSON!

# Job tracking
externalJobId: String
status: GenerationStatus!
progress: Float!
errorMessage: String

# Timestamps
startedAt: DateTime
completedAt: DateTime
createdAt: DateTime!
updatedAt: DateTime!

# Resolved fields
board: Board!
user: User!
inputArtifacts: [ArtifactLineage!]!
ancestry(maxDepth: Int = 25): AncestryNode!
descendants(maxDepth: Int = 25): DescendantNode!
}

Fields

FieldTypeDescription
idUUID!Unique identifier
tenantIdUUID!Tenant this generation belongs to
boardIdUUID!Board containing this generation
userIdUUID!User who created this generation
generatorNameString!Name of the generator used
artifactTypeArtifactType!Type of content generated
storageUrlStringURL to the generated artifact
thumbnailUrlStringURL to thumbnail (for images/videos)
additionalFiles[AdditionalFile!]!Extra output files
inputParamsJSON!Parameters passed to the generator
outputMetadataJSON!Metadata from the generation
externalJobIdStringID from external generation service
statusGenerationStatus!Current job status
progressFloat!Progress (0.0 to 1.0)
errorMessageStringError details if failed
startedAtDateTimeWhen processing started
completedAtDateTimeWhen processing finished
createdAtDateTime!When the job was created
updatedAtDateTime!Last update time
boardBoard!The board this belongs to
userUser!User who created this
inputArtifacts[ArtifactLineage!]!Input artifacts with roles
ancestryAncestryNode!Full ancestry tree
descendantsDescendantNode!All derived generations

Example Query

query GetGeneration($id: UUID!) {
generation(id: $id) {
id
generatorName
artifactType
status
progress
storageUrl
thumbnailUrl
inputParams
outputMetadata
createdAt
completedAt
user {
displayName
}
inputArtifacts {
role
artifactType
generation {
id
thumbnailUrl
}
}
}
}

GenerationStatus

Enumeration of generation job states.

enum GenerationStatus {
PENDING
PROCESSING
COMPLETED
FAILED
CANCELLED
}
ValueDescription
PENDINGJob is queued, waiting to start
PROCESSINGJob is currently running
COMPLETEDJob finished successfully
FAILEDJob encountered an error
CANCELLEDJob was cancelled by user

ArtifactType

Enumeration of supported artifact content types.

enum ArtifactType {
IMAGE
VIDEO
AUDIO
TEXT
LORA
MODEL
}
ValueDescription
IMAGEStatic image (PNG, JPEG, WebP, etc.)
VIDEOVideo file (MP4, WebM, etc.)
AUDIOAudio file (MP3, WAV, etc.)
TEXTText content
LORALoRA model weights
MODELFull model weights

ArtifactLineage

Represents a relationship between a generation and one of its input artifacts.

type ArtifactLineage {
generationId: UUID!
role: String!
artifactType: ArtifactType!

# Resolved fields
generation: Generation
}

Fields

FieldTypeDescription
generationIdUUID!ID of the input generation
roleString!Role of this input (e.g., "image", "mask", "reference")
artifactTypeArtifactType!Type of the input artifact
generationGenerationFull generation object

AncestryNode

Represents a node in the ancestry tree, showing all inputs that led to a generation.

type AncestryNode {
generation: Generation!
depth: Int!
role: String
parents: [AncestryNode!]!
}

Fields

FieldTypeDescription
generationGeneration!The generation at this node
depthInt!Depth in the tree (0 = root)
roleStringRole this generation played as input
parents[AncestryNode!]!Parent nodes (inputs to this generation)

DescendantNode

Represents a node in the descendants tree, showing all generations derived from an artifact.

type DescendantNode {
generation: Generation!
depth: Int!
role: String
children: [DescendantNode!]!
}

Fields

FieldTypeDescription
generationGeneration!The generation at this node
depthInt!Depth in the tree (0 = root)
roleStringRole the parent played for this generation
children[DescendantNode!]!Child nodes (generations using this as input)

AdditionalFile

Represents an additional file produced by a generation (e.g., depth maps, masks).

type AdditionalFile {
url: String!
type: String!
metadata: JSON!
}

Fields

FieldTypeDescription
urlString!URL to the file
typeString!File type identifier
metadataJSON!Additional file metadata

Generator Types

GeneratorInfo

Information about an available generator.

type GeneratorInfo {
name: String!
description: String!
artifactType: ArtifactType!
inputSchema: JSON!
}

Fields

FieldTypeDescription
nameString!Unique generator identifier
descriptionString!Human-readable description
artifactTypeArtifactType!Type of content this generator produces
inputSchemaJSON!JSON Schema for input parameters

Example Query

query GetGenerators {
generators {
name
description
artifactType
inputSchema
}
}

User Types

User

Represents a user account in the system.

type User {
id: UUID!
tenantId: UUID!
authProvider: String!
authSubject: String!
email: String
displayName: String
avatarUrl: String
createdAt: DateTime!
updatedAt: DateTime!

# Resolved fields
boards: [Board!]!
memberBoards: [Board!]!
}

Fields

FieldTypeDescription
idUUID!Unique identifier
tenantIdUUID!Tenant this user belongs to
authProviderString!Authentication provider (supabase, clerk, etc.)
authSubjectString!Subject ID from the auth provider
emailStringUser's email address
displayNameStringDisplay name
avatarUrlStringURL to avatar image
createdAtDateTime!Account creation time
updatedAtDateTime!Last update time
boards[Board!]!Boards owned by this user
memberBoards[Board!]!Boards where user is a member

Example Query

query GetCurrentUser {
me {
id
email
displayName
avatarUrl
boards {
id
title
}
memberBoards {
id
title
owner {
displayName
}
}
}
}

Scalar Types

The API uses the following scalar types:

ScalarDescription
UUIDUUID string (e.g., "550e8400-e29b-41d4-a716-446655440000")
DateTimeISO 8601 datetime string (e.g., "2024-01-15T10:30:00Z")
JSONArbitrary JSON object

Source Files

Type definitions are implemented in:

  • packages/backend/src/boards/graphql/types/board.py
  • packages/backend/src/boards/graphql/types/generation.py
  • packages/backend/src/boards/graphql/types/generator.py
  • packages/backend/src/boards/graphql/types/user.py