HttpResponse.code

The HTTP response code, if the response was completed, or some value < 100 if it was aborted or failed.

Code 0 - initial value, nothing happened Code 1 - you called request.abort Code 2 - connection refused Code 3 - connection succeeded, but server disconnected early Code 4 - server sent corrupted response (or this code has a bug and processed it wrong) Code 5 - request timed out

Code >= 100 - a HTTP response

struct HttpResponse
int code;

Meta