diff --git a/R/matomoquery.R b/R/matomoquery.R
index d9fd57a..8a8aad4 100644
--- a/R/matomoquery.R
+++ b/R/matomoquery.R
@@ -34,7 +34,7 @@
                              siteId,
                              period = "month",
                              date = "last16",
-                             filter_limit = 100,
+                             filter_limit = 500,
                              removeFirst = FALSE,
                              removeLast = FALSE,
                              accessToken = getAccessToken(matomoUrl),
@@ -55,9 +55,8 @@
     url = matomoUrl,
     query = list(
       module = "API",
-      method = "API.getBulkRequest",
+      method = getMethod,
       format = "json",
-      "urls[0]" = paste0("method=", getMethod),
       idSite = paste0(siteId, collapse = ","),
       date = date,
       period = period,
@@ -86,31 +85,36 @@
   }
 
   json <- httr::content(res, "text", encoding = "UTF-8")
-  l <- jsonlite::fromJSON(json, simplifyVector = F)
 
-  if (!is.null(l[[1]]$result) && l[[1]]$result == "error") {
-    stop(l[[1]]$message, call. = FALSE)
-  }
-
-  df <- (if (length(siteId) == 1) {
-    bind_rows(l[[1]], .id=period) %>%
-      head(if(removeLast) -1 else filter_limit) %>%
-      tail(if(removeFirst) -1 else filter_limit) %>%
-      mutate(site_id=siteId)
-  } else {
-    df <- bind_rows(l[[1]][[1]], .id=period) %>%
-      head(if(removeLast) -1 else filter_limit) %>%
-      tail(if(removeFirst) -1 else filter_limit) %>%
-      mutate(site_id=siteId[1])
-    for (i in 2:length(l[[1]])) {
-      df <- bind_rows(df,
-                      bind_rows(l[[1]][[i]], .id=period) %>%
-                        head(if(removeLast) -1 else filter_limit) %>%
-                        tail(if(removeFirst) -1 else filter_limit) %>%
-                        mutate(site_id=siteId[i]))
+  if (period=="range") {
+    df <- if (length(siteId) == 1) {
+      jsonlite::fromJSON(json) %>%
+        mutate(site_id=siteId)
+    } else {
+      bind_rows(jsonlite::fromJSON(json), .id = "site_id")
     }
-    df
-  })
+  } else {
+    l <- jsonlite::fromJSON(json)
+    df <- (if (length(siteId) == 1) {
+      bind_rows(l, .id=period) %>%
+        head(if(removeLast) -1 else filter_limit) %>%
+        tail(if(removeFirst) -1 else filter_limit) %>%
+        mutate(site_id=siteId)
+    } else {
+      df <- bind_rows(l[[1]], .id=period) %>%
+        head(if(removeLast) -1 else filter_limit) %>%
+        tail(if(removeFirst) -1 else filter_limit) %>%
+        mutate(site_id=siteId[1])
+      for (i in 2:length(l)) {
+        df <- bind_rows(df,
+                        bind_rows(l[[i]], .id=period) %>%
+                          head(if(removeLast) -1 else filter_limit) %>%
+                          tail(if(removeFirst) -1 else filter_limit) %>%
+                          mutate(site_id=siteId[i]))
+      }
+      df
+    })
+  }
 
   if("day" %in% colnames(df) | "month" %in% colnames(df) | "ye" %in% colnames(df)) {
     df <- df %>%
@@ -125,7 +129,7 @@
           day
         else
           stop(paste0("unsupported period parameter: '", period, "'"), call. = FALSE)
-      ))
+      , optional = TRUE))
   }
   return(df)
 }
