ga_filter_update_filter_link: Update an existing profile filter link. Patch semantics...

Description Usage Arguments See Also Examples

View source: R/filter_management.R

Description

Update an existing profile filter link. Patch semantics supported

Usage

1
2
3
4
5
6
7
8
ga_filter_update_filter_link(
  viewFilterLink,
  accountId,
  webPropertyId,
  viewId,
  linkId,
  method = c("PUT", "PATCH")
)

Arguments

viewFilterLink

The profileFilterLink object

accountId

Account Id of the account that contains the filter

webPropertyId

Web property Id to which the profile filter link belongs

viewId

View Id to which the profile filter link belongs

linkId

The id of the profile filter link to be updated

method

PUT by default. Supports patch semantics when set to PATCH

See Also

https://developers.google.com/analytics/devguides/config/mgmt/v3/mgmtReference/management/profileFilterLinks

Other managementAPI functions: ga_experiment_list(), ga_experiment(), ga_filter_add(), ga_filter_apply_to_view(), ga_filter_update(), ga_segment_list()

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
## Not run: 

# create a filter object
Filter <- list(
 name = 'googleAnalyticsR test: Exclude Internal Traffic',
 type = 'EXCLUDE',
 excludeDetails = list(
   field = 'GEO_IP_ADDRESS',
   matchType = 'EQUAL',
   expressionValue = '199.04.123.1',
   caseSensitive = 'False'
   )
 )
 
 # link Filter to a View
 response <- ga_filter_add(Filter, 
                           accountId = 12345, 
                           webPropertyId = "UA-12345-1", 
                           viewId = 654321, 
                           linkFilter = TRUE)
                           
# create Filter patch to move existing filter up to rank 1
viewFilterLink <- list(rank = 1)

# use the linkId given in response$id to update to new rank 1
response2 <- ga_filter_update_filter_link(viewFilterLink, 
                                          accountId = 12345, 
                                          webPropertyId = "UA-12345-1", 
                                          viewId = 654321,  
                                          linkId = response$id)


## End(Not run)

MarkEdmondson1234/googleAnalyticsR_public documentation built on Aug. 30, 2020, 7:28 a.m.