code: public JSONObject getLogs(int offset, int length, LogType logType, RequestOptions requestOptions) throws AlgoliaException {
      String type = null;
      switch (logType) {
        case LOG_BUILD:
          type = "build";
          break;
        case LOG_QUERY:
          type = "query";
          break;
        case LOG_ERROR:
          type = "error";
          break;
        case LOG_ALL:
          type = "all";
          break;
      }
      return getRequest("/1/logs?offset=" + offset + "&length=" + length + "&type=" + type, false, requestOptions);
    }
docs: Return last logs entries.
  
  @param offset         Specify the first entry to retrieve (0-based, 0 is the most recent log entry).
  @param length         Specify the maximum number of entries to retrieve starting at offset. Maximum allowed value: 1000.
  @param logType        Specify the type of log to retrieve
  @param requestOptions Options to pass to this request