import { SupportConversationRow, SupportConversationStatus, SupportMessageRow, SupportSenderType } from '../models/support.model'; export type ConversationListFilters = { status?: SupportConversationStatus; assignedTo?: string | null; search?: string; limit?: number; offset?: number; }; export declare function findConversationById(id: string): Promise; export declare function findActiveConversationForUser(userId: string): Promise; export declare function findActiveConversationForVisitor(visitorToken: string): Promise; export declare function listConversationsForUser(userId: string, limit?: number): Promise; export declare function listConversationsAdmin(filters: ConversationListFilters): Promise<{ rows: SupportConversationRow[]; total: number; }>; export declare function createConversation(input: { userId?: string | null; visitorToken?: string | null; subject?: string | null; }): Promise; export declare function attachVisitorConversationToUser(conversationId: string, userId: string): Promise; export declare function updateConversation(id: string, patch: Partial<{ status: SupportConversationStatus; assignedTo: string | null; subject: string | null; unreadUser: number; unreadStaff: number; }>): Promise; export declare function touchConversationLastMessage(id: string, preview: string, incrementUnreadUser: boolean, incrementUnreadStaff: boolean): Promise; export declare function resetUnreadCounters(id: string, side: 'user' | 'staff'): Promise; export declare function listMessages(conversationId: string, after?: string, limit?: number): Promise; export declare function createMessage(input: { conversationId: string; senderType: SupportSenderType; senderUserId?: string | null; body?: string | null; attachmentUrl?: string | null; attachmentName?: string | null; attachmentMime?: string | null; }): Promise; export declare function markMessagesRead(conversationId: string, readerSide: 'user' | 'staff'): Promise; export declare function countUnreadStaffInbox(): Promise; export declare function getUserContextForSupport(userId: string): Promise<{ id: string; email_encrypted: string | null; first_name: string | null; last_name: string | null; role_name: string; email_verified: boolean; is_enabled: boolean; created_at: Date; } | null>; export declare function getStaffDisplayName(userId: string): Promise; /** Attach every open visitor conversation to the user and rewrite visitor senders. */ export declare function mergeAllVisitorConversationsToUser(visitorToken: string, userId: string): Promise; //# sourceMappingURL=supportRepository.d.ts.map