get_ga_metadata {metricminer}R Documentation

Get metadata associated Google Analytics property

Description

This is a function to get the Google Analytics accounts that this user has access to

Usage

get_ga_metadata(property_id, token = NULL)

Arguments

property_id

a GA property. Looks like '123456789' Can be obtained from running 'get_ga_properties()'

token

credentials for access to Google using OAuth. 'authorize("google")'

Value

A list showing the metadata types available for the Google Analytics property. This can be used to craft an API request.

Examples

## Not run: 

authorize("google")
accounts <- get_ga_user()

properties_list <- get_ga_properties(account_id = accounts$id[1])

property_id <- gsub("properties/", "", properties_list$name[1])
property_metadata <- get_ga_metadata(property_id = property_id)

## End(Not run)

[Package metricminer version 0.5.1 Index]