import { type PersistedScanIssue, type ScanIssue } from "../types/index.js";
/**
 * Derive a stable fingerprint from an issue.
 * Normalises the page URL to its pathname (ignores query/fragment) so the same
 * error on foo.com/page?x=1 and foo.com/page?x=2 is treated as the same issue.
 */
export declare function fingerprintIssue(issue: ScanIssue): string;
export type UpsertOutcome = "new" | "existing" | "regressed";
export interface UpsertResult {
    issue: PersistedScanIssue;
    outcome: UpsertOutcome;
}
/**
 * Upsert a scan issue by fingerprint:
 * - New (never seen): insert with status=open
 * - Known open: bump occurrence_count + last_seen_at
 * - Known resolved: mark as regressed (status=regressed, increment count)
 */
export declare function upsertScanIssue(issue: ScanIssue, projectId?: string): UpsertResult;
export declare function resolveScanIssue(id: string): boolean;
export declare function setScanIssueTodoTaskId(id: string, todoTaskId: string): void;
export declare function listScanIssues(opts?: {
    status?: string;
    type?: string;
    projectId?: string;
    limit?: number;
}): PersistedScanIssue[];
export declare function getScanIssue(id: string): PersistedScanIssue | null;
//# sourceMappingURL=scan-issues.d.ts.map