/**
 * The contract POSTed to a webhook endpoint when an eval report matches the
 * subscriber's events. Authored independently of `WebhookEventEnvelopeSchema`
 * (in `schemas/callback-payload.ts`) so the schema asserts `satisfies` against
 * it (D0045). Versioned so receivers can branch on future shape changes.
 */
import type { EventType } from "../../ailf-shared/index.d.ts";
export interface WebhookEventReport {
    /** Published report id, when the run published. */
    reportId?: string;
    /** Human-supplied report tag, when present. */
    publishTag?: string;
    /** Documentation source name (e.g. repo slug). */
    source: string;
    /** Feature areas this report covered. */
    areas: string[];
    /** Area slugs scoring below the critical threshold. */
    belowCritical: string[];
    /** Area slugs that regressed vs the comparison baseline. */
    regressed: string[];
    /** Whether the report was published degraded. */
    degraded: boolean;
    /** Dashboard deep link to the report, when resolvable. */
    link?: string;
}
export interface WebhookEventEnvelope {
    schemaVersion: 1;
    /** ISO 8601 UTC, stamped at delivery. */
    deliveredAt: string;
    /** Which emitter produced this delivery. */
    surface: "per-run" | "subscription";
    /** Derived events that matched the subscriber's filter. */
    events: EventType[];
    report: WebhookEventReport;
    /** Present for per-run (B1) deliveries. */
    jobId?: string;
    /** The report's summary (ReportSummary) for richer consumers. */
    summary?: unknown;
}
