Skip to content
Français

CustomReporterOptions

import type { CustomReporterOptions } from "@elie-laloum/outpost";
  • capacityOptional
    number | undefined
    Maximum waiting events in the reporter queue, default 1024; overflow drops newest deliveries and makes flush reject.
  • deliveryTimeoutMsOptional
    number | undefined
    Maximum asynchronous handler wait in milliseconds, default 5000; timeout disables further deliveries and makes flush reject.
  • onErrorOptional
    ((error: unknown, event: AgentObservation) => void | Promise<void>) | undefined
    Called for each failed handler with its error and event; diagnostic failures are isolated and the first handler failure remains observable through flush().
export interface CustomReporterOptions {
  readonly capacity?: number;
  readonly deliveryTimeoutMs?: number;
  readonly onError?: (
    error: unknown,
    event: AgentObservation,
  ) => void | Promise<void>;
}