import type { PublicUser, User, LoginInput, RegisterInput, VerifyEmailInput, ResendVerificationInput, ForgotPasswordInput, ResetPasswordInput, AcceptInviteInput, ProfileUpdateInput, ChangePasswordInput, } from '@flashcard/shared'; import { api } from './client.js'; export const authApi = { me: () => api.get('/auth/me'), register: (input: RegisterInput) => api.post('/auth/register', input), verifyEmail: (input: VerifyEmailInput) => api.post<{ ok: true }>('/auth/verify-email', input), resendVerification: (input: ResendVerificationInput) => api.post<{ ok: true }>('/auth/resend-verification', input), login: (input: LoginInput) => api.post('/auth/login', input), logout: () => api.post('/auth/logout'), forgotPassword: (input: ForgotPasswordInput) => api.post<{ ok: true }>('/auth/forgot-password', input), resetPassword: (input: ResetPasswordInput) => api.post<{ ok: true }>('/auth/reset-password', input), acceptInvite: (input: AcceptInviteInput) => api.post('/auth/accept-invite', input), updateProfile: (input: ProfileUpdateInput) => api.patch('/auth/profile', input), changePassword: (input: ChangePasswordInput) => api.post('/auth/change-password', input), };