/**
 * Minimal AsyncLocalStorage context for request-scoped data.
 * Currently used only to propagate accountability into createAuditLog
 * so audit entries capture userId/IP even when ItemsService has no explicit accountability.
 */
import { AsyncLocalStorage } from 'node:async_hooks';
import type { Accountability } from '../types/index.js';
export interface RequestStore {
    accountability?: Accountability;
}
/** Singleton ALS instance */
export declare const requestContext: AsyncLocalStorage<RequestStore>;
/** Get the current request's accountability (or undefined outside a request) */
export declare function getContextAccountability(): Accountability | undefined;
/** Set accountability on the current request store */
export declare function setContextAccountability(accountability: Accountability): void;
/**
 * Express middleware — wraps the rest of the request in an ALS context.
 * Must be mounted BEFORE authMiddleware so the store exists when auth writes to it.
 */
export declare function requestContextMiddleware(req: any, _res: any, next: any): void;
//# sourceMappingURL=requestContext.d.ts.map