Hierarchy

  • Error
    • ApiError

Implements

Constructors

  • Parameters

    • error: string
    • errcode: ErrCode = ErrCode.Unknown
    • statusCode: number = -1
    • additionalContent: Record<string, unknown> = {}

    Returns ApiError

Properties

additionalContent: Record<string, unknown> = {}
cause?: unknown
errcode: ErrCode = ErrCode.Unknown
error: string
message: string
name: string
stack?: string
statusCode: number = -1
prepareStackTrace?: ((err, stackTraces) => any)

Optional override for formatting stack traces

Type declaration

stackTraceLimit: number

Accessors

  • get jsonBody(): {
        errcode: string;
        error: string;
    }
  • Returns {
        errcode: string;
        error: string;
    }

    • errcode: string
    • error: string

Methods

  • Create .stack property on a target object

    Parameters

    • targetObject: object
    • Optional constructorOpt: Function

    Returns void

Generated using TypeDoc