OLD | NEW |
| 1 // This is a generated file (see the discoveryapis_generator project). |
| 2 |
1 library googleapis.analytics.v3; | 3 library googleapis.analytics.v3; |
2 | 4 |
3 import "dart:core" as core; | 5 import 'dart:core' as core; |
4 import "dart:collection" as collection; | 6 import 'dart:collection' as collection; |
5 import "dart:async" as async; | 7 import 'dart:async' as async; |
6 import "dart:convert" as convert; | 8 import 'dart:convert' as convert; |
7 | 9 |
8 import "package:crypto/crypto.dart" as crypto; | 10 import 'package:_discoveryapis_commons/_discoveryapis_commons.dart' as commons; |
| 11 import 'package:crypto/crypto.dart' as crypto; |
9 import 'package:http/http.dart' as http; | 12 import 'package:http/http.dart' as http; |
10 import '../src/common_internal.dart' as common_internal; | |
11 import '../common/common.dart' as common; | |
12 | 13 |
13 export '../common/common.dart' show ApiRequestError; | 14 export 'package:_discoveryapis_commons/_discoveryapis_commons.dart' show |
14 export '../common/common.dart' show DetailedApiRequestError; | 15 ApiRequestError, DetailedApiRequestError, Media, UploadOptions, |
| 16 ResumableUploadOptions, DownloadOptions, PartialDownloadOptions, |
| 17 ByteRange; |
| 18 |
| 19 const core.String USER_AGENT = 'dart-api-client analytics/v3'; |
15 | 20 |
16 /** View and manage your Google Analytics data */ | 21 /** View and manage your Google Analytics data */ |
17 class AnalyticsApi { | 22 class AnalyticsApi { |
18 /** View and manage your Google Analytics data */ | 23 /** View and manage your Google Analytics data */ |
19 static const AnalyticsScope = "https://www.googleapis.com/auth/analytics"; | 24 static const AnalyticsScope = "https://www.googleapis.com/auth/analytics"; |
20 | 25 |
21 /** Edit Google Analytics management entities */ | 26 /** Edit Google Analytics management entities */ |
22 static const AnalyticsEditScope = "https://www.googleapis.com/auth/analytics.e
dit"; | 27 static const AnalyticsEditScope = "https://www.googleapis.com/auth/analytics.e
dit"; |
23 | 28 |
24 /** Manage Google Analytics Account users by email address */ | 29 /** Manage Google Analytics Account users by email address */ |
25 static const AnalyticsManageUsersScope = "https://www.googleapis.com/auth/anal
ytics.manage.users"; | 30 static const AnalyticsManageUsersScope = "https://www.googleapis.com/auth/anal
ytics.manage.users"; |
26 | 31 |
27 /** View Google Analytics user permissions */ | 32 /** View Google Analytics user permissions */ |
28 static const AnalyticsManageUsersReadonlyScope = "https://www.googleapis.com/a
uth/analytics.manage.users.readonly"; | 33 static const AnalyticsManageUsersReadonlyScope = "https://www.googleapis.com/a
uth/analytics.manage.users.readonly"; |
29 | 34 |
30 /** | 35 /** |
31 * Create a new Google Analytics account along with its default property and | 36 * Create a new Google Analytics account along with its default property and |
32 * view | 37 * view |
33 */ | 38 */ |
34 static const AnalyticsProvisionScope = "https://www.googleapis.com/auth/analyt
ics.provision"; | 39 static const AnalyticsProvisionScope = "https://www.googleapis.com/auth/analyt
ics.provision"; |
35 | 40 |
36 /** View your Google Analytics data */ | 41 /** View your Google Analytics data */ |
37 static const AnalyticsReadonlyScope = "https://www.googleapis.com/auth/analyti
cs.readonly"; | 42 static const AnalyticsReadonlyScope = "https://www.googleapis.com/auth/analyti
cs.readonly"; |
38 | 43 |
39 | 44 |
40 final common_internal.ApiRequester _requester; | 45 final commons.ApiRequester _requester; |
41 | 46 |
42 DataResourceApi get data => new DataResourceApi(_requester); | 47 DataResourceApi get data => new DataResourceApi(_requester); |
43 ManagementResourceApi get management => new ManagementResourceApi(_requester); | 48 ManagementResourceApi get management => new ManagementResourceApi(_requester); |
44 MetadataResourceApi get metadata => new MetadataResourceApi(_requester); | 49 MetadataResourceApi get metadata => new MetadataResourceApi(_requester); |
45 ProvisioningResourceApi get provisioning => new ProvisioningResourceApi(_reque
ster); | 50 ProvisioningResourceApi get provisioning => new ProvisioningResourceApi(_reque
ster); |
46 | 51 |
47 AnalyticsApi(http.Client client, {core.String rootUrl: "https://www.googleapis
.com/", core.String servicePath: "analytics/v3/"}) : | 52 AnalyticsApi(http.Client client, {core.String rootUrl: "https://www.googleapis
.com/", core.String servicePath: "analytics/v3/"}) : |
48 _requester = new common_internal.ApiRequester(client, rootUrl, servicePath
); | 53 _requester = new commons.ApiRequester(client, rootUrl, servicePath, USER_A
GENT); |
49 } | 54 } |
50 | 55 |
51 | 56 |
52 /** Not documented yet. */ | |
53 class DataResourceApi { | 57 class DataResourceApi { |
54 final common_internal.ApiRequester _requester; | 58 final commons.ApiRequester _requester; |
55 | 59 |
56 DataGaResourceApi get ga => new DataGaResourceApi(_requester); | 60 DataGaResourceApi get ga => new DataGaResourceApi(_requester); |
57 DataMcfResourceApi get mcf => new DataMcfResourceApi(_requester); | 61 DataMcfResourceApi get mcf => new DataMcfResourceApi(_requester); |
58 DataRealtimeResourceApi get realtime => new DataRealtimeResourceApi(_requester
); | 62 DataRealtimeResourceApi get realtime => new DataRealtimeResourceApi(_requester
); |
59 | 63 |
60 DataResourceApi(common_internal.ApiRequester client) : | 64 DataResourceApi(commons.ApiRequester client) : |
61 _requester = client; | 65 _requester = client; |
62 } | 66 } |
63 | 67 |
64 | 68 |
65 /** Not documented yet. */ | |
66 class DataGaResourceApi { | 69 class DataGaResourceApi { |
67 final common_internal.ApiRequester _requester; | 70 final commons.ApiRequester _requester; |
68 | 71 |
69 DataGaResourceApi(common_internal.ApiRequester client) : | 72 DataGaResourceApi(commons.ApiRequester client) : |
70 _requester = client; | 73 _requester = client; |
71 | 74 |
72 /** | 75 /** |
73 * Returns Analytics data for a view (profile). | 76 * Returns Analytics data for a view (profile). |
74 * | 77 * |
75 * Request parameters: | 78 * Request parameters: |
76 * | 79 * |
77 * [ids] - Unique table ID for retrieving Analytics data. Table ID is of the | 80 * [ids] - Unique table ID for retrieving Analytics data. Table ID is of the |
78 * form ga:XXXX, where XXXX is the Analytics view (profile) ID. | 81 * form ga:XXXX, where XXXX is the Analytics view (profile) ID. |
79 * Value must have pattern "ga:[0-9]+". | 82 * Value must have pattern "ga:[0-9]+". |
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
122 * | 125 * |
123 * [sort] - A comma-separated list of dimensions or metrics that determine the | 126 * [sort] - A comma-separated list of dimensions or metrics that determine the |
124 * sort order for Analytics data. | 127 * sort order for Analytics data. |
125 * Value must have pattern "(-)?ga:.+". | 128 * Value must have pattern "(-)?ga:.+". |
126 * | 129 * |
127 * [start_index] - An index of the first entity to retrieve. Use this | 130 * [start_index] - An index of the first entity to retrieve. Use this |
128 * parameter as a pagination mechanism along with the max-results parameter. | 131 * parameter as a pagination mechanism along with the max-results parameter. |
129 * | 132 * |
130 * Completes with a [GaData]. | 133 * Completes with a [GaData]. |
131 * | 134 * |
132 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 135 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
133 * error. | 136 * error. |
134 * | 137 * |
135 * If the used [http.Client] completes with an error when making a REST call, | 138 * If the used [http.Client] completes with an error when making a REST call, |
136 * this method will complete with the same error. | 139 * this method will complete with the same error. |
137 */ | 140 */ |
138 async.Future<GaData> get(core.String ids, core.String start_date, core.String
end_date, core.String metrics, {core.String dimensions, core.String filters, cor
e.int max_results, core.String output, core.String samplingLevel, core.String se
gment, core.String sort, core.int start_index}) { | 141 async.Future<GaData> get(core.String ids, core.String start_date, core.String
end_date, core.String metrics, {core.String dimensions, core.String filters, cor
e.int max_results, core.String output, core.String samplingLevel, core.String se
gment, core.String sort, core.int start_index}) { |
139 var _url = null; | 142 var _url = null; |
140 var _queryParams = new core.Map(); | 143 var _queryParams = new core.Map(); |
141 var _uploadMedia = null; | 144 var _uploadMedia = null; |
142 var _uploadOptions = null; | 145 var _uploadOptions = null; |
143 var _downloadOptions = common.DownloadOptions.Metadata; | 146 var _downloadOptions = commons.DownloadOptions.Metadata; |
144 var _body = null; | 147 var _body = null; |
145 | 148 |
146 if (ids == null) { | 149 if (ids == null) { |
147 throw new core.ArgumentError("Parameter ids is required."); | 150 throw new core.ArgumentError("Parameter ids is required."); |
148 } | 151 } |
149 _queryParams["ids"] = [ids]; | 152 _queryParams["ids"] = [ids]; |
150 if (start_date == null) { | 153 if (start_date == null) { |
151 throw new core.ArgumentError("Parameter start_date is required."); | 154 throw new core.ArgumentError("Parameter start_date is required."); |
152 } | 155 } |
153 _queryParams["start-date"] = [start_date]; | 156 _queryParams["start-date"] = [start_date]; |
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
193 queryParams: _queryParams, | 196 queryParams: _queryParams, |
194 uploadOptions: _uploadOptions, | 197 uploadOptions: _uploadOptions, |
195 uploadMedia: _uploadMedia, | 198 uploadMedia: _uploadMedia, |
196 downloadOptions: _downloadOptions); | 199 downloadOptions: _downloadOptions); |
197 return _response.then((data) => new GaData.fromJson(data)); | 200 return _response.then((data) => new GaData.fromJson(data)); |
198 } | 201 } |
199 | 202 |
200 } | 203 } |
201 | 204 |
202 | 205 |
203 /** Not documented yet. */ | |
204 class DataMcfResourceApi { | 206 class DataMcfResourceApi { |
205 final common_internal.ApiRequester _requester; | 207 final commons.ApiRequester _requester; |
206 | 208 |
207 DataMcfResourceApi(common_internal.ApiRequester client) : | 209 DataMcfResourceApi(commons.ApiRequester client) : |
208 _requester = client; | 210 _requester = client; |
209 | 211 |
210 /** | 212 /** |
211 * Returns Analytics Multi-Channel Funnels data for a view (profile). | 213 * Returns Analytics Multi-Channel Funnels data for a view (profile). |
212 * | 214 * |
213 * Request parameters: | 215 * Request parameters: |
214 * | 216 * |
215 * [ids] - Unique table ID for retrieving Analytics data. Table ID is of the | 217 * [ids] - Unique table ID for retrieving Analytics data. Table ID is of the |
216 * form ga:XXXX, where XXXX is the Analytics view (profile) ID. | 218 * form ga:XXXX, where XXXX is the Analytics view (profile) ID. |
217 * Value must have pattern "ga:[0-9]+". | 219 * Value must have pattern "ga:[0-9]+". |
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
253 * | 255 * |
254 * [sort] - A comma-separated list of dimensions or metrics that determine the | 256 * [sort] - A comma-separated list of dimensions or metrics that determine the |
255 * sort order for the Analytics data. | 257 * sort order for the Analytics data. |
256 * Value must have pattern "(-)?mcf:.+". | 258 * Value must have pattern "(-)?mcf:.+". |
257 * | 259 * |
258 * [start_index] - An index of the first entity to retrieve. Use this | 260 * [start_index] - An index of the first entity to retrieve. Use this |
259 * parameter as a pagination mechanism along with the max-results parameter. | 261 * parameter as a pagination mechanism along with the max-results parameter. |
260 * | 262 * |
261 * Completes with a [McfData]. | 263 * Completes with a [McfData]. |
262 * | 264 * |
263 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 265 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
264 * error. | 266 * error. |
265 * | 267 * |
266 * If the used [http.Client] completes with an error when making a REST call, | 268 * If the used [http.Client] completes with an error when making a REST call, |
267 * this method will complete with the same error. | 269 * this method will complete with the same error. |
268 */ | 270 */ |
269 async.Future<McfData> get(core.String ids, core.String start_date, core.String
end_date, core.String metrics, {core.String dimensions, core.String filters, co
re.int max_results, core.String samplingLevel, core.String sort, core.int start_
index}) { | 271 async.Future<McfData> get(core.String ids, core.String start_date, core.String
end_date, core.String metrics, {core.String dimensions, core.String filters, co
re.int max_results, core.String samplingLevel, core.String sort, core.int start_
index}) { |
270 var _url = null; | 272 var _url = null; |
271 var _queryParams = new core.Map(); | 273 var _queryParams = new core.Map(); |
272 var _uploadMedia = null; | 274 var _uploadMedia = null; |
273 var _uploadOptions = null; | 275 var _uploadOptions = null; |
274 var _downloadOptions = common.DownloadOptions.Metadata; | 276 var _downloadOptions = commons.DownloadOptions.Metadata; |
275 var _body = null; | 277 var _body = null; |
276 | 278 |
277 if (ids == null) { | 279 if (ids == null) { |
278 throw new core.ArgumentError("Parameter ids is required."); | 280 throw new core.ArgumentError("Parameter ids is required."); |
279 } | 281 } |
280 _queryParams["ids"] = [ids]; | 282 _queryParams["ids"] = [ids]; |
281 if (start_date == null) { | 283 if (start_date == null) { |
282 throw new core.ArgumentError("Parameter start_date is required."); | 284 throw new core.ArgumentError("Parameter start_date is required."); |
283 } | 285 } |
284 _queryParams["start-date"] = [start_date]; | 286 _queryParams["start-date"] = [start_date]; |
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
318 queryParams: _queryParams, | 320 queryParams: _queryParams, |
319 uploadOptions: _uploadOptions, | 321 uploadOptions: _uploadOptions, |
320 uploadMedia: _uploadMedia, | 322 uploadMedia: _uploadMedia, |
321 downloadOptions: _downloadOptions); | 323 downloadOptions: _downloadOptions); |
322 return _response.then((data) => new McfData.fromJson(data)); | 324 return _response.then((data) => new McfData.fromJson(data)); |
323 } | 325 } |
324 | 326 |
325 } | 327 } |
326 | 328 |
327 | 329 |
328 /** Not documented yet. */ | |
329 class DataRealtimeResourceApi { | 330 class DataRealtimeResourceApi { |
330 final common_internal.ApiRequester _requester; | 331 final commons.ApiRequester _requester; |
331 | 332 |
332 DataRealtimeResourceApi(common_internal.ApiRequester client) : | 333 DataRealtimeResourceApi(commons.ApiRequester client) : |
333 _requester = client; | 334 _requester = client; |
334 | 335 |
335 /** | 336 /** |
336 * Returns real time data for a view (profile). | 337 * Returns real time data for a view (profile). |
337 * | 338 * |
338 * Request parameters: | 339 * Request parameters: |
339 * | 340 * |
340 * [ids] - Unique table ID for retrieving real time data. Table ID is of the | 341 * [ids] - Unique table ID for retrieving real time data. Table ID is of the |
341 * form ga:XXXX, where XXXX is the Analytics view (profile) ID. | 342 * form ga:XXXX, where XXXX is the Analytics view (profile) ID. |
342 * Value must have pattern "ga:[0-9]+". | 343 * Value must have pattern "ga:[0-9]+". |
(...skipping 11 matching lines...) Expand all Loading... |
354 * Value must have pattern "(ga:.+)|(rt:.+)". | 355 * Value must have pattern "(ga:.+)|(rt:.+)". |
355 * | 356 * |
356 * [max_results] - The maximum number of entries to include in this feed. | 357 * [max_results] - The maximum number of entries to include in this feed. |
357 * | 358 * |
358 * [sort] - A comma-separated list of dimensions or metrics that determine the | 359 * [sort] - A comma-separated list of dimensions or metrics that determine the |
359 * sort order for real time data. | 360 * sort order for real time data. |
360 * Value must have pattern "(-)?((ga:.+)|(rt:.+))". | 361 * Value must have pattern "(-)?((ga:.+)|(rt:.+))". |
361 * | 362 * |
362 * Completes with a [RealtimeData]. | 363 * Completes with a [RealtimeData]. |
363 * | 364 * |
364 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 365 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
365 * error. | 366 * error. |
366 * | 367 * |
367 * If the used [http.Client] completes with an error when making a REST call, | 368 * If the used [http.Client] completes with an error when making a REST call, |
368 * this method will complete with the same error. | 369 * this method will complete with the same error. |
369 */ | 370 */ |
370 async.Future<RealtimeData> get(core.String ids, core.String metrics, {core.Str
ing dimensions, core.String filters, core.int max_results, core.String sort}) { | 371 async.Future<RealtimeData> get(core.String ids, core.String metrics, {core.Str
ing dimensions, core.String filters, core.int max_results, core.String sort}) { |
371 var _url = null; | 372 var _url = null; |
372 var _queryParams = new core.Map(); | 373 var _queryParams = new core.Map(); |
373 var _uploadMedia = null; | 374 var _uploadMedia = null; |
374 var _uploadOptions = null; | 375 var _uploadOptions = null; |
375 var _downloadOptions = common.DownloadOptions.Metadata; | 376 var _downloadOptions = commons.DownloadOptions.Metadata; |
376 var _body = null; | 377 var _body = null; |
377 | 378 |
378 if (ids == null) { | 379 if (ids == null) { |
379 throw new core.ArgumentError("Parameter ids is required."); | 380 throw new core.ArgumentError("Parameter ids is required."); |
380 } | 381 } |
381 _queryParams["ids"] = [ids]; | 382 _queryParams["ids"] = [ids]; |
382 if (metrics == null) { | 383 if (metrics == null) { |
383 throw new core.ArgumentError("Parameter metrics is required."); | 384 throw new core.ArgumentError("Parameter metrics is required."); |
384 } | 385 } |
385 _queryParams["metrics"] = [metrics]; | 386 _queryParams["metrics"] = [metrics]; |
(...skipping 19 matching lines...) Expand all Loading... |
405 queryParams: _queryParams, | 406 queryParams: _queryParams, |
406 uploadOptions: _uploadOptions, | 407 uploadOptions: _uploadOptions, |
407 uploadMedia: _uploadMedia, | 408 uploadMedia: _uploadMedia, |
408 downloadOptions: _downloadOptions); | 409 downloadOptions: _downloadOptions); |
409 return _response.then((data) => new RealtimeData.fromJson(data)); | 410 return _response.then((data) => new RealtimeData.fromJson(data)); |
410 } | 411 } |
411 | 412 |
412 } | 413 } |
413 | 414 |
414 | 415 |
415 /** Not documented yet. */ | |
416 class ManagementResourceApi { | 416 class ManagementResourceApi { |
417 final common_internal.ApiRequester _requester; | 417 final commons.ApiRequester _requester; |
418 | 418 |
419 ManagementAccountSummariesResourceApi get accountSummaries => new ManagementAc
countSummariesResourceApi(_requester); | 419 ManagementAccountSummariesResourceApi get accountSummaries => new ManagementAc
countSummariesResourceApi(_requester); |
420 ManagementAccountUserLinksResourceApi get accountUserLinks => new ManagementAc
countUserLinksResourceApi(_requester); | 420 ManagementAccountUserLinksResourceApi get accountUserLinks => new ManagementAc
countUserLinksResourceApi(_requester); |
421 ManagementAccountsResourceApi get accounts => new ManagementAccountsResourceAp
i(_requester); | 421 ManagementAccountsResourceApi get accounts => new ManagementAccountsResourceAp
i(_requester); |
422 ManagementCustomDataSourcesResourceApi get customDataSources => new Management
CustomDataSourcesResourceApi(_requester); | 422 ManagementCustomDataSourcesResourceApi get customDataSources => new Management
CustomDataSourcesResourceApi(_requester); |
423 ManagementCustomDimensionsResourceApi get customDimensions => new ManagementCu
stomDimensionsResourceApi(_requester); | 423 ManagementCustomDimensionsResourceApi get customDimensions => new ManagementCu
stomDimensionsResourceApi(_requester); |
424 ManagementCustomMetricsResourceApi get customMetrics => new ManagementCustomMe
tricsResourceApi(_requester); | 424 ManagementCustomMetricsResourceApi get customMetrics => new ManagementCustomMe
tricsResourceApi(_requester); |
425 ManagementDailyUploadsResourceApi get dailyUploads => new ManagementDailyUploa
dsResourceApi(_requester); | |
426 ManagementExperimentsResourceApi get experiments => new ManagementExperimentsR
esourceApi(_requester); | 425 ManagementExperimentsResourceApi get experiments => new ManagementExperimentsR
esourceApi(_requester); |
427 ManagementFiltersResourceApi get filters => new ManagementFiltersResourceApi(_
requester); | 426 ManagementFiltersResourceApi get filters => new ManagementFiltersResourceApi(_
requester); |
428 ManagementGoalsResourceApi get goals => new ManagementGoalsResourceApi(_reques
ter); | 427 ManagementGoalsResourceApi get goals => new ManagementGoalsResourceApi(_reques
ter); |
429 ManagementProfileFilterLinksResourceApi get profileFilterLinks => new Manageme
ntProfileFilterLinksResourceApi(_requester); | 428 ManagementProfileFilterLinksResourceApi get profileFilterLinks => new Manageme
ntProfileFilterLinksResourceApi(_requester); |
430 ManagementProfileUserLinksResourceApi get profileUserLinks => new ManagementPr
ofileUserLinksResourceApi(_requester); | 429 ManagementProfileUserLinksResourceApi get profileUserLinks => new ManagementPr
ofileUserLinksResourceApi(_requester); |
431 ManagementProfilesResourceApi get profiles => new ManagementProfilesResourceAp
i(_requester); | 430 ManagementProfilesResourceApi get profiles => new ManagementProfilesResourceAp
i(_requester); |
432 ManagementSegmentsResourceApi get segments => new ManagementSegmentsResourceAp
i(_requester); | 431 ManagementSegmentsResourceApi get segments => new ManagementSegmentsResourceAp
i(_requester); |
433 ManagementUnsampledReportsResourceApi get unsampledReports => new ManagementUn
sampledReportsResourceApi(_requester); | 432 ManagementUnsampledReportsResourceApi get unsampledReports => new ManagementUn
sampledReportsResourceApi(_requester); |
434 ManagementUploadsResourceApi get uploads => new ManagementUploadsResourceApi(_
requester); | 433 ManagementUploadsResourceApi get uploads => new ManagementUploadsResourceApi(_
requester); |
435 ManagementWebPropertyAdWordsLinksResourceApi get webPropertyAdWordsLinks => ne
w ManagementWebPropertyAdWordsLinksResourceApi(_requester); | 434 ManagementWebPropertyAdWordsLinksResourceApi get webPropertyAdWordsLinks => ne
w ManagementWebPropertyAdWordsLinksResourceApi(_requester); |
436 ManagementWebpropertiesResourceApi get webproperties => new ManagementWebprope
rtiesResourceApi(_requester); | 435 ManagementWebpropertiesResourceApi get webproperties => new ManagementWebprope
rtiesResourceApi(_requester); |
437 ManagementWebpropertyUserLinksResourceApi get webpropertyUserLinks => new Mana
gementWebpropertyUserLinksResourceApi(_requester); | 436 ManagementWebpropertyUserLinksResourceApi get webpropertyUserLinks => new Mana
gementWebpropertyUserLinksResourceApi(_requester); |
438 | 437 |
439 ManagementResourceApi(common_internal.ApiRequester client) : | 438 ManagementResourceApi(commons.ApiRequester client) : |
440 _requester = client; | 439 _requester = client; |
441 } | 440 } |
442 | 441 |
443 | 442 |
444 /** Not documented yet. */ | |
445 class ManagementAccountSummariesResourceApi { | 443 class ManagementAccountSummariesResourceApi { |
446 final common_internal.ApiRequester _requester; | 444 final commons.ApiRequester _requester; |
447 | 445 |
448 ManagementAccountSummariesResourceApi(common_internal.ApiRequester client) : | 446 ManagementAccountSummariesResourceApi(commons.ApiRequester client) : |
449 _requester = client; | 447 _requester = client; |
450 | 448 |
451 /** | 449 /** |
452 * Lists account summaries (lightweight tree comprised of | 450 * Lists account summaries (lightweight tree comprised of |
453 * accounts/properties/profiles) to which the user has access. | 451 * accounts/properties/profiles) to which the user has access. |
454 * | 452 * |
455 * Request parameters: | 453 * Request parameters: |
456 * | 454 * |
457 * [max_results] - The maximum number of account summaries to include in this | 455 * [max_results] - The maximum number of account summaries to include in this |
458 * response, where the largest acceptable value is 1000. | 456 * response, where the largest acceptable value is 1000. |
459 * | 457 * |
460 * [start_index] - An index of the first entity to retrieve. Use this | 458 * [start_index] - An index of the first entity to retrieve. Use this |
461 * parameter as a pagination mechanism along with the max-results parameter. | 459 * parameter as a pagination mechanism along with the max-results parameter. |
462 * | 460 * |
463 * Completes with a [AccountSummaries]. | 461 * Completes with a [AccountSummaries]. |
464 * | 462 * |
465 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 463 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
466 * error. | 464 * error. |
467 * | 465 * |
468 * If the used [http.Client] completes with an error when making a REST call, | 466 * If the used [http.Client] completes with an error when making a REST call, |
469 * this method will complete with the same error. | 467 * this method will complete with the same error. |
470 */ | 468 */ |
471 async.Future<AccountSummaries> list({core.int max_results, core.int start_inde
x}) { | 469 async.Future<AccountSummaries> list({core.int max_results, core.int start_inde
x}) { |
472 var _url = null; | 470 var _url = null; |
473 var _queryParams = new core.Map(); | 471 var _queryParams = new core.Map(); |
474 var _uploadMedia = null; | 472 var _uploadMedia = null; |
475 var _uploadOptions = null; | 473 var _uploadOptions = null; |
476 var _downloadOptions = common.DownloadOptions.Metadata; | 474 var _downloadOptions = commons.DownloadOptions.Metadata; |
477 var _body = null; | 475 var _body = null; |
478 | 476 |
479 if (max_results != null) { | 477 if (max_results != null) { |
480 _queryParams["max-results"] = ["${max_results}"]; | 478 _queryParams["max-results"] = ["${max_results}"]; |
481 } | 479 } |
482 if (start_index != null) { | 480 if (start_index != null) { |
483 _queryParams["start-index"] = ["${start_index}"]; | 481 _queryParams["start-index"] = ["${start_index}"]; |
484 } | 482 } |
485 | 483 |
486 | 484 |
487 _url = 'management/accountSummaries'; | 485 _url = 'management/accountSummaries'; |
488 | 486 |
489 var _response = _requester.request(_url, | 487 var _response = _requester.request(_url, |
490 "GET", | 488 "GET", |
491 body: _body, | 489 body: _body, |
492 queryParams: _queryParams, | 490 queryParams: _queryParams, |
493 uploadOptions: _uploadOptions, | 491 uploadOptions: _uploadOptions, |
494 uploadMedia: _uploadMedia, | 492 uploadMedia: _uploadMedia, |
495 downloadOptions: _downloadOptions); | 493 downloadOptions: _downloadOptions); |
496 return _response.then((data) => new AccountSummaries.fromJson(data)); | 494 return _response.then((data) => new AccountSummaries.fromJson(data)); |
497 } | 495 } |
498 | 496 |
499 } | 497 } |
500 | 498 |
501 | 499 |
502 /** Not documented yet. */ | |
503 class ManagementAccountUserLinksResourceApi { | 500 class ManagementAccountUserLinksResourceApi { |
504 final common_internal.ApiRequester _requester; | 501 final commons.ApiRequester _requester; |
505 | 502 |
506 ManagementAccountUserLinksResourceApi(common_internal.ApiRequester client) : | 503 ManagementAccountUserLinksResourceApi(commons.ApiRequester client) : |
507 _requester = client; | 504 _requester = client; |
508 | 505 |
509 /** | 506 /** |
510 * Removes a user from the given account. | 507 * Removes a user from the given account. |
511 * | 508 * |
512 * Request parameters: | 509 * Request parameters: |
513 * | 510 * |
514 * [accountId] - Account ID to delete the user link for. | 511 * [accountId] - Account ID to delete the user link for. |
515 * | 512 * |
516 * [linkId] - Link ID to delete the user link for. | 513 * [linkId] - Link ID to delete the user link for. |
517 * | 514 * |
518 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 515 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
519 * error. | 516 * error. |
520 * | 517 * |
521 * If the used [http.Client] completes with an error when making a REST call, | 518 * If the used [http.Client] completes with an error when making a REST call, |
522 * this method will complete with the same error. | 519 * this method will complete with the same error. |
523 */ | 520 */ |
524 async.Future delete(core.String accountId, core.String linkId) { | 521 async.Future delete(core.String accountId, core.String linkId) { |
525 var _url = null; | 522 var _url = null; |
526 var _queryParams = new core.Map(); | 523 var _queryParams = new core.Map(); |
527 var _uploadMedia = null; | 524 var _uploadMedia = null; |
528 var _uploadOptions = null; | 525 var _uploadOptions = null; |
529 var _downloadOptions = common.DownloadOptions.Metadata; | 526 var _downloadOptions = commons.DownloadOptions.Metadata; |
530 var _body = null; | 527 var _body = null; |
531 | 528 |
532 if (accountId == null) { | 529 if (accountId == null) { |
533 throw new core.ArgumentError("Parameter accountId is required."); | 530 throw new core.ArgumentError("Parameter accountId is required."); |
534 } | 531 } |
535 if (linkId == null) { | 532 if (linkId == null) { |
536 throw new core.ArgumentError("Parameter linkId is required."); | 533 throw new core.ArgumentError("Parameter linkId is required."); |
537 } | 534 } |
538 | 535 |
539 _downloadOptions = null; | 536 _downloadOptions = null; |
540 | 537 |
541 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/entityUserLinks/' + common_internal.Escaper.ecapeVariable('$linkId')
; | 538 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId')
+ '/entityUserLinks/' + commons.Escaper.ecapeVariable('$linkId'); |
542 | 539 |
543 var _response = _requester.request(_url, | 540 var _response = _requester.request(_url, |
544 "DELETE", | 541 "DELETE", |
545 body: _body, | 542 body: _body, |
546 queryParams: _queryParams, | 543 queryParams: _queryParams, |
547 uploadOptions: _uploadOptions, | 544 uploadOptions: _uploadOptions, |
548 uploadMedia: _uploadMedia, | 545 uploadMedia: _uploadMedia, |
549 downloadOptions: _downloadOptions); | 546 downloadOptions: _downloadOptions); |
550 return _response.then((data) => null); | 547 return _response.then((data) => null); |
551 } | 548 } |
552 | 549 |
553 /** | 550 /** |
554 * Adds a new user to the given account. | 551 * Adds a new user to the given account. |
555 * | 552 * |
556 * [request] - The metadata request object. | 553 * [request] - The metadata request object. |
557 * | 554 * |
558 * Request parameters: | 555 * Request parameters: |
559 * | 556 * |
560 * [accountId] - Account ID to create the user link for. | 557 * [accountId] - Account ID to create the user link for. |
561 * | 558 * |
562 * Completes with a [EntityUserLink]. | 559 * Completes with a [EntityUserLink]. |
563 * | 560 * |
564 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 561 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
565 * error. | 562 * error. |
566 * | 563 * |
567 * If the used [http.Client] completes with an error when making a REST call, | 564 * If the used [http.Client] completes with an error when making a REST call, |
568 * this method will complete with the same error. | 565 * this method will complete with the same error. |
569 */ | 566 */ |
570 async.Future<EntityUserLink> insert(EntityUserLink request, core.String accoun
tId) { | 567 async.Future<EntityUserLink> insert(EntityUserLink request, core.String accoun
tId) { |
571 var _url = null; | 568 var _url = null; |
572 var _queryParams = new core.Map(); | 569 var _queryParams = new core.Map(); |
573 var _uploadMedia = null; | 570 var _uploadMedia = null; |
574 var _uploadOptions = null; | 571 var _uploadOptions = null; |
575 var _downloadOptions = common.DownloadOptions.Metadata; | 572 var _downloadOptions = commons.DownloadOptions.Metadata; |
576 var _body = null; | 573 var _body = null; |
577 | 574 |
578 if (request != null) { | 575 if (request != null) { |
579 _body = convert.JSON.encode((request).toJson()); | 576 _body = convert.JSON.encode((request).toJson()); |
580 } | 577 } |
581 if (accountId == null) { | 578 if (accountId == null) { |
582 throw new core.ArgumentError("Parameter accountId is required."); | 579 throw new core.ArgumentError("Parameter accountId is required."); |
583 } | 580 } |
584 | 581 |
585 | 582 |
586 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/entityUserLinks'; | 583 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId')
+ '/entityUserLinks'; |
587 | 584 |
588 var _response = _requester.request(_url, | 585 var _response = _requester.request(_url, |
589 "POST", | 586 "POST", |
590 body: _body, | 587 body: _body, |
591 queryParams: _queryParams, | 588 queryParams: _queryParams, |
592 uploadOptions: _uploadOptions, | 589 uploadOptions: _uploadOptions, |
593 uploadMedia: _uploadMedia, | 590 uploadMedia: _uploadMedia, |
594 downloadOptions: _downloadOptions); | 591 downloadOptions: _downloadOptions); |
595 return _response.then((data) => new EntityUserLink.fromJson(data)); | 592 return _response.then((data) => new EntityUserLink.fromJson(data)); |
596 } | 593 } |
597 | 594 |
598 /** | 595 /** |
599 * Lists account-user links for a given account. | 596 * Lists account-user links for a given account. |
600 * | 597 * |
601 * Request parameters: | 598 * Request parameters: |
602 * | 599 * |
603 * [accountId] - Account ID to retrieve the user links for. | 600 * [accountId] - Account ID to retrieve the user links for. |
604 * | 601 * |
605 * [max_results] - The maximum number of account-user links to include in this | 602 * [max_results] - The maximum number of account-user links to include in this |
606 * response. | 603 * response. |
607 * | 604 * |
608 * [start_index] - An index of the first account-user link to retrieve. Use | 605 * [start_index] - An index of the first account-user link to retrieve. Use |
609 * this parameter as a pagination mechanism along with the max-results | 606 * this parameter as a pagination mechanism along with the max-results |
610 * parameter. | 607 * parameter. |
611 * | 608 * |
612 * Completes with a [EntityUserLinks]. | 609 * Completes with a [EntityUserLinks]. |
613 * | 610 * |
614 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 611 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
615 * error. | 612 * error. |
616 * | 613 * |
617 * If the used [http.Client] completes with an error when making a REST call, | 614 * If the used [http.Client] completes with an error when making a REST call, |
618 * this method will complete with the same error. | 615 * this method will complete with the same error. |
619 */ | 616 */ |
620 async.Future<EntityUserLinks> list(core.String accountId, {core.int max_result
s, core.int start_index}) { | 617 async.Future<EntityUserLinks> list(core.String accountId, {core.int max_result
s, core.int start_index}) { |
621 var _url = null; | 618 var _url = null; |
622 var _queryParams = new core.Map(); | 619 var _queryParams = new core.Map(); |
623 var _uploadMedia = null; | 620 var _uploadMedia = null; |
624 var _uploadOptions = null; | 621 var _uploadOptions = null; |
625 var _downloadOptions = common.DownloadOptions.Metadata; | 622 var _downloadOptions = commons.DownloadOptions.Metadata; |
626 var _body = null; | 623 var _body = null; |
627 | 624 |
628 if (accountId == null) { | 625 if (accountId == null) { |
629 throw new core.ArgumentError("Parameter accountId is required."); | 626 throw new core.ArgumentError("Parameter accountId is required."); |
630 } | 627 } |
631 if (max_results != null) { | 628 if (max_results != null) { |
632 _queryParams["max-results"] = ["${max_results}"]; | 629 _queryParams["max-results"] = ["${max_results}"]; |
633 } | 630 } |
634 if (start_index != null) { | 631 if (start_index != null) { |
635 _queryParams["start-index"] = ["${start_index}"]; | 632 _queryParams["start-index"] = ["${start_index}"]; |
636 } | 633 } |
637 | 634 |
638 | 635 |
639 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/entityUserLinks'; | 636 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId')
+ '/entityUserLinks'; |
640 | 637 |
641 var _response = _requester.request(_url, | 638 var _response = _requester.request(_url, |
642 "GET", | 639 "GET", |
643 body: _body, | 640 body: _body, |
644 queryParams: _queryParams, | 641 queryParams: _queryParams, |
645 uploadOptions: _uploadOptions, | 642 uploadOptions: _uploadOptions, |
646 uploadMedia: _uploadMedia, | 643 uploadMedia: _uploadMedia, |
647 downloadOptions: _downloadOptions); | 644 downloadOptions: _downloadOptions); |
648 return _response.then((data) => new EntityUserLinks.fromJson(data)); | 645 return _response.then((data) => new EntityUserLinks.fromJson(data)); |
649 } | 646 } |
650 | 647 |
651 /** | 648 /** |
652 * Updates permissions for an existing user on the given account. | 649 * Updates permissions for an existing user on the given account. |
653 * | 650 * |
654 * [request] - The metadata request object. | 651 * [request] - The metadata request object. |
655 * | 652 * |
656 * Request parameters: | 653 * Request parameters: |
657 * | 654 * |
658 * [accountId] - Account ID to update the account-user link for. | 655 * [accountId] - Account ID to update the account-user link for. |
659 * | 656 * |
660 * [linkId] - Link ID to update the account-user link for. | 657 * [linkId] - Link ID to update the account-user link for. |
661 * | 658 * |
662 * Completes with a [EntityUserLink]. | 659 * Completes with a [EntityUserLink]. |
663 * | 660 * |
664 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 661 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
665 * error. | 662 * error. |
666 * | 663 * |
667 * If the used [http.Client] completes with an error when making a REST call, | 664 * If the used [http.Client] completes with an error when making a REST call, |
668 * this method will complete with the same error. | 665 * this method will complete with the same error. |
669 */ | 666 */ |
670 async.Future<EntityUserLink> update(EntityUserLink request, core.String accoun
tId, core.String linkId) { | 667 async.Future<EntityUserLink> update(EntityUserLink request, core.String accoun
tId, core.String linkId) { |
671 var _url = null; | 668 var _url = null; |
672 var _queryParams = new core.Map(); | 669 var _queryParams = new core.Map(); |
673 var _uploadMedia = null; | 670 var _uploadMedia = null; |
674 var _uploadOptions = null; | 671 var _uploadOptions = null; |
675 var _downloadOptions = common.DownloadOptions.Metadata; | 672 var _downloadOptions = commons.DownloadOptions.Metadata; |
676 var _body = null; | 673 var _body = null; |
677 | 674 |
678 if (request != null) { | 675 if (request != null) { |
679 _body = convert.JSON.encode((request).toJson()); | 676 _body = convert.JSON.encode((request).toJson()); |
680 } | 677 } |
681 if (accountId == null) { | 678 if (accountId == null) { |
682 throw new core.ArgumentError("Parameter accountId is required."); | 679 throw new core.ArgumentError("Parameter accountId is required."); |
683 } | 680 } |
684 if (linkId == null) { | 681 if (linkId == null) { |
685 throw new core.ArgumentError("Parameter linkId is required."); | 682 throw new core.ArgumentError("Parameter linkId is required."); |
686 } | 683 } |
687 | 684 |
688 | 685 |
689 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/entityUserLinks/' + common_internal.Escaper.ecapeVariable('$linkId')
; | 686 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId')
+ '/entityUserLinks/' + commons.Escaper.ecapeVariable('$linkId'); |
690 | 687 |
691 var _response = _requester.request(_url, | 688 var _response = _requester.request(_url, |
692 "PUT", | 689 "PUT", |
693 body: _body, | 690 body: _body, |
694 queryParams: _queryParams, | 691 queryParams: _queryParams, |
695 uploadOptions: _uploadOptions, | 692 uploadOptions: _uploadOptions, |
696 uploadMedia: _uploadMedia, | 693 uploadMedia: _uploadMedia, |
697 downloadOptions: _downloadOptions); | 694 downloadOptions: _downloadOptions); |
698 return _response.then((data) => new EntityUserLink.fromJson(data)); | 695 return _response.then((data) => new EntityUserLink.fromJson(data)); |
699 } | 696 } |
700 | 697 |
701 } | 698 } |
702 | 699 |
703 | 700 |
704 /** Not documented yet. */ | |
705 class ManagementAccountsResourceApi { | 701 class ManagementAccountsResourceApi { |
706 final common_internal.ApiRequester _requester; | 702 final commons.ApiRequester _requester; |
707 | 703 |
708 ManagementAccountsResourceApi(common_internal.ApiRequester client) : | 704 ManagementAccountsResourceApi(commons.ApiRequester client) : |
709 _requester = client; | 705 _requester = client; |
710 | 706 |
711 /** | 707 /** |
712 * Lists all accounts to which the user has access. | 708 * Lists all accounts to which the user has access. |
713 * | 709 * |
714 * Request parameters: | 710 * Request parameters: |
715 * | 711 * |
716 * [max_results] - The maximum number of accounts to include in this response. | 712 * [max_results] - The maximum number of accounts to include in this response. |
717 * | 713 * |
718 * [start_index] - An index of the first account to retrieve. Use this | 714 * [start_index] - An index of the first account to retrieve. Use this |
719 * parameter as a pagination mechanism along with the max-results parameter. | 715 * parameter as a pagination mechanism along with the max-results parameter. |
720 * | 716 * |
721 * Completes with a [Accounts]. | 717 * Completes with a [Accounts]. |
722 * | 718 * |
723 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 719 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
724 * error. | 720 * error. |
725 * | 721 * |
726 * If the used [http.Client] completes with an error when making a REST call, | 722 * If the used [http.Client] completes with an error when making a REST call, |
727 * this method will complete with the same error. | 723 * this method will complete with the same error. |
728 */ | 724 */ |
729 async.Future<Accounts> list({core.int max_results, core.int start_index}) { | 725 async.Future<Accounts> list({core.int max_results, core.int start_index}) { |
730 var _url = null; | 726 var _url = null; |
731 var _queryParams = new core.Map(); | 727 var _queryParams = new core.Map(); |
732 var _uploadMedia = null; | 728 var _uploadMedia = null; |
733 var _uploadOptions = null; | 729 var _uploadOptions = null; |
734 var _downloadOptions = common.DownloadOptions.Metadata; | 730 var _downloadOptions = commons.DownloadOptions.Metadata; |
735 var _body = null; | 731 var _body = null; |
736 | 732 |
737 if (max_results != null) { | 733 if (max_results != null) { |
738 _queryParams["max-results"] = ["${max_results}"]; | 734 _queryParams["max-results"] = ["${max_results}"]; |
739 } | 735 } |
740 if (start_index != null) { | 736 if (start_index != null) { |
741 _queryParams["start-index"] = ["${start_index}"]; | 737 _queryParams["start-index"] = ["${start_index}"]; |
742 } | 738 } |
743 | 739 |
744 | 740 |
745 _url = 'management/accounts'; | 741 _url = 'management/accounts'; |
746 | 742 |
747 var _response = _requester.request(_url, | 743 var _response = _requester.request(_url, |
748 "GET", | 744 "GET", |
749 body: _body, | 745 body: _body, |
750 queryParams: _queryParams, | 746 queryParams: _queryParams, |
751 uploadOptions: _uploadOptions, | 747 uploadOptions: _uploadOptions, |
752 uploadMedia: _uploadMedia, | 748 uploadMedia: _uploadMedia, |
753 downloadOptions: _downloadOptions); | 749 downloadOptions: _downloadOptions); |
754 return _response.then((data) => new Accounts.fromJson(data)); | 750 return _response.then((data) => new Accounts.fromJson(data)); |
755 } | 751 } |
756 | 752 |
757 } | 753 } |
758 | 754 |
759 | 755 |
760 /** Not documented yet. */ | |
761 class ManagementCustomDataSourcesResourceApi { | 756 class ManagementCustomDataSourcesResourceApi { |
762 final common_internal.ApiRequester _requester; | 757 final commons.ApiRequester _requester; |
763 | 758 |
764 ManagementCustomDataSourcesResourceApi(common_internal.ApiRequester client) : | 759 ManagementCustomDataSourcesResourceApi(commons.ApiRequester client) : |
765 _requester = client; | 760 _requester = client; |
766 | 761 |
767 /** | 762 /** |
768 * List custom data sources to which the user has access. | 763 * List custom data sources to which the user has access. |
769 * | 764 * |
770 * Request parameters: | 765 * Request parameters: |
771 * | 766 * |
772 * [accountId] - Account Id for the custom data sources to retrieve. | 767 * [accountId] - Account Id for the custom data sources to retrieve. |
773 * Value must have pattern "\d+". | 768 * Value must have pattern "\d+". |
774 * | 769 * |
775 * [webPropertyId] - Web property Id for the custom data sources to retrieve. | 770 * [webPropertyId] - Web property Id for the custom data sources to retrieve. |
776 * Value must have pattern "UA-(\d+)-(\d+)". | 771 * Value must have pattern "UA-(\d+)-(\d+)". |
777 * | 772 * |
778 * [max_results] - The maximum number of custom data sources to include in | 773 * [max_results] - The maximum number of custom data sources to include in |
779 * this response. | 774 * this response. |
780 * | 775 * |
781 * [start_index] - A 1-based index of the first custom data source to | 776 * [start_index] - A 1-based index of the first custom data source to |
782 * retrieve. Use this parameter as a pagination mechanism along with the | 777 * retrieve. Use this parameter as a pagination mechanism along with the |
783 * max-results parameter. | 778 * max-results parameter. |
784 * | 779 * |
785 * Completes with a [CustomDataSources]. | 780 * Completes with a [CustomDataSources]. |
786 * | 781 * |
787 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 782 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
788 * error. | 783 * error. |
789 * | 784 * |
790 * If the used [http.Client] completes with an error when making a REST call, | 785 * If the used [http.Client] completes with an error when making a REST call, |
791 * this method will complete with the same error. | 786 * this method will complete with the same error. |
792 */ | 787 */ |
793 async.Future<CustomDataSources> list(core.String accountId, core.String webPro
pertyId, {core.int max_results, core.int start_index}) { | 788 async.Future<CustomDataSources> list(core.String accountId, core.String webPro
pertyId, {core.int max_results, core.int start_index}) { |
794 var _url = null; | 789 var _url = null; |
795 var _queryParams = new core.Map(); | 790 var _queryParams = new core.Map(); |
796 var _uploadMedia = null; | 791 var _uploadMedia = null; |
797 var _uploadOptions = null; | 792 var _uploadOptions = null; |
798 var _downloadOptions = common.DownloadOptions.Metadata; | 793 var _downloadOptions = commons.DownloadOptions.Metadata; |
799 var _body = null; | 794 var _body = null; |
800 | 795 |
801 if (accountId == null) { | 796 if (accountId == null) { |
802 throw new core.ArgumentError("Parameter accountId is required."); | 797 throw new core.ArgumentError("Parameter accountId is required."); |
803 } | 798 } |
804 if (webPropertyId == null) { | 799 if (webPropertyId == null) { |
805 throw new core.ArgumentError("Parameter webPropertyId is required."); | 800 throw new core.ArgumentError("Parameter webPropertyId is required."); |
806 } | 801 } |
807 if (max_results != null) { | 802 if (max_results != null) { |
808 _queryParams["max-results"] = ["${max_results}"]; | 803 _queryParams["max-results"] = ["${max_results}"]; |
809 } | 804 } |
810 if (start_index != null) { | 805 if (start_index != null) { |
811 _queryParams["start-index"] = ["${start_index}"]; | 806 _queryParams["start-index"] = ["${start_index}"]; |
812 } | 807 } |
813 | 808 |
814 | 809 |
815 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/webproperties/' + common_internal.Escaper.ecapeVariable('$webPropert
yId') + '/customDataSources'; | 810 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId')
+ '/webproperties/' + commons.Escaper.ecapeVariable('$webPropertyId') + '/custom
DataSources'; |
816 | 811 |
817 var _response = _requester.request(_url, | 812 var _response = _requester.request(_url, |
818 "GET", | 813 "GET", |
819 body: _body, | 814 body: _body, |
820 queryParams: _queryParams, | 815 queryParams: _queryParams, |
821 uploadOptions: _uploadOptions, | 816 uploadOptions: _uploadOptions, |
822 uploadMedia: _uploadMedia, | 817 uploadMedia: _uploadMedia, |
823 downloadOptions: _downloadOptions); | 818 downloadOptions: _downloadOptions); |
824 return _response.then((data) => new CustomDataSources.fromJson(data)); | 819 return _response.then((data) => new CustomDataSources.fromJson(data)); |
825 } | 820 } |
826 | 821 |
827 } | 822 } |
828 | 823 |
829 | 824 |
830 /** Not documented yet. */ | |
831 class ManagementCustomDimensionsResourceApi { | 825 class ManagementCustomDimensionsResourceApi { |
832 final common_internal.ApiRequester _requester; | 826 final commons.ApiRequester _requester; |
833 | 827 |
834 ManagementCustomDimensionsResourceApi(common_internal.ApiRequester client) : | 828 ManagementCustomDimensionsResourceApi(commons.ApiRequester client) : |
835 _requester = client; | 829 _requester = client; |
836 | 830 |
837 /** | 831 /** |
838 * Get a custom dimension to which the user has access. | 832 * Get a custom dimension to which the user has access. |
839 * | 833 * |
840 * Request parameters: | 834 * Request parameters: |
841 * | 835 * |
842 * [accountId] - Account ID for the custom dimension to retrieve. | 836 * [accountId] - Account ID for the custom dimension to retrieve. |
843 * | 837 * |
844 * [webPropertyId] - Web property ID for the custom dimension to retrieve. | 838 * [webPropertyId] - Web property ID for the custom dimension to retrieve. |
845 * | 839 * |
846 * [customDimensionId] - The ID of the custom dimension to retrieve. | 840 * [customDimensionId] - The ID of the custom dimension to retrieve. |
847 * | 841 * |
848 * Completes with a [CustomDimension]. | 842 * Completes with a [CustomDimension]. |
849 * | 843 * |
850 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 844 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
851 * error. | 845 * error. |
852 * | 846 * |
853 * If the used [http.Client] completes with an error when making a REST call, | 847 * If the used [http.Client] completes with an error when making a REST call, |
854 * this method will complete with the same error. | 848 * this method will complete with the same error. |
855 */ | 849 */ |
856 async.Future<CustomDimension> get(core.String accountId, core.String webProper
tyId, core.String customDimensionId) { | 850 async.Future<CustomDimension> get(core.String accountId, core.String webProper
tyId, core.String customDimensionId) { |
857 var _url = null; | 851 var _url = null; |
858 var _queryParams = new core.Map(); | 852 var _queryParams = new core.Map(); |
859 var _uploadMedia = null; | 853 var _uploadMedia = null; |
860 var _uploadOptions = null; | 854 var _uploadOptions = null; |
861 var _downloadOptions = common.DownloadOptions.Metadata; | 855 var _downloadOptions = commons.DownloadOptions.Metadata; |
862 var _body = null; | 856 var _body = null; |
863 | 857 |
864 if (accountId == null) { | 858 if (accountId == null) { |
865 throw new core.ArgumentError("Parameter accountId is required."); | 859 throw new core.ArgumentError("Parameter accountId is required."); |
866 } | 860 } |
867 if (webPropertyId == null) { | 861 if (webPropertyId == null) { |
868 throw new core.ArgumentError("Parameter webPropertyId is required."); | 862 throw new core.ArgumentError("Parameter webPropertyId is required."); |
869 } | 863 } |
870 if (customDimensionId == null) { | 864 if (customDimensionId == null) { |
871 throw new core.ArgumentError("Parameter customDimensionId is required."); | 865 throw new core.ArgumentError("Parameter customDimensionId is required."); |
872 } | 866 } |
873 | 867 |
874 | 868 |
875 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/webproperties/' + common_internal.Escaper.ecapeVariable('$webPropert
yId') + '/customDimensions/' + common_internal.Escaper.ecapeVariable('$customDim
ensionId'); | 869 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId')
+ '/webproperties/' + commons.Escaper.ecapeVariable('$webPropertyId') + '/custom
Dimensions/' + commons.Escaper.ecapeVariable('$customDimensionId'); |
876 | 870 |
877 var _response = _requester.request(_url, | 871 var _response = _requester.request(_url, |
878 "GET", | 872 "GET", |
879 body: _body, | 873 body: _body, |
880 queryParams: _queryParams, | 874 queryParams: _queryParams, |
881 uploadOptions: _uploadOptions, | 875 uploadOptions: _uploadOptions, |
882 uploadMedia: _uploadMedia, | 876 uploadMedia: _uploadMedia, |
883 downloadOptions: _downloadOptions); | 877 downloadOptions: _downloadOptions); |
884 return _response.then((data) => new CustomDimension.fromJson(data)); | 878 return _response.then((data) => new CustomDimension.fromJson(data)); |
885 } | 879 } |
886 | 880 |
887 /** | 881 /** |
888 * Create a new custom dimension. | 882 * Create a new custom dimension. |
889 * | 883 * |
890 * [request] - The metadata request object. | 884 * [request] - The metadata request object. |
891 * | 885 * |
892 * Request parameters: | 886 * Request parameters: |
893 * | 887 * |
894 * [accountId] - Account ID for the custom dimension to create. | 888 * [accountId] - Account ID for the custom dimension to create. |
895 * | 889 * |
896 * [webPropertyId] - Web property ID for the custom dimension to create. | 890 * [webPropertyId] - Web property ID for the custom dimension to create. |
897 * | 891 * |
898 * Completes with a [CustomDimension]. | 892 * Completes with a [CustomDimension]. |
899 * | 893 * |
900 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 894 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
901 * error. | 895 * error. |
902 * | 896 * |
903 * If the used [http.Client] completes with an error when making a REST call, | 897 * If the used [http.Client] completes with an error when making a REST call, |
904 * this method will complete with the same error. | 898 * this method will complete with the same error. |
905 */ | 899 */ |
906 async.Future<CustomDimension> insert(CustomDimension request, core.String acco
untId, core.String webPropertyId) { | 900 async.Future<CustomDimension> insert(CustomDimension request, core.String acco
untId, core.String webPropertyId) { |
907 var _url = null; | 901 var _url = null; |
908 var _queryParams = new core.Map(); | 902 var _queryParams = new core.Map(); |
909 var _uploadMedia = null; | 903 var _uploadMedia = null; |
910 var _uploadOptions = null; | 904 var _uploadOptions = null; |
911 var _downloadOptions = common.DownloadOptions.Metadata; | 905 var _downloadOptions = commons.DownloadOptions.Metadata; |
912 var _body = null; | 906 var _body = null; |
913 | 907 |
914 if (request != null) { | 908 if (request != null) { |
915 _body = convert.JSON.encode((request).toJson()); | 909 _body = convert.JSON.encode((request).toJson()); |
916 } | 910 } |
917 if (accountId == null) { | 911 if (accountId == null) { |
918 throw new core.ArgumentError("Parameter accountId is required."); | 912 throw new core.ArgumentError("Parameter accountId is required."); |
919 } | 913 } |
920 if (webPropertyId == null) { | 914 if (webPropertyId == null) { |
921 throw new core.ArgumentError("Parameter webPropertyId is required."); | 915 throw new core.ArgumentError("Parameter webPropertyId is required."); |
922 } | 916 } |
923 | 917 |
924 | 918 |
925 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/webproperties/' + common_internal.Escaper.ecapeVariable('$webPropert
yId') + '/customDimensions'; | 919 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId')
+ '/webproperties/' + commons.Escaper.ecapeVariable('$webPropertyId') + '/custom
Dimensions'; |
926 | 920 |
927 var _response = _requester.request(_url, | 921 var _response = _requester.request(_url, |
928 "POST", | 922 "POST", |
929 body: _body, | 923 body: _body, |
930 queryParams: _queryParams, | 924 queryParams: _queryParams, |
931 uploadOptions: _uploadOptions, | 925 uploadOptions: _uploadOptions, |
932 uploadMedia: _uploadMedia, | 926 uploadMedia: _uploadMedia, |
933 downloadOptions: _downloadOptions); | 927 downloadOptions: _downloadOptions); |
934 return _response.then((data) => new CustomDimension.fromJson(data)); | 928 return _response.then((data) => new CustomDimension.fromJson(data)); |
935 } | 929 } |
936 | 930 |
937 /** | 931 /** |
938 * Lists custom dimensions to which the user has access. | 932 * Lists custom dimensions to which the user has access. |
939 * | 933 * |
940 * Request parameters: | 934 * Request parameters: |
941 * | 935 * |
942 * [accountId] - Account ID for the custom dimensions to retrieve. | 936 * [accountId] - Account ID for the custom dimensions to retrieve. |
943 * | 937 * |
944 * [webPropertyId] - Web property ID for the custom dimensions to retrieve. | 938 * [webPropertyId] - Web property ID for the custom dimensions to retrieve. |
945 * | 939 * |
946 * [max_results] - The maximum number of custom dimensions to include in this | 940 * [max_results] - The maximum number of custom dimensions to include in this |
947 * response. | 941 * response. |
948 * | 942 * |
949 * [start_index] - An index of the first entity to retrieve. Use this | 943 * [start_index] - An index of the first entity to retrieve. Use this |
950 * parameter as a pagination mechanism along with the max-results parameter. | 944 * parameter as a pagination mechanism along with the max-results parameter. |
951 * | 945 * |
952 * Completes with a [CustomDimensions]. | 946 * Completes with a [CustomDimensions]. |
953 * | 947 * |
954 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 948 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
955 * error. | 949 * error. |
956 * | 950 * |
957 * If the used [http.Client] completes with an error when making a REST call, | 951 * If the used [http.Client] completes with an error when making a REST call, |
958 * this method will complete with the same error. | 952 * this method will complete with the same error. |
959 */ | 953 */ |
960 async.Future<CustomDimensions> list(core.String accountId, core.String webProp
ertyId, {core.int max_results, core.int start_index}) { | 954 async.Future<CustomDimensions> list(core.String accountId, core.String webProp
ertyId, {core.int max_results, core.int start_index}) { |
961 var _url = null; | 955 var _url = null; |
962 var _queryParams = new core.Map(); | 956 var _queryParams = new core.Map(); |
963 var _uploadMedia = null; | 957 var _uploadMedia = null; |
964 var _uploadOptions = null; | 958 var _uploadOptions = null; |
965 var _downloadOptions = common.DownloadOptions.Metadata; | 959 var _downloadOptions = commons.DownloadOptions.Metadata; |
966 var _body = null; | 960 var _body = null; |
967 | 961 |
968 if (accountId == null) { | 962 if (accountId == null) { |
969 throw new core.ArgumentError("Parameter accountId is required."); | 963 throw new core.ArgumentError("Parameter accountId is required."); |
970 } | 964 } |
971 if (webPropertyId == null) { | 965 if (webPropertyId == null) { |
972 throw new core.ArgumentError("Parameter webPropertyId is required."); | 966 throw new core.ArgumentError("Parameter webPropertyId is required."); |
973 } | 967 } |
974 if (max_results != null) { | 968 if (max_results != null) { |
975 _queryParams["max-results"] = ["${max_results}"]; | 969 _queryParams["max-results"] = ["${max_results}"]; |
976 } | 970 } |
977 if (start_index != null) { | 971 if (start_index != null) { |
978 _queryParams["start-index"] = ["${start_index}"]; | 972 _queryParams["start-index"] = ["${start_index}"]; |
979 } | 973 } |
980 | 974 |
981 | 975 |
982 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/webproperties/' + common_internal.Escaper.ecapeVariable('$webPropert
yId') + '/customDimensions'; | 976 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId')
+ '/webproperties/' + commons.Escaper.ecapeVariable('$webPropertyId') + '/custom
Dimensions'; |
983 | 977 |
984 var _response = _requester.request(_url, | 978 var _response = _requester.request(_url, |
985 "GET", | 979 "GET", |
986 body: _body, | 980 body: _body, |
987 queryParams: _queryParams, | 981 queryParams: _queryParams, |
988 uploadOptions: _uploadOptions, | 982 uploadOptions: _uploadOptions, |
989 uploadMedia: _uploadMedia, | 983 uploadMedia: _uploadMedia, |
990 downloadOptions: _downloadOptions); | 984 downloadOptions: _downloadOptions); |
991 return _response.then((data) => new CustomDimensions.fromJson(data)); | 985 return _response.then((data) => new CustomDimensions.fromJson(data)); |
992 } | 986 } |
(...skipping 11 matching lines...) Expand all Loading... |
1004 * | 998 * |
1005 * [customDimensionId] - Custom dimension ID for the custom dimension to | 999 * [customDimensionId] - Custom dimension ID for the custom dimension to |
1006 * update. | 1000 * update. |
1007 * | 1001 * |
1008 * [ignoreCustomDataSourceLinks] - Force the update and ignore any warnings | 1002 * [ignoreCustomDataSourceLinks] - Force the update and ignore any warnings |
1009 * related to the custom dimension being linked to a custom data source / data | 1003 * related to the custom dimension being linked to a custom data source / data |
1010 * set. | 1004 * set. |
1011 * | 1005 * |
1012 * Completes with a [CustomDimension]. | 1006 * Completes with a [CustomDimension]. |
1013 * | 1007 * |
1014 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 1008 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
1015 * error. | 1009 * error. |
1016 * | 1010 * |
1017 * If the used [http.Client] completes with an error when making a REST call, | 1011 * If the used [http.Client] completes with an error when making a REST call, |
1018 * this method will complete with the same error. | 1012 * this method will complete with the same error. |
1019 */ | 1013 */ |
1020 async.Future<CustomDimension> patch(CustomDimension request, core.String accou
ntId, core.String webPropertyId, core.String customDimensionId, {core.bool ignor
eCustomDataSourceLinks}) { | 1014 async.Future<CustomDimension> patch(CustomDimension request, core.String accou
ntId, core.String webPropertyId, core.String customDimensionId, {core.bool ignor
eCustomDataSourceLinks}) { |
1021 var _url = null; | 1015 var _url = null; |
1022 var _queryParams = new core.Map(); | 1016 var _queryParams = new core.Map(); |
1023 var _uploadMedia = null; | 1017 var _uploadMedia = null; |
1024 var _uploadOptions = null; | 1018 var _uploadOptions = null; |
1025 var _downloadOptions = common.DownloadOptions.Metadata; | 1019 var _downloadOptions = commons.DownloadOptions.Metadata; |
1026 var _body = null; | 1020 var _body = null; |
1027 | 1021 |
1028 if (request != null) { | 1022 if (request != null) { |
1029 _body = convert.JSON.encode((request).toJson()); | 1023 _body = convert.JSON.encode((request).toJson()); |
1030 } | 1024 } |
1031 if (accountId == null) { | 1025 if (accountId == null) { |
1032 throw new core.ArgumentError("Parameter accountId is required."); | 1026 throw new core.ArgumentError("Parameter accountId is required."); |
1033 } | 1027 } |
1034 if (webPropertyId == null) { | 1028 if (webPropertyId == null) { |
1035 throw new core.ArgumentError("Parameter webPropertyId is required."); | 1029 throw new core.ArgumentError("Parameter webPropertyId is required."); |
1036 } | 1030 } |
1037 if (customDimensionId == null) { | 1031 if (customDimensionId == null) { |
1038 throw new core.ArgumentError("Parameter customDimensionId is required."); | 1032 throw new core.ArgumentError("Parameter customDimensionId is required."); |
1039 } | 1033 } |
1040 if (ignoreCustomDataSourceLinks != null) { | 1034 if (ignoreCustomDataSourceLinks != null) { |
1041 _queryParams["ignoreCustomDataSourceLinks"] = ["${ignoreCustomDataSourceLi
nks}"]; | 1035 _queryParams["ignoreCustomDataSourceLinks"] = ["${ignoreCustomDataSourceLi
nks}"]; |
1042 } | 1036 } |
1043 | 1037 |
1044 | 1038 |
1045 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/webproperties/' + common_internal.Escaper.ecapeVariable('$webPropert
yId') + '/customDimensions/' + common_internal.Escaper.ecapeVariable('$customDim
ensionId'); | 1039 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId')
+ '/webproperties/' + commons.Escaper.ecapeVariable('$webPropertyId') + '/custom
Dimensions/' + commons.Escaper.ecapeVariable('$customDimensionId'); |
1046 | 1040 |
1047 var _response = _requester.request(_url, | 1041 var _response = _requester.request(_url, |
1048 "PATCH", | 1042 "PATCH", |
1049 body: _body, | 1043 body: _body, |
1050 queryParams: _queryParams, | 1044 queryParams: _queryParams, |
1051 uploadOptions: _uploadOptions, | 1045 uploadOptions: _uploadOptions, |
1052 uploadMedia: _uploadMedia, | 1046 uploadMedia: _uploadMedia, |
1053 downloadOptions: _downloadOptions); | 1047 downloadOptions: _downloadOptions); |
1054 return _response.then((data) => new CustomDimension.fromJson(data)); | 1048 return _response.then((data) => new CustomDimension.fromJson(data)); |
1055 } | 1049 } |
(...skipping 11 matching lines...) Expand all Loading... |
1067 * | 1061 * |
1068 * [customDimensionId] - Custom dimension ID for the custom dimension to | 1062 * [customDimensionId] - Custom dimension ID for the custom dimension to |
1069 * update. | 1063 * update. |
1070 * | 1064 * |
1071 * [ignoreCustomDataSourceLinks] - Force the update and ignore any warnings | 1065 * [ignoreCustomDataSourceLinks] - Force the update and ignore any warnings |
1072 * related to the custom dimension being linked to a custom data source / data | 1066 * related to the custom dimension being linked to a custom data source / data |
1073 * set. | 1067 * set. |
1074 * | 1068 * |
1075 * Completes with a [CustomDimension]. | 1069 * Completes with a [CustomDimension]. |
1076 * | 1070 * |
1077 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 1071 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
1078 * error. | 1072 * error. |
1079 * | 1073 * |
1080 * If the used [http.Client] completes with an error when making a REST call, | 1074 * If the used [http.Client] completes with an error when making a REST call, |
1081 * this method will complete with the same error. | 1075 * this method will complete with the same error. |
1082 */ | 1076 */ |
1083 async.Future<CustomDimension> update(CustomDimension request, core.String acco
untId, core.String webPropertyId, core.String customDimensionId, {core.bool igno
reCustomDataSourceLinks}) { | 1077 async.Future<CustomDimension> update(CustomDimension request, core.String acco
untId, core.String webPropertyId, core.String customDimensionId, {core.bool igno
reCustomDataSourceLinks}) { |
1084 var _url = null; | 1078 var _url = null; |
1085 var _queryParams = new core.Map(); | 1079 var _queryParams = new core.Map(); |
1086 var _uploadMedia = null; | 1080 var _uploadMedia = null; |
1087 var _uploadOptions = null; | 1081 var _uploadOptions = null; |
1088 var _downloadOptions = common.DownloadOptions.Metadata; | 1082 var _downloadOptions = commons.DownloadOptions.Metadata; |
1089 var _body = null; | 1083 var _body = null; |
1090 | 1084 |
1091 if (request != null) { | 1085 if (request != null) { |
1092 _body = convert.JSON.encode((request).toJson()); | 1086 _body = convert.JSON.encode((request).toJson()); |
1093 } | 1087 } |
1094 if (accountId == null) { | 1088 if (accountId == null) { |
1095 throw new core.ArgumentError("Parameter accountId is required."); | 1089 throw new core.ArgumentError("Parameter accountId is required."); |
1096 } | 1090 } |
1097 if (webPropertyId == null) { | 1091 if (webPropertyId == null) { |
1098 throw new core.ArgumentError("Parameter webPropertyId is required."); | 1092 throw new core.ArgumentError("Parameter webPropertyId is required."); |
1099 } | 1093 } |
1100 if (customDimensionId == null) { | 1094 if (customDimensionId == null) { |
1101 throw new core.ArgumentError("Parameter customDimensionId is required."); | 1095 throw new core.ArgumentError("Parameter customDimensionId is required."); |
1102 } | 1096 } |
1103 if (ignoreCustomDataSourceLinks != null) { | 1097 if (ignoreCustomDataSourceLinks != null) { |
1104 _queryParams["ignoreCustomDataSourceLinks"] = ["${ignoreCustomDataSourceLi
nks}"]; | 1098 _queryParams["ignoreCustomDataSourceLinks"] = ["${ignoreCustomDataSourceLi
nks}"]; |
1105 } | 1099 } |
1106 | 1100 |
1107 | 1101 |
1108 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/webproperties/' + common_internal.Escaper.ecapeVariable('$webPropert
yId') + '/customDimensions/' + common_internal.Escaper.ecapeVariable('$customDim
ensionId'); | 1102 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId')
+ '/webproperties/' + commons.Escaper.ecapeVariable('$webPropertyId') + '/custom
Dimensions/' + commons.Escaper.ecapeVariable('$customDimensionId'); |
1109 | 1103 |
1110 var _response = _requester.request(_url, | 1104 var _response = _requester.request(_url, |
1111 "PUT", | 1105 "PUT", |
1112 body: _body, | 1106 body: _body, |
1113 queryParams: _queryParams, | 1107 queryParams: _queryParams, |
1114 uploadOptions: _uploadOptions, | 1108 uploadOptions: _uploadOptions, |
1115 uploadMedia: _uploadMedia, | 1109 uploadMedia: _uploadMedia, |
1116 downloadOptions: _downloadOptions); | 1110 downloadOptions: _downloadOptions); |
1117 return _response.then((data) => new CustomDimension.fromJson(data)); | 1111 return _response.then((data) => new CustomDimension.fromJson(data)); |
1118 } | 1112 } |
1119 | 1113 |
1120 } | 1114 } |
1121 | 1115 |
1122 | 1116 |
1123 /** Not documented yet. */ | |
1124 class ManagementCustomMetricsResourceApi { | 1117 class ManagementCustomMetricsResourceApi { |
1125 final common_internal.ApiRequester _requester; | 1118 final commons.ApiRequester _requester; |
1126 | 1119 |
1127 ManagementCustomMetricsResourceApi(common_internal.ApiRequester client) : | 1120 ManagementCustomMetricsResourceApi(commons.ApiRequester client) : |
1128 _requester = client; | 1121 _requester = client; |
1129 | 1122 |
1130 /** | 1123 /** |
1131 * Get a custom metric to which the user has access. | 1124 * Get a custom metric to which the user has access. |
1132 * | 1125 * |
1133 * Request parameters: | 1126 * Request parameters: |
1134 * | 1127 * |
1135 * [accountId] - Account ID for the custom metric to retrieve. | 1128 * [accountId] - Account ID for the custom metric to retrieve. |
1136 * | 1129 * |
1137 * [webPropertyId] - Web property ID for the custom metric to retrieve. | 1130 * [webPropertyId] - Web property ID for the custom metric to retrieve. |
1138 * | 1131 * |
1139 * [customMetricId] - The ID of the custom metric to retrieve. | 1132 * [customMetricId] - The ID of the custom metric to retrieve. |
1140 * | 1133 * |
1141 * Completes with a [CustomMetric]. | 1134 * Completes with a [CustomMetric]. |
1142 * | 1135 * |
1143 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 1136 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
1144 * error. | 1137 * error. |
1145 * | 1138 * |
1146 * If the used [http.Client] completes with an error when making a REST call, | 1139 * If the used [http.Client] completes with an error when making a REST call, |
1147 * this method will complete with the same error. | 1140 * this method will complete with the same error. |
1148 */ | 1141 */ |
1149 async.Future<CustomMetric> get(core.String accountId, core.String webPropertyI
d, core.String customMetricId) { | 1142 async.Future<CustomMetric> get(core.String accountId, core.String webPropertyI
d, core.String customMetricId) { |
1150 var _url = null; | 1143 var _url = null; |
1151 var _queryParams = new core.Map(); | 1144 var _queryParams = new core.Map(); |
1152 var _uploadMedia = null; | 1145 var _uploadMedia = null; |
1153 var _uploadOptions = null; | 1146 var _uploadOptions = null; |
1154 var _downloadOptions = common.DownloadOptions.Metadata; | 1147 var _downloadOptions = commons.DownloadOptions.Metadata; |
1155 var _body = null; | 1148 var _body = null; |
1156 | 1149 |
1157 if (accountId == null) { | 1150 if (accountId == null) { |
1158 throw new core.ArgumentError("Parameter accountId is required."); | 1151 throw new core.ArgumentError("Parameter accountId is required."); |
1159 } | 1152 } |
1160 if (webPropertyId == null) { | 1153 if (webPropertyId == null) { |
1161 throw new core.ArgumentError("Parameter webPropertyId is required."); | 1154 throw new core.ArgumentError("Parameter webPropertyId is required."); |
1162 } | 1155 } |
1163 if (customMetricId == null) { | 1156 if (customMetricId == null) { |
1164 throw new core.ArgumentError("Parameter customMetricId is required."); | 1157 throw new core.ArgumentError("Parameter customMetricId is required."); |
1165 } | 1158 } |
1166 | 1159 |
1167 | 1160 |
1168 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/webproperties/' + common_internal.Escaper.ecapeVariable('$webPropert
yId') + '/customMetrics/' + common_internal.Escaper.ecapeVariable('$customMetric
Id'); | 1161 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId')
+ '/webproperties/' + commons.Escaper.ecapeVariable('$webPropertyId') + '/custom
Metrics/' + commons.Escaper.ecapeVariable('$customMetricId'); |
1169 | 1162 |
1170 var _response = _requester.request(_url, | 1163 var _response = _requester.request(_url, |
1171 "GET", | 1164 "GET", |
1172 body: _body, | 1165 body: _body, |
1173 queryParams: _queryParams, | 1166 queryParams: _queryParams, |
1174 uploadOptions: _uploadOptions, | 1167 uploadOptions: _uploadOptions, |
1175 uploadMedia: _uploadMedia, | 1168 uploadMedia: _uploadMedia, |
1176 downloadOptions: _downloadOptions); | 1169 downloadOptions: _downloadOptions); |
1177 return _response.then((data) => new CustomMetric.fromJson(data)); | 1170 return _response.then((data) => new CustomMetric.fromJson(data)); |
1178 } | 1171 } |
1179 | 1172 |
1180 /** | 1173 /** |
1181 * Create a new custom metric. | 1174 * Create a new custom metric. |
1182 * | 1175 * |
1183 * [request] - The metadata request object. | 1176 * [request] - The metadata request object. |
1184 * | 1177 * |
1185 * Request parameters: | 1178 * Request parameters: |
1186 * | 1179 * |
1187 * [accountId] - Account ID for the custom metric to create. | 1180 * [accountId] - Account ID for the custom metric to create. |
1188 * | 1181 * |
1189 * [webPropertyId] - Web property ID for the custom dimension to create. | 1182 * [webPropertyId] - Web property ID for the custom dimension to create. |
1190 * | 1183 * |
1191 * Completes with a [CustomMetric]. | 1184 * Completes with a [CustomMetric]. |
1192 * | 1185 * |
1193 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 1186 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
1194 * error. | 1187 * error. |
1195 * | 1188 * |
1196 * If the used [http.Client] completes with an error when making a REST call, | 1189 * If the used [http.Client] completes with an error when making a REST call, |
1197 * this method will complete with the same error. | 1190 * this method will complete with the same error. |
1198 */ | 1191 */ |
1199 async.Future<CustomMetric> insert(CustomMetric request, core.String accountId,
core.String webPropertyId) { | 1192 async.Future<CustomMetric> insert(CustomMetric request, core.String accountId,
core.String webPropertyId) { |
1200 var _url = null; | 1193 var _url = null; |
1201 var _queryParams = new core.Map(); | 1194 var _queryParams = new core.Map(); |
1202 var _uploadMedia = null; | 1195 var _uploadMedia = null; |
1203 var _uploadOptions = null; | 1196 var _uploadOptions = null; |
1204 var _downloadOptions = common.DownloadOptions.Metadata; | 1197 var _downloadOptions = commons.DownloadOptions.Metadata; |
1205 var _body = null; | 1198 var _body = null; |
1206 | 1199 |
1207 if (request != null) { | 1200 if (request != null) { |
1208 _body = convert.JSON.encode((request).toJson()); | 1201 _body = convert.JSON.encode((request).toJson()); |
1209 } | 1202 } |
1210 if (accountId == null) { | 1203 if (accountId == null) { |
1211 throw new core.ArgumentError("Parameter accountId is required."); | 1204 throw new core.ArgumentError("Parameter accountId is required."); |
1212 } | 1205 } |
1213 if (webPropertyId == null) { | 1206 if (webPropertyId == null) { |
1214 throw new core.ArgumentError("Parameter webPropertyId is required."); | 1207 throw new core.ArgumentError("Parameter webPropertyId is required."); |
1215 } | 1208 } |
1216 | 1209 |
1217 | 1210 |
1218 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/webproperties/' + common_internal.Escaper.ecapeVariable('$webPropert
yId') + '/customMetrics'; | 1211 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId')
+ '/webproperties/' + commons.Escaper.ecapeVariable('$webPropertyId') + '/custom
Metrics'; |
1219 | 1212 |
1220 var _response = _requester.request(_url, | 1213 var _response = _requester.request(_url, |
1221 "POST", | 1214 "POST", |
1222 body: _body, | 1215 body: _body, |
1223 queryParams: _queryParams, | 1216 queryParams: _queryParams, |
1224 uploadOptions: _uploadOptions, | 1217 uploadOptions: _uploadOptions, |
1225 uploadMedia: _uploadMedia, | 1218 uploadMedia: _uploadMedia, |
1226 downloadOptions: _downloadOptions); | 1219 downloadOptions: _downloadOptions); |
1227 return _response.then((data) => new CustomMetric.fromJson(data)); | 1220 return _response.then((data) => new CustomMetric.fromJson(data)); |
1228 } | 1221 } |
1229 | 1222 |
1230 /** | 1223 /** |
1231 * Lists custom metrics to which the user has access. | 1224 * Lists custom metrics to which the user has access. |
1232 * | 1225 * |
1233 * Request parameters: | 1226 * Request parameters: |
1234 * | 1227 * |
1235 * [accountId] - Account ID for the custom metrics to retrieve. | 1228 * [accountId] - Account ID for the custom metrics to retrieve. |
1236 * | 1229 * |
1237 * [webPropertyId] - Web property ID for the custom metrics to retrieve. | 1230 * [webPropertyId] - Web property ID for the custom metrics to retrieve. |
1238 * | 1231 * |
1239 * [max_results] - The maximum number of custom metrics to include in this | 1232 * [max_results] - The maximum number of custom metrics to include in this |
1240 * response. | 1233 * response. |
1241 * | 1234 * |
1242 * [start_index] - An index of the first entity to retrieve. Use this | 1235 * [start_index] - An index of the first entity to retrieve. Use this |
1243 * parameter as a pagination mechanism along with the max-results parameter. | 1236 * parameter as a pagination mechanism along with the max-results parameter. |
1244 * | 1237 * |
1245 * Completes with a [CustomMetrics]. | 1238 * Completes with a [CustomMetrics]. |
1246 * | 1239 * |
1247 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 1240 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
1248 * error. | 1241 * error. |
1249 * | 1242 * |
1250 * If the used [http.Client] completes with an error when making a REST call, | 1243 * If the used [http.Client] completes with an error when making a REST call, |
1251 * this method will complete with the same error. | 1244 * this method will complete with the same error. |
1252 */ | 1245 */ |
1253 async.Future<CustomMetrics> list(core.String accountId, core.String webPropert
yId, {core.int max_results, core.int start_index}) { | 1246 async.Future<CustomMetrics> list(core.String accountId, core.String webPropert
yId, {core.int max_results, core.int start_index}) { |
1254 var _url = null; | 1247 var _url = null; |
1255 var _queryParams = new core.Map(); | 1248 var _queryParams = new core.Map(); |
1256 var _uploadMedia = null; | 1249 var _uploadMedia = null; |
1257 var _uploadOptions = null; | 1250 var _uploadOptions = null; |
1258 var _downloadOptions = common.DownloadOptions.Metadata; | 1251 var _downloadOptions = commons.DownloadOptions.Metadata; |
1259 var _body = null; | 1252 var _body = null; |
1260 | 1253 |
1261 if (accountId == null) { | 1254 if (accountId == null) { |
1262 throw new core.ArgumentError("Parameter accountId is required."); | 1255 throw new core.ArgumentError("Parameter accountId is required."); |
1263 } | 1256 } |
1264 if (webPropertyId == null) { | 1257 if (webPropertyId == null) { |
1265 throw new core.ArgumentError("Parameter webPropertyId is required."); | 1258 throw new core.ArgumentError("Parameter webPropertyId is required."); |
1266 } | 1259 } |
1267 if (max_results != null) { | 1260 if (max_results != null) { |
1268 _queryParams["max-results"] = ["${max_results}"]; | 1261 _queryParams["max-results"] = ["${max_results}"]; |
1269 } | 1262 } |
1270 if (start_index != null) { | 1263 if (start_index != null) { |
1271 _queryParams["start-index"] = ["${start_index}"]; | 1264 _queryParams["start-index"] = ["${start_index}"]; |
1272 } | 1265 } |
1273 | 1266 |
1274 | 1267 |
1275 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/webproperties/' + common_internal.Escaper.ecapeVariable('$webPropert
yId') + '/customMetrics'; | 1268 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId')
+ '/webproperties/' + commons.Escaper.ecapeVariable('$webPropertyId') + '/custom
Metrics'; |
1276 | 1269 |
1277 var _response = _requester.request(_url, | 1270 var _response = _requester.request(_url, |
1278 "GET", | 1271 "GET", |
1279 body: _body, | 1272 body: _body, |
1280 queryParams: _queryParams, | 1273 queryParams: _queryParams, |
1281 uploadOptions: _uploadOptions, | 1274 uploadOptions: _uploadOptions, |
1282 uploadMedia: _uploadMedia, | 1275 uploadMedia: _uploadMedia, |
1283 downloadOptions: _downloadOptions); | 1276 downloadOptions: _downloadOptions); |
1284 return _response.then((data) => new CustomMetrics.fromJson(data)); | 1277 return _response.then((data) => new CustomMetrics.fromJson(data)); |
1285 } | 1278 } |
(...skipping 10 matching lines...) Expand all Loading... |
1296 * [webPropertyId] - Web property ID for the custom metric to update. | 1289 * [webPropertyId] - Web property ID for the custom metric to update. |
1297 * | 1290 * |
1298 * [customMetricId] - Custom metric ID for the custom metric to update. | 1291 * [customMetricId] - Custom metric ID for the custom metric to update. |
1299 * | 1292 * |
1300 * [ignoreCustomDataSourceLinks] - Force the update and ignore any warnings | 1293 * [ignoreCustomDataSourceLinks] - Force the update and ignore any warnings |
1301 * related to the custom metric being linked to a custom data source / data | 1294 * related to the custom metric being linked to a custom data source / data |
1302 * set. | 1295 * set. |
1303 * | 1296 * |
1304 * Completes with a [CustomMetric]. | 1297 * Completes with a [CustomMetric]. |
1305 * | 1298 * |
1306 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 1299 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
1307 * error. | 1300 * error. |
1308 * | 1301 * |
1309 * If the used [http.Client] completes with an error when making a REST call, | 1302 * If the used [http.Client] completes with an error when making a REST call, |
1310 * this method will complete with the same error. | 1303 * this method will complete with the same error. |
1311 */ | 1304 */ |
1312 async.Future<CustomMetric> patch(CustomMetric request, core.String accountId,
core.String webPropertyId, core.String customMetricId, {core.bool ignoreCustomDa
taSourceLinks}) { | 1305 async.Future<CustomMetric> patch(CustomMetric request, core.String accountId,
core.String webPropertyId, core.String customMetricId, {core.bool ignoreCustomDa
taSourceLinks}) { |
1313 var _url = null; | 1306 var _url = null; |
1314 var _queryParams = new core.Map(); | 1307 var _queryParams = new core.Map(); |
1315 var _uploadMedia = null; | 1308 var _uploadMedia = null; |
1316 var _uploadOptions = null; | 1309 var _uploadOptions = null; |
1317 var _downloadOptions = common.DownloadOptions.Metadata; | 1310 var _downloadOptions = commons.DownloadOptions.Metadata; |
1318 var _body = null; | 1311 var _body = null; |
1319 | 1312 |
1320 if (request != null) { | 1313 if (request != null) { |
1321 _body = convert.JSON.encode((request).toJson()); | 1314 _body = convert.JSON.encode((request).toJson()); |
1322 } | 1315 } |
1323 if (accountId == null) { | 1316 if (accountId == null) { |
1324 throw new core.ArgumentError("Parameter accountId is required."); | 1317 throw new core.ArgumentError("Parameter accountId is required."); |
1325 } | 1318 } |
1326 if (webPropertyId == null) { | 1319 if (webPropertyId == null) { |
1327 throw new core.ArgumentError("Parameter webPropertyId is required."); | 1320 throw new core.ArgumentError("Parameter webPropertyId is required."); |
1328 } | 1321 } |
1329 if (customMetricId == null) { | 1322 if (customMetricId == null) { |
1330 throw new core.ArgumentError("Parameter customMetricId is required."); | 1323 throw new core.ArgumentError("Parameter customMetricId is required."); |
1331 } | 1324 } |
1332 if (ignoreCustomDataSourceLinks != null) { | 1325 if (ignoreCustomDataSourceLinks != null) { |
1333 _queryParams["ignoreCustomDataSourceLinks"] = ["${ignoreCustomDataSourceLi
nks}"]; | 1326 _queryParams["ignoreCustomDataSourceLinks"] = ["${ignoreCustomDataSourceLi
nks}"]; |
1334 } | 1327 } |
1335 | 1328 |
1336 | 1329 |
1337 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/webproperties/' + common_internal.Escaper.ecapeVariable('$webPropert
yId') + '/customMetrics/' + common_internal.Escaper.ecapeVariable('$customMetric
Id'); | 1330 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId')
+ '/webproperties/' + commons.Escaper.ecapeVariable('$webPropertyId') + '/custom
Metrics/' + commons.Escaper.ecapeVariable('$customMetricId'); |
1338 | 1331 |
1339 var _response = _requester.request(_url, | 1332 var _response = _requester.request(_url, |
1340 "PATCH", | 1333 "PATCH", |
1341 body: _body, | 1334 body: _body, |
1342 queryParams: _queryParams, | 1335 queryParams: _queryParams, |
1343 uploadOptions: _uploadOptions, | 1336 uploadOptions: _uploadOptions, |
1344 uploadMedia: _uploadMedia, | 1337 uploadMedia: _uploadMedia, |
1345 downloadOptions: _downloadOptions); | 1338 downloadOptions: _downloadOptions); |
1346 return _response.then((data) => new CustomMetric.fromJson(data)); | 1339 return _response.then((data) => new CustomMetric.fromJson(data)); |
1347 } | 1340 } |
(...skipping 10 matching lines...) Expand all Loading... |
1358 * [webPropertyId] - Web property ID for the custom metric to update. | 1351 * [webPropertyId] - Web property ID for the custom metric to update. |
1359 * | 1352 * |
1360 * [customMetricId] - Custom metric ID for the custom metric to update. | 1353 * [customMetricId] - Custom metric ID for the custom metric to update. |
1361 * | 1354 * |
1362 * [ignoreCustomDataSourceLinks] - Force the update and ignore any warnings | 1355 * [ignoreCustomDataSourceLinks] - Force the update and ignore any warnings |
1363 * related to the custom metric being linked to a custom data source / data | 1356 * related to the custom metric being linked to a custom data source / data |
1364 * set. | 1357 * set. |
1365 * | 1358 * |
1366 * Completes with a [CustomMetric]. | 1359 * Completes with a [CustomMetric]. |
1367 * | 1360 * |
1368 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 1361 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
1369 * error. | 1362 * error. |
1370 * | 1363 * |
1371 * If the used [http.Client] completes with an error when making a REST call, | 1364 * If the used [http.Client] completes with an error when making a REST call, |
1372 * this method will complete with the same error. | 1365 * this method will complete with the same error. |
1373 */ | 1366 */ |
1374 async.Future<CustomMetric> update(CustomMetric request, core.String accountId,
core.String webPropertyId, core.String customMetricId, {core.bool ignoreCustomD
ataSourceLinks}) { | 1367 async.Future<CustomMetric> update(CustomMetric request, core.String accountId,
core.String webPropertyId, core.String customMetricId, {core.bool ignoreCustomD
ataSourceLinks}) { |
1375 var _url = null; | 1368 var _url = null; |
1376 var _queryParams = new core.Map(); | 1369 var _queryParams = new core.Map(); |
1377 var _uploadMedia = null; | 1370 var _uploadMedia = null; |
1378 var _uploadOptions = null; | 1371 var _uploadOptions = null; |
1379 var _downloadOptions = common.DownloadOptions.Metadata; | 1372 var _downloadOptions = commons.DownloadOptions.Metadata; |
1380 var _body = null; | 1373 var _body = null; |
1381 | 1374 |
1382 if (request != null) { | 1375 if (request != null) { |
1383 _body = convert.JSON.encode((request).toJson()); | 1376 _body = convert.JSON.encode((request).toJson()); |
1384 } | 1377 } |
1385 if (accountId == null) { | 1378 if (accountId == null) { |
1386 throw new core.ArgumentError("Parameter accountId is required."); | 1379 throw new core.ArgumentError("Parameter accountId is required."); |
1387 } | 1380 } |
1388 if (webPropertyId == null) { | 1381 if (webPropertyId == null) { |
1389 throw new core.ArgumentError("Parameter webPropertyId is required."); | 1382 throw new core.ArgumentError("Parameter webPropertyId is required."); |
1390 } | 1383 } |
1391 if (customMetricId == null) { | 1384 if (customMetricId == null) { |
1392 throw new core.ArgumentError("Parameter customMetricId is required."); | 1385 throw new core.ArgumentError("Parameter customMetricId is required."); |
1393 } | 1386 } |
1394 if (ignoreCustomDataSourceLinks != null) { | 1387 if (ignoreCustomDataSourceLinks != null) { |
1395 _queryParams["ignoreCustomDataSourceLinks"] = ["${ignoreCustomDataSourceLi
nks}"]; | 1388 _queryParams["ignoreCustomDataSourceLinks"] = ["${ignoreCustomDataSourceLi
nks}"]; |
1396 } | 1389 } |
1397 | 1390 |
1398 | 1391 |
1399 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/webproperties/' + common_internal.Escaper.ecapeVariable('$webPropert
yId') + '/customMetrics/' + common_internal.Escaper.ecapeVariable('$customMetric
Id'); | 1392 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId')
+ '/webproperties/' + commons.Escaper.ecapeVariable('$webPropertyId') + '/custom
Metrics/' + commons.Escaper.ecapeVariable('$customMetricId'); |
1400 | 1393 |
1401 var _response = _requester.request(_url, | 1394 var _response = _requester.request(_url, |
1402 "PUT", | 1395 "PUT", |
1403 body: _body, | 1396 body: _body, |
1404 queryParams: _queryParams, | 1397 queryParams: _queryParams, |
1405 uploadOptions: _uploadOptions, | 1398 uploadOptions: _uploadOptions, |
1406 uploadMedia: _uploadMedia, | 1399 uploadMedia: _uploadMedia, |
1407 downloadOptions: _downloadOptions); | 1400 downloadOptions: _downloadOptions); |
1408 return _response.then((data) => new CustomMetric.fromJson(data)); | 1401 return _response.then((data) => new CustomMetric.fromJson(data)); |
1409 } | 1402 } |
1410 | 1403 |
1411 } | 1404 } |
1412 | 1405 |
1413 | 1406 |
1414 /** Not documented yet. */ | 1407 class ManagementExperimentsResourceApi { |
1415 class ManagementDailyUploadsResourceApi { | 1408 final commons.ApiRequester _requester; |
1416 final common_internal.ApiRequester _requester; | |
1417 | 1409 |
1418 ManagementDailyUploadsResourceApi(common_internal.ApiRequester client) : | 1410 ManagementExperimentsResourceApi(commons.ApiRequester client) : |
1419 _requester = client; | 1411 _requester = client; |
1420 | 1412 |
1421 /** | 1413 /** |
1422 * Delete uploaded data for the given date. | |
1423 * | |
1424 * Request parameters: | |
1425 * | |
1426 * [accountId] - Account Id associated with daily upload delete. | |
1427 * Value must have pattern "[0-9]+". | |
1428 * | |
1429 * [webPropertyId] - Web property Id associated with daily upload delete. | |
1430 * Value must have pattern "UA-[0-9]+-[0-9]+". | |
1431 * | |
1432 * [customDataSourceId] - Custom data source Id associated with daily upload | |
1433 * delete. | |
1434 * | |
1435 * [date] - Date for which data is to be deleted. Date should be formatted as | |
1436 * YYYY-MM-DD. | |
1437 * Value must have pattern "[0-9]{4}-[0-9]{2}-[0-9]{2}". | |
1438 * | |
1439 * [type] - Type of data for this delete. | |
1440 * Possible string values are: | |
1441 * - "cost" : Value for specifying cost data upload. | |
1442 * | |
1443 * Completes with a [common.ApiRequestError] if the API endpoint returned an | |
1444 * error. | |
1445 * | |
1446 * If the used [http.Client] completes with an error when making a REST call, | |
1447 * this method will complete with the same error. | |
1448 */ | |
1449 async.Future delete(core.String accountId, core.String webPropertyId, core.Str
ing customDataSourceId, core.String date, core.String type) { | |
1450 var _url = null; | |
1451 var _queryParams = new core.Map(); | |
1452 var _uploadMedia = null; | |
1453 var _uploadOptions = null; | |
1454 var _downloadOptions = common.DownloadOptions.Metadata; | |
1455 var _body = null; | |
1456 | |
1457 if (accountId == null) { | |
1458 throw new core.ArgumentError("Parameter accountId is required."); | |
1459 } | |
1460 if (webPropertyId == null) { | |
1461 throw new core.ArgumentError("Parameter webPropertyId is required."); | |
1462 } | |
1463 if (customDataSourceId == null) { | |
1464 throw new core.ArgumentError("Parameter customDataSourceId is required."); | |
1465 } | |
1466 if (date == null) { | |
1467 throw new core.ArgumentError("Parameter date is required."); | |
1468 } | |
1469 if (type == null) { | |
1470 throw new core.ArgumentError("Parameter type is required."); | |
1471 } | |
1472 _queryParams["type"] = [type]; | |
1473 | |
1474 _downloadOptions = null; | |
1475 | |
1476 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/webproperties/' + common_internal.Escaper.ecapeVariable('$webPropert
yId') + '/customDataSources/' + common_internal.Escaper.ecapeVariable('$customDa
taSourceId') + '/dailyUploads/' + common_internal.Escaper.ecapeVariable('$date')
; | |
1477 | |
1478 var _response = _requester.request(_url, | |
1479 "DELETE", | |
1480 body: _body, | |
1481 queryParams: _queryParams, | |
1482 uploadOptions: _uploadOptions, | |
1483 uploadMedia: _uploadMedia, | |
1484 downloadOptions: _downloadOptions); | |
1485 return _response.then((data) => null); | |
1486 } | |
1487 | |
1488 /** | |
1489 * List daily uploads to which the user has access. | |
1490 * | |
1491 * Request parameters: | |
1492 * | |
1493 * [accountId] - Account Id for the daily uploads to retrieve. | |
1494 * Value must have pattern "\d+". | |
1495 * | |
1496 * [webPropertyId] - Web property Id for the daily uploads to retrieve. | |
1497 * Value must have pattern "UA-(\d+)-(\d+)". | |
1498 * | |
1499 * [customDataSourceId] - Custom data source Id for daily uploads to retrieve. | |
1500 * Value must have pattern ".{22}". | |
1501 * | |
1502 * [start_date] - Start date of the form YYYY-MM-DD. | |
1503 * Value must have pattern "[0-9]{4}-[0-9]{2}-[0-9]{2}". | |
1504 * | |
1505 * [end_date] - End date of the form YYYY-MM-DD. | |
1506 * Value must have pattern "[0-9]{4}-[0-9]{2}-[0-9]{2}". | |
1507 * | |
1508 * [max_results] - The maximum number of custom data sources to include in | |
1509 * this response. | |
1510 * | |
1511 * [start_index] - A 1-based index of the first daily upload to retrieve. Use | |
1512 * this parameter as a pagination mechanism along with the max-results | |
1513 * parameter. | |
1514 * | |
1515 * Completes with a [DailyUploads]. | |
1516 * | |
1517 * Completes with a [common.ApiRequestError] if the API endpoint returned an | |
1518 * error. | |
1519 * | |
1520 * If the used [http.Client] completes with an error when making a REST call, | |
1521 * this method will complete with the same error. | |
1522 */ | |
1523 async.Future<DailyUploads> list(core.String accountId, core.String webProperty
Id, core.String customDataSourceId, core.String start_date, core.String end_date
, {core.int max_results, core.int start_index}) { | |
1524 var _url = null; | |
1525 var _queryParams = new core.Map(); | |
1526 var _uploadMedia = null; | |
1527 var _uploadOptions = null; | |
1528 var _downloadOptions = common.DownloadOptions.Metadata; | |
1529 var _body = null; | |
1530 | |
1531 if (accountId == null) { | |
1532 throw new core.ArgumentError("Parameter accountId is required."); | |
1533 } | |
1534 if (webPropertyId == null) { | |
1535 throw new core.ArgumentError("Parameter webPropertyId is required."); | |
1536 } | |
1537 if (customDataSourceId == null) { | |
1538 throw new core.ArgumentError("Parameter customDataSourceId is required."); | |
1539 } | |
1540 if (start_date == null) { | |
1541 throw new core.ArgumentError("Parameter start_date is required."); | |
1542 } | |
1543 _queryParams["start-date"] = [start_date]; | |
1544 if (end_date == null) { | |
1545 throw new core.ArgumentError("Parameter end_date is required."); | |
1546 } | |
1547 _queryParams["end-date"] = [end_date]; | |
1548 if (max_results != null) { | |
1549 _queryParams["max-results"] = ["${max_results}"]; | |
1550 } | |
1551 if (start_index != null) { | |
1552 _queryParams["start-index"] = ["${start_index}"]; | |
1553 } | |
1554 | |
1555 | |
1556 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/webproperties/' + common_internal.Escaper.ecapeVariable('$webPropert
yId') + '/customDataSources/' + common_internal.Escaper.ecapeVariable('$customDa
taSourceId') + '/dailyUploads'; | |
1557 | |
1558 var _response = _requester.request(_url, | |
1559 "GET", | |
1560 body: _body, | |
1561 queryParams: _queryParams, | |
1562 uploadOptions: _uploadOptions, | |
1563 uploadMedia: _uploadMedia, | |
1564 downloadOptions: _downloadOptions); | |
1565 return _response.then((data) => new DailyUploads.fromJson(data)); | |
1566 } | |
1567 | |
1568 /** | |
1569 * Update/Overwrite data for a custom data source. | |
1570 * | |
1571 * Request parameters: | |
1572 * | |
1573 * [accountId] - Account Id associated with daily upload. | |
1574 * Value must have pattern "\d+". | |
1575 * | |
1576 * [webPropertyId] - Web property Id associated with daily upload. | |
1577 * Value must have pattern "UA-\d+-\d+". | |
1578 * | |
1579 * [customDataSourceId] - Custom data source Id to which the data being | |
1580 * uploaded belongs. | |
1581 * | |
1582 * [date] - Date for which data is uploaded. Date should be formatted as | |
1583 * YYYY-MM-DD. | |
1584 * Value must have pattern "[0-9]{4}-[0-9]{2}-[0-9]{2}". | |
1585 * | |
1586 * [appendNumber] - Append number for this upload indexed from 1. | |
1587 * Value must be between "1" and "20". | |
1588 * | |
1589 * [type] - Type of data for this upload. | |
1590 * Possible string values are: | |
1591 * - "cost" : Value for specifying cost data upload. | |
1592 * | |
1593 * [reset] - Reset/Overwrite all previous appends for this date and start over | |
1594 * with this file as the first upload. | |
1595 * | |
1596 * [uploadMedia] - The media to upload. | |
1597 * | |
1598 * [uploadOptions] - Options for the media upload. Streaming Media without the | |
1599 * length being known ahead of time is only supported via resumable uploads. | |
1600 * | |
1601 * Completes with a [DailyUploadAppend]. | |
1602 * | |
1603 * Completes with a [common.ApiRequestError] if the API endpoint returned an | |
1604 * error. | |
1605 * | |
1606 * If the used [http.Client] completes with an error when making a REST call, | |
1607 * this method will complete with the same error. | |
1608 */ | |
1609 async.Future<DailyUploadAppend> upload(core.String accountId, core.String webP
ropertyId, core.String customDataSourceId, core.String date, core.int appendNumb
er, core.String type, {core.bool reset, common.UploadOptions uploadOptions : com
mon.UploadOptions.Default, common.Media uploadMedia}) { | |
1610 var _url = null; | |
1611 var _queryParams = new core.Map(); | |
1612 var _uploadMedia = null; | |
1613 var _uploadOptions = null; | |
1614 var _downloadOptions = common.DownloadOptions.Metadata; | |
1615 var _body = null; | |
1616 | |
1617 if (accountId == null) { | |
1618 throw new core.ArgumentError("Parameter accountId is required."); | |
1619 } | |
1620 if (webPropertyId == null) { | |
1621 throw new core.ArgumentError("Parameter webPropertyId is required."); | |
1622 } | |
1623 if (customDataSourceId == null) { | |
1624 throw new core.ArgumentError("Parameter customDataSourceId is required."); | |
1625 } | |
1626 if (date == null) { | |
1627 throw new core.ArgumentError("Parameter date is required."); | |
1628 } | |
1629 if (appendNumber == null) { | |
1630 throw new core.ArgumentError("Parameter appendNumber is required."); | |
1631 } | |
1632 _queryParams["appendNumber"] = ["${appendNumber}"]; | |
1633 if (type == null) { | |
1634 throw new core.ArgumentError("Parameter type is required."); | |
1635 } | |
1636 _queryParams["type"] = [type]; | |
1637 if (reset != null) { | |
1638 _queryParams["reset"] = ["${reset}"]; | |
1639 } | |
1640 | |
1641 _uploadMedia = uploadMedia; | |
1642 _uploadOptions = uploadOptions; | |
1643 | |
1644 if (_uploadMedia == null) { | |
1645 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$ac
countId') + '/webproperties/' + common_internal.Escaper.ecapeVariable('$webPrope
rtyId') + '/customDataSources/' + common_internal.Escaper.ecapeVariable('$custom
DataSourceId') + '/dailyUploads/' + common_internal.Escaper.ecapeVariable('$date
') + '/uploads'; | |
1646 } else if (_uploadOptions is common.ResumableUploadOptions) { | |
1647 _url = '/resumable/upload/analytics/v3/management/accounts/' + common_inte
rnal.Escaper.ecapeVariable('$accountId') + '/webproperties/' + common_internal.E
scaper.ecapeVariable('$webPropertyId') + '/customDataSources/' + common_internal
.Escaper.ecapeVariable('$customDataSourceId') + '/dailyUploads/' + common_intern
al.Escaper.ecapeVariable('$date') + '/uploads'; | |
1648 } else { | |
1649 _url = '/upload/analytics/v3/management/accounts/' + common_internal.Escap
er.ecapeVariable('$accountId') + '/webproperties/' + common_internal.Escaper.eca
peVariable('$webPropertyId') + '/customDataSources/' + common_internal.Escaper.e
capeVariable('$customDataSourceId') + '/dailyUploads/' + common_internal.Escaper
.ecapeVariable('$date') + '/uploads'; | |
1650 } | |
1651 | |
1652 | |
1653 var _response = _requester.request(_url, | |
1654 "POST", | |
1655 body: _body, | |
1656 queryParams: _queryParams, | |
1657 uploadOptions: _uploadOptions, | |
1658 uploadMedia: _uploadMedia, | |
1659 downloadOptions: _downloadOptions); | |
1660 return _response.then((data) => new DailyUploadAppend.fromJson(data)); | |
1661 } | |
1662 | |
1663 } | |
1664 | |
1665 | |
1666 /** Not documented yet. */ | |
1667 class ManagementExperimentsResourceApi { | |
1668 final common_internal.ApiRequester _requester; | |
1669 | |
1670 ManagementExperimentsResourceApi(common_internal.ApiRequester client) : | |
1671 _requester = client; | |
1672 | |
1673 /** | |
1674 * Delete an experiment. | 1414 * Delete an experiment. |
1675 * | 1415 * |
1676 * Request parameters: | 1416 * Request parameters: |
1677 * | 1417 * |
1678 * [accountId] - Account ID to which the experiment belongs | 1418 * [accountId] - Account ID to which the experiment belongs |
1679 * | 1419 * |
1680 * [webPropertyId] - Web property ID to which the experiment belongs | 1420 * [webPropertyId] - Web property ID to which the experiment belongs |
1681 * | 1421 * |
1682 * [profileId] - View (Profile) ID to which the experiment belongs | 1422 * [profileId] - View (Profile) ID to which the experiment belongs |
1683 * | 1423 * |
1684 * [experimentId] - ID of the experiment to delete | 1424 * [experimentId] - ID of the experiment to delete |
1685 * | 1425 * |
1686 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 1426 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
1687 * error. | 1427 * error. |
1688 * | 1428 * |
1689 * If the used [http.Client] completes with an error when making a REST call, | 1429 * If the used [http.Client] completes with an error when making a REST call, |
1690 * this method will complete with the same error. | 1430 * this method will complete with the same error. |
1691 */ | 1431 */ |
1692 async.Future delete(core.String accountId, core.String webPropertyId, core.Str
ing profileId, core.String experimentId) { | 1432 async.Future delete(core.String accountId, core.String webPropertyId, core.Str
ing profileId, core.String experimentId) { |
1693 var _url = null; | 1433 var _url = null; |
1694 var _queryParams = new core.Map(); | 1434 var _queryParams = new core.Map(); |
1695 var _uploadMedia = null; | 1435 var _uploadMedia = null; |
1696 var _uploadOptions = null; | 1436 var _uploadOptions = null; |
1697 var _downloadOptions = common.DownloadOptions.Metadata; | 1437 var _downloadOptions = commons.DownloadOptions.Metadata; |
1698 var _body = null; | 1438 var _body = null; |
1699 | 1439 |
1700 if (accountId == null) { | 1440 if (accountId == null) { |
1701 throw new core.ArgumentError("Parameter accountId is required."); | 1441 throw new core.ArgumentError("Parameter accountId is required."); |
1702 } | 1442 } |
1703 if (webPropertyId == null) { | 1443 if (webPropertyId == null) { |
1704 throw new core.ArgumentError("Parameter webPropertyId is required."); | 1444 throw new core.ArgumentError("Parameter webPropertyId is required."); |
1705 } | 1445 } |
1706 if (profileId == null) { | 1446 if (profileId == null) { |
1707 throw new core.ArgumentError("Parameter profileId is required."); | 1447 throw new core.ArgumentError("Parameter profileId is required."); |
1708 } | 1448 } |
1709 if (experimentId == null) { | 1449 if (experimentId == null) { |
1710 throw new core.ArgumentError("Parameter experimentId is required."); | 1450 throw new core.ArgumentError("Parameter experimentId is required."); |
1711 } | 1451 } |
1712 | 1452 |
1713 _downloadOptions = null; | 1453 _downloadOptions = null; |
1714 | 1454 |
1715 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/webproperties/' + common_internal.Escaper.ecapeVariable('$webPropert
yId') + '/profiles/' + common_internal.Escaper.ecapeVariable('$profileId') + '/e
xperiments/' + common_internal.Escaper.ecapeVariable('$experimentId'); | 1455 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId')
+ '/webproperties/' + commons.Escaper.ecapeVariable('$webPropertyId') + '/profil
es/' + commons.Escaper.ecapeVariable('$profileId') + '/experiments/' + commons.E
scaper.ecapeVariable('$experimentId'); |
1716 | 1456 |
1717 var _response = _requester.request(_url, | 1457 var _response = _requester.request(_url, |
1718 "DELETE", | 1458 "DELETE", |
1719 body: _body, | 1459 body: _body, |
1720 queryParams: _queryParams, | 1460 queryParams: _queryParams, |
1721 uploadOptions: _uploadOptions, | 1461 uploadOptions: _uploadOptions, |
1722 uploadMedia: _uploadMedia, | 1462 uploadMedia: _uploadMedia, |
1723 downloadOptions: _downloadOptions); | 1463 downloadOptions: _downloadOptions); |
1724 return _response.then((data) => null); | 1464 return _response.then((data) => null); |
1725 } | 1465 } |
1726 | 1466 |
1727 /** | 1467 /** |
1728 * Returns an experiment to which the user has access. | 1468 * Returns an experiment to which the user has access. |
1729 * | 1469 * |
1730 * Request parameters: | 1470 * Request parameters: |
1731 * | 1471 * |
1732 * [accountId] - Account ID to retrieve the experiment for. | 1472 * [accountId] - Account ID to retrieve the experiment for. |
1733 * | 1473 * |
1734 * [webPropertyId] - Web property ID to retrieve the experiment for. | 1474 * [webPropertyId] - Web property ID to retrieve the experiment for. |
1735 * | 1475 * |
1736 * [profileId] - View (Profile) ID to retrieve the experiment for. | 1476 * [profileId] - View (Profile) ID to retrieve the experiment for. |
1737 * | 1477 * |
1738 * [experimentId] - Experiment ID to retrieve the experiment for. | 1478 * [experimentId] - Experiment ID to retrieve the experiment for. |
1739 * | 1479 * |
1740 * Completes with a [Experiment]. | 1480 * Completes with a [Experiment]. |
1741 * | 1481 * |
1742 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 1482 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
1743 * error. | 1483 * error. |
1744 * | 1484 * |
1745 * If the used [http.Client] completes with an error when making a REST call, | 1485 * If the used [http.Client] completes with an error when making a REST call, |
1746 * this method will complete with the same error. | 1486 * this method will complete with the same error. |
1747 */ | 1487 */ |
1748 async.Future<Experiment> get(core.String accountId, core.String webPropertyId,
core.String profileId, core.String experimentId) { | 1488 async.Future<Experiment> get(core.String accountId, core.String webPropertyId,
core.String profileId, core.String experimentId) { |
1749 var _url = null; | 1489 var _url = null; |
1750 var _queryParams = new core.Map(); | 1490 var _queryParams = new core.Map(); |
1751 var _uploadMedia = null; | 1491 var _uploadMedia = null; |
1752 var _uploadOptions = null; | 1492 var _uploadOptions = null; |
1753 var _downloadOptions = common.DownloadOptions.Metadata; | 1493 var _downloadOptions = commons.DownloadOptions.Metadata; |
1754 var _body = null; | 1494 var _body = null; |
1755 | 1495 |
1756 if (accountId == null) { | 1496 if (accountId == null) { |
1757 throw new core.ArgumentError("Parameter accountId is required."); | 1497 throw new core.ArgumentError("Parameter accountId is required."); |
1758 } | 1498 } |
1759 if (webPropertyId == null) { | 1499 if (webPropertyId == null) { |
1760 throw new core.ArgumentError("Parameter webPropertyId is required."); | 1500 throw new core.ArgumentError("Parameter webPropertyId is required."); |
1761 } | 1501 } |
1762 if (profileId == null) { | 1502 if (profileId == null) { |
1763 throw new core.ArgumentError("Parameter profileId is required."); | 1503 throw new core.ArgumentError("Parameter profileId is required."); |
1764 } | 1504 } |
1765 if (experimentId == null) { | 1505 if (experimentId == null) { |
1766 throw new core.ArgumentError("Parameter experimentId is required."); | 1506 throw new core.ArgumentError("Parameter experimentId is required."); |
1767 } | 1507 } |
1768 | 1508 |
1769 | 1509 |
1770 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/webproperties/' + common_internal.Escaper.ecapeVariable('$webPropert
yId') + '/profiles/' + common_internal.Escaper.ecapeVariable('$profileId') + '/e
xperiments/' + common_internal.Escaper.ecapeVariable('$experimentId'); | 1510 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId')
+ '/webproperties/' + commons.Escaper.ecapeVariable('$webPropertyId') + '/profil
es/' + commons.Escaper.ecapeVariable('$profileId') + '/experiments/' + commons.E
scaper.ecapeVariable('$experimentId'); |
1771 | 1511 |
1772 var _response = _requester.request(_url, | 1512 var _response = _requester.request(_url, |
1773 "GET", | 1513 "GET", |
1774 body: _body, | 1514 body: _body, |
1775 queryParams: _queryParams, | 1515 queryParams: _queryParams, |
1776 uploadOptions: _uploadOptions, | 1516 uploadOptions: _uploadOptions, |
1777 uploadMedia: _uploadMedia, | 1517 uploadMedia: _uploadMedia, |
1778 downloadOptions: _downloadOptions); | 1518 downloadOptions: _downloadOptions); |
1779 return _response.then((data) => new Experiment.fromJson(data)); | 1519 return _response.then((data) => new Experiment.fromJson(data)); |
1780 } | 1520 } |
1781 | 1521 |
1782 /** | 1522 /** |
1783 * Create a new experiment. | 1523 * Create a new experiment. |
1784 * | 1524 * |
1785 * [request] - The metadata request object. | 1525 * [request] - The metadata request object. |
1786 * | 1526 * |
1787 * Request parameters: | 1527 * Request parameters: |
1788 * | 1528 * |
1789 * [accountId] - Account ID to create the experiment for. | 1529 * [accountId] - Account ID to create the experiment for. |
1790 * | 1530 * |
1791 * [webPropertyId] - Web property ID to create the experiment for. | 1531 * [webPropertyId] - Web property ID to create the experiment for. |
1792 * | 1532 * |
1793 * [profileId] - View (Profile) ID to create the experiment for. | 1533 * [profileId] - View (Profile) ID to create the experiment for. |
1794 * | 1534 * |
1795 * Completes with a [Experiment]. | 1535 * Completes with a [Experiment]. |
1796 * | 1536 * |
1797 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 1537 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
1798 * error. | 1538 * error. |
1799 * | 1539 * |
1800 * If the used [http.Client] completes with an error when making a REST call, | 1540 * If the used [http.Client] completes with an error when making a REST call, |
1801 * this method will complete with the same error. | 1541 * this method will complete with the same error. |
1802 */ | 1542 */ |
1803 async.Future<Experiment> insert(Experiment request, core.String accountId, cor
e.String webPropertyId, core.String profileId) { | 1543 async.Future<Experiment> insert(Experiment request, core.String accountId, cor
e.String webPropertyId, core.String profileId) { |
1804 var _url = null; | 1544 var _url = null; |
1805 var _queryParams = new core.Map(); | 1545 var _queryParams = new core.Map(); |
1806 var _uploadMedia = null; | 1546 var _uploadMedia = null; |
1807 var _uploadOptions = null; | 1547 var _uploadOptions = null; |
1808 var _downloadOptions = common.DownloadOptions.Metadata; | 1548 var _downloadOptions = commons.DownloadOptions.Metadata; |
1809 var _body = null; | 1549 var _body = null; |
1810 | 1550 |
1811 if (request != null) { | 1551 if (request != null) { |
1812 _body = convert.JSON.encode((request).toJson()); | 1552 _body = convert.JSON.encode((request).toJson()); |
1813 } | 1553 } |
1814 if (accountId == null) { | 1554 if (accountId == null) { |
1815 throw new core.ArgumentError("Parameter accountId is required."); | 1555 throw new core.ArgumentError("Parameter accountId is required."); |
1816 } | 1556 } |
1817 if (webPropertyId == null) { | 1557 if (webPropertyId == null) { |
1818 throw new core.ArgumentError("Parameter webPropertyId is required."); | 1558 throw new core.ArgumentError("Parameter webPropertyId is required."); |
1819 } | 1559 } |
1820 if (profileId == null) { | 1560 if (profileId == null) { |
1821 throw new core.ArgumentError("Parameter profileId is required."); | 1561 throw new core.ArgumentError("Parameter profileId is required."); |
1822 } | 1562 } |
1823 | 1563 |
1824 | 1564 |
1825 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/webproperties/' + common_internal.Escaper.ecapeVariable('$webPropert
yId') + '/profiles/' + common_internal.Escaper.ecapeVariable('$profileId') + '/e
xperiments'; | 1565 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId')
+ '/webproperties/' + commons.Escaper.ecapeVariable('$webPropertyId') + '/profil
es/' + commons.Escaper.ecapeVariable('$profileId') + '/experiments'; |
1826 | 1566 |
1827 var _response = _requester.request(_url, | 1567 var _response = _requester.request(_url, |
1828 "POST", | 1568 "POST", |
1829 body: _body, | 1569 body: _body, |
1830 queryParams: _queryParams, | 1570 queryParams: _queryParams, |
1831 uploadOptions: _uploadOptions, | 1571 uploadOptions: _uploadOptions, |
1832 uploadMedia: _uploadMedia, | 1572 uploadMedia: _uploadMedia, |
1833 downloadOptions: _downloadOptions); | 1573 downloadOptions: _downloadOptions); |
1834 return _response.then((data) => new Experiment.fromJson(data)); | 1574 return _response.then((data) => new Experiment.fromJson(data)); |
1835 } | 1575 } |
(...skipping 13 matching lines...) Expand all Loading... |
1849 * Value must have pattern "\d+". | 1589 * Value must have pattern "\d+". |
1850 * | 1590 * |
1851 * [max_results] - The maximum number of experiments to include in this | 1591 * [max_results] - The maximum number of experiments to include in this |
1852 * response. | 1592 * response. |
1853 * | 1593 * |
1854 * [start_index] - An index of the first experiment to retrieve. Use this | 1594 * [start_index] - An index of the first experiment to retrieve. Use this |
1855 * parameter as a pagination mechanism along with the max-results parameter. | 1595 * parameter as a pagination mechanism along with the max-results parameter. |
1856 * | 1596 * |
1857 * Completes with a [Experiments]. | 1597 * Completes with a [Experiments]. |
1858 * | 1598 * |
1859 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 1599 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
1860 * error. | 1600 * error. |
1861 * | 1601 * |
1862 * If the used [http.Client] completes with an error when making a REST call, | 1602 * If the used [http.Client] completes with an error when making a REST call, |
1863 * this method will complete with the same error. | 1603 * this method will complete with the same error. |
1864 */ | 1604 */ |
1865 async.Future<Experiments> list(core.String accountId, core.String webPropertyI
d, core.String profileId, {core.int max_results, core.int start_index}) { | 1605 async.Future<Experiments> list(core.String accountId, core.String webPropertyI
d, core.String profileId, {core.int max_results, core.int start_index}) { |
1866 var _url = null; | 1606 var _url = null; |
1867 var _queryParams = new core.Map(); | 1607 var _queryParams = new core.Map(); |
1868 var _uploadMedia = null; | 1608 var _uploadMedia = null; |
1869 var _uploadOptions = null; | 1609 var _uploadOptions = null; |
1870 var _downloadOptions = common.DownloadOptions.Metadata; | 1610 var _downloadOptions = commons.DownloadOptions.Metadata; |
1871 var _body = null; | 1611 var _body = null; |
1872 | 1612 |
1873 if (accountId == null) { | 1613 if (accountId == null) { |
1874 throw new core.ArgumentError("Parameter accountId is required."); | 1614 throw new core.ArgumentError("Parameter accountId is required."); |
1875 } | 1615 } |
1876 if (webPropertyId == null) { | 1616 if (webPropertyId == null) { |
1877 throw new core.ArgumentError("Parameter webPropertyId is required."); | 1617 throw new core.ArgumentError("Parameter webPropertyId is required."); |
1878 } | 1618 } |
1879 if (profileId == null) { | 1619 if (profileId == null) { |
1880 throw new core.ArgumentError("Parameter profileId is required."); | 1620 throw new core.ArgumentError("Parameter profileId is required."); |
1881 } | 1621 } |
1882 if (max_results != null) { | 1622 if (max_results != null) { |
1883 _queryParams["max-results"] = ["${max_results}"]; | 1623 _queryParams["max-results"] = ["${max_results}"]; |
1884 } | 1624 } |
1885 if (start_index != null) { | 1625 if (start_index != null) { |
1886 _queryParams["start-index"] = ["${start_index}"]; | 1626 _queryParams["start-index"] = ["${start_index}"]; |
1887 } | 1627 } |
1888 | 1628 |
1889 | 1629 |
1890 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/webproperties/' + common_internal.Escaper.ecapeVariable('$webPropert
yId') + '/profiles/' + common_internal.Escaper.ecapeVariable('$profileId') + '/e
xperiments'; | 1630 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId')
+ '/webproperties/' + commons.Escaper.ecapeVariable('$webPropertyId') + '/profil
es/' + commons.Escaper.ecapeVariable('$profileId') + '/experiments'; |
1891 | 1631 |
1892 var _response = _requester.request(_url, | 1632 var _response = _requester.request(_url, |
1893 "GET", | 1633 "GET", |
1894 body: _body, | 1634 body: _body, |
1895 queryParams: _queryParams, | 1635 queryParams: _queryParams, |
1896 uploadOptions: _uploadOptions, | 1636 uploadOptions: _uploadOptions, |
1897 uploadMedia: _uploadMedia, | 1637 uploadMedia: _uploadMedia, |
1898 downloadOptions: _downloadOptions); | 1638 downloadOptions: _downloadOptions); |
1899 return _response.then((data) => new Experiments.fromJson(data)); | 1639 return _response.then((data) => new Experiments.fromJson(data)); |
1900 } | 1640 } |
1901 | 1641 |
1902 /** | 1642 /** |
1903 * Update an existing experiment. This method supports patch semantics. | 1643 * Update an existing experiment. This method supports patch semantics. |
1904 * | 1644 * |
1905 * [request] - The metadata request object. | 1645 * [request] - The metadata request object. |
1906 * | 1646 * |
1907 * Request parameters: | 1647 * Request parameters: |
1908 * | 1648 * |
1909 * [accountId] - Account ID of the experiment to update. | 1649 * [accountId] - Account ID of the experiment to update. |
1910 * | 1650 * |
1911 * [webPropertyId] - Web property ID of the experiment to update. | 1651 * [webPropertyId] - Web property ID of the experiment to update. |
1912 * | 1652 * |
1913 * [profileId] - View (Profile) ID of the experiment to update. | 1653 * [profileId] - View (Profile) ID of the experiment to update. |
1914 * | 1654 * |
1915 * [experimentId] - Experiment ID of the experiment to update. | 1655 * [experimentId] - Experiment ID of the experiment to update. |
1916 * | 1656 * |
1917 * Completes with a [Experiment]. | 1657 * Completes with a [Experiment]. |
1918 * | 1658 * |
1919 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 1659 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
1920 * error. | 1660 * error. |
1921 * | 1661 * |
1922 * If the used [http.Client] completes with an error when making a REST call, | 1662 * If the used [http.Client] completes with an error when making a REST call, |
1923 * this method will complete with the same error. | 1663 * this method will complete with the same error. |
1924 */ | 1664 */ |
1925 async.Future<Experiment> patch(Experiment request, core.String accountId, core
.String webPropertyId, core.String profileId, core.String experimentId) { | 1665 async.Future<Experiment> patch(Experiment request, core.String accountId, core
.String webPropertyId, core.String profileId, core.String experimentId) { |
1926 var _url = null; | 1666 var _url = null; |
1927 var _queryParams = new core.Map(); | 1667 var _queryParams = new core.Map(); |
1928 var _uploadMedia = null; | 1668 var _uploadMedia = null; |
1929 var _uploadOptions = null; | 1669 var _uploadOptions = null; |
1930 var _downloadOptions = common.DownloadOptions.Metadata; | 1670 var _downloadOptions = commons.DownloadOptions.Metadata; |
1931 var _body = null; | 1671 var _body = null; |
1932 | 1672 |
1933 if (request != null) { | 1673 if (request != null) { |
1934 _body = convert.JSON.encode((request).toJson()); | 1674 _body = convert.JSON.encode((request).toJson()); |
1935 } | 1675 } |
1936 if (accountId == null) { | 1676 if (accountId == null) { |
1937 throw new core.ArgumentError("Parameter accountId is required."); | 1677 throw new core.ArgumentError("Parameter accountId is required."); |
1938 } | 1678 } |
1939 if (webPropertyId == null) { | 1679 if (webPropertyId == null) { |
1940 throw new core.ArgumentError("Parameter webPropertyId is required."); | 1680 throw new core.ArgumentError("Parameter webPropertyId is required."); |
1941 } | 1681 } |
1942 if (profileId == null) { | 1682 if (profileId == null) { |
1943 throw new core.ArgumentError("Parameter profileId is required."); | 1683 throw new core.ArgumentError("Parameter profileId is required."); |
1944 } | 1684 } |
1945 if (experimentId == null) { | 1685 if (experimentId == null) { |
1946 throw new core.ArgumentError("Parameter experimentId is required."); | 1686 throw new core.ArgumentError("Parameter experimentId is required."); |
1947 } | 1687 } |
1948 | 1688 |
1949 | 1689 |
1950 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/webproperties/' + common_internal.Escaper.ecapeVariable('$webPropert
yId') + '/profiles/' + common_internal.Escaper.ecapeVariable('$profileId') + '/e
xperiments/' + common_internal.Escaper.ecapeVariable('$experimentId'); | 1690 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId')
+ '/webproperties/' + commons.Escaper.ecapeVariable('$webPropertyId') + '/profil
es/' + commons.Escaper.ecapeVariable('$profileId') + '/experiments/' + commons.E
scaper.ecapeVariable('$experimentId'); |
1951 | 1691 |
1952 var _response = _requester.request(_url, | 1692 var _response = _requester.request(_url, |
1953 "PATCH", | 1693 "PATCH", |
1954 body: _body, | 1694 body: _body, |
1955 queryParams: _queryParams, | 1695 queryParams: _queryParams, |
1956 uploadOptions: _uploadOptions, | 1696 uploadOptions: _uploadOptions, |
1957 uploadMedia: _uploadMedia, | 1697 uploadMedia: _uploadMedia, |
1958 downloadOptions: _downloadOptions); | 1698 downloadOptions: _downloadOptions); |
1959 return _response.then((data) => new Experiment.fromJson(data)); | 1699 return _response.then((data) => new Experiment.fromJson(data)); |
1960 } | 1700 } |
1961 | 1701 |
1962 /** | 1702 /** |
1963 * Update an existing experiment. | 1703 * Update an existing experiment. |
1964 * | 1704 * |
1965 * [request] - The metadata request object. | 1705 * [request] - The metadata request object. |
1966 * | 1706 * |
1967 * Request parameters: | 1707 * Request parameters: |
1968 * | 1708 * |
1969 * [accountId] - Account ID of the experiment to update. | 1709 * [accountId] - Account ID of the experiment to update. |
1970 * | 1710 * |
1971 * [webPropertyId] - Web property ID of the experiment to update. | 1711 * [webPropertyId] - Web property ID of the experiment to update. |
1972 * | 1712 * |
1973 * [profileId] - View (Profile) ID of the experiment to update. | 1713 * [profileId] - View (Profile) ID of the experiment to update. |
1974 * | 1714 * |
1975 * [experimentId] - Experiment ID of the experiment to update. | 1715 * [experimentId] - Experiment ID of the experiment to update. |
1976 * | 1716 * |
1977 * Completes with a [Experiment]. | 1717 * Completes with a [Experiment]. |
1978 * | 1718 * |
1979 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 1719 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
1980 * error. | 1720 * error. |
1981 * | 1721 * |
1982 * If the used [http.Client] completes with an error when making a REST call, | 1722 * If the used [http.Client] completes with an error when making a REST call, |
1983 * this method will complete with the same error. | 1723 * this method will complete with the same error. |
1984 */ | 1724 */ |
1985 async.Future<Experiment> update(Experiment request, core.String accountId, cor
e.String webPropertyId, core.String profileId, core.String experimentId) { | 1725 async.Future<Experiment> update(Experiment request, core.String accountId, cor
e.String webPropertyId, core.String profileId, core.String experimentId) { |
1986 var _url = null; | 1726 var _url = null; |
1987 var _queryParams = new core.Map(); | 1727 var _queryParams = new core.Map(); |
1988 var _uploadMedia = null; | 1728 var _uploadMedia = null; |
1989 var _uploadOptions = null; | 1729 var _uploadOptions = null; |
1990 var _downloadOptions = common.DownloadOptions.Metadata; | 1730 var _downloadOptions = commons.DownloadOptions.Metadata; |
1991 var _body = null; | 1731 var _body = null; |
1992 | 1732 |
1993 if (request != null) { | 1733 if (request != null) { |
1994 _body = convert.JSON.encode((request).toJson()); | 1734 _body = convert.JSON.encode((request).toJson()); |
1995 } | 1735 } |
1996 if (accountId == null) { | 1736 if (accountId == null) { |
1997 throw new core.ArgumentError("Parameter accountId is required."); | 1737 throw new core.ArgumentError("Parameter accountId is required."); |
1998 } | 1738 } |
1999 if (webPropertyId == null) { | 1739 if (webPropertyId == null) { |
2000 throw new core.ArgumentError("Parameter webPropertyId is required."); | 1740 throw new core.ArgumentError("Parameter webPropertyId is required."); |
2001 } | 1741 } |
2002 if (profileId == null) { | 1742 if (profileId == null) { |
2003 throw new core.ArgumentError("Parameter profileId is required."); | 1743 throw new core.ArgumentError("Parameter profileId is required."); |
2004 } | 1744 } |
2005 if (experimentId == null) { | 1745 if (experimentId == null) { |
2006 throw new core.ArgumentError("Parameter experimentId is required."); | 1746 throw new core.ArgumentError("Parameter experimentId is required."); |
2007 } | 1747 } |
2008 | 1748 |
2009 | 1749 |
2010 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/webproperties/' + common_internal.Escaper.ecapeVariable('$webPropert
yId') + '/profiles/' + common_internal.Escaper.ecapeVariable('$profileId') + '/e
xperiments/' + common_internal.Escaper.ecapeVariable('$experimentId'); | 1750 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId')
+ '/webproperties/' + commons.Escaper.ecapeVariable('$webPropertyId') + '/profil
es/' + commons.Escaper.ecapeVariable('$profileId') + '/experiments/' + commons.E
scaper.ecapeVariable('$experimentId'); |
2011 | 1751 |
2012 var _response = _requester.request(_url, | 1752 var _response = _requester.request(_url, |
2013 "PUT", | 1753 "PUT", |
2014 body: _body, | 1754 body: _body, |
2015 queryParams: _queryParams, | 1755 queryParams: _queryParams, |
2016 uploadOptions: _uploadOptions, | 1756 uploadOptions: _uploadOptions, |
2017 uploadMedia: _uploadMedia, | 1757 uploadMedia: _uploadMedia, |
2018 downloadOptions: _downloadOptions); | 1758 downloadOptions: _downloadOptions); |
2019 return _response.then((data) => new Experiment.fromJson(data)); | 1759 return _response.then((data) => new Experiment.fromJson(data)); |
2020 } | 1760 } |
2021 | 1761 |
2022 } | 1762 } |
2023 | 1763 |
2024 | 1764 |
2025 /** Not documented yet. */ | |
2026 class ManagementFiltersResourceApi { | 1765 class ManagementFiltersResourceApi { |
2027 final common_internal.ApiRequester _requester; | 1766 final commons.ApiRequester _requester; |
2028 | 1767 |
2029 ManagementFiltersResourceApi(common_internal.ApiRequester client) : | 1768 ManagementFiltersResourceApi(commons.ApiRequester client) : |
2030 _requester = client; | 1769 _requester = client; |
2031 | 1770 |
2032 /** | 1771 /** |
2033 * Delete a filter. | 1772 * Delete a filter. |
2034 * | 1773 * |
2035 * Request parameters: | 1774 * Request parameters: |
2036 * | 1775 * |
2037 * [accountId] - Account ID to delete the filter for. | 1776 * [accountId] - Account ID to delete the filter for. |
2038 * | 1777 * |
2039 * [filterId] - ID of the filter to be deleted. | 1778 * [filterId] - ID of the filter to be deleted. |
2040 * | 1779 * |
2041 * Completes with a [Filter]. | 1780 * Completes with a [Filter]. |
2042 * | 1781 * |
2043 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 1782 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
2044 * error. | 1783 * error. |
2045 * | 1784 * |
2046 * If the used [http.Client] completes with an error when making a REST call, | 1785 * If the used [http.Client] completes with an error when making a REST call, |
2047 * this method will complete with the same error. | 1786 * this method will complete with the same error. |
2048 */ | 1787 */ |
2049 async.Future<Filter> delete(core.String accountId, core.String filterId) { | 1788 async.Future<Filter> delete(core.String accountId, core.String filterId) { |
2050 var _url = null; | 1789 var _url = null; |
2051 var _queryParams = new core.Map(); | 1790 var _queryParams = new core.Map(); |
2052 var _uploadMedia = null; | 1791 var _uploadMedia = null; |
2053 var _uploadOptions = null; | 1792 var _uploadOptions = null; |
2054 var _downloadOptions = common.DownloadOptions.Metadata; | 1793 var _downloadOptions = commons.DownloadOptions.Metadata; |
2055 var _body = null; | 1794 var _body = null; |
2056 | 1795 |
2057 if (accountId == null) { | 1796 if (accountId == null) { |
2058 throw new core.ArgumentError("Parameter accountId is required."); | 1797 throw new core.ArgumentError("Parameter accountId is required."); |
2059 } | 1798 } |
2060 if (filterId == null) { | 1799 if (filterId == null) { |
2061 throw new core.ArgumentError("Parameter filterId is required."); | 1800 throw new core.ArgumentError("Parameter filterId is required."); |
2062 } | 1801 } |
2063 | 1802 |
2064 | 1803 |
2065 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/filters/' + common_internal.Escaper.ecapeVariable('$filterId'); | 1804 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId')
+ '/filters/' + commons.Escaper.ecapeVariable('$filterId'); |
2066 | 1805 |
2067 var _response = _requester.request(_url, | 1806 var _response = _requester.request(_url, |
2068 "DELETE", | 1807 "DELETE", |
2069 body: _body, | 1808 body: _body, |
2070 queryParams: _queryParams, | 1809 queryParams: _queryParams, |
2071 uploadOptions: _uploadOptions, | 1810 uploadOptions: _uploadOptions, |
2072 uploadMedia: _uploadMedia, | 1811 uploadMedia: _uploadMedia, |
2073 downloadOptions: _downloadOptions); | 1812 downloadOptions: _downloadOptions); |
2074 return _response.then((data) => new Filter.fromJson(data)); | 1813 return _response.then((data) => new Filter.fromJson(data)); |
2075 } | 1814 } |
2076 | 1815 |
2077 /** | 1816 /** |
2078 * Returns a filters to which the user has access. | 1817 * Returns a filters to which the user has access. |
2079 * | 1818 * |
2080 * Request parameters: | 1819 * Request parameters: |
2081 * | 1820 * |
2082 * [accountId] - Account ID to retrieve filters for. | 1821 * [accountId] - Account ID to retrieve filters for. |
2083 * | 1822 * |
2084 * [filterId] - Filter ID to retrieve filters for. | 1823 * [filterId] - Filter ID to retrieve filters for. |
2085 * | 1824 * |
2086 * Completes with a [Filter]. | 1825 * Completes with a [Filter]. |
2087 * | 1826 * |
2088 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 1827 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
2089 * error. | 1828 * error. |
2090 * | 1829 * |
2091 * If the used [http.Client] completes with an error when making a REST call, | 1830 * If the used [http.Client] completes with an error when making a REST call, |
2092 * this method will complete with the same error. | 1831 * this method will complete with the same error. |
2093 */ | 1832 */ |
2094 async.Future<Filter> get(core.String accountId, core.String filterId) { | 1833 async.Future<Filter> get(core.String accountId, core.String filterId) { |
2095 var _url = null; | 1834 var _url = null; |
2096 var _queryParams = new core.Map(); | 1835 var _queryParams = new core.Map(); |
2097 var _uploadMedia = null; | 1836 var _uploadMedia = null; |
2098 var _uploadOptions = null; | 1837 var _uploadOptions = null; |
2099 var _downloadOptions = common.DownloadOptions.Metadata; | 1838 var _downloadOptions = commons.DownloadOptions.Metadata; |
2100 var _body = null; | 1839 var _body = null; |
2101 | 1840 |
2102 if (accountId == null) { | 1841 if (accountId == null) { |
2103 throw new core.ArgumentError("Parameter accountId is required."); | 1842 throw new core.ArgumentError("Parameter accountId is required."); |
2104 } | 1843 } |
2105 if (filterId == null) { | 1844 if (filterId == null) { |
2106 throw new core.ArgumentError("Parameter filterId is required."); | 1845 throw new core.ArgumentError("Parameter filterId is required."); |
2107 } | 1846 } |
2108 | 1847 |
2109 | 1848 |
2110 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/filters/' + common_internal.Escaper.ecapeVariable('$filterId'); | 1849 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId')
+ '/filters/' + commons.Escaper.ecapeVariable('$filterId'); |
2111 | 1850 |
2112 var _response = _requester.request(_url, | 1851 var _response = _requester.request(_url, |
2113 "GET", | 1852 "GET", |
2114 body: _body, | 1853 body: _body, |
2115 queryParams: _queryParams, | 1854 queryParams: _queryParams, |
2116 uploadOptions: _uploadOptions, | 1855 uploadOptions: _uploadOptions, |
2117 uploadMedia: _uploadMedia, | 1856 uploadMedia: _uploadMedia, |
2118 downloadOptions: _downloadOptions); | 1857 downloadOptions: _downloadOptions); |
2119 return _response.then((data) => new Filter.fromJson(data)); | 1858 return _response.then((data) => new Filter.fromJson(data)); |
2120 } | 1859 } |
2121 | 1860 |
2122 /** | 1861 /** |
2123 * Create a new filter. | 1862 * Create a new filter. |
2124 * | 1863 * |
2125 * [request] - The metadata request object. | 1864 * [request] - The metadata request object. |
2126 * | 1865 * |
2127 * Request parameters: | 1866 * Request parameters: |
2128 * | 1867 * |
2129 * [accountId] - Account ID to create filter for. | 1868 * [accountId] - Account ID to create filter for. |
2130 * | 1869 * |
2131 * Completes with a [Filter]. | 1870 * Completes with a [Filter]. |
2132 * | 1871 * |
2133 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 1872 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
2134 * error. | 1873 * error. |
2135 * | 1874 * |
2136 * If the used [http.Client] completes with an error when making a REST call, | 1875 * If the used [http.Client] completes with an error when making a REST call, |
2137 * this method will complete with the same error. | 1876 * this method will complete with the same error. |
2138 */ | 1877 */ |
2139 async.Future<Filter> insert(Filter request, core.String accountId) { | 1878 async.Future<Filter> insert(Filter request, core.String accountId) { |
2140 var _url = null; | 1879 var _url = null; |
2141 var _queryParams = new core.Map(); | 1880 var _queryParams = new core.Map(); |
2142 var _uploadMedia = null; | 1881 var _uploadMedia = null; |
2143 var _uploadOptions = null; | 1882 var _uploadOptions = null; |
2144 var _downloadOptions = common.DownloadOptions.Metadata; | 1883 var _downloadOptions = commons.DownloadOptions.Metadata; |
2145 var _body = null; | 1884 var _body = null; |
2146 | 1885 |
2147 if (request != null) { | 1886 if (request != null) { |
2148 _body = convert.JSON.encode((request).toJson()); | 1887 _body = convert.JSON.encode((request).toJson()); |
2149 } | 1888 } |
2150 if (accountId == null) { | 1889 if (accountId == null) { |
2151 throw new core.ArgumentError("Parameter accountId is required."); | 1890 throw new core.ArgumentError("Parameter accountId is required."); |
2152 } | 1891 } |
2153 | 1892 |
2154 | 1893 |
2155 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/filters'; | 1894 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId')
+ '/filters'; |
2156 | 1895 |
2157 var _response = _requester.request(_url, | 1896 var _response = _requester.request(_url, |
2158 "POST", | 1897 "POST", |
2159 body: _body, | 1898 body: _body, |
2160 queryParams: _queryParams, | 1899 queryParams: _queryParams, |
2161 uploadOptions: _uploadOptions, | 1900 uploadOptions: _uploadOptions, |
2162 uploadMedia: _uploadMedia, | 1901 uploadMedia: _uploadMedia, |
2163 downloadOptions: _downloadOptions); | 1902 downloadOptions: _downloadOptions); |
2164 return _response.then((data) => new Filter.fromJson(data)); | 1903 return _response.then((data) => new Filter.fromJson(data)); |
2165 } | 1904 } |
2166 | 1905 |
2167 /** | 1906 /** |
2168 * Lists all filters for an account | 1907 * Lists all filters for an account |
2169 * | 1908 * |
2170 * Request parameters: | 1909 * Request parameters: |
2171 * | 1910 * |
2172 * [accountId] - Account ID to retrieve filters for. | 1911 * [accountId] - Account ID to retrieve filters for. |
2173 * Value must have pattern "\d+". | 1912 * Value must have pattern "\d+". |
2174 * | 1913 * |
2175 * [max_results] - The maximum number of filters to include in this response. | 1914 * [max_results] - The maximum number of filters to include in this response. |
2176 * | 1915 * |
2177 * [start_index] - An index of the first entity to retrieve. Use this | 1916 * [start_index] - An index of the first entity to retrieve. Use this |
2178 * parameter as a pagination mechanism along with the max-results parameter. | 1917 * parameter as a pagination mechanism along with the max-results parameter. |
2179 * | 1918 * |
2180 * Completes with a [Filters]. | 1919 * Completes with a [Filters]. |
2181 * | 1920 * |
2182 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 1921 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
2183 * error. | 1922 * error. |
2184 * | 1923 * |
2185 * If the used [http.Client] completes with an error when making a REST call, | 1924 * If the used [http.Client] completes with an error when making a REST call, |
2186 * this method will complete with the same error. | 1925 * this method will complete with the same error. |
2187 */ | 1926 */ |
2188 async.Future<Filters> list(core.String accountId, {core.int max_results, core.
int start_index}) { | 1927 async.Future<Filters> list(core.String accountId, {core.int max_results, core.
int start_index}) { |
2189 var _url = null; | 1928 var _url = null; |
2190 var _queryParams = new core.Map(); | 1929 var _queryParams = new core.Map(); |
2191 var _uploadMedia = null; | 1930 var _uploadMedia = null; |
2192 var _uploadOptions = null; | 1931 var _uploadOptions = null; |
2193 var _downloadOptions = common.DownloadOptions.Metadata; | 1932 var _downloadOptions = commons.DownloadOptions.Metadata; |
2194 var _body = null; | 1933 var _body = null; |
2195 | 1934 |
2196 if (accountId == null) { | 1935 if (accountId == null) { |
2197 throw new core.ArgumentError("Parameter accountId is required."); | 1936 throw new core.ArgumentError("Parameter accountId is required."); |
2198 } | 1937 } |
2199 if (max_results != null) { | 1938 if (max_results != null) { |
2200 _queryParams["max-results"] = ["${max_results}"]; | 1939 _queryParams["max-results"] = ["${max_results}"]; |
2201 } | 1940 } |
2202 if (start_index != null) { | 1941 if (start_index != null) { |
2203 _queryParams["start-index"] = ["${start_index}"]; | 1942 _queryParams["start-index"] = ["${start_index}"]; |
2204 } | 1943 } |
2205 | 1944 |
2206 | 1945 |
2207 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/filters'; | 1946 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId')
+ '/filters'; |
2208 | 1947 |
2209 var _response = _requester.request(_url, | 1948 var _response = _requester.request(_url, |
2210 "GET", | 1949 "GET", |
2211 body: _body, | 1950 body: _body, |
2212 queryParams: _queryParams, | 1951 queryParams: _queryParams, |
2213 uploadOptions: _uploadOptions, | 1952 uploadOptions: _uploadOptions, |
2214 uploadMedia: _uploadMedia, | 1953 uploadMedia: _uploadMedia, |
2215 downloadOptions: _downloadOptions); | 1954 downloadOptions: _downloadOptions); |
2216 return _response.then((data) => new Filters.fromJson(data)); | 1955 return _response.then((data) => new Filters.fromJson(data)); |
2217 } | 1956 } |
2218 | 1957 |
2219 /** | 1958 /** |
2220 * Updates an existing filter. This method supports patch semantics. | 1959 * Updates an existing filter. This method supports patch semantics. |
2221 * | 1960 * |
2222 * [request] - The metadata request object. | 1961 * [request] - The metadata request object. |
2223 * | 1962 * |
2224 * Request parameters: | 1963 * Request parameters: |
2225 * | 1964 * |
2226 * [accountId] - Account ID to which the filter belongs. | 1965 * [accountId] - Account ID to which the filter belongs. |
2227 * | 1966 * |
2228 * [filterId] - ID of the filter to be updated. | 1967 * [filterId] - ID of the filter to be updated. |
2229 * | 1968 * |
2230 * Completes with a [Filter]. | 1969 * Completes with a [Filter]. |
2231 * | 1970 * |
2232 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 1971 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
2233 * error. | 1972 * error. |
2234 * | 1973 * |
2235 * If the used [http.Client] completes with an error when making a REST call, | 1974 * If the used [http.Client] completes with an error when making a REST call, |
2236 * this method will complete with the same error. | 1975 * this method will complete with the same error. |
2237 */ | 1976 */ |
2238 async.Future<Filter> patch(Filter request, core.String accountId, core.String
filterId) { | 1977 async.Future<Filter> patch(Filter request, core.String accountId, core.String
filterId) { |
2239 var _url = null; | 1978 var _url = null; |
2240 var _queryParams = new core.Map(); | 1979 var _queryParams = new core.Map(); |
2241 var _uploadMedia = null; | 1980 var _uploadMedia = null; |
2242 var _uploadOptions = null; | 1981 var _uploadOptions = null; |
2243 var _downloadOptions = common.DownloadOptions.Metadata; | 1982 var _downloadOptions = commons.DownloadOptions.Metadata; |
2244 var _body = null; | 1983 var _body = null; |
2245 | 1984 |
2246 if (request != null) { | 1985 if (request != null) { |
2247 _body = convert.JSON.encode((request).toJson()); | 1986 _body = convert.JSON.encode((request).toJson()); |
2248 } | 1987 } |
2249 if (accountId == null) { | 1988 if (accountId == null) { |
2250 throw new core.ArgumentError("Parameter accountId is required."); | 1989 throw new core.ArgumentError("Parameter accountId is required."); |
2251 } | 1990 } |
2252 if (filterId == null) { | 1991 if (filterId == null) { |
2253 throw new core.ArgumentError("Parameter filterId is required."); | 1992 throw new core.ArgumentError("Parameter filterId is required."); |
2254 } | 1993 } |
2255 | 1994 |
2256 | 1995 |
2257 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/filters/' + common_internal.Escaper.ecapeVariable('$filterId'); | 1996 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId')
+ '/filters/' + commons.Escaper.ecapeVariable('$filterId'); |
2258 | 1997 |
2259 var _response = _requester.request(_url, | 1998 var _response = _requester.request(_url, |
2260 "PATCH", | 1999 "PATCH", |
2261 body: _body, | 2000 body: _body, |
2262 queryParams: _queryParams, | 2001 queryParams: _queryParams, |
2263 uploadOptions: _uploadOptions, | 2002 uploadOptions: _uploadOptions, |
2264 uploadMedia: _uploadMedia, | 2003 uploadMedia: _uploadMedia, |
2265 downloadOptions: _downloadOptions); | 2004 downloadOptions: _downloadOptions); |
2266 return _response.then((data) => new Filter.fromJson(data)); | 2005 return _response.then((data) => new Filter.fromJson(data)); |
2267 } | 2006 } |
2268 | 2007 |
2269 /** | 2008 /** |
2270 * Updates an existing filter. | 2009 * Updates an existing filter. |
2271 * | 2010 * |
2272 * [request] - The metadata request object. | 2011 * [request] - The metadata request object. |
2273 * | 2012 * |
2274 * Request parameters: | 2013 * Request parameters: |
2275 * | 2014 * |
2276 * [accountId] - Account ID to which the filter belongs. | 2015 * [accountId] - Account ID to which the filter belongs. |
2277 * | 2016 * |
2278 * [filterId] - ID of the filter to be updated. | 2017 * [filterId] - ID of the filter to be updated. |
2279 * | 2018 * |
2280 * Completes with a [Filter]. | 2019 * Completes with a [Filter]. |
2281 * | 2020 * |
2282 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 2021 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
2283 * error. | 2022 * error. |
2284 * | 2023 * |
2285 * If the used [http.Client] completes with an error when making a REST call, | 2024 * If the used [http.Client] completes with an error when making a REST call, |
2286 * this method will complete with the same error. | 2025 * this method will complete with the same error. |
2287 */ | 2026 */ |
2288 async.Future<Filter> update(Filter request, core.String accountId, core.String
filterId) { | 2027 async.Future<Filter> update(Filter request, core.String accountId, core.String
filterId) { |
2289 var _url = null; | 2028 var _url = null; |
2290 var _queryParams = new core.Map(); | 2029 var _queryParams = new core.Map(); |
2291 var _uploadMedia = null; | 2030 var _uploadMedia = null; |
2292 var _uploadOptions = null; | 2031 var _uploadOptions = null; |
2293 var _downloadOptions = common.DownloadOptions.Metadata; | 2032 var _downloadOptions = commons.DownloadOptions.Metadata; |
2294 var _body = null; | 2033 var _body = null; |
2295 | 2034 |
2296 if (request != null) { | 2035 if (request != null) { |
2297 _body = convert.JSON.encode((request).toJson()); | 2036 _body = convert.JSON.encode((request).toJson()); |
2298 } | 2037 } |
2299 if (accountId == null) { | 2038 if (accountId == null) { |
2300 throw new core.ArgumentError("Parameter accountId is required."); | 2039 throw new core.ArgumentError("Parameter accountId is required."); |
2301 } | 2040 } |
2302 if (filterId == null) { | 2041 if (filterId == null) { |
2303 throw new core.ArgumentError("Parameter filterId is required."); | 2042 throw new core.ArgumentError("Parameter filterId is required."); |
2304 } | 2043 } |
2305 | 2044 |
2306 | 2045 |
2307 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/filters/' + common_internal.Escaper.ecapeVariable('$filterId'); | 2046 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId')
+ '/filters/' + commons.Escaper.ecapeVariable('$filterId'); |
2308 | 2047 |
2309 var _response = _requester.request(_url, | 2048 var _response = _requester.request(_url, |
2310 "PUT", | 2049 "PUT", |
2311 body: _body, | 2050 body: _body, |
2312 queryParams: _queryParams, | 2051 queryParams: _queryParams, |
2313 uploadOptions: _uploadOptions, | 2052 uploadOptions: _uploadOptions, |
2314 uploadMedia: _uploadMedia, | 2053 uploadMedia: _uploadMedia, |
2315 downloadOptions: _downloadOptions); | 2054 downloadOptions: _downloadOptions); |
2316 return _response.then((data) => new Filter.fromJson(data)); | 2055 return _response.then((data) => new Filter.fromJson(data)); |
2317 } | 2056 } |
2318 | 2057 |
2319 } | 2058 } |
2320 | 2059 |
2321 | 2060 |
2322 /** Not documented yet. */ | |
2323 class ManagementGoalsResourceApi { | 2061 class ManagementGoalsResourceApi { |
2324 final common_internal.ApiRequester _requester; | 2062 final commons.ApiRequester _requester; |
2325 | 2063 |
2326 ManagementGoalsResourceApi(common_internal.ApiRequester client) : | 2064 ManagementGoalsResourceApi(commons.ApiRequester client) : |
2327 _requester = client; | 2065 _requester = client; |
2328 | 2066 |
2329 /** | 2067 /** |
2330 * Gets a goal to which the user has access. | 2068 * Gets a goal to which the user has access. |
2331 * | 2069 * |
2332 * Request parameters: | 2070 * Request parameters: |
2333 * | 2071 * |
2334 * [accountId] - Account ID to retrieve the goal for. | 2072 * [accountId] - Account ID to retrieve the goal for. |
2335 * | 2073 * |
2336 * [webPropertyId] - Web property ID to retrieve the goal for. | 2074 * [webPropertyId] - Web property ID to retrieve the goal for. |
2337 * | 2075 * |
2338 * [profileId] - View (Profile) ID to retrieve the goal for. | 2076 * [profileId] - View (Profile) ID to retrieve the goal for. |
2339 * | 2077 * |
2340 * [goalId] - Goal ID to retrieve the goal for. | 2078 * [goalId] - Goal ID to retrieve the goal for. |
2341 * | 2079 * |
2342 * Completes with a [Goal]. | 2080 * Completes with a [Goal]. |
2343 * | 2081 * |
2344 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 2082 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
2345 * error. | 2083 * error. |
2346 * | 2084 * |
2347 * If the used [http.Client] completes with an error when making a REST call, | 2085 * If the used [http.Client] completes with an error when making a REST call, |
2348 * this method will complete with the same error. | 2086 * this method will complete with the same error. |
2349 */ | 2087 */ |
2350 async.Future<Goal> get(core.String accountId, core.String webPropertyId, core.
String profileId, core.String goalId) { | 2088 async.Future<Goal> get(core.String accountId, core.String webPropertyId, core.
String profileId, core.String goalId) { |
2351 var _url = null; | 2089 var _url = null; |
2352 var _queryParams = new core.Map(); | 2090 var _queryParams = new core.Map(); |
2353 var _uploadMedia = null; | 2091 var _uploadMedia = null; |
2354 var _uploadOptions = null; | 2092 var _uploadOptions = null; |
2355 var _downloadOptions = common.DownloadOptions.Metadata; | 2093 var _downloadOptions = commons.DownloadOptions.Metadata; |
2356 var _body = null; | 2094 var _body = null; |
2357 | 2095 |
2358 if (accountId == null) { | 2096 if (accountId == null) { |
2359 throw new core.ArgumentError("Parameter accountId is required."); | 2097 throw new core.ArgumentError("Parameter accountId is required."); |
2360 } | 2098 } |
2361 if (webPropertyId == null) { | 2099 if (webPropertyId == null) { |
2362 throw new core.ArgumentError("Parameter webPropertyId is required."); | 2100 throw new core.ArgumentError("Parameter webPropertyId is required."); |
2363 } | 2101 } |
2364 if (profileId == null) { | 2102 if (profileId == null) { |
2365 throw new core.ArgumentError("Parameter profileId is required."); | 2103 throw new core.ArgumentError("Parameter profileId is required."); |
2366 } | 2104 } |
2367 if (goalId == null) { | 2105 if (goalId == null) { |
2368 throw new core.ArgumentError("Parameter goalId is required."); | 2106 throw new core.ArgumentError("Parameter goalId is required."); |
2369 } | 2107 } |
2370 | 2108 |
2371 | 2109 |
2372 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/webproperties/' + common_internal.Escaper.ecapeVariable('$webPropert
yId') + '/profiles/' + common_internal.Escaper.ecapeVariable('$profileId') + '/g
oals/' + common_internal.Escaper.ecapeVariable('$goalId'); | 2110 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId')
+ '/webproperties/' + commons.Escaper.ecapeVariable('$webPropertyId') + '/profil
es/' + commons.Escaper.ecapeVariable('$profileId') + '/goals/' + commons.Escaper
.ecapeVariable('$goalId'); |
2373 | 2111 |
2374 var _response = _requester.request(_url, | 2112 var _response = _requester.request(_url, |
2375 "GET", | 2113 "GET", |
2376 body: _body, | 2114 body: _body, |
2377 queryParams: _queryParams, | 2115 queryParams: _queryParams, |
2378 uploadOptions: _uploadOptions, | 2116 uploadOptions: _uploadOptions, |
2379 uploadMedia: _uploadMedia, | 2117 uploadMedia: _uploadMedia, |
2380 downloadOptions: _downloadOptions); | 2118 downloadOptions: _downloadOptions); |
2381 return _response.then((data) => new Goal.fromJson(data)); | 2119 return _response.then((data) => new Goal.fromJson(data)); |
2382 } | 2120 } |
2383 | 2121 |
2384 /** | 2122 /** |
2385 * Create a new goal. | 2123 * Create a new goal. |
2386 * | 2124 * |
2387 * [request] - The metadata request object. | 2125 * [request] - The metadata request object. |
2388 * | 2126 * |
2389 * Request parameters: | 2127 * Request parameters: |
2390 * | 2128 * |
2391 * [accountId] - Account ID to create the goal for. | 2129 * [accountId] - Account ID to create the goal for. |
2392 * | 2130 * |
2393 * [webPropertyId] - Web property ID to create the goal for. | 2131 * [webPropertyId] - Web property ID to create the goal for. |
2394 * | 2132 * |
2395 * [profileId] - View (Profile) ID to create the goal for. | 2133 * [profileId] - View (Profile) ID to create the goal for. |
2396 * | 2134 * |
2397 * Completes with a [Goal]. | 2135 * Completes with a [Goal]. |
2398 * | 2136 * |
2399 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 2137 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
2400 * error. | 2138 * error. |
2401 * | 2139 * |
2402 * If the used [http.Client] completes with an error when making a REST call, | 2140 * If the used [http.Client] completes with an error when making a REST call, |
2403 * this method will complete with the same error. | 2141 * this method will complete with the same error. |
2404 */ | 2142 */ |
2405 async.Future<Goal> insert(Goal request, core.String accountId, core.String web
PropertyId, core.String profileId) { | 2143 async.Future<Goal> insert(Goal request, core.String accountId, core.String web
PropertyId, core.String profileId) { |
2406 var _url = null; | 2144 var _url = null; |
2407 var _queryParams = new core.Map(); | 2145 var _queryParams = new core.Map(); |
2408 var _uploadMedia = null; | 2146 var _uploadMedia = null; |
2409 var _uploadOptions = null; | 2147 var _uploadOptions = null; |
2410 var _downloadOptions = common.DownloadOptions.Metadata; | 2148 var _downloadOptions = commons.DownloadOptions.Metadata; |
2411 var _body = null; | 2149 var _body = null; |
2412 | 2150 |
2413 if (request != null) { | 2151 if (request != null) { |
2414 _body = convert.JSON.encode((request).toJson()); | 2152 _body = convert.JSON.encode((request).toJson()); |
2415 } | 2153 } |
2416 if (accountId == null) { | 2154 if (accountId == null) { |
2417 throw new core.ArgumentError("Parameter accountId is required."); | 2155 throw new core.ArgumentError("Parameter accountId is required."); |
2418 } | 2156 } |
2419 if (webPropertyId == null) { | 2157 if (webPropertyId == null) { |
2420 throw new core.ArgumentError("Parameter webPropertyId is required."); | 2158 throw new core.ArgumentError("Parameter webPropertyId is required."); |
2421 } | 2159 } |
2422 if (profileId == null) { | 2160 if (profileId == null) { |
2423 throw new core.ArgumentError("Parameter profileId is required."); | 2161 throw new core.ArgumentError("Parameter profileId is required."); |
2424 } | 2162 } |
2425 | 2163 |
2426 | 2164 |
2427 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/webproperties/' + common_internal.Escaper.ecapeVariable('$webPropert
yId') + '/profiles/' + common_internal.Escaper.ecapeVariable('$profileId') + '/g
oals'; | 2165 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId')
+ '/webproperties/' + commons.Escaper.ecapeVariable('$webPropertyId') + '/profil
es/' + commons.Escaper.ecapeVariable('$profileId') + '/goals'; |
2428 | 2166 |
2429 var _response = _requester.request(_url, | 2167 var _response = _requester.request(_url, |
2430 "POST", | 2168 "POST", |
2431 body: _body, | 2169 body: _body, |
2432 queryParams: _queryParams, | 2170 queryParams: _queryParams, |
2433 uploadOptions: _uploadOptions, | 2171 uploadOptions: _uploadOptions, |
2434 uploadMedia: _uploadMedia, | 2172 uploadMedia: _uploadMedia, |
2435 downloadOptions: _downloadOptions); | 2173 downloadOptions: _downloadOptions); |
2436 return _response.then((data) => new Goal.fromJson(data)); | 2174 return _response.then((data) => new Goal.fromJson(data)); |
2437 } | 2175 } |
(...skipping 15 matching lines...) Expand all Loading... |
2453 * specific view (profile) ID or '~all', which refers to all the views | 2191 * specific view (profile) ID or '~all', which refers to all the views |
2454 * (profiles) that user has access to. | 2192 * (profiles) that user has access to. |
2455 * | 2193 * |
2456 * [max_results] - The maximum number of goals to include in this response. | 2194 * [max_results] - The maximum number of goals to include in this response. |
2457 * | 2195 * |
2458 * [start_index] - An index of the first goal to retrieve. Use this parameter | 2196 * [start_index] - An index of the first goal to retrieve. Use this parameter |
2459 * as a pagination mechanism along with the max-results parameter. | 2197 * as a pagination mechanism along with the max-results parameter. |
2460 * | 2198 * |
2461 * Completes with a [Goals]. | 2199 * Completes with a [Goals]. |
2462 * | 2200 * |
2463 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 2201 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
2464 * error. | 2202 * error. |
2465 * | 2203 * |
2466 * If the used [http.Client] completes with an error when making a REST call, | 2204 * If the used [http.Client] completes with an error when making a REST call, |
2467 * this method will complete with the same error. | 2205 * this method will complete with the same error. |
2468 */ | 2206 */ |
2469 async.Future<Goals> list(core.String accountId, core.String webPropertyId, cor
e.String profileId, {core.int max_results, core.int start_index}) { | 2207 async.Future<Goals> list(core.String accountId, core.String webPropertyId, cor
e.String profileId, {core.int max_results, core.int start_index}) { |
2470 var _url = null; | 2208 var _url = null; |
2471 var _queryParams = new core.Map(); | 2209 var _queryParams = new core.Map(); |
2472 var _uploadMedia = null; | 2210 var _uploadMedia = null; |
2473 var _uploadOptions = null; | 2211 var _uploadOptions = null; |
2474 var _downloadOptions = common.DownloadOptions.Metadata; | 2212 var _downloadOptions = commons.DownloadOptions.Metadata; |
2475 var _body = null; | 2213 var _body = null; |
2476 | 2214 |
2477 if (accountId == null) { | 2215 if (accountId == null) { |
2478 throw new core.ArgumentError("Parameter accountId is required."); | 2216 throw new core.ArgumentError("Parameter accountId is required."); |
2479 } | 2217 } |
2480 if (webPropertyId == null) { | 2218 if (webPropertyId == null) { |
2481 throw new core.ArgumentError("Parameter webPropertyId is required."); | 2219 throw new core.ArgumentError("Parameter webPropertyId is required."); |
2482 } | 2220 } |
2483 if (profileId == null) { | 2221 if (profileId == null) { |
2484 throw new core.ArgumentError("Parameter profileId is required."); | 2222 throw new core.ArgumentError("Parameter profileId is required."); |
2485 } | 2223 } |
2486 if (max_results != null) { | 2224 if (max_results != null) { |
2487 _queryParams["max-results"] = ["${max_results}"]; | 2225 _queryParams["max-results"] = ["${max_results}"]; |
2488 } | 2226 } |
2489 if (start_index != null) { | 2227 if (start_index != null) { |
2490 _queryParams["start-index"] = ["${start_index}"]; | 2228 _queryParams["start-index"] = ["${start_index}"]; |
2491 } | 2229 } |
2492 | 2230 |
2493 | 2231 |
2494 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/webproperties/' + common_internal.Escaper.ecapeVariable('$webPropert
yId') + '/profiles/' + common_internal.Escaper.ecapeVariable('$profileId') + '/g
oals'; | 2232 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId')
+ '/webproperties/' + commons.Escaper.ecapeVariable('$webPropertyId') + '/profil
es/' + commons.Escaper.ecapeVariable('$profileId') + '/goals'; |
2495 | 2233 |
2496 var _response = _requester.request(_url, | 2234 var _response = _requester.request(_url, |
2497 "GET", | 2235 "GET", |
2498 body: _body, | 2236 body: _body, |
2499 queryParams: _queryParams, | 2237 queryParams: _queryParams, |
2500 uploadOptions: _uploadOptions, | 2238 uploadOptions: _uploadOptions, |
2501 uploadMedia: _uploadMedia, | 2239 uploadMedia: _uploadMedia, |
2502 downloadOptions: _downloadOptions); | 2240 downloadOptions: _downloadOptions); |
2503 return _response.then((data) => new Goals.fromJson(data)); | 2241 return _response.then((data) => new Goals.fromJson(data)); |
2504 } | 2242 } |
2505 | 2243 |
2506 /** | 2244 /** |
2507 * Updates an existing view (profile). This method supports patch semantics. | 2245 * Updates an existing view (profile). This method supports patch semantics. |
2508 * | 2246 * |
2509 * [request] - The metadata request object. | 2247 * [request] - The metadata request object. |
2510 * | 2248 * |
2511 * Request parameters: | 2249 * Request parameters: |
2512 * | 2250 * |
2513 * [accountId] - Account ID to update the goal. | 2251 * [accountId] - Account ID to update the goal. |
2514 * | 2252 * |
2515 * [webPropertyId] - Web property ID to update the goal. | 2253 * [webPropertyId] - Web property ID to update the goal. |
2516 * | 2254 * |
2517 * [profileId] - View (Profile) ID to update the goal. | 2255 * [profileId] - View (Profile) ID to update the goal. |
2518 * | 2256 * |
2519 * [goalId] - Index of the goal to be updated. | 2257 * [goalId] - Index of the goal to be updated. |
2520 * | 2258 * |
2521 * Completes with a [Goal]. | 2259 * Completes with a [Goal]. |
2522 * | 2260 * |
2523 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 2261 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
2524 * error. | 2262 * error. |
2525 * | 2263 * |
2526 * If the used [http.Client] completes with an error when making a REST call, | 2264 * If the used [http.Client] completes with an error when making a REST call, |
2527 * this method will complete with the same error. | 2265 * this method will complete with the same error. |
2528 */ | 2266 */ |
2529 async.Future<Goal> patch(Goal request, core.String accountId, core.String webP
ropertyId, core.String profileId, core.String goalId) { | 2267 async.Future<Goal> patch(Goal request, core.String accountId, core.String webP
ropertyId, core.String profileId, core.String goalId) { |
2530 var _url = null; | 2268 var _url = null; |
2531 var _queryParams = new core.Map(); | 2269 var _queryParams = new core.Map(); |
2532 var _uploadMedia = null; | 2270 var _uploadMedia = null; |
2533 var _uploadOptions = null; | 2271 var _uploadOptions = null; |
2534 var _downloadOptions = common.DownloadOptions.Metadata; | 2272 var _downloadOptions = commons.DownloadOptions.Metadata; |
2535 var _body = null; | 2273 var _body = null; |
2536 | 2274 |
2537 if (request != null) { | 2275 if (request != null) { |
2538 _body = convert.JSON.encode((request).toJson()); | 2276 _body = convert.JSON.encode((request).toJson()); |
2539 } | 2277 } |
2540 if (accountId == null) { | 2278 if (accountId == null) { |
2541 throw new core.ArgumentError("Parameter accountId is required."); | 2279 throw new core.ArgumentError("Parameter accountId is required."); |
2542 } | 2280 } |
2543 if (webPropertyId == null) { | 2281 if (webPropertyId == null) { |
2544 throw new core.ArgumentError("Parameter webPropertyId is required."); | 2282 throw new core.ArgumentError("Parameter webPropertyId is required."); |
2545 } | 2283 } |
2546 if (profileId == null) { | 2284 if (profileId == null) { |
2547 throw new core.ArgumentError("Parameter profileId is required."); | 2285 throw new core.ArgumentError("Parameter profileId is required."); |
2548 } | 2286 } |
2549 if (goalId == null) { | 2287 if (goalId == null) { |
2550 throw new core.ArgumentError("Parameter goalId is required."); | 2288 throw new core.ArgumentError("Parameter goalId is required."); |
2551 } | 2289 } |
2552 | 2290 |
2553 | 2291 |
2554 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/webproperties/' + common_internal.Escaper.ecapeVariable('$webPropert
yId') + '/profiles/' + common_internal.Escaper.ecapeVariable('$profileId') + '/g
oals/' + common_internal.Escaper.ecapeVariable('$goalId'); | 2292 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId')
+ '/webproperties/' + commons.Escaper.ecapeVariable('$webPropertyId') + '/profil
es/' + commons.Escaper.ecapeVariable('$profileId') + '/goals/' + commons.Escaper
.ecapeVariable('$goalId'); |
2555 | 2293 |
2556 var _response = _requester.request(_url, | 2294 var _response = _requester.request(_url, |
2557 "PATCH", | 2295 "PATCH", |
2558 body: _body, | 2296 body: _body, |
2559 queryParams: _queryParams, | 2297 queryParams: _queryParams, |
2560 uploadOptions: _uploadOptions, | 2298 uploadOptions: _uploadOptions, |
2561 uploadMedia: _uploadMedia, | 2299 uploadMedia: _uploadMedia, |
2562 downloadOptions: _downloadOptions); | 2300 downloadOptions: _downloadOptions); |
2563 return _response.then((data) => new Goal.fromJson(data)); | 2301 return _response.then((data) => new Goal.fromJson(data)); |
2564 } | 2302 } |
2565 | 2303 |
2566 /** | 2304 /** |
2567 * Updates an existing view (profile). | 2305 * Updates an existing view (profile). |
2568 * | 2306 * |
2569 * [request] - The metadata request object. | 2307 * [request] - The metadata request object. |
2570 * | 2308 * |
2571 * Request parameters: | 2309 * Request parameters: |
2572 * | 2310 * |
2573 * [accountId] - Account ID to update the goal. | 2311 * [accountId] - Account ID to update the goal. |
2574 * | 2312 * |
2575 * [webPropertyId] - Web property ID to update the goal. | 2313 * [webPropertyId] - Web property ID to update the goal. |
2576 * | 2314 * |
2577 * [profileId] - View (Profile) ID to update the goal. | 2315 * [profileId] - View (Profile) ID to update the goal. |
2578 * | 2316 * |
2579 * [goalId] - Index of the goal to be updated. | 2317 * [goalId] - Index of the goal to be updated. |
2580 * | 2318 * |
2581 * Completes with a [Goal]. | 2319 * Completes with a [Goal]. |
2582 * | 2320 * |
2583 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 2321 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
2584 * error. | 2322 * error. |
2585 * | 2323 * |
2586 * If the used [http.Client] completes with an error when making a REST call, | 2324 * If the used [http.Client] completes with an error when making a REST call, |
2587 * this method will complete with the same error. | 2325 * this method will complete with the same error. |
2588 */ | 2326 */ |
2589 async.Future<Goal> update(Goal request, core.String accountId, core.String web
PropertyId, core.String profileId, core.String goalId) { | 2327 async.Future<Goal> update(Goal request, core.String accountId, core.String web
PropertyId, core.String profileId, core.String goalId) { |
2590 var _url = null; | 2328 var _url = null; |
2591 var _queryParams = new core.Map(); | 2329 var _queryParams = new core.Map(); |
2592 var _uploadMedia = null; | 2330 var _uploadMedia = null; |
2593 var _uploadOptions = null; | 2331 var _uploadOptions = null; |
2594 var _downloadOptions = common.DownloadOptions.Metadata; | 2332 var _downloadOptions = commons.DownloadOptions.Metadata; |
2595 var _body = null; | 2333 var _body = null; |
2596 | 2334 |
2597 if (request != null) { | 2335 if (request != null) { |
2598 _body = convert.JSON.encode((request).toJson()); | 2336 _body = convert.JSON.encode((request).toJson()); |
2599 } | 2337 } |
2600 if (accountId == null) { | 2338 if (accountId == null) { |
2601 throw new core.ArgumentError("Parameter accountId is required."); | 2339 throw new core.ArgumentError("Parameter accountId is required."); |
2602 } | 2340 } |
2603 if (webPropertyId == null) { | 2341 if (webPropertyId == null) { |
2604 throw new core.ArgumentError("Parameter webPropertyId is required."); | 2342 throw new core.ArgumentError("Parameter webPropertyId is required."); |
2605 } | 2343 } |
2606 if (profileId == null) { | 2344 if (profileId == null) { |
2607 throw new core.ArgumentError("Parameter profileId is required."); | 2345 throw new core.ArgumentError("Parameter profileId is required."); |
2608 } | 2346 } |
2609 if (goalId == null) { | 2347 if (goalId == null) { |
2610 throw new core.ArgumentError("Parameter goalId is required."); | 2348 throw new core.ArgumentError("Parameter goalId is required."); |
2611 } | 2349 } |
2612 | 2350 |
2613 | 2351 |
2614 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/webproperties/' + common_internal.Escaper.ecapeVariable('$webPropert
yId') + '/profiles/' + common_internal.Escaper.ecapeVariable('$profileId') + '/g
oals/' + common_internal.Escaper.ecapeVariable('$goalId'); | 2352 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId')
+ '/webproperties/' + commons.Escaper.ecapeVariable('$webPropertyId') + '/profil
es/' + commons.Escaper.ecapeVariable('$profileId') + '/goals/' + commons.Escaper
.ecapeVariable('$goalId'); |
2615 | 2353 |
2616 var _response = _requester.request(_url, | 2354 var _response = _requester.request(_url, |
2617 "PUT", | 2355 "PUT", |
2618 body: _body, | 2356 body: _body, |
2619 queryParams: _queryParams, | 2357 queryParams: _queryParams, |
2620 uploadOptions: _uploadOptions, | 2358 uploadOptions: _uploadOptions, |
2621 uploadMedia: _uploadMedia, | 2359 uploadMedia: _uploadMedia, |
2622 downloadOptions: _downloadOptions); | 2360 downloadOptions: _downloadOptions); |
2623 return _response.then((data) => new Goal.fromJson(data)); | 2361 return _response.then((data) => new Goal.fromJson(data)); |
2624 } | 2362 } |
2625 | 2363 |
2626 } | 2364 } |
2627 | 2365 |
2628 | 2366 |
2629 /** Not documented yet. */ | |
2630 class ManagementProfileFilterLinksResourceApi { | 2367 class ManagementProfileFilterLinksResourceApi { |
2631 final common_internal.ApiRequester _requester; | 2368 final commons.ApiRequester _requester; |
2632 | 2369 |
2633 ManagementProfileFilterLinksResourceApi(common_internal.ApiRequester client) :
| 2370 ManagementProfileFilterLinksResourceApi(commons.ApiRequester client) : |
2634 _requester = client; | 2371 _requester = client; |
2635 | 2372 |
2636 /** | 2373 /** |
2637 * Delete a profile filter link. | 2374 * Delete a profile filter link. |
2638 * | 2375 * |
2639 * Request parameters: | 2376 * Request parameters: |
2640 * | 2377 * |
2641 * [accountId] - Account ID to which the profile filter link belongs. | 2378 * [accountId] - Account ID to which the profile filter link belongs. |
2642 * Value must have pattern "\d+". | 2379 * Value must have pattern "\d+". |
2643 * | 2380 * |
2644 * [webPropertyId] - Web property Id to which the profile filter link belongs. | 2381 * [webPropertyId] - Web property Id to which the profile filter link belongs. |
2645 * Value must have pattern "UA-(\d+)-(\d+)". | 2382 * Value must have pattern "UA-(\d+)-(\d+)". |
2646 * | 2383 * |
2647 * [profileId] - Profile ID to which the filter link belongs. | 2384 * [profileId] - Profile ID to which the filter link belongs. |
2648 * Value must have pattern "\d+". | 2385 * Value must have pattern "\d+". |
2649 * | 2386 * |
2650 * [linkId] - ID of the profile filter link to delete. | 2387 * [linkId] - ID of the profile filter link to delete. |
2651 * Value must have pattern "\d+:\d+". | 2388 * Value must have pattern "\d+:\d+". |
2652 * | 2389 * |
2653 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 2390 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
2654 * error. | 2391 * error. |
2655 * | 2392 * |
2656 * If the used [http.Client] completes with an error when making a REST call, | 2393 * If the used [http.Client] completes with an error when making a REST call, |
2657 * this method will complete with the same error. | 2394 * this method will complete with the same error. |
2658 */ | 2395 */ |
2659 async.Future delete(core.String accountId, core.String webPropertyId, core.Str
ing profileId, core.String linkId) { | 2396 async.Future delete(core.String accountId, core.String webPropertyId, core.Str
ing profileId, core.String linkId) { |
2660 var _url = null; | 2397 var _url = null; |
2661 var _queryParams = new core.Map(); | 2398 var _queryParams = new core.Map(); |
2662 var _uploadMedia = null; | 2399 var _uploadMedia = null; |
2663 var _uploadOptions = null; | 2400 var _uploadOptions = null; |
2664 var _downloadOptions = common.DownloadOptions.Metadata; | 2401 var _downloadOptions = commons.DownloadOptions.Metadata; |
2665 var _body = null; | 2402 var _body = null; |
2666 | 2403 |
2667 if (accountId == null) { | 2404 if (accountId == null) { |
2668 throw new core.ArgumentError("Parameter accountId is required."); | 2405 throw new core.ArgumentError("Parameter accountId is required."); |
2669 } | 2406 } |
2670 if (webPropertyId == null) { | 2407 if (webPropertyId == null) { |
2671 throw new core.ArgumentError("Parameter webPropertyId is required."); | 2408 throw new core.ArgumentError("Parameter webPropertyId is required."); |
2672 } | 2409 } |
2673 if (profileId == null) { | 2410 if (profileId == null) { |
2674 throw new core.ArgumentError("Parameter profileId is required."); | 2411 throw new core.ArgumentError("Parameter profileId is required."); |
2675 } | 2412 } |
2676 if (linkId == null) { | 2413 if (linkId == null) { |
2677 throw new core.ArgumentError("Parameter linkId is required."); | 2414 throw new core.ArgumentError("Parameter linkId is required."); |
2678 } | 2415 } |
2679 | 2416 |
2680 _downloadOptions = null; | 2417 _downloadOptions = null; |
2681 | 2418 |
2682 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/webproperties/' + common_internal.Escaper.ecapeVariable('$webPropert
yId') + '/profiles/' + common_internal.Escaper.ecapeVariable('$profileId') + '/p
rofileFilterLinks/' + common_internal.Escaper.ecapeVariable('$linkId'); | 2419 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId')
+ '/webproperties/' + commons.Escaper.ecapeVariable('$webPropertyId') + '/profil
es/' + commons.Escaper.ecapeVariable('$profileId') + '/profileFilterLinks/' + co
mmons.Escaper.ecapeVariable('$linkId'); |
2683 | 2420 |
2684 var _response = _requester.request(_url, | 2421 var _response = _requester.request(_url, |
2685 "DELETE", | 2422 "DELETE", |
2686 body: _body, | 2423 body: _body, |
2687 queryParams: _queryParams, | 2424 queryParams: _queryParams, |
2688 uploadOptions: _uploadOptions, | 2425 uploadOptions: _uploadOptions, |
2689 uploadMedia: _uploadMedia, | 2426 uploadMedia: _uploadMedia, |
2690 downloadOptions: _downloadOptions); | 2427 downloadOptions: _downloadOptions); |
2691 return _response.then((data) => null); | 2428 return _response.then((data) => null); |
2692 } | 2429 } |
(...skipping 10 matching lines...) Expand all Loading... |
2703 * Value must have pattern "UA-(\d+)-(\d+)". | 2440 * Value must have pattern "UA-(\d+)-(\d+)". |
2704 * | 2441 * |
2705 * [profileId] - Profile ID to retrieve filter link for. | 2442 * [profileId] - Profile ID to retrieve filter link for. |
2706 * Value must have pattern "\d+". | 2443 * Value must have pattern "\d+". |
2707 * | 2444 * |
2708 * [linkId] - ID of the profile filter link. | 2445 * [linkId] - ID of the profile filter link. |
2709 * Value must have pattern "\d+:\d+". | 2446 * Value must have pattern "\d+:\d+". |
2710 * | 2447 * |
2711 * Completes with a [ProfileFilterLink]. | 2448 * Completes with a [ProfileFilterLink]. |
2712 * | 2449 * |
2713 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 2450 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
2714 * error. | 2451 * error. |
2715 * | 2452 * |
2716 * If the used [http.Client] completes with an error when making a REST call, | 2453 * If the used [http.Client] completes with an error when making a REST call, |
2717 * this method will complete with the same error. | 2454 * this method will complete with the same error. |
2718 */ | 2455 */ |
2719 async.Future<ProfileFilterLink> get(core.String accountId, core.String webProp
ertyId, core.String profileId, core.String linkId) { | 2456 async.Future<ProfileFilterLink> get(core.String accountId, core.String webProp
ertyId, core.String profileId, core.String linkId) { |
2720 var _url = null; | 2457 var _url = null; |
2721 var _queryParams = new core.Map(); | 2458 var _queryParams = new core.Map(); |
2722 var _uploadMedia = null; | 2459 var _uploadMedia = null; |
2723 var _uploadOptions = null; | 2460 var _uploadOptions = null; |
2724 var _downloadOptions = common.DownloadOptions.Metadata; | 2461 var _downloadOptions = commons.DownloadOptions.Metadata; |
2725 var _body = null; | 2462 var _body = null; |
2726 | 2463 |
2727 if (accountId == null) { | 2464 if (accountId == null) { |
2728 throw new core.ArgumentError("Parameter accountId is required."); | 2465 throw new core.ArgumentError("Parameter accountId is required."); |
2729 } | 2466 } |
2730 if (webPropertyId == null) { | 2467 if (webPropertyId == null) { |
2731 throw new core.ArgumentError("Parameter webPropertyId is required."); | 2468 throw new core.ArgumentError("Parameter webPropertyId is required."); |
2732 } | 2469 } |
2733 if (profileId == null) { | 2470 if (profileId == null) { |
2734 throw new core.ArgumentError("Parameter profileId is required."); | 2471 throw new core.ArgumentError("Parameter profileId is required."); |
2735 } | 2472 } |
2736 if (linkId == null) { | 2473 if (linkId == null) { |
2737 throw new core.ArgumentError("Parameter linkId is required."); | 2474 throw new core.ArgumentError("Parameter linkId is required."); |
2738 } | 2475 } |
2739 | 2476 |
2740 | 2477 |
2741 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/webproperties/' + common_internal.Escaper.ecapeVariable('$webPropert
yId') + '/profiles/' + common_internal.Escaper.ecapeVariable('$profileId') + '/p
rofileFilterLinks/' + common_internal.Escaper.ecapeVariable('$linkId'); | 2478 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId')
+ '/webproperties/' + commons.Escaper.ecapeVariable('$webPropertyId') + '/profil
es/' + commons.Escaper.ecapeVariable('$profileId') + '/profileFilterLinks/' + co
mmons.Escaper.ecapeVariable('$linkId'); |
2742 | 2479 |
2743 var _response = _requester.request(_url, | 2480 var _response = _requester.request(_url, |
2744 "GET", | 2481 "GET", |
2745 body: _body, | 2482 body: _body, |
2746 queryParams: _queryParams, | 2483 queryParams: _queryParams, |
2747 uploadOptions: _uploadOptions, | 2484 uploadOptions: _uploadOptions, |
2748 uploadMedia: _uploadMedia, | 2485 uploadMedia: _uploadMedia, |
2749 downloadOptions: _downloadOptions); | 2486 downloadOptions: _downloadOptions); |
2750 return _response.then((data) => new ProfileFilterLink.fromJson(data)); | 2487 return _response.then((data) => new ProfileFilterLink.fromJson(data)); |
2751 } | 2488 } |
2752 | 2489 |
2753 /** | 2490 /** |
2754 * Create a new profile filter link. | 2491 * Create a new profile filter link. |
2755 * | 2492 * |
2756 * [request] - The metadata request object. | 2493 * [request] - The metadata request object. |
2757 * | 2494 * |
2758 * Request parameters: | 2495 * Request parameters: |
2759 * | 2496 * |
2760 * [accountId] - Account ID to create profile filter link for. | 2497 * [accountId] - Account ID to create profile filter link for. |
2761 * Value must have pattern "\d+". | 2498 * Value must have pattern "\d+". |
2762 * | 2499 * |
2763 * [webPropertyId] - Web property Id to create profile filter link for. | 2500 * [webPropertyId] - Web property Id to create profile filter link for. |
2764 * Value must have pattern "UA-(\d+)-(\d+)". | 2501 * Value must have pattern "UA-(\d+)-(\d+)". |
2765 * | 2502 * |
2766 * [profileId] - Profile ID to create filter link for. | 2503 * [profileId] - Profile ID to create filter link for. |
2767 * Value must have pattern "\d+". | 2504 * Value must have pattern "\d+". |
2768 * | 2505 * |
2769 * Completes with a [ProfileFilterLink]. | 2506 * Completes with a [ProfileFilterLink]. |
2770 * | 2507 * |
2771 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 2508 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
2772 * error. | 2509 * error. |
2773 * | 2510 * |
2774 * If the used [http.Client] completes with an error when making a REST call, | 2511 * If the used [http.Client] completes with an error when making a REST call, |
2775 * this method will complete with the same error. | 2512 * this method will complete with the same error. |
2776 */ | 2513 */ |
2777 async.Future<ProfileFilterLink> insert(ProfileFilterLink request, core.String
accountId, core.String webPropertyId, core.String profileId) { | 2514 async.Future<ProfileFilterLink> insert(ProfileFilterLink request, core.String
accountId, core.String webPropertyId, core.String profileId) { |
2778 var _url = null; | 2515 var _url = null; |
2779 var _queryParams = new core.Map(); | 2516 var _queryParams = new core.Map(); |
2780 var _uploadMedia = null; | 2517 var _uploadMedia = null; |
2781 var _uploadOptions = null; | 2518 var _uploadOptions = null; |
2782 var _downloadOptions = common.DownloadOptions.Metadata; | 2519 var _downloadOptions = commons.DownloadOptions.Metadata; |
2783 var _body = null; | 2520 var _body = null; |
2784 | 2521 |
2785 if (request != null) { | 2522 if (request != null) { |
2786 _body = convert.JSON.encode((request).toJson()); | 2523 _body = convert.JSON.encode((request).toJson()); |
2787 } | 2524 } |
2788 if (accountId == null) { | 2525 if (accountId == null) { |
2789 throw new core.ArgumentError("Parameter accountId is required."); | 2526 throw new core.ArgumentError("Parameter accountId is required."); |
2790 } | 2527 } |
2791 if (webPropertyId == null) { | 2528 if (webPropertyId == null) { |
2792 throw new core.ArgumentError("Parameter webPropertyId is required."); | 2529 throw new core.ArgumentError("Parameter webPropertyId is required."); |
2793 } | 2530 } |
2794 if (profileId == null) { | 2531 if (profileId == null) { |
2795 throw new core.ArgumentError("Parameter profileId is required."); | 2532 throw new core.ArgumentError("Parameter profileId is required."); |
2796 } | 2533 } |
2797 | 2534 |
2798 | 2535 |
2799 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/webproperties/' + common_internal.Escaper.ecapeVariable('$webPropert
yId') + '/profiles/' + common_internal.Escaper.ecapeVariable('$profileId') + '/p
rofileFilterLinks'; | 2536 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId')
+ '/webproperties/' + commons.Escaper.ecapeVariable('$webPropertyId') + '/profil
es/' + commons.Escaper.ecapeVariable('$profileId') + '/profileFilterLinks'; |
2800 | 2537 |
2801 var _response = _requester.request(_url, | 2538 var _response = _requester.request(_url, |
2802 "POST", | 2539 "POST", |
2803 body: _body, | 2540 body: _body, |
2804 queryParams: _queryParams, | 2541 queryParams: _queryParams, |
2805 uploadOptions: _uploadOptions, | 2542 uploadOptions: _uploadOptions, |
2806 uploadMedia: _uploadMedia, | 2543 uploadMedia: _uploadMedia, |
2807 downloadOptions: _downloadOptions); | 2544 downloadOptions: _downloadOptions); |
2808 return _response.then((data) => new ProfileFilterLink.fromJson(data)); | 2545 return _response.then((data) => new ProfileFilterLink.fromJson(data)); |
2809 } | 2546 } |
(...skipping 15 matching lines...) Expand all Loading... |
2825 * has access to. | 2562 * has access to. |
2826 * | 2563 * |
2827 * [max_results] - The maximum number of profile filter links to include in | 2564 * [max_results] - The maximum number of profile filter links to include in |
2828 * this response. | 2565 * this response. |
2829 * | 2566 * |
2830 * [start_index] - An index of the first entity to retrieve. Use this | 2567 * [start_index] - An index of the first entity to retrieve. Use this |
2831 * parameter as a pagination mechanism along with the max-results parameter. | 2568 * parameter as a pagination mechanism along with the max-results parameter. |
2832 * | 2569 * |
2833 * Completes with a [ProfileFilterLinks]. | 2570 * Completes with a [ProfileFilterLinks]. |
2834 * | 2571 * |
2835 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 2572 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
2836 * error. | 2573 * error. |
2837 * | 2574 * |
2838 * If the used [http.Client] completes with an error when making a REST call, | 2575 * If the used [http.Client] completes with an error when making a REST call, |
2839 * this method will complete with the same error. | 2576 * this method will complete with the same error. |
2840 */ | 2577 */ |
2841 async.Future<ProfileFilterLinks> list(core.String accountId, core.String webPr
opertyId, core.String profileId, {core.int max_results, core.int start_index}) { | 2578 async.Future<ProfileFilterLinks> list(core.String accountId, core.String webPr
opertyId, core.String profileId, {core.int max_results, core.int start_index}) { |
2842 var _url = null; | 2579 var _url = null; |
2843 var _queryParams = new core.Map(); | 2580 var _queryParams = new core.Map(); |
2844 var _uploadMedia = null; | 2581 var _uploadMedia = null; |
2845 var _uploadOptions = null; | 2582 var _uploadOptions = null; |
2846 var _downloadOptions = common.DownloadOptions.Metadata; | 2583 var _downloadOptions = commons.DownloadOptions.Metadata; |
2847 var _body = null; | 2584 var _body = null; |
2848 | 2585 |
2849 if (accountId == null) { | 2586 if (accountId == null) { |
2850 throw new core.ArgumentError("Parameter accountId is required."); | 2587 throw new core.ArgumentError("Parameter accountId is required."); |
2851 } | 2588 } |
2852 if (webPropertyId == null) { | 2589 if (webPropertyId == null) { |
2853 throw new core.ArgumentError("Parameter webPropertyId is required."); | 2590 throw new core.ArgumentError("Parameter webPropertyId is required."); |
2854 } | 2591 } |
2855 if (profileId == null) { | 2592 if (profileId == null) { |
2856 throw new core.ArgumentError("Parameter profileId is required."); | 2593 throw new core.ArgumentError("Parameter profileId is required."); |
2857 } | 2594 } |
2858 if (max_results != null) { | 2595 if (max_results != null) { |
2859 _queryParams["max-results"] = ["${max_results}"]; | 2596 _queryParams["max-results"] = ["${max_results}"]; |
2860 } | 2597 } |
2861 if (start_index != null) { | 2598 if (start_index != null) { |
2862 _queryParams["start-index"] = ["${start_index}"]; | 2599 _queryParams["start-index"] = ["${start_index}"]; |
2863 } | 2600 } |
2864 | 2601 |
2865 | 2602 |
2866 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/webproperties/' + common_internal.Escaper.ecapeVariable('$webPropert
yId') + '/profiles/' + common_internal.Escaper.ecapeVariable('$profileId') + '/p
rofileFilterLinks'; | 2603 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId')
+ '/webproperties/' + commons.Escaper.ecapeVariable('$webPropertyId') + '/profil
es/' + commons.Escaper.ecapeVariable('$profileId') + '/profileFilterLinks'; |
2867 | 2604 |
2868 var _response = _requester.request(_url, | 2605 var _response = _requester.request(_url, |
2869 "GET", | 2606 "GET", |
2870 body: _body, | 2607 body: _body, |
2871 queryParams: _queryParams, | 2608 queryParams: _queryParams, |
2872 uploadOptions: _uploadOptions, | 2609 uploadOptions: _uploadOptions, |
2873 uploadMedia: _uploadMedia, | 2610 uploadMedia: _uploadMedia, |
2874 downloadOptions: _downloadOptions); | 2611 downloadOptions: _downloadOptions); |
2875 return _response.then((data) => new ProfileFilterLinks.fromJson(data)); | 2612 return _response.then((data) => new ProfileFilterLinks.fromJson(data)); |
2876 } | 2613 } |
(...skipping 13 matching lines...) Expand all Loading... |
2890 * Value must have pattern "UA-(\d+)-(\d+)". | 2627 * Value must have pattern "UA-(\d+)-(\d+)". |
2891 * | 2628 * |
2892 * [profileId] - Profile ID to which filter link belongs | 2629 * [profileId] - Profile ID to which filter link belongs |
2893 * Value must have pattern "\d+". | 2630 * Value must have pattern "\d+". |
2894 * | 2631 * |
2895 * [linkId] - ID of the profile filter link to be updated. | 2632 * [linkId] - ID of the profile filter link to be updated. |
2896 * Value must have pattern "\d+:\d+". | 2633 * Value must have pattern "\d+:\d+". |
2897 * | 2634 * |
2898 * Completes with a [ProfileFilterLink]. | 2635 * Completes with a [ProfileFilterLink]. |
2899 * | 2636 * |
2900 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 2637 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
2901 * error. | 2638 * error. |
2902 * | 2639 * |
2903 * If the used [http.Client] completes with an error when making a REST call, | 2640 * If the used [http.Client] completes with an error when making a REST call, |
2904 * this method will complete with the same error. | 2641 * this method will complete with the same error. |
2905 */ | 2642 */ |
2906 async.Future<ProfileFilterLink> patch(ProfileFilterLink request, core.String a
ccountId, core.String webPropertyId, core.String profileId, core.String linkId)
{ | 2643 async.Future<ProfileFilterLink> patch(ProfileFilterLink request, core.String a
ccountId, core.String webPropertyId, core.String profileId, core.String linkId)
{ |
2907 var _url = null; | 2644 var _url = null; |
2908 var _queryParams = new core.Map(); | 2645 var _queryParams = new core.Map(); |
2909 var _uploadMedia = null; | 2646 var _uploadMedia = null; |
2910 var _uploadOptions = null; | 2647 var _uploadOptions = null; |
2911 var _downloadOptions = common.DownloadOptions.Metadata; | 2648 var _downloadOptions = commons.DownloadOptions.Metadata; |
2912 var _body = null; | 2649 var _body = null; |
2913 | 2650 |
2914 if (request != null) { | 2651 if (request != null) { |
2915 _body = convert.JSON.encode((request).toJson()); | 2652 _body = convert.JSON.encode((request).toJson()); |
2916 } | 2653 } |
2917 if (accountId == null) { | 2654 if (accountId == null) { |
2918 throw new core.ArgumentError("Parameter accountId is required."); | 2655 throw new core.ArgumentError("Parameter accountId is required."); |
2919 } | 2656 } |
2920 if (webPropertyId == null) { | 2657 if (webPropertyId == null) { |
2921 throw new core.ArgumentError("Parameter webPropertyId is required."); | 2658 throw new core.ArgumentError("Parameter webPropertyId is required."); |
2922 } | 2659 } |
2923 if (profileId == null) { | 2660 if (profileId == null) { |
2924 throw new core.ArgumentError("Parameter profileId is required."); | 2661 throw new core.ArgumentError("Parameter profileId is required."); |
2925 } | 2662 } |
2926 if (linkId == null) { | 2663 if (linkId == null) { |
2927 throw new core.ArgumentError("Parameter linkId is required."); | 2664 throw new core.ArgumentError("Parameter linkId is required."); |
2928 } | 2665 } |
2929 | 2666 |
2930 | 2667 |
2931 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/webproperties/' + common_internal.Escaper.ecapeVariable('$webPropert
yId') + '/profiles/' + common_internal.Escaper.ecapeVariable('$profileId') + '/p
rofileFilterLinks/' + common_internal.Escaper.ecapeVariable('$linkId'); | 2668 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId')
+ '/webproperties/' + commons.Escaper.ecapeVariable('$webPropertyId') + '/profil
es/' + commons.Escaper.ecapeVariable('$profileId') + '/profileFilterLinks/' + co
mmons.Escaper.ecapeVariable('$linkId'); |
2932 | 2669 |
2933 var _response = _requester.request(_url, | 2670 var _response = _requester.request(_url, |
2934 "PATCH", | 2671 "PATCH", |
2935 body: _body, | 2672 body: _body, |
2936 queryParams: _queryParams, | 2673 queryParams: _queryParams, |
2937 uploadOptions: _uploadOptions, | 2674 uploadOptions: _uploadOptions, |
2938 uploadMedia: _uploadMedia, | 2675 uploadMedia: _uploadMedia, |
2939 downloadOptions: _downloadOptions); | 2676 downloadOptions: _downloadOptions); |
2940 return _response.then((data) => new ProfileFilterLink.fromJson(data)); | 2677 return _response.then((data) => new ProfileFilterLink.fromJson(data)); |
2941 } | 2678 } |
(...skipping 12 matching lines...) Expand all Loading... |
2954 * Value must have pattern "UA-(\d+)-(\d+)". | 2691 * Value must have pattern "UA-(\d+)-(\d+)". |
2955 * | 2692 * |
2956 * [profileId] - Profile ID to which filter link belongs | 2693 * [profileId] - Profile ID to which filter link belongs |
2957 * Value must have pattern "\d+". | 2694 * Value must have pattern "\d+". |
2958 * | 2695 * |
2959 * [linkId] - ID of the profile filter link to be updated. | 2696 * [linkId] - ID of the profile filter link to be updated. |
2960 * Value must have pattern "\d+:\d+". | 2697 * Value must have pattern "\d+:\d+". |
2961 * | 2698 * |
2962 * Completes with a [ProfileFilterLink]. | 2699 * Completes with a [ProfileFilterLink]. |
2963 * | 2700 * |
2964 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 2701 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
2965 * error. | 2702 * error. |
2966 * | 2703 * |
2967 * If the used [http.Client] completes with an error when making a REST call, | 2704 * If the used [http.Client] completes with an error when making a REST call, |
2968 * this method will complete with the same error. | 2705 * this method will complete with the same error. |
2969 */ | 2706 */ |
2970 async.Future<ProfileFilterLink> update(ProfileFilterLink request, core.String
accountId, core.String webPropertyId, core.String profileId, core.String linkId)
{ | 2707 async.Future<ProfileFilterLink> update(ProfileFilterLink request, core.String
accountId, core.String webPropertyId, core.String profileId, core.String linkId)
{ |
2971 var _url = null; | 2708 var _url = null; |
2972 var _queryParams = new core.Map(); | 2709 var _queryParams = new core.Map(); |
2973 var _uploadMedia = null; | 2710 var _uploadMedia = null; |
2974 var _uploadOptions = null; | 2711 var _uploadOptions = null; |
2975 var _downloadOptions = common.DownloadOptions.Metadata; | 2712 var _downloadOptions = commons.DownloadOptions.Metadata; |
2976 var _body = null; | 2713 var _body = null; |
2977 | 2714 |
2978 if (request != null) { | 2715 if (request != null) { |
2979 _body = convert.JSON.encode((request).toJson()); | 2716 _body = convert.JSON.encode((request).toJson()); |
2980 } | 2717 } |
2981 if (accountId == null) { | 2718 if (accountId == null) { |
2982 throw new core.ArgumentError("Parameter accountId is required."); | 2719 throw new core.ArgumentError("Parameter accountId is required."); |
2983 } | 2720 } |
2984 if (webPropertyId == null) { | 2721 if (webPropertyId == null) { |
2985 throw new core.ArgumentError("Parameter webPropertyId is required."); | 2722 throw new core.ArgumentError("Parameter webPropertyId is required."); |
2986 } | 2723 } |
2987 if (profileId == null) { | 2724 if (profileId == null) { |
2988 throw new core.ArgumentError("Parameter profileId is required."); | 2725 throw new core.ArgumentError("Parameter profileId is required."); |
2989 } | 2726 } |
2990 if (linkId == null) { | 2727 if (linkId == null) { |
2991 throw new core.ArgumentError("Parameter linkId is required."); | 2728 throw new core.ArgumentError("Parameter linkId is required."); |
2992 } | 2729 } |
2993 | 2730 |
2994 | 2731 |
2995 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/webproperties/' + common_internal.Escaper.ecapeVariable('$webPropert
yId') + '/profiles/' + common_internal.Escaper.ecapeVariable('$profileId') + '/p
rofileFilterLinks/' + common_internal.Escaper.ecapeVariable('$linkId'); | 2732 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId')
+ '/webproperties/' + commons.Escaper.ecapeVariable('$webPropertyId') + '/profil
es/' + commons.Escaper.ecapeVariable('$profileId') + '/profileFilterLinks/' + co
mmons.Escaper.ecapeVariable('$linkId'); |
2996 | 2733 |
2997 var _response = _requester.request(_url, | 2734 var _response = _requester.request(_url, |
2998 "PUT", | 2735 "PUT", |
2999 body: _body, | 2736 body: _body, |
3000 queryParams: _queryParams, | 2737 queryParams: _queryParams, |
3001 uploadOptions: _uploadOptions, | 2738 uploadOptions: _uploadOptions, |
3002 uploadMedia: _uploadMedia, | 2739 uploadMedia: _uploadMedia, |
3003 downloadOptions: _downloadOptions); | 2740 downloadOptions: _downloadOptions); |
3004 return _response.then((data) => new ProfileFilterLink.fromJson(data)); | 2741 return _response.then((data) => new ProfileFilterLink.fromJson(data)); |
3005 } | 2742 } |
3006 | 2743 |
3007 } | 2744 } |
3008 | 2745 |
3009 | 2746 |
3010 /** Not documented yet. */ | |
3011 class ManagementProfileUserLinksResourceApi { | 2747 class ManagementProfileUserLinksResourceApi { |
3012 final common_internal.ApiRequester _requester; | 2748 final commons.ApiRequester _requester; |
3013 | 2749 |
3014 ManagementProfileUserLinksResourceApi(common_internal.ApiRequester client) : | 2750 ManagementProfileUserLinksResourceApi(commons.ApiRequester client) : |
3015 _requester = client; | 2751 _requester = client; |
3016 | 2752 |
3017 /** | 2753 /** |
3018 * Removes a user from the given view (profile). | 2754 * Removes a user from the given view (profile). |
3019 * | 2755 * |
3020 * Request parameters: | 2756 * Request parameters: |
3021 * | 2757 * |
3022 * [accountId] - Account ID to delete the user link for. | 2758 * [accountId] - Account ID to delete the user link for. |
3023 * | 2759 * |
3024 * [webPropertyId] - Web Property ID to delete the user link for. | 2760 * [webPropertyId] - Web Property ID to delete the user link for. |
3025 * | 2761 * |
3026 * [profileId] - View (Profile) ID to delete the user link for. | 2762 * [profileId] - View (Profile) ID to delete the user link for. |
3027 * | 2763 * |
3028 * [linkId] - Link ID to delete the user link for. | 2764 * [linkId] - Link ID to delete the user link for. |
3029 * | 2765 * |
3030 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 2766 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
3031 * error. | 2767 * error. |
3032 * | 2768 * |
3033 * If the used [http.Client] completes with an error when making a REST call, | 2769 * If the used [http.Client] completes with an error when making a REST call, |
3034 * this method will complete with the same error. | 2770 * this method will complete with the same error. |
3035 */ | 2771 */ |
3036 async.Future delete(core.String accountId, core.String webPropertyId, core.Str
ing profileId, core.String linkId) { | 2772 async.Future delete(core.String accountId, core.String webPropertyId, core.Str
ing profileId, core.String linkId) { |
3037 var _url = null; | 2773 var _url = null; |
3038 var _queryParams = new core.Map(); | 2774 var _queryParams = new core.Map(); |
3039 var _uploadMedia = null; | 2775 var _uploadMedia = null; |
3040 var _uploadOptions = null; | 2776 var _uploadOptions = null; |
3041 var _downloadOptions = common.DownloadOptions.Metadata; | 2777 var _downloadOptions = commons.DownloadOptions.Metadata; |
3042 var _body = null; | 2778 var _body = null; |
3043 | 2779 |
3044 if (accountId == null) { | 2780 if (accountId == null) { |
3045 throw new core.ArgumentError("Parameter accountId is required."); | 2781 throw new core.ArgumentError("Parameter accountId is required."); |
3046 } | 2782 } |
3047 if (webPropertyId == null) { | 2783 if (webPropertyId == null) { |
3048 throw new core.ArgumentError("Parameter webPropertyId is required."); | 2784 throw new core.ArgumentError("Parameter webPropertyId is required."); |
3049 } | 2785 } |
3050 if (profileId == null) { | 2786 if (profileId == null) { |
3051 throw new core.ArgumentError("Parameter profileId is required."); | 2787 throw new core.ArgumentError("Parameter profileId is required."); |
3052 } | 2788 } |
3053 if (linkId == null) { | 2789 if (linkId == null) { |
3054 throw new core.ArgumentError("Parameter linkId is required."); | 2790 throw new core.ArgumentError("Parameter linkId is required."); |
3055 } | 2791 } |
3056 | 2792 |
3057 _downloadOptions = null; | 2793 _downloadOptions = null; |
3058 | 2794 |
3059 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/webproperties/' + common_internal.Escaper.ecapeVariable('$webPropert
yId') + '/profiles/' + common_internal.Escaper.ecapeVariable('$profileId') + '/e
ntityUserLinks/' + common_internal.Escaper.ecapeVariable('$linkId'); | 2795 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId')
+ '/webproperties/' + commons.Escaper.ecapeVariable('$webPropertyId') + '/profil
es/' + commons.Escaper.ecapeVariable('$profileId') + '/entityUserLinks/' + commo
ns.Escaper.ecapeVariable('$linkId'); |
3060 | 2796 |
3061 var _response = _requester.request(_url, | 2797 var _response = _requester.request(_url, |
3062 "DELETE", | 2798 "DELETE", |
3063 body: _body, | 2799 body: _body, |
3064 queryParams: _queryParams, | 2800 queryParams: _queryParams, |
3065 uploadOptions: _uploadOptions, | 2801 uploadOptions: _uploadOptions, |
3066 uploadMedia: _uploadMedia, | 2802 uploadMedia: _uploadMedia, |
3067 downloadOptions: _downloadOptions); | 2803 downloadOptions: _downloadOptions); |
3068 return _response.then((data) => null); | 2804 return _response.then((data) => null); |
3069 } | 2805 } |
3070 | 2806 |
3071 /** | 2807 /** |
3072 * Adds a new user to the given view (profile). | 2808 * Adds a new user to the given view (profile). |
3073 * | 2809 * |
3074 * [request] - The metadata request object. | 2810 * [request] - The metadata request object. |
3075 * | 2811 * |
3076 * Request parameters: | 2812 * Request parameters: |
3077 * | 2813 * |
3078 * [accountId] - Account ID to create the user link for. | 2814 * [accountId] - Account ID to create the user link for. |
3079 * | 2815 * |
3080 * [webPropertyId] - Web Property ID to create the user link for. | 2816 * [webPropertyId] - Web Property ID to create the user link for. |
3081 * | 2817 * |
3082 * [profileId] - View (Profile) ID to create the user link for. | 2818 * [profileId] - View (Profile) ID to create the user link for. |
3083 * | 2819 * |
3084 * Completes with a [EntityUserLink]. | 2820 * Completes with a [EntityUserLink]. |
3085 * | 2821 * |
3086 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 2822 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
3087 * error. | 2823 * error. |
3088 * | 2824 * |
3089 * If the used [http.Client] completes with an error when making a REST call, | 2825 * If the used [http.Client] completes with an error when making a REST call, |
3090 * this method will complete with the same error. | 2826 * this method will complete with the same error. |
3091 */ | 2827 */ |
3092 async.Future<EntityUserLink> insert(EntityUserLink request, core.String accoun
tId, core.String webPropertyId, core.String profileId) { | 2828 async.Future<EntityUserLink> insert(EntityUserLink request, core.String accoun
tId, core.String webPropertyId, core.String profileId) { |
3093 var _url = null; | 2829 var _url = null; |
3094 var _queryParams = new core.Map(); | 2830 var _queryParams = new core.Map(); |
3095 var _uploadMedia = null; | 2831 var _uploadMedia = null; |
3096 var _uploadOptions = null; | 2832 var _uploadOptions = null; |
3097 var _downloadOptions = common.DownloadOptions.Metadata; | 2833 var _downloadOptions = commons.DownloadOptions.Metadata; |
3098 var _body = null; | 2834 var _body = null; |
3099 | 2835 |
3100 if (request != null) { | 2836 if (request != null) { |
3101 _body = convert.JSON.encode((request).toJson()); | 2837 _body = convert.JSON.encode((request).toJson()); |
3102 } | 2838 } |
3103 if (accountId == null) { | 2839 if (accountId == null) { |
3104 throw new core.ArgumentError("Parameter accountId is required."); | 2840 throw new core.ArgumentError("Parameter accountId is required."); |
3105 } | 2841 } |
3106 if (webPropertyId == null) { | 2842 if (webPropertyId == null) { |
3107 throw new core.ArgumentError("Parameter webPropertyId is required."); | 2843 throw new core.ArgumentError("Parameter webPropertyId is required."); |
3108 } | 2844 } |
3109 if (profileId == null) { | 2845 if (profileId == null) { |
3110 throw new core.ArgumentError("Parameter profileId is required."); | 2846 throw new core.ArgumentError("Parameter profileId is required."); |
3111 } | 2847 } |
3112 | 2848 |
3113 | 2849 |
3114 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/webproperties/' + common_internal.Escaper.ecapeVariable('$webPropert
yId') + '/profiles/' + common_internal.Escaper.ecapeVariable('$profileId') + '/e
ntityUserLinks'; | 2850 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId')
+ '/webproperties/' + commons.Escaper.ecapeVariable('$webPropertyId') + '/profil
es/' + commons.Escaper.ecapeVariable('$profileId') + '/entityUserLinks'; |
3115 | 2851 |
3116 var _response = _requester.request(_url, | 2852 var _response = _requester.request(_url, |
3117 "POST", | 2853 "POST", |
3118 body: _body, | 2854 body: _body, |
3119 queryParams: _queryParams, | 2855 queryParams: _queryParams, |
3120 uploadOptions: _uploadOptions, | 2856 uploadOptions: _uploadOptions, |
3121 uploadMedia: _uploadMedia, | 2857 uploadMedia: _uploadMedia, |
3122 downloadOptions: _downloadOptions); | 2858 downloadOptions: _downloadOptions); |
3123 return _response.then((data) => new EntityUserLink.fromJson(data)); | 2859 return _response.then((data) => new EntityUserLink.fromJson(data)); |
3124 } | 2860 } |
(...skipping 15 matching lines...) Expand all Loading... |
3140 * | 2876 * |
3141 * [max_results] - The maximum number of profile-user links to include in this | 2877 * [max_results] - The maximum number of profile-user links to include in this |
3142 * response. | 2878 * response. |
3143 * | 2879 * |
3144 * [start_index] - An index of the first profile-user link to retrieve. Use | 2880 * [start_index] - An index of the first profile-user link to retrieve. Use |
3145 * this parameter as a pagination mechanism along with the max-results | 2881 * this parameter as a pagination mechanism along with the max-results |
3146 * parameter. | 2882 * parameter. |
3147 * | 2883 * |
3148 * Completes with a [EntityUserLinks]. | 2884 * Completes with a [EntityUserLinks]. |
3149 * | 2885 * |
3150 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 2886 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
3151 * error. | 2887 * error. |
3152 * | 2888 * |
3153 * If the used [http.Client] completes with an error when making a REST call, | 2889 * If the used [http.Client] completes with an error when making a REST call, |
3154 * this method will complete with the same error. | 2890 * this method will complete with the same error. |
3155 */ | 2891 */ |
3156 async.Future<EntityUserLinks> list(core.String accountId, core.String webPrope
rtyId, core.String profileId, {core.int max_results, core.int start_index}) { | 2892 async.Future<EntityUserLinks> list(core.String accountId, core.String webPrope
rtyId, core.String profileId, {core.int max_results, core.int start_index}) { |
3157 var _url = null; | 2893 var _url = null; |
3158 var _queryParams = new core.Map(); | 2894 var _queryParams = new core.Map(); |
3159 var _uploadMedia = null; | 2895 var _uploadMedia = null; |
3160 var _uploadOptions = null; | 2896 var _uploadOptions = null; |
3161 var _downloadOptions = common.DownloadOptions.Metadata; | 2897 var _downloadOptions = commons.DownloadOptions.Metadata; |
3162 var _body = null; | 2898 var _body = null; |
3163 | 2899 |
3164 if (accountId == null) { | 2900 if (accountId == null) { |
3165 throw new core.ArgumentError("Parameter accountId is required."); | 2901 throw new core.ArgumentError("Parameter accountId is required."); |
3166 } | 2902 } |
3167 if (webPropertyId == null) { | 2903 if (webPropertyId == null) { |
3168 throw new core.ArgumentError("Parameter webPropertyId is required."); | 2904 throw new core.ArgumentError("Parameter webPropertyId is required."); |
3169 } | 2905 } |
3170 if (profileId == null) { | 2906 if (profileId == null) { |
3171 throw new core.ArgumentError("Parameter profileId is required."); | 2907 throw new core.ArgumentError("Parameter profileId is required."); |
3172 } | 2908 } |
3173 if (max_results != null) { | 2909 if (max_results != null) { |
3174 _queryParams["max-results"] = ["${max_results}"]; | 2910 _queryParams["max-results"] = ["${max_results}"]; |
3175 } | 2911 } |
3176 if (start_index != null) { | 2912 if (start_index != null) { |
3177 _queryParams["start-index"] = ["${start_index}"]; | 2913 _queryParams["start-index"] = ["${start_index}"]; |
3178 } | 2914 } |
3179 | 2915 |
3180 | 2916 |
3181 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/webproperties/' + common_internal.Escaper.ecapeVariable('$webPropert
yId') + '/profiles/' + common_internal.Escaper.ecapeVariable('$profileId') + '/e
ntityUserLinks'; | 2917 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId')
+ '/webproperties/' + commons.Escaper.ecapeVariable('$webPropertyId') + '/profil
es/' + commons.Escaper.ecapeVariable('$profileId') + '/entityUserLinks'; |
3182 | 2918 |
3183 var _response = _requester.request(_url, | 2919 var _response = _requester.request(_url, |
3184 "GET", | 2920 "GET", |
3185 body: _body, | 2921 body: _body, |
3186 queryParams: _queryParams, | 2922 queryParams: _queryParams, |
3187 uploadOptions: _uploadOptions, | 2923 uploadOptions: _uploadOptions, |
3188 uploadMedia: _uploadMedia, | 2924 uploadMedia: _uploadMedia, |
3189 downloadOptions: _downloadOptions); | 2925 downloadOptions: _downloadOptions); |
3190 return _response.then((data) => new EntityUserLinks.fromJson(data)); | 2926 return _response.then((data) => new EntityUserLinks.fromJson(data)); |
3191 } | 2927 } |
3192 | 2928 |
3193 /** | 2929 /** |
3194 * Updates permissions for an existing user on the given view (profile). | 2930 * Updates permissions for an existing user on the given view (profile). |
3195 * | 2931 * |
3196 * [request] - The metadata request object. | 2932 * [request] - The metadata request object. |
3197 * | 2933 * |
3198 * Request parameters: | 2934 * Request parameters: |
3199 * | 2935 * |
3200 * [accountId] - Account ID to update the user link for. | 2936 * [accountId] - Account ID to update the user link for. |
3201 * | 2937 * |
3202 * [webPropertyId] - Web Property ID to update the user link for. | 2938 * [webPropertyId] - Web Property ID to update the user link for. |
3203 * | 2939 * |
3204 * [profileId] - View (Profile ID) to update the user link for. | 2940 * [profileId] - View (Profile ID) to update the user link for. |
3205 * | 2941 * |
3206 * [linkId] - Link ID to update the user link for. | 2942 * [linkId] - Link ID to update the user link for. |
3207 * | 2943 * |
3208 * Completes with a [EntityUserLink]. | 2944 * Completes with a [EntityUserLink]. |
3209 * | 2945 * |
3210 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 2946 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
3211 * error. | 2947 * error. |
3212 * | 2948 * |
3213 * If the used [http.Client] completes with an error when making a REST call, | 2949 * If the used [http.Client] completes with an error when making a REST call, |
3214 * this method will complete with the same error. | 2950 * this method will complete with the same error. |
3215 */ | 2951 */ |
3216 async.Future<EntityUserLink> update(EntityUserLink request, core.String accoun
tId, core.String webPropertyId, core.String profileId, core.String linkId) { | 2952 async.Future<EntityUserLink> update(EntityUserLink request, core.String accoun
tId, core.String webPropertyId, core.String profileId, core.String linkId) { |
3217 var _url = null; | 2953 var _url = null; |
3218 var _queryParams = new core.Map(); | 2954 var _queryParams = new core.Map(); |
3219 var _uploadMedia = null; | 2955 var _uploadMedia = null; |
3220 var _uploadOptions = null; | 2956 var _uploadOptions = null; |
3221 var _downloadOptions = common.DownloadOptions.Metadata; | 2957 var _downloadOptions = commons.DownloadOptions.Metadata; |
3222 var _body = null; | 2958 var _body = null; |
3223 | 2959 |
3224 if (request != null) { | 2960 if (request != null) { |
3225 _body = convert.JSON.encode((request).toJson()); | 2961 _body = convert.JSON.encode((request).toJson()); |
3226 } | 2962 } |
3227 if (accountId == null) { | 2963 if (accountId == null) { |
3228 throw new core.ArgumentError("Parameter accountId is required."); | 2964 throw new core.ArgumentError("Parameter accountId is required."); |
3229 } | 2965 } |
3230 if (webPropertyId == null) { | 2966 if (webPropertyId == null) { |
3231 throw new core.ArgumentError("Parameter webPropertyId is required."); | 2967 throw new core.ArgumentError("Parameter webPropertyId is required."); |
3232 } | 2968 } |
3233 if (profileId == null) { | 2969 if (profileId == null) { |
3234 throw new core.ArgumentError("Parameter profileId is required."); | 2970 throw new core.ArgumentError("Parameter profileId is required."); |
3235 } | 2971 } |
3236 if (linkId == null) { | 2972 if (linkId == null) { |
3237 throw new core.ArgumentError("Parameter linkId is required."); | 2973 throw new core.ArgumentError("Parameter linkId is required."); |
3238 } | 2974 } |
3239 | 2975 |
3240 | 2976 |
3241 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/webproperties/' + common_internal.Escaper.ecapeVariable('$webPropert
yId') + '/profiles/' + common_internal.Escaper.ecapeVariable('$profileId') + '/e
ntityUserLinks/' + common_internal.Escaper.ecapeVariable('$linkId'); | 2977 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId')
+ '/webproperties/' + commons.Escaper.ecapeVariable('$webPropertyId') + '/profil
es/' + commons.Escaper.ecapeVariable('$profileId') + '/entityUserLinks/' + commo
ns.Escaper.ecapeVariable('$linkId'); |
3242 | 2978 |
3243 var _response = _requester.request(_url, | 2979 var _response = _requester.request(_url, |
3244 "PUT", | 2980 "PUT", |
3245 body: _body, | 2981 body: _body, |
3246 queryParams: _queryParams, | 2982 queryParams: _queryParams, |
3247 uploadOptions: _uploadOptions, | 2983 uploadOptions: _uploadOptions, |
3248 uploadMedia: _uploadMedia, | 2984 uploadMedia: _uploadMedia, |
3249 downloadOptions: _downloadOptions); | 2985 downloadOptions: _downloadOptions); |
3250 return _response.then((data) => new EntityUserLink.fromJson(data)); | 2986 return _response.then((data) => new EntityUserLink.fromJson(data)); |
3251 } | 2987 } |
3252 | 2988 |
3253 } | 2989 } |
3254 | 2990 |
3255 | 2991 |
3256 /** Not documented yet. */ | |
3257 class ManagementProfilesResourceApi { | 2992 class ManagementProfilesResourceApi { |
3258 final common_internal.ApiRequester _requester; | 2993 final commons.ApiRequester _requester; |
3259 | 2994 |
3260 ManagementProfilesResourceApi(common_internal.ApiRequester client) : | 2995 ManagementProfilesResourceApi(commons.ApiRequester client) : |
3261 _requester = client; | 2996 _requester = client; |
3262 | 2997 |
3263 /** | 2998 /** |
3264 * Deletes a view (profile). | 2999 * Deletes a view (profile). |
3265 * | 3000 * |
3266 * Request parameters: | 3001 * Request parameters: |
3267 * | 3002 * |
3268 * [accountId] - Account ID to delete the view (profile) for. | 3003 * [accountId] - Account ID to delete the view (profile) for. |
3269 * | 3004 * |
3270 * [webPropertyId] - Web property ID to delete the view (profile) for. | 3005 * [webPropertyId] - Web property ID to delete the view (profile) for. |
3271 * | 3006 * |
3272 * [profileId] - ID of the view (profile) to be deleted. | 3007 * [profileId] - ID of the view (profile) to be deleted. |
3273 * | 3008 * |
3274 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 3009 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
3275 * error. | 3010 * error. |
3276 * | 3011 * |
3277 * If the used [http.Client] completes with an error when making a REST call, | 3012 * If the used [http.Client] completes with an error when making a REST call, |
3278 * this method will complete with the same error. | 3013 * this method will complete with the same error. |
3279 */ | 3014 */ |
3280 async.Future delete(core.String accountId, core.String webPropertyId, core.Str
ing profileId) { | 3015 async.Future delete(core.String accountId, core.String webPropertyId, core.Str
ing profileId) { |
3281 var _url = null; | 3016 var _url = null; |
3282 var _queryParams = new core.Map(); | 3017 var _queryParams = new core.Map(); |
3283 var _uploadMedia = null; | 3018 var _uploadMedia = null; |
3284 var _uploadOptions = null; | 3019 var _uploadOptions = null; |
3285 var _downloadOptions = common.DownloadOptions.Metadata; | 3020 var _downloadOptions = commons.DownloadOptions.Metadata; |
3286 var _body = null; | 3021 var _body = null; |
3287 | 3022 |
3288 if (accountId == null) { | 3023 if (accountId == null) { |
3289 throw new core.ArgumentError("Parameter accountId is required."); | 3024 throw new core.ArgumentError("Parameter accountId is required."); |
3290 } | 3025 } |
3291 if (webPropertyId == null) { | 3026 if (webPropertyId == null) { |
3292 throw new core.ArgumentError("Parameter webPropertyId is required."); | 3027 throw new core.ArgumentError("Parameter webPropertyId is required."); |
3293 } | 3028 } |
3294 if (profileId == null) { | 3029 if (profileId == null) { |
3295 throw new core.ArgumentError("Parameter profileId is required."); | 3030 throw new core.ArgumentError("Parameter profileId is required."); |
3296 } | 3031 } |
3297 | 3032 |
3298 _downloadOptions = null; | 3033 _downloadOptions = null; |
3299 | 3034 |
3300 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/webproperties/' + common_internal.Escaper.ecapeVariable('$webPropert
yId') + '/profiles/' + common_internal.Escaper.ecapeVariable('$profileId'); | 3035 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId')
+ '/webproperties/' + commons.Escaper.ecapeVariable('$webPropertyId') + '/profil
es/' + commons.Escaper.ecapeVariable('$profileId'); |
3301 | 3036 |
3302 var _response = _requester.request(_url, | 3037 var _response = _requester.request(_url, |
3303 "DELETE", | 3038 "DELETE", |
3304 body: _body, | 3039 body: _body, |
3305 queryParams: _queryParams, | 3040 queryParams: _queryParams, |
3306 uploadOptions: _uploadOptions, | 3041 uploadOptions: _uploadOptions, |
3307 uploadMedia: _uploadMedia, | 3042 uploadMedia: _uploadMedia, |
3308 downloadOptions: _downloadOptions); | 3043 downloadOptions: _downloadOptions); |
3309 return _response.then((data) => null); | 3044 return _response.then((data) => null); |
3310 } | 3045 } |
3311 | 3046 |
3312 /** | 3047 /** |
3313 * Gets a view (profile) to which the user has access. | 3048 * Gets a view (profile) to which the user has access. |
3314 * | 3049 * |
3315 * Request parameters: | 3050 * Request parameters: |
3316 * | 3051 * |
3317 * [accountId] - Account ID to retrieve the goal for. | 3052 * [accountId] - Account ID to retrieve the goal for. |
3318 * Value must have pattern "[0-9]+". | 3053 * Value must have pattern "[0-9]+". |
3319 * | 3054 * |
3320 * [webPropertyId] - Web property ID to retrieve the goal for. | 3055 * [webPropertyId] - Web property ID to retrieve the goal for. |
3321 * Value must have pattern "UA-[0-9]+-[0-9]+". | 3056 * Value must have pattern "UA-[0-9]+-[0-9]+". |
3322 * | 3057 * |
3323 * [profileId] - View (Profile) ID to retrieve the goal for. | 3058 * [profileId] - View (Profile) ID to retrieve the goal for. |
3324 * Value must have pattern "[0-9]+". | 3059 * Value must have pattern "[0-9]+". |
3325 * | 3060 * |
3326 * Completes with a [Profile]. | 3061 * Completes with a [Profile]. |
3327 * | 3062 * |
3328 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 3063 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
3329 * error. | 3064 * error. |
3330 * | 3065 * |
3331 * If the used [http.Client] completes with an error when making a REST call, | 3066 * If the used [http.Client] completes with an error when making a REST call, |
3332 * this method will complete with the same error. | 3067 * this method will complete with the same error. |
3333 */ | 3068 */ |
3334 async.Future<Profile> get(core.String accountId, core.String webPropertyId, co
re.String profileId) { | 3069 async.Future<Profile> get(core.String accountId, core.String webPropertyId, co
re.String profileId) { |
3335 var _url = null; | 3070 var _url = null; |
3336 var _queryParams = new core.Map(); | 3071 var _queryParams = new core.Map(); |
3337 var _uploadMedia = null; | 3072 var _uploadMedia = null; |
3338 var _uploadOptions = null; | 3073 var _uploadOptions = null; |
3339 var _downloadOptions = common.DownloadOptions.Metadata; | 3074 var _downloadOptions = commons.DownloadOptions.Metadata; |
3340 var _body = null; | 3075 var _body = null; |
3341 | 3076 |
3342 if (accountId == null) { | 3077 if (accountId == null) { |
3343 throw new core.ArgumentError("Parameter accountId is required."); | 3078 throw new core.ArgumentError("Parameter accountId is required."); |
3344 } | 3079 } |
3345 if (webPropertyId == null) { | 3080 if (webPropertyId == null) { |
3346 throw new core.ArgumentError("Parameter webPropertyId is required."); | 3081 throw new core.ArgumentError("Parameter webPropertyId is required."); |
3347 } | 3082 } |
3348 if (profileId == null) { | 3083 if (profileId == null) { |
3349 throw new core.ArgumentError("Parameter profileId is required."); | 3084 throw new core.ArgumentError("Parameter profileId is required."); |
3350 } | 3085 } |
3351 | 3086 |
3352 | 3087 |
3353 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/webproperties/' + common_internal.Escaper.ecapeVariable('$webPropert
yId') + '/profiles/' + common_internal.Escaper.ecapeVariable('$profileId'); | 3088 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId')
+ '/webproperties/' + commons.Escaper.ecapeVariable('$webPropertyId') + '/profil
es/' + commons.Escaper.ecapeVariable('$profileId'); |
3354 | 3089 |
3355 var _response = _requester.request(_url, | 3090 var _response = _requester.request(_url, |
3356 "GET", | 3091 "GET", |
3357 body: _body, | 3092 body: _body, |
3358 queryParams: _queryParams, | 3093 queryParams: _queryParams, |
3359 uploadOptions: _uploadOptions, | 3094 uploadOptions: _uploadOptions, |
3360 uploadMedia: _uploadMedia, | 3095 uploadMedia: _uploadMedia, |
3361 downloadOptions: _downloadOptions); | 3096 downloadOptions: _downloadOptions); |
3362 return _response.then((data) => new Profile.fromJson(data)); | 3097 return _response.then((data) => new Profile.fromJson(data)); |
3363 } | 3098 } |
3364 | 3099 |
3365 /** | 3100 /** |
3366 * Create a new view (profile). | 3101 * Create a new view (profile). |
3367 * | 3102 * |
3368 * [request] - The metadata request object. | 3103 * [request] - The metadata request object. |
3369 * | 3104 * |
3370 * Request parameters: | 3105 * Request parameters: |
3371 * | 3106 * |
3372 * [accountId] - Account ID to create the view (profile) for. | 3107 * [accountId] - Account ID to create the view (profile) for. |
3373 * | 3108 * |
3374 * [webPropertyId] - Web property ID to create the view (profile) for. | 3109 * [webPropertyId] - Web property ID to create the view (profile) for. |
3375 * | 3110 * |
3376 * Completes with a [Profile]. | 3111 * Completes with a [Profile]. |
3377 * | 3112 * |
3378 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 3113 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
3379 * error. | 3114 * error. |
3380 * | 3115 * |
3381 * If the used [http.Client] completes with an error when making a REST call, | 3116 * If the used [http.Client] completes with an error when making a REST call, |
3382 * this method will complete with the same error. | 3117 * this method will complete with the same error. |
3383 */ | 3118 */ |
3384 async.Future<Profile> insert(Profile request, core.String accountId, core.Stri
ng webPropertyId) { | 3119 async.Future<Profile> insert(Profile request, core.String accountId, core.Stri
ng webPropertyId) { |
3385 var _url = null; | 3120 var _url = null; |
3386 var _queryParams = new core.Map(); | 3121 var _queryParams = new core.Map(); |
3387 var _uploadMedia = null; | 3122 var _uploadMedia = null; |
3388 var _uploadOptions = null; | 3123 var _uploadOptions = null; |
3389 var _downloadOptions = common.DownloadOptions.Metadata; | 3124 var _downloadOptions = commons.DownloadOptions.Metadata; |
3390 var _body = null; | 3125 var _body = null; |
3391 | 3126 |
3392 if (request != null) { | 3127 if (request != null) { |
3393 _body = convert.JSON.encode((request).toJson()); | 3128 _body = convert.JSON.encode((request).toJson()); |
3394 } | 3129 } |
3395 if (accountId == null) { | 3130 if (accountId == null) { |
3396 throw new core.ArgumentError("Parameter accountId is required."); | 3131 throw new core.ArgumentError("Parameter accountId is required."); |
3397 } | 3132 } |
3398 if (webPropertyId == null) { | 3133 if (webPropertyId == null) { |
3399 throw new core.ArgumentError("Parameter webPropertyId is required."); | 3134 throw new core.ArgumentError("Parameter webPropertyId is required."); |
3400 } | 3135 } |
3401 | 3136 |
3402 | 3137 |
3403 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/webproperties/' + common_internal.Escaper.ecapeVariable('$webPropert
yId') + '/profiles'; | 3138 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId')
+ '/webproperties/' + commons.Escaper.ecapeVariable('$webPropertyId') + '/profil
es'; |
3404 | 3139 |
3405 var _response = _requester.request(_url, | 3140 var _response = _requester.request(_url, |
3406 "POST", | 3141 "POST", |
3407 body: _body, | 3142 body: _body, |
3408 queryParams: _queryParams, | 3143 queryParams: _queryParams, |
3409 uploadOptions: _uploadOptions, | 3144 uploadOptions: _uploadOptions, |
3410 uploadMedia: _uploadMedia, | 3145 uploadMedia: _uploadMedia, |
3411 downloadOptions: _downloadOptions); | 3146 downloadOptions: _downloadOptions); |
3412 return _response.then((data) => new Profile.fromJson(data)); | 3147 return _response.then((data) => new Profile.fromJson(data)); |
3413 } | 3148 } |
(...skipping 12 matching lines...) Expand all Loading... |
3426 * properties to which the user has access. | 3161 * properties to which the user has access. |
3427 * | 3162 * |
3428 * [max_results] - The maximum number of views (profiles) to include in this | 3163 * [max_results] - The maximum number of views (profiles) to include in this |
3429 * response. | 3164 * response. |
3430 * | 3165 * |
3431 * [start_index] - An index of the first entity to retrieve. Use this | 3166 * [start_index] - An index of the first entity to retrieve. Use this |
3432 * parameter as a pagination mechanism along with the max-results parameter. | 3167 * parameter as a pagination mechanism along with the max-results parameter. |
3433 * | 3168 * |
3434 * Completes with a [Profiles]. | 3169 * Completes with a [Profiles]. |
3435 * | 3170 * |
3436 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 3171 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
3437 * error. | 3172 * error. |
3438 * | 3173 * |
3439 * If the used [http.Client] completes with an error when making a REST call, | 3174 * If the used [http.Client] completes with an error when making a REST call, |
3440 * this method will complete with the same error. | 3175 * this method will complete with the same error. |
3441 */ | 3176 */ |
3442 async.Future<Profiles> list(core.String accountId, core.String webPropertyId,
{core.int max_results, core.int start_index}) { | 3177 async.Future<Profiles> list(core.String accountId, core.String webPropertyId,
{core.int max_results, core.int start_index}) { |
3443 var _url = null; | 3178 var _url = null; |
3444 var _queryParams = new core.Map(); | 3179 var _queryParams = new core.Map(); |
3445 var _uploadMedia = null; | 3180 var _uploadMedia = null; |
3446 var _uploadOptions = null; | 3181 var _uploadOptions = null; |
3447 var _downloadOptions = common.DownloadOptions.Metadata; | 3182 var _downloadOptions = commons.DownloadOptions.Metadata; |
3448 var _body = null; | 3183 var _body = null; |
3449 | 3184 |
3450 if (accountId == null) { | 3185 if (accountId == null) { |
3451 throw new core.ArgumentError("Parameter accountId is required."); | 3186 throw new core.ArgumentError("Parameter accountId is required."); |
3452 } | 3187 } |
3453 if (webPropertyId == null) { | 3188 if (webPropertyId == null) { |
3454 throw new core.ArgumentError("Parameter webPropertyId is required."); | 3189 throw new core.ArgumentError("Parameter webPropertyId is required."); |
3455 } | 3190 } |
3456 if (max_results != null) { | 3191 if (max_results != null) { |
3457 _queryParams["max-results"] = ["${max_results}"]; | 3192 _queryParams["max-results"] = ["${max_results}"]; |
3458 } | 3193 } |
3459 if (start_index != null) { | 3194 if (start_index != null) { |
3460 _queryParams["start-index"] = ["${start_index}"]; | 3195 _queryParams["start-index"] = ["${start_index}"]; |
3461 } | 3196 } |
3462 | 3197 |
3463 | 3198 |
3464 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/webproperties/' + common_internal.Escaper.ecapeVariable('$webPropert
yId') + '/profiles'; | 3199 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId')
+ '/webproperties/' + commons.Escaper.ecapeVariable('$webPropertyId') + '/profil
es'; |
3465 | 3200 |
3466 var _response = _requester.request(_url, | 3201 var _response = _requester.request(_url, |
3467 "GET", | 3202 "GET", |
3468 body: _body, | 3203 body: _body, |
3469 queryParams: _queryParams, | 3204 queryParams: _queryParams, |
3470 uploadOptions: _uploadOptions, | 3205 uploadOptions: _uploadOptions, |
3471 uploadMedia: _uploadMedia, | 3206 uploadMedia: _uploadMedia, |
3472 downloadOptions: _downloadOptions); | 3207 downloadOptions: _downloadOptions); |
3473 return _response.then((data) => new Profiles.fromJson(data)); | 3208 return _response.then((data) => new Profiles.fromJson(data)); |
3474 } | 3209 } |
3475 | 3210 |
3476 /** | 3211 /** |
3477 * Updates an existing view (profile). This method supports patch semantics. | 3212 * Updates an existing view (profile). This method supports patch semantics. |
3478 * | 3213 * |
3479 * [request] - The metadata request object. | 3214 * [request] - The metadata request object. |
3480 * | 3215 * |
3481 * Request parameters: | 3216 * Request parameters: |
3482 * | 3217 * |
3483 * [accountId] - Account ID to which the view (profile) belongs | 3218 * [accountId] - Account ID to which the view (profile) belongs |
3484 * | 3219 * |
3485 * [webPropertyId] - Web property ID to which the view (profile) belongs | 3220 * [webPropertyId] - Web property ID to which the view (profile) belongs |
3486 * | 3221 * |
3487 * [profileId] - ID of the view (profile) to be updated. | 3222 * [profileId] - ID of the view (profile) to be updated. |
3488 * | 3223 * |
3489 * Completes with a [Profile]. | 3224 * Completes with a [Profile]. |
3490 * | 3225 * |
3491 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 3226 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
3492 * error. | 3227 * error. |
3493 * | 3228 * |
3494 * If the used [http.Client] completes with an error when making a REST call, | 3229 * If the used [http.Client] completes with an error when making a REST call, |
3495 * this method will complete with the same error. | 3230 * this method will complete with the same error. |
3496 */ | 3231 */ |
3497 async.Future<Profile> patch(Profile request, core.String accountId, core.Strin
g webPropertyId, core.String profileId) { | 3232 async.Future<Profile> patch(Profile request, core.String accountId, core.Strin
g webPropertyId, core.String profileId) { |
3498 var _url = null; | 3233 var _url = null; |
3499 var _queryParams = new core.Map(); | 3234 var _queryParams = new core.Map(); |
3500 var _uploadMedia = null; | 3235 var _uploadMedia = null; |
3501 var _uploadOptions = null; | 3236 var _uploadOptions = null; |
3502 var _downloadOptions = common.DownloadOptions.Metadata; | 3237 var _downloadOptions = commons.DownloadOptions.Metadata; |
3503 var _body = null; | 3238 var _body = null; |
3504 | 3239 |
3505 if (request != null) { | 3240 if (request != null) { |
3506 _body = convert.JSON.encode((request).toJson()); | 3241 _body = convert.JSON.encode((request).toJson()); |
3507 } | 3242 } |
3508 if (accountId == null) { | 3243 if (accountId == null) { |
3509 throw new core.ArgumentError("Parameter accountId is required."); | 3244 throw new core.ArgumentError("Parameter accountId is required."); |
3510 } | 3245 } |
3511 if (webPropertyId == null) { | 3246 if (webPropertyId == null) { |
3512 throw new core.ArgumentError("Parameter webPropertyId is required."); | 3247 throw new core.ArgumentError("Parameter webPropertyId is required."); |
3513 } | 3248 } |
3514 if (profileId == null) { | 3249 if (profileId == null) { |
3515 throw new core.ArgumentError("Parameter profileId is required."); | 3250 throw new core.ArgumentError("Parameter profileId is required."); |
3516 } | 3251 } |
3517 | 3252 |
3518 | 3253 |
3519 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/webproperties/' + common_internal.Escaper.ecapeVariable('$webPropert
yId') + '/profiles/' + common_internal.Escaper.ecapeVariable('$profileId'); | 3254 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId')
+ '/webproperties/' + commons.Escaper.ecapeVariable('$webPropertyId') + '/profil
es/' + commons.Escaper.ecapeVariable('$profileId'); |
3520 | 3255 |
3521 var _response = _requester.request(_url, | 3256 var _response = _requester.request(_url, |
3522 "PATCH", | 3257 "PATCH", |
3523 body: _body, | 3258 body: _body, |
3524 queryParams: _queryParams, | 3259 queryParams: _queryParams, |
3525 uploadOptions: _uploadOptions, | 3260 uploadOptions: _uploadOptions, |
3526 uploadMedia: _uploadMedia, | 3261 uploadMedia: _uploadMedia, |
3527 downloadOptions: _downloadOptions); | 3262 downloadOptions: _downloadOptions); |
3528 return _response.then((data) => new Profile.fromJson(data)); | 3263 return _response.then((data) => new Profile.fromJson(data)); |
3529 } | 3264 } |
3530 | 3265 |
3531 /** | 3266 /** |
3532 * Updates an existing view (profile). | 3267 * Updates an existing view (profile). |
3533 * | 3268 * |
3534 * [request] - The metadata request object. | 3269 * [request] - The metadata request object. |
3535 * | 3270 * |
3536 * Request parameters: | 3271 * Request parameters: |
3537 * | 3272 * |
3538 * [accountId] - Account ID to which the view (profile) belongs | 3273 * [accountId] - Account ID to which the view (profile) belongs |
3539 * | 3274 * |
3540 * [webPropertyId] - Web property ID to which the view (profile) belongs | 3275 * [webPropertyId] - Web property ID to which the view (profile) belongs |
3541 * | 3276 * |
3542 * [profileId] - ID of the view (profile) to be updated. | 3277 * [profileId] - ID of the view (profile) to be updated. |
3543 * | 3278 * |
3544 * Completes with a [Profile]. | 3279 * Completes with a [Profile]. |
3545 * | 3280 * |
3546 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 3281 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
3547 * error. | 3282 * error. |
3548 * | 3283 * |
3549 * If the used [http.Client] completes with an error when making a REST call, | 3284 * If the used [http.Client] completes with an error when making a REST call, |
3550 * this method will complete with the same error. | 3285 * this method will complete with the same error. |
3551 */ | 3286 */ |
3552 async.Future<Profile> update(Profile request, core.String accountId, core.Stri
ng webPropertyId, core.String profileId) { | 3287 async.Future<Profile> update(Profile request, core.String accountId, core.Stri
ng webPropertyId, core.String profileId) { |
3553 var _url = null; | 3288 var _url = null; |
3554 var _queryParams = new core.Map(); | 3289 var _queryParams = new core.Map(); |
3555 var _uploadMedia = null; | 3290 var _uploadMedia = null; |
3556 var _uploadOptions = null; | 3291 var _uploadOptions = null; |
3557 var _downloadOptions = common.DownloadOptions.Metadata; | 3292 var _downloadOptions = commons.DownloadOptions.Metadata; |
3558 var _body = null; | 3293 var _body = null; |
3559 | 3294 |
3560 if (request != null) { | 3295 if (request != null) { |
3561 _body = convert.JSON.encode((request).toJson()); | 3296 _body = convert.JSON.encode((request).toJson()); |
3562 } | 3297 } |
3563 if (accountId == null) { | 3298 if (accountId == null) { |
3564 throw new core.ArgumentError("Parameter accountId is required."); | 3299 throw new core.ArgumentError("Parameter accountId is required."); |
3565 } | 3300 } |
3566 if (webPropertyId == null) { | 3301 if (webPropertyId == null) { |
3567 throw new core.ArgumentError("Parameter webPropertyId is required."); | 3302 throw new core.ArgumentError("Parameter webPropertyId is required."); |
3568 } | 3303 } |
3569 if (profileId == null) { | 3304 if (profileId == null) { |
3570 throw new core.ArgumentError("Parameter profileId is required."); | 3305 throw new core.ArgumentError("Parameter profileId is required."); |
3571 } | 3306 } |
3572 | 3307 |
3573 | 3308 |
3574 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/webproperties/' + common_internal.Escaper.ecapeVariable('$webPropert
yId') + '/profiles/' + common_internal.Escaper.ecapeVariable('$profileId'); | 3309 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId')
+ '/webproperties/' + commons.Escaper.ecapeVariable('$webPropertyId') + '/profil
es/' + commons.Escaper.ecapeVariable('$profileId'); |
3575 | 3310 |
3576 var _response = _requester.request(_url, | 3311 var _response = _requester.request(_url, |
3577 "PUT", | 3312 "PUT", |
3578 body: _body, | 3313 body: _body, |
3579 queryParams: _queryParams, | 3314 queryParams: _queryParams, |
3580 uploadOptions: _uploadOptions, | 3315 uploadOptions: _uploadOptions, |
3581 uploadMedia: _uploadMedia, | 3316 uploadMedia: _uploadMedia, |
3582 downloadOptions: _downloadOptions); | 3317 downloadOptions: _downloadOptions); |
3583 return _response.then((data) => new Profile.fromJson(data)); | 3318 return _response.then((data) => new Profile.fromJson(data)); |
3584 } | 3319 } |
3585 | 3320 |
3586 } | 3321 } |
3587 | 3322 |
3588 | 3323 |
3589 /** Not documented yet. */ | |
3590 class ManagementSegmentsResourceApi { | 3324 class ManagementSegmentsResourceApi { |
3591 final common_internal.ApiRequester _requester; | 3325 final commons.ApiRequester _requester; |
3592 | 3326 |
3593 ManagementSegmentsResourceApi(common_internal.ApiRequester client) : | 3327 ManagementSegmentsResourceApi(commons.ApiRequester client) : |
3594 _requester = client; | 3328 _requester = client; |
3595 | 3329 |
3596 /** | 3330 /** |
3597 * Lists segments to which the user has access. | 3331 * Lists segments to which the user has access. |
3598 * | 3332 * |
3599 * Request parameters: | 3333 * Request parameters: |
3600 * | 3334 * |
3601 * [max_results] - The maximum number of segments to include in this response. | 3335 * [max_results] - The maximum number of segments to include in this response. |
3602 * | 3336 * |
3603 * [start_index] - An index of the first segment to retrieve. Use this | 3337 * [start_index] - An index of the first segment to retrieve. Use this |
3604 * parameter as a pagination mechanism along with the max-results parameter. | 3338 * parameter as a pagination mechanism along with the max-results parameter. |
3605 * | 3339 * |
3606 * Completes with a [Segments]. | 3340 * Completes with a [Segments]. |
3607 * | 3341 * |
3608 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 3342 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
3609 * error. | 3343 * error. |
3610 * | 3344 * |
3611 * If the used [http.Client] completes with an error when making a REST call, | 3345 * If the used [http.Client] completes with an error when making a REST call, |
3612 * this method will complete with the same error. | 3346 * this method will complete with the same error. |
3613 */ | 3347 */ |
3614 async.Future<Segments> list({core.int max_results, core.int start_index}) { | 3348 async.Future<Segments> list({core.int max_results, core.int start_index}) { |
3615 var _url = null; | 3349 var _url = null; |
3616 var _queryParams = new core.Map(); | 3350 var _queryParams = new core.Map(); |
3617 var _uploadMedia = null; | 3351 var _uploadMedia = null; |
3618 var _uploadOptions = null; | 3352 var _uploadOptions = null; |
3619 var _downloadOptions = common.DownloadOptions.Metadata; | 3353 var _downloadOptions = commons.DownloadOptions.Metadata; |
3620 var _body = null; | 3354 var _body = null; |
3621 | 3355 |
3622 if (max_results != null) { | 3356 if (max_results != null) { |
3623 _queryParams["max-results"] = ["${max_results}"]; | 3357 _queryParams["max-results"] = ["${max_results}"]; |
3624 } | 3358 } |
3625 if (start_index != null) { | 3359 if (start_index != null) { |
3626 _queryParams["start-index"] = ["${start_index}"]; | 3360 _queryParams["start-index"] = ["${start_index}"]; |
3627 } | 3361 } |
3628 | 3362 |
3629 | 3363 |
3630 _url = 'management/segments'; | 3364 _url = 'management/segments'; |
3631 | 3365 |
3632 var _response = _requester.request(_url, | 3366 var _response = _requester.request(_url, |
3633 "GET", | 3367 "GET", |
3634 body: _body, | 3368 body: _body, |
3635 queryParams: _queryParams, | 3369 queryParams: _queryParams, |
3636 uploadOptions: _uploadOptions, | 3370 uploadOptions: _uploadOptions, |
3637 uploadMedia: _uploadMedia, | 3371 uploadMedia: _uploadMedia, |
3638 downloadOptions: _downloadOptions); | 3372 downloadOptions: _downloadOptions); |
3639 return _response.then((data) => new Segments.fromJson(data)); | 3373 return _response.then((data) => new Segments.fromJson(data)); |
3640 } | 3374 } |
3641 | 3375 |
3642 } | 3376 } |
3643 | 3377 |
3644 | 3378 |
3645 /** Not documented yet. */ | |
3646 class ManagementUnsampledReportsResourceApi { | 3379 class ManagementUnsampledReportsResourceApi { |
3647 final common_internal.ApiRequester _requester; | 3380 final commons.ApiRequester _requester; |
3648 | 3381 |
3649 ManagementUnsampledReportsResourceApi(common_internal.ApiRequester client) : | 3382 ManagementUnsampledReportsResourceApi(commons.ApiRequester client) : |
3650 _requester = client; | 3383 _requester = client; |
3651 | 3384 |
3652 /** | 3385 /** |
3653 * Returns a single unsampled report. | 3386 * Returns a single unsampled report. |
3654 * | 3387 * |
3655 * Request parameters: | 3388 * Request parameters: |
3656 * | 3389 * |
3657 * [accountId] - Account ID to retrieve unsampled report for. | 3390 * [accountId] - Account ID to retrieve unsampled report for. |
3658 * | 3391 * |
3659 * [webPropertyId] - Web property ID to retrieve unsampled reports for. | 3392 * [webPropertyId] - Web property ID to retrieve unsampled reports for. |
3660 * | 3393 * |
3661 * [profileId] - View (Profile) ID to retrieve unsampled report for. | 3394 * [profileId] - View (Profile) ID to retrieve unsampled report for. |
3662 * | 3395 * |
3663 * [unsampledReportId] - ID of the unsampled report to retrieve. | 3396 * [unsampledReportId] - ID of the unsampled report to retrieve. |
3664 * | 3397 * |
3665 * Completes with a [UnsampledReport]. | 3398 * Completes with a [UnsampledReport]. |
3666 * | 3399 * |
3667 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 3400 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
3668 * error. | 3401 * error. |
3669 * | 3402 * |
3670 * If the used [http.Client] completes with an error when making a REST call, | 3403 * If the used [http.Client] completes with an error when making a REST call, |
3671 * this method will complete with the same error. | 3404 * this method will complete with the same error. |
3672 */ | 3405 */ |
3673 async.Future<UnsampledReport> get(core.String accountId, core.String webProper
tyId, core.String profileId, core.String unsampledReportId) { | 3406 async.Future<UnsampledReport> get(core.String accountId, core.String webProper
tyId, core.String profileId, core.String unsampledReportId) { |
3674 var _url = null; | 3407 var _url = null; |
3675 var _queryParams = new core.Map(); | 3408 var _queryParams = new core.Map(); |
3676 var _uploadMedia = null; | 3409 var _uploadMedia = null; |
3677 var _uploadOptions = null; | 3410 var _uploadOptions = null; |
3678 var _downloadOptions = common.DownloadOptions.Metadata; | 3411 var _downloadOptions = commons.DownloadOptions.Metadata; |
3679 var _body = null; | 3412 var _body = null; |
3680 | 3413 |
3681 if (accountId == null) { | 3414 if (accountId == null) { |
3682 throw new core.ArgumentError("Parameter accountId is required."); | 3415 throw new core.ArgumentError("Parameter accountId is required."); |
3683 } | 3416 } |
3684 if (webPropertyId == null) { | 3417 if (webPropertyId == null) { |
3685 throw new core.ArgumentError("Parameter webPropertyId is required."); | 3418 throw new core.ArgumentError("Parameter webPropertyId is required."); |
3686 } | 3419 } |
3687 if (profileId == null) { | 3420 if (profileId == null) { |
3688 throw new core.ArgumentError("Parameter profileId is required."); | 3421 throw new core.ArgumentError("Parameter profileId is required."); |
3689 } | 3422 } |
3690 if (unsampledReportId == null) { | 3423 if (unsampledReportId == null) { |
3691 throw new core.ArgumentError("Parameter unsampledReportId is required."); | 3424 throw new core.ArgumentError("Parameter unsampledReportId is required."); |
3692 } | 3425 } |
3693 | 3426 |
3694 | 3427 |
3695 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/webproperties/' + common_internal.Escaper.ecapeVariable('$webPropert
yId') + '/profiles/' + common_internal.Escaper.ecapeVariable('$profileId') + '/u
nsampledReports/' + common_internal.Escaper.ecapeVariable('$unsampledReportId'); | 3428 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId')
+ '/webproperties/' + commons.Escaper.ecapeVariable('$webPropertyId') + '/profil
es/' + commons.Escaper.ecapeVariable('$profileId') + '/unsampledReports/' + comm
ons.Escaper.ecapeVariable('$unsampledReportId'); |
3696 | 3429 |
3697 var _response = _requester.request(_url, | 3430 var _response = _requester.request(_url, |
3698 "GET", | 3431 "GET", |
3699 body: _body, | 3432 body: _body, |
3700 queryParams: _queryParams, | 3433 queryParams: _queryParams, |
3701 uploadOptions: _uploadOptions, | 3434 uploadOptions: _uploadOptions, |
3702 uploadMedia: _uploadMedia, | 3435 uploadMedia: _uploadMedia, |
3703 downloadOptions: _downloadOptions); | 3436 downloadOptions: _downloadOptions); |
3704 return _response.then((data) => new UnsampledReport.fromJson(data)); | 3437 return _response.then((data) => new UnsampledReport.fromJson(data)); |
3705 } | 3438 } |
3706 | 3439 |
3707 /** | 3440 /** |
3708 * Create a new unsampled report. | 3441 * Create a new unsampled report. |
3709 * | 3442 * |
3710 * [request] - The metadata request object. | 3443 * [request] - The metadata request object. |
3711 * | 3444 * |
3712 * Request parameters: | 3445 * Request parameters: |
3713 * | 3446 * |
3714 * [accountId] - Account ID to create the unsampled report for. | 3447 * [accountId] - Account ID to create the unsampled report for. |
3715 * | 3448 * |
3716 * [webPropertyId] - Web property ID to create the unsampled report for. | 3449 * [webPropertyId] - Web property ID to create the unsampled report for. |
3717 * | 3450 * |
3718 * [profileId] - View (Profile) ID to create the unsampled report for. | 3451 * [profileId] - View (Profile) ID to create the unsampled report for. |
3719 * | 3452 * |
3720 * Completes with a [UnsampledReport]. | 3453 * Completes with a [UnsampledReport]. |
3721 * | 3454 * |
3722 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 3455 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
3723 * error. | 3456 * error. |
3724 * | 3457 * |
3725 * If the used [http.Client] completes with an error when making a REST call, | 3458 * If the used [http.Client] completes with an error when making a REST call, |
3726 * this method will complete with the same error. | 3459 * this method will complete with the same error. |
3727 */ | 3460 */ |
3728 async.Future<UnsampledReport> insert(UnsampledReport request, core.String acco
untId, core.String webPropertyId, core.String profileId) { | 3461 async.Future<UnsampledReport> insert(UnsampledReport request, core.String acco
untId, core.String webPropertyId, core.String profileId) { |
3729 var _url = null; | 3462 var _url = null; |
3730 var _queryParams = new core.Map(); | 3463 var _queryParams = new core.Map(); |
3731 var _uploadMedia = null; | 3464 var _uploadMedia = null; |
3732 var _uploadOptions = null; | 3465 var _uploadOptions = null; |
3733 var _downloadOptions = common.DownloadOptions.Metadata; | 3466 var _downloadOptions = commons.DownloadOptions.Metadata; |
3734 var _body = null; | 3467 var _body = null; |
3735 | 3468 |
3736 if (request != null) { | 3469 if (request != null) { |
3737 _body = convert.JSON.encode((request).toJson()); | 3470 _body = convert.JSON.encode((request).toJson()); |
3738 } | 3471 } |
3739 if (accountId == null) { | 3472 if (accountId == null) { |
3740 throw new core.ArgumentError("Parameter accountId is required."); | 3473 throw new core.ArgumentError("Parameter accountId is required."); |
3741 } | 3474 } |
3742 if (webPropertyId == null) { | 3475 if (webPropertyId == null) { |
3743 throw new core.ArgumentError("Parameter webPropertyId is required."); | 3476 throw new core.ArgumentError("Parameter webPropertyId is required."); |
3744 } | 3477 } |
3745 if (profileId == null) { | 3478 if (profileId == null) { |
3746 throw new core.ArgumentError("Parameter profileId is required."); | 3479 throw new core.ArgumentError("Parameter profileId is required."); |
3747 } | 3480 } |
3748 | 3481 |
3749 | 3482 |
3750 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/webproperties/' + common_internal.Escaper.ecapeVariable('$webPropert
yId') + '/profiles/' + common_internal.Escaper.ecapeVariable('$profileId') + '/u
nsampledReports'; | 3483 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId')
+ '/webproperties/' + commons.Escaper.ecapeVariable('$webPropertyId') + '/profil
es/' + commons.Escaper.ecapeVariable('$profileId') + '/unsampledReports'; |
3751 | 3484 |
3752 var _response = _requester.request(_url, | 3485 var _response = _requester.request(_url, |
3753 "POST", | 3486 "POST", |
3754 body: _body, | 3487 body: _body, |
3755 queryParams: _queryParams, | 3488 queryParams: _queryParams, |
3756 uploadOptions: _uploadOptions, | 3489 uploadOptions: _uploadOptions, |
3757 uploadMedia: _uploadMedia, | 3490 uploadMedia: _uploadMedia, |
3758 downloadOptions: _downloadOptions); | 3491 downloadOptions: _downloadOptions); |
3759 return _response.then((data) => new UnsampledReport.fromJson(data)); | 3492 return _response.then((data) => new UnsampledReport.fromJson(data)); |
3760 } | 3493 } |
(...skipping 14 matching lines...) Expand all Loading... |
3775 * | 3508 * |
3776 * [max_results] - The maximum number of unsampled reports to include in this | 3509 * [max_results] - The maximum number of unsampled reports to include in this |
3777 * response. | 3510 * response. |
3778 * | 3511 * |
3779 * [start_index] - An index of the first unsampled report to retrieve. Use | 3512 * [start_index] - An index of the first unsampled report to retrieve. Use |
3780 * this parameter as a pagination mechanism along with the max-results | 3513 * this parameter as a pagination mechanism along with the max-results |
3781 * parameter. | 3514 * parameter. |
3782 * | 3515 * |
3783 * Completes with a [UnsampledReports]. | 3516 * Completes with a [UnsampledReports]. |
3784 * | 3517 * |
3785 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 3518 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
3786 * error. | 3519 * error. |
3787 * | 3520 * |
3788 * If the used [http.Client] completes with an error when making a REST call, | 3521 * If the used [http.Client] completes with an error when making a REST call, |
3789 * this method will complete with the same error. | 3522 * this method will complete with the same error. |
3790 */ | 3523 */ |
3791 async.Future<UnsampledReports> list(core.String accountId, core.String webProp
ertyId, core.String profileId, {core.int max_results, core.int start_index}) { | 3524 async.Future<UnsampledReports> list(core.String accountId, core.String webProp
ertyId, core.String profileId, {core.int max_results, core.int start_index}) { |
3792 var _url = null; | 3525 var _url = null; |
3793 var _queryParams = new core.Map(); | 3526 var _queryParams = new core.Map(); |
3794 var _uploadMedia = null; | 3527 var _uploadMedia = null; |
3795 var _uploadOptions = null; | 3528 var _uploadOptions = null; |
3796 var _downloadOptions = common.DownloadOptions.Metadata; | 3529 var _downloadOptions = commons.DownloadOptions.Metadata; |
3797 var _body = null; | 3530 var _body = null; |
3798 | 3531 |
3799 if (accountId == null) { | 3532 if (accountId == null) { |
3800 throw new core.ArgumentError("Parameter accountId is required."); | 3533 throw new core.ArgumentError("Parameter accountId is required."); |
3801 } | 3534 } |
3802 if (webPropertyId == null) { | 3535 if (webPropertyId == null) { |
3803 throw new core.ArgumentError("Parameter webPropertyId is required."); | 3536 throw new core.ArgumentError("Parameter webPropertyId is required."); |
3804 } | 3537 } |
3805 if (profileId == null) { | 3538 if (profileId == null) { |
3806 throw new core.ArgumentError("Parameter profileId is required."); | 3539 throw new core.ArgumentError("Parameter profileId is required."); |
3807 } | 3540 } |
3808 if (max_results != null) { | 3541 if (max_results != null) { |
3809 _queryParams["max-results"] = ["${max_results}"]; | 3542 _queryParams["max-results"] = ["${max_results}"]; |
3810 } | 3543 } |
3811 if (start_index != null) { | 3544 if (start_index != null) { |
3812 _queryParams["start-index"] = ["${start_index}"]; | 3545 _queryParams["start-index"] = ["${start_index}"]; |
3813 } | 3546 } |
3814 | 3547 |
3815 | 3548 |
3816 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/webproperties/' + common_internal.Escaper.ecapeVariable('$webPropert
yId') + '/profiles/' + common_internal.Escaper.ecapeVariable('$profileId') + '/u
nsampledReports'; | 3549 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId')
+ '/webproperties/' + commons.Escaper.ecapeVariable('$webPropertyId') + '/profil
es/' + commons.Escaper.ecapeVariable('$profileId') + '/unsampledReports'; |
3817 | 3550 |
3818 var _response = _requester.request(_url, | 3551 var _response = _requester.request(_url, |
3819 "GET", | 3552 "GET", |
3820 body: _body, | 3553 body: _body, |
3821 queryParams: _queryParams, | 3554 queryParams: _queryParams, |
3822 uploadOptions: _uploadOptions, | 3555 uploadOptions: _uploadOptions, |
3823 uploadMedia: _uploadMedia, | 3556 uploadMedia: _uploadMedia, |
3824 downloadOptions: _downloadOptions); | 3557 downloadOptions: _downloadOptions); |
3825 return _response.then((data) => new UnsampledReports.fromJson(data)); | 3558 return _response.then((data) => new UnsampledReports.fromJson(data)); |
3826 } | 3559 } |
3827 | 3560 |
3828 } | 3561 } |
3829 | 3562 |
3830 | 3563 |
3831 /** Not documented yet. */ | |
3832 class ManagementUploadsResourceApi { | 3564 class ManagementUploadsResourceApi { |
3833 final common_internal.ApiRequester _requester; | 3565 final commons.ApiRequester _requester; |
3834 | 3566 |
3835 ManagementUploadsResourceApi(common_internal.ApiRequester client) : | 3567 ManagementUploadsResourceApi(commons.ApiRequester client) : |
3836 _requester = client; | 3568 _requester = client; |
3837 | 3569 |
3838 /** | 3570 /** |
3839 * Delete data associated with a previous upload. | 3571 * Delete data associated with a previous upload. |
3840 * | 3572 * |
3841 * [request] - The metadata request object. | 3573 * [request] - The metadata request object. |
3842 * | 3574 * |
3843 * Request parameters: | 3575 * Request parameters: |
3844 * | 3576 * |
3845 * [accountId] - Account Id for the uploads to be deleted. | 3577 * [accountId] - Account Id for the uploads to be deleted. |
3846 * Value must have pattern "\d+". | 3578 * Value must have pattern "\d+". |
3847 * | 3579 * |
3848 * [webPropertyId] - Web property Id for the uploads to be deleted. | 3580 * [webPropertyId] - Web property Id for the uploads to be deleted. |
3849 * Value must have pattern "UA-(\d+)-(\d+)". | 3581 * Value must have pattern "UA-(\d+)-(\d+)". |
3850 * | 3582 * |
3851 * [customDataSourceId] - Custom data source Id for the uploads to be deleted. | 3583 * [customDataSourceId] - Custom data source Id for the uploads to be deleted. |
3852 * Value must have pattern ".{22}". | 3584 * Value must have pattern ".{22}". |
3853 * | 3585 * |
3854 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 3586 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
3855 * error. | 3587 * error. |
3856 * | 3588 * |
3857 * If the used [http.Client] completes with an error when making a REST call, | 3589 * If the used [http.Client] completes with an error when making a REST call, |
3858 * this method will complete with the same error. | 3590 * this method will complete with the same error. |
3859 */ | 3591 */ |
3860 async.Future deleteUploadData(AnalyticsDataimportDeleteUploadDataRequest reque
st, core.String accountId, core.String webPropertyId, core.String customDataSour
ceId) { | 3592 async.Future deleteUploadData(AnalyticsDataimportDeleteUploadDataRequest reque
st, core.String accountId, core.String webPropertyId, core.String customDataSour
ceId) { |
3861 var _url = null; | 3593 var _url = null; |
3862 var _queryParams = new core.Map(); | 3594 var _queryParams = new core.Map(); |
3863 var _uploadMedia = null; | 3595 var _uploadMedia = null; |
3864 var _uploadOptions = null; | 3596 var _uploadOptions = null; |
3865 var _downloadOptions = common.DownloadOptions.Metadata; | 3597 var _downloadOptions = commons.DownloadOptions.Metadata; |
3866 var _body = null; | 3598 var _body = null; |
3867 | 3599 |
3868 if (request != null) { | 3600 if (request != null) { |
3869 _body = convert.JSON.encode((request).toJson()); | 3601 _body = convert.JSON.encode((request).toJson()); |
3870 } | 3602 } |
3871 if (accountId == null) { | 3603 if (accountId == null) { |
3872 throw new core.ArgumentError("Parameter accountId is required."); | 3604 throw new core.ArgumentError("Parameter accountId is required."); |
3873 } | 3605 } |
3874 if (webPropertyId == null) { | 3606 if (webPropertyId == null) { |
3875 throw new core.ArgumentError("Parameter webPropertyId is required."); | 3607 throw new core.ArgumentError("Parameter webPropertyId is required."); |
3876 } | 3608 } |
3877 if (customDataSourceId == null) { | 3609 if (customDataSourceId == null) { |
3878 throw new core.ArgumentError("Parameter customDataSourceId is required."); | 3610 throw new core.ArgumentError("Parameter customDataSourceId is required."); |
3879 } | 3611 } |
3880 | 3612 |
3881 _downloadOptions = null; | 3613 _downloadOptions = null; |
3882 | 3614 |
3883 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/webproperties/' + common_internal.Escaper.ecapeVariable('$webPropert
yId') + '/customDataSources/' + common_internal.Escaper.ecapeVariable('$customDa
taSourceId') + '/deleteUploadData'; | 3615 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId')
+ '/webproperties/' + commons.Escaper.ecapeVariable('$webPropertyId') + '/custom
DataSources/' + commons.Escaper.ecapeVariable('$customDataSourceId') + '/deleteU
ploadData'; |
3884 | 3616 |
3885 var _response = _requester.request(_url, | 3617 var _response = _requester.request(_url, |
3886 "POST", | 3618 "POST", |
3887 body: _body, | 3619 body: _body, |
3888 queryParams: _queryParams, | 3620 queryParams: _queryParams, |
3889 uploadOptions: _uploadOptions, | 3621 uploadOptions: _uploadOptions, |
3890 uploadMedia: _uploadMedia, | 3622 uploadMedia: _uploadMedia, |
3891 downloadOptions: _downloadOptions); | 3623 downloadOptions: _downloadOptions); |
3892 return _response.then((data) => null); | 3624 return _response.then((data) => null); |
3893 } | 3625 } |
(...skipping 10 matching lines...) Expand all Loading... |
3904 * Value must have pattern "UA-(\d+)-(\d+)". | 3636 * Value must have pattern "UA-(\d+)-(\d+)". |
3905 * | 3637 * |
3906 * [customDataSourceId] - Custom data source Id for upload to retrieve. | 3638 * [customDataSourceId] - Custom data source Id for upload to retrieve. |
3907 * Value must have pattern ".{22}". | 3639 * Value must have pattern ".{22}". |
3908 * | 3640 * |
3909 * [uploadId] - Upload Id to retrieve. | 3641 * [uploadId] - Upload Id to retrieve. |
3910 * Value must have pattern ".{22}". | 3642 * Value must have pattern ".{22}". |
3911 * | 3643 * |
3912 * Completes with a [Upload]. | 3644 * Completes with a [Upload]. |
3913 * | 3645 * |
3914 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 3646 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
3915 * error. | 3647 * error. |
3916 * | 3648 * |
3917 * If the used [http.Client] completes with an error when making a REST call, | 3649 * If the used [http.Client] completes with an error when making a REST call, |
3918 * this method will complete with the same error. | 3650 * this method will complete with the same error. |
3919 */ | 3651 */ |
3920 async.Future<Upload> get(core.String accountId, core.String webPropertyId, cor
e.String customDataSourceId, core.String uploadId) { | 3652 async.Future<Upload> get(core.String accountId, core.String webPropertyId, cor
e.String customDataSourceId, core.String uploadId) { |
3921 var _url = null; | 3653 var _url = null; |
3922 var _queryParams = new core.Map(); | 3654 var _queryParams = new core.Map(); |
3923 var _uploadMedia = null; | 3655 var _uploadMedia = null; |
3924 var _uploadOptions = null; | 3656 var _uploadOptions = null; |
3925 var _downloadOptions = common.DownloadOptions.Metadata; | 3657 var _downloadOptions = commons.DownloadOptions.Metadata; |
3926 var _body = null; | 3658 var _body = null; |
3927 | 3659 |
3928 if (accountId == null) { | 3660 if (accountId == null) { |
3929 throw new core.ArgumentError("Parameter accountId is required."); | 3661 throw new core.ArgumentError("Parameter accountId is required."); |
3930 } | 3662 } |
3931 if (webPropertyId == null) { | 3663 if (webPropertyId == null) { |
3932 throw new core.ArgumentError("Parameter webPropertyId is required."); | 3664 throw new core.ArgumentError("Parameter webPropertyId is required."); |
3933 } | 3665 } |
3934 if (customDataSourceId == null) { | 3666 if (customDataSourceId == null) { |
3935 throw new core.ArgumentError("Parameter customDataSourceId is required."); | 3667 throw new core.ArgumentError("Parameter customDataSourceId is required."); |
3936 } | 3668 } |
3937 if (uploadId == null) { | 3669 if (uploadId == null) { |
3938 throw new core.ArgumentError("Parameter uploadId is required."); | 3670 throw new core.ArgumentError("Parameter uploadId is required."); |
3939 } | 3671 } |
3940 | 3672 |
3941 | 3673 |
3942 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/webproperties/' + common_internal.Escaper.ecapeVariable('$webPropert
yId') + '/customDataSources/' + common_internal.Escaper.ecapeVariable('$customDa
taSourceId') + '/uploads/' + common_internal.Escaper.ecapeVariable('$uploadId'); | 3674 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId')
+ '/webproperties/' + commons.Escaper.ecapeVariable('$webPropertyId') + '/custom
DataSources/' + commons.Escaper.ecapeVariable('$customDataSourceId') + '/uploads
/' + commons.Escaper.ecapeVariable('$uploadId'); |
3943 | 3675 |
3944 var _response = _requester.request(_url, | 3676 var _response = _requester.request(_url, |
3945 "GET", | 3677 "GET", |
3946 body: _body, | 3678 body: _body, |
3947 queryParams: _queryParams, | 3679 queryParams: _queryParams, |
3948 uploadOptions: _uploadOptions, | 3680 uploadOptions: _uploadOptions, |
3949 uploadMedia: _uploadMedia, | 3681 uploadMedia: _uploadMedia, |
3950 downloadOptions: _downloadOptions); | 3682 downloadOptions: _downloadOptions); |
3951 return _response.then((data) => new Upload.fromJson(data)); | 3683 return _response.then((data) => new Upload.fromJson(data)); |
3952 } | 3684 } |
(...skipping 12 matching lines...) Expand all Loading... |
3965 * [customDataSourceId] - Custom data source Id for uploads to retrieve. | 3697 * [customDataSourceId] - Custom data source Id for uploads to retrieve. |
3966 * Value must have pattern ".{22}". | 3698 * Value must have pattern ".{22}". |
3967 * | 3699 * |
3968 * [max_results] - The maximum number of uploads to include in this response. | 3700 * [max_results] - The maximum number of uploads to include in this response. |
3969 * | 3701 * |
3970 * [start_index] - A 1-based index of the first upload to retrieve. Use this | 3702 * [start_index] - A 1-based index of the first upload to retrieve. Use this |
3971 * parameter as a pagination mechanism along with the max-results parameter. | 3703 * parameter as a pagination mechanism along with the max-results parameter. |
3972 * | 3704 * |
3973 * Completes with a [Uploads]. | 3705 * Completes with a [Uploads]. |
3974 * | 3706 * |
3975 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 3707 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
3976 * error. | 3708 * error. |
3977 * | 3709 * |
3978 * If the used [http.Client] completes with an error when making a REST call, | 3710 * If the used [http.Client] completes with an error when making a REST call, |
3979 * this method will complete with the same error. | 3711 * this method will complete with the same error. |
3980 */ | 3712 */ |
3981 async.Future<Uploads> list(core.String accountId, core.String webPropertyId, c
ore.String customDataSourceId, {core.int max_results, core.int start_index}) { | 3713 async.Future<Uploads> list(core.String accountId, core.String webPropertyId, c
ore.String customDataSourceId, {core.int max_results, core.int start_index}) { |
3982 var _url = null; | 3714 var _url = null; |
3983 var _queryParams = new core.Map(); | 3715 var _queryParams = new core.Map(); |
3984 var _uploadMedia = null; | 3716 var _uploadMedia = null; |
3985 var _uploadOptions = null; | 3717 var _uploadOptions = null; |
3986 var _downloadOptions = common.DownloadOptions.Metadata; | 3718 var _downloadOptions = commons.DownloadOptions.Metadata; |
3987 var _body = null; | 3719 var _body = null; |
3988 | 3720 |
3989 if (accountId == null) { | 3721 if (accountId == null) { |
3990 throw new core.ArgumentError("Parameter accountId is required."); | 3722 throw new core.ArgumentError("Parameter accountId is required."); |
3991 } | 3723 } |
3992 if (webPropertyId == null) { | 3724 if (webPropertyId == null) { |
3993 throw new core.ArgumentError("Parameter webPropertyId is required."); | 3725 throw new core.ArgumentError("Parameter webPropertyId is required."); |
3994 } | 3726 } |
3995 if (customDataSourceId == null) { | 3727 if (customDataSourceId == null) { |
3996 throw new core.ArgumentError("Parameter customDataSourceId is required."); | 3728 throw new core.ArgumentError("Parameter customDataSourceId is required."); |
3997 } | 3729 } |
3998 if (max_results != null) { | 3730 if (max_results != null) { |
3999 _queryParams["max-results"] = ["${max_results}"]; | 3731 _queryParams["max-results"] = ["${max_results}"]; |
4000 } | 3732 } |
4001 if (start_index != null) { | 3733 if (start_index != null) { |
4002 _queryParams["start-index"] = ["${start_index}"]; | 3734 _queryParams["start-index"] = ["${start_index}"]; |
4003 } | 3735 } |
4004 | 3736 |
4005 | 3737 |
4006 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/webproperties/' + common_internal.Escaper.ecapeVariable('$webPropert
yId') + '/customDataSources/' + common_internal.Escaper.ecapeVariable('$customDa
taSourceId') + '/uploads'; | 3738 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId')
+ '/webproperties/' + commons.Escaper.ecapeVariable('$webPropertyId') + '/custom
DataSources/' + commons.Escaper.ecapeVariable('$customDataSourceId') + '/uploads
'; |
4007 | 3739 |
4008 var _response = _requester.request(_url, | 3740 var _response = _requester.request(_url, |
4009 "GET", | 3741 "GET", |
4010 body: _body, | 3742 body: _body, |
4011 queryParams: _queryParams, | 3743 queryParams: _queryParams, |
4012 uploadOptions: _uploadOptions, | 3744 uploadOptions: _uploadOptions, |
4013 uploadMedia: _uploadMedia, | 3745 uploadMedia: _uploadMedia, |
4014 downloadOptions: _downloadOptions); | 3746 downloadOptions: _downloadOptions); |
4015 return _response.then((data) => new Uploads.fromJson(data)); | 3747 return _response.then((data) => new Uploads.fromJson(data)); |
4016 } | 3748 } |
4017 | 3749 |
4018 /** | 3750 /** |
4019 * Migrate custom data source and data imports to latest version. | |
4020 * | |
4021 * Request parameters: | |
4022 * | |
4023 * [accountId] - Account Id for migration. | |
4024 * Value must have pattern "\d+". | |
4025 * | |
4026 * [webPropertyId] - Web property Id for migration. | |
4027 * Value must have pattern "UA-(\d+)-(\d+)". | |
4028 * | |
4029 * [customDataSourceId] - Custom data source Id for migration. | |
4030 * Value must have pattern ".{22}". | |
4031 * | |
4032 * Completes with a [common.ApiRequestError] if the API endpoint returned an | |
4033 * error. | |
4034 * | |
4035 * If the used [http.Client] completes with an error when making a REST call, | |
4036 * this method will complete with the same error. | |
4037 */ | |
4038 async.Future migrateDataImport(core.String accountId, core.String webPropertyI
d, core.String customDataSourceId) { | |
4039 var _url = null; | |
4040 var _queryParams = new core.Map(); | |
4041 var _uploadMedia = null; | |
4042 var _uploadOptions = null; | |
4043 var _downloadOptions = common.DownloadOptions.Metadata; | |
4044 var _body = null; | |
4045 | |
4046 if (accountId == null) { | |
4047 throw new core.ArgumentError("Parameter accountId is required."); | |
4048 } | |
4049 if (webPropertyId == null) { | |
4050 throw new core.ArgumentError("Parameter webPropertyId is required."); | |
4051 } | |
4052 if (customDataSourceId == null) { | |
4053 throw new core.ArgumentError("Parameter customDataSourceId is required."); | |
4054 } | |
4055 | |
4056 _downloadOptions = null; | |
4057 | |
4058 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/webproperties/' + common_internal.Escaper.ecapeVariable('$webPropert
yId') + '/customDataSources/' + common_internal.Escaper.ecapeVariable('$customDa
taSourceId') + '/migrateDataImport'; | |
4059 | |
4060 var _response = _requester.request(_url, | |
4061 "POST", | |
4062 body: _body, | |
4063 queryParams: _queryParams, | |
4064 uploadOptions: _uploadOptions, | |
4065 uploadMedia: _uploadMedia, | |
4066 downloadOptions: _downloadOptions); | |
4067 return _response.then((data) => null); | |
4068 } | |
4069 | |
4070 /** | |
4071 * Upload data for a custom data source. | 3751 * Upload data for a custom data source. |
4072 * | 3752 * |
4073 * Request parameters: | 3753 * Request parameters: |
4074 * | 3754 * |
4075 * [accountId] - Account Id associated with the upload. | 3755 * [accountId] - Account Id associated with the upload. |
4076 * Value must have pattern "\d+". | 3756 * Value must have pattern "\d+". |
4077 * | 3757 * |
4078 * [webPropertyId] - Web property UA-string associated with the upload. | 3758 * [webPropertyId] - Web property UA-string associated with the upload. |
4079 * Value must have pattern "UA-\d+-\d+". | 3759 * Value must have pattern "UA-\d+-\d+". |
4080 * | 3760 * |
4081 * [customDataSourceId] - Custom data source Id to which the data being | 3761 * [customDataSourceId] - Custom data source Id to which the data being |
4082 * uploaded belongs. | 3762 * uploaded belongs. |
4083 * | 3763 * |
4084 * [uploadMedia] - The media to upload. | 3764 * [uploadMedia] - The media to upload. |
4085 * | 3765 * |
4086 * [uploadOptions] - Options for the media upload. Streaming Media without the | 3766 * [uploadOptions] - Options for the media upload. Streaming Media without the |
4087 * length being known ahead of time is only supported via resumable uploads. | 3767 * length being known ahead of time is only supported via resumable uploads. |
4088 * | 3768 * |
4089 * Completes with a [Upload]. | 3769 * Completes with a [Upload]. |
4090 * | 3770 * |
4091 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 3771 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
4092 * error. | 3772 * error. |
4093 * | 3773 * |
4094 * If the used [http.Client] completes with an error when making a REST call, | 3774 * If the used [http.Client] completes with an error when making a REST call, |
4095 * this method will complete with the same error. | 3775 * this method will complete with the same error. |
4096 */ | 3776 */ |
4097 async.Future<Upload> uploadData(core.String accountId, core.String webProperty
Id, core.String customDataSourceId, {common.UploadOptions uploadOptions : common
.UploadOptions.Default, common.Media uploadMedia}) { | 3777 async.Future<Upload> uploadData(core.String accountId, core.String webProperty
Id, core.String customDataSourceId, {commons.UploadOptions uploadOptions : commo
ns.UploadOptions.Default, commons.Media uploadMedia}) { |
4098 var _url = null; | 3778 var _url = null; |
4099 var _queryParams = new core.Map(); | 3779 var _queryParams = new core.Map(); |
4100 var _uploadMedia = null; | 3780 var _uploadMedia = null; |
4101 var _uploadOptions = null; | 3781 var _uploadOptions = null; |
4102 var _downloadOptions = common.DownloadOptions.Metadata; | 3782 var _downloadOptions = commons.DownloadOptions.Metadata; |
4103 var _body = null; | 3783 var _body = null; |
4104 | 3784 |
4105 if (accountId == null) { | 3785 if (accountId == null) { |
4106 throw new core.ArgumentError("Parameter accountId is required."); | 3786 throw new core.ArgumentError("Parameter accountId is required."); |
4107 } | 3787 } |
4108 if (webPropertyId == null) { | 3788 if (webPropertyId == null) { |
4109 throw new core.ArgumentError("Parameter webPropertyId is required."); | 3789 throw new core.ArgumentError("Parameter webPropertyId is required."); |
4110 } | 3790 } |
4111 if (customDataSourceId == null) { | 3791 if (customDataSourceId == null) { |
4112 throw new core.ArgumentError("Parameter customDataSourceId is required."); | 3792 throw new core.ArgumentError("Parameter customDataSourceId is required."); |
4113 } | 3793 } |
4114 | 3794 |
4115 _uploadMedia = uploadMedia; | 3795 _uploadMedia = uploadMedia; |
4116 _uploadOptions = uploadOptions; | 3796 _uploadOptions = uploadOptions; |
4117 | 3797 |
4118 if (_uploadMedia == null) { | 3798 if (_uploadMedia == null) { |
4119 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$ac
countId') + '/webproperties/' + common_internal.Escaper.ecapeVariable('$webPrope
rtyId') + '/customDataSources/' + common_internal.Escaper.ecapeVariable('$custom
DataSourceId') + '/uploads'; | 3799 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId'
) + '/webproperties/' + commons.Escaper.ecapeVariable('$webPropertyId') + '/cust
omDataSources/' + commons.Escaper.ecapeVariable('$customDataSourceId') + '/uploa
ds'; |
4120 } else if (_uploadOptions is common.ResumableUploadOptions) { | 3800 } else if (_uploadOptions is commons.ResumableUploadOptions) { |
4121 _url = '/resumable/upload/analytics/v3/management/accounts/' + common_inte
rnal.Escaper.ecapeVariable('$accountId') + '/webproperties/' + common_internal.E
scaper.ecapeVariable('$webPropertyId') + '/customDataSources/' + common_internal
.Escaper.ecapeVariable('$customDataSourceId') + '/uploads'; | 3801 _url = '/resumable/upload/analytics/v3/management/accounts/' + commons.Esc
aper.ecapeVariable('$accountId') + '/webproperties/' + commons.Escaper.ecapeVari
able('$webPropertyId') + '/customDataSources/' + commons.Escaper.ecapeVariable('
$customDataSourceId') + '/uploads'; |
4122 } else { | 3802 } else { |
4123 _url = '/upload/analytics/v3/management/accounts/' + common_internal.Escap
er.ecapeVariable('$accountId') + '/webproperties/' + common_internal.Escaper.eca
peVariable('$webPropertyId') + '/customDataSources/' + common_internal.Escaper.e
capeVariable('$customDataSourceId') + '/uploads'; | 3803 _url = '/upload/analytics/v3/management/accounts/' + commons.Escaper.ecape
Variable('$accountId') + '/webproperties/' + commons.Escaper.ecapeVariable('$web
PropertyId') + '/customDataSources/' + commons.Escaper.ecapeVariable('$customDat
aSourceId') + '/uploads'; |
4124 } | 3804 } |
4125 | 3805 |
4126 | 3806 |
4127 var _response = _requester.request(_url, | 3807 var _response = _requester.request(_url, |
4128 "POST", | 3808 "POST", |
4129 body: _body, | 3809 body: _body, |
4130 queryParams: _queryParams, | 3810 queryParams: _queryParams, |
4131 uploadOptions: _uploadOptions, | 3811 uploadOptions: _uploadOptions, |
4132 uploadMedia: _uploadMedia, | 3812 uploadMedia: _uploadMedia, |
4133 downloadOptions: _downloadOptions); | 3813 downloadOptions: _downloadOptions); |
4134 return _response.then((data) => new Upload.fromJson(data)); | 3814 return _response.then((data) => new Upload.fromJson(data)); |
4135 } | 3815 } |
4136 | 3816 |
4137 } | 3817 } |
4138 | 3818 |
4139 | 3819 |
4140 /** Not documented yet. */ | |
4141 class ManagementWebPropertyAdWordsLinksResourceApi { | 3820 class ManagementWebPropertyAdWordsLinksResourceApi { |
4142 final common_internal.ApiRequester _requester; | 3821 final commons.ApiRequester _requester; |
4143 | 3822 |
4144 ManagementWebPropertyAdWordsLinksResourceApi(common_internal.ApiRequester clie
nt) : | 3823 ManagementWebPropertyAdWordsLinksResourceApi(commons.ApiRequester client) : |
4145 _requester = client; | 3824 _requester = client; |
4146 | 3825 |
4147 /** | 3826 /** |
4148 * Deletes a web property-AdWords link. | 3827 * Deletes a web property-AdWords link. |
4149 * | 3828 * |
4150 * Request parameters: | 3829 * Request parameters: |
4151 * | 3830 * |
4152 * [accountId] - ID of the account which the given web property belongs to. | 3831 * [accountId] - ID of the account which the given web property belongs to. |
4153 * | 3832 * |
4154 * [webPropertyId] - Web property ID to delete the AdWords link for. | 3833 * [webPropertyId] - Web property ID to delete the AdWords link for. |
4155 * | 3834 * |
4156 * [webPropertyAdWordsLinkId] - Web property AdWords link ID. | 3835 * [webPropertyAdWordsLinkId] - Web property AdWords link ID. |
4157 * | 3836 * |
4158 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 3837 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
4159 * error. | 3838 * error. |
4160 * | 3839 * |
4161 * If the used [http.Client] completes with an error when making a REST call, | 3840 * If the used [http.Client] completes with an error when making a REST call, |
4162 * this method will complete with the same error. | 3841 * this method will complete with the same error. |
4163 */ | 3842 */ |
4164 async.Future delete(core.String accountId, core.String webPropertyId, core.Str
ing webPropertyAdWordsLinkId) { | 3843 async.Future delete(core.String accountId, core.String webPropertyId, core.Str
ing webPropertyAdWordsLinkId) { |
4165 var _url = null; | 3844 var _url = null; |
4166 var _queryParams = new core.Map(); | 3845 var _queryParams = new core.Map(); |
4167 var _uploadMedia = null; | 3846 var _uploadMedia = null; |
4168 var _uploadOptions = null; | 3847 var _uploadOptions = null; |
4169 var _downloadOptions = common.DownloadOptions.Metadata; | 3848 var _downloadOptions = commons.DownloadOptions.Metadata; |
4170 var _body = null; | 3849 var _body = null; |
4171 | 3850 |
4172 if (accountId == null) { | 3851 if (accountId == null) { |
4173 throw new core.ArgumentError("Parameter accountId is required."); | 3852 throw new core.ArgumentError("Parameter accountId is required."); |
4174 } | 3853 } |
4175 if (webPropertyId == null) { | 3854 if (webPropertyId == null) { |
4176 throw new core.ArgumentError("Parameter webPropertyId is required."); | 3855 throw new core.ArgumentError("Parameter webPropertyId is required."); |
4177 } | 3856 } |
4178 if (webPropertyAdWordsLinkId == null) { | 3857 if (webPropertyAdWordsLinkId == null) { |
4179 throw new core.ArgumentError("Parameter webPropertyAdWordsLinkId is requir
ed."); | 3858 throw new core.ArgumentError("Parameter webPropertyAdWordsLinkId is requir
ed."); |
4180 } | 3859 } |
4181 | 3860 |
4182 _downloadOptions = null; | 3861 _downloadOptions = null; |
4183 | 3862 |
4184 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/webproperties/' + common_internal.Escaper.ecapeVariable('$webPropert
yId') + '/entityAdWordsLinks/' + common_internal.Escaper.ecapeVariable('$webProp
ertyAdWordsLinkId'); | 3863 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId')
+ '/webproperties/' + commons.Escaper.ecapeVariable('$webPropertyId') + '/entity
AdWordsLinks/' + commons.Escaper.ecapeVariable('$webPropertyAdWordsLinkId'); |
4185 | 3864 |
4186 var _response = _requester.request(_url, | 3865 var _response = _requester.request(_url, |
4187 "DELETE", | 3866 "DELETE", |
4188 body: _body, | 3867 body: _body, |
4189 queryParams: _queryParams, | 3868 queryParams: _queryParams, |
4190 uploadOptions: _uploadOptions, | 3869 uploadOptions: _uploadOptions, |
4191 uploadMedia: _uploadMedia, | 3870 uploadMedia: _uploadMedia, |
4192 downloadOptions: _downloadOptions); | 3871 downloadOptions: _downloadOptions); |
4193 return _response.then((data) => null); | 3872 return _response.then((data) => null); |
4194 } | 3873 } |
4195 | 3874 |
4196 /** | 3875 /** |
4197 * Returns a web property-AdWords link to which the user has access. | 3876 * Returns a web property-AdWords link to which the user has access. |
4198 * | 3877 * |
4199 * Request parameters: | 3878 * Request parameters: |
4200 * | 3879 * |
4201 * [accountId] - ID of the account which the given web property belongs to. | 3880 * [accountId] - ID of the account which the given web property belongs to. |
4202 * | 3881 * |
4203 * [webPropertyId] - Web property ID to retrieve the AdWords link for. | 3882 * [webPropertyId] - Web property ID to retrieve the AdWords link for. |
4204 * | 3883 * |
4205 * [webPropertyAdWordsLinkId] - Web property-AdWords link ID. | 3884 * [webPropertyAdWordsLinkId] - Web property-AdWords link ID. |
4206 * | 3885 * |
4207 * Completes with a [EntityAdWordsLink]. | 3886 * Completes with a [EntityAdWordsLink]. |
4208 * | 3887 * |
4209 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 3888 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
4210 * error. | 3889 * error. |
4211 * | 3890 * |
4212 * If the used [http.Client] completes with an error when making a REST call, | 3891 * If the used [http.Client] completes with an error when making a REST call, |
4213 * this method will complete with the same error. | 3892 * this method will complete with the same error. |
4214 */ | 3893 */ |
4215 async.Future<EntityAdWordsLink> get(core.String accountId, core.String webProp
ertyId, core.String webPropertyAdWordsLinkId) { | 3894 async.Future<EntityAdWordsLink> get(core.String accountId, core.String webProp
ertyId, core.String webPropertyAdWordsLinkId) { |
4216 var _url = null; | 3895 var _url = null; |
4217 var _queryParams = new core.Map(); | 3896 var _queryParams = new core.Map(); |
4218 var _uploadMedia = null; | 3897 var _uploadMedia = null; |
4219 var _uploadOptions = null; | 3898 var _uploadOptions = null; |
4220 var _downloadOptions = common.DownloadOptions.Metadata; | 3899 var _downloadOptions = commons.DownloadOptions.Metadata; |
4221 var _body = null; | 3900 var _body = null; |
4222 | 3901 |
4223 if (accountId == null) { | 3902 if (accountId == null) { |
4224 throw new core.ArgumentError("Parameter accountId is required."); | 3903 throw new core.ArgumentError("Parameter accountId is required."); |
4225 } | 3904 } |
4226 if (webPropertyId == null) { | 3905 if (webPropertyId == null) { |
4227 throw new core.ArgumentError("Parameter webPropertyId is required."); | 3906 throw new core.ArgumentError("Parameter webPropertyId is required."); |
4228 } | 3907 } |
4229 if (webPropertyAdWordsLinkId == null) { | 3908 if (webPropertyAdWordsLinkId == null) { |
4230 throw new core.ArgumentError("Parameter webPropertyAdWordsLinkId is requir
ed."); | 3909 throw new core.ArgumentError("Parameter webPropertyAdWordsLinkId is requir
ed."); |
4231 } | 3910 } |
4232 | 3911 |
4233 | 3912 |
4234 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/webproperties/' + common_internal.Escaper.ecapeVariable('$webPropert
yId') + '/entityAdWordsLinks/' + common_internal.Escaper.ecapeVariable('$webProp
ertyAdWordsLinkId'); | 3913 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId')
+ '/webproperties/' + commons.Escaper.ecapeVariable('$webPropertyId') + '/entity
AdWordsLinks/' + commons.Escaper.ecapeVariable('$webPropertyAdWordsLinkId'); |
4235 | 3914 |
4236 var _response = _requester.request(_url, | 3915 var _response = _requester.request(_url, |
4237 "GET", | 3916 "GET", |
4238 body: _body, | 3917 body: _body, |
4239 queryParams: _queryParams, | 3918 queryParams: _queryParams, |
4240 uploadOptions: _uploadOptions, | 3919 uploadOptions: _uploadOptions, |
4241 uploadMedia: _uploadMedia, | 3920 uploadMedia: _uploadMedia, |
4242 downloadOptions: _downloadOptions); | 3921 downloadOptions: _downloadOptions); |
4243 return _response.then((data) => new EntityAdWordsLink.fromJson(data)); | 3922 return _response.then((data) => new EntityAdWordsLink.fromJson(data)); |
4244 } | 3923 } |
4245 | 3924 |
4246 /** | 3925 /** |
4247 * Creates a webProperty-AdWords link. | 3926 * Creates a webProperty-AdWords link. |
4248 * | 3927 * |
4249 * [request] - The metadata request object. | 3928 * [request] - The metadata request object. |
4250 * | 3929 * |
4251 * Request parameters: | 3930 * Request parameters: |
4252 * | 3931 * |
4253 * [accountId] - ID of the Google Analytics account to create the link for. | 3932 * [accountId] - ID of the Google Analytics account to create the link for. |
4254 * | 3933 * |
4255 * [webPropertyId] - Web property ID to create the link for. | 3934 * [webPropertyId] - Web property ID to create the link for. |
4256 * | 3935 * |
4257 * Completes with a [EntityAdWordsLink]. | 3936 * Completes with a [EntityAdWordsLink]. |
4258 * | 3937 * |
4259 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 3938 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
4260 * error. | 3939 * error. |
4261 * | 3940 * |
4262 * If the used [http.Client] completes with an error when making a REST call, | 3941 * If the used [http.Client] completes with an error when making a REST call, |
4263 * this method will complete with the same error. | 3942 * this method will complete with the same error. |
4264 */ | 3943 */ |
4265 async.Future<EntityAdWordsLink> insert(EntityAdWordsLink request, core.String
accountId, core.String webPropertyId) { | 3944 async.Future<EntityAdWordsLink> insert(EntityAdWordsLink request, core.String
accountId, core.String webPropertyId) { |
4266 var _url = null; | 3945 var _url = null; |
4267 var _queryParams = new core.Map(); | 3946 var _queryParams = new core.Map(); |
4268 var _uploadMedia = null; | 3947 var _uploadMedia = null; |
4269 var _uploadOptions = null; | 3948 var _uploadOptions = null; |
4270 var _downloadOptions = common.DownloadOptions.Metadata; | 3949 var _downloadOptions = commons.DownloadOptions.Metadata; |
4271 var _body = null; | 3950 var _body = null; |
4272 | 3951 |
4273 if (request != null) { | 3952 if (request != null) { |
4274 _body = convert.JSON.encode((request).toJson()); | 3953 _body = convert.JSON.encode((request).toJson()); |
4275 } | 3954 } |
4276 if (accountId == null) { | 3955 if (accountId == null) { |
4277 throw new core.ArgumentError("Parameter accountId is required."); | 3956 throw new core.ArgumentError("Parameter accountId is required."); |
4278 } | 3957 } |
4279 if (webPropertyId == null) { | 3958 if (webPropertyId == null) { |
4280 throw new core.ArgumentError("Parameter webPropertyId is required."); | 3959 throw new core.ArgumentError("Parameter webPropertyId is required."); |
4281 } | 3960 } |
4282 | 3961 |
4283 | 3962 |
4284 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/webproperties/' + common_internal.Escaper.ecapeVariable('$webPropert
yId') + '/entityAdWordsLinks'; | 3963 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId')
+ '/webproperties/' + commons.Escaper.ecapeVariable('$webPropertyId') + '/entity
AdWordsLinks'; |
4285 | 3964 |
4286 var _response = _requester.request(_url, | 3965 var _response = _requester.request(_url, |
4287 "POST", | 3966 "POST", |
4288 body: _body, | 3967 body: _body, |
4289 queryParams: _queryParams, | 3968 queryParams: _queryParams, |
4290 uploadOptions: _uploadOptions, | 3969 uploadOptions: _uploadOptions, |
4291 uploadMedia: _uploadMedia, | 3970 uploadMedia: _uploadMedia, |
4292 downloadOptions: _downloadOptions); | 3971 downloadOptions: _downloadOptions); |
4293 return _response.then((data) => new EntityAdWordsLink.fromJson(data)); | 3972 return _response.then((data) => new EntityAdWordsLink.fromJson(data)); |
4294 } | 3973 } |
(...skipping 10 matching lines...) Expand all Loading... |
4305 * | 3984 * |
4306 * [max_results] - The maximum number of webProperty-AdWords links to include | 3985 * [max_results] - The maximum number of webProperty-AdWords links to include |
4307 * in this response. | 3986 * in this response. |
4308 * | 3987 * |
4309 * [start_index] - An index of the first webProperty-AdWords link to retrieve. | 3988 * [start_index] - An index of the first webProperty-AdWords link to retrieve. |
4310 * Use this parameter as a pagination mechanism along with the max-results | 3989 * Use this parameter as a pagination mechanism along with the max-results |
4311 * parameter. | 3990 * parameter. |
4312 * | 3991 * |
4313 * Completes with a [EntityAdWordsLinks]. | 3992 * Completes with a [EntityAdWordsLinks]. |
4314 * | 3993 * |
4315 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 3994 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
4316 * error. | 3995 * error. |
4317 * | 3996 * |
4318 * If the used [http.Client] completes with an error when making a REST call, | 3997 * If the used [http.Client] completes with an error when making a REST call, |
4319 * this method will complete with the same error. | 3998 * this method will complete with the same error. |
4320 */ | 3999 */ |
4321 async.Future<EntityAdWordsLinks> list(core.String accountId, core.String webPr
opertyId, {core.int max_results, core.int start_index}) { | 4000 async.Future<EntityAdWordsLinks> list(core.String accountId, core.String webPr
opertyId, {core.int max_results, core.int start_index}) { |
4322 var _url = null; | 4001 var _url = null; |
4323 var _queryParams = new core.Map(); | 4002 var _queryParams = new core.Map(); |
4324 var _uploadMedia = null; | 4003 var _uploadMedia = null; |
4325 var _uploadOptions = null; | 4004 var _uploadOptions = null; |
4326 var _downloadOptions = common.DownloadOptions.Metadata; | 4005 var _downloadOptions = commons.DownloadOptions.Metadata; |
4327 var _body = null; | 4006 var _body = null; |
4328 | 4007 |
4329 if (accountId == null) { | 4008 if (accountId == null) { |
4330 throw new core.ArgumentError("Parameter accountId is required."); | 4009 throw new core.ArgumentError("Parameter accountId is required."); |
4331 } | 4010 } |
4332 if (webPropertyId == null) { | 4011 if (webPropertyId == null) { |
4333 throw new core.ArgumentError("Parameter webPropertyId is required."); | 4012 throw new core.ArgumentError("Parameter webPropertyId is required."); |
4334 } | 4013 } |
4335 if (max_results != null) { | 4014 if (max_results != null) { |
4336 _queryParams["max-results"] = ["${max_results}"]; | 4015 _queryParams["max-results"] = ["${max_results}"]; |
4337 } | 4016 } |
4338 if (start_index != null) { | 4017 if (start_index != null) { |
4339 _queryParams["start-index"] = ["${start_index}"]; | 4018 _queryParams["start-index"] = ["${start_index}"]; |
4340 } | 4019 } |
4341 | 4020 |
4342 | 4021 |
4343 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/webproperties/' + common_internal.Escaper.ecapeVariable('$webPropert
yId') + '/entityAdWordsLinks'; | 4022 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId')
+ '/webproperties/' + commons.Escaper.ecapeVariable('$webPropertyId') + '/entity
AdWordsLinks'; |
4344 | 4023 |
4345 var _response = _requester.request(_url, | 4024 var _response = _requester.request(_url, |
4346 "GET", | 4025 "GET", |
4347 body: _body, | 4026 body: _body, |
4348 queryParams: _queryParams, | 4027 queryParams: _queryParams, |
4349 uploadOptions: _uploadOptions, | 4028 uploadOptions: _uploadOptions, |
4350 uploadMedia: _uploadMedia, | 4029 uploadMedia: _uploadMedia, |
4351 downloadOptions: _downloadOptions); | 4030 downloadOptions: _downloadOptions); |
4352 return _response.then((data) => new EntityAdWordsLinks.fromJson(data)); | 4031 return _response.then((data) => new EntityAdWordsLinks.fromJson(data)); |
4353 } | 4032 } |
4354 | 4033 |
4355 /** | 4034 /** |
4356 * Updates an existing webProperty-AdWords link. This method supports patch | 4035 * Updates an existing webProperty-AdWords link. This method supports patch |
4357 * semantics. | 4036 * semantics. |
4358 * | 4037 * |
4359 * [request] - The metadata request object. | 4038 * [request] - The metadata request object. |
4360 * | 4039 * |
4361 * Request parameters: | 4040 * Request parameters: |
4362 * | 4041 * |
4363 * [accountId] - ID of the account which the given web property belongs to. | 4042 * [accountId] - ID of the account which the given web property belongs to. |
4364 * | 4043 * |
4365 * [webPropertyId] - Web property ID to retrieve the AdWords link for. | 4044 * [webPropertyId] - Web property ID to retrieve the AdWords link for. |
4366 * | 4045 * |
4367 * [webPropertyAdWordsLinkId] - Web property-AdWords link ID. | 4046 * [webPropertyAdWordsLinkId] - Web property-AdWords link ID. |
4368 * | 4047 * |
4369 * Completes with a [EntityAdWordsLink]. | 4048 * Completes with a [EntityAdWordsLink]. |
4370 * | 4049 * |
4371 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 4050 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
4372 * error. | 4051 * error. |
4373 * | 4052 * |
4374 * If the used [http.Client] completes with an error when making a REST call, | 4053 * If the used [http.Client] completes with an error when making a REST call, |
4375 * this method will complete with the same error. | 4054 * this method will complete with the same error. |
4376 */ | 4055 */ |
4377 async.Future<EntityAdWordsLink> patch(EntityAdWordsLink request, core.String a
ccountId, core.String webPropertyId, core.String webPropertyAdWordsLinkId) { | 4056 async.Future<EntityAdWordsLink> patch(EntityAdWordsLink request, core.String a
ccountId, core.String webPropertyId, core.String webPropertyAdWordsLinkId) { |
4378 var _url = null; | 4057 var _url = null; |
4379 var _queryParams = new core.Map(); | 4058 var _queryParams = new core.Map(); |
4380 var _uploadMedia = null; | 4059 var _uploadMedia = null; |
4381 var _uploadOptions = null; | 4060 var _uploadOptions = null; |
4382 var _downloadOptions = common.DownloadOptions.Metadata; | 4061 var _downloadOptions = commons.DownloadOptions.Metadata; |
4383 var _body = null; | 4062 var _body = null; |
4384 | 4063 |
4385 if (request != null) { | 4064 if (request != null) { |
4386 _body = convert.JSON.encode((request).toJson()); | 4065 _body = convert.JSON.encode((request).toJson()); |
4387 } | 4066 } |
4388 if (accountId == null) { | 4067 if (accountId == null) { |
4389 throw new core.ArgumentError("Parameter accountId is required."); | 4068 throw new core.ArgumentError("Parameter accountId is required."); |
4390 } | 4069 } |
4391 if (webPropertyId == null) { | 4070 if (webPropertyId == null) { |
4392 throw new core.ArgumentError("Parameter webPropertyId is required."); | 4071 throw new core.ArgumentError("Parameter webPropertyId is required."); |
4393 } | 4072 } |
4394 if (webPropertyAdWordsLinkId == null) { | 4073 if (webPropertyAdWordsLinkId == null) { |
4395 throw new core.ArgumentError("Parameter webPropertyAdWordsLinkId is requir
ed."); | 4074 throw new core.ArgumentError("Parameter webPropertyAdWordsLinkId is requir
ed."); |
4396 } | 4075 } |
4397 | 4076 |
4398 | 4077 |
4399 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/webproperties/' + common_internal.Escaper.ecapeVariable('$webPropert
yId') + '/entityAdWordsLinks/' + common_internal.Escaper.ecapeVariable('$webProp
ertyAdWordsLinkId'); | 4078 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId')
+ '/webproperties/' + commons.Escaper.ecapeVariable('$webPropertyId') + '/entity
AdWordsLinks/' + commons.Escaper.ecapeVariable('$webPropertyAdWordsLinkId'); |
4400 | 4079 |
4401 var _response = _requester.request(_url, | 4080 var _response = _requester.request(_url, |
4402 "PATCH", | 4081 "PATCH", |
4403 body: _body, | 4082 body: _body, |
4404 queryParams: _queryParams, | 4083 queryParams: _queryParams, |
4405 uploadOptions: _uploadOptions, | 4084 uploadOptions: _uploadOptions, |
4406 uploadMedia: _uploadMedia, | 4085 uploadMedia: _uploadMedia, |
4407 downloadOptions: _downloadOptions); | 4086 downloadOptions: _downloadOptions); |
4408 return _response.then((data) => new EntityAdWordsLink.fromJson(data)); | 4087 return _response.then((data) => new EntityAdWordsLink.fromJson(data)); |
4409 } | 4088 } |
4410 | 4089 |
4411 /** | 4090 /** |
4412 * Updates an existing webProperty-AdWords link. | 4091 * Updates an existing webProperty-AdWords link. |
4413 * | 4092 * |
4414 * [request] - The metadata request object. | 4093 * [request] - The metadata request object. |
4415 * | 4094 * |
4416 * Request parameters: | 4095 * Request parameters: |
4417 * | 4096 * |
4418 * [accountId] - ID of the account which the given web property belongs to. | 4097 * [accountId] - ID of the account which the given web property belongs to. |
4419 * | 4098 * |
4420 * [webPropertyId] - Web property ID to retrieve the AdWords link for. | 4099 * [webPropertyId] - Web property ID to retrieve the AdWords link for. |
4421 * | 4100 * |
4422 * [webPropertyAdWordsLinkId] - Web property-AdWords link ID. | 4101 * [webPropertyAdWordsLinkId] - Web property-AdWords link ID. |
4423 * | 4102 * |
4424 * Completes with a [EntityAdWordsLink]. | 4103 * Completes with a [EntityAdWordsLink]. |
4425 * | 4104 * |
4426 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 4105 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
4427 * error. | 4106 * error. |
4428 * | 4107 * |
4429 * If the used [http.Client] completes with an error when making a REST call, | 4108 * If the used [http.Client] completes with an error when making a REST call, |
4430 * this method will complete with the same error. | 4109 * this method will complete with the same error. |
4431 */ | 4110 */ |
4432 async.Future<EntityAdWordsLink> update(EntityAdWordsLink request, core.String
accountId, core.String webPropertyId, core.String webPropertyAdWordsLinkId) { | 4111 async.Future<EntityAdWordsLink> update(EntityAdWordsLink request, core.String
accountId, core.String webPropertyId, core.String webPropertyAdWordsLinkId) { |
4433 var _url = null; | 4112 var _url = null; |
4434 var _queryParams = new core.Map(); | 4113 var _queryParams = new core.Map(); |
4435 var _uploadMedia = null; | 4114 var _uploadMedia = null; |
4436 var _uploadOptions = null; | 4115 var _uploadOptions = null; |
4437 var _downloadOptions = common.DownloadOptions.Metadata; | 4116 var _downloadOptions = commons.DownloadOptions.Metadata; |
4438 var _body = null; | 4117 var _body = null; |
4439 | 4118 |
4440 if (request != null) { | 4119 if (request != null) { |
4441 _body = convert.JSON.encode((request).toJson()); | 4120 _body = convert.JSON.encode((request).toJson()); |
4442 } | 4121 } |
4443 if (accountId == null) { | 4122 if (accountId == null) { |
4444 throw new core.ArgumentError("Parameter accountId is required."); | 4123 throw new core.ArgumentError("Parameter accountId is required."); |
4445 } | 4124 } |
4446 if (webPropertyId == null) { | 4125 if (webPropertyId == null) { |
4447 throw new core.ArgumentError("Parameter webPropertyId is required."); | 4126 throw new core.ArgumentError("Parameter webPropertyId is required."); |
4448 } | 4127 } |
4449 if (webPropertyAdWordsLinkId == null) { | 4128 if (webPropertyAdWordsLinkId == null) { |
4450 throw new core.ArgumentError("Parameter webPropertyAdWordsLinkId is requir
ed."); | 4129 throw new core.ArgumentError("Parameter webPropertyAdWordsLinkId is requir
ed."); |
4451 } | 4130 } |
4452 | 4131 |
4453 | 4132 |
4454 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/webproperties/' + common_internal.Escaper.ecapeVariable('$webPropert
yId') + '/entityAdWordsLinks/' + common_internal.Escaper.ecapeVariable('$webProp
ertyAdWordsLinkId'); | 4133 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId')
+ '/webproperties/' + commons.Escaper.ecapeVariable('$webPropertyId') + '/entity
AdWordsLinks/' + commons.Escaper.ecapeVariable('$webPropertyAdWordsLinkId'); |
4455 | 4134 |
4456 var _response = _requester.request(_url, | 4135 var _response = _requester.request(_url, |
4457 "PUT", | 4136 "PUT", |
4458 body: _body, | 4137 body: _body, |
4459 queryParams: _queryParams, | 4138 queryParams: _queryParams, |
4460 uploadOptions: _uploadOptions, | 4139 uploadOptions: _uploadOptions, |
4461 uploadMedia: _uploadMedia, | 4140 uploadMedia: _uploadMedia, |
4462 downloadOptions: _downloadOptions); | 4141 downloadOptions: _downloadOptions); |
4463 return _response.then((data) => new EntityAdWordsLink.fromJson(data)); | 4142 return _response.then((data) => new EntityAdWordsLink.fromJson(data)); |
4464 } | 4143 } |
4465 | 4144 |
4466 } | 4145 } |
4467 | 4146 |
4468 | 4147 |
4469 /** Not documented yet. */ | |
4470 class ManagementWebpropertiesResourceApi { | 4148 class ManagementWebpropertiesResourceApi { |
4471 final common_internal.ApiRequester _requester; | 4149 final commons.ApiRequester _requester; |
4472 | 4150 |
4473 ManagementWebpropertiesResourceApi(common_internal.ApiRequester client) : | 4151 ManagementWebpropertiesResourceApi(commons.ApiRequester client) : |
4474 _requester = client; | 4152 _requester = client; |
4475 | 4153 |
4476 /** | 4154 /** |
4477 * Gets a web property to which the user has access. | 4155 * Gets a web property to which the user has access. |
4478 * | 4156 * |
4479 * Request parameters: | 4157 * Request parameters: |
4480 * | 4158 * |
4481 * [accountId] - Account ID to retrieve the web property for. | 4159 * [accountId] - Account ID to retrieve the web property for. |
4482 * Value must have pattern "[0-9]+". | 4160 * Value must have pattern "[0-9]+". |
4483 * | 4161 * |
4484 * [webPropertyId] - ID to retrieve the web property for. | 4162 * [webPropertyId] - ID to retrieve the web property for. |
4485 * Value must have pattern "UA-[0-9]+-[0-9]+". | 4163 * Value must have pattern "UA-[0-9]+-[0-9]+". |
4486 * | 4164 * |
4487 * Completes with a [Webproperty]. | 4165 * Completes with a [Webproperty]. |
4488 * | 4166 * |
4489 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 4167 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
4490 * error. | 4168 * error. |
4491 * | 4169 * |
4492 * If the used [http.Client] completes with an error when making a REST call, | 4170 * If the used [http.Client] completes with an error when making a REST call, |
4493 * this method will complete with the same error. | 4171 * this method will complete with the same error. |
4494 */ | 4172 */ |
4495 async.Future<Webproperty> get(core.String accountId, core.String webPropertyId
) { | 4173 async.Future<Webproperty> get(core.String accountId, core.String webPropertyId
) { |
4496 var _url = null; | 4174 var _url = null; |
4497 var _queryParams = new core.Map(); | 4175 var _queryParams = new core.Map(); |
4498 var _uploadMedia = null; | 4176 var _uploadMedia = null; |
4499 var _uploadOptions = null; | 4177 var _uploadOptions = null; |
4500 var _downloadOptions = common.DownloadOptions.Metadata; | 4178 var _downloadOptions = commons.DownloadOptions.Metadata; |
4501 var _body = null; | 4179 var _body = null; |
4502 | 4180 |
4503 if (accountId == null) { | 4181 if (accountId == null) { |
4504 throw new core.ArgumentError("Parameter accountId is required."); | 4182 throw new core.ArgumentError("Parameter accountId is required."); |
4505 } | 4183 } |
4506 if (webPropertyId == null) { | 4184 if (webPropertyId == null) { |
4507 throw new core.ArgumentError("Parameter webPropertyId is required."); | 4185 throw new core.ArgumentError("Parameter webPropertyId is required."); |
4508 } | 4186 } |
4509 | 4187 |
4510 | 4188 |
4511 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/webproperties/' + common_internal.Escaper.ecapeVariable('$webPropert
yId'); | 4189 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId')
+ '/webproperties/' + commons.Escaper.ecapeVariable('$webPropertyId'); |
4512 | 4190 |
4513 var _response = _requester.request(_url, | 4191 var _response = _requester.request(_url, |
4514 "GET", | 4192 "GET", |
4515 body: _body, | 4193 body: _body, |
4516 queryParams: _queryParams, | 4194 queryParams: _queryParams, |
4517 uploadOptions: _uploadOptions, | 4195 uploadOptions: _uploadOptions, |
4518 uploadMedia: _uploadMedia, | 4196 uploadMedia: _uploadMedia, |
4519 downloadOptions: _downloadOptions); | 4197 downloadOptions: _downloadOptions); |
4520 return _response.then((data) => new Webproperty.fromJson(data)); | 4198 return _response.then((data) => new Webproperty.fromJson(data)); |
4521 } | 4199 } |
4522 | 4200 |
4523 /** | 4201 /** |
4524 * Create a new property if the account has fewer than 20 properties. Web | 4202 * Create a new property if the account has fewer than 20 properties. Web |
4525 * properties are visible in the Google Analytics interface only if they have | 4203 * properties are visible in the Google Analytics interface only if they have |
4526 * at least one profile. | 4204 * at least one profile. |
4527 * | 4205 * |
4528 * [request] - The metadata request object. | 4206 * [request] - The metadata request object. |
4529 * | 4207 * |
4530 * Request parameters: | 4208 * Request parameters: |
4531 * | 4209 * |
4532 * [accountId] - Account ID to create the web property for. | 4210 * [accountId] - Account ID to create the web property for. |
4533 * | 4211 * |
4534 * Completes with a [Webproperty]. | 4212 * Completes with a [Webproperty]. |
4535 * | 4213 * |
4536 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 4214 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
4537 * error. | 4215 * error. |
4538 * | 4216 * |
4539 * If the used [http.Client] completes with an error when making a REST call, | 4217 * If the used [http.Client] completes with an error when making a REST call, |
4540 * this method will complete with the same error. | 4218 * this method will complete with the same error. |
4541 */ | 4219 */ |
4542 async.Future<Webproperty> insert(Webproperty request, core.String accountId) { | 4220 async.Future<Webproperty> insert(Webproperty request, core.String accountId) { |
4543 var _url = null; | 4221 var _url = null; |
4544 var _queryParams = new core.Map(); | 4222 var _queryParams = new core.Map(); |
4545 var _uploadMedia = null; | 4223 var _uploadMedia = null; |
4546 var _uploadOptions = null; | 4224 var _uploadOptions = null; |
4547 var _downloadOptions = common.DownloadOptions.Metadata; | 4225 var _downloadOptions = commons.DownloadOptions.Metadata; |
4548 var _body = null; | 4226 var _body = null; |
4549 | 4227 |
4550 if (request != null) { | 4228 if (request != null) { |
4551 _body = convert.JSON.encode((request).toJson()); | 4229 _body = convert.JSON.encode((request).toJson()); |
4552 } | 4230 } |
4553 if (accountId == null) { | 4231 if (accountId == null) { |
4554 throw new core.ArgumentError("Parameter accountId is required."); | 4232 throw new core.ArgumentError("Parameter accountId is required."); |
4555 } | 4233 } |
4556 | 4234 |
4557 | 4235 |
4558 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/webproperties'; | 4236 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId')
+ '/webproperties'; |
4559 | 4237 |
4560 var _response = _requester.request(_url, | 4238 var _response = _requester.request(_url, |
4561 "POST", | 4239 "POST", |
4562 body: _body, | 4240 body: _body, |
4563 queryParams: _queryParams, | 4241 queryParams: _queryParams, |
4564 uploadOptions: _uploadOptions, | 4242 uploadOptions: _uploadOptions, |
4565 uploadMedia: _uploadMedia, | 4243 uploadMedia: _uploadMedia, |
4566 downloadOptions: _downloadOptions); | 4244 downloadOptions: _downloadOptions); |
4567 return _response.then((data) => new Webproperty.fromJson(data)); | 4245 return _response.then((data) => new Webproperty.fromJson(data)); |
4568 } | 4246 } |
4569 | 4247 |
4570 /** | 4248 /** |
4571 * Lists web properties to which the user has access. | 4249 * Lists web properties to which the user has access. |
4572 * | 4250 * |
4573 * Request parameters: | 4251 * Request parameters: |
4574 * | 4252 * |
4575 * [accountId] - Account ID to retrieve web properties for. Can either be a | 4253 * [accountId] - Account ID to retrieve web properties for. Can either be a |
4576 * specific account ID or '~all', which refers to all the accounts that user | 4254 * specific account ID or '~all', which refers to all the accounts that user |
4577 * has access to. | 4255 * has access to. |
4578 * | 4256 * |
4579 * [max_results] - The maximum number of web properties to include in this | 4257 * [max_results] - The maximum number of web properties to include in this |
4580 * response. | 4258 * response. |
4581 * | 4259 * |
4582 * [start_index] - An index of the first entity to retrieve. Use this | 4260 * [start_index] - An index of the first entity to retrieve. Use this |
4583 * parameter as a pagination mechanism along with the max-results parameter. | 4261 * parameter as a pagination mechanism along with the max-results parameter. |
4584 * | 4262 * |
4585 * Completes with a [Webproperties]. | 4263 * Completes with a [Webproperties]. |
4586 * | 4264 * |
4587 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 4265 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
4588 * error. | 4266 * error. |
4589 * | 4267 * |
4590 * If the used [http.Client] completes with an error when making a REST call, | 4268 * If the used [http.Client] completes with an error when making a REST call, |
4591 * this method will complete with the same error. | 4269 * this method will complete with the same error. |
4592 */ | 4270 */ |
4593 async.Future<Webproperties> list(core.String accountId, {core.int max_results,
core.int start_index}) { | 4271 async.Future<Webproperties> list(core.String accountId, {core.int max_results,
core.int start_index}) { |
4594 var _url = null; | 4272 var _url = null; |
4595 var _queryParams = new core.Map(); | 4273 var _queryParams = new core.Map(); |
4596 var _uploadMedia = null; | 4274 var _uploadMedia = null; |
4597 var _uploadOptions = null; | 4275 var _uploadOptions = null; |
4598 var _downloadOptions = common.DownloadOptions.Metadata; | 4276 var _downloadOptions = commons.DownloadOptions.Metadata; |
4599 var _body = null; | 4277 var _body = null; |
4600 | 4278 |
4601 if (accountId == null) { | 4279 if (accountId == null) { |
4602 throw new core.ArgumentError("Parameter accountId is required."); | 4280 throw new core.ArgumentError("Parameter accountId is required."); |
4603 } | 4281 } |
4604 if (max_results != null) { | 4282 if (max_results != null) { |
4605 _queryParams["max-results"] = ["${max_results}"]; | 4283 _queryParams["max-results"] = ["${max_results}"]; |
4606 } | 4284 } |
4607 if (start_index != null) { | 4285 if (start_index != null) { |
4608 _queryParams["start-index"] = ["${start_index}"]; | 4286 _queryParams["start-index"] = ["${start_index}"]; |
4609 } | 4287 } |
4610 | 4288 |
4611 | 4289 |
4612 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/webproperties'; | 4290 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId')
+ '/webproperties'; |
4613 | 4291 |
4614 var _response = _requester.request(_url, | 4292 var _response = _requester.request(_url, |
4615 "GET", | 4293 "GET", |
4616 body: _body, | 4294 body: _body, |
4617 queryParams: _queryParams, | 4295 queryParams: _queryParams, |
4618 uploadOptions: _uploadOptions, | 4296 uploadOptions: _uploadOptions, |
4619 uploadMedia: _uploadMedia, | 4297 uploadMedia: _uploadMedia, |
4620 downloadOptions: _downloadOptions); | 4298 downloadOptions: _downloadOptions); |
4621 return _response.then((data) => new Webproperties.fromJson(data)); | 4299 return _response.then((data) => new Webproperties.fromJson(data)); |
4622 } | 4300 } |
4623 | 4301 |
4624 /** | 4302 /** |
4625 * Updates an existing web property. This method supports patch semantics. | 4303 * Updates an existing web property. This method supports patch semantics. |
4626 * | 4304 * |
4627 * [request] - The metadata request object. | 4305 * [request] - The metadata request object. |
4628 * | 4306 * |
4629 * Request parameters: | 4307 * Request parameters: |
4630 * | 4308 * |
4631 * [accountId] - Account ID to which the web property belongs | 4309 * [accountId] - Account ID to which the web property belongs |
4632 * | 4310 * |
4633 * [webPropertyId] - Web property ID | 4311 * [webPropertyId] - Web property ID |
4634 * | 4312 * |
4635 * Completes with a [Webproperty]. | 4313 * Completes with a [Webproperty]. |
4636 * | 4314 * |
4637 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 4315 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
4638 * error. | 4316 * error. |
4639 * | 4317 * |
4640 * If the used [http.Client] completes with an error when making a REST call, | 4318 * If the used [http.Client] completes with an error when making a REST call, |
4641 * this method will complete with the same error. | 4319 * this method will complete with the same error. |
4642 */ | 4320 */ |
4643 async.Future<Webproperty> patch(Webproperty request, core.String accountId, co
re.String webPropertyId) { | 4321 async.Future<Webproperty> patch(Webproperty request, core.String accountId, co
re.String webPropertyId) { |
4644 var _url = null; | 4322 var _url = null; |
4645 var _queryParams = new core.Map(); | 4323 var _queryParams = new core.Map(); |
4646 var _uploadMedia = null; | 4324 var _uploadMedia = null; |
4647 var _uploadOptions = null; | 4325 var _uploadOptions = null; |
4648 var _downloadOptions = common.DownloadOptions.Metadata; | 4326 var _downloadOptions = commons.DownloadOptions.Metadata; |
4649 var _body = null; | 4327 var _body = null; |
4650 | 4328 |
4651 if (request != null) { | 4329 if (request != null) { |
4652 _body = convert.JSON.encode((request).toJson()); | 4330 _body = convert.JSON.encode((request).toJson()); |
4653 } | 4331 } |
4654 if (accountId == null) { | 4332 if (accountId == null) { |
4655 throw new core.ArgumentError("Parameter accountId is required."); | 4333 throw new core.ArgumentError("Parameter accountId is required."); |
4656 } | 4334 } |
4657 if (webPropertyId == null) { | 4335 if (webPropertyId == null) { |
4658 throw new core.ArgumentError("Parameter webPropertyId is required."); | 4336 throw new core.ArgumentError("Parameter webPropertyId is required."); |
4659 } | 4337 } |
4660 | 4338 |
4661 | 4339 |
4662 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/webproperties/' + common_internal.Escaper.ecapeVariable('$webPropert
yId'); | 4340 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId')
+ '/webproperties/' + commons.Escaper.ecapeVariable('$webPropertyId'); |
4663 | 4341 |
4664 var _response = _requester.request(_url, | 4342 var _response = _requester.request(_url, |
4665 "PATCH", | 4343 "PATCH", |
4666 body: _body, | 4344 body: _body, |
4667 queryParams: _queryParams, | 4345 queryParams: _queryParams, |
4668 uploadOptions: _uploadOptions, | 4346 uploadOptions: _uploadOptions, |
4669 uploadMedia: _uploadMedia, | 4347 uploadMedia: _uploadMedia, |
4670 downloadOptions: _downloadOptions); | 4348 downloadOptions: _downloadOptions); |
4671 return _response.then((data) => new Webproperty.fromJson(data)); | 4349 return _response.then((data) => new Webproperty.fromJson(data)); |
4672 } | 4350 } |
4673 | 4351 |
4674 /** | 4352 /** |
4675 * Updates an existing web property. | 4353 * Updates an existing web property. |
4676 * | 4354 * |
4677 * [request] - The metadata request object. | 4355 * [request] - The metadata request object. |
4678 * | 4356 * |
4679 * Request parameters: | 4357 * Request parameters: |
4680 * | 4358 * |
4681 * [accountId] - Account ID to which the web property belongs | 4359 * [accountId] - Account ID to which the web property belongs |
4682 * | 4360 * |
4683 * [webPropertyId] - Web property ID | 4361 * [webPropertyId] - Web property ID |
4684 * | 4362 * |
4685 * Completes with a [Webproperty]. | 4363 * Completes with a [Webproperty]. |
4686 * | 4364 * |
4687 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 4365 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
4688 * error. | 4366 * error. |
4689 * | 4367 * |
4690 * If the used [http.Client] completes with an error when making a REST call, | 4368 * If the used [http.Client] completes with an error when making a REST call, |
4691 * this method will complete with the same error. | 4369 * this method will complete with the same error. |
4692 */ | 4370 */ |
4693 async.Future<Webproperty> update(Webproperty request, core.String accountId, c
ore.String webPropertyId) { | 4371 async.Future<Webproperty> update(Webproperty request, core.String accountId, c
ore.String webPropertyId) { |
4694 var _url = null; | 4372 var _url = null; |
4695 var _queryParams = new core.Map(); | 4373 var _queryParams = new core.Map(); |
4696 var _uploadMedia = null; | 4374 var _uploadMedia = null; |
4697 var _uploadOptions = null; | 4375 var _uploadOptions = null; |
4698 var _downloadOptions = common.DownloadOptions.Metadata; | 4376 var _downloadOptions = commons.DownloadOptions.Metadata; |
4699 var _body = null; | 4377 var _body = null; |
4700 | 4378 |
4701 if (request != null) { | 4379 if (request != null) { |
4702 _body = convert.JSON.encode((request).toJson()); | 4380 _body = convert.JSON.encode((request).toJson()); |
4703 } | 4381 } |
4704 if (accountId == null) { | 4382 if (accountId == null) { |
4705 throw new core.ArgumentError("Parameter accountId is required."); | 4383 throw new core.ArgumentError("Parameter accountId is required."); |
4706 } | 4384 } |
4707 if (webPropertyId == null) { | 4385 if (webPropertyId == null) { |
4708 throw new core.ArgumentError("Parameter webPropertyId is required."); | 4386 throw new core.ArgumentError("Parameter webPropertyId is required."); |
4709 } | 4387 } |
4710 | 4388 |
4711 | 4389 |
4712 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/webproperties/' + common_internal.Escaper.ecapeVariable('$webPropert
yId'); | 4390 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId')
+ '/webproperties/' + commons.Escaper.ecapeVariable('$webPropertyId'); |
4713 | 4391 |
4714 var _response = _requester.request(_url, | 4392 var _response = _requester.request(_url, |
4715 "PUT", | 4393 "PUT", |
4716 body: _body, | 4394 body: _body, |
4717 queryParams: _queryParams, | 4395 queryParams: _queryParams, |
4718 uploadOptions: _uploadOptions, | 4396 uploadOptions: _uploadOptions, |
4719 uploadMedia: _uploadMedia, | 4397 uploadMedia: _uploadMedia, |
4720 downloadOptions: _downloadOptions); | 4398 downloadOptions: _downloadOptions); |
4721 return _response.then((data) => new Webproperty.fromJson(data)); | 4399 return _response.then((data) => new Webproperty.fromJson(data)); |
4722 } | 4400 } |
4723 | 4401 |
4724 } | 4402 } |
4725 | 4403 |
4726 | 4404 |
4727 /** Not documented yet. */ | |
4728 class ManagementWebpropertyUserLinksResourceApi { | 4405 class ManagementWebpropertyUserLinksResourceApi { |
4729 final common_internal.ApiRequester _requester; | 4406 final commons.ApiRequester _requester; |
4730 | 4407 |
4731 ManagementWebpropertyUserLinksResourceApi(common_internal.ApiRequester client)
: | 4408 ManagementWebpropertyUserLinksResourceApi(commons.ApiRequester client) : |
4732 _requester = client; | 4409 _requester = client; |
4733 | 4410 |
4734 /** | 4411 /** |
4735 * Removes a user from the given web property. | 4412 * Removes a user from the given web property. |
4736 * | 4413 * |
4737 * Request parameters: | 4414 * Request parameters: |
4738 * | 4415 * |
4739 * [accountId] - Account ID to delete the user link for. | 4416 * [accountId] - Account ID to delete the user link for. |
4740 * | 4417 * |
4741 * [webPropertyId] - Web Property ID to delete the user link for. | 4418 * [webPropertyId] - Web Property ID to delete the user link for. |
4742 * | 4419 * |
4743 * [linkId] - Link ID to delete the user link for. | 4420 * [linkId] - Link ID to delete the user link for. |
4744 * | 4421 * |
4745 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 4422 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
4746 * error. | 4423 * error. |
4747 * | 4424 * |
4748 * If the used [http.Client] completes with an error when making a REST call, | 4425 * If the used [http.Client] completes with an error when making a REST call, |
4749 * this method will complete with the same error. | 4426 * this method will complete with the same error. |
4750 */ | 4427 */ |
4751 async.Future delete(core.String accountId, core.String webPropertyId, core.Str
ing linkId) { | 4428 async.Future delete(core.String accountId, core.String webPropertyId, core.Str
ing linkId) { |
4752 var _url = null; | 4429 var _url = null; |
4753 var _queryParams = new core.Map(); | 4430 var _queryParams = new core.Map(); |
4754 var _uploadMedia = null; | 4431 var _uploadMedia = null; |
4755 var _uploadOptions = null; | 4432 var _uploadOptions = null; |
4756 var _downloadOptions = common.DownloadOptions.Metadata; | 4433 var _downloadOptions = commons.DownloadOptions.Metadata; |
4757 var _body = null; | 4434 var _body = null; |
4758 | 4435 |
4759 if (accountId == null) { | 4436 if (accountId == null) { |
4760 throw new core.ArgumentError("Parameter accountId is required."); | 4437 throw new core.ArgumentError("Parameter accountId is required."); |
4761 } | 4438 } |
4762 if (webPropertyId == null) { | 4439 if (webPropertyId == null) { |
4763 throw new core.ArgumentError("Parameter webPropertyId is required."); | 4440 throw new core.ArgumentError("Parameter webPropertyId is required."); |
4764 } | 4441 } |
4765 if (linkId == null) { | 4442 if (linkId == null) { |
4766 throw new core.ArgumentError("Parameter linkId is required."); | 4443 throw new core.ArgumentError("Parameter linkId is required."); |
4767 } | 4444 } |
4768 | 4445 |
4769 _downloadOptions = null; | 4446 _downloadOptions = null; |
4770 | 4447 |
4771 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/webproperties/' + common_internal.Escaper.ecapeVariable('$webPropert
yId') + '/entityUserLinks/' + common_internal.Escaper.ecapeVariable('$linkId'); | 4448 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId')
+ '/webproperties/' + commons.Escaper.ecapeVariable('$webPropertyId') + '/entity
UserLinks/' + commons.Escaper.ecapeVariable('$linkId'); |
4772 | 4449 |
4773 var _response = _requester.request(_url, | 4450 var _response = _requester.request(_url, |
4774 "DELETE", | 4451 "DELETE", |
4775 body: _body, | 4452 body: _body, |
4776 queryParams: _queryParams, | 4453 queryParams: _queryParams, |
4777 uploadOptions: _uploadOptions, | 4454 uploadOptions: _uploadOptions, |
4778 uploadMedia: _uploadMedia, | 4455 uploadMedia: _uploadMedia, |
4779 downloadOptions: _downloadOptions); | 4456 downloadOptions: _downloadOptions); |
4780 return _response.then((data) => null); | 4457 return _response.then((data) => null); |
4781 } | 4458 } |
4782 | 4459 |
4783 /** | 4460 /** |
4784 * Adds a new user to the given web property. | 4461 * Adds a new user to the given web property. |
4785 * | 4462 * |
4786 * [request] - The metadata request object. | 4463 * [request] - The metadata request object. |
4787 * | 4464 * |
4788 * Request parameters: | 4465 * Request parameters: |
4789 * | 4466 * |
4790 * [accountId] - Account ID to create the user link for. | 4467 * [accountId] - Account ID to create the user link for. |
4791 * | 4468 * |
4792 * [webPropertyId] - Web Property ID to create the user link for. | 4469 * [webPropertyId] - Web Property ID to create the user link for. |
4793 * | 4470 * |
4794 * Completes with a [EntityUserLink]. | 4471 * Completes with a [EntityUserLink]. |
4795 * | 4472 * |
4796 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 4473 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
4797 * error. | 4474 * error. |
4798 * | 4475 * |
4799 * If the used [http.Client] completes with an error when making a REST call, | 4476 * If the used [http.Client] completes with an error when making a REST call, |
4800 * this method will complete with the same error. | 4477 * this method will complete with the same error. |
4801 */ | 4478 */ |
4802 async.Future<EntityUserLink> insert(EntityUserLink request, core.String accoun
tId, core.String webPropertyId) { | 4479 async.Future<EntityUserLink> insert(EntityUserLink request, core.String accoun
tId, core.String webPropertyId) { |
4803 var _url = null; | 4480 var _url = null; |
4804 var _queryParams = new core.Map(); | 4481 var _queryParams = new core.Map(); |
4805 var _uploadMedia = null; | 4482 var _uploadMedia = null; |
4806 var _uploadOptions = null; | 4483 var _uploadOptions = null; |
4807 var _downloadOptions = common.DownloadOptions.Metadata; | 4484 var _downloadOptions = commons.DownloadOptions.Metadata; |
4808 var _body = null; | 4485 var _body = null; |
4809 | 4486 |
4810 if (request != null) { | 4487 if (request != null) { |
4811 _body = convert.JSON.encode((request).toJson()); | 4488 _body = convert.JSON.encode((request).toJson()); |
4812 } | 4489 } |
4813 if (accountId == null) { | 4490 if (accountId == null) { |
4814 throw new core.ArgumentError("Parameter accountId is required."); | 4491 throw new core.ArgumentError("Parameter accountId is required."); |
4815 } | 4492 } |
4816 if (webPropertyId == null) { | 4493 if (webPropertyId == null) { |
4817 throw new core.ArgumentError("Parameter webPropertyId is required."); | 4494 throw new core.ArgumentError("Parameter webPropertyId is required."); |
4818 } | 4495 } |
4819 | 4496 |
4820 | 4497 |
4821 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/webproperties/' + common_internal.Escaper.ecapeVariable('$webPropert
yId') + '/entityUserLinks'; | 4498 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId')
+ '/webproperties/' + commons.Escaper.ecapeVariable('$webPropertyId') + '/entity
UserLinks'; |
4822 | 4499 |
4823 var _response = _requester.request(_url, | 4500 var _response = _requester.request(_url, |
4824 "POST", | 4501 "POST", |
4825 body: _body, | 4502 body: _body, |
4826 queryParams: _queryParams, | 4503 queryParams: _queryParams, |
4827 uploadOptions: _uploadOptions, | 4504 uploadOptions: _uploadOptions, |
4828 uploadMedia: _uploadMedia, | 4505 uploadMedia: _uploadMedia, |
4829 downloadOptions: _downloadOptions); | 4506 downloadOptions: _downloadOptions); |
4830 return _response.then((data) => new EntityUserLink.fromJson(data)); | 4507 return _response.then((data) => new EntityUserLink.fromJson(data)); |
4831 } | 4508 } |
(...skipping 11 matching lines...) Expand all Loading... |
4843 * | 4520 * |
4844 * [max_results] - The maximum number of webProperty-user Links to include in | 4521 * [max_results] - The maximum number of webProperty-user Links to include in |
4845 * this response. | 4522 * this response. |
4846 * | 4523 * |
4847 * [start_index] - An index of the first webProperty-user link to retrieve. | 4524 * [start_index] - An index of the first webProperty-user link to retrieve. |
4848 * Use this parameter as a pagination mechanism along with the max-results | 4525 * Use this parameter as a pagination mechanism along with the max-results |
4849 * parameter. | 4526 * parameter. |
4850 * | 4527 * |
4851 * Completes with a [EntityUserLinks]. | 4528 * Completes with a [EntityUserLinks]. |
4852 * | 4529 * |
4853 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 4530 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
4854 * error. | 4531 * error. |
4855 * | 4532 * |
4856 * If the used [http.Client] completes with an error when making a REST call, | 4533 * If the used [http.Client] completes with an error when making a REST call, |
4857 * this method will complete with the same error. | 4534 * this method will complete with the same error. |
4858 */ | 4535 */ |
4859 async.Future<EntityUserLinks> list(core.String accountId, core.String webPrope
rtyId, {core.int max_results, core.int start_index}) { | 4536 async.Future<EntityUserLinks> list(core.String accountId, core.String webPrope
rtyId, {core.int max_results, core.int start_index}) { |
4860 var _url = null; | 4537 var _url = null; |
4861 var _queryParams = new core.Map(); | 4538 var _queryParams = new core.Map(); |
4862 var _uploadMedia = null; | 4539 var _uploadMedia = null; |
4863 var _uploadOptions = null; | 4540 var _uploadOptions = null; |
4864 var _downloadOptions = common.DownloadOptions.Metadata; | 4541 var _downloadOptions = commons.DownloadOptions.Metadata; |
4865 var _body = null; | 4542 var _body = null; |
4866 | 4543 |
4867 if (accountId == null) { | 4544 if (accountId == null) { |
4868 throw new core.ArgumentError("Parameter accountId is required."); | 4545 throw new core.ArgumentError("Parameter accountId is required."); |
4869 } | 4546 } |
4870 if (webPropertyId == null) { | 4547 if (webPropertyId == null) { |
4871 throw new core.ArgumentError("Parameter webPropertyId is required."); | 4548 throw new core.ArgumentError("Parameter webPropertyId is required."); |
4872 } | 4549 } |
4873 if (max_results != null) { | 4550 if (max_results != null) { |
4874 _queryParams["max-results"] = ["${max_results}"]; | 4551 _queryParams["max-results"] = ["${max_results}"]; |
4875 } | 4552 } |
4876 if (start_index != null) { | 4553 if (start_index != null) { |
4877 _queryParams["start-index"] = ["${start_index}"]; | 4554 _queryParams["start-index"] = ["${start_index}"]; |
4878 } | 4555 } |
4879 | 4556 |
4880 | 4557 |
4881 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/webproperties/' + common_internal.Escaper.ecapeVariable('$webPropert
yId') + '/entityUserLinks'; | 4558 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId')
+ '/webproperties/' + commons.Escaper.ecapeVariable('$webPropertyId') + '/entity
UserLinks'; |
4882 | 4559 |
4883 var _response = _requester.request(_url, | 4560 var _response = _requester.request(_url, |
4884 "GET", | 4561 "GET", |
4885 body: _body, | 4562 body: _body, |
4886 queryParams: _queryParams, | 4563 queryParams: _queryParams, |
4887 uploadOptions: _uploadOptions, | 4564 uploadOptions: _uploadOptions, |
4888 uploadMedia: _uploadMedia, | 4565 uploadMedia: _uploadMedia, |
4889 downloadOptions: _downloadOptions); | 4566 downloadOptions: _downloadOptions); |
4890 return _response.then((data) => new EntityUserLinks.fromJson(data)); | 4567 return _response.then((data) => new EntityUserLinks.fromJson(data)); |
4891 } | 4568 } |
4892 | 4569 |
4893 /** | 4570 /** |
4894 * Updates permissions for an existing user on the given web property. | 4571 * Updates permissions for an existing user on the given web property. |
4895 * | 4572 * |
4896 * [request] - The metadata request object. | 4573 * [request] - The metadata request object. |
4897 * | 4574 * |
4898 * Request parameters: | 4575 * Request parameters: |
4899 * | 4576 * |
4900 * [accountId] - Account ID to update the account-user link for. | 4577 * [accountId] - Account ID to update the account-user link for. |
4901 * | 4578 * |
4902 * [webPropertyId] - Web property ID to update the account-user link for. | 4579 * [webPropertyId] - Web property ID to update the account-user link for. |
4903 * | 4580 * |
4904 * [linkId] - Link ID to update the account-user link for. | 4581 * [linkId] - Link ID to update the account-user link for. |
4905 * | 4582 * |
4906 * Completes with a [EntityUserLink]. | 4583 * Completes with a [EntityUserLink]. |
4907 * | 4584 * |
4908 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 4585 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
4909 * error. | 4586 * error. |
4910 * | 4587 * |
4911 * If the used [http.Client] completes with an error when making a REST call, | 4588 * If the used [http.Client] completes with an error when making a REST call, |
4912 * this method will complete with the same error. | 4589 * this method will complete with the same error. |
4913 */ | 4590 */ |
4914 async.Future<EntityUserLink> update(EntityUserLink request, core.String accoun
tId, core.String webPropertyId, core.String linkId) { | 4591 async.Future<EntityUserLink> update(EntityUserLink request, core.String accoun
tId, core.String webPropertyId, core.String linkId) { |
4915 var _url = null; | 4592 var _url = null; |
4916 var _queryParams = new core.Map(); | 4593 var _queryParams = new core.Map(); |
4917 var _uploadMedia = null; | 4594 var _uploadMedia = null; |
4918 var _uploadOptions = null; | 4595 var _uploadOptions = null; |
4919 var _downloadOptions = common.DownloadOptions.Metadata; | 4596 var _downloadOptions = commons.DownloadOptions.Metadata; |
4920 var _body = null; | 4597 var _body = null; |
4921 | 4598 |
4922 if (request != null) { | 4599 if (request != null) { |
4923 _body = convert.JSON.encode((request).toJson()); | 4600 _body = convert.JSON.encode((request).toJson()); |
4924 } | 4601 } |
4925 if (accountId == null) { | 4602 if (accountId == null) { |
4926 throw new core.ArgumentError("Parameter accountId is required."); | 4603 throw new core.ArgumentError("Parameter accountId is required."); |
4927 } | 4604 } |
4928 if (webPropertyId == null) { | 4605 if (webPropertyId == null) { |
4929 throw new core.ArgumentError("Parameter webPropertyId is required."); | 4606 throw new core.ArgumentError("Parameter webPropertyId is required."); |
4930 } | 4607 } |
4931 if (linkId == null) { | 4608 if (linkId == null) { |
4932 throw new core.ArgumentError("Parameter linkId is required."); | 4609 throw new core.ArgumentError("Parameter linkId is required."); |
4933 } | 4610 } |
4934 | 4611 |
4935 | 4612 |
4936 _url = 'management/accounts/' + common_internal.Escaper.ecapeVariable('$acco
untId') + '/webproperties/' + common_internal.Escaper.ecapeVariable('$webPropert
yId') + '/entityUserLinks/' + common_internal.Escaper.ecapeVariable('$linkId'); | 4613 _url = 'management/accounts/' + commons.Escaper.ecapeVariable('$accountId')
+ '/webproperties/' + commons.Escaper.ecapeVariable('$webPropertyId') + '/entity
UserLinks/' + commons.Escaper.ecapeVariable('$linkId'); |
4937 | 4614 |
4938 var _response = _requester.request(_url, | 4615 var _response = _requester.request(_url, |
4939 "PUT", | 4616 "PUT", |
4940 body: _body, | 4617 body: _body, |
4941 queryParams: _queryParams, | 4618 queryParams: _queryParams, |
4942 uploadOptions: _uploadOptions, | 4619 uploadOptions: _uploadOptions, |
4943 uploadMedia: _uploadMedia, | 4620 uploadMedia: _uploadMedia, |
4944 downloadOptions: _downloadOptions); | 4621 downloadOptions: _downloadOptions); |
4945 return _response.then((data) => new EntityUserLink.fromJson(data)); | 4622 return _response.then((data) => new EntityUserLink.fromJson(data)); |
4946 } | 4623 } |
4947 | 4624 |
4948 } | 4625 } |
4949 | 4626 |
4950 | 4627 |
4951 /** Not documented yet. */ | |
4952 class MetadataResourceApi { | 4628 class MetadataResourceApi { |
4953 final common_internal.ApiRequester _requester; | 4629 final commons.ApiRequester _requester; |
4954 | 4630 |
4955 MetadataColumnsResourceApi get columns => new MetadataColumnsResourceApi(_requ
ester); | 4631 MetadataColumnsResourceApi get columns => new MetadataColumnsResourceApi(_requ
ester); |
4956 | 4632 |
4957 MetadataResourceApi(common_internal.ApiRequester client) : | 4633 MetadataResourceApi(commons.ApiRequester client) : |
4958 _requester = client; | 4634 _requester = client; |
4959 } | 4635 } |
4960 | 4636 |
4961 | 4637 |
4962 /** Not documented yet. */ | |
4963 class MetadataColumnsResourceApi { | 4638 class MetadataColumnsResourceApi { |
4964 final common_internal.ApiRequester _requester; | 4639 final commons.ApiRequester _requester; |
4965 | 4640 |
4966 MetadataColumnsResourceApi(common_internal.ApiRequester client) : | 4641 MetadataColumnsResourceApi(commons.ApiRequester client) : |
4967 _requester = client; | 4642 _requester = client; |
4968 | 4643 |
4969 /** | 4644 /** |
4970 * Lists all columns for a report type | 4645 * Lists all columns for a report type |
4971 * | 4646 * |
4972 * Request parameters: | 4647 * Request parameters: |
4973 * | 4648 * |
4974 * [reportType] - Report type. Allowed Values: 'ga'. Where 'ga' corresponds to | 4649 * [reportType] - Report type. Allowed Values: 'ga'. Where 'ga' corresponds to |
4975 * the Core Reporting API | 4650 * the Core Reporting API |
4976 * Value must have pattern "ga". | 4651 * Value must have pattern "ga". |
4977 * | 4652 * |
4978 * Completes with a [Columns]. | 4653 * Completes with a [Columns]. |
4979 * | 4654 * |
4980 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 4655 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
4981 * error. | 4656 * error. |
4982 * | 4657 * |
4983 * If the used [http.Client] completes with an error when making a REST call, | 4658 * If the used [http.Client] completes with an error when making a REST call, |
4984 * this method will complete with the same error. | 4659 * this method will complete with the same error. |
4985 */ | 4660 */ |
4986 async.Future<Columns> list(core.String reportType) { | 4661 async.Future<Columns> list(core.String reportType) { |
4987 var _url = null; | 4662 var _url = null; |
4988 var _queryParams = new core.Map(); | 4663 var _queryParams = new core.Map(); |
4989 var _uploadMedia = null; | 4664 var _uploadMedia = null; |
4990 var _uploadOptions = null; | 4665 var _uploadOptions = null; |
4991 var _downloadOptions = common.DownloadOptions.Metadata; | 4666 var _downloadOptions = commons.DownloadOptions.Metadata; |
4992 var _body = null; | 4667 var _body = null; |
4993 | 4668 |
4994 if (reportType == null) { | 4669 if (reportType == null) { |
4995 throw new core.ArgumentError("Parameter reportType is required."); | 4670 throw new core.ArgumentError("Parameter reportType is required."); |
4996 } | 4671 } |
4997 | 4672 |
4998 | 4673 |
4999 _url = 'metadata/' + common_internal.Escaper.ecapeVariable('$reportType') +
'/columns'; | 4674 _url = 'metadata/' + commons.Escaper.ecapeVariable('$reportType') + '/column
s'; |
5000 | 4675 |
5001 var _response = _requester.request(_url, | 4676 var _response = _requester.request(_url, |
5002 "GET", | 4677 "GET", |
5003 body: _body, | 4678 body: _body, |
5004 queryParams: _queryParams, | 4679 queryParams: _queryParams, |
5005 uploadOptions: _uploadOptions, | 4680 uploadOptions: _uploadOptions, |
5006 uploadMedia: _uploadMedia, | 4681 uploadMedia: _uploadMedia, |
5007 downloadOptions: _downloadOptions); | 4682 downloadOptions: _downloadOptions); |
5008 return _response.then((data) => new Columns.fromJson(data)); | 4683 return _response.then((data) => new Columns.fromJson(data)); |
5009 } | 4684 } |
5010 | 4685 |
5011 } | 4686 } |
5012 | 4687 |
5013 | 4688 |
5014 /** Not documented yet. */ | |
5015 class ProvisioningResourceApi { | 4689 class ProvisioningResourceApi { |
5016 final common_internal.ApiRequester _requester; | 4690 final commons.ApiRequester _requester; |
5017 | 4691 |
5018 ProvisioningResourceApi(common_internal.ApiRequester client) : | 4692 ProvisioningResourceApi(commons.ApiRequester client) : |
5019 _requester = client; | 4693 _requester = client; |
5020 | 4694 |
5021 /** | 4695 /** |
5022 * Creates an account ticket. | 4696 * Creates an account ticket. |
5023 * | 4697 * |
5024 * [request] - The metadata request object. | 4698 * [request] - The metadata request object. |
5025 * | 4699 * |
5026 * Request parameters: | 4700 * Request parameters: |
5027 * | 4701 * |
5028 * Completes with a [AccountTicket]. | 4702 * Completes with a [AccountTicket]. |
5029 * | 4703 * |
5030 * Completes with a [common.ApiRequestError] if the API endpoint returned an | 4704 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
5031 * error. | 4705 * error. |
5032 * | 4706 * |
5033 * If the used [http.Client] completes with an error when making a REST call, | 4707 * If the used [http.Client] completes with an error when making a REST call, |
5034 * this method will complete with the same error. | 4708 * this method will complete with the same error. |
5035 */ | 4709 */ |
5036 async.Future<AccountTicket> createAccountTicket(AccountTicket request) { | 4710 async.Future<AccountTicket> createAccountTicket(AccountTicket request) { |
5037 var _url = null; | 4711 var _url = null; |
5038 var _queryParams = new core.Map(); | 4712 var _queryParams = new core.Map(); |
5039 var _uploadMedia = null; | 4713 var _uploadMedia = null; |
5040 var _uploadOptions = null; | 4714 var _uploadOptions = null; |
5041 var _downloadOptions = common.DownloadOptions.Metadata; | 4715 var _downloadOptions = commons.DownloadOptions.Metadata; |
5042 var _body = null; | 4716 var _body = null; |
5043 | 4717 |
5044 if (request != null) { | 4718 if (request != null) { |
5045 _body = convert.JSON.encode((request).toJson()); | 4719 _body = convert.JSON.encode((request).toJson()); |
5046 } | 4720 } |
5047 | 4721 |
5048 | 4722 |
5049 _url = 'provisioning/createAccountTicket'; | 4723 _url = 'provisioning/createAccountTicket'; |
5050 | 4724 |
5051 var _response = _requester.request(_url, | 4725 var _response = _requester.request(_url, |
(...skipping 716 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
5768 _json["kind"] = kind; | 5442 _json["kind"] = kind; |
5769 } | 5443 } |
5770 if (totalResults != null) { | 5444 if (totalResults != null) { |
5771 _json["totalResults"] = totalResults; | 5445 _json["totalResults"] = totalResults; |
5772 } | 5446 } |
5773 return _json; | 5447 return _json; |
5774 } | 5448 } |
5775 } | 5449 } |
5776 | 5450 |
5777 | 5451 |
5778 /** Not documented yet. */ | |
5779 class CustomDataSourceChildLink { | 5452 class CustomDataSourceChildLink { |
5780 /** | 5453 /** |
5781 * Link to the list of daily uploads for this custom data source. Link to the | 5454 * Link to the list of daily uploads for this custom data source. Link to the |
5782 * list of uploads for this custom data source. | 5455 * list of uploads for this custom data source. |
5783 */ | 5456 */ |
5784 core.String href; | 5457 core.String href; |
5785 | 5458 |
5786 /** Value is "analytics#dailyUploads". Value is "analytics#uploads". */ | 5459 /** Value is "analytics#dailyUploads". Value is "analytics#uploads". */ |
5787 core.String type; | 5460 core.String type; |
5788 | 5461 |
(...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
5845 return _json; | 5518 return _json; |
5846 } | 5519 } |
5847 } | 5520 } |
5848 | 5521 |
5849 | 5522 |
5850 /** JSON template for an Analytics custom data source. */ | 5523 /** JSON template for an Analytics custom data source. */ |
5851 class CustomDataSource { | 5524 class CustomDataSource { |
5852 /** Account ID to which this custom data source belongs. */ | 5525 /** Account ID to which this custom data source belongs. */ |
5853 core.String accountId; | 5526 core.String accountId; |
5854 | 5527 |
5855 /** Not documented yet. */ | |
5856 CustomDataSourceChildLink childLink; | 5528 CustomDataSourceChildLink childLink; |
5857 | 5529 |
5858 /** Time this custom data source was created. */ | 5530 /** Time this custom data source was created. */ |
5859 core.DateTime created; | 5531 core.DateTime created; |
5860 | 5532 |
5861 /** Description of custom data source. */ | 5533 /** Description of custom data source. */ |
5862 core.String description; | 5534 core.String description; |
5863 | 5535 |
5864 /** Custom data source ID. */ | 5536 /** Custom data source ID. */ |
5865 core.String id; | 5537 core.String id; |
5866 | 5538 |
5867 /** Not documented yet. */ | |
5868 core.String importBehavior; | 5539 core.String importBehavior; |
5869 | 5540 |
5870 /** Resource type for Analytics custom data source. */ | 5541 /** Resource type for Analytics custom data source. */ |
5871 core.String kind; | 5542 core.String kind; |
5872 | 5543 |
5873 /** Name of this custom data source. */ | 5544 /** Name of this custom data source. */ |
5874 core.String name; | 5545 core.String name; |
5875 | 5546 |
5876 /** | 5547 /** |
5877 * Parent link for this custom data source. Points to the web property to | 5548 * Parent link for this custom data source. Points to the web property to |
5878 * which this custom data source belongs. | 5549 * which this custom data source belongs. |
5879 */ | 5550 */ |
5880 CustomDataSourceParentLink parentLink; | 5551 CustomDataSourceParentLink parentLink; |
5881 | 5552 |
5882 /** IDs of views (profiles) linked to the custom data source. */ | 5553 /** IDs of views (profiles) linked to the custom data source. */ |
5883 core.List<core.String> profilesLinked; | 5554 core.List<core.String> profilesLinked; |
5884 | 5555 |
5885 /** Link for this Analytics custom data source. */ | 5556 /** Link for this Analytics custom data source. */ |
5886 core.String selfLink; | 5557 core.String selfLink; |
5887 | 5558 |
5888 /** Type of the custom data source. */ | 5559 /** Type of the custom data source. */ |
5889 core.String type; | 5560 core.String type; |
5890 | 5561 |
5891 /** Time this custom data source was last modified. */ | 5562 /** Time this custom data source was last modified. */ |
5892 core.DateTime updated; | 5563 core.DateTime updated; |
5893 | 5564 |
5894 /** Not documented yet. */ | |
5895 core.String uploadType; | 5565 core.String uploadType; |
5896 | 5566 |
5897 /** | 5567 /** |
5898 * Web property ID of the form UA-XXXXX-YY to which this custom data source | 5568 * Web property ID of the form UA-XXXXX-YY to which this custom data source |
5899 * belongs. | 5569 * belongs. |
5900 */ | 5570 */ |
5901 core.String webPropertyId; | 5571 core.String webPropertyId; |
5902 | 5572 |
5903 | 5573 |
5904 CustomDataSource(); | 5574 CustomDataSource(); |
(...skipping 754 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
6659 _json["totalResults"] = totalResults; | 6329 _json["totalResults"] = totalResults; |
6660 } | 6330 } |
6661 if (username != null) { | 6331 if (username != null) { |
6662 _json["username"] = username; | 6332 _json["username"] = username; |
6663 } | 6333 } |
6664 return _json; | 6334 return _json; |
6665 } | 6335 } |
6666 } | 6336 } |
6667 | 6337 |
6668 | 6338 |
6669 /** | |
6670 * Parent link for a daily upload. Points to the custom data source to which | |
6671 * this daily upload belongs. | |
6672 */ | |
6673 class DailyUploadParentLink { | |
6674 /** Link to the custom data source to which this daily upload belongs. */ | |
6675 core.String href; | |
6676 | |
6677 /** Value is "analytics#customDataSource". */ | |
6678 core.String type; | |
6679 | |
6680 | |
6681 DailyUploadParentLink(); | |
6682 | |
6683 DailyUploadParentLink.fromJson(core.Map _json) { | |
6684 if (_json.containsKey("href")) { | |
6685 href = _json["href"]; | |
6686 } | |
6687 if (_json.containsKey("type")) { | |
6688 type = _json["type"]; | |
6689 } | |
6690 } | |
6691 | |
6692 core.Map toJson() { | |
6693 var _json = new core.Map(); | |
6694 if (href != null) { | |
6695 _json["href"] = href; | |
6696 } | |
6697 if (type != null) { | |
6698 _json["type"] = type; | |
6699 } | |
6700 return _json; | |
6701 } | |
6702 } | |
6703 | |
6704 | |
6705 /** Not documented yet. */ | |
6706 class DailyUploadRecentChanges { | |
6707 /** The type of change: APPEND, RESET, or DELETE. */ | |
6708 core.String change; | |
6709 | |
6710 /** The time when the change occurred. */ | |
6711 core.DateTime time; | |
6712 | |
6713 | |
6714 DailyUploadRecentChanges(); | |
6715 | |
6716 DailyUploadRecentChanges.fromJson(core.Map _json) { | |
6717 if (_json.containsKey("change")) { | |
6718 change = _json["change"]; | |
6719 } | |
6720 if (_json.containsKey("time")) { | |
6721 time = core.DateTime.parse(_json["time"]); | |
6722 } | |
6723 } | |
6724 | |
6725 core.Map toJson() { | |
6726 var _json = new core.Map(); | |
6727 if (change != null) { | |
6728 _json["change"] = change; | |
6729 } | |
6730 if (time != null) { | |
6731 _json["time"] = (time).toIso8601String(); | |
6732 } | |
6733 return _json; | |
6734 } | |
6735 } | |
6736 | |
6737 | |
6738 /** Metadata for daily upload entity. */ | |
6739 class DailyUpload { | |
6740 /** Account ID to which this daily upload belongs. */ | |
6741 core.String accountId; | |
6742 | |
6743 /** Number of appends for this date. */ | |
6744 core.int appendCount; | |
6745 | |
6746 /** Time this daily upload was created. */ | |
6747 core.DateTime createdTime; | |
6748 | |
6749 /** Custom data source ID to which this daily upload belongs. */ | |
6750 core.String customDataSourceId; | |
6751 | |
6752 /** Date associated with daily upload. */ | |
6753 core.String date; | |
6754 | |
6755 /** Resource type for Analytics daily upload. */ | |
6756 core.String kind; | |
6757 | |
6758 /** Time this daily upload was last modified. */ | |
6759 core.DateTime modifiedTime; | |
6760 | |
6761 /** | |
6762 * Parent link for a daily upload. Points to the custom data source to which | |
6763 * this daily upload belongs. | |
6764 */ | |
6765 DailyUploadParentLink parentLink; | |
6766 | |
6767 /** Change log for last 10 changes in chronological order. */ | |
6768 core.List<DailyUploadRecentChanges> recentChanges; | |
6769 | |
6770 /** Link for this daily upload. */ | |
6771 core.String selfLink; | |
6772 | |
6773 /** | |
6774 * Web property ID of the form UA-XXXXX-YY to which this daily upload belongs. | |
6775 */ | |
6776 core.String webPropertyId; | |
6777 | |
6778 | |
6779 DailyUpload(); | |
6780 | |
6781 DailyUpload.fromJson(core.Map _json) { | |
6782 if (_json.containsKey("accountId")) { | |
6783 accountId = _json["accountId"]; | |
6784 } | |
6785 if (_json.containsKey("appendCount")) { | |
6786 appendCount = _json["appendCount"]; | |
6787 } | |
6788 if (_json.containsKey("createdTime")) { | |
6789 createdTime = core.DateTime.parse(_json["createdTime"]); | |
6790 } | |
6791 if (_json.containsKey("customDataSourceId")) { | |
6792 customDataSourceId = _json["customDataSourceId"]; | |
6793 } | |
6794 if (_json.containsKey("date")) { | |
6795 date = _json["date"]; | |
6796 } | |
6797 if (_json.containsKey("kind")) { | |
6798 kind = _json["kind"]; | |
6799 } | |
6800 if (_json.containsKey("modifiedTime")) { | |
6801 modifiedTime = core.DateTime.parse(_json["modifiedTime"]); | |
6802 } | |
6803 if (_json.containsKey("parentLink")) { | |
6804 parentLink = new DailyUploadParentLink.fromJson(_json["parentLink"]); | |
6805 } | |
6806 if (_json.containsKey("recentChanges")) { | |
6807 recentChanges = _json["recentChanges"].map((value) => new DailyUploadRecen
tChanges.fromJson(value)).toList(); | |
6808 } | |
6809 if (_json.containsKey("selfLink")) { | |
6810 selfLink = _json["selfLink"]; | |
6811 } | |
6812 if (_json.containsKey("webPropertyId")) { | |
6813 webPropertyId = _json["webPropertyId"]; | |
6814 } | |
6815 } | |
6816 | |
6817 core.Map toJson() { | |
6818 var _json = new core.Map(); | |
6819 if (accountId != null) { | |
6820 _json["accountId"] = accountId; | |
6821 } | |
6822 if (appendCount != null) { | |
6823 _json["appendCount"] = appendCount; | |
6824 } | |
6825 if (createdTime != null) { | |
6826 _json["createdTime"] = (createdTime).toIso8601String(); | |
6827 } | |
6828 if (customDataSourceId != null) { | |
6829 _json["customDataSourceId"] = customDataSourceId; | |
6830 } | |
6831 if (date != null) { | |
6832 _json["date"] = date; | |
6833 } | |
6834 if (kind != null) { | |
6835 _json["kind"] = kind; | |
6836 } | |
6837 if (modifiedTime != null) { | |
6838 _json["modifiedTime"] = (modifiedTime).toIso8601String(); | |
6839 } | |
6840 if (parentLink != null) { | |
6841 _json["parentLink"] = (parentLink).toJson(); | |
6842 } | |
6843 if (recentChanges != null) { | |
6844 _json["recentChanges"] = recentChanges.map((value) => (value).toJson()).to
List(); | |
6845 } | |
6846 if (selfLink != null) { | |
6847 _json["selfLink"] = selfLink; | |
6848 } | |
6849 if (webPropertyId != null) { | |
6850 _json["webPropertyId"] = webPropertyId; | |
6851 } | |
6852 return _json; | |
6853 } | |
6854 } | |
6855 | |
6856 | |
6857 /** Metadata returned for a successful append operation. */ | |
6858 class DailyUploadAppend { | |
6859 /** Account Id to which this daily upload append belongs. */ | |
6860 core.String accountId; | |
6861 | |
6862 /** Append number. */ | |
6863 core.int appendNumber; | |
6864 | |
6865 /** Custom data source Id to which this daily upload append belongs. */ | |
6866 core.String customDataSourceId; | |
6867 | |
6868 /** Date associated with daily upload append. */ | |
6869 core.String date; | |
6870 | |
6871 /** Resource type for Analytics daily upload append. */ | |
6872 core.String kind; | |
6873 | |
6874 /** Not documented yet. */ | |
6875 core.String nextAppendLink; | |
6876 | |
6877 /** | |
6878 * Web property Id of the form UA-XXXXX-YY to which this daily upload append | |
6879 * belongs. | |
6880 */ | |
6881 core.String webPropertyId; | |
6882 | |
6883 | |
6884 DailyUploadAppend(); | |
6885 | |
6886 DailyUploadAppend.fromJson(core.Map _json) { | |
6887 if (_json.containsKey("accountId")) { | |
6888 accountId = _json["accountId"]; | |
6889 } | |
6890 if (_json.containsKey("appendNumber")) { | |
6891 appendNumber = _json["appendNumber"]; | |
6892 } | |
6893 if (_json.containsKey("customDataSourceId")) { | |
6894 customDataSourceId = _json["customDataSourceId"]; | |
6895 } | |
6896 if (_json.containsKey("date")) { | |
6897 date = _json["date"]; | |
6898 } | |
6899 if (_json.containsKey("kind")) { | |
6900 kind = _json["kind"]; | |
6901 } | |
6902 if (_json.containsKey("nextAppendLink")) { | |
6903 nextAppendLink = _json["nextAppendLink"]; | |
6904 } | |
6905 if (_json.containsKey("webPropertyId")) { | |
6906 webPropertyId = _json["webPropertyId"]; | |
6907 } | |
6908 } | |
6909 | |
6910 core.Map toJson() { | |
6911 var _json = new core.Map(); | |
6912 if (accountId != null) { | |
6913 _json["accountId"] = accountId; | |
6914 } | |
6915 if (appendNumber != null) { | |
6916 _json["appendNumber"] = appendNumber; | |
6917 } | |
6918 if (customDataSourceId != null) { | |
6919 _json["customDataSourceId"] = customDataSourceId; | |
6920 } | |
6921 if (date != null) { | |
6922 _json["date"] = date; | |
6923 } | |
6924 if (kind != null) { | |
6925 _json["kind"] = kind; | |
6926 } | |
6927 if (nextAppendLink != null) { | |
6928 _json["nextAppendLink"] = nextAppendLink; | |
6929 } | |
6930 if (webPropertyId != null) { | |
6931 _json["webPropertyId"] = webPropertyId; | |
6932 } | |
6933 return _json; | |
6934 } | |
6935 } | |
6936 | |
6937 | |
6938 /** | |
6939 * A daily upload collection lists Analytics daily uploads to which the user has | |
6940 * access. Each resource in the collection corresponds to a single Analytics | |
6941 * daily upload. | |
6942 */ | |
6943 class DailyUploads { | |
6944 /** A collection of daily uploads. */ | |
6945 core.List<DailyUpload> items; | |
6946 | |
6947 /** | |
6948 * The maximum number of resources the response can contain, regardless of the | |
6949 * actual number of resources returned. Its value ranges from 1 to 1000 with a | |
6950 * value of 1000 by default, or otherwise specified by the max-results query | |
6951 * parameter. | |
6952 */ | |
6953 core.int itemsPerPage; | |
6954 | |
6955 /** Collection type. Value is analytics#dailyUploads. */ | |
6956 core.String kind; | |
6957 | |
6958 /** Link to next page for this daily upload collection. */ | |
6959 core.String nextLink; | |
6960 | |
6961 /** Link to previous page for this daily upload collection. */ | |
6962 core.String previousLink; | |
6963 | |
6964 /** | |
6965 * The starting index of the resources, which is 1 by default or otherwise | |
6966 * specified by the start-index query parameter. | |
6967 */ | |
6968 core.int startIndex; | |
6969 | |
6970 /** | |
6971 * The total number of results for the query, regardless of the number of | |
6972 * results in the response. | |
6973 */ | |
6974 core.int totalResults; | |
6975 | |
6976 /** Email ID of the authenticated user */ | |
6977 core.String username; | |
6978 | |
6979 | |
6980 DailyUploads(); | |
6981 | |
6982 DailyUploads.fromJson(core.Map _json) { | |
6983 if (_json.containsKey("items")) { | |
6984 items = _json["items"].map((value) => new DailyUpload.fromJson(value)).toL
ist(); | |
6985 } | |
6986 if (_json.containsKey("itemsPerPage")) { | |
6987 itemsPerPage = _json["itemsPerPage"]; | |
6988 } | |
6989 if (_json.containsKey("kind")) { | |
6990 kind = _json["kind"]; | |
6991 } | |
6992 if (_json.containsKey("nextLink")) { | |
6993 nextLink = _json["nextLink"]; | |
6994 } | |
6995 if (_json.containsKey("previousLink")) { | |
6996 previousLink = _json["previousLink"]; | |
6997 } | |
6998 if (_json.containsKey("startIndex")) { | |
6999 startIndex = _json["startIndex"]; | |
7000 } | |
7001 if (_json.containsKey("totalResults")) { | |
7002 totalResults = _json["totalResults"]; | |
7003 } | |
7004 if (_json.containsKey("username")) { | |
7005 username = _json["username"]; | |
7006 } | |
7007 } | |
7008 | |
7009 core.Map toJson() { | |
7010 var _json = new core.Map(); | |
7011 if (items != null) { | |
7012 _json["items"] = items.map((value) => (value).toJson()).toList(); | |
7013 } | |
7014 if (itemsPerPage != null) { | |
7015 _json["itemsPerPage"] = itemsPerPage; | |
7016 } | |
7017 if (kind != null) { | |
7018 _json["kind"] = kind; | |
7019 } | |
7020 if (nextLink != null) { | |
7021 _json["nextLink"] = nextLink; | |
7022 } | |
7023 if (previousLink != null) { | |
7024 _json["previousLink"] = previousLink; | |
7025 } | |
7026 if (startIndex != null) { | |
7027 _json["startIndex"] = startIndex; | |
7028 } | |
7029 if (totalResults != null) { | |
7030 _json["totalResults"] = totalResults; | |
7031 } | |
7032 if (username != null) { | |
7033 _json["username"] = username; | |
7034 } | |
7035 return _json; | |
7036 } | |
7037 } | |
7038 | |
7039 | |
7040 /** Web property being linked. */ | 6339 /** Web property being linked. */ |
7041 class EntityAdWordsLinkEntity { | 6340 class EntityAdWordsLinkEntity { |
7042 /** Not documented yet. */ | |
7043 WebPropertyRef webPropertyRef; | 6341 WebPropertyRef webPropertyRef; |
7044 | 6342 |
7045 | 6343 |
7046 EntityAdWordsLinkEntity(); | 6344 EntityAdWordsLinkEntity(); |
7047 | 6345 |
7048 EntityAdWordsLinkEntity.fromJson(core.Map _json) { | 6346 EntityAdWordsLinkEntity.fromJson(core.Map _json) { |
7049 if (_json.containsKey("webPropertyRef")) { | 6347 if (_json.containsKey("webPropertyRef")) { |
7050 webPropertyRef = new WebPropertyRef.fromJson(_json["webPropertyRef"]); | 6348 webPropertyRef = new WebPropertyRef.fromJson(_json["webPropertyRef"]); |
7051 } | 6349 } |
7052 } | 6350 } |
(...skipping 469 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
7522 _json["href"] = href; | 6820 _json["href"] = href; |
7523 } | 6821 } |
7524 if (type != null) { | 6822 if (type != null) { |
7525 _json["type"] = type; | 6823 _json["type"] = type; |
7526 } | 6824 } |
7527 return _json; | 6825 return _json; |
7528 } | 6826 } |
7529 } | 6827 } |
7530 | 6828 |
7531 | 6829 |
7532 /** Not documented yet. */ | |
7533 class ExperimentVariations { | 6830 class ExperimentVariations { |
7534 /** | 6831 /** |
7535 * The name of the variation. This field is required when creating an | 6832 * The name of the variation. This field is required when creating an |
7536 * experiment. This field may not be changed for an experiment whose status is | 6833 * experiment. This field may not be changed for an experiment whose status is |
7537 * ENDED. | 6834 * ENDED. |
7538 */ | 6835 */ |
7539 core.String name; | 6836 core.String name; |
7540 | 6837 |
7541 /** | 6838 /** |
7542 * Status of the variation. Possible values: "ACTIVE", "INACTIVE". INACTIVE | 6839 * Status of the variation. Possible values: "ACTIVE", "INACTIVE". INACTIVE |
(...skipping 1232 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
8775 _json["totalResults"] = totalResults; | 8072 _json["totalResults"] = totalResults; |
8776 } | 8073 } |
8777 if (username != null) { | 8074 if (username != null) { |
8778 _json["username"] = username; | 8075 _json["username"] = username; |
8779 } | 8076 } |
8780 return _json; | 8077 return _json; |
8781 } | 8078 } |
8782 } | 8079 } |
8783 | 8080 |
8784 | 8081 |
8785 /** Not documented yet. */ | |
8786 class GaDataColumnHeaders { | 8082 class GaDataColumnHeaders { |
8787 /** Column Type. Either DIMENSION or METRIC. */ | 8083 /** Column Type. Either DIMENSION or METRIC. */ |
8788 core.String columnType; | 8084 core.String columnType; |
8789 | 8085 |
8790 /** | 8086 /** |
8791 * Data type. Dimension column headers have only STRING as the data type. | 8087 * Data type. Dimension column headers have only STRING as the data type. |
8792 * Metric column headers have data types for metric values such as INTEGER, | 8088 * Metric column headers have data types for metric values such as INTEGER, |
8793 * DOUBLE, CURRENCY etc. | 8089 * DOUBLE, CURRENCY etc. |
8794 */ | 8090 */ |
8795 core.String dataType; | 8091 core.String dataType; |
(...skipping 25 matching lines...) Expand all Loading... |
8821 _json["dataType"] = dataType; | 8117 _json["dataType"] = dataType; |
8822 } | 8118 } |
8823 if (name != null) { | 8119 if (name != null) { |
8824 _json["name"] = name; | 8120 _json["name"] = name; |
8825 } | 8121 } |
8826 return _json; | 8122 return _json; |
8827 } | 8123 } |
8828 } | 8124 } |
8829 | 8125 |
8830 | 8126 |
8831 /** Not documented yet. */ | |
8832 class GaDataDataTableCols { | 8127 class GaDataDataTableCols { |
8833 /** Not documented yet. */ | |
8834 core.String id; | 8128 core.String id; |
8835 | 8129 |
8836 /** Not documented yet. */ | |
8837 core.String label; | 8130 core.String label; |
8838 | 8131 |
8839 /** Not documented yet. */ | |
8840 core.String type; | 8132 core.String type; |
8841 | 8133 |
8842 | 8134 |
8843 GaDataDataTableCols(); | 8135 GaDataDataTableCols(); |
8844 | 8136 |
8845 GaDataDataTableCols.fromJson(core.Map _json) { | 8137 GaDataDataTableCols.fromJson(core.Map _json) { |
8846 if (_json.containsKey("id")) { | 8138 if (_json.containsKey("id")) { |
8847 id = _json["id"]; | 8139 id = _json["id"]; |
8848 } | 8140 } |
8849 if (_json.containsKey("label")) { | 8141 if (_json.containsKey("label")) { |
(...skipping 13 matching lines...) Expand all Loading... |
8863 _json["label"] = label; | 8155 _json["label"] = label; |
8864 } | 8156 } |
8865 if (type != null) { | 8157 if (type != null) { |
8866 _json["type"] = type; | 8158 _json["type"] = type; |
8867 } | 8159 } |
8868 return _json; | 8160 return _json; |
8869 } | 8161 } |
8870 } | 8162 } |
8871 | 8163 |
8872 | 8164 |
8873 /** Not documented yet. */ | |
8874 class GaDataDataTableRowsC { | 8165 class GaDataDataTableRowsC { |
8875 /** Not documented yet. */ | |
8876 core.String v; | 8166 core.String v; |
8877 | 8167 |
8878 | 8168 |
8879 GaDataDataTableRowsC(); | 8169 GaDataDataTableRowsC(); |
8880 | 8170 |
8881 GaDataDataTableRowsC.fromJson(core.Map _json) { | 8171 GaDataDataTableRowsC.fromJson(core.Map _json) { |
8882 if (_json.containsKey("v")) { | 8172 if (_json.containsKey("v")) { |
8883 v = _json["v"]; | 8173 v = _json["v"]; |
8884 } | 8174 } |
8885 } | 8175 } |
8886 | 8176 |
8887 core.Map toJson() { | 8177 core.Map toJson() { |
8888 var _json = new core.Map(); | 8178 var _json = new core.Map(); |
8889 if (v != null) { | 8179 if (v != null) { |
8890 _json["v"] = v; | 8180 _json["v"] = v; |
8891 } | 8181 } |
8892 return _json; | 8182 return _json; |
8893 } | 8183 } |
8894 } | 8184 } |
8895 | 8185 |
8896 | 8186 |
8897 /** Not documented yet. */ | |
8898 class GaDataDataTableRows { | 8187 class GaDataDataTableRows { |
8899 /** Not documented yet. */ | |
8900 core.List<GaDataDataTableRowsC> c; | 8188 core.List<GaDataDataTableRowsC> c; |
8901 | 8189 |
8902 | 8190 |
8903 GaDataDataTableRows(); | 8191 GaDataDataTableRows(); |
8904 | 8192 |
8905 GaDataDataTableRows.fromJson(core.Map _json) { | 8193 GaDataDataTableRows.fromJson(core.Map _json) { |
8906 if (_json.containsKey("c")) { | 8194 if (_json.containsKey("c")) { |
8907 c = _json["c"].map((value) => new GaDataDataTableRowsC.fromJson(value)).to
List(); | 8195 c = _json["c"].map((value) => new GaDataDataTableRowsC.fromJson(value)).to
List(); |
8908 } | 8196 } |
8909 } | 8197 } |
8910 | 8198 |
8911 core.Map toJson() { | 8199 core.Map toJson() { |
8912 var _json = new core.Map(); | 8200 var _json = new core.Map(); |
8913 if (c != null) { | 8201 if (c != null) { |
8914 _json["c"] = c.map((value) => (value).toJson()).toList(); | 8202 _json["c"] = c.map((value) => (value).toJson()).toList(); |
8915 } | 8203 } |
8916 return _json; | 8204 return _json; |
8917 } | 8205 } |
8918 } | 8206 } |
8919 | 8207 |
8920 | 8208 |
8921 /** Not documented yet. */ | |
8922 class GaDataDataTable { | 8209 class GaDataDataTable { |
8923 /** Not documented yet. */ | |
8924 core.List<GaDataDataTableCols> cols; | 8210 core.List<GaDataDataTableCols> cols; |
8925 | 8211 |
8926 /** Not documented yet. */ | |
8927 core.List<GaDataDataTableRows> rows; | 8212 core.List<GaDataDataTableRows> rows; |
8928 | 8213 |
8929 | 8214 |
8930 GaDataDataTable(); | 8215 GaDataDataTable(); |
8931 | 8216 |
8932 GaDataDataTable.fromJson(core.Map _json) { | 8217 GaDataDataTable.fromJson(core.Map _json) { |
8933 if (_json.containsKey("cols")) { | 8218 if (_json.containsKey("cols")) { |
8934 cols = _json["cols"].map((value) => new GaDataDataTableCols.fromJson(value
)).toList(); | 8219 cols = _json["cols"].map((value) => new GaDataDataTableCols.fromJson(value
)).toList(); |
8935 } | 8220 } |
8936 if (_json.containsKey("rows")) { | 8221 if (_json.containsKey("rows")) { |
(...skipping 204 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
9141 class GaData { | 8426 class GaData { |
9142 /** | 8427 /** |
9143 * Column headers that list dimension names followed by the metric names. The | 8428 * Column headers that list dimension names followed by the metric names. The |
9144 * order of dimensions and metrics is same as specified in the request. | 8429 * order of dimensions and metrics is same as specified in the request. |
9145 */ | 8430 */ |
9146 core.List<GaDataColumnHeaders> columnHeaders; | 8431 core.List<GaDataColumnHeaders> columnHeaders; |
9147 | 8432 |
9148 /** Determines if Analytics data contains samples. */ | 8433 /** Determines if Analytics data contains samples. */ |
9149 core.bool containsSampledData; | 8434 core.bool containsSampledData; |
9150 | 8435 |
9151 /** Not documented yet. */ | |
9152 GaDataDataTable dataTable; | 8436 GaDataDataTable dataTable; |
9153 | 8437 |
9154 /** Unique ID for this data response. */ | 8438 /** Unique ID for this data response. */ |
9155 core.String id; | 8439 core.String id; |
9156 | 8440 |
9157 /** | 8441 /** |
9158 * The maximum number of rows the response can contain, regardless of the | 8442 * The maximum number of rows the response can contain, regardless of the |
9159 * actual number of rows returned. Its value ranges from 1 to 10,000 with a | 8443 * actual number of rows returned. Its value ranges from 1 to 10,000 with a |
9160 * value of 1000 by default, or otherwise specified by the max-results query | 8444 * value of 1000 by default, or otherwise specified by the max-results query |
9161 * parameter. | 8445 * parameter. |
(...skipping 149 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
9311 _json["totalResults"] = totalResults; | 8595 _json["totalResults"] = totalResults; |
9312 } | 8596 } |
9313 if (totalsForAllResults != null) { | 8597 if (totalsForAllResults != null) { |
9314 _json["totalsForAllResults"] = totalsForAllResults; | 8598 _json["totalsForAllResults"] = totalsForAllResults; |
9315 } | 8599 } |
9316 return _json; | 8600 return _json; |
9317 } | 8601 } |
9318 } | 8602 } |
9319 | 8603 |
9320 | 8604 |
9321 /** Not documented yet. */ | |
9322 class GoalEventDetailsEventConditions { | 8605 class GoalEventDetailsEventConditions { |
9323 /** | 8606 /** |
9324 * Type of comparison. Possible values are LESS_THAN, GREATER_THAN or EQUAL. | 8607 * Type of comparison. Possible values are LESS_THAN, GREATER_THAN or EQUAL. |
9325 */ | 8608 */ |
9326 core.String comparisonType; | 8609 core.String comparisonType; |
9327 | 8610 |
9328 /** Value used for this comparison. */ | 8611 /** Value used for this comparison. */ |
9329 core.String comparisonValue; | 8612 core.String comparisonValue; |
9330 | 8613 |
9331 /** Expression used for this match. */ | 8614 /** Expression used for this match. */ |
(...skipping 118 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
9450 _json["href"] = href; | 8733 _json["href"] = href; |
9451 } | 8734 } |
9452 if (type != null) { | 8735 if (type != null) { |
9453 _json["type"] = type; | 8736 _json["type"] = type; |
9454 } | 8737 } |
9455 return _json; | 8738 return _json; |
9456 } | 8739 } |
9457 } | 8740 } |
9458 | 8741 |
9459 | 8742 |
9460 /** Not documented yet. */ | |
9461 class GoalUrlDestinationDetailsSteps { | 8743 class GoalUrlDestinationDetailsSteps { |
9462 /** Step name. */ | 8744 /** Step name. */ |
9463 core.String name; | 8745 core.String name; |
9464 | 8746 |
9465 /** Step number. */ | 8747 /** Step number. */ |
9466 core.int number; | 8748 core.int number; |
9467 | 8749 |
9468 /** URL for this step. */ | 8750 /** URL for this step. */ |
9469 core.String url; | 8751 core.String url; |
9470 | 8752 |
(...skipping 442 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
9913 _json["totalResults"] = totalResults; | 9195 _json["totalResults"] = totalResults; |
9914 } | 9196 } |
9915 if (username != null) { | 9197 if (username != null) { |
9916 _json["username"] = username; | 9198 _json["username"] = username; |
9917 } | 9199 } |
9918 return _json; | 9200 return _json; |
9919 } | 9201 } |
9920 } | 9202 } |
9921 | 9203 |
9922 | 9204 |
9923 /** Not documented yet. */ | |
9924 class McfDataColumnHeaders { | 9205 class McfDataColumnHeaders { |
9925 /** Column Type. Either DIMENSION or METRIC. */ | 9206 /** Column Type. Either DIMENSION or METRIC. */ |
9926 core.String columnType; | 9207 core.String columnType; |
9927 | 9208 |
9928 /** | 9209 /** |
9929 * Data type. Dimension and metric values data types such as INTEGER, DOUBLE, | 9210 * Data type. Dimension and metric values data types such as INTEGER, DOUBLE, |
9930 * CURRENCY, MCF_SEQUENCE etc. | 9211 * CURRENCY, MCF_SEQUENCE etc. |
9931 */ | 9212 */ |
9932 core.String dataType; | 9213 core.String dataType; |
9933 | 9214 |
(...skipping 210 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
10144 _json["start-date"] = start_date; | 9425 _json["start-date"] = start_date; |
10145 } | 9426 } |
10146 if (start_index != null) { | 9427 if (start_index != null) { |
10147 _json["start-index"] = start_index; | 9428 _json["start-index"] = start_index; |
10148 } | 9429 } |
10149 return _json; | 9430 return _json; |
10150 } | 9431 } |
10151 } | 9432 } |
10152 | 9433 |
10153 | 9434 |
10154 /** Not documented yet. */ | |
10155 class McfDataRowsConversionPathValue { | 9435 class McfDataRowsConversionPathValue { |
10156 /** | 9436 /** |
10157 * Type of an interaction on conversion path. Such as CLICK, IMPRESSION etc. | 9437 * Type of an interaction on conversion path. Such as CLICK, IMPRESSION etc. |
10158 */ | 9438 */ |
10159 core.String interactionType; | 9439 core.String interactionType; |
10160 | 9440 |
10161 /** | 9441 /** |
10162 * Node value of an interaction on conversion path. Such as source, medium | 9442 * Node value of an interaction on conversion path. Such as source, medium |
10163 * etc. | 9443 * etc. |
10164 */ | 9444 */ |
(...skipping 1009 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
11174 _json["totalResults"] = totalResults; | 10454 _json["totalResults"] = totalResults; |
11175 } | 10455 } |
11176 if (username != null) { | 10456 if (username != null) { |
11177 _json["username"] = username; | 10457 _json["username"] = username; |
11178 } | 10458 } |
11179 return _json; | 10459 return _json; |
11180 } | 10460 } |
11181 } | 10461 } |
11182 | 10462 |
11183 | 10463 |
11184 /** Not documented yet. */ | |
11185 class RealtimeDataColumnHeaders { | 10464 class RealtimeDataColumnHeaders { |
11186 /** Column Type. Either DIMENSION or METRIC. */ | 10465 /** Column Type. Either DIMENSION or METRIC. */ |
11187 core.String columnType; | 10466 core.String columnType; |
11188 | 10467 |
11189 /** | 10468 /** |
11190 * Data type. Dimension column headers have only STRING as the data type. | 10469 * Data type. Dimension column headers have only STRING as the data type. |
11191 * Metric column headers have data types for metric values such as INTEGER, | 10470 * Metric column headers have data types for metric values such as INTEGER, |
11192 * DOUBLE, CURRENCY etc. | 10471 * DOUBLE, CURRENCY etc. |
11193 */ | 10472 */ |
11194 core.String dataType; | 10473 core.String dataType; |
(...skipping 1003 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
12198 | 11477 |
12199 | 11478 |
12200 /** JSON template for a user reference. */ | 11479 /** JSON template for a user reference. */ |
12201 class UserRef { | 11480 class UserRef { |
12202 /** Email ID of this user. */ | 11481 /** Email ID of this user. */ |
12203 core.String email; | 11482 core.String email; |
12204 | 11483 |
12205 /** User ID. */ | 11484 /** User ID. */ |
12206 core.String id; | 11485 core.String id; |
12207 | 11486 |
12208 /** Not documented yet. */ | |
12209 core.String kind; | 11487 core.String kind; |
12210 | 11488 |
12211 | 11489 |
12212 UserRef(); | 11490 UserRef(); |
12213 | 11491 |
12214 UserRef.fromJson(core.Map _json) { | 11492 UserRef.fromJson(core.Map _json) { |
12215 if (_json.containsKey("email")) { | 11493 if (_json.containsKey("email")) { |
12216 email = _json["email"]; | 11494 email = _json["email"]; |
12217 } | 11495 } |
12218 if (_json.containsKey("id")) { | 11496 if (_json.containsKey("id")) { |
(...skipping 528 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
12747 } | 12025 } |
12748 if (updated != null) { | 12026 if (updated != null) { |
12749 _json["updated"] = (updated).toIso8601String(); | 12027 _json["updated"] = (updated).toIso8601String(); |
12750 } | 12028 } |
12751 if (websiteUrl != null) { | 12029 if (websiteUrl != null) { |
12752 _json["websiteUrl"] = websiteUrl; | 12030 _json["websiteUrl"] = websiteUrl; |
12753 } | 12031 } |
12754 return _json; | 12032 return _json; |
12755 } | 12033 } |
12756 } | 12034 } |
12757 | |
12758 | |
OLD | NEW |