R/customMetrics.R

Defines functions list_custom_metrics get_custom_metric

Documented in get_custom_metric list_custom_metrics

#' @template get_customMetrics
#' @include mgmt.R
#' @export
get_custom_metric <- function(accountId, webPropertyId, customMetricId, token) {
    path <- sprintf("management/accounts/%s/webproperties/%s/customMetrics/%s",
                    accountId, webPropertyId, customMetricId)
    get_mgmt(path, token)
}

#' @template list_customMetrics
#' @include mgmt.R
#' @export
list_custom_metrics <- function(accountId, webPropertyId, start.index = NULL, max.results = NULL, token) {
    path <- sprintf("management/accounts/%s/webproperties/%s/customMetrics",
                    accountId, webPropertyId)
    list_mgmt(path, list(start.index = start.index, max.results = max.results), token)
}

Try the RGA package in your browser

Any scripts or data that you put into this service are public.

RGA documentation built on May 2, 2019, 6:47 a.m.