Skip to content
Français

WorkflowCostUnavailable

import { WorkflowCostUnavailable } from "@elie-laloum/outpost/workflows";

Raised when a cost budget cannot measure every reported token because usage, model attribution or a matching price is missing. Stops running attempts even if an attempt limit exists; workflow terminationCode is usage-unavailable.

Complete example and detailed rules.

  • dimensionRequired
    "cost"
    Always cost, identifying unavailable monetary accounting.
  • nameRequired
    string
    Error class name used to distinguish this failure from other JavaScript errors.
  • messageRequired
    string
    Human-readable explanation of the failure.
  • stackOptional
    string | undefined
    JavaScript stack trace for the error, when available.
  • causeOptional
    unknown
    Underlying failure this error wraps; quotaFault() and unavailableFault() follow this chain.
export declare class WorkflowCostUnavailable extends Error {
  readonly dimension = "cost";
  constructor();
}