import request from './request'

export interface SchemaChangeLogItem {
  id: number
  source_id: number
  database_id?: number
  table_id?: number
  column_id?: number
  change_type: string
  old_value?: string
  new_value?: string
  detected_at?: string
}

export function getSchemaChangeLogs(params?: { source_id?: number; change_type?: string; page?: number; page_size?: number }) {
  return request.get('/schema-changes/logs', { params })
}
