/** * `webhookToStreamEvent` — pure Q1=A mapping. Takes a normalized * `{ githubEvent, action, body }` triple, the epic's ref-set filter, and * returns one `CockpitStreamEvent` per matched ref (or null when the payload * is out of scope). * * Contract: `specs/978-summary-generacy-cockpit/contracts/webhook-to-event-mapping.md`. * * Reuses `CockpitEventSchema` from `../watch/emit.ts` — does NOT extend the * enum. `from`/`to` are best-effort null (see contract § "Emitted shape"). */ import type { CockpitEventValidated } from '../watch/emit.js'; export interface RefSetView { epicRef: string; epicNumber: number; epicRepo: string; issues: Set; prs: Set; watchedRepos: Set; } /** * Q1=A mapping. Returns exactly one `CockpitEventValidated` for `issues.*` and * `pull_request.*` matches, or one per matched PR for `check_run.completed` / * `check_suite.completed`. Callers that want single-event semantics should * take the first element. */ export declare function webhookToStreamEvent(githubEvent: string, action: string, body: Record, refSet: RefSetView, now: () => string): CockpitEventValidated | CockpitEventValidated[] | null; //# sourceMappingURL=webhook-to-event.d.ts.map