OLD | NEW |
(Empty) | |
| 1 library googleapis.tagmanager.v1; |
| 2 |
| 3 import "dart:core" as core; |
| 4 import "dart:collection" as collection; |
| 5 import "dart:async" as async; |
| 6 import "dart:convert" as convert; |
| 7 |
| 8 import "package:crypto/crypto.dart" as crypto; |
| 9 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 export '../common/common.dart' show ApiRequestError; |
| 14 export '../common/common.dart' show DetailedApiRequestError; |
| 15 |
| 16 /** API for accessing Tag Manager accounts and containers. */ |
| 17 class TagmanagerApi { |
| 18 /** Delete your Google Tag Manager containers */ |
| 19 static const TagmanagerDeleteContainersScope = "https://www.googleapis.com/aut
h/tagmanager.delete.containers"; |
| 20 |
| 21 /** Manage your Google Tag Manager containers */ |
| 22 static const TagmanagerEditContainersScope = "https://www.googleapis.com/auth/
tagmanager.edit.containers"; |
| 23 |
| 24 /** Manage your Google Tag Manager container versions */ |
| 25 static const TagmanagerEditContainerversionsScope = "https://www.googleapis.co
m/auth/tagmanager.edit.containerversions"; |
| 26 |
| 27 /** Manage your Google Tag Manager accounts */ |
| 28 static const TagmanagerManageAccountsScope = "https://www.googleapis.com/auth/
tagmanager.manage.accounts"; |
| 29 |
| 30 /** Manage user permissions of your Google Tag Manager data */ |
| 31 static const TagmanagerManageUsersScope = "https://www.googleapis.com/auth/tag
manager.manage.users"; |
| 32 |
| 33 /** Publish your Google Tag Manager containers */ |
| 34 static const TagmanagerPublishScope = "https://www.googleapis.com/auth/tagmana
ger.publish"; |
| 35 |
| 36 /** View your Google Tag Manager containers */ |
| 37 static const TagmanagerReadonlyScope = "https://www.googleapis.com/auth/tagman
ager.readonly"; |
| 38 |
| 39 |
| 40 final common_internal.ApiRequester _requester; |
| 41 |
| 42 AccountsResourceApi get accounts => new AccountsResourceApi(_requester); |
| 43 |
| 44 TagmanagerApi(http.Client client) : |
| 45 _requester = new common_internal.ApiRequester(client, "https://www.googlea
pis.com/", "tagmanager/v1/"); |
| 46 } |
| 47 |
| 48 |
| 49 /** Not documented yet. */ |
| 50 class AccountsResourceApi { |
| 51 final common_internal.ApiRequester _requester; |
| 52 |
| 53 AccountsContainersResourceApi get containers => new AccountsContainersResource
Api(_requester); |
| 54 AccountsPermissionsResourceApi get permissions => new AccountsPermissionsResou
rceApi(_requester); |
| 55 |
| 56 AccountsResourceApi(common_internal.ApiRequester client) : |
| 57 _requester = client; |
| 58 |
| 59 /** |
| 60 * Gets a GTM Account. |
| 61 * |
| 62 * Request parameters: |
| 63 * |
| 64 * [accountId] - The GTM Account ID. |
| 65 * |
| 66 * Completes with a [Account]. |
| 67 * |
| 68 * Completes with a [common.ApiRequestError] if the API endpoint returned an |
| 69 * error. |
| 70 * |
| 71 * If the used [http.Client] completes with an error when making a REST call, |
| 72 * this method will complete with the same error. |
| 73 */ |
| 74 async.Future<Account> get(core.String accountId) { |
| 75 var _url = null; |
| 76 var _queryParams = new core.Map(); |
| 77 var _uploadMedia = null; |
| 78 var _uploadOptions = null; |
| 79 var _downloadOptions = common.DownloadOptions.Metadata; |
| 80 var _body = null; |
| 81 |
| 82 if (accountId == null) { |
| 83 throw new core.ArgumentError("Parameter accountId is required."); |
| 84 } |
| 85 |
| 86 |
| 87 _url = 'accounts/' + common_internal.Escaper.ecapeVariable('$accountId'); |
| 88 |
| 89 var _response = _requester.request(_url, |
| 90 "GET", |
| 91 body: _body, |
| 92 queryParams: _queryParams, |
| 93 uploadOptions: _uploadOptions, |
| 94 uploadMedia: _uploadMedia, |
| 95 downloadOptions: _downloadOptions); |
| 96 return _response.then((data) => new Account.fromJson(data)); |
| 97 } |
| 98 |
| 99 /** |
| 100 * Lists all GTM Accounts that a user has access to. |
| 101 * |
| 102 * Request parameters: |
| 103 * |
| 104 * Completes with a [ListAccountsResponse]. |
| 105 * |
| 106 * Completes with a [common.ApiRequestError] if the API endpoint returned an |
| 107 * error. |
| 108 * |
| 109 * If the used [http.Client] completes with an error when making a REST call, |
| 110 * this method will complete with the same error. |
| 111 */ |
| 112 async.Future<ListAccountsResponse> list() { |
| 113 var _url = null; |
| 114 var _queryParams = new core.Map(); |
| 115 var _uploadMedia = null; |
| 116 var _uploadOptions = null; |
| 117 var _downloadOptions = common.DownloadOptions.Metadata; |
| 118 var _body = null; |
| 119 |
| 120 |
| 121 |
| 122 _url = 'accounts'; |
| 123 |
| 124 var _response = _requester.request(_url, |
| 125 "GET", |
| 126 body: _body, |
| 127 queryParams: _queryParams, |
| 128 uploadOptions: _uploadOptions, |
| 129 uploadMedia: _uploadMedia, |
| 130 downloadOptions: _downloadOptions); |
| 131 return _response.then((data) => new ListAccountsResponse.fromJson(data)); |
| 132 } |
| 133 |
| 134 /** |
| 135 * Updates a GTM Account. |
| 136 * |
| 137 * [request] - The metadata request object. |
| 138 * |
| 139 * Request parameters: |
| 140 * |
| 141 * [accountId] - The GTM Account ID. |
| 142 * |
| 143 * [fingerprint] - When provided, this fingerprint must match the fingerprint |
| 144 * of the account in storage. |
| 145 * |
| 146 * Completes with a [Account]. |
| 147 * |
| 148 * Completes with a [common.ApiRequestError] if the API endpoint returned an |
| 149 * error. |
| 150 * |
| 151 * If the used [http.Client] completes with an error when making a REST call, |
| 152 * this method will complete with the same error. |
| 153 */ |
| 154 async.Future<Account> update(Account request, core.String accountId, {core.Str
ing fingerprint}) { |
| 155 var _url = null; |
| 156 var _queryParams = new core.Map(); |
| 157 var _uploadMedia = null; |
| 158 var _uploadOptions = null; |
| 159 var _downloadOptions = common.DownloadOptions.Metadata; |
| 160 var _body = null; |
| 161 |
| 162 if (request != null) { |
| 163 _body = convert.JSON.encode((request).toJson()); |
| 164 } |
| 165 if (accountId == null) { |
| 166 throw new core.ArgumentError("Parameter accountId is required."); |
| 167 } |
| 168 if (fingerprint != null) { |
| 169 _queryParams["fingerprint"] = [fingerprint]; |
| 170 } |
| 171 |
| 172 |
| 173 _url = 'accounts/' + common_internal.Escaper.ecapeVariable('$accountId'); |
| 174 |
| 175 var _response = _requester.request(_url, |
| 176 "PUT", |
| 177 body: _body, |
| 178 queryParams: _queryParams, |
| 179 uploadOptions: _uploadOptions, |
| 180 uploadMedia: _uploadMedia, |
| 181 downloadOptions: _downloadOptions); |
| 182 return _response.then((data) => new Account.fromJson(data)); |
| 183 } |
| 184 |
| 185 } |
| 186 |
| 187 |
| 188 /** Not documented yet. */ |
| 189 class AccountsContainersResourceApi { |
| 190 final common_internal.ApiRequester _requester; |
| 191 |
| 192 AccountsContainersMacrosResourceApi get macros => new AccountsContainersMacros
ResourceApi(_requester); |
| 193 AccountsContainersRulesResourceApi get rules => new AccountsContainersRulesRes
ourceApi(_requester); |
| 194 AccountsContainersTagsResourceApi get tags => new AccountsContainersTagsResour
ceApi(_requester); |
| 195 AccountsContainersTriggersResourceApi get triggers => new AccountsContainersTr
iggersResourceApi(_requester); |
| 196 AccountsContainersVariablesResourceApi get variables => new AccountsContainers
VariablesResourceApi(_requester); |
| 197 AccountsContainersVersionsResourceApi get versions => new AccountsContainersVe
rsionsResourceApi(_requester); |
| 198 |
| 199 AccountsContainersResourceApi(common_internal.ApiRequester client) : |
| 200 _requester = client; |
| 201 |
| 202 /** |
| 203 * Creates a Container. |
| 204 * |
| 205 * [request] - The metadata request object. |
| 206 * |
| 207 * Request parameters: |
| 208 * |
| 209 * [accountId] - The GTM Account ID. |
| 210 * |
| 211 * Completes with a [Container]. |
| 212 * |
| 213 * Completes with a [common.ApiRequestError] if the API endpoint returned an |
| 214 * error. |
| 215 * |
| 216 * If the used [http.Client] completes with an error when making a REST call, |
| 217 * this method will complete with the same error. |
| 218 */ |
| 219 async.Future<Container> create(Container request, core.String accountId) { |
| 220 var _url = null; |
| 221 var _queryParams = new core.Map(); |
| 222 var _uploadMedia = null; |
| 223 var _uploadOptions = null; |
| 224 var _downloadOptions = common.DownloadOptions.Metadata; |
| 225 var _body = null; |
| 226 |
| 227 if (request != null) { |
| 228 _body = convert.JSON.encode((request).toJson()); |
| 229 } |
| 230 if (accountId == null) { |
| 231 throw new core.ArgumentError("Parameter accountId is required."); |
| 232 } |
| 233 |
| 234 |
| 235 _url = 'accounts/' + common_internal.Escaper.ecapeVariable('$accountId') + '
/containers'; |
| 236 |
| 237 var _response = _requester.request(_url, |
| 238 "POST", |
| 239 body: _body, |
| 240 queryParams: _queryParams, |
| 241 uploadOptions: _uploadOptions, |
| 242 uploadMedia: _uploadMedia, |
| 243 downloadOptions: _downloadOptions); |
| 244 return _response.then((data) => new Container.fromJson(data)); |
| 245 } |
| 246 |
| 247 /** |
| 248 * Deletes a Container. |
| 249 * |
| 250 * Request parameters: |
| 251 * |
| 252 * [accountId] - The GTM Account ID. |
| 253 * |
| 254 * [containerId] - The GTM Container ID. |
| 255 * |
| 256 * Completes with a [common.ApiRequestError] if the API endpoint returned an |
| 257 * error. |
| 258 * |
| 259 * If the used [http.Client] completes with an error when making a REST call, |
| 260 * this method will complete with the same error. |
| 261 */ |
| 262 async.Future delete(core.String accountId, core.String containerId) { |
| 263 var _url = null; |
| 264 var _queryParams = new core.Map(); |
| 265 var _uploadMedia = null; |
| 266 var _uploadOptions = null; |
| 267 var _downloadOptions = common.DownloadOptions.Metadata; |
| 268 var _body = null; |
| 269 |
| 270 if (accountId == null) { |
| 271 throw new core.ArgumentError("Parameter accountId is required."); |
| 272 } |
| 273 if (containerId == null) { |
| 274 throw new core.ArgumentError("Parameter containerId is required."); |
| 275 } |
| 276 |
| 277 _downloadOptions = null; |
| 278 |
| 279 _url = 'accounts/' + common_internal.Escaper.ecapeVariable('$accountId') + '
/containers/' + common_internal.Escaper.ecapeVariable('$containerId'); |
| 280 |
| 281 var _response = _requester.request(_url, |
| 282 "DELETE", |
| 283 body: _body, |
| 284 queryParams: _queryParams, |
| 285 uploadOptions: _uploadOptions, |
| 286 uploadMedia: _uploadMedia, |
| 287 downloadOptions: _downloadOptions); |
| 288 return _response.then((data) => null); |
| 289 } |
| 290 |
| 291 /** |
| 292 * Gets a Container. |
| 293 * |
| 294 * Request parameters: |
| 295 * |
| 296 * [accountId] - The GTM Account ID. |
| 297 * |
| 298 * [containerId] - The GTM Container ID. |
| 299 * |
| 300 * Completes with a [Container]. |
| 301 * |
| 302 * Completes with a [common.ApiRequestError] if the API endpoint returned an |
| 303 * error. |
| 304 * |
| 305 * If the used [http.Client] completes with an error when making a REST call, |
| 306 * this method will complete with the same error. |
| 307 */ |
| 308 async.Future<Container> get(core.String accountId, core.String containerId) { |
| 309 var _url = null; |
| 310 var _queryParams = new core.Map(); |
| 311 var _uploadMedia = null; |
| 312 var _uploadOptions = null; |
| 313 var _downloadOptions = common.DownloadOptions.Metadata; |
| 314 var _body = null; |
| 315 |
| 316 if (accountId == null) { |
| 317 throw new core.ArgumentError("Parameter accountId is required."); |
| 318 } |
| 319 if (containerId == null) { |
| 320 throw new core.ArgumentError("Parameter containerId is required."); |
| 321 } |
| 322 |
| 323 |
| 324 _url = 'accounts/' + common_internal.Escaper.ecapeVariable('$accountId') + '
/containers/' + common_internal.Escaper.ecapeVariable('$containerId'); |
| 325 |
| 326 var _response = _requester.request(_url, |
| 327 "GET", |
| 328 body: _body, |
| 329 queryParams: _queryParams, |
| 330 uploadOptions: _uploadOptions, |
| 331 uploadMedia: _uploadMedia, |
| 332 downloadOptions: _downloadOptions); |
| 333 return _response.then((data) => new Container.fromJson(data)); |
| 334 } |
| 335 |
| 336 /** |
| 337 * Lists all Containers that belongs to a GTM Account. |
| 338 * |
| 339 * Request parameters: |
| 340 * |
| 341 * [accountId] - The GTM Account ID. |
| 342 * |
| 343 * Completes with a [ListContainersResponse]. |
| 344 * |
| 345 * Completes with a [common.ApiRequestError] if the API endpoint returned an |
| 346 * error. |
| 347 * |
| 348 * If the used [http.Client] completes with an error when making a REST call, |
| 349 * this method will complete with the same error. |
| 350 */ |
| 351 async.Future<ListContainersResponse> list(core.String accountId) { |
| 352 var _url = null; |
| 353 var _queryParams = new core.Map(); |
| 354 var _uploadMedia = null; |
| 355 var _uploadOptions = null; |
| 356 var _downloadOptions = common.DownloadOptions.Metadata; |
| 357 var _body = null; |
| 358 |
| 359 if (accountId == null) { |
| 360 throw new core.ArgumentError("Parameter accountId is required."); |
| 361 } |
| 362 |
| 363 |
| 364 _url = 'accounts/' + common_internal.Escaper.ecapeVariable('$accountId') + '
/containers'; |
| 365 |
| 366 var _response = _requester.request(_url, |
| 367 "GET", |
| 368 body: _body, |
| 369 queryParams: _queryParams, |
| 370 uploadOptions: _uploadOptions, |
| 371 uploadMedia: _uploadMedia, |
| 372 downloadOptions: _downloadOptions); |
| 373 return _response.then((data) => new ListContainersResponse.fromJson(data)); |
| 374 } |
| 375 |
| 376 /** |
| 377 * Updates a Container. |
| 378 * |
| 379 * [request] - The metadata request object. |
| 380 * |
| 381 * Request parameters: |
| 382 * |
| 383 * [accountId] - The GTM Account ID. |
| 384 * |
| 385 * [containerId] - The GTM Container ID. |
| 386 * |
| 387 * [fingerprint] - When provided, this fingerprint must match the fingerprint |
| 388 * of the container in storage. |
| 389 * |
| 390 * Completes with a [Container]. |
| 391 * |
| 392 * Completes with a [common.ApiRequestError] if the API endpoint returned an |
| 393 * error. |
| 394 * |
| 395 * If the used [http.Client] completes with an error when making a REST call, |
| 396 * this method will complete with the same error. |
| 397 */ |
| 398 async.Future<Container> update(Container request, core.String accountId, core.
String containerId, {core.String fingerprint}) { |
| 399 var _url = null; |
| 400 var _queryParams = new core.Map(); |
| 401 var _uploadMedia = null; |
| 402 var _uploadOptions = null; |
| 403 var _downloadOptions = common.DownloadOptions.Metadata; |
| 404 var _body = null; |
| 405 |
| 406 if (request != null) { |
| 407 _body = convert.JSON.encode((request).toJson()); |
| 408 } |
| 409 if (accountId == null) { |
| 410 throw new core.ArgumentError("Parameter accountId is required."); |
| 411 } |
| 412 if (containerId == null) { |
| 413 throw new core.ArgumentError("Parameter containerId is required."); |
| 414 } |
| 415 if (fingerprint != null) { |
| 416 _queryParams["fingerprint"] = [fingerprint]; |
| 417 } |
| 418 |
| 419 |
| 420 _url = 'accounts/' + common_internal.Escaper.ecapeVariable('$accountId') + '
/containers/' + common_internal.Escaper.ecapeVariable('$containerId'); |
| 421 |
| 422 var _response = _requester.request(_url, |
| 423 "PUT", |
| 424 body: _body, |
| 425 queryParams: _queryParams, |
| 426 uploadOptions: _uploadOptions, |
| 427 uploadMedia: _uploadMedia, |
| 428 downloadOptions: _downloadOptions); |
| 429 return _response.then((data) => new Container.fromJson(data)); |
| 430 } |
| 431 |
| 432 } |
| 433 |
| 434 |
| 435 /** Not documented yet. */ |
| 436 class AccountsContainersMacrosResourceApi { |
| 437 final common_internal.ApiRequester _requester; |
| 438 |
| 439 AccountsContainersMacrosResourceApi(common_internal.ApiRequester client) : |
| 440 _requester = client; |
| 441 |
| 442 /** |
| 443 * Creates a GTM Macro. |
| 444 * |
| 445 * [request] - The metadata request object. |
| 446 * |
| 447 * Request parameters: |
| 448 * |
| 449 * [accountId] - The GTM Account ID. |
| 450 * |
| 451 * [containerId] - The GTM Container ID. |
| 452 * |
| 453 * Completes with a [Macro]. |
| 454 * |
| 455 * Completes with a [common.ApiRequestError] if the API endpoint returned an |
| 456 * error. |
| 457 * |
| 458 * If the used [http.Client] completes with an error when making a REST call, |
| 459 * this method will complete with the same error. |
| 460 */ |
| 461 async.Future<Macro> create(Macro request, core.String accountId, core.String c
ontainerId) { |
| 462 var _url = null; |
| 463 var _queryParams = new core.Map(); |
| 464 var _uploadMedia = null; |
| 465 var _uploadOptions = null; |
| 466 var _downloadOptions = common.DownloadOptions.Metadata; |
| 467 var _body = null; |
| 468 |
| 469 if (request != null) { |
| 470 _body = convert.JSON.encode((request).toJson()); |
| 471 } |
| 472 if (accountId == null) { |
| 473 throw new core.ArgumentError("Parameter accountId is required."); |
| 474 } |
| 475 if (containerId == null) { |
| 476 throw new core.ArgumentError("Parameter containerId is required."); |
| 477 } |
| 478 |
| 479 |
| 480 _url = 'accounts/' + common_internal.Escaper.ecapeVariable('$accountId') + '
/containers/' + common_internal.Escaper.ecapeVariable('$containerId') + '/macros
'; |
| 481 |
| 482 var _response = _requester.request(_url, |
| 483 "POST", |
| 484 body: _body, |
| 485 queryParams: _queryParams, |
| 486 uploadOptions: _uploadOptions, |
| 487 uploadMedia: _uploadMedia, |
| 488 downloadOptions: _downloadOptions); |
| 489 return _response.then((data) => new Macro.fromJson(data)); |
| 490 } |
| 491 |
| 492 /** |
| 493 * Deletes a GTM Macro. |
| 494 * |
| 495 * Request parameters: |
| 496 * |
| 497 * [accountId] - The GTM Account ID. |
| 498 * |
| 499 * [containerId] - The GTM Container ID. |
| 500 * |
| 501 * [macroId] - The GTM Macro ID. |
| 502 * |
| 503 * Completes with a [common.ApiRequestError] if the API endpoint returned an |
| 504 * error. |
| 505 * |
| 506 * If the used [http.Client] completes with an error when making a REST call, |
| 507 * this method will complete with the same error. |
| 508 */ |
| 509 async.Future delete(core.String accountId, core.String containerId, core.Strin
g macroId) { |
| 510 var _url = null; |
| 511 var _queryParams = new core.Map(); |
| 512 var _uploadMedia = null; |
| 513 var _uploadOptions = null; |
| 514 var _downloadOptions = common.DownloadOptions.Metadata; |
| 515 var _body = null; |
| 516 |
| 517 if (accountId == null) { |
| 518 throw new core.ArgumentError("Parameter accountId is required."); |
| 519 } |
| 520 if (containerId == null) { |
| 521 throw new core.ArgumentError("Parameter containerId is required."); |
| 522 } |
| 523 if (macroId == null) { |
| 524 throw new core.ArgumentError("Parameter macroId is required."); |
| 525 } |
| 526 |
| 527 _downloadOptions = null; |
| 528 |
| 529 _url = 'accounts/' + common_internal.Escaper.ecapeVariable('$accountId') + '
/containers/' + common_internal.Escaper.ecapeVariable('$containerId') + '/macros
/' + common_internal.Escaper.ecapeVariable('$macroId'); |
| 530 |
| 531 var _response = _requester.request(_url, |
| 532 "DELETE", |
| 533 body: _body, |
| 534 queryParams: _queryParams, |
| 535 uploadOptions: _uploadOptions, |
| 536 uploadMedia: _uploadMedia, |
| 537 downloadOptions: _downloadOptions); |
| 538 return _response.then((data) => null); |
| 539 } |
| 540 |
| 541 /** |
| 542 * Gets a GTM Macro. |
| 543 * |
| 544 * Request parameters: |
| 545 * |
| 546 * [accountId] - The GTM Account ID. |
| 547 * |
| 548 * [containerId] - The GTM Container ID. |
| 549 * |
| 550 * [macroId] - The GTM Macro ID. |
| 551 * |
| 552 * Completes with a [Macro]. |
| 553 * |
| 554 * Completes with a [common.ApiRequestError] if the API endpoint returned an |
| 555 * error. |
| 556 * |
| 557 * If the used [http.Client] completes with an error when making a REST call, |
| 558 * this method will complete with the same error. |
| 559 */ |
| 560 async.Future<Macro> get(core.String accountId, core.String containerId, core.S
tring macroId) { |
| 561 var _url = null; |
| 562 var _queryParams = new core.Map(); |
| 563 var _uploadMedia = null; |
| 564 var _uploadOptions = null; |
| 565 var _downloadOptions = common.DownloadOptions.Metadata; |
| 566 var _body = null; |
| 567 |
| 568 if (accountId == null) { |
| 569 throw new core.ArgumentError("Parameter accountId is required."); |
| 570 } |
| 571 if (containerId == null) { |
| 572 throw new core.ArgumentError("Parameter containerId is required."); |
| 573 } |
| 574 if (macroId == null) { |
| 575 throw new core.ArgumentError("Parameter macroId is required."); |
| 576 } |
| 577 |
| 578 |
| 579 _url = 'accounts/' + common_internal.Escaper.ecapeVariable('$accountId') + '
/containers/' + common_internal.Escaper.ecapeVariable('$containerId') + '/macros
/' + common_internal.Escaper.ecapeVariable('$macroId'); |
| 580 |
| 581 var _response = _requester.request(_url, |
| 582 "GET", |
| 583 body: _body, |
| 584 queryParams: _queryParams, |
| 585 uploadOptions: _uploadOptions, |
| 586 uploadMedia: _uploadMedia, |
| 587 downloadOptions: _downloadOptions); |
| 588 return _response.then((data) => new Macro.fromJson(data)); |
| 589 } |
| 590 |
| 591 /** |
| 592 * Lists all GTM Macros of a Container. |
| 593 * |
| 594 * Request parameters: |
| 595 * |
| 596 * [accountId] - The GTM Account ID. |
| 597 * |
| 598 * [containerId] - The GTM Container ID. |
| 599 * |
| 600 * Completes with a [ListMacrosResponse]. |
| 601 * |
| 602 * Completes with a [common.ApiRequestError] if the API endpoint returned an |
| 603 * error. |
| 604 * |
| 605 * If the used [http.Client] completes with an error when making a REST call, |
| 606 * this method will complete with the same error. |
| 607 */ |
| 608 async.Future<ListMacrosResponse> list(core.String accountId, core.String conta
inerId) { |
| 609 var _url = null; |
| 610 var _queryParams = new core.Map(); |
| 611 var _uploadMedia = null; |
| 612 var _uploadOptions = null; |
| 613 var _downloadOptions = common.DownloadOptions.Metadata; |
| 614 var _body = null; |
| 615 |
| 616 if (accountId == null) { |
| 617 throw new core.ArgumentError("Parameter accountId is required."); |
| 618 } |
| 619 if (containerId == null) { |
| 620 throw new core.ArgumentError("Parameter containerId is required."); |
| 621 } |
| 622 |
| 623 |
| 624 _url = 'accounts/' + common_internal.Escaper.ecapeVariable('$accountId') + '
/containers/' + common_internal.Escaper.ecapeVariable('$containerId') + '/macros
'; |
| 625 |
| 626 var _response = _requester.request(_url, |
| 627 "GET", |
| 628 body: _body, |
| 629 queryParams: _queryParams, |
| 630 uploadOptions: _uploadOptions, |
| 631 uploadMedia: _uploadMedia, |
| 632 downloadOptions: _downloadOptions); |
| 633 return _response.then((data) => new ListMacrosResponse.fromJson(data)); |
| 634 } |
| 635 |
| 636 /** |
| 637 * Updates a GTM Macro. |
| 638 * |
| 639 * [request] - The metadata request object. |
| 640 * |
| 641 * Request parameters: |
| 642 * |
| 643 * [accountId] - The GTM Account ID. |
| 644 * |
| 645 * [containerId] - The GTM Container ID. |
| 646 * |
| 647 * [macroId] - The GTM Macro ID. |
| 648 * |
| 649 * [fingerprint] - When provided, this fingerprint must match the fingerprint |
| 650 * of the macro in storage. |
| 651 * |
| 652 * Completes with a [Macro]. |
| 653 * |
| 654 * Completes with a [common.ApiRequestError] if the API endpoint returned an |
| 655 * error. |
| 656 * |
| 657 * If the used [http.Client] completes with an error when making a REST call, |
| 658 * this method will complete with the same error. |
| 659 */ |
| 660 async.Future<Macro> update(Macro request, core.String accountId, core.String c
ontainerId, core.String macroId, {core.String fingerprint}) { |
| 661 var _url = null; |
| 662 var _queryParams = new core.Map(); |
| 663 var _uploadMedia = null; |
| 664 var _uploadOptions = null; |
| 665 var _downloadOptions = common.DownloadOptions.Metadata; |
| 666 var _body = null; |
| 667 |
| 668 if (request != null) { |
| 669 _body = convert.JSON.encode((request).toJson()); |
| 670 } |
| 671 if (accountId == null) { |
| 672 throw new core.ArgumentError("Parameter accountId is required."); |
| 673 } |
| 674 if (containerId == null) { |
| 675 throw new core.ArgumentError("Parameter containerId is required."); |
| 676 } |
| 677 if (macroId == null) { |
| 678 throw new core.ArgumentError("Parameter macroId is required."); |
| 679 } |
| 680 if (fingerprint != null) { |
| 681 _queryParams["fingerprint"] = [fingerprint]; |
| 682 } |
| 683 |
| 684 |
| 685 _url = 'accounts/' + common_internal.Escaper.ecapeVariable('$accountId') + '
/containers/' + common_internal.Escaper.ecapeVariable('$containerId') + '/macros
/' + common_internal.Escaper.ecapeVariable('$macroId'); |
| 686 |
| 687 var _response = _requester.request(_url, |
| 688 "PUT", |
| 689 body: _body, |
| 690 queryParams: _queryParams, |
| 691 uploadOptions: _uploadOptions, |
| 692 uploadMedia: _uploadMedia, |
| 693 downloadOptions: _downloadOptions); |
| 694 return _response.then((data) => new Macro.fromJson(data)); |
| 695 } |
| 696 |
| 697 } |
| 698 |
| 699 |
| 700 /** Not documented yet. */ |
| 701 class AccountsContainersRulesResourceApi { |
| 702 final common_internal.ApiRequester _requester; |
| 703 |
| 704 AccountsContainersRulesResourceApi(common_internal.ApiRequester client) : |
| 705 _requester = client; |
| 706 |
| 707 /** |
| 708 * Creates a GTM Rule. |
| 709 * |
| 710 * [request] - The metadata request object. |
| 711 * |
| 712 * Request parameters: |
| 713 * |
| 714 * [accountId] - The GTM Account ID. |
| 715 * |
| 716 * [containerId] - The GTM Container ID. |
| 717 * |
| 718 * Completes with a [Rule]. |
| 719 * |
| 720 * Completes with a [common.ApiRequestError] if the API endpoint returned an |
| 721 * error. |
| 722 * |
| 723 * If the used [http.Client] completes with an error when making a REST call, |
| 724 * this method will complete with the same error. |
| 725 */ |
| 726 async.Future<Rule> create(Rule request, core.String accountId, core.String con
tainerId) { |
| 727 var _url = null; |
| 728 var _queryParams = new core.Map(); |
| 729 var _uploadMedia = null; |
| 730 var _uploadOptions = null; |
| 731 var _downloadOptions = common.DownloadOptions.Metadata; |
| 732 var _body = null; |
| 733 |
| 734 if (request != null) { |
| 735 _body = convert.JSON.encode((request).toJson()); |
| 736 } |
| 737 if (accountId == null) { |
| 738 throw new core.ArgumentError("Parameter accountId is required."); |
| 739 } |
| 740 if (containerId == null) { |
| 741 throw new core.ArgumentError("Parameter containerId is required."); |
| 742 } |
| 743 |
| 744 |
| 745 _url = 'accounts/' + common_internal.Escaper.ecapeVariable('$accountId') + '
/containers/' + common_internal.Escaper.ecapeVariable('$containerId') + '/rules'
; |
| 746 |
| 747 var _response = _requester.request(_url, |
| 748 "POST", |
| 749 body: _body, |
| 750 queryParams: _queryParams, |
| 751 uploadOptions: _uploadOptions, |
| 752 uploadMedia: _uploadMedia, |
| 753 downloadOptions: _downloadOptions); |
| 754 return _response.then((data) => new Rule.fromJson(data)); |
| 755 } |
| 756 |
| 757 /** |
| 758 * Deletes a GTM Rule. |
| 759 * |
| 760 * Request parameters: |
| 761 * |
| 762 * [accountId] - The GTM Account ID. |
| 763 * |
| 764 * [containerId] - The GTM Container ID. |
| 765 * |
| 766 * [ruleId] - The GTM Rule ID. |
| 767 * |
| 768 * Completes with a [common.ApiRequestError] if the API endpoint returned an |
| 769 * error. |
| 770 * |
| 771 * If the used [http.Client] completes with an error when making a REST call, |
| 772 * this method will complete with the same error. |
| 773 */ |
| 774 async.Future delete(core.String accountId, core.String containerId, core.Strin
g ruleId) { |
| 775 var _url = null; |
| 776 var _queryParams = new core.Map(); |
| 777 var _uploadMedia = null; |
| 778 var _uploadOptions = null; |
| 779 var _downloadOptions = common.DownloadOptions.Metadata; |
| 780 var _body = null; |
| 781 |
| 782 if (accountId == null) { |
| 783 throw new core.ArgumentError("Parameter accountId is required."); |
| 784 } |
| 785 if (containerId == null) { |
| 786 throw new core.ArgumentError("Parameter containerId is required."); |
| 787 } |
| 788 if (ruleId == null) { |
| 789 throw new core.ArgumentError("Parameter ruleId is required."); |
| 790 } |
| 791 |
| 792 _downloadOptions = null; |
| 793 |
| 794 _url = 'accounts/' + common_internal.Escaper.ecapeVariable('$accountId') + '
/containers/' + common_internal.Escaper.ecapeVariable('$containerId') + '/rules/
' + common_internal.Escaper.ecapeVariable('$ruleId'); |
| 795 |
| 796 var _response = _requester.request(_url, |
| 797 "DELETE", |
| 798 body: _body, |
| 799 queryParams: _queryParams, |
| 800 uploadOptions: _uploadOptions, |
| 801 uploadMedia: _uploadMedia, |
| 802 downloadOptions: _downloadOptions); |
| 803 return _response.then((data) => null); |
| 804 } |
| 805 |
| 806 /** |
| 807 * Gets a GTM Rule. |
| 808 * |
| 809 * Request parameters: |
| 810 * |
| 811 * [accountId] - The GTM Account ID. |
| 812 * |
| 813 * [containerId] - The GTM Container ID. |
| 814 * |
| 815 * [ruleId] - The GTM Rule ID. |
| 816 * |
| 817 * Completes with a [Rule]. |
| 818 * |
| 819 * Completes with a [common.ApiRequestError] if the API endpoint returned an |
| 820 * error. |
| 821 * |
| 822 * If the used [http.Client] completes with an error when making a REST call, |
| 823 * this method will complete with the same error. |
| 824 */ |
| 825 async.Future<Rule> get(core.String accountId, core.String containerId, core.St
ring ruleId) { |
| 826 var _url = null; |
| 827 var _queryParams = new core.Map(); |
| 828 var _uploadMedia = null; |
| 829 var _uploadOptions = null; |
| 830 var _downloadOptions = common.DownloadOptions.Metadata; |
| 831 var _body = null; |
| 832 |
| 833 if (accountId == null) { |
| 834 throw new core.ArgumentError("Parameter accountId is required."); |
| 835 } |
| 836 if (containerId == null) { |
| 837 throw new core.ArgumentError("Parameter containerId is required."); |
| 838 } |
| 839 if (ruleId == null) { |
| 840 throw new core.ArgumentError("Parameter ruleId is required."); |
| 841 } |
| 842 |
| 843 |
| 844 _url = 'accounts/' + common_internal.Escaper.ecapeVariable('$accountId') + '
/containers/' + common_internal.Escaper.ecapeVariable('$containerId') + '/rules/
' + common_internal.Escaper.ecapeVariable('$ruleId'); |
| 845 |
| 846 var _response = _requester.request(_url, |
| 847 "GET", |
| 848 body: _body, |
| 849 queryParams: _queryParams, |
| 850 uploadOptions: _uploadOptions, |
| 851 uploadMedia: _uploadMedia, |
| 852 downloadOptions: _downloadOptions); |
| 853 return _response.then((data) => new Rule.fromJson(data)); |
| 854 } |
| 855 |
| 856 /** |
| 857 * Lists all GTM Rules of a Container. |
| 858 * |
| 859 * Request parameters: |
| 860 * |
| 861 * [accountId] - The GTM Account ID. |
| 862 * |
| 863 * [containerId] - The GTM Container ID. |
| 864 * |
| 865 * Completes with a [ListRulesResponse]. |
| 866 * |
| 867 * Completes with a [common.ApiRequestError] if the API endpoint returned an |
| 868 * error. |
| 869 * |
| 870 * If the used [http.Client] completes with an error when making a REST call, |
| 871 * this method will complete with the same error. |
| 872 */ |
| 873 async.Future<ListRulesResponse> list(core.String accountId, core.String contai
nerId) { |
| 874 var _url = null; |
| 875 var _queryParams = new core.Map(); |
| 876 var _uploadMedia = null; |
| 877 var _uploadOptions = null; |
| 878 var _downloadOptions = common.DownloadOptions.Metadata; |
| 879 var _body = null; |
| 880 |
| 881 if (accountId == null) { |
| 882 throw new core.ArgumentError("Parameter accountId is required."); |
| 883 } |
| 884 if (containerId == null) { |
| 885 throw new core.ArgumentError("Parameter containerId is required."); |
| 886 } |
| 887 |
| 888 |
| 889 _url = 'accounts/' + common_internal.Escaper.ecapeVariable('$accountId') + '
/containers/' + common_internal.Escaper.ecapeVariable('$containerId') + '/rules'
; |
| 890 |
| 891 var _response = _requester.request(_url, |
| 892 "GET", |
| 893 body: _body, |
| 894 queryParams: _queryParams, |
| 895 uploadOptions: _uploadOptions, |
| 896 uploadMedia: _uploadMedia, |
| 897 downloadOptions: _downloadOptions); |
| 898 return _response.then((data) => new ListRulesResponse.fromJson(data)); |
| 899 } |
| 900 |
| 901 /** |
| 902 * Updates a GTM Rule. |
| 903 * |
| 904 * [request] - The metadata request object. |
| 905 * |
| 906 * Request parameters: |
| 907 * |
| 908 * [accountId] - The GTM Account ID. |
| 909 * |
| 910 * [containerId] - The GTM Container ID. |
| 911 * |
| 912 * [ruleId] - The GTM Rule ID. |
| 913 * |
| 914 * [fingerprint] - When provided, this fingerprint must match the fingerprint |
| 915 * of the rule in storage. |
| 916 * |
| 917 * Completes with a [Rule]. |
| 918 * |
| 919 * Completes with a [common.ApiRequestError] if the API endpoint returned an |
| 920 * error. |
| 921 * |
| 922 * If the used [http.Client] completes with an error when making a REST call, |
| 923 * this method will complete with the same error. |
| 924 */ |
| 925 async.Future<Rule> update(Rule request, core.String accountId, core.String con
tainerId, core.String ruleId, {core.String fingerprint}) { |
| 926 var _url = null; |
| 927 var _queryParams = new core.Map(); |
| 928 var _uploadMedia = null; |
| 929 var _uploadOptions = null; |
| 930 var _downloadOptions = common.DownloadOptions.Metadata; |
| 931 var _body = null; |
| 932 |
| 933 if (request != null) { |
| 934 _body = convert.JSON.encode((request).toJson()); |
| 935 } |
| 936 if (accountId == null) { |
| 937 throw new core.ArgumentError("Parameter accountId is required."); |
| 938 } |
| 939 if (containerId == null) { |
| 940 throw new core.ArgumentError("Parameter containerId is required."); |
| 941 } |
| 942 if (ruleId == null) { |
| 943 throw new core.ArgumentError("Parameter ruleId is required."); |
| 944 } |
| 945 if (fingerprint != null) { |
| 946 _queryParams["fingerprint"] = [fingerprint]; |
| 947 } |
| 948 |
| 949 |
| 950 _url = 'accounts/' + common_internal.Escaper.ecapeVariable('$accountId') + '
/containers/' + common_internal.Escaper.ecapeVariable('$containerId') + '/rules/
' + common_internal.Escaper.ecapeVariable('$ruleId'); |
| 951 |
| 952 var _response = _requester.request(_url, |
| 953 "PUT", |
| 954 body: _body, |
| 955 queryParams: _queryParams, |
| 956 uploadOptions: _uploadOptions, |
| 957 uploadMedia: _uploadMedia, |
| 958 downloadOptions: _downloadOptions); |
| 959 return _response.then((data) => new Rule.fromJson(data)); |
| 960 } |
| 961 |
| 962 } |
| 963 |
| 964 |
| 965 /** Not documented yet. */ |
| 966 class AccountsContainersTagsResourceApi { |
| 967 final common_internal.ApiRequester _requester; |
| 968 |
| 969 AccountsContainersTagsResourceApi(common_internal.ApiRequester client) : |
| 970 _requester = client; |
| 971 |
| 972 /** |
| 973 * Creates a GTM Tag. |
| 974 * |
| 975 * [request] - The metadata request object. |
| 976 * |
| 977 * Request parameters: |
| 978 * |
| 979 * [accountId] - The GTM Account ID. |
| 980 * |
| 981 * [containerId] - The GTM Container ID. |
| 982 * |
| 983 * Completes with a [Tag]. |
| 984 * |
| 985 * Completes with a [common.ApiRequestError] if the API endpoint returned an |
| 986 * error. |
| 987 * |
| 988 * If the used [http.Client] completes with an error when making a REST call, |
| 989 * this method will complete with the same error. |
| 990 */ |
| 991 async.Future<Tag> create(Tag request, core.String accountId, core.String conta
inerId) { |
| 992 var _url = null; |
| 993 var _queryParams = new core.Map(); |
| 994 var _uploadMedia = null; |
| 995 var _uploadOptions = null; |
| 996 var _downloadOptions = common.DownloadOptions.Metadata; |
| 997 var _body = null; |
| 998 |
| 999 if (request != null) { |
| 1000 _body = convert.JSON.encode((request).toJson()); |
| 1001 } |
| 1002 if (accountId == null) { |
| 1003 throw new core.ArgumentError("Parameter accountId is required."); |
| 1004 } |
| 1005 if (containerId == null) { |
| 1006 throw new core.ArgumentError("Parameter containerId is required."); |
| 1007 } |
| 1008 |
| 1009 |
| 1010 _url = 'accounts/' + common_internal.Escaper.ecapeVariable('$accountId') + '
/containers/' + common_internal.Escaper.ecapeVariable('$containerId') + '/tags'; |
| 1011 |
| 1012 var _response = _requester.request(_url, |
| 1013 "POST", |
| 1014 body: _body, |
| 1015 queryParams: _queryParams, |
| 1016 uploadOptions: _uploadOptions, |
| 1017 uploadMedia: _uploadMedia, |
| 1018 downloadOptions: _downloadOptions); |
| 1019 return _response.then((data) => new Tag.fromJson(data)); |
| 1020 } |
| 1021 |
| 1022 /** |
| 1023 * Deletes a GTM Tag. |
| 1024 * |
| 1025 * Request parameters: |
| 1026 * |
| 1027 * [accountId] - The GTM Account ID. |
| 1028 * |
| 1029 * [containerId] - The GTM Container ID. |
| 1030 * |
| 1031 * [tagId] - The GTM Tag ID. |
| 1032 * |
| 1033 * Completes with a [common.ApiRequestError] if the API endpoint returned an |
| 1034 * error. |
| 1035 * |
| 1036 * If the used [http.Client] completes with an error when making a REST call, |
| 1037 * this method will complete with the same error. |
| 1038 */ |
| 1039 async.Future delete(core.String accountId, core.String containerId, core.Strin
g tagId) { |
| 1040 var _url = null; |
| 1041 var _queryParams = new core.Map(); |
| 1042 var _uploadMedia = null; |
| 1043 var _uploadOptions = null; |
| 1044 var _downloadOptions = common.DownloadOptions.Metadata; |
| 1045 var _body = null; |
| 1046 |
| 1047 if (accountId == null) { |
| 1048 throw new core.ArgumentError("Parameter accountId is required."); |
| 1049 } |
| 1050 if (containerId == null) { |
| 1051 throw new core.ArgumentError("Parameter containerId is required."); |
| 1052 } |
| 1053 if (tagId == null) { |
| 1054 throw new core.ArgumentError("Parameter tagId is required."); |
| 1055 } |
| 1056 |
| 1057 _downloadOptions = null; |
| 1058 |
| 1059 _url = 'accounts/' + common_internal.Escaper.ecapeVariable('$accountId') + '
/containers/' + common_internal.Escaper.ecapeVariable('$containerId') + '/tags/'
+ common_internal.Escaper.ecapeVariable('$tagId'); |
| 1060 |
| 1061 var _response = _requester.request(_url, |
| 1062 "DELETE", |
| 1063 body: _body, |
| 1064 queryParams: _queryParams, |
| 1065 uploadOptions: _uploadOptions, |
| 1066 uploadMedia: _uploadMedia, |
| 1067 downloadOptions: _downloadOptions); |
| 1068 return _response.then((data) => null); |
| 1069 } |
| 1070 |
| 1071 /** |
| 1072 * Gets a GTM Tag. |
| 1073 * |
| 1074 * Request parameters: |
| 1075 * |
| 1076 * [accountId] - The GTM Account ID. |
| 1077 * |
| 1078 * [containerId] - The GTM Container ID. |
| 1079 * |
| 1080 * [tagId] - The GTM Tag ID. |
| 1081 * |
| 1082 * Completes with a [Tag]. |
| 1083 * |
| 1084 * Completes with a [common.ApiRequestError] if the API endpoint returned an |
| 1085 * error. |
| 1086 * |
| 1087 * If the used [http.Client] completes with an error when making a REST call, |
| 1088 * this method will complete with the same error. |
| 1089 */ |
| 1090 async.Future<Tag> get(core.String accountId, core.String containerId, core.Str
ing tagId) { |
| 1091 var _url = null; |
| 1092 var _queryParams = new core.Map(); |
| 1093 var _uploadMedia = null; |
| 1094 var _uploadOptions = null; |
| 1095 var _downloadOptions = common.DownloadOptions.Metadata; |
| 1096 var _body = null; |
| 1097 |
| 1098 if (accountId == null) { |
| 1099 throw new core.ArgumentError("Parameter accountId is required."); |
| 1100 } |
| 1101 if (containerId == null) { |
| 1102 throw new core.ArgumentError("Parameter containerId is required."); |
| 1103 } |
| 1104 if (tagId == null) { |
| 1105 throw new core.ArgumentError("Parameter tagId is required."); |
| 1106 } |
| 1107 |
| 1108 |
| 1109 _url = 'accounts/' + common_internal.Escaper.ecapeVariable('$accountId') + '
/containers/' + common_internal.Escaper.ecapeVariable('$containerId') + '/tags/'
+ common_internal.Escaper.ecapeVariable('$tagId'); |
| 1110 |
| 1111 var _response = _requester.request(_url, |
| 1112 "GET", |
| 1113 body: _body, |
| 1114 queryParams: _queryParams, |
| 1115 uploadOptions: _uploadOptions, |
| 1116 uploadMedia: _uploadMedia, |
| 1117 downloadOptions: _downloadOptions); |
| 1118 return _response.then((data) => new Tag.fromJson(data)); |
| 1119 } |
| 1120 |
| 1121 /** |
| 1122 * Lists all GTM Tags of a Container. |
| 1123 * |
| 1124 * Request parameters: |
| 1125 * |
| 1126 * [accountId] - The GTM Account ID. |
| 1127 * |
| 1128 * [containerId] - The GTM Container ID. |
| 1129 * |
| 1130 * Completes with a [ListTagsResponse]. |
| 1131 * |
| 1132 * Completes with a [common.ApiRequestError] if the API endpoint returned an |
| 1133 * error. |
| 1134 * |
| 1135 * If the used [http.Client] completes with an error when making a REST call, |
| 1136 * this method will complete with the same error. |
| 1137 */ |
| 1138 async.Future<ListTagsResponse> list(core.String accountId, core.String contain
erId) { |
| 1139 var _url = null; |
| 1140 var _queryParams = new core.Map(); |
| 1141 var _uploadMedia = null; |
| 1142 var _uploadOptions = null; |
| 1143 var _downloadOptions = common.DownloadOptions.Metadata; |
| 1144 var _body = null; |
| 1145 |
| 1146 if (accountId == null) { |
| 1147 throw new core.ArgumentError("Parameter accountId is required."); |
| 1148 } |
| 1149 if (containerId == null) { |
| 1150 throw new core.ArgumentError("Parameter containerId is required."); |
| 1151 } |
| 1152 |
| 1153 |
| 1154 _url = 'accounts/' + common_internal.Escaper.ecapeVariable('$accountId') + '
/containers/' + common_internal.Escaper.ecapeVariable('$containerId') + '/tags'; |
| 1155 |
| 1156 var _response = _requester.request(_url, |
| 1157 "GET", |
| 1158 body: _body, |
| 1159 queryParams: _queryParams, |
| 1160 uploadOptions: _uploadOptions, |
| 1161 uploadMedia: _uploadMedia, |
| 1162 downloadOptions: _downloadOptions); |
| 1163 return _response.then((data) => new ListTagsResponse.fromJson(data)); |
| 1164 } |
| 1165 |
| 1166 /** |
| 1167 * Updates a GTM Tag. |
| 1168 * |
| 1169 * [request] - The metadata request object. |
| 1170 * |
| 1171 * Request parameters: |
| 1172 * |
| 1173 * [accountId] - The GTM Account ID. |
| 1174 * |
| 1175 * [containerId] - The GTM Container ID. |
| 1176 * |
| 1177 * [tagId] - The GTM Tag ID. |
| 1178 * |
| 1179 * [fingerprint] - When provided, this fingerprint must match the fingerprint |
| 1180 * of the tag in storage. |
| 1181 * |
| 1182 * Completes with a [Tag]. |
| 1183 * |
| 1184 * Completes with a [common.ApiRequestError] if the API endpoint returned an |
| 1185 * error. |
| 1186 * |
| 1187 * If the used [http.Client] completes with an error when making a REST call, |
| 1188 * this method will complete with the same error. |
| 1189 */ |
| 1190 async.Future<Tag> update(Tag request, core.String accountId, core.String conta
inerId, core.String tagId, {core.String fingerprint}) { |
| 1191 var _url = null; |
| 1192 var _queryParams = new core.Map(); |
| 1193 var _uploadMedia = null; |
| 1194 var _uploadOptions = null; |
| 1195 var _downloadOptions = common.DownloadOptions.Metadata; |
| 1196 var _body = null; |
| 1197 |
| 1198 if (request != null) { |
| 1199 _body = convert.JSON.encode((request).toJson()); |
| 1200 } |
| 1201 if (accountId == null) { |
| 1202 throw new core.ArgumentError("Parameter accountId is required."); |
| 1203 } |
| 1204 if (containerId == null) { |
| 1205 throw new core.ArgumentError("Parameter containerId is required."); |
| 1206 } |
| 1207 if (tagId == null) { |
| 1208 throw new core.ArgumentError("Parameter tagId is required."); |
| 1209 } |
| 1210 if (fingerprint != null) { |
| 1211 _queryParams["fingerprint"] = [fingerprint]; |
| 1212 } |
| 1213 |
| 1214 |
| 1215 _url = 'accounts/' + common_internal.Escaper.ecapeVariable('$accountId') + '
/containers/' + common_internal.Escaper.ecapeVariable('$containerId') + '/tags/'
+ common_internal.Escaper.ecapeVariable('$tagId'); |
| 1216 |
| 1217 var _response = _requester.request(_url, |
| 1218 "PUT", |
| 1219 body: _body, |
| 1220 queryParams: _queryParams, |
| 1221 uploadOptions: _uploadOptions, |
| 1222 uploadMedia: _uploadMedia, |
| 1223 downloadOptions: _downloadOptions); |
| 1224 return _response.then((data) => new Tag.fromJson(data)); |
| 1225 } |
| 1226 |
| 1227 } |
| 1228 |
| 1229 |
| 1230 /** Not documented yet. */ |
| 1231 class AccountsContainersTriggersResourceApi { |
| 1232 final common_internal.ApiRequester _requester; |
| 1233 |
| 1234 AccountsContainersTriggersResourceApi(common_internal.ApiRequester client) : |
| 1235 _requester = client; |
| 1236 |
| 1237 /** |
| 1238 * Creates a GTM Trigger. |
| 1239 * |
| 1240 * [request] - The metadata request object. |
| 1241 * |
| 1242 * Request parameters: |
| 1243 * |
| 1244 * [accountId] - The GTM Account ID. |
| 1245 * |
| 1246 * [containerId] - The GTM Container ID. |
| 1247 * |
| 1248 * Completes with a [Trigger]. |
| 1249 * |
| 1250 * Completes with a [common.ApiRequestError] if the API endpoint returned an |
| 1251 * error. |
| 1252 * |
| 1253 * If the used [http.Client] completes with an error when making a REST call, |
| 1254 * this method will complete with the same error. |
| 1255 */ |
| 1256 async.Future<Trigger> create(Trigger request, core.String accountId, core.Stri
ng containerId) { |
| 1257 var _url = null; |
| 1258 var _queryParams = new core.Map(); |
| 1259 var _uploadMedia = null; |
| 1260 var _uploadOptions = null; |
| 1261 var _downloadOptions = common.DownloadOptions.Metadata; |
| 1262 var _body = null; |
| 1263 |
| 1264 if (request != null) { |
| 1265 _body = convert.JSON.encode((request).toJson()); |
| 1266 } |
| 1267 if (accountId == null) { |
| 1268 throw new core.ArgumentError("Parameter accountId is required."); |
| 1269 } |
| 1270 if (containerId == null) { |
| 1271 throw new core.ArgumentError("Parameter containerId is required."); |
| 1272 } |
| 1273 |
| 1274 |
| 1275 _url = 'accounts/' + common_internal.Escaper.ecapeVariable('$accountId') + '
/containers/' + common_internal.Escaper.ecapeVariable('$containerId') + '/trigge
rs'; |
| 1276 |
| 1277 var _response = _requester.request(_url, |
| 1278 "POST", |
| 1279 body: _body, |
| 1280 queryParams: _queryParams, |
| 1281 uploadOptions: _uploadOptions, |
| 1282 uploadMedia: _uploadMedia, |
| 1283 downloadOptions: _downloadOptions); |
| 1284 return _response.then((data) => new Trigger.fromJson(data)); |
| 1285 } |
| 1286 |
| 1287 /** |
| 1288 * Deletes a GTM Trigger. |
| 1289 * |
| 1290 * Request parameters: |
| 1291 * |
| 1292 * [accountId] - The GTM Account ID. |
| 1293 * |
| 1294 * [containerId] - The GTM Container ID. |
| 1295 * |
| 1296 * [triggerId] - The GTM Trigger ID. |
| 1297 * |
| 1298 * Completes with a [common.ApiRequestError] if the API endpoint returned an |
| 1299 * error. |
| 1300 * |
| 1301 * If the used [http.Client] completes with an error when making a REST call, |
| 1302 * this method will complete with the same error. |
| 1303 */ |
| 1304 async.Future delete(core.String accountId, core.String containerId, core.Strin
g triggerId) { |
| 1305 var _url = null; |
| 1306 var _queryParams = new core.Map(); |
| 1307 var _uploadMedia = null; |
| 1308 var _uploadOptions = null; |
| 1309 var _downloadOptions = common.DownloadOptions.Metadata; |
| 1310 var _body = null; |
| 1311 |
| 1312 if (accountId == null) { |
| 1313 throw new core.ArgumentError("Parameter accountId is required."); |
| 1314 } |
| 1315 if (containerId == null) { |
| 1316 throw new core.ArgumentError("Parameter containerId is required."); |
| 1317 } |
| 1318 if (triggerId == null) { |
| 1319 throw new core.ArgumentError("Parameter triggerId is required."); |
| 1320 } |
| 1321 |
| 1322 _downloadOptions = null; |
| 1323 |
| 1324 _url = 'accounts/' + common_internal.Escaper.ecapeVariable('$accountId') + '
/containers/' + common_internal.Escaper.ecapeVariable('$containerId') + '/trigge
rs/' + common_internal.Escaper.ecapeVariable('$triggerId'); |
| 1325 |
| 1326 var _response = _requester.request(_url, |
| 1327 "DELETE", |
| 1328 body: _body, |
| 1329 queryParams: _queryParams, |
| 1330 uploadOptions: _uploadOptions, |
| 1331 uploadMedia: _uploadMedia, |
| 1332 downloadOptions: _downloadOptions); |
| 1333 return _response.then((data) => null); |
| 1334 } |
| 1335 |
| 1336 /** |
| 1337 * Gets a GTM Trigger. |
| 1338 * |
| 1339 * Request parameters: |
| 1340 * |
| 1341 * [accountId] - The GTM Account ID. |
| 1342 * |
| 1343 * [containerId] - The GTM Container ID. |
| 1344 * |
| 1345 * [triggerId] - The GTM Trigger ID. |
| 1346 * |
| 1347 * Completes with a [Trigger]. |
| 1348 * |
| 1349 * Completes with a [common.ApiRequestError] if the API endpoint returned an |
| 1350 * error. |
| 1351 * |
| 1352 * If the used [http.Client] completes with an error when making a REST call, |
| 1353 * this method will complete with the same error. |
| 1354 */ |
| 1355 async.Future<Trigger> get(core.String accountId, core.String containerId, core
.String triggerId) { |
| 1356 var _url = null; |
| 1357 var _queryParams = new core.Map(); |
| 1358 var _uploadMedia = null; |
| 1359 var _uploadOptions = null; |
| 1360 var _downloadOptions = common.DownloadOptions.Metadata; |
| 1361 var _body = null; |
| 1362 |
| 1363 if (accountId == null) { |
| 1364 throw new core.ArgumentError("Parameter accountId is required."); |
| 1365 } |
| 1366 if (containerId == null) { |
| 1367 throw new core.ArgumentError("Parameter containerId is required."); |
| 1368 } |
| 1369 if (triggerId == null) { |
| 1370 throw new core.ArgumentError("Parameter triggerId is required."); |
| 1371 } |
| 1372 |
| 1373 |
| 1374 _url = 'accounts/' + common_internal.Escaper.ecapeVariable('$accountId') + '
/containers/' + common_internal.Escaper.ecapeVariable('$containerId') + '/trigge
rs/' + common_internal.Escaper.ecapeVariable('$triggerId'); |
| 1375 |
| 1376 var _response = _requester.request(_url, |
| 1377 "GET", |
| 1378 body: _body, |
| 1379 queryParams: _queryParams, |
| 1380 uploadOptions: _uploadOptions, |
| 1381 uploadMedia: _uploadMedia, |
| 1382 downloadOptions: _downloadOptions); |
| 1383 return _response.then((data) => new Trigger.fromJson(data)); |
| 1384 } |
| 1385 |
| 1386 /** |
| 1387 * Lists all GTM Triggers of a Container. |
| 1388 * |
| 1389 * Request parameters: |
| 1390 * |
| 1391 * [accountId] - The GTM Account ID. |
| 1392 * |
| 1393 * [containerId] - The GTM Container ID. |
| 1394 * |
| 1395 * Completes with a [ListTriggersResponse]. |
| 1396 * |
| 1397 * Completes with a [common.ApiRequestError] if the API endpoint returned an |
| 1398 * error. |
| 1399 * |
| 1400 * If the used [http.Client] completes with an error when making a REST call, |
| 1401 * this method will complete with the same error. |
| 1402 */ |
| 1403 async.Future<ListTriggersResponse> list(core.String accountId, core.String con
tainerId) { |
| 1404 var _url = null; |
| 1405 var _queryParams = new core.Map(); |
| 1406 var _uploadMedia = null; |
| 1407 var _uploadOptions = null; |
| 1408 var _downloadOptions = common.DownloadOptions.Metadata; |
| 1409 var _body = null; |
| 1410 |
| 1411 if (accountId == null) { |
| 1412 throw new core.ArgumentError("Parameter accountId is required."); |
| 1413 } |
| 1414 if (containerId == null) { |
| 1415 throw new core.ArgumentError("Parameter containerId is required."); |
| 1416 } |
| 1417 |
| 1418 |
| 1419 _url = 'accounts/' + common_internal.Escaper.ecapeVariable('$accountId') + '
/containers/' + common_internal.Escaper.ecapeVariable('$containerId') + '/trigge
rs'; |
| 1420 |
| 1421 var _response = _requester.request(_url, |
| 1422 "GET", |
| 1423 body: _body, |
| 1424 queryParams: _queryParams, |
| 1425 uploadOptions: _uploadOptions, |
| 1426 uploadMedia: _uploadMedia, |
| 1427 downloadOptions: _downloadOptions); |
| 1428 return _response.then((data) => new ListTriggersResponse.fromJson(data)); |
| 1429 } |
| 1430 |
| 1431 /** |
| 1432 * Updates a GTM Trigger. |
| 1433 * |
| 1434 * [request] - The metadata request object. |
| 1435 * |
| 1436 * Request parameters: |
| 1437 * |
| 1438 * [accountId] - The GTM Account ID. |
| 1439 * |
| 1440 * [containerId] - The GTM Container ID. |
| 1441 * |
| 1442 * [triggerId] - The GTM Trigger ID. |
| 1443 * |
| 1444 * [fingerprint] - When provided, this fingerprint must match the fingerprint |
| 1445 * of the trigger in storage. |
| 1446 * |
| 1447 * Completes with a [Trigger]. |
| 1448 * |
| 1449 * Completes with a [common.ApiRequestError] if the API endpoint returned an |
| 1450 * error. |
| 1451 * |
| 1452 * If the used [http.Client] completes with an error when making a REST call, |
| 1453 * this method will complete with the same error. |
| 1454 */ |
| 1455 async.Future<Trigger> update(Trigger request, core.String accountId, core.Stri
ng containerId, core.String triggerId, {core.String fingerprint}) { |
| 1456 var _url = null; |
| 1457 var _queryParams = new core.Map(); |
| 1458 var _uploadMedia = null; |
| 1459 var _uploadOptions = null; |
| 1460 var _downloadOptions = common.DownloadOptions.Metadata; |
| 1461 var _body = null; |
| 1462 |
| 1463 if (request != null) { |
| 1464 _body = convert.JSON.encode((request).toJson()); |
| 1465 } |
| 1466 if (accountId == null) { |
| 1467 throw new core.ArgumentError("Parameter accountId is required."); |
| 1468 } |
| 1469 if (containerId == null) { |
| 1470 throw new core.ArgumentError("Parameter containerId is required."); |
| 1471 } |
| 1472 if (triggerId == null) { |
| 1473 throw new core.ArgumentError("Parameter triggerId is required."); |
| 1474 } |
| 1475 if (fingerprint != null) { |
| 1476 _queryParams["fingerprint"] = [fingerprint]; |
| 1477 } |
| 1478 |
| 1479 |
| 1480 _url = 'accounts/' + common_internal.Escaper.ecapeVariable('$accountId') + '
/containers/' + common_internal.Escaper.ecapeVariable('$containerId') + '/trigge
rs/' + common_internal.Escaper.ecapeVariable('$triggerId'); |
| 1481 |
| 1482 var _response = _requester.request(_url, |
| 1483 "PUT", |
| 1484 body: _body, |
| 1485 queryParams: _queryParams, |
| 1486 uploadOptions: _uploadOptions, |
| 1487 uploadMedia: _uploadMedia, |
| 1488 downloadOptions: _downloadOptions); |
| 1489 return _response.then((data) => new Trigger.fromJson(data)); |
| 1490 } |
| 1491 |
| 1492 } |
| 1493 |
| 1494 |
| 1495 /** Not documented yet. */ |
| 1496 class AccountsContainersVariablesResourceApi { |
| 1497 final common_internal.ApiRequester _requester; |
| 1498 |
| 1499 AccountsContainersVariablesResourceApi(common_internal.ApiRequester client) : |
| 1500 _requester = client; |
| 1501 |
| 1502 /** |
| 1503 * Creates a GTM Variable. |
| 1504 * |
| 1505 * [request] - The metadata request object. |
| 1506 * |
| 1507 * Request parameters: |
| 1508 * |
| 1509 * [accountId] - The GTM Account ID. |
| 1510 * |
| 1511 * [containerId] - The GTM Container ID. |
| 1512 * |
| 1513 * Completes with a [Variable]. |
| 1514 * |
| 1515 * Completes with a [common.ApiRequestError] if the API endpoint returned an |
| 1516 * error. |
| 1517 * |
| 1518 * If the used [http.Client] completes with an error when making a REST call, |
| 1519 * this method will complete with the same error. |
| 1520 */ |
| 1521 async.Future<Variable> create(Variable request, core.String accountId, core.St
ring containerId) { |
| 1522 var _url = null; |
| 1523 var _queryParams = new core.Map(); |
| 1524 var _uploadMedia = null; |
| 1525 var _uploadOptions = null; |
| 1526 var _downloadOptions = common.DownloadOptions.Metadata; |
| 1527 var _body = null; |
| 1528 |
| 1529 if (request != null) { |
| 1530 _body = convert.JSON.encode((request).toJson()); |
| 1531 } |
| 1532 if (accountId == null) { |
| 1533 throw new core.ArgumentError("Parameter accountId is required."); |
| 1534 } |
| 1535 if (containerId == null) { |
| 1536 throw new core.ArgumentError("Parameter containerId is required."); |
| 1537 } |
| 1538 |
| 1539 |
| 1540 _url = 'accounts/' + common_internal.Escaper.ecapeVariable('$accountId') + '
/containers/' + common_internal.Escaper.ecapeVariable('$containerId') + '/variab
les'; |
| 1541 |
| 1542 var _response = _requester.request(_url, |
| 1543 "POST", |
| 1544 body: _body, |
| 1545 queryParams: _queryParams, |
| 1546 uploadOptions: _uploadOptions, |
| 1547 uploadMedia: _uploadMedia, |
| 1548 downloadOptions: _downloadOptions); |
| 1549 return _response.then((data) => new Variable.fromJson(data)); |
| 1550 } |
| 1551 |
| 1552 /** |
| 1553 * Deletes a GTM Variable. |
| 1554 * |
| 1555 * Request parameters: |
| 1556 * |
| 1557 * [accountId] - The GTM Account ID. |
| 1558 * |
| 1559 * [containerId] - The GTM Container ID. |
| 1560 * |
| 1561 * [variableId] - The GTM Variable ID. |
| 1562 * |
| 1563 * Completes with a [common.ApiRequestError] if the API endpoint returned an |
| 1564 * error. |
| 1565 * |
| 1566 * If the used [http.Client] completes with an error when making a REST call, |
| 1567 * this method will complete with the same error. |
| 1568 */ |
| 1569 async.Future delete(core.String accountId, core.String containerId, core.Strin
g variableId) { |
| 1570 var _url = null; |
| 1571 var _queryParams = new core.Map(); |
| 1572 var _uploadMedia = null; |
| 1573 var _uploadOptions = null; |
| 1574 var _downloadOptions = common.DownloadOptions.Metadata; |
| 1575 var _body = null; |
| 1576 |
| 1577 if (accountId == null) { |
| 1578 throw new core.ArgumentError("Parameter accountId is required."); |
| 1579 } |
| 1580 if (containerId == null) { |
| 1581 throw new core.ArgumentError("Parameter containerId is required."); |
| 1582 } |
| 1583 if (variableId == null) { |
| 1584 throw new core.ArgumentError("Parameter variableId is required."); |
| 1585 } |
| 1586 |
| 1587 _downloadOptions = null; |
| 1588 |
| 1589 _url = 'accounts/' + common_internal.Escaper.ecapeVariable('$accountId') + '
/containers/' + common_internal.Escaper.ecapeVariable('$containerId') + '/variab
les/' + common_internal.Escaper.ecapeVariable('$variableId'); |
| 1590 |
| 1591 var _response = _requester.request(_url, |
| 1592 "DELETE", |
| 1593 body: _body, |
| 1594 queryParams: _queryParams, |
| 1595 uploadOptions: _uploadOptions, |
| 1596 uploadMedia: _uploadMedia, |
| 1597 downloadOptions: _downloadOptions); |
| 1598 return _response.then((data) => null); |
| 1599 } |
| 1600 |
| 1601 /** |
| 1602 * Gets a GTM Variable. |
| 1603 * |
| 1604 * Request parameters: |
| 1605 * |
| 1606 * [accountId] - The GTM Account ID. |
| 1607 * |
| 1608 * [containerId] - The GTM Container ID. |
| 1609 * |
| 1610 * [variableId] - The GTM Variable ID. |
| 1611 * |
| 1612 * Completes with a [Variable]. |
| 1613 * |
| 1614 * Completes with a [common.ApiRequestError] if the API endpoint returned an |
| 1615 * error. |
| 1616 * |
| 1617 * If the used [http.Client] completes with an error when making a REST call, |
| 1618 * this method will complete with the same error. |
| 1619 */ |
| 1620 async.Future<Variable> get(core.String accountId, core.String containerId, cor
e.String variableId) { |
| 1621 var _url = null; |
| 1622 var _queryParams = new core.Map(); |
| 1623 var _uploadMedia = null; |
| 1624 var _uploadOptions = null; |
| 1625 var _downloadOptions = common.DownloadOptions.Metadata; |
| 1626 var _body = null; |
| 1627 |
| 1628 if (accountId == null) { |
| 1629 throw new core.ArgumentError("Parameter accountId is required."); |
| 1630 } |
| 1631 if (containerId == null) { |
| 1632 throw new core.ArgumentError("Parameter containerId is required."); |
| 1633 } |
| 1634 if (variableId == null) { |
| 1635 throw new core.ArgumentError("Parameter variableId is required."); |
| 1636 } |
| 1637 |
| 1638 |
| 1639 _url = 'accounts/' + common_internal.Escaper.ecapeVariable('$accountId') + '
/containers/' + common_internal.Escaper.ecapeVariable('$containerId') + '/variab
les/' + common_internal.Escaper.ecapeVariable('$variableId'); |
| 1640 |
| 1641 var _response = _requester.request(_url, |
| 1642 "GET", |
| 1643 body: _body, |
| 1644 queryParams: _queryParams, |
| 1645 uploadOptions: _uploadOptions, |
| 1646 uploadMedia: _uploadMedia, |
| 1647 downloadOptions: _downloadOptions); |
| 1648 return _response.then((data) => new Variable.fromJson(data)); |
| 1649 } |
| 1650 |
| 1651 /** |
| 1652 * Lists all GTM Variables of a Container. |
| 1653 * |
| 1654 * Request parameters: |
| 1655 * |
| 1656 * [accountId] - The GTM Account ID. |
| 1657 * |
| 1658 * [containerId] - The GTM Container ID. |
| 1659 * |
| 1660 * Completes with a [ListVariablesResponse]. |
| 1661 * |
| 1662 * Completes with a [common.ApiRequestError] if the API endpoint returned an |
| 1663 * error. |
| 1664 * |
| 1665 * If the used [http.Client] completes with an error when making a REST call, |
| 1666 * this method will complete with the same error. |
| 1667 */ |
| 1668 async.Future<ListVariablesResponse> list(core.String accountId, core.String co
ntainerId) { |
| 1669 var _url = null; |
| 1670 var _queryParams = new core.Map(); |
| 1671 var _uploadMedia = null; |
| 1672 var _uploadOptions = null; |
| 1673 var _downloadOptions = common.DownloadOptions.Metadata; |
| 1674 var _body = null; |
| 1675 |
| 1676 if (accountId == null) { |
| 1677 throw new core.ArgumentError("Parameter accountId is required."); |
| 1678 } |
| 1679 if (containerId == null) { |
| 1680 throw new core.ArgumentError("Parameter containerId is required."); |
| 1681 } |
| 1682 |
| 1683 |
| 1684 _url = 'accounts/' + common_internal.Escaper.ecapeVariable('$accountId') + '
/containers/' + common_internal.Escaper.ecapeVariable('$containerId') + '/variab
les'; |
| 1685 |
| 1686 var _response = _requester.request(_url, |
| 1687 "GET", |
| 1688 body: _body, |
| 1689 queryParams: _queryParams, |
| 1690 uploadOptions: _uploadOptions, |
| 1691 uploadMedia: _uploadMedia, |
| 1692 downloadOptions: _downloadOptions); |
| 1693 return _response.then((data) => new ListVariablesResponse.fromJson(data)); |
| 1694 } |
| 1695 |
| 1696 /** |
| 1697 * Updates a GTM Variable. |
| 1698 * |
| 1699 * [request] - The metadata request object. |
| 1700 * |
| 1701 * Request parameters: |
| 1702 * |
| 1703 * [accountId] - The GTM Account ID. |
| 1704 * |
| 1705 * [containerId] - The GTM Container ID. |
| 1706 * |
| 1707 * [variableId] - The GTM Variable ID. |
| 1708 * |
| 1709 * [fingerprint] - When provided, this fingerprint must match the fingerprint |
| 1710 * of the variable in storage. |
| 1711 * |
| 1712 * Completes with a [Variable]. |
| 1713 * |
| 1714 * Completes with a [common.ApiRequestError] if the API endpoint returned an |
| 1715 * error. |
| 1716 * |
| 1717 * If the used [http.Client] completes with an error when making a REST call, |
| 1718 * this method will complete with the same error. |
| 1719 */ |
| 1720 async.Future<Variable> update(Variable request, core.String accountId, core.St
ring containerId, core.String variableId, {core.String fingerprint}) { |
| 1721 var _url = null; |
| 1722 var _queryParams = new core.Map(); |
| 1723 var _uploadMedia = null; |
| 1724 var _uploadOptions = null; |
| 1725 var _downloadOptions = common.DownloadOptions.Metadata; |
| 1726 var _body = null; |
| 1727 |
| 1728 if (request != null) { |
| 1729 _body = convert.JSON.encode((request).toJson()); |
| 1730 } |
| 1731 if (accountId == null) { |
| 1732 throw new core.ArgumentError("Parameter accountId is required."); |
| 1733 } |
| 1734 if (containerId == null) { |
| 1735 throw new core.ArgumentError("Parameter containerId is required."); |
| 1736 } |
| 1737 if (variableId == null) { |
| 1738 throw new core.ArgumentError("Parameter variableId is required."); |
| 1739 } |
| 1740 if (fingerprint != null) { |
| 1741 _queryParams["fingerprint"] = [fingerprint]; |
| 1742 } |
| 1743 |
| 1744 |
| 1745 _url = 'accounts/' + common_internal.Escaper.ecapeVariable('$accountId') + '
/containers/' + common_internal.Escaper.ecapeVariable('$containerId') + '/variab
les/' + common_internal.Escaper.ecapeVariable('$variableId'); |
| 1746 |
| 1747 var _response = _requester.request(_url, |
| 1748 "PUT", |
| 1749 body: _body, |
| 1750 queryParams: _queryParams, |
| 1751 uploadOptions: _uploadOptions, |
| 1752 uploadMedia: _uploadMedia, |
| 1753 downloadOptions: _downloadOptions); |
| 1754 return _response.then((data) => new Variable.fromJson(data)); |
| 1755 } |
| 1756 |
| 1757 } |
| 1758 |
| 1759 |
| 1760 /** Not documented yet. */ |
| 1761 class AccountsContainersVersionsResourceApi { |
| 1762 final common_internal.ApiRequester _requester; |
| 1763 |
| 1764 AccountsContainersVersionsResourceApi(common_internal.ApiRequester client) : |
| 1765 _requester = client; |
| 1766 |
| 1767 /** |
| 1768 * Creates a Container Version. |
| 1769 * |
| 1770 * [request] - The metadata request object. |
| 1771 * |
| 1772 * Request parameters: |
| 1773 * |
| 1774 * [accountId] - The GTM Account ID. |
| 1775 * |
| 1776 * [containerId] - The GTM Container ID. |
| 1777 * |
| 1778 * Completes with a [CreateContainerVersionResponse]. |
| 1779 * |
| 1780 * Completes with a [common.ApiRequestError] if the API endpoint returned an |
| 1781 * error. |
| 1782 * |
| 1783 * If the used [http.Client] completes with an error when making a REST call, |
| 1784 * this method will complete with the same error. |
| 1785 */ |
| 1786 async.Future<CreateContainerVersionResponse> create(CreateContainerVersionRequ
estVersionOptions request, core.String accountId, core.String containerId) { |
| 1787 var _url = null; |
| 1788 var _queryParams = new core.Map(); |
| 1789 var _uploadMedia = null; |
| 1790 var _uploadOptions = null; |
| 1791 var _downloadOptions = common.DownloadOptions.Metadata; |
| 1792 var _body = null; |
| 1793 |
| 1794 if (request != null) { |
| 1795 _body = convert.JSON.encode((request).toJson()); |
| 1796 } |
| 1797 if (accountId == null) { |
| 1798 throw new core.ArgumentError("Parameter accountId is required."); |
| 1799 } |
| 1800 if (containerId == null) { |
| 1801 throw new core.ArgumentError("Parameter containerId is required."); |
| 1802 } |
| 1803 |
| 1804 |
| 1805 _url = 'accounts/' + common_internal.Escaper.ecapeVariable('$accountId') + '
/containers/' + common_internal.Escaper.ecapeVariable('$containerId') + '/versio
ns'; |
| 1806 |
| 1807 var _response = _requester.request(_url, |
| 1808 "POST", |
| 1809 body: _body, |
| 1810 queryParams: _queryParams, |
| 1811 uploadOptions: _uploadOptions, |
| 1812 uploadMedia: _uploadMedia, |
| 1813 downloadOptions: _downloadOptions); |
| 1814 return _response.then((data) => new CreateContainerVersionResponse.fromJson(
data)); |
| 1815 } |
| 1816 |
| 1817 /** |
| 1818 * Deletes a Container Version. |
| 1819 * |
| 1820 * Request parameters: |
| 1821 * |
| 1822 * [accountId] - The GTM Account ID. |
| 1823 * |
| 1824 * [containerId] - The GTM Container ID. |
| 1825 * |
| 1826 * [containerVersionId] - The GTM Container Version ID. |
| 1827 * |
| 1828 * Completes with a [common.ApiRequestError] if the API endpoint returned an |
| 1829 * error. |
| 1830 * |
| 1831 * If the used [http.Client] completes with an error when making a REST call, |
| 1832 * this method will complete with the same error. |
| 1833 */ |
| 1834 async.Future delete(core.String accountId, core.String containerId, core.Strin
g containerVersionId) { |
| 1835 var _url = null; |
| 1836 var _queryParams = new core.Map(); |
| 1837 var _uploadMedia = null; |
| 1838 var _uploadOptions = null; |
| 1839 var _downloadOptions = common.DownloadOptions.Metadata; |
| 1840 var _body = null; |
| 1841 |
| 1842 if (accountId == null) { |
| 1843 throw new core.ArgumentError("Parameter accountId is required."); |
| 1844 } |
| 1845 if (containerId == null) { |
| 1846 throw new core.ArgumentError("Parameter containerId is required."); |
| 1847 } |
| 1848 if (containerVersionId == null) { |
| 1849 throw new core.ArgumentError("Parameter containerVersionId is required."); |
| 1850 } |
| 1851 |
| 1852 _downloadOptions = null; |
| 1853 |
| 1854 _url = 'accounts/' + common_internal.Escaper.ecapeVariable('$accountId') + '
/containers/' + common_internal.Escaper.ecapeVariable('$containerId') + '/versio
ns/' + common_internal.Escaper.ecapeVariable('$containerVersionId'); |
| 1855 |
| 1856 var _response = _requester.request(_url, |
| 1857 "DELETE", |
| 1858 body: _body, |
| 1859 queryParams: _queryParams, |
| 1860 uploadOptions: _uploadOptions, |
| 1861 uploadMedia: _uploadMedia, |
| 1862 downloadOptions: _downloadOptions); |
| 1863 return _response.then((data) => null); |
| 1864 } |
| 1865 |
| 1866 /** |
| 1867 * Gets a Container Version. |
| 1868 * |
| 1869 * Request parameters: |
| 1870 * |
| 1871 * [accountId] - The GTM Account ID. |
| 1872 * |
| 1873 * [containerId] - The GTM Container ID. |
| 1874 * |
| 1875 * [containerVersionId] - The GTM Container Version ID. Specify published to |
| 1876 * retrieve the currently published version. |
| 1877 * |
| 1878 * Completes with a [ContainerVersion]. |
| 1879 * |
| 1880 * Completes with a [common.ApiRequestError] if the API endpoint returned an |
| 1881 * error. |
| 1882 * |
| 1883 * If the used [http.Client] completes with an error when making a REST call, |
| 1884 * this method will complete with the same error. |
| 1885 */ |
| 1886 async.Future<ContainerVersion> get(core.String accountId, core.String containe
rId, core.String containerVersionId) { |
| 1887 var _url = null; |
| 1888 var _queryParams = new core.Map(); |
| 1889 var _uploadMedia = null; |
| 1890 var _uploadOptions = null; |
| 1891 var _downloadOptions = common.DownloadOptions.Metadata; |
| 1892 var _body = null; |
| 1893 |
| 1894 if (accountId == null) { |
| 1895 throw new core.ArgumentError("Parameter accountId is required."); |
| 1896 } |
| 1897 if (containerId == null) { |
| 1898 throw new core.ArgumentError("Parameter containerId is required."); |
| 1899 } |
| 1900 if (containerVersionId == null) { |
| 1901 throw new core.ArgumentError("Parameter containerVersionId is required."); |
| 1902 } |
| 1903 |
| 1904 |
| 1905 _url = 'accounts/' + common_internal.Escaper.ecapeVariable('$accountId') + '
/containers/' + common_internal.Escaper.ecapeVariable('$containerId') + '/versio
ns/' + common_internal.Escaper.ecapeVariable('$containerVersionId'); |
| 1906 |
| 1907 var _response = _requester.request(_url, |
| 1908 "GET", |
| 1909 body: _body, |
| 1910 queryParams: _queryParams, |
| 1911 uploadOptions: _uploadOptions, |
| 1912 uploadMedia: _uploadMedia, |
| 1913 downloadOptions: _downloadOptions); |
| 1914 return _response.then((data) => new ContainerVersion.fromJson(data)); |
| 1915 } |
| 1916 |
| 1917 /** |
| 1918 * Lists all Container Versions of a GTM Container. |
| 1919 * |
| 1920 * Request parameters: |
| 1921 * |
| 1922 * [accountId] - The GTM Account ID. |
| 1923 * |
| 1924 * [containerId] - The GTM Container ID. |
| 1925 * |
| 1926 * [headers] - Retrieve headers only when true. |
| 1927 * |
| 1928 * Completes with a [ListContainerVersionsResponse]. |
| 1929 * |
| 1930 * Completes with a [common.ApiRequestError] if the API endpoint returned an |
| 1931 * error. |
| 1932 * |
| 1933 * If the used [http.Client] completes with an error when making a REST call, |
| 1934 * this method will complete with the same error. |
| 1935 */ |
| 1936 async.Future<ListContainerVersionsResponse> list(core.String accountId, core.S
tring containerId, {core.bool headers}) { |
| 1937 var _url = null; |
| 1938 var _queryParams = new core.Map(); |
| 1939 var _uploadMedia = null; |
| 1940 var _uploadOptions = null; |
| 1941 var _downloadOptions = common.DownloadOptions.Metadata; |
| 1942 var _body = null; |
| 1943 |
| 1944 if (accountId == null) { |
| 1945 throw new core.ArgumentError("Parameter accountId is required."); |
| 1946 } |
| 1947 if (containerId == null) { |
| 1948 throw new core.ArgumentError("Parameter containerId is required."); |
| 1949 } |
| 1950 if (headers != null) { |
| 1951 _queryParams["headers"] = ["${headers}"]; |
| 1952 } |
| 1953 |
| 1954 |
| 1955 _url = 'accounts/' + common_internal.Escaper.ecapeVariable('$accountId') + '
/containers/' + common_internal.Escaper.ecapeVariable('$containerId') + '/versio
ns'; |
| 1956 |
| 1957 var _response = _requester.request(_url, |
| 1958 "GET", |
| 1959 body: _body, |
| 1960 queryParams: _queryParams, |
| 1961 uploadOptions: _uploadOptions, |
| 1962 uploadMedia: _uploadMedia, |
| 1963 downloadOptions: _downloadOptions); |
| 1964 return _response.then((data) => new ListContainerVersionsResponse.fromJson(d
ata)); |
| 1965 } |
| 1966 |
| 1967 /** |
| 1968 * Publishes a Container Version. |
| 1969 * |
| 1970 * Request parameters: |
| 1971 * |
| 1972 * [accountId] - The GTM Account ID. |
| 1973 * |
| 1974 * [containerId] - The GTM Container ID. |
| 1975 * |
| 1976 * [containerVersionId] - The GTM Container Version ID. |
| 1977 * |
| 1978 * [fingerprint] - When provided, this fingerprint must match the fingerprint |
| 1979 * of the container version in storage. |
| 1980 * |
| 1981 * Completes with a [PublishContainerVersionResponse]. |
| 1982 * |
| 1983 * Completes with a [common.ApiRequestError] if the API endpoint returned an |
| 1984 * error. |
| 1985 * |
| 1986 * If the used [http.Client] completes with an error when making a REST call, |
| 1987 * this method will complete with the same error. |
| 1988 */ |
| 1989 async.Future<PublishContainerVersionResponse> publish(core.String accountId, c
ore.String containerId, core.String containerVersionId, {core.String fingerprint
}) { |
| 1990 var _url = null; |
| 1991 var _queryParams = new core.Map(); |
| 1992 var _uploadMedia = null; |
| 1993 var _uploadOptions = null; |
| 1994 var _downloadOptions = common.DownloadOptions.Metadata; |
| 1995 var _body = null; |
| 1996 |
| 1997 if (accountId == null) { |
| 1998 throw new core.ArgumentError("Parameter accountId is required."); |
| 1999 } |
| 2000 if (containerId == null) { |
| 2001 throw new core.ArgumentError("Parameter containerId is required."); |
| 2002 } |
| 2003 if (containerVersionId == null) { |
| 2004 throw new core.ArgumentError("Parameter containerVersionId is required."); |
| 2005 } |
| 2006 if (fingerprint != null) { |
| 2007 _queryParams["fingerprint"] = [fingerprint]; |
| 2008 } |
| 2009 |
| 2010 |
| 2011 _url = 'accounts/' + common_internal.Escaper.ecapeVariable('$accountId') + '
/containers/' + common_internal.Escaper.ecapeVariable('$containerId') + '/versio
ns/' + common_internal.Escaper.ecapeVariable('$containerVersionId') + '/publish'
; |
| 2012 |
| 2013 var _response = _requester.request(_url, |
| 2014 "POST", |
| 2015 body: _body, |
| 2016 queryParams: _queryParams, |
| 2017 uploadOptions: _uploadOptions, |
| 2018 uploadMedia: _uploadMedia, |
| 2019 downloadOptions: _downloadOptions); |
| 2020 return _response.then((data) => new PublishContainerVersionResponse.fromJson
(data)); |
| 2021 } |
| 2022 |
| 2023 /** |
| 2024 * Restores a Container Version. This will overwrite the container's current |
| 2025 * configuration (including its macros, rules and tags). The operation will |
| 2026 * not have any effect on the version that is being served (i.e. the published |
| 2027 * version). |
| 2028 * |
| 2029 * Request parameters: |
| 2030 * |
| 2031 * [accountId] - The GTM Account ID. |
| 2032 * |
| 2033 * [containerId] - The GTM Container ID. |
| 2034 * |
| 2035 * [containerVersionId] - The GTM Container Version ID. |
| 2036 * |
| 2037 * Completes with a [ContainerVersion]. |
| 2038 * |
| 2039 * Completes with a [common.ApiRequestError] if the API endpoint returned an |
| 2040 * error. |
| 2041 * |
| 2042 * If the used [http.Client] completes with an error when making a REST call, |
| 2043 * this method will complete with the same error. |
| 2044 */ |
| 2045 async.Future<ContainerVersion> restore(core.String accountId, core.String cont
ainerId, core.String containerVersionId) { |
| 2046 var _url = null; |
| 2047 var _queryParams = new core.Map(); |
| 2048 var _uploadMedia = null; |
| 2049 var _uploadOptions = null; |
| 2050 var _downloadOptions = common.DownloadOptions.Metadata; |
| 2051 var _body = null; |
| 2052 |
| 2053 if (accountId == null) { |
| 2054 throw new core.ArgumentError("Parameter accountId is required."); |
| 2055 } |
| 2056 if (containerId == null) { |
| 2057 throw new core.ArgumentError("Parameter containerId is required."); |
| 2058 } |
| 2059 if (containerVersionId == null) { |
| 2060 throw new core.ArgumentError("Parameter containerVersionId is required."); |
| 2061 } |
| 2062 |
| 2063 |
| 2064 _url = 'accounts/' + common_internal.Escaper.ecapeVariable('$accountId') + '
/containers/' + common_internal.Escaper.ecapeVariable('$containerId') + '/versio
ns/' + common_internal.Escaper.ecapeVariable('$containerVersionId') + '/restore'
; |
| 2065 |
| 2066 var _response = _requester.request(_url, |
| 2067 "POST", |
| 2068 body: _body, |
| 2069 queryParams: _queryParams, |
| 2070 uploadOptions: _uploadOptions, |
| 2071 uploadMedia: _uploadMedia, |
| 2072 downloadOptions: _downloadOptions); |
| 2073 return _response.then((data) => new ContainerVersion.fromJson(data)); |
| 2074 } |
| 2075 |
| 2076 /** |
| 2077 * Undeletes a Container Version. |
| 2078 * |
| 2079 * Request parameters: |
| 2080 * |
| 2081 * [accountId] - The GTM Account ID. |
| 2082 * |
| 2083 * [containerId] - The GTM Container ID. |
| 2084 * |
| 2085 * [containerVersionId] - The GTM Container Version ID. |
| 2086 * |
| 2087 * Completes with a [ContainerVersion]. |
| 2088 * |
| 2089 * Completes with a [common.ApiRequestError] if the API endpoint returned an |
| 2090 * error. |
| 2091 * |
| 2092 * If the used [http.Client] completes with an error when making a REST call, |
| 2093 * this method will complete with the same error. |
| 2094 */ |
| 2095 async.Future<ContainerVersion> undelete(core.String accountId, core.String con
tainerId, core.String containerVersionId) { |
| 2096 var _url = null; |
| 2097 var _queryParams = new core.Map(); |
| 2098 var _uploadMedia = null; |
| 2099 var _uploadOptions = null; |
| 2100 var _downloadOptions = common.DownloadOptions.Metadata; |
| 2101 var _body = null; |
| 2102 |
| 2103 if (accountId == null) { |
| 2104 throw new core.ArgumentError("Parameter accountId is required."); |
| 2105 } |
| 2106 if (containerId == null) { |
| 2107 throw new core.ArgumentError("Parameter containerId is required."); |
| 2108 } |
| 2109 if (containerVersionId == null) { |
| 2110 throw new core.ArgumentError("Parameter containerVersionId is required."); |
| 2111 } |
| 2112 |
| 2113 |
| 2114 _url = 'accounts/' + common_internal.Escaper.ecapeVariable('$accountId') + '
/containers/' + common_internal.Escaper.ecapeVariable('$containerId') + '/versio
ns/' + common_internal.Escaper.ecapeVariable('$containerVersionId') + '/undelete
'; |
| 2115 |
| 2116 var _response = _requester.request(_url, |
| 2117 "POST", |
| 2118 body: _body, |
| 2119 queryParams: _queryParams, |
| 2120 uploadOptions: _uploadOptions, |
| 2121 uploadMedia: _uploadMedia, |
| 2122 downloadOptions: _downloadOptions); |
| 2123 return _response.then((data) => new ContainerVersion.fromJson(data)); |
| 2124 } |
| 2125 |
| 2126 /** |
| 2127 * Updates a Container Version. |
| 2128 * |
| 2129 * [request] - The metadata request object. |
| 2130 * |
| 2131 * Request parameters: |
| 2132 * |
| 2133 * [accountId] - The GTM Account ID. |
| 2134 * |
| 2135 * [containerId] - The GTM Container ID. |
| 2136 * |
| 2137 * [containerVersionId] - The GTM Container Version ID. |
| 2138 * |
| 2139 * [fingerprint] - When provided, this fingerprint must match the fingerprint |
| 2140 * of the container version in storage. |
| 2141 * |
| 2142 * Completes with a [ContainerVersion]. |
| 2143 * |
| 2144 * Completes with a [common.ApiRequestError] if the API endpoint returned an |
| 2145 * error. |
| 2146 * |
| 2147 * If the used [http.Client] completes with an error when making a REST call, |
| 2148 * this method will complete with the same error. |
| 2149 */ |
| 2150 async.Future<ContainerVersion> update(ContainerVersion request, core.String ac
countId, core.String containerId, core.String containerVersionId, {core.String f
ingerprint}) { |
| 2151 var _url = null; |
| 2152 var _queryParams = new core.Map(); |
| 2153 var _uploadMedia = null; |
| 2154 var _uploadOptions = null; |
| 2155 var _downloadOptions = common.DownloadOptions.Metadata; |
| 2156 var _body = null; |
| 2157 |
| 2158 if (request != null) { |
| 2159 _body = convert.JSON.encode((request).toJson()); |
| 2160 } |
| 2161 if (accountId == null) { |
| 2162 throw new core.ArgumentError("Parameter accountId is required."); |
| 2163 } |
| 2164 if (containerId == null) { |
| 2165 throw new core.ArgumentError("Parameter containerId is required."); |
| 2166 } |
| 2167 if (containerVersionId == null) { |
| 2168 throw new core.ArgumentError("Parameter containerVersionId is required."); |
| 2169 } |
| 2170 if (fingerprint != null) { |
| 2171 _queryParams["fingerprint"] = [fingerprint]; |
| 2172 } |
| 2173 |
| 2174 |
| 2175 _url = 'accounts/' + common_internal.Escaper.ecapeVariable('$accountId') + '
/containers/' + common_internal.Escaper.ecapeVariable('$containerId') + '/versio
ns/' + common_internal.Escaper.ecapeVariable('$containerVersionId'); |
| 2176 |
| 2177 var _response = _requester.request(_url, |
| 2178 "PUT", |
| 2179 body: _body, |
| 2180 queryParams: _queryParams, |
| 2181 uploadOptions: _uploadOptions, |
| 2182 uploadMedia: _uploadMedia, |
| 2183 downloadOptions: _downloadOptions); |
| 2184 return _response.then((data) => new ContainerVersion.fromJson(data)); |
| 2185 } |
| 2186 |
| 2187 } |
| 2188 |
| 2189 |
| 2190 /** Not documented yet. */ |
| 2191 class AccountsPermissionsResourceApi { |
| 2192 final common_internal.ApiRequester _requester; |
| 2193 |
| 2194 AccountsPermissionsResourceApi(common_internal.ApiRequester client) : |
| 2195 _requester = client; |
| 2196 |
| 2197 /** |
| 2198 * Creates a user's Account & Container Permissions. |
| 2199 * |
| 2200 * [request] - The metadata request object. |
| 2201 * |
| 2202 * Request parameters: |
| 2203 * |
| 2204 * [accountId] - The GTM Account ID. |
| 2205 * |
| 2206 * Completes with a [UserAccess]. |
| 2207 * |
| 2208 * Completes with a [common.ApiRequestError] if the API endpoint returned an |
| 2209 * error. |
| 2210 * |
| 2211 * If the used [http.Client] completes with an error when making a REST call, |
| 2212 * this method will complete with the same error. |
| 2213 */ |
| 2214 async.Future<UserAccess> create(UserAccess request, core.String accountId) { |
| 2215 var _url = null; |
| 2216 var _queryParams = new core.Map(); |
| 2217 var _uploadMedia = null; |
| 2218 var _uploadOptions = null; |
| 2219 var _downloadOptions = common.DownloadOptions.Metadata; |
| 2220 var _body = null; |
| 2221 |
| 2222 if (request != null) { |
| 2223 _body = convert.JSON.encode((request).toJson()); |
| 2224 } |
| 2225 if (accountId == null) { |
| 2226 throw new core.ArgumentError("Parameter accountId is required."); |
| 2227 } |
| 2228 |
| 2229 |
| 2230 _url = 'accounts/' + common_internal.Escaper.ecapeVariable('$accountId') + '
/permissions'; |
| 2231 |
| 2232 var _response = _requester.request(_url, |
| 2233 "POST", |
| 2234 body: _body, |
| 2235 queryParams: _queryParams, |
| 2236 uploadOptions: _uploadOptions, |
| 2237 uploadMedia: _uploadMedia, |
| 2238 downloadOptions: _downloadOptions); |
| 2239 return _response.then((data) => new UserAccess.fromJson(data)); |
| 2240 } |
| 2241 |
| 2242 /** |
| 2243 * Removes a user from the account, revoking access to it and all of its |
| 2244 * containers. |
| 2245 * |
| 2246 * Request parameters: |
| 2247 * |
| 2248 * [accountId] - The GTM Account ID. |
| 2249 * |
| 2250 * [permissionId] - The GTM User ID. |
| 2251 * |
| 2252 * Completes with a [common.ApiRequestError] if the API endpoint returned an |
| 2253 * error. |
| 2254 * |
| 2255 * If the used [http.Client] completes with an error when making a REST call, |
| 2256 * this method will complete with the same error. |
| 2257 */ |
| 2258 async.Future delete(core.String accountId, core.String permissionId) { |
| 2259 var _url = null; |
| 2260 var _queryParams = new core.Map(); |
| 2261 var _uploadMedia = null; |
| 2262 var _uploadOptions = null; |
| 2263 var _downloadOptions = common.DownloadOptions.Metadata; |
| 2264 var _body = null; |
| 2265 |
| 2266 if (accountId == null) { |
| 2267 throw new core.ArgumentError("Parameter accountId is required."); |
| 2268 } |
| 2269 if (permissionId == null) { |
| 2270 throw new core.ArgumentError("Parameter permissionId is required."); |
| 2271 } |
| 2272 |
| 2273 _downloadOptions = null; |
| 2274 |
| 2275 _url = 'accounts/' + common_internal.Escaper.ecapeVariable('$accountId') + '
/permissions/' + common_internal.Escaper.ecapeVariable('$permissionId'); |
| 2276 |
| 2277 var _response = _requester.request(_url, |
| 2278 "DELETE", |
| 2279 body: _body, |
| 2280 queryParams: _queryParams, |
| 2281 uploadOptions: _uploadOptions, |
| 2282 uploadMedia: _uploadMedia, |
| 2283 downloadOptions: _downloadOptions); |
| 2284 return _response.then((data) => null); |
| 2285 } |
| 2286 |
| 2287 /** |
| 2288 * Gets a user's Account & Container Permissions. |
| 2289 * |
| 2290 * Request parameters: |
| 2291 * |
| 2292 * [accountId] - The GTM Account ID. |
| 2293 * |
| 2294 * [permissionId] - The GTM User ID. |
| 2295 * |
| 2296 * Completes with a [UserAccess]. |
| 2297 * |
| 2298 * Completes with a [common.ApiRequestError] if the API endpoint returned an |
| 2299 * error. |
| 2300 * |
| 2301 * If the used [http.Client] completes with an error when making a REST call, |
| 2302 * this method will complete with the same error. |
| 2303 */ |
| 2304 async.Future<UserAccess> get(core.String accountId, core.String permissionId)
{ |
| 2305 var _url = null; |
| 2306 var _queryParams = new core.Map(); |
| 2307 var _uploadMedia = null; |
| 2308 var _uploadOptions = null; |
| 2309 var _downloadOptions = common.DownloadOptions.Metadata; |
| 2310 var _body = null; |
| 2311 |
| 2312 if (accountId == null) { |
| 2313 throw new core.ArgumentError("Parameter accountId is required."); |
| 2314 } |
| 2315 if (permissionId == null) { |
| 2316 throw new core.ArgumentError("Parameter permissionId is required."); |
| 2317 } |
| 2318 |
| 2319 |
| 2320 _url = 'accounts/' + common_internal.Escaper.ecapeVariable('$accountId') + '
/permissions/' + common_internal.Escaper.ecapeVariable('$permissionId'); |
| 2321 |
| 2322 var _response = _requester.request(_url, |
| 2323 "GET", |
| 2324 body: _body, |
| 2325 queryParams: _queryParams, |
| 2326 uploadOptions: _uploadOptions, |
| 2327 uploadMedia: _uploadMedia, |
| 2328 downloadOptions: _downloadOptions); |
| 2329 return _response.then((data) => new UserAccess.fromJson(data)); |
| 2330 } |
| 2331 |
| 2332 /** |
| 2333 * List all users that have access to the account along with Account and |
| 2334 * Container Permissions granted to each of them. |
| 2335 * |
| 2336 * Request parameters: |
| 2337 * |
| 2338 * [accountId] - The GTM Account ID. @required |
| 2339 * tagmanager.accounts.permissions.list |
| 2340 * |
| 2341 * Completes with a [ListAccountUsersResponse]. |
| 2342 * |
| 2343 * Completes with a [common.ApiRequestError] if the API endpoint returned an |
| 2344 * error. |
| 2345 * |
| 2346 * If the used [http.Client] completes with an error when making a REST call, |
| 2347 * this method will complete with the same error. |
| 2348 */ |
| 2349 async.Future<ListAccountUsersResponse> list(core.String accountId) { |
| 2350 var _url = null; |
| 2351 var _queryParams = new core.Map(); |
| 2352 var _uploadMedia = null; |
| 2353 var _uploadOptions = null; |
| 2354 var _downloadOptions = common.DownloadOptions.Metadata; |
| 2355 var _body = null; |
| 2356 |
| 2357 if (accountId == null) { |
| 2358 throw new core.ArgumentError("Parameter accountId is required."); |
| 2359 } |
| 2360 |
| 2361 |
| 2362 _url = 'accounts/' + common_internal.Escaper.ecapeVariable('$accountId') + '
/permissions'; |
| 2363 |
| 2364 var _response = _requester.request(_url, |
| 2365 "GET", |
| 2366 body: _body, |
| 2367 queryParams: _queryParams, |
| 2368 uploadOptions: _uploadOptions, |
| 2369 uploadMedia: _uploadMedia, |
| 2370 downloadOptions: _downloadOptions); |
| 2371 return _response.then((data) => new ListAccountUsersResponse.fromJson(data))
; |
| 2372 } |
| 2373 |
| 2374 /** |
| 2375 * Updates a user's Account & Container Permissions. |
| 2376 * |
| 2377 * [request] - The metadata request object. |
| 2378 * |
| 2379 * Request parameters: |
| 2380 * |
| 2381 * [accountId] - The GTM Account ID. |
| 2382 * |
| 2383 * [permissionId] - The GTM User ID. |
| 2384 * |
| 2385 * Completes with a [UserAccess]. |
| 2386 * |
| 2387 * Completes with a [common.ApiRequestError] if the API endpoint returned an |
| 2388 * error. |
| 2389 * |
| 2390 * If the used [http.Client] completes with an error when making a REST call, |
| 2391 * this method will complete with the same error. |
| 2392 */ |
| 2393 async.Future<UserAccess> update(UserAccess request, core.String accountId, cor
e.String permissionId) { |
| 2394 var _url = null; |
| 2395 var _queryParams = new core.Map(); |
| 2396 var _uploadMedia = null; |
| 2397 var _uploadOptions = null; |
| 2398 var _downloadOptions = common.DownloadOptions.Metadata; |
| 2399 var _body = null; |
| 2400 |
| 2401 if (request != null) { |
| 2402 _body = convert.JSON.encode((request).toJson()); |
| 2403 } |
| 2404 if (accountId == null) { |
| 2405 throw new core.ArgumentError("Parameter accountId is required."); |
| 2406 } |
| 2407 if (permissionId == null) { |
| 2408 throw new core.ArgumentError("Parameter permissionId is required."); |
| 2409 } |
| 2410 |
| 2411 |
| 2412 _url = 'accounts/' + common_internal.Escaper.ecapeVariable('$accountId') + '
/permissions/' + common_internal.Escaper.ecapeVariable('$permissionId'); |
| 2413 |
| 2414 var _response = _requester.request(_url, |
| 2415 "PUT", |
| 2416 body: _body, |
| 2417 queryParams: _queryParams, |
| 2418 uploadOptions: _uploadOptions, |
| 2419 uploadMedia: _uploadMedia, |
| 2420 downloadOptions: _downloadOptions); |
| 2421 return _response.then((data) => new UserAccess.fromJson(data)); |
| 2422 } |
| 2423 |
| 2424 } |
| 2425 |
| 2426 |
| 2427 |
| 2428 /** Represents a Google Tag Manager Account. */ |
| 2429 class Account { |
| 2430 /** The Account ID uniquely identifies the GTM Account. */ |
| 2431 core.String accountId; |
| 2432 |
| 2433 /** |
| 2434 * The fingerprint of the GTM Account as computed at storage time. This value |
| 2435 * is recomputed whenever the account is modified. |
| 2436 */ |
| 2437 core.String fingerprint; |
| 2438 |
| 2439 /** Account display name. */ |
| 2440 core.String name; |
| 2441 |
| 2442 /** Whether the account shares data anonymously with Google and others. */ |
| 2443 core.bool shareData; |
| 2444 |
| 2445 |
| 2446 Account(); |
| 2447 |
| 2448 Account.fromJson(core.Map _json) { |
| 2449 if (_json.containsKey("accountId")) { |
| 2450 accountId = _json["accountId"]; |
| 2451 } |
| 2452 if (_json.containsKey("fingerprint")) { |
| 2453 fingerprint = _json["fingerprint"]; |
| 2454 } |
| 2455 if (_json.containsKey("name")) { |
| 2456 name = _json["name"]; |
| 2457 } |
| 2458 if (_json.containsKey("shareData")) { |
| 2459 shareData = _json["shareData"]; |
| 2460 } |
| 2461 } |
| 2462 |
| 2463 core.Map toJson() { |
| 2464 var _json = new core.Map(); |
| 2465 if (accountId != null) { |
| 2466 _json["accountId"] = accountId; |
| 2467 } |
| 2468 if (fingerprint != null) { |
| 2469 _json["fingerprint"] = fingerprint; |
| 2470 } |
| 2471 if (name != null) { |
| 2472 _json["name"] = name; |
| 2473 } |
| 2474 if (shareData != null) { |
| 2475 _json["shareData"] = shareData; |
| 2476 } |
| 2477 return _json; |
| 2478 } |
| 2479 } |
| 2480 |
| 2481 |
| 2482 /** Defines the Google Tag Manager Account access permissions. */ |
| 2483 class AccountAccess { |
| 2484 /** |
| 2485 * List of Account permissions. Valid account permissions are read and manage. |
| 2486 */ |
| 2487 core.List<core.String> permission; |
| 2488 |
| 2489 |
| 2490 AccountAccess(); |
| 2491 |
| 2492 AccountAccess.fromJson(core.Map _json) { |
| 2493 if (_json.containsKey("permission")) { |
| 2494 permission = _json["permission"]; |
| 2495 } |
| 2496 } |
| 2497 |
| 2498 core.Map toJson() { |
| 2499 var _json = new core.Map(); |
| 2500 if (permission != null) { |
| 2501 _json["permission"] = permission; |
| 2502 } |
| 2503 return _json; |
| 2504 } |
| 2505 } |
| 2506 |
| 2507 |
| 2508 /** Represents a predicate. */ |
| 2509 class Condition { |
| 2510 /** |
| 2511 * A list of named parameters (key/value), depending on the condition's type. |
| 2512 * Notes: |
| 2513 * - For binary operators, include parameters named arg0 and arg1 for |
| 2514 * specifying the left and right operands, respectively. |
| 2515 * - At this time, the left operand (arg0) must be a reference to a macro. |
| 2516 * - For case-insensitive Regex matching, include a boolean parameter named |
| 2517 * ignore_case that is set to true. If not specified or set to any other |
| 2518 * value, the matching will be case sensitive. |
| 2519 * - To negate an operator, include a boolean parameter named negate boolean |
| 2520 * parameter that is set to true. |
| 2521 */ |
| 2522 core.List<Parameter> parameter; |
| 2523 |
| 2524 /** |
| 2525 * The type of operator for this condition. |
| 2526 * Possible string values are: |
| 2527 * - "contains" |
| 2528 * - "endsWith" |
| 2529 * - "equals" |
| 2530 * - "greater" |
| 2531 * - "greaterOrEquals" |
| 2532 * - "less" |
| 2533 * - "lessOrEquals" |
| 2534 * - "matchRegex" |
| 2535 * - "startsWith" |
| 2536 */ |
| 2537 core.String type; |
| 2538 |
| 2539 |
| 2540 Condition(); |
| 2541 |
| 2542 Condition.fromJson(core.Map _json) { |
| 2543 if (_json.containsKey("parameter")) { |
| 2544 parameter = _json["parameter"].map((value) => new Parameter.fromJson(value
)).toList(); |
| 2545 } |
| 2546 if (_json.containsKey("type")) { |
| 2547 type = _json["type"]; |
| 2548 } |
| 2549 } |
| 2550 |
| 2551 core.Map toJson() { |
| 2552 var _json = new core.Map(); |
| 2553 if (parameter != null) { |
| 2554 _json["parameter"] = parameter.map((value) => (value).toJson()).toList(); |
| 2555 } |
| 2556 if (type != null) { |
| 2557 _json["type"] = type; |
| 2558 } |
| 2559 return _json; |
| 2560 } |
| 2561 } |
| 2562 |
| 2563 |
| 2564 /** Represents a Google Tag Manager Container. */ |
| 2565 class Container { |
| 2566 /** GTM Account ID. */ |
| 2567 core.String accountId; |
| 2568 |
| 2569 /** The Container ID uniquely identifies the GTM Container. */ |
| 2570 core.String containerId; |
| 2571 |
| 2572 /** Optional list of domain names associated with the Container. */ |
| 2573 core.List<core.String> domainName; |
| 2574 |
| 2575 /** |
| 2576 * The fingerprint of the GTM Container as computed at storage time. This |
| 2577 * value is recomputed whenever the account is modified. |
| 2578 */ |
| 2579 core.String fingerprint; |
| 2580 |
| 2581 /** Container display name. */ |
| 2582 core.String name; |
| 2583 |
| 2584 /** Container Notes. */ |
| 2585 core.String notes; |
| 2586 |
| 2587 /** Container Public ID. */ |
| 2588 core.String publicId; |
| 2589 |
| 2590 /** Container Country ID. */ |
| 2591 core.String timeZoneCountryId; |
| 2592 |
| 2593 /** Container Time Zone ID. */ |
| 2594 core.String timeZoneId; |
| 2595 |
| 2596 /** |
| 2597 * List of Usage Contexts for the Container. Valid values include: web, |
| 2598 * android, ios. |
| 2599 */ |
| 2600 core.List<core.String> usageContext; |
| 2601 |
| 2602 |
| 2603 Container(); |
| 2604 |
| 2605 Container.fromJson(core.Map _json) { |
| 2606 if (_json.containsKey("accountId")) { |
| 2607 accountId = _json["accountId"]; |
| 2608 } |
| 2609 if (_json.containsKey("containerId")) { |
| 2610 containerId = _json["containerId"]; |
| 2611 } |
| 2612 if (_json.containsKey("domainName")) { |
| 2613 domainName = _json["domainName"]; |
| 2614 } |
| 2615 if (_json.containsKey("fingerprint")) { |
| 2616 fingerprint = _json["fingerprint"]; |
| 2617 } |
| 2618 if (_json.containsKey("name")) { |
| 2619 name = _json["name"]; |
| 2620 } |
| 2621 if (_json.containsKey("notes")) { |
| 2622 notes = _json["notes"]; |
| 2623 } |
| 2624 if (_json.containsKey("publicId")) { |
| 2625 publicId = _json["publicId"]; |
| 2626 } |
| 2627 if (_json.containsKey("timeZoneCountryId")) { |
| 2628 timeZoneCountryId = _json["timeZoneCountryId"]; |
| 2629 } |
| 2630 if (_json.containsKey("timeZoneId")) { |
| 2631 timeZoneId = _json["timeZoneId"]; |
| 2632 } |
| 2633 if (_json.containsKey("usageContext")) { |
| 2634 usageContext = _json["usageContext"]; |
| 2635 } |
| 2636 } |
| 2637 |
| 2638 core.Map toJson() { |
| 2639 var _json = new core.Map(); |
| 2640 if (accountId != null) { |
| 2641 _json["accountId"] = accountId; |
| 2642 } |
| 2643 if (containerId != null) { |
| 2644 _json["containerId"] = containerId; |
| 2645 } |
| 2646 if (domainName != null) { |
| 2647 _json["domainName"] = domainName; |
| 2648 } |
| 2649 if (fingerprint != null) { |
| 2650 _json["fingerprint"] = fingerprint; |
| 2651 } |
| 2652 if (name != null) { |
| 2653 _json["name"] = name; |
| 2654 } |
| 2655 if (notes != null) { |
| 2656 _json["notes"] = notes; |
| 2657 } |
| 2658 if (publicId != null) { |
| 2659 _json["publicId"] = publicId; |
| 2660 } |
| 2661 if (timeZoneCountryId != null) { |
| 2662 _json["timeZoneCountryId"] = timeZoneCountryId; |
| 2663 } |
| 2664 if (timeZoneId != null) { |
| 2665 _json["timeZoneId"] = timeZoneId; |
| 2666 } |
| 2667 if (usageContext != null) { |
| 2668 _json["usageContext"] = usageContext; |
| 2669 } |
| 2670 return _json; |
| 2671 } |
| 2672 } |
| 2673 |
| 2674 |
| 2675 /** Defines the Google Tag Manager Container access permissions. */ |
| 2676 class ContainerAccess { |
| 2677 /** GTM Container ID. */ |
| 2678 core.String containerId; |
| 2679 |
| 2680 /** |
| 2681 * List of Container permissions. Valid container permissions are: read, edit, |
| 2682 * delete, publish. |
| 2683 */ |
| 2684 core.List<core.String> permission; |
| 2685 |
| 2686 |
| 2687 ContainerAccess(); |
| 2688 |
| 2689 ContainerAccess.fromJson(core.Map _json) { |
| 2690 if (_json.containsKey("containerId")) { |
| 2691 containerId = _json["containerId"]; |
| 2692 } |
| 2693 if (_json.containsKey("permission")) { |
| 2694 permission = _json["permission"]; |
| 2695 } |
| 2696 } |
| 2697 |
| 2698 core.Map toJson() { |
| 2699 var _json = new core.Map(); |
| 2700 if (containerId != null) { |
| 2701 _json["containerId"] = containerId; |
| 2702 } |
| 2703 if (permission != null) { |
| 2704 _json["permission"] = permission; |
| 2705 } |
| 2706 return _json; |
| 2707 } |
| 2708 } |
| 2709 |
| 2710 |
| 2711 /** Represents a Google Tag Manager Container Version. */ |
| 2712 class ContainerVersion { |
| 2713 /** GTM Account ID. */ |
| 2714 core.String accountId; |
| 2715 |
| 2716 /** The container that this version was taken from. */ |
| 2717 Container container; |
| 2718 |
| 2719 /** GTM Container ID. */ |
| 2720 core.String containerId; |
| 2721 |
| 2722 /** |
| 2723 * The Container Version ID uniquely identifies the GTM Container Version. |
| 2724 */ |
| 2725 core.String containerVersionId; |
| 2726 |
| 2727 /** A value of true indicates this container version has been deleted. */ |
| 2728 core.bool deleted; |
| 2729 |
| 2730 /** |
| 2731 * The fingerprint of the GTM Container Version as computed at storage time. |
| 2732 * This value is recomputed whenever the container version is modified. |
| 2733 */ |
| 2734 core.String fingerprint; |
| 2735 |
| 2736 /** The macros in the container that this version was taken from. */ |
| 2737 core.List<Macro> macro; |
| 2738 |
| 2739 /** Container version display name. */ |
| 2740 core.String name; |
| 2741 |
| 2742 /** User notes on how to apply this container version in the container. */ |
| 2743 core.String notes; |
| 2744 |
| 2745 /** The rules in the container that this version was taken from. */ |
| 2746 core.List<Rule> rule; |
| 2747 |
| 2748 /** The tags in the container that this version was taken from. */ |
| 2749 core.List<Tag> tag; |
| 2750 |
| 2751 /** The triggers in the container that this version was taken from. */ |
| 2752 core.List<Trigger> trigger; |
| 2753 |
| 2754 /** The variables in the container that this version was taken from. */ |
| 2755 core.List<Variable> variable; |
| 2756 |
| 2757 |
| 2758 ContainerVersion(); |
| 2759 |
| 2760 ContainerVersion.fromJson(core.Map _json) { |
| 2761 if (_json.containsKey("accountId")) { |
| 2762 accountId = _json["accountId"]; |
| 2763 } |
| 2764 if (_json.containsKey("container")) { |
| 2765 container = new Container.fromJson(_json["container"]); |
| 2766 } |
| 2767 if (_json.containsKey("containerId")) { |
| 2768 containerId = _json["containerId"]; |
| 2769 } |
| 2770 if (_json.containsKey("containerVersionId")) { |
| 2771 containerVersionId = _json["containerVersionId"]; |
| 2772 } |
| 2773 if (_json.containsKey("deleted")) { |
| 2774 deleted = _json["deleted"]; |
| 2775 } |
| 2776 if (_json.containsKey("fingerprint")) { |
| 2777 fingerprint = _json["fingerprint"]; |
| 2778 } |
| 2779 if (_json.containsKey("macro")) { |
| 2780 macro = _json["macro"].map((value) => new Macro.fromJson(value)).toList(); |
| 2781 } |
| 2782 if (_json.containsKey("name")) { |
| 2783 name = _json["name"]; |
| 2784 } |
| 2785 if (_json.containsKey("notes")) { |
| 2786 notes = _json["notes"]; |
| 2787 } |
| 2788 if (_json.containsKey("rule")) { |
| 2789 rule = _json["rule"].map((value) => new Rule.fromJson(value)).toList(); |
| 2790 } |
| 2791 if (_json.containsKey("tag")) { |
| 2792 tag = _json["tag"].map((value) => new Tag.fromJson(value)).toList(); |
| 2793 } |
| 2794 if (_json.containsKey("trigger")) { |
| 2795 trigger = _json["trigger"].map((value) => new Trigger.fromJson(value)).toL
ist(); |
| 2796 } |
| 2797 if (_json.containsKey("variable")) { |
| 2798 variable = _json["variable"].map((value) => new Variable.fromJson(value)).
toList(); |
| 2799 } |
| 2800 } |
| 2801 |
| 2802 core.Map toJson() { |
| 2803 var _json = new core.Map(); |
| 2804 if (accountId != null) { |
| 2805 _json["accountId"] = accountId; |
| 2806 } |
| 2807 if (container != null) { |
| 2808 _json["container"] = (container).toJson(); |
| 2809 } |
| 2810 if (containerId != null) { |
| 2811 _json["containerId"] = containerId; |
| 2812 } |
| 2813 if (containerVersionId != null) { |
| 2814 _json["containerVersionId"] = containerVersionId; |
| 2815 } |
| 2816 if (deleted != null) { |
| 2817 _json["deleted"] = deleted; |
| 2818 } |
| 2819 if (fingerprint != null) { |
| 2820 _json["fingerprint"] = fingerprint; |
| 2821 } |
| 2822 if (macro != null) { |
| 2823 _json["macro"] = macro.map((value) => (value).toJson()).toList(); |
| 2824 } |
| 2825 if (name != null) { |
| 2826 _json["name"] = name; |
| 2827 } |
| 2828 if (notes != null) { |
| 2829 _json["notes"] = notes; |
| 2830 } |
| 2831 if (rule != null) { |
| 2832 _json["rule"] = rule.map((value) => (value).toJson()).toList(); |
| 2833 } |
| 2834 if (tag != null) { |
| 2835 _json["tag"] = tag.map((value) => (value).toJson()).toList(); |
| 2836 } |
| 2837 if (trigger != null) { |
| 2838 _json["trigger"] = trigger.map((value) => (value).toJson()).toList(); |
| 2839 } |
| 2840 if (variable != null) { |
| 2841 _json["variable"] = variable.map((value) => (value).toJson()).toList(); |
| 2842 } |
| 2843 return _json; |
| 2844 } |
| 2845 } |
| 2846 |
| 2847 |
| 2848 /** Represents a Google Tag Manager Container Version Header. */ |
| 2849 class ContainerVersionHeader { |
| 2850 /** GTM Account ID. */ |
| 2851 core.String accountId; |
| 2852 |
| 2853 /** GTM Container ID. */ |
| 2854 core.String containerId; |
| 2855 |
| 2856 /** |
| 2857 * The Container Version ID uniquely identifies the GTM Container Version. |
| 2858 */ |
| 2859 core.String containerVersionId; |
| 2860 |
| 2861 /** A value of true indicates this container version has been deleted. */ |
| 2862 core.bool deleted; |
| 2863 |
| 2864 /** Container version display name. */ |
| 2865 core.String name; |
| 2866 |
| 2867 /** Number of macros in the container version. */ |
| 2868 core.String numMacros; |
| 2869 |
| 2870 /** Number of rules in the container version. */ |
| 2871 core.String numRules; |
| 2872 |
| 2873 /** Number of tags in the container version. */ |
| 2874 core.String numTags; |
| 2875 |
| 2876 /** Number of triggers in the container version. */ |
| 2877 core.String numTriggers; |
| 2878 |
| 2879 /** Number of variables in the container version. */ |
| 2880 core.String numVariables; |
| 2881 |
| 2882 |
| 2883 ContainerVersionHeader(); |
| 2884 |
| 2885 ContainerVersionHeader.fromJson(core.Map _json) { |
| 2886 if (_json.containsKey("accountId")) { |
| 2887 accountId = _json["accountId"]; |
| 2888 } |
| 2889 if (_json.containsKey("containerId")) { |
| 2890 containerId = _json["containerId"]; |
| 2891 } |
| 2892 if (_json.containsKey("containerVersionId")) { |
| 2893 containerVersionId = _json["containerVersionId"]; |
| 2894 } |
| 2895 if (_json.containsKey("deleted")) { |
| 2896 deleted = _json["deleted"]; |
| 2897 } |
| 2898 if (_json.containsKey("name")) { |
| 2899 name = _json["name"]; |
| 2900 } |
| 2901 if (_json.containsKey("numMacros")) { |
| 2902 numMacros = _json["numMacros"]; |
| 2903 } |
| 2904 if (_json.containsKey("numRules")) { |
| 2905 numRules = _json["numRules"]; |
| 2906 } |
| 2907 if (_json.containsKey("numTags")) { |
| 2908 numTags = _json["numTags"]; |
| 2909 } |
| 2910 if (_json.containsKey("numTriggers")) { |
| 2911 numTriggers = _json["numTriggers"]; |
| 2912 } |
| 2913 if (_json.containsKey("numVariables")) { |
| 2914 numVariables = _json["numVariables"]; |
| 2915 } |
| 2916 } |
| 2917 |
| 2918 core.Map toJson() { |
| 2919 var _json = new core.Map(); |
| 2920 if (accountId != null) { |
| 2921 _json["accountId"] = accountId; |
| 2922 } |
| 2923 if (containerId != null) { |
| 2924 _json["containerId"] = containerId; |
| 2925 } |
| 2926 if (containerVersionId != null) { |
| 2927 _json["containerVersionId"] = containerVersionId; |
| 2928 } |
| 2929 if (deleted != null) { |
| 2930 _json["deleted"] = deleted; |
| 2931 } |
| 2932 if (name != null) { |
| 2933 _json["name"] = name; |
| 2934 } |
| 2935 if (numMacros != null) { |
| 2936 _json["numMacros"] = numMacros; |
| 2937 } |
| 2938 if (numRules != null) { |
| 2939 _json["numRules"] = numRules; |
| 2940 } |
| 2941 if (numTags != null) { |
| 2942 _json["numTags"] = numTags; |
| 2943 } |
| 2944 if (numTriggers != null) { |
| 2945 _json["numTriggers"] = numTriggers; |
| 2946 } |
| 2947 if (numVariables != null) { |
| 2948 _json["numVariables"] = numVariables; |
| 2949 } |
| 2950 return _json; |
| 2951 } |
| 2952 } |
| 2953 |
| 2954 |
| 2955 /** Options for new container versions. */ |
| 2956 class CreateContainerVersionRequestVersionOptions { |
| 2957 /** The name of the container version to be created. */ |
| 2958 core.String name; |
| 2959 |
| 2960 /** The notes of the container version to be created. */ |
| 2961 core.String notes; |
| 2962 |
| 2963 /** |
| 2964 * The creation of this version may be for quick preview and shouldn't be |
| 2965 * saved. |
| 2966 */ |
| 2967 core.bool quickPreview; |
| 2968 |
| 2969 |
| 2970 CreateContainerVersionRequestVersionOptions(); |
| 2971 |
| 2972 CreateContainerVersionRequestVersionOptions.fromJson(core.Map _json) { |
| 2973 if (_json.containsKey("name")) { |
| 2974 name = _json["name"]; |
| 2975 } |
| 2976 if (_json.containsKey("notes")) { |
| 2977 notes = _json["notes"]; |
| 2978 } |
| 2979 if (_json.containsKey("quickPreview")) { |
| 2980 quickPreview = _json["quickPreview"]; |
| 2981 } |
| 2982 } |
| 2983 |
| 2984 core.Map toJson() { |
| 2985 var _json = new core.Map(); |
| 2986 if (name != null) { |
| 2987 _json["name"] = name; |
| 2988 } |
| 2989 if (notes != null) { |
| 2990 _json["notes"] = notes; |
| 2991 } |
| 2992 if (quickPreview != null) { |
| 2993 _json["quickPreview"] = quickPreview; |
| 2994 } |
| 2995 return _json; |
| 2996 } |
| 2997 } |
| 2998 |
| 2999 |
| 3000 /** Create container versions response. */ |
| 3001 class CreateContainerVersionResponse { |
| 3002 /** Compiler errors or not. */ |
| 3003 core.bool compilerError; |
| 3004 |
| 3005 /** The container version created. */ |
| 3006 ContainerVersion containerVersion; |
| 3007 |
| 3008 |
| 3009 CreateContainerVersionResponse(); |
| 3010 |
| 3011 CreateContainerVersionResponse.fromJson(core.Map _json) { |
| 3012 if (_json.containsKey("compilerError")) { |
| 3013 compilerError = _json["compilerError"]; |
| 3014 } |
| 3015 if (_json.containsKey("containerVersion")) { |
| 3016 containerVersion = new ContainerVersion.fromJson(_json["containerVersion"]
); |
| 3017 } |
| 3018 } |
| 3019 |
| 3020 core.Map toJson() { |
| 3021 var _json = new core.Map(); |
| 3022 if (compilerError != null) { |
| 3023 _json["compilerError"] = compilerError; |
| 3024 } |
| 3025 if (containerVersion != null) { |
| 3026 _json["containerVersion"] = (containerVersion).toJson(); |
| 3027 } |
| 3028 return _json; |
| 3029 } |
| 3030 } |
| 3031 |
| 3032 |
| 3033 /** List AccountUsers Response. */ |
| 3034 class ListAccountUsersResponse { |
| 3035 /** All GTM AccountUsers of a GTM Account. */ |
| 3036 core.List<UserAccess> userAccess; |
| 3037 |
| 3038 |
| 3039 ListAccountUsersResponse(); |
| 3040 |
| 3041 ListAccountUsersResponse.fromJson(core.Map _json) { |
| 3042 if (_json.containsKey("userAccess")) { |
| 3043 userAccess = _json["userAccess"].map((value) => new UserAccess.fromJson(va
lue)).toList(); |
| 3044 } |
| 3045 } |
| 3046 |
| 3047 core.Map toJson() { |
| 3048 var _json = new core.Map(); |
| 3049 if (userAccess != null) { |
| 3050 _json["userAccess"] = userAccess.map((value) => (value).toJson()).toList()
; |
| 3051 } |
| 3052 return _json; |
| 3053 } |
| 3054 } |
| 3055 |
| 3056 |
| 3057 /** List Accounts Response. */ |
| 3058 class ListAccountsResponse { |
| 3059 /** List of GTM Accounts that a user has access to. */ |
| 3060 core.List<Account> accounts; |
| 3061 |
| 3062 |
| 3063 ListAccountsResponse(); |
| 3064 |
| 3065 ListAccountsResponse.fromJson(core.Map _json) { |
| 3066 if (_json.containsKey("accounts")) { |
| 3067 accounts = _json["accounts"].map((value) => new Account.fromJson(value)).t
oList(); |
| 3068 } |
| 3069 } |
| 3070 |
| 3071 core.Map toJson() { |
| 3072 var _json = new core.Map(); |
| 3073 if (accounts != null) { |
| 3074 _json["accounts"] = accounts.map((value) => (value).toJson()).toList(); |
| 3075 } |
| 3076 return _json; |
| 3077 } |
| 3078 } |
| 3079 |
| 3080 |
| 3081 /** List container versions response. */ |
| 3082 class ListContainerVersionsResponse { |
| 3083 /** All versions of a GTM Container. */ |
| 3084 core.List<ContainerVersion> containerVersion; |
| 3085 |
| 3086 /** All container version headers of a GTM Container. */ |
| 3087 core.List<ContainerVersionHeader> containerVersionHeader; |
| 3088 |
| 3089 |
| 3090 ListContainerVersionsResponse(); |
| 3091 |
| 3092 ListContainerVersionsResponse.fromJson(core.Map _json) { |
| 3093 if (_json.containsKey("containerVersion")) { |
| 3094 containerVersion = _json["containerVersion"].map((value) => new ContainerV
ersion.fromJson(value)).toList(); |
| 3095 } |
| 3096 if (_json.containsKey("containerVersionHeader")) { |
| 3097 containerVersionHeader = _json["containerVersionHeader"].map((value) => ne
w ContainerVersionHeader.fromJson(value)).toList(); |
| 3098 } |
| 3099 } |
| 3100 |
| 3101 core.Map toJson() { |
| 3102 var _json = new core.Map(); |
| 3103 if (containerVersion != null) { |
| 3104 _json["containerVersion"] = containerVersion.map((value) => (value).toJson
()).toList(); |
| 3105 } |
| 3106 if (containerVersionHeader != null) { |
| 3107 _json["containerVersionHeader"] = containerVersionHeader.map((value) => (v
alue).toJson()).toList(); |
| 3108 } |
| 3109 return _json; |
| 3110 } |
| 3111 } |
| 3112 |
| 3113 |
| 3114 /** List Containers Response. */ |
| 3115 class ListContainersResponse { |
| 3116 /** All Containers of a GTM Account. */ |
| 3117 core.List<Container> containers; |
| 3118 |
| 3119 |
| 3120 ListContainersResponse(); |
| 3121 |
| 3122 ListContainersResponse.fromJson(core.Map _json) { |
| 3123 if (_json.containsKey("containers")) { |
| 3124 containers = _json["containers"].map((value) => new Container.fromJson(val
ue)).toList(); |
| 3125 } |
| 3126 } |
| 3127 |
| 3128 core.Map toJson() { |
| 3129 var _json = new core.Map(); |
| 3130 if (containers != null) { |
| 3131 _json["containers"] = containers.map((value) => (value).toJson()).toList()
; |
| 3132 } |
| 3133 return _json; |
| 3134 } |
| 3135 } |
| 3136 |
| 3137 |
| 3138 /** List Macros Response. */ |
| 3139 class ListMacrosResponse { |
| 3140 /** All GTM Macros of a GTM Container. */ |
| 3141 core.List<Macro> macros; |
| 3142 |
| 3143 |
| 3144 ListMacrosResponse(); |
| 3145 |
| 3146 ListMacrosResponse.fromJson(core.Map _json) { |
| 3147 if (_json.containsKey("macros")) { |
| 3148 macros = _json["macros"].map((value) => new Macro.fromJson(value)).toList(
); |
| 3149 } |
| 3150 } |
| 3151 |
| 3152 core.Map toJson() { |
| 3153 var _json = new core.Map(); |
| 3154 if (macros != null) { |
| 3155 _json["macros"] = macros.map((value) => (value).toJson()).toList(); |
| 3156 } |
| 3157 return _json; |
| 3158 } |
| 3159 } |
| 3160 |
| 3161 |
| 3162 /** List Rules Response. */ |
| 3163 class ListRulesResponse { |
| 3164 /** All GTM Rules of a GTM Container. */ |
| 3165 core.List<Rule> rules; |
| 3166 |
| 3167 |
| 3168 ListRulesResponse(); |
| 3169 |
| 3170 ListRulesResponse.fromJson(core.Map _json) { |
| 3171 if (_json.containsKey("rules")) { |
| 3172 rules = _json["rules"].map((value) => new Rule.fromJson(value)).toList(); |
| 3173 } |
| 3174 } |
| 3175 |
| 3176 core.Map toJson() { |
| 3177 var _json = new core.Map(); |
| 3178 if (rules != null) { |
| 3179 _json["rules"] = rules.map((value) => (value).toJson()).toList(); |
| 3180 } |
| 3181 return _json; |
| 3182 } |
| 3183 } |
| 3184 |
| 3185 |
| 3186 /** List Tags Response. */ |
| 3187 class ListTagsResponse { |
| 3188 /** All GTM Tags of a GTM Container. */ |
| 3189 core.List<Tag> tags; |
| 3190 |
| 3191 |
| 3192 ListTagsResponse(); |
| 3193 |
| 3194 ListTagsResponse.fromJson(core.Map _json) { |
| 3195 if (_json.containsKey("tags")) { |
| 3196 tags = _json["tags"].map((value) => new Tag.fromJson(value)).toList(); |
| 3197 } |
| 3198 } |
| 3199 |
| 3200 core.Map toJson() { |
| 3201 var _json = new core.Map(); |
| 3202 if (tags != null) { |
| 3203 _json["tags"] = tags.map((value) => (value).toJson()).toList(); |
| 3204 } |
| 3205 return _json; |
| 3206 } |
| 3207 } |
| 3208 |
| 3209 |
| 3210 /** List triggers response. */ |
| 3211 class ListTriggersResponse { |
| 3212 /** All GTM Triggers of a GTM Container. */ |
| 3213 core.List<Trigger> triggers; |
| 3214 |
| 3215 |
| 3216 ListTriggersResponse(); |
| 3217 |
| 3218 ListTriggersResponse.fromJson(core.Map _json) { |
| 3219 if (_json.containsKey("triggers")) { |
| 3220 triggers = _json["triggers"].map((value) => new Trigger.fromJson(value)).t
oList(); |
| 3221 } |
| 3222 } |
| 3223 |
| 3224 core.Map toJson() { |
| 3225 var _json = new core.Map(); |
| 3226 if (triggers != null) { |
| 3227 _json["triggers"] = triggers.map((value) => (value).toJson()).toList(); |
| 3228 } |
| 3229 return _json; |
| 3230 } |
| 3231 } |
| 3232 |
| 3233 |
| 3234 /** List Variables Response. */ |
| 3235 class ListVariablesResponse { |
| 3236 /** All GTM Variables of a GTM Container. */ |
| 3237 core.List<Variable> variables; |
| 3238 |
| 3239 |
| 3240 ListVariablesResponse(); |
| 3241 |
| 3242 ListVariablesResponse.fromJson(core.Map _json) { |
| 3243 if (_json.containsKey("variables")) { |
| 3244 variables = _json["variables"].map((value) => new Variable.fromJson(value)
).toList(); |
| 3245 } |
| 3246 } |
| 3247 |
| 3248 core.Map toJson() { |
| 3249 var _json = new core.Map(); |
| 3250 if (variables != null) { |
| 3251 _json["variables"] = variables.map((value) => (value).toJson()).toList(); |
| 3252 } |
| 3253 return _json; |
| 3254 } |
| 3255 } |
| 3256 |
| 3257 |
| 3258 /** Represents a Google Tag Manager Macro. */ |
| 3259 class Macro { |
| 3260 /** GTM Account ID. */ |
| 3261 core.String accountId; |
| 3262 |
| 3263 /** GTM Container ID. */ |
| 3264 core.String containerId; |
| 3265 |
| 3266 /** |
| 3267 * For mobile containers only: A list of rule IDs for disabling conditional |
| 3268 * macros; the macro is enabled if one of the enabling rules is true while all |
| 3269 * the disabling rules are false. Treated as an unordered set. |
| 3270 */ |
| 3271 core.List<core.String> disablingRuleId; |
| 3272 |
| 3273 /** |
| 3274 * For mobile containers only: A list of rule IDs for enabling conditional |
| 3275 * macros; the macro is enabled if one of the enabling rules is true while all |
| 3276 * the disabling rules are false. Treated as an unordered set. |
| 3277 */ |
| 3278 core.List<core.String> enablingRuleId; |
| 3279 |
| 3280 /** |
| 3281 * The fingerprint of the GTM Macro as computed at storage time. This value is |
| 3282 * recomputed whenever the macro is modified. |
| 3283 */ |
| 3284 core.String fingerprint; |
| 3285 |
| 3286 /** The Macro ID uniquely identifies the GTM Macro. */ |
| 3287 core.String macroId; |
| 3288 |
| 3289 /** Macro display name. */ |
| 3290 core.String name; |
| 3291 |
| 3292 /** User notes on how to apply this macro in the container. */ |
| 3293 core.String notes; |
| 3294 |
| 3295 /** The macro's parameters. */ |
| 3296 core.List<Parameter> parameter; |
| 3297 |
| 3298 /** The end timestamp in milliseconds to schedule a macro. */ |
| 3299 core.String scheduleEndMs; |
| 3300 |
| 3301 /** The start timestamp in milliseconds to schedule a macro. */ |
| 3302 core.String scheduleStartMs; |
| 3303 |
| 3304 /** GTM Macro Type. */ |
| 3305 core.String type; |
| 3306 |
| 3307 |
| 3308 Macro(); |
| 3309 |
| 3310 Macro.fromJson(core.Map _json) { |
| 3311 if (_json.containsKey("accountId")) { |
| 3312 accountId = _json["accountId"]; |
| 3313 } |
| 3314 if (_json.containsKey("containerId")) { |
| 3315 containerId = _json["containerId"]; |
| 3316 } |
| 3317 if (_json.containsKey("disablingRuleId")) { |
| 3318 disablingRuleId = _json["disablingRuleId"]; |
| 3319 } |
| 3320 if (_json.containsKey("enablingRuleId")) { |
| 3321 enablingRuleId = _json["enablingRuleId"]; |
| 3322 } |
| 3323 if (_json.containsKey("fingerprint")) { |
| 3324 fingerprint = _json["fingerprint"]; |
| 3325 } |
| 3326 if (_json.containsKey("macroId")) { |
| 3327 macroId = _json["macroId"]; |
| 3328 } |
| 3329 if (_json.containsKey("name")) { |
| 3330 name = _json["name"]; |
| 3331 } |
| 3332 if (_json.containsKey("notes")) { |
| 3333 notes = _json["notes"]; |
| 3334 } |
| 3335 if (_json.containsKey("parameter")) { |
| 3336 parameter = _json["parameter"].map((value) => new Parameter.fromJson(value
)).toList(); |
| 3337 } |
| 3338 if (_json.containsKey("scheduleEndMs")) { |
| 3339 scheduleEndMs = _json["scheduleEndMs"]; |
| 3340 } |
| 3341 if (_json.containsKey("scheduleStartMs")) { |
| 3342 scheduleStartMs = _json["scheduleStartMs"]; |
| 3343 } |
| 3344 if (_json.containsKey("type")) { |
| 3345 type = _json["type"]; |
| 3346 } |
| 3347 } |
| 3348 |
| 3349 core.Map toJson() { |
| 3350 var _json = new core.Map(); |
| 3351 if (accountId != null) { |
| 3352 _json["accountId"] = accountId; |
| 3353 } |
| 3354 if (containerId != null) { |
| 3355 _json["containerId"] = containerId; |
| 3356 } |
| 3357 if (disablingRuleId != null) { |
| 3358 _json["disablingRuleId"] = disablingRuleId; |
| 3359 } |
| 3360 if (enablingRuleId != null) { |
| 3361 _json["enablingRuleId"] = enablingRuleId; |
| 3362 } |
| 3363 if (fingerprint != null) { |
| 3364 _json["fingerprint"] = fingerprint; |
| 3365 } |
| 3366 if (macroId != null) { |
| 3367 _json["macroId"] = macroId; |
| 3368 } |
| 3369 if (name != null) { |
| 3370 _json["name"] = name; |
| 3371 } |
| 3372 if (notes != null) { |
| 3373 _json["notes"] = notes; |
| 3374 } |
| 3375 if (parameter != null) { |
| 3376 _json["parameter"] = parameter.map((value) => (value).toJson()).toList(); |
| 3377 } |
| 3378 if (scheduleEndMs != null) { |
| 3379 _json["scheduleEndMs"] = scheduleEndMs; |
| 3380 } |
| 3381 if (scheduleStartMs != null) { |
| 3382 _json["scheduleStartMs"] = scheduleStartMs; |
| 3383 } |
| 3384 if (type != null) { |
| 3385 _json["type"] = type; |
| 3386 } |
| 3387 return _json; |
| 3388 } |
| 3389 } |
| 3390 |
| 3391 |
| 3392 /** Represents a Google Tag Manager Parameter. */ |
| 3393 class Parameter { |
| 3394 /** |
| 3395 * The named key that uniquely identifies a parameter. Required for top-level |
| 3396 * parameters, as well as map values. Ignored for list values. |
| 3397 */ |
| 3398 core.String key; |
| 3399 |
| 3400 /** This list parameter's parameters (keys will be ignored). */ |
| 3401 core.List<Parameter> list; |
| 3402 |
| 3403 /** This map parameter's parameters (must have keys; keys must be unique). */ |
| 3404 core.List<Parameter> map; |
| 3405 |
| 3406 /** |
| 3407 * The parameter type. Valid values are: |
| 3408 * - boolean: The value represents a boolean, represented as 'true' or 'false' |
| 3409 * - integer: The value represents a 64-bit signed integer value, in base 10 |
| 3410 * - list: A list of parameters should be specified |
| 3411 * - map: A map of parameters should be specified |
| 3412 * - template: The value represents any text; this can include macro |
| 3413 * references (even macro references that might return non-string types) |
| 3414 * Possible string values are: |
| 3415 * - "boolean" |
| 3416 * - "integer" |
| 3417 * - "list" |
| 3418 * - "map" |
| 3419 * - "template" |
| 3420 */ |
| 3421 core.String type; |
| 3422 |
| 3423 /** |
| 3424 * A parameter's value (may contain macro references such as "{{myMacro}}") as |
| 3425 * appropriate to the specified type. |
| 3426 */ |
| 3427 core.String value; |
| 3428 |
| 3429 |
| 3430 Parameter(); |
| 3431 |
| 3432 Parameter.fromJson(core.Map _json) { |
| 3433 if (_json.containsKey("key")) { |
| 3434 key = _json["key"]; |
| 3435 } |
| 3436 if (_json.containsKey("list")) { |
| 3437 list = _json["list"].map((value) => new Parameter.fromJson(value)).toList(
); |
| 3438 } |
| 3439 if (_json.containsKey("map")) { |
| 3440 map = _json["map"].map((value) => new Parameter.fromJson(value)).toList(); |
| 3441 } |
| 3442 if (_json.containsKey("type")) { |
| 3443 type = _json["type"]; |
| 3444 } |
| 3445 if (_json.containsKey("value")) { |
| 3446 value = _json["value"]; |
| 3447 } |
| 3448 } |
| 3449 |
| 3450 core.Map toJson() { |
| 3451 var _json = new core.Map(); |
| 3452 if (key != null) { |
| 3453 _json["key"] = key; |
| 3454 } |
| 3455 if (list != null) { |
| 3456 _json["list"] = list.map((value) => (value).toJson()).toList(); |
| 3457 } |
| 3458 if (map != null) { |
| 3459 _json["map"] = map.map((value) => (value).toJson()).toList(); |
| 3460 } |
| 3461 if (type != null) { |
| 3462 _json["type"] = type; |
| 3463 } |
| 3464 if (value != null) { |
| 3465 _json["value"] = value; |
| 3466 } |
| 3467 return _json; |
| 3468 } |
| 3469 } |
| 3470 |
| 3471 |
| 3472 /** Publish container version response. */ |
| 3473 class PublishContainerVersionResponse { |
| 3474 /** Compiler errors or not. */ |
| 3475 core.bool compilerError; |
| 3476 |
| 3477 /** The container version created. */ |
| 3478 ContainerVersion containerVersion; |
| 3479 |
| 3480 |
| 3481 PublishContainerVersionResponse(); |
| 3482 |
| 3483 PublishContainerVersionResponse.fromJson(core.Map _json) { |
| 3484 if (_json.containsKey("compilerError")) { |
| 3485 compilerError = _json["compilerError"]; |
| 3486 } |
| 3487 if (_json.containsKey("containerVersion")) { |
| 3488 containerVersion = new ContainerVersion.fromJson(_json["containerVersion"]
); |
| 3489 } |
| 3490 } |
| 3491 |
| 3492 core.Map toJson() { |
| 3493 var _json = new core.Map(); |
| 3494 if (compilerError != null) { |
| 3495 _json["compilerError"] = compilerError; |
| 3496 } |
| 3497 if (containerVersion != null) { |
| 3498 _json["containerVersion"] = (containerVersion).toJson(); |
| 3499 } |
| 3500 return _json; |
| 3501 } |
| 3502 } |
| 3503 |
| 3504 |
| 3505 /** Represents a Google Tag Manager Rule. */ |
| 3506 class Rule { |
| 3507 /** GTM Account ID. */ |
| 3508 core.String accountId; |
| 3509 |
| 3510 /** |
| 3511 * The list of conditions that make up this rule (implicit AND between them). |
| 3512 */ |
| 3513 core.List<Condition> condition; |
| 3514 |
| 3515 /** GTM Container ID. */ |
| 3516 core.String containerId; |
| 3517 |
| 3518 /** |
| 3519 * The fingerprint of the GTM Rule as computed at storage time. This value is |
| 3520 * recomputed whenever the rule is modified. |
| 3521 */ |
| 3522 core.String fingerprint; |
| 3523 |
| 3524 /** Rule display name. */ |
| 3525 core.String name; |
| 3526 |
| 3527 /** User notes on how to apply this rule in the container. */ |
| 3528 core.String notes; |
| 3529 |
| 3530 /** The Rule ID uniquely identifies the GTM Rule. */ |
| 3531 core.String ruleId; |
| 3532 |
| 3533 |
| 3534 Rule(); |
| 3535 |
| 3536 Rule.fromJson(core.Map _json) { |
| 3537 if (_json.containsKey("accountId")) { |
| 3538 accountId = _json["accountId"]; |
| 3539 } |
| 3540 if (_json.containsKey("condition")) { |
| 3541 condition = _json["condition"].map((value) => new Condition.fromJson(value
)).toList(); |
| 3542 } |
| 3543 if (_json.containsKey("containerId")) { |
| 3544 containerId = _json["containerId"]; |
| 3545 } |
| 3546 if (_json.containsKey("fingerprint")) { |
| 3547 fingerprint = _json["fingerprint"]; |
| 3548 } |
| 3549 if (_json.containsKey("name")) { |
| 3550 name = _json["name"]; |
| 3551 } |
| 3552 if (_json.containsKey("notes")) { |
| 3553 notes = _json["notes"]; |
| 3554 } |
| 3555 if (_json.containsKey("ruleId")) { |
| 3556 ruleId = _json["ruleId"]; |
| 3557 } |
| 3558 } |
| 3559 |
| 3560 core.Map toJson() { |
| 3561 var _json = new core.Map(); |
| 3562 if (accountId != null) { |
| 3563 _json["accountId"] = accountId; |
| 3564 } |
| 3565 if (condition != null) { |
| 3566 _json["condition"] = condition.map((value) => (value).toJson()).toList(); |
| 3567 } |
| 3568 if (containerId != null) { |
| 3569 _json["containerId"] = containerId; |
| 3570 } |
| 3571 if (fingerprint != null) { |
| 3572 _json["fingerprint"] = fingerprint; |
| 3573 } |
| 3574 if (name != null) { |
| 3575 _json["name"] = name; |
| 3576 } |
| 3577 if (notes != null) { |
| 3578 _json["notes"] = notes; |
| 3579 } |
| 3580 if (ruleId != null) { |
| 3581 _json["ruleId"] = ruleId; |
| 3582 } |
| 3583 return _json; |
| 3584 } |
| 3585 } |
| 3586 |
| 3587 |
| 3588 /** Represents a Google Tag Manager Tag. */ |
| 3589 class Tag { |
| 3590 /** GTM Account ID. */ |
| 3591 core.String accountId; |
| 3592 |
| 3593 /** |
| 3594 * Blocking rule IDs. If any of the listed rules evaluate to true, the tag |
| 3595 * will not fire. |
| 3596 */ |
| 3597 core.List<core.String> blockingRuleId; |
| 3598 |
| 3599 /** |
| 3600 * Blocking trigger IDs. If any of the listed triggers evaluate to true, the |
| 3601 * tag will not fire. |
| 3602 */ |
| 3603 core.List<core.String> blockingTriggerId; |
| 3604 |
| 3605 /** GTM Container ID. */ |
| 3606 core.String containerId; |
| 3607 |
| 3608 /** |
| 3609 * An optional list of tag names that this tag depends on to fire. Execution |
| 3610 * of this tag will be prevented until the tags with the given names complete |
| 3611 * their execution. |
| 3612 */ |
| 3613 Parameter dependencies; |
| 3614 |
| 3615 /** |
| 3616 * The fingerprint of the GTM Tag as computed at storage time. This value is |
| 3617 * recomputed whenever the tag is modified. |
| 3618 */ |
| 3619 core.String fingerprint; |
| 3620 |
| 3621 /** |
| 3622 * Firing rule IDs. A tag will fire when any of the listed rules are true and |
| 3623 * all of its blockingRuleIds (if any specified) are false. |
| 3624 */ |
| 3625 core.List<core.String> firingRuleId; |
| 3626 |
| 3627 /** |
| 3628 * Firing trigger IDs. A tag will fire when any of the listed triggers are |
| 3629 * true and all of its blockingTriggerIds (if any specified) are false. |
| 3630 */ |
| 3631 core.List<core.String> firingTriggerId; |
| 3632 |
| 3633 /** |
| 3634 * If set to true, this tag will only fire in the live environment (e.g. not |
| 3635 * in preview or debug mode). |
| 3636 */ |
| 3637 core.bool liveOnly; |
| 3638 |
| 3639 /** Tag display name. */ |
| 3640 core.String name; |
| 3641 |
| 3642 /** User notes on how to apply this tag in the container. */ |
| 3643 core.String notes; |
| 3644 |
| 3645 /** The tag's parameters. */ |
| 3646 core.List<Parameter> parameter; |
| 3647 |
| 3648 /** |
| 3649 * User defined numeric priority of the tag. Tags are fired asynchronously in |
| 3650 * order of priority. Tags with higher numeric value fire first. A tag's |
| 3651 * priority can be a positive or negative value. The default value is 0. |
| 3652 */ |
| 3653 Parameter priority; |
| 3654 |
| 3655 /** The end timestamp in milliseconds to schedule a tag. */ |
| 3656 core.String scheduleEndMs; |
| 3657 |
| 3658 /** The start timestamp in milliseconds to schedule a tag. */ |
| 3659 core.String scheduleStartMs; |
| 3660 |
| 3661 /** The Tag ID uniquely identifies the GTM Tag. */ |
| 3662 core.String tagId; |
| 3663 |
| 3664 /** GTM Tag Type. */ |
| 3665 core.String type; |
| 3666 |
| 3667 |
| 3668 Tag(); |
| 3669 |
| 3670 Tag.fromJson(core.Map _json) { |
| 3671 if (_json.containsKey("accountId")) { |
| 3672 accountId = _json["accountId"]; |
| 3673 } |
| 3674 if (_json.containsKey("blockingRuleId")) { |
| 3675 blockingRuleId = _json["blockingRuleId"]; |
| 3676 } |
| 3677 if (_json.containsKey("blockingTriggerId")) { |
| 3678 blockingTriggerId = _json["blockingTriggerId"]; |
| 3679 } |
| 3680 if (_json.containsKey("containerId")) { |
| 3681 containerId = _json["containerId"]; |
| 3682 } |
| 3683 if (_json.containsKey("dependencies")) { |
| 3684 dependencies = new Parameter.fromJson(_json["dependencies"]); |
| 3685 } |
| 3686 if (_json.containsKey("fingerprint")) { |
| 3687 fingerprint = _json["fingerprint"]; |
| 3688 } |
| 3689 if (_json.containsKey("firingRuleId")) { |
| 3690 firingRuleId = _json["firingRuleId"]; |
| 3691 } |
| 3692 if (_json.containsKey("firingTriggerId")) { |
| 3693 firingTriggerId = _json["firingTriggerId"]; |
| 3694 } |
| 3695 if (_json.containsKey("liveOnly")) { |
| 3696 liveOnly = _json["liveOnly"]; |
| 3697 } |
| 3698 if (_json.containsKey("name")) { |
| 3699 name = _json["name"]; |
| 3700 } |
| 3701 if (_json.containsKey("notes")) { |
| 3702 notes = _json["notes"]; |
| 3703 } |
| 3704 if (_json.containsKey("parameter")) { |
| 3705 parameter = _json["parameter"].map((value) => new Parameter.fromJson(value
)).toList(); |
| 3706 } |
| 3707 if (_json.containsKey("priority")) { |
| 3708 priority = new Parameter.fromJson(_json["priority"]); |
| 3709 } |
| 3710 if (_json.containsKey("scheduleEndMs")) { |
| 3711 scheduleEndMs = _json["scheduleEndMs"]; |
| 3712 } |
| 3713 if (_json.containsKey("scheduleStartMs")) { |
| 3714 scheduleStartMs = _json["scheduleStartMs"]; |
| 3715 } |
| 3716 if (_json.containsKey("tagId")) { |
| 3717 tagId = _json["tagId"]; |
| 3718 } |
| 3719 if (_json.containsKey("type")) { |
| 3720 type = _json["type"]; |
| 3721 } |
| 3722 } |
| 3723 |
| 3724 core.Map toJson() { |
| 3725 var _json = new core.Map(); |
| 3726 if (accountId != null) { |
| 3727 _json["accountId"] = accountId; |
| 3728 } |
| 3729 if (blockingRuleId != null) { |
| 3730 _json["blockingRuleId"] = blockingRuleId; |
| 3731 } |
| 3732 if (blockingTriggerId != null) { |
| 3733 _json["blockingTriggerId"] = blockingTriggerId; |
| 3734 } |
| 3735 if (containerId != null) { |
| 3736 _json["containerId"] = containerId; |
| 3737 } |
| 3738 if (dependencies != null) { |
| 3739 _json["dependencies"] = (dependencies).toJson(); |
| 3740 } |
| 3741 if (fingerprint != null) { |
| 3742 _json["fingerprint"] = fingerprint; |
| 3743 } |
| 3744 if (firingRuleId != null) { |
| 3745 _json["firingRuleId"] = firingRuleId; |
| 3746 } |
| 3747 if (firingTriggerId != null) { |
| 3748 _json["firingTriggerId"] = firingTriggerId; |
| 3749 } |
| 3750 if (liveOnly != null) { |
| 3751 _json["liveOnly"] = liveOnly; |
| 3752 } |
| 3753 if (name != null) { |
| 3754 _json["name"] = name; |
| 3755 } |
| 3756 if (notes != null) { |
| 3757 _json["notes"] = notes; |
| 3758 } |
| 3759 if (parameter != null) { |
| 3760 _json["parameter"] = parameter.map((value) => (value).toJson()).toList(); |
| 3761 } |
| 3762 if (priority != null) { |
| 3763 _json["priority"] = (priority).toJson(); |
| 3764 } |
| 3765 if (scheduleEndMs != null) { |
| 3766 _json["scheduleEndMs"] = scheduleEndMs; |
| 3767 } |
| 3768 if (scheduleStartMs != null) { |
| 3769 _json["scheduleStartMs"] = scheduleStartMs; |
| 3770 } |
| 3771 if (tagId != null) { |
| 3772 _json["tagId"] = tagId; |
| 3773 } |
| 3774 if (type != null) { |
| 3775 _json["type"] = type; |
| 3776 } |
| 3777 return _json; |
| 3778 } |
| 3779 } |
| 3780 |
| 3781 |
| 3782 /** Represents a Google Tag Manager Trigger */ |
| 3783 class Trigger { |
| 3784 /** GTM Account ID. */ |
| 3785 core.String accountId; |
| 3786 |
| 3787 /** Used in the case of auto event tracking. */ |
| 3788 core.List<Condition> autoEventFilter; |
| 3789 |
| 3790 /** |
| 3791 * Whether or not we should only fire tags if the form submit or link click |
| 3792 * event is not cancelled by some other event handler (e.g. because of |
| 3793 * validation). Only valid for Form Submission and Link Click triggers. |
| 3794 */ |
| 3795 Parameter checkValidation; |
| 3796 |
| 3797 /** GTM Container ID. */ |
| 3798 core.String containerId; |
| 3799 |
| 3800 /** |
| 3801 * Used in the case of custom event, which is fired iff all Conditions are |
| 3802 * true. |
| 3803 */ |
| 3804 core.List<Condition> customEventFilter; |
| 3805 |
| 3806 /** |
| 3807 * Reloads the videos in the page that don't already have the YT API enabled. |
| 3808 * If false, only capture events from videos that already have the API |
| 3809 * enabled. Only valid for YouTube triggers. |
| 3810 */ |
| 3811 Parameter enableAllVideos; |
| 3812 |
| 3813 /** Name of the GTM event that is fired. Only valid for Timer triggers. */ |
| 3814 Parameter eventName; |
| 3815 |
| 3816 /** The trigger will only fire iff all Conditions are true. */ |
| 3817 core.List<Condition> filter; |
| 3818 |
| 3819 /** |
| 3820 * The fingerprint of the GTM Trigger as computed at storage time. This value |
| 3821 * is recomputed whenever the trigger is modified. |
| 3822 */ |
| 3823 core.String fingerprint; |
| 3824 |
| 3825 /** |
| 3826 * Time between triggering recurring Timer Events (in milliseconds). Only |
| 3827 * valid for Timer triggers. |
| 3828 */ |
| 3829 Parameter interval; |
| 3830 |
| 3831 /** |
| 3832 * Limit of the number of GTM events this Timer Trigger will fire. If no limit |
| 3833 * is set, we will continue to fire GTM events until the user leaves the page. |
| 3834 * Only valid for Timer triggers. |
| 3835 */ |
| 3836 Parameter limit; |
| 3837 |
| 3838 /** Trigger display name. */ |
| 3839 core.String name; |
| 3840 |
| 3841 /** The Trigger ID uniquely identifies the GTM Trigger. */ |
| 3842 core.String triggerId; |
| 3843 |
| 3844 /** |
| 3845 * Defines the data layer event that causes this trigger. |
| 3846 * Possible string values are: |
| 3847 * - "ajaxSubmission" |
| 3848 * - "always" |
| 3849 * - "click" |
| 3850 * - "customEvent" |
| 3851 * - "domReady" |
| 3852 * - "formSubmission" |
| 3853 * - "historyChange" |
| 3854 * - "jsError" |
| 3855 * - "linkClick" |
| 3856 * - "pageview" |
| 3857 * - "timer" |
| 3858 * - "windowLoaded" |
| 3859 * - "youTube" |
| 3860 */ |
| 3861 core.String type; |
| 3862 |
| 3863 /** |
| 3864 * Globally unique id of the trigger that auto-generates this Form Submit or |
| 3865 * Link Click listeners if any. Used to make incompatible auto-events work |
| 3866 * together with trigger filtering based on trigger ids. This value is |
| 3867 * populated during output generation since the tags implied by triggers don't |
| 3868 * exist until then. Only valid for Form Submission and Link Click triggers. |
| 3869 */ |
| 3870 Parameter uniqueTriggerId; |
| 3871 |
| 3872 /** |
| 3873 * List of integer percentage values. The trigger will fire as each percentage |
| 3874 * is reached in any instrumented videos. Only valid for YouTube triggers. |
| 3875 */ |
| 3876 Parameter videoPercentageList; |
| 3877 |
| 3878 /** |
| 3879 * Whether or not we should delay the form submissions or link opening until |
| 3880 * all of the tags have fired (by preventing the default action and later |
| 3881 * simulating the default action). Only valid for Form Submission and Link |
| 3882 * Click triggers. |
| 3883 */ |
| 3884 Parameter waitForTags; |
| 3885 |
| 3886 /** |
| 3887 * How long to wait (in milliseconds) for tags to fire when 'waits_for_tags' |
| 3888 * above evaluates to true. Only valid for Form Submission and Link Click |
| 3889 * triggers. |
| 3890 */ |
| 3891 Parameter waitForTagsTimeout; |
| 3892 |
| 3893 |
| 3894 Trigger(); |
| 3895 |
| 3896 Trigger.fromJson(core.Map _json) { |
| 3897 if (_json.containsKey("accountId")) { |
| 3898 accountId = _json["accountId"]; |
| 3899 } |
| 3900 if (_json.containsKey("autoEventFilter")) { |
| 3901 autoEventFilter = _json["autoEventFilter"].map((value) => new Condition.fr
omJson(value)).toList(); |
| 3902 } |
| 3903 if (_json.containsKey("checkValidation")) { |
| 3904 checkValidation = new Parameter.fromJson(_json["checkValidation"]); |
| 3905 } |
| 3906 if (_json.containsKey("containerId")) { |
| 3907 containerId = _json["containerId"]; |
| 3908 } |
| 3909 if (_json.containsKey("customEventFilter")) { |
| 3910 customEventFilter = _json["customEventFilter"].map((value) => new Conditio
n.fromJson(value)).toList(); |
| 3911 } |
| 3912 if (_json.containsKey("enableAllVideos")) { |
| 3913 enableAllVideos = new Parameter.fromJson(_json["enableAllVideos"]); |
| 3914 } |
| 3915 if (_json.containsKey("eventName")) { |
| 3916 eventName = new Parameter.fromJson(_json["eventName"]); |
| 3917 } |
| 3918 if (_json.containsKey("filter")) { |
| 3919 filter = _json["filter"].map((value) => new Condition.fromJson(value)).toL
ist(); |
| 3920 } |
| 3921 if (_json.containsKey("fingerprint")) { |
| 3922 fingerprint = _json["fingerprint"]; |
| 3923 } |
| 3924 if (_json.containsKey("interval")) { |
| 3925 interval = new Parameter.fromJson(_json["interval"]); |
| 3926 } |
| 3927 if (_json.containsKey("limit")) { |
| 3928 limit = new Parameter.fromJson(_json["limit"]); |
| 3929 } |
| 3930 if (_json.containsKey("name")) { |
| 3931 name = _json["name"]; |
| 3932 } |
| 3933 if (_json.containsKey("triggerId")) { |
| 3934 triggerId = _json["triggerId"]; |
| 3935 } |
| 3936 if (_json.containsKey("type")) { |
| 3937 type = _json["type"]; |
| 3938 } |
| 3939 if (_json.containsKey("uniqueTriggerId")) { |
| 3940 uniqueTriggerId = new Parameter.fromJson(_json["uniqueTriggerId"]); |
| 3941 } |
| 3942 if (_json.containsKey("videoPercentageList")) { |
| 3943 videoPercentageList = new Parameter.fromJson(_json["videoPercentageList"])
; |
| 3944 } |
| 3945 if (_json.containsKey("waitForTags")) { |
| 3946 waitForTags = new Parameter.fromJson(_json["waitForTags"]); |
| 3947 } |
| 3948 if (_json.containsKey("waitForTagsTimeout")) { |
| 3949 waitForTagsTimeout = new Parameter.fromJson(_json["waitForTagsTimeout"]); |
| 3950 } |
| 3951 } |
| 3952 |
| 3953 core.Map toJson() { |
| 3954 var _json = new core.Map(); |
| 3955 if (accountId != null) { |
| 3956 _json["accountId"] = accountId; |
| 3957 } |
| 3958 if (autoEventFilter != null) { |
| 3959 _json["autoEventFilter"] = autoEventFilter.map((value) => (value).toJson()
).toList(); |
| 3960 } |
| 3961 if (checkValidation != null) { |
| 3962 _json["checkValidation"] = (checkValidation).toJson(); |
| 3963 } |
| 3964 if (containerId != null) { |
| 3965 _json["containerId"] = containerId; |
| 3966 } |
| 3967 if (customEventFilter != null) { |
| 3968 _json["customEventFilter"] = customEventFilter.map((value) => (value).toJs
on()).toList(); |
| 3969 } |
| 3970 if (enableAllVideos != null) { |
| 3971 _json["enableAllVideos"] = (enableAllVideos).toJson(); |
| 3972 } |
| 3973 if (eventName != null) { |
| 3974 _json["eventName"] = (eventName).toJson(); |
| 3975 } |
| 3976 if (filter != null) { |
| 3977 _json["filter"] = filter.map((value) => (value).toJson()).toList(); |
| 3978 } |
| 3979 if (fingerprint != null) { |
| 3980 _json["fingerprint"] = fingerprint; |
| 3981 } |
| 3982 if (interval != null) { |
| 3983 _json["interval"] = (interval).toJson(); |
| 3984 } |
| 3985 if (limit != null) { |
| 3986 _json["limit"] = (limit).toJson(); |
| 3987 } |
| 3988 if (name != null) { |
| 3989 _json["name"] = name; |
| 3990 } |
| 3991 if (triggerId != null) { |
| 3992 _json["triggerId"] = triggerId; |
| 3993 } |
| 3994 if (type != null) { |
| 3995 _json["type"] = type; |
| 3996 } |
| 3997 if (uniqueTriggerId != null) { |
| 3998 _json["uniqueTriggerId"] = (uniqueTriggerId).toJson(); |
| 3999 } |
| 4000 if (videoPercentageList != null) { |
| 4001 _json["videoPercentageList"] = (videoPercentageList).toJson(); |
| 4002 } |
| 4003 if (waitForTags != null) { |
| 4004 _json["waitForTags"] = (waitForTags).toJson(); |
| 4005 } |
| 4006 if (waitForTagsTimeout != null) { |
| 4007 _json["waitForTagsTimeout"] = (waitForTagsTimeout).toJson(); |
| 4008 } |
| 4009 return _json; |
| 4010 } |
| 4011 } |
| 4012 |
| 4013 |
| 4014 /** Represents a user's permissions to an account and its container. */ |
| 4015 class UserAccess { |
| 4016 /** GTM Account access permissions. */ |
| 4017 AccountAccess accountAccess; |
| 4018 |
| 4019 /** GTM Account ID. */ |
| 4020 core.String accountId; |
| 4021 |
| 4022 /** GTM Container access permissions. */ |
| 4023 core.List<ContainerAccess> containerAccess; |
| 4024 |
| 4025 /** User's email address. */ |
| 4026 core.String emailAddress; |
| 4027 |
| 4028 /** Account Permission ID. */ |
| 4029 core.String permissionId; |
| 4030 |
| 4031 |
| 4032 UserAccess(); |
| 4033 |
| 4034 UserAccess.fromJson(core.Map _json) { |
| 4035 if (_json.containsKey("accountAccess")) { |
| 4036 accountAccess = new AccountAccess.fromJson(_json["accountAccess"]); |
| 4037 } |
| 4038 if (_json.containsKey("accountId")) { |
| 4039 accountId = _json["accountId"]; |
| 4040 } |
| 4041 if (_json.containsKey("containerAccess")) { |
| 4042 containerAccess = _json["containerAccess"].map((value) => new ContainerAcc
ess.fromJson(value)).toList(); |
| 4043 } |
| 4044 if (_json.containsKey("emailAddress")) { |
| 4045 emailAddress = _json["emailAddress"]; |
| 4046 } |
| 4047 if (_json.containsKey("permissionId")) { |
| 4048 permissionId = _json["permissionId"]; |
| 4049 } |
| 4050 } |
| 4051 |
| 4052 core.Map toJson() { |
| 4053 var _json = new core.Map(); |
| 4054 if (accountAccess != null) { |
| 4055 _json["accountAccess"] = (accountAccess).toJson(); |
| 4056 } |
| 4057 if (accountId != null) { |
| 4058 _json["accountId"] = accountId; |
| 4059 } |
| 4060 if (containerAccess != null) { |
| 4061 _json["containerAccess"] = containerAccess.map((value) => (value).toJson()
).toList(); |
| 4062 } |
| 4063 if (emailAddress != null) { |
| 4064 _json["emailAddress"] = emailAddress; |
| 4065 } |
| 4066 if (permissionId != null) { |
| 4067 _json["permissionId"] = permissionId; |
| 4068 } |
| 4069 return _json; |
| 4070 } |
| 4071 } |
| 4072 |
| 4073 |
| 4074 /** Represents a Google Tag Manager Variable. */ |
| 4075 class Variable { |
| 4076 /** GTM Account ID. */ |
| 4077 core.String accountId; |
| 4078 |
| 4079 /** GTM Container ID. */ |
| 4080 core.String containerId; |
| 4081 |
| 4082 /** |
| 4083 * For mobile containers only: A list of trigger IDs for disabling conditional |
| 4084 * variables; the variable is enabled if one of the enabling trigger is true |
| 4085 * while all the disabling trigger are false. Treated as an unordered set. |
| 4086 */ |
| 4087 core.List<core.String> disablingTriggerId; |
| 4088 |
| 4089 /** |
| 4090 * For mobile containers only: A list of trigger IDs for enabling conditional |
| 4091 * variables; the variable is enabled if one of the enabling triggers is true |
| 4092 * while all the disabling triggers are false. Treated as an unordered set. |
| 4093 */ |
| 4094 core.List<core.String> enablingTriggerId; |
| 4095 |
| 4096 /** |
| 4097 * The fingerprint of the GTM Variable as computed at storage time. This value |
| 4098 * is recomputed whenever the variable is modified. |
| 4099 */ |
| 4100 core.String fingerprint; |
| 4101 |
| 4102 /** Variable display name. */ |
| 4103 core.String name; |
| 4104 |
| 4105 /** User notes on how to apply this variable in the container. */ |
| 4106 core.String notes; |
| 4107 |
| 4108 /** The variable's parameters. */ |
| 4109 core.List<Parameter> parameter; |
| 4110 |
| 4111 /** The end timestamp in milliseconds to schedule a variable. */ |
| 4112 core.String scheduleEndMs; |
| 4113 |
| 4114 /** The start timestamp in milliseconds to schedule a variable. */ |
| 4115 core.String scheduleStartMs; |
| 4116 |
| 4117 /** GTM Variable Type. */ |
| 4118 core.String type; |
| 4119 |
| 4120 /** The Variable ID uniquely identifies the GTM Variable. */ |
| 4121 core.String variableId; |
| 4122 |
| 4123 |
| 4124 Variable(); |
| 4125 |
| 4126 Variable.fromJson(core.Map _json) { |
| 4127 if (_json.containsKey("accountId")) { |
| 4128 accountId = _json["accountId"]; |
| 4129 } |
| 4130 if (_json.containsKey("containerId")) { |
| 4131 containerId = _json["containerId"]; |
| 4132 } |
| 4133 if (_json.containsKey("disablingTriggerId")) { |
| 4134 disablingTriggerId = _json["disablingTriggerId"]; |
| 4135 } |
| 4136 if (_json.containsKey("enablingTriggerId")) { |
| 4137 enablingTriggerId = _json["enablingTriggerId"]; |
| 4138 } |
| 4139 if (_json.containsKey("fingerprint")) { |
| 4140 fingerprint = _json["fingerprint"]; |
| 4141 } |
| 4142 if (_json.containsKey("name")) { |
| 4143 name = _json["name"]; |
| 4144 } |
| 4145 if (_json.containsKey("notes")) { |
| 4146 notes = _json["notes"]; |
| 4147 } |
| 4148 if (_json.containsKey("parameter")) { |
| 4149 parameter = _json["parameter"].map((value) => new Parameter.fromJson(value
)).toList(); |
| 4150 } |
| 4151 if (_json.containsKey("scheduleEndMs")) { |
| 4152 scheduleEndMs = _json["scheduleEndMs"]; |
| 4153 } |
| 4154 if (_json.containsKey("scheduleStartMs")) { |
| 4155 scheduleStartMs = _json["scheduleStartMs"]; |
| 4156 } |
| 4157 if (_json.containsKey("type")) { |
| 4158 type = _json["type"]; |
| 4159 } |
| 4160 if (_json.containsKey("variableId")) { |
| 4161 variableId = _json["variableId"]; |
| 4162 } |
| 4163 } |
| 4164 |
| 4165 core.Map toJson() { |
| 4166 var _json = new core.Map(); |
| 4167 if (accountId != null) { |
| 4168 _json["accountId"] = accountId; |
| 4169 } |
| 4170 if (containerId != null) { |
| 4171 _json["containerId"] = containerId; |
| 4172 } |
| 4173 if (disablingTriggerId != null) { |
| 4174 _json["disablingTriggerId"] = disablingTriggerId; |
| 4175 } |
| 4176 if (enablingTriggerId != null) { |
| 4177 _json["enablingTriggerId"] = enablingTriggerId; |
| 4178 } |
| 4179 if (fingerprint != null) { |
| 4180 _json["fingerprint"] = fingerprint; |
| 4181 } |
| 4182 if (name != null) { |
| 4183 _json["name"] = name; |
| 4184 } |
| 4185 if (notes != null) { |
| 4186 _json["notes"] = notes; |
| 4187 } |
| 4188 if (parameter != null) { |
| 4189 _json["parameter"] = parameter.map((value) => (value).toJson()).toList(); |
| 4190 } |
| 4191 if (scheduleEndMs != null) { |
| 4192 _json["scheduleEndMs"] = scheduleEndMs; |
| 4193 } |
| 4194 if (scheduleStartMs != null) { |
| 4195 _json["scheduleStartMs"] = scheduleStartMs; |
| 4196 } |
| 4197 if (type != null) { |
| 4198 _json["type"] = type; |
| 4199 } |
| 4200 if (variableId != null) { |
| 4201 _json["variableId"] = variableId; |
| 4202 } |
| 4203 return _json; |
| 4204 } |
| 4205 } |
| 4206 |
| 4207 |
OLD | NEW |