import { Command } from 'commander'; import { type CommandRunner, type GhWrapper, type RateLimitScheduler } from '@generacy-ai/cockpit'; import { type AcquireOptions, type Acquired } from './mcp/event-bus-registry.js'; import { discoverChannelUrl } from './doorbell/channel-discovery.js'; import { SourceSelector } from './doorbell/source-selector.js'; import { SmeeDoorbellSource } from './doorbell/smee-source.js'; export interface DoorbellOptions { tracking?: boolean; new?: string; exitOnEpicComplete?: boolean; } export interface DoorbellDeps { runner?: CommandRunner; gh?: GhWrapper; rateLimitScheduler?: RateLimitScheduler; logger?: { warn: (msg: string) => void; info?: (msg: string) => void; }; acquireBus?: (options: AcquireOptions) => Promise; abortSignal?: AbortSignal; stdout?: { write(chunk: string, cb?: () => void): boolean | void; }; exit?: (code: number) => void; /** Test seam: override channel discovery. */ discoverChannel?: typeof discoverChannelUrl; /** Test seam: override the smee source constructor. */ smeeSourceFactory?: (opts: ConstructorParameters[0]) => SmeeDoorbellSource; /** Test seam: override the source selector constructor. */ sourceSelectorFactory?: (opts: ConstructorParameters[0]) => SourceSelector; /** Test seam: env passed to `discoverChannelUrl`. Defaults to `process.env`. */ env?: NodeJS.ProcessEnv; /** Test seam: filesystem passed to `discoverChannelUrl`. */ fs?: Parameters[0]['fs']; /** Test seam: channel-file path override. */ channelFilePath?: string; } export type Form = { kind: 'form-1'; ref: string; } | { kind: 'form-2'; ref: string; } | { kind: 'form-3'; title: string; }; export type Rejection = { kind: 'missing-positional'; } | { kind: 'conflicting-flags'; reason: 'positional-with-new' | 'tracking-with-new'; }; export declare function classifyForm(positional: string | undefined, options: DoorbellOptions): Form | Rejection; export declare function runDoorbell(positional: string | undefined, options: DoorbellOptions, deps?: DoorbellDeps): Promise; export declare function doorbellCommand(): Command; //# sourceMappingURL=doorbell.d.ts.map