Thrown when a client request fails, either because the server responded with an error status or because the request could not be sent.

Hierarchy

  • Error
    • RequestError

Constructors

Properties

Constructors

  • Parameters

    • message: string
    • options: {
          error: unknown;
          status?: number;
      }
      • error: unknown
      • Optional status?: number

    Returns RequestError

Properties

error: unknown

The underlying cause: the failed response's status text or the original error.

status?: number

HTTP status of the failed response; undefined when no response was received.

Generated using TypeDoc