import { apiClient } from './client'

export interface OnboardingStatus {
  created_flow: boolean
  ran_session: boolean
  exported_session: boolean
  tried_ai_assistant: boolean
  invited_teammate: boolean
  connected_psa: boolean
  is_team_user: boolean
  dismissed: boolean
}

export async function getOnboardingStatus(): Promise<OnboardingStatus> {
  const response = await apiClient.get('/users/onboarding-status')
  return response.data
}

export async function dismissOnboarding(): Promise<void> {
  await apiClient.post('/users/onboarding-status/dismiss')
}
