import request from './request' export interface UserProfile { id: number employeeNo: string realName: string avatarUrl: string email: string departmentName: string position: string userType: string status: string feishuStatus: string lastLoginAt: string } export interface LoginResponse { token: string tokenType: string expiresIn: number user: UserProfile } export const authApi = { feishuLogin: (code: string, state?: string): Promise => request.post('/auth/feishu-login', { code, state }), getAuthUrl: (): Promise<{ authUrl: string }> => request.get('/feishu/auth-url'), getUserInfo: (): Promise => request.get('/auth/me'), refreshToken: (): Promise => request.post('/auth/refresh'), logout: (): Promise => request.post('/auth/logout'), }