import type { WebhookTarget } from './matchWebhooks.js'; /** * In-process cache of the enabled webhooks and each one's pending count. The * subscriber runs for EVERY event (a bulk import emits thousands), so it must * not query the database per event. A change to a webhook is picked up within * `ttlMs`; the pending count is also bumped locally as deliveries are created, * and the next refresh corrects it as the cron job drains rows. */ export declare function createWebhookCache(load: () => Promise, ttlMs?: number, clock?: () => number): { getTargets(): Promise; recordEnqueued(webhookId: number, count: number): void; reset(): void; }; export declare const webhookCache: { getTargets(): Promise; recordEnqueued(webhookId: number, count: number): void; reset(): void; };