import { SupabaseClient } from '@supabase/supabase-js'; export interface Role { id: string; name: string; displayName?: string; description?: string; level: number; permissions: string[]; metadata?: Record; isActive: boolean; } export interface UserRole { userId: string; roleId: string; roleName?: string; context?: Record; grantedBy?: string; grantedAt?: string; expiresAt?: string | null; isActive: boolean; } /** * Hook for managing roles in the system (admin functionality) * Provides CRUD operations for roles and user assignments */ export declare function useRoleManagement(supabase: SupabaseClient): { loading: boolean; error: Error | null; fetchRoles: () => Promise; createRole: (role: Omit) => Promise; updateRole: (roleId: string, updates: Partial>) => Promise; deleteRole: (roleId: string) => Promise; fetchUserRoles: (userId?: string) => Promise; assignUserRole: (userId: string, roleName: string, context?: Record, expiresAt?: string | null) => Promise; revokeUserRole: (userId: string, roleName: string) => Promise; fetchAuditLog: (filters?: { userId?: string; targetUserId?: string; action?: string; limit?: number; }) => Promise; }; //# sourceMappingURL=useRoleManagement.d.ts.map