import { type EntityManager } from 'typeorm'; export declare class SequenceNeedsATransaction extends Error { readonly code = "sequence-needs-a-transaction"; constructor(key: string); } export interface TakeSequenceOptions { /** How many numbers - the first of the run is answered. */ count?: number; /** The highest number already in use, for a series that existed before its counter. Called once, by the first taker. */ seed?: () => Promise; } export declare function takeSequence(tx: EntityManager, domain: { id: string; }, key: string, options?: TakeSequenceOptions): Promise; /** * **The next name of a day's series** - `{head}-YYYYMMDD-NNN`, numbered by `takeSequence` (key `daily:{head}:{day}`). * `taken` lists the names already in the table, for a series that existed before its counter - read once, by the first * taker of the day. */ export declare function takeDailyName(tx: EntityManager, domain: { id: string; }, head: string, day: string, options?: { width?: number; taken?: () => Promise; }): Promise;