import { FastifyRequest } from 'fastify'
import { Pool } from 'pg'
import { TenantContext } from '../middleware/tenant-auth'

export interface User {
  id: string
  email: string
  name: string
  role: 'ADMIN' | 'USER' | 'VIEWER'
  createdAt: Date
  updatedAt: Date
}

export interface Context {
  request: FastifyRequest
  user?: User
  tenantContext?: TenantContext
  db: Pool
}

