• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1<html><body>
2<style>
3
4body, h1, h2, h3, div, span, p, pre, a {
5  margin: 0;
6  padding: 0;
7  border: 0;
8  font-weight: inherit;
9  font-style: inherit;
10  font-size: 100%;
11  font-family: inherit;
12  vertical-align: baseline;
13}
14
15body {
16  font-size: 13px;
17  padding: 1em;
18}
19
20h1 {
21  font-size: 26px;
22  margin-bottom: 1em;
23}
24
25h2 {
26  font-size: 24px;
27  margin-bottom: 1em;
28}
29
30h3 {
31  font-size: 20px;
32  margin-bottom: 1em;
33  margin-top: 1em;
34}
35
36pre, code {
37  line-height: 1.5;
38  font-family: Monaco, 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', 'Lucida Console', monospace;
39}
40
41pre {
42  margin-top: 0.5em;
43}
44
45h1, h2, h3, p {
46  font-family: Arial, sans serif;
47}
48
49h1, h2, h3 {
50  border-bottom: solid #CCC 1px;
51}
52
53.toc_element {
54  margin-top: 0.5em;
55}
56
57.firstline {
58  margin-left: 2 em;
59}
60
61.method  {
62  margin-top: 1em;
63  border: solid 1px #CCC;
64  padding: 1em;
65  background: #EEE;
66}
67
68.details {
69  font-weight: bold;
70  font-size: 14px;
71}
72
73</style>
74
75<h1><a href="analytics_v3.html">Google Analytics API</a> . <a href="analytics_v3.management.html">management</a> . <a href="analytics_v3.management.customDimensions.html">customDimensions</a></h1>
76<h2>Instance Methods</h2>
77<p class="toc_element">
78  <code><a href="#get">get(accountId, webPropertyId, customDimensionId)</a></code></p>
79<p class="firstline">Get a custom dimension to which the user has access.</p>
80<p class="toc_element">
81  <code><a href="#insert">insert(accountId, webPropertyId, body)</a></code></p>
82<p class="firstline">Create a new custom dimension.</p>
83<p class="toc_element">
84  <code><a href="#list">list(accountId, webPropertyId, max_results=None, start_index=None)</a></code></p>
85<p class="firstline">Lists custom dimensions to which the user has access.</p>
86<p class="toc_element">
87  <code><a href="#patch">patch(accountId, webPropertyId, customDimensionId, body, ignoreCustomDataSourceLinks=None)</a></code></p>
88<p class="firstline">Updates an existing custom dimension. This method supports patch semantics.</p>
89<p class="toc_element">
90  <code><a href="#update">update(accountId, webPropertyId, customDimensionId, body, ignoreCustomDataSourceLinks=None)</a></code></p>
91<p class="firstline">Updates an existing custom dimension.</p>
92<h3>Method Details</h3>
93<div class="method">
94    <code class="details" id="get">get(accountId, webPropertyId, customDimensionId)</code>
95  <pre>Get a custom dimension to which the user has access.
96
97Args:
98  accountId: string, Account ID for the custom dimension to retrieve. (required)
99  webPropertyId: string, Web property ID for the custom dimension to retrieve. (required)
100  customDimensionId: string, The ID of the custom dimension to retrieve. (required)
101
102Returns:
103  An object of the form:
104
105    { # JSON template for Analytics Custom Dimension.
106      "index": 42, # Index of the custom dimension.
107      "kind": "analytics#customDimension", # Kind value for a custom dimension. Set to "analytics#customDimension". It is a read-only field.
108      "name": "A String", # Name of the custom dimension.
109      "created": "A String", # Time the custom dimension was created.
110      "updated": "A String", # Time the custom dimension was last modified.
111      "webPropertyId": "A String", # Property ID.
112      "active": True or False, # Boolean indicating whether the custom dimension is active.
113      "scope": "A String", # Scope of the custom dimension: HIT, SESSION, USER or PRODUCT.
114      "parentLink": { # Parent link for the custom dimension. Points to the property to which the custom dimension belongs.
115        "href": "A String", # Link to the property to which the custom dimension belongs.
116        "type": "analytics#webproperty", # Type of the parent link. Set to "analytics#webproperty".
117      },
118      "id": "A String", # Custom dimension ID.
119      "selfLink": "A String", # Link for the custom dimension
120      "accountId": "A String", # Account ID.
121    }</pre>
122</div>
123
124<div class="method">
125    <code class="details" id="insert">insert(accountId, webPropertyId, body)</code>
126  <pre>Create a new custom dimension.
127
128Args:
129  accountId: string, Account ID for the custom dimension to create. (required)
130  webPropertyId: string, Web property ID for the custom dimension to create. (required)
131  body: object, The request body. (required)
132    The object takes the form of:
133
134{ # JSON template for Analytics Custom Dimension.
135    "index": 42, # Index of the custom dimension.
136    "kind": "analytics#customDimension", # Kind value for a custom dimension. Set to "analytics#customDimension". It is a read-only field.
137    "name": "A String", # Name of the custom dimension.
138    "created": "A String", # Time the custom dimension was created.
139    "updated": "A String", # Time the custom dimension was last modified.
140    "webPropertyId": "A String", # Property ID.
141    "active": True or False, # Boolean indicating whether the custom dimension is active.
142    "scope": "A String", # Scope of the custom dimension: HIT, SESSION, USER or PRODUCT.
143    "parentLink": { # Parent link for the custom dimension. Points to the property to which the custom dimension belongs.
144      "href": "A String", # Link to the property to which the custom dimension belongs.
145      "type": "analytics#webproperty", # Type of the parent link. Set to "analytics#webproperty".
146    },
147    "id": "A String", # Custom dimension ID.
148    "selfLink": "A String", # Link for the custom dimension
149    "accountId": "A String", # Account ID.
150  }
151
152
153Returns:
154  An object of the form:
155
156    { # JSON template for Analytics Custom Dimension.
157      "index": 42, # Index of the custom dimension.
158      "kind": "analytics#customDimension", # Kind value for a custom dimension. Set to "analytics#customDimension". It is a read-only field.
159      "name": "A String", # Name of the custom dimension.
160      "created": "A String", # Time the custom dimension was created.
161      "updated": "A String", # Time the custom dimension was last modified.
162      "webPropertyId": "A String", # Property ID.
163      "active": True or False, # Boolean indicating whether the custom dimension is active.
164      "scope": "A String", # Scope of the custom dimension: HIT, SESSION, USER or PRODUCT.
165      "parentLink": { # Parent link for the custom dimension. Points to the property to which the custom dimension belongs.
166        "href": "A String", # Link to the property to which the custom dimension belongs.
167        "type": "analytics#webproperty", # Type of the parent link. Set to "analytics#webproperty".
168      },
169      "id": "A String", # Custom dimension ID.
170      "selfLink": "A String", # Link for the custom dimension
171      "accountId": "A String", # Account ID.
172    }</pre>
173</div>
174
175<div class="method">
176    <code class="details" id="list">list(accountId, webPropertyId, max_results=None, start_index=None)</code>
177  <pre>Lists custom dimensions to which the user has access.
178
179Args:
180  accountId: string, Account ID for the custom dimensions to retrieve. (required)
181  webPropertyId: string, Web property ID for the custom dimensions to retrieve. (required)
182  max_results: integer, The maximum number of custom dimensions to include in this response.
183  start_index: integer, An index of the first entity to retrieve. Use this parameter as a pagination mechanism along with the max-results parameter.
184
185Returns:
186  An object of the form:
187
188    { # A custom dimension collection lists Analytics custom dimensions to which the user has access. Each resource in the collection corresponds to a single Analytics custom dimension.
189    "username": "A String", # Email ID of the authenticated user
190    "kind": "analytics#customDimensions", # Collection type.
191    "items": [ # Collection of custom dimensions.
192      { # JSON template for Analytics Custom Dimension.
193          "index": 42, # Index of the custom dimension.
194          "kind": "analytics#customDimension", # Kind value for a custom dimension. Set to "analytics#customDimension". It is a read-only field.
195          "name": "A String", # Name of the custom dimension.
196          "created": "A String", # Time the custom dimension was created.
197          "updated": "A String", # Time the custom dimension was last modified.
198          "webPropertyId": "A String", # Property ID.
199          "active": True or False, # Boolean indicating whether the custom dimension is active.
200          "scope": "A String", # Scope of the custom dimension: HIT, SESSION, USER or PRODUCT.
201          "parentLink": { # Parent link for the custom dimension. Points to the property to which the custom dimension belongs.
202            "href": "A String", # Link to the property to which the custom dimension belongs.
203            "type": "analytics#webproperty", # Type of the parent link. Set to "analytics#webproperty".
204          },
205          "id": "A String", # Custom dimension ID.
206          "selfLink": "A String", # Link for the custom dimension
207          "accountId": "A String", # Account ID.
208        },
209    ],
210    "itemsPerPage": 42, # The maximum number of resources the response can contain, regardless of the actual number of resources returned. Its value ranges from 1 to 1000 with a value of 1000 by default, or otherwise specified by the max-results query parameter.
211    "previousLink": "A String", # Link to previous page for this custom dimension collection.
212    "startIndex": 42, # The starting index of the resources, which is 1 by default or otherwise specified by the start-index query parameter.
213    "nextLink": "A String", # Link to next page for this custom dimension collection.
214    "totalResults": 42, # The total number of results for the query, regardless of the number of results in the response.
215  }</pre>
216</div>
217
218<div class="method">
219    <code class="details" id="patch">patch(accountId, webPropertyId, customDimensionId, body, ignoreCustomDataSourceLinks=None)</code>
220  <pre>Updates an existing custom dimension. This method supports patch semantics.
221
222Args:
223  accountId: string, Account ID for the custom dimension to update. (required)
224  webPropertyId: string, Web property ID for the custom dimension to update. (required)
225  customDimensionId: string, Custom dimension ID for the custom dimension to update. (required)
226  body: object, The request body. (required)
227    The object takes the form of:
228
229{ # JSON template for Analytics Custom Dimension.
230    "index": 42, # Index of the custom dimension.
231    "kind": "analytics#customDimension", # Kind value for a custom dimension. Set to "analytics#customDimension". It is a read-only field.
232    "name": "A String", # Name of the custom dimension.
233    "created": "A String", # Time the custom dimension was created.
234    "updated": "A String", # Time the custom dimension was last modified.
235    "webPropertyId": "A String", # Property ID.
236    "active": True or False, # Boolean indicating whether the custom dimension is active.
237    "scope": "A String", # Scope of the custom dimension: HIT, SESSION, USER or PRODUCT.
238    "parentLink": { # Parent link for the custom dimension. Points to the property to which the custom dimension belongs.
239      "href": "A String", # Link to the property to which the custom dimension belongs.
240      "type": "analytics#webproperty", # Type of the parent link. Set to "analytics#webproperty".
241    },
242    "id": "A String", # Custom dimension ID.
243    "selfLink": "A String", # Link for the custom dimension
244    "accountId": "A String", # Account ID.
245  }
246
247  ignoreCustomDataSourceLinks: boolean, Force the update and ignore any warnings related to the custom dimension being linked to a custom data source / data set.
248
249Returns:
250  An object of the form:
251
252    { # JSON template for Analytics Custom Dimension.
253      "index": 42, # Index of the custom dimension.
254      "kind": "analytics#customDimension", # Kind value for a custom dimension. Set to "analytics#customDimension". It is a read-only field.
255      "name": "A String", # Name of the custom dimension.
256      "created": "A String", # Time the custom dimension was created.
257      "updated": "A String", # Time the custom dimension was last modified.
258      "webPropertyId": "A String", # Property ID.
259      "active": True or False, # Boolean indicating whether the custom dimension is active.
260      "scope": "A String", # Scope of the custom dimension: HIT, SESSION, USER or PRODUCT.
261      "parentLink": { # Parent link for the custom dimension. Points to the property to which the custom dimension belongs.
262        "href": "A String", # Link to the property to which the custom dimension belongs.
263        "type": "analytics#webproperty", # Type of the parent link. Set to "analytics#webproperty".
264      },
265      "id": "A String", # Custom dimension ID.
266      "selfLink": "A String", # Link for the custom dimension
267      "accountId": "A String", # Account ID.
268    }</pre>
269</div>
270
271<div class="method">
272    <code class="details" id="update">update(accountId, webPropertyId, customDimensionId, body, ignoreCustomDataSourceLinks=None)</code>
273  <pre>Updates an existing custom dimension.
274
275Args:
276  accountId: string, Account ID for the custom dimension to update. (required)
277  webPropertyId: string, Web property ID for the custom dimension to update. (required)
278  customDimensionId: string, Custom dimension ID for the custom dimension to update. (required)
279  body: object, The request body. (required)
280    The object takes the form of:
281
282{ # JSON template for Analytics Custom Dimension.
283    "index": 42, # Index of the custom dimension.
284    "kind": "analytics#customDimension", # Kind value for a custom dimension. Set to "analytics#customDimension". It is a read-only field.
285    "name": "A String", # Name of the custom dimension.
286    "created": "A String", # Time the custom dimension was created.
287    "updated": "A String", # Time the custom dimension was last modified.
288    "webPropertyId": "A String", # Property ID.
289    "active": True or False, # Boolean indicating whether the custom dimension is active.
290    "scope": "A String", # Scope of the custom dimension: HIT, SESSION, USER or PRODUCT.
291    "parentLink": { # Parent link for the custom dimension. Points to the property to which the custom dimension belongs.
292      "href": "A String", # Link to the property to which the custom dimension belongs.
293      "type": "analytics#webproperty", # Type of the parent link. Set to "analytics#webproperty".
294    },
295    "id": "A String", # Custom dimension ID.
296    "selfLink": "A String", # Link for the custom dimension
297    "accountId": "A String", # Account ID.
298  }
299
300  ignoreCustomDataSourceLinks: boolean, Force the update and ignore any warnings related to the custom dimension being linked to a custom data source / data set.
301
302Returns:
303  An object of the form:
304
305    { # JSON template for Analytics Custom Dimension.
306      "index": 42, # Index of the custom dimension.
307      "kind": "analytics#customDimension", # Kind value for a custom dimension. Set to "analytics#customDimension". It is a read-only field.
308      "name": "A String", # Name of the custom dimension.
309      "created": "A String", # Time the custom dimension was created.
310      "updated": "A String", # Time the custom dimension was last modified.
311      "webPropertyId": "A String", # Property ID.
312      "active": True or False, # Boolean indicating whether the custom dimension is active.
313      "scope": "A String", # Scope of the custom dimension: HIT, SESSION, USER or PRODUCT.
314      "parentLink": { # Parent link for the custom dimension. Points to the property to which the custom dimension belongs.
315        "href": "A String", # Link to the property to which the custom dimension belongs.
316        "type": "analytics#webproperty", # Type of the parent link. Set to "analytics#webproperty".
317      },
318      "id": "A String", # Custom dimension ID.
319      "selfLink": "A String", # Link for the custom dimension
320      "accountId": "A String", # Account ID.
321    }</pre>
322</div>
323
324</body></html>