Skip to content
Alchemy Logo

ServerError

Defined in: packages/common/src/errors/ServerError.ts:6

Error class representing a "Server Error" error, typically thrown when a server request fails.

new ServerError(
   message,
   status,
   cause?): ServerError;

Defined in: packages/common/src/errors/ServerError.ts:16

Initializes a new instance of the error message with a default message indicating that no chain was supplied to the client.

Parameters

ParameterTypeDescription

message

string

The error message.

status

number

The HTTP status code of the error.

cause?

Error

The cause of the error.

Returns

ServerError

Overrides

BaseError.constructor

PropertyTypeDefault value

name

string

"ServerError"

version

string

VERSION

Was this page helpful?