import type { AuthProvider } from 'ra-core'; import type { AuthDevice, AuthIdentity, AuthRegisterRequest, AuthRegisterResponse, AuthThirdPartyLogin, UpdateProfileRequest } from '../core/types/auth.types'; import type { BaseResponse } from '../core/types/common'; interface IApplicaAuthProvider extends AuthProvider { getHeaders: () => Promise; getToken: () => Promise; validateToken: (token: string) => Promise; getRoles: () => Promise; impersonate: (id: string | number) => Promise; isImpersonating: () => Promise; stopImpersonate: () => Promise; registerDevice: (code: string) => Promise; resetPin: (userId: string, pin: string) => Promise; pinLogin: (deviceCode: string, pin: string) => Promise; register: (data: AuthRegisterRequest) => Promise; getDevice: (code: string) => Promise; changePassword: (oldPassword: string, newPassword: string) => Promise; recover: (email: string) => Promise; activate: (activationCode: string) => Promise; updateProfile: (request: UpdateProfileRequest) => Promise; thirdPartyLogin: (data: AuthThirdPartyLogin) => Promise; } export type { IApplicaAuthProvider };