Skip to main content

index/interfaces/NetworkErrorServerAnswer.md

What a server answered a failed request with, as a NetworkError carries it.

The launchpad backend (NestJS, GlobalExceptionFilter) answers an error with { status, error: true, message } (an HttpException: validation failures, sendResult refusals, guards) or { statusCode, message } (its CustomError, an upload over 4 MB, an unhandled 500). message is the text the backend means the user to read.

Since​

9.0.0

Properties​

PropertyTypeDescription
body?unknownThe whole body as received: parsed JSON, or the text of a non-JSON answer (a proxy's HTML).
details?unknownThe body's details, when it has them (the launchpad backend sends none today).
serverError?stringThe body's error when it is a string (NestJS's default "Bad Request", another host's error name). The launchpad backend sends error: true, which is no text: then this is absent and the boolean is in body.
serverMessage?stringThe body's message. An array of strings (NestJS class-validator messages) is joined with ,, exactly as String(array) shows it.