Files
alrahma_sunday_school_api/apps/api/dist/services/teamService.d.ts
T
2026-06-11 03:22:12 -04:00

36 lines
1.4 KiB
TypeScript

import { EmployeeRole } from '@rentaldrivego/database';
export interface InvitePayload {
firstName: string;
lastName: string;
email: string;
role: EmployeeRole;
}
export interface TeamMember {
id: string;
clerkUserId: string;
firstName: string;
lastName: string;
email: string;
phone: string | null;
role: EmployeeRole;
isActive: boolean;
createdAt: Date;
updatedAt: Date;
lastActiveAt?: Date | null;
invitationStatus?: 'accepted' | 'pending' | 'revoked';
}
export declare function listEmployees(companyId: string): Promise<TeamMember[]>;
export declare function inviteEmployee(companyId: string, inviterId: string, payload: InvitePayload): Promise<{
employee: any;
invitationId: any;
invitedBy: string;
}>;
export declare function updateEmployeeRole(companyId: string, requesterId: string, requesterRole: EmployeeRole, employeeId: string, payload: {
role: EmployeeRole;
}): Promise<any>;
export declare function deactivateEmployee(companyId: string, requesterRole: EmployeeRole, employeeId: string): Promise<any>;
export declare function reactivateEmployee(companyId: string, requesterRole: EmployeeRole, employeeId: string): Promise<any>;
export declare function removeEmployee(companyId: string, requesterRole: EmployeeRole, employeeId: string): Promise<{
success: boolean;
}>;
//# sourceMappingURL=teamService.d.ts.map