gatelineAPI reference
  • Wire the runner-agent poll/claim/report surface. Returns undefined when no token is configured (or no callback is wired to serve it) — the routes then never exist; an unauthenticated poll surface would let anyone who can reach the port claim and report dispatch work.

    Parameters

    • opts: {
          callback: undefined | RunnerCallback;
          log: (line: string) => void;
          now?: () => number;
          repoDir?: string;
          token: undefined | string;
      }
      • callback: undefined | RunnerCallback
      • log: (line: string) => void
      • Optionalnow?: () => number

        Injectable clock for deterministic claim-TTL tests (review-03.md F1); defaults to Date.now. Production callers never pass this.

      • OptionalrepoDir?: string

        Repo whose branches the intents reference, for base-OID augmentation (ADR-2) and origin-URL resolution (review-03.md F6). Optional: without it, intents are served with baseOid left as the callback provided (normally undefined), and repoUrl() resolves to null.

      • token: undefined | string

    Returns undefined | RunnerApi