Class HTTPError

Represents a HTTP error

Hierarchy

  • Error
    • HTTPError

Constructors

  • Parameters

    • status: number

      The status code of the response

    • statusText: string

      The status text of the response

    • method: string

      The method of the request that erred

    • url: string

      The url of the request that erred

    • bodyData: Pick<InternalRequest, "files" | "body">

      The unparsed data for the request that errored

    Returns HTTPError

Properties

cause?: unknown
message: string
method: string
name: string
requestBody: RequestBody
stack?: string
status: number
url: string
prepareStackTrace?: ((err, stackTraces) => any)

Type declaration

stackTraceLimit: number

Methods

  • Create .stack property on a target object

    Parameters

    • targetObject: object
    • Optional constructorOpt: Function

    Returns void

Generated using TypeDoc