import { apiClient } from './api'

export interface PendingReviewSubmission {
  id: number
  task_id: number
  user_id: number
  file_name: string
  version_number: number
  submitted_at: string
  user_first_name: string
  user_last_name: string
}

export const reviewService = {
  async getPendingReviews(projectId?: number): Promise<PendingReviewSubmission[]> {
    const params = projectId ? { project_id: projectId } : {}
    const response = await apiClient.get('/reviews/pending', { params })
    return response.data
  }
}
