mirror of
https://github.com/bigcapitalhq/bigcapital.git
synced 2026-02-12 02:40:31 +00:00
29 lines
743 B
TypeScript
29 lines
743 B
TypeScript
import { ISystemUser } from './User';
|
|
import { ITenant } from './Tenancy';
|
|
|
|
export interface IRegisterDTO {
|
|
firstName: string,
|
|
lastName: string,
|
|
email: string,
|
|
password: string,
|
|
organizationName: string,
|
|
};
|
|
|
|
export interface ILoginDTO {
|
|
crediential: string,
|
|
password: string,
|
|
};
|
|
|
|
export interface IPasswordReset {
|
|
id: number,
|
|
email: string,
|
|
token: string,
|
|
createdAt: Date,
|
|
};
|
|
|
|
export interface IAuthenticationService {
|
|
signIn(emailOrPhone: string, password: string): Promise<{ user: ISystemUser, token: string, tenant: ITenant }>;
|
|
register(registerDTO: IRegisterDTO): Promise<ISystemUser>;
|
|
sendResetPassword(email: string): Promise<IPasswordReset>;
|
|
resetPassword(token: string, password: string): Promise<void>;
|
|
} |