← API reference
CANONICAL TYPE REFERENCE

FileState

A file attached to a job, component, or other entity

Unique identifier

Associated job ID

Associated component ID

Associated order ID

Associated estimate ID

Associated invoice ID

Associated purchase order ID

nameString!

Display name

Original filename as uploaded

mimeTypeString!

MIME type of the file

File size in bytes

Where the bytes live, or null while an upload is in flight

Folder holding the bytes for folder-managed files; null otherwise

Storage key for external-backed files; null for folder-managed files

checksumString

File checksum

File category

Processing status

Usage role when attached to a component

Parent file ID for versioned files

Version number

Processing metadata (JSON)

ID of the user who uploaded the file

createdAtString!

Creation timestamp (ISO8601)

updatedAtString!

Last update timestamp (ISO8601)

View exact SDL
"""A file attached to a job, component, or other entity"""
type FileState {
  """Unique identifier"""
  id: FileID!
  """Associated job ID"""
  jobId: JobID
  """Associated component ID"""
  componentId: ComponentID
  """Associated order ID"""
  orderId: OrderID
  """Associated estimate ID"""
  estimateId: EstimateID
  """Associated invoice ID"""
  invoiceId: InvoiceID
  """Associated purchase order ID"""
  purchaseOrderId: PurchaseOrderID
  """Display name"""
  name: String!
  """Original filename as uploaded"""
  originalFilename: String!
  """MIME type of the file"""
  mimeType: String!
  """File size in bytes"""
  sizeBytes: Int!
  """Where the bytes live, or null while an upload is in flight"""
  storageBackend: FileStorageBackendTag
  """Folder holding the bytes for folder-managed files; null otherwise"""
  folderId: FolderID
  """Storage key for external-backed files; null for folder-managed files"""
  externalStorageKey: String
  """File checksum"""
  checksum: String
  """File category"""
  category: FileCategory!
  """Processing status"""
  status: FileStatus!
  """Usage role when attached to a component"""
  usageRole: ComponentFileUsageRole
  """Parent file ID for versioned files"""
  parentFileId: FileID
  """Version number"""
  versionNumber: Int!
  """Processing metadata (JSON)"""
  processingMetadata: JSONMap
  """ID of the user who uploaded the file"""
  uploadedByUserId: UserID
  """Creation timestamp (ISO8601)"""
  createdAt: String!
  """Last update timestamp (ISO8601)"""
  updatedAt: String!
}

One stable address across all schema views. Follow a field’s type to explore connections between domains.