docs: public static final Status parseResponseStatus(int statusCode, @Nullable Throwable error) {
      String message = null;
  
      if (error != null) {
        message = error.getMessage();
        if (message == null) {
          message = error.getClass().getSimpleName();
        }
      }
  
      // set status according to response
      if (statusCode == 0) {
        return Status.UNKNOWN.withDescription(message);
      } else {
        if (statusCode >= 200 && statusCode < 400) {
          return Status.OK;
        } else {
          // error code, try parse it
          switch (statusCode) {
            case 100:
              return STATUS_100;
            case 101:
              return STATUS_101;
            case 400:
              return Status.INVALID_ARGUMENT.withDescription(message);
            case 401:
              return Status.UNAUTHENTICATED.withDescription(message);
            case 402:
              return STATUS_402;
            case 403:
              return Status.PERMISSION_DENIED.withDescription(message);
            case 404:
              return Status.NOT_FOUND.withDescription(message);
            case 405:
              return STATUS_405;
            case 406:
              return STATUS_406;
            case 407:
              return STATUS_407;
            case 408:
              return STATUS_408;
            case 409:
              return STATUS_409;
            case 410:
              return STATUS_410;
            case 411:
              return STATUS_411;
            case 412:
              return STATUS_412;
            case 413:
              return STATUS_413;
            case 414:
              return STATUS_414;
            case 415:
              return STATUS_415;
            case 416:
              return STATUS_416;
            case 417:
              return STATUS_417;
            case 429:
              return Status.RESOURCE_EXHAUSTED.withDescription(message);
            case 500:
              return STATUS_500;
            case 501:
              return Status.UNIMPLEMENTED.withDescription(message);
            case 502:
              return STATUS_502;
            case 503:
              return Status.UNAVAILABLE.withDescription(message);
            case 504:
              return Status.DEADLINE_EXCEEDED.withDescription(message);
            case 505:
              return STATUS_505;
            default:
              return Status.UNKNOWN.withDescription(message);
          }
        }
      }
    }