Type Alias OpenAPIDefaultErrorMapperFunction
OpenAPIDefaultErrorMapperFunction: (
data: { error: string; status: HTTPErrorCode },
) => Promise<WebResponse>
data: { error: string; status: HTTPErrorCode },
) => Promise<WebResponse>
Type declaration
- (data: { error: string; status: HTTPErrorCode }): Promise<WebResponse>
Parameters
- data: { error: string; status: HTTPErrorCode }
Returns Promise<WebResponse>
Signature for a x-webhare-default-error-mapper function. Note that this callback doesn't receive the RestRequest as we may not have evaluated the route when we invoke the error handler