• 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.accountUserLinks.html">accountUserLinks</a></h1>
76<h2>Instance Methods</h2>
77<p class="toc_element">
78  <code><a href="#delete">delete(accountId, linkId)</a></code></p>
79<p class="firstline">Removes a user from the given account.</p>
80<p class="toc_element">
81  <code><a href="#insert">insert(accountId, body)</a></code></p>
82<p class="firstline">Adds a new user to the given account.</p>
83<p class="toc_element">
84  <code><a href="#list">list(accountId, max_results=None, start_index=None)</a></code></p>
85<p class="firstline">Lists account-user links for a given account.</p>
86<p class="toc_element">
87  <code><a href="#update">update(accountId, linkId, body)</a></code></p>
88<p class="firstline">Updates permissions for an existing user on the given account.</p>
89<h3>Method Details</h3>
90<div class="method">
91    <code class="details" id="delete">delete(accountId, linkId)</code>
92  <pre>Removes a user from the given account.
93
94Args:
95  accountId: string, Account ID to delete the user link for. (required)
96  linkId: string, Link ID to delete the user link for. (required)
97</pre>
98</div>
99
100<div class="method">
101    <code class="details" id="insert">insert(accountId, body)</code>
102  <pre>Adds a new user to the given account.
103
104Args:
105  accountId: string, Account ID to create the user link for. (required)
106  body: object, The request body. (required)
107    The object takes the form of:
108
109{ # JSON template for an Analytics Entity-User Link. Returns permissions that a user has for an entity.
110    "kind": "analytics#entityUserLink", # Resource type for entity user link.
111    "entity": { # Entity for this link. It can be an account, a web property, or a view (profile).
112      "accountRef": { # JSON template for a linked account. # Account for this link.
113        "kind": "analytics#accountRef", # Analytics account reference.
114        "href": "A String", # Link for this account.
115        "id": "A String", # Account ID.
116        "name": "A String", # Account name.
117      },
118      "profileRef": { # JSON template for a linked view (profile). # View (Profile) for this link.
119        "kind": "analytics#profileRef", # Analytics view (profile) reference.
120        "name": "A String", # Name of this view (profile).
121        "internalWebPropertyId": "A String", # Internal ID for the web property to which this view (profile) belongs.
122        "href": "A String", # Link for this view (profile).
123        "webPropertyId": "A String", # Web property ID of the form UA-XXXXX-YY to which this view (profile) belongs.
124        "id": "A String", # View (Profile) ID.
125        "accountId": "A String", # Account ID to which this view (profile) belongs.
126      },
127      "webPropertyRef": { # JSON template for a web property reference. # Web property for this link.
128        "kind": "analytics#webPropertyRef", # Analytics web property reference.
129        "name": "A String", # Name of this web property.
130        "internalWebPropertyId": "A String", # Internal ID for this web property.
131        "href": "A String", # Link for this web property.
132        "id": "A String", # Web property ID of the form UA-XXXXX-YY.
133        "accountId": "A String", # Account ID to which this web property belongs.
134      },
135    },
136    "userRef": { # JSON template for a user reference. # User reference.
137      "kind": "analytics#userRef",
138      "email": "A String", # Email ID of this user.
139      "id": "A String", # User ID.
140    },
141    "id": "A String", # Entity user link ID
142    "selfLink": "A String", # Self link for this resource.
143    "permissions": { # Permissions the user has for this entity.
144      "local": [ # Permissions that a user has been assigned at this very level. Does not include any implied or inherited permissions. Local permissions are modifiable.
145        "A String",
146      ],
147      "effective": [ # Effective permissions represent all the permissions that a user has for this entity. These include any implied permissions (e.g., EDIT implies VIEW) or inherited permissions from the parent entity. Effective permissions are read-only.
148        "A String",
149      ],
150    },
151  }
152
153
154Returns:
155  An object of the form:
156
157    { # JSON template for an Analytics Entity-User Link. Returns permissions that a user has for an entity.
158      "kind": "analytics#entityUserLink", # Resource type for entity user link.
159      "entity": { # Entity for this link. It can be an account, a web property, or a view (profile).
160        "accountRef": { # JSON template for a linked account. # Account for this link.
161          "kind": "analytics#accountRef", # Analytics account reference.
162          "href": "A String", # Link for this account.
163          "id": "A String", # Account ID.
164          "name": "A String", # Account name.
165        },
166        "profileRef": { # JSON template for a linked view (profile). # View (Profile) for this link.
167          "kind": "analytics#profileRef", # Analytics view (profile) reference.
168          "name": "A String", # Name of this view (profile).
169          "internalWebPropertyId": "A String", # Internal ID for the web property to which this view (profile) belongs.
170          "href": "A String", # Link for this view (profile).
171          "webPropertyId": "A String", # Web property ID of the form UA-XXXXX-YY to which this view (profile) belongs.
172          "id": "A String", # View (Profile) ID.
173          "accountId": "A String", # Account ID to which this view (profile) belongs.
174        },
175        "webPropertyRef": { # JSON template for a web property reference. # Web property for this link.
176          "kind": "analytics#webPropertyRef", # Analytics web property reference.
177          "name": "A String", # Name of this web property.
178          "internalWebPropertyId": "A String", # Internal ID for this web property.
179          "href": "A String", # Link for this web property.
180          "id": "A String", # Web property ID of the form UA-XXXXX-YY.
181          "accountId": "A String", # Account ID to which this web property belongs.
182        },
183      },
184      "userRef": { # JSON template for a user reference. # User reference.
185        "kind": "analytics#userRef",
186        "email": "A String", # Email ID of this user.
187        "id": "A String", # User ID.
188      },
189      "id": "A String", # Entity user link ID
190      "selfLink": "A String", # Self link for this resource.
191      "permissions": { # Permissions the user has for this entity.
192        "local": [ # Permissions that a user has been assigned at this very level. Does not include any implied or inherited permissions. Local permissions are modifiable.
193          "A String",
194        ],
195        "effective": [ # Effective permissions represent all the permissions that a user has for this entity. These include any implied permissions (e.g., EDIT implies VIEW) or inherited permissions from the parent entity. Effective permissions are read-only.
196          "A String",
197        ],
198      },
199    }</pre>
200</div>
201
202<div class="method">
203    <code class="details" id="list">list(accountId, max_results=None, start_index=None)</code>
204  <pre>Lists account-user links for a given account.
205
206Args:
207  accountId: string, Account ID to retrieve the user links for. (required)
208  max_results: integer, The maximum number of account-user links to include in this response.
209  start_index: integer, An index of the first account-user link to retrieve. Use this parameter as a pagination mechanism along with the max-results parameter.
210
211Returns:
212  An object of the form:
213
214    { # An entity user link collection provides a list of Analytics ACL links Each resource in this collection corresponds to a single link.
215    "kind": "analytics#entityUserLinks", # Collection type.
216    "items": [ # A list of entity user links.
217      { # JSON template for an Analytics Entity-User Link. Returns permissions that a user has for an entity.
218          "kind": "analytics#entityUserLink", # Resource type for entity user link.
219          "entity": { # Entity for this link. It can be an account, a web property, or a view (profile).
220            "accountRef": { # JSON template for a linked account. # Account for this link.
221              "kind": "analytics#accountRef", # Analytics account reference.
222              "href": "A String", # Link for this account.
223              "id": "A String", # Account ID.
224              "name": "A String", # Account name.
225            },
226            "profileRef": { # JSON template for a linked view (profile). # View (Profile) for this link.
227              "kind": "analytics#profileRef", # Analytics view (profile) reference.
228              "name": "A String", # Name of this view (profile).
229              "internalWebPropertyId": "A String", # Internal ID for the web property to which this view (profile) belongs.
230              "href": "A String", # Link for this view (profile).
231              "webPropertyId": "A String", # Web property ID of the form UA-XXXXX-YY to which this view (profile) belongs.
232              "id": "A String", # View (Profile) ID.
233              "accountId": "A String", # Account ID to which this view (profile) belongs.
234            },
235            "webPropertyRef": { # JSON template for a web property reference. # Web property for this link.
236              "kind": "analytics#webPropertyRef", # Analytics web property reference.
237              "name": "A String", # Name of this web property.
238              "internalWebPropertyId": "A String", # Internal ID for this web property.
239              "href": "A String", # Link for this web property.
240              "id": "A String", # Web property ID of the form UA-XXXXX-YY.
241              "accountId": "A String", # Account ID to which this web property belongs.
242            },
243          },
244          "userRef": { # JSON template for a user reference. # User reference.
245            "kind": "analytics#userRef",
246            "email": "A String", # Email ID of this user.
247            "id": "A String", # User ID.
248          },
249          "id": "A String", # Entity user link ID
250          "selfLink": "A String", # Self link for this resource.
251          "permissions": { # Permissions the user has for this entity.
252            "local": [ # Permissions that a user has been assigned at this very level. Does not include any implied or inherited permissions. Local permissions are modifiable.
253              "A String",
254            ],
255            "effective": [ # Effective permissions represent all the permissions that a user has for this entity. These include any implied permissions (e.g., EDIT implies VIEW) or inherited permissions from the parent entity. Effective permissions are read-only.
256              "A String",
257            ],
258          },
259        },
260    ],
261    "itemsPerPage": 42, # The maximum number of entries the response can contain, regardless of the actual number of entries returned. Its value ranges from 1 to 1000 with a value of 1000 by default, or otherwise specified by the max-results query parameter.
262    "previousLink": "A String", # Previous link for this account collection.
263    "startIndex": 42, # The starting index of the entries, which is 1 by default or otherwise specified by the start-index query parameter.
264    "nextLink": "A String", # Next link for this account collection.
265    "totalResults": 42, # The total number of results for the query, regardless of the number of results in the response.
266  }</pre>
267</div>
268
269<div class="method">
270    <code class="details" id="update">update(accountId, linkId, body)</code>
271  <pre>Updates permissions for an existing user on the given account.
272
273Args:
274  accountId: string, Account ID to update the account-user link for. (required)
275  linkId: string, Link ID to update the account-user link for. (required)
276  body: object, The request body. (required)
277    The object takes the form of:
278
279{ # JSON template for an Analytics Entity-User Link. Returns permissions that a user has for an entity.
280    "kind": "analytics#entityUserLink", # Resource type for entity user link.
281    "entity": { # Entity for this link. It can be an account, a web property, or a view (profile).
282      "accountRef": { # JSON template for a linked account. # Account for this link.
283        "kind": "analytics#accountRef", # Analytics account reference.
284        "href": "A String", # Link for this account.
285        "id": "A String", # Account ID.
286        "name": "A String", # Account name.
287      },
288      "profileRef": { # JSON template for a linked view (profile). # View (Profile) for this link.
289        "kind": "analytics#profileRef", # Analytics view (profile) reference.
290        "name": "A String", # Name of this view (profile).
291        "internalWebPropertyId": "A String", # Internal ID for the web property to which this view (profile) belongs.
292        "href": "A String", # Link for this view (profile).
293        "webPropertyId": "A String", # Web property ID of the form UA-XXXXX-YY to which this view (profile) belongs.
294        "id": "A String", # View (Profile) ID.
295        "accountId": "A String", # Account ID to which this view (profile) belongs.
296      },
297      "webPropertyRef": { # JSON template for a web property reference. # Web property for this link.
298        "kind": "analytics#webPropertyRef", # Analytics web property reference.
299        "name": "A String", # Name of this web property.
300        "internalWebPropertyId": "A String", # Internal ID for this web property.
301        "href": "A String", # Link for this web property.
302        "id": "A String", # Web property ID of the form UA-XXXXX-YY.
303        "accountId": "A String", # Account ID to which this web property belongs.
304      },
305    },
306    "userRef": { # JSON template for a user reference. # User reference.
307      "kind": "analytics#userRef",
308      "email": "A String", # Email ID of this user.
309      "id": "A String", # User ID.
310    },
311    "id": "A String", # Entity user link ID
312    "selfLink": "A String", # Self link for this resource.
313    "permissions": { # Permissions the user has for this entity.
314      "local": [ # Permissions that a user has been assigned at this very level. Does not include any implied or inherited permissions. Local permissions are modifiable.
315        "A String",
316      ],
317      "effective": [ # Effective permissions represent all the permissions that a user has for this entity. These include any implied permissions (e.g., EDIT implies VIEW) or inherited permissions from the parent entity. Effective permissions are read-only.
318        "A String",
319      ],
320    },
321  }
322
323
324Returns:
325  An object of the form:
326
327    { # JSON template for an Analytics Entity-User Link. Returns permissions that a user has for an entity.
328      "kind": "analytics#entityUserLink", # Resource type for entity user link.
329      "entity": { # Entity for this link. It can be an account, a web property, or a view (profile).
330        "accountRef": { # JSON template for a linked account. # Account for this link.
331          "kind": "analytics#accountRef", # Analytics account reference.
332          "href": "A String", # Link for this account.
333          "id": "A String", # Account ID.
334          "name": "A String", # Account name.
335        },
336        "profileRef": { # JSON template for a linked view (profile). # View (Profile) for this link.
337          "kind": "analytics#profileRef", # Analytics view (profile) reference.
338          "name": "A String", # Name of this view (profile).
339          "internalWebPropertyId": "A String", # Internal ID for the web property to which this view (profile) belongs.
340          "href": "A String", # Link for this view (profile).
341          "webPropertyId": "A String", # Web property ID of the form UA-XXXXX-YY to which this view (profile) belongs.
342          "id": "A String", # View (Profile) ID.
343          "accountId": "A String", # Account ID to which this view (profile) belongs.
344        },
345        "webPropertyRef": { # JSON template for a web property reference. # Web property for this link.
346          "kind": "analytics#webPropertyRef", # Analytics web property reference.
347          "name": "A String", # Name of this web property.
348          "internalWebPropertyId": "A String", # Internal ID for this web property.
349          "href": "A String", # Link for this web property.
350          "id": "A String", # Web property ID of the form UA-XXXXX-YY.
351          "accountId": "A String", # Account ID to which this web property belongs.
352        },
353      },
354      "userRef": { # JSON template for a user reference. # User reference.
355        "kind": "analytics#userRef",
356        "email": "A String", # Email ID of this user.
357        "id": "A String", # User ID.
358      },
359      "id": "A String", # Entity user link ID
360      "selfLink": "A String", # Self link for this resource.
361      "permissions": { # Permissions the user has for this entity.
362        "local": [ # Permissions that a user has been assigned at this very level. Does not include any implied or inherited permissions. Local permissions are modifiable.
363          "A String",
364        ],
365        "effective": [ # Effective permissions represent all the permissions that a user has for this entity. These include any implied permissions (e.g., EDIT implies VIEW) or inherited permissions from the parent entity. Effective permissions are read-only.
366          "A String",
367        ],
368      },
369    }</pre>
370</div>
371
372</body></html>