code: private Map<String, String> getQueryParams(Request request) {
          final Map<String, String> queryParams = new HashMap<>();
          request.queryMap().toMap().forEach((k, v) -> {
              queryParams.put(k, v[0]);
          });
          return queryParams;
      }
docs: Gets query parameters from request, ignoring duplicates. This
  is different from Spark's queryMap().toMap()
  
  @param request the spark request
  @return the params as a {@link Map<String, String>}