import api from '../utils/api'; export interface LoginRequest { username: string; password: string; } export interface LoginResponse { accessToken: string; userId: number; username: string; role: string; } export const adminAuthService = { async login(data: LoginRequest): Promise { const response = await api.post('/admin/auth/login', data); return response.data; }, async logout(): Promise<{ message: string }> { const response = await api.post<{ message: string }>('/admin/auth/logout'); return response.data; }, };