Stone.js API
    Preparing search index...

    Thrown when authentication fails (missing/invalid/expired token). Carries statusCode = 401 so any HTTP error handler maps it to 401 Unauthorized, while the error itself stays agnostic.

    Hierarchy

    • IntegrationError
      • AuthenticationError
    Index
    • Parameters

      • message: string
      • options: ErrorOptions = {}

      Returns AuthenticationError

    cause?: Error
    code?: string
    metadata?: unknown
    statusCode: 401
    • Converts the error to a formatted string representation.

      Parameters

      • Optionalmultiline: boolean

        Determine if output value must be multiline or not.

      Returns string

      A formatted error string.

    • Create a RuntimeError.

      Type Parameters

      • T extends RuntimeError = RuntimeError

      Parameters

      • message: string
      • Optionaloptions: ErrorOptions

        The options to create a RuntimeError.

      Returns T

      A new RuntimeError instance.