import { LedgerStore } from './ledger-store.js';
import type { TrellisHttpServer } from './server-shared.js';
export interface LedgerHandlerOptions {
    store: LedgerStore;
    /** When set, require Authorization: Bearer <key> */
    apiKey?: string;
}
export declare function resolveLedgerApiKey(): string | undefined;
export declare function createLedgerFetchHandler(opts: LedgerHandlerOptions): (req: Request) => Promise<Response>;
export declare function startLedgerServer(opts: {
    store: LedgerStore;
    apiKey?: string;
    port?: number;
    hostname?: string;
}): Promise<TrellisHttpServer>;
//# sourceMappingURL=ledger-handler.d.ts.map