Class TierError

Error subclass raised for any error returned by the API. Should not be instantiated directly.

Hierarchy

  • Error
    • TierError

Constructors

  • Parameters

    • path: string
    • reqBody: any
    • status: number
    • resBody: any
    • Optional er: any

    Returns TierError

Properties

cause?: Error

An underlying system error or other cause.

code?: string

The code field in the ErrorResponse

message: string
name: string
path: string

The API endpoint that was requested

requestData: any

The data that was sent to the API endpoint. Will be a parsed JavaScript object unless the request JSON was invalid, in which case it will be a string.

responseData: any

The HTTP response body. Will be a parsed JavaScript object unless the response JSON was invalid, in which case it will be a string.

stack?: string
status: number

The HTTP response status code returned

prepareStackTrace?: ((err: Error, stackTraces: CallSite[]) => any)

Type declaration

stackTraceLimit: number

Methods

  • Create .stack property on a target object

    Parameters

    • targetObject: object
    • Optional constructorOpt: Function

    Returns void

Generated using TypeDoc