gatelineAPI reference
  • The landing counters (#343), as a pure function of the facts they read — the counting rule the engine's DL check depends on, exposed so it can be tested without a repository.

    What a dispatch was sent to land is the gate's packet artifact for a producer role, and the task's whole record — work item plus reviews — for a task-scoped one. An entry counts when it closed ok — a failure is the failure path's business (#147) and a refusal never ran (#155) — and was opened after both of the facts that reset the count: the artifact last moving, and the latest resolution of that (role, task)'s own landing escalation. A missing artifact has no landing to be newer than, so every closed-ok entry counts, which is the case the cap most needs to see.

    "After" is branch order (#346): the entry's own intent commit against the commit that landed the artifact. It is the opening commit that decides, not the closing one — a dispatch that produced something opens before its artifact lands and closes after it, so counting by the close would count every successful dispatch as idle. The ledger's at and the artifact's commit time remain the fallback for facts the branch cannot place.

    Parameters

    • input: {
          escalations: {
              at: null | string;
              disposition: null | "re-review" | "return-to-implement" | "re-plan";
              from_role: null | string;
              reason: string;
              resolution: null | string;
              resolved: boolean;
              resolved_at: null | string;
              resolved_by: null | string;
              [key: string]: unknown;
          }[];
          lastTouched: Record<string, null | number>;
          lastTouchedOid?: Record<string, null | string>;
          ledger: BudgetLedgerEntry[];
          ledgerCommits?: { close: null | CommitInfo; open: null | CommitInfo }[];
          order?: BranchOrder;
          resolutionCommits?: (null | CommitInfo)[];
          reviews: ReviewInfo[];
          taskFiles: Map<string, TaskFileInfo>;
      }
      • escalations: {
            at: null | string;
            disposition: null | "re-review" | "return-to-implement" | "re-plan";
            from_role: null | string;
            reason: string;
            resolution: null | string;
            resolved: boolean;
            resolved_at: null | string;
            resolved_by: null | string;
            [key: string]: unknown;
        }[]
      • lastTouched: Record<string, null | number>
      • OptionallastTouchedOid?: Record<string, null | string>
      • ledger: BudgetLedgerEntry[]
      • OptionalledgerCommits?: { close: null | CommitInfo; open: null | CommitInfo }[]

        Aligned with ledger.

      • Optionalorder?: BranchOrder

        Branch order over the run's commits; absent → every comparison falls back to clocks.

      • OptionalresolutionCommits?: (null | CommitInfo)[]

        Aligned with escalations.

      • reviews: ReviewInfo[]
      • taskFiles: Map<string, TaskFileInfo>

    Returns Map<string, number>