OLD | NEW |
| (Empty) |
1 // This is a generated file (see the discoveryapis_generator project). | |
2 | |
3 library googleapis.dfareporting.v2_3; | |
4 | |
5 import 'dart:core' as core; | |
6 import 'dart:async' as async; | |
7 import 'dart:convert' as convert; | |
8 | |
9 import 'package:_discoveryapis_commons/_discoveryapis_commons.dart' as commons; | |
10 import 'package:http/http.dart' as http; | |
11 | |
12 export 'package:_discoveryapis_commons/_discoveryapis_commons.dart' show | |
13 ApiRequestError, DetailedApiRequestError, Media, UploadOptions, | |
14 ResumableUploadOptions, DownloadOptions, PartialDownloadOptions, | |
15 ByteRange; | |
16 | |
17 const core.String USER_AGENT = 'dart-api-client dfareporting/v2.3'; | |
18 | |
19 /** Manages your DoubleClick Campaign Manager ad campaigns and reports. */ | |
20 class DfareportingApi { | |
21 /** View and manage DoubleClick for Advertisers reports */ | |
22 static const DfareportingScope = "https://www.googleapis.com/auth/dfareporting
"; | |
23 | |
24 /** | |
25 * View and manage your DoubleClick Campaign Manager's (DCM) display ad | |
26 * campaigns | |
27 */ | |
28 static const DfatraffickingScope = "https://www.googleapis.com/auth/dfatraffic
king"; | |
29 | |
30 | |
31 final commons.ApiRequester _requester; | |
32 | |
33 AccountActiveAdSummariesResourceApi get accountActiveAdSummaries => new Accoun
tActiveAdSummariesResourceApi(_requester); | |
34 AccountPermissionGroupsResourceApi get accountPermissionGroups => new AccountP
ermissionGroupsResourceApi(_requester); | |
35 AccountPermissionsResourceApi get accountPermissions => new AccountPermissions
ResourceApi(_requester); | |
36 AccountUserProfilesResourceApi get accountUserProfiles => new AccountUserProfi
lesResourceApi(_requester); | |
37 AccountsResourceApi get accounts => new AccountsResourceApi(_requester); | |
38 AdsResourceApi get ads => new AdsResourceApi(_requester); | |
39 AdvertiserGroupsResourceApi get advertiserGroups => new AdvertiserGroupsResour
ceApi(_requester); | |
40 AdvertisersResourceApi get advertisers => new AdvertisersResourceApi(_requeste
r); | |
41 BrowsersResourceApi get browsers => new BrowsersResourceApi(_requester); | |
42 CampaignCreativeAssociationsResourceApi get campaignCreativeAssociations => ne
w CampaignCreativeAssociationsResourceApi(_requester); | |
43 CampaignsResourceApi get campaigns => new CampaignsResourceApi(_requester); | |
44 ChangeLogsResourceApi get changeLogs => new ChangeLogsResourceApi(_requester); | |
45 CitiesResourceApi get cities => new CitiesResourceApi(_requester); | |
46 ConnectionTypesResourceApi get connectionTypes => new ConnectionTypesResourceA
pi(_requester); | |
47 ContentCategoriesResourceApi get contentCategories => new ContentCategoriesRes
ourceApi(_requester); | |
48 CountriesResourceApi get countries => new CountriesResourceApi(_requester); | |
49 CreativeAssetsResourceApi get creativeAssets => new CreativeAssetsResourceApi(
_requester); | |
50 CreativeFieldValuesResourceApi get creativeFieldValues => new CreativeFieldVal
uesResourceApi(_requester); | |
51 CreativeFieldsResourceApi get creativeFields => new CreativeFieldsResourceApi(
_requester); | |
52 CreativeGroupsResourceApi get creativeGroups => new CreativeGroupsResourceApi(
_requester); | |
53 CreativesResourceApi get creatives => new CreativesResourceApi(_requester); | |
54 DimensionValuesResourceApi get dimensionValues => new DimensionValuesResourceA
pi(_requester); | |
55 DirectorySiteContactsResourceApi get directorySiteContacts => new DirectorySit
eContactsResourceApi(_requester); | |
56 DirectorySitesResourceApi get directorySites => new DirectorySitesResourceApi(
_requester); | |
57 EventTagsResourceApi get eventTags => new EventTagsResourceApi(_requester); | |
58 FilesResourceApi get files => new FilesResourceApi(_requester); | |
59 FloodlightActivitiesResourceApi get floodlightActivities => new FloodlightActi
vitiesResourceApi(_requester); | |
60 FloodlightActivityGroupsResourceApi get floodlightActivityGroups => new Floodl
ightActivityGroupsResourceApi(_requester); | |
61 FloodlightConfigurationsResourceApi get floodlightConfigurations => new Floodl
ightConfigurationsResourceApi(_requester); | |
62 InventoryItemsResourceApi get inventoryItems => new InventoryItemsResourceApi(
_requester); | |
63 LandingPagesResourceApi get landingPages => new LandingPagesResourceApi(_reque
ster); | |
64 MetrosResourceApi get metros => new MetrosResourceApi(_requester); | |
65 MobileCarriersResourceApi get mobileCarriers => new MobileCarriersResourceApi(
_requester); | |
66 OperatingSystemVersionsResourceApi get operatingSystemVersions => new Operatin
gSystemVersionsResourceApi(_requester); | |
67 OperatingSystemsResourceApi get operatingSystems => new OperatingSystemsResour
ceApi(_requester); | |
68 OrderDocumentsResourceApi get orderDocuments => new OrderDocumentsResourceApi(
_requester); | |
69 OrdersResourceApi get orders => new OrdersResourceApi(_requester); | |
70 PlacementGroupsResourceApi get placementGroups => new PlacementGroupsResourceA
pi(_requester); | |
71 PlacementStrategiesResourceApi get placementStrategies => new PlacementStrateg
iesResourceApi(_requester); | |
72 PlacementsResourceApi get placements => new PlacementsResourceApi(_requester); | |
73 PlatformTypesResourceApi get platformTypes => new PlatformTypesResourceApi(_re
quester); | |
74 PostalCodesResourceApi get postalCodes => new PostalCodesResourceApi(_requeste
r); | |
75 ProjectsResourceApi get projects => new ProjectsResourceApi(_requester); | |
76 RegionsResourceApi get regions => new RegionsResourceApi(_requester); | |
77 RemarketingListSharesResourceApi get remarketingListShares => new RemarketingL
istSharesResourceApi(_requester); | |
78 RemarketingListsResourceApi get remarketingLists => new RemarketingListsResour
ceApi(_requester); | |
79 ReportsResourceApi get reports => new ReportsResourceApi(_requester); | |
80 SitesResourceApi get sites => new SitesResourceApi(_requester); | |
81 SizesResourceApi get sizes => new SizesResourceApi(_requester); | |
82 SubaccountsResourceApi get subaccounts => new SubaccountsResourceApi(_requeste
r); | |
83 TargetableRemarketingListsResourceApi get targetableRemarketingLists => new Ta
rgetableRemarketingListsResourceApi(_requester); | |
84 UserProfilesResourceApi get userProfiles => new UserProfilesResourceApi(_reque
ster); | |
85 UserRolePermissionGroupsResourceApi get userRolePermissionGroups => new UserRo
lePermissionGroupsResourceApi(_requester); | |
86 UserRolePermissionsResourceApi get userRolePermissions => new UserRolePermissi
onsResourceApi(_requester); | |
87 UserRolesResourceApi get userRoles => new UserRolesResourceApi(_requester); | |
88 | |
89 DfareportingApi(http.Client client, {core.String rootUrl: "https://www.googlea
pis.com/", core.String servicePath: "dfareporting/v2.3/"}) : | |
90 _requester = new commons.ApiRequester(client, rootUrl, servicePath, USER_A
GENT); | |
91 } | |
92 | |
93 | |
94 class AccountActiveAdSummariesResourceApi { | |
95 final commons.ApiRequester _requester; | |
96 | |
97 AccountActiveAdSummariesResourceApi(commons.ApiRequester client) : | |
98 _requester = client; | |
99 | |
100 /** | |
101 * Gets the account's active ad summary by account ID. | |
102 * | |
103 * Request parameters: | |
104 * | |
105 * [profileId] - User profile ID associated with this request. | |
106 * | |
107 * [summaryAccountId] - Account ID. | |
108 * | |
109 * Completes with a [AccountActiveAdSummary]. | |
110 * | |
111 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
112 * error. | |
113 * | |
114 * If the used [http.Client] completes with an error when making a REST call, | |
115 * this method will complete with the same error. | |
116 */ | |
117 async.Future<AccountActiveAdSummary> get(core.String profileId, core.String su
mmaryAccountId) { | |
118 var _url = null; | |
119 var _queryParams = new core.Map(); | |
120 var _uploadMedia = null; | |
121 var _uploadOptions = null; | |
122 var _downloadOptions = commons.DownloadOptions.Metadata; | |
123 var _body = null; | |
124 | |
125 if (profileId == null) { | |
126 throw new core.ArgumentError("Parameter profileId is required."); | |
127 } | |
128 if (summaryAccountId == null) { | |
129 throw new core.ArgumentError("Parameter summaryAccountId is required."); | |
130 } | |
131 | |
132 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/acc
ountActiveAdSummaries/' + commons.Escaper.ecapeVariable('$summaryAccountId'); | |
133 | |
134 var _response = _requester.request(_url, | |
135 "GET", | |
136 body: _body, | |
137 queryParams: _queryParams, | |
138 uploadOptions: _uploadOptions, | |
139 uploadMedia: _uploadMedia, | |
140 downloadOptions: _downloadOptions); | |
141 return _response.then((data) => new AccountActiveAdSummary.fromJson(data)); | |
142 } | |
143 | |
144 } | |
145 | |
146 | |
147 class AccountPermissionGroupsResourceApi { | |
148 final commons.ApiRequester _requester; | |
149 | |
150 AccountPermissionGroupsResourceApi(commons.ApiRequester client) : | |
151 _requester = client; | |
152 | |
153 /** | |
154 * Gets one account permission group by ID. | |
155 * | |
156 * Request parameters: | |
157 * | |
158 * [profileId] - User profile ID associated with this request. | |
159 * | |
160 * [id] - Account permission group ID. | |
161 * | |
162 * Completes with a [AccountPermissionGroup]. | |
163 * | |
164 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
165 * error. | |
166 * | |
167 * If the used [http.Client] completes with an error when making a REST call, | |
168 * this method will complete with the same error. | |
169 */ | |
170 async.Future<AccountPermissionGroup> get(core.String profileId, core.String id
) { | |
171 var _url = null; | |
172 var _queryParams = new core.Map(); | |
173 var _uploadMedia = null; | |
174 var _uploadOptions = null; | |
175 var _downloadOptions = commons.DownloadOptions.Metadata; | |
176 var _body = null; | |
177 | |
178 if (profileId == null) { | |
179 throw new core.ArgumentError("Parameter profileId is required."); | |
180 } | |
181 if (id == null) { | |
182 throw new core.ArgumentError("Parameter id is required."); | |
183 } | |
184 | |
185 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/acc
ountPermissionGroups/' + commons.Escaper.ecapeVariable('$id'); | |
186 | |
187 var _response = _requester.request(_url, | |
188 "GET", | |
189 body: _body, | |
190 queryParams: _queryParams, | |
191 uploadOptions: _uploadOptions, | |
192 uploadMedia: _uploadMedia, | |
193 downloadOptions: _downloadOptions); | |
194 return _response.then((data) => new AccountPermissionGroup.fromJson(data)); | |
195 } | |
196 | |
197 /** | |
198 * Retrieves the list of account permission groups. | |
199 * | |
200 * Request parameters: | |
201 * | |
202 * [profileId] - User profile ID associated with this request. | |
203 * | |
204 * Completes with a [AccountPermissionGroupsListResponse]. | |
205 * | |
206 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
207 * error. | |
208 * | |
209 * If the used [http.Client] completes with an error when making a REST call, | |
210 * this method will complete with the same error. | |
211 */ | |
212 async.Future<AccountPermissionGroupsListResponse> list(core.String profileId)
{ | |
213 var _url = null; | |
214 var _queryParams = new core.Map(); | |
215 var _uploadMedia = null; | |
216 var _uploadOptions = null; | |
217 var _downloadOptions = commons.DownloadOptions.Metadata; | |
218 var _body = null; | |
219 | |
220 if (profileId == null) { | |
221 throw new core.ArgumentError("Parameter profileId is required."); | |
222 } | |
223 | |
224 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/acc
ountPermissionGroups'; | |
225 | |
226 var _response = _requester.request(_url, | |
227 "GET", | |
228 body: _body, | |
229 queryParams: _queryParams, | |
230 uploadOptions: _uploadOptions, | |
231 uploadMedia: _uploadMedia, | |
232 downloadOptions: _downloadOptions); | |
233 return _response.then((data) => new AccountPermissionGroupsListResponse.from
Json(data)); | |
234 } | |
235 | |
236 } | |
237 | |
238 | |
239 class AccountPermissionsResourceApi { | |
240 final commons.ApiRequester _requester; | |
241 | |
242 AccountPermissionsResourceApi(commons.ApiRequester client) : | |
243 _requester = client; | |
244 | |
245 /** | |
246 * Gets one account permission by ID. | |
247 * | |
248 * Request parameters: | |
249 * | |
250 * [profileId] - User profile ID associated with this request. | |
251 * | |
252 * [id] - Account permission ID. | |
253 * | |
254 * Completes with a [AccountPermission]. | |
255 * | |
256 * Completes with a [commons.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<AccountPermission> get(core.String profileId, core.String id) { | |
263 var _url = null; | |
264 var _queryParams = new core.Map(); | |
265 var _uploadMedia = null; | |
266 var _uploadOptions = null; | |
267 var _downloadOptions = commons.DownloadOptions.Metadata; | |
268 var _body = null; | |
269 | |
270 if (profileId == null) { | |
271 throw new core.ArgumentError("Parameter profileId is required."); | |
272 } | |
273 if (id == null) { | |
274 throw new core.ArgumentError("Parameter id is required."); | |
275 } | |
276 | |
277 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/acc
ountPermissions/' + commons.Escaper.ecapeVariable('$id'); | |
278 | |
279 var _response = _requester.request(_url, | |
280 "GET", | |
281 body: _body, | |
282 queryParams: _queryParams, | |
283 uploadOptions: _uploadOptions, | |
284 uploadMedia: _uploadMedia, | |
285 downloadOptions: _downloadOptions); | |
286 return _response.then((data) => new AccountPermission.fromJson(data)); | |
287 } | |
288 | |
289 /** | |
290 * Retrieves the list of account permissions. | |
291 * | |
292 * Request parameters: | |
293 * | |
294 * [profileId] - User profile ID associated with this request. | |
295 * | |
296 * Completes with a [AccountPermissionsListResponse]. | |
297 * | |
298 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
299 * error. | |
300 * | |
301 * If the used [http.Client] completes with an error when making a REST call, | |
302 * this method will complete with the same error. | |
303 */ | |
304 async.Future<AccountPermissionsListResponse> list(core.String profileId) { | |
305 var _url = null; | |
306 var _queryParams = new core.Map(); | |
307 var _uploadMedia = null; | |
308 var _uploadOptions = null; | |
309 var _downloadOptions = commons.DownloadOptions.Metadata; | |
310 var _body = null; | |
311 | |
312 if (profileId == null) { | |
313 throw new core.ArgumentError("Parameter profileId is required."); | |
314 } | |
315 | |
316 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/acc
ountPermissions'; | |
317 | |
318 var _response = _requester.request(_url, | |
319 "GET", | |
320 body: _body, | |
321 queryParams: _queryParams, | |
322 uploadOptions: _uploadOptions, | |
323 uploadMedia: _uploadMedia, | |
324 downloadOptions: _downloadOptions); | |
325 return _response.then((data) => new AccountPermissionsListResponse.fromJson(
data)); | |
326 } | |
327 | |
328 } | |
329 | |
330 | |
331 class AccountUserProfilesResourceApi { | |
332 final commons.ApiRequester _requester; | |
333 | |
334 AccountUserProfilesResourceApi(commons.ApiRequester client) : | |
335 _requester = client; | |
336 | |
337 /** | |
338 * Gets one account user profile by ID. | |
339 * | |
340 * Request parameters: | |
341 * | |
342 * [profileId] - User profile ID associated with this request. | |
343 * | |
344 * [id] - User profile ID. | |
345 * | |
346 * Completes with a [AccountUserProfile]. | |
347 * | |
348 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
349 * error. | |
350 * | |
351 * If the used [http.Client] completes with an error when making a REST call, | |
352 * this method will complete with the same error. | |
353 */ | |
354 async.Future<AccountUserProfile> get(core.String profileId, core.String id) { | |
355 var _url = null; | |
356 var _queryParams = new core.Map(); | |
357 var _uploadMedia = null; | |
358 var _uploadOptions = null; | |
359 var _downloadOptions = commons.DownloadOptions.Metadata; | |
360 var _body = null; | |
361 | |
362 if (profileId == null) { | |
363 throw new core.ArgumentError("Parameter profileId is required."); | |
364 } | |
365 if (id == null) { | |
366 throw new core.ArgumentError("Parameter id is required."); | |
367 } | |
368 | |
369 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/acc
ountUserProfiles/' + commons.Escaper.ecapeVariable('$id'); | |
370 | |
371 var _response = _requester.request(_url, | |
372 "GET", | |
373 body: _body, | |
374 queryParams: _queryParams, | |
375 uploadOptions: _uploadOptions, | |
376 uploadMedia: _uploadMedia, | |
377 downloadOptions: _downloadOptions); | |
378 return _response.then((data) => new AccountUserProfile.fromJson(data)); | |
379 } | |
380 | |
381 /** | |
382 * Inserts a new account user profile. | |
383 * | |
384 * [request] - The metadata request object. | |
385 * | |
386 * Request parameters: | |
387 * | |
388 * [profileId] - User profile ID associated with this request. | |
389 * | |
390 * Completes with a [AccountUserProfile]. | |
391 * | |
392 * Completes with a [commons.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<AccountUserProfile> insert(AccountUserProfile request, core.Strin
g profileId) { | |
399 var _url = null; | |
400 var _queryParams = new core.Map(); | |
401 var _uploadMedia = null; | |
402 var _uploadOptions = null; | |
403 var _downloadOptions = commons.DownloadOptions.Metadata; | |
404 var _body = null; | |
405 | |
406 if (request != null) { | |
407 _body = convert.JSON.encode((request).toJson()); | |
408 } | |
409 if (profileId == null) { | |
410 throw new core.ArgumentError("Parameter profileId is required."); | |
411 } | |
412 | |
413 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/acc
ountUserProfiles'; | |
414 | |
415 var _response = _requester.request(_url, | |
416 "POST", | |
417 body: _body, | |
418 queryParams: _queryParams, | |
419 uploadOptions: _uploadOptions, | |
420 uploadMedia: _uploadMedia, | |
421 downloadOptions: _downloadOptions); | |
422 return _response.then((data) => new AccountUserProfile.fromJson(data)); | |
423 } | |
424 | |
425 /** | |
426 * Retrieves a list of account user profiles, possibly filtered. | |
427 * | |
428 * Request parameters: | |
429 * | |
430 * [profileId] - User profile ID associated with this request. | |
431 * | |
432 * [active] - Select only active user profiles. | |
433 * | |
434 * [ids] - Select only user profiles with these IDs. | |
435 * | |
436 * [maxResults] - Maximum number of results to return. | |
437 * | |
438 * [pageToken] - Value of the nextPageToken from the previous result page. | |
439 * | |
440 * [searchString] - Allows searching for objects by name, ID or email. | |
441 * Wildcards (*) are allowed. For example, "user profile*2015" will return | |
442 * objects with names like "user profile June 2015", "user profile April | |
443 * 2015", or simply "user profile 2015". Most of the searches also add | |
444 * wildcards implicitly at the start and the end of the search string. For | |
445 * example, a search string of "user profile" will match objects with name "my | |
446 * user profile", "user profile 2015", or simply "user profile". | |
447 * | |
448 * [sortField] - Field by which to sort the list. | |
449 * Possible string values are: | |
450 * - "ID" | |
451 * - "NAME" | |
452 * | |
453 * [sortOrder] - Order of sorted results, default is ASCENDING. | |
454 * Possible string values are: | |
455 * - "ASCENDING" | |
456 * - "DESCENDING" | |
457 * | |
458 * [subaccountId] - Select only user profiles with the specified subaccount | |
459 * ID. | |
460 * | |
461 * [userRoleId] - Select only user profiles with the specified user role ID. | |
462 * | |
463 * Completes with a [AccountUserProfilesListResponse]. | |
464 * | |
465 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
466 * error. | |
467 * | |
468 * If the used [http.Client] completes with an error when making a REST call, | |
469 * this method will complete with the same error. | |
470 */ | |
471 async.Future<AccountUserProfilesListResponse> list(core.String profileId, {cor
e.bool active, core.List<core.String> ids, core.int maxResults, core.String page
Token, core.String searchString, core.String sortField, core.String sortOrder, c
ore.String subaccountId, core.String userRoleId}) { | |
472 var _url = null; | |
473 var _queryParams = new core.Map(); | |
474 var _uploadMedia = null; | |
475 var _uploadOptions = null; | |
476 var _downloadOptions = commons.DownloadOptions.Metadata; | |
477 var _body = null; | |
478 | |
479 if (profileId == null) { | |
480 throw new core.ArgumentError("Parameter profileId is required."); | |
481 } | |
482 if (active != null) { | |
483 _queryParams["active"] = ["${active}"]; | |
484 } | |
485 if (ids != null) { | |
486 _queryParams["ids"] = ids; | |
487 } | |
488 if (maxResults != null) { | |
489 _queryParams["maxResults"] = ["${maxResults}"]; | |
490 } | |
491 if (pageToken != null) { | |
492 _queryParams["pageToken"] = [pageToken]; | |
493 } | |
494 if (searchString != null) { | |
495 _queryParams["searchString"] = [searchString]; | |
496 } | |
497 if (sortField != null) { | |
498 _queryParams["sortField"] = [sortField]; | |
499 } | |
500 if (sortOrder != null) { | |
501 _queryParams["sortOrder"] = [sortOrder]; | |
502 } | |
503 if (subaccountId != null) { | |
504 _queryParams["subaccountId"] = [subaccountId]; | |
505 } | |
506 if (userRoleId != null) { | |
507 _queryParams["userRoleId"] = [userRoleId]; | |
508 } | |
509 | |
510 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/acc
ountUserProfiles'; | |
511 | |
512 var _response = _requester.request(_url, | |
513 "GET", | |
514 body: _body, | |
515 queryParams: _queryParams, | |
516 uploadOptions: _uploadOptions, | |
517 uploadMedia: _uploadMedia, | |
518 downloadOptions: _downloadOptions); | |
519 return _response.then((data) => new AccountUserProfilesListResponse.fromJson
(data)); | |
520 } | |
521 | |
522 /** | |
523 * Updates an existing account user profile. This method supports patch | |
524 * semantics. | |
525 * | |
526 * [request] - The metadata request object. | |
527 * | |
528 * Request parameters: | |
529 * | |
530 * [profileId] - User profile ID associated with this request. | |
531 * | |
532 * [id] - User profile ID. | |
533 * | |
534 * Completes with a [AccountUserProfile]. | |
535 * | |
536 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
537 * error. | |
538 * | |
539 * If the used [http.Client] completes with an error when making a REST call, | |
540 * this method will complete with the same error. | |
541 */ | |
542 async.Future<AccountUserProfile> patch(AccountUserProfile request, core.String
profileId, core.String id) { | |
543 var _url = null; | |
544 var _queryParams = new core.Map(); | |
545 var _uploadMedia = null; | |
546 var _uploadOptions = null; | |
547 var _downloadOptions = commons.DownloadOptions.Metadata; | |
548 var _body = null; | |
549 | |
550 if (request != null) { | |
551 _body = convert.JSON.encode((request).toJson()); | |
552 } | |
553 if (profileId == null) { | |
554 throw new core.ArgumentError("Parameter profileId is required."); | |
555 } | |
556 if (id == null) { | |
557 throw new core.ArgumentError("Parameter id is required."); | |
558 } | |
559 _queryParams["id"] = [id]; | |
560 | |
561 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/acc
ountUserProfiles'; | |
562 | |
563 var _response = _requester.request(_url, | |
564 "PATCH", | |
565 body: _body, | |
566 queryParams: _queryParams, | |
567 uploadOptions: _uploadOptions, | |
568 uploadMedia: _uploadMedia, | |
569 downloadOptions: _downloadOptions); | |
570 return _response.then((data) => new AccountUserProfile.fromJson(data)); | |
571 } | |
572 | |
573 /** | |
574 * Updates an existing account user profile. | |
575 * | |
576 * [request] - The metadata request object. | |
577 * | |
578 * Request parameters: | |
579 * | |
580 * [profileId] - User profile ID associated with this request. | |
581 * | |
582 * Completes with a [AccountUserProfile]. | |
583 * | |
584 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
585 * error. | |
586 * | |
587 * If the used [http.Client] completes with an error when making a REST call, | |
588 * this method will complete with the same error. | |
589 */ | |
590 async.Future<AccountUserProfile> update(AccountUserProfile request, core.Strin
g profileId) { | |
591 var _url = null; | |
592 var _queryParams = new core.Map(); | |
593 var _uploadMedia = null; | |
594 var _uploadOptions = null; | |
595 var _downloadOptions = commons.DownloadOptions.Metadata; | |
596 var _body = null; | |
597 | |
598 if (request != null) { | |
599 _body = convert.JSON.encode((request).toJson()); | |
600 } | |
601 if (profileId == null) { | |
602 throw new core.ArgumentError("Parameter profileId is required."); | |
603 } | |
604 | |
605 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/acc
ountUserProfiles'; | |
606 | |
607 var _response = _requester.request(_url, | |
608 "PUT", | |
609 body: _body, | |
610 queryParams: _queryParams, | |
611 uploadOptions: _uploadOptions, | |
612 uploadMedia: _uploadMedia, | |
613 downloadOptions: _downloadOptions); | |
614 return _response.then((data) => new AccountUserProfile.fromJson(data)); | |
615 } | |
616 | |
617 } | |
618 | |
619 | |
620 class AccountsResourceApi { | |
621 final commons.ApiRequester _requester; | |
622 | |
623 AccountsResourceApi(commons.ApiRequester client) : | |
624 _requester = client; | |
625 | |
626 /** | |
627 * Gets one account by ID. | |
628 * | |
629 * Request parameters: | |
630 * | |
631 * [profileId] - User profile ID associated with this request. | |
632 * | |
633 * [id] - Account ID. | |
634 * | |
635 * Completes with a [Account]. | |
636 * | |
637 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
638 * error. | |
639 * | |
640 * If the used [http.Client] completes with an error when making a REST call, | |
641 * this method will complete with the same error. | |
642 */ | |
643 async.Future<Account> get(core.String profileId, core.String id) { | |
644 var _url = null; | |
645 var _queryParams = new core.Map(); | |
646 var _uploadMedia = null; | |
647 var _uploadOptions = null; | |
648 var _downloadOptions = commons.DownloadOptions.Metadata; | |
649 var _body = null; | |
650 | |
651 if (profileId == null) { | |
652 throw new core.ArgumentError("Parameter profileId is required."); | |
653 } | |
654 if (id == null) { | |
655 throw new core.ArgumentError("Parameter id is required."); | |
656 } | |
657 | |
658 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/acc
ounts/' + commons.Escaper.ecapeVariable('$id'); | |
659 | |
660 var _response = _requester.request(_url, | |
661 "GET", | |
662 body: _body, | |
663 queryParams: _queryParams, | |
664 uploadOptions: _uploadOptions, | |
665 uploadMedia: _uploadMedia, | |
666 downloadOptions: _downloadOptions); | |
667 return _response.then((data) => new Account.fromJson(data)); | |
668 } | |
669 | |
670 /** | |
671 * Retrieves the list of accounts, possibly filtered. | |
672 * | |
673 * Request parameters: | |
674 * | |
675 * [profileId] - User profile ID associated with this request. | |
676 * | |
677 * [active] - Select only active accounts. Don't set this field to select both | |
678 * active and non-active accounts. | |
679 * | |
680 * [ids] - Select only accounts with these IDs. | |
681 * | |
682 * [maxResults] - Maximum number of results to return. | |
683 * | |
684 * [pageToken] - Value of the nextPageToken from the previous result page. | |
685 * | |
686 * [searchString] - Allows searching for objects by name or ID. Wildcards (*) | |
687 * are allowed. For example, "account*2015" will return objects with names | |
688 * like "account June 2015", "account April 2015", or simply "account 2015". | |
689 * Most of the searches also add wildcards implicitly at the start and the end | |
690 * of the search string. For example, a search string of "account" will match | |
691 * objects with name "my account", "account 2015", or simply "account". | |
692 * | |
693 * [sortField] - Field by which to sort the list. | |
694 * Possible string values are: | |
695 * - "ID" | |
696 * - "NAME" | |
697 * | |
698 * [sortOrder] - Order of sorted results, default is ASCENDING. | |
699 * Possible string values are: | |
700 * - "ASCENDING" | |
701 * - "DESCENDING" | |
702 * | |
703 * Completes with a [AccountsListResponse]. | |
704 * | |
705 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
706 * error. | |
707 * | |
708 * If the used [http.Client] completes with an error when making a REST call, | |
709 * this method will complete with the same error. | |
710 */ | |
711 async.Future<AccountsListResponse> list(core.String profileId, {core.bool acti
ve, core.List<core.String> ids, core.int maxResults, core.String pageToken, core
.String searchString, core.String sortField, core.String sortOrder}) { | |
712 var _url = null; | |
713 var _queryParams = new core.Map(); | |
714 var _uploadMedia = null; | |
715 var _uploadOptions = null; | |
716 var _downloadOptions = commons.DownloadOptions.Metadata; | |
717 var _body = null; | |
718 | |
719 if (profileId == null) { | |
720 throw new core.ArgumentError("Parameter profileId is required."); | |
721 } | |
722 if (active != null) { | |
723 _queryParams["active"] = ["${active}"]; | |
724 } | |
725 if (ids != null) { | |
726 _queryParams["ids"] = ids; | |
727 } | |
728 if (maxResults != null) { | |
729 _queryParams["maxResults"] = ["${maxResults}"]; | |
730 } | |
731 if (pageToken != null) { | |
732 _queryParams["pageToken"] = [pageToken]; | |
733 } | |
734 if (searchString != null) { | |
735 _queryParams["searchString"] = [searchString]; | |
736 } | |
737 if (sortField != null) { | |
738 _queryParams["sortField"] = [sortField]; | |
739 } | |
740 if (sortOrder != null) { | |
741 _queryParams["sortOrder"] = [sortOrder]; | |
742 } | |
743 | |
744 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/acc
ounts'; | |
745 | |
746 var _response = _requester.request(_url, | |
747 "GET", | |
748 body: _body, | |
749 queryParams: _queryParams, | |
750 uploadOptions: _uploadOptions, | |
751 uploadMedia: _uploadMedia, | |
752 downloadOptions: _downloadOptions); | |
753 return _response.then((data) => new AccountsListResponse.fromJson(data)); | |
754 } | |
755 | |
756 /** | |
757 * Updates an existing account. This method supports patch semantics. | |
758 * | |
759 * [request] - The metadata request object. | |
760 * | |
761 * Request parameters: | |
762 * | |
763 * [profileId] - User profile ID associated with this request. | |
764 * | |
765 * [id] - Account ID. | |
766 * | |
767 * Completes with a [Account]. | |
768 * | |
769 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
770 * error. | |
771 * | |
772 * If the used [http.Client] completes with an error when making a REST call, | |
773 * this method will complete with the same error. | |
774 */ | |
775 async.Future<Account> patch(Account request, core.String profileId, core.Strin
g id) { | |
776 var _url = null; | |
777 var _queryParams = new core.Map(); | |
778 var _uploadMedia = null; | |
779 var _uploadOptions = null; | |
780 var _downloadOptions = commons.DownloadOptions.Metadata; | |
781 var _body = null; | |
782 | |
783 if (request != null) { | |
784 _body = convert.JSON.encode((request).toJson()); | |
785 } | |
786 if (profileId == null) { | |
787 throw new core.ArgumentError("Parameter profileId is required."); | |
788 } | |
789 if (id == null) { | |
790 throw new core.ArgumentError("Parameter id is required."); | |
791 } | |
792 _queryParams["id"] = [id]; | |
793 | |
794 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/acc
ounts'; | |
795 | |
796 var _response = _requester.request(_url, | |
797 "PATCH", | |
798 body: _body, | |
799 queryParams: _queryParams, | |
800 uploadOptions: _uploadOptions, | |
801 uploadMedia: _uploadMedia, | |
802 downloadOptions: _downloadOptions); | |
803 return _response.then((data) => new Account.fromJson(data)); | |
804 } | |
805 | |
806 /** | |
807 * Updates an existing account. | |
808 * | |
809 * [request] - The metadata request object. | |
810 * | |
811 * Request parameters: | |
812 * | |
813 * [profileId] - User profile ID associated with this request. | |
814 * | |
815 * Completes with a [Account]. | |
816 * | |
817 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
818 * error. | |
819 * | |
820 * If the used [http.Client] completes with an error when making a REST call, | |
821 * this method will complete with the same error. | |
822 */ | |
823 async.Future<Account> update(Account request, core.String profileId) { | |
824 var _url = null; | |
825 var _queryParams = new core.Map(); | |
826 var _uploadMedia = null; | |
827 var _uploadOptions = null; | |
828 var _downloadOptions = commons.DownloadOptions.Metadata; | |
829 var _body = null; | |
830 | |
831 if (request != null) { | |
832 _body = convert.JSON.encode((request).toJson()); | |
833 } | |
834 if (profileId == null) { | |
835 throw new core.ArgumentError("Parameter profileId is required."); | |
836 } | |
837 | |
838 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/acc
ounts'; | |
839 | |
840 var _response = _requester.request(_url, | |
841 "PUT", | |
842 body: _body, | |
843 queryParams: _queryParams, | |
844 uploadOptions: _uploadOptions, | |
845 uploadMedia: _uploadMedia, | |
846 downloadOptions: _downloadOptions); | |
847 return _response.then((data) => new Account.fromJson(data)); | |
848 } | |
849 | |
850 } | |
851 | |
852 | |
853 class AdsResourceApi { | |
854 final commons.ApiRequester _requester; | |
855 | |
856 AdsResourceApi(commons.ApiRequester client) : | |
857 _requester = client; | |
858 | |
859 /** | |
860 * Gets one ad by ID. | |
861 * | |
862 * Request parameters: | |
863 * | |
864 * [profileId] - User profile ID associated with this request. | |
865 * | |
866 * [id] - Ad ID. | |
867 * | |
868 * Completes with a [Ad]. | |
869 * | |
870 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
871 * error. | |
872 * | |
873 * If the used [http.Client] completes with an error when making a REST call, | |
874 * this method will complete with the same error. | |
875 */ | |
876 async.Future<Ad> get(core.String profileId, core.String id) { | |
877 var _url = null; | |
878 var _queryParams = new core.Map(); | |
879 var _uploadMedia = null; | |
880 var _uploadOptions = null; | |
881 var _downloadOptions = commons.DownloadOptions.Metadata; | |
882 var _body = null; | |
883 | |
884 if (profileId == null) { | |
885 throw new core.ArgumentError("Parameter profileId is required."); | |
886 } | |
887 if (id == null) { | |
888 throw new core.ArgumentError("Parameter id is required."); | |
889 } | |
890 | |
891 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/ads
/' + commons.Escaper.ecapeVariable('$id'); | |
892 | |
893 var _response = _requester.request(_url, | |
894 "GET", | |
895 body: _body, | |
896 queryParams: _queryParams, | |
897 uploadOptions: _uploadOptions, | |
898 uploadMedia: _uploadMedia, | |
899 downloadOptions: _downloadOptions); | |
900 return _response.then((data) => new Ad.fromJson(data)); | |
901 } | |
902 | |
903 /** | |
904 * Inserts a new ad. | |
905 * | |
906 * [request] - The metadata request object. | |
907 * | |
908 * Request parameters: | |
909 * | |
910 * [profileId] - User profile ID associated with this request. | |
911 * | |
912 * Completes with a [Ad]. | |
913 * | |
914 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
915 * error. | |
916 * | |
917 * If the used [http.Client] completes with an error when making a REST call, | |
918 * this method will complete with the same error. | |
919 */ | |
920 async.Future<Ad> insert(Ad request, core.String profileId) { | |
921 var _url = null; | |
922 var _queryParams = new core.Map(); | |
923 var _uploadMedia = null; | |
924 var _uploadOptions = null; | |
925 var _downloadOptions = commons.DownloadOptions.Metadata; | |
926 var _body = null; | |
927 | |
928 if (request != null) { | |
929 _body = convert.JSON.encode((request).toJson()); | |
930 } | |
931 if (profileId == null) { | |
932 throw new core.ArgumentError("Parameter profileId is required."); | |
933 } | |
934 | |
935 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/ads
'; | |
936 | |
937 var _response = _requester.request(_url, | |
938 "POST", | |
939 body: _body, | |
940 queryParams: _queryParams, | |
941 uploadOptions: _uploadOptions, | |
942 uploadMedia: _uploadMedia, | |
943 downloadOptions: _downloadOptions); | |
944 return _response.then((data) => new Ad.fromJson(data)); | |
945 } | |
946 | |
947 /** | |
948 * Retrieves a list of ads, possibly filtered. | |
949 * | |
950 * Request parameters: | |
951 * | |
952 * [profileId] - User profile ID associated with this request. | |
953 * | |
954 * [active] - Select only active ads. | |
955 * | |
956 * [advertiserId] - Select only ads with this advertiser ID. | |
957 * | |
958 * [archived] - Select only archived ads. | |
959 * | |
960 * [audienceSegmentIds] - Select only ads with these audience segment IDs. | |
961 * | |
962 * [campaignIds] - Select only ads with these campaign IDs. | |
963 * | |
964 * [compatibility] - Select default ads with the specified compatibility. | |
965 * Applicable when type is AD_SERVING_DEFAULT_AD. WEB and WEB_INTERSTITIAL | |
966 * refer to rendering either on desktop or on mobile devices for regular or | |
967 * interstitial ads, respectively. APP and APP_INTERSTITIAL are for rendering | |
968 * in mobile apps. IN_STREAM_VIDEO refers to rendering an in-stream video ads | |
969 * developed with the VAST standard. | |
970 * Possible string values are: | |
971 * - "APP" | |
972 * - "APP_INTERSTITIAL" | |
973 * - "IN_STREAM_VIDEO" | |
974 * - "WEB" | |
975 * - "WEB_INTERSTITIAL" | |
976 * | |
977 * [creativeIds] - Select only ads with these creative IDs assigned. | |
978 * | |
979 * [creativeOptimizationConfigurationIds] - Select only ads with these | |
980 * creative optimization configuration IDs. | |
981 * | |
982 * [creativeType] - Select only ads with the specified creativeType. | |
983 * Possible string values are: | |
984 * - "BRAND_SAFE_DEFAULT_INSTREAM_VIDEO" | |
985 * - "CUSTOM_INPAGE" | |
986 * - "CUSTOM_INTERSTITIAL" | |
987 * - "ENHANCED_BANNER" | |
988 * - "ENHANCED_IMAGE" | |
989 * - "FLASH_INPAGE" | |
990 * - "HTML5_BANNER" | |
991 * - "IMAGE" | |
992 * - "INSTREAM_VIDEO" | |
993 * - "INSTREAM_VIDEO_REDIRECT" | |
994 * - "INTERNAL_REDIRECT" | |
995 * - "INTERSTITIAL_INTERNAL_REDIRECT" | |
996 * - "REDIRECT" | |
997 * - "RICH_MEDIA_EXPANDING" | |
998 * - "RICH_MEDIA_IM_EXPAND" | |
999 * - "RICH_MEDIA_INPAGE" | |
1000 * - "RICH_MEDIA_INPAGE_FLOATING" | |
1001 * - "RICH_MEDIA_INTERSTITIAL_FLOAT" | |
1002 * - "RICH_MEDIA_MOBILE_IN_APP" | |
1003 * - "RICH_MEDIA_MULTI_FLOATING" | |
1004 * - "RICH_MEDIA_PEEL_DOWN" | |
1005 * - "TRACKING_TEXT" | |
1006 * - "VPAID_LINEAR" | |
1007 * - "VPAID_NON_LINEAR" | |
1008 * | |
1009 * [dynamicClickTracker] - Select only dynamic click trackers. Applicable when | |
1010 * type is AD_SERVING_CLICK_TRACKER. If true, select dynamic click trackers. | |
1011 * If false, select static click trackers. Leave unset to select both. | |
1012 * | |
1013 * [ids] - Select only ads with these IDs. | |
1014 * | |
1015 * [landingPageIds] - Select only ads with these landing page IDs. | |
1016 * | |
1017 * [maxResults] - Maximum number of results to return. | |
1018 * | |
1019 * [overriddenEventTagId] - Select only ads with this event tag override ID. | |
1020 * | |
1021 * [pageToken] - Value of the nextPageToken from the previous result page. | |
1022 * | |
1023 * [placementIds] - Select only ads with these placement IDs assigned. | |
1024 * | |
1025 * [remarketingListIds] - Select only ads whose list targeting expression use | |
1026 * these remarketing list IDs. | |
1027 * | |
1028 * [searchString] - Allows searching for objects by name or ID. Wildcards (*) | |
1029 * are allowed. For example, "ad*2015" will return objects with names like "ad | |
1030 * June 2015", "ad April 2015", or simply "ad 2015". Most of the searches also | |
1031 * add wildcards implicitly at the start and the end of the search string. For | |
1032 * example, a search string of "ad" will match objects with name "my ad", "ad | |
1033 * 2015", or simply "ad". | |
1034 * | |
1035 * [sizeIds] - Select only ads with these size IDs. | |
1036 * | |
1037 * [sortField] - Field by which to sort the list. | |
1038 * Possible string values are: | |
1039 * - "ID" | |
1040 * - "NAME" | |
1041 * | |
1042 * [sortOrder] - Order of sorted results, default is ASCENDING. | |
1043 * Possible string values are: | |
1044 * - "ASCENDING" | |
1045 * - "DESCENDING" | |
1046 * | |
1047 * [sslCompliant] - Select only ads that are SSL-compliant. | |
1048 * | |
1049 * [sslRequired] - Select only ads that require SSL. | |
1050 * | |
1051 * [type] - Select only ads with these types. | |
1052 * | |
1053 * Completes with a [AdsListResponse]. | |
1054 * | |
1055 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
1056 * error. | |
1057 * | |
1058 * If the used [http.Client] completes with an error when making a REST call, | |
1059 * this method will complete with the same error. | |
1060 */ | |
1061 async.Future<AdsListResponse> list(core.String profileId, {core.bool active, c
ore.String advertiserId, core.bool archived, core.List<core.String> audienceSegm
entIds, core.List<core.String> campaignIds, core.String compatibility, core.List
<core.String> creativeIds, core.List<core.String> creativeOptimizationConfigurat
ionIds, core.String creativeType, core.bool dynamicClickTracker, core.List<core.
String> ids, core.List<core.String> landingPageIds, core.int maxResults, core.St
ring overriddenEventTagId, core.String pageToken, core.List<core.String> placeme
ntIds, core.List<core.String> remarketingListIds, core.String searchString, core
.List<core.String> sizeIds, core.String sortField, core.String sortOrder, core.b
ool sslCompliant, core.bool sslRequired, core.List<core.String> type}) { | |
1062 var _url = null; | |
1063 var _queryParams = new core.Map(); | |
1064 var _uploadMedia = null; | |
1065 var _uploadOptions = null; | |
1066 var _downloadOptions = commons.DownloadOptions.Metadata; | |
1067 var _body = null; | |
1068 | |
1069 if (profileId == null) { | |
1070 throw new core.ArgumentError("Parameter profileId is required."); | |
1071 } | |
1072 if (active != null) { | |
1073 _queryParams["active"] = ["${active}"]; | |
1074 } | |
1075 if (advertiserId != null) { | |
1076 _queryParams["advertiserId"] = [advertiserId]; | |
1077 } | |
1078 if (archived != null) { | |
1079 _queryParams["archived"] = ["${archived}"]; | |
1080 } | |
1081 if (audienceSegmentIds != null) { | |
1082 _queryParams["audienceSegmentIds"] = audienceSegmentIds; | |
1083 } | |
1084 if (campaignIds != null) { | |
1085 _queryParams["campaignIds"] = campaignIds; | |
1086 } | |
1087 if (compatibility != null) { | |
1088 _queryParams["compatibility"] = [compatibility]; | |
1089 } | |
1090 if (creativeIds != null) { | |
1091 _queryParams["creativeIds"] = creativeIds; | |
1092 } | |
1093 if (creativeOptimizationConfigurationIds != null) { | |
1094 _queryParams["creativeOptimizationConfigurationIds"] = creativeOptimizatio
nConfigurationIds; | |
1095 } | |
1096 if (creativeType != null) { | |
1097 _queryParams["creativeType"] = [creativeType]; | |
1098 } | |
1099 if (dynamicClickTracker != null) { | |
1100 _queryParams["dynamicClickTracker"] = ["${dynamicClickTracker}"]; | |
1101 } | |
1102 if (ids != null) { | |
1103 _queryParams["ids"] = ids; | |
1104 } | |
1105 if (landingPageIds != null) { | |
1106 _queryParams["landingPageIds"] = landingPageIds; | |
1107 } | |
1108 if (maxResults != null) { | |
1109 _queryParams["maxResults"] = ["${maxResults}"]; | |
1110 } | |
1111 if (overriddenEventTagId != null) { | |
1112 _queryParams["overriddenEventTagId"] = [overriddenEventTagId]; | |
1113 } | |
1114 if (pageToken != null) { | |
1115 _queryParams["pageToken"] = [pageToken]; | |
1116 } | |
1117 if (placementIds != null) { | |
1118 _queryParams["placementIds"] = placementIds; | |
1119 } | |
1120 if (remarketingListIds != null) { | |
1121 _queryParams["remarketingListIds"] = remarketingListIds; | |
1122 } | |
1123 if (searchString != null) { | |
1124 _queryParams["searchString"] = [searchString]; | |
1125 } | |
1126 if (sizeIds != null) { | |
1127 _queryParams["sizeIds"] = sizeIds; | |
1128 } | |
1129 if (sortField != null) { | |
1130 _queryParams["sortField"] = [sortField]; | |
1131 } | |
1132 if (sortOrder != null) { | |
1133 _queryParams["sortOrder"] = [sortOrder]; | |
1134 } | |
1135 if (sslCompliant != null) { | |
1136 _queryParams["sslCompliant"] = ["${sslCompliant}"]; | |
1137 } | |
1138 if (sslRequired != null) { | |
1139 _queryParams["sslRequired"] = ["${sslRequired}"]; | |
1140 } | |
1141 if (type != null) { | |
1142 _queryParams["type"] = type; | |
1143 } | |
1144 | |
1145 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/ads
'; | |
1146 | |
1147 var _response = _requester.request(_url, | |
1148 "GET", | |
1149 body: _body, | |
1150 queryParams: _queryParams, | |
1151 uploadOptions: _uploadOptions, | |
1152 uploadMedia: _uploadMedia, | |
1153 downloadOptions: _downloadOptions); | |
1154 return _response.then((data) => new AdsListResponse.fromJson(data)); | |
1155 } | |
1156 | |
1157 /** | |
1158 * Updates an existing ad. This method supports patch semantics. | |
1159 * | |
1160 * [request] - The metadata request object. | |
1161 * | |
1162 * Request parameters: | |
1163 * | |
1164 * [profileId] - User profile ID associated with this request. | |
1165 * | |
1166 * [id] - Ad ID. | |
1167 * | |
1168 * Completes with a [Ad]. | |
1169 * | |
1170 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
1171 * error. | |
1172 * | |
1173 * If the used [http.Client] completes with an error when making a REST call, | |
1174 * this method will complete with the same error. | |
1175 */ | |
1176 async.Future<Ad> patch(Ad request, core.String profileId, core.String id) { | |
1177 var _url = null; | |
1178 var _queryParams = new core.Map(); | |
1179 var _uploadMedia = null; | |
1180 var _uploadOptions = null; | |
1181 var _downloadOptions = commons.DownloadOptions.Metadata; | |
1182 var _body = null; | |
1183 | |
1184 if (request != null) { | |
1185 _body = convert.JSON.encode((request).toJson()); | |
1186 } | |
1187 if (profileId == null) { | |
1188 throw new core.ArgumentError("Parameter profileId is required."); | |
1189 } | |
1190 if (id == null) { | |
1191 throw new core.ArgumentError("Parameter id is required."); | |
1192 } | |
1193 _queryParams["id"] = [id]; | |
1194 | |
1195 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/ads
'; | |
1196 | |
1197 var _response = _requester.request(_url, | |
1198 "PATCH", | |
1199 body: _body, | |
1200 queryParams: _queryParams, | |
1201 uploadOptions: _uploadOptions, | |
1202 uploadMedia: _uploadMedia, | |
1203 downloadOptions: _downloadOptions); | |
1204 return _response.then((data) => new Ad.fromJson(data)); | |
1205 } | |
1206 | |
1207 /** | |
1208 * Updates an existing ad. | |
1209 * | |
1210 * [request] - The metadata request object. | |
1211 * | |
1212 * Request parameters: | |
1213 * | |
1214 * [profileId] - User profile ID associated with this request. | |
1215 * | |
1216 * Completes with a [Ad]. | |
1217 * | |
1218 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
1219 * error. | |
1220 * | |
1221 * If the used [http.Client] completes with an error when making a REST call, | |
1222 * this method will complete with the same error. | |
1223 */ | |
1224 async.Future<Ad> update(Ad request, core.String profileId) { | |
1225 var _url = null; | |
1226 var _queryParams = new core.Map(); | |
1227 var _uploadMedia = null; | |
1228 var _uploadOptions = null; | |
1229 var _downloadOptions = commons.DownloadOptions.Metadata; | |
1230 var _body = null; | |
1231 | |
1232 if (request != null) { | |
1233 _body = convert.JSON.encode((request).toJson()); | |
1234 } | |
1235 if (profileId == null) { | |
1236 throw new core.ArgumentError("Parameter profileId is required."); | |
1237 } | |
1238 | |
1239 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/ads
'; | |
1240 | |
1241 var _response = _requester.request(_url, | |
1242 "PUT", | |
1243 body: _body, | |
1244 queryParams: _queryParams, | |
1245 uploadOptions: _uploadOptions, | |
1246 uploadMedia: _uploadMedia, | |
1247 downloadOptions: _downloadOptions); | |
1248 return _response.then((data) => new Ad.fromJson(data)); | |
1249 } | |
1250 | |
1251 } | |
1252 | |
1253 | |
1254 class AdvertiserGroupsResourceApi { | |
1255 final commons.ApiRequester _requester; | |
1256 | |
1257 AdvertiserGroupsResourceApi(commons.ApiRequester client) : | |
1258 _requester = client; | |
1259 | |
1260 /** | |
1261 * Deletes an existing advertiser group. | |
1262 * | |
1263 * Request parameters: | |
1264 * | |
1265 * [profileId] - User profile ID associated with this request. | |
1266 * | |
1267 * [id] - Advertiser group ID. | |
1268 * | |
1269 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
1270 * error. | |
1271 * | |
1272 * If the used [http.Client] completes with an error when making a REST call, | |
1273 * this method will complete with the same error. | |
1274 */ | |
1275 async.Future delete(core.String profileId, core.String id) { | |
1276 var _url = null; | |
1277 var _queryParams = new core.Map(); | |
1278 var _uploadMedia = null; | |
1279 var _uploadOptions = null; | |
1280 var _downloadOptions = commons.DownloadOptions.Metadata; | |
1281 var _body = null; | |
1282 | |
1283 if (profileId == null) { | |
1284 throw new core.ArgumentError("Parameter profileId is required."); | |
1285 } | |
1286 if (id == null) { | |
1287 throw new core.ArgumentError("Parameter id is required."); | |
1288 } | |
1289 | |
1290 _downloadOptions = null; | |
1291 | |
1292 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/adv
ertiserGroups/' + commons.Escaper.ecapeVariable('$id'); | |
1293 | |
1294 var _response = _requester.request(_url, | |
1295 "DELETE", | |
1296 body: _body, | |
1297 queryParams: _queryParams, | |
1298 uploadOptions: _uploadOptions, | |
1299 uploadMedia: _uploadMedia, | |
1300 downloadOptions: _downloadOptions); | |
1301 return _response.then((data) => null); | |
1302 } | |
1303 | |
1304 /** | |
1305 * Gets one advertiser group by ID. | |
1306 * | |
1307 * Request parameters: | |
1308 * | |
1309 * [profileId] - User profile ID associated with this request. | |
1310 * | |
1311 * [id] - Advertiser group ID. | |
1312 * | |
1313 * Completes with a [AdvertiserGroup]. | |
1314 * | |
1315 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
1316 * error. | |
1317 * | |
1318 * If the used [http.Client] completes with an error when making a REST call, | |
1319 * this method will complete with the same error. | |
1320 */ | |
1321 async.Future<AdvertiserGroup> get(core.String profileId, core.String id) { | |
1322 var _url = null; | |
1323 var _queryParams = new core.Map(); | |
1324 var _uploadMedia = null; | |
1325 var _uploadOptions = null; | |
1326 var _downloadOptions = commons.DownloadOptions.Metadata; | |
1327 var _body = null; | |
1328 | |
1329 if (profileId == null) { | |
1330 throw new core.ArgumentError("Parameter profileId is required."); | |
1331 } | |
1332 if (id == null) { | |
1333 throw new core.ArgumentError("Parameter id is required."); | |
1334 } | |
1335 | |
1336 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/adv
ertiserGroups/' + commons.Escaper.ecapeVariable('$id'); | |
1337 | |
1338 var _response = _requester.request(_url, | |
1339 "GET", | |
1340 body: _body, | |
1341 queryParams: _queryParams, | |
1342 uploadOptions: _uploadOptions, | |
1343 uploadMedia: _uploadMedia, | |
1344 downloadOptions: _downloadOptions); | |
1345 return _response.then((data) => new AdvertiserGroup.fromJson(data)); | |
1346 } | |
1347 | |
1348 /** | |
1349 * Inserts a new advertiser group. | |
1350 * | |
1351 * [request] - The metadata request object. | |
1352 * | |
1353 * Request parameters: | |
1354 * | |
1355 * [profileId] - User profile ID associated with this request. | |
1356 * | |
1357 * Completes with a [AdvertiserGroup]. | |
1358 * | |
1359 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
1360 * error. | |
1361 * | |
1362 * If the used [http.Client] completes with an error when making a REST call, | |
1363 * this method will complete with the same error. | |
1364 */ | |
1365 async.Future<AdvertiserGroup> insert(AdvertiserGroup request, core.String prof
ileId) { | |
1366 var _url = null; | |
1367 var _queryParams = new core.Map(); | |
1368 var _uploadMedia = null; | |
1369 var _uploadOptions = null; | |
1370 var _downloadOptions = commons.DownloadOptions.Metadata; | |
1371 var _body = null; | |
1372 | |
1373 if (request != null) { | |
1374 _body = convert.JSON.encode((request).toJson()); | |
1375 } | |
1376 if (profileId == null) { | |
1377 throw new core.ArgumentError("Parameter profileId is required."); | |
1378 } | |
1379 | |
1380 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/adv
ertiserGroups'; | |
1381 | |
1382 var _response = _requester.request(_url, | |
1383 "POST", | |
1384 body: _body, | |
1385 queryParams: _queryParams, | |
1386 uploadOptions: _uploadOptions, | |
1387 uploadMedia: _uploadMedia, | |
1388 downloadOptions: _downloadOptions); | |
1389 return _response.then((data) => new AdvertiserGroup.fromJson(data)); | |
1390 } | |
1391 | |
1392 /** | |
1393 * Retrieves a list of advertiser groups, possibly filtered. | |
1394 * | |
1395 * Request parameters: | |
1396 * | |
1397 * [profileId] - User profile ID associated with this request. | |
1398 * | |
1399 * [ids] - Select only advertiser groups with these IDs. | |
1400 * | |
1401 * [maxResults] - Maximum number of results to return. | |
1402 * | |
1403 * [pageToken] - Value of the nextPageToken from the previous result page. | |
1404 * | |
1405 * [searchString] - Allows searching for objects by name or ID. Wildcards (*) | |
1406 * are allowed. For example, "advertiser*2015" will return objects with names | |
1407 * like "advertiser group June 2015", "advertiser group April 2015", or simply | |
1408 * "advertiser group 2015". Most of the searches also add wildcards implicitly | |
1409 * at the start and the end of the search string. For example, a search string | |
1410 * of "advertisergroup" will match objects with name "my advertisergroup", | |
1411 * "advertisergroup 2015", or simply "advertisergroup". | |
1412 * | |
1413 * [sortField] - Field by which to sort the list. | |
1414 * Possible string values are: | |
1415 * - "ID" | |
1416 * - "NAME" | |
1417 * | |
1418 * [sortOrder] - Order of sorted results, default is ASCENDING. | |
1419 * Possible string values are: | |
1420 * - "ASCENDING" | |
1421 * - "DESCENDING" | |
1422 * | |
1423 * Completes with a [AdvertiserGroupsListResponse]. | |
1424 * | |
1425 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
1426 * error. | |
1427 * | |
1428 * If the used [http.Client] completes with an error when making a REST call, | |
1429 * this method will complete with the same error. | |
1430 */ | |
1431 async.Future<AdvertiserGroupsListResponse> list(core.String profileId, {core.L
ist<core.String> ids, core.int maxResults, core.String pageToken, core.String se
archString, core.String sortField, core.String sortOrder}) { | |
1432 var _url = null; | |
1433 var _queryParams = new core.Map(); | |
1434 var _uploadMedia = null; | |
1435 var _uploadOptions = null; | |
1436 var _downloadOptions = commons.DownloadOptions.Metadata; | |
1437 var _body = null; | |
1438 | |
1439 if (profileId == null) { | |
1440 throw new core.ArgumentError("Parameter profileId is required."); | |
1441 } | |
1442 if (ids != null) { | |
1443 _queryParams["ids"] = ids; | |
1444 } | |
1445 if (maxResults != null) { | |
1446 _queryParams["maxResults"] = ["${maxResults}"]; | |
1447 } | |
1448 if (pageToken != null) { | |
1449 _queryParams["pageToken"] = [pageToken]; | |
1450 } | |
1451 if (searchString != null) { | |
1452 _queryParams["searchString"] = [searchString]; | |
1453 } | |
1454 if (sortField != null) { | |
1455 _queryParams["sortField"] = [sortField]; | |
1456 } | |
1457 if (sortOrder != null) { | |
1458 _queryParams["sortOrder"] = [sortOrder]; | |
1459 } | |
1460 | |
1461 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/adv
ertiserGroups'; | |
1462 | |
1463 var _response = _requester.request(_url, | |
1464 "GET", | |
1465 body: _body, | |
1466 queryParams: _queryParams, | |
1467 uploadOptions: _uploadOptions, | |
1468 uploadMedia: _uploadMedia, | |
1469 downloadOptions: _downloadOptions); | |
1470 return _response.then((data) => new AdvertiserGroupsListResponse.fromJson(da
ta)); | |
1471 } | |
1472 | |
1473 /** | |
1474 * Updates an existing advertiser group. This method supports patch semantics. | |
1475 * | |
1476 * [request] - The metadata request object. | |
1477 * | |
1478 * Request parameters: | |
1479 * | |
1480 * [profileId] - User profile ID associated with this request. | |
1481 * | |
1482 * [id] - Advertiser group ID. | |
1483 * | |
1484 * Completes with a [AdvertiserGroup]. | |
1485 * | |
1486 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
1487 * error. | |
1488 * | |
1489 * If the used [http.Client] completes with an error when making a REST call, | |
1490 * this method will complete with the same error. | |
1491 */ | |
1492 async.Future<AdvertiserGroup> patch(AdvertiserGroup request, core.String profi
leId, core.String id) { | |
1493 var _url = null; | |
1494 var _queryParams = new core.Map(); | |
1495 var _uploadMedia = null; | |
1496 var _uploadOptions = null; | |
1497 var _downloadOptions = commons.DownloadOptions.Metadata; | |
1498 var _body = null; | |
1499 | |
1500 if (request != null) { | |
1501 _body = convert.JSON.encode((request).toJson()); | |
1502 } | |
1503 if (profileId == null) { | |
1504 throw new core.ArgumentError("Parameter profileId is required."); | |
1505 } | |
1506 if (id == null) { | |
1507 throw new core.ArgumentError("Parameter id is required."); | |
1508 } | |
1509 _queryParams["id"] = [id]; | |
1510 | |
1511 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/adv
ertiserGroups'; | |
1512 | |
1513 var _response = _requester.request(_url, | |
1514 "PATCH", | |
1515 body: _body, | |
1516 queryParams: _queryParams, | |
1517 uploadOptions: _uploadOptions, | |
1518 uploadMedia: _uploadMedia, | |
1519 downloadOptions: _downloadOptions); | |
1520 return _response.then((data) => new AdvertiserGroup.fromJson(data)); | |
1521 } | |
1522 | |
1523 /** | |
1524 * Updates an existing advertiser group. | |
1525 * | |
1526 * [request] - The metadata request object. | |
1527 * | |
1528 * Request parameters: | |
1529 * | |
1530 * [profileId] - User profile ID associated with this request. | |
1531 * | |
1532 * Completes with a [AdvertiserGroup]. | |
1533 * | |
1534 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
1535 * error. | |
1536 * | |
1537 * If the used [http.Client] completes with an error when making a REST call, | |
1538 * this method will complete with the same error. | |
1539 */ | |
1540 async.Future<AdvertiserGroup> update(AdvertiserGroup request, core.String prof
ileId) { | |
1541 var _url = null; | |
1542 var _queryParams = new core.Map(); | |
1543 var _uploadMedia = null; | |
1544 var _uploadOptions = null; | |
1545 var _downloadOptions = commons.DownloadOptions.Metadata; | |
1546 var _body = null; | |
1547 | |
1548 if (request != null) { | |
1549 _body = convert.JSON.encode((request).toJson()); | |
1550 } | |
1551 if (profileId == null) { | |
1552 throw new core.ArgumentError("Parameter profileId is required."); | |
1553 } | |
1554 | |
1555 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/adv
ertiserGroups'; | |
1556 | |
1557 var _response = _requester.request(_url, | |
1558 "PUT", | |
1559 body: _body, | |
1560 queryParams: _queryParams, | |
1561 uploadOptions: _uploadOptions, | |
1562 uploadMedia: _uploadMedia, | |
1563 downloadOptions: _downloadOptions); | |
1564 return _response.then((data) => new AdvertiserGroup.fromJson(data)); | |
1565 } | |
1566 | |
1567 } | |
1568 | |
1569 | |
1570 class AdvertisersResourceApi { | |
1571 final commons.ApiRequester _requester; | |
1572 | |
1573 AdvertisersResourceApi(commons.ApiRequester client) : | |
1574 _requester = client; | |
1575 | |
1576 /** | |
1577 * Gets one advertiser by ID. | |
1578 * | |
1579 * Request parameters: | |
1580 * | |
1581 * [profileId] - User profile ID associated with this request. | |
1582 * | |
1583 * [id] - Advertiser ID. | |
1584 * | |
1585 * Completes with a [Advertiser]. | |
1586 * | |
1587 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
1588 * error. | |
1589 * | |
1590 * If the used [http.Client] completes with an error when making a REST call, | |
1591 * this method will complete with the same error. | |
1592 */ | |
1593 async.Future<Advertiser> get(core.String profileId, core.String id) { | |
1594 var _url = null; | |
1595 var _queryParams = new core.Map(); | |
1596 var _uploadMedia = null; | |
1597 var _uploadOptions = null; | |
1598 var _downloadOptions = commons.DownloadOptions.Metadata; | |
1599 var _body = null; | |
1600 | |
1601 if (profileId == null) { | |
1602 throw new core.ArgumentError("Parameter profileId is required."); | |
1603 } | |
1604 if (id == null) { | |
1605 throw new core.ArgumentError("Parameter id is required."); | |
1606 } | |
1607 | |
1608 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/adv
ertisers/' + commons.Escaper.ecapeVariable('$id'); | |
1609 | |
1610 var _response = _requester.request(_url, | |
1611 "GET", | |
1612 body: _body, | |
1613 queryParams: _queryParams, | |
1614 uploadOptions: _uploadOptions, | |
1615 uploadMedia: _uploadMedia, | |
1616 downloadOptions: _downloadOptions); | |
1617 return _response.then((data) => new Advertiser.fromJson(data)); | |
1618 } | |
1619 | |
1620 /** | |
1621 * Inserts a new advertiser. | |
1622 * | |
1623 * [request] - The metadata request object. | |
1624 * | |
1625 * Request parameters: | |
1626 * | |
1627 * [profileId] - User profile ID associated with this request. | |
1628 * | |
1629 * Completes with a [Advertiser]. | |
1630 * | |
1631 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
1632 * error. | |
1633 * | |
1634 * If the used [http.Client] completes with an error when making a REST call, | |
1635 * this method will complete with the same error. | |
1636 */ | |
1637 async.Future<Advertiser> insert(Advertiser request, core.String profileId) { | |
1638 var _url = null; | |
1639 var _queryParams = new core.Map(); | |
1640 var _uploadMedia = null; | |
1641 var _uploadOptions = null; | |
1642 var _downloadOptions = commons.DownloadOptions.Metadata; | |
1643 var _body = null; | |
1644 | |
1645 if (request != null) { | |
1646 _body = convert.JSON.encode((request).toJson()); | |
1647 } | |
1648 if (profileId == null) { | |
1649 throw new core.ArgumentError("Parameter profileId is required."); | |
1650 } | |
1651 | |
1652 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/adv
ertisers'; | |
1653 | |
1654 var _response = _requester.request(_url, | |
1655 "POST", | |
1656 body: _body, | |
1657 queryParams: _queryParams, | |
1658 uploadOptions: _uploadOptions, | |
1659 uploadMedia: _uploadMedia, | |
1660 downloadOptions: _downloadOptions); | |
1661 return _response.then((data) => new Advertiser.fromJson(data)); | |
1662 } | |
1663 | |
1664 /** | |
1665 * Retrieves a list of advertisers, possibly filtered. | |
1666 * | |
1667 * Request parameters: | |
1668 * | |
1669 * [profileId] - User profile ID associated with this request. | |
1670 * | |
1671 * [advertiserGroupIds] - Select only advertisers with these advertiser group | |
1672 * IDs. | |
1673 * | |
1674 * [floodlightConfigurationIds] - Select only advertisers with these | |
1675 * floodlight configuration IDs. | |
1676 * | |
1677 * [ids] - Select only advertisers with these IDs. | |
1678 * | |
1679 * [includeAdvertisersWithoutGroupsOnly] - Select only advertisers which do | |
1680 * not belong to any advertiser group. | |
1681 * | |
1682 * [maxResults] - Maximum number of results to return. | |
1683 * | |
1684 * [onlyParent] - Select only advertisers which use another advertiser's | |
1685 * floodlight configuration. | |
1686 * | |
1687 * [pageToken] - Value of the nextPageToken from the previous result page. | |
1688 * | |
1689 * [searchString] - Allows searching for objects by name or ID. Wildcards (*) | |
1690 * are allowed. For example, "advertiser*2015" will return objects with names | |
1691 * like "advertiser June 2015", "advertiser April 2015", or simply "advertiser | |
1692 * 2015". Most of the searches also add wildcards implicitly at the start and | |
1693 * the end of the search string. For example, a search string of "advertiser" | |
1694 * will match objects with name "my advertiser", "advertiser 2015", or simply | |
1695 * "advertiser". | |
1696 * | |
1697 * [sortField] - Field by which to sort the list. | |
1698 * Possible string values are: | |
1699 * - "ID" | |
1700 * - "NAME" | |
1701 * | |
1702 * [sortOrder] - Order of sorted results, default is ASCENDING. | |
1703 * Possible string values are: | |
1704 * - "ASCENDING" | |
1705 * - "DESCENDING" | |
1706 * | |
1707 * [status] - Select only advertisers with the specified status. | |
1708 * Possible string values are: | |
1709 * - "APPROVED" | |
1710 * - "ON_HOLD" | |
1711 * | |
1712 * [subaccountId] - Select only advertisers with these subaccount IDs. | |
1713 * | |
1714 * Completes with a [AdvertisersListResponse]. | |
1715 * | |
1716 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
1717 * error. | |
1718 * | |
1719 * If the used [http.Client] completes with an error when making a REST call, | |
1720 * this method will complete with the same error. | |
1721 */ | |
1722 async.Future<AdvertisersListResponse> list(core.String profileId, {core.List<c
ore.String> advertiserGroupIds, core.List<core.String> floodlightConfigurationId
s, core.List<core.String> ids, core.bool includeAdvertisersWithoutGroupsOnly, co
re.int maxResults, core.bool onlyParent, core.String pageToken, core.String sear
chString, core.String sortField, core.String sortOrder, core.String status, core
.String subaccountId}) { | |
1723 var _url = null; | |
1724 var _queryParams = new core.Map(); | |
1725 var _uploadMedia = null; | |
1726 var _uploadOptions = null; | |
1727 var _downloadOptions = commons.DownloadOptions.Metadata; | |
1728 var _body = null; | |
1729 | |
1730 if (profileId == null) { | |
1731 throw new core.ArgumentError("Parameter profileId is required."); | |
1732 } | |
1733 if (advertiserGroupIds != null) { | |
1734 _queryParams["advertiserGroupIds"] = advertiserGroupIds; | |
1735 } | |
1736 if (floodlightConfigurationIds != null) { | |
1737 _queryParams["floodlightConfigurationIds"] = floodlightConfigurationIds; | |
1738 } | |
1739 if (ids != null) { | |
1740 _queryParams["ids"] = ids; | |
1741 } | |
1742 if (includeAdvertisersWithoutGroupsOnly != null) { | |
1743 _queryParams["includeAdvertisersWithoutGroupsOnly"] = ["${includeAdvertise
rsWithoutGroupsOnly}"]; | |
1744 } | |
1745 if (maxResults != null) { | |
1746 _queryParams["maxResults"] = ["${maxResults}"]; | |
1747 } | |
1748 if (onlyParent != null) { | |
1749 _queryParams["onlyParent"] = ["${onlyParent}"]; | |
1750 } | |
1751 if (pageToken != null) { | |
1752 _queryParams["pageToken"] = [pageToken]; | |
1753 } | |
1754 if (searchString != null) { | |
1755 _queryParams["searchString"] = [searchString]; | |
1756 } | |
1757 if (sortField != null) { | |
1758 _queryParams["sortField"] = [sortField]; | |
1759 } | |
1760 if (sortOrder != null) { | |
1761 _queryParams["sortOrder"] = [sortOrder]; | |
1762 } | |
1763 if (status != null) { | |
1764 _queryParams["status"] = [status]; | |
1765 } | |
1766 if (subaccountId != null) { | |
1767 _queryParams["subaccountId"] = [subaccountId]; | |
1768 } | |
1769 | |
1770 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/adv
ertisers'; | |
1771 | |
1772 var _response = _requester.request(_url, | |
1773 "GET", | |
1774 body: _body, | |
1775 queryParams: _queryParams, | |
1776 uploadOptions: _uploadOptions, | |
1777 uploadMedia: _uploadMedia, | |
1778 downloadOptions: _downloadOptions); | |
1779 return _response.then((data) => new AdvertisersListResponse.fromJson(data)); | |
1780 } | |
1781 | |
1782 /** | |
1783 * Updates an existing advertiser. This method supports patch semantics. | |
1784 * | |
1785 * [request] - The metadata request object. | |
1786 * | |
1787 * Request parameters: | |
1788 * | |
1789 * [profileId] - User profile ID associated with this request. | |
1790 * | |
1791 * [id] - Advertiser ID. | |
1792 * | |
1793 * Completes with a [Advertiser]. | |
1794 * | |
1795 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
1796 * error. | |
1797 * | |
1798 * If the used [http.Client] completes with an error when making a REST call, | |
1799 * this method will complete with the same error. | |
1800 */ | |
1801 async.Future<Advertiser> patch(Advertiser request, core.String profileId, core
.String id) { | |
1802 var _url = null; | |
1803 var _queryParams = new core.Map(); | |
1804 var _uploadMedia = null; | |
1805 var _uploadOptions = null; | |
1806 var _downloadOptions = commons.DownloadOptions.Metadata; | |
1807 var _body = null; | |
1808 | |
1809 if (request != null) { | |
1810 _body = convert.JSON.encode((request).toJson()); | |
1811 } | |
1812 if (profileId == null) { | |
1813 throw new core.ArgumentError("Parameter profileId is required."); | |
1814 } | |
1815 if (id == null) { | |
1816 throw new core.ArgumentError("Parameter id is required."); | |
1817 } | |
1818 _queryParams["id"] = [id]; | |
1819 | |
1820 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/adv
ertisers'; | |
1821 | |
1822 var _response = _requester.request(_url, | |
1823 "PATCH", | |
1824 body: _body, | |
1825 queryParams: _queryParams, | |
1826 uploadOptions: _uploadOptions, | |
1827 uploadMedia: _uploadMedia, | |
1828 downloadOptions: _downloadOptions); | |
1829 return _response.then((data) => new Advertiser.fromJson(data)); | |
1830 } | |
1831 | |
1832 /** | |
1833 * Updates an existing advertiser. | |
1834 * | |
1835 * [request] - The metadata request object. | |
1836 * | |
1837 * Request parameters: | |
1838 * | |
1839 * [profileId] - User profile ID associated with this request. | |
1840 * | |
1841 * Completes with a [Advertiser]. | |
1842 * | |
1843 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
1844 * error. | |
1845 * | |
1846 * If the used [http.Client] completes with an error when making a REST call, | |
1847 * this method will complete with the same error. | |
1848 */ | |
1849 async.Future<Advertiser> update(Advertiser request, core.String profileId) { | |
1850 var _url = null; | |
1851 var _queryParams = new core.Map(); | |
1852 var _uploadMedia = null; | |
1853 var _uploadOptions = null; | |
1854 var _downloadOptions = commons.DownloadOptions.Metadata; | |
1855 var _body = null; | |
1856 | |
1857 if (request != null) { | |
1858 _body = convert.JSON.encode((request).toJson()); | |
1859 } | |
1860 if (profileId == null) { | |
1861 throw new core.ArgumentError("Parameter profileId is required."); | |
1862 } | |
1863 | |
1864 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/adv
ertisers'; | |
1865 | |
1866 var _response = _requester.request(_url, | |
1867 "PUT", | |
1868 body: _body, | |
1869 queryParams: _queryParams, | |
1870 uploadOptions: _uploadOptions, | |
1871 uploadMedia: _uploadMedia, | |
1872 downloadOptions: _downloadOptions); | |
1873 return _response.then((data) => new Advertiser.fromJson(data)); | |
1874 } | |
1875 | |
1876 } | |
1877 | |
1878 | |
1879 class BrowsersResourceApi { | |
1880 final commons.ApiRequester _requester; | |
1881 | |
1882 BrowsersResourceApi(commons.ApiRequester client) : | |
1883 _requester = client; | |
1884 | |
1885 /** | |
1886 * Retrieves a list of browsers. | |
1887 * | |
1888 * Request parameters: | |
1889 * | |
1890 * [profileId] - User profile ID associated with this request. | |
1891 * | |
1892 * Completes with a [BrowsersListResponse]. | |
1893 * | |
1894 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
1895 * error. | |
1896 * | |
1897 * If the used [http.Client] completes with an error when making a REST call, | |
1898 * this method will complete with the same error. | |
1899 */ | |
1900 async.Future<BrowsersListResponse> list(core.String profileId) { | |
1901 var _url = null; | |
1902 var _queryParams = new core.Map(); | |
1903 var _uploadMedia = null; | |
1904 var _uploadOptions = null; | |
1905 var _downloadOptions = commons.DownloadOptions.Metadata; | |
1906 var _body = null; | |
1907 | |
1908 if (profileId == null) { | |
1909 throw new core.ArgumentError("Parameter profileId is required."); | |
1910 } | |
1911 | |
1912 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/bro
wsers'; | |
1913 | |
1914 var _response = _requester.request(_url, | |
1915 "GET", | |
1916 body: _body, | |
1917 queryParams: _queryParams, | |
1918 uploadOptions: _uploadOptions, | |
1919 uploadMedia: _uploadMedia, | |
1920 downloadOptions: _downloadOptions); | |
1921 return _response.then((data) => new BrowsersListResponse.fromJson(data)); | |
1922 } | |
1923 | |
1924 } | |
1925 | |
1926 | |
1927 class CampaignCreativeAssociationsResourceApi { | |
1928 final commons.ApiRequester _requester; | |
1929 | |
1930 CampaignCreativeAssociationsResourceApi(commons.ApiRequester client) : | |
1931 _requester = client; | |
1932 | |
1933 /** | |
1934 * Associates a creative with the specified campaign. This method creates a | |
1935 * default ad with dimensions matching the creative in the campaign if such a | |
1936 * default ad does not exist already. | |
1937 * | |
1938 * [request] - The metadata request object. | |
1939 * | |
1940 * Request parameters: | |
1941 * | |
1942 * [profileId] - User profile ID associated with this request. | |
1943 * | |
1944 * [campaignId] - Campaign ID in this association. | |
1945 * | |
1946 * Completes with a [CampaignCreativeAssociation]. | |
1947 * | |
1948 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
1949 * error. | |
1950 * | |
1951 * If the used [http.Client] completes with an error when making a REST call, | |
1952 * this method will complete with the same error. | |
1953 */ | |
1954 async.Future<CampaignCreativeAssociation> insert(CampaignCreativeAssociation r
equest, core.String profileId, core.String campaignId) { | |
1955 var _url = null; | |
1956 var _queryParams = new core.Map(); | |
1957 var _uploadMedia = null; | |
1958 var _uploadOptions = null; | |
1959 var _downloadOptions = commons.DownloadOptions.Metadata; | |
1960 var _body = null; | |
1961 | |
1962 if (request != null) { | |
1963 _body = convert.JSON.encode((request).toJson()); | |
1964 } | |
1965 if (profileId == null) { | |
1966 throw new core.ArgumentError("Parameter profileId is required."); | |
1967 } | |
1968 if (campaignId == null) { | |
1969 throw new core.ArgumentError("Parameter campaignId is required."); | |
1970 } | |
1971 | |
1972 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/cam
paigns/' + commons.Escaper.ecapeVariable('$campaignId') + '/campaignCreativeAsso
ciations'; | |
1973 | |
1974 var _response = _requester.request(_url, | |
1975 "POST", | |
1976 body: _body, | |
1977 queryParams: _queryParams, | |
1978 uploadOptions: _uploadOptions, | |
1979 uploadMedia: _uploadMedia, | |
1980 downloadOptions: _downloadOptions); | |
1981 return _response.then((data) => new CampaignCreativeAssociation.fromJson(dat
a)); | |
1982 } | |
1983 | |
1984 /** | |
1985 * Retrieves the list of creative IDs associated with the specified campaign. | |
1986 * | |
1987 * Request parameters: | |
1988 * | |
1989 * [profileId] - User profile ID associated with this request. | |
1990 * | |
1991 * [campaignId] - Campaign ID in this association. | |
1992 * | |
1993 * [maxResults] - Maximum number of results to return. | |
1994 * | |
1995 * [pageToken] - Value of the nextPageToken from the previous result page. | |
1996 * | |
1997 * [sortOrder] - Order of sorted results, default is ASCENDING. | |
1998 * Possible string values are: | |
1999 * - "ASCENDING" | |
2000 * - "DESCENDING" | |
2001 * | |
2002 * Completes with a [CampaignCreativeAssociationsListResponse]. | |
2003 * | |
2004 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
2005 * error. | |
2006 * | |
2007 * If the used [http.Client] completes with an error when making a REST call, | |
2008 * this method will complete with the same error. | |
2009 */ | |
2010 async.Future<CampaignCreativeAssociationsListResponse> list(core.String profil
eId, core.String campaignId, {core.int maxResults, core.String pageToken, core.S
tring sortOrder}) { | |
2011 var _url = null; | |
2012 var _queryParams = new core.Map(); | |
2013 var _uploadMedia = null; | |
2014 var _uploadOptions = null; | |
2015 var _downloadOptions = commons.DownloadOptions.Metadata; | |
2016 var _body = null; | |
2017 | |
2018 if (profileId == null) { | |
2019 throw new core.ArgumentError("Parameter profileId is required."); | |
2020 } | |
2021 if (campaignId == null) { | |
2022 throw new core.ArgumentError("Parameter campaignId is required."); | |
2023 } | |
2024 if (maxResults != null) { | |
2025 _queryParams["maxResults"] = ["${maxResults}"]; | |
2026 } | |
2027 if (pageToken != null) { | |
2028 _queryParams["pageToken"] = [pageToken]; | |
2029 } | |
2030 if (sortOrder != null) { | |
2031 _queryParams["sortOrder"] = [sortOrder]; | |
2032 } | |
2033 | |
2034 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/cam
paigns/' + commons.Escaper.ecapeVariable('$campaignId') + '/campaignCreativeAsso
ciations'; | |
2035 | |
2036 var _response = _requester.request(_url, | |
2037 "GET", | |
2038 body: _body, | |
2039 queryParams: _queryParams, | |
2040 uploadOptions: _uploadOptions, | |
2041 uploadMedia: _uploadMedia, | |
2042 downloadOptions: _downloadOptions); | |
2043 return _response.then((data) => new CampaignCreativeAssociationsListResponse
.fromJson(data)); | |
2044 } | |
2045 | |
2046 } | |
2047 | |
2048 | |
2049 class CampaignsResourceApi { | |
2050 final commons.ApiRequester _requester; | |
2051 | |
2052 CampaignsResourceApi(commons.ApiRequester client) : | |
2053 _requester = client; | |
2054 | |
2055 /** | |
2056 * Gets one campaign by ID. | |
2057 * | |
2058 * Request parameters: | |
2059 * | |
2060 * [profileId] - User profile ID associated with this request. | |
2061 * | |
2062 * [id] - Campaign ID. | |
2063 * | |
2064 * Completes with a [Campaign]. | |
2065 * | |
2066 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
2067 * error. | |
2068 * | |
2069 * If the used [http.Client] completes with an error when making a REST call, | |
2070 * this method will complete with the same error. | |
2071 */ | |
2072 async.Future<Campaign> get(core.String profileId, core.String id) { | |
2073 var _url = null; | |
2074 var _queryParams = new core.Map(); | |
2075 var _uploadMedia = null; | |
2076 var _uploadOptions = null; | |
2077 var _downloadOptions = commons.DownloadOptions.Metadata; | |
2078 var _body = null; | |
2079 | |
2080 if (profileId == null) { | |
2081 throw new core.ArgumentError("Parameter profileId is required."); | |
2082 } | |
2083 if (id == null) { | |
2084 throw new core.ArgumentError("Parameter id is required."); | |
2085 } | |
2086 | |
2087 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/cam
paigns/' + commons.Escaper.ecapeVariable('$id'); | |
2088 | |
2089 var _response = _requester.request(_url, | |
2090 "GET", | |
2091 body: _body, | |
2092 queryParams: _queryParams, | |
2093 uploadOptions: _uploadOptions, | |
2094 uploadMedia: _uploadMedia, | |
2095 downloadOptions: _downloadOptions); | |
2096 return _response.then((data) => new Campaign.fromJson(data)); | |
2097 } | |
2098 | |
2099 /** | |
2100 * Inserts a new campaign. | |
2101 * | |
2102 * [request] - The metadata request object. | |
2103 * | |
2104 * Request parameters: | |
2105 * | |
2106 * [profileId] - User profile ID associated with this request. | |
2107 * | |
2108 * [defaultLandingPageName] - Default landing page name for this new campaign. | |
2109 * Must be less than 256 characters long. | |
2110 * | |
2111 * [defaultLandingPageUrl] - Default landing page URL for this new campaign. | |
2112 * | |
2113 * Completes with a [Campaign]. | |
2114 * | |
2115 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
2116 * error. | |
2117 * | |
2118 * If the used [http.Client] completes with an error when making a REST call, | |
2119 * this method will complete with the same error. | |
2120 */ | |
2121 async.Future<Campaign> insert(Campaign request, core.String profileId, core.St
ring defaultLandingPageName, core.String defaultLandingPageUrl) { | |
2122 var _url = null; | |
2123 var _queryParams = new core.Map(); | |
2124 var _uploadMedia = null; | |
2125 var _uploadOptions = null; | |
2126 var _downloadOptions = commons.DownloadOptions.Metadata; | |
2127 var _body = null; | |
2128 | |
2129 if (request != null) { | |
2130 _body = convert.JSON.encode((request).toJson()); | |
2131 } | |
2132 if (profileId == null) { | |
2133 throw new core.ArgumentError("Parameter profileId is required."); | |
2134 } | |
2135 if (defaultLandingPageName == null) { | |
2136 throw new core.ArgumentError("Parameter defaultLandingPageName is required
."); | |
2137 } | |
2138 _queryParams["defaultLandingPageName"] = [defaultLandingPageName]; | |
2139 if (defaultLandingPageUrl == null) { | |
2140 throw new core.ArgumentError("Parameter defaultLandingPageUrl is required.
"); | |
2141 } | |
2142 _queryParams["defaultLandingPageUrl"] = [defaultLandingPageUrl]; | |
2143 | |
2144 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/cam
paigns'; | |
2145 | |
2146 var _response = _requester.request(_url, | |
2147 "POST", | |
2148 body: _body, | |
2149 queryParams: _queryParams, | |
2150 uploadOptions: _uploadOptions, | |
2151 uploadMedia: _uploadMedia, | |
2152 downloadOptions: _downloadOptions); | |
2153 return _response.then((data) => new Campaign.fromJson(data)); | |
2154 } | |
2155 | |
2156 /** | |
2157 * Retrieves a list of campaigns, possibly filtered. | |
2158 * | |
2159 * Request parameters: | |
2160 * | |
2161 * [profileId] - User profile ID associated with this request. | |
2162 * | |
2163 * [advertiserGroupIds] - Select only campaigns whose advertisers belong to | |
2164 * these advertiser groups. | |
2165 * | |
2166 * [advertiserIds] - Select only campaigns that belong to these advertisers. | |
2167 * | |
2168 * [archived] - Select only archived campaigns. Don't set this field to select | |
2169 * both archived and non-archived campaigns. | |
2170 * | |
2171 * [atLeastOneOptimizationActivity] - Select only campaigns that have at least | |
2172 * one optimization activity. | |
2173 * | |
2174 * [excludedIds] - Exclude campaigns with these IDs. | |
2175 * | |
2176 * [ids] - Select only campaigns with these IDs. | |
2177 * | |
2178 * [maxResults] - Maximum number of results to return. | |
2179 * | |
2180 * [overriddenEventTagId] - Select only campaigns that have overridden this | |
2181 * event tag ID. | |
2182 * | |
2183 * [pageToken] - Value of the nextPageToken from the previous result page. | |
2184 * | |
2185 * [searchString] - Allows searching for campaigns by name or ID. Wildcards | |
2186 * (*) are allowed. For example, "campaign*2015" will return campaigns with | |
2187 * names like "campaign June 2015", "campaign April 2015", or simply "campaign | |
2188 * 2015". Most of the searches also add wildcards implicitly at the start and | |
2189 * the end of the search string. For example, a search string of "campaign" | |
2190 * will match campaigns with name "my campaign", "campaign 2015", or simply | |
2191 * "campaign". | |
2192 * | |
2193 * [sortField] - Field by which to sort the list. | |
2194 * Possible string values are: | |
2195 * - "ID" | |
2196 * - "NAME" | |
2197 * | |
2198 * [sortOrder] - Order of sorted results, default is ASCENDING. | |
2199 * Possible string values are: | |
2200 * - "ASCENDING" | |
2201 * - "DESCENDING" | |
2202 * | |
2203 * [subaccountId] - Select only campaigns that belong to this subaccount. | |
2204 * | |
2205 * Completes with a [CampaignsListResponse]. | |
2206 * | |
2207 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
2208 * error. | |
2209 * | |
2210 * If the used [http.Client] completes with an error when making a REST call, | |
2211 * this method will complete with the same error. | |
2212 */ | |
2213 async.Future<CampaignsListResponse> list(core.String profileId, {core.List<cor
e.String> advertiserGroupIds, core.List<core.String> advertiserIds, core.bool ar
chived, core.bool atLeastOneOptimizationActivity, core.List<core.String> exclude
dIds, core.List<core.String> ids, core.int maxResults, core.String overriddenEve
ntTagId, core.String pageToken, core.String searchString, core.String sortField,
core.String sortOrder, core.String subaccountId}) { | |
2214 var _url = null; | |
2215 var _queryParams = new core.Map(); | |
2216 var _uploadMedia = null; | |
2217 var _uploadOptions = null; | |
2218 var _downloadOptions = commons.DownloadOptions.Metadata; | |
2219 var _body = null; | |
2220 | |
2221 if (profileId == null) { | |
2222 throw new core.ArgumentError("Parameter profileId is required."); | |
2223 } | |
2224 if (advertiserGroupIds != null) { | |
2225 _queryParams["advertiserGroupIds"] = advertiserGroupIds; | |
2226 } | |
2227 if (advertiserIds != null) { | |
2228 _queryParams["advertiserIds"] = advertiserIds; | |
2229 } | |
2230 if (archived != null) { | |
2231 _queryParams["archived"] = ["${archived}"]; | |
2232 } | |
2233 if (atLeastOneOptimizationActivity != null) { | |
2234 _queryParams["atLeastOneOptimizationActivity"] = ["${atLeastOneOptimizatio
nActivity}"]; | |
2235 } | |
2236 if (excludedIds != null) { | |
2237 _queryParams["excludedIds"] = excludedIds; | |
2238 } | |
2239 if (ids != null) { | |
2240 _queryParams["ids"] = ids; | |
2241 } | |
2242 if (maxResults != null) { | |
2243 _queryParams["maxResults"] = ["${maxResults}"]; | |
2244 } | |
2245 if (overriddenEventTagId != null) { | |
2246 _queryParams["overriddenEventTagId"] = [overriddenEventTagId]; | |
2247 } | |
2248 if (pageToken != null) { | |
2249 _queryParams["pageToken"] = [pageToken]; | |
2250 } | |
2251 if (searchString != null) { | |
2252 _queryParams["searchString"] = [searchString]; | |
2253 } | |
2254 if (sortField != null) { | |
2255 _queryParams["sortField"] = [sortField]; | |
2256 } | |
2257 if (sortOrder != null) { | |
2258 _queryParams["sortOrder"] = [sortOrder]; | |
2259 } | |
2260 if (subaccountId != null) { | |
2261 _queryParams["subaccountId"] = [subaccountId]; | |
2262 } | |
2263 | |
2264 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/cam
paigns'; | |
2265 | |
2266 var _response = _requester.request(_url, | |
2267 "GET", | |
2268 body: _body, | |
2269 queryParams: _queryParams, | |
2270 uploadOptions: _uploadOptions, | |
2271 uploadMedia: _uploadMedia, | |
2272 downloadOptions: _downloadOptions); | |
2273 return _response.then((data) => new CampaignsListResponse.fromJson(data)); | |
2274 } | |
2275 | |
2276 /** | |
2277 * Updates an existing campaign. This method supports patch semantics. | |
2278 * | |
2279 * [request] - The metadata request object. | |
2280 * | |
2281 * Request parameters: | |
2282 * | |
2283 * [profileId] - User profile ID associated with this request. | |
2284 * | |
2285 * [id] - Campaign ID. | |
2286 * | |
2287 * Completes with a [Campaign]. | |
2288 * | |
2289 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
2290 * error. | |
2291 * | |
2292 * If the used [http.Client] completes with an error when making a REST call, | |
2293 * this method will complete with the same error. | |
2294 */ | |
2295 async.Future<Campaign> patch(Campaign request, core.String profileId, core.Str
ing id) { | |
2296 var _url = null; | |
2297 var _queryParams = new core.Map(); | |
2298 var _uploadMedia = null; | |
2299 var _uploadOptions = null; | |
2300 var _downloadOptions = commons.DownloadOptions.Metadata; | |
2301 var _body = null; | |
2302 | |
2303 if (request != null) { | |
2304 _body = convert.JSON.encode((request).toJson()); | |
2305 } | |
2306 if (profileId == null) { | |
2307 throw new core.ArgumentError("Parameter profileId is required."); | |
2308 } | |
2309 if (id == null) { | |
2310 throw new core.ArgumentError("Parameter id is required."); | |
2311 } | |
2312 _queryParams["id"] = [id]; | |
2313 | |
2314 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/cam
paigns'; | |
2315 | |
2316 var _response = _requester.request(_url, | |
2317 "PATCH", | |
2318 body: _body, | |
2319 queryParams: _queryParams, | |
2320 uploadOptions: _uploadOptions, | |
2321 uploadMedia: _uploadMedia, | |
2322 downloadOptions: _downloadOptions); | |
2323 return _response.then((data) => new Campaign.fromJson(data)); | |
2324 } | |
2325 | |
2326 /** | |
2327 * Updates an existing campaign. | |
2328 * | |
2329 * [request] - The metadata request object. | |
2330 * | |
2331 * Request parameters: | |
2332 * | |
2333 * [profileId] - User profile ID associated with this request. | |
2334 * | |
2335 * Completes with a [Campaign]. | |
2336 * | |
2337 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
2338 * error. | |
2339 * | |
2340 * If the used [http.Client] completes with an error when making a REST call, | |
2341 * this method will complete with the same error. | |
2342 */ | |
2343 async.Future<Campaign> update(Campaign request, core.String profileId) { | |
2344 var _url = null; | |
2345 var _queryParams = new core.Map(); | |
2346 var _uploadMedia = null; | |
2347 var _uploadOptions = null; | |
2348 var _downloadOptions = commons.DownloadOptions.Metadata; | |
2349 var _body = null; | |
2350 | |
2351 if (request != null) { | |
2352 _body = convert.JSON.encode((request).toJson()); | |
2353 } | |
2354 if (profileId == null) { | |
2355 throw new core.ArgumentError("Parameter profileId is required."); | |
2356 } | |
2357 | |
2358 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/cam
paigns'; | |
2359 | |
2360 var _response = _requester.request(_url, | |
2361 "PUT", | |
2362 body: _body, | |
2363 queryParams: _queryParams, | |
2364 uploadOptions: _uploadOptions, | |
2365 uploadMedia: _uploadMedia, | |
2366 downloadOptions: _downloadOptions); | |
2367 return _response.then((data) => new Campaign.fromJson(data)); | |
2368 } | |
2369 | |
2370 } | |
2371 | |
2372 | |
2373 class ChangeLogsResourceApi { | |
2374 final commons.ApiRequester _requester; | |
2375 | |
2376 ChangeLogsResourceApi(commons.ApiRequester client) : | |
2377 _requester = client; | |
2378 | |
2379 /** | |
2380 * Gets one change log by ID. | |
2381 * | |
2382 * Request parameters: | |
2383 * | |
2384 * [profileId] - User profile ID associated with this request. | |
2385 * | |
2386 * [id] - Change log ID. | |
2387 * | |
2388 * Completes with a [ChangeLog]. | |
2389 * | |
2390 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
2391 * error. | |
2392 * | |
2393 * If the used [http.Client] completes with an error when making a REST call, | |
2394 * this method will complete with the same error. | |
2395 */ | |
2396 async.Future<ChangeLog> get(core.String profileId, core.String id) { | |
2397 var _url = null; | |
2398 var _queryParams = new core.Map(); | |
2399 var _uploadMedia = null; | |
2400 var _uploadOptions = null; | |
2401 var _downloadOptions = commons.DownloadOptions.Metadata; | |
2402 var _body = null; | |
2403 | |
2404 if (profileId == null) { | |
2405 throw new core.ArgumentError("Parameter profileId is required."); | |
2406 } | |
2407 if (id == null) { | |
2408 throw new core.ArgumentError("Parameter id is required."); | |
2409 } | |
2410 | |
2411 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/cha
ngeLogs/' + commons.Escaper.ecapeVariable('$id'); | |
2412 | |
2413 var _response = _requester.request(_url, | |
2414 "GET", | |
2415 body: _body, | |
2416 queryParams: _queryParams, | |
2417 uploadOptions: _uploadOptions, | |
2418 uploadMedia: _uploadMedia, | |
2419 downloadOptions: _downloadOptions); | |
2420 return _response.then((data) => new ChangeLog.fromJson(data)); | |
2421 } | |
2422 | |
2423 /** | |
2424 * Retrieves a list of change logs. | |
2425 * | |
2426 * Request parameters: | |
2427 * | |
2428 * [profileId] - User profile ID associated with this request. | |
2429 * | |
2430 * [action] - Select only change logs with the specified action. | |
2431 * Possible string values are: | |
2432 * - "ACTION_ADD" | |
2433 * - "ACTION_ASSIGN" | |
2434 * - "ACTION_ASSOCIATE" | |
2435 * - "ACTION_CREATE" | |
2436 * - "ACTION_DELETE" | |
2437 * - "ACTION_DISABLE" | |
2438 * - "ACTION_EMAIL_TAGS" | |
2439 * - "ACTION_ENABLE" | |
2440 * - "ACTION_LINK" | |
2441 * - "ACTION_MARK_AS_DEFAULT" | |
2442 * - "ACTION_PUSH" | |
2443 * - "ACTION_REMOVE" | |
2444 * - "ACTION_SEND" | |
2445 * - "ACTION_SHARE" | |
2446 * - "ACTION_UNASSIGN" | |
2447 * - "ACTION_UNLINK" | |
2448 * - "ACTION_UPDATE" | |
2449 * | |
2450 * [ids] - Select only change logs with these IDs. | |
2451 * | |
2452 * [maxChangeTime] - Select only change logs whose change time is before the | |
2453 * specified maxChangeTime.The time should be formatted as an RFC3339 | |
2454 * date/time string. For example, for 10:54 PM on July 18th, 2015, in the | |
2455 * America/New York time zone, the format is "2015-07-18T22:54:00-04:00". In | |
2456 * other words, the year, month, day, the letter T, the hour (24-hour clock | |
2457 * system), minute, second, and then the time zone offset. | |
2458 * | |
2459 * [maxResults] - Maximum number of results to return. | |
2460 * | |
2461 * [minChangeTime] - Select only change logs whose change time is before the | |
2462 * specified minChangeTime.The time should be formatted as an RFC3339 | |
2463 * date/time string. For example, for 10:54 PM on July 18th, 2015, in the | |
2464 * America/New York time zone, the format is "2015-07-18T22:54:00-04:00". In | |
2465 * other words, the year, month, day, the letter T, the hour (24-hour clock | |
2466 * system), minute, second, and then the time zone offset. | |
2467 * | |
2468 * [objectIds] - Select only change logs with these object IDs. | |
2469 * | |
2470 * [objectType] - Select only change logs with the specified object type. | |
2471 * Possible string values are: | |
2472 * - "OBJECT_ACCOUNT" | |
2473 * - "OBJECT_ACCOUNT_BILLING_FEATURE" | |
2474 * - "OBJECT_AD" | |
2475 * - "OBJECT_ADVERTISER" | |
2476 * - "OBJECT_ADVERTISER_GROUP" | |
2477 * - "OBJECT_BILLING_ACCOUNT_GROUP" | |
2478 * - "OBJECT_BILLING_FEATURE" | |
2479 * - "OBJECT_BILLING_MINIMUM_FEE" | |
2480 * - "OBJECT_BILLING_PROFILE" | |
2481 * - "OBJECT_CAMPAIGN" | |
2482 * - "OBJECT_CONTENT_CATEGORY" | |
2483 * - "OBJECT_CREATIVE" | |
2484 * - "OBJECT_CREATIVE_ASSET" | |
2485 * - "OBJECT_CREATIVE_BUNDLE" | |
2486 * - "OBJECT_CREATIVE_FIELD" | |
2487 * - "OBJECT_CREATIVE_GROUP" | |
2488 * - "OBJECT_DFA_SITE" | |
2489 * - "OBJECT_EVENT_TAG" | |
2490 * - "OBJECT_FLOODLIGHT_ACTIVITY_GROUP" | |
2491 * - "OBJECT_FLOODLIGHT_ACTVITY" | |
2492 * - "OBJECT_FLOODLIGHT_CONFIGURATION" | |
2493 * - "OBJECT_INSTREAM_CREATIVE" | |
2494 * - "OBJECT_LANDING_PAGE" | |
2495 * - "OBJECT_MEDIA_ORDER" | |
2496 * - "OBJECT_PLACEMENT" | |
2497 * - "OBJECT_PLACEMENT_STRATEGY" | |
2498 * - "OBJECT_PLAYSTORE_LINK" | |
2499 * - "OBJECT_PROVIDED_LIST_CLIENT" | |
2500 * - "OBJECT_RATE_CARD" | |
2501 * - "OBJECT_REMARKETING_LIST" | |
2502 * - "OBJECT_RICHMEDIA_CREATIVE" | |
2503 * - "OBJECT_SD_SITE" | |
2504 * - "OBJECT_SIZE" | |
2505 * - "OBJECT_SUBACCOUNT" | |
2506 * - "OBJECT_TARGETING_TEMPLATE" | |
2507 * - "OBJECT_USER_PROFILE" | |
2508 * - "OBJECT_USER_PROFILE_FILTER" | |
2509 * - "OBJECT_USER_ROLE" | |
2510 * | |
2511 * [pageToken] - Value of the nextPageToken from the previous result page. | |
2512 * | |
2513 * [searchString] - Select only change logs whose object ID, user name, old or | |
2514 * new values match the search string. | |
2515 * | |
2516 * [userProfileIds] - Select only change logs with these user profile IDs. | |
2517 * | |
2518 * Completes with a [ChangeLogsListResponse]. | |
2519 * | |
2520 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
2521 * error. | |
2522 * | |
2523 * If the used [http.Client] completes with an error when making a REST call, | |
2524 * this method will complete with the same error. | |
2525 */ | |
2526 async.Future<ChangeLogsListResponse> list(core.String profileId, {core.String
action, core.List<core.String> ids, core.String maxChangeTime, core.int maxResul
ts, core.String minChangeTime, core.List<core.String> objectIds, core.String obj
ectType, core.String pageToken, core.String searchString, core.List<core.String>
userProfileIds}) { | |
2527 var _url = null; | |
2528 var _queryParams = new core.Map(); | |
2529 var _uploadMedia = null; | |
2530 var _uploadOptions = null; | |
2531 var _downloadOptions = commons.DownloadOptions.Metadata; | |
2532 var _body = null; | |
2533 | |
2534 if (profileId == null) { | |
2535 throw new core.ArgumentError("Parameter profileId is required."); | |
2536 } | |
2537 if (action != null) { | |
2538 _queryParams["action"] = [action]; | |
2539 } | |
2540 if (ids != null) { | |
2541 _queryParams["ids"] = ids; | |
2542 } | |
2543 if (maxChangeTime != null) { | |
2544 _queryParams["maxChangeTime"] = [maxChangeTime]; | |
2545 } | |
2546 if (maxResults != null) { | |
2547 _queryParams["maxResults"] = ["${maxResults}"]; | |
2548 } | |
2549 if (minChangeTime != null) { | |
2550 _queryParams["minChangeTime"] = [minChangeTime]; | |
2551 } | |
2552 if (objectIds != null) { | |
2553 _queryParams["objectIds"] = objectIds; | |
2554 } | |
2555 if (objectType != null) { | |
2556 _queryParams["objectType"] = [objectType]; | |
2557 } | |
2558 if (pageToken != null) { | |
2559 _queryParams["pageToken"] = [pageToken]; | |
2560 } | |
2561 if (searchString != null) { | |
2562 _queryParams["searchString"] = [searchString]; | |
2563 } | |
2564 if (userProfileIds != null) { | |
2565 _queryParams["userProfileIds"] = userProfileIds; | |
2566 } | |
2567 | |
2568 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/cha
ngeLogs'; | |
2569 | |
2570 var _response = _requester.request(_url, | |
2571 "GET", | |
2572 body: _body, | |
2573 queryParams: _queryParams, | |
2574 uploadOptions: _uploadOptions, | |
2575 uploadMedia: _uploadMedia, | |
2576 downloadOptions: _downloadOptions); | |
2577 return _response.then((data) => new ChangeLogsListResponse.fromJson(data)); | |
2578 } | |
2579 | |
2580 } | |
2581 | |
2582 | |
2583 class CitiesResourceApi { | |
2584 final commons.ApiRequester _requester; | |
2585 | |
2586 CitiesResourceApi(commons.ApiRequester client) : | |
2587 _requester = client; | |
2588 | |
2589 /** | |
2590 * Retrieves a list of cities, possibly filtered. | |
2591 * | |
2592 * Request parameters: | |
2593 * | |
2594 * [profileId] - User profile ID associated with this request. | |
2595 * | |
2596 * [countryDartIds] - Select only cities from these countries. | |
2597 * | |
2598 * [dartIds] - Select only cities with these DART IDs. | |
2599 * | |
2600 * [namePrefix] - Select only cities with names starting with this prefix. | |
2601 * | |
2602 * [regionDartIds] - Select only cities from these regions. | |
2603 * | |
2604 * Completes with a [CitiesListResponse]. | |
2605 * | |
2606 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
2607 * error. | |
2608 * | |
2609 * If the used [http.Client] completes with an error when making a REST call, | |
2610 * this method will complete with the same error. | |
2611 */ | |
2612 async.Future<CitiesListResponse> list(core.String profileId, {core.List<core.S
tring> countryDartIds, core.List<core.String> dartIds, core.String namePrefix, c
ore.List<core.String> regionDartIds}) { | |
2613 var _url = null; | |
2614 var _queryParams = new core.Map(); | |
2615 var _uploadMedia = null; | |
2616 var _uploadOptions = null; | |
2617 var _downloadOptions = commons.DownloadOptions.Metadata; | |
2618 var _body = null; | |
2619 | |
2620 if (profileId == null) { | |
2621 throw new core.ArgumentError("Parameter profileId is required."); | |
2622 } | |
2623 if (countryDartIds != null) { | |
2624 _queryParams["countryDartIds"] = countryDartIds; | |
2625 } | |
2626 if (dartIds != null) { | |
2627 _queryParams["dartIds"] = dartIds; | |
2628 } | |
2629 if (namePrefix != null) { | |
2630 _queryParams["namePrefix"] = [namePrefix]; | |
2631 } | |
2632 if (regionDartIds != null) { | |
2633 _queryParams["regionDartIds"] = regionDartIds; | |
2634 } | |
2635 | |
2636 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/cit
ies'; | |
2637 | |
2638 var _response = _requester.request(_url, | |
2639 "GET", | |
2640 body: _body, | |
2641 queryParams: _queryParams, | |
2642 uploadOptions: _uploadOptions, | |
2643 uploadMedia: _uploadMedia, | |
2644 downloadOptions: _downloadOptions); | |
2645 return _response.then((data) => new CitiesListResponse.fromJson(data)); | |
2646 } | |
2647 | |
2648 } | |
2649 | |
2650 | |
2651 class ConnectionTypesResourceApi { | |
2652 final commons.ApiRequester _requester; | |
2653 | |
2654 ConnectionTypesResourceApi(commons.ApiRequester client) : | |
2655 _requester = client; | |
2656 | |
2657 /** | |
2658 * Gets one connection type by ID. | |
2659 * | |
2660 * Request parameters: | |
2661 * | |
2662 * [profileId] - User profile ID associated with this request. | |
2663 * | |
2664 * [id] - Connection type ID. | |
2665 * | |
2666 * Completes with a [ConnectionType]. | |
2667 * | |
2668 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
2669 * error. | |
2670 * | |
2671 * If the used [http.Client] completes with an error when making a REST call, | |
2672 * this method will complete with the same error. | |
2673 */ | |
2674 async.Future<ConnectionType> get(core.String profileId, core.String id) { | |
2675 var _url = null; | |
2676 var _queryParams = new core.Map(); | |
2677 var _uploadMedia = null; | |
2678 var _uploadOptions = null; | |
2679 var _downloadOptions = commons.DownloadOptions.Metadata; | |
2680 var _body = null; | |
2681 | |
2682 if (profileId == null) { | |
2683 throw new core.ArgumentError("Parameter profileId is required."); | |
2684 } | |
2685 if (id == null) { | |
2686 throw new core.ArgumentError("Parameter id is required."); | |
2687 } | |
2688 | |
2689 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/con
nectionTypes/' + commons.Escaper.ecapeVariable('$id'); | |
2690 | |
2691 var _response = _requester.request(_url, | |
2692 "GET", | |
2693 body: _body, | |
2694 queryParams: _queryParams, | |
2695 uploadOptions: _uploadOptions, | |
2696 uploadMedia: _uploadMedia, | |
2697 downloadOptions: _downloadOptions); | |
2698 return _response.then((data) => new ConnectionType.fromJson(data)); | |
2699 } | |
2700 | |
2701 /** | |
2702 * Retrieves a list of connection types. | |
2703 * | |
2704 * Request parameters: | |
2705 * | |
2706 * [profileId] - User profile ID associated with this request. | |
2707 * | |
2708 * Completes with a [ConnectionTypesListResponse]. | |
2709 * | |
2710 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
2711 * error. | |
2712 * | |
2713 * If the used [http.Client] completes with an error when making a REST call, | |
2714 * this method will complete with the same error. | |
2715 */ | |
2716 async.Future<ConnectionTypesListResponse> list(core.String profileId) { | |
2717 var _url = null; | |
2718 var _queryParams = new core.Map(); | |
2719 var _uploadMedia = null; | |
2720 var _uploadOptions = null; | |
2721 var _downloadOptions = commons.DownloadOptions.Metadata; | |
2722 var _body = null; | |
2723 | |
2724 if (profileId == null) { | |
2725 throw new core.ArgumentError("Parameter profileId is required."); | |
2726 } | |
2727 | |
2728 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/con
nectionTypes'; | |
2729 | |
2730 var _response = _requester.request(_url, | |
2731 "GET", | |
2732 body: _body, | |
2733 queryParams: _queryParams, | |
2734 uploadOptions: _uploadOptions, | |
2735 uploadMedia: _uploadMedia, | |
2736 downloadOptions: _downloadOptions); | |
2737 return _response.then((data) => new ConnectionTypesListResponse.fromJson(dat
a)); | |
2738 } | |
2739 | |
2740 } | |
2741 | |
2742 | |
2743 class ContentCategoriesResourceApi { | |
2744 final commons.ApiRequester _requester; | |
2745 | |
2746 ContentCategoriesResourceApi(commons.ApiRequester client) : | |
2747 _requester = client; | |
2748 | |
2749 /** | |
2750 * Deletes an existing content category. | |
2751 * | |
2752 * Request parameters: | |
2753 * | |
2754 * [profileId] - User profile ID associated with this request. | |
2755 * | |
2756 * [id] - Content category ID. | |
2757 * | |
2758 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
2759 * error. | |
2760 * | |
2761 * If the used [http.Client] completes with an error when making a REST call, | |
2762 * this method will complete with the same error. | |
2763 */ | |
2764 async.Future delete(core.String profileId, core.String id) { | |
2765 var _url = null; | |
2766 var _queryParams = new core.Map(); | |
2767 var _uploadMedia = null; | |
2768 var _uploadOptions = null; | |
2769 var _downloadOptions = commons.DownloadOptions.Metadata; | |
2770 var _body = null; | |
2771 | |
2772 if (profileId == null) { | |
2773 throw new core.ArgumentError("Parameter profileId is required."); | |
2774 } | |
2775 if (id == null) { | |
2776 throw new core.ArgumentError("Parameter id is required."); | |
2777 } | |
2778 | |
2779 _downloadOptions = null; | |
2780 | |
2781 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/con
tentCategories/' + commons.Escaper.ecapeVariable('$id'); | |
2782 | |
2783 var _response = _requester.request(_url, | |
2784 "DELETE", | |
2785 body: _body, | |
2786 queryParams: _queryParams, | |
2787 uploadOptions: _uploadOptions, | |
2788 uploadMedia: _uploadMedia, | |
2789 downloadOptions: _downloadOptions); | |
2790 return _response.then((data) => null); | |
2791 } | |
2792 | |
2793 /** | |
2794 * Gets one content category by ID. | |
2795 * | |
2796 * Request parameters: | |
2797 * | |
2798 * [profileId] - User profile ID associated with this request. | |
2799 * | |
2800 * [id] - Content category ID. | |
2801 * | |
2802 * Completes with a [ContentCategory]. | |
2803 * | |
2804 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
2805 * error. | |
2806 * | |
2807 * If the used [http.Client] completes with an error when making a REST call, | |
2808 * this method will complete with the same error. | |
2809 */ | |
2810 async.Future<ContentCategory> get(core.String profileId, core.String id) { | |
2811 var _url = null; | |
2812 var _queryParams = new core.Map(); | |
2813 var _uploadMedia = null; | |
2814 var _uploadOptions = null; | |
2815 var _downloadOptions = commons.DownloadOptions.Metadata; | |
2816 var _body = null; | |
2817 | |
2818 if (profileId == null) { | |
2819 throw new core.ArgumentError("Parameter profileId is required."); | |
2820 } | |
2821 if (id == null) { | |
2822 throw new core.ArgumentError("Parameter id is required."); | |
2823 } | |
2824 | |
2825 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/con
tentCategories/' + commons.Escaper.ecapeVariable('$id'); | |
2826 | |
2827 var _response = _requester.request(_url, | |
2828 "GET", | |
2829 body: _body, | |
2830 queryParams: _queryParams, | |
2831 uploadOptions: _uploadOptions, | |
2832 uploadMedia: _uploadMedia, | |
2833 downloadOptions: _downloadOptions); | |
2834 return _response.then((data) => new ContentCategory.fromJson(data)); | |
2835 } | |
2836 | |
2837 /** | |
2838 * Inserts a new content category. | |
2839 * | |
2840 * [request] - The metadata request object. | |
2841 * | |
2842 * Request parameters: | |
2843 * | |
2844 * [profileId] - User profile ID associated with this request. | |
2845 * | |
2846 * Completes with a [ContentCategory]. | |
2847 * | |
2848 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
2849 * error. | |
2850 * | |
2851 * If the used [http.Client] completes with an error when making a REST call, | |
2852 * this method will complete with the same error. | |
2853 */ | |
2854 async.Future<ContentCategory> insert(ContentCategory request, core.String prof
ileId) { | |
2855 var _url = null; | |
2856 var _queryParams = new core.Map(); | |
2857 var _uploadMedia = null; | |
2858 var _uploadOptions = null; | |
2859 var _downloadOptions = commons.DownloadOptions.Metadata; | |
2860 var _body = null; | |
2861 | |
2862 if (request != null) { | |
2863 _body = convert.JSON.encode((request).toJson()); | |
2864 } | |
2865 if (profileId == null) { | |
2866 throw new core.ArgumentError("Parameter profileId is required."); | |
2867 } | |
2868 | |
2869 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/con
tentCategories'; | |
2870 | |
2871 var _response = _requester.request(_url, | |
2872 "POST", | |
2873 body: _body, | |
2874 queryParams: _queryParams, | |
2875 uploadOptions: _uploadOptions, | |
2876 uploadMedia: _uploadMedia, | |
2877 downloadOptions: _downloadOptions); | |
2878 return _response.then((data) => new ContentCategory.fromJson(data)); | |
2879 } | |
2880 | |
2881 /** | |
2882 * Retrieves a list of content categories, possibly filtered. | |
2883 * | |
2884 * Request parameters: | |
2885 * | |
2886 * [profileId] - User profile ID associated with this request. | |
2887 * | |
2888 * [ids] - Select only content categories with these IDs. | |
2889 * | |
2890 * [maxResults] - Maximum number of results to return. | |
2891 * | |
2892 * [pageToken] - Value of the nextPageToken from the previous result page. | |
2893 * | |
2894 * [searchString] - Allows searching for objects by name or ID. Wildcards (*) | |
2895 * are allowed. For example, "contentcategory*2015" will return objects with | |
2896 * names like "contentcategory June 2015", "contentcategory April 2015", or | |
2897 * simply "contentcategory 2015". Most of the searches also add wildcards | |
2898 * implicitly at the start and the end of the search string. For example, a | |
2899 * search string of "contentcategory" will match objects with name "my | |
2900 * contentcategory", "contentcategory 2015", or simply "contentcategory". | |
2901 * | |
2902 * [sortField] - Field by which to sort the list. | |
2903 * Possible string values are: | |
2904 * - "ID" | |
2905 * - "NAME" | |
2906 * | |
2907 * [sortOrder] - Order of sorted results, default is ASCENDING. | |
2908 * Possible string values are: | |
2909 * - "ASCENDING" | |
2910 * - "DESCENDING" | |
2911 * | |
2912 * Completes with a [ContentCategoriesListResponse]. | |
2913 * | |
2914 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
2915 * error. | |
2916 * | |
2917 * If the used [http.Client] completes with an error when making a REST call, | |
2918 * this method will complete with the same error. | |
2919 */ | |
2920 async.Future<ContentCategoriesListResponse> list(core.String profileId, {core.
List<core.String> ids, core.int maxResults, core.String pageToken, core.String s
earchString, core.String sortField, core.String sortOrder}) { | |
2921 var _url = null; | |
2922 var _queryParams = new core.Map(); | |
2923 var _uploadMedia = null; | |
2924 var _uploadOptions = null; | |
2925 var _downloadOptions = commons.DownloadOptions.Metadata; | |
2926 var _body = null; | |
2927 | |
2928 if (profileId == null) { | |
2929 throw new core.ArgumentError("Parameter profileId is required."); | |
2930 } | |
2931 if (ids != null) { | |
2932 _queryParams["ids"] = ids; | |
2933 } | |
2934 if (maxResults != null) { | |
2935 _queryParams["maxResults"] = ["${maxResults}"]; | |
2936 } | |
2937 if (pageToken != null) { | |
2938 _queryParams["pageToken"] = [pageToken]; | |
2939 } | |
2940 if (searchString != null) { | |
2941 _queryParams["searchString"] = [searchString]; | |
2942 } | |
2943 if (sortField != null) { | |
2944 _queryParams["sortField"] = [sortField]; | |
2945 } | |
2946 if (sortOrder != null) { | |
2947 _queryParams["sortOrder"] = [sortOrder]; | |
2948 } | |
2949 | |
2950 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/con
tentCategories'; | |
2951 | |
2952 var _response = _requester.request(_url, | |
2953 "GET", | |
2954 body: _body, | |
2955 queryParams: _queryParams, | |
2956 uploadOptions: _uploadOptions, | |
2957 uploadMedia: _uploadMedia, | |
2958 downloadOptions: _downloadOptions); | |
2959 return _response.then((data) => new ContentCategoriesListResponse.fromJson(d
ata)); | |
2960 } | |
2961 | |
2962 /** | |
2963 * Updates an existing content category. This method supports patch semantics. | |
2964 * | |
2965 * [request] - The metadata request object. | |
2966 * | |
2967 * Request parameters: | |
2968 * | |
2969 * [profileId] - User profile ID associated with this request. | |
2970 * | |
2971 * [id] - Content category ID. | |
2972 * | |
2973 * Completes with a [ContentCategory]. | |
2974 * | |
2975 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
2976 * error. | |
2977 * | |
2978 * If the used [http.Client] completes with an error when making a REST call, | |
2979 * this method will complete with the same error. | |
2980 */ | |
2981 async.Future<ContentCategory> patch(ContentCategory request, core.String profi
leId, core.String id) { | |
2982 var _url = null; | |
2983 var _queryParams = new core.Map(); | |
2984 var _uploadMedia = null; | |
2985 var _uploadOptions = null; | |
2986 var _downloadOptions = commons.DownloadOptions.Metadata; | |
2987 var _body = null; | |
2988 | |
2989 if (request != null) { | |
2990 _body = convert.JSON.encode((request).toJson()); | |
2991 } | |
2992 if (profileId == null) { | |
2993 throw new core.ArgumentError("Parameter profileId is required."); | |
2994 } | |
2995 if (id == null) { | |
2996 throw new core.ArgumentError("Parameter id is required."); | |
2997 } | |
2998 _queryParams["id"] = [id]; | |
2999 | |
3000 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/con
tentCategories'; | |
3001 | |
3002 var _response = _requester.request(_url, | |
3003 "PATCH", | |
3004 body: _body, | |
3005 queryParams: _queryParams, | |
3006 uploadOptions: _uploadOptions, | |
3007 uploadMedia: _uploadMedia, | |
3008 downloadOptions: _downloadOptions); | |
3009 return _response.then((data) => new ContentCategory.fromJson(data)); | |
3010 } | |
3011 | |
3012 /** | |
3013 * Updates an existing content category. | |
3014 * | |
3015 * [request] - The metadata request object. | |
3016 * | |
3017 * Request parameters: | |
3018 * | |
3019 * [profileId] - User profile ID associated with this request. | |
3020 * | |
3021 * Completes with a [ContentCategory]. | |
3022 * | |
3023 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
3024 * error. | |
3025 * | |
3026 * If the used [http.Client] completes with an error when making a REST call, | |
3027 * this method will complete with the same error. | |
3028 */ | |
3029 async.Future<ContentCategory> update(ContentCategory request, core.String prof
ileId) { | |
3030 var _url = null; | |
3031 var _queryParams = new core.Map(); | |
3032 var _uploadMedia = null; | |
3033 var _uploadOptions = null; | |
3034 var _downloadOptions = commons.DownloadOptions.Metadata; | |
3035 var _body = null; | |
3036 | |
3037 if (request != null) { | |
3038 _body = convert.JSON.encode((request).toJson()); | |
3039 } | |
3040 if (profileId == null) { | |
3041 throw new core.ArgumentError("Parameter profileId is required."); | |
3042 } | |
3043 | |
3044 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/con
tentCategories'; | |
3045 | |
3046 var _response = _requester.request(_url, | |
3047 "PUT", | |
3048 body: _body, | |
3049 queryParams: _queryParams, | |
3050 uploadOptions: _uploadOptions, | |
3051 uploadMedia: _uploadMedia, | |
3052 downloadOptions: _downloadOptions); | |
3053 return _response.then((data) => new ContentCategory.fromJson(data)); | |
3054 } | |
3055 | |
3056 } | |
3057 | |
3058 | |
3059 class CountriesResourceApi { | |
3060 final commons.ApiRequester _requester; | |
3061 | |
3062 CountriesResourceApi(commons.ApiRequester client) : | |
3063 _requester = client; | |
3064 | |
3065 /** | |
3066 * Gets one country by ID. | |
3067 * | |
3068 * Request parameters: | |
3069 * | |
3070 * [profileId] - User profile ID associated with this request. | |
3071 * | |
3072 * [dartId] - Country DART ID. | |
3073 * | |
3074 * Completes with a [Country]. | |
3075 * | |
3076 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
3077 * error. | |
3078 * | |
3079 * If the used [http.Client] completes with an error when making a REST call, | |
3080 * this method will complete with the same error. | |
3081 */ | |
3082 async.Future<Country> get(core.String profileId, core.String dartId) { | |
3083 var _url = null; | |
3084 var _queryParams = new core.Map(); | |
3085 var _uploadMedia = null; | |
3086 var _uploadOptions = null; | |
3087 var _downloadOptions = commons.DownloadOptions.Metadata; | |
3088 var _body = null; | |
3089 | |
3090 if (profileId == null) { | |
3091 throw new core.ArgumentError("Parameter profileId is required."); | |
3092 } | |
3093 if (dartId == null) { | |
3094 throw new core.ArgumentError("Parameter dartId is required."); | |
3095 } | |
3096 | |
3097 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/cou
ntries/' + commons.Escaper.ecapeVariable('$dartId'); | |
3098 | |
3099 var _response = _requester.request(_url, | |
3100 "GET", | |
3101 body: _body, | |
3102 queryParams: _queryParams, | |
3103 uploadOptions: _uploadOptions, | |
3104 uploadMedia: _uploadMedia, | |
3105 downloadOptions: _downloadOptions); | |
3106 return _response.then((data) => new Country.fromJson(data)); | |
3107 } | |
3108 | |
3109 /** | |
3110 * Retrieves a list of countries. | |
3111 * | |
3112 * Request parameters: | |
3113 * | |
3114 * [profileId] - User profile ID associated with this request. | |
3115 * | |
3116 * Completes with a [CountriesListResponse]. | |
3117 * | |
3118 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
3119 * error. | |
3120 * | |
3121 * If the used [http.Client] completes with an error when making a REST call, | |
3122 * this method will complete with the same error. | |
3123 */ | |
3124 async.Future<CountriesListResponse> list(core.String profileId) { | |
3125 var _url = null; | |
3126 var _queryParams = new core.Map(); | |
3127 var _uploadMedia = null; | |
3128 var _uploadOptions = null; | |
3129 var _downloadOptions = commons.DownloadOptions.Metadata; | |
3130 var _body = null; | |
3131 | |
3132 if (profileId == null) { | |
3133 throw new core.ArgumentError("Parameter profileId is required."); | |
3134 } | |
3135 | |
3136 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/cou
ntries'; | |
3137 | |
3138 var _response = _requester.request(_url, | |
3139 "GET", | |
3140 body: _body, | |
3141 queryParams: _queryParams, | |
3142 uploadOptions: _uploadOptions, | |
3143 uploadMedia: _uploadMedia, | |
3144 downloadOptions: _downloadOptions); | |
3145 return _response.then((data) => new CountriesListResponse.fromJson(data)); | |
3146 } | |
3147 | |
3148 } | |
3149 | |
3150 | |
3151 class CreativeAssetsResourceApi { | |
3152 final commons.ApiRequester _requester; | |
3153 | |
3154 CreativeAssetsResourceApi(commons.ApiRequester client) : | |
3155 _requester = client; | |
3156 | |
3157 /** | |
3158 * Inserts a new creative asset. | |
3159 * | |
3160 * [request] - The metadata request object. | |
3161 * | |
3162 * Request parameters: | |
3163 * | |
3164 * [profileId] - User profile ID associated with this request. | |
3165 * | |
3166 * [advertiserId] - Advertiser ID of this creative. This is a required field. | |
3167 * | |
3168 * [uploadMedia] - The media to upload. | |
3169 * | |
3170 * [uploadOptions] - Options for the media upload. Streaming Media without the | |
3171 * length being known ahead of time is only supported via resumable uploads. | |
3172 * | |
3173 * Completes with a [CreativeAssetMetadata]. | |
3174 * | |
3175 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
3176 * error. | |
3177 * | |
3178 * If the used [http.Client] completes with an error when making a REST call, | |
3179 * this method will complete with the same error. | |
3180 */ | |
3181 async.Future<CreativeAssetMetadata> insert(CreativeAssetMetadata request, core
.String profileId, core.String advertiserId, {commons.UploadOptions uploadOption
s : commons.UploadOptions.Default, commons.Media uploadMedia}) { | |
3182 var _url = null; | |
3183 var _queryParams = new core.Map(); | |
3184 var _uploadMedia = null; | |
3185 var _uploadOptions = null; | |
3186 var _downloadOptions = commons.DownloadOptions.Metadata; | |
3187 var _body = null; | |
3188 | |
3189 if (request != null) { | |
3190 _body = convert.JSON.encode((request).toJson()); | |
3191 } | |
3192 if (profileId == null) { | |
3193 throw new core.ArgumentError("Parameter profileId is required."); | |
3194 } | |
3195 if (advertiserId == null) { | |
3196 throw new core.ArgumentError("Parameter advertiserId is required."); | |
3197 } | |
3198 | |
3199 _uploadMedia = uploadMedia; | |
3200 _uploadOptions = uploadOptions; | |
3201 | |
3202 if (_uploadMedia == null) { | |
3203 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/c
reativeAssets/' + commons.Escaper.ecapeVariable('$advertiserId') + '/creativeAss
ets'; | |
3204 } else if (_uploadOptions is commons.ResumableUploadOptions) { | |
3205 _url = '/resumable/upload/dfareporting/v2.3/userprofiles/' + commons.Escap
er.ecapeVariable('$profileId') + '/creativeAssets/' + commons.Escaper.ecapeVaria
ble('$advertiserId') + '/creativeAssets'; | |
3206 } else { | |
3207 _url = '/upload/dfareporting/v2.3/userprofiles/' + commons.Escaper.ecapeVa
riable('$profileId') + '/creativeAssets/' + commons.Escaper.ecapeVariable('$adve
rtiserId') + '/creativeAssets'; | |
3208 } | |
3209 | |
3210 | |
3211 var _response = _requester.request(_url, | |
3212 "POST", | |
3213 body: _body, | |
3214 queryParams: _queryParams, | |
3215 uploadOptions: _uploadOptions, | |
3216 uploadMedia: _uploadMedia, | |
3217 downloadOptions: _downloadOptions); | |
3218 return _response.then((data) => new CreativeAssetMetadata.fromJson(data)); | |
3219 } | |
3220 | |
3221 } | |
3222 | |
3223 | |
3224 class CreativeFieldValuesResourceApi { | |
3225 final commons.ApiRequester _requester; | |
3226 | |
3227 CreativeFieldValuesResourceApi(commons.ApiRequester client) : | |
3228 _requester = client; | |
3229 | |
3230 /** | |
3231 * Deletes an existing creative field value. | |
3232 * | |
3233 * Request parameters: | |
3234 * | |
3235 * [profileId] - User profile ID associated with this request. | |
3236 * | |
3237 * [creativeFieldId] - Creative field ID for this creative field value. | |
3238 * | |
3239 * [id] - Creative Field Value ID | |
3240 * | |
3241 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
3242 * error. | |
3243 * | |
3244 * If the used [http.Client] completes with an error when making a REST call, | |
3245 * this method will complete with the same error. | |
3246 */ | |
3247 async.Future delete(core.String profileId, core.String creativeFieldId, core.S
tring id) { | |
3248 var _url = null; | |
3249 var _queryParams = new core.Map(); | |
3250 var _uploadMedia = null; | |
3251 var _uploadOptions = null; | |
3252 var _downloadOptions = commons.DownloadOptions.Metadata; | |
3253 var _body = null; | |
3254 | |
3255 if (profileId == null) { | |
3256 throw new core.ArgumentError("Parameter profileId is required."); | |
3257 } | |
3258 if (creativeFieldId == null) { | |
3259 throw new core.ArgumentError("Parameter creativeFieldId is required."); | |
3260 } | |
3261 if (id == null) { | |
3262 throw new core.ArgumentError("Parameter id is required."); | |
3263 } | |
3264 | |
3265 _downloadOptions = null; | |
3266 | |
3267 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/cre
ativeFields/' + commons.Escaper.ecapeVariable('$creativeFieldId') + '/creativeFi
eldValues/' + commons.Escaper.ecapeVariable('$id'); | |
3268 | |
3269 var _response = _requester.request(_url, | |
3270 "DELETE", | |
3271 body: _body, | |
3272 queryParams: _queryParams, | |
3273 uploadOptions: _uploadOptions, | |
3274 uploadMedia: _uploadMedia, | |
3275 downloadOptions: _downloadOptions); | |
3276 return _response.then((data) => null); | |
3277 } | |
3278 | |
3279 /** | |
3280 * Gets one creative field value by ID. | |
3281 * | |
3282 * Request parameters: | |
3283 * | |
3284 * [profileId] - User profile ID associated with this request. | |
3285 * | |
3286 * [creativeFieldId] - Creative field ID for this creative field value. | |
3287 * | |
3288 * [id] - Creative Field Value ID | |
3289 * | |
3290 * Completes with a [CreativeFieldValue]. | |
3291 * | |
3292 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
3293 * error. | |
3294 * | |
3295 * If the used [http.Client] completes with an error when making a REST call, | |
3296 * this method will complete with the same error. | |
3297 */ | |
3298 async.Future<CreativeFieldValue> get(core.String profileId, core.String creati
veFieldId, core.String id) { | |
3299 var _url = null; | |
3300 var _queryParams = new core.Map(); | |
3301 var _uploadMedia = null; | |
3302 var _uploadOptions = null; | |
3303 var _downloadOptions = commons.DownloadOptions.Metadata; | |
3304 var _body = null; | |
3305 | |
3306 if (profileId == null) { | |
3307 throw new core.ArgumentError("Parameter profileId is required."); | |
3308 } | |
3309 if (creativeFieldId == null) { | |
3310 throw new core.ArgumentError("Parameter creativeFieldId is required."); | |
3311 } | |
3312 if (id == null) { | |
3313 throw new core.ArgumentError("Parameter id is required."); | |
3314 } | |
3315 | |
3316 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/cre
ativeFields/' + commons.Escaper.ecapeVariable('$creativeFieldId') + '/creativeFi
eldValues/' + commons.Escaper.ecapeVariable('$id'); | |
3317 | |
3318 var _response = _requester.request(_url, | |
3319 "GET", | |
3320 body: _body, | |
3321 queryParams: _queryParams, | |
3322 uploadOptions: _uploadOptions, | |
3323 uploadMedia: _uploadMedia, | |
3324 downloadOptions: _downloadOptions); | |
3325 return _response.then((data) => new CreativeFieldValue.fromJson(data)); | |
3326 } | |
3327 | |
3328 /** | |
3329 * Inserts a new creative field value. | |
3330 * | |
3331 * [request] - The metadata request object. | |
3332 * | |
3333 * Request parameters: | |
3334 * | |
3335 * [profileId] - User profile ID associated with this request. | |
3336 * | |
3337 * [creativeFieldId] - Creative field ID for this creative field value. | |
3338 * | |
3339 * Completes with a [CreativeFieldValue]. | |
3340 * | |
3341 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
3342 * error. | |
3343 * | |
3344 * If the used [http.Client] completes with an error when making a REST call, | |
3345 * this method will complete with the same error. | |
3346 */ | |
3347 async.Future<CreativeFieldValue> insert(CreativeFieldValue request, core.Strin
g profileId, core.String creativeFieldId) { | |
3348 var _url = null; | |
3349 var _queryParams = new core.Map(); | |
3350 var _uploadMedia = null; | |
3351 var _uploadOptions = null; | |
3352 var _downloadOptions = commons.DownloadOptions.Metadata; | |
3353 var _body = null; | |
3354 | |
3355 if (request != null) { | |
3356 _body = convert.JSON.encode((request).toJson()); | |
3357 } | |
3358 if (profileId == null) { | |
3359 throw new core.ArgumentError("Parameter profileId is required."); | |
3360 } | |
3361 if (creativeFieldId == null) { | |
3362 throw new core.ArgumentError("Parameter creativeFieldId is required."); | |
3363 } | |
3364 | |
3365 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/cre
ativeFields/' + commons.Escaper.ecapeVariable('$creativeFieldId') + '/creativeFi
eldValues'; | |
3366 | |
3367 var _response = _requester.request(_url, | |
3368 "POST", | |
3369 body: _body, | |
3370 queryParams: _queryParams, | |
3371 uploadOptions: _uploadOptions, | |
3372 uploadMedia: _uploadMedia, | |
3373 downloadOptions: _downloadOptions); | |
3374 return _response.then((data) => new CreativeFieldValue.fromJson(data)); | |
3375 } | |
3376 | |
3377 /** | |
3378 * Retrieves a list of creative field values, possibly filtered. | |
3379 * | |
3380 * Request parameters: | |
3381 * | |
3382 * [profileId] - User profile ID associated with this request. | |
3383 * | |
3384 * [creativeFieldId] - Creative field ID for this creative field value. | |
3385 * | |
3386 * [ids] - Select only creative field values with these IDs. | |
3387 * | |
3388 * [maxResults] - Maximum number of results to return. | |
3389 * | |
3390 * [pageToken] - Value of the nextPageToken from the previous result page. | |
3391 * | |
3392 * [searchString] - Allows searching for creative field values by their | |
3393 * values. Wildcards (e.g. *) are not allowed. | |
3394 * | |
3395 * [sortField] - Field by which to sort the list. | |
3396 * Possible string values are: | |
3397 * - "ID" | |
3398 * - "VALUE" | |
3399 * | |
3400 * [sortOrder] - Order of sorted results, default is ASCENDING. | |
3401 * Possible string values are: | |
3402 * - "ASCENDING" | |
3403 * - "DESCENDING" | |
3404 * | |
3405 * Completes with a [CreativeFieldValuesListResponse]. | |
3406 * | |
3407 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
3408 * error. | |
3409 * | |
3410 * If the used [http.Client] completes with an error when making a REST call, | |
3411 * this method will complete with the same error. | |
3412 */ | |
3413 async.Future<CreativeFieldValuesListResponse> list(core.String profileId, core
.String creativeFieldId, {core.List<core.String> ids, core.int maxResults, core.
String pageToken, core.String searchString, core.String sortField, core.String s
ortOrder}) { | |
3414 var _url = null; | |
3415 var _queryParams = new core.Map(); | |
3416 var _uploadMedia = null; | |
3417 var _uploadOptions = null; | |
3418 var _downloadOptions = commons.DownloadOptions.Metadata; | |
3419 var _body = null; | |
3420 | |
3421 if (profileId == null) { | |
3422 throw new core.ArgumentError("Parameter profileId is required."); | |
3423 } | |
3424 if (creativeFieldId == null) { | |
3425 throw new core.ArgumentError("Parameter creativeFieldId is required."); | |
3426 } | |
3427 if (ids != null) { | |
3428 _queryParams["ids"] = ids; | |
3429 } | |
3430 if (maxResults != null) { | |
3431 _queryParams["maxResults"] = ["${maxResults}"]; | |
3432 } | |
3433 if (pageToken != null) { | |
3434 _queryParams["pageToken"] = [pageToken]; | |
3435 } | |
3436 if (searchString != null) { | |
3437 _queryParams["searchString"] = [searchString]; | |
3438 } | |
3439 if (sortField != null) { | |
3440 _queryParams["sortField"] = [sortField]; | |
3441 } | |
3442 if (sortOrder != null) { | |
3443 _queryParams["sortOrder"] = [sortOrder]; | |
3444 } | |
3445 | |
3446 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/cre
ativeFields/' + commons.Escaper.ecapeVariable('$creativeFieldId') + '/creativeFi
eldValues'; | |
3447 | |
3448 var _response = _requester.request(_url, | |
3449 "GET", | |
3450 body: _body, | |
3451 queryParams: _queryParams, | |
3452 uploadOptions: _uploadOptions, | |
3453 uploadMedia: _uploadMedia, | |
3454 downloadOptions: _downloadOptions); | |
3455 return _response.then((data) => new CreativeFieldValuesListResponse.fromJson
(data)); | |
3456 } | |
3457 | |
3458 /** | |
3459 * Updates an existing creative field value. This method supports patch | |
3460 * semantics. | |
3461 * | |
3462 * [request] - The metadata request object. | |
3463 * | |
3464 * Request parameters: | |
3465 * | |
3466 * [profileId] - User profile ID associated with this request. | |
3467 * | |
3468 * [creativeFieldId] - Creative field ID for this creative field value. | |
3469 * | |
3470 * [id] - Creative Field Value ID | |
3471 * | |
3472 * Completes with a [CreativeFieldValue]. | |
3473 * | |
3474 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
3475 * error. | |
3476 * | |
3477 * If the used [http.Client] completes with an error when making a REST call, | |
3478 * this method will complete with the same error. | |
3479 */ | |
3480 async.Future<CreativeFieldValue> patch(CreativeFieldValue request, core.String
profileId, core.String creativeFieldId, core.String id) { | |
3481 var _url = null; | |
3482 var _queryParams = new core.Map(); | |
3483 var _uploadMedia = null; | |
3484 var _uploadOptions = null; | |
3485 var _downloadOptions = commons.DownloadOptions.Metadata; | |
3486 var _body = null; | |
3487 | |
3488 if (request != null) { | |
3489 _body = convert.JSON.encode((request).toJson()); | |
3490 } | |
3491 if (profileId == null) { | |
3492 throw new core.ArgumentError("Parameter profileId is required."); | |
3493 } | |
3494 if (creativeFieldId == null) { | |
3495 throw new core.ArgumentError("Parameter creativeFieldId is required."); | |
3496 } | |
3497 if (id == null) { | |
3498 throw new core.ArgumentError("Parameter id is required."); | |
3499 } | |
3500 _queryParams["id"] = [id]; | |
3501 | |
3502 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/cre
ativeFields/' + commons.Escaper.ecapeVariable('$creativeFieldId') + '/creativeFi
eldValues'; | |
3503 | |
3504 var _response = _requester.request(_url, | |
3505 "PATCH", | |
3506 body: _body, | |
3507 queryParams: _queryParams, | |
3508 uploadOptions: _uploadOptions, | |
3509 uploadMedia: _uploadMedia, | |
3510 downloadOptions: _downloadOptions); | |
3511 return _response.then((data) => new CreativeFieldValue.fromJson(data)); | |
3512 } | |
3513 | |
3514 /** | |
3515 * Updates an existing creative field value. | |
3516 * | |
3517 * [request] - The metadata request object. | |
3518 * | |
3519 * Request parameters: | |
3520 * | |
3521 * [profileId] - User profile ID associated with this request. | |
3522 * | |
3523 * [creativeFieldId] - Creative field ID for this creative field value. | |
3524 * | |
3525 * Completes with a [CreativeFieldValue]. | |
3526 * | |
3527 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
3528 * error. | |
3529 * | |
3530 * If the used [http.Client] completes with an error when making a REST call, | |
3531 * this method will complete with the same error. | |
3532 */ | |
3533 async.Future<CreativeFieldValue> update(CreativeFieldValue request, core.Strin
g profileId, core.String creativeFieldId) { | |
3534 var _url = null; | |
3535 var _queryParams = new core.Map(); | |
3536 var _uploadMedia = null; | |
3537 var _uploadOptions = null; | |
3538 var _downloadOptions = commons.DownloadOptions.Metadata; | |
3539 var _body = null; | |
3540 | |
3541 if (request != null) { | |
3542 _body = convert.JSON.encode((request).toJson()); | |
3543 } | |
3544 if (profileId == null) { | |
3545 throw new core.ArgumentError("Parameter profileId is required."); | |
3546 } | |
3547 if (creativeFieldId == null) { | |
3548 throw new core.ArgumentError("Parameter creativeFieldId is required."); | |
3549 } | |
3550 | |
3551 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/cre
ativeFields/' + commons.Escaper.ecapeVariable('$creativeFieldId') + '/creativeFi
eldValues'; | |
3552 | |
3553 var _response = _requester.request(_url, | |
3554 "PUT", | |
3555 body: _body, | |
3556 queryParams: _queryParams, | |
3557 uploadOptions: _uploadOptions, | |
3558 uploadMedia: _uploadMedia, | |
3559 downloadOptions: _downloadOptions); | |
3560 return _response.then((data) => new CreativeFieldValue.fromJson(data)); | |
3561 } | |
3562 | |
3563 } | |
3564 | |
3565 | |
3566 class CreativeFieldsResourceApi { | |
3567 final commons.ApiRequester _requester; | |
3568 | |
3569 CreativeFieldsResourceApi(commons.ApiRequester client) : | |
3570 _requester = client; | |
3571 | |
3572 /** | |
3573 * Deletes an existing creative field. | |
3574 * | |
3575 * Request parameters: | |
3576 * | |
3577 * [profileId] - User profile ID associated with this request. | |
3578 * | |
3579 * [id] - Creative Field ID | |
3580 * | |
3581 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
3582 * error. | |
3583 * | |
3584 * If the used [http.Client] completes with an error when making a REST call, | |
3585 * this method will complete with the same error. | |
3586 */ | |
3587 async.Future delete(core.String profileId, core.String id) { | |
3588 var _url = null; | |
3589 var _queryParams = new core.Map(); | |
3590 var _uploadMedia = null; | |
3591 var _uploadOptions = null; | |
3592 var _downloadOptions = commons.DownloadOptions.Metadata; | |
3593 var _body = null; | |
3594 | |
3595 if (profileId == null) { | |
3596 throw new core.ArgumentError("Parameter profileId is required."); | |
3597 } | |
3598 if (id == null) { | |
3599 throw new core.ArgumentError("Parameter id is required."); | |
3600 } | |
3601 | |
3602 _downloadOptions = null; | |
3603 | |
3604 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/cre
ativeFields/' + commons.Escaper.ecapeVariable('$id'); | |
3605 | |
3606 var _response = _requester.request(_url, | |
3607 "DELETE", | |
3608 body: _body, | |
3609 queryParams: _queryParams, | |
3610 uploadOptions: _uploadOptions, | |
3611 uploadMedia: _uploadMedia, | |
3612 downloadOptions: _downloadOptions); | |
3613 return _response.then((data) => null); | |
3614 } | |
3615 | |
3616 /** | |
3617 * Gets one creative field by ID. | |
3618 * | |
3619 * Request parameters: | |
3620 * | |
3621 * [profileId] - User profile ID associated with this request. | |
3622 * | |
3623 * [id] - Creative Field ID | |
3624 * | |
3625 * Completes with a [CreativeField]. | |
3626 * | |
3627 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
3628 * error. | |
3629 * | |
3630 * If the used [http.Client] completes with an error when making a REST call, | |
3631 * this method will complete with the same error. | |
3632 */ | |
3633 async.Future<CreativeField> get(core.String profileId, core.String id) { | |
3634 var _url = null; | |
3635 var _queryParams = new core.Map(); | |
3636 var _uploadMedia = null; | |
3637 var _uploadOptions = null; | |
3638 var _downloadOptions = commons.DownloadOptions.Metadata; | |
3639 var _body = null; | |
3640 | |
3641 if (profileId == null) { | |
3642 throw new core.ArgumentError("Parameter profileId is required."); | |
3643 } | |
3644 if (id == null) { | |
3645 throw new core.ArgumentError("Parameter id is required."); | |
3646 } | |
3647 | |
3648 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/cre
ativeFields/' + commons.Escaper.ecapeVariable('$id'); | |
3649 | |
3650 var _response = _requester.request(_url, | |
3651 "GET", | |
3652 body: _body, | |
3653 queryParams: _queryParams, | |
3654 uploadOptions: _uploadOptions, | |
3655 uploadMedia: _uploadMedia, | |
3656 downloadOptions: _downloadOptions); | |
3657 return _response.then((data) => new CreativeField.fromJson(data)); | |
3658 } | |
3659 | |
3660 /** | |
3661 * Inserts a new creative field. | |
3662 * | |
3663 * [request] - The metadata request object. | |
3664 * | |
3665 * Request parameters: | |
3666 * | |
3667 * [profileId] - User profile ID associated with this request. | |
3668 * | |
3669 * Completes with a [CreativeField]. | |
3670 * | |
3671 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
3672 * error. | |
3673 * | |
3674 * If the used [http.Client] completes with an error when making a REST call, | |
3675 * this method will complete with the same error. | |
3676 */ | |
3677 async.Future<CreativeField> insert(CreativeField request, core.String profileI
d) { | |
3678 var _url = null; | |
3679 var _queryParams = new core.Map(); | |
3680 var _uploadMedia = null; | |
3681 var _uploadOptions = null; | |
3682 var _downloadOptions = commons.DownloadOptions.Metadata; | |
3683 var _body = null; | |
3684 | |
3685 if (request != null) { | |
3686 _body = convert.JSON.encode((request).toJson()); | |
3687 } | |
3688 if (profileId == null) { | |
3689 throw new core.ArgumentError("Parameter profileId is required."); | |
3690 } | |
3691 | |
3692 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/cre
ativeFields'; | |
3693 | |
3694 var _response = _requester.request(_url, | |
3695 "POST", | |
3696 body: _body, | |
3697 queryParams: _queryParams, | |
3698 uploadOptions: _uploadOptions, | |
3699 uploadMedia: _uploadMedia, | |
3700 downloadOptions: _downloadOptions); | |
3701 return _response.then((data) => new CreativeField.fromJson(data)); | |
3702 } | |
3703 | |
3704 /** | |
3705 * Retrieves a list of creative fields, possibly filtered. | |
3706 * | |
3707 * Request parameters: | |
3708 * | |
3709 * [profileId] - User profile ID associated with this request. | |
3710 * | |
3711 * [advertiserIds] - Select only creative fields that belong to these | |
3712 * advertisers. | |
3713 * | |
3714 * [ids] - Select only creative fields with these IDs. | |
3715 * | |
3716 * [maxResults] - Maximum number of results to return. | |
3717 * | |
3718 * [pageToken] - Value of the nextPageToken from the previous result page. | |
3719 * | |
3720 * [searchString] - Allows searching for creative fields by name or ID. | |
3721 * Wildcards (*) are allowed. For example, "creativefield*2015" will return | |
3722 * creative fields with names like "creativefield June 2015", "creativefield | |
3723 * April 2015", or simply "creativefield 2015". Most of the searches also add | |
3724 * wild-cards implicitly at the start and the end of the search string. For | |
3725 * example, a search string of "creativefield" will match creative fields with | |
3726 * the name "my creativefield", "creativefield 2015", or simply | |
3727 * "creativefield". | |
3728 * | |
3729 * [sortField] - Field by which to sort the list. | |
3730 * Possible string values are: | |
3731 * - "ID" | |
3732 * - "NAME" | |
3733 * | |
3734 * [sortOrder] - Order of sorted results, default is ASCENDING. | |
3735 * Possible string values are: | |
3736 * - "ASCENDING" | |
3737 * - "DESCENDING" | |
3738 * | |
3739 * Completes with a [CreativeFieldsListResponse]. | |
3740 * | |
3741 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
3742 * error. | |
3743 * | |
3744 * If the used [http.Client] completes with an error when making a REST call, | |
3745 * this method will complete with the same error. | |
3746 */ | |
3747 async.Future<CreativeFieldsListResponse> list(core.String profileId, {core.Lis
t<core.String> advertiserIds, core.List<core.String> ids, core.int maxResults, c
ore.String pageToken, core.String searchString, core.String sortField, core.Stri
ng sortOrder}) { | |
3748 var _url = null; | |
3749 var _queryParams = new core.Map(); | |
3750 var _uploadMedia = null; | |
3751 var _uploadOptions = null; | |
3752 var _downloadOptions = commons.DownloadOptions.Metadata; | |
3753 var _body = null; | |
3754 | |
3755 if (profileId == null) { | |
3756 throw new core.ArgumentError("Parameter profileId is required."); | |
3757 } | |
3758 if (advertiserIds != null) { | |
3759 _queryParams["advertiserIds"] = advertiserIds; | |
3760 } | |
3761 if (ids != null) { | |
3762 _queryParams["ids"] = ids; | |
3763 } | |
3764 if (maxResults != null) { | |
3765 _queryParams["maxResults"] = ["${maxResults}"]; | |
3766 } | |
3767 if (pageToken != null) { | |
3768 _queryParams["pageToken"] = [pageToken]; | |
3769 } | |
3770 if (searchString != null) { | |
3771 _queryParams["searchString"] = [searchString]; | |
3772 } | |
3773 if (sortField != null) { | |
3774 _queryParams["sortField"] = [sortField]; | |
3775 } | |
3776 if (sortOrder != null) { | |
3777 _queryParams["sortOrder"] = [sortOrder]; | |
3778 } | |
3779 | |
3780 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/cre
ativeFields'; | |
3781 | |
3782 var _response = _requester.request(_url, | |
3783 "GET", | |
3784 body: _body, | |
3785 queryParams: _queryParams, | |
3786 uploadOptions: _uploadOptions, | |
3787 uploadMedia: _uploadMedia, | |
3788 downloadOptions: _downloadOptions); | |
3789 return _response.then((data) => new CreativeFieldsListResponse.fromJson(data
)); | |
3790 } | |
3791 | |
3792 /** | |
3793 * Updates an existing creative field. This method supports patch semantics. | |
3794 * | |
3795 * [request] - The metadata request object. | |
3796 * | |
3797 * Request parameters: | |
3798 * | |
3799 * [profileId] - User profile ID associated with this request. | |
3800 * | |
3801 * [id] - Creative Field ID | |
3802 * | |
3803 * Completes with a [CreativeField]. | |
3804 * | |
3805 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
3806 * error. | |
3807 * | |
3808 * If the used [http.Client] completes with an error when making a REST call, | |
3809 * this method will complete with the same error. | |
3810 */ | |
3811 async.Future<CreativeField> patch(CreativeField request, core.String profileId
, core.String id) { | |
3812 var _url = null; | |
3813 var _queryParams = new core.Map(); | |
3814 var _uploadMedia = null; | |
3815 var _uploadOptions = null; | |
3816 var _downloadOptions = commons.DownloadOptions.Metadata; | |
3817 var _body = null; | |
3818 | |
3819 if (request != null) { | |
3820 _body = convert.JSON.encode((request).toJson()); | |
3821 } | |
3822 if (profileId == null) { | |
3823 throw new core.ArgumentError("Parameter profileId is required."); | |
3824 } | |
3825 if (id == null) { | |
3826 throw new core.ArgumentError("Parameter id is required."); | |
3827 } | |
3828 _queryParams["id"] = [id]; | |
3829 | |
3830 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/cre
ativeFields'; | |
3831 | |
3832 var _response = _requester.request(_url, | |
3833 "PATCH", | |
3834 body: _body, | |
3835 queryParams: _queryParams, | |
3836 uploadOptions: _uploadOptions, | |
3837 uploadMedia: _uploadMedia, | |
3838 downloadOptions: _downloadOptions); | |
3839 return _response.then((data) => new CreativeField.fromJson(data)); | |
3840 } | |
3841 | |
3842 /** | |
3843 * Updates an existing creative field. | |
3844 * | |
3845 * [request] - The metadata request object. | |
3846 * | |
3847 * Request parameters: | |
3848 * | |
3849 * [profileId] - User profile ID associated with this request. | |
3850 * | |
3851 * Completes with a [CreativeField]. | |
3852 * | |
3853 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
3854 * error. | |
3855 * | |
3856 * If the used [http.Client] completes with an error when making a REST call, | |
3857 * this method will complete with the same error. | |
3858 */ | |
3859 async.Future<CreativeField> update(CreativeField request, core.String profileI
d) { | |
3860 var _url = null; | |
3861 var _queryParams = new core.Map(); | |
3862 var _uploadMedia = null; | |
3863 var _uploadOptions = null; | |
3864 var _downloadOptions = commons.DownloadOptions.Metadata; | |
3865 var _body = null; | |
3866 | |
3867 if (request != null) { | |
3868 _body = convert.JSON.encode((request).toJson()); | |
3869 } | |
3870 if (profileId == null) { | |
3871 throw new core.ArgumentError("Parameter profileId is required."); | |
3872 } | |
3873 | |
3874 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/cre
ativeFields'; | |
3875 | |
3876 var _response = _requester.request(_url, | |
3877 "PUT", | |
3878 body: _body, | |
3879 queryParams: _queryParams, | |
3880 uploadOptions: _uploadOptions, | |
3881 uploadMedia: _uploadMedia, | |
3882 downloadOptions: _downloadOptions); | |
3883 return _response.then((data) => new CreativeField.fromJson(data)); | |
3884 } | |
3885 | |
3886 } | |
3887 | |
3888 | |
3889 class CreativeGroupsResourceApi { | |
3890 final commons.ApiRequester _requester; | |
3891 | |
3892 CreativeGroupsResourceApi(commons.ApiRequester client) : | |
3893 _requester = client; | |
3894 | |
3895 /** | |
3896 * Gets one creative group by ID. | |
3897 * | |
3898 * Request parameters: | |
3899 * | |
3900 * [profileId] - User profile ID associated with this request. | |
3901 * | |
3902 * [id] - Creative group ID. | |
3903 * | |
3904 * Completes with a [CreativeGroup]. | |
3905 * | |
3906 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
3907 * error. | |
3908 * | |
3909 * If the used [http.Client] completes with an error when making a REST call, | |
3910 * this method will complete with the same error. | |
3911 */ | |
3912 async.Future<CreativeGroup> get(core.String profileId, core.String id) { | |
3913 var _url = null; | |
3914 var _queryParams = new core.Map(); | |
3915 var _uploadMedia = null; | |
3916 var _uploadOptions = null; | |
3917 var _downloadOptions = commons.DownloadOptions.Metadata; | |
3918 var _body = null; | |
3919 | |
3920 if (profileId == null) { | |
3921 throw new core.ArgumentError("Parameter profileId is required."); | |
3922 } | |
3923 if (id == null) { | |
3924 throw new core.ArgumentError("Parameter id is required."); | |
3925 } | |
3926 | |
3927 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/cre
ativeGroups/' + commons.Escaper.ecapeVariable('$id'); | |
3928 | |
3929 var _response = _requester.request(_url, | |
3930 "GET", | |
3931 body: _body, | |
3932 queryParams: _queryParams, | |
3933 uploadOptions: _uploadOptions, | |
3934 uploadMedia: _uploadMedia, | |
3935 downloadOptions: _downloadOptions); | |
3936 return _response.then((data) => new CreativeGroup.fromJson(data)); | |
3937 } | |
3938 | |
3939 /** | |
3940 * Inserts a new creative group. | |
3941 * | |
3942 * [request] - The metadata request object. | |
3943 * | |
3944 * Request parameters: | |
3945 * | |
3946 * [profileId] - User profile ID associated with this request. | |
3947 * | |
3948 * Completes with a [CreativeGroup]. | |
3949 * | |
3950 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
3951 * error. | |
3952 * | |
3953 * If the used [http.Client] completes with an error when making a REST call, | |
3954 * this method will complete with the same error. | |
3955 */ | |
3956 async.Future<CreativeGroup> insert(CreativeGroup request, core.String profileI
d) { | |
3957 var _url = null; | |
3958 var _queryParams = new core.Map(); | |
3959 var _uploadMedia = null; | |
3960 var _uploadOptions = null; | |
3961 var _downloadOptions = commons.DownloadOptions.Metadata; | |
3962 var _body = null; | |
3963 | |
3964 if (request != null) { | |
3965 _body = convert.JSON.encode((request).toJson()); | |
3966 } | |
3967 if (profileId == null) { | |
3968 throw new core.ArgumentError("Parameter profileId is required."); | |
3969 } | |
3970 | |
3971 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/cre
ativeGroups'; | |
3972 | |
3973 var _response = _requester.request(_url, | |
3974 "POST", | |
3975 body: _body, | |
3976 queryParams: _queryParams, | |
3977 uploadOptions: _uploadOptions, | |
3978 uploadMedia: _uploadMedia, | |
3979 downloadOptions: _downloadOptions); | |
3980 return _response.then((data) => new CreativeGroup.fromJson(data)); | |
3981 } | |
3982 | |
3983 /** | |
3984 * Retrieves a list of creative groups, possibly filtered. | |
3985 * | |
3986 * Request parameters: | |
3987 * | |
3988 * [profileId] - User profile ID associated with this request. | |
3989 * | |
3990 * [advertiserIds] - Select only creative groups that belong to these | |
3991 * advertisers. | |
3992 * | |
3993 * [groupNumber] - Select only creative groups that belong to this subgroup. | |
3994 * | |
3995 * [ids] - Select only creative groups with these IDs. | |
3996 * | |
3997 * [maxResults] - Maximum number of results to return. | |
3998 * | |
3999 * [pageToken] - Value of the nextPageToken from the previous result page. | |
4000 * | |
4001 * [searchString] - Allows searching for creative groups by name or ID. | |
4002 * Wildcards (*) are allowed. For example, "creativegroup*2015" will return | |
4003 * creative groups with names like "creativegroup June 2015", "creativegroup | |
4004 * April 2015", or simply "creativegroup 2015". Most of the searches also add | |
4005 * wild-cards implicitly at the start and the end of the search string. For | |
4006 * example, a search string of "creativegroup" will match creative groups with | |
4007 * the name "my creativegroup", "creativegroup 2015", or simply | |
4008 * "creativegroup". | |
4009 * | |
4010 * [sortField] - Field by which to sort the list. | |
4011 * Possible string values are: | |
4012 * - "ID" | |
4013 * - "NAME" | |
4014 * | |
4015 * [sortOrder] - Order of sorted results, default is ASCENDING. | |
4016 * Possible string values are: | |
4017 * - "ASCENDING" | |
4018 * - "DESCENDING" | |
4019 * | |
4020 * Completes with a [CreativeGroupsListResponse]. | |
4021 * | |
4022 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
4023 * error. | |
4024 * | |
4025 * If the used [http.Client] completes with an error when making a REST call, | |
4026 * this method will complete with the same error. | |
4027 */ | |
4028 async.Future<CreativeGroupsListResponse> list(core.String profileId, {core.Lis
t<core.String> advertiserIds, core.int groupNumber, core.List<core.String> ids,
core.int maxResults, core.String pageToken, core.String searchString, core.Strin
g sortField, core.String sortOrder}) { | |
4029 var _url = null; | |
4030 var _queryParams = new core.Map(); | |
4031 var _uploadMedia = null; | |
4032 var _uploadOptions = null; | |
4033 var _downloadOptions = commons.DownloadOptions.Metadata; | |
4034 var _body = null; | |
4035 | |
4036 if (profileId == null) { | |
4037 throw new core.ArgumentError("Parameter profileId is required."); | |
4038 } | |
4039 if (advertiserIds != null) { | |
4040 _queryParams["advertiserIds"] = advertiserIds; | |
4041 } | |
4042 if (groupNumber != null) { | |
4043 _queryParams["groupNumber"] = ["${groupNumber}"]; | |
4044 } | |
4045 if (ids != null) { | |
4046 _queryParams["ids"] = ids; | |
4047 } | |
4048 if (maxResults != null) { | |
4049 _queryParams["maxResults"] = ["${maxResults}"]; | |
4050 } | |
4051 if (pageToken != null) { | |
4052 _queryParams["pageToken"] = [pageToken]; | |
4053 } | |
4054 if (searchString != null) { | |
4055 _queryParams["searchString"] = [searchString]; | |
4056 } | |
4057 if (sortField != null) { | |
4058 _queryParams["sortField"] = [sortField]; | |
4059 } | |
4060 if (sortOrder != null) { | |
4061 _queryParams["sortOrder"] = [sortOrder]; | |
4062 } | |
4063 | |
4064 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/cre
ativeGroups'; | |
4065 | |
4066 var _response = _requester.request(_url, | |
4067 "GET", | |
4068 body: _body, | |
4069 queryParams: _queryParams, | |
4070 uploadOptions: _uploadOptions, | |
4071 uploadMedia: _uploadMedia, | |
4072 downloadOptions: _downloadOptions); | |
4073 return _response.then((data) => new CreativeGroupsListResponse.fromJson(data
)); | |
4074 } | |
4075 | |
4076 /** | |
4077 * Updates an existing creative group. This method supports patch semantics. | |
4078 * | |
4079 * [request] - The metadata request object. | |
4080 * | |
4081 * Request parameters: | |
4082 * | |
4083 * [profileId] - User profile ID associated with this request. | |
4084 * | |
4085 * [id] - Creative group ID. | |
4086 * | |
4087 * Completes with a [CreativeGroup]. | |
4088 * | |
4089 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
4090 * error. | |
4091 * | |
4092 * If the used [http.Client] completes with an error when making a REST call, | |
4093 * this method will complete with the same error. | |
4094 */ | |
4095 async.Future<CreativeGroup> patch(CreativeGroup request, core.String profileId
, core.String id) { | |
4096 var _url = null; | |
4097 var _queryParams = new core.Map(); | |
4098 var _uploadMedia = null; | |
4099 var _uploadOptions = null; | |
4100 var _downloadOptions = commons.DownloadOptions.Metadata; | |
4101 var _body = null; | |
4102 | |
4103 if (request != null) { | |
4104 _body = convert.JSON.encode((request).toJson()); | |
4105 } | |
4106 if (profileId == null) { | |
4107 throw new core.ArgumentError("Parameter profileId is required."); | |
4108 } | |
4109 if (id == null) { | |
4110 throw new core.ArgumentError("Parameter id is required."); | |
4111 } | |
4112 _queryParams["id"] = [id]; | |
4113 | |
4114 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/cre
ativeGroups'; | |
4115 | |
4116 var _response = _requester.request(_url, | |
4117 "PATCH", | |
4118 body: _body, | |
4119 queryParams: _queryParams, | |
4120 uploadOptions: _uploadOptions, | |
4121 uploadMedia: _uploadMedia, | |
4122 downloadOptions: _downloadOptions); | |
4123 return _response.then((data) => new CreativeGroup.fromJson(data)); | |
4124 } | |
4125 | |
4126 /** | |
4127 * Updates an existing creative group. | |
4128 * | |
4129 * [request] - The metadata request object. | |
4130 * | |
4131 * Request parameters: | |
4132 * | |
4133 * [profileId] - User profile ID associated with this request. | |
4134 * | |
4135 * Completes with a [CreativeGroup]. | |
4136 * | |
4137 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
4138 * error. | |
4139 * | |
4140 * If the used [http.Client] completes with an error when making a REST call, | |
4141 * this method will complete with the same error. | |
4142 */ | |
4143 async.Future<CreativeGroup> update(CreativeGroup request, core.String profileI
d) { | |
4144 var _url = null; | |
4145 var _queryParams = new core.Map(); | |
4146 var _uploadMedia = null; | |
4147 var _uploadOptions = null; | |
4148 var _downloadOptions = commons.DownloadOptions.Metadata; | |
4149 var _body = null; | |
4150 | |
4151 if (request != null) { | |
4152 _body = convert.JSON.encode((request).toJson()); | |
4153 } | |
4154 if (profileId == null) { | |
4155 throw new core.ArgumentError("Parameter profileId is required."); | |
4156 } | |
4157 | |
4158 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/cre
ativeGroups'; | |
4159 | |
4160 var _response = _requester.request(_url, | |
4161 "PUT", | |
4162 body: _body, | |
4163 queryParams: _queryParams, | |
4164 uploadOptions: _uploadOptions, | |
4165 uploadMedia: _uploadMedia, | |
4166 downloadOptions: _downloadOptions); | |
4167 return _response.then((data) => new CreativeGroup.fromJson(data)); | |
4168 } | |
4169 | |
4170 } | |
4171 | |
4172 | |
4173 class CreativesResourceApi { | |
4174 final commons.ApiRequester _requester; | |
4175 | |
4176 CreativesResourceApi(commons.ApiRequester client) : | |
4177 _requester = client; | |
4178 | |
4179 /** | |
4180 * Gets one creative by ID. | |
4181 * | |
4182 * Request parameters: | |
4183 * | |
4184 * [profileId] - User profile ID associated with this request. | |
4185 * | |
4186 * [id] - Creative ID. | |
4187 * | |
4188 * Completes with a [Creative]. | |
4189 * | |
4190 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
4191 * error. | |
4192 * | |
4193 * If the used [http.Client] completes with an error when making a REST call, | |
4194 * this method will complete with the same error. | |
4195 */ | |
4196 async.Future<Creative> get(core.String profileId, core.String id) { | |
4197 var _url = null; | |
4198 var _queryParams = new core.Map(); | |
4199 var _uploadMedia = null; | |
4200 var _uploadOptions = null; | |
4201 var _downloadOptions = commons.DownloadOptions.Metadata; | |
4202 var _body = null; | |
4203 | |
4204 if (profileId == null) { | |
4205 throw new core.ArgumentError("Parameter profileId is required."); | |
4206 } | |
4207 if (id == null) { | |
4208 throw new core.ArgumentError("Parameter id is required."); | |
4209 } | |
4210 | |
4211 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/cre
atives/' + commons.Escaper.ecapeVariable('$id'); | |
4212 | |
4213 var _response = _requester.request(_url, | |
4214 "GET", | |
4215 body: _body, | |
4216 queryParams: _queryParams, | |
4217 uploadOptions: _uploadOptions, | |
4218 uploadMedia: _uploadMedia, | |
4219 downloadOptions: _downloadOptions); | |
4220 return _response.then((data) => new Creative.fromJson(data)); | |
4221 } | |
4222 | |
4223 /** | |
4224 * Inserts a new creative. | |
4225 * | |
4226 * [request] - The metadata request object. | |
4227 * | |
4228 * Request parameters: | |
4229 * | |
4230 * [profileId] - User profile ID associated with this request. | |
4231 * | |
4232 * Completes with a [Creative]. | |
4233 * | |
4234 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
4235 * error. | |
4236 * | |
4237 * If the used [http.Client] completes with an error when making a REST call, | |
4238 * this method will complete with the same error. | |
4239 */ | |
4240 async.Future<Creative> insert(Creative request, core.String profileId) { | |
4241 var _url = null; | |
4242 var _queryParams = new core.Map(); | |
4243 var _uploadMedia = null; | |
4244 var _uploadOptions = null; | |
4245 var _downloadOptions = commons.DownloadOptions.Metadata; | |
4246 var _body = null; | |
4247 | |
4248 if (request != null) { | |
4249 _body = convert.JSON.encode((request).toJson()); | |
4250 } | |
4251 if (profileId == null) { | |
4252 throw new core.ArgumentError("Parameter profileId is required."); | |
4253 } | |
4254 | |
4255 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/cre
atives'; | |
4256 | |
4257 var _response = _requester.request(_url, | |
4258 "POST", | |
4259 body: _body, | |
4260 queryParams: _queryParams, | |
4261 uploadOptions: _uploadOptions, | |
4262 uploadMedia: _uploadMedia, | |
4263 downloadOptions: _downloadOptions); | |
4264 return _response.then((data) => new Creative.fromJson(data)); | |
4265 } | |
4266 | |
4267 /** | |
4268 * Retrieves a list of creatives, possibly filtered. | |
4269 * | |
4270 * Request parameters: | |
4271 * | |
4272 * [profileId] - User profile ID associated with this request. | |
4273 * | |
4274 * [active] - Select only active creatives. Leave blank to select active and | |
4275 * inactive creatives. | |
4276 * | |
4277 * [advertiserId] - Select only creatives with this advertiser ID. | |
4278 * | |
4279 * [archived] - Select only archived creatives. Leave blank to select archived | |
4280 * and unarchived creatives. | |
4281 * | |
4282 * [campaignId] - Select only creatives with this campaign ID. | |
4283 * | |
4284 * [companionCreativeIds] - Select only in-stream video creatives with these | |
4285 * companion IDs. | |
4286 * | |
4287 * [creativeFieldIds] - Select only creatives with these creative field IDs. | |
4288 * | |
4289 * [ids] - Select only creatives with these IDs. | |
4290 * | |
4291 * [maxResults] - Maximum number of results to return. | |
4292 * | |
4293 * [pageToken] - Value of the nextPageToken from the previous result page. | |
4294 * | |
4295 * [renderingIds] - Select only creatives with these rendering IDs. | |
4296 * | |
4297 * [searchString] - Allows searching for objects by name or ID. Wildcards (*) | |
4298 * are allowed. For example, "creative*2015" will return objects with names | |
4299 * like "creative June 2015", "creative April 2015", or simply "creative | |
4300 * 2015". Most of the searches also add wildcards implicitly at the start and | |
4301 * the end of the search string. For example, a search string of "creative" | |
4302 * will match objects with name "my creative", "creative 2015", or simply | |
4303 * "creative". | |
4304 * | |
4305 * [sizeIds] - Select only creatives with these size IDs. | |
4306 * | |
4307 * [sortField] - Field by which to sort the list. | |
4308 * Possible string values are: | |
4309 * - "ID" | |
4310 * - "NAME" | |
4311 * | |
4312 * [sortOrder] - Order of sorted results, default is ASCENDING. | |
4313 * Possible string values are: | |
4314 * - "ASCENDING" | |
4315 * - "DESCENDING" | |
4316 * | |
4317 * [studioCreativeId] - Select only creatives corresponding to this Studio | |
4318 * creative ID. | |
4319 * | |
4320 * [types] - Select only creatives with these creative types. | |
4321 * | |
4322 * Completes with a [CreativesListResponse]. | |
4323 * | |
4324 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
4325 * error. | |
4326 * | |
4327 * If the used [http.Client] completes with an error when making a REST call, | |
4328 * this method will complete with the same error. | |
4329 */ | |
4330 async.Future<CreativesListResponse> list(core.String profileId, {core.bool act
ive, core.String advertiserId, core.bool archived, core.String campaignId, core.
List<core.String> companionCreativeIds, core.List<core.String> creativeFieldIds,
core.List<core.String> ids, core.int maxResults, core.String pageToken, core.Li
st<core.String> renderingIds, core.String searchString, core.List<core.String> s
izeIds, core.String sortField, core.String sortOrder, core.String studioCreative
Id, core.List<core.String> types}) { | |
4331 var _url = null; | |
4332 var _queryParams = new core.Map(); | |
4333 var _uploadMedia = null; | |
4334 var _uploadOptions = null; | |
4335 var _downloadOptions = commons.DownloadOptions.Metadata; | |
4336 var _body = null; | |
4337 | |
4338 if (profileId == null) { | |
4339 throw new core.ArgumentError("Parameter profileId is required."); | |
4340 } | |
4341 if (active != null) { | |
4342 _queryParams["active"] = ["${active}"]; | |
4343 } | |
4344 if (advertiserId != null) { | |
4345 _queryParams["advertiserId"] = [advertiserId]; | |
4346 } | |
4347 if (archived != null) { | |
4348 _queryParams["archived"] = ["${archived}"]; | |
4349 } | |
4350 if (campaignId != null) { | |
4351 _queryParams["campaignId"] = [campaignId]; | |
4352 } | |
4353 if (companionCreativeIds != null) { | |
4354 _queryParams["companionCreativeIds"] = companionCreativeIds; | |
4355 } | |
4356 if (creativeFieldIds != null) { | |
4357 _queryParams["creativeFieldIds"] = creativeFieldIds; | |
4358 } | |
4359 if (ids != null) { | |
4360 _queryParams["ids"] = ids; | |
4361 } | |
4362 if (maxResults != null) { | |
4363 _queryParams["maxResults"] = ["${maxResults}"]; | |
4364 } | |
4365 if (pageToken != null) { | |
4366 _queryParams["pageToken"] = [pageToken]; | |
4367 } | |
4368 if (renderingIds != null) { | |
4369 _queryParams["renderingIds"] = renderingIds; | |
4370 } | |
4371 if (searchString != null) { | |
4372 _queryParams["searchString"] = [searchString]; | |
4373 } | |
4374 if (sizeIds != null) { | |
4375 _queryParams["sizeIds"] = sizeIds; | |
4376 } | |
4377 if (sortField != null) { | |
4378 _queryParams["sortField"] = [sortField]; | |
4379 } | |
4380 if (sortOrder != null) { | |
4381 _queryParams["sortOrder"] = [sortOrder]; | |
4382 } | |
4383 if (studioCreativeId != null) { | |
4384 _queryParams["studioCreativeId"] = [studioCreativeId]; | |
4385 } | |
4386 if (types != null) { | |
4387 _queryParams["types"] = types; | |
4388 } | |
4389 | |
4390 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/cre
atives'; | |
4391 | |
4392 var _response = _requester.request(_url, | |
4393 "GET", | |
4394 body: _body, | |
4395 queryParams: _queryParams, | |
4396 uploadOptions: _uploadOptions, | |
4397 uploadMedia: _uploadMedia, | |
4398 downloadOptions: _downloadOptions); | |
4399 return _response.then((data) => new CreativesListResponse.fromJson(data)); | |
4400 } | |
4401 | |
4402 /** | |
4403 * Updates an existing creative. This method supports patch semantics. | |
4404 * | |
4405 * [request] - The metadata request object. | |
4406 * | |
4407 * Request parameters: | |
4408 * | |
4409 * [profileId] - User profile ID associated with this request. | |
4410 * | |
4411 * [id] - Creative ID. | |
4412 * | |
4413 * Completes with a [Creative]. | |
4414 * | |
4415 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
4416 * error. | |
4417 * | |
4418 * If the used [http.Client] completes with an error when making a REST call, | |
4419 * this method will complete with the same error. | |
4420 */ | |
4421 async.Future<Creative> patch(Creative request, core.String profileId, core.Str
ing id) { | |
4422 var _url = null; | |
4423 var _queryParams = new core.Map(); | |
4424 var _uploadMedia = null; | |
4425 var _uploadOptions = null; | |
4426 var _downloadOptions = commons.DownloadOptions.Metadata; | |
4427 var _body = null; | |
4428 | |
4429 if (request != null) { | |
4430 _body = convert.JSON.encode((request).toJson()); | |
4431 } | |
4432 if (profileId == null) { | |
4433 throw new core.ArgumentError("Parameter profileId is required."); | |
4434 } | |
4435 if (id == null) { | |
4436 throw new core.ArgumentError("Parameter id is required."); | |
4437 } | |
4438 _queryParams["id"] = [id]; | |
4439 | |
4440 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/cre
atives'; | |
4441 | |
4442 var _response = _requester.request(_url, | |
4443 "PATCH", | |
4444 body: _body, | |
4445 queryParams: _queryParams, | |
4446 uploadOptions: _uploadOptions, | |
4447 uploadMedia: _uploadMedia, | |
4448 downloadOptions: _downloadOptions); | |
4449 return _response.then((data) => new Creative.fromJson(data)); | |
4450 } | |
4451 | |
4452 /** | |
4453 * Updates an existing creative. | |
4454 * | |
4455 * [request] - The metadata request object. | |
4456 * | |
4457 * Request parameters: | |
4458 * | |
4459 * [profileId] - User profile ID associated with this request. | |
4460 * | |
4461 * Completes with a [Creative]. | |
4462 * | |
4463 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
4464 * error. | |
4465 * | |
4466 * If the used [http.Client] completes with an error when making a REST call, | |
4467 * this method will complete with the same error. | |
4468 */ | |
4469 async.Future<Creative> update(Creative request, core.String profileId) { | |
4470 var _url = null; | |
4471 var _queryParams = new core.Map(); | |
4472 var _uploadMedia = null; | |
4473 var _uploadOptions = null; | |
4474 var _downloadOptions = commons.DownloadOptions.Metadata; | |
4475 var _body = null; | |
4476 | |
4477 if (request != null) { | |
4478 _body = convert.JSON.encode((request).toJson()); | |
4479 } | |
4480 if (profileId == null) { | |
4481 throw new core.ArgumentError("Parameter profileId is required."); | |
4482 } | |
4483 | |
4484 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/cre
atives'; | |
4485 | |
4486 var _response = _requester.request(_url, | |
4487 "PUT", | |
4488 body: _body, | |
4489 queryParams: _queryParams, | |
4490 uploadOptions: _uploadOptions, | |
4491 uploadMedia: _uploadMedia, | |
4492 downloadOptions: _downloadOptions); | |
4493 return _response.then((data) => new Creative.fromJson(data)); | |
4494 } | |
4495 | |
4496 } | |
4497 | |
4498 | |
4499 class DimensionValuesResourceApi { | |
4500 final commons.ApiRequester _requester; | |
4501 | |
4502 DimensionValuesResourceApi(commons.ApiRequester client) : | |
4503 _requester = client; | |
4504 | |
4505 /** | |
4506 * Retrieves list of report dimension values for a list of filters. | |
4507 * | |
4508 * [request] - The metadata request object. | |
4509 * | |
4510 * Request parameters: | |
4511 * | |
4512 * [profileId] - The DFA user profile ID. | |
4513 * | |
4514 * [maxResults] - Maximum number of results to return. | |
4515 * Value must be between "0" and "100". | |
4516 * | |
4517 * [pageToken] - The value of the nextToken from the previous result page. | |
4518 * | |
4519 * Completes with a [DimensionValueList]. | |
4520 * | |
4521 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
4522 * error. | |
4523 * | |
4524 * If the used [http.Client] completes with an error when making a REST call, | |
4525 * this method will complete with the same error. | |
4526 */ | |
4527 async.Future<DimensionValueList> query(DimensionValueRequest request, core.Str
ing profileId, {core.int maxResults, core.String pageToken}) { | |
4528 var _url = null; | |
4529 var _queryParams = new core.Map(); | |
4530 var _uploadMedia = null; | |
4531 var _uploadOptions = null; | |
4532 var _downloadOptions = commons.DownloadOptions.Metadata; | |
4533 var _body = null; | |
4534 | |
4535 if (request != null) { | |
4536 _body = convert.JSON.encode((request).toJson()); | |
4537 } | |
4538 if (profileId == null) { | |
4539 throw new core.ArgumentError("Parameter profileId is required."); | |
4540 } | |
4541 if (maxResults != null) { | |
4542 _queryParams["maxResults"] = ["${maxResults}"]; | |
4543 } | |
4544 if (pageToken != null) { | |
4545 _queryParams["pageToken"] = [pageToken]; | |
4546 } | |
4547 | |
4548 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/dim
ensionvalues/query'; | |
4549 | |
4550 var _response = _requester.request(_url, | |
4551 "POST", | |
4552 body: _body, | |
4553 queryParams: _queryParams, | |
4554 uploadOptions: _uploadOptions, | |
4555 uploadMedia: _uploadMedia, | |
4556 downloadOptions: _downloadOptions); | |
4557 return _response.then((data) => new DimensionValueList.fromJson(data)); | |
4558 } | |
4559 | |
4560 } | |
4561 | |
4562 | |
4563 class DirectorySiteContactsResourceApi { | |
4564 final commons.ApiRequester _requester; | |
4565 | |
4566 DirectorySiteContactsResourceApi(commons.ApiRequester client) : | |
4567 _requester = client; | |
4568 | |
4569 /** | |
4570 * Gets one directory site contact by ID. | |
4571 * | |
4572 * Request parameters: | |
4573 * | |
4574 * [profileId] - User profile ID associated with this request. | |
4575 * | |
4576 * [id] - Directory site contact ID. | |
4577 * | |
4578 * Completes with a [DirectorySiteContact]. | |
4579 * | |
4580 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
4581 * error. | |
4582 * | |
4583 * If the used [http.Client] completes with an error when making a REST call, | |
4584 * this method will complete with the same error. | |
4585 */ | |
4586 async.Future<DirectorySiteContact> get(core.String profileId, core.String id)
{ | |
4587 var _url = null; | |
4588 var _queryParams = new core.Map(); | |
4589 var _uploadMedia = null; | |
4590 var _uploadOptions = null; | |
4591 var _downloadOptions = commons.DownloadOptions.Metadata; | |
4592 var _body = null; | |
4593 | |
4594 if (profileId == null) { | |
4595 throw new core.ArgumentError("Parameter profileId is required."); | |
4596 } | |
4597 if (id == null) { | |
4598 throw new core.ArgumentError("Parameter id is required."); | |
4599 } | |
4600 | |
4601 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/dir
ectorySiteContacts/' + commons.Escaper.ecapeVariable('$id'); | |
4602 | |
4603 var _response = _requester.request(_url, | |
4604 "GET", | |
4605 body: _body, | |
4606 queryParams: _queryParams, | |
4607 uploadOptions: _uploadOptions, | |
4608 uploadMedia: _uploadMedia, | |
4609 downloadOptions: _downloadOptions); | |
4610 return _response.then((data) => new DirectorySiteContact.fromJson(data)); | |
4611 } | |
4612 | |
4613 /** | |
4614 * Retrieves a list of directory site contacts, possibly filtered. | |
4615 * | |
4616 * Request parameters: | |
4617 * | |
4618 * [profileId] - User profile ID associated with this request. | |
4619 * | |
4620 * [directorySiteIds] - Select only directory site contacts with these | |
4621 * directory site IDs. This is a required field. | |
4622 * | |
4623 * [ids] - Select only directory site contacts with these IDs. | |
4624 * | |
4625 * [maxResults] - Maximum number of results to return. | |
4626 * | |
4627 * [pageToken] - Value of the nextPageToken from the previous result page. | |
4628 * | |
4629 * [searchString] - Allows searching for objects by name, ID or email. | |
4630 * Wildcards (*) are allowed. For example, "directory site contact*2015" will | |
4631 * return objects with names like "directory site contact June 2015", | |
4632 * "directory site contact April 2015", or simply "directory site contact | |
4633 * 2015". Most of the searches also add wildcards implicitly at the start and | |
4634 * the end of the search string. For example, a search string of "directory | |
4635 * site contact" will match objects with name "my directory site contact", | |
4636 * "directory site contact 2015", or simply "directory site contact". | |
4637 * | |
4638 * [sortField] - Field by which to sort the list. | |
4639 * Possible string values are: | |
4640 * - "ID" | |
4641 * - "NAME" | |
4642 * | |
4643 * [sortOrder] - Order of sorted results, default is ASCENDING. | |
4644 * Possible string values are: | |
4645 * - "ASCENDING" | |
4646 * - "DESCENDING" | |
4647 * | |
4648 * Completes with a [DirectorySiteContactsListResponse]. | |
4649 * | |
4650 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
4651 * error. | |
4652 * | |
4653 * If the used [http.Client] completes with an error when making a REST call, | |
4654 * this method will complete with the same error. | |
4655 */ | |
4656 async.Future<DirectorySiteContactsListResponse> list(core.String profileId, {c
ore.List<core.String> directorySiteIds, core.List<core.String> ids, core.int max
Results, core.String pageToken, core.String searchString, core.String sortField,
core.String sortOrder}) { | |
4657 var _url = null; | |
4658 var _queryParams = new core.Map(); | |
4659 var _uploadMedia = null; | |
4660 var _uploadOptions = null; | |
4661 var _downloadOptions = commons.DownloadOptions.Metadata; | |
4662 var _body = null; | |
4663 | |
4664 if (profileId == null) { | |
4665 throw new core.ArgumentError("Parameter profileId is required."); | |
4666 } | |
4667 if (directorySiteIds != null) { | |
4668 _queryParams["directorySiteIds"] = directorySiteIds; | |
4669 } | |
4670 if (ids != null) { | |
4671 _queryParams["ids"] = ids; | |
4672 } | |
4673 if (maxResults != null) { | |
4674 _queryParams["maxResults"] = ["${maxResults}"]; | |
4675 } | |
4676 if (pageToken != null) { | |
4677 _queryParams["pageToken"] = [pageToken]; | |
4678 } | |
4679 if (searchString != null) { | |
4680 _queryParams["searchString"] = [searchString]; | |
4681 } | |
4682 if (sortField != null) { | |
4683 _queryParams["sortField"] = [sortField]; | |
4684 } | |
4685 if (sortOrder != null) { | |
4686 _queryParams["sortOrder"] = [sortOrder]; | |
4687 } | |
4688 | |
4689 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/dir
ectorySiteContacts'; | |
4690 | |
4691 var _response = _requester.request(_url, | |
4692 "GET", | |
4693 body: _body, | |
4694 queryParams: _queryParams, | |
4695 uploadOptions: _uploadOptions, | |
4696 uploadMedia: _uploadMedia, | |
4697 downloadOptions: _downloadOptions); | |
4698 return _response.then((data) => new DirectorySiteContactsListResponse.fromJs
on(data)); | |
4699 } | |
4700 | |
4701 } | |
4702 | |
4703 | |
4704 class DirectorySitesResourceApi { | |
4705 final commons.ApiRequester _requester; | |
4706 | |
4707 DirectorySitesResourceApi(commons.ApiRequester client) : | |
4708 _requester = client; | |
4709 | |
4710 /** | |
4711 * Gets one directory site by ID. | |
4712 * | |
4713 * Request parameters: | |
4714 * | |
4715 * [profileId] - User profile ID associated with this request. | |
4716 * | |
4717 * [id] - Directory site ID. | |
4718 * | |
4719 * Completes with a [DirectorySite]. | |
4720 * | |
4721 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
4722 * error. | |
4723 * | |
4724 * If the used [http.Client] completes with an error when making a REST call, | |
4725 * this method will complete with the same error. | |
4726 */ | |
4727 async.Future<DirectorySite> get(core.String profileId, core.String id) { | |
4728 var _url = null; | |
4729 var _queryParams = new core.Map(); | |
4730 var _uploadMedia = null; | |
4731 var _uploadOptions = null; | |
4732 var _downloadOptions = commons.DownloadOptions.Metadata; | |
4733 var _body = null; | |
4734 | |
4735 if (profileId == null) { | |
4736 throw new core.ArgumentError("Parameter profileId is required."); | |
4737 } | |
4738 if (id == null) { | |
4739 throw new core.ArgumentError("Parameter id is required."); | |
4740 } | |
4741 | |
4742 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/dir
ectorySites/' + commons.Escaper.ecapeVariable('$id'); | |
4743 | |
4744 var _response = _requester.request(_url, | |
4745 "GET", | |
4746 body: _body, | |
4747 queryParams: _queryParams, | |
4748 uploadOptions: _uploadOptions, | |
4749 uploadMedia: _uploadMedia, | |
4750 downloadOptions: _downloadOptions); | |
4751 return _response.then((data) => new DirectorySite.fromJson(data)); | |
4752 } | |
4753 | |
4754 /** | |
4755 * Inserts a new directory site. | |
4756 * | |
4757 * [request] - The metadata request object. | |
4758 * | |
4759 * Request parameters: | |
4760 * | |
4761 * [profileId] - User profile ID associated with this request. | |
4762 * | |
4763 * Completes with a [DirectorySite]. | |
4764 * | |
4765 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
4766 * error. | |
4767 * | |
4768 * If the used [http.Client] completes with an error when making a REST call, | |
4769 * this method will complete with the same error. | |
4770 */ | |
4771 async.Future<DirectorySite> insert(DirectorySite request, core.String profileI
d) { | |
4772 var _url = null; | |
4773 var _queryParams = new core.Map(); | |
4774 var _uploadMedia = null; | |
4775 var _uploadOptions = null; | |
4776 var _downloadOptions = commons.DownloadOptions.Metadata; | |
4777 var _body = null; | |
4778 | |
4779 if (request != null) { | |
4780 _body = convert.JSON.encode((request).toJson()); | |
4781 } | |
4782 if (profileId == null) { | |
4783 throw new core.ArgumentError("Parameter profileId is required."); | |
4784 } | |
4785 | |
4786 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/dir
ectorySites'; | |
4787 | |
4788 var _response = _requester.request(_url, | |
4789 "POST", | |
4790 body: _body, | |
4791 queryParams: _queryParams, | |
4792 uploadOptions: _uploadOptions, | |
4793 uploadMedia: _uploadMedia, | |
4794 downloadOptions: _downloadOptions); | |
4795 return _response.then((data) => new DirectorySite.fromJson(data)); | |
4796 } | |
4797 | |
4798 /** | |
4799 * Retrieves a list of directory sites, possibly filtered. | |
4800 * | |
4801 * Request parameters: | |
4802 * | |
4803 * [profileId] - User profile ID associated with this request. | |
4804 * | |
4805 * [acceptsInStreamVideoPlacements] - This search filter is no longer | |
4806 * supported and will have no effect on the results returned. | |
4807 * | |
4808 * [acceptsInterstitialPlacements] - This search filter is no longer supported | |
4809 * and will have no effect on the results returned. | |
4810 * | |
4811 * [acceptsPublisherPaidPlacements] - Select only directory sites that accept | |
4812 * publisher paid placements. This field can be left blank. | |
4813 * | |
4814 * [active] - Select only active directory sites. Leave blank to retrieve both | |
4815 * active and inactive directory sites. | |
4816 * | |
4817 * [countryId] - Select only directory sites with this country ID. | |
4818 * | |
4819 * [dfpNetworkCode] - Select only directory sites with this DFP network code. | |
4820 * | |
4821 * [ids] - Select only directory sites with these IDs. | |
4822 * | |
4823 * [maxResults] - Maximum number of results to return. | |
4824 * | |
4825 * [pageToken] - Value of the nextPageToken from the previous result page. | |
4826 * | |
4827 * [parentId] - Select only directory sites with this parent ID. | |
4828 * | |
4829 * [searchString] - Allows searching for objects by name, ID or URL. Wildcards | |
4830 * (*) are allowed. For example, "directory site*2015" will return objects | |
4831 * with names like "directory site June 2015", "directory site April 2015", or | |
4832 * simply "directory site 2015". Most of the searches also add wildcards | |
4833 * implicitly at the start and the end of the search string. For example, a | |
4834 * search string of "directory site" will match objects with name "my | |
4835 * directory site", "directory site 2015" or simply, "directory site". | |
4836 * | |
4837 * [sortField] - Field by which to sort the list. | |
4838 * Possible string values are: | |
4839 * - "ID" | |
4840 * - "NAME" | |
4841 * | |
4842 * [sortOrder] - Order of sorted results, default is ASCENDING. | |
4843 * Possible string values are: | |
4844 * - "ASCENDING" | |
4845 * - "DESCENDING" | |
4846 * | |
4847 * Completes with a [DirectorySitesListResponse]. | |
4848 * | |
4849 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
4850 * error. | |
4851 * | |
4852 * If the used [http.Client] completes with an error when making a REST call, | |
4853 * this method will complete with the same error. | |
4854 */ | |
4855 async.Future<DirectorySitesListResponse> list(core.String profileId, {core.boo
l acceptsInStreamVideoPlacements, core.bool acceptsInterstitialPlacements, core.
bool acceptsPublisherPaidPlacements, core.bool active, core.String countryId, co
re.String dfpNetworkCode, core.List<core.String> ids, core.int maxResults, core.
String pageToken, core.String parentId, core.String searchString, core.String so
rtField, core.String sortOrder}) { | |
4856 var _url = null; | |
4857 var _queryParams = new core.Map(); | |
4858 var _uploadMedia = null; | |
4859 var _uploadOptions = null; | |
4860 var _downloadOptions = commons.DownloadOptions.Metadata; | |
4861 var _body = null; | |
4862 | |
4863 if (profileId == null) { | |
4864 throw new core.ArgumentError("Parameter profileId is required."); | |
4865 } | |
4866 if (acceptsInStreamVideoPlacements != null) { | |
4867 _queryParams["acceptsInStreamVideoPlacements"] = ["${acceptsInStreamVideoP
lacements}"]; | |
4868 } | |
4869 if (acceptsInterstitialPlacements != null) { | |
4870 _queryParams["acceptsInterstitialPlacements"] = ["${acceptsInterstitialPla
cements}"]; | |
4871 } | |
4872 if (acceptsPublisherPaidPlacements != null) { | |
4873 _queryParams["acceptsPublisherPaidPlacements"] = ["${acceptsPublisherPaidP
lacements}"]; | |
4874 } | |
4875 if (active != null) { | |
4876 _queryParams["active"] = ["${active}"]; | |
4877 } | |
4878 if (countryId != null) { | |
4879 _queryParams["countryId"] = [countryId]; | |
4880 } | |
4881 if (dfpNetworkCode != null) { | |
4882 _queryParams["dfp_network_code"] = [dfpNetworkCode]; | |
4883 } | |
4884 if (ids != null) { | |
4885 _queryParams["ids"] = ids; | |
4886 } | |
4887 if (maxResults != null) { | |
4888 _queryParams["maxResults"] = ["${maxResults}"]; | |
4889 } | |
4890 if (pageToken != null) { | |
4891 _queryParams["pageToken"] = [pageToken]; | |
4892 } | |
4893 if (parentId != null) { | |
4894 _queryParams["parentId"] = [parentId]; | |
4895 } | |
4896 if (searchString != null) { | |
4897 _queryParams["searchString"] = [searchString]; | |
4898 } | |
4899 if (sortField != null) { | |
4900 _queryParams["sortField"] = [sortField]; | |
4901 } | |
4902 if (sortOrder != null) { | |
4903 _queryParams["sortOrder"] = [sortOrder]; | |
4904 } | |
4905 | |
4906 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/dir
ectorySites'; | |
4907 | |
4908 var _response = _requester.request(_url, | |
4909 "GET", | |
4910 body: _body, | |
4911 queryParams: _queryParams, | |
4912 uploadOptions: _uploadOptions, | |
4913 uploadMedia: _uploadMedia, | |
4914 downloadOptions: _downloadOptions); | |
4915 return _response.then((data) => new DirectorySitesListResponse.fromJson(data
)); | |
4916 } | |
4917 | |
4918 } | |
4919 | |
4920 | |
4921 class EventTagsResourceApi { | |
4922 final commons.ApiRequester _requester; | |
4923 | |
4924 EventTagsResourceApi(commons.ApiRequester client) : | |
4925 _requester = client; | |
4926 | |
4927 /** | |
4928 * Deletes an existing event tag. | |
4929 * | |
4930 * Request parameters: | |
4931 * | |
4932 * [profileId] - User profile ID associated with this request. | |
4933 * | |
4934 * [id] - Event tag ID. | |
4935 * | |
4936 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
4937 * error. | |
4938 * | |
4939 * If the used [http.Client] completes with an error when making a REST call, | |
4940 * this method will complete with the same error. | |
4941 */ | |
4942 async.Future delete(core.String profileId, core.String id) { | |
4943 var _url = null; | |
4944 var _queryParams = new core.Map(); | |
4945 var _uploadMedia = null; | |
4946 var _uploadOptions = null; | |
4947 var _downloadOptions = commons.DownloadOptions.Metadata; | |
4948 var _body = null; | |
4949 | |
4950 if (profileId == null) { | |
4951 throw new core.ArgumentError("Parameter profileId is required."); | |
4952 } | |
4953 if (id == null) { | |
4954 throw new core.ArgumentError("Parameter id is required."); | |
4955 } | |
4956 | |
4957 _downloadOptions = null; | |
4958 | |
4959 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/eve
ntTags/' + commons.Escaper.ecapeVariable('$id'); | |
4960 | |
4961 var _response = _requester.request(_url, | |
4962 "DELETE", | |
4963 body: _body, | |
4964 queryParams: _queryParams, | |
4965 uploadOptions: _uploadOptions, | |
4966 uploadMedia: _uploadMedia, | |
4967 downloadOptions: _downloadOptions); | |
4968 return _response.then((data) => null); | |
4969 } | |
4970 | |
4971 /** | |
4972 * Gets one event tag by ID. | |
4973 * | |
4974 * Request parameters: | |
4975 * | |
4976 * [profileId] - User profile ID associated with this request. | |
4977 * | |
4978 * [id] - Event tag ID. | |
4979 * | |
4980 * Completes with a [EventTag]. | |
4981 * | |
4982 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
4983 * error. | |
4984 * | |
4985 * If the used [http.Client] completes with an error when making a REST call, | |
4986 * this method will complete with the same error. | |
4987 */ | |
4988 async.Future<EventTag> get(core.String profileId, core.String id) { | |
4989 var _url = null; | |
4990 var _queryParams = new core.Map(); | |
4991 var _uploadMedia = null; | |
4992 var _uploadOptions = null; | |
4993 var _downloadOptions = commons.DownloadOptions.Metadata; | |
4994 var _body = null; | |
4995 | |
4996 if (profileId == null) { | |
4997 throw new core.ArgumentError("Parameter profileId is required."); | |
4998 } | |
4999 if (id == null) { | |
5000 throw new core.ArgumentError("Parameter id is required."); | |
5001 } | |
5002 | |
5003 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/eve
ntTags/' + commons.Escaper.ecapeVariable('$id'); | |
5004 | |
5005 var _response = _requester.request(_url, | |
5006 "GET", | |
5007 body: _body, | |
5008 queryParams: _queryParams, | |
5009 uploadOptions: _uploadOptions, | |
5010 uploadMedia: _uploadMedia, | |
5011 downloadOptions: _downloadOptions); | |
5012 return _response.then((data) => new EventTag.fromJson(data)); | |
5013 } | |
5014 | |
5015 /** | |
5016 * Inserts a new event tag. | |
5017 * | |
5018 * [request] - The metadata request object. | |
5019 * | |
5020 * Request parameters: | |
5021 * | |
5022 * [profileId] - User profile ID associated with this request. | |
5023 * | |
5024 * Completes with a [EventTag]. | |
5025 * | |
5026 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
5027 * error. | |
5028 * | |
5029 * If the used [http.Client] completes with an error when making a REST call, | |
5030 * this method will complete with the same error. | |
5031 */ | |
5032 async.Future<EventTag> insert(EventTag request, core.String profileId) { | |
5033 var _url = null; | |
5034 var _queryParams = new core.Map(); | |
5035 var _uploadMedia = null; | |
5036 var _uploadOptions = null; | |
5037 var _downloadOptions = commons.DownloadOptions.Metadata; | |
5038 var _body = null; | |
5039 | |
5040 if (request != null) { | |
5041 _body = convert.JSON.encode((request).toJson()); | |
5042 } | |
5043 if (profileId == null) { | |
5044 throw new core.ArgumentError("Parameter profileId is required."); | |
5045 } | |
5046 | |
5047 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/eve
ntTags'; | |
5048 | |
5049 var _response = _requester.request(_url, | |
5050 "POST", | |
5051 body: _body, | |
5052 queryParams: _queryParams, | |
5053 uploadOptions: _uploadOptions, | |
5054 uploadMedia: _uploadMedia, | |
5055 downloadOptions: _downloadOptions); | |
5056 return _response.then((data) => new EventTag.fromJson(data)); | |
5057 } | |
5058 | |
5059 /** | |
5060 * Retrieves a list of event tags, possibly filtered. | |
5061 * | |
5062 * Request parameters: | |
5063 * | |
5064 * [profileId] - User profile ID associated with this request. | |
5065 * | |
5066 * [adId] - Select only event tags that belong to this ad. | |
5067 * | |
5068 * [advertiserId] - Select only event tags that belong to this advertiser. | |
5069 * | |
5070 * [campaignId] - Select only event tags that belong to this campaign. | |
5071 * | |
5072 * [definitionsOnly] - Examine only the specified campaign or advertiser's | |
5073 * event tags for matching selector criteria. When set to false, the parent | |
5074 * advertiser and parent campaign of the specified ad or campaign is examined | |
5075 * as well. In addition, when set to false, the status field is examined as | |
5076 * well, along with the enabledByDefault field. This parameter can not be set | |
5077 * to true when adId is specified as ads do not define their own even tags. | |
5078 * | |
5079 * [enabled] - Select only enabled event tags. What is considered enabled or | |
5080 * disabled depends on the definitionsOnly parameter. When definitionsOnly is | |
5081 * set to true, only the specified advertiser or campaign's event tags' | |
5082 * enabledByDefault field is examined. When definitionsOnly is set to false, | |
5083 * the specified ad or specified campaign's parent advertiser's or parent | |
5084 * campaign's event tags' enabledByDefault and status fields are examined as | |
5085 * well. | |
5086 * | |
5087 * [eventTagTypes] - Select only event tags with the specified event tag | |
5088 * types. Event tag types can be used to specify whether to use a third-party | |
5089 * pixel, a third-party JavaScript URL, or a third-party click-through URL for | |
5090 * either impression or click tracking. | |
5091 * | |
5092 * [ids] - Select only event tags with these IDs. | |
5093 * | |
5094 * [searchString] - Allows searching for objects by name or ID. Wildcards (*) | |
5095 * are allowed. For example, "eventtag*2015" will return objects with names | |
5096 * like "eventtag June 2015", "eventtag April 2015", or simply "eventtag | |
5097 * 2015". Most of the searches also add wildcards implicitly at the start and | |
5098 * the end of the search string. For example, a search string of "eventtag" | |
5099 * will match objects with name "my eventtag", "eventtag 2015", or simply | |
5100 * "eventtag". | |
5101 * | |
5102 * [sortField] - Field by which to sort the list. | |
5103 * Possible string values are: | |
5104 * - "ID" | |
5105 * - "NAME" | |
5106 * | |
5107 * [sortOrder] - Order of sorted results, default is ASCENDING. | |
5108 * Possible string values are: | |
5109 * - "ASCENDING" | |
5110 * - "DESCENDING" | |
5111 * | |
5112 * Completes with a [EventTagsListResponse]. | |
5113 * | |
5114 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
5115 * error. | |
5116 * | |
5117 * If the used [http.Client] completes with an error when making a REST call, | |
5118 * this method will complete with the same error. | |
5119 */ | |
5120 async.Future<EventTagsListResponse> list(core.String profileId, {core.String a
dId, core.String advertiserId, core.String campaignId, core.bool definitionsOnly
, core.bool enabled, core.List<core.String> eventTagTypes, core.List<core.String
> ids, core.String searchString, core.String sortField, core.String sortOrder})
{ | |
5121 var _url = null; | |
5122 var _queryParams = new core.Map(); | |
5123 var _uploadMedia = null; | |
5124 var _uploadOptions = null; | |
5125 var _downloadOptions = commons.DownloadOptions.Metadata; | |
5126 var _body = null; | |
5127 | |
5128 if (profileId == null) { | |
5129 throw new core.ArgumentError("Parameter profileId is required."); | |
5130 } | |
5131 if (adId != null) { | |
5132 _queryParams["adId"] = [adId]; | |
5133 } | |
5134 if (advertiserId != null) { | |
5135 _queryParams["advertiserId"] = [advertiserId]; | |
5136 } | |
5137 if (campaignId != null) { | |
5138 _queryParams["campaignId"] = [campaignId]; | |
5139 } | |
5140 if (definitionsOnly != null) { | |
5141 _queryParams["definitionsOnly"] = ["${definitionsOnly}"]; | |
5142 } | |
5143 if (enabled != null) { | |
5144 _queryParams["enabled"] = ["${enabled}"]; | |
5145 } | |
5146 if (eventTagTypes != null) { | |
5147 _queryParams["eventTagTypes"] = eventTagTypes; | |
5148 } | |
5149 if (ids != null) { | |
5150 _queryParams["ids"] = ids; | |
5151 } | |
5152 if (searchString != null) { | |
5153 _queryParams["searchString"] = [searchString]; | |
5154 } | |
5155 if (sortField != null) { | |
5156 _queryParams["sortField"] = [sortField]; | |
5157 } | |
5158 if (sortOrder != null) { | |
5159 _queryParams["sortOrder"] = [sortOrder]; | |
5160 } | |
5161 | |
5162 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/eve
ntTags'; | |
5163 | |
5164 var _response = _requester.request(_url, | |
5165 "GET", | |
5166 body: _body, | |
5167 queryParams: _queryParams, | |
5168 uploadOptions: _uploadOptions, | |
5169 uploadMedia: _uploadMedia, | |
5170 downloadOptions: _downloadOptions); | |
5171 return _response.then((data) => new EventTagsListResponse.fromJson(data)); | |
5172 } | |
5173 | |
5174 /** | |
5175 * Updates an existing event tag. This method supports patch semantics. | |
5176 * | |
5177 * [request] - The metadata request object. | |
5178 * | |
5179 * Request parameters: | |
5180 * | |
5181 * [profileId] - User profile ID associated with this request. | |
5182 * | |
5183 * [id] - Event tag ID. | |
5184 * | |
5185 * Completes with a [EventTag]. | |
5186 * | |
5187 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
5188 * error. | |
5189 * | |
5190 * If the used [http.Client] completes with an error when making a REST call, | |
5191 * this method will complete with the same error. | |
5192 */ | |
5193 async.Future<EventTag> patch(EventTag request, core.String profileId, core.Str
ing id) { | |
5194 var _url = null; | |
5195 var _queryParams = new core.Map(); | |
5196 var _uploadMedia = null; | |
5197 var _uploadOptions = null; | |
5198 var _downloadOptions = commons.DownloadOptions.Metadata; | |
5199 var _body = null; | |
5200 | |
5201 if (request != null) { | |
5202 _body = convert.JSON.encode((request).toJson()); | |
5203 } | |
5204 if (profileId == null) { | |
5205 throw new core.ArgumentError("Parameter profileId is required."); | |
5206 } | |
5207 if (id == null) { | |
5208 throw new core.ArgumentError("Parameter id is required."); | |
5209 } | |
5210 _queryParams["id"] = [id]; | |
5211 | |
5212 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/eve
ntTags'; | |
5213 | |
5214 var _response = _requester.request(_url, | |
5215 "PATCH", | |
5216 body: _body, | |
5217 queryParams: _queryParams, | |
5218 uploadOptions: _uploadOptions, | |
5219 uploadMedia: _uploadMedia, | |
5220 downloadOptions: _downloadOptions); | |
5221 return _response.then((data) => new EventTag.fromJson(data)); | |
5222 } | |
5223 | |
5224 /** | |
5225 * Updates an existing event tag. | |
5226 * | |
5227 * [request] - The metadata request object. | |
5228 * | |
5229 * Request parameters: | |
5230 * | |
5231 * [profileId] - User profile ID associated with this request. | |
5232 * | |
5233 * Completes with a [EventTag]. | |
5234 * | |
5235 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
5236 * error. | |
5237 * | |
5238 * If the used [http.Client] completes with an error when making a REST call, | |
5239 * this method will complete with the same error. | |
5240 */ | |
5241 async.Future<EventTag> update(EventTag request, core.String profileId) { | |
5242 var _url = null; | |
5243 var _queryParams = new core.Map(); | |
5244 var _uploadMedia = null; | |
5245 var _uploadOptions = null; | |
5246 var _downloadOptions = commons.DownloadOptions.Metadata; | |
5247 var _body = null; | |
5248 | |
5249 if (request != null) { | |
5250 _body = convert.JSON.encode((request).toJson()); | |
5251 } | |
5252 if (profileId == null) { | |
5253 throw new core.ArgumentError("Parameter profileId is required."); | |
5254 } | |
5255 | |
5256 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/eve
ntTags'; | |
5257 | |
5258 var _response = _requester.request(_url, | |
5259 "PUT", | |
5260 body: _body, | |
5261 queryParams: _queryParams, | |
5262 uploadOptions: _uploadOptions, | |
5263 uploadMedia: _uploadMedia, | |
5264 downloadOptions: _downloadOptions); | |
5265 return _response.then((data) => new EventTag.fromJson(data)); | |
5266 } | |
5267 | |
5268 } | |
5269 | |
5270 | |
5271 class FilesResourceApi { | |
5272 final commons.ApiRequester _requester; | |
5273 | |
5274 FilesResourceApi(commons.ApiRequester client) : | |
5275 _requester = client; | |
5276 | |
5277 /** | |
5278 * Retrieves a report file by its report ID and file ID. | |
5279 * | |
5280 * Request parameters: | |
5281 * | |
5282 * [reportId] - The ID of the report. | |
5283 * | |
5284 * [fileId] - The ID of the report file. | |
5285 * | |
5286 * [downloadOptions] - Options for downloading. A download can be either a | |
5287 * Metadata (default) or Media download. Partial Media downloads are possible | |
5288 * as well. | |
5289 * | |
5290 * Completes with a | |
5291 * | |
5292 * - [File] for Metadata downloads (see [downloadOptions]). | |
5293 * | |
5294 * - [commons.Media] for Media downloads (see [downloadOptions]). | |
5295 * | |
5296 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
5297 * error. | |
5298 * | |
5299 * If the used [http.Client] completes with an error when making a REST call, | |
5300 * this method will complete with the same error. | |
5301 */ | |
5302 async.Future get(core.String reportId, core.String fileId, {commons.DownloadOp
tions downloadOptions: commons.DownloadOptions.Metadata}) { | |
5303 var _url = null; | |
5304 var _queryParams = new core.Map(); | |
5305 var _uploadMedia = null; | |
5306 var _uploadOptions = null; | |
5307 var _downloadOptions = commons.DownloadOptions.Metadata; | |
5308 var _body = null; | |
5309 | |
5310 if (reportId == null) { | |
5311 throw new core.ArgumentError("Parameter reportId is required."); | |
5312 } | |
5313 if (fileId == null) { | |
5314 throw new core.ArgumentError("Parameter fileId is required."); | |
5315 } | |
5316 | |
5317 _downloadOptions = downloadOptions; | |
5318 | |
5319 _url = 'reports/' + commons.Escaper.ecapeVariable('$reportId') + '/files/' +
commons.Escaper.ecapeVariable('$fileId'); | |
5320 | |
5321 var _response = _requester.request(_url, | |
5322 "GET", | |
5323 body: _body, | |
5324 queryParams: _queryParams, | |
5325 uploadOptions: _uploadOptions, | |
5326 uploadMedia: _uploadMedia, | |
5327 downloadOptions: _downloadOptions); | |
5328 if (_downloadOptions == null || | |
5329 _downloadOptions == commons.DownloadOptions.Metadata) { | |
5330 return _response.then((data) => new File.fromJson(data)); | |
5331 } else { | |
5332 return _response; | |
5333 } | |
5334 } | |
5335 | |
5336 /** | |
5337 * Lists files for a user profile. | |
5338 * | |
5339 * Request parameters: | |
5340 * | |
5341 * [profileId] - The DFA profile ID. | |
5342 * | |
5343 * [maxResults] - Maximum number of results to return. | |
5344 * Value must be between "0" and "10". | |
5345 * | |
5346 * [pageToken] - The value of the nextToken from the previous result page. | |
5347 * | |
5348 * [scope] - The scope that defines which results are returned, default is | |
5349 * 'MINE'. | |
5350 * Possible string values are: | |
5351 * - "ALL" : All files in account. | |
5352 * - "MINE" : My files. | |
5353 * - "SHARED_WITH_ME" : Files shared with me. | |
5354 * | |
5355 * [sortField] - The field by which to sort the list. | |
5356 * Possible string values are: | |
5357 * - "ID" : Sort by file ID. | |
5358 * - "LAST_MODIFIED_TIME" : Sort by 'lastmodifiedAt' field. | |
5359 * | |
5360 * [sortOrder] - Order of sorted results, default is 'DESCENDING'. | |
5361 * Possible string values are: | |
5362 * - "ASCENDING" : Ascending order. | |
5363 * - "DESCENDING" : Descending order. | |
5364 * | |
5365 * Completes with a [FileList]. | |
5366 * | |
5367 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
5368 * error. | |
5369 * | |
5370 * If the used [http.Client] completes with an error when making a REST call, | |
5371 * this method will complete with the same error. | |
5372 */ | |
5373 async.Future<FileList> list(core.String profileId, {core.int maxResults, core.
String pageToken, core.String scope, core.String sortField, core.String sortOrde
r}) { | |
5374 var _url = null; | |
5375 var _queryParams = new core.Map(); | |
5376 var _uploadMedia = null; | |
5377 var _uploadOptions = null; | |
5378 var _downloadOptions = commons.DownloadOptions.Metadata; | |
5379 var _body = null; | |
5380 | |
5381 if (profileId == null) { | |
5382 throw new core.ArgumentError("Parameter profileId is required."); | |
5383 } | |
5384 if (maxResults != null) { | |
5385 _queryParams["maxResults"] = ["${maxResults}"]; | |
5386 } | |
5387 if (pageToken != null) { | |
5388 _queryParams["pageToken"] = [pageToken]; | |
5389 } | |
5390 if (scope != null) { | |
5391 _queryParams["scope"] = [scope]; | |
5392 } | |
5393 if (sortField != null) { | |
5394 _queryParams["sortField"] = [sortField]; | |
5395 } | |
5396 if (sortOrder != null) { | |
5397 _queryParams["sortOrder"] = [sortOrder]; | |
5398 } | |
5399 | |
5400 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/fil
es'; | |
5401 | |
5402 var _response = _requester.request(_url, | |
5403 "GET", | |
5404 body: _body, | |
5405 queryParams: _queryParams, | |
5406 uploadOptions: _uploadOptions, | |
5407 uploadMedia: _uploadMedia, | |
5408 downloadOptions: _downloadOptions); | |
5409 return _response.then((data) => new FileList.fromJson(data)); | |
5410 } | |
5411 | |
5412 } | |
5413 | |
5414 | |
5415 class FloodlightActivitiesResourceApi { | |
5416 final commons.ApiRequester _requester; | |
5417 | |
5418 FloodlightActivitiesResourceApi(commons.ApiRequester client) : | |
5419 _requester = client; | |
5420 | |
5421 /** | |
5422 * Deletes an existing floodlight activity. | |
5423 * | |
5424 * Request parameters: | |
5425 * | |
5426 * [profileId] - User profile ID associated with this request. | |
5427 * | |
5428 * [id] - Floodlight activity ID. | |
5429 * | |
5430 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
5431 * error. | |
5432 * | |
5433 * If the used [http.Client] completes with an error when making a REST call, | |
5434 * this method will complete with the same error. | |
5435 */ | |
5436 async.Future delete(core.String profileId, core.String id) { | |
5437 var _url = null; | |
5438 var _queryParams = new core.Map(); | |
5439 var _uploadMedia = null; | |
5440 var _uploadOptions = null; | |
5441 var _downloadOptions = commons.DownloadOptions.Metadata; | |
5442 var _body = null; | |
5443 | |
5444 if (profileId == null) { | |
5445 throw new core.ArgumentError("Parameter profileId is required."); | |
5446 } | |
5447 if (id == null) { | |
5448 throw new core.ArgumentError("Parameter id is required."); | |
5449 } | |
5450 | |
5451 _downloadOptions = null; | |
5452 | |
5453 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/flo
odlightActivities/' + commons.Escaper.ecapeVariable('$id'); | |
5454 | |
5455 var _response = _requester.request(_url, | |
5456 "DELETE", | |
5457 body: _body, | |
5458 queryParams: _queryParams, | |
5459 uploadOptions: _uploadOptions, | |
5460 uploadMedia: _uploadMedia, | |
5461 downloadOptions: _downloadOptions); | |
5462 return _response.then((data) => null); | |
5463 } | |
5464 | |
5465 /** | |
5466 * Generates a tag for a floodlight activity. | |
5467 * | |
5468 * Request parameters: | |
5469 * | |
5470 * [profileId] - User profile ID associated with this request. | |
5471 * | |
5472 * [floodlightActivityId] - Floodlight activity ID for which we want to | |
5473 * generate a tag. | |
5474 * | |
5475 * Completes with a [FloodlightActivitiesGenerateTagResponse]. | |
5476 * | |
5477 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
5478 * error. | |
5479 * | |
5480 * If the used [http.Client] completes with an error when making a REST call, | |
5481 * this method will complete with the same error. | |
5482 */ | |
5483 async.Future<FloodlightActivitiesGenerateTagResponse> generatetag(core.String
profileId, {core.String floodlightActivityId}) { | |
5484 var _url = null; | |
5485 var _queryParams = new core.Map(); | |
5486 var _uploadMedia = null; | |
5487 var _uploadOptions = null; | |
5488 var _downloadOptions = commons.DownloadOptions.Metadata; | |
5489 var _body = null; | |
5490 | |
5491 if (profileId == null) { | |
5492 throw new core.ArgumentError("Parameter profileId is required."); | |
5493 } | |
5494 if (floodlightActivityId != null) { | |
5495 _queryParams["floodlightActivityId"] = [floodlightActivityId]; | |
5496 } | |
5497 | |
5498 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/flo
odlightActivities/generatetag'; | |
5499 | |
5500 var _response = _requester.request(_url, | |
5501 "POST", | |
5502 body: _body, | |
5503 queryParams: _queryParams, | |
5504 uploadOptions: _uploadOptions, | |
5505 uploadMedia: _uploadMedia, | |
5506 downloadOptions: _downloadOptions); | |
5507 return _response.then((data) => new FloodlightActivitiesGenerateTagResponse.
fromJson(data)); | |
5508 } | |
5509 | |
5510 /** | |
5511 * Gets one floodlight activity by ID. | |
5512 * | |
5513 * Request parameters: | |
5514 * | |
5515 * [profileId] - User profile ID associated with this request. | |
5516 * | |
5517 * [id] - Floodlight activity ID. | |
5518 * | |
5519 * Completes with a [FloodlightActivity]. | |
5520 * | |
5521 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
5522 * error. | |
5523 * | |
5524 * If the used [http.Client] completes with an error when making a REST call, | |
5525 * this method will complete with the same error. | |
5526 */ | |
5527 async.Future<FloodlightActivity> get(core.String profileId, core.String id) { | |
5528 var _url = null; | |
5529 var _queryParams = new core.Map(); | |
5530 var _uploadMedia = null; | |
5531 var _uploadOptions = null; | |
5532 var _downloadOptions = commons.DownloadOptions.Metadata; | |
5533 var _body = null; | |
5534 | |
5535 if (profileId == null) { | |
5536 throw new core.ArgumentError("Parameter profileId is required."); | |
5537 } | |
5538 if (id == null) { | |
5539 throw new core.ArgumentError("Parameter id is required."); | |
5540 } | |
5541 | |
5542 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/flo
odlightActivities/' + commons.Escaper.ecapeVariable('$id'); | |
5543 | |
5544 var _response = _requester.request(_url, | |
5545 "GET", | |
5546 body: _body, | |
5547 queryParams: _queryParams, | |
5548 uploadOptions: _uploadOptions, | |
5549 uploadMedia: _uploadMedia, | |
5550 downloadOptions: _downloadOptions); | |
5551 return _response.then((data) => new FloodlightActivity.fromJson(data)); | |
5552 } | |
5553 | |
5554 /** | |
5555 * Inserts a new floodlight activity. | |
5556 * | |
5557 * [request] - The metadata request object. | |
5558 * | |
5559 * Request parameters: | |
5560 * | |
5561 * [profileId] - User profile ID associated with this request. | |
5562 * | |
5563 * Completes with a [FloodlightActivity]. | |
5564 * | |
5565 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
5566 * error. | |
5567 * | |
5568 * If the used [http.Client] completes with an error when making a REST call, | |
5569 * this method will complete with the same error. | |
5570 */ | |
5571 async.Future<FloodlightActivity> insert(FloodlightActivity request, core.Strin
g profileId) { | |
5572 var _url = null; | |
5573 var _queryParams = new core.Map(); | |
5574 var _uploadMedia = null; | |
5575 var _uploadOptions = null; | |
5576 var _downloadOptions = commons.DownloadOptions.Metadata; | |
5577 var _body = null; | |
5578 | |
5579 if (request != null) { | |
5580 _body = convert.JSON.encode((request).toJson()); | |
5581 } | |
5582 if (profileId == null) { | |
5583 throw new core.ArgumentError("Parameter profileId is required."); | |
5584 } | |
5585 | |
5586 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/flo
odlightActivities'; | |
5587 | |
5588 var _response = _requester.request(_url, | |
5589 "POST", | |
5590 body: _body, | |
5591 queryParams: _queryParams, | |
5592 uploadOptions: _uploadOptions, | |
5593 uploadMedia: _uploadMedia, | |
5594 downloadOptions: _downloadOptions); | |
5595 return _response.then((data) => new FloodlightActivity.fromJson(data)); | |
5596 } | |
5597 | |
5598 /** | |
5599 * Retrieves a list of floodlight activities, possibly filtered. | |
5600 * | |
5601 * Request parameters: | |
5602 * | |
5603 * [profileId] - User profile ID associated with this request. | |
5604 * | |
5605 * [advertiserId] - Select only floodlight activities for the specified | |
5606 * advertiser ID. Must specify either ids, advertiserId, or | |
5607 * floodlightConfigurationId for a non-empty result. | |
5608 * | |
5609 * [floodlightActivityGroupIds] - Select only floodlight activities with the | |
5610 * specified floodlight activity group IDs. | |
5611 * | |
5612 * [floodlightActivityGroupName] - Select only floodlight activities with the | |
5613 * specified floodlight activity group name. | |
5614 * | |
5615 * [floodlightActivityGroupTagString] - Select only floodlight activities with | |
5616 * the specified floodlight activity group tag string. | |
5617 * | |
5618 * [floodlightActivityGroupType] - Select only floodlight activities with the | |
5619 * specified floodlight activity group type. | |
5620 * Possible string values are: | |
5621 * - "COUNTER" | |
5622 * - "SALE" | |
5623 * | |
5624 * [floodlightConfigurationId] - Select only floodlight activities for the | |
5625 * specified floodlight configuration ID. Must specify either ids, | |
5626 * advertiserId, or floodlightConfigurationId for a non-empty result. | |
5627 * | |
5628 * [ids] - Select only floodlight activities with the specified IDs. Must | |
5629 * specify either ids, advertiserId, or floodlightConfigurationId for a | |
5630 * non-empty result. | |
5631 * | |
5632 * [maxResults] - Maximum number of results to return. | |
5633 * | |
5634 * [pageToken] - Value of the nextPageToken from the previous result page. | |
5635 * | |
5636 * [searchString] - Allows searching for objects by name or ID. Wildcards (*) | |
5637 * are allowed. For example, "floodlightactivity*2015" will return objects | |
5638 * with names like "floodlightactivity June 2015", "floodlightactivity April | |
5639 * 2015", or simply "floodlightactivity 2015". Most of the searches also add | |
5640 * wildcards implicitly at the start and the end of the search string. For | |
5641 * example, a search string of "floodlightactivity" will match objects with | |
5642 * name "my floodlightactivity activity", "floodlightactivity 2015", or simply | |
5643 * "floodlightactivity". | |
5644 * | |
5645 * [sortField] - Field by which to sort the list. | |
5646 * Possible string values are: | |
5647 * - "ID" | |
5648 * - "NAME" | |
5649 * | |
5650 * [sortOrder] - Order of sorted results, default is ASCENDING. | |
5651 * Possible string values are: | |
5652 * - "ASCENDING" | |
5653 * - "DESCENDING" | |
5654 * | |
5655 * [tagString] - Select only floodlight activities with the specified tag | |
5656 * string. | |
5657 * | |
5658 * Completes with a [FloodlightActivitiesListResponse]. | |
5659 * | |
5660 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
5661 * error. | |
5662 * | |
5663 * If the used [http.Client] completes with an error when making a REST call, | |
5664 * this method will complete with the same error. | |
5665 */ | |
5666 async.Future<FloodlightActivitiesListResponse> list(core.String profileId, {co
re.String advertiserId, core.List<core.String> floodlightActivityGroupIds, core.
String floodlightActivityGroupName, core.String floodlightActivityGroupTagString
, core.String floodlightActivityGroupType, core.String floodlightConfigurationId
, core.List<core.String> ids, core.int maxResults, core.String pageToken, core.S
tring searchString, core.String sortField, core.String sortOrder, core.String ta
gString}) { | |
5667 var _url = null; | |
5668 var _queryParams = new core.Map(); | |
5669 var _uploadMedia = null; | |
5670 var _uploadOptions = null; | |
5671 var _downloadOptions = commons.DownloadOptions.Metadata; | |
5672 var _body = null; | |
5673 | |
5674 if (profileId == null) { | |
5675 throw new core.ArgumentError("Parameter profileId is required."); | |
5676 } | |
5677 if (advertiserId != null) { | |
5678 _queryParams["advertiserId"] = [advertiserId]; | |
5679 } | |
5680 if (floodlightActivityGroupIds != null) { | |
5681 _queryParams["floodlightActivityGroupIds"] = floodlightActivityGroupIds; | |
5682 } | |
5683 if (floodlightActivityGroupName != null) { | |
5684 _queryParams["floodlightActivityGroupName"] = [floodlightActivityGroupName
]; | |
5685 } | |
5686 if (floodlightActivityGroupTagString != null) { | |
5687 _queryParams["floodlightActivityGroupTagString"] = [floodlightActivityGrou
pTagString]; | |
5688 } | |
5689 if (floodlightActivityGroupType != null) { | |
5690 _queryParams["floodlightActivityGroupType"] = [floodlightActivityGroupType
]; | |
5691 } | |
5692 if (floodlightConfigurationId != null) { | |
5693 _queryParams["floodlightConfigurationId"] = [floodlightConfigurationId]; | |
5694 } | |
5695 if (ids != null) { | |
5696 _queryParams["ids"] = ids; | |
5697 } | |
5698 if (maxResults != null) { | |
5699 _queryParams["maxResults"] = ["${maxResults}"]; | |
5700 } | |
5701 if (pageToken != null) { | |
5702 _queryParams["pageToken"] = [pageToken]; | |
5703 } | |
5704 if (searchString != null) { | |
5705 _queryParams["searchString"] = [searchString]; | |
5706 } | |
5707 if (sortField != null) { | |
5708 _queryParams["sortField"] = [sortField]; | |
5709 } | |
5710 if (sortOrder != null) { | |
5711 _queryParams["sortOrder"] = [sortOrder]; | |
5712 } | |
5713 if (tagString != null) { | |
5714 _queryParams["tagString"] = [tagString]; | |
5715 } | |
5716 | |
5717 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/flo
odlightActivities'; | |
5718 | |
5719 var _response = _requester.request(_url, | |
5720 "GET", | |
5721 body: _body, | |
5722 queryParams: _queryParams, | |
5723 uploadOptions: _uploadOptions, | |
5724 uploadMedia: _uploadMedia, | |
5725 downloadOptions: _downloadOptions); | |
5726 return _response.then((data) => new FloodlightActivitiesListResponse.fromJso
n(data)); | |
5727 } | |
5728 | |
5729 /** | |
5730 * Updates an existing floodlight activity. This method supports patch | |
5731 * semantics. | |
5732 * | |
5733 * [request] - The metadata request object. | |
5734 * | |
5735 * Request parameters: | |
5736 * | |
5737 * [profileId] - User profile ID associated with this request. | |
5738 * | |
5739 * [id] - Floodlight activity ID. | |
5740 * | |
5741 * Completes with a [FloodlightActivity]. | |
5742 * | |
5743 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
5744 * error. | |
5745 * | |
5746 * If the used [http.Client] completes with an error when making a REST call, | |
5747 * this method will complete with the same error. | |
5748 */ | |
5749 async.Future<FloodlightActivity> patch(FloodlightActivity request, core.String
profileId, core.String id) { | |
5750 var _url = null; | |
5751 var _queryParams = new core.Map(); | |
5752 var _uploadMedia = null; | |
5753 var _uploadOptions = null; | |
5754 var _downloadOptions = commons.DownloadOptions.Metadata; | |
5755 var _body = null; | |
5756 | |
5757 if (request != null) { | |
5758 _body = convert.JSON.encode((request).toJson()); | |
5759 } | |
5760 if (profileId == null) { | |
5761 throw new core.ArgumentError("Parameter profileId is required."); | |
5762 } | |
5763 if (id == null) { | |
5764 throw new core.ArgumentError("Parameter id is required."); | |
5765 } | |
5766 _queryParams["id"] = [id]; | |
5767 | |
5768 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/flo
odlightActivities'; | |
5769 | |
5770 var _response = _requester.request(_url, | |
5771 "PATCH", | |
5772 body: _body, | |
5773 queryParams: _queryParams, | |
5774 uploadOptions: _uploadOptions, | |
5775 uploadMedia: _uploadMedia, | |
5776 downloadOptions: _downloadOptions); | |
5777 return _response.then((data) => new FloodlightActivity.fromJson(data)); | |
5778 } | |
5779 | |
5780 /** | |
5781 * Updates an existing floodlight activity. | |
5782 * | |
5783 * [request] - The metadata request object. | |
5784 * | |
5785 * Request parameters: | |
5786 * | |
5787 * [profileId] - User profile ID associated with this request. | |
5788 * | |
5789 * Completes with a [FloodlightActivity]. | |
5790 * | |
5791 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
5792 * error. | |
5793 * | |
5794 * If the used [http.Client] completes with an error when making a REST call, | |
5795 * this method will complete with the same error. | |
5796 */ | |
5797 async.Future<FloodlightActivity> update(FloodlightActivity request, core.Strin
g profileId) { | |
5798 var _url = null; | |
5799 var _queryParams = new core.Map(); | |
5800 var _uploadMedia = null; | |
5801 var _uploadOptions = null; | |
5802 var _downloadOptions = commons.DownloadOptions.Metadata; | |
5803 var _body = null; | |
5804 | |
5805 if (request != null) { | |
5806 _body = convert.JSON.encode((request).toJson()); | |
5807 } | |
5808 if (profileId == null) { | |
5809 throw new core.ArgumentError("Parameter profileId is required."); | |
5810 } | |
5811 | |
5812 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/flo
odlightActivities'; | |
5813 | |
5814 var _response = _requester.request(_url, | |
5815 "PUT", | |
5816 body: _body, | |
5817 queryParams: _queryParams, | |
5818 uploadOptions: _uploadOptions, | |
5819 uploadMedia: _uploadMedia, | |
5820 downloadOptions: _downloadOptions); | |
5821 return _response.then((data) => new FloodlightActivity.fromJson(data)); | |
5822 } | |
5823 | |
5824 } | |
5825 | |
5826 | |
5827 class FloodlightActivityGroupsResourceApi { | |
5828 final commons.ApiRequester _requester; | |
5829 | |
5830 FloodlightActivityGroupsResourceApi(commons.ApiRequester client) : | |
5831 _requester = client; | |
5832 | |
5833 /** | |
5834 * Gets one floodlight activity group by ID. | |
5835 * | |
5836 * Request parameters: | |
5837 * | |
5838 * [profileId] - User profile ID associated with this request. | |
5839 * | |
5840 * [id] - Floodlight activity Group ID. | |
5841 * | |
5842 * Completes with a [FloodlightActivityGroup]. | |
5843 * | |
5844 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
5845 * error. | |
5846 * | |
5847 * If the used [http.Client] completes with an error when making a REST call, | |
5848 * this method will complete with the same error. | |
5849 */ | |
5850 async.Future<FloodlightActivityGroup> get(core.String profileId, core.String i
d) { | |
5851 var _url = null; | |
5852 var _queryParams = new core.Map(); | |
5853 var _uploadMedia = null; | |
5854 var _uploadOptions = null; | |
5855 var _downloadOptions = commons.DownloadOptions.Metadata; | |
5856 var _body = null; | |
5857 | |
5858 if (profileId == null) { | |
5859 throw new core.ArgumentError("Parameter profileId is required."); | |
5860 } | |
5861 if (id == null) { | |
5862 throw new core.ArgumentError("Parameter id is required."); | |
5863 } | |
5864 | |
5865 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/flo
odlightActivityGroups/' + commons.Escaper.ecapeVariable('$id'); | |
5866 | |
5867 var _response = _requester.request(_url, | |
5868 "GET", | |
5869 body: _body, | |
5870 queryParams: _queryParams, | |
5871 uploadOptions: _uploadOptions, | |
5872 uploadMedia: _uploadMedia, | |
5873 downloadOptions: _downloadOptions); | |
5874 return _response.then((data) => new FloodlightActivityGroup.fromJson(data)); | |
5875 } | |
5876 | |
5877 /** | |
5878 * Inserts a new floodlight activity group. | |
5879 * | |
5880 * [request] - The metadata request object. | |
5881 * | |
5882 * Request parameters: | |
5883 * | |
5884 * [profileId] - User profile ID associated with this request. | |
5885 * | |
5886 * Completes with a [FloodlightActivityGroup]. | |
5887 * | |
5888 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
5889 * error. | |
5890 * | |
5891 * If the used [http.Client] completes with an error when making a REST call, | |
5892 * this method will complete with the same error. | |
5893 */ | |
5894 async.Future<FloodlightActivityGroup> insert(FloodlightActivityGroup request,
core.String profileId) { | |
5895 var _url = null; | |
5896 var _queryParams = new core.Map(); | |
5897 var _uploadMedia = null; | |
5898 var _uploadOptions = null; | |
5899 var _downloadOptions = commons.DownloadOptions.Metadata; | |
5900 var _body = null; | |
5901 | |
5902 if (request != null) { | |
5903 _body = convert.JSON.encode((request).toJson()); | |
5904 } | |
5905 if (profileId == null) { | |
5906 throw new core.ArgumentError("Parameter profileId is required."); | |
5907 } | |
5908 | |
5909 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/flo
odlightActivityGroups'; | |
5910 | |
5911 var _response = _requester.request(_url, | |
5912 "POST", | |
5913 body: _body, | |
5914 queryParams: _queryParams, | |
5915 uploadOptions: _uploadOptions, | |
5916 uploadMedia: _uploadMedia, | |
5917 downloadOptions: _downloadOptions); | |
5918 return _response.then((data) => new FloodlightActivityGroup.fromJson(data)); | |
5919 } | |
5920 | |
5921 /** | |
5922 * Retrieves a list of floodlight activity groups, possibly filtered. | |
5923 * | |
5924 * Request parameters: | |
5925 * | |
5926 * [profileId] - User profile ID associated with this request. | |
5927 * | |
5928 * [advertiserId] - Select only floodlight activity groups with the specified | |
5929 * advertiser ID. Must specify either advertiserId or | |
5930 * floodlightConfigurationId for a non-empty result. | |
5931 * | |
5932 * [floodlightConfigurationId] - Select only floodlight activity groups with | |
5933 * the specified floodlight configuration ID. Must specify either | |
5934 * advertiserId, or floodlightConfigurationId for a non-empty result. | |
5935 * | |
5936 * [ids] - Select only floodlight activity groups with the specified IDs. Must | |
5937 * specify either advertiserId or floodlightConfigurationId for a non-empty | |
5938 * result. | |
5939 * | |
5940 * [maxResults] - Maximum number of results to return. | |
5941 * | |
5942 * [pageToken] - Value of the nextPageToken from the previous result page. | |
5943 * | |
5944 * [searchString] - Allows searching for objects by name or ID. Wildcards (*) | |
5945 * are allowed. For example, "floodlightactivitygroup*2015" will return | |
5946 * objects with names like "floodlightactivitygroup June 2015", | |
5947 * "floodlightactivitygroup April 2015", or simply "floodlightactivitygroup | |
5948 * 2015". Most of the searches also add wildcards implicitly at the start and | |
5949 * the end of the search string. For example, a search string of | |
5950 * "floodlightactivitygroup" will match objects with name "my | |
5951 * floodlightactivitygroup activity", "floodlightactivitygroup 2015", or | |
5952 * simply "floodlightactivitygroup". | |
5953 * | |
5954 * [sortField] - Field by which to sort the list. | |
5955 * Possible string values are: | |
5956 * - "ID" | |
5957 * - "NAME" | |
5958 * | |
5959 * [sortOrder] - Order of sorted results, default is ASCENDING. | |
5960 * Possible string values are: | |
5961 * - "ASCENDING" | |
5962 * - "DESCENDING" | |
5963 * | |
5964 * [type] - Select only floodlight activity groups with the specified | |
5965 * floodlight activity group type. | |
5966 * Possible string values are: | |
5967 * - "COUNTER" | |
5968 * - "SALE" | |
5969 * | |
5970 * Completes with a [FloodlightActivityGroupsListResponse]. | |
5971 * | |
5972 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
5973 * error. | |
5974 * | |
5975 * If the used [http.Client] completes with an error when making a REST call, | |
5976 * this method will complete with the same error. | |
5977 */ | |
5978 async.Future<FloodlightActivityGroupsListResponse> list(core.String profileId,
{core.String advertiserId, core.String floodlightConfigurationId, core.List<cor
e.String> ids, core.int maxResults, core.String pageToken, core.String searchStr
ing, core.String sortField, core.String sortOrder, core.String type}) { | |
5979 var _url = null; | |
5980 var _queryParams = new core.Map(); | |
5981 var _uploadMedia = null; | |
5982 var _uploadOptions = null; | |
5983 var _downloadOptions = commons.DownloadOptions.Metadata; | |
5984 var _body = null; | |
5985 | |
5986 if (profileId == null) { | |
5987 throw new core.ArgumentError("Parameter profileId is required."); | |
5988 } | |
5989 if (advertiserId != null) { | |
5990 _queryParams["advertiserId"] = [advertiserId]; | |
5991 } | |
5992 if (floodlightConfigurationId != null) { | |
5993 _queryParams["floodlightConfigurationId"] = [floodlightConfigurationId]; | |
5994 } | |
5995 if (ids != null) { | |
5996 _queryParams["ids"] = ids; | |
5997 } | |
5998 if (maxResults != null) { | |
5999 _queryParams["maxResults"] = ["${maxResults}"]; | |
6000 } | |
6001 if (pageToken != null) { | |
6002 _queryParams["pageToken"] = [pageToken]; | |
6003 } | |
6004 if (searchString != null) { | |
6005 _queryParams["searchString"] = [searchString]; | |
6006 } | |
6007 if (sortField != null) { | |
6008 _queryParams["sortField"] = [sortField]; | |
6009 } | |
6010 if (sortOrder != null) { | |
6011 _queryParams["sortOrder"] = [sortOrder]; | |
6012 } | |
6013 if (type != null) { | |
6014 _queryParams["type"] = [type]; | |
6015 } | |
6016 | |
6017 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/flo
odlightActivityGroups'; | |
6018 | |
6019 var _response = _requester.request(_url, | |
6020 "GET", | |
6021 body: _body, | |
6022 queryParams: _queryParams, | |
6023 uploadOptions: _uploadOptions, | |
6024 uploadMedia: _uploadMedia, | |
6025 downloadOptions: _downloadOptions); | |
6026 return _response.then((data) => new FloodlightActivityGroupsListResponse.fro
mJson(data)); | |
6027 } | |
6028 | |
6029 /** | |
6030 * Updates an existing floodlight activity group. This method supports patch | |
6031 * semantics. | |
6032 * | |
6033 * [request] - The metadata request object. | |
6034 * | |
6035 * Request parameters: | |
6036 * | |
6037 * [profileId] - User profile ID associated with this request. | |
6038 * | |
6039 * [id] - Floodlight activity Group ID. | |
6040 * | |
6041 * Completes with a [FloodlightActivityGroup]. | |
6042 * | |
6043 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
6044 * error. | |
6045 * | |
6046 * If the used [http.Client] completes with an error when making a REST call, | |
6047 * this method will complete with the same error. | |
6048 */ | |
6049 async.Future<FloodlightActivityGroup> patch(FloodlightActivityGroup request, c
ore.String profileId, core.String id) { | |
6050 var _url = null; | |
6051 var _queryParams = new core.Map(); | |
6052 var _uploadMedia = null; | |
6053 var _uploadOptions = null; | |
6054 var _downloadOptions = commons.DownloadOptions.Metadata; | |
6055 var _body = null; | |
6056 | |
6057 if (request != null) { | |
6058 _body = convert.JSON.encode((request).toJson()); | |
6059 } | |
6060 if (profileId == null) { | |
6061 throw new core.ArgumentError("Parameter profileId is required."); | |
6062 } | |
6063 if (id == null) { | |
6064 throw new core.ArgumentError("Parameter id is required."); | |
6065 } | |
6066 _queryParams["id"] = [id]; | |
6067 | |
6068 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/flo
odlightActivityGroups'; | |
6069 | |
6070 var _response = _requester.request(_url, | |
6071 "PATCH", | |
6072 body: _body, | |
6073 queryParams: _queryParams, | |
6074 uploadOptions: _uploadOptions, | |
6075 uploadMedia: _uploadMedia, | |
6076 downloadOptions: _downloadOptions); | |
6077 return _response.then((data) => new FloodlightActivityGroup.fromJson(data)); | |
6078 } | |
6079 | |
6080 /** | |
6081 * Updates an existing floodlight activity group. | |
6082 * | |
6083 * [request] - The metadata request object. | |
6084 * | |
6085 * Request parameters: | |
6086 * | |
6087 * [profileId] - User profile ID associated with this request. | |
6088 * | |
6089 * Completes with a [FloodlightActivityGroup]. | |
6090 * | |
6091 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
6092 * error. | |
6093 * | |
6094 * If the used [http.Client] completes with an error when making a REST call, | |
6095 * this method will complete with the same error. | |
6096 */ | |
6097 async.Future<FloodlightActivityGroup> update(FloodlightActivityGroup request,
core.String profileId) { | |
6098 var _url = null; | |
6099 var _queryParams = new core.Map(); | |
6100 var _uploadMedia = null; | |
6101 var _uploadOptions = null; | |
6102 var _downloadOptions = commons.DownloadOptions.Metadata; | |
6103 var _body = null; | |
6104 | |
6105 if (request != null) { | |
6106 _body = convert.JSON.encode((request).toJson()); | |
6107 } | |
6108 if (profileId == null) { | |
6109 throw new core.ArgumentError("Parameter profileId is required."); | |
6110 } | |
6111 | |
6112 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/flo
odlightActivityGroups'; | |
6113 | |
6114 var _response = _requester.request(_url, | |
6115 "PUT", | |
6116 body: _body, | |
6117 queryParams: _queryParams, | |
6118 uploadOptions: _uploadOptions, | |
6119 uploadMedia: _uploadMedia, | |
6120 downloadOptions: _downloadOptions); | |
6121 return _response.then((data) => new FloodlightActivityGroup.fromJson(data)); | |
6122 } | |
6123 | |
6124 } | |
6125 | |
6126 | |
6127 class FloodlightConfigurationsResourceApi { | |
6128 final commons.ApiRequester _requester; | |
6129 | |
6130 FloodlightConfigurationsResourceApi(commons.ApiRequester client) : | |
6131 _requester = client; | |
6132 | |
6133 /** | |
6134 * Gets one floodlight configuration by ID. | |
6135 * | |
6136 * Request parameters: | |
6137 * | |
6138 * [profileId] - User profile ID associated with this request. | |
6139 * | |
6140 * [id] - Floodlight configuration ID. | |
6141 * | |
6142 * Completes with a [FloodlightConfiguration]. | |
6143 * | |
6144 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
6145 * error. | |
6146 * | |
6147 * If the used [http.Client] completes with an error when making a REST call, | |
6148 * this method will complete with the same error. | |
6149 */ | |
6150 async.Future<FloodlightConfiguration> get(core.String profileId, core.String i
d) { | |
6151 var _url = null; | |
6152 var _queryParams = new core.Map(); | |
6153 var _uploadMedia = null; | |
6154 var _uploadOptions = null; | |
6155 var _downloadOptions = commons.DownloadOptions.Metadata; | |
6156 var _body = null; | |
6157 | |
6158 if (profileId == null) { | |
6159 throw new core.ArgumentError("Parameter profileId is required."); | |
6160 } | |
6161 if (id == null) { | |
6162 throw new core.ArgumentError("Parameter id is required."); | |
6163 } | |
6164 | |
6165 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/flo
odlightConfigurations/' + commons.Escaper.ecapeVariable('$id'); | |
6166 | |
6167 var _response = _requester.request(_url, | |
6168 "GET", | |
6169 body: _body, | |
6170 queryParams: _queryParams, | |
6171 uploadOptions: _uploadOptions, | |
6172 uploadMedia: _uploadMedia, | |
6173 downloadOptions: _downloadOptions); | |
6174 return _response.then((data) => new FloodlightConfiguration.fromJson(data)); | |
6175 } | |
6176 | |
6177 /** | |
6178 * Retrieves a list of floodlight configurations, possibly filtered. | |
6179 * | |
6180 * Request parameters: | |
6181 * | |
6182 * [profileId] - User profile ID associated with this request. | |
6183 * | |
6184 * [ids] - Set of IDs of floodlight configurations to retrieve. Required | |
6185 * field; otherwise an empty list will be returned. | |
6186 * | |
6187 * Completes with a [FloodlightConfigurationsListResponse]. | |
6188 * | |
6189 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
6190 * error. | |
6191 * | |
6192 * If the used [http.Client] completes with an error when making a REST call, | |
6193 * this method will complete with the same error. | |
6194 */ | |
6195 async.Future<FloodlightConfigurationsListResponse> list(core.String profileId,
{core.List<core.String> ids}) { | |
6196 var _url = null; | |
6197 var _queryParams = new core.Map(); | |
6198 var _uploadMedia = null; | |
6199 var _uploadOptions = null; | |
6200 var _downloadOptions = commons.DownloadOptions.Metadata; | |
6201 var _body = null; | |
6202 | |
6203 if (profileId == null) { | |
6204 throw new core.ArgumentError("Parameter profileId is required."); | |
6205 } | |
6206 if (ids != null) { | |
6207 _queryParams["ids"] = ids; | |
6208 } | |
6209 | |
6210 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/flo
odlightConfigurations'; | |
6211 | |
6212 var _response = _requester.request(_url, | |
6213 "GET", | |
6214 body: _body, | |
6215 queryParams: _queryParams, | |
6216 uploadOptions: _uploadOptions, | |
6217 uploadMedia: _uploadMedia, | |
6218 downloadOptions: _downloadOptions); | |
6219 return _response.then((data) => new FloodlightConfigurationsListResponse.fro
mJson(data)); | |
6220 } | |
6221 | |
6222 /** | |
6223 * Updates an existing floodlight configuration. This method supports patch | |
6224 * semantics. | |
6225 * | |
6226 * [request] - The metadata request object. | |
6227 * | |
6228 * Request parameters: | |
6229 * | |
6230 * [profileId] - User profile ID associated with this request. | |
6231 * | |
6232 * [id] - Floodlight configuration ID. | |
6233 * | |
6234 * Completes with a [FloodlightConfiguration]. | |
6235 * | |
6236 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
6237 * error. | |
6238 * | |
6239 * If the used [http.Client] completes with an error when making a REST call, | |
6240 * this method will complete with the same error. | |
6241 */ | |
6242 async.Future<FloodlightConfiguration> patch(FloodlightConfiguration request, c
ore.String profileId, core.String id) { | |
6243 var _url = null; | |
6244 var _queryParams = new core.Map(); | |
6245 var _uploadMedia = null; | |
6246 var _uploadOptions = null; | |
6247 var _downloadOptions = commons.DownloadOptions.Metadata; | |
6248 var _body = null; | |
6249 | |
6250 if (request != null) { | |
6251 _body = convert.JSON.encode((request).toJson()); | |
6252 } | |
6253 if (profileId == null) { | |
6254 throw new core.ArgumentError("Parameter profileId is required."); | |
6255 } | |
6256 if (id == null) { | |
6257 throw new core.ArgumentError("Parameter id is required."); | |
6258 } | |
6259 _queryParams["id"] = [id]; | |
6260 | |
6261 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/flo
odlightConfigurations'; | |
6262 | |
6263 var _response = _requester.request(_url, | |
6264 "PATCH", | |
6265 body: _body, | |
6266 queryParams: _queryParams, | |
6267 uploadOptions: _uploadOptions, | |
6268 uploadMedia: _uploadMedia, | |
6269 downloadOptions: _downloadOptions); | |
6270 return _response.then((data) => new FloodlightConfiguration.fromJson(data)); | |
6271 } | |
6272 | |
6273 /** | |
6274 * Updates an existing floodlight configuration. | |
6275 * | |
6276 * [request] - The metadata request object. | |
6277 * | |
6278 * Request parameters: | |
6279 * | |
6280 * [profileId] - User profile ID associated with this request. | |
6281 * | |
6282 * Completes with a [FloodlightConfiguration]. | |
6283 * | |
6284 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
6285 * error. | |
6286 * | |
6287 * If the used [http.Client] completes with an error when making a REST call, | |
6288 * this method will complete with the same error. | |
6289 */ | |
6290 async.Future<FloodlightConfiguration> update(FloodlightConfiguration request,
core.String profileId) { | |
6291 var _url = null; | |
6292 var _queryParams = new core.Map(); | |
6293 var _uploadMedia = null; | |
6294 var _uploadOptions = null; | |
6295 var _downloadOptions = commons.DownloadOptions.Metadata; | |
6296 var _body = null; | |
6297 | |
6298 if (request != null) { | |
6299 _body = convert.JSON.encode((request).toJson()); | |
6300 } | |
6301 if (profileId == null) { | |
6302 throw new core.ArgumentError("Parameter profileId is required."); | |
6303 } | |
6304 | |
6305 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/flo
odlightConfigurations'; | |
6306 | |
6307 var _response = _requester.request(_url, | |
6308 "PUT", | |
6309 body: _body, | |
6310 queryParams: _queryParams, | |
6311 uploadOptions: _uploadOptions, | |
6312 uploadMedia: _uploadMedia, | |
6313 downloadOptions: _downloadOptions); | |
6314 return _response.then((data) => new FloodlightConfiguration.fromJson(data)); | |
6315 } | |
6316 | |
6317 } | |
6318 | |
6319 | |
6320 class InventoryItemsResourceApi { | |
6321 final commons.ApiRequester _requester; | |
6322 | |
6323 InventoryItemsResourceApi(commons.ApiRequester client) : | |
6324 _requester = client; | |
6325 | |
6326 /** | |
6327 * Gets one inventory item by ID. | |
6328 * | |
6329 * Request parameters: | |
6330 * | |
6331 * [profileId] - User profile ID associated with this request. | |
6332 * | |
6333 * [projectId] - Project ID for order documents. | |
6334 * | |
6335 * [id] - Inventory item ID. | |
6336 * | |
6337 * Completes with a [InventoryItem]. | |
6338 * | |
6339 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
6340 * error. | |
6341 * | |
6342 * If the used [http.Client] completes with an error when making a REST call, | |
6343 * this method will complete with the same error. | |
6344 */ | |
6345 async.Future<InventoryItem> get(core.String profileId, core.String projectId,
core.String id) { | |
6346 var _url = null; | |
6347 var _queryParams = new core.Map(); | |
6348 var _uploadMedia = null; | |
6349 var _uploadOptions = null; | |
6350 var _downloadOptions = commons.DownloadOptions.Metadata; | |
6351 var _body = null; | |
6352 | |
6353 if (profileId == null) { | |
6354 throw new core.ArgumentError("Parameter profileId is required."); | |
6355 } | |
6356 if (projectId == null) { | |
6357 throw new core.ArgumentError("Parameter projectId is required."); | |
6358 } | |
6359 if (id == null) { | |
6360 throw new core.ArgumentError("Parameter id is required."); | |
6361 } | |
6362 | |
6363 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/pro
jects/' + commons.Escaper.ecapeVariable('$projectId') + '/inventoryItems/' + com
mons.Escaper.ecapeVariable('$id'); | |
6364 | |
6365 var _response = _requester.request(_url, | |
6366 "GET", | |
6367 body: _body, | |
6368 queryParams: _queryParams, | |
6369 uploadOptions: _uploadOptions, | |
6370 uploadMedia: _uploadMedia, | |
6371 downloadOptions: _downloadOptions); | |
6372 return _response.then((data) => new InventoryItem.fromJson(data)); | |
6373 } | |
6374 | |
6375 /** | |
6376 * Retrieves a list of inventory items, possibly filtered. | |
6377 * | |
6378 * Request parameters: | |
6379 * | |
6380 * [profileId] - User profile ID associated with this request. | |
6381 * | |
6382 * [projectId] - Project ID for order documents. | |
6383 * | |
6384 * [ids] - Select only inventory items with these IDs. | |
6385 * | |
6386 * [inPlan] - Select only inventory items that are in plan. | |
6387 * | |
6388 * [maxResults] - Maximum number of results to return. | |
6389 * | |
6390 * [orderId] - Select only inventory items that belong to specified orders. | |
6391 * | |
6392 * [pageToken] - Value of the nextPageToken from the previous result page. | |
6393 * | |
6394 * [siteId] - Select only inventory items that are associated with these | |
6395 * sites. | |
6396 * | |
6397 * [sortField] - Field by which to sort the list. | |
6398 * Possible string values are: | |
6399 * - "ID" | |
6400 * - "NAME" | |
6401 * | |
6402 * [sortOrder] - Order of sorted results, default is ASCENDING. | |
6403 * Possible string values are: | |
6404 * - "ASCENDING" | |
6405 * - "DESCENDING" | |
6406 * | |
6407 * Completes with a [InventoryItemsListResponse]. | |
6408 * | |
6409 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
6410 * error. | |
6411 * | |
6412 * If the used [http.Client] completes with an error when making a REST call, | |
6413 * this method will complete with the same error. | |
6414 */ | |
6415 async.Future<InventoryItemsListResponse> list(core.String profileId, core.Stri
ng projectId, {core.List<core.String> ids, core.bool inPlan, core.int maxResults
, core.List<core.String> orderId, core.String pageToken, core.List<core.String>
siteId, core.String sortField, core.String sortOrder}) { | |
6416 var _url = null; | |
6417 var _queryParams = new core.Map(); | |
6418 var _uploadMedia = null; | |
6419 var _uploadOptions = null; | |
6420 var _downloadOptions = commons.DownloadOptions.Metadata; | |
6421 var _body = null; | |
6422 | |
6423 if (profileId == null) { | |
6424 throw new core.ArgumentError("Parameter profileId is required."); | |
6425 } | |
6426 if (projectId == null) { | |
6427 throw new core.ArgumentError("Parameter projectId is required."); | |
6428 } | |
6429 if (ids != null) { | |
6430 _queryParams["ids"] = ids; | |
6431 } | |
6432 if (inPlan != null) { | |
6433 _queryParams["inPlan"] = ["${inPlan}"]; | |
6434 } | |
6435 if (maxResults != null) { | |
6436 _queryParams["maxResults"] = ["${maxResults}"]; | |
6437 } | |
6438 if (orderId != null) { | |
6439 _queryParams["orderId"] = orderId; | |
6440 } | |
6441 if (pageToken != null) { | |
6442 _queryParams["pageToken"] = [pageToken]; | |
6443 } | |
6444 if (siteId != null) { | |
6445 _queryParams["siteId"] = siteId; | |
6446 } | |
6447 if (sortField != null) { | |
6448 _queryParams["sortField"] = [sortField]; | |
6449 } | |
6450 if (sortOrder != null) { | |
6451 _queryParams["sortOrder"] = [sortOrder]; | |
6452 } | |
6453 | |
6454 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/pro
jects/' + commons.Escaper.ecapeVariable('$projectId') + '/inventoryItems'; | |
6455 | |
6456 var _response = _requester.request(_url, | |
6457 "GET", | |
6458 body: _body, | |
6459 queryParams: _queryParams, | |
6460 uploadOptions: _uploadOptions, | |
6461 uploadMedia: _uploadMedia, | |
6462 downloadOptions: _downloadOptions); | |
6463 return _response.then((data) => new InventoryItemsListResponse.fromJson(data
)); | |
6464 } | |
6465 | |
6466 } | |
6467 | |
6468 | |
6469 class LandingPagesResourceApi { | |
6470 final commons.ApiRequester _requester; | |
6471 | |
6472 LandingPagesResourceApi(commons.ApiRequester client) : | |
6473 _requester = client; | |
6474 | |
6475 /** | |
6476 * Deletes an existing campaign landing page. | |
6477 * | |
6478 * Request parameters: | |
6479 * | |
6480 * [profileId] - User profile ID associated with this request. | |
6481 * | |
6482 * [campaignId] - Landing page campaign ID. | |
6483 * | |
6484 * [id] - Landing page ID. | |
6485 * | |
6486 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
6487 * error. | |
6488 * | |
6489 * If the used [http.Client] completes with an error when making a REST call, | |
6490 * this method will complete with the same error. | |
6491 */ | |
6492 async.Future delete(core.String profileId, core.String campaignId, core.String
id) { | |
6493 var _url = null; | |
6494 var _queryParams = new core.Map(); | |
6495 var _uploadMedia = null; | |
6496 var _uploadOptions = null; | |
6497 var _downloadOptions = commons.DownloadOptions.Metadata; | |
6498 var _body = null; | |
6499 | |
6500 if (profileId == null) { | |
6501 throw new core.ArgumentError("Parameter profileId is required."); | |
6502 } | |
6503 if (campaignId == null) { | |
6504 throw new core.ArgumentError("Parameter campaignId is required."); | |
6505 } | |
6506 if (id == null) { | |
6507 throw new core.ArgumentError("Parameter id is required."); | |
6508 } | |
6509 | |
6510 _downloadOptions = null; | |
6511 | |
6512 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/cam
paigns/' + commons.Escaper.ecapeVariable('$campaignId') + '/landingPages/' + com
mons.Escaper.ecapeVariable('$id'); | |
6513 | |
6514 var _response = _requester.request(_url, | |
6515 "DELETE", | |
6516 body: _body, | |
6517 queryParams: _queryParams, | |
6518 uploadOptions: _uploadOptions, | |
6519 uploadMedia: _uploadMedia, | |
6520 downloadOptions: _downloadOptions); | |
6521 return _response.then((data) => null); | |
6522 } | |
6523 | |
6524 /** | |
6525 * Gets one campaign landing page by ID. | |
6526 * | |
6527 * Request parameters: | |
6528 * | |
6529 * [profileId] - User profile ID associated with this request. | |
6530 * | |
6531 * [campaignId] - Landing page campaign ID. | |
6532 * | |
6533 * [id] - Landing page ID. | |
6534 * | |
6535 * Completes with a [LandingPage]. | |
6536 * | |
6537 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
6538 * error. | |
6539 * | |
6540 * If the used [http.Client] completes with an error when making a REST call, | |
6541 * this method will complete with the same error. | |
6542 */ | |
6543 async.Future<LandingPage> get(core.String profileId, core.String campaignId, c
ore.String id) { | |
6544 var _url = null; | |
6545 var _queryParams = new core.Map(); | |
6546 var _uploadMedia = null; | |
6547 var _uploadOptions = null; | |
6548 var _downloadOptions = commons.DownloadOptions.Metadata; | |
6549 var _body = null; | |
6550 | |
6551 if (profileId == null) { | |
6552 throw new core.ArgumentError("Parameter profileId is required."); | |
6553 } | |
6554 if (campaignId == null) { | |
6555 throw new core.ArgumentError("Parameter campaignId is required."); | |
6556 } | |
6557 if (id == null) { | |
6558 throw new core.ArgumentError("Parameter id is required."); | |
6559 } | |
6560 | |
6561 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/cam
paigns/' + commons.Escaper.ecapeVariable('$campaignId') + '/landingPages/' + com
mons.Escaper.ecapeVariable('$id'); | |
6562 | |
6563 var _response = _requester.request(_url, | |
6564 "GET", | |
6565 body: _body, | |
6566 queryParams: _queryParams, | |
6567 uploadOptions: _uploadOptions, | |
6568 uploadMedia: _uploadMedia, | |
6569 downloadOptions: _downloadOptions); | |
6570 return _response.then((data) => new LandingPage.fromJson(data)); | |
6571 } | |
6572 | |
6573 /** | |
6574 * Inserts a new landing page for the specified campaign. | |
6575 * | |
6576 * [request] - The metadata request object. | |
6577 * | |
6578 * Request parameters: | |
6579 * | |
6580 * [profileId] - User profile ID associated with this request. | |
6581 * | |
6582 * [campaignId] - Landing page campaign ID. | |
6583 * | |
6584 * Completes with a [LandingPage]. | |
6585 * | |
6586 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
6587 * error. | |
6588 * | |
6589 * If the used [http.Client] completes with an error when making a REST call, | |
6590 * this method will complete with the same error. | |
6591 */ | |
6592 async.Future<LandingPage> insert(LandingPage request, core.String profileId, c
ore.String campaignId) { | |
6593 var _url = null; | |
6594 var _queryParams = new core.Map(); | |
6595 var _uploadMedia = null; | |
6596 var _uploadOptions = null; | |
6597 var _downloadOptions = commons.DownloadOptions.Metadata; | |
6598 var _body = null; | |
6599 | |
6600 if (request != null) { | |
6601 _body = convert.JSON.encode((request).toJson()); | |
6602 } | |
6603 if (profileId == null) { | |
6604 throw new core.ArgumentError("Parameter profileId is required."); | |
6605 } | |
6606 if (campaignId == null) { | |
6607 throw new core.ArgumentError("Parameter campaignId is required."); | |
6608 } | |
6609 | |
6610 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/cam
paigns/' + commons.Escaper.ecapeVariable('$campaignId') + '/landingPages'; | |
6611 | |
6612 var _response = _requester.request(_url, | |
6613 "POST", | |
6614 body: _body, | |
6615 queryParams: _queryParams, | |
6616 uploadOptions: _uploadOptions, | |
6617 uploadMedia: _uploadMedia, | |
6618 downloadOptions: _downloadOptions); | |
6619 return _response.then((data) => new LandingPage.fromJson(data)); | |
6620 } | |
6621 | |
6622 /** | |
6623 * Retrieves the list of landing pages for the specified campaign. | |
6624 * | |
6625 * Request parameters: | |
6626 * | |
6627 * [profileId] - User profile ID associated with this request. | |
6628 * | |
6629 * [campaignId] - Landing page campaign ID. | |
6630 * | |
6631 * Completes with a [LandingPagesListResponse]. | |
6632 * | |
6633 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
6634 * error. | |
6635 * | |
6636 * If the used [http.Client] completes with an error when making a REST call, | |
6637 * this method will complete with the same error. | |
6638 */ | |
6639 async.Future<LandingPagesListResponse> list(core.String profileId, core.String
campaignId) { | |
6640 var _url = null; | |
6641 var _queryParams = new core.Map(); | |
6642 var _uploadMedia = null; | |
6643 var _uploadOptions = null; | |
6644 var _downloadOptions = commons.DownloadOptions.Metadata; | |
6645 var _body = null; | |
6646 | |
6647 if (profileId == null) { | |
6648 throw new core.ArgumentError("Parameter profileId is required."); | |
6649 } | |
6650 if (campaignId == null) { | |
6651 throw new core.ArgumentError("Parameter campaignId is required."); | |
6652 } | |
6653 | |
6654 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/cam
paigns/' + commons.Escaper.ecapeVariable('$campaignId') + '/landingPages'; | |
6655 | |
6656 var _response = _requester.request(_url, | |
6657 "GET", | |
6658 body: _body, | |
6659 queryParams: _queryParams, | |
6660 uploadOptions: _uploadOptions, | |
6661 uploadMedia: _uploadMedia, | |
6662 downloadOptions: _downloadOptions); | |
6663 return _response.then((data) => new LandingPagesListResponse.fromJson(data))
; | |
6664 } | |
6665 | |
6666 /** | |
6667 * Updates an existing campaign landing page. This method supports patch | |
6668 * semantics. | |
6669 * | |
6670 * [request] - The metadata request object. | |
6671 * | |
6672 * Request parameters: | |
6673 * | |
6674 * [profileId] - User profile ID associated with this request. | |
6675 * | |
6676 * [campaignId] - Landing page campaign ID. | |
6677 * | |
6678 * [id] - Landing page ID. | |
6679 * | |
6680 * Completes with a [LandingPage]. | |
6681 * | |
6682 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
6683 * error. | |
6684 * | |
6685 * If the used [http.Client] completes with an error when making a REST call, | |
6686 * this method will complete with the same error. | |
6687 */ | |
6688 async.Future<LandingPage> patch(LandingPage request, core.String profileId, co
re.String campaignId, core.String id) { | |
6689 var _url = null; | |
6690 var _queryParams = new core.Map(); | |
6691 var _uploadMedia = null; | |
6692 var _uploadOptions = null; | |
6693 var _downloadOptions = commons.DownloadOptions.Metadata; | |
6694 var _body = null; | |
6695 | |
6696 if (request != null) { | |
6697 _body = convert.JSON.encode((request).toJson()); | |
6698 } | |
6699 if (profileId == null) { | |
6700 throw new core.ArgumentError("Parameter profileId is required."); | |
6701 } | |
6702 if (campaignId == null) { | |
6703 throw new core.ArgumentError("Parameter campaignId is required."); | |
6704 } | |
6705 if (id == null) { | |
6706 throw new core.ArgumentError("Parameter id is required."); | |
6707 } | |
6708 _queryParams["id"] = [id]; | |
6709 | |
6710 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/cam
paigns/' + commons.Escaper.ecapeVariable('$campaignId') + '/landingPages'; | |
6711 | |
6712 var _response = _requester.request(_url, | |
6713 "PATCH", | |
6714 body: _body, | |
6715 queryParams: _queryParams, | |
6716 uploadOptions: _uploadOptions, | |
6717 uploadMedia: _uploadMedia, | |
6718 downloadOptions: _downloadOptions); | |
6719 return _response.then((data) => new LandingPage.fromJson(data)); | |
6720 } | |
6721 | |
6722 /** | |
6723 * Updates an existing campaign landing page. | |
6724 * | |
6725 * [request] - The metadata request object. | |
6726 * | |
6727 * Request parameters: | |
6728 * | |
6729 * [profileId] - User profile ID associated with this request. | |
6730 * | |
6731 * [campaignId] - Landing page campaign ID. | |
6732 * | |
6733 * Completes with a [LandingPage]. | |
6734 * | |
6735 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
6736 * error. | |
6737 * | |
6738 * If the used [http.Client] completes with an error when making a REST call, | |
6739 * this method will complete with the same error. | |
6740 */ | |
6741 async.Future<LandingPage> update(LandingPage request, core.String profileId, c
ore.String campaignId) { | |
6742 var _url = null; | |
6743 var _queryParams = new core.Map(); | |
6744 var _uploadMedia = null; | |
6745 var _uploadOptions = null; | |
6746 var _downloadOptions = commons.DownloadOptions.Metadata; | |
6747 var _body = null; | |
6748 | |
6749 if (request != null) { | |
6750 _body = convert.JSON.encode((request).toJson()); | |
6751 } | |
6752 if (profileId == null) { | |
6753 throw new core.ArgumentError("Parameter profileId is required."); | |
6754 } | |
6755 if (campaignId == null) { | |
6756 throw new core.ArgumentError("Parameter campaignId is required."); | |
6757 } | |
6758 | |
6759 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/cam
paigns/' + commons.Escaper.ecapeVariable('$campaignId') + '/landingPages'; | |
6760 | |
6761 var _response = _requester.request(_url, | |
6762 "PUT", | |
6763 body: _body, | |
6764 queryParams: _queryParams, | |
6765 uploadOptions: _uploadOptions, | |
6766 uploadMedia: _uploadMedia, | |
6767 downloadOptions: _downloadOptions); | |
6768 return _response.then((data) => new LandingPage.fromJson(data)); | |
6769 } | |
6770 | |
6771 } | |
6772 | |
6773 | |
6774 class MetrosResourceApi { | |
6775 final commons.ApiRequester _requester; | |
6776 | |
6777 MetrosResourceApi(commons.ApiRequester client) : | |
6778 _requester = client; | |
6779 | |
6780 /** | |
6781 * Retrieves a list of metros. | |
6782 * | |
6783 * Request parameters: | |
6784 * | |
6785 * [profileId] - User profile ID associated with this request. | |
6786 * | |
6787 * Completes with a [MetrosListResponse]. | |
6788 * | |
6789 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
6790 * error. | |
6791 * | |
6792 * If the used [http.Client] completes with an error when making a REST call, | |
6793 * this method will complete with the same error. | |
6794 */ | |
6795 async.Future<MetrosListResponse> list(core.String profileId) { | |
6796 var _url = null; | |
6797 var _queryParams = new core.Map(); | |
6798 var _uploadMedia = null; | |
6799 var _uploadOptions = null; | |
6800 var _downloadOptions = commons.DownloadOptions.Metadata; | |
6801 var _body = null; | |
6802 | |
6803 if (profileId == null) { | |
6804 throw new core.ArgumentError("Parameter profileId is required."); | |
6805 } | |
6806 | |
6807 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/met
ros'; | |
6808 | |
6809 var _response = _requester.request(_url, | |
6810 "GET", | |
6811 body: _body, | |
6812 queryParams: _queryParams, | |
6813 uploadOptions: _uploadOptions, | |
6814 uploadMedia: _uploadMedia, | |
6815 downloadOptions: _downloadOptions); | |
6816 return _response.then((data) => new MetrosListResponse.fromJson(data)); | |
6817 } | |
6818 | |
6819 } | |
6820 | |
6821 | |
6822 class MobileCarriersResourceApi { | |
6823 final commons.ApiRequester _requester; | |
6824 | |
6825 MobileCarriersResourceApi(commons.ApiRequester client) : | |
6826 _requester = client; | |
6827 | |
6828 /** | |
6829 * Gets one mobile carrier by ID. | |
6830 * | |
6831 * Request parameters: | |
6832 * | |
6833 * [profileId] - User profile ID associated with this request. | |
6834 * | |
6835 * [id] - Mobile carrier ID. | |
6836 * | |
6837 * Completes with a [MobileCarrier]. | |
6838 * | |
6839 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
6840 * error. | |
6841 * | |
6842 * If the used [http.Client] completes with an error when making a REST call, | |
6843 * this method will complete with the same error. | |
6844 */ | |
6845 async.Future<MobileCarrier> get(core.String profileId, core.String id) { | |
6846 var _url = null; | |
6847 var _queryParams = new core.Map(); | |
6848 var _uploadMedia = null; | |
6849 var _uploadOptions = null; | |
6850 var _downloadOptions = commons.DownloadOptions.Metadata; | |
6851 var _body = null; | |
6852 | |
6853 if (profileId == null) { | |
6854 throw new core.ArgumentError("Parameter profileId is required."); | |
6855 } | |
6856 if (id == null) { | |
6857 throw new core.ArgumentError("Parameter id is required."); | |
6858 } | |
6859 | |
6860 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/mob
ileCarriers/' + commons.Escaper.ecapeVariable('$id'); | |
6861 | |
6862 var _response = _requester.request(_url, | |
6863 "GET", | |
6864 body: _body, | |
6865 queryParams: _queryParams, | |
6866 uploadOptions: _uploadOptions, | |
6867 uploadMedia: _uploadMedia, | |
6868 downloadOptions: _downloadOptions); | |
6869 return _response.then((data) => new MobileCarrier.fromJson(data)); | |
6870 } | |
6871 | |
6872 /** | |
6873 * Retrieves a list of mobile carriers. | |
6874 * | |
6875 * Request parameters: | |
6876 * | |
6877 * [profileId] - User profile ID associated with this request. | |
6878 * | |
6879 * Completes with a [MobileCarriersListResponse]. | |
6880 * | |
6881 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
6882 * error. | |
6883 * | |
6884 * If the used [http.Client] completes with an error when making a REST call, | |
6885 * this method will complete with the same error. | |
6886 */ | |
6887 async.Future<MobileCarriersListResponse> list(core.String profileId) { | |
6888 var _url = null; | |
6889 var _queryParams = new core.Map(); | |
6890 var _uploadMedia = null; | |
6891 var _uploadOptions = null; | |
6892 var _downloadOptions = commons.DownloadOptions.Metadata; | |
6893 var _body = null; | |
6894 | |
6895 if (profileId == null) { | |
6896 throw new core.ArgumentError("Parameter profileId is required."); | |
6897 } | |
6898 | |
6899 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/mob
ileCarriers'; | |
6900 | |
6901 var _response = _requester.request(_url, | |
6902 "GET", | |
6903 body: _body, | |
6904 queryParams: _queryParams, | |
6905 uploadOptions: _uploadOptions, | |
6906 uploadMedia: _uploadMedia, | |
6907 downloadOptions: _downloadOptions); | |
6908 return _response.then((data) => new MobileCarriersListResponse.fromJson(data
)); | |
6909 } | |
6910 | |
6911 } | |
6912 | |
6913 | |
6914 class OperatingSystemVersionsResourceApi { | |
6915 final commons.ApiRequester _requester; | |
6916 | |
6917 OperatingSystemVersionsResourceApi(commons.ApiRequester client) : | |
6918 _requester = client; | |
6919 | |
6920 /** | |
6921 * Gets one operating system version by ID. | |
6922 * | |
6923 * Request parameters: | |
6924 * | |
6925 * [profileId] - User profile ID associated with this request. | |
6926 * | |
6927 * [id] - Operating system version ID. | |
6928 * | |
6929 * Completes with a [OperatingSystemVersion]. | |
6930 * | |
6931 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
6932 * error. | |
6933 * | |
6934 * If the used [http.Client] completes with an error when making a REST call, | |
6935 * this method will complete with the same error. | |
6936 */ | |
6937 async.Future<OperatingSystemVersion> get(core.String profileId, core.String id
) { | |
6938 var _url = null; | |
6939 var _queryParams = new core.Map(); | |
6940 var _uploadMedia = null; | |
6941 var _uploadOptions = null; | |
6942 var _downloadOptions = commons.DownloadOptions.Metadata; | |
6943 var _body = null; | |
6944 | |
6945 if (profileId == null) { | |
6946 throw new core.ArgumentError("Parameter profileId is required."); | |
6947 } | |
6948 if (id == null) { | |
6949 throw new core.ArgumentError("Parameter id is required."); | |
6950 } | |
6951 | |
6952 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/ope
ratingSystemVersions/' + commons.Escaper.ecapeVariable('$id'); | |
6953 | |
6954 var _response = _requester.request(_url, | |
6955 "GET", | |
6956 body: _body, | |
6957 queryParams: _queryParams, | |
6958 uploadOptions: _uploadOptions, | |
6959 uploadMedia: _uploadMedia, | |
6960 downloadOptions: _downloadOptions); | |
6961 return _response.then((data) => new OperatingSystemVersion.fromJson(data)); | |
6962 } | |
6963 | |
6964 /** | |
6965 * Retrieves a list of operating system versions. | |
6966 * | |
6967 * Request parameters: | |
6968 * | |
6969 * [profileId] - User profile ID associated with this request. | |
6970 * | |
6971 * Completes with a [OperatingSystemVersionsListResponse]. | |
6972 * | |
6973 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
6974 * error. | |
6975 * | |
6976 * If the used [http.Client] completes with an error when making a REST call, | |
6977 * this method will complete with the same error. | |
6978 */ | |
6979 async.Future<OperatingSystemVersionsListResponse> list(core.String profileId)
{ | |
6980 var _url = null; | |
6981 var _queryParams = new core.Map(); | |
6982 var _uploadMedia = null; | |
6983 var _uploadOptions = null; | |
6984 var _downloadOptions = commons.DownloadOptions.Metadata; | |
6985 var _body = null; | |
6986 | |
6987 if (profileId == null) { | |
6988 throw new core.ArgumentError("Parameter profileId is required."); | |
6989 } | |
6990 | |
6991 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/ope
ratingSystemVersions'; | |
6992 | |
6993 var _response = _requester.request(_url, | |
6994 "GET", | |
6995 body: _body, | |
6996 queryParams: _queryParams, | |
6997 uploadOptions: _uploadOptions, | |
6998 uploadMedia: _uploadMedia, | |
6999 downloadOptions: _downloadOptions); | |
7000 return _response.then((data) => new OperatingSystemVersionsListResponse.from
Json(data)); | |
7001 } | |
7002 | |
7003 } | |
7004 | |
7005 | |
7006 class OperatingSystemsResourceApi { | |
7007 final commons.ApiRequester _requester; | |
7008 | |
7009 OperatingSystemsResourceApi(commons.ApiRequester client) : | |
7010 _requester = client; | |
7011 | |
7012 /** | |
7013 * Gets one operating system by DART ID. | |
7014 * | |
7015 * Request parameters: | |
7016 * | |
7017 * [profileId] - User profile ID associated with this request. | |
7018 * | |
7019 * [dartId] - Operating system DART ID. | |
7020 * | |
7021 * Completes with a [OperatingSystem]. | |
7022 * | |
7023 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
7024 * error. | |
7025 * | |
7026 * If the used [http.Client] completes with an error when making a REST call, | |
7027 * this method will complete with the same error. | |
7028 */ | |
7029 async.Future<OperatingSystem> get(core.String profileId, core.String dartId) { | |
7030 var _url = null; | |
7031 var _queryParams = new core.Map(); | |
7032 var _uploadMedia = null; | |
7033 var _uploadOptions = null; | |
7034 var _downloadOptions = commons.DownloadOptions.Metadata; | |
7035 var _body = null; | |
7036 | |
7037 if (profileId == null) { | |
7038 throw new core.ArgumentError("Parameter profileId is required."); | |
7039 } | |
7040 if (dartId == null) { | |
7041 throw new core.ArgumentError("Parameter dartId is required."); | |
7042 } | |
7043 | |
7044 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/ope
ratingSystems/' + commons.Escaper.ecapeVariable('$dartId'); | |
7045 | |
7046 var _response = _requester.request(_url, | |
7047 "GET", | |
7048 body: _body, | |
7049 queryParams: _queryParams, | |
7050 uploadOptions: _uploadOptions, | |
7051 uploadMedia: _uploadMedia, | |
7052 downloadOptions: _downloadOptions); | |
7053 return _response.then((data) => new OperatingSystem.fromJson(data)); | |
7054 } | |
7055 | |
7056 /** | |
7057 * Retrieves a list of operating systems. | |
7058 * | |
7059 * Request parameters: | |
7060 * | |
7061 * [profileId] - User profile ID associated with this request. | |
7062 * | |
7063 * Completes with a [OperatingSystemsListResponse]. | |
7064 * | |
7065 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
7066 * error. | |
7067 * | |
7068 * If the used [http.Client] completes with an error when making a REST call, | |
7069 * this method will complete with the same error. | |
7070 */ | |
7071 async.Future<OperatingSystemsListResponse> list(core.String profileId) { | |
7072 var _url = null; | |
7073 var _queryParams = new core.Map(); | |
7074 var _uploadMedia = null; | |
7075 var _uploadOptions = null; | |
7076 var _downloadOptions = commons.DownloadOptions.Metadata; | |
7077 var _body = null; | |
7078 | |
7079 if (profileId == null) { | |
7080 throw new core.ArgumentError("Parameter profileId is required."); | |
7081 } | |
7082 | |
7083 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/ope
ratingSystems'; | |
7084 | |
7085 var _response = _requester.request(_url, | |
7086 "GET", | |
7087 body: _body, | |
7088 queryParams: _queryParams, | |
7089 uploadOptions: _uploadOptions, | |
7090 uploadMedia: _uploadMedia, | |
7091 downloadOptions: _downloadOptions); | |
7092 return _response.then((data) => new OperatingSystemsListResponse.fromJson(da
ta)); | |
7093 } | |
7094 | |
7095 } | |
7096 | |
7097 | |
7098 class OrderDocumentsResourceApi { | |
7099 final commons.ApiRequester _requester; | |
7100 | |
7101 OrderDocumentsResourceApi(commons.ApiRequester client) : | |
7102 _requester = client; | |
7103 | |
7104 /** | |
7105 * Gets one order document by ID. | |
7106 * | |
7107 * Request parameters: | |
7108 * | |
7109 * [profileId] - User profile ID associated with this request. | |
7110 * | |
7111 * [projectId] - Project ID for order documents. | |
7112 * | |
7113 * [id] - Order document ID. | |
7114 * | |
7115 * Completes with a [OrderDocument]. | |
7116 * | |
7117 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
7118 * error. | |
7119 * | |
7120 * If the used [http.Client] completes with an error when making a REST call, | |
7121 * this method will complete with the same error. | |
7122 */ | |
7123 async.Future<OrderDocument> get(core.String profileId, core.String projectId,
core.String id) { | |
7124 var _url = null; | |
7125 var _queryParams = new core.Map(); | |
7126 var _uploadMedia = null; | |
7127 var _uploadOptions = null; | |
7128 var _downloadOptions = commons.DownloadOptions.Metadata; | |
7129 var _body = null; | |
7130 | |
7131 if (profileId == null) { | |
7132 throw new core.ArgumentError("Parameter profileId is required."); | |
7133 } | |
7134 if (projectId == null) { | |
7135 throw new core.ArgumentError("Parameter projectId is required."); | |
7136 } | |
7137 if (id == null) { | |
7138 throw new core.ArgumentError("Parameter id is required."); | |
7139 } | |
7140 | |
7141 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/pro
jects/' + commons.Escaper.ecapeVariable('$projectId') + '/orderDocuments/' + com
mons.Escaper.ecapeVariable('$id'); | |
7142 | |
7143 var _response = _requester.request(_url, | |
7144 "GET", | |
7145 body: _body, | |
7146 queryParams: _queryParams, | |
7147 uploadOptions: _uploadOptions, | |
7148 uploadMedia: _uploadMedia, | |
7149 downloadOptions: _downloadOptions); | |
7150 return _response.then((data) => new OrderDocument.fromJson(data)); | |
7151 } | |
7152 | |
7153 /** | |
7154 * Retrieves a list of order documents, possibly filtered. | |
7155 * | |
7156 * Request parameters: | |
7157 * | |
7158 * [profileId] - User profile ID associated with this request. | |
7159 * | |
7160 * [projectId] - Project ID for order documents. | |
7161 * | |
7162 * [approved] - Select only order documents that have been approved by at | |
7163 * least one user. | |
7164 * | |
7165 * [ids] - Select only order documents with these IDs. | |
7166 * | |
7167 * [maxResults] - Maximum number of results to return. | |
7168 * | |
7169 * [orderId] - Select only order documents for specified orders. | |
7170 * | |
7171 * [pageToken] - Value of the nextPageToken from the previous result page. | |
7172 * | |
7173 * [searchString] - Allows searching for order documents by name or ID. | |
7174 * Wildcards (*) are allowed. For example, "orderdocument*2015" will return | |
7175 * order documents with names like "orderdocument June 2015", "orderdocument | |
7176 * April 2015", or simply "orderdocument 2015". Most of the searches also add | |
7177 * wildcards implicitly at the start and the end of the search string. For | |
7178 * example, a search string of "orderdocument" will match order documents with | |
7179 * name "my orderdocument", "orderdocument 2015", or simply "orderdocument". | |
7180 * | |
7181 * [siteId] - Select only order documents that are associated with these | |
7182 * sites. | |
7183 * | |
7184 * [sortField] - Field by which to sort the list. | |
7185 * Possible string values are: | |
7186 * - "ID" | |
7187 * - "NAME" | |
7188 * | |
7189 * [sortOrder] - Order of sorted results, default is ASCENDING. | |
7190 * Possible string values are: | |
7191 * - "ASCENDING" | |
7192 * - "DESCENDING" | |
7193 * | |
7194 * Completes with a [OrderDocumentsListResponse]. | |
7195 * | |
7196 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
7197 * error. | |
7198 * | |
7199 * If the used [http.Client] completes with an error when making a REST call, | |
7200 * this method will complete with the same error. | |
7201 */ | |
7202 async.Future<OrderDocumentsListResponse> list(core.String profileId, core.Stri
ng projectId, {core.bool approved, core.List<core.String> ids, core.int maxResul
ts, core.List<core.String> orderId, core.String pageToken, core.String searchStr
ing, core.List<core.String> siteId, core.String sortField, core.String sortOrder
}) { | |
7203 var _url = null; | |
7204 var _queryParams = new core.Map(); | |
7205 var _uploadMedia = null; | |
7206 var _uploadOptions = null; | |
7207 var _downloadOptions = commons.DownloadOptions.Metadata; | |
7208 var _body = null; | |
7209 | |
7210 if (profileId == null) { | |
7211 throw new core.ArgumentError("Parameter profileId is required."); | |
7212 } | |
7213 if (projectId == null) { | |
7214 throw new core.ArgumentError("Parameter projectId is required."); | |
7215 } | |
7216 if (approved != null) { | |
7217 _queryParams["approved"] = ["${approved}"]; | |
7218 } | |
7219 if (ids != null) { | |
7220 _queryParams["ids"] = ids; | |
7221 } | |
7222 if (maxResults != null) { | |
7223 _queryParams["maxResults"] = ["${maxResults}"]; | |
7224 } | |
7225 if (orderId != null) { | |
7226 _queryParams["orderId"] = orderId; | |
7227 } | |
7228 if (pageToken != null) { | |
7229 _queryParams["pageToken"] = [pageToken]; | |
7230 } | |
7231 if (searchString != null) { | |
7232 _queryParams["searchString"] = [searchString]; | |
7233 } | |
7234 if (siteId != null) { | |
7235 _queryParams["siteId"] = siteId; | |
7236 } | |
7237 if (sortField != null) { | |
7238 _queryParams["sortField"] = [sortField]; | |
7239 } | |
7240 if (sortOrder != null) { | |
7241 _queryParams["sortOrder"] = [sortOrder]; | |
7242 } | |
7243 | |
7244 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/pro
jects/' + commons.Escaper.ecapeVariable('$projectId') + '/orderDocuments'; | |
7245 | |
7246 var _response = _requester.request(_url, | |
7247 "GET", | |
7248 body: _body, | |
7249 queryParams: _queryParams, | |
7250 uploadOptions: _uploadOptions, | |
7251 uploadMedia: _uploadMedia, | |
7252 downloadOptions: _downloadOptions); | |
7253 return _response.then((data) => new OrderDocumentsListResponse.fromJson(data
)); | |
7254 } | |
7255 | |
7256 } | |
7257 | |
7258 | |
7259 class OrdersResourceApi { | |
7260 final commons.ApiRequester _requester; | |
7261 | |
7262 OrdersResourceApi(commons.ApiRequester client) : | |
7263 _requester = client; | |
7264 | |
7265 /** | |
7266 * Gets one order by ID. | |
7267 * | |
7268 * Request parameters: | |
7269 * | |
7270 * [profileId] - User profile ID associated with this request. | |
7271 * | |
7272 * [projectId] - Project ID for orders. | |
7273 * | |
7274 * [id] - Order ID. | |
7275 * | |
7276 * Completes with a [Order]. | |
7277 * | |
7278 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
7279 * error. | |
7280 * | |
7281 * If the used [http.Client] completes with an error when making a REST call, | |
7282 * this method will complete with the same error. | |
7283 */ | |
7284 async.Future<Order> get(core.String profileId, core.String projectId, core.Str
ing id) { | |
7285 var _url = null; | |
7286 var _queryParams = new core.Map(); | |
7287 var _uploadMedia = null; | |
7288 var _uploadOptions = null; | |
7289 var _downloadOptions = commons.DownloadOptions.Metadata; | |
7290 var _body = null; | |
7291 | |
7292 if (profileId == null) { | |
7293 throw new core.ArgumentError("Parameter profileId is required."); | |
7294 } | |
7295 if (projectId == null) { | |
7296 throw new core.ArgumentError("Parameter projectId is required."); | |
7297 } | |
7298 if (id == null) { | |
7299 throw new core.ArgumentError("Parameter id is required."); | |
7300 } | |
7301 | |
7302 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/pro
jects/' + commons.Escaper.ecapeVariable('$projectId') + '/orders/' + commons.Esc
aper.ecapeVariable('$id'); | |
7303 | |
7304 var _response = _requester.request(_url, | |
7305 "GET", | |
7306 body: _body, | |
7307 queryParams: _queryParams, | |
7308 uploadOptions: _uploadOptions, | |
7309 uploadMedia: _uploadMedia, | |
7310 downloadOptions: _downloadOptions); | |
7311 return _response.then((data) => new Order.fromJson(data)); | |
7312 } | |
7313 | |
7314 /** | |
7315 * Retrieves a list of orders, possibly filtered. | |
7316 * | |
7317 * Request parameters: | |
7318 * | |
7319 * [profileId] - User profile ID associated with this request. | |
7320 * | |
7321 * [projectId] - Project ID for orders. | |
7322 * | |
7323 * [ids] - Select only orders with these IDs. | |
7324 * | |
7325 * [maxResults] - Maximum number of results to return. | |
7326 * | |
7327 * [pageToken] - Value of the nextPageToken from the previous result page. | |
7328 * | |
7329 * [searchString] - Allows searching for orders by name or ID. Wildcards (*) | |
7330 * are allowed. For example, "order*2015" will return orders with names like | |
7331 * "order June 2015", "order April 2015", or simply "order 2015". Most of the | |
7332 * searches also add wildcards implicitly at the start and the end of the | |
7333 * search string. For example, a search string of "order" will match orders | |
7334 * with name "my order", "order 2015", or simply "order". | |
7335 * | |
7336 * [siteId] - Select only orders that are associated with these site IDs. | |
7337 * | |
7338 * [sortField] - Field by which to sort the list. | |
7339 * Possible string values are: | |
7340 * - "ID" | |
7341 * - "NAME" | |
7342 * | |
7343 * [sortOrder] - Order of sorted results, default is ASCENDING. | |
7344 * Possible string values are: | |
7345 * - "ASCENDING" | |
7346 * - "DESCENDING" | |
7347 * | |
7348 * Completes with a [OrdersListResponse]. | |
7349 * | |
7350 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
7351 * error. | |
7352 * | |
7353 * If the used [http.Client] completes with an error when making a REST call, | |
7354 * this method will complete with the same error. | |
7355 */ | |
7356 async.Future<OrdersListResponse> list(core.String profileId, core.String proje
ctId, {core.List<core.String> ids, core.int maxResults, core.String pageToken, c
ore.String searchString, core.List<core.String> siteId, core.String sortField, c
ore.String sortOrder}) { | |
7357 var _url = null; | |
7358 var _queryParams = new core.Map(); | |
7359 var _uploadMedia = null; | |
7360 var _uploadOptions = null; | |
7361 var _downloadOptions = commons.DownloadOptions.Metadata; | |
7362 var _body = null; | |
7363 | |
7364 if (profileId == null) { | |
7365 throw new core.ArgumentError("Parameter profileId is required."); | |
7366 } | |
7367 if (projectId == null) { | |
7368 throw new core.ArgumentError("Parameter projectId is required."); | |
7369 } | |
7370 if (ids != null) { | |
7371 _queryParams["ids"] = ids; | |
7372 } | |
7373 if (maxResults != null) { | |
7374 _queryParams["maxResults"] = ["${maxResults}"]; | |
7375 } | |
7376 if (pageToken != null) { | |
7377 _queryParams["pageToken"] = [pageToken]; | |
7378 } | |
7379 if (searchString != null) { | |
7380 _queryParams["searchString"] = [searchString]; | |
7381 } | |
7382 if (siteId != null) { | |
7383 _queryParams["siteId"] = siteId; | |
7384 } | |
7385 if (sortField != null) { | |
7386 _queryParams["sortField"] = [sortField]; | |
7387 } | |
7388 if (sortOrder != null) { | |
7389 _queryParams["sortOrder"] = [sortOrder]; | |
7390 } | |
7391 | |
7392 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/pro
jects/' + commons.Escaper.ecapeVariable('$projectId') + '/orders'; | |
7393 | |
7394 var _response = _requester.request(_url, | |
7395 "GET", | |
7396 body: _body, | |
7397 queryParams: _queryParams, | |
7398 uploadOptions: _uploadOptions, | |
7399 uploadMedia: _uploadMedia, | |
7400 downloadOptions: _downloadOptions); | |
7401 return _response.then((data) => new OrdersListResponse.fromJson(data)); | |
7402 } | |
7403 | |
7404 } | |
7405 | |
7406 | |
7407 class PlacementGroupsResourceApi { | |
7408 final commons.ApiRequester _requester; | |
7409 | |
7410 PlacementGroupsResourceApi(commons.ApiRequester client) : | |
7411 _requester = client; | |
7412 | |
7413 /** | |
7414 * Gets one placement group by ID. | |
7415 * | |
7416 * Request parameters: | |
7417 * | |
7418 * [profileId] - User profile ID associated with this request. | |
7419 * | |
7420 * [id] - Placement group ID. | |
7421 * | |
7422 * Completes with a [PlacementGroup]. | |
7423 * | |
7424 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
7425 * error. | |
7426 * | |
7427 * If the used [http.Client] completes with an error when making a REST call, | |
7428 * this method will complete with the same error. | |
7429 */ | |
7430 async.Future<PlacementGroup> get(core.String profileId, core.String id) { | |
7431 var _url = null; | |
7432 var _queryParams = new core.Map(); | |
7433 var _uploadMedia = null; | |
7434 var _uploadOptions = null; | |
7435 var _downloadOptions = commons.DownloadOptions.Metadata; | |
7436 var _body = null; | |
7437 | |
7438 if (profileId == null) { | |
7439 throw new core.ArgumentError("Parameter profileId is required."); | |
7440 } | |
7441 if (id == null) { | |
7442 throw new core.ArgumentError("Parameter id is required."); | |
7443 } | |
7444 | |
7445 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/pla
cementGroups/' + commons.Escaper.ecapeVariable('$id'); | |
7446 | |
7447 var _response = _requester.request(_url, | |
7448 "GET", | |
7449 body: _body, | |
7450 queryParams: _queryParams, | |
7451 uploadOptions: _uploadOptions, | |
7452 uploadMedia: _uploadMedia, | |
7453 downloadOptions: _downloadOptions); | |
7454 return _response.then((data) => new PlacementGroup.fromJson(data)); | |
7455 } | |
7456 | |
7457 /** | |
7458 * Inserts a new placement group. | |
7459 * | |
7460 * [request] - The metadata request object. | |
7461 * | |
7462 * Request parameters: | |
7463 * | |
7464 * [profileId] - User profile ID associated with this request. | |
7465 * | |
7466 * Completes with a [PlacementGroup]. | |
7467 * | |
7468 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
7469 * error. | |
7470 * | |
7471 * If the used [http.Client] completes with an error when making a REST call, | |
7472 * this method will complete with the same error. | |
7473 */ | |
7474 async.Future<PlacementGroup> insert(PlacementGroup request, core.String profil
eId) { | |
7475 var _url = null; | |
7476 var _queryParams = new core.Map(); | |
7477 var _uploadMedia = null; | |
7478 var _uploadOptions = null; | |
7479 var _downloadOptions = commons.DownloadOptions.Metadata; | |
7480 var _body = null; | |
7481 | |
7482 if (request != null) { | |
7483 _body = convert.JSON.encode((request).toJson()); | |
7484 } | |
7485 if (profileId == null) { | |
7486 throw new core.ArgumentError("Parameter profileId is required."); | |
7487 } | |
7488 | |
7489 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/pla
cementGroups'; | |
7490 | |
7491 var _response = _requester.request(_url, | |
7492 "POST", | |
7493 body: _body, | |
7494 queryParams: _queryParams, | |
7495 uploadOptions: _uploadOptions, | |
7496 uploadMedia: _uploadMedia, | |
7497 downloadOptions: _downloadOptions); | |
7498 return _response.then((data) => new PlacementGroup.fromJson(data)); | |
7499 } | |
7500 | |
7501 /** | |
7502 * Retrieves a list of placement groups, possibly filtered. | |
7503 * | |
7504 * Request parameters: | |
7505 * | |
7506 * [profileId] - User profile ID associated with this request. | |
7507 * | |
7508 * [advertiserIds] - Select only placement groups that belong to these | |
7509 * advertisers. | |
7510 * | |
7511 * [archived] - Select only archived placements. Don't set this field to | |
7512 * select both archived and non-archived placements. | |
7513 * | |
7514 * [campaignIds] - Select only placement groups that belong to these | |
7515 * campaigns. | |
7516 * | |
7517 * [contentCategoryIds] - Select only placement groups that are associated | |
7518 * with these content categories. | |
7519 * | |
7520 * [directorySiteIds] - Select only placement groups that are associated with | |
7521 * these directory sites. | |
7522 * | |
7523 * [ids] - Select only placement groups with these IDs. | |
7524 * | |
7525 * [maxEndDate] - Select only placements or placement groups whose end date is | |
7526 * on or before the specified maxEndDate. The date should be formatted as | |
7527 * "yyyy-MM-dd". | |
7528 * | |
7529 * [maxResults] - Maximum number of results to return. | |
7530 * | |
7531 * [maxStartDate] - Select only placements or placement groups whose start | |
7532 * date is on or before the specified maxStartDate. The date should be | |
7533 * formatted as "yyyy-MM-dd". | |
7534 * | |
7535 * [minEndDate] - Select only placements or placement groups whose end date is | |
7536 * on or after the specified minEndDate. The date should be formatted as | |
7537 * "yyyy-MM-dd". | |
7538 * | |
7539 * [minStartDate] - Select only placements or placement groups whose start | |
7540 * date is on or after the specified minStartDate. The date should be | |
7541 * formatted as "yyyy-MM-dd". | |
7542 * | |
7543 * [pageToken] - Value of the nextPageToken from the previous result page. | |
7544 * | |
7545 * [placementGroupType] - Select only placement groups belonging with this | |
7546 * group type. A package is a simple group of placements that acts as a single | |
7547 * pricing point for a group of tags. A roadblock is a group of placements | |
7548 * that not only acts as a single pricing point but also assumes that all the | |
7549 * tags in it will be served at the same time. A roadblock requires one of its | |
7550 * assigned placements to be marked as primary for reporting. | |
7551 * Possible string values are: | |
7552 * - "PLACEMENT_PACKAGE" | |
7553 * - "PLACEMENT_ROADBLOCK" | |
7554 * | |
7555 * [placementStrategyIds] - Select only placement groups that are associated | |
7556 * with these placement strategies. | |
7557 * | |
7558 * [pricingTypes] - Select only placement groups with these pricing types. | |
7559 * | |
7560 * [searchString] - Allows searching for placement groups by name or ID. | |
7561 * Wildcards (*) are allowed. For example, "placement*2015" will return | |
7562 * placement groups with names like "placement group June 2015", "placement | |
7563 * group May 2015", or simply "placements 2015". Most of the searches also add | |
7564 * wildcards implicitly at the start and the end of the search string. For | |
7565 * example, a search string of "placementgroup" will match placement groups | |
7566 * with name "my placementgroup", "placementgroup 2015", or simply | |
7567 * "placementgroup". | |
7568 * | |
7569 * [siteIds] - Select only placement groups that are associated with these | |
7570 * sites. | |
7571 * | |
7572 * [sortField] - Field by which to sort the list. | |
7573 * Possible string values are: | |
7574 * - "ID" | |
7575 * - "NAME" | |
7576 * | |
7577 * [sortOrder] - Order of sorted results, default is ASCENDING. | |
7578 * Possible string values are: | |
7579 * - "ASCENDING" | |
7580 * - "DESCENDING" | |
7581 * | |
7582 * Completes with a [PlacementGroupsListResponse]. | |
7583 * | |
7584 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
7585 * error. | |
7586 * | |
7587 * If the used [http.Client] completes with an error when making a REST call, | |
7588 * this method will complete with the same error. | |
7589 */ | |
7590 async.Future<PlacementGroupsListResponse> list(core.String profileId, {core.Li
st<core.String> advertiserIds, core.bool archived, core.List<core.String> campai
gnIds, core.List<core.String> contentCategoryIds, core.List<core.String> directo
rySiteIds, core.List<core.String> ids, core.String maxEndDate, core.int maxResul
ts, core.String maxStartDate, core.String minEndDate, core.String minStartDate,
core.String pageToken, core.String placementGroupType, core.List<core.String> pl
acementStrategyIds, core.List<core.String> pricingTypes, core.String searchStrin
g, core.List<core.String> siteIds, core.String sortField, core.String sortOrder}
) { | |
7591 var _url = null; | |
7592 var _queryParams = new core.Map(); | |
7593 var _uploadMedia = null; | |
7594 var _uploadOptions = null; | |
7595 var _downloadOptions = commons.DownloadOptions.Metadata; | |
7596 var _body = null; | |
7597 | |
7598 if (profileId == null) { | |
7599 throw new core.ArgumentError("Parameter profileId is required."); | |
7600 } | |
7601 if (advertiserIds != null) { | |
7602 _queryParams["advertiserIds"] = advertiserIds; | |
7603 } | |
7604 if (archived != null) { | |
7605 _queryParams["archived"] = ["${archived}"]; | |
7606 } | |
7607 if (campaignIds != null) { | |
7608 _queryParams["campaignIds"] = campaignIds; | |
7609 } | |
7610 if (contentCategoryIds != null) { | |
7611 _queryParams["contentCategoryIds"] = contentCategoryIds; | |
7612 } | |
7613 if (directorySiteIds != null) { | |
7614 _queryParams["directorySiteIds"] = directorySiteIds; | |
7615 } | |
7616 if (ids != null) { | |
7617 _queryParams["ids"] = ids; | |
7618 } | |
7619 if (maxEndDate != null) { | |
7620 _queryParams["maxEndDate"] = [maxEndDate]; | |
7621 } | |
7622 if (maxResults != null) { | |
7623 _queryParams["maxResults"] = ["${maxResults}"]; | |
7624 } | |
7625 if (maxStartDate != null) { | |
7626 _queryParams["maxStartDate"] = [maxStartDate]; | |
7627 } | |
7628 if (minEndDate != null) { | |
7629 _queryParams["minEndDate"] = [minEndDate]; | |
7630 } | |
7631 if (minStartDate != null) { | |
7632 _queryParams["minStartDate"] = [minStartDate]; | |
7633 } | |
7634 if (pageToken != null) { | |
7635 _queryParams["pageToken"] = [pageToken]; | |
7636 } | |
7637 if (placementGroupType != null) { | |
7638 _queryParams["placementGroupType"] = [placementGroupType]; | |
7639 } | |
7640 if (placementStrategyIds != null) { | |
7641 _queryParams["placementStrategyIds"] = placementStrategyIds; | |
7642 } | |
7643 if (pricingTypes != null) { | |
7644 _queryParams["pricingTypes"] = pricingTypes; | |
7645 } | |
7646 if (searchString != null) { | |
7647 _queryParams["searchString"] = [searchString]; | |
7648 } | |
7649 if (siteIds != null) { | |
7650 _queryParams["siteIds"] = siteIds; | |
7651 } | |
7652 if (sortField != null) { | |
7653 _queryParams["sortField"] = [sortField]; | |
7654 } | |
7655 if (sortOrder != null) { | |
7656 _queryParams["sortOrder"] = [sortOrder]; | |
7657 } | |
7658 | |
7659 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/pla
cementGroups'; | |
7660 | |
7661 var _response = _requester.request(_url, | |
7662 "GET", | |
7663 body: _body, | |
7664 queryParams: _queryParams, | |
7665 uploadOptions: _uploadOptions, | |
7666 uploadMedia: _uploadMedia, | |
7667 downloadOptions: _downloadOptions); | |
7668 return _response.then((data) => new PlacementGroupsListResponse.fromJson(dat
a)); | |
7669 } | |
7670 | |
7671 /** | |
7672 * Updates an existing placement group. This method supports patch semantics. | |
7673 * | |
7674 * [request] - The metadata request object. | |
7675 * | |
7676 * Request parameters: | |
7677 * | |
7678 * [profileId] - User profile ID associated with this request. | |
7679 * | |
7680 * [id] - Placement group ID. | |
7681 * | |
7682 * Completes with a [PlacementGroup]. | |
7683 * | |
7684 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
7685 * error. | |
7686 * | |
7687 * If the used [http.Client] completes with an error when making a REST call, | |
7688 * this method will complete with the same error. | |
7689 */ | |
7690 async.Future<PlacementGroup> patch(PlacementGroup request, core.String profile
Id, core.String id) { | |
7691 var _url = null; | |
7692 var _queryParams = new core.Map(); | |
7693 var _uploadMedia = null; | |
7694 var _uploadOptions = null; | |
7695 var _downloadOptions = commons.DownloadOptions.Metadata; | |
7696 var _body = null; | |
7697 | |
7698 if (request != null) { | |
7699 _body = convert.JSON.encode((request).toJson()); | |
7700 } | |
7701 if (profileId == null) { | |
7702 throw new core.ArgumentError("Parameter profileId is required."); | |
7703 } | |
7704 if (id == null) { | |
7705 throw new core.ArgumentError("Parameter id is required."); | |
7706 } | |
7707 _queryParams["id"] = [id]; | |
7708 | |
7709 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/pla
cementGroups'; | |
7710 | |
7711 var _response = _requester.request(_url, | |
7712 "PATCH", | |
7713 body: _body, | |
7714 queryParams: _queryParams, | |
7715 uploadOptions: _uploadOptions, | |
7716 uploadMedia: _uploadMedia, | |
7717 downloadOptions: _downloadOptions); | |
7718 return _response.then((data) => new PlacementGroup.fromJson(data)); | |
7719 } | |
7720 | |
7721 /** | |
7722 * Updates an existing placement group. | |
7723 * | |
7724 * [request] - The metadata request object. | |
7725 * | |
7726 * Request parameters: | |
7727 * | |
7728 * [profileId] - User profile ID associated with this request. | |
7729 * | |
7730 * Completes with a [PlacementGroup]. | |
7731 * | |
7732 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
7733 * error. | |
7734 * | |
7735 * If the used [http.Client] completes with an error when making a REST call, | |
7736 * this method will complete with the same error. | |
7737 */ | |
7738 async.Future<PlacementGroup> update(PlacementGroup request, core.String profil
eId) { | |
7739 var _url = null; | |
7740 var _queryParams = new core.Map(); | |
7741 var _uploadMedia = null; | |
7742 var _uploadOptions = null; | |
7743 var _downloadOptions = commons.DownloadOptions.Metadata; | |
7744 var _body = null; | |
7745 | |
7746 if (request != null) { | |
7747 _body = convert.JSON.encode((request).toJson()); | |
7748 } | |
7749 if (profileId == null) { | |
7750 throw new core.ArgumentError("Parameter profileId is required."); | |
7751 } | |
7752 | |
7753 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/pla
cementGroups'; | |
7754 | |
7755 var _response = _requester.request(_url, | |
7756 "PUT", | |
7757 body: _body, | |
7758 queryParams: _queryParams, | |
7759 uploadOptions: _uploadOptions, | |
7760 uploadMedia: _uploadMedia, | |
7761 downloadOptions: _downloadOptions); | |
7762 return _response.then((data) => new PlacementGroup.fromJson(data)); | |
7763 } | |
7764 | |
7765 } | |
7766 | |
7767 | |
7768 class PlacementStrategiesResourceApi { | |
7769 final commons.ApiRequester _requester; | |
7770 | |
7771 PlacementStrategiesResourceApi(commons.ApiRequester client) : | |
7772 _requester = client; | |
7773 | |
7774 /** | |
7775 * Deletes an existing placement strategy. | |
7776 * | |
7777 * Request parameters: | |
7778 * | |
7779 * [profileId] - User profile ID associated with this request. | |
7780 * | |
7781 * [id] - Placement strategy ID. | |
7782 * | |
7783 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
7784 * error. | |
7785 * | |
7786 * If the used [http.Client] completes with an error when making a REST call, | |
7787 * this method will complete with the same error. | |
7788 */ | |
7789 async.Future delete(core.String profileId, core.String id) { | |
7790 var _url = null; | |
7791 var _queryParams = new core.Map(); | |
7792 var _uploadMedia = null; | |
7793 var _uploadOptions = null; | |
7794 var _downloadOptions = commons.DownloadOptions.Metadata; | |
7795 var _body = null; | |
7796 | |
7797 if (profileId == null) { | |
7798 throw new core.ArgumentError("Parameter profileId is required."); | |
7799 } | |
7800 if (id == null) { | |
7801 throw new core.ArgumentError("Parameter id is required."); | |
7802 } | |
7803 | |
7804 _downloadOptions = null; | |
7805 | |
7806 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/pla
cementStrategies/' + commons.Escaper.ecapeVariable('$id'); | |
7807 | |
7808 var _response = _requester.request(_url, | |
7809 "DELETE", | |
7810 body: _body, | |
7811 queryParams: _queryParams, | |
7812 uploadOptions: _uploadOptions, | |
7813 uploadMedia: _uploadMedia, | |
7814 downloadOptions: _downloadOptions); | |
7815 return _response.then((data) => null); | |
7816 } | |
7817 | |
7818 /** | |
7819 * Gets one placement strategy by ID. | |
7820 * | |
7821 * Request parameters: | |
7822 * | |
7823 * [profileId] - User profile ID associated with this request. | |
7824 * | |
7825 * [id] - Placement strategy ID. | |
7826 * | |
7827 * Completes with a [PlacementStrategy]. | |
7828 * | |
7829 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
7830 * error. | |
7831 * | |
7832 * If the used [http.Client] completes with an error when making a REST call, | |
7833 * this method will complete with the same error. | |
7834 */ | |
7835 async.Future<PlacementStrategy> get(core.String profileId, core.String id) { | |
7836 var _url = null; | |
7837 var _queryParams = new core.Map(); | |
7838 var _uploadMedia = null; | |
7839 var _uploadOptions = null; | |
7840 var _downloadOptions = commons.DownloadOptions.Metadata; | |
7841 var _body = null; | |
7842 | |
7843 if (profileId == null) { | |
7844 throw new core.ArgumentError("Parameter profileId is required."); | |
7845 } | |
7846 if (id == null) { | |
7847 throw new core.ArgumentError("Parameter id is required."); | |
7848 } | |
7849 | |
7850 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/pla
cementStrategies/' + commons.Escaper.ecapeVariable('$id'); | |
7851 | |
7852 var _response = _requester.request(_url, | |
7853 "GET", | |
7854 body: _body, | |
7855 queryParams: _queryParams, | |
7856 uploadOptions: _uploadOptions, | |
7857 uploadMedia: _uploadMedia, | |
7858 downloadOptions: _downloadOptions); | |
7859 return _response.then((data) => new PlacementStrategy.fromJson(data)); | |
7860 } | |
7861 | |
7862 /** | |
7863 * Inserts a new placement strategy. | |
7864 * | |
7865 * [request] - The metadata request object. | |
7866 * | |
7867 * Request parameters: | |
7868 * | |
7869 * [profileId] - User profile ID associated with this request. | |
7870 * | |
7871 * Completes with a [PlacementStrategy]. | |
7872 * | |
7873 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
7874 * error. | |
7875 * | |
7876 * If the used [http.Client] completes with an error when making a REST call, | |
7877 * this method will complete with the same error. | |
7878 */ | |
7879 async.Future<PlacementStrategy> insert(PlacementStrategy request, core.String
profileId) { | |
7880 var _url = null; | |
7881 var _queryParams = new core.Map(); | |
7882 var _uploadMedia = null; | |
7883 var _uploadOptions = null; | |
7884 var _downloadOptions = commons.DownloadOptions.Metadata; | |
7885 var _body = null; | |
7886 | |
7887 if (request != null) { | |
7888 _body = convert.JSON.encode((request).toJson()); | |
7889 } | |
7890 if (profileId == null) { | |
7891 throw new core.ArgumentError("Parameter profileId is required."); | |
7892 } | |
7893 | |
7894 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/pla
cementStrategies'; | |
7895 | |
7896 var _response = _requester.request(_url, | |
7897 "POST", | |
7898 body: _body, | |
7899 queryParams: _queryParams, | |
7900 uploadOptions: _uploadOptions, | |
7901 uploadMedia: _uploadMedia, | |
7902 downloadOptions: _downloadOptions); | |
7903 return _response.then((data) => new PlacementStrategy.fromJson(data)); | |
7904 } | |
7905 | |
7906 /** | |
7907 * Retrieves a list of placement strategies, possibly filtered. | |
7908 * | |
7909 * Request parameters: | |
7910 * | |
7911 * [profileId] - User profile ID associated with this request. | |
7912 * | |
7913 * [ids] - Select only placement strategies with these IDs. | |
7914 * | |
7915 * [maxResults] - Maximum number of results to return. | |
7916 * | |
7917 * [pageToken] - Value of the nextPageToken from the previous result page. | |
7918 * | |
7919 * [searchString] - Allows searching for objects by name or ID. Wildcards (*) | |
7920 * are allowed. For example, "placementstrategy*2015" will return objects with | |
7921 * names like "placementstrategy June 2015", "placementstrategy April 2015", | |
7922 * or simply "placementstrategy 2015". Most of the searches also add wildcards | |
7923 * implicitly at the start and the end of the search string. For example, a | |
7924 * search string of "placementstrategy" will match objects with name "my | |
7925 * placementstrategy", "placementstrategy 2015", or simply | |
7926 * "placementstrategy". | |
7927 * | |
7928 * [sortField] - Field by which to sort the list. | |
7929 * Possible string values are: | |
7930 * - "ID" | |
7931 * - "NAME" | |
7932 * | |
7933 * [sortOrder] - Order of sorted results, default is ASCENDING. | |
7934 * Possible string values are: | |
7935 * - "ASCENDING" | |
7936 * - "DESCENDING" | |
7937 * | |
7938 * Completes with a [PlacementStrategiesListResponse]. | |
7939 * | |
7940 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
7941 * error. | |
7942 * | |
7943 * If the used [http.Client] completes with an error when making a REST call, | |
7944 * this method will complete with the same error. | |
7945 */ | |
7946 async.Future<PlacementStrategiesListResponse> list(core.String profileId, {cor
e.List<core.String> ids, core.int maxResults, core.String pageToken, core.String
searchString, core.String sortField, core.String sortOrder}) { | |
7947 var _url = null; | |
7948 var _queryParams = new core.Map(); | |
7949 var _uploadMedia = null; | |
7950 var _uploadOptions = null; | |
7951 var _downloadOptions = commons.DownloadOptions.Metadata; | |
7952 var _body = null; | |
7953 | |
7954 if (profileId == null) { | |
7955 throw new core.ArgumentError("Parameter profileId is required."); | |
7956 } | |
7957 if (ids != null) { | |
7958 _queryParams["ids"] = ids; | |
7959 } | |
7960 if (maxResults != null) { | |
7961 _queryParams["maxResults"] = ["${maxResults}"]; | |
7962 } | |
7963 if (pageToken != null) { | |
7964 _queryParams["pageToken"] = [pageToken]; | |
7965 } | |
7966 if (searchString != null) { | |
7967 _queryParams["searchString"] = [searchString]; | |
7968 } | |
7969 if (sortField != null) { | |
7970 _queryParams["sortField"] = [sortField]; | |
7971 } | |
7972 if (sortOrder != null) { | |
7973 _queryParams["sortOrder"] = [sortOrder]; | |
7974 } | |
7975 | |
7976 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/pla
cementStrategies'; | |
7977 | |
7978 var _response = _requester.request(_url, | |
7979 "GET", | |
7980 body: _body, | |
7981 queryParams: _queryParams, | |
7982 uploadOptions: _uploadOptions, | |
7983 uploadMedia: _uploadMedia, | |
7984 downloadOptions: _downloadOptions); | |
7985 return _response.then((data) => new PlacementStrategiesListResponse.fromJson
(data)); | |
7986 } | |
7987 | |
7988 /** | |
7989 * Updates an existing placement strategy. This method supports patch | |
7990 * semantics. | |
7991 * | |
7992 * [request] - The metadata request object. | |
7993 * | |
7994 * Request parameters: | |
7995 * | |
7996 * [profileId] - User profile ID associated with this request. | |
7997 * | |
7998 * [id] - Placement strategy ID. | |
7999 * | |
8000 * Completes with a [PlacementStrategy]. | |
8001 * | |
8002 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
8003 * error. | |
8004 * | |
8005 * If the used [http.Client] completes with an error when making a REST call, | |
8006 * this method will complete with the same error. | |
8007 */ | |
8008 async.Future<PlacementStrategy> patch(PlacementStrategy request, core.String p
rofileId, core.String id) { | |
8009 var _url = null; | |
8010 var _queryParams = new core.Map(); | |
8011 var _uploadMedia = null; | |
8012 var _uploadOptions = null; | |
8013 var _downloadOptions = commons.DownloadOptions.Metadata; | |
8014 var _body = null; | |
8015 | |
8016 if (request != null) { | |
8017 _body = convert.JSON.encode((request).toJson()); | |
8018 } | |
8019 if (profileId == null) { | |
8020 throw new core.ArgumentError("Parameter profileId is required."); | |
8021 } | |
8022 if (id == null) { | |
8023 throw new core.ArgumentError("Parameter id is required."); | |
8024 } | |
8025 _queryParams["id"] = [id]; | |
8026 | |
8027 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/pla
cementStrategies'; | |
8028 | |
8029 var _response = _requester.request(_url, | |
8030 "PATCH", | |
8031 body: _body, | |
8032 queryParams: _queryParams, | |
8033 uploadOptions: _uploadOptions, | |
8034 uploadMedia: _uploadMedia, | |
8035 downloadOptions: _downloadOptions); | |
8036 return _response.then((data) => new PlacementStrategy.fromJson(data)); | |
8037 } | |
8038 | |
8039 /** | |
8040 * Updates an existing placement strategy. | |
8041 * | |
8042 * [request] - The metadata request object. | |
8043 * | |
8044 * Request parameters: | |
8045 * | |
8046 * [profileId] - User profile ID associated with this request. | |
8047 * | |
8048 * Completes with a [PlacementStrategy]. | |
8049 * | |
8050 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
8051 * error. | |
8052 * | |
8053 * If the used [http.Client] completes with an error when making a REST call, | |
8054 * this method will complete with the same error. | |
8055 */ | |
8056 async.Future<PlacementStrategy> update(PlacementStrategy request, core.String
profileId) { | |
8057 var _url = null; | |
8058 var _queryParams = new core.Map(); | |
8059 var _uploadMedia = null; | |
8060 var _uploadOptions = null; | |
8061 var _downloadOptions = commons.DownloadOptions.Metadata; | |
8062 var _body = null; | |
8063 | |
8064 if (request != null) { | |
8065 _body = convert.JSON.encode((request).toJson()); | |
8066 } | |
8067 if (profileId == null) { | |
8068 throw new core.ArgumentError("Parameter profileId is required."); | |
8069 } | |
8070 | |
8071 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/pla
cementStrategies'; | |
8072 | |
8073 var _response = _requester.request(_url, | |
8074 "PUT", | |
8075 body: _body, | |
8076 queryParams: _queryParams, | |
8077 uploadOptions: _uploadOptions, | |
8078 uploadMedia: _uploadMedia, | |
8079 downloadOptions: _downloadOptions); | |
8080 return _response.then((data) => new PlacementStrategy.fromJson(data)); | |
8081 } | |
8082 | |
8083 } | |
8084 | |
8085 | |
8086 class PlacementsResourceApi { | |
8087 final commons.ApiRequester _requester; | |
8088 | |
8089 PlacementsResourceApi(commons.ApiRequester client) : | |
8090 _requester = client; | |
8091 | |
8092 /** | |
8093 * Generates tags for a placement. | |
8094 * | |
8095 * Request parameters: | |
8096 * | |
8097 * [profileId] - User profile ID associated with this request. | |
8098 * | |
8099 * [campaignId] - Generate placements belonging to this campaign. This is a | |
8100 * required field. | |
8101 * | |
8102 * [placementIds] - Generate tags for these placements. | |
8103 * | |
8104 * [tagFormats] - Tag formats to generate for these placements. | |
8105 * | |
8106 * Completes with a [PlacementsGenerateTagsResponse]. | |
8107 * | |
8108 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
8109 * error. | |
8110 * | |
8111 * If the used [http.Client] completes with an error when making a REST call, | |
8112 * this method will complete with the same error. | |
8113 */ | |
8114 async.Future<PlacementsGenerateTagsResponse> generatetags(core.String profileI
d, {core.String campaignId, core.List<core.String> placementIds, core.List<core.
String> tagFormats}) { | |
8115 var _url = null; | |
8116 var _queryParams = new core.Map(); | |
8117 var _uploadMedia = null; | |
8118 var _uploadOptions = null; | |
8119 var _downloadOptions = commons.DownloadOptions.Metadata; | |
8120 var _body = null; | |
8121 | |
8122 if (profileId == null) { | |
8123 throw new core.ArgumentError("Parameter profileId is required."); | |
8124 } | |
8125 if (campaignId != null) { | |
8126 _queryParams["campaignId"] = [campaignId]; | |
8127 } | |
8128 if (placementIds != null) { | |
8129 _queryParams["placementIds"] = placementIds; | |
8130 } | |
8131 if (tagFormats != null) { | |
8132 _queryParams["tagFormats"] = tagFormats; | |
8133 } | |
8134 | |
8135 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/pla
cements/generatetags'; | |
8136 | |
8137 var _response = _requester.request(_url, | |
8138 "POST", | |
8139 body: _body, | |
8140 queryParams: _queryParams, | |
8141 uploadOptions: _uploadOptions, | |
8142 uploadMedia: _uploadMedia, | |
8143 downloadOptions: _downloadOptions); | |
8144 return _response.then((data) => new PlacementsGenerateTagsResponse.fromJson(
data)); | |
8145 } | |
8146 | |
8147 /** | |
8148 * Gets one placement by ID. | |
8149 * | |
8150 * Request parameters: | |
8151 * | |
8152 * [profileId] - User profile ID associated with this request. | |
8153 * | |
8154 * [id] - Placement ID. | |
8155 * | |
8156 * Completes with a [Placement]. | |
8157 * | |
8158 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
8159 * error. | |
8160 * | |
8161 * If the used [http.Client] completes with an error when making a REST call, | |
8162 * this method will complete with the same error. | |
8163 */ | |
8164 async.Future<Placement> get(core.String profileId, core.String id) { | |
8165 var _url = null; | |
8166 var _queryParams = new core.Map(); | |
8167 var _uploadMedia = null; | |
8168 var _uploadOptions = null; | |
8169 var _downloadOptions = commons.DownloadOptions.Metadata; | |
8170 var _body = null; | |
8171 | |
8172 if (profileId == null) { | |
8173 throw new core.ArgumentError("Parameter profileId is required."); | |
8174 } | |
8175 if (id == null) { | |
8176 throw new core.ArgumentError("Parameter id is required."); | |
8177 } | |
8178 | |
8179 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/pla
cements/' + commons.Escaper.ecapeVariable('$id'); | |
8180 | |
8181 var _response = _requester.request(_url, | |
8182 "GET", | |
8183 body: _body, | |
8184 queryParams: _queryParams, | |
8185 uploadOptions: _uploadOptions, | |
8186 uploadMedia: _uploadMedia, | |
8187 downloadOptions: _downloadOptions); | |
8188 return _response.then((data) => new Placement.fromJson(data)); | |
8189 } | |
8190 | |
8191 /** | |
8192 * Inserts a new placement. | |
8193 * | |
8194 * [request] - The metadata request object. | |
8195 * | |
8196 * Request parameters: | |
8197 * | |
8198 * [profileId] - User profile ID associated with this request. | |
8199 * | |
8200 * Completes with a [Placement]. | |
8201 * | |
8202 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
8203 * error. | |
8204 * | |
8205 * If the used [http.Client] completes with an error when making a REST call, | |
8206 * this method will complete with the same error. | |
8207 */ | |
8208 async.Future<Placement> insert(Placement request, core.String profileId) { | |
8209 var _url = null; | |
8210 var _queryParams = new core.Map(); | |
8211 var _uploadMedia = null; | |
8212 var _uploadOptions = null; | |
8213 var _downloadOptions = commons.DownloadOptions.Metadata; | |
8214 var _body = null; | |
8215 | |
8216 if (request != null) { | |
8217 _body = convert.JSON.encode((request).toJson()); | |
8218 } | |
8219 if (profileId == null) { | |
8220 throw new core.ArgumentError("Parameter profileId is required."); | |
8221 } | |
8222 | |
8223 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/pla
cements'; | |
8224 | |
8225 var _response = _requester.request(_url, | |
8226 "POST", | |
8227 body: _body, | |
8228 queryParams: _queryParams, | |
8229 uploadOptions: _uploadOptions, | |
8230 uploadMedia: _uploadMedia, | |
8231 downloadOptions: _downloadOptions); | |
8232 return _response.then((data) => new Placement.fromJson(data)); | |
8233 } | |
8234 | |
8235 /** | |
8236 * Retrieves a list of placements, possibly filtered. | |
8237 * | |
8238 * Request parameters: | |
8239 * | |
8240 * [profileId] - User profile ID associated with this request. | |
8241 * | |
8242 * [advertiserIds] - Select only placements that belong to these advertisers. | |
8243 * | |
8244 * [archived] - Select only archived placements. Don't set this field to | |
8245 * select both archived and non-archived placements. | |
8246 * | |
8247 * [campaignIds] - Select only placements that belong to these campaigns. | |
8248 * | |
8249 * [compatibilities] - Select only placements that are associated with these | |
8250 * compatibilities. WEB and WEB_INTERSTITIAL refer to rendering either on | |
8251 * desktop or on mobile devices for regular or interstitial ads respectively. | |
8252 * APP and APP_INTERSTITIAL are for rendering in mobile apps. IN_STREAM_VIDEO | |
8253 * refers to rendering in in-stream video ads developed with the VAST | |
8254 * standard. | |
8255 * | |
8256 * [contentCategoryIds] - Select only placements that are associated with | |
8257 * these content categories. | |
8258 * | |
8259 * [directorySiteIds] - Select only placements that are associated with these | |
8260 * directory sites. | |
8261 * | |
8262 * [groupIds] - Select only placements that belong to these placement groups. | |
8263 * | |
8264 * [ids] - Select only placements with these IDs. | |
8265 * | |
8266 * [maxEndDate] - Select only placements or placement groups whose end date is | |
8267 * on or before the specified maxEndDate. The date should be formatted as | |
8268 * "yyyy-MM-dd". | |
8269 * | |
8270 * [maxResults] - Maximum number of results to return. | |
8271 * | |
8272 * [maxStartDate] - Select only placements or placement groups whose start | |
8273 * date is on or before the specified maxStartDate. The date should be | |
8274 * formatted as "yyyy-MM-dd". | |
8275 * | |
8276 * [minEndDate] - Select only placements or placement groups whose end date is | |
8277 * on or after the specified minEndDate. The date should be formatted as | |
8278 * "yyyy-MM-dd". | |
8279 * | |
8280 * [minStartDate] - Select only placements or placement groups whose start | |
8281 * date is on or after the specified minStartDate. The date should be | |
8282 * formatted as "yyyy-MM-dd". | |
8283 * | |
8284 * [pageToken] - Value of the nextPageToken from the previous result page. | |
8285 * | |
8286 * [paymentSource] - Select only placements with this payment source. | |
8287 * Possible string values are: | |
8288 * - "PLACEMENT_AGENCY_PAID" | |
8289 * - "PLACEMENT_PUBLISHER_PAID" | |
8290 * | |
8291 * [placementStrategyIds] - Select only placements that are associated with | |
8292 * these placement strategies. | |
8293 * | |
8294 * [pricingTypes] - Select only placements with these pricing types. | |
8295 * | |
8296 * [searchString] - Allows searching for placements by name or ID. Wildcards | |
8297 * (*) are allowed. For example, "placement*2015" will return placements with | |
8298 * names like "placement June 2015", "placement May 2015", or simply | |
8299 * "placements 2015". Most of the searches also add wildcards implicitly at | |
8300 * the start and the end of the search string. For example, a search string of | |
8301 * "placement" will match placements with name "my placement", "placement | |
8302 * 2015", or simply "placement". | |
8303 * | |
8304 * [siteIds] - Select only placements that are associated with these sites. | |
8305 * | |
8306 * [sizeIds] - Select only placements that are associated with these sizes. | |
8307 * | |
8308 * [sortField] - Field by which to sort the list. | |
8309 * Possible string values are: | |
8310 * - "ID" | |
8311 * - "NAME" | |
8312 * | |
8313 * [sortOrder] - Order of sorted results, default is ASCENDING. | |
8314 * Possible string values are: | |
8315 * - "ASCENDING" | |
8316 * - "DESCENDING" | |
8317 * | |
8318 * Completes with a [PlacementsListResponse]. | |
8319 * | |
8320 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
8321 * error. | |
8322 * | |
8323 * If the used [http.Client] completes with an error when making a REST call, | |
8324 * this method will complete with the same error. | |
8325 */ | |
8326 async.Future<PlacementsListResponse> list(core.String profileId, {core.List<co
re.String> advertiserIds, core.bool archived, core.List<core.String> campaignIds
, core.List<core.String> compatibilities, core.List<core.String> contentCategory
Ids, core.List<core.String> directorySiteIds, core.List<core.String> groupIds, c
ore.List<core.String> ids, core.String maxEndDate, core.int maxResults, core.Str
ing maxStartDate, core.String minEndDate, core.String minStartDate, core.String
pageToken, core.String paymentSource, core.List<core.String> placementStrategyId
s, core.List<core.String> pricingTypes, core.String searchString, core.List<core
.String> siteIds, core.List<core.String> sizeIds, core.String sortField, core.St
ring sortOrder}) { | |
8327 var _url = null; | |
8328 var _queryParams = new core.Map(); | |
8329 var _uploadMedia = null; | |
8330 var _uploadOptions = null; | |
8331 var _downloadOptions = commons.DownloadOptions.Metadata; | |
8332 var _body = null; | |
8333 | |
8334 if (profileId == null) { | |
8335 throw new core.ArgumentError("Parameter profileId is required."); | |
8336 } | |
8337 if (advertiserIds != null) { | |
8338 _queryParams["advertiserIds"] = advertiserIds; | |
8339 } | |
8340 if (archived != null) { | |
8341 _queryParams["archived"] = ["${archived}"]; | |
8342 } | |
8343 if (campaignIds != null) { | |
8344 _queryParams["campaignIds"] = campaignIds; | |
8345 } | |
8346 if (compatibilities != null) { | |
8347 _queryParams["compatibilities"] = compatibilities; | |
8348 } | |
8349 if (contentCategoryIds != null) { | |
8350 _queryParams["contentCategoryIds"] = contentCategoryIds; | |
8351 } | |
8352 if (directorySiteIds != null) { | |
8353 _queryParams["directorySiteIds"] = directorySiteIds; | |
8354 } | |
8355 if (groupIds != null) { | |
8356 _queryParams["groupIds"] = groupIds; | |
8357 } | |
8358 if (ids != null) { | |
8359 _queryParams["ids"] = ids; | |
8360 } | |
8361 if (maxEndDate != null) { | |
8362 _queryParams["maxEndDate"] = [maxEndDate]; | |
8363 } | |
8364 if (maxResults != null) { | |
8365 _queryParams["maxResults"] = ["${maxResults}"]; | |
8366 } | |
8367 if (maxStartDate != null) { | |
8368 _queryParams["maxStartDate"] = [maxStartDate]; | |
8369 } | |
8370 if (minEndDate != null) { | |
8371 _queryParams["minEndDate"] = [minEndDate]; | |
8372 } | |
8373 if (minStartDate != null) { | |
8374 _queryParams["minStartDate"] = [minStartDate]; | |
8375 } | |
8376 if (pageToken != null) { | |
8377 _queryParams["pageToken"] = [pageToken]; | |
8378 } | |
8379 if (paymentSource != null) { | |
8380 _queryParams["paymentSource"] = [paymentSource]; | |
8381 } | |
8382 if (placementStrategyIds != null) { | |
8383 _queryParams["placementStrategyIds"] = placementStrategyIds; | |
8384 } | |
8385 if (pricingTypes != null) { | |
8386 _queryParams["pricingTypes"] = pricingTypes; | |
8387 } | |
8388 if (searchString != null) { | |
8389 _queryParams["searchString"] = [searchString]; | |
8390 } | |
8391 if (siteIds != null) { | |
8392 _queryParams["siteIds"] = siteIds; | |
8393 } | |
8394 if (sizeIds != null) { | |
8395 _queryParams["sizeIds"] = sizeIds; | |
8396 } | |
8397 if (sortField != null) { | |
8398 _queryParams["sortField"] = [sortField]; | |
8399 } | |
8400 if (sortOrder != null) { | |
8401 _queryParams["sortOrder"] = [sortOrder]; | |
8402 } | |
8403 | |
8404 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/pla
cements'; | |
8405 | |
8406 var _response = _requester.request(_url, | |
8407 "GET", | |
8408 body: _body, | |
8409 queryParams: _queryParams, | |
8410 uploadOptions: _uploadOptions, | |
8411 uploadMedia: _uploadMedia, | |
8412 downloadOptions: _downloadOptions); | |
8413 return _response.then((data) => new PlacementsListResponse.fromJson(data)); | |
8414 } | |
8415 | |
8416 /** | |
8417 * Updates an existing placement. This method supports patch semantics. | |
8418 * | |
8419 * [request] - The metadata request object. | |
8420 * | |
8421 * Request parameters: | |
8422 * | |
8423 * [profileId] - User profile ID associated with this request. | |
8424 * | |
8425 * [id] - Placement ID. | |
8426 * | |
8427 * Completes with a [Placement]. | |
8428 * | |
8429 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
8430 * error. | |
8431 * | |
8432 * If the used [http.Client] completes with an error when making a REST call, | |
8433 * this method will complete with the same error. | |
8434 */ | |
8435 async.Future<Placement> patch(Placement request, core.String profileId, core.S
tring id) { | |
8436 var _url = null; | |
8437 var _queryParams = new core.Map(); | |
8438 var _uploadMedia = null; | |
8439 var _uploadOptions = null; | |
8440 var _downloadOptions = commons.DownloadOptions.Metadata; | |
8441 var _body = null; | |
8442 | |
8443 if (request != null) { | |
8444 _body = convert.JSON.encode((request).toJson()); | |
8445 } | |
8446 if (profileId == null) { | |
8447 throw new core.ArgumentError("Parameter profileId is required."); | |
8448 } | |
8449 if (id == null) { | |
8450 throw new core.ArgumentError("Parameter id is required."); | |
8451 } | |
8452 _queryParams["id"] = [id]; | |
8453 | |
8454 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/pla
cements'; | |
8455 | |
8456 var _response = _requester.request(_url, | |
8457 "PATCH", | |
8458 body: _body, | |
8459 queryParams: _queryParams, | |
8460 uploadOptions: _uploadOptions, | |
8461 uploadMedia: _uploadMedia, | |
8462 downloadOptions: _downloadOptions); | |
8463 return _response.then((data) => new Placement.fromJson(data)); | |
8464 } | |
8465 | |
8466 /** | |
8467 * Updates an existing placement. | |
8468 * | |
8469 * [request] - The metadata request object. | |
8470 * | |
8471 * Request parameters: | |
8472 * | |
8473 * [profileId] - User profile ID associated with this request. | |
8474 * | |
8475 * Completes with a [Placement]. | |
8476 * | |
8477 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
8478 * error. | |
8479 * | |
8480 * If the used [http.Client] completes with an error when making a REST call, | |
8481 * this method will complete with the same error. | |
8482 */ | |
8483 async.Future<Placement> update(Placement request, core.String profileId) { | |
8484 var _url = null; | |
8485 var _queryParams = new core.Map(); | |
8486 var _uploadMedia = null; | |
8487 var _uploadOptions = null; | |
8488 var _downloadOptions = commons.DownloadOptions.Metadata; | |
8489 var _body = null; | |
8490 | |
8491 if (request != null) { | |
8492 _body = convert.JSON.encode((request).toJson()); | |
8493 } | |
8494 if (profileId == null) { | |
8495 throw new core.ArgumentError("Parameter profileId is required."); | |
8496 } | |
8497 | |
8498 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/pla
cements'; | |
8499 | |
8500 var _response = _requester.request(_url, | |
8501 "PUT", | |
8502 body: _body, | |
8503 queryParams: _queryParams, | |
8504 uploadOptions: _uploadOptions, | |
8505 uploadMedia: _uploadMedia, | |
8506 downloadOptions: _downloadOptions); | |
8507 return _response.then((data) => new Placement.fromJson(data)); | |
8508 } | |
8509 | |
8510 } | |
8511 | |
8512 | |
8513 class PlatformTypesResourceApi { | |
8514 final commons.ApiRequester _requester; | |
8515 | |
8516 PlatformTypesResourceApi(commons.ApiRequester client) : | |
8517 _requester = client; | |
8518 | |
8519 /** | |
8520 * Gets one platform type by ID. | |
8521 * | |
8522 * Request parameters: | |
8523 * | |
8524 * [profileId] - User profile ID associated with this request. | |
8525 * | |
8526 * [id] - Platform type ID. | |
8527 * | |
8528 * Completes with a [PlatformType]. | |
8529 * | |
8530 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
8531 * error. | |
8532 * | |
8533 * If the used [http.Client] completes with an error when making a REST call, | |
8534 * this method will complete with the same error. | |
8535 */ | |
8536 async.Future<PlatformType> get(core.String profileId, core.String id) { | |
8537 var _url = null; | |
8538 var _queryParams = new core.Map(); | |
8539 var _uploadMedia = null; | |
8540 var _uploadOptions = null; | |
8541 var _downloadOptions = commons.DownloadOptions.Metadata; | |
8542 var _body = null; | |
8543 | |
8544 if (profileId == null) { | |
8545 throw new core.ArgumentError("Parameter profileId is required."); | |
8546 } | |
8547 if (id == null) { | |
8548 throw new core.ArgumentError("Parameter id is required."); | |
8549 } | |
8550 | |
8551 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/pla
tformTypes/' + commons.Escaper.ecapeVariable('$id'); | |
8552 | |
8553 var _response = _requester.request(_url, | |
8554 "GET", | |
8555 body: _body, | |
8556 queryParams: _queryParams, | |
8557 uploadOptions: _uploadOptions, | |
8558 uploadMedia: _uploadMedia, | |
8559 downloadOptions: _downloadOptions); | |
8560 return _response.then((data) => new PlatformType.fromJson(data)); | |
8561 } | |
8562 | |
8563 /** | |
8564 * Retrieves a list of platform types. | |
8565 * | |
8566 * Request parameters: | |
8567 * | |
8568 * [profileId] - User profile ID associated with this request. | |
8569 * | |
8570 * Completes with a [PlatformTypesListResponse]. | |
8571 * | |
8572 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
8573 * error. | |
8574 * | |
8575 * If the used [http.Client] completes with an error when making a REST call, | |
8576 * this method will complete with the same error. | |
8577 */ | |
8578 async.Future<PlatformTypesListResponse> list(core.String profileId) { | |
8579 var _url = null; | |
8580 var _queryParams = new core.Map(); | |
8581 var _uploadMedia = null; | |
8582 var _uploadOptions = null; | |
8583 var _downloadOptions = commons.DownloadOptions.Metadata; | |
8584 var _body = null; | |
8585 | |
8586 if (profileId == null) { | |
8587 throw new core.ArgumentError("Parameter profileId is required."); | |
8588 } | |
8589 | |
8590 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/pla
tformTypes'; | |
8591 | |
8592 var _response = _requester.request(_url, | |
8593 "GET", | |
8594 body: _body, | |
8595 queryParams: _queryParams, | |
8596 uploadOptions: _uploadOptions, | |
8597 uploadMedia: _uploadMedia, | |
8598 downloadOptions: _downloadOptions); | |
8599 return _response.then((data) => new PlatformTypesListResponse.fromJson(data)
); | |
8600 } | |
8601 | |
8602 } | |
8603 | |
8604 | |
8605 class PostalCodesResourceApi { | |
8606 final commons.ApiRequester _requester; | |
8607 | |
8608 PostalCodesResourceApi(commons.ApiRequester client) : | |
8609 _requester = client; | |
8610 | |
8611 /** | |
8612 * Gets one postal code by ID. | |
8613 * | |
8614 * Request parameters: | |
8615 * | |
8616 * [profileId] - User profile ID associated with this request. | |
8617 * | |
8618 * [code] - Postal code ID. | |
8619 * | |
8620 * Completes with a [PostalCode]. | |
8621 * | |
8622 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
8623 * error. | |
8624 * | |
8625 * If the used [http.Client] completes with an error when making a REST call, | |
8626 * this method will complete with the same error. | |
8627 */ | |
8628 async.Future<PostalCode> get(core.String profileId, core.String code) { | |
8629 var _url = null; | |
8630 var _queryParams = new core.Map(); | |
8631 var _uploadMedia = null; | |
8632 var _uploadOptions = null; | |
8633 var _downloadOptions = commons.DownloadOptions.Metadata; | |
8634 var _body = null; | |
8635 | |
8636 if (profileId == null) { | |
8637 throw new core.ArgumentError("Parameter profileId is required."); | |
8638 } | |
8639 if (code == null) { | |
8640 throw new core.ArgumentError("Parameter code is required."); | |
8641 } | |
8642 | |
8643 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/pos
talCodes/' + commons.Escaper.ecapeVariable('$code'); | |
8644 | |
8645 var _response = _requester.request(_url, | |
8646 "GET", | |
8647 body: _body, | |
8648 queryParams: _queryParams, | |
8649 uploadOptions: _uploadOptions, | |
8650 uploadMedia: _uploadMedia, | |
8651 downloadOptions: _downloadOptions); | |
8652 return _response.then((data) => new PostalCode.fromJson(data)); | |
8653 } | |
8654 | |
8655 /** | |
8656 * Retrieves a list of postal codes. | |
8657 * | |
8658 * Request parameters: | |
8659 * | |
8660 * [profileId] - User profile ID associated with this request. | |
8661 * | |
8662 * Completes with a [PostalCodesListResponse]. | |
8663 * | |
8664 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
8665 * error. | |
8666 * | |
8667 * If the used [http.Client] completes with an error when making a REST call, | |
8668 * this method will complete with the same error. | |
8669 */ | |
8670 async.Future<PostalCodesListResponse> list(core.String profileId) { | |
8671 var _url = null; | |
8672 var _queryParams = new core.Map(); | |
8673 var _uploadMedia = null; | |
8674 var _uploadOptions = null; | |
8675 var _downloadOptions = commons.DownloadOptions.Metadata; | |
8676 var _body = null; | |
8677 | |
8678 if (profileId == null) { | |
8679 throw new core.ArgumentError("Parameter profileId is required."); | |
8680 } | |
8681 | |
8682 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/pos
talCodes'; | |
8683 | |
8684 var _response = _requester.request(_url, | |
8685 "GET", | |
8686 body: _body, | |
8687 queryParams: _queryParams, | |
8688 uploadOptions: _uploadOptions, | |
8689 uploadMedia: _uploadMedia, | |
8690 downloadOptions: _downloadOptions); | |
8691 return _response.then((data) => new PostalCodesListResponse.fromJson(data)); | |
8692 } | |
8693 | |
8694 } | |
8695 | |
8696 | |
8697 class ProjectsResourceApi { | |
8698 final commons.ApiRequester _requester; | |
8699 | |
8700 ProjectsResourceApi(commons.ApiRequester client) : | |
8701 _requester = client; | |
8702 | |
8703 /** | |
8704 * Gets one project by ID. | |
8705 * | |
8706 * Request parameters: | |
8707 * | |
8708 * [profileId] - User profile ID associated with this request. | |
8709 * | |
8710 * [id] - Project ID. | |
8711 * | |
8712 * Completes with a [Project]. | |
8713 * | |
8714 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
8715 * error. | |
8716 * | |
8717 * If the used [http.Client] completes with an error when making a REST call, | |
8718 * this method will complete with the same error. | |
8719 */ | |
8720 async.Future<Project> get(core.String profileId, core.String id) { | |
8721 var _url = null; | |
8722 var _queryParams = new core.Map(); | |
8723 var _uploadMedia = null; | |
8724 var _uploadOptions = null; | |
8725 var _downloadOptions = commons.DownloadOptions.Metadata; | |
8726 var _body = null; | |
8727 | |
8728 if (profileId == null) { | |
8729 throw new core.ArgumentError("Parameter profileId is required."); | |
8730 } | |
8731 if (id == null) { | |
8732 throw new core.ArgumentError("Parameter id is required."); | |
8733 } | |
8734 | |
8735 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/pro
jects/' + commons.Escaper.ecapeVariable('$id'); | |
8736 | |
8737 var _response = _requester.request(_url, | |
8738 "GET", | |
8739 body: _body, | |
8740 queryParams: _queryParams, | |
8741 uploadOptions: _uploadOptions, | |
8742 uploadMedia: _uploadMedia, | |
8743 downloadOptions: _downloadOptions); | |
8744 return _response.then((data) => new Project.fromJson(data)); | |
8745 } | |
8746 | |
8747 /** | |
8748 * Retrieves a list of projects, possibly filtered. | |
8749 * | |
8750 * Request parameters: | |
8751 * | |
8752 * [profileId] - User profile ID associated with this request. | |
8753 * | |
8754 * [advertiserIds] - Select only projects with these advertiser IDs. | |
8755 * | |
8756 * [ids] - Select only projects with these IDs. | |
8757 * | |
8758 * [maxResults] - Maximum number of results to return. | |
8759 * | |
8760 * [pageToken] - Value of the nextPageToken from the previous result page. | |
8761 * | |
8762 * [searchString] - Allows searching for projects by name or ID. Wildcards (*) | |
8763 * are allowed. For example, "project*2015" will return projects with names | |
8764 * like "project June 2015", "project April 2015", or simply "project 2015". | |
8765 * Most of the searches also add wildcards implicitly at the start and the end | |
8766 * of the search string. For example, a search string of "project" will match | |
8767 * projects with name "my project", "project 2015", or simply "project". | |
8768 * | |
8769 * [sortField] - Field by which to sort the list. | |
8770 * Possible string values are: | |
8771 * - "ID" | |
8772 * - "NAME" | |
8773 * | |
8774 * [sortOrder] - Order of sorted results, default is ASCENDING. | |
8775 * Possible string values are: | |
8776 * - "ASCENDING" | |
8777 * - "DESCENDING" | |
8778 * | |
8779 * Completes with a [ProjectsListResponse]. | |
8780 * | |
8781 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
8782 * error. | |
8783 * | |
8784 * If the used [http.Client] completes with an error when making a REST call, | |
8785 * this method will complete with the same error. | |
8786 */ | |
8787 async.Future<ProjectsListResponse> list(core.String profileId, {core.List<core
.String> advertiserIds, core.List<core.String> ids, core.int maxResults, core.St
ring pageToken, core.String searchString, core.String sortField, core.String sor
tOrder}) { | |
8788 var _url = null; | |
8789 var _queryParams = new core.Map(); | |
8790 var _uploadMedia = null; | |
8791 var _uploadOptions = null; | |
8792 var _downloadOptions = commons.DownloadOptions.Metadata; | |
8793 var _body = null; | |
8794 | |
8795 if (profileId == null) { | |
8796 throw new core.ArgumentError("Parameter profileId is required."); | |
8797 } | |
8798 if (advertiserIds != null) { | |
8799 _queryParams["advertiserIds"] = advertiserIds; | |
8800 } | |
8801 if (ids != null) { | |
8802 _queryParams["ids"] = ids; | |
8803 } | |
8804 if (maxResults != null) { | |
8805 _queryParams["maxResults"] = ["${maxResults}"]; | |
8806 } | |
8807 if (pageToken != null) { | |
8808 _queryParams["pageToken"] = [pageToken]; | |
8809 } | |
8810 if (searchString != null) { | |
8811 _queryParams["searchString"] = [searchString]; | |
8812 } | |
8813 if (sortField != null) { | |
8814 _queryParams["sortField"] = [sortField]; | |
8815 } | |
8816 if (sortOrder != null) { | |
8817 _queryParams["sortOrder"] = [sortOrder]; | |
8818 } | |
8819 | |
8820 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/pro
jects'; | |
8821 | |
8822 var _response = _requester.request(_url, | |
8823 "GET", | |
8824 body: _body, | |
8825 queryParams: _queryParams, | |
8826 uploadOptions: _uploadOptions, | |
8827 uploadMedia: _uploadMedia, | |
8828 downloadOptions: _downloadOptions); | |
8829 return _response.then((data) => new ProjectsListResponse.fromJson(data)); | |
8830 } | |
8831 | |
8832 } | |
8833 | |
8834 | |
8835 class RegionsResourceApi { | |
8836 final commons.ApiRequester _requester; | |
8837 | |
8838 RegionsResourceApi(commons.ApiRequester client) : | |
8839 _requester = client; | |
8840 | |
8841 /** | |
8842 * Retrieves a list of regions. | |
8843 * | |
8844 * Request parameters: | |
8845 * | |
8846 * [profileId] - User profile ID associated with this request. | |
8847 * | |
8848 * Completes with a [RegionsListResponse]. | |
8849 * | |
8850 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
8851 * error. | |
8852 * | |
8853 * If the used [http.Client] completes with an error when making a REST call, | |
8854 * this method will complete with the same error. | |
8855 */ | |
8856 async.Future<RegionsListResponse> list(core.String profileId) { | |
8857 var _url = null; | |
8858 var _queryParams = new core.Map(); | |
8859 var _uploadMedia = null; | |
8860 var _uploadOptions = null; | |
8861 var _downloadOptions = commons.DownloadOptions.Metadata; | |
8862 var _body = null; | |
8863 | |
8864 if (profileId == null) { | |
8865 throw new core.ArgumentError("Parameter profileId is required."); | |
8866 } | |
8867 | |
8868 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/reg
ions'; | |
8869 | |
8870 var _response = _requester.request(_url, | |
8871 "GET", | |
8872 body: _body, | |
8873 queryParams: _queryParams, | |
8874 uploadOptions: _uploadOptions, | |
8875 uploadMedia: _uploadMedia, | |
8876 downloadOptions: _downloadOptions); | |
8877 return _response.then((data) => new RegionsListResponse.fromJson(data)); | |
8878 } | |
8879 | |
8880 } | |
8881 | |
8882 | |
8883 class RemarketingListSharesResourceApi { | |
8884 final commons.ApiRequester _requester; | |
8885 | |
8886 RemarketingListSharesResourceApi(commons.ApiRequester client) : | |
8887 _requester = client; | |
8888 | |
8889 /** | |
8890 * Gets one remarketing list share by remarketing list ID. | |
8891 * | |
8892 * Request parameters: | |
8893 * | |
8894 * [profileId] - User profile ID associated with this request. | |
8895 * | |
8896 * [remarketingListId] - Remarketing list ID. | |
8897 * | |
8898 * Completes with a [RemarketingListShare]. | |
8899 * | |
8900 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
8901 * error. | |
8902 * | |
8903 * If the used [http.Client] completes with an error when making a REST call, | |
8904 * this method will complete with the same error. | |
8905 */ | |
8906 async.Future<RemarketingListShare> get(core.String profileId, core.String rema
rketingListId) { | |
8907 var _url = null; | |
8908 var _queryParams = new core.Map(); | |
8909 var _uploadMedia = null; | |
8910 var _uploadOptions = null; | |
8911 var _downloadOptions = commons.DownloadOptions.Metadata; | |
8912 var _body = null; | |
8913 | |
8914 if (profileId == null) { | |
8915 throw new core.ArgumentError("Parameter profileId is required."); | |
8916 } | |
8917 if (remarketingListId == null) { | |
8918 throw new core.ArgumentError("Parameter remarketingListId is required."); | |
8919 } | |
8920 | |
8921 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/rem
arketingListShares/' + commons.Escaper.ecapeVariable('$remarketingListId'); | |
8922 | |
8923 var _response = _requester.request(_url, | |
8924 "GET", | |
8925 body: _body, | |
8926 queryParams: _queryParams, | |
8927 uploadOptions: _uploadOptions, | |
8928 uploadMedia: _uploadMedia, | |
8929 downloadOptions: _downloadOptions); | |
8930 return _response.then((data) => new RemarketingListShare.fromJson(data)); | |
8931 } | |
8932 | |
8933 /** | |
8934 * Updates an existing remarketing list share. This method supports patch | |
8935 * semantics. | |
8936 * | |
8937 * [request] - The metadata request object. | |
8938 * | |
8939 * Request parameters: | |
8940 * | |
8941 * [profileId] - User profile ID associated with this request. | |
8942 * | |
8943 * [remarketingListId] - Remarketing list ID. | |
8944 * | |
8945 * Completes with a [RemarketingListShare]. | |
8946 * | |
8947 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
8948 * error. | |
8949 * | |
8950 * If the used [http.Client] completes with an error when making a REST call, | |
8951 * this method will complete with the same error. | |
8952 */ | |
8953 async.Future<RemarketingListShare> patch(RemarketingListShare request, core.St
ring profileId, core.String remarketingListId) { | |
8954 var _url = null; | |
8955 var _queryParams = new core.Map(); | |
8956 var _uploadMedia = null; | |
8957 var _uploadOptions = null; | |
8958 var _downloadOptions = commons.DownloadOptions.Metadata; | |
8959 var _body = null; | |
8960 | |
8961 if (request != null) { | |
8962 _body = convert.JSON.encode((request).toJson()); | |
8963 } | |
8964 if (profileId == null) { | |
8965 throw new core.ArgumentError("Parameter profileId is required."); | |
8966 } | |
8967 if (remarketingListId == null) { | |
8968 throw new core.ArgumentError("Parameter remarketingListId is required."); | |
8969 } | |
8970 _queryParams["remarketingListId"] = [remarketingListId]; | |
8971 | |
8972 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/rem
arketingListShares'; | |
8973 | |
8974 var _response = _requester.request(_url, | |
8975 "PATCH", | |
8976 body: _body, | |
8977 queryParams: _queryParams, | |
8978 uploadOptions: _uploadOptions, | |
8979 uploadMedia: _uploadMedia, | |
8980 downloadOptions: _downloadOptions); | |
8981 return _response.then((data) => new RemarketingListShare.fromJson(data)); | |
8982 } | |
8983 | |
8984 /** | |
8985 * Updates an existing remarketing list share. | |
8986 * | |
8987 * [request] - The metadata request object. | |
8988 * | |
8989 * Request parameters: | |
8990 * | |
8991 * [profileId] - User profile ID associated with this request. | |
8992 * | |
8993 * Completes with a [RemarketingListShare]. | |
8994 * | |
8995 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
8996 * error. | |
8997 * | |
8998 * If the used [http.Client] completes with an error when making a REST call, | |
8999 * this method will complete with the same error. | |
9000 */ | |
9001 async.Future<RemarketingListShare> update(RemarketingListShare request, core.S
tring profileId) { | |
9002 var _url = null; | |
9003 var _queryParams = new core.Map(); | |
9004 var _uploadMedia = null; | |
9005 var _uploadOptions = null; | |
9006 var _downloadOptions = commons.DownloadOptions.Metadata; | |
9007 var _body = null; | |
9008 | |
9009 if (request != null) { | |
9010 _body = convert.JSON.encode((request).toJson()); | |
9011 } | |
9012 if (profileId == null) { | |
9013 throw new core.ArgumentError("Parameter profileId is required."); | |
9014 } | |
9015 | |
9016 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/rem
arketingListShares'; | |
9017 | |
9018 var _response = _requester.request(_url, | |
9019 "PUT", | |
9020 body: _body, | |
9021 queryParams: _queryParams, | |
9022 uploadOptions: _uploadOptions, | |
9023 uploadMedia: _uploadMedia, | |
9024 downloadOptions: _downloadOptions); | |
9025 return _response.then((data) => new RemarketingListShare.fromJson(data)); | |
9026 } | |
9027 | |
9028 } | |
9029 | |
9030 | |
9031 class RemarketingListsResourceApi { | |
9032 final commons.ApiRequester _requester; | |
9033 | |
9034 RemarketingListsResourceApi(commons.ApiRequester client) : | |
9035 _requester = client; | |
9036 | |
9037 /** | |
9038 * Gets one remarketing list by ID. | |
9039 * | |
9040 * Request parameters: | |
9041 * | |
9042 * [profileId] - User profile ID associated with this request. | |
9043 * | |
9044 * [id] - Remarketing list ID. | |
9045 * | |
9046 * Completes with a [RemarketingList]. | |
9047 * | |
9048 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
9049 * error. | |
9050 * | |
9051 * If the used [http.Client] completes with an error when making a REST call, | |
9052 * this method will complete with the same error. | |
9053 */ | |
9054 async.Future<RemarketingList> get(core.String profileId, core.String id) { | |
9055 var _url = null; | |
9056 var _queryParams = new core.Map(); | |
9057 var _uploadMedia = null; | |
9058 var _uploadOptions = null; | |
9059 var _downloadOptions = commons.DownloadOptions.Metadata; | |
9060 var _body = null; | |
9061 | |
9062 if (profileId == null) { | |
9063 throw new core.ArgumentError("Parameter profileId is required."); | |
9064 } | |
9065 if (id == null) { | |
9066 throw new core.ArgumentError("Parameter id is required."); | |
9067 } | |
9068 | |
9069 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/rem
arketingLists/' + commons.Escaper.ecapeVariable('$id'); | |
9070 | |
9071 var _response = _requester.request(_url, | |
9072 "GET", | |
9073 body: _body, | |
9074 queryParams: _queryParams, | |
9075 uploadOptions: _uploadOptions, | |
9076 uploadMedia: _uploadMedia, | |
9077 downloadOptions: _downloadOptions); | |
9078 return _response.then((data) => new RemarketingList.fromJson(data)); | |
9079 } | |
9080 | |
9081 /** | |
9082 * Inserts a new remarketing list. | |
9083 * | |
9084 * [request] - The metadata request object. | |
9085 * | |
9086 * Request parameters: | |
9087 * | |
9088 * [profileId] - User profile ID associated with this request. | |
9089 * | |
9090 * Completes with a [RemarketingList]. | |
9091 * | |
9092 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
9093 * error. | |
9094 * | |
9095 * If the used [http.Client] completes with an error when making a REST call, | |
9096 * this method will complete with the same error. | |
9097 */ | |
9098 async.Future<RemarketingList> insert(RemarketingList request, core.String prof
ileId) { | |
9099 var _url = null; | |
9100 var _queryParams = new core.Map(); | |
9101 var _uploadMedia = null; | |
9102 var _uploadOptions = null; | |
9103 var _downloadOptions = commons.DownloadOptions.Metadata; | |
9104 var _body = null; | |
9105 | |
9106 if (request != null) { | |
9107 _body = convert.JSON.encode((request).toJson()); | |
9108 } | |
9109 if (profileId == null) { | |
9110 throw new core.ArgumentError("Parameter profileId is required."); | |
9111 } | |
9112 | |
9113 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/rem
arketingLists'; | |
9114 | |
9115 var _response = _requester.request(_url, | |
9116 "POST", | |
9117 body: _body, | |
9118 queryParams: _queryParams, | |
9119 uploadOptions: _uploadOptions, | |
9120 uploadMedia: _uploadMedia, | |
9121 downloadOptions: _downloadOptions); | |
9122 return _response.then((data) => new RemarketingList.fromJson(data)); | |
9123 } | |
9124 | |
9125 /** | |
9126 * Retrieves a list of remarketing lists, possibly filtered. | |
9127 * | |
9128 * Request parameters: | |
9129 * | |
9130 * [profileId] - User profile ID associated with this request. | |
9131 * | |
9132 * [advertiserId] - Select only remarketing lists owned by this advertiser. | |
9133 * | |
9134 * [active] - Select only active or only inactive remarketing lists. | |
9135 * | |
9136 * [floodlightActivityId] - Select only remarketing lists that have this | |
9137 * floodlight activity ID. | |
9138 * | |
9139 * [maxResults] - Maximum number of results to return. | |
9140 * | |
9141 * [name] - Allows searching for objects by name or ID. Wildcards (*) are | |
9142 * allowed. For example, "remarketing list*2015" will return objects with | |
9143 * names like "remarketing list June 2015", "remarketing list April 2015", or | |
9144 * simply "remarketing list 2015". Most of the searches also add wildcards | |
9145 * implicitly at the start and the end of the search string. For example, a | |
9146 * search string of "remarketing list" will match objects with name "my | |
9147 * remarketing list", "remarketing list 2015", or simply "remarketing list". | |
9148 * | |
9149 * [pageToken] - Value of the nextPageToken from the previous result page. | |
9150 * | |
9151 * [sortField] - Field by which to sort the list. | |
9152 * Possible string values are: | |
9153 * - "ID" | |
9154 * - "NAME" | |
9155 * | |
9156 * [sortOrder] - Order of sorted results, default is ASCENDING. | |
9157 * Possible string values are: | |
9158 * - "ASCENDING" | |
9159 * - "DESCENDING" | |
9160 * | |
9161 * Completes with a [RemarketingListsListResponse]. | |
9162 * | |
9163 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
9164 * error. | |
9165 * | |
9166 * If the used [http.Client] completes with an error when making a REST call, | |
9167 * this method will complete with the same error. | |
9168 */ | |
9169 async.Future<RemarketingListsListResponse> list(core.String profileId, core.St
ring advertiserId, {core.bool active, core.String floodlightActivityId, core.int
maxResults, core.String name, core.String pageToken, core.String sortField, cor
e.String sortOrder}) { | |
9170 var _url = null; | |
9171 var _queryParams = new core.Map(); | |
9172 var _uploadMedia = null; | |
9173 var _uploadOptions = null; | |
9174 var _downloadOptions = commons.DownloadOptions.Metadata; | |
9175 var _body = null; | |
9176 | |
9177 if (profileId == null) { | |
9178 throw new core.ArgumentError("Parameter profileId is required."); | |
9179 } | |
9180 if (advertiserId == null) { | |
9181 throw new core.ArgumentError("Parameter advertiserId is required."); | |
9182 } | |
9183 _queryParams["advertiserId"] = [advertiserId]; | |
9184 if (active != null) { | |
9185 _queryParams["active"] = ["${active}"]; | |
9186 } | |
9187 if (floodlightActivityId != null) { | |
9188 _queryParams["floodlightActivityId"] = [floodlightActivityId]; | |
9189 } | |
9190 if (maxResults != null) { | |
9191 _queryParams["maxResults"] = ["${maxResults}"]; | |
9192 } | |
9193 if (name != null) { | |
9194 _queryParams["name"] = [name]; | |
9195 } | |
9196 if (pageToken != null) { | |
9197 _queryParams["pageToken"] = [pageToken]; | |
9198 } | |
9199 if (sortField != null) { | |
9200 _queryParams["sortField"] = [sortField]; | |
9201 } | |
9202 if (sortOrder != null) { | |
9203 _queryParams["sortOrder"] = [sortOrder]; | |
9204 } | |
9205 | |
9206 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/rem
arketingLists'; | |
9207 | |
9208 var _response = _requester.request(_url, | |
9209 "GET", | |
9210 body: _body, | |
9211 queryParams: _queryParams, | |
9212 uploadOptions: _uploadOptions, | |
9213 uploadMedia: _uploadMedia, | |
9214 downloadOptions: _downloadOptions); | |
9215 return _response.then((data) => new RemarketingListsListResponse.fromJson(da
ta)); | |
9216 } | |
9217 | |
9218 /** | |
9219 * Updates an existing remarketing list. This method supports patch semantics. | |
9220 * | |
9221 * [request] - The metadata request object. | |
9222 * | |
9223 * Request parameters: | |
9224 * | |
9225 * [profileId] - User profile ID associated with this request. | |
9226 * | |
9227 * [id] - Remarketing list ID. | |
9228 * | |
9229 * Completes with a [RemarketingList]. | |
9230 * | |
9231 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
9232 * error. | |
9233 * | |
9234 * If the used [http.Client] completes with an error when making a REST call, | |
9235 * this method will complete with the same error. | |
9236 */ | |
9237 async.Future<RemarketingList> patch(RemarketingList request, core.String profi
leId, core.String id) { | |
9238 var _url = null; | |
9239 var _queryParams = new core.Map(); | |
9240 var _uploadMedia = null; | |
9241 var _uploadOptions = null; | |
9242 var _downloadOptions = commons.DownloadOptions.Metadata; | |
9243 var _body = null; | |
9244 | |
9245 if (request != null) { | |
9246 _body = convert.JSON.encode((request).toJson()); | |
9247 } | |
9248 if (profileId == null) { | |
9249 throw new core.ArgumentError("Parameter profileId is required."); | |
9250 } | |
9251 if (id == null) { | |
9252 throw new core.ArgumentError("Parameter id is required."); | |
9253 } | |
9254 _queryParams["id"] = [id]; | |
9255 | |
9256 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/rem
arketingLists'; | |
9257 | |
9258 var _response = _requester.request(_url, | |
9259 "PATCH", | |
9260 body: _body, | |
9261 queryParams: _queryParams, | |
9262 uploadOptions: _uploadOptions, | |
9263 uploadMedia: _uploadMedia, | |
9264 downloadOptions: _downloadOptions); | |
9265 return _response.then((data) => new RemarketingList.fromJson(data)); | |
9266 } | |
9267 | |
9268 /** | |
9269 * Updates an existing remarketing list. | |
9270 * | |
9271 * [request] - The metadata request object. | |
9272 * | |
9273 * Request parameters: | |
9274 * | |
9275 * [profileId] - User profile ID associated with this request. | |
9276 * | |
9277 * Completes with a [RemarketingList]. | |
9278 * | |
9279 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
9280 * error. | |
9281 * | |
9282 * If the used [http.Client] completes with an error when making a REST call, | |
9283 * this method will complete with the same error. | |
9284 */ | |
9285 async.Future<RemarketingList> update(RemarketingList request, core.String prof
ileId) { | |
9286 var _url = null; | |
9287 var _queryParams = new core.Map(); | |
9288 var _uploadMedia = null; | |
9289 var _uploadOptions = null; | |
9290 var _downloadOptions = commons.DownloadOptions.Metadata; | |
9291 var _body = null; | |
9292 | |
9293 if (request != null) { | |
9294 _body = convert.JSON.encode((request).toJson()); | |
9295 } | |
9296 if (profileId == null) { | |
9297 throw new core.ArgumentError("Parameter profileId is required."); | |
9298 } | |
9299 | |
9300 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/rem
arketingLists'; | |
9301 | |
9302 var _response = _requester.request(_url, | |
9303 "PUT", | |
9304 body: _body, | |
9305 queryParams: _queryParams, | |
9306 uploadOptions: _uploadOptions, | |
9307 uploadMedia: _uploadMedia, | |
9308 downloadOptions: _downloadOptions); | |
9309 return _response.then((data) => new RemarketingList.fromJson(data)); | |
9310 } | |
9311 | |
9312 } | |
9313 | |
9314 | |
9315 class ReportsResourceApi { | |
9316 final commons.ApiRequester _requester; | |
9317 | |
9318 ReportsCompatibleFieldsResourceApi get compatibleFields => new ReportsCompatib
leFieldsResourceApi(_requester); | |
9319 ReportsFilesResourceApi get files => new ReportsFilesResourceApi(_requester); | |
9320 | |
9321 ReportsResourceApi(commons.ApiRequester client) : | |
9322 _requester = client; | |
9323 | |
9324 /** | |
9325 * Deletes a report by its ID. | |
9326 * | |
9327 * Request parameters: | |
9328 * | |
9329 * [profileId] - The DFA user profile ID. | |
9330 * | |
9331 * [reportId] - The ID of the report. | |
9332 * | |
9333 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
9334 * error. | |
9335 * | |
9336 * If the used [http.Client] completes with an error when making a REST call, | |
9337 * this method will complete with the same error. | |
9338 */ | |
9339 async.Future delete(core.String profileId, core.String reportId) { | |
9340 var _url = null; | |
9341 var _queryParams = new core.Map(); | |
9342 var _uploadMedia = null; | |
9343 var _uploadOptions = null; | |
9344 var _downloadOptions = commons.DownloadOptions.Metadata; | |
9345 var _body = null; | |
9346 | |
9347 if (profileId == null) { | |
9348 throw new core.ArgumentError("Parameter profileId is required."); | |
9349 } | |
9350 if (reportId == null) { | |
9351 throw new core.ArgumentError("Parameter reportId is required."); | |
9352 } | |
9353 | |
9354 _downloadOptions = null; | |
9355 | |
9356 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/rep
orts/' + commons.Escaper.ecapeVariable('$reportId'); | |
9357 | |
9358 var _response = _requester.request(_url, | |
9359 "DELETE", | |
9360 body: _body, | |
9361 queryParams: _queryParams, | |
9362 uploadOptions: _uploadOptions, | |
9363 uploadMedia: _uploadMedia, | |
9364 downloadOptions: _downloadOptions); | |
9365 return _response.then((data) => null); | |
9366 } | |
9367 | |
9368 /** | |
9369 * Retrieves a report by its ID. | |
9370 * | |
9371 * Request parameters: | |
9372 * | |
9373 * [profileId] - The DFA user profile ID. | |
9374 * | |
9375 * [reportId] - The ID of the report. | |
9376 * | |
9377 * Completes with a [Report]. | |
9378 * | |
9379 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
9380 * error. | |
9381 * | |
9382 * If the used [http.Client] completes with an error when making a REST call, | |
9383 * this method will complete with the same error. | |
9384 */ | |
9385 async.Future<Report> get(core.String profileId, core.String reportId) { | |
9386 var _url = null; | |
9387 var _queryParams = new core.Map(); | |
9388 var _uploadMedia = null; | |
9389 var _uploadOptions = null; | |
9390 var _downloadOptions = commons.DownloadOptions.Metadata; | |
9391 var _body = null; | |
9392 | |
9393 if (profileId == null) { | |
9394 throw new core.ArgumentError("Parameter profileId is required."); | |
9395 } | |
9396 if (reportId == null) { | |
9397 throw new core.ArgumentError("Parameter reportId is required."); | |
9398 } | |
9399 | |
9400 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/rep
orts/' + commons.Escaper.ecapeVariable('$reportId'); | |
9401 | |
9402 var _response = _requester.request(_url, | |
9403 "GET", | |
9404 body: _body, | |
9405 queryParams: _queryParams, | |
9406 uploadOptions: _uploadOptions, | |
9407 uploadMedia: _uploadMedia, | |
9408 downloadOptions: _downloadOptions); | |
9409 return _response.then((data) => new Report.fromJson(data)); | |
9410 } | |
9411 | |
9412 /** | |
9413 * Creates a report. | |
9414 * | |
9415 * [request] - The metadata request object. | |
9416 * | |
9417 * Request parameters: | |
9418 * | |
9419 * [profileId] - The DFA user profile ID. | |
9420 * | |
9421 * Completes with a [Report]. | |
9422 * | |
9423 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
9424 * error. | |
9425 * | |
9426 * If the used [http.Client] completes with an error when making a REST call, | |
9427 * this method will complete with the same error. | |
9428 */ | |
9429 async.Future<Report> insert(Report request, core.String profileId) { | |
9430 var _url = null; | |
9431 var _queryParams = new core.Map(); | |
9432 var _uploadMedia = null; | |
9433 var _uploadOptions = null; | |
9434 var _downloadOptions = commons.DownloadOptions.Metadata; | |
9435 var _body = null; | |
9436 | |
9437 if (request != null) { | |
9438 _body = convert.JSON.encode((request).toJson()); | |
9439 } | |
9440 if (profileId == null) { | |
9441 throw new core.ArgumentError("Parameter profileId is required."); | |
9442 } | |
9443 | |
9444 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/rep
orts'; | |
9445 | |
9446 var _response = _requester.request(_url, | |
9447 "POST", | |
9448 body: _body, | |
9449 queryParams: _queryParams, | |
9450 uploadOptions: _uploadOptions, | |
9451 uploadMedia: _uploadMedia, | |
9452 downloadOptions: _downloadOptions); | |
9453 return _response.then((data) => new Report.fromJson(data)); | |
9454 } | |
9455 | |
9456 /** | |
9457 * Retrieves list of reports. | |
9458 * | |
9459 * Request parameters: | |
9460 * | |
9461 * [profileId] - The DFA user profile ID. | |
9462 * | |
9463 * [maxResults] - Maximum number of results to return. | |
9464 * Value must be between "0" and "10". | |
9465 * | |
9466 * [pageToken] - The value of the nextToken from the previous result page. | |
9467 * | |
9468 * [scope] - The scope that defines which results are returned, default is | |
9469 * 'MINE'. | |
9470 * Possible string values are: | |
9471 * - "ALL" : All reports in account. | |
9472 * - "MINE" : My reports. | |
9473 * | |
9474 * [sortField] - The field by which to sort the list. | |
9475 * Possible string values are: | |
9476 * - "ID" : Sort by report ID. | |
9477 * - "LAST_MODIFIED_TIME" : Sort by 'lastModifiedTime' field. | |
9478 * - "NAME" : Sort by name of reports. | |
9479 * | |
9480 * [sortOrder] - Order of sorted results, default is 'DESCENDING'. | |
9481 * Possible string values are: | |
9482 * - "ASCENDING" : Ascending order. | |
9483 * - "DESCENDING" : Descending order. | |
9484 * | |
9485 * Completes with a [ReportList]. | |
9486 * | |
9487 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
9488 * error. | |
9489 * | |
9490 * If the used [http.Client] completes with an error when making a REST call, | |
9491 * this method will complete with the same error. | |
9492 */ | |
9493 async.Future<ReportList> list(core.String profileId, {core.int maxResults, cor
e.String pageToken, core.String scope, core.String sortField, core.String sortOr
der}) { | |
9494 var _url = null; | |
9495 var _queryParams = new core.Map(); | |
9496 var _uploadMedia = null; | |
9497 var _uploadOptions = null; | |
9498 var _downloadOptions = commons.DownloadOptions.Metadata; | |
9499 var _body = null; | |
9500 | |
9501 if (profileId == null) { | |
9502 throw new core.ArgumentError("Parameter profileId is required."); | |
9503 } | |
9504 if (maxResults != null) { | |
9505 _queryParams["maxResults"] = ["${maxResults}"]; | |
9506 } | |
9507 if (pageToken != null) { | |
9508 _queryParams["pageToken"] = [pageToken]; | |
9509 } | |
9510 if (scope != null) { | |
9511 _queryParams["scope"] = [scope]; | |
9512 } | |
9513 if (sortField != null) { | |
9514 _queryParams["sortField"] = [sortField]; | |
9515 } | |
9516 if (sortOrder != null) { | |
9517 _queryParams["sortOrder"] = [sortOrder]; | |
9518 } | |
9519 | |
9520 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/rep
orts'; | |
9521 | |
9522 var _response = _requester.request(_url, | |
9523 "GET", | |
9524 body: _body, | |
9525 queryParams: _queryParams, | |
9526 uploadOptions: _uploadOptions, | |
9527 uploadMedia: _uploadMedia, | |
9528 downloadOptions: _downloadOptions); | |
9529 return _response.then((data) => new ReportList.fromJson(data)); | |
9530 } | |
9531 | |
9532 /** | |
9533 * Updates a report. This method supports patch semantics. | |
9534 * | |
9535 * [request] - The metadata request object. | |
9536 * | |
9537 * Request parameters: | |
9538 * | |
9539 * [profileId] - The DFA user profile ID. | |
9540 * | |
9541 * [reportId] - The ID of the report. | |
9542 * | |
9543 * Completes with a [Report]. | |
9544 * | |
9545 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
9546 * error. | |
9547 * | |
9548 * If the used [http.Client] completes with an error when making a REST call, | |
9549 * this method will complete with the same error. | |
9550 */ | |
9551 async.Future<Report> patch(Report request, core.String profileId, core.String
reportId) { | |
9552 var _url = null; | |
9553 var _queryParams = new core.Map(); | |
9554 var _uploadMedia = null; | |
9555 var _uploadOptions = null; | |
9556 var _downloadOptions = commons.DownloadOptions.Metadata; | |
9557 var _body = null; | |
9558 | |
9559 if (request != null) { | |
9560 _body = convert.JSON.encode((request).toJson()); | |
9561 } | |
9562 if (profileId == null) { | |
9563 throw new core.ArgumentError("Parameter profileId is required."); | |
9564 } | |
9565 if (reportId == null) { | |
9566 throw new core.ArgumentError("Parameter reportId is required."); | |
9567 } | |
9568 | |
9569 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/rep
orts/' + commons.Escaper.ecapeVariable('$reportId'); | |
9570 | |
9571 var _response = _requester.request(_url, | |
9572 "PATCH", | |
9573 body: _body, | |
9574 queryParams: _queryParams, | |
9575 uploadOptions: _uploadOptions, | |
9576 uploadMedia: _uploadMedia, | |
9577 downloadOptions: _downloadOptions); | |
9578 return _response.then((data) => new Report.fromJson(data)); | |
9579 } | |
9580 | |
9581 /** | |
9582 * Runs a report. | |
9583 * | |
9584 * Request parameters: | |
9585 * | |
9586 * [profileId] - The DFA profile ID. | |
9587 * | |
9588 * [reportId] - The ID of the report. | |
9589 * | |
9590 * [synchronous] - If set and true, tries to run the report synchronously. | |
9591 * | |
9592 * Completes with a [File]. | |
9593 * | |
9594 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
9595 * error. | |
9596 * | |
9597 * If the used [http.Client] completes with an error when making a REST call, | |
9598 * this method will complete with the same error. | |
9599 */ | |
9600 async.Future<File> run(core.String profileId, core.String reportId, {core.bool
synchronous}) { | |
9601 var _url = null; | |
9602 var _queryParams = new core.Map(); | |
9603 var _uploadMedia = null; | |
9604 var _uploadOptions = null; | |
9605 var _downloadOptions = commons.DownloadOptions.Metadata; | |
9606 var _body = null; | |
9607 | |
9608 if (profileId == null) { | |
9609 throw new core.ArgumentError("Parameter profileId is required."); | |
9610 } | |
9611 if (reportId == null) { | |
9612 throw new core.ArgumentError("Parameter reportId is required."); | |
9613 } | |
9614 if (synchronous != null) { | |
9615 _queryParams["synchronous"] = ["${synchronous}"]; | |
9616 } | |
9617 | |
9618 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/rep
orts/' + commons.Escaper.ecapeVariable('$reportId') + '/run'; | |
9619 | |
9620 var _response = _requester.request(_url, | |
9621 "POST", | |
9622 body: _body, | |
9623 queryParams: _queryParams, | |
9624 uploadOptions: _uploadOptions, | |
9625 uploadMedia: _uploadMedia, | |
9626 downloadOptions: _downloadOptions); | |
9627 return _response.then((data) => new File.fromJson(data)); | |
9628 } | |
9629 | |
9630 /** | |
9631 * Updates a report. | |
9632 * | |
9633 * [request] - The metadata request object. | |
9634 * | |
9635 * Request parameters: | |
9636 * | |
9637 * [profileId] - The DFA user profile ID. | |
9638 * | |
9639 * [reportId] - The ID of the report. | |
9640 * | |
9641 * Completes with a [Report]. | |
9642 * | |
9643 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
9644 * error. | |
9645 * | |
9646 * If the used [http.Client] completes with an error when making a REST call, | |
9647 * this method will complete with the same error. | |
9648 */ | |
9649 async.Future<Report> update(Report request, core.String profileId, core.String
reportId) { | |
9650 var _url = null; | |
9651 var _queryParams = new core.Map(); | |
9652 var _uploadMedia = null; | |
9653 var _uploadOptions = null; | |
9654 var _downloadOptions = commons.DownloadOptions.Metadata; | |
9655 var _body = null; | |
9656 | |
9657 if (request != null) { | |
9658 _body = convert.JSON.encode((request).toJson()); | |
9659 } | |
9660 if (profileId == null) { | |
9661 throw new core.ArgumentError("Parameter profileId is required."); | |
9662 } | |
9663 if (reportId == null) { | |
9664 throw new core.ArgumentError("Parameter reportId is required."); | |
9665 } | |
9666 | |
9667 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/rep
orts/' + commons.Escaper.ecapeVariable('$reportId'); | |
9668 | |
9669 var _response = _requester.request(_url, | |
9670 "PUT", | |
9671 body: _body, | |
9672 queryParams: _queryParams, | |
9673 uploadOptions: _uploadOptions, | |
9674 uploadMedia: _uploadMedia, | |
9675 downloadOptions: _downloadOptions); | |
9676 return _response.then((data) => new Report.fromJson(data)); | |
9677 } | |
9678 | |
9679 } | |
9680 | |
9681 | |
9682 class ReportsCompatibleFieldsResourceApi { | |
9683 final commons.ApiRequester _requester; | |
9684 | |
9685 ReportsCompatibleFieldsResourceApi(commons.ApiRequester client) : | |
9686 _requester = client; | |
9687 | |
9688 /** | |
9689 * Returns the fields that are compatible to be selected in the respective | |
9690 * sections of a report criteria, given the fields already selected in the | |
9691 * input report and user permissions. | |
9692 * | |
9693 * [request] - The metadata request object. | |
9694 * | |
9695 * Request parameters: | |
9696 * | |
9697 * [profileId] - The DFA user profile ID. | |
9698 * | |
9699 * Completes with a [CompatibleFields]. | |
9700 * | |
9701 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
9702 * error. | |
9703 * | |
9704 * If the used [http.Client] completes with an error when making a REST call, | |
9705 * this method will complete with the same error. | |
9706 */ | |
9707 async.Future<CompatibleFields> query(Report request, core.String profileId) { | |
9708 var _url = null; | |
9709 var _queryParams = new core.Map(); | |
9710 var _uploadMedia = null; | |
9711 var _uploadOptions = null; | |
9712 var _downloadOptions = commons.DownloadOptions.Metadata; | |
9713 var _body = null; | |
9714 | |
9715 if (request != null) { | |
9716 _body = convert.JSON.encode((request).toJson()); | |
9717 } | |
9718 if (profileId == null) { | |
9719 throw new core.ArgumentError("Parameter profileId is required."); | |
9720 } | |
9721 | |
9722 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/rep
orts/compatiblefields/query'; | |
9723 | |
9724 var _response = _requester.request(_url, | |
9725 "POST", | |
9726 body: _body, | |
9727 queryParams: _queryParams, | |
9728 uploadOptions: _uploadOptions, | |
9729 uploadMedia: _uploadMedia, | |
9730 downloadOptions: _downloadOptions); | |
9731 return _response.then((data) => new CompatibleFields.fromJson(data)); | |
9732 } | |
9733 | |
9734 } | |
9735 | |
9736 | |
9737 class ReportsFilesResourceApi { | |
9738 final commons.ApiRequester _requester; | |
9739 | |
9740 ReportsFilesResourceApi(commons.ApiRequester client) : | |
9741 _requester = client; | |
9742 | |
9743 /** | |
9744 * Retrieves a report file. | |
9745 * | |
9746 * Request parameters: | |
9747 * | |
9748 * [profileId] - The DFA profile ID. | |
9749 * | |
9750 * [reportId] - The ID of the report. | |
9751 * | |
9752 * [fileId] - The ID of the report file. | |
9753 * | |
9754 * [downloadOptions] - Options for downloading. A download can be either a | |
9755 * Metadata (default) or Media download. Partial Media downloads are possible | |
9756 * as well. | |
9757 * | |
9758 * Completes with a | |
9759 * | |
9760 * - [File] for Metadata downloads (see [downloadOptions]). | |
9761 * | |
9762 * - [commons.Media] for Media downloads (see [downloadOptions]). | |
9763 * | |
9764 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
9765 * error. | |
9766 * | |
9767 * If the used [http.Client] completes with an error when making a REST call, | |
9768 * this method will complete with the same error. | |
9769 */ | |
9770 async.Future get(core.String profileId, core.String reportId, core.String file
Id, {commons.DownloadOptions downloadOptions: commons.DownloadOptions.Metadata})
{ | |
9771 var _url = null; | |
9772 var _queryParams = new core.Map(); | |
9773 var _uploadMedia = null; | |
9774 var _uploadOptions = null; | |
9775 var _downloadOptions = commons.DownloadOptions.Metadata; | |
9776 var _body = null; | |
9777 | |
9778 if (profileId == null) { | |
9779 throw new core.ArgumentError("Parameter profileId is required."); | |
9780 } | |
9781 if (reportId == null) { | |
9782 throw new core.ArgumentError("Parameter reportId is required."); | |
9783 } | |
9784 if (fileId == null) { | |
9785 throw new core.ArgumentError("Parameter fileId is required."); | |
9786 } | |
9787 | |
9788 _downloadOptions = downloadOptions; | |
9789 | |
9790 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/rep
orts/' + commons.Escaper.ecapeVariable('$reportId') + '/files/' + commons.Escape
r.ecapeVariable('$fileId'); | |
9791 | |
9792 var _response = _requester.request(_url, | |
9793 "GET", | |
9794 body: _body, | |
9795 queryParams: _queryParams, | |
9796 uploadOptions: _uploadOptions, | |
9797 uploadMedia: _uploadMedia, | |
9798 downloadOptions: _downloadOptions); | |
9799 if (_downloadOptions == null || | |
9800 _downloadOptions == commons.DownloadOptions.Metadata) { | |
9801 return _response.then((data) => new File.fromJson(data)); | |
9802 } else { | |
9803 return _response; | |
9804 } | |
9805 } | |
9806 | |
9807 /** | |
9808 * Lists files for a report. | |
9809 * | |
9810 * Request parameters: | |
9811 * | |
9812 * [profileId] - The DFA profile ID. | |
9813 * | |
9814 * [reportId] - The ID of the parent report. | |
9815 * | |
9816 * [maxResults] - Maximum number of results to return. | |
9817 * Value must be between "0" and "10". | |
9818 * | |
9819 * [pageToken] - The value of the nextToken from the previous result page. | |
9820 * | |
9821 * [sortField] - The field by which to sort the list. | |
9822 * Possible string values are: | |
9823 * - "ID" : Sort by file ID. | |
9824 * - "LAST_MODIFIED_TIME" : Sort by 'lastmodifiedAt' field. | |
9825 * | |
9826 * [sortOrder] - Order of sorted results, default is 'DESCENDING'. | |
9827 * Possible string values are: | |
9828 * - "ASCENDING" : Ascending order. | |
9829 * - "DESCENDING" : Descending order. | |
9830 * | |
9831 * Completes with a [FileList]. | |
9832 * | |
9833 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
9834 * error. | |
9835 * | |
9836 * If the used [http.Client] completes with an error when making a REST call, | |
9837 * this method will complete with the same error. | |
9838 */ | |
9839 async.Future<FileList> list(core.String profileId, core.String reportId, {core
.int maxResults, core.String pageToken, core.String sortField, core.String sortO
rder}) { | |
9840 var _url = null; | |
9841 var _queryParams = new core.Map(); | |
9842 var _uploadMedia = null; | |
9843 var _uploadOptions = null; | |
9844 var _downloadOptions = commons.DownloadOptions.Metadata; | |
9845 var _body = null; | |
9846 | |
9847 if (profileId == null) { | |
9848 throw new core.ArgumentError("Parameter profileId is required."); | |
9849 } | |
9850 if (reportId == null) { | |
9851 throw new core.ArgumentError("Parameter reportId is required."); | |
9852 } | |
9853 if (maxResults != null) { | |
9854 _queryParams["maxResults"] = ["${maxResults}"]; | |
9855 } | |
9856 if (pageToken != null) { | |
9857 _queryParams["pageToken"] = [pageToken]; | |
9858 } | |
9859 if (sortField != null) { | |
9860 _queryParams["sortField"] = [sortField]; | |
9861 } | |
9862 if (sortOrder != null) { | |
9863 _queryParams["sortOrder"] = [sortOrder]; | |
9864 } | |
9865 | |
9866 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/rep
orts/' + commons.Escaper.ecapeVariable('$reportId') + '/files'; | |
9867 | |
9868 var _response = _requester.request(_url, | |
9869 "GET", | |
9870 body: _body, | |
9871 queryParams: _queryParams, | |
9872 uploadOptions: _uploadOptions, | |
9873 uploadMedia: _uploadMedia, | |
9874 downloadOptions: _downloadOptions); | |
9875 return _response.then((data) => new FileList.fromJson(data)); | |
9876 } | |
9877 | |
9878 } | |
9879 | |
9880 | |
9881 class SitesResourceApi { | |
9882 final commons.ApiRequester _requester; | |
9883 | |
9884 SitesResourceApi(commons.ApiRequester client) : | |
9885 _requester = client; | |
9886 | |
9887 /** | |
9888 * Gets one site by ID. | |
9889 * | |
9890 * Request parameters: | |
9891 * | |
9892 * [profileId] - User profile ID associated with this request. | |
9893 * | |
9894 * [id] - Site ID. | |
9895 * | |
9896 * Completes with a [Site]. | |
9897 * | |
9898 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
9899 * error. | |
9900 * | |
9901 * If the used [http.Client] completes with an error when making a REST call, | |
9902 * this method will complete with the same error. | |
9903 */ | |
9904 async.Future<Site> get(core.String profileId, core.String id) { | |
9905 var _url = null; | |
9906 var _queryParams = new core.Map(); | |
9907 var _uploadMedia = null; | |
9908 var _uploadOptions = null; | |
9909 var _downloadOptions = commons.DownloadOptions.Metadata; | |
9910 var _body = null; | |
9911 | |
9912 if (profileId == null) { | |
9913 throw new core.ArgumentError("Parameter profileId is required."); | |
9914 } | |
9915 if (id == null) { | |
9916 throw new core.ArgumentError("Parameter id is required."); | |
9917 } | |
9918 | |
9919 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/sit
es/' + commons.Escaper.ecapeVariable('$id'); | |
9920 | |
9921 var _response = _requester.request(_url, | |
9922 "GET", | |
9923 body: _body, | |
9924 queryParams: _queryParams, | |
9925 uploadOptions: _uploadOptions, | |
9926 uploadMedia: _uploadMedia, | |
9927 downloadOptions: _downloadOptions); | |
9928 return _response.then((data) => new Site.fromJson(data)); | |
9929 } | |
9930 | |
9931 /** | |
9932 * Inserts a new site. | |
9933 * | |
9934 * [request] - The metadata request object. | |
9935 * | |
9936 * Request parameters: | |
9937 * | |
9938 * [profileId] - User profile ID associated with this request. | |
9939 * | |
9940 * Completes with a [Site]. | |
9941 * | |
9942 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
9943 * error. | |
9944 * | |
9945 * If the used [http.Client] completes with an error when making a REST call, | |
9946 * this method will complete with the same error. | |
9947 */ | |
9948 async.Future<Site> insert(Site request, core.String profileId) { | |
9949 var _url = null; | |
9950 var _queryParams = new core.Map(); | |
9951 var _uploadMedia = null; | |
9952 var _uploadOptions = null; | |
9953 var _downloadOptions = commons.DownloadOptions.Metadata; | |
9954 var _body = null; | |
9955 | |
9956 if (request != null) { | |
9957 _body = convert.JSON.encode((request).toJson()); | |
9958 } | |
9959 if (profileId == null) { | |
9960 throw new core.ArgumentError("Parameter profileId is required."); | |
9961 } | |
9962 | |
9963 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/sit
es'; | |
9964 | |
9965 var _response = _requester.request(_url, | |
9966 "POST", | |
9967 body: _body, | |
9968 queryParams: _queryParams, | |
9969 uploadOptions: _uploadOptions, | |
9970 uploadMedia: _uploadMedia, | |
9971 downloadOptions: _downloadOptions); | |
9972 return _response.then((data) => new Site.fromJson(data)); | |
9973 } | |
9974 | |
9975 /** | |
9976 * Retrieves a list of sites, possibly filtered. | |
9977 * | |
9978 * Request parameters: | |
9979 * | |
9980 * [profileId] - User profile ID associated with this request. | |
9981 * | |
9982 * [acceptsInStreamVideoPlacements] - This search filter is no longer | |
9983 * supported and will have no effect on the results returned. | |
9984 * | |
9985 * [acceptsInterstitialPlacements] - This search filter is no longer supported | |
9986 * and will have no effect on the results returned. | |
9987 * | |
9988 * [acceptsPublisherPaidPlacements] - Select only sites that accept publisher | |
9989 * paid placements. | |
9990 * | |
9991 * [adWordsSite] - Select only AdWords sites. | |
9992 * | |
9993 * [approved] - Select only approved sites. | |
9994 * | |
9995 * [campaignIds] - Select only sites with these campaign IDs. | |
9996 * | |
9997 * [directorySiteIds] - Select only sites with these directory site IDs. | |
9998 * | |
9999 * [ids] - Select only sites with these IDs. | |
10000 * | |
10001 * [maxResults] - Maximum number of results to return. | |
10002 * | |
10003 * [pageToken] - Value of the nextPageToken from the previous result page. | |
10004 * | |
10005 * [searchString] - Allows searching for objects by name, ID or keyName. | |
10006 * Wildcards (*) are allowed. For example, "site*2015" will return objects | |
10007 * with names like "site June 2015", "site April 2015", or simply "site 2015". | |
10008 * Most of the searches also add wildcards implicitly at the start and the end | |
10009 * of the search string. For example, a search string of "site" will match | |
10010 * objects with name "my site", "site 2015", or simply "site". | |
10011 * | |
10012 * [sortField] - Field by which to sort the list. | |
10013 * Possible string values are: | |
10014 * - "ID" | |
10015 * - "NAME" | |
10016 * | |
10017 * [sortOrder] - Order of sorted results, default is ASCENDING. | |
10018 * Possible string values are: | |
10019 * - "ASCENDING" | |
10020 * - "DESCENDING" | |
10021 * | |
10022 * [subaccountId] - Select only sites with this subaccount ID. | |
10023 * | |
10024 * [unmappedSite] - Select only sites that have not been mapped to a directory | |
10025 * site. | |
10026 * | |
10027 * Completes with a [SitesListResponse]. | |
10028 * | |
10029 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
10030 * error. | |
10031 * | |
10032 * If the used [http.Client] completes with an error when making a REST call, | |
10033 * this method will complete with the same error. | |
10034 */ | |
10035 async.Future<SitesListResponse> list(core.String profileId, {core.bool accepts
InStreamVideoPlacements, core.bool acceptsInterstitialPlacements, core.bool acce
ptsPublisherPaidPlacements, core.bool adWordsSite, core.bool approved, core.List
<core.String> campaignIds, core.List<core.String> directorySiteIds, core.List<co
re.String> ids, core.int maxResults, core.String pageToken, core.String searchSt
ring, core.String sortField, core.String sortOrder, core.String subaccountId, co
re.bool unmappedSite}) { | |
10036 var _url = null; | |
10037 var _queryParams = new core.Map(); | |
10038 var _uploadMedia = null; | |
10039 var _uploadOptions = null; | |
10040 var _downloadOptions = commons.DownloadOptions.Metadata; | |
10041 var _body = null; | |
10042 | |
10043 if (profileId == null) { | |
10044 throw new core.ArgumentError("Parameter profileId is required."); | |
10045 } | |
10046 if (acceptsInStreamVideoPlacements != null) { | |
10047 _queryParams["acceptsInStreamVideoPlacements"] = ["${acceptsInStreamVideoP
lacements}"]; | |
10048 } | |
10049 if (acceptsInterstitialPlacements != null) { | |
10050 _queryParams["acceptsInterstitialPlacements"] = ["${acceptsInterstitialPla
cements}"]; | |
10051 } | |
10052 if (acceptsPublisherPaidPlacements != null) { | |
10053 _queryParams["acceptsPublisherPaidPlacements"] = ["${acceptsPublisherPaidP
lacements}"]; | |
10054 } | |
10055 if (adWordsSite != null) { | |
10056 _queryParams["adWordsSite"] = ["${adWordsSite}"]; | |
10057 } | |
10058 if (approved != null) { | |
10059 _queryParams["approved"] = ["${approved}"]; | |
10060 } | |
10061 if (campaignIds != null) { | |
10062 _queryParams["campaignIds"] = campaignIds; | |
10063 } | |
10064 if (directorySiteIds != null) { | |
10065 _queryParams["directorySiteIds"] = directorySiteIds; | |
10066 } | |
10067 if (ids != null) { | |
10068 _queryParams["ids"] = ids; | |
10069 } | |
10070 if (maxResults != null) { | |
10071 _queryParams["maxResults"] = ["${maxResults}"]; | |
10072 } | |
10073 if (pageToken != null) { | |
10074 _queryParams["pageToken"] = [pageToken]; | |
10075 } | |
10076 if (searchString != null) { | |
10077 _queryParams["searchString"] = [searchString]; | |
10078 } | |
10079 if (sortField != null) { | |
10080 _queryParams["sortField"] = [sortField]; | |
10081 } | |
10082 if (sortOrder != null) { | |
10083 _queryParams["sortOrder"] = [sortOrder]; | |
10084 } | |
10085 if (subaccountId != null) { | |
10086 _queryParams["subaccountId"] = [subaccountId]; | |
10087 } | |
10088 if (unmappedSite != null) { | |
10089 _queryParams["unmappedSite"] = ["${unmappedSite}"]; | |
10090 } | |
10091 | |
10092 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/sit
es'; | |
10093 | |
10094 var _response = _requester.request(_url, | |
10095 "GET", | |
10096 body: _body, | |
10097 queryParams: _queryParams, | |
10098 uploadOptions: _uploadOptions, | |
10099 uploadMedia: _uploadMedia, | |
10100 downloadOptions: _downloadOptions); | |
10101 return _response.then((data) => new SitesListResponse.fromJson(data)); | |
10102 } | |
10103 | |
10104 /** | |
10105 * Updates an existing site. This method supports patch semantics. | |
10106 * | |
10107 * [request] - The metadata request object. | |
10108 * | |
10109 * Request parameters: | |
10110 * | |
10111 * [profileId] - User profile ID associated with this request. | |
10112 * | |
10113 * [id] - Site ID. | |
10114 * | |
10115 * Completes with a [Site]. | |
10116 * | |
10117 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
10118 * error. | |
10119 * | |
10120 * If the used [http.Client] completes with an error when making a REST call, | |
10121 * this method will complete with the same error. | |
10122 */ | |
10123 async.Future<Site> patch(Site request, core.String profileId, core.String id)
{ | |
10124 var _url = null; | |
10125 var _queryParams = new core.Map(); | |
10126 var _uploadMedia = null; | |
10127 var _uploadOptions = null; | |
10128 var _downloadOptions = commons.DownloadOptions.Metadata; | |
10129 var _body = null; | |
10130 | |
10131 if (request != null) { | |
10132 _body = convert.JSON.encode((request).toJson()); | |
10133 } | |
10134 if (profileId == null) { | |
10135 throw new core.ArgumentError("Parameter profileId is required."); | |
10136 } | |
10137 if (id == null) { | |
10138 throw new core.ArgumentError("Parameter id is required."); | |
10139 } | |
10140 _queryParams["id"] = [id]; | |
10141 | |
10142 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/sit
es'; | |
10143 | |
10144 var _response = _requester.request(_url, | |
10145 "PATCH", | |
10146 body: _body, | |
10147 queryParams: _queryParams, | |
10148 uploadOptions: _uploadOptions, | |
10149 uploadMedia: _uploadMedia, | |
10150 downloadOptions: _downloadOptions); | |
10151 return _response.then((data) => new Site.fromJson(data)); | |
10152 } | |
10153 | |
10154 /** | |
10155 * Updates an existing site. | |
10156 * | |
10157 * [request] - The metadata request object. | |
10158 * | |
10159 * Request parameters: | |
10160 * | |
10161 * [profileId] - User profile ID associated with this request. | |
10162 * | |
10163 * Completes with a [Site]. | |
10164 * | |
10165 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
10166 * error. | |
10167 * | |
10168 * If the used [http.Client] completes with an error when making a REST call, | |
10169 * this method will complete with the same error. | |
10170 */ | |
10171 async.Future<Site> update(Site request, core.String profileId) { | |
10172 var _url = null; | |
10173 var _queryParams = new core.Map(); | |
10174 var _uploadMedia = null; | |
10175 var _uploadOptions = null; | |
10176 var _downloadOptions = commons.DownloadOptions.Metadata; | |
10177 var _body = null; | |
10178 | |
10179 if (request != null) { | |
10180 _body = convert.JSON.encode((request).toJson()); | |
10181 } | |
10182 if (profileId == null) { | |
10183 throw new core.ArgumentError("Parameter profileId is required."); | |
10184 } | |
10185 | |
10186 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/sit
es'; | |
10187 | |
10188 var _response = _requester.request(_url, | |
10189 "PUT", | |
10190 body: _body, | |
10191 queryParams: _queryParams, | |
10192 uploadOptions: _uploadOptions, | |
10193 uploadMedia: _uploadMedia, | |
10194 downloadOptions: _downloadOptions); | |
10195 return _response.then((data) => new Site.fromJson(data)); | |
10196 } | |
10197 | |
10198 } | |
10199 | |
10200 | |
10201 class SizesResourceApi { | |
10202 final commons.ApiRequester _requester; | |
10203 | |
10204 SizesResourceApi(commons.ApiRequester client) : | |
10205 _requester = client; | |
10206 | |
10207 /** | |
10208 * Gets one size by ID. | |
10209 * | |
10210 * Request parameters: | |
10211 * | |
10212 * [profileId] - User profile ID associated with this request. | |
10213 * | |
10214 * [id] - Size ID. | |
10215 * | |
10216 * Completes with a [Size]. | |
10217 * | |
10218 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
10219 * error. | |
10220 * | |
10221 * If the used [http.Client] completes with an error when making a REST call, | |
10222 * this method will complete with the same error. | |
10223 */ | |
10224 async.Future<Size> get(core.String profileId, core.String id) { | |
10225 var _url = null; | |
10226 var _queryParams = new core.Map(); | |
10227 var _uploadMedia = null; | |
10228 var _uploadOptions = null; | |
10229 var _downloadOptions = commons.DownloadOptions.Metadata; | |
10230 var _body = null; | |
10231 | |
10232 if (profileId == null) { | |
10233 throw new core.ArgumentError("Parameter profileId is required."); | |
10234 } | |
10235 if (id == null) { | |
10236 throw new core.ArgumentError("Parameter id is required."); | |
10237 } | |
10238 | |
10239 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/siz
es/' + commons.Escaper.ecapeVariable('$id'); | |
10240 | |
10241 var _response = _requester.request(_url, | |
10242 "GET", | |
10243 body: _body, | |
10244 queryParams: _queryParams, | |
10245 uploadOptions: _uploadOptions, | |
10246 uploadMedia: _uploadMedia, | |
10247 downloadOptions: _downloadOptions); | |
10248 return _response.then((data) => new Size.fromJson(data)); | |
10249 } | |
10250 | |
10251 /** | |
10252 * Inserts a new size. | |
10253 * | |
10254 * [request] - The metadata request object. | |
10255 * | |
10256 * Request parameters: | |
10257 * | |
10258 * [profileId] - User profile ID associated with this request. | |
10259 * | |
10260 * Completes with a [Size]. | |
10261 * | |
10262 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
10263 * error. | |
10264 * | |
10265 * If the used [http.Client] completes with an error when making a REST call, | |
10266 * this method will complete with the same error. | |
10267 */ | |
10268 async.Future<Size> insert(Size request, core.String profileId) { | |
10269 var _url = null; | |
10270 var _queryParams = new core.Map(); | |
10271 var _uploadMedia = null; | |
10272 var _uploadOptions = null; | |
10273 var _downloadOptions = commons.DownloadOptions.Metadata; | |
10274 var _body = null; | |
10275 | |
10276 if (request != null) { | |
10277 _body = convert.JSON.encode((request).toJson()); | |
10278 } | |
10279 if (profileId == null) { | |
10280 throw new core.ArgumentError("Parameter profileId is required."); | |
10281 } | |
10282 | |
10283 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/siz
es'; | |
10284 | |
10285 var _response = _requester.request(_url, | |
10286 "POST", | |
10287 body: _body, | |
10288 queryParams: _queryParams, | |
10289 uploadOptions: _uploadOptions, | |
10290 uploadMedia: _uploadMedia, | |
10291 downloadOptions: _downloadOptions); | |
10292 return _response.then((data) => new Size.fromJson(data)); | |
10293 } | |
10294 | |
10295 /** | |
10296 * Retrieves a list of sizes, possibly filtered. | |
10297 * | |
10298 * Request parameters: | |
10299 * | |
10300 * [profileId] - User profile ID associated with this request. | |
10301 * | |
10302 * [height] - Select only sizes with this height. | |
10303 * | |
10304 * [iabStandard] - Select only IAB standard sizes. | |
10305 * | |
10306 * [ids] - Select only sizes with these IDs. | |
10307 * | |
10308 * [width] - Select only sizes with this width. | |
10309 * | |
10310 * Completes with a [SizesListResponse]. | |
10311 * | |
10312 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
10313 * error. | |
10314 * | |
10315 * If the used [http.Client] completes with an error when making a REST call, | |
10316 * this method will complete with the same error. | |
10317 */ | |
10318 async.Future<SizesListResponse> list(core.String profileId, {core.int height,
core.bool iabStandard, core.List<core.String> ids, core.int width}) { | |
10319 var _url = null; | |
10320 var _queryParams = new core.Map(); | |
10321 var _uploadMedia = null; | |
10322 var _uploadOptions = null; | |
10323 var _downloadOptions = commons.DownloadOptions.Metadata; | |
10324 var _body = null; | |
10325 | |
10326 if (profileId == null) { | |
10327 throw new core.ArgumentError("Parameter profileId is required."); | |
10328 } | |
10329 if (height != null) { | |
10330 _queryParams["height"] = ["${height}"]; | |
10331 } | |
10332 if (iabStandard != null) { | |
10333 _queryParams["iabStandard"] = ["${iabStandard}"]; | |
10334 } | |
10335 if (ids != null) { | |
10336 _queryParams["ids"] = ids; | |
10337 } | |
10338 if (width != null) { | |
10339 _queryParams["width"] = ["${width}"]; | |
10340 } | |
10341 | |
10342 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/siz
es'; | |
10343 | |
10344 var _response = _requester.request(_url, | |
10345 "GET", | |
10346 body: _body, | |
10347 queryParams: _queryParams, | |
10348 uploadOptions: _uploadOptions, | |
10349 uploadMedia: _uploadMedia, | |
10350 downloadOptions: _downloadOptions); | |
10351 return _response.then((data) => new SizesListResponse.fromJson(data)); | |
10352 } | |
10353 | |
10354 } | |
10355 | |
10356 | |
10357 class SubaccountsResourceApi { | |
10358 final commons.ApiRequester _requester; | |
10359 | |
10360 SubaccountsResourceApi(commons.ApiRequester client) : | |
10361 _requester = client; | |
10362 | |
10363 /** | |
10364 * Gets one subaccount by ID. | |
10365 * | |
10366 * Request parameters: | |
10367 * | |
10368 * [profileId] - User profile ID associated with this request. | |
10369 * | |
10370 * [id] - Subaccount ID. | |
10371 * | |
10372 * Completes with a [Subaccount]. | |
10373 * | |
10374 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
10375 * error. | |
10376 * | |
10377 * If the used [http.Client] completes with an error when making a REST call, | |
10378 * this method will complete with the same error. | |
10379 */ | |
10380 async.Future<Subaccount> get(core.String profileId, core.String id) { | |
10381 var _url = null; | |
10382 var _queryParams = new core.Map(); | |
10383 var _uploadMedia = null; | |
10384 var _uploadOptions = null; | |
10385 var _downloadOptions = commons.DownloadOptions.Metadata; | |
10386 var _body = null; | |
10387 | |
10388 if (profileId == null) { | |
10389 throw new core.ArgumentError("Parameter profileId is required."); | |
10390 } | |
10391 if (id == null) { | |
10392 throw new core.ArgumentError("Parameter id is required."); | |
10393 } | |
10394 | |
10395 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/sub
accounts/' + commons.Escaper.ecapeVariable('$id'); | |
10396 | |
10397 var _response = _requester.request(_url, | |
10398 "GET", | |
10399 body: _body, | |
10400 queryParams: _queryParams, | |
10401 uploadOptions: _uploadOptions, | |
10402 uploadMedia: _uploadMedia, | |
10403 downloadOptions: _downloadOptions); | |
10404 return _response.then((data) => new Subaccount.fromJson(data)); | |
10405 } | |
10406 | |
10407 /** | |
10408 * Inserts a new subaccount. | |
10409 * | |
10410 * [request] - The metadata request object. | |
10411 * | |
10412 * Request parameters: | |
10413 * | |
10414 * [profileId] - User profile ID associated with this request. | |
10415 * | |
10416 * Completes with a [Subaccount]. | |
10417 * | |
10418 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
10419 * error. | |
10420 * | |
10421 * If the used [http.Client] completes with an error when making a REST call, | |
10422 * this method will complete with the same error. | |
10423 */ | |
10424 async.Future<Subaccount> insert(Subaccount request, core.String profileId) { | |
10425 var _url = null; | |
10426 var _queryParams = new core.Map(); | |
10427 var _uploadMedia = null; | |
10428 var _uploadOptions = null; | |
10429 var _downloadOptions = commons.DownloadOptions.Metadata; | |
10430 var _body = null; | |
10431 | |
10432 if (request != null) { | |
10433 _body = convert.JSON.encode((request).toJson()); | |
10434 } | |
10435 if (profileId == null) { | |
10436 throw new core.ArgumentError("Parameter profileId is required."); | |
10437 } | |
10438 | |
10439 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/sub
accounts'; | |
10440 | |
10441 var _response = _requester.request(_url, | |
10442 "POST", | |
10443 body: _body, | |
10444 queryParams: _queryParams, | |
10445 uploadOptions: _uploadOptions, | |
10446 uploadMedia: _uploadMedia, | |
10447 downloadOptions: _downloadOptions); | |
10448 return _response.then((data) => new Subaccount.fromJson(data)); | |
10449 } | |
10450 | |
10451 /** | |
10452 * Gets a list of subaccounts, possibly filtered. | |
10453 * | |
10454 * Request parameters: | |
10455 * | |
10456 * [profileId] - User profile ID associated with this request. | |
10457 * | |
10458 * [ids] - Select only subaccounts with these IDs. | |
10459 * | |
10460 * [maxResults] - Maximum number of results to return. | |
10461 * | |
10462 * [pageToken] - Value of the nextPageToken from the previous result page. | |
10463 * | |
10464 * [searchString] - Allows searching for objects by name or ID. Wildcards (*) | |
10465 * are allowed. For example, "subaccount*2015" will return objects with names | |
10466 * like "subaccount June 2015", "subaccount April 2015", or simply "subaccount | |
10467 * 2015". Most of the searches also add wildcards implicitly at the start and | |
10468 * the end of the search string. For example, a search string of "subaccount" | |
10469 * will match objects with name "my subaccount", "subaccount 2015", or simply | |
10470 * "subaccount". | |
10471 * | |
10472 * [sortField] - Field by which to sort the list. | |
10473 * Possible string values are: | |
10474 * - "ID" | |
10475 * - "NAME" | |
10476 * | |
10477 * [sortOrder] - Order of sorted results, default is ASCENDING. | |
10478 * Possible string values are: | |
10479 * - "ASCENDING" | |
10480 * - "DESCENDING" | |
10481 * | |
10482 * Completes with a [SubaccountsListResponse]. | |
10483 * | |
10484 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
10485 * error. | |
10486 * | |
10487 * If the used [http.Client] completes with an error when making a REST call, | |
10488 * this method will complete with the same error. | |
10489 */ | |
10490 async.Future<SubaccountsListResponse> list(core.String profileId, {core.List<c
ore.String> ids, core.int maxResults, core.String pageToken, core.String searchS
tring, core.String sortField, core.String sortOrder}) { | |
10491 var _url = null; | |
10492 var _queryParams = new core.Map(); | |
10493 var _uploadMedia = null; | |
10494 var _uploadOptions = null; | |
10495 var _downloadOptions = commons.DownloadOptions.Metadata; | |
10496 var _body = null; | |
10497 | |
10498 if (profileId == null) { | |
10499 throw new core.ArgumentError("Parameter profileId is required."); | |
10500 } | |
10501 if (ids != null) { | |
10502 _queryParams["ids"] = ids; | |
10503 } | |
10504 if (maxResults != null) { | |
10505 _queryParams["maxResults"] = ["${maxResults}"]; | |
10506 } | |
10507 if (pageToken != null) { | |
10508 _queryParams["pageToken"] = [pageToken]; | |
10509 } | |
10510 if (searchString != null) { | |
10511 _queryParams["searchString"] = [searchString]; | |
10512 } | |
10513 if (sortField != null) { | |
10514 _queryParams["sortField"] = [sortField]; | |
10515 } | |
10516 if (sortOrder != null) { | |
10517 _queryParams["sortOrder"] = [sortOrder]; | |
10518 } | |
10519 | |
10520 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/sub
accounts'; | |
10521 | |
10522 var _response = _requester.request(_url, | |
10523 "GET", | |
10524 body: _body, | |
10525 queryParams: _queryParams, | |
10526 uploadOptions: _uploadOptions, | |
10527 uploadMedia: _uploadMedia, | |
10528 downloadOptions: _downloadOptions); | |
10529 return _response.then((data) => new SubaccountsListResponse.fromJson(data)); | |
10530 } | |
10531 | |
10532 /** | |
10533 * Updates an existing subaccount. This method supports patch semantics. | |
10534 * | |
10535 * [request] - The metadata request object. | |
10536 * | |
10537 * Request parameters: | |
10538 * | |
10539 * [profileId] - User profile ID associated with this request. | |
10540 * | |
10541 * [id] - Subaccount ID. | |
10542 * | |
10543 * Completes with a [Subaccount]. | |
10544 * | |
10545 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
10546 * error. | |
10547 * | |
10548 * If the used [http.Client] completes with an error when making a REST call, | |
10549 * this method will complete with the same error. | |
10550 */ | |
10551 async.Future<Subaccount> patch(Subaccount request, core.String profileId, core
.String id) { | |
10552 var _url = null; | |
10553 var _queryParams = new core.Map(); | |
10554 var _uploadMedia = null; | |
10555 var _uploadOptions = null; | |
10556 var _downloadOptions = commons.DownloadOptions.Metadata; | |
10557 var _body = null; | |
10558 | |
10559 if (request != null) { | |
10560 _body = convert.JSON.encode((request).toJson()); | |
10561 } | |
10562 if (profileId == null) { | |
10563 throw new core.ArgumentError("Parameter profileId is required."); | |
10564 } | |
10565 if (id == null) { | |
10566 throw new core.ArgumentError("Parameter id is required."); | |
10567 } | |
10568 _queryParams["id"] = [id]; | |
10569 | |
10570 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/sub
accounts'; | |
10571 | |
10572 var _response = _requester.request(_url, | |
10573 "PATCH", | |
10574 body: _body, | |
10575 queryParams: _queryParams, | |
10576 uploadOptions: _uploadOptions, | |
10577 uploadMedia: _uploadMedia, | |
10578 downloadOptions: _downloadOptions); | |
10579 return _response.then((data) => new Subaccount.fromJson(data)); | |
10580 } | |
10581 | |
10582 /** | |
10583 * Updates an existing subaccount. | |
10584 * | |
10585 * [request] - The metadata request object. | |
10586 * | |
10587 * Request parameters: | |
10588 * | |
10589 * [profileId] - User profile ID associated with this request. | |
10590 * | |
10591 * Completes with a [Subaccount]. | |
10592 * | |
10593 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
10594 * error. | |
10595 * | |
10596 * If the used [http.Client] completes with an error when making a REST call, | |
10597 * this method will complete with the same error. | |
10598 */ | |
10599 async.Future<Subaccount> update(Subaccount request, core.String profileId) { | |
10600 var _url = null; | |
10601 var _queryParams = new core.Map(); | |
10602 var _uploadMedia = null; | |
10603 var _uploadOptions = null; | |
10604 var _downloadOptions = commons.DownloadOptions.Metadata; | |
10605 var _body = null; | |
10606 | |
10607 if (request != null) { | |
10608 _body = convert.JSON.encode((request).toJson()); | |
10609 } | |
10610 if (profileId == null) { | |
10611 throw new core.ArgumentError("Parameter profileId is required."); | |
10612 } | |
10613 | |
10614 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/sub
accounts'; | |
10615 | |
10616 var _response = _requester.request(_url, | |
10617 "PUT", | |
10618 body: _body, | |
10619 queryParams: _queryParams, | |
10620 uploadOptions: _uploadOptions, | |
10621 uploadMedia: _uploadMedia, | |
10622 downloadOptions: _downloadOptions); | |
10623 return _response.then((data) => new Subaccount.fromJson(data)); | |
10624 } | |
10625 | |
10626 } | |
10627 | |
10628 | |
10629 class TargetableRemarketingListsResourceApi { | |
10630 final commons.ApiRequester _requester; | |
10631 | |
10632 TargetableRemarketingListsResourceApi(commons.ApiRequester client) : | |
10633 _requester = client; | |
10634 | |
10635 /** | |
10636 * Gets one remarketing list by ID. | |
10637 * | |
10638 * Request parameters: | |
10639 * | |
10640 * [profileId] - User profile ID associated with this request. | |
10641 * | |
10642 * [id] - Remarketing list ID. | |
10643 * | |
10644 * Completes with a [TargetableRemarketingList]. | |
10645 * | |
10646 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
10647 * error. | |
10648 * | |
10649 * If the used [http.Client] completes with an error when making a REST call, | |
10650 * this method will complete with the same error. | |
10651 */ | |
10652 async.Future<TargetableRemarketingList> get(core.String profileId, core.String
id) { | |
10653 var _url = null; | |
10654 var _queryParams = new core.Map(); | |
10655 var _uploadMedia = null; | |
10656 var _uploadOptions = null; | |
10657 var _downloadOptions = commons.DownloadOptions.Metadata; | |
10658 var _body = null; | |
10659 | |
10660 if (profileId == null) { | |
10661 throw new core.ArgumentError("Parameter profileId is required."); | |
10662 } | |
10663 if (id == null) { | |
10664 throw new core.ArgumentError("Parameter id is required."); | |
10665 } | |
10666 | |
10667 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/tar
getableRemarketingLists/' + commons.Escaper.ecapeVariable('$id'); | |
10668 | |
10669 var _response = _requester.request(_url, | |
10670 "GET", | |
10671 body: _body, | |
10672 queryParams: _queryParams, | |
10673 uploadOptions: _uploadOptions, | |
10674 uploadMedia: _uploadMedia, | |
10675 downloadOptions: _downloadOptions); | |
10676 return _response.then((data) => new TargetableRemarketingList.fromJson(data)
); | |
10677 } | |
10678 | |
10679 /** | |
10680 * Retrieves a list of targetable remarketing lists, possibly filtered. | |
10681 * | |
10682 * Request parameters: | |
10683 * | |
10684 * [profileId] - User profile ID associated with this request. | |
10685 * | |
10686 * [advertiserId] - Select only targetable remarketing lists targetable by | |
10687 * these advertisers. | |
10688 * | |
10689 * [active] - Select only active or only inactive targetable remarketing | |
10690 * lists. | |
10691 * | |
10692 * [maxResults] - Maximum number of results to return. | |
10693 * | |
10694 * [name] - Allows searching for objects by name or ID. Wildcards (*) are | |
10695 * allowed. For example, "remarketing list*2015" will return objects with | |
10696 * names like "remarketing list June 2015", "remarketing list April 2015", or | |
10697 * simply "remarketing list 2015". Most of the searches also add wildcards | |
10698 * implicitly at the start and the end of the search string. For example, a | |
10699 * search string of "remarketing list" will match objects with name "my | |
10700 * remarketing list", "remarketing list 2015", or simply "remarketing list". | |
10701 * | |
10702 * [pageToken] - Value of the nextPageToken from the previous result page. | |
10703 * | |
10704 * [sortField] - Field by which to sort the list. | |
10705 * Possible string values are: | |
10706 * - "ID" | |
10707 * - "NAME" | |
10708 * | |
10709 * [sortOrder] - Order of sorted results, default is ASCENDING. | |
10710 * Possible string values are: | |
10711 * - "ASCENDING" | |
10712 * - "DESCENDING" | |
10713 * | |
10714 * Completes with a [TargetableRemarketingListsListResponse]. | |
10715 * | |
10716 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
10717 * error. | |
10718 * | |
10719 * If the used [http.Client] completes with an error when making a REST call, | |
10720 * this method will complete with the same error. | |
10721 */ | |
10722 async.Future<TargetableRemarketingListsListResponse> list(core.String profileI
d, core.String advertiserId, {core.bool active, core.int maxResults, core.String
name, core.String pageToken, core.String sortField, core.String sortOrder}) { | |
10723 var _url = null; | |
10724 var _queryParams = new core.Map(); | |
10725 var _uploadMedia = null; | |
10726 var _uploadOptions = null; | |
10727 var _downloadOptions = commons.DownloadOptions.Metadata; | |
10728 var _body = null; | |
10729 | |
10730 if (profileId == null) { | |
10731 throw new core.ArgumentError("Parameter profileId is required."); | |
10732 } | |
10733 if (advertiserId == null) { | |
10734 throw new core.ArgumentError("Parameter advertiserId is required."); | |
10735 } | |
10736 _queryParams["advertiserId"] = [advertiserId]; | |
10737 if (active != null) { | |
10738 _queryParams["active"] = ["${active}"]; | |
10739 } | |
10740 if (maxResults != null) { | |
10741 _queryParams["maxResults"] = ["${maxResults}"]; | |
10742 } | |
10743 if (name != null) { | |
10744 _queryParams["name"] = [name]; | |
10745 } | |
10746 if (pageToken != null) { | |
10747 _queryParams["pageToken"] = [pageToken]; | |
10748 } | |
10749 if (sortField != null) { | |
10750 _queryParams["sortField"] = [sortField]; | |
10751 } | |
10752 if (sortOrder != null) { | |
10753 _queryParams["sortOrder"] = [sortOrder]; | |
10754 } | |
10755 | |
10756 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/tar
getableRemarketingLists'; | |
10757 | |
10758 var _response = _requester.request(_url, | |
10759 "GET", | |
10760 body: _body, | |
10761 queryParams: _queryParams, | |
10762 uploadOptions: _uploadOptions, | |
10763 uploadMedia: _uploadMedia, | |
10764 downloadOptions: _downloadOptions); | |
10765 return _response.then((data) => new TargetableRemarketingListsListResponse.f
romJson(data)); | |
10766 } | |
10767 | |
10768 } | |
10769 | |
10770 | |
10771 class UserProfilesResourceApi { | |
10772 final commons.ApiRequester _requester; | |
10773 | |
10774 UserProfilesResourceApi(commons.ApiRequester client) : | |
10775 _requester = client; | |
10776 | |
10777 /** | |
10778 * Gets one user profile by ID. | |
10779 * | |
10780 * Request parameters: | |
10781 * | |
10782 * [profileId] - The user profile ID. | |
10783 * | |
10784 * Completes with a [UserProfile]. | |
10785 * | |
10786 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
10787 * error. | |
10788 * | |
10789 * If the used [http.Client] completes with an error when making a REST call, | |
10790 * this method will complete with the same error. | |
10791 */ | |
10792 async.Future<UserProfile> get(core.String profileId) { | |
10793 var _url = null; | |
10794 var _queryParams = new core.Map(); | |
10795 var _uploadMedia = null; | |
10796 var _uploadOptions = null; | |
10797 var _downloadOptions = commons.DownloadOptions.Metadata; | |
10798 var _body = null; | |
10799 | |
10800 if (profileId == null) { | |
10801 throw new core.ArgumentError("Parameter profileId is required."); | |
10802 } | |
10803 | |
10804 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId'); | |
10805 | |
10806 var _response = _requester.request(_url, | |
10807 "GET", | |
10808 body: _body, | |
10809 queryParams: _queryParams, | |
10810 uploadOptions: _uploadOptions, | |
10811 uploadMedia: _uploadMedia, | |
10812 downloadOptions: _downloadOptions); | |
10813 return _response.then((data) => new UserProfile.fromJson(data)); | |
10814 } | |
10815 | |
10816 /** | |
10817 * Retrieves list of user profiles for a user. | |
10818 * | |
10819 * Request parameters: | |
10820 * | |
10821 * Completes with a [UserProfileList]. | |
10822 * | |
10823 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
10824 * error. | |
10825 * | |
10826 * If the used [http.Client] completes with an error when making a REST call, | |
10827 * this method will complete with the same error. | |
10828 */ | |
10829 async.Future<UserProfileList> list() { | |
10830 var _url = null; | |
10831 var _queryParams = new core.Map(); | |
10832 var _uploadMedia = null; | |
10833 var _uploadOptions = null; | |
10834 var _downloadOptions = commons.DownloadOptions.Metadata; | |
10835 var _body = null; | |
10836 | |
10837 | |
10838 _url = 'userprofiles'; | |
10839 | |
10840 var _response = _requester.request(_url, | |
10841 "GET", | |
10842 body: _body, | |
10843 queryParams: _queryParams, | |
10844 uploadOptions: _uploadOptions, | |
10845 uploadMedia: _uploadMedia, | |
10846 downloadOptions: _downloadOptions); | |
10847 return _response.then((data) => new UserProfileList.fromJson(data)); | |
10848 } | |
10849 | |
10850 } | |
10851 | |
10852 | |
10853 class UserRolePermissionGroupsResourceApi { | |
10854 final commons.ApiRequester _requester; | |
10855 | |
10856 UserRolePermissionGroupsResourceApi(commons.ApiRequester client) : | |
10857 _requester = client; | |
10858 | |
10859 /** | |
10860 * Gets one user role permission group by ID. | |
10861 * | |
10862 * Request parameters: | |
10863 * | |
10864 * [profileId] - User profile ID associated with this request. | |
10865 * | |
10866 * [id] - User role permission group ID. | |
10867 * | |
10868 * Completes with a [UserRolePermissionGroup]. | |
10869 * | |
10870 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
10871 * error. | |
10872 * | |
10873 * If the used [http.Client] completes with an error when making a REST call, | |
10874 * this method will complete with the same error. | |
10875 */ | |
10876 async.Future<UserRolePermissionGroup> get(core.String profileId, core.String i
d) { | |
10877 var _url = null; | |
10878 var _queryParams = new core.Map(); | |
10879 var _uploadMedia = null; | |
10880 var _uploadOptions = null; | |
10881 var _downloadOptions = commons.DownloadOptions.Metadata; | |
10882 var _body = null; | |
10883 | |
10884 if (profileId == null) { | |
10885 throw new core.ArgumentError("Parameter profileId is required."); | |
10886 } | |
10887 if (id == null) { | |
10888 throw new core.ArgumentError("Parameter id is required."); | |
10889 } | |
10890 | |
10891 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/use
rRolePermissionGroups/' + commons.Escaper.ecapeVariable('$id'); | |
10892 | |
10893 var _response = _requester.request(_url, | |
10894 "GET", | |
10895 body: _body, | |
10896 queryParams: _queryParams, | |
10897 uploadOptions: _uploadOptions, | |
10898 uploadMedia: _uploadMedia, | |
10899 downloadOptions: _downloadOptions); | |
10900 return _response.then((data) => new UserRolePermissionGroup.fromJson(data)); | |
10901 } | |
10902 | |
10903 /** | |
10904 * Gets a list of all supported user role permission groups. | |
10905 * | |
10906 * Request parameters: | |
10907 * | |
10908 * [profileId] - User profile ID associated with this request. | |
10909 * | |
10910 * Completes with a [UserRolePermissionGroupsListResponse]. | |
10911 * | |
10912 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
10913 * error. | |
10914 * | |
10915 * If the used [http.Client] completes with an error when making a REST call, | |
10916 * this method will complete with the same error. | |
10917 */ | |
10918 async.Future<UserRolePermissionGroupsListResponse> list(core.String profileId)
{ | |
10919 var _url = null; | |
10920 var _queryParams = new core.Map(); | |
10921 var _uploadMedia = null; | |
10922 var _uploadOptions = null; | |
10923 var _downloadOptions = commons.DownloadOptions.Metadata; | |
10924 var _body = null; | |
10925 | |
10926 if (profileId == null) { | |
10927 throw new core.ArgumentError("Parameter profileId is required."); | |
10928 } | |
10929 | |
10930 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/use
rRolePermissionGroups'; | |
10931 | |
10932 var _response = _requester.request(_url, | |
10933 "GET", | |
10934 body: _body, | |
10935 queryParams: _queryParams, | |
10936 uploadOptions: _uploadOptions, | |
10937 uploadMedia: _uploadMedia, | |
10938 downloadOptions: _downloadOptions); | |
10939 return _response.then((data) => new UserRolePermissionGroupsListResponse.fro
mJson(data)); | |
10940 } | |
10941 | |
10942 } | |
10943 | |
10944 | |
10945 class UserRolePermissionsResourceApi { | |
10946 final commons.ApiRequester _requester; | |
10947 | |
10948 UserRolePermissionsResourceApi(commons.ApiRequester client) : | |
10949 _requester = client; | |
10950 | |
10951 /** | |
10952 * Gets one user role permission by ID. | |
10953 * | |
10954 * Request parameters: | |
10955 * | |
10956 * [profileId] - User profile ID associated with this request. | |
10957 * | |
10958 * [id] - User role permission ID. | |
10959 * | |
10960 * Completes with a [UserRolePermission]. | |
10961 * | |
10962 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
10963 * error. | |
10964 * | |
10965 * If the used [http.Client] completes with an error when making a REST call, | |
10966 * this method will complete with the same error. | |
10967 */ | |
10968 async.Future<UserRolePermission> get(core.String profileId, core.String id) { | |
10969 var _url = null; | |
10970 var _queryParams = new core.Map(); | |
10971 var _uploadMedia = null; | |
10972 var _uploadOptions = null; | |
10973 var _downloadOptions = commons.DownloadOptions.Metadata; | |
10974 var _body = null; | |
10975 | |
10976 if (profileId == null) { | |
10977 throw new core.ArgumentError("Parameter profileId is required."); | |
10978 } | |
10979 if (id == null) { | |
10980 throw new core.ArgumentError("Parameter id is required."); | |
10981 } | |
10982 | |
10983 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/use
rRolePermissions/' + commons.Escaper.ecapeVariable('$id'); | |
10984 | |
10985 var _response = _requester.request(_url, | |
10986 "GET", | |
10987 body: _body, | |
10988 queryParams: _queryParams, | |
10989 uploadOptions: _uploadOptions, | |
10990 uploadMedia: _uploadMedia, | |
10991 downloadOptions: _downloadOptions); | |
10992 return _response.then((data) => new UserRolePermission.fromJson(data)); | |
10993 } | |
10994 | |
10995 /** | |
10996 * Gets a list of user role permissions, possibly filtered. | |
10997 * | |
10998 * Request parameters: | |
10999 * | |
11000 * [profileId] - User profile ID associated with this request. | |
11001 * | |
11002 * [ids] - Select only user role permissions with these IDs. | |
11003 * | |
11004 * Completes with a [UserRolePermissionsListResponse]. | |
11005 * | |
11006 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
11007 * error. | |
11008 * | |
11009 * If the used [http.Client] completes with an error when making a REST call, | |
11010 * this method will complete with the same error. | |
11011 */ | |
11012 async.Future<UserRolePermissionsListResponse> list(core.String profileId, {cor
e.List<core.String> ids}) { | |
11013 var _url = null; | |
11014 var _queryParams = new core.Map(); | |
11015 var _uploadMedia = null; | |
11016 var _uploadOptions = null; | |
11017 var _downloadOptions = commons.DownloadOptions.Metadata; | |
11018 var _body = null; | |
11019 | |
11020 if (profileId == null) { | |
11021 throw new core.ArgumentError("Parameter profileId is required."); | |
11022 } | |
11023 if (ids != null) { | |
11024 _queryParams["ids"] = ids; | |
11025 } | |
11026 | |
11027 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/use
rRolePermissions'; | |
11028 | |
11029 var _response = _requester.request(_url, | |
11030 "GET", | |
11031 body: _body, | |
11032 queryParams: _queryParams, | |
11033 uploadOptions: _uploadOptions, | |
11034 uploadMedia: _uploadMedia, | |
11035 downloadOptions: _downloadOptions); | |
11036 return _response.then((data) => new UserRolePermissionsListResponse.fromJson
(data)); | |
11037 } | |
11038 | |
11039 } | |
11040 | |
11041 | |
11042 class UserRolesResourceApi { | |
11043 final commons.ApiRequester _requester; | |
11044 | |
11045 UserRolesResourceApi(commons.ApiRequester client) : | |
11046 _requester = client; | |
11047 | |
11048 /** | |
11049 * Deletes an existing user role. | |
11050 * | |
11051 * Request parameters: | |
11052 * | |
11053 * [profileId] - User profile ID associated with this request. | |
11054 * | |
11055 * [id] - User role ID. | |
11056 * | |
11057 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
11058 * error. | |
11059 * | |
11060 * If the used [http.Client] completes with an error when making a REST call, | |
11061 * this method will complete with the same error. | |
11062 */ | |
11063 async.Future delete(core.String profileId, core.String id) { | |
11064 var _url = null; | |
11065 var _queryParams = new core.Map(); | |
11066 var _uploadMedia = null; | |
11067 var _uploadOptions = null; | |
11068 var _downloadOptions = commons.DownloadOptions.Metadata; | |
11069 var _body = null; | |
11070 | |
11071 if (profileId == null) { | |
11072 throw new core.ArgumentError("Parameter profileId is required."); | |
11073 } | |
11074 if (id == null) { | |
11075 throw new core.ArgumentError("Parameter id is required."); | |
11076 } | |
11077 | |
11078 _downloadOptions = null; | |
11079 | |
11080 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/use
rRoles/' + commons.Escaper.ecapeVariable('$id'); | |
11081 | |
11082 var _response = _requester.request(_url, | |
11083 "DELETE", | |
11084 body: _body, | |
11085 queryParams: _queryParams, | |
11086 uploadOptions: _uploadOptions, | |
11087 uploadMedia: _uploadMedia, | |
11088 downloadOptions: _downloadOptions); | |
11089 return _response.then((data) => null); | |
11090 } | |
11091 | |
11092 /** | |
11093 * Gets one user role by ID. | |
11094 * | |
11095 * Request parameters: | |
11096 * | |
11097 * [profileId] - User profile ID associated with this request. | |
11098 * | |
11099 * [id] - User role ID. | |
11100 * | |
11101 * Completes with a [UserRole]. | |
11102 * | |
11103 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
11104 * error. | |
11105 * | |
11106 * If the used [http.Client] completes with an error when making a REST call, | |
11107 * this method will complete with the same error. | |
11108 */ | |
11109 async.Future<UserRole> get(core.String profileId, core.String id) { | |
11110 var _url = null; | |
11111 var _queryParams = new core.Map(); | |
11112 var _uploadMedia = null; | |
11113 var _uploadOptions = null; | |
11114 var _downloadOptions = commons.DownloadOptions.Metadata; | |
11115 var _body = null; | |
11116 | |
11117 if (profileId == null) { | |
11118 throw new core.ArgumentError("Parameter profileId is required."); | |
11119 } | |
11120 if (id == null) { | |
11121 throw new core.ArgumentError("Parameter id is required."); | |
11122 } | |
11123 | |
11124 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/use
rRoles/' + commons.Escaper.ecapeVariable('$id'); | |
11125 | |
11126 var _response = _requester.request(_url, | |
11127 "GET", | |
11128 body: _body, | |
11129 queryParams: _queryParams, | |
11130 uploadOptions: _uploadOptions, | |
11131 uploadMedia: _uploadMedia, | |
11132 downloadOptions: _downloadOptions); | |
11133 return _response.then((data) => new UserRole.fromJson(data)); | |
11134 } | |
11135 | |
11136 /** | |
11137 * Inserts a new user role. | |
11138 * | |
11139 * [request] - The metadata request object. | |
11140 * | |
11141 * Request parameters: | |
11142 * | |
11143 * [profileId] - User profile ID associated with this request. | |
11144 * | |
11145 * Completes with a [UserRole]. | |
11146 * | |
11147 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
11148 * error. | |
11149 * | |
11150 * If the used [http.Client] completes with an error when making a REST call, | |
11151 * this method will complete with the same error. | |
11152 */ | |
11153 async.Future<UserRole> insert(UserRole request, core.String profileId) { | |
11154 var _url = null; | |
11155 var _queryParams = new core.Map(); | |
11156 var _uploadMedia = null; | |
11157 var _uploadOptions = null; | |
11158 var _downloadOptions = commons.DownloadOptions.Metadata; | |
11159 var _body = null; | |
11160 | |
11161 if (request != null) { | |
11162 _body = convert.JSON.encode((request).toJson()); | |
11163 } | |
11164 if (profileId == null) { | |
11165 throw new core.ArgumentError("Parameter profileId is required."); | |
11166 } | |
11167 | |
11168 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/use
rRoles'; | |
11169 | |
11170 var _response = _requester.request(_url, | |
11171 "POST", | |
11172 body: _body, | |
11173 queryParams: _queryParams, | |
11174 uploadOptions: _uploadOptions, | |
11175 uploadMedia: _uploadMedia, | |
11176 downloadOptions: _downloadOptions); | |
11177 return _response.then((data) => new UserRole.fromJson(data)); | |
11178 } | |
11179 | |
11180 /** | |
11181 * Retrieves a list of user roles, possibly filtered. | |
11182 * | |
11183 * Request parameters: | |
11184 * | |
11185 * [profileId] - User profile ID associated with this request. | |
11186 * | |
11187 * [accountUserRoleOnly] - Select only account level user roles not associated | |
11188 * with any specific subaccount. | |
11189 * | |
11190 * [ids] - Select only user roles with the specified IDs. | |
11191 * | |
11192 * [maxResults] - Maximum number of results to return. | |
11193 * | |
11194 * [pageToken] - Value of the nextPageToken from the previous result page. | |
11195 * | |
11196 * [searchString] - Allows searching for objects by name or ID. Wildcards (*) | |
11197 * are allowed. For example, "userrole*2015" will return objects with names | |
11198 * like "userrole June 2015", "userrole April 2015", or simply "userrole | |
11199 * 2015". Most of the searches also add wildcards implicitly at the start and | |
11200 * the end of the search string. For example, a search string of "userrole" | |
11201 * will match objects with name "my userrole", "userrole 2015", or simply | |
11202 * "userrole". | |
11203 * | |
11204 * [sortField] - Field by which to sort the list. | |
11205 * Possible string values are: | |
11206 * - "ID" | |
11207 * - "NAME" | |
11208 * | |
11209 * [sortOrder] - Order of sorted results, default is ASCENDING. | |
11210 * Possible string values are: | |
11211 * - "ASCENDING" | |
11212 * - "DESCENDING" | |
11213 * | |
11214 * [subaccountId] - Select only user roles that belong to this subaccount. | |
11215 * | |
11216 * Completes with a [UserRolesListResponse]. | |
11217 * | |
11218 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
11219 * error. | |
11220 * | |
11221 * If the used [http.Client] completes with an error when making a REST call, | |
11222 * this method will complete with the same error. | |
11223 */ | |
11224 async.Future<UserRolesListResponse> list(core.String profileId, {core.bool acc
ountUserRoleOnly, core.List<core.String> ids, core.int maxResults, core.String p
ageToken, core.String searchString, core.String sortField, core.String sortOrder
, core.String subaccountId}) { | |
11225 var _url = null; | |
11226 var _queryParams = new core.Map(); | |
11227 var _uploadMedia = null; | |
11228 var _uploadOptions = null; | |
11229 var _downloadOptions = commons.DownloadOptions.Metadata; | |
11230 var _body = null; | |
11231 | |
11232 if (profileId == null) { | |
11233 throw new core.ArgumentError("Parameter profileId is required."); | |
11234 } | |
11235 if (accountUserRoleOnly != null) { | |
11236 _queryParams["accountUserRoleOnly"] = ["${accountUserRoleOnly}"]; | |
11237 } | |
11238 if (ids != null) { | |
11239 _queryParams["ids"] = ids; | |
11240 } | |
11241 if (maxResults != null) { | |
11242 _queryParams["maxResults"] = ["${maxResults}"]; | |
11243 } | |
11244 if (pageToken != null) { | |
11245 _queryParams["pageToken"] = [pageToken]; | |
11246 } | |
11247 if (searchString != null) { | |
11248 _queryParams["searchString"] = [searchString]; | |
11249 } | |
11250 if (sortField != null) { | |
11251 _queryParams["sortField"] = [sortField]; | |
11252 } | |
11253 if (sortOrder != null) { | |
11254 _queryParams["sortOrder"] = [sortOrder]; | |
11255 } | |
11256 if (subaccountId != null) { | |
11257 _queryParams["subaccountId"] = [subaccountId]; | |
11258 } | |
11259 | |
11260 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/use
rRoles'; | |
11261 | |
11262 var _response = _requester.request(_url, | |
11263 "GET", | |
11264 body: _body, | |
11265 queryParams: _queryParams, | |
11266 uploadOptions: _uploadOptions, | |
11267 uploadMedia: _uploadMedia, | |
11268 downloadOptions: _downloadOptions); | |
11269 return _response.then((data) => new UserRolesListResponse.fromJson(data)); | |
11270 } | |
11271 | |
11272 /** | |
11273 * Updates an existing user role. This method supports patch semantics. | |
11274 * | |
11275 * [request] - The metadata request object. | |
11276 * | |
11277 * Request parameters: | |
11278 * | |
11279 * [profileId] - User profile ID associated with this request. | |
11280 * | |
11281 * [id] - User role ID. | |
11282 * | |
11283 * Completes with a [UserRole]. | |
11284 * | |
11285 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
11286 * error. | |
11287 * | |
11288 * If the used [http.Client] completes with an error when making a REST call, | |
11289 * this method will complete with the same error. | |
11290 */ | |
11291 async.Future<UserRole> patch(UserRole request, core.String profileId, core.Str
ing id) { | |
11292 var _url = null; | |
11293 var _queryParams = new core.Map(); | |
11294 var _uploadMedia = null; | |
11295 var _uploadOptions = null; | |
11296 var _downloadOptions = commons.DownloadOptions.Metadata; | |
11297 var _body = null; | |
11298 | |
11299 if (request != null) { | |
11300 _body = convert.JSON.encode((request).toJson()); | |
11301 } | |
11302 if (profileId == null) { | |
11303 throw new core.ArgumentError("Parameter profileId is required."); | |
11304 } | |
11305 if (id == null) { | |
11306 throw new core.ArgumentError("Parameter id is required."); | |
11307 } | |
11308 _queryParams["id"] = [id]; | |
11309 | |
11310 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/use
rRoles'; | |
11311 | |
11312 var _response = _requester.request(_url, | |
11313 "PATCH", | |
11314 body: _body, | |
11315 queryParams: _queryParams, | |
11316 uploadOptions: _uploadOptions, | |
11317 uploadMedia: _uploadMedia, | |
11318 downloadOptions: _downloadOptions); | |
11319 return _response.then((data) => new UserRole.fromJson(data)); | |
11320 } | |
11321 | |
11322 /** | |
11323 * Updates an existing user role. | |
11324 * | |
11325 * [request] - The metadata request object. | |
11326 * | |
11327 * Request parameters: | |
11328 * | |
11329 * [profileId] - User profile ID associated with this request. | |
11330 * | |
11331 * Completes with a [UserRole]. | |
11332 * | |
11333 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
11334 * error. | |
11335 * | |
11336 * If the used [http.Client] completes with an error when making a REST call, | |
11337 * this method will complete with the same error. | |
11338 */ | |
11339 async.Future<UserRole> update(UserRole request, core.String profileId) { | |
11340 var _url = null; | |
11341 var _queryParams = new core.Map(); | |
11342 var _uploadMedia = null; | |
11343 var _uploadOptions = null; | |
11344 var _downloadOptions = commons.DownloadOptions.Metadata; | |
11345 var _body = null; | |
11346 | |
11347 if (request != null) { | |
11348 _body = convert.JSON.encode((request).toJson()); | |
11349 } | |
11350 if (profileId == null) { | |
11351 throw new core.ArgumentError("Parameter profileId is required."); | |
11352 } | |
11353 | |
11354 _url = 'userprofiles/' + commons.Escaper.ecapeVariable('$profileId') + '/use
rRoles'; | |
11355 | |
11356 var _response = _requester.request(_url, | |
11357 "PUT", | |
11358 body: _body, | |
11359 queryParams: _queryParams, | |
11360 uploadOptions: _uploadOptions, | |
11361 uploadMedia: _uploadMedia, | |
11362 downloadOptions: _downloadOptions); | |
11363 return _response.then((data) => new UserRole.fromJson(data)); | |
11364 } | |
11365 | |
11366 } | |
11367 | |
11368 | |
11369 | |
11370 /** Contains properties of a DCM account. */ | |
11371 class Account { | |
11372 /** Account permissions assigned to this account. */ | |
11373 core.List<core.String> accountPermissionIds; | |
11374 /** | |
11375 * Profile for this account. This is a read-only field that can be left blank. | |
11376 * Possible string values are: | |
11377 * - "ACCOUNT_PROFILE_BASIC" | |
11378 * - "ACCOUNT_PROFILE_STANDARD" | |
11379 */ | |
11380 core.String accountProfile; | |
11381 /** Whether this account is active. */ | |
11382 core.bool active; | |
11383 /** | |
11384 * Maximum number of active ads allowed for this account. | |
11385 * Possible string values are: | |
11386 * - "ACTIVE_ADS_TIER_100K" | |
11387 * - "ACTIVE_ADS_TIER_200K" | |
11388 * - "ACTIVE_ADS_TIER_300K" | |
11389 * - "ACTIVE_ADS_TIER_40K" | |
11390 * - "ACTIVE_ADS_TIER_500K" | |
11391 * - "ACTIVE_ADS_TIER_75K" | |
11392 */ | |
11393 core.String activeAdsLimitTier; | |
11394 /** | |
11395 * Whether to serve creatives with Active View tags. If disabled, viewability | |
11396 * data will not be available for any impressions. | |
11397 */ | |
11398 core.bool activeViewOptOut; | |
11399 /** User role permissions available to the user roles of this account. */ | |
11400 core.List<core.String> availablePermissionIds; | |
11401 /** | |
11402 * Whether campaigns created in this account will be enabled for comScore vCE | |
11403 * by default. | |
11404 */ | |
11405 core.bool comscoreVceEnabled; | |
11406 /** ID of the country associated with this account. */ | |
11407 core.String countryId; | |
11408 /** | |
11409 * ID of currency associated with this account. This is a required field. | |
11410 * Acceptable values are: | |
11411 * - "1" for USD | |
11412 * - "2" for GBP | |
11413 * - "3" for ESP | |
11414 * - "4" for SEK | |
11415 * - "5" for CAD | |
11416 * - "6" for JPY | |
11417 * - "7" for DEM | |
11418 * - "8" for AUD | |
11419 * - "9" for FRF | |
11420 * - "10" for ITL | |
11421 * - "11" for DKK | |
11422 * - "12" for NOK | |
11423 * - "13" for FIM | |
11424 * - "14" for ZAR | |
11425 * - "15" for IEP | |
11426 * - "16" for NLG | |
11427 * - "17" for EUR | |
11428 * - "18" for KRW | |
11429 * - "19" for TWD | |
11430 * - "20" for SGD | |
11431 * - "21" for CNY | |
11432 * - "22" for HKD | |
11433 * - "23" for NZD | |
11434 * - "24" for MYR | |
11435 * - "25" for BRL | |
11436 * - "26" for PTE | |
11437 * - "27" for MXP | |
11438 * - "28" for CLP | |
11439 * - "29" for TRY | |
11440 * - "30" for ARS | |
11441 * - "31" for PEN | |
11442 * - "32" for ILS | |
11443 * - "33" for CHF | |
11444 * - "34" for VEF | |
11445 * - "35" for COP | |
11446 * - "36" for GTQ | |
11447 * - "37" for PLN | |
11448 * - "39" for INR | |
11449 * - "40" for THB | |
11450 * - "41" for IDR | |
11451 * - "42" for CZK | |
11452 * - "43" for RON | |
11453 * - "44" for HUF | |
11454 * - "45" for RUB | |
11455 * - "46" for AED | |
11456 * - "47" for BGN | |
11457 * - "48" for HRK | |
11458 */ | |
11459 core.String currencyId; | |
11460 /** Default placement dimensions for this account. */ | |
11461 core.String defaultCreativeSizeId; | |
11462 /** Description of this account. */ | |
11463 core.String description; | |
11464 /** ID of this account. This is a read-only, auto-generated field. */ | |
11465 core.String id; | |
11466 /** | |
11467 * Identifies what kind of resource this is. Value: the fixed string | |
11468 * "dfareporting#account". | |
11469 */ | |
11470 core.String kind; | |
11471 /** | |
11472 * Locale of this account. | |
11473 * Acceptable values are: | |
11474 * - "cs" (Czech) | |
11475 * - "de" (German) | |
11476 * - "en" (English) | |
11477 * - "en-GB" (English United Kingdom) | |
11478 * - "es" (Spanish) | |
11479 * - "fr" (French) | |
11480 * - "it" (Italian) | |
11481 * - "ja" (Japanese) | |
11482 * - "ko" (Korean) | |
11483 * - "pl" (Polish) | |
11484 * - "pt-BR" (Portuguese Brazil) | |
11485 * - "ru" (Russian) | |
11486 * - "sv" (Swedish) | |
11487 * - "tr" (Turkish) | |
11488 * - "zh-CN" (Chinese Simplified) | |
11489 * - "zh-TW" (Chinese Traditional) | |
11490 */ | |
11491 core.String locale; | |
11492 /** Maximum image size allowed for this account. */ | |
11493 core.String maximumImageSize; | |
11494 /** | |
11495 * Name of this account. This is a required field, and must be less than 128 | |
11496 * characters long and be globally unique. | |
11497 */ | |
11498 core.String name; | |
11499 /** | |
11500 * Whether campaigns created in this account will be enabled for Nielsen OCR | |
11501 * reach ratings by default. | |
11502 */ | |
11503 core.bool nielsenOcrEnabled; | |
11504 /** Reporting configuration of this account. */ | |
11505 ReportsConfiguration reportsConfiguration; | |
11506 /** | |
11507 * File size limit in kilobytes of Rich Media teaser creatives. Must be | |
11508 * between 1 and 10240. | |
11509 */ | |
11510 core.String teaserSizeLimit; | |
11511 | |
11512 Account(); | |
11513 | |
11514 Account.fromJson(core.Map _json) { | |
11515 if (_json.containsKey("accountPermissionIds")) { | |
11516 accountPermissionIds = _json["accountPermissionIds"]; | |
11517 } | |
11518 if (_json.containsKey("accountProfile")) { | |
11519 accountProfile = _json["accountProfile"]; | |
11520 } | |
11521 if (_json.containsKey("active")) { | |
11522 active = _json["active"]; | |
11523 } | |
11524 if (_json.containsKey("activeAdsLimitTier")) { | |
11525 activeAdsLimitTier = _json["activeAdsLimitTier"]; | |
11526 } | |
11527 if (_json.containsKey("activeViewOptOut")) { | |
11528 activeViewOptOut = _json["activeViewOptOut"]; | |
11529 } | |
11530 if (_json.containsKey("availablePermissionIds")) { | |
11531 availablePermissionIds = _json["availablePermissionIds"]; | |
11532 } | |
11533 if (_json.containsKey("comscoreVceEnabled")) { | |
11534 comscoreVceEnabled = _json["comscoreVceEnabled"]; | |
11535 } | |
11536 if (_json.containsKey("countryId")) { | |
11537 countryId = _json["countryId"]; | |
11538 } | |
11539 if (_json.containsKey("currencyId")) { | |
11540 currencyId = _json["currencyId"]; | |
11541 } | |
11542 if (_json.containsKey("defaultCreativeSizeId")) { | |
11543 defaultCreativeSizeId = _json["defaultCreativeSizeId"]; | |
11544 } | |
11545 if (_json.containsKey("description")) { | |
11546 description = _json["description"]; | |
11547 } | |
11548 if (_json.containsKey("id")) { | |
11549 id = _json["id"]; | |
11550 } | |
11551 if (_json.containsKey("kind")) { | |
11552 kind = _json["kind"]; | |
11553 } | |
11554 if (_json.containsKey("locale")) { | |
11555 locale = _json["locale"]; | |
11556 } | |
11557 if (_json.containsKey("maximumImageSize")) { | |
11558 maximumImageSize = _json["maximumImageSize"]; | |
11559 } | |
11560 if (_json.containsKey("name")) { | |
11561 name = _json["name"]; | |
11562 } | |
11563 if (_json.containsKey("nielsenOcrEnabled")) { | |
11564 nielsenOcrEnabled = _json["nielsenOcrEnabled"]; | |
11565 } | |
11566 if (_json.containsKey("reportsConfiguration")) { | |
11567 reportsConfiguration = new ReportsConfiguration.fromJson(_json["reportsCon
figuration"]); | |
11568 } | |
11569 if (_json.containsKey("teaserSizeLimit")) { | |
11570 teaserSizeLimit = _json["teaserSizeLimit"]; | |
11571 } | |
11572 } | |
11573 | |
11574 core.Map toJson() { | |
11575 var _json = new core.Map(); | |
11576 if (accountPermissionIds != null) { | |
11577 _json["accountPermissionIds"] = accountPermissionIds; | |
11578 } | |
11579 if (accountProfile != null) { | |
11580 _json["accountProfile"] = accountProfile; | |
11581 } | |
11582 if (active != null) { | |
11583 _json["active"] = active; | |
11584 } | |
11585 if (activeAdsLimitTier != null) { | |
11586 _json["activeAdsLimitTier"] = activeAdsLimitTier; | |
11587 } | |
11588 if (activeViewOptOut != null) { | |
11589 _json["activeViewOptOut"] = activeViewOptOut; | |
11590 } | |
11591 if (availablePermissionIds != null) { | |
11592 _json["availablePermissionIds"] = availablePermissionIds; | |
11593 } | |
11594 if (comscoreVceEnabled != null) { | |
11595 _json["comscoreVceEnabled"] = comscoreVceEnabled; | |
11596 } | |
11597 if (countryId != null) { | |
11598 _json["countryId"] = countryId; | |
11599 } | |
11600 if (currencyId != null) { | |
11601 _json["currencyId"] = currencyId; | |
11602 } | |
11603 if (defaultCreativeSizeId != null) { | |
11604 _json["defaultCreativeSizeId"] = defaultCreativeSizeId; | |
11605 } | |
11606 if (description != null) { | |
11607 _json["description"] = description; | |
11608 } | |
11609 if (id != null) { | |
11610 _json["id"] = id; | |
11611 } | |
11612 if (kind != null) { | |
11613 _json["kind"] = kind; | |
11614 } | |
11615 if (locale != null) { | |
11616 _json["locale"] = locale; | |
11617 } | |
11618 if (maximumImageSize != null) { | |
11619 _json["maximumImageSize"] = maximumImageSize; | |
11620 } | |
11621 if (name != null) { | |
11622 _json["name"] = name; | |
11623 } | |
11624 if (nielsenOcrEnabled != null) { | |
11625 _json["nielsenOcrEnabled"] = nielsenOcrEnabled; | |
11626 } | |
11627 if (reportsConfiguration != null) { | |
11628 _json["reportsConfiguration"] = (reportsConfiguration).toJson(); | |
11629 } | |
11630 if (teaserSizeLimit != null) { | |
11631 _json["teaserSizeLimit"] = teaserSizeLimit; | |
11632 } | |
11633 return _json; | |
11634 } | |
11635 } | |
11636 | |
11637 /** Gets a summary of active ads in an account. */ | |
11638 class AccountActiveAdSummary { | |
11639 /** ID of the account. */ | |
11640 core.String accountId; | |
11641 /** Ads that have been activated for the account */ | |
11642 core.String activeAds; | |
11643 /** | |
11644 * Maximum number of active ads allowed for the account. | |
11645 * Possible string values are: | |
11646 * - "ACTIVE_ADS_TIER_100K" | |
11647 * - "ACTIVE_ADS_TIER_200K" | |
11648 * - "ACTIVE_ADS_TIER_300K" | |
11649 * - "ACTIVE_ADS_TIER_40K" | |
11650 * - "ACTIVE_ADS_TIER_500K" | |
11651 * - "ACTIVE_ADS_TIER_75K" | |
11652 */ | |
11653 core.String activeAdsLimitTier; | |
11654 /** Ads that can be activated for the account. */ | |
11655 core.String availableAds; | |
11656 /** | |
11657 * Identifies what kind of resource this is. Value: the fixed string | |
11658 * "dfareporting#accountActiveAdSummary". | |
11659 */ | |
11660 core.String kind; | |
11661 | |
11662 AccountActiveAdSummary(); | |
11663 | |
11664 AccountActiveAdSummary.fromJson(core.Map _json) { | |
11665 if (_json.containsKey("accountId")) { | |
11666 accountId = _json["accountId"]; | |
11667 } | |
11668 if (_json.containsKey("activeAds")) { | |
11669 activeAds = _json["activeAds"]; | |
11670 } | |
11671 if (_json.containsKey("activeAdsLimitTier")) { | |
11672 activeAdsLimitTier = _json["activeAdsLimitTier"]; | |
11673 } | |
11674 if (_json.containsKey("availableAds")) { | |
11675 availableAds = _json["availableAds"]; | |
11676 } | |
11677 if (_json.containsKey("kind")) { | |
11678 kind = _json["kind"]; | |
11679 } | |
11680 } | |
11681 | |
11682 core.Map toJson() { | |
11683 var _json = new core.Map(); | |
11684 if (accountId != null) { | |
11685 _json["accountId"] = accountId; | |
11686 } | |
11687 if (activeAds != null) { | |
11688 _json["activeAds"] = activeAds; | |
11689 } | |
11690 if (activeAdsLimitTier != null) { | |
11691 _json["activeAdsLimitTier"] = activeAdsLimitTier; | |
11692 } | |
11693 if (availableAds != null) { | |
11694 _json["availableAds"] = availableAds; | |
11695 } | |
11696 if (kind != null) { | |
11697 _json["kind"] = kind; | |
11698 } | |
11699 return _json; | |
11700 } | |
11701 } | |
11702 | |
11703 /** | |
11704 * AccountPermissions contains information about a particular account | |
11705 * permission. Some features of DCM require an account permission to be present | |
11706 * in the account. | |
11707 */ | |
11708 class AccountPermission { | |
11709 /** | |
11710 * Account profiles associated with this account permission. | |
11711 * | |
11712 * Possible values are: | |
11713 * - "ACCOUNT_PROFILE_BASIC" | |
11714 * - "ACCOUNT_PROFILE_STANDARD" | |
11715 */ | |
11716 core.List<core.String> accountProfiles; | |
11717 /** ID of this account permission. */ | |
11718 core.String id; | |
11719 /** | |
11720 * Identifies what kind of resource this is. Value: the fixed string | |
11721 * "dfareporting#accountPermission". | |
11722 */ | |
11723 core.String kind; | |
11724 /** | |
11725 * Administrative level required to enable this account permission. | |
11726 * Possible string values are: | |
11727 * - "ADMINISTRATOR" | |
11728 * - "USER" | |
11729 */ | |
11730 core.String level; | |
11731 /** Name of this account permission. */ | |
11732 core.String name; | |
11733 /** Permission group of this account permission. */ | |
11734 core.String permissionGroupId; | |
11735 | |
11736 AccountPermission(); | |
11737 | |
11738 AccountPermission.fromJson(core.Map _json) { | |
11739 if (_json.containsKey("accountProfiles")) { | |
11740 accountProfiles = _json["accountProfiles"]; | |
11741 } | |
11742 if (_json.containsKey("id")) { | |
11743 id = _json["id"]; | |
11744 } | |
11745 if (_json.containsKey("kind")) { | |
11746 kind = _json["kind"]; | |
11747 } | |
11748 if (_json.containsKey("level")) { | |
11749 level = _json["level"]; | |
11750 } | |
11751 if (_json.containsKey("name")) { | |
11752 name = _json["name"]; | |
11753 } | |
11754 if (_json.containsKey("permissionGroupId")) { | |
11755 permissionGroupId = _json["permissionGroupId"]; | |
11756 } | |
11757 } | |
11758 | |
11759 core.Map toJson() { | |
11760 var _json = new core.Map(); | |
11761 if (accountProfiles != null) { | |
11762 _json["accountProfiles"] = accountProfiles; | |
11763 } | |
11764 if (id != null) { | |
11765 _json["id"] = id; | |
11766 } | |
11767 if (kind != null) { | |
11768 _json["kind"] = kind; | |
11769 } | |
11770 if (level != null) { | |
11771 _json["level"] = level; | |
11772 } | |
11773 if (name != null) { | |
11774 _json["name"] = name; | |
11775 } | |
11776 if (permissionGroupId != null) { | |
11777 _json["permissionGroupId"] = permissionGroupId; | |
11778 } | |
11779 return _json; | |
11780 } | |
11781 } | |
11782 | |
11783 /** | |
11784 * AccountPermissionGroups contains a mapping of permission group IDs to names. | |
11785 * A permission group is a grouping of account permissions. | |
11786 */ | |
11787 class AccountPermissionGroup { | |
11788 /** ID of this account permission group. */ | |
11789 core.String id; | |
11790 /** | |
11791 * Identifies what kind of resource this is. Value: the fixed string | |
11792 * "dfareporting#accountPermissionGroup". | |
11793 */ | |
11794 core.String kind; | |
11795 /** Name of this account permission group. */ | |
11796 core.String name; | |
11797 | |
11798 AccountPermissionGroup(); | |
11799 | |
11800 AccountPermissionGroup.fromJson(core.Map _json) { | |
11801 if (_json.containsKey("id")) { | |
11802 id = _json["id"]; | |
11803 } | |
11804 if (_json.containsKey("kind")) { | |
11805 kind = _json["kind"]; | |
11806 } | |
11807 if (_json.containsKey("name")) { | |
11808 name = _json["name"]; | |
11809 } | |
11810 } | |
11811 | |
11812 core.Map toJson() { | |
11813 var _json = new core.Map(); | |
11814 if (id != null) { | |
11815 _json["id"] = id; | |
11816 } | |
11817 if (kind != null) { | |
11818 _json["kind"] = kind; | |
11819 } | |
11820 if (name != null) { | |
11821 _json["name"] = name; | |
11822 } | |
11823 return _json; | |
11824 } | |
11825 } | |
11826 | |
11827 /** Account Permission Group List Response */ | |
11828 class AccountPermissionGroupsListResponse { | |
11829 /** Account permission group collection. */ | |
11830 core.List<AccountPermissionGroup> accountPermissionGroups; | |
11831 /** | |
11832 * Identifies what kind of resource this is. Value: the fixed string | |
11833 * "dfareporting#accountPermissionGroupsListResponse". | |
11834 */ | |
11835 core.String kind; | |
11836 | |
11837 AccountPermissionGroupsListResponse(); | |
11838 | |
11839 AccountPermissionGroupsListResponse.fromJson(core.Map _json) { | |
11840 if (_json.containsKey("accountPermissionGroups")) { | |
11841 accountPermissionGroups = _json["accountPermissionGroups"].map((value) =>
new AccountPermissionGroup.fromJson(value)).toList(); | |
11842 } | |
11843 if (_json.containsKey("kind")) { | |
11844 kind = _json["kind"]; | |
11845 } | |
11846 } | |
11847 | |
11848 core.Map toJson() { | |
11849 var _json = new core.Map(); | |
11850 if (accountPermissionGroups != null) { | |
11851 _json["accountPermissionGroups"] = accountPermissionGroups.map((value) =>
(value).toJson()).toList(); | |
11852 } | |
11853 if (kind != null) { | |
11854 _json["kind"] = kind; | |
11855 } | |
11856 return _json; | |
11857 } | |
11858 } | |
11859 | |
11860 /** Account Permission List Response */ | |
11861 class AccountPermissionsListResponse { | |
11862 /** Account permission collection. */ | |
11863 core.List<AccountPermission> accountPermissions; | |
11864 /** | |
11865 * Identifies what kind of resource this is. Value: the fixed string | |
11866 * "dfareporting#accountPermissionsListResponse". | |
11867 */ | |
11868 core.String kind; | |
11869 | |
11870 AccountPermissionsListResponse(); | |
11871 | |
11872 AccountPermissionsListResponse.fromJson(core.Map _json) { | |
11873 if (_json.containsKey("accountPermissions")) { | |
11874 accountPermissions = _json["accountPermissions"].map((value) => new Accoun
tPermission.fromJson(value)).toList(); | |
11875 } | |
11876 if (_json.containsKey("kind")) { | |
11877 kind = _json["kind"]; | |
11878 } | |
11879 } | |
11880 | |
11881 core.Map toJson() { | |
11882 var _json = new core.Map(); | |
11883 if (accountPermissions != null) { | |
11884 _json["accountPermissions"] = accountPermissions.map((value) => (value).to
Json()).toList(); | |
11885 } | |
11886 if (kind != null) { | |
11887 _json["kind"] = kind; | |
11888 } | |
11889 return _json; | |
11890 } | |
11891 } | |
11892 | |
11893 /** | |
11894 * AccountUserProfiles contains properties of a DCM user profile. This resource | |
11895 * is specifically for managing user profiles, whereas UserProfiles is for | |
11896 * accessing the API. | |
11897 */ | |
11898 class AccountUserProfile { | |
11899 /** | |
11900 * Account ID of the user profile. This is a read-only field that can be left | |
11901 * blank. | |
11902 */ | |
11903 core.String accountId; | |
11904 /** | |
11905 * Whether this user profile is active. This defaults to false, and must be | |
11906 * set true on insert for the user profile to be usable. | |
11907 */ | |
11908 core.bool active; | |
11909 /** | |
11910 * Filter that describes which advertisers are visible to the user profile. | |
11911 */ | |
11912 ObjectFilter advertiserFilter; | |
11913 /** Filter that describes which campaigns are visible to the user profile. */ | |
11914 ObjectFilter campaignFilter; | |
11915 /** Comments for this user profile. */ | |
11916 core.String comments; | |
11917 /** | |
11918 * Email of the user profile. The email addresss must be linked to a Google | |
11919 * Account. This field is required on insertion and is read-only after | |
11920 * insertion. | |
11921 */ | |
11922 core.String email; | |
11923 /** ID of the user profile. This is a read-only, auto-generated field. */ | |
11924 core.String id; | |
11925 /** | |
11926 * Identifies what kind of resource this is. Value: the fixed string | |
11927 * "dfareporting#accountUserProfile". | |
11928 */ | |
11929 core.String kind; | |
11930 /** | |
11931 * Locale of the user profile. This is a required field. | |
11932 * Acceptable values are: | |
11933 * - "cs" (Czech) | |
11934 * - "de" (German) | |
11935 * - "en" (English) | |
11936 * - "en-GB" (English United Kingdom) | |
11937 * - "es" (Spanish) | |
11938 * - "fr" (French) | |
11939 * - "it" (Italian) | |
11940 * - "ja" (Japanese) | |
11941 * - "ko" (Korean) | |
11942 * - "pl" (Polish) | |
11943 * - "pt-BR" (Portuguese Brazil) | |
11944 * - "ru" (Russian) | |
11945 * - "sv" (Swedish) | |
11946 * - "tr" (Turkish) | |
11947 * - "zh-CN" (Chinese Simplified) | |
11948 * - "zh-TW" (Chinese Traditional) | |
11949 */ | |
11950 core.String locale; | |
11951 /** | |
11952 * Name of the user profile. This is a required field. Must be less than 64 | |
11953 * characters long, must be globally unique, and cannot contain whitespace or | |
11954 * any of the following characters: "&;"#%,". | |
11955 */ | |
11956 core.String name; | |
11957 /** Filter that describes which sites are visible to the user profile. */ | |
11958 ObjectFilter siteFilter; | |
11959 /** | |
11960 * Subaccount ID of the user profile. This is a read-only field that can be | |
11961 * left blank. | |
11962 */ | |
11963 core.String subaccountId; | |
11964 /** | |
11965 * Trafficker type of this user profile. | |
11966 * Possible string values are: | |
11967 * - "EXTERNAL_TRAFFICKER" | |
11968 * - "INTERNAL_NON_TRAFFICKER" | |
11969 * - "INTERNAL_TRAFFICKER" | |
11970 */ | |
11971 core.String traffickerType; | |
11972 /** | |
11973 * User type of the user profile. This is a read-only field that can be left | |
11974 * blank. | |
11975 * Possible string values are: | |
11976 * - "INTERNAL_ADMINISTRATOR" | |
11977 * - "NORMAL_USER" | |
11978 * - "READ_ONLY_SUPER_USER" | |
11979 * - "SUPER_USER" | |
11980 */ | |
11981 core.String userAccessType; | |
11982 /** | |
11983 * Filter that describes which user roles are visible to the user profile. | |
11984 */ | |
11985 ObjectFilter userRoleFilter; | |
11986 /** User role ID of the user profile. This is a required field. */ | |
11987 core.String userRoleId; | |
11988 | |
11989 AccountUserProfile(); | |
11990 | |
11991 AccountUserProfile.fromJson(core.Map _json) { | |
11992 if (_json.containsKey("accountId")) { | |
11993 accountId = _json["accountId"]; | |
11994 } | |
11995 if (_json.containsKey("active")) { | |
11996 active = _json["active"]; | |
11997 } | |
11998 if (_json.containsKey("advertiserFilter")) { | |
11999 advertiserFilter = new ObjectFilter.fromJson(_json["advertiserFilter"]); | |
12000 } | |
12001 if (_json.containsKey("campaignFilter")) { | |
12002 campaignFilter = new ObjectFilter.fromJson(_json["campaignFilter"]); | |
12003 } | |
12004 if (_json.containsKey("comments")) { | |
12005 comments = _json["comments"]; | |
12006 } | |
12007 if (_json.containsKey("email")) { | |
12008 email = _json["email"]; | |
12009 } | |
12010 if (_json.containsKey("id")) { | |
12011 id = _json["id"]; | |
12012 } | |
12013 if (_json.containsKey("kind")) { | |
12014 kind = _json["kind"]; | |
12015 } | |
12016 if (_json.containsKey("locale")) { | |
12017 locale = _json["locale"]; | |
12018 } | |
12019 if (_json.containsKey("name")) { | |
12020 name = _json["name"]; | |
12021 } | |
12022 if (_json.containsKey("siteFilter")) { | |
12023 siteFilter = new ObjectFilter.fromJson(_json["siteFilter"]); | |
12024 } | |
12025 if (_json.containsKey("subaccountId")) { | |
12026 subaccountId = _json["subaccountId"]; | |
12027 } | |
12028 if (_json.containsKey("traffickerType")) { | |
12029 traffickerType = _json["traffickerType"]; | |
12030 } | |
12031 if (_json.containsKey("userAccessType")) { | |
12032 userAccessType = _json["userAccessType"]; | |
12033 } | |
12034 if (_json.containsKey("userRoleFilter")) { | |
12035 userRoleFilter = new ObjectFilter.fromJson(_json["userRoleFilter"]); | |
12036 } | |
12037 if (_json.containsKey("userRoleId")) { | |
12038 userRoleId = _json["userRoleId"]; | |
12039 } | |
12040 } | |
12041 | |
12042 core.Map toJson() { | |
12043 var _json = new core.Map(); | |
12044 if (accountId != null) { | |
12045 _json["accountId"] = accountId; | |
12046 } | |
12047 if (active != null) { | |
12048 _json["active"] = active; | |
12049 } | |
12050 if (advertiserFilter != null) { | |
12051 _json["advertiserFilter"] = (advertiserFilter).toJson(); | |
12052 } | |
12053 if (campaignFilter != null) { | |
12054 _json["campaignFilter"] = (campaignFilter).toJson(); | |
12055 } | |
12056 if (comments != null) { | |
12057 _json["comments"] = comments; | |
12058 } | |
12059 if (email != null) { | |
12060 _json["email"] = email; | |
12061 } | |
12062 if (id != null) { | |
12063 _json["id"] = id; | |
12064 } | |
12065 if (kind != null) { | |
12066 _json["kind"] = kind; | |
12067 } | |
12068 if (locale != null) { | |
12069 _json["locale"] = locale; | |
12070 } | |
12071 if (name != null) { | |
12072 _json["name"] = name; | |
12073 } | |
12074 if (siteFilter != null) { | |
12075 _json["siteFilter"] = (siteFilter).toJson(); | |
12076 } | |
12077 if (subaccountId != null) { | |
12078 _json["subaccountId"] = subaccountId; | |
12079 } | |
12080 if (traffickerType != null) { | |
12081 _json["traffickerType"] = traffickerType; | |
12082 } | |
12083 if (userAccessType != null) { | |
12084 _json["userAccessType"] = userAccessType; | |
12085 } | |
12086 if (userRoleFilter != null) { | |
12087 _json["userRoleFilter"] = (userRoleFilter).toJson(); | |
12088 } | |
12089 if (userRoleId != null) { | |
12090 _json["userRoleId"] = userRoleId; | |
12091 } | |
12092 return _json; | |
12093 } | |
12094 } | |
12095 | |
12096 /** Account User Profile List Response */ | |
12097 class AccountUserProfilesListResponse { | |
12098 /** Account user profile collection. */ | |
12099 core.List<AccountUserProfile> accountUserProfiles; | |
12100 /** | |
12101 * Identifies what kind of resource this is. Value: the fixed string | |
12102 * "dfareporting#accountUserProfilesListResponse". | |
12103 */ | |
12104 core.String kind; | |
12105 /** Pagination token to be used for the next list operation. */ | |
12106 core.String nextPageToken; | |
12107 | |
12108 AccountUserProfilesListResponse(); | |
12109 | |
12110 AccountUserProfilesListResponse.fromJson(core.Map _json) { | |
12111 if (_json.containsKey("accountUserProfiles")) { | |
12112 accountUserProfiles = _json["accountUserProfiles"].map((value) => new Acco
untUserProfile.fromJson(value)).toList(); | |
12113 } | |
12114 if (_json.containsKey("kind")) { | |
12115 kind = _json["kind"]; | |
12116 } | |
12117 if (_json.containsKey("nextPageToken")) { | |
12118 nextPageToken = _json["nextPageToken"]; | |
12119 } | |
12120 } | |
12121 | |
12122 core.Map toJson() { | |
12123 var _json = new core.Map(); | |
12124 if (accountUserProfiles != null) { | |
12125 _json["accountUserProfiles"] = accountUserProfiles.map((value) => (value).
toJson()).toList(); | |
12126 } | |
12127 if (kind != null) { | |
12128 _json["kind"] = kind; | |
12129 } | |
12130 if (nextPageToken != null) { | |
12131 _json["nextPageToken"] = nextPageToken; | |
12132 } | |
12133 return _json; | |
12134 } | |
12135 } | |
12136 | |
12137 /** Account List Response */ | |
12138 class AccountsListResponse { | |
12139 /** Account collection. */ | |
12140 core.List<Account> accounts; | |
12141 /** | |
12142 * Identifies what kind of resource this is. Value: the fixed string | |
12143 * "dfareporting#accountsListResponse". | |
12144 */ | |
12145 core.String kind; | |
12146 /** Pagination token to be used for the next list operation. */ | |
12147 core.String nextPageToken; | |
12148 | |
12149 AccountsListResponse(); | |
12150 | |
12151 AccountsListResponse.fromJson(core.Map _json) { | |
12152 if (_json.containsKey("accounts")) { | |
12153 accounts = _json["accounts"].map((value) => new Account.fromJson(value)).t
oList(); | |
12154 } | |
12155 if (_json.containsKey("kind")) { | |
12156 kind = _json["kind"]; | |
12157 } | |
12158 if (_json.containsKey("nextPageToken")) { | |
12159 nextPageToken = _json["nextPageToken"]; | |
12160 } | |
12161 } | |
12162 | |
12163 core.Map toJson() { | |
12164 var _json = new core.Map(); | |
12165 if (accounts != null) { | |
12166 _json["accounts"] = accounts.map((value) => (value).toJson()).toList(); | |
12167 } | |
12168 if (kind != null) { | |
12169 _json["kind"] = kind; | |
12170 } | |
12171 if (nextPageToken != null) { | |
12172 _json["nextPageToken"] = nextPageToken; | |
12173 } | |
12174 return _json; | |
12175 } | |
12176 } | |
12177 | |
12178 /** Represents an activity group. */ | |
12179 class Activities { | |
12180 /** | |
12181 * List of activity filters. The dimension values need to be all either of | |
12182 * type "dfa:activity" or "dfa:activityGroup". | |
12183 */ | |
12184 core.List<DimensionValue> filters; | |
12185 /** The kind of resource this is, in this case dfareporting#activities. */ | |
12186 core.String kind; | |
12187 /** List of names of floodlight activity metrics. */ | |
12188 core.List<core.String> metricNames; | |
12189 | |
12190 Activities(); | |
12191 | |
12192 Activities.fromJson(core.Map _json) { | |
12193 if (_json.containsKey("filters")) { | |
12194 filters = _json["filters"].map((value) => new DimensionValue.fromJson(valu
e)).toList(); | |
12195 } | |
12196 if (_json.containsKey("kind")) { | |
12197 kind = _json["kind"]; | |
12198 } | |
12199 if (_json.containsKey("metricNames")) { | |
12200 metricNames = _json["metricNames"]; | |
12201 } | |
12202 } | |
12203 | |
12204 core.Map toJson() { | |
12205 var _json = new core.Map(); | |
12206 if (filters != null) { | |
12207 _json["filters"] = filters.map((value) => (value).toJson()).toList(); | |
12208 } | |
12209 if (kind != null) { | |
12210 _json["kind"] = kind; | |
12211 } | |
12212 if (metricNames != null) { | |
12213 _json["metricNames"] = metricNames; | |
12214 } | |
12215 return _json; | |
12216 } | |
12217 } | |
12218 | |
12219 /** Contains properties of a DCM ad. */ | |
12220 class Ad { | |
12221 /** | |
12222 * Account ID of this ad. This is a read-only field that can be left blank. | |
12223 */ | |
12224 core.String accountId; | |
12225 /** Whether this ad is active. */ | |
12226 core.bool active; | |
12227 /** Advertiser ID of this ad. This is a required field on insertion. */ | |
12228 core.String advertiserId; | |
12229 /** | |
12230 * Dimension value for the ID of the advertiser. This is a read-only, | |
12231 * auto-generated field. | |
12232 */ | |
12233 DimensionValue advertiserIdDimensionValue; | |
12234 /** Whether this ad is archived. */ | |
12235 core.bool archived; | |
12236 /** | |
12237 * Audience segment ID that is being targeted for this ad. Applicable when | |
12238 * type is AD_SERVING_STANDARD_AD. | |
12239 */ | |
12240 core.String audienceSegmentId; | |
12241 /** Campaign ID of this ad. This is a required field on insertion. */ | |
12242 core.String campaignId; | |
12243 /** | |
12244 * Dimension value for the ID of the campaign. This is a read-only, | |
12245 * auto-generated field. | |
12246 */ | |
12247 DimensionValue campaignIdDimensionValue; | |
12248 /** | |
12249 * Click-through URL for this ad. This is a required field on insertion. | |
12250 * Applicable when type is AD_SERVING_CLICK_TRACKER. | |
12251 */ | |
12252 ClickThroughUrl clickThroughUrl; | |
12253 /** | |
12254 * Click-through URL suffix properties for this ad. Applies to the URL in the | |
12255 * ad or (if overriding ad properties) the URL in the creative. | |
12256 */ | |
12257 ClickThroughUrlSuffixProperties clickThroughUrlSuffixProperties; | |
12258 /** Comments for this ad. */ | |
12259 core.String comments; | |
12260 /** | |
12261 * Compatibility of this ad. Applicable when type is AD_SERVING_DEFAULT_AD. | |
12262 * WEB and WEB_INTERSTITIAL refer to rendering either on desktop or on mobile | |
12263 * devices for regular or interstitial ads, respectively. APP and | |
12264 * APP_INTERSTITIAL are for rendering in mobile apps. IN_STREAM_VIDEO refers | |
12265 * to rendering an in-stream video ads developed with the VAST standard. | |
12266 * Possible string values are: | |
12267 * - "APP" | |
12268 * - "APP_INTERSTITIAL" | |
12269 * - "IN_STREAM_VIDEO" | |
12270 * - "WEB" | |
12271 * - "WEB_INTERSTITIAL" | |
12272 */ | |
12273 core.String compatibility; | |
12274 /** Information about the creation of this ad. This is a read-only field. */ | |
12275 LastModifiedInfo createInfo; | |
12276 /** | |
12277 * Creative group assignments for this ad. Applicable when type is | |
12278 * AD_SERVING_CLICK_TRACKER. Only one assignment per creative group number is | |
12279 * allowed for a maximum of two assignments. | |
12280 */ | |
12281 core.List<CreativeGroupAssignment> creativeGroupAssignments; | |
12282 /** | |
12283 * Creative rotation for this ad. Applicable when type is | |
12284 * AD_SERVING_DEFAULT_AD, AD_SERVING_STANDARD_AD, or AD_SERVING_TRACKING. When | |
12285 * type is AD_SERVING_DEFAULT_AD, this field should have exactly one | |
12286 * creativeAssignment. | |
12287 */ | |
12288 CreativeRotation creativeRotation; | |
12289 /** | |
12290 * Time and day targeting information for this ad. This field must be left | |
12291 * blank if the ad is using a targeting template. Applicable when type is | |
12292 * AD_SERVING_STANDARD_AD. | |
12293 */ | |
12294 DayPartTargeting dayPartTargeting; | |
12295 /** Default click-through event tag properties for this ad. */ | |
12296 DefaultClickThroughEventTagProperties defaultClickThroughEventTagProperties; | |
12297 /** | |
12298 * Delivery schedule information for this ad. Applicable when type is | |
12299 * AD_SERVING_STANDARD_AD or AD_SERVING_TRACKING. This field along with | |
12300 * subfields priority and impressionRatio are required on insertion when type | |
12301 * is AD_SERVING_STANDARD_AD. | |
12302 */ | |
12303 DeliverySchedule deliverySchedule; | |
12304 /** | |
12305 * Whether this ad is a dynamic click tracker. Applicable when type is | |
12306 * AD_SERVING_CLICK_TRACKER. This is a required field on insert, and is | |
12307 * read-only after insert. | |
12308 */ | |
12309 core.bool dynamicClickTracker; | |
12310 /** | |
12311 * Date and time that this ad should stop serving. Must be later than the | |
12312 * start time. This is a required field on insertion. | |
12313 */ | |
12314 core.DateTime endTime; | |
12315 /** Event tag overrides for this ad. */ | |
12316 core.List<EventTagOverride> eventTagOverrides; | |
12317 /** | |
12318 * Geographical targeting information for this ad. This field must be left | |
12319 * blank if the ad is using a targeting template. Applicable when type is | |
12320 * AD_SERVING_STANDARD_AD. | |
12321 */ | |
12322 GeoTargeting geoTargeting; | |
12323 /** ID of this ad. This is a read-only, auto-generated field. */ | |
12324 core.String id; | |
12325 /** | |
12326 * Dimension value for the ID of this ad. This is a read-only, auto-generated | |
12327 * field. | |
12328 */ | |
12329 DimensionValue idDimensionValue; | |
12330 /** | |
12331 * Key-value targeting information for this ad. This field must be left blank | |
12332 * if the ad is using a targeting template. Applicable when type is | |
12333 * AD_SERVING_STANDARD_AD. | |
12334 */ | |
12335 KeyValueTargetingExpression keyValueTargetingExpression; | |
12336 /** | |
12337 * Identifies what kind of resource this is. Value: the fixed string | |
12338 * "dfareporting#ad". | |
12339 */ | |
12340 core.String kind; | |
12341 /** | |
12342 * Information about the most recent modification of this ad. This is a | |
12343 * read-only field. | |
12344 */ | |
12345 LastModifiedInfo lastModifiedInfo; | |
12346 /** | |
12347 * Name of this ad. This is a required field and must be less than 256 | |
12348 * characters long. | |
12349 */ | |
12350 core.String name; | |
12351 /** Placement assignments for this ad. */ | |
12352 core.List<PlacementAssignment> placementAssignments; | |
12353 /** | |
12354 * Remarketing list targeting expression for this ad. This field must be left | |
12355 * blank if the ad is using a targeting template. Applicable when type is | |
12356 * AD_SERVING_STANDARD_AD. | |
12357 */ | |
12358 ListTargetingExpression remarketingListExpression; | |
12359 /** Size of this ad. Applicable when type is AD_SERVING_DEFAULT_AD. */ | |
12360 Size size; | |
12361 /** | |
12362 * Whether this ad is ssl compliant. This is a read-only field that is | |
12363 * auto-generated when the ad is inserted or updated. | |
12364 */ | |
12365 core.bool sslCompliant; | |
12366 /** | |
12367 * Whether this ad requires ssl. This is a read-only field that is | |
12368 * auto-generated when the ad is inserted or updated. | |
12369 */ | |
12370 core.bool sslRequired; | |
12371 /** | |
12372 * Date and time that this ad should start serving. If creating an ad, this | |
12373 * field must be a time in the future. This is a required field on insertion. | |
12374 */ | |
12375 core.DateTime startTime; | |
12376 /** | |
12377 * Subaccount ID of this ad. This is a read-only field that can be left blank. | |
12378 */ | |
12379 core.String subaccountId; | |
12380 /** | |
12381 * Technology platform targeting information for this ad. This field must be | |
12382 * left blank if the ad is using a targeting template. Applicable when type is | |
12383 * AD_SERVING_STANDARD_AD. | |
12384 */ | |
12385 TechnologyTargeting technologyTargeting; | |
12386 /** | |
12387 * Type of ad. This is a required field on insertion. Note that default ads | |
12388 * (AD_SERVING_DEFAULT_AD) cannot be created directly (see Creative resource). | |
12389 * Possible string values are: | |
12390 * - "AD_SERVING_CLICK_TRACKER" | |
12391 * - "AD_SERVING_DEFAULT_AD" | |
12392 * - "AD_SERVING_STANDARD_AD" | |
12393 * - "AD_SERVING_TRACKING" | |
12394 */ | |
12395 core.String type; | |
12396 | |
12397 Ad(); | |
12398 | |
12399 Ad.fromJson(core.Map _json) { | |
12400 if (_json.containsKey("accountId")) { | |
12401 accountId = _json["accountId"]; | |
12402 } | |
12403 if (_json.containsKey("active")) { | |
12404 active = _json["active"]; | |
12405 } | |
12406 if (_json.containsKey("advertiserId")) { | |
12407 advertiserId = _json["advertiserId"]; | |
12408 } | |
12409 if (_json.containsKey("advertiserIdDimensionValue")) { | |
12410 advertiserIdDimensionValue = new DimensionValue.fromJson(_json["advertiser
IdDimensionValue"]); | |
12411 } | |
12412 if (_json.containsKey("archived")) { | |
12413 archived = _json["archived"]; | |
12414 } | |
12415 if (_json.containsKey("audienceSegmentId")) { | |
12416 audienceSegmentId = _json["audienceSegmentId"]; | |
12417 } | |
12418 if (_json.containsKey("campaignId")) { | |
12419 campaignId = _json["campaignId"]; | |
12420 } | |
12421 if (_json.containsKey("campaignIdDimensionValue")) { | |
12422 campaignIdDimensionValue = new DimensionValue.fromJson(_json["campaignIdDi
mensionValue"]); | |
12423 } | |
12424 if (_json.containsKey("clickThroughUrl")) { | |
12425 clickThroughUrl = new ClickThroughUrl.fromJson(_json["clickThroughUrl"]); | |
12426 } | |
12427 if (_json.containsKey("clickThroughUrlSuffixProperties")) { | |
12428 clickThroughUrlSuffixProperties = new ClickThroughUrlSuffixProperties.from
Json(_json["clickThroughUrlSuffixProperties"]); | |
12429 } | |
12430 if (_json.containsKey("comments")) { | |
12431 comments = _json["comments"]; | |
12432 } | |
12433 if (_json.containsKey("compatibility")) { | |
12434 compatibility = _json["compatibility"]; | |
12435 } | |
12436 if (_json.containsKey("createInfo")) { | |
12437 createInfo = new LastModifiedInfo.fromJson(_json["createInfo"]); | |
12438 } | |
12439 if (_json.containsKey("creativeGroupAssignments")) { | |
12440 creativeGroupAssignments = _json["creativeGroupAssignments"].map((value) =
> new CreativeGroupAssignment.fromJson(value)).toList(); | |
12441 } | |
12442 if (_json.containsKey("creativeRotation")) { | |
12443 creativeRotation = new CreativeRotation.fromJson(_json["creativeRotation"]
); | |
12444 } | |
12445 if (_json.containsKey("dayPartTargeting")) { | |
12446 dayPartTargeting = new DayPartTargeting.fromJson(_json["dayPartTargeting"]
); | |
12447 } | |
12448 if (_json.containsKey("defaultClickThroughEventTagProperties")) { | |
12449 defaultClickThroughEventTagProperties = new DefaultClickThroughEventTagPro
perties.fromJson(_json["defaultClickThroughEventTagProperties"]); | |
12450 } | |
12451 if (_json.containsKey("deliverySchedule")) { | |
12452 deliverySchedule = new DeliverySchedule.fromJson(_json["deliverySchedule"]
); | |
12453 } | |
12454 if (_json.containsKey("dynamicClickTracker")) { | |
12455 dynamicClickTracker = _json["dynamicClickTracker"]; | |
12456 } | |
12457 if (_json.containsKey("endTime")) { | |
12458 endTime = core.DateTime.parse(_json["endTime"]); | |
12459 } | |
12460 if (_json.containsKey("eventTagOverrides")) { | |
12461 eventTagOverrides = _json["eventTagOverrides"].map((value) => new EventTag
Override.fromJson(value)).toList(); | |
12462 } | |
12463 if (_json.containsKey("geoTargeting")) { | |
12464 geoTargeting = new GeoTargeting.fromJson(_json["geoTargeting"]); | |
12465 } | |
12466 if (_json.containsKey("id")) { | |
12467 id = _json["id"]; | |
12468 } | |
12469 if (_json.containsKey("idDimensionValue")) { | |
12470 idDimensionValue = new DimensionValue.fromJson(_json["idDimensionValue"]); | |
12471 } | |
12472 if (_json.containsKey("keyValueTargetingExpression")) { | |
12473 keyValueTargetingExpression = new KeyValueTargetingExpression.fromJson(_js
on["keyValueTargetingExpression"]); | |
12474 } | |
12475 if (_json.containsKey("kind")) { | |
12476 kind = _json["kind"]; | |
12477 } | |
12478 if (_json.containsKey("lastModifiedInfo")) { | |
12479 lastModifiedInfo = new LastModifiedInfo.fromJson(_json["lastModifiedInfo"]
); | |
12480 } | |
12481 if (_json.containsKey("name")) { | |
12482 name = _json["name"]; | |
12483 } | |
12484 if (_json.containsKey("placementAssignments")) { | |
12485 placementAssignments = _json["placementAssignments"].map((value) => new Pl
acementAssignment.fromJson(value)).toList(); | |
12486 } | |
12487 if (_json.containsKey("remarketingListExpression")) { | |
12488 remarketingListExpression = new ListTargetingExpression.fromJson(_json["re
marketingListExpression"]); | |
12489 } | |
12490 if (_json.containsKey("size")) { | |
12491 size = new Size.fromJson(_json["size"]); | |
12492 } | |
12493 if (_json.containsKey("sslCompliant")) { | |
12494 sslCompliant = _json["sslCompliant"]; | |
12495 } | |
12496 if (_json.containsKey("sslRequired")) { | |
12497 sslRequired = _json["sslRequired"]; | |
12498 } | |
12499 if (_json.containsKey("startTime")) { | |
12500 startTime = core.DateTime.parse(_json["startTime"]); | |
12501 } | |
12502 if (_json.containsKey("subaccountId")) { | |
12503 subaccountId = _json["subaccountId"]; | |
12504 } | |
12505 if (_json.containsKey("technologyTargeting")) { | |
12506 technologyTargeting = new TechnologyTargeting.fromJson(_json["technologyTa
rgeting"]); | |
12507 } | |
12508 if (_json.containsKey("type")) { | |
12509 type = _json["type"]; | |
12510 } | |
12511 } | |
12512 | |
12513 core.Map toJson() { | |
12514 var _json = new core.Map(); | |
12515 if (accountId != null) { | |
12516 _json["accountId"] = accountId; | |
12517 } | |
12518 if (active != null) { | |
12519 _json["active"] = active; | |
12520 } | |
12521 if (advertiserId != null) { | |
12522 _json["advertiserId"] = advertiserId; | |
12523 } | |
12524 if (advertiserIdDimensionValue != null) { | |
12525 _json["advertiserIdDimensionValue"] = (advertiserIdDimensionValue).toJson(
); | |
12526 } | |
12527 if (archived != null) { | |
12528 _json["archived"] = archived; | |
12529 } | |
12530 if (audienceSegmentId != null) { | |
12531 _json["audienceSegmentId"] = audienceSegmentId; | |
12532 } | |
12533 if (campaignId != null) { | |
12534 _json["campaignId"] = campaignId; | |
12535 } | |
12536 if (campaignIdDimensionValue != null) { | |
12537 _json["campaignIdDimensionValue"] = (campaignIdDimensionValue).toJson(); | |
12538 } | |
12539 if (clickThroughUrl != null) { | |
12540 _json["clickThroughUrl"] = (clickThroughUrl).toJson(); | |
12541 } | |
12542 if (clickThroughUrlSuffixProperties != null) { | |
12543 _json["clickThroughUrlSuffixProperties"] = (clickThroughUrlSuffixPropertie
s).toJson(); | |
12544 } | |
12545 if (comments != null) { | |
12546 _json["comments"] = comments; | |
12547 } | |
12548 if (compatibility != null) { | |
12549 _json["compatibility"] = compatibility; | |
12550 } | |
12551 if (createInfo != null) { | |
12552 _json["createInfo"] = (createInfo).toJson(); | |
12553 } | |
12554 if (creativeGroupAssignments != null) { | |
12555 _json["creativeGroupAssignments"] = creativeGroupAssignments.map((value) =
> (value).toJson()).toList(); | |
12556 } | |
12557 if (creativeRotation != null) { | |
12558 _json["creativeRotation"] = (creativeRotation).toJson(); | |
12559 } | |
12560 if (dayPartTargeting != null) { | |
12561 _json["dayPartTargeting"] = (dayPartTargeting).toJson(); | |
12562 } | |
12563 if (defaultClickThroughEventTagProperties != null) { | |
12564 _json["defaultClickThroughEventTagProperties"] = (defaultClickThroughEvent
TagProperties).toJson(); | |
12565 } | |
12566 if (deliverySchedule != null) { | |
12567 _json["deliverySchedule"] = (deliverySchedule).toJson(); | |
12568 } | |
12569 if (dynamicClickTracker != null) { | |
12570 _json["dynamicClickTracker"] = dynamicClickTracker; | |
12571 } | |
12572 if (endTime != null) { | |
12573 _json["endTime"] = (endTime).toIso8601String(); | |
12574 } | |
12575 if (eventTagOverrides != null) { | |
12576 _json["eventTagOverrides"] = eventTagOverrides.map((value) => (value).toJs
on()).toList(); | |
12577 } | |
12578 if (geoTargeting != null) { | |
12579 _json["geoTargeting"] = (geoTargeting).toJson(); | |
12580 } | |
12581 if (id != null) { | |
12582 _json["id"] = id; | |
12583 } | |
12584 if (idDimensionValue != null) { | |
12585 _json["idDimensionValue"] = (idDimensionValue).toJson(); | |
12586 } | |
12587 if (keyValueTargetingExpression != null) { | |
12588 _json["keyValueTargetingExpression"] = (keyValueTargetingExpression).toJso
n(); | |
12589 } | |
12590 if (kind != null) { | |
12591 _json["kind"] = kind; | |
12592 } | |
12593 if (lastModifiedInfo != null) { | |
12594 _json["lastModifiedInfo"] = (lastModifiedInfo).toJson(); | |
12595 } | |
12596 if (name != null) { | |
12597 _json["name"] = name; | |
12598 } | |
12599 if (placementAssignments != null) { | |
12600 _json["placementAssignments"] = placementAssignments.map((value) => (value
).toJson()).toList(); | |
12601 } | |
12602 if (remarketingListExpression != null) { | |
12603 _json["remarketingListExpression"] = (remarketingListExpression).toJson(); | |
12604 } | |
12605 if (size != null) { | |
12606 _json["size"] = (size).toJson(); | |
12607 } | |
12608 if (sslCompliant != null) { | |
12609 _json["sslCompliant"] = sslCompliant; | |
12610 } | |
12611 if (sslRequired != null) { | |
12612 _json["sslRequired"] = sslRequired; | |
12613 } | |
12614 if (startTime != null) { | |
12615 _json["startTime"] = (startTime).toIso8601String(); | |
12616 } | |
12617 if (subaccountId != null) { | |
12618 _json["subaccountId"] = subaccountId; | |
12619 } | |
12620 if (technologyTargeting != null) { | |
12621 _json["technologyTargeting"] = (technologyTargeting).toJson(); | |
12622 } | |
12623 if (type != null) { | |
12624 _json["type"] = type; | |
12625 } | |
12626 return _json; | |
12627 } | |
12628 } | |
12629 | |
12630 /** Ad Slot */ | |
12631 class AdSlot { | |
12632 /** Comment for this ad slot. */ | |
12633 core.String comment; | |
12634 /** | |
12635 * Ad slot compatibility. WEB and WEB_INTERSTITIAL refer to rendering either | |
12636 * on desktop or on mobile devices for regular or interstitial ads | |
12637 * respectively. APP and APP_INTERSTITIAL are for rendering in mobile apps. | |
12638 * IN_STREAM_VIDEO refers to rendering in in-stream video ads developed with | |
12639 * the VAST standard. | |
12640 * Possible string values are: | |
12641 * - "PLANNING_RENDERING_ENVIRONMENT_TYPE_APP" | |
12642 * - "PLANNING_RENDERING_ENVIRONMENT_TYPE_APP_INTERSTITIAL" | |
12643 * - "PLANNING_RENDERING_ENVIRONMENT_TYPE_IN_STREAM_VIDEO" | |
12644 * - "PLANNING_RENDERING_ENVIRONMENT_TYPE_WEB" | |
12645 * - "PLANNING_RENDERING_ENVIRONMENT_TYPE_WEB_INTERSTITIAL" | |
12646 */ | |
12647 core.String compatibility; | |
12648 /** Height of this ad slot. */ | |
12649 core.String height; | |
12650 /** | |
12651 * ID of the placement from an external platform that is linked to this ad | |
12652 * slot. | |
12653 */ | |
12654 core.String linkedPlacementId; | |
12655 /** Name of this ad slot. */ | |
12656 core.String name; | |
12657 /** | |
12658 * Payment source type of this ad slot. | |
12659 * Possible string values are: | |
12660 * - "PLANNING_PAYMENT_SOURCE_TYPE_AGENCY_PAID" | |
12661 * - "PLANNING_PAYMENT_SOURCE_TYPE_PUBLISHER_PAID" | |
12662 */ | |
12663 core.String paymentSourceType; | |
12664 /** Primary ad slot of a roadblock inventory item. */ | |
12665 core.bool primary; | |
12666 /** Width of this ad slot. */ | |
12667 core.String width; | |
12668 | |
12669 AdSlot(); | |
12670 | |
12671 AdSlot.fromJson(core.Map _json) { | |
12672 if (_json.containsKey("comment")) { | |
12673 comment = _json["comment"]; | |
12674 } | |
12675 if (_json.containsKey("compatibility")) { | |
12676 compatibility = _json["compatibility"]; | |
12677 } | |
12678 if (_json.containsKey("height")) { | |
12679 height = _json["height"]; | |
12680 } | |
12681 if (_json.containsKey("linkedPlacementId")) { | |
12682 linkedPlacementId = _json["linkedPlacementId"]; | |
12683 } | |
12684 if (_json.containsKey("name")) { | |
12685 name = _json["name"]; | |
12686 } | |
12687 if (_json.containsKey("paymentSourceType")) { | |
12688 paymentSourceType = _json["paymentSourceType"]; | |
12689 } | |
12690 if (_json.containsKey("primary")) { | |
12691 primary = _json["primary"]; | |
12692 } | |
12693 if (_json.containsKey("width")) { | |
12694 width = _json["width"]; | |
12695 } | |
12696 } | |
12697 | |
12698 core.Map toJson() { | |
12699 var _json = new core.Map(); | |
12700 if (comment != null) { | |
12701 _json["comment"] = comment; | |
12702 } | |
12703 if (compatibility != null) { | |
12704 _json["compatibility"] = compatibility; | |
12705 } | |
12706 if (height != null) { | |
12707 _json["height"] = height; | |
12708 } | |
12709 if (linkedPlacementId != null) { | |
12710 _json["linkedPlacementId"] = linkedPlacementId; | |
12711 } | |
12712 if (name != null) { | |
12713 _json["name"] = name; | |
12714 } | |
12715 if (paymentSourceType != null) { | |
12716 _json["paymentSourceType"] = paymentSourceType; | |
12717 } | |
12718 if (primary != null) { | |
12719 _json["primary"] = primary; | |
12720 } | |
12721 if (width != null) { | |
12722 _json["width"] = width; | |
12723 } | |
12724 return _json; | |
12725 } | |
12726 } | |
12727 | |
12728 /** Ad List Response */ | |
12729 class AdsListResponse { | |
12730 /** Ad collection. */ | |
12731 core.List<Ad> ads; | |
12732 /** | |
12733 * Identifies what kind of resource this is. Value: the fixed string | |
12734 * "dfareporting#adsListResponse". | |
12735 */ | |
12736 core.String kind; | |
12737 /** Pagination token to be used for the next list operation. */ | |
12738 core.String nextPageToken; | |
12739 | |
12740 AdsListResponse(); | |
12741 | |
12742 AdsListResponse.fromJson(core.Map _json) { | |
12743 if (_json.containsKey("ads")) { | |
12744 ads = _json["ads"].map((value) => new Ad.fromJson(value)).toList(); | |
12745 } | |
12746 if (_json.containsKey("kind")) { | |
12747 kind = _json["kind"]; | |
12748 } | |
12749 if (_json.containsKey("nextPageToken")) { | |
12750 nextPageToken = _json["nextPageToken"]; | |
12751 } | |
12752 } | |
12753 | |
12754 core.Map toJson() { | |
12755 var _json = new core.Map(); | |
12756 if (ads != null) { | |
12757 _json["ads"] = ads.map((value) => (value).toJson()).toList(); | |
12758 } | |
12759 if (kind != null) { | |
12760 _json["kind"] = kind; | |
12761 } | |
12762 if (nextPageToken != null) { | |
12763 _json["nextPageToken"] = nextPageToken; | |
12764 } | |
12765 return _json; | |
12766 } | |
12767 } | |
12768 | |
12769 /** Contains properties of a DCM advertiser. */ | |
12770 class Advertiser { | |
12771 /** | |
12772 * Account ID of this advertiser.This is a read-only field that can be left | |
12773 * blank. | |
12774 */ | |
12775 core.String accountId; | |
12776 /** | |
12777 * ID of the advertiser group this advertiser belongs to. You can group | |
12778 * advertisers for reporting purposes, allowing you to see aggregated | |
12779 * information for all advertisers in each group. | |
12780 */ | |
12781 core.String advertiserGroupId; | |
12782 /** | |
12783 * Suffix added to click-through URL of ad creative associations under this | |
12784 * advertiser. Must be less than 129 characters long. | |
12785 */ | |
12786 core.String clickThroughUrlSuffix; | |
12787 /** | |
12788 * ID of the click-through event tag to apply by default to the landing pages | |
12789 * of this advertiser's campaigns. | |
12790 */ | |
12791 core.String defaultClickThroughEventTagId; | |
12792 /** Default email address used in sender field for tag emails. */ | |
12793 core.String defaultEmail; | |
12794 /** | |
12795 * Floodlight configuration ID of this advertiser. The floodlight | |
12796 * configuration ID will be created automatically, so on insert this field | |
12797 * should be left blank. This field can be set to another advertiser's | |
12798 * floodlight configuration ID in order to share that advertiser's floodlight | |
12799 * configuration with this advertiser, so long as: | |
12800 * - This advertiser's original floodlight configuration is not already | |
12801 * associated with floodlight activities or floodlight activity groups. | |
12802 * - This advertiser's original floodlight configuration is not already shared | |
12803 * with another advertiser. | |
12804 */ | |
12805 core.String floodlightConfigurationId; | |
12806 /** | |
12807 * Dimension value for the ID of the floodlight configuration. This is a | |
12808 * read-only, auto-generated field. | |
12809 */ | |
12810 DimensionValue floodlightConfigurationIdDimensionValue; | |
12811 /** ID of this advertiser. This is a read-only, auto-generated field. */ | |
12812 core.String id; | |
12813 /** | |
12814 * Dimension value for the ID of this advertiser. This is a read-only, | |
12815 * auto-generated field. | |
12816 */ | |
12817 DimensionValue idDimensionValue; | |
12818 /** | |
12819 * Identifies what kind of resource this is. Value: the fixed string | |
12820 * "dfareporting#advertiser". | |
12821 */ | |
12822 core.String kind; | |
12823 /** | |
12824 * Name of this advertiser. This is a required field and must be less than 256 | |
12825 * characters long and unique among advertisers of the same account. | |
12826 */ | |
12827 core.String name; | |
12828 /** | |
12829 * Original floodlight configuration before any sharing occurred. Set the | |
12830 * floodlightConfigurationId of this advertiser to | |
12831 * originalFloodlightConfigurationId to unshare the advertiser's current | |
12832 * floodlight configuration. You cannot unshare an advertiser's floodlight | |
12833 * configuration if the shared configuration has activities associated with | |
12834 * any campaign or placement. | |
12835 */ | |
12836 core.String originalFloodlightConfigurationId; | |
12837 /** | |
12838 * Status of this advertiser. | |
12839 * Possible string values are: | |
12840 * - "APPROVED" | |
12841 * - "ON_HOLD" | |
12842 */ | |
12843 core.String status; | |
12844 /** | |
12845 * Subaccount ID of this advertiser.This is a read-only field that can be left | |
12846 * blank. | |
12847 */ | |
12848 core.String subaccountId; | |
12849 /** Suspension status of this advertiser. */ | |
12850 core.bool suspended; | |
12851 | |
12852 Advertiser(); | |
12853 | |
12854 Advertiser.fromJson(core.Map _json) { | |
12855 if (_json.containsKey("accountId")) { | |
12856 accountId = _json["accountId"]; | |
12857 } | |
12858 if (_json.containsKey("advertiserGroupId")) { | |
12859 advertiserGroupId = _json["advertiserGroupId"]; | |
12860 } | |
12861 if (_json.containsKey("clickThroughUrlSuffix")) { | |
12862 clickThroughUrlSuffix = _json["clickThroughUrlSuffix"]; | |
12863 } | |
12864 if (_json.containsKey("defaultClickThroughEventTagId")) { | |
12865 defaultClickThroughEventTagId = _json["defaultClickThroughEventTagId"]; | |
12866 } | |
12867 if (_json.containsKey("defaultEmail")) { | |
12868 defaultEmail = _json["defaultEmail"]; | |
12869 } | |
12870 if (_json.containsKey("floodlightConfigurationId")) { | |
12871 floodlightConfigurationId = _json["floodlightConfigurationId"]; | |
12872 } | |
12873 if (_json.containsKey("floodlightConfigurationIdDimensionValue")) { | |
12874 floodlightConfigurationIdDimensionValue = new DimensionValue.fromJson(_jso
n["floodlightConfigurationIdDimensionValue"]); | |
12875 } | |
12876 if (_json.containsKey("id")) { | |
12877 id = _json["id"]; | |
12878 } | |
12879 if (_json.containsKey("idDimensionValue")) { | |
12880 idDimensionValue = new DimensionValue.fromJson(_json["idDimensionValue"]); | |
12881 } | |
12882 if (_json.containsKey("kind")) { | |
12883 kind = _json["kind"]; | |
12884 } | |
12885 if (_json.containsKey("name")) { | |
12886 name = _json["name"]; | |
12887 } | |
12888 if (_json.containsKey("originalFloodlightConfigurationId")) { | |
12889 originalFloodlightConfigurationId = _json["originalFloodlightConfiguration
Id"]; | |
12890 } | |
12891 if (_json.containsKey("status")) { | |
12892 status = _json["status"]; | |
12893 } | |
12894 if (_json.containsKey("subaccountId")) { | |
12895 subaccountId = _json["subaccountId"]; | |
12896 } | |
12897 if (_json.containsKey("suspended")) { | |
12898 suspended = _json["suspended"]; | |
12899 } | |
12900 } | |
12901 | |
12902 core.Map toJson() { | |
12903 var _json = new core.Map(); | |
12904 if (accountId != null) { | |
12905 _json["accountId"] = accountId; | |
12906 } | |
12907 if (advertiserGroupId != null) { | |
12908 _json["advertiserGroupId"] = advertiserGroupId; | |
12909 } | |
12910 if (clickThroughUrlSuffix != null) { | |
12911 _json["clickThroughUrlSuffix"] = clickThroughUrlSuffix; | |
12912 } | |
12913 if (defaultClickThroughEventTagId != null) { | |
12914 _json["defaultClickThroughEventTagId"] = defaultClickThroughEventTagId; | |
12915 } | |
12916 if (defaultEmail != null) { | |
12917 _json["defaultEmail"] = defaultEmail; | |
12918 } | |
12919 if (floodlightConfigurationId != null) { | |
12920 _json["floodlightConfigurationId"] = floodlightConfigurationId; | |
12921 } | |
12922 if (floodlightConfigurationIdDimensionValue != null) { | |
12923 _json["floodlightConfigurationIdDimensionValue"] = (floodlightConfiguratio
nIdDimensionValue).toJson(); | |
12924 } | |
12925 if (id != null) { | |
12926 _json["id"] = id; | |
12927 } | |
12928 if (idDimensionValue != null) { | |
12929 _json["idDimensionValue"] = (idDimensionValue).toJson(); | |
12930 } | |
12931 if (kind != null) { | |
12932 _json["kind"] = kind; | |
12933 } | |
12934 if (name != null) { | |
12935 _json["name"] = name; | |
12936 } | |
12937 if (originalFloodlightConfigurationId != null) { | |
12938 _json["originalFloodlightConfigurationId"] = originalFloodlightConfigurati
onId; | |
12939 } | |
12940 if (status != null) { | |
12941 _json["status"] = status; | |
12942 } | |
12943 if (subaccountId != null) { | |
12944 _json["subaccountId"] = subaccountId; | |
12945 } | |
12946 if (suspended != null) { | |
12947 _json["suspended"] = suspended; | |
12948 } | |
12949 return _json; | |
12950 } | |
12951 } | |
12952 | |
12953 /** | |
12954 * Groups advertisers together so that reports can be generated for the entire | |
12955 * group at once. | |
12956 */ | |
12957 class AdvertiserGroup { | |
12958 /** | |
12959 * Account ID of this advertiser group. This is a read-only field that can be | |
12960 * left blank. | |
12961 */ | |
12962 core.String accountId; | |
12963 /** | |
12964 * ID of this advertiser group. This is a read-only, auto-generated field. | |
12965 */ | |
12966 core.String id; | |
12967 /** | |
12968 * Identifies what kind of resource this is. Value: the fixed string | |
12969 * "dfareporting#advertiserGroup". | |
12970 */ | |
12971 core.String kind; | |
12972 /** | |
12973 * Name of this advertiser group. This is a required field and must be less | |
12974 * than 256 characters long and unique among advertiser groups of the same | |
12975 * account. | |
12976 */ | |
12977 core.String name; | |
12978 | |
12979 AdvertiserGroup(); | |
12980 | |
12981 AdvertiserGroup.fromJson(core.Map _json) { | |
12982 if (_json.containsKey("accountId")) { | |
12983 accountId = _json["accountId"]; | |
12984 } | |
12985 if (_json.containsKey("id")) { | |
12986 id = _json["id"]; | |
12987 } | |
12988 if (_json.containsKey("kind")) { | |
12989 kind = _json["kind"]; | |
12990 } | |
12991 if (_json.containsKey("name")) { | |
12992 name = _json["name"]; | |
12993 } | |
12994 } | |
12995 | |
12996 core.Map toJson() { | |
12997 var _json = new core.Map(); | |
12998 if (accountId != null) { | |
12999 _json["accountId"] = accountId; | |
13000 } | |
13001 if (id != null) { | |
13002 _json["id"] = id; | |
13003 } | |
13004 if (kind != null) { | |
13005 _json["kind"] = kind; | |
13006 } | |
13007 if (name != null) { | |
13008 _json["name"] = name; | |
13009 } | |
13010 return _json; | |
13011 } | |
13012 } | |
13013 | |
13014 /** Advertiser Group List Response */ | |
13015 class AdvertiserGroupsListResponse { | |
13016 /** Advertiser group collection. */ | |
13017 core.List<AdvertiserGroup> advertiserGroups; | |
13018 /** | |
13019 * Identifies what kind of resource this is. Value: the fixed string | |
13020 * "dfareporting#advertiserGroupsListResponse". | |
13021 */ | |
13022 core.String kind; | |
13023 /** Pagination token to be used for the next list operation. */ | |
13024 core.String nextPageToken; | |
13025 | |
13026 AdvertiserGroupsListResponse(); | |
13027 | |
13028 AdvertiserGroupsListResponse.fromJson(core.Map _json) { | |
13029 if (_json.containsKey("advertiserGroups")) { | |
13030 advertiserGroups = _json["advertiserGroups"].map((value) => new Advertiser
Group.fromJson(value)).toList(); | |
13031 } | |
13032 if (_json.containsKey("kind")) { | |
13033 kind = _json["kind"]; | |
13034 } | |
13035 if (_json.containsKey("nextPageToken")) { | |
13036 nextPageToken = _json["nextPageToken"]; | |
13037 } | |
13038 } | |
13039 | |
13040 core.Map toJson() { | |
13041 var _json = new core.Map(); | |
13042 if (advertiserGroups != null) { | |
13043 _json["advertiserGroups"] = advertiserGroups.map((value) => (value).toJson
()).toList(); | |
13044 } | |
13045 if (kind != null) { | |
13046 _json["kind"] = kind; | |
13047 } | |
13048 if (nextPageToken != null) { | |
13049 _json["nextPageToken"] = nextPageToken; | |
13050 } | |
13051 return _json; | |
13052 } | |
13053 } | |
13054 | |
13055 /** Advertiser List Response */ | |
13056 class AdvertisersListResponse { | |
13057 /** Advertiser collection. */ | |
13058 core.List<Advertiser> advertisers; | |
13059 /** | |
13060 * Identifies what kind of resource this is. Value: the fixed string | |
13061 * "dfareporting#advertisersListResponse". | |
13062 */ | |
13063 core.String kind; | |
13064 /** Pagination token to be used for the next list operation. */ | |
13065 core.String nextPageToken; | |
13066 | |
13067 AdvertisersListResponse(); | |
13068 | |
13069 AdvertisersListResponse.fromJson(core.Map _json) { | |
13070 if (_json.containsKey("advertisers")) { | |
13071 advertisers = _json["advertisers"].map((value) => new Advertiser.fromJson(
value)).toList(); | |
13072 } | |
13073 if (_json.containsKey("kind")) { | |
13074 kind = _json["kind"]; | |
13075 } | |
13076 if (_json.containsKey("nextPageToken")) { | |
13077 nextPageToken = _json["nextPageToken"]; | |
13078 } | |
13079 } | |
13080 | |
13081 core.Map toJson() { | |
13082 var _json = new core.Map(); | |
13083 if (advertisers != null) { | |
13084 _json["advertisers"] = advertisers.map((value) => (value).toJson()).toList
(); | |
13085 } | |
13086 if (kind != null) { | |
13087 _json["kind"] = kind; | |
13088 } | |
13089 if (nextPageToken != null) { | |
13090 _json["nextPageToken"] = nextPageToken; | |
13091 } | |
13092 return _json; | |
13093 } | |
13094 } | |
13095 | |
13096 /** Audience Segment. */ | |
13097 class AudienceSegment { | |
13098 /** | |
13099 * Weight allocated to this segment. Must be between 1 and 1000. The weight | |
13100 * assigned will be understood in proportion to the weights assigned to other | |
13101 * segments in the same segment group. | |
13102 */ | |
13103 core.int allocation; | |
13104 /** | |
13105 * ID of this audience segment. This is a read-only, auto-generated field. | |
13106 */ | |
13107 core.String id; | |
13108 /** | |
13109 * Name of this audience segment. This is a required field and must be less | |
13110 * than 65 characters long. | |
13111 */ | |
13112 core.String name; | |
13113 | |
13114 AudienceSegment(); | |
13115 | |
13116 AudienceSegment.fromJson(core.Map _json) { | |
13117 if (_json.containsKey("allocation")) { | |
13118 allocation = _json["allocation"]; | |
13119 } | |
13120 if (_json.containsKey("id")) { | |
13121 id = _json["id"]; | |
13122 } | |
13123 if (_json.containsKey("name")) { | |
13124 name = _json["name"]; | |
13125 } | |
13126 } | |
13127 | |
13128 core.Map toJson() { | |
13129 var _json = new core.Map(); | |
13130 if (allocation != null) { | |
13131 _json["allocation"] = allocation; | |
13132 } | |
13133 if (id != null) { | |
13134 _json["id"] = id; | |
13135 } | |
13136 if (name != null) { | |
13137 _json["name"] = name; | |
13138 } | |
13139 return _json; | |
13140 } | |
13141 } | |
13142 | |
13143 /** Audience Segment Group. */ | |
13144 class AudienceSegmentGroup { | |
13145 /** | |
13146 * Audience segments assigned to this group. The number of segments must be | |
13147 * between 2 and 100. | |
13148 */ | |
13149 core.List<AudienceSegment> audienceSegments; | |
13150 /** | |
13151 * ID of this audience segment group. This is a read-only, auto-generated | |
13152 * field. | |
13153 */ | |
13154 core.String id; | |
13155 /** | |
13156 * Name of this audience segment group. This is a required field and must be | |
13157 * less than 65 characters long. | |
13158 */ | |
13159 core.String name; | |
13160 | |
13161 AudienceSegmentGroup(); | |
13162 | |
13163 AudienceSegmentGroup.fromJson(core.Map _json) { | |
13164 if (_json.containsKey("audienceSegments")) { | |
13165 audienceSegments = _json["audienceSegments"].map((value) => new AudienceSe
gment.fromJson(value)).toList(); | |
13166 } | |
13167 if (_json.containsKey("id")) { | |
13168 id = _json["id"]; | |
13169 } | |
13170 if (_json.containsKey("name")) { | |
13171 name = _json["name"]; | |
13172 } | |
13173 } | |
13174 | |
13175 core.Map toJson() { | |
13176 var _json = new core.Map(); | |
13177 if (audienceSegments != null) { | |
13178 _json["audienceSegments"] = audienceSegments.map((value) => (value).toJson
()).toList(); | |
13179 } | |
13180 if (id != null) { | |
13181 _json["id"] = id; | |
13182 } | |
13183 if (name != null) { | |
13184 _json["name"] = name; | |
13185 } | |
13186 return _json; | |
13187 } | |
13188 } | |
13189 | |
13190 /** Contains information about a browser that can be targeted by ads. */ | |
13191 class Browser { | |
13192 /** | |
13193 * ID referring to this grouping of browser and version numbers. This is the | |
13194 * ID used for targeting. | |
13195 */ | |
13196 core.String browserVersionId; | |
13197 /** DART ID of this browser. This is the ID used when generating reports. */ | |
13198 core.String dartId; | |
13199 /** | |
13200 * Identifies what kind of resource this is. Value: the fixed string | |
13201 * "dfareporting#browser". | |
13202 */ | |
13203 core.String kind; | |
13204 /** | |
13205 * Major version number (leftmost number) of this browser. For example, for | |
13206 * Chrome 5.0.376.86 beta, this field should be set to 5. An asterisk (*) may | |
13207 * be used to target any version number, and a question mark (?) may be used | |
13208 * to target cases where the version number cannot be identified. For example, | |
13209 * Chrome *.* targets any version of Chrome: 1.2, 2.5, 3.5, and so on. Chrome | |
13210 * 3.* targets Chrome 3.1, 3.5, but not 4.0. Firefox ?.? targets cases where | |
13211 * the ad server knows the browser is Firefox but can't tell which version it | |
13212 * is. | |
13213 */ | |
13214 core.String majorVersion; | |
13215 /** | |
13216 * Minor version number (number after first dot on left) of this browser. For | |
13217 * example, for Chrome 5.0.375.86 beta, this field should be set to 0. An | |
13218 * asterisk (*) may be used to target any version number, and a question mark | |
13219 * (?) may be used to target cases where the version number cannot be | |
13220 * identified. For example, Chrome *.* targets any version of Chrome: 1.2, | |
13221 * 2.5, 3.5, and so on. Chrome 3.* targets Chrome 3.1, 3.5, but not 4.0. | |
13222 * Firefox ?.? targets cases where the ad server knows the browser is Firefox | |
13223 * but can't tell which version it is. | |
13224 */ | |
13225 core.String minorVersion; | |
13226 /** Name of this browser. */ | |
13227 core.String name; | |
13228 | |
13229 Browser(); | |
13230 | |
13231 Browser.fromJson(core.Map _json) { | |
13232 if (_json.containsKey("browserVersionId")) { | |
13233 browserVersionId = _json["browserVersionId"]; | |
13234 } | |
13235 if (_json.containsKey("dartId")) { | |
13236 dartId = _json["dartId"]; | |
13237 } | |
13238 if (_json.containsKey("kind")) { | |
13239 kind = _json["kind"]; | |
13240 } | |
13241 if (_json.containsKey("majorVersion")) { | |
13242 majorVersion = _json["majorVersion"]; | |
13243 } | |
13244 if (_json.containsKey("minorVersion")) { | |
13245 minorVersion = _json["minorVersion"]; | |
13246 } | |
13247 if (_json.containsKey("name")) { | |
13248 name = _json["name"]; | |
13249 } | |
13250 } | |
13251 | |
13252 core.Map toJson() { | |
13253 var _json = new core.Map(); | |
13254 if (browserVersionId != null) { | |
13255 _json["browserVersionId"] = browserVersionId; | |
13256 } | |
13257 if (dartId != null) { | |
13258 _json["dartId"] = dartId; | |
13259 } | |
13260 if (kind != null) { | |
13261 _json["kind"] = kind; | |
13262 } | |
13263 if (majorVersion != null) { | |
13264 _json["majorVersion"] = majorVersion; | |
13265 } | |
13266 if (minorVersion != null) { | |
13267 _json["minorVersion"] = minorVersion; | |
13268 } | |
13269 if (name != null) { | |
13270 _json["name"] = name; | |
13271 } | |
13272 return _json; | |
13273 } | |
13274 } | |
13275 | |
13276 /** Browser List Response */ | |
13277 class BrowsersListResponse { | |
13278 /** Browser collection. */ | |
13279 core.List<Browser> browsers; | |
13280 /** | |
13281 * Identifies what kind of resource this is. Value: the fixed string | |
13282 * "dfareporting#browsersListResponse". | |
13283 */ | |
13284 core.String kind; | |
13285 | |
13286 BrowsersListResponse(); | |
13287 | |
13288 BrowsersListResponse.fromJson(core.Map _json) { | |
13289 if (_json.containsKey("browsers")) { | |
13290 browsers = _json["browsers"].map((value) => new Browser.fromJson(value)).t
oList(); | |
13291 } | |
13292 if (_json.containsKey("kind")) { | |
13293 kind = _json["kind"]; | |
13294 } | |
13295 } | |
13296 | |
13297 core.Map toJson() { | |
13298 var _json = new core.Map(); | |
13299 if (browsers != null) { | |
13300 _json["browsers"] = browsers.map((value) => (value).toJson()).toList(); | |
13301 } | |
13302 if (kind != null) { | |
13303 _json["kind"] = kind; | |
13304 } | |
13305 return _json; | |
13306 } | |
13307 } | |
13308 | |
13309 /** Contains properties of a DCM campaign. */ | |
13310 class Campaign { | |
13311 /** | |
13312 * Account ID of this campaign. This is a read-only field that can be left | |
13313 * blank. | |
13314 */ | |
13315 core.String accountId; | |
13316 /** Additional creative optimization configurations for the campaign. */ | |
13317 core.List<CreativeOptimizationConfiguration> additionalCreativeOptimizationCon
figurations; | |
13318 /** Advertiser group ID of the associated advertiser. */ | |
13319 core.String advertiserGroupId; | |
13320 /** Advertiser ID of this campaign. This is a required field. */ | |
13321 core.String advertiserId; | |
13322 /** | |
13323 * Dimension value for the advertiser ID of this campaign. This is a | |
13324 * read-only, auto-generated field. | |
13325 */ | |
13326 DimensionValue advertiserIdDimensionValue; | |
13327 /** Whether this campaign has been archived. */ | |
13328 core.bool archived; | |
13329 /** | |
13330 * Audience segment groups assigned to this campaign. Cannot have more than | |
13331 * 300 segment groups. | |
13332 */ | |
13333 core.List<AudienceSegmentGroup> audienceSegmentGroups; | |
13334 /** | |
13335 * Billing invoice code included in the DCM client billing invoices associated | |
13336 * with the campaign. | |
13337 */ | |
13338 core.String billingInvoiceCode; | |
13339 /** Click-through URL suffix override properties for this campaign. */ | |
13340 ClickThroughUrlSuffixProperties clickThroughUrlSuffixProperties; | |
13341 /** | |
13342 * Arbitrary comments about this campaign. Must be less than 256 characters | |
13343 * long. | |
13344 */ | |
13345 core.String comment; | |
13346 /** Whether comScore vCE reports are enabled for this campaign. */ | |
13347 core.bool comscoreVceEnabled; | |
13348 /** | |
13349 * Information about the creation of this campaign. This is a read-only field. | |
13350 */ | |
13351 LastModifiedInfo createInfo; | |
13352 /** List of creative group IDs that are assigned to the campaign. */ | |
13353 core.List<core.String> creativeGroupIds; | |
13354 /** Creative optimization configuration for the campaign. */ | |
13355 CreativeOptimizationConfiguration creativeOptimizationConfiguration; | |
13356 /** Click-through event tag ID override properties for this campaign. */ | |
13357 DefaultClickThroughEventTagProperties defaultClickThroughEventTagProperties; | |
13358 /** | |
13359 * Date on which the campaign will stop running. On insert, the end date must | |
13360 * be today or a future date. The end date must be later than or be the same | |
13361 * as the start date. If, for example, you set 6/25/2015 as both the start and | |
13362 * end dates, the effective campaign run date is just that day only, | |
13363 * 6/25/2015. The hours, minutes, and seconds of the end date should not be | |
13364 * set, as doing so will result in an error. This is a required field. | |
13365 */ | |
13366 core.DateTime endDate; | |
13367 /** | |
13368 * Overrides that can be used to activate or deactivate advertiser event tags. | |
13369 */ | |
13370 core.List<EventTagOverride> eventTagOverrides; | |
13371 /** External ID for this campaign. */ | |
13372 core.String externalId; | |
13373 /** ID of this campaign. This is a read-only auto-generated field. */ | |
13374 core.String id; | |
13375 /** | |
13376 * Dimension value for the ID of this campaign. This is a read-only, | |
13377 * auto-generated field. | |
13378 */ | |
13379 DimensionValue idDimensionValue; | |
13380 /** | |
13381 * Identifies what kind of resource this is. Value: the fixed string | |
13382 * "dfareporting#campaign". | |
13383 */ | |
13384 core.String kind; | |
13385 /** | |
13386 * Information about the most recent modification of this campaign. This is a | |
13387 * read-only field. | |
13388 */ | |
13389 LastModifiedInfo lastModifiedInfo; | |
13390 /** Lookback window settings for the campaign. */ | |
13391 LookbackConfiguration lookbackConfiguration; | |
13392 /** | |
13393 * Name of this campaign. This is a required field and must be less than 256 | |
13394 * characters long and unique among campaigns of the same advertiser. | |
13395 */ | |
13396 core.String name; | |
13397 /** Whether Nielsen reports are enabled for this campaign. */ | |
13398 core.bool nielsenOcrEnabled; | |
13399 /** | |
13400 * Date on which the campaign starts running. The start date can be any date. | |
13401 * The hours, minutes, and seconds of the start date should not be set, as | |
13402 * doing so will result in an error. This is a required field. | |
13403 */ | |
13404 core.DateTime startDate; | |
13405 /** | |
13406 * Subaccount ID of this campaign. This is a read-only field that can be left | |
13407 * blank. | |
13408 */ | |
13409 core.String subaccountId; | |
13410 /** Campaign trafficker contact emails. */ | |
13411 core.List<core.String> traffickerEmails; | |
13412 | |
13413 Campaign(); | |
13414 | |
13415 Campaign.fromJson(core.Map _json) { | |
13416 if (_json.containsKey("accountId")) { | |
13417 accountId = _json["accountId"]; | |
13418 } | |
13419 if (_json.containsKey("additionalCreativeOptimizationConfigurations")) { | |
13420 additionalCreativeOptimizationConfigurations = _json["additionalCreativeOp
timizationConfigurations"].map((value) => new CreativeOptimizationConfiguration.
fromJson(value)).toList(); | |
13421 } | |
13422 if (_json.containsKey("advertiserGroupId")) { | |
13423 advertiserGroupId = _json["advertiserGroupId"]; | |
13424 } | |
13425 if (_json.containsKey("advertiserId")) { | |
13426 advertiserId = _json["advertiserId"]; | |
13427 } | |
13428 if (_json.containsKey("advertiserIdDimensionValue")) { | |
13429 advertiserIdDimensionValue = new DimensionValue.fromJson(_json["advertiser
IdDimensionValue"]); | |
13430 } | |
13431 if (_json.containsKey("archived")) { | |
13432 archived = _json["archived"]; | |
13433 } | |
13434 if (_json.containsKey("audienceSegmentGroups")) { | |
13435 audienceSegmentGroups = _json["audienceSegmentGroups"].map((value) => new
AudienceSegmentGroup.fromJson(value)).toList(); | |
13436 } | |
13437 if (_json.containsKey("billingInvoiceCode")) { | |
13438 billingInvoiceCode = _json["billingInvoiceCode"]; | |
13439 } | |
13440 if (_json.containsKey("clickThroughUrlSuffixProperties")) { | |
13441 clickThroughUrlSuffixProperties = new ClickThroughUrlSuffixProperties.from
Json(_json["clickThroughUrlSuffixProperties"]); | |
13442 } | |
13443 if (_json.containsKey("comment")) { | |
13444 comment = _json["comment"]; | |
13445 } | |
13446 if (_json.containsKey("comscoreVceEnabled")) { | |
13447 comscoreVceEnabled = _json["comscoreVceEnabled"]; | |
13448 } | |
13449 if (_json.containsKey("createInfo")) { | |
13450 createInfo = new LastModifiedInfo.fromJson(_json["createInfo"]); | |
13451 } | |
13452 if (_json.containsKey("creativeGroupIds")) { | |
13453 creativeGroupIds = _json["creativeGroupIds"]; | |
13454 } | |
13455 if (_json.containsKey("creativeOptimizationConfiguration")) { | |
13456 creativeOptimizationConfiguration = new CreativeOptimizationConfiguration.
fromJson(_json["creativeOptimizationConfiguration"]); | |
13457 } | |
13458 if (_json.containsKey("defaultClickThroughEventTagProperties")) { | |
13459 defaultClickThroughEventTagProperties = new DefaultClickThroughEventTagPro
perties.fromJson(_json["defaultClickThroughEventTagProperties"]); | |
13460 } | |
13461 if (_json.containsKey("endDate")) { | |
13462 endDate = core.DateTime.parse(_json["endDate"]); | |
13463 } | |
13464 if (_json.containsKey("eventTagOverrides")) { | |
13465 eventTagOverrides = _json["eventTagOverrides"].map((value) => new EventTag
Override.fromJson(value)).toList(); | |
13466 } | |
13467 if (_json.containsKey("externalId")) { | |
13468 externalId = _json["externalId"]; | |
13469 } | |
13470 if (_json.containsKey("id")) { | |
13471 id = _json["id"]; | |
13472 } | |
13473 if (_json.containsKey("idDimensionValue")) { | |
13474 idDimensionValue = new DimensionValue.fromJson(_json["idDimensionValue"]); | |
13475 } | |
13476 if (_json.containsKey("kind")) { | |
13477 kind = _json["kind"]; | |
13478 } | |
13479 if (_json.containsKey("lastModifiedInfo")) { | |
13480 lastModifiedInfo = new LastModifiedInfo.fromJson(_json["lastModifiedInfo"]
); | |
13481 } | |
13482 if (_json.containsKey("lookbackConfiguration")) { | |
13483 lookbackConfiguration = new LookbackConfiguration.fromJson(_json["lookback
Configuration"]); | |
13484 } | |
13485 if (_json.containsKey("name")) { | |
13486 name = _json["name"]; | |
13487 } | |
13488 if (_json.containsKey("nielsenOcrEnabled")) { | |
13489 nielsenOcrEnabled = _json["nielsenOcrEnabled"]; | |
13490 } | |
13491 if (_json.containsKey("startDate")) { | |
13492 startDate = core.DateTime.parse(_json["startDate"]); | |
13493 } | |
13494 if (_json.containsKey("subaccountId")) { | |
13495 subaccountId = _json["subaccountId"]; | |
13496 } | |
13497 if (_json.containsKey("traffickerEmails")) { | |
13498 traffickerEmails = _json["traffickerEmails"]; | |
13499 } | |
13500 } | |
13501 | |
13502 core.Map toJson() { | |
13503 var _json = new core.Map(); | |
13504 if (accountId != null) { | |
13505 _json["accountId"] = accountId; | |
13506 } | |
13507 if (additionalCreativeOptimizationConfigurations != null) { | |
13508 _json["additionalCreativeOptimizationConfigurations"] = additionalCreative
OptimizationConfigurations.map((value) => (value).toJson()).toList(); | |
13509 } | |
13510 if (advertiserGroupId != null) { | |
13511 _json["advertiserGroupId"] = advertiserGroupId; | |
13512 } | |
13513 if (advertiserId != null) { | |
13514 _json["advertiserId"] = advertiserId; | |
13515 } | |
13516 if (advertiserIdDimensionValue != null) { | |
13517 _json["advertiserIdDimensionValue"] = (advertiserIdDimensionValue).toJson(
); | |
13518 } | |
13519 if (archived != null) { | |
13520 _json["archived"] = archived; | |
13521 } | |
13522 if (audienceSegmentGroups != null) { | |
13523 _json["audienceSegmentGroups"] = audienceSegmentGroups.map((value) => (val
ue).toJson()).toList(); | |
13524 } | |
13525 if (billingInvoiceCode != null) { | |
13526 _json["billingInvoiceCode"] = billingInvoiceCode; | |
13527 } | |
13528 if (clickThroughUrlSuffixProperties != null) { | |
13529 _json["clickThroughUrlSuffixProperties"] = (clickThroughUrlSuffixPropertie
s).toJson(); | |
13530 } | |
13531 if (comment != null) { | |
13532 _json["comment"] = comment; | |
13533 } | |
13534 if (comscoreVceEnabled != null) { | |
13535 _json["comscoreVceEnabled"] = comscoreVceEnabled; | |
13536 } | |
13537 if (createInfo != null) { | |
13538 _json["createInfo"] = (createInfo).toJson(); | |
13539 } | |
13540 if (creativeGroupIds != null) { | |
13541 _json["creativeGroupIds"] = creativeGroupIds; | |
13542 } | |
13543 if (creativeOptimizationConfiguration != null) { | |
13544 _json["creativeOptimizationConfiguration"] = (creativeOptimizationConfigur
ation).toJson(); | |
13545 } | |
13546 if (defaultClickThroughEventTagProperties != null) { | |
13547 _json["defaultClickThroughEventTagProperties"] = (defaultClickThroughEvent
TagProperties).toJson(); | |
13548 } | |
13549 if (endDate != null) { | |
13550 _json["endDate"] = "${(endDate).year.toString().padLeft(4, '0')}-${(endDat
e).month.toString().padLeft(2, '0')}-${(endDate).day.toString().padLeft(2, '0')}
"; | |
13551 } | |
13552 if (eventTagOverrides != null) { | |
13553 _json["eventTagOverrides"] = eventTagOverrides.map((value) => (value).toJs
on()).toList(); | |
13554 } | |
13555 if (externalId != null) { | |
13556 _json["externalId"] = externalId; | |
13557 } | |
13558 if (id != null) { | |
13559 _json["id"] = id; | |
13560 } | |
13561 if (idDimensionValue != null) { | |
13562 _json["idDimensionValue"] = (idDimensionValue).toJson(); | |
13563 } | |
13564 if (kind != null) { | |
13565 _json["kind"] = kind; | |
13566 } | |
13567 if (lastModifiedInfo != null) { | |
13568 _json["lastModifiedInfo"] = (lastModifiedInfo).toJson(); | |
13569 } | |
13570 if (lookbackConfiguration != null) { | |
13571 _json["lookbackConfiguration"] = (lookbackConfiguration).toJson(); | |
13572 } | |
13573 if (name != null) { | |
13574 _json["name"] = name; | |
13575 } | |
13576 if (nielsenOcrEnabled != null) { | |
13577 _json["nielsenOcrEnabled"] = nielsenOcrEnabled; | |
13578 } | |
13579 if (startDate != null) { | |
13580 _json["startDate"] = "${(startDate).year.toString().padLeft(4, '0')}-${(st
artDate).month.toString().padLeft(2, '0')}-${(startDate).day.toString().padLeft(
2, '0')}"; | |
13581 } | |
13582 if (subaccountId != null) { | |
13583 _json["subaccountId"] = subaccountId; | |
13584 } | |
13585 if (traffickerEmails != null) { | |
13586 _json["traffickerEmails"] = traffickerEmails; | |
13587 } | |
13588 return _json; | |
13589 } | |
13590 } | |
13591 | |
13592 /** Identifies a creative which has been associated with a given campaign. */ | |
13593 class CampaignCreativeAssociation { | |
13594 /** | |
13595 * ID of the creative associated with the campaign. This is a required field. | |
13596 */ | |
13597 core.String creativeId; | |
13598 /** | |
13599 * Identifies what kind of resource this is. Value: the fixed string | |
13600 * "dfareporting#campaignCreativeAssociation". | |
13601 */ | |
13602 core.String kind; | |
13603 | |
13604 CampaignCreativeAssociation(); | |
13605 | |
13606 CampaignCreativeAssociation.fromJson(core.Map _json) { | |
13607 if (_json.containsKey("creativeId")) { | |
13608 creativeId = _json["creativeId"]; | |
13609 } | |
13610 if (_json.containsKey("kind")) { | |
13611 kind = _json["kind"]; | |
13612 } | |
13613 } | |
13614 | |
13615 core.Map toJson() { | |
13616 var _json = new core.Map(); | |
13617 if (creativeId != null) { | |
13618 _json["creativeId"] = creativeId; | |
13619 } | |
13620 if (kind != null) { | |
13621 _json["kind"] = kind; | |
13622 } | |
13623 return _json; | |
13624 } | |
13625 } | |
13626 | |
13627 /** Campaign Creative Association List Response */ | |
13628 class CampaignCreativeAssociationsListResponse { | |
13629 /** Campaign creative association collection */ | |
13630 core.List<CampaignCreativeAssociation> campaignCreativeAssociations; | |
13631 /** | |
13632 * Identifies what kind of resource this is. Value: the fixed string | |
13633 * "dfareporting#campaignCreativeAssociationsListResponse". | |
13634 */ | |
13635 core.String kind; | |
13636 /** Pagination token to be used for the next list operation. */ | |
13637 core.String nextPageToken; | |
13638 | |
13639 CampaignCreativeAssociationsListResponse(); | |
13640 | |
13641 CampaignCreativeAssociationsListResponse.fromJson(core.Map _json) { | |
13642 if (_json.containsKey("campaignCreativeAssociations")) { | |
13643 campaignCreativeAssociations = _json["campaignCreativeAssociations"].map((
value) => new CampaignCreativeAssociation.fromJson(value)).toList(); | |
13644 } | |
13645 if (_json.containsKey("kind")) { | |
13646 kind = _json["kind"]; | |
13647 } | |
13648 if (_json.containsKey("nextPageToken")) { | |
13649 nextPageToken = _json["nextPageToken"]; | |
13650 } | |
13651 } | |
13652 | |
13653 core.Map toJson() { | |
13654 var _json = new core.Map(); | |
13655 if (campaignCreativeAssociations != null) { | |
13656 _json["campaignCreativeAssociations"] = campaignCreativeAssociations.map((
value) => (value).toJson()).toList(); | |
13657 } | |
13658 if (kind != null) { | |
13659 _json["kind"] = kind; | |
13660 } | |
13661 if (nextPageToken != null) { | |
13662 _json["nextPageToken"] = nextPageToken; | |
13663 } | |
13664 return _json; | |
13665 } | |
13666 } | |
13667 | |
13668 /** Campaign List Response */ | |
13669 class CampaignsListResponse { | |
13670 /** Campaign collection. */ | |
13671 core.List<Campaign> campaigns; | |
13672 /** | |
13673 * Identifies what kind of resource this is. Value: the fixed string | |
13674 * "dfareporting#campaignsListResponse". | |
13675 */ | |
13676 core.String kind; | |
13677 /** Pagination token to be used for the next list operation. */ | |
13678 core.String nextPageToken; | |
13679 | |
13680 CampaignsListResponse(); | |
13681 | |
13682 CampaignsListResponse.fromJson(core.Map _json) { | |
13683 if (_json.containsKey("campaigns")) { | |
13684 campaigns = _json["campaigns"].map((value) => new Campaign.fromJson(value)
).toList(); | |
13685 } | |
13686 if (_json.containsKey("kind")) { | |
13687 kind = _json["kind"]; | |
13688 } | |
13689 if (_json.containsKey("nextPageToken")) { | |
13690 nextPageToken = _json["nextPageToken"]; | |
13691 } | |
13692 } | |
13693 | |
13694 core.Map toJson() { | |
13695 var _json = new core.Map(); | |
13696 if (campaigns != null) { | |
13697 _json["campaigns"] = campaigns.map((value) => (value).toJson()).toList(); | |
13698 } | |
13699 if (kind != null) { | |
13700 _json["kind"] = kind; | |
13701 } | |
13702 if (nextPageToken != null) { | |
13703 _json["nextPageToken"] = nextPageToken; | |
13704 } | |
13705 return _json; | |
13706 } | |
13707 } | |
13708 | |
13709 /** Describes a change that a user has made to a resource. */ | |
13710 class ChangeLog { | |
13711 /** Account ID of the modified object. */ | |
13712 core.String accountId; | |
13713 /** Action which caused the change. */ | |
13714 core.String action; | |
13715 /** Time when the object was modified. */ | |
13716 core.DateTime changeTime; | |
13717 /** Field name of the object which changed. */ | |
13718 core.String fieldName; | |
13719 /** ID of this change log. */ | |
13720 core.String id; | |
13721 /** | |
13722 * Identifies what kind of resource this is. Value: the fixed string | |
13723 * "dfareporting#changeLog". | |
13724 */ | |
13725 core.String kind; | |
13726 /** New value of the object field. */ | |
13727 core.String newValue; | |
13728 /** | |
13729 * ID of the object of this change log. The object could be a campaign, | |
13730 * placement, ad, or other type. | |
13731 */ | |
13732 core.String objectId; | |
13733 /** Object type of the change log. */ | |
13734 core.String objectType; | |
13735 /** Old value of the object field. */ | |
13736 core.String oldValue; | |
13737 /** Subaccount ID of the modified object. */ | |
13738 core.String subaccountId; | |
13739 /** | |
13740 * Transaction ID of this change log. When a single API call results in many | |
13741 * changes, each change will have a separate ID in the change log but will | |
13742 * share the same transactionId. | |
13743 */ | |
13744 core.String transactionId; | |
13745 /** ID of the user who modified the object. */ | |
13746 core.String userProfileId; | |
13747 /** User profile name of the user who modified the object. */ | |
13748 core.String userProfileName; | |
13749 | |
13750 ChangeLog(); | |
13751 | |
13752 ChangeLog.fromJson(core.Map _json) { | |
13753 if (_json.containsKey("accountId")) { | |
13754 accountId = _json["accountId"]; | |
13755 } | |
13756 if (_json.containsKey("action")) { | |
13757 action = _json["action"]; | |
13758 } | |
13759 if (_json.containsKey("changeTime")) { | |
13760 changeTime = core.DateTime.parse(_json["changeTime"]); | |
13761 } | |
13762 if (_json.containsKey("fieldName")) { | |
13763 fieldName = _json["fieldName"]; | |
13764 } | |
13765 if (_json.containsKey("id")) { | |
13766 id = _json["id"]; | |
13767 } | |
13768 if (_json.containsKey("kind")) { | |
13769 kind = _json["kind"]; | |
13770 } | |
13771 if (_json.containsKey("newValue")) { | |
13772 newValue = _json["newValue"]; | |
13773 } | |
13774 if (_json.containsKey("objectId")) { | |
13775 objectId = _json["objectId"]; | |
13776 } | |
13777 if (_json.containsKey("objectType")) { | |
13778 objectType = _json["objectType"]; | |
13779 } | |
13780 if (_json.containsKey("oldValue")) { | |
13781 oldValue = _json["oldValue"]; | |
13782 } | |
13783 if (_json.containsKey("subaccountId")) { | |
13784 subaccountId = _json["subaccountId"]; | |
13785 } | |
13786 if (_json.containsKey("transactionId")) { | |
13787 transactionId = _json["transactionId"]; | |
13788 } | |
13789 if (_json.containsKey("userProfileId")) { | |
13790 userProfileId = _json["userProfileId"]; | |
13791 } | |
13792 if (_json.containsKey("userProfileName")) { | |
13793 userProfileName = _json["userProfileName"]; | |
13794 } | |
13795 } | |
13796 | |
13797 core.Map toJson() { | |
13798 var _json = new core.Map(); | |
13799 if (accountId != null) { | |
13800 _json["accountId"] = accountId; | |
13801 } | |
13802 if (action != null) { | |
13803 _json["action"] = action; | |
13804 } | |
13805 if (changeTime != null) { | |
13806 _json["changeTime"] = (changeTime).toIso8601String(); | |
13807 } | |
13808 if (fieldName != null) { | |
13809 _json["fieldName"] = fieldName; | |
13810 } | |
13811 if (id != null) { | |
13812 _json["id"] = id; | |
13813 } | |
13814 if (kind != null) { | |
13815 _json["kind"] = kind; | |
13816 } | |
13817 if (newValue != null) { | |
13818 _json["newValue"] = newValue; | |
13819 } | |
13820 if (objectId != null) { | |
13821 _json["objectId"] = objectId; | |
13822 } | |
13823 if (objectType != null) { | |
13824 _json["objectType"] = objectType; | |
13825 } | |
13826 if (oldValue != null) { | |
13827 _json["oldValue"] = oldValue; | |
13828 } | |
13829 if (subaccountId != null) { | |
13830 _json["subaccountId"] = subaccountId; | |
13831 } | |
13832 if (transactionId != null) { | |
13833 _json["transactionId"] = transactionId; | |
13834 } | |
13835 if (userProfileId != null) { | |
13836 _json["userProfileId"] = userProfileId; | |
13837 } | |
13838 if (userProfileName != null) { | |
13839 _json["userProfileName"] = userProfileName; | |
13840 } | |
13841 return _json; | |
13842 } | |
13843 } | |
13844 | |
13845 /** Change Log List Response */ | |
13846 class ChangeLogsListResponse { | |
13847 /** Change log collection. */ | |
13848 core.List<ChangeLog> changeLogs; | |
13849 /** | |
13850 * Identifies what kind of resource this is. Value: the fixed string | |
13851 * "dfareporting#changeLogsListResponse". | |
13852 */ | |
13853 core.String kind; | |
13854 /** Pagination token to be used for the next list operation. */ | |
13855 core.String nextPageToken; | |
13856 | |
13857 ChangeLogsListResponse(); | |
13858 | |
13859 ChangeLogsListResponse.fromJson(core.Map _json) { | |
13860 if (_json.containsKey("changeLogs")) { | |
13861 changeLogs = _json["changeLogs"].map((value) => new ChangeLog.fromJson(val
ue)).toList(); | |
13862 } | |
13863 if (_json.containsKey("kind")) { | |
13864 kind = _json["kind"]; | |
13865 } | |
13866 if (_json.containsKey("nextPageToken")) { | |
13867 nextPageToken = _json["nextPageToken"]; | |
13868 } | |
13869 } | |
13870 | |
13871 core.Map toJson() { | |
13872 var _json = new core.Map(); | |
13873 if (changeLogs != null) { | |
13874 _json["changeLogs"] = changeLogs.map((value) => (value).toJson()).toList()
; | |
13875 } | |
13876 if (kind != null) { | |
13877 _json["kind"] = kind; | |
13878 } | |
13879 if (nextPageToken != null) { | |
13880 _json["nextPageToken"] = nextPageToken; | |
13881 } | |
13882 return _json; | |
13883 } | |
13884 } | |
13885 | |
13886 /** City List Response */ | |
13887 class CitiesListResponse { | |
13888 /** City collection. */ | |
13889 core.List<City> cities; | |
13890 /** | |
13891 * Identifies what kind of resource this is. Value: the fixed string | |
13892 * "dfareporting#citiesListResponse". | |
13893 */ | |
13894 core.String kind; | |
13895 | |
13896 CitiesListResponse(); | |
13897 | |
13898 CitiesListResponse.fromJson(core.Map _json) { | |
13899 if (_json.containsKey("cities")) { | |
13900 cities = _json["cities"].map((value) => new City.fromJson(value)).toList()
; | |
13901 } | |
13902 if (_json.containsKey("kind")) { | |
13903 kind = _json["kind"]; | |
13904 } | |
13905 } | |
13906 | |
13907 core.Map toJson() { | |
13908 var _json = new core.Map(); | |
13909 if (cities != null) { | |
13910 _json["cities"] = cities.map((value) => (value).toJson()).toList(); | |
13911 } | |
13912 if (kind != null) { | |
13913 _json["kind"] = kind; | |
13914 } | |
13915 return _json; | |
13916 } | |
13917 } | |
13918 | |
13919 /** Contains information about a city that can be targeted by ads. */ | |
13920 class City { | |
13921 /** Country code of the country to which this city belongs. */ | |
13922 core.String countryCode; | |
13923 /** DART ID of the country to which this city belongs. */ | |
13924 core.String countryDartId; | |
13925 /** | |
13926 * DART ID of this city. This is the ID used for targeting and generating | |
13927 * reports. | |
13928 */ | |
13929 core.String dartId; | |
13930 /** | |
13931 * Identifies what kind of resource this is. Value: the fixed string | |
13932 * "dfareporting#city". | |
13933 */ | |
13934 core.String kind; | |
13935 /** | |
13936 * Metro region code of the metro region (DMA) to which this city belongs. | |
13937 */ | |
13938 core.String metroCode; | |
13939 /** ID of the metro region (DMA) to which this city belongs. */ | |
13940 core.String metroDmaId; | |
13941 /** Name of this city. */ | |
13942 core.String name; | |
13943 /** Region code of the region to which this city belongs. */ | |
13944 core.String regionCode; | |
13945 /** DART ID of the region to which this city belongs. */ | |
13946 core.String regionDartId; | |
13947 | |
13948 City(); | |
13949 | |
13950 City.fromJson(core.Map _json) { | |
13951 if (_json.containsKey("countryCode")) { | |
13952 countryCode = _json["countryCode"]; | |
13953 } | |
13954 if (_json.containsKey("countryDartId")) { | |
13955 countryDartId = _json["countryDartId"]; | |
13956 } | |
13957 if (_json.containsKey("dartId")) { | |
13958 dartId = _json["dartId"]; | |
13959 } | |
13960 if (_json.containsKey("kind")) { | |
13961 kind = _json["kind"]; | |
13962 } | |
13963 if (_json.containsKey("metroCode")) { | |
13964 metroCode = _json["metroCode"]; | |
13965 } | |
13966 if (_json.containsKey("metroDmaId")) { | |
13967 metroDmaId = _json["metroDmaId"]; | |
13968 } | |
13969 if (_json.containsKey("name")) { | |
13970 name = _json["name"]; | |
13971 } | |
13972 if (_json.containsKey("regionCode")) { | |
13973 regionCode = _json["regionCode"]; | |
13974 } | |
13975 if (_json.containsKey("regionDartId")) { | |
13976 regionDartId = _json["regionDartId"]; | |
13977 } | |
13978 } | |
13979 | |
13980 core.Map toJson() { | |
13981 var _json = new core.Map(); | |
13982 if (countryCode != null) { | |
13983 _json["countryCode"] = countryCode; | |
13984 } | |
13985 if (countryDartId != null) { | |
13986 _json["countryDartId"] = countryDartId; | |
13987 } | |
13988 if (dartId != null) { | |
13989 _json["dartId"] = dartId; | |
13990 } | |
13991 if (kind != null) { | |
13992 _json["kind"] = kind; | |
13993 } | |
13994 if (metroCode != null) { | |
13995 _json["metroCode"] = metroCode; | |
13996 } | |
13997 if (metroDmaId != null) { | |
13998 _json["metroDmaId"] = metroDmaId; | |
13999 } | |
14000 if (name != null) { | |
14001 _json["name"] = name; | |
14002 } | |
14003 if (regionCode != null) { | |
14004 _json["regionCode"] = regionCode; | |
14005 } | |
14006 if (regionDartId != null) { | |
14007 _json["regionDartId"] = regionDartId; | |
14008 } | |
14009 return _json; | |
14010 } | |
14011 } | |
14012 | |
14013 /** Creative Click Tag. */ | |
14014 class ClickTag { | |
14015 /** | |
14016 * Advertiser event name associated with the click tag. This field is used by | |
14017 * ENHANCED_IMAGE, and HTML5_BANNER creatives. Applicable to ENHANCED_BANNER | |
14018 * when the primary asset type is not HTML_IMAGE | |
14019 */ | |
14020 core.String eventName; | |
14021 /** | |
14022 * Parameter name for the specified click tag. For ENHANCED_IMAGE creative | |
14023 * assets, this field must match the value of the creative asset's | |
14024 * creativeAssetId.name field. | |
14025 */ | |
14026 core.String name; | |
14027 /** | |
14028 * Parameter value for the specified click tag. This field contains a | |
14029 * click-through url. | |
14030 */ | |
14031 core.String value; | |
14032 | |
14033 ClickTag(); | |
14034 | |
14035 ClickTag.fromJson(core.Map _json) { | |
14036 if (_json.containsKey("eventName")) { | |
14037 eventName = _json["eventName"]; | |
14038 } | |
14039 if (_json.containsKey("name")) { | |
14040 name = _json["name"]; | |
14041 } | |
14042 if (_json.containsKey("value")) { | |
14043 value = _json["value"]; | |
14044 } | |
14045 } | |
14046 | |
14047 core.Map toJson() { | |
14048 var _json = new core.Map(); | |
14049 if (eventName != null) { | |
14050 _json["eventName"] = eventName; | |
14051 } | |
14052 if (name != null) { | |
14053 _json["name"] = name; | |
14054 } | |
14055 if (value != null) { | |
14056 _json["value"] = value; | |
14057 } | |
14058 return _json; | |
14059 } | |
14060 } | |
14061 | |
14062 /** Click-through URL */ | |
14063 class ClickThroughUrl { | |
14064 /** | |
14065 * Read-only convenience field representing the actual URL that will be used | |
14066 * for this click-through. The URL is computed as follows: | |
14067 * - If defaultLandingPage is enabled then the campaign's default landing page | |
14068 * URL is assigned to this field. | |
14069 * - If defaultLandingPage is not enabled and a landingPageId is specified | |
14070 * then that landing page's URL is assigned to this field. | |
14071 * - If neither of the above cases apply, then the customClickThroughUrl is | |
14072 * assigned to this field. | |
14073 */ | |
14074 core.String computedClickThroughUrl; | |
14075 /** | |
14076 * Custom click-through URL. Applicable if the defaultLandingPage field is set | |
14077 * to false and the landingPageId field is left unset. | |
14078 */ | |
14079 core.String customClickThroughUrl; | |
14080 /** Whether the campaign default landing page is used. */ | |
14081 core.bool defaultLandingPage; | |
14082 /** | |
14083 * ID of the landing page for the click-through URL. Applicable if the | |
14084 * defaultLandingPage field is set to false. | |
14085 */ | |
14086 core.String landingPageId; | |
14087 | |
14088 ClickThroughUrl(); | |
14089 | |
14090 ClickThroughUrl.fromJson(core.Map _json) { | |
14091 if (_json.containsKey("computedClickThroughUrl")) { | |
14092 computedClickThroughUrl = _json["computedClickThroughUrl"]; | |
14093 } | |
14094 if (_json.containsKey("customClickThroughUrl")) { | |
14095 customClickThroughUrl = _json["customClickThroughUrl"]; | |
14096 } | |
14097 if (_json.containsKey("defaultLandingPage")) { | |
14098 defaultLandingPage = _json["defaultLandingPage"]; | |
14099 } | |
14100 if (_json.containsKey("landingPageId")) { | |
14101 landingPageId = _json["landingPageId"]; | |
14102 } | |
14103 } | |
14104 | |
14105 core.Map toJson() { | |
14106 var _json = new core.Map(); | |
14107 if (computedClickThroughUrl != null) { | |
14108 _json["computedClickThroughUrl"] = computedClickThroughUrl; | |
14109 } | |
14110 if (customClickThroughUrl != null) { | |
14111 _json["customClickThroughUrl"] = customClickThroughUrl; | |
14112 } | |
14113 if (defaultLandingPage != null) { | |
14114 _json["defaultLandingPage"] = defaultLandingPage; | |
14115 } | |
14116 if (landingPageId != null) { | |
14117 _json["landingPageId"] = landingPageId; | |
14118 } | |
14119 return _json; | |
14120 } | |
14121 } | |
14122 | |
14123 /** Click Through URL Suffix settings. */ | |
14124 class ClickThroughUrlSuffixProperties { | |
14125 /** | |
14126 * Click-through URL suffix to apply to all ads in this entity's scope. Must | |
14127 * be less than 128 characters long. | |
14128 */ | |
14129 core.String clickThroughUrlSuffix; | |
14130 /** | |
14131 * Whether this entity should override the inherited click-through URL suffix | |
14132 * with its own defined value. | |
14133 */ | |
14134 core.bool overrideInheritedSuffix; | |
14135 | |
14136 ClickThroughUrlSuffixProperties(); | |
14137 | |
14138 ClickThroughUrlSuffixProperties.fromJson(core.Map _json) { | |
14139 if (_json.containsKey("clickThroughUrlSuffix")) { | |
14140 clickThroughUrlSuffix = _json["clickThroughUrlSuffix"]; | |
14141 } | |
14142 if (_json.containsKey("overrideInheritedSuffix")) { | |
14143 overrideInheritedSuffix = _json["overrideInheritedSuffix"]; | |
14144 } | |
14145 } | |
14146 | |
14147 core.Map toJson() { | |
14148 var _json = new core.Map(); | |
14149 if (clickThroughUrlSuffix != null) { | |
14150 _json["clickThroughUrlSuffix"] = clickThroughUrlSuffix; | |
14151 } | |
14152 if (overrideInheritedSuffix != null) { | |
14153 _json["overrideInheritedSuffix"] = overrideInheritedSuffix; | |
14154 } | |
14155 return _json; | |
14156 } | |
14157 } | |
14158 | |
14159 /** Companion Click-through override. */ | |
14160 class CompanionClickThroughOverride { | |
14161 /** Click-through URL of this companion click-through override. */ | |
14162 ClickThroughUrl clickThroughUrl; | |
14163 /** ID of the creative for this companion click-through override. */ | |
14164 core.String creativeId; | |
14165 | |
14166 CompanionClickThroughOverride(); | |
14167 | |
14168 CompanionClickThroughOverride.fromJson(core.Map _json) { | |
14169 if (_json.containsKey("clickThroughUrl")) { | |
14170 clickThroughUrl = new ClickThroughUrl.fromJson(_json["clickThroughUrl"]); | |
14171 } | |
14172 if (_json.containsKey("creativeId")) { | |
14173 creativeId = _json["creativeId"]; | |
14174 } | |
14175 } | |
14176 | |
14177 core.Map toJson() { | |
14178 var _json = new core.Map(); | |
14179 if (clickThroughUrl != null) { | |
14180 _json["clickThroughUrl"] = (clickThroughUrl).toJson(); | |
14181 } | |
14182 if (creativeId != null) { | |
14183 _json["creativeId"] = creativeId; | |
14184 } | |
14185 return _json; | |
14186 } | |
14187 } | |
14188 | |
14189 /** Represents a response to the queryCompatibleFields method. */ | |
14190 class CompatibleFields { | |
14191 /** | |
14192 * Contains items that are compatible to be selected for a report of type | |
14193 * "CROSS_DIMENSION_REACH". | |
14194 */ | |
14195 CrossDimensionReachReportCompatibleFields crossDimensionReachReportCompatibleF
ields; | |
14196 /** | |
14197 * Contains items that are compatible to be selected for a report of type | |
14198 * "FLOODLIGHT". | |
14199 */ | |
14200 FloodlightReportCompatibleFields floodlightReportCompatibleFields; | |
14201 /** | |
14202 * The kind of resource this is, in this case dfareporting#compatibleFields. | |
14203 */ | |
14204 core.String kind; | |
14205 /** | |
14206 * Contains items that are compatible to be selected for a report of type | |
14207 * "PATH_TO_CONVERSION". | |
14208 */ | |
14209 PathToConversionReportCompatibleFields pathToConversionReportCompatibleFields; | |
14210 /** | |
14211 * Contains items that are compatible to be selected for a report of type | |
14212 * "REACH". | |
14213 */ | |
14214 ReachReportCompatibleFields reachReportCompatibleFields; | |
14215 /** | |
14216 * Contains items that are compatible to be selected for a report of type | |
14217 * "STANDARD". | |
14218 */ | |
14219 ReportCompatibleFields reportCompatibleFields; | |
14220 | |
14221 CompatibleFields(); | |
14222 | |
14223 CompatibleFields.fromJson(core.Map _json) { | |
14224 if (_json.containsKey("crossDimensionReachReportCompatibleFields")) { | |
14225 crossDimensionReachReportCompatibleFields = new CrossDimensionReachReportC
ompatibleFields.fromJson(_json["crossDimensionReachReportCompatibleFields"]); | |
14226 } | |
14227 if (_json.containsKey("floodlightReportCompatibleFields")) { | |
14228 floodlightReportCompatibleFields = new FloodlightReportCompatibleFields.fr
omJson(_json["floodlightReportCompatibleFields"]); | |
14229 } | |
14230 if (_json.containsKey("kind")) { | |
14231 kind = _json["kind"]; | |
14232 } | |
14233 if (_json.containsKey("pathToConversionReportCompatibleFields")) { | |
14234 pathToConversionReportCompatibleFields = new PathToConversionReportCompati
bleFields.fromJson(_json["pathToConversionReportCompatibleFields"]); | |
14235 } | |
14236 if (_json.containsKey("reachReportCompatibleFields")) { | |
14237 reachReportCompatibleFields = new ReachReportCompatibleFields.fromJson(_js
on["reachReportCompatibleFields"]); | |
14238 } | |
14239 if (_json.containsKey("reportCompatibleFields")) { | |
14240 reportCompatibleFields = new ReportCompatibleFields.fromJson(_json["report
CompatibleFields"]); | |
14241 } | |
14242 } | |
14243 | |
14244 core.Map toJson() { | |
14245 var _json = new core.Map(); | |
14246 if (crossDimensionReachReportCompatibleFields != null) { | |
14247 _json["crossDimensionReachReportCompatibleFields"] = (crossDimensionReachR
eportCompatibleFields).toJson(); | |
14248 } | |
14249 if (floodlightReportCompatibleFields != null) { | |
14250 _json["floodlightReportCompatibleFields"] = (floodlightReportCompatibleFie
lds).toJson(); | |
14251 } | |
14252 if (kind != null) { | |
14253 _json["kind"] = kind; | |
14254 } | |
14255 if (pathToConversionReportCompatibleFields != null) { | |
14256 _json["pathToConversionReportCompatibleFields"] = (pathToConversionReportC
ompatibleFields).toJson(); | |
14257 } | |
14258 if (reachReportCompatibleFields != null) { | |
14259 _json["reachReportCompatibleFields"] = (reachReportCompatibleFields).toJso
n(); | |
14260 } | |
14261 if (reportCompatibleFields != null) { | |
14262 _json["reportCompatibleFields"] = (reportCompatibleFields).toJson(); | |
14263 } | |
14264 return _json; | |
14265 } | |
14266 } | |
14267 | |
14268 /** | |
14269 * Contains information about an internet connection type that can be targeted | |
14270 * by ads. Clients can use the connection type to target mobile vs. broadband | |
14271 * users. | |
14272 */ | |
14273 class ConnectionType { | |
14274 /** ID of this connection type. */ | |
14275 core.String id; | |
14276 /** | |
14277 * Identifies what kind of resource this is. Value: the fixed string | |
14278 * "dfareporting#connectionType". | |
14279 */ | |
14280 core.String kind; | |
14281 /** Name of this connection type. */ | |
14282 core.String name; | |
14283 | |
14284 ConnectionType(); | |
14285 | |
14286 ConnectionType.fromJson(core.Map _json) { | |
14287 if (_json.containsKey("id")) { | |
14288 id = _json["id"]; | |
14289 } | |
14290 if (_json.containsKey("kind")) { | |
14291 kind = _json["kind"]; | |
14292 } | |
14293 if (_json.containsKey("name")) { | |
14294 name = _json["name"]; | |
14295 } | |
14296 } | |
14297 | |
14298 core.Map toJson() { | |
14299 var _json = new core.Map(); | |
14300 if (id != null) { | |
14301 _json["id"] = id; | |
14302 } | |
14303 if (kind != null) { | |
14304 _json["kind"] = kind; | |
14305 } | |
14306 if (name != null) { | |
14307 _json["name"] = name; | |
14308 } | |
14309 return _json; | |
14310 } | |
14311 } | |
14312 | |
14313 /** Connection Type List Response */ | |
14314 class ConnectionTypesListResponse { | |
14315 /** Collection of connection types such as broadband and mobile. */ | |
14316 core.List<ConnectionType> connectionTypes; | |
14317 /** | |
14318 * Identifies what kind of resource this is. Value: the fixed string | |
14319 * "dfareporting#connectionTypesListResponse". | |
14320 */ | |
14321 core.String kind; | |
14322 | |
14323 ConnectionTypesListResponse(); | |
14324 | |
14325 ConnectionTypesListResponse.fromJson(core.Map _json) { | |
14326 if (_json.containsKey("connectionTypes")) { | |
14327 connectionTypes = _json["connectionTypes"].map((value) => new ConnectionTy
pe.fromJson(value)).toList(); | |
14328 } | |
14329 if (_json.containsKey("kind")) { | |
14330 kind = _json["kind"]; | |
14331 } | |
14332 } | |
14333 | |
14334 core.Map toJson() { | |
14335 var _json = new core.Map(); | |
14336 if (connectionTypes != null) { | |
14337 _json["connectionTypes"] = connectionTypes.map((value) => (value).toJson()
).toList(); | |
14338 } | |
14339 if (kind != null) { | |
14340 _json["kind"] = kind; | |
14341 } | |
14342 return _json; | |
14343 } | |
14344 } | |
14345 | |
14346 /** Content Category List Response */ | |
14347 class ContentCategoriesListResponse { | |
14348 /** Content category collection. */ | |
14349 core.List<ContentCategory> contentCategories; | |
14350 /** | |
14351 * Identifies what kind of resource this is. Value: the fixed string | |
14352 * "dfareporting#contentCategoriesListResponse". | |
14353 */ | |
14354 core.String kind; | |
14355 /** Pagination token to be used for the next list operation. */ | |
14356 core.String nextPageToken; | |
14357 | |
14358 ContentCategoriesListResponse(); | |
14359 | |
14360 ContentCategoriesListResponse.fromJson(core.Map _json) { | |
14361 if (_json.containsKey("contentCategories")) { | |
14362 contentCategories = _json["contentCategories"].map((value) => new ContentC
ategory.fromJson(value)).toList(); | |
14363 } | |
14364 if (_json.containsKey("kind")) { | |
14365 kind = _json["kind"]; | |
14366 } | |
14367 if (_json.containsKey("nextPageToken")) { | |
14368 nextPageToken = _json["nextPageToken"]; | |
14369 } | |
14370 } | |
14371 | |
14372 core.Map toJson() { | |
14373 var _json = new core.Map(); | |
14374 if (contentCategories != null) { | |
14375 _json["contentCategories"] = contentCategories.map((value) => (value).toJs
on()).toList(); | |
14376 } | |
14377 if (kind != null) { | |
14378 _json["kind"] = kind; | |
14379 } | |
14380 if (nextPageToken != null) { | |
14381 _json["nextPageToken"] = nextPageToken; | |
14382 } | |
14383 return _json; | |
14384 } | |
14385 } | |
14386 | |
14387 /** | |
14388 * Organizes placements according to the contents of their associated webpages. | |
14389 */ | |
14390 class ContentCategory { | |
14391 /** | |
14392 * Account ID of this content category. This is a read-only field that can be | |
14393 * left blank. | |
14394 */ | |
14395 core.String accountId; | |
14396 /** | |
14397 * ID of this content category. This is a read-only, auto-generated field. | |
14398 */ | |
14399 core.String id; | |
14400 /** | |
14401 * Identifies what kind of resource this is. Value: the fixed string | |
14402 * "dfareporting#contentCategory". | |
14403 */ | |
14404 core.String kind; | |
14405 /** | |
14406 * Name of this content category. This is a required field and must be less | |
14407 * than 256 characters long and unique among content categories of the same | |
14408 * account. | |
14409 */ | |
14410 core.String name; | |
14411 | |
14412 ContentCategory(); | |
14413 | |
14414 ContentCategory.fromJson(core.Map _json) { | |
14415 if (_json.containsKey("accountId")) { | |
14416 accountId = _json["accountId"]; | |
14417 } | |
14418 if (_json.containsKey("id")) { | |
14419 id = _json["id"]; | |
14420 } | |
14421 if (_json.containsKey("kind")) { | |
14422 kind = _json["kind"]; | |
14423 } | |
14424 if (_json.containsKey("name")) { | |
14425 name = _json["name"]; | |
14426 } | |
14427 } | |
14428 | |
14429 core.Map toJson() { | |
14430 var _json = new core.Map(); | |
14431 if (accountId != null) { | |
14432 _json["accountId"] = accountId; | |
14433 } | |
14434 if (id != null) { | |
14435 _json["id"] = id; | |
14436 } | |
14437 if (kind != null) { | |
14438 _json["kind"] = kind; | |
14439 } | |
14440 if (name != null) { | |
14441 _json["name"] = name; | |
14442 } | |
14443 return _json; | |
14444 } | |
14445 } | |
14446 | |
14447 /** Country List Response */ | |
14448 class CountriesListResponse { | |
14449 /** Country collection. */ | |
14450 core.List<Country> countries; | |
14451 /** | |
14452 * Identifies what kind of resource this is. Value: the fixed string | |
14453 * "dfareporting#countriesListResponse". | |
14454 */ | |
14455 core.String kind; | |
14456 | |
14457 CountriesListResponse(); | |
14458 | |
14459 CountriesListResponse.fromJson(core.Map _json) { | |
14460 if (_json.containsKey("countries")) { | |
14461 countries = _json["countries"].map((value) => new Country.fromJson(value))
.toList(); | |
14462 } | |
14463 if (_json.containsKey("kind")) { | |
14464 kind = _json["kind"]; | |
14465 } | |
14466 } | |
14467 | |
14468 core.Map toJson() { | |
14469 var _json = new core.Map(); | |
14470 if (countries != null) { | |
14471 _json["countries"] = countries.map((value) => (value).toJson()).toList(); | |
14472 } | |
14473 if (kind != null) { | |
14474 _json["kind"] = kind; | |
14475 } | |
14476 return _json; | |
14477 } | |
14478 } | |
14479 | |
14480 /** Contains information about a country that can be targeted by ads. */ | |
14481 class Country { | |
14482 /** Country code. */ | |
14483 core.String countryCode; | |
14484 /** | |
14485 * DART ID of this country. This is the ID used for targeting and generating | |
14486 * reports. | |
14487 */ | |
14488 core.String dartId; | |
14489 /** | |
14490 * Identifies what kind of resource this is. Value: the fixed string | |
14491 * "dfareporting#country". | |
14492 */ | |
14493 core.String kind; | |
14494 /** Name of this country. */ | |
14495 core.String name; | |
14496 /** Whether ad serving supports secure servers in this country. */ | |
14497 core.bool sslEnabled; | |
14498 | |
14499 Country(); | |
14500 | |
14501 Country.fromJson(core.Map _json) { | |
14502 if (_json.containsKey("countryCode")) { | |
14503 countryCode = _json["countryCode"]; | |
14504 } | |
14505 if (_json.containsKey("dartId")) { | |
14506 dartId = _json["dartId"]; | |
14507 } | |
14508 if (_json.containsKey("kind")) { | |
14509 kind = _json["kind"]; | |
14510 } | |
14511 if (_json.containsKey("name")) { | |
14512 name = _json["name"]; | |
14513 } | |
14514 if (_json.containsKey("sslEnabled")) { | |
14515 sslEnabled = _json["sslEnabled"]; | |
14516 } | |
14517 } | |
14518 | |
14519 core.Map toJson() { | |
14520 var _json = new core.Map(); | |
14521 if (countryCode != null) { | |
14522 _json["countryCode"] = countryCode; | |
14523 } | |
14524 if (dartId != null) { | |
14525 _json["dartId"] = dartId; | |
14526 } | |
14527 if (kind != null) { | |
14528 _json["kind"] = kind; | |
14529 } | |
14530 if (name != null) { | |
14531 _json["name"] = name; | |
14532 } | |
14533 if (sslEnabled != null) { | |
14534 _json["sslEnabled"] = sslEnabled; | |
14535 } | |
14536 return _json; | |
14537 } | |
14538 } | |
14539 | |
14540 /** Contains properties of a Creative. */ | |
14541 class Creative { | |
14542 /** | |
14543 * Account ID of this creative. This field, if left unset, will be | |
14544 * auto-generated for both insert and update operations. Applicable to all | |
14545 * creative types. | |
14546 */ | |
14547 core.String accountId; | |
14548 /** Whether the creative is active. Applicable to all creative types. */ | |
14549 core.bool active; | |
14550 /** | |
14551 * Ad parameters user for VPAID creative. This is a read-only field. | |
14552 * Applicable to the following creative types: all VPAID. | |
14553 */ | |
14554 core.String adParameters; | |
14555 /** | |
14556 * Keywords for a Rich Media creative. Keywords let you customize the creative | |
14557 * settings of a Rich Media ad running on your site without having to contact | |
14558 * the advertiser. You can use keywords to dynamically change the look or | |
14559 * functionality of a creative. Applicable to the following creative types: | |
14560 * all RICH_MEDIA, and all VPAID. | |
14561 */ | |
14562 core.List<core.String> adTagKeys; | |
14563 /** | |
14564 * Advertiser ID of this creative. This is a required field. Applicable to all | |
14565 * creative types. | |
14566 */ | |
14567 core.String advertiserId; | |
14568 /** | |
14569 * Whether script access is allowed for this creative. This is a read-only and | |
14570 * deprecated field which will automatically be set to true on update. | |
14571 * Applicable to the following creative types: FLASH_INPAGE. | |
14572 */ | |
14573 core.bool allowScriptAccess; | |
14574 /** Whether the creative is archived. Applicable to all creative types. */ | |
14575 core.bool archived; | |
14576 /** | |
14577 * Type of artwork used for the creative. This is a read-only field. | |
14578 * Applicable to the following creative types: all RICH_MEDIA, and all VPAID. | |
14579 * Possible string values are: | |
14580 * - "ARTWORK_TYPE_FLASH" | |
14581 * - "ARTWORK_TYPE_HTML5" | |
14582 * - "ARTWORK_TYPE_IMAGE" | |
14583 * - "ARTWORK_TYPE_MIXED" | |
14584 */ | |
14585 core.String artworkType; | |
14586 /** | |
14587 * Source application where creative was authored. Presently, only DBM | |
14588 * authored creatives will have this field set. Applicable to all creative | |
14589 * types. | |
14590 * Possible string values are: | |
14591 * - "CREATIVE_AUTHORING_SOURCE_DBM" | |
14592 * - "CREATIVE_AUTHORING_SOURCE_DCM" | |
14593 * - "CREATIVE_AUTHORING_SOURCE_STUDIO" | |
14594 */ | |
14595 core.String authoringSource; | |
14596 /** | |
14597 * Authoring tool for HTML5 banner creatives. This is a read-only field. | |
14598 * Applicable to the following creative types: HTML5_BANNER. | |
14599 * Possible string values are: | |
14600 * - "NINJA" | |
14601 * - "SWIFFY" | |
14602 */ | |
14603 core.String authoringTool; | |
14604 /** | |
14605 * Whether images are automatically advanced for enhanced image creatives. | |
14606 * Applicable to the following creative types: ENHANCED_IMAGE. | |
14607 */ | |
14608 core.bool autoAdvanceImages; | |
14609 /** | |
14610 * The 6-character HTML color code, beginning with #, for the background of | |
14611 * the window area where the Flash file is displayed. Default is white. | |
14612 * Applicable to the following creative types: FLASH_INPAGE. | |
14613 */ | |
14614 core.String backgroundColor; | |
14615 /** | |
14616 * Click-through URL for backup image. Applicable to the following creative | |
14617 * types: FLASH_INPAGE, and HTML5_BANNER. Applicable to ENHANCED_BANNER when | |
14618 * the primary asset type is not HTML_IMAGE. | |
14619 */ | |
14620 core.String backupImageClickThroughUrl; | |
14621 /** | |
14622 * List of feature dependencies that will cause a backup image to be served if | |
14623 * the browser that serves the ad does not support them. Feature dependencies | |
14624 * are features that a browser must be able to support in order to render your | |
14625 * HTML5 creative asset correctly. This field is initially auto-generated to | |
14626 * contain all features detected by DCM for all the assets of this creative | |
14627 * and can then be modified by the client. To reset this field, copy over all | |
14628 * the creativeAssets' detected features. Applicable to the following creative | |
14629 * types: HTML5_BANNER. Applicable to ENHANCED_BANNER when the primary asset | |
14630 * is not HTML_IMAGE. | |
14631 */ | |
14632 core.List<core.String> backupImageFeatures; | |
14633 /** | |
14634 * Reporting label used for HTML5 banner backup image. Applicable to | |
14635 * ENHANCED_BANNER when the primary asset type is not HTML_IMAGE. | |
14636 */ | |
14637 core.String backupImageReportingLabel; | |
14638 /** | |
14639 * Target window for backup image. Applicable to the following creative types: | |
14640 * FLASH_INPAGE, and HTML5_BANNER. Applicable to ENHANCED_BANNER when the | |
14641 * primary asset type is not HTML_IMAGE. | |
14642 */ | |
14643 TargetWindow backupImageTargetWindow; | |
14644 /** | |
14645 * Click tags of the creative. For ENHANCED_BANNER, FLASH_INPAGE, and | |
14646 * HTML5_BANNER creatives, this is a subset of detected click tags for the | |
14647 * assets associated with this creative. After creating a flash asset, | |
14648 * detected click tags will be returned in the creativeAssetMetadata. When | |
14649 * inserting the creative, populate the creative clickTags field using the | |
14650 * creativeAssetMetadata.clickTags field. For ENHANCED_IMAGE creatives, there | |
14651 * should be exactly one entry in this list for each image creative asset. A | |
14652 * click tag is matched with a corresponding creative asset by matching the | |
14653 * clickTag.name field with the creativeAsset.assetIdentifier.name field. | |
14654 * Applicable to the following creative types: ENHANCED_IMAGE, FLASH_INPAGE | |
14655 * HTML5_BANNER. Applicable to ENHANCED_BANNER when the primary asset type is | |
14656 * not HTML_IMAGE. | |
14657 */ | |
14658 core.List<ClickTag> clickTags; | |
14659 /** | |
14660 * Industry standard ID assigned to creative for reach and frequency. | |
14661 * Applicable to the following creative types: all INSTREAM_VIDEO and all | |
14662 * VPAID. | |
14663 */ | |
14664 core.String commercialId; | |
14665 /** | |
14666 * List of companion creatives assigned to an in-Stream videocreative. | |
14667 * Acceptable values include IDs of existing flash and image creatives. | |
14668 * Applicable to the following creative types: all INSTREAM_VIDEO and all | |
14669 * VPAID. | |
14670 */ | |
14671 core.List<core.String> companionCreatives; | |
14672 /** | |
14673 * Compatibilities associated with this creative. This is a read-only field. | |
14674 * WEB and WEB_INTERSTITIAL refer to rendering either on desktop or on mobile | |
14675 * devices for regular or interstitial ads, respectively. APP and | |
14676 * APP_INTERSTITIAL are for rendering in mobile apps. IN_STREAM_VIDEO refers | |
14677 * to rendering in in-stream video ads developed with the VAST standard. | |
14678 * Applicable to all creative types. | |
14679 * | |
14680 * Acceptable values are: | |
14681 * - "APP" | |
14682 * - "APP_INTERSTITIAL" | |
14683 * - "IN_STREAM_VIDEO" | |
14684 * - "WEB" | |
14685 * - "WEB_INTERSTITIAL" | |
14686 */ | |
14687 core.List<core.String> compatibility; | |
14688 /** | |
14689 * Whether Flash assets associated with the creative need to be automatically | |
14690 * converted to HTML5. This flag is enabled by default and users can choose to | |
14691 * disable it if they don't want the system to generate and use HTML5 asset | |
14692 * for this creative. Applicable to the following creative type: FLASH_INPAGE. | |
14693 * Applicable to ENHANCED_BANNER when the primary asset type is not | |
14694 * HTML_IMAGE. | |
14695 */ | |
14696 core.bool convertFlashToHtml5; | |
14697 /** | |
14698 * List of counter events configured for the creative. For ENHANCED_IMAGE | |
14699 * creatives, these are read-only and auto-generated from clickTags. | |
14700 * Applicable to the following creative types: ENHANCED_IMAGE, all RICH_MEDIA, | |
14701 * and all VPAID. | |
14702 */ | |
14703 core.List<CreativeCustomEvent> counterCustomEvents; | |
14704 /** | |
14705 * Assets associated with a creative. Applicable to all but the following | |
14706 * creative types: INTERNAL_REDIRECT, INTERSTITIAL_INTERNAL_REDIRECT, and | |
14707 * REDIRECT | |
14708 */ | |
14709 core.List<CreativeAsset> creativeAssets; | |
14710 /** | |
14711 * Creative field assignments for this creative. Applicable to all creative | |
14712 * types. | |
14713 */ | |
14714 core.List<CreativeFieldAssignment> creativeFieldAssignments; | |
14715 /** | |
14716 * Custom key-values for a Rich Media creative. Key-values let you customize | |
14717 * the creative settings of a Rich Media ad running on your site without | |
14718 * having to contact the advertiser. You can use key-values to dynamically | |
14719 * change the look or functionality of a creative. Applicable to the following | |
14720 * creative types: all RICH_MEDIA, and all VPAID. | |
14721 */ | |
14722 core.List<core.String> customKeyValues; | |
14723 /** | |
14724 * List of exit events configured for the creative. For ENHANCED_BANNER and | |
14725 * ENHANCED_IMAGE creatives, these are read-only and auto-generated from | |
14726 * clickTags, For ENHANCED_BANNER, an event is also created from the | |
14727 * backupImageReportingLabel. Applicable to the following creative types: | |
14728 * ENHANCED_IMAGE, all RICH_MEDIA, and all VPAID. Applicable to | |
14729 * ENHANCED_BANNER when the primary asset is not HTML_IMAGE. | |
14730 */ | |
14731 core.List<CreativeCustomEvent> exitCustomEvents; | |
14732 /** | |
14733 * OpenWindow FSCommand of this creative. This lets the SWF file communicate | |
14734 * with either Flash Player or the program hosting Flash Player, such as a web | |
14735 * browser. This is only triggered if allowScriptAccess field is true. | |
14736 * Applicable to the following creative types: FLASH_INPAGE. | |
14737 */ | |
14738 FsCommand fsCommand; | |
14739 /** | |
14740 * HTML code for the creative. This is a required field when applicable. This | |
14741 * field is ignored if htmlCodeLocked is false. Applicable to the following | |
14742 * creative types: all CUSTOM, FLASH_INPAGE, and HTML5_BANNER, and all | |
14743 * RICH_MEDIA. | |
14744 */ | |
14745 core.String htmlCode; | |
14746 /** | |
14747 * Whether HTML code is DCM-generated or manually entered. Set to true to | |
14748 * ignore changes to htmlCode. Applicable to the following creative types: | |
14749 * FLASH_INPAGE and HTML5_BANNER. | |
14750 */ | |
14751 core.bool htmlCodeLocked; | |
14752 /** | |
14753 * ID of this creative. This is a read-only, auto-generated field. Applicable | |
14754 * to all creative types. | |
14755 */ | |
14756 core.String id; | |
14757 /** | |
14758 * Dimension value for the ID of this creative. This is a read-only field. | |
14759 * Applicable to all creative types. | |
14760 */ | |
14761 DimensionValue idDimensionValue; | |
14762 /** | |
14763 * Identifies what kind of resource this is. Value: the fixed string | |
14764 * "dfareporting#creative". | |
14765 */ | |
14766 core.String kind; | |
14767 /** | |
14768 * Creative last modification information. This is a read-only field. | |
14769 * Applicable to all creative types. | |
14770 */ | |
14771 LastModifiedInfo lastModifiedInfo; | |
14772 /** | |
14773 * Latest Studio trafficked creative ID associated with rich media and VPAID | |
14774 * creatives. This is a read-only field. Applicable to the following creative | |
14775 * types: all RICH_MEDIA, and all VPAID. | |
14776 */ | |
14777 core.String latestTraffickedCreativeId; | |
14778 /** | |
14779 * Name of the creative. This is a required field and must be less than 256 | |
14780 * characters long. Applicable to all creative types. | |
14781 */ | |
14782 core.String name; | |
14783 /** | |
14784 * Override CSS value for rich media creatives. Applicable to the following | |
14785 * creative types: all RICH_MEDIA. | |
14786 */ | |
14787 core.String overrideCss; | |
14788 /** | |
14789 * URL of hosted image or hosted video or another ad tag. For | |
14790 * INSTREAM_VIDEO_REDIRECT creatives this is the in-stream video redirect URL. | |
14791 * The standard for a VAST (Video Ad Serving Template) ad response allows for | |
14792 * a redirect link to another VAST 2.0 or 3.0 call. This is a required field | |
14793 * when applicable. Applicable to the following creative types: | |
14794 * INTERNAL_REDIRECT, INTERSTITIAL_INTERNAL_REDIRECT, REDIRECT, and | |
14795 * INSTREAM_VIDEO_REDIRECT | |
14796 */ | |
14797 core.String redirectUrl; | |
14798 /** | |
14799 * ID of current rendering version. This is a read-only field. Applicable to | |
14800 * all creative types. | |
14801 */ | |
14802 core.String renderingId; | |
14803 /** | |
14804 * Dimension value for the rendering ID of this creative. This is a read-only | |
14805 * field. Applicable to all creative types. | |
14806 */ | |
14807 DimensionValue renderingIdDimensionValue; | |
14808 /** | |
14809 * The minimum required Flash plugin version for this creative. For example, | |
14810 * 11.2.202.235. This is a read-only field. Applicable to the following | |
14811 * creative types: all RICH_MEDIA, and all VPAID. | |
14812 */ | |
14813 core.String requiredFlashPluginVersion; | |
14814 /** | |
14815 * The internal Flash version for this creative as calculated by DoubleClick | |
14816 * Studio. This is a read-only field. Applicable to the following creative | |
14817 * types: FLASH_INPAGE, all RICH_MEDIA, and all VPAID. Applicable to | |
14818 * ENHANCED_BANNER when the primary asset type is not HTML_IMAGE. | |
14819 */ | |
14820 core.int requiredFlashVersion; | |
14821 /** | |
14822 * Size associated with this creative. When inserting or updating a creative | |
14823 * either the size ID field or size width and height fields can be used. This | |
14824 * is a required field when applicable; however for IMAGE and FLASH_INPAGE | |
14825 * creatives, and for ENHANCED_BANNER creatives with a primary asset of type | |
14826 * HTML_IMAGE, if left blank, this field will be automatically set using the | |
14827 * actual size of the associated image assets. Applicable to the following | |
14828 * creative types: ENHANCED_BANNER, ENHANCED_IMAGE, FLASH_INPAGE, | |
14829 * HTML5_BANNER, IMAGE, and all RICH_MEDIA. | |
14830 */ | |
14831 Size size; | |
14832 /** | |
14833 * Whether the user can choose to skip the creative. Applicable to the | |
14834 * following creative types: all INSTREAM_VIDEO and all VPAID. | |
14835 */ | |
14836 core.bool skippable; | |
14837 /** | |
14838 * Whether the creative is SSL-compliant. This is a read-only field. | |
14839 * Applicable to all creative types. | |
14840 */ | |
14841 core.bool sslCompliant; | |
14842 /** | |
14843 * Whether creative should be treated as SSL compliant even if the system scan | |
14844 * shows it's not. Applicable to all creative types. | |
14845 */ | |
14846 core.bool sslOverride; | |
14847 /** | |
14848 * Studio advertiser ID associated with rich media and VPAID creatives. This | |
14849 * is a read-only field. Applicable to the following creative types: all | |
14850 * RICH_MEDIA, and all VPAID. | |
14851 */ | |
14852 core.String studioAdvertiserId; | |
14853 /** | |
14854 * Studio creative ID associated with rich media and VPAID creatives. This is | |
14855 * a read-only field. Applicable to the following creative types: all | |
14856 * RICH_MEDIA, and all VPAID. | |
14857 */ | |
14858 core.String studioCreativeId; | |
14859 /** | |
14860 * Studio trafficked creative ID associated with rich media and VPAID | |
14861 * creatives. This is a read-only field. Applicable to the following creative | |
14862 * types: all RICH_MEDIA, and all VPAID. | |
14863 */ | |
14864 core.String studioTraffickedCreativeId; | |
14865 /** | |
14866 * Subaccount ID of this creative. This field, if left unset, will be | |
14867 * auto-generated for both insert and update operations. Applicable to all | |
14868 * creative types. | |
14869 */ | |
14870 core.String subaccountId; | |
14871 /** | |
14872 * Third-party URL used to record backup image impressions. Applicable to the | |
14873 * following creative types: all RICH_MEDIA. | |
14874 */ | |
14875 core.String thirdPartyBackupImageImpressionsUrl; | |
14876 /** | |
14877 * Third-party URL used to record rich media impressions. Applicable to the | |
14878 * following creative types: all RICH_MEDIA. | |
14879 */ | |
14880 core.String thirdPartyRichMediaImpressionsUrl; | |
14881 /** | |
14882 * Third-party URLs for tracking in-stream video creative events. Applicable | |
14883 * to the following creative types: all INSTREAM_VIDEO and all VPAID. | |
14884 */ | |
14885 core.List<ThirdPartyTrackingUrl> thirdPartyUrls; | |
14886 /** | |
14887 * List of timer events configured for the creative. For ENHANCED_IMAGE | |
14888 * creatives, these are read-only and auto-generated from clickTags. | |
14889 * Applicable to the following creative types: ENHANCED_IMAGE, all RICH_MEDIA, | |
14890 * and all VPAID. Applicable to ENHANCED_BANNER when the primary asset is not | |
14891 * HTML_IMAGE. | |
14892 */ | |
14893 core.List<CreativeCustomEvent> timerCustomEvents; | |
14894 /** | |
14895 * Combined size of all creative assets. This is a read-only field. Applicable | |
14896 * to the following creative types: all RICH_MEDIA, and all VPAID. | |
14897 */ | |
14898 core.String totalFileSize; | |
14899 /** | |
14900 * Type of this creative.This is a required field. Applicable to all creative | |
14901 * types. | |
14902 * Possible string values are: | |
14903 * - "BRAND_SAFE_DEFAULT_INSTREAM_VIDEO" | |
14904 * - "CUSTOM_INPAGE" | |
14905 * - "CUSTOM_INTERSTITIAL" | |
14906 * - "ENHANCED_BANNER" | |
14907 * - "ENHANCED_IMAGE" | |
14908 * - "FLASH_INPAGE" | |
14909 * - "HTML5_BANNER" | |
14910 * - "IMAGE" | |
14911 * - "INSTREAM_VIDEO" | |
14912 * - "INSTREAM_VIDEO_REDIRECT" | |
14913 * - "INTERNAL_REDIRECT" | |
14914 * - "INTERSTITIAL_INTERNAL_REDIRECT" | |
14915 * - "REDIRECT" | |
14916 * - "RICH_MEDIA_EXPANDING" | |
14917 * - "RICH_MEDIA_IM_EXPAND" | |
14918 * - "RICH_MEDIA_INPAGE" | |
14919 * - "RICH_MEDIA_INPAGE_FLOATING" | |
14920 * - "RICH_MEDIA_INTERSTITIAL_FLOAT" | |
14921 * - "RICH_MEDIA_MOBILE_IN_APP" | |
14922 * - "RICH_MEDIA_MULTI_FLOATING" | |
14923 * - "RICH_MEDIA_PEEL_DOWN" | |
14924 * - "TRACKING_TEXT" | |
14925 * - "VPAID_LINEAR" | |
14926 * - "VPAID_NON_LINEAR" | |
14927 */ | |
14928 core.String type; | |
14929 /** | |
14930 * The version number helps you keep track of multiple versions of your | |
14931 * creative in your reports. The version number will always be auto-generated | |
14932 * during insert operations to start at 1. For tracking creatives the version | |
14933 * cannot be incremented and will always remain at 1. For all other creative | |
14934 * types the version can be incremented only by 1 during update operations. In | |
14935 * addition, the version will be automatically incremented by 1 when | |
14936 * undergoing Rich Media creative merging. Applicable to all creative types. | |
14937 */ | |
14938 core.int version; | |
14939 /** | |
14940 * Description of the video ad. Applicable to the following creative types: | |
14941 * all INSTREAM_VIDEO and all VPAID. | |
14942 */ | |
14943 core.String videoDescription; | |
14944 /** | |
14945 * Creative video duration in seconds. This is a read-only field. Applicable | |
14946 * to the following creative types: INSTREAM_VIDEO, all RICH_MEDIA, and all | |
14947 * VPAID. | |
14948 */ | |
14949 core.double videoDuration; | |
14950 | |
14951 Creative(); | |
14952 | |
14953 Creative.fromJson(core.Map _json) { | |
14954 if (_json.containsKey("accountId")) { | |
14955 accountId = _json["accountId"]; | |
14956 } | |
14957 if (_json.containsKey("active")) { | |
14958 active = _json["active"]; | |
14959 } | |
14960 if (_json.containsKey("adParameters")) { | |
14961 adParameters = _json["adParameters"]; | |
14962 } | |
14963 if (_json.containsKey("adTagKeys")) { | |
14964 adTagKeys = _json["adTagKeys"]; | |
14965 } | |
14966 if (_json.containsKey("advertiserId")) { | |
14967 advertiserId = _json["advertiserId"]; | |
14968 } | |
14969 if (_json.containsKey("allowScriptAccess")) { | |
14970 allowScriptAccess = _json["allowScriptAccess"]; | |
14971 } | |
14972 if (_json.containsKey("archived")) { | |
14973 archived = _json["archived"]; | |
14974 } | |
14975 if (_json.containsKey("artworkType")) { | |
14976 artworkType = _json["artworkType"]; | |
14977 } | |
14978 if (_json.containsKey("authoringSource")) { | |
14979 authoringSource = _json["authoringSource"]; | |
14980 } | |
14981 if (_json.containsKey("authoringTool")) { | |
14982 authoringTool = _json["authoringTool"]; | |
14983 } | |
14984 if (_json.containsKey("auto_advance_images")) { | |
14985 autoAdvanceImages = _json["auto_advance_images"]; | |
14986 } | |
14987 if (_json.containsKey("backgroundColor")) { | |
14988 backgroundColor = _json["backgroundColor"]; | |
14989 } | |
14990 if (_json.containsKey("backupImageClickThroughUrl")) { | |
14991 backupImageClickThroughUrl = _json["backupImageClickThroughUrl"]; | |
14992 } | |
14993 if (_json.containsKey("backupImageFeatures")) { | |
14994 backupImageFeatures = _json["backupImageFeatures"]; | |
14995 } | |
14996 if (_json.containsKey("backupImageReportingLabel")) { | |
14997 backupImageReportingLabel = _json["backupImageReportingLabel"]; | |
14998 } | |
14999 if (_json.containsKey("backupImageTargetWindow")) { | |
15000 backupImageTargetWindow = new TargetWindow.fromJson(_json["backupImageTarg
etWindow"]); | |
15001 } | |
15002 if (_json.containsKey("clickTags")) { | |
15003 clickTags = _json["clickTags"].map((value) => new ClickTag.fromJson(value)
).toList(); | |
15004 } | |
15005 if (_json.containsKey("commercialId")) { | |
15006 commercialId = _json["commercialId"]; | |
15007 } | |
15008 if (_json.containsKey("companionCreatives")) { | |
15009 companionCreatives = _json["companionCreatives"]; | |
15010 } | |
15011 if (_json.containsKey("compatibility")) { | |
15012 compatibility = _json["compatibility"]; | |
15013 } | |
15014 if (_json.containsKey("convertFlashToHtml5")) { | |
15015 convertFlashToHtml5 = _json["convertFlashToHtml5"]; | |
15016 } | |
15017 if (_json.containsKey("counterCustomEvents")) { | |
15018 counterCustomEvents = _json["counterCustomEvents"].map((value) => new Crea
tiveCustomEvent.fromJson(value)).toList(); | |
15019 } | |
15020 if (_json.containsKey("creativeAssets")) { | |
15021 creativeAssets = _json["creativeAssets"].map((value) => new CreativeAsset.
fromJson(value)).toList(); | |
15022 } | |
15023 if (_json.containsKey("creativeFieldAssignments")) { | |
15024 creativeFieldAssignments = _json["creativeFieldAssignments"].map((value) =
> new CreativeFieldAssignment.fromJson(value)).toList(); | |
15025 } | |
15026 if (_json.containsKey("customKeyValues")) { | |
15027 customKeyValues = _json["customKeyValues"]; | |
15028 } | |
15029 if (_json.containsKey("exitCustomEvents")) { | |
15030 exitCustomEvents = _json["exitCustomEvents"].map((value) => new CreativeCu
stomEvent.fromJson(value)).toList(); | |
15031 } | |
15032 if (_json.containsKey("fsCommand")) { | |
15033 fsCommand = new FsCommand.fromJson(_json["fsCommand"]); | |
15034 } | |
15035 if (_json.containsKey("htmlCode")) { | |
15036 htmlCode = _json["htmlCode"]; | |
15037 } | |
15038 if (_json.containsKey("htmlCodeLocked")) { | |
15039 htmlCodeLocked = _json["htmlCodeLocked"]; | |
15040 } | |
15041 if (_json.containsKey("id")) { | |
15042 id = _json["id"]; | |
15043 } | |
15044 if (_json.containsKey("idDimensionValue")) { | |
15045 idDimensionValue = new DimensionValue.fromJson(_json["idDimensionValue"]); | |
15046 } | |
15047 if (_json.containsKey("kind")) { | |
15048 kind = _json["kind"]; | |
15049 } | |
15050 if (_json.containsKey("lastModifiedInfo")) { | |
15051 lastModifiedInfo = new LastModifiedInfo.fromJson(_json["lastModifiedInfo"]
); | |
15052 } | |
15053 if (_json.containsKey("latestTraffickedCreativeId")) { | |
15054 latestTraffickedCreativeId = _json["latestTraffickedCreativeId"]; | |
15055 } | |
15056 if (_json.containsKey("name")) { | |
15057 name = _json["name"]; | |
15058 } | |
15059 if (_json.containsKey("overrideCss")) { | |
15060 overrideCss = _json["overrideCss"]; | |
15061 } | |
15062 if (_json.containsKey("redirectUrl")) { | |
15063 redirectUrl = _json["redirectUrl"]; | |
15064 } | |
15065 if (_json.containsKey("renderingId")) { | |
15066 renderingId = _json["renderingId"]; | |
15067 } | |
15068 if (_json.containsKey("renderingIdDimensionValue")) { | |
15069 renderingIdDimensionValue = new DimensionValue.fromJson(_json["renderingId
DimensionValue"]); | |
15070 } | |
15071 if (_json.containsKey("requiredFlashPluginVersion")) { | |
15072 requiredFlashPluginVersion = _json["requiredFlashPluginVersion"]; | |
15073 } | |
15074 if (_json.containsKey("requiredFlashVersion")) { | |
15075 requiredFlashVersion = _json["requiredFlashVersion"]; | |
15076 } | |
15077 if (_json.containsKey("size")) { | |
15078 size = new Size.fromJson(_json["size"]); | |
15079 } | |
15080 if (_json.containsKey("skippable")) { | |
15081 skippable = _json["skippable"]; | |
15082 } | |
15083 if (_json.containsKey("sslCompliant")) { | |
15084 sslCompliant = _json["sslCompliant"]; | |
15085 } | |
15086 if (_json.containsKey("sslOverride")) { | |
15087 sslOverride = _json["sslOverride"]; | |
15088 } | |
15089 if (_json.containsKey("studioAdvertiserId")) { | |
15090 studioAdvertiserId = _json["studioAdvertiserId"]; | |
15091 } | |
15092 if (_json.containsKey("studioCreativeId")) { | |
15093 studioCreativeId = _json["studioCreativeId"]; | |
15094 } | |
15095 if (_json.containsKey("studioTraffickedCreativeId")) { | |
15096 studioTraffickedCreativeId = _json["studioTraffickedCreativeId"]; | |
15097 } | |
15098 if (_json.containsKey("subaccountId")) { | |
15099 subaccountId = _json["subaccountId"]; | |
15100 } | |
15101 if (_json.containsKey("thirdPartyBackupImageImpressionsUrl")) { | |
15102 thirdPartyBackupImageImpressionsUrl = _json["thirdPartyBackupImageImpressi
onsUrl"]; | |
15103 } | |
15104 if (_json.containsKey("thirdPartyRichMediaImpressionsUrl")) { | |
15105 thirdPartyRichMediaImpressionsUrl = _json["thirdPartyRichMediaImpressionsU
rl"]; | |
15106 } | |
15107 if (_json.containsKey("thirdPartyUrls")) { | |
15108 thirdPartyUrls = _json["thirdPartyUrls"].map((value) => new ThirdPartyTrac
kingUrl.fromJson(value)).toList(); | |
15109 } | |
15110 if (_json.containsKey("timerCustomEvents")) { | |
15111 timerCustomEvents = _json["timerCustomEvents"].map((value) => new Creative
CustomEvent.fromJson(value)).toList(); | |
15112 } | |
15113 if (_json.containsKey("totalFileSize")) { | |
15114 totalFileSize = _json["totalFileSize"]; | |
15115 } | |
15116 if (_json.containsKey("type")) { | |
15117 type = _json["type"]; | |
15118 } | |
15119 if (_json.containsKey("version")) { | |
15120 version = _json["version"]; | |
15121 } | |
15122 if (_json.containsKey("videoDescription")) { | |
15123 videoDescription = _json["videoDescription"]; | |
15124 } | |
15125 if (_json.containsKey("videoDuration")) { | |
15126 videoDuration = _json["videoDuration"]; | |
15127 } | |
15128 } | |
15129 | |
15130 core.Map toJson() { | |
15131 var _json = new core.Map(); | |
15132 if (accountId != null) { | |
15133 _json["accountId"] = accountId; | |
15134 } | |
15135 if (active != null) { | |
15136 _json["active"] = active; | |
15137 } | |
15138 if (adParameters != null) { | |
15139 _json["adParameters"] = adParameters; | |
15140 } | |
15141 if (adTagKeys != null) { | |
15142 _json["adTagKeys"] = adTagKeys; | |
15143 } | |
15144 if (advertiserId != null) { | |
15145 _json["advertiserId"] = advertiserId; | |
15146 } | |
15147 if (allowScriptAccess != null) { | |
15148 _json["allowScriptAccess"] = allowScriptAccess; | |
15149 } | |
15150 if (archived != null) { | |
15151 _json["archived"] = archived; | |
15152 } | |
15153 if (artworkType != null) { | |
15154 _json["artworkType"] = artworkType; | |
15155 } | |
15156 if (authoringSource != null) { | |
15157 _json["authoringSource"] = authoringSource; | |
15158 } | |
15159 if (authoringTool != null) { | |
15160 _json["authoringTool"] = authoringTool; | |
15161 } | |
15162 if (autoAdvanceImages != null) { | |
15163 _json["auto_advance_images"] = autoAdvanceImages; | |
15164 } | |
15165 if (backgroundColor != null) { | |
15166 _json["backgroundColor"] = backgroundColor; | |
15167 } | |
15168 if (backupImageClickThroughUrl != null) { | |
15169 _json["backupImageClickThroughUrl"] = backupImageClickThroughUrl; | |
15170 } | |
15171 if (backupImageFeatures != null) { | |
15172 _json["backupImageFeatures"] = backupImageFeatures; | |
15173 } | |
15174 if (backupImageReportingLabel != null) { | |
15175 _json["backupImageReportingLabel"] = backupImageReportingLabel; | |
15176 } | |
15177 if (backupImageTargetWindow != null) { | |
15178 _json["backupImageTargetWindow"] = (backupImageTargetWindow).toJson(); | |
15179 } | |
15180 if (clickTags != null) { | |
15181 _json["clickTags"] = clickTags.map((value) => (value).toJson()).toList(); | |
15182 } | |
15183 if (commercialId != null) { | |
15184 _json["commercialId"] = commercialId; | |
15185 } | |
15186 if (companionCreatives != null) { | |
15187 _json["companionCreatives"] = companionCreatives; | |
15188 } | |
15189 if (compatibility != null) { | |
15190 _json["compatibility"] = compatibility; | |
15191 } | |
15192 if (convertFlashToHtml5 != null) { | |
15193 _json["convertFlashToHtml5"] = convertFlashToHtml5; | |
15194 } | |
15195 if (counterCustomEvents != null) { | |
15196 _json["counterCustomEvents"] = counterCustomEvents.map((value) => (value).
toJson()).toList(); | |
15197 } | |
15198 if (creativeAssets != null) { | |
15199 _json["creativeAssets"] = creativeAssets.map((value) => (value).toJson()).
toList(); | |
15200 } | |
15201 if (creativeFieldAssignments != null) { | |
15202 _json["creativeFieldAssignments"] = creativeFieldAssignments.map((value) =
> (value).toJson()).toList(); | |
15203 } | |
15204 if (customKeyValues != null) { | |
15205 _json["customKeyValues"] = customKeyValues; | |
15206 } | |
15207 if (exitCustomEvents != null) { | |
15208 _json["exitCustomEvents"] = exitCustomEvents.map((value) => (value).toJson
()).toList(); | |
15209 } | |
15210 if (fsCommand != null) { | |
15211 _json["fsCommand"] = (fsCommand).toJson(); | |
15212 } | |
15213 if (htmlCode != null) { | |
15214 _json["htmlCode"] = htmlCode; | |
15215 } | |
15216 if (htmlCodeLocked != null) { | |
15217 _json["htmlCodeLocked"] = htmlCodeLocked; | |
15218 } | |
15219 if (id != null) { | |
15220 _json["id"] = id; | |
15221 } | |
15222 if (idDimensionValue != null) { | |
15223 _json["idDimensionValue"] = (idDimensionValue).toJson(); | |
15224 } | |
15225 if (kind != null) { | |
15226 _json["kind"] = kind; | |
15227 } | |
15228 if (lastModifiedInfo != null) { | |
15229 _json["lastModifiedInfo"] = (lastModifiedInfo).toJson(); | |
15230 } | |
15231 if (latestTraffickedCreativeId != null) { | |
15232 _json["latestTraffickedCreativeId"] = latestTraffickedCreativeId; | |
15233 } | |
15234 if (name != null) { | |
15235 _json["name"] = name; | |
15236 } | |
15237 if (overrideCss != null) { | |
15238 _json["overrideCss"] = overrideCss; | |
15239 } | |
15240 if (redirectUrl != null) { | |
15241 _json["redirectUrl"] = redirectUrl; | |
15242 } | |
15243 if (renderingId != null) { | |
15244 _json["renderingId"] = renderingId; | |
15245 } | |
15246 if (renderingIdDimensionValue != null) { | |
15247 _json["renderingIdDimensionValue"] = (renderingIdDimensionValue).toJson(); | |
15248 } | |
15249 if (requiredFlashPluginVersion != null) { | |
15250 _json["requiredFlashPluginVersion"] = requiredFlashPluginVersion; | |
15251 } | |
15252 if (requiredFlashVersion != null) { | |
15253 _json["requiredFlashVersion"] = requiredFlashVersion; | |
15254 } | |
15255 if (size != null) { | |
15256 _json["size"] = (size).toJson(); | |
15257 } | |
15258 if (skippable != null) { | |
15259 _json["skippable"] = skippable; | |
15260 } | |
15261 if (sslCompliant != null) { | |
15262 _json["sslCompliant"] = sslCompliant; | |
15263 } | |
15264 if (sslOverride != null) { | |
15265 _json["sslOverride"] = sslOverride; | |
15266 } | |
15267 if (studioAdvertiserId != null) { | |
15268 _json["studioAdvertiserId"] = studioAdvertiserId; | |
15269 } | |
15270 if (studioCreativeId != null) { | |
15271 _json["studioCreativeId"] = studioCreativeId; | |
15272 } | |
15273 if (studioTraffickedCreativeId != null) { | |
15274 _json["studioTraffickedCreativeId"] = studioTraffickedCreativeId; | |
15275 } | |
15276 if (subaccountId != null) { | |
15277 _json["subaccountId"] = subaccountId; | |
15278 } | |
15279 if (thirdPartyBackupImageImpressionsUrl != null) { | |
15280 _json["thirdPartyBackupImageImpressionsUrl"] = thirdPartyBackupImageImpres
sionsUrl; | |
15281 } | |
15282 if (thirdPartyRichMediaImpressionsUrl != null) { | |
15283 _json["thirdPartyRichMediaImpressionsUrl"] = thirdPartyRichMediaImpression
sUrl; | |
15284 } | |
15285 if (thirdPartyUrls != null) { | |
15286 _json["thirdPartyUrls"] = thirdPartyUrls.map((value) => (value).toJson()).
toList(); | |
15287 } | |
15288 if (timerCustomEvents != null) { | |
15289 _json["timerCustomEvents"] = timerCustomEvents.map((value) => (value).toJs
on()).toList(); | |
15290 } | |
15291 if (totalFileSize != null) { | |
15292 _json["totalFileSize"] = totalFileSize; | |
15293 } | |
15294 if (type != null) { | |
15295 _json["type"] = type; | |
15296 } | |
15297 if (version != null) { | |
15298 _json["version"] = version; | |
15299 } | |
15300 if (videoDescription != null) { | |
15301 _json["videoDescription"] = videoDescription; | |
15302 } | |
15303 if (videoDuration != null) { | |
15304 _json["videoDuration"] = videoDuration; | |
15305 } | |
15306 return _json; | |
15307 } | |
15308 } | |
15309 | |
15310 /** Creative Asset. */ | |
15311 class CreativeAsset { | |
15312 /** | |
15313 * Whether ActionScript3 is enabled for the flash asset. This is a read-only | |
15314 * field. Applicable to the following creative type: FLASH_INPAGE. Applicable | |
15315 * to ENHANCED_BANNER when the primary asset type is not HTML_IMAGE. | |
15316 */ | |
15317 core.bool actionScript3; | |
15318 /** | |
15319 * Whether the video asset is active. This is a read-only field for | |
15320 * VPAID_NON_LINEAR assets. Applicable to the following creative types: | |
15321 * INSTREAM_VIDEO and all VPAID. | |
15322 */ | |
15323 core.bool active; | |
15324 /** | |
15325 * Possible alignments for an asset. This is a read-only field. Applicable to | |
15326 * the following creative types: RICH_MEDIA_MULTI_FLOATING. | |
15327 * Possible string values are: | |
15328 * - "ALIGNMENT_BOTTOM" | |
15329 * - "ALIGNMENT_LEFT" | |
15330 * - "ALIGNMENT_RIGHT" | |
15331 * - "ALIGNMENT_TOP" | |
15332 */ | |
15333 core.String alignment; | |
15334 /** | |
15335 * Artwork type of rich media creative. This is a read-only field. Applicable | |
15336 * to the following creative types: all RICH_MEDIA. | |
15337 * Possible string values are: | |
15338 * - "ARTWORK_TYPE_FLASH" | |
15339 * - "ARTWORK_TYPE_HTML5" | |
15340 * - "ARTWORK_TYPE_IMAGE" | |
15341 * - "ARTWORK_TYPE_MIXED" | |
15342 */ | |
15343 core.String artworkType; | |
15344 /** | |
15345 * Identifier of this asset. This is the same identifier returned during | |
15346 * creative asset insert operation. This is a required field. Applicable to | |
15347 * all but the following creative types: all REDIRECT and TRACKING_TEXT. | |
15348 */ | |
15349 CreativeAssetId assetIdentifier; | |
15350 /** | |
15351 * Exit event configured for the backup image. Applicable to the following | |
15352 * creative types: all RICH_MEDIA. | |
15353 */ | |
15354 CreativeCustomEvent backupImageExit; | |
15355 /** | |
15356 * Detected bit-rate for video asset. This is a read-only field. Applicable to | |
15357 * the following creative types: INSTREAM_VIDEO and all VPAID. | |
15358 */ | |
15359 core.int bitRate; | |
15360 /** | |
15361 * Rich media child asset type. This is a read-only field. Applicable to the | |
15362 * following creative types: all VPAID. | |
15363 * Possible string values are: | |
15364 * - "CHILD_ASSET_TYPE_DATA" | |
15365 * - "CHILD_ASSET_TYPE_FLASH" | |
15366 * - "CHILD_ASSET_TYPE_IMAGE" | |
15367 * - "CHILD_ASSET_TYPE_VIDEO" | |
15368 */ | |
15369 core.String childAssetType; | |
15370 /** | |
15371 * Size of an asset when collapsed. This is a read-only field. Applicable to | |
15372 * the following creative types: all RICH_MEDIA and all VPAID. Additionally, | |
15373 * applicable to assets whose displayType is ASSET_DISPLAY_TYPE_EXPANDING or | |
15374 * ASSET_DISPLAY_TYPE_PEEL_DOWN. | |
15375 */ | |
15376 Size collapsedSize; | |
15377 /** | |
15378 * Custom start time in seconds for making the asset visible. Applicable to | |
15379 * the following creative types: all RICH_MEDIA. | |
15380 */ | |
15381 core.int customStartTimeValue; | |
15382 /** | |
15383 * List of feature dependencies for the creative asset that are detected by | |
15384 * DCM. Feature dependencies are features that a browser must be able to | |
15385 * support in order to render your HTML5 creative correctly. This is a | |
15386 * read-only, auto-generated field. Applicable to the following creative | |
15387 * types: ENHANCED_BANNER and HTML5_BANNER. | |
15388 */ | |
15389 core.List<core.String> detectedFeatures; | |
15390 /** | |
15391 * Type of rich media asset. This is a read-only field. Applicable to the | |
15392 * following creative types: all RICH_MEDIA. | |
15393 * Possible string values are: | |
15394 * - "ASSET_DISPLAY_TYPE_BACKDROP" | |
15395 * - "ASSET_DISPLAY_TYPE_EXPANDING" | |
15396 * - "ASSET_DISPLAY_TYPE_FLASH_IN_FLASH" | |
15397 * - "ASSET_DISPLAY_TYPE_FLASH_IN_FLASH_EXPANDING" | |
15398 * - "ASSET_DISPLAY_TYPE_FLOATING" | |
15399 * - "ASSET_DISPLAY_TYPE_INPAGE" | |
15400 * - "ASSET_DISPLAY_TYPE_OVERLAY" | |
15401 * - "ASSET_DISPLAY_TYPE_PEEL_DOWN" | |
15402 * - "ASSET_DISPLAY_TYPE_VPAID_LINEAR" | |
15403 * - "ASSET_DISPLAY_TYPE_VPAID_NON_LINEAR" | |
15404 */ | |
15405 core.String displayType; | |
15406 /** | |
15407 * Duration in seconds for which an asset will be displayed. Applicable to the | |
15408 * following creative types: INSTREAM_VIDEO and VPAID_LINEAR. | |
15409 */ | |
15410 core.int duration; | |
15411 /** | |
15412 * Duration type for which an asset will be displayed. Applicable to the | |
15413 * following creative types: all RICH_MEDIA. | |
15414 * Possible string values are: | |
15415 * - "ASSET_DURATION_TYPE_AUTO" | |
15416 * - "ASSET_DURATION_TYPE_CUSTOM" | |
15417 * - "ASSET_DURATION_TYPE_NONE" | |
15418 */ | |
15419 core.String durationType; | |
15420 /** | |
15421 * Detected expanded dimension for video asset. This is a read-only field. | |
15422 * Applicable to the following creative types: INSTREAM_VIDEO and all VPAID. | |
15423 */ | |
15424 Size expandedDimension; | |
15425 /** | |
15426 * File size associated with this creative asset. This is a read-only field. | |
15427 * Applicable to all but the following creative types: all REDIRECT and | |
15428 * TRACKING_TEXT. | |
15429 */ | |
15430 core.String fileSize; | |
15431 /** | |
15432 * Flash version of the asset. This is a read-only field. Applicable to the | |
15433 * following creative types: FLASH_INPAGE, all RICH_MEDIA, and all VPAID. | |
15434 * Applicable to ENHANCED_BANNER when the primary asset type is not | |
15435 * HTML_IMAGE. | |
15436 */ | |
15437 core.int flashVersion; | |
15438 /** | |
15439 * Whether to hide Flash objects flag for an asset. Applicable to the | |
15440 * following creative types: all RICH_MEDIA. | |
15441 */ | |
15442 core.bool hideFlashObjects; | |
15443 /** | |
15444 * Whether to hide selection boxes flag for an asset. Applicable to the | |
15445 * following creative types: all RICH_MEDIA. | |
15446 */ | |
15447 core.bool hideSelectionBoxes; | |
15448 /** | |
15449 * Whether the asset is horizontally locked. This is a read-only field. | |
15450 * Applicable to the following creative types: all RICH_MEDIA. | |
15451 */ | |
15452 core.bool horizontallyLocked; | |
15453 /** | |
15454 * Numeric ID of this creative asset. This is a required field and should not | |
15455 * be modified. Applicable to all but the following creative types: all | |
15456 * REDIRECT and TRACKING_TEXT. | |
15457 */ | |
15458 core.String id; | |
15459 /** | |
15460 * Detected MIME type for video asset. This is a read-only field. Applicable | |
15461 * to the following creative types: INSTREAM_VIDEO and all VPAID. | |
15462 */ | |
15463 core.String mimeType; | |
15464 /** | |
15465 * Offset position for an asset in collapsed mode. This is a read-only field. | |
15466 * Applicable to the following creative types: all RICH_MEDIA and all VPAID. | |
15467 * Additionally, only applicable to assets whose displayType is | |
15468 * ASSET_DISPLAY_TYPE_EXPANDING or ASSET_DISPLAY_TYPE_PEEL_DOWN. | |
15469 */ | |
15470 OffsetPosition offset; | |
15471 /** | |
15472 * Whether the backup asset is original or changed by the user in DCM. | |
15473 * Applicable to the following creative types: all RICH_MEDIA. | |
15474 */ | |
15475 core.bool originalBackup; | |
15476 /** | |
15477 * Offset position for an asset. Applicable to the following creative types: | |
15478 * all RICH_MEDIA. | |
15479 */ | |
15480 OffsetPosition position; | |
15481 /** | |
15482 * Offset left unit for an asset. This is a read-only field. Applicable to the | |
15483 * following creative types: all RICH_MEDIA. | |
15484 * Possible string values are: | |
15485 * - "OFFSET_UNIT_PERCENT" | |
15486 * - "OFFSET_UNIT_PIXEL" | |
15487 * - "OFFSET_UNIT_PIXEL_FROM_CENTER" | |
15488 */ | |
15489 core.String positionLeftUnit; | |
15490 /** | |
15491 * Offset top unit for an asset. This is a read-only field if the asset | |
15492 * displayType is ASSET_DISPLAY_TYPE_OVERLAY. Applicable to the following | |
15493 * creative types: all RICH_MEDIA. | |
15494 * Possible string values are: | |
15495 * - "OFFSET_UNIT_PERCENT" | |
15496 * - "OFFSET_UNIT_PIXEL" | |
15497 * - "OFFSET_UNIT_PIXEL_FROM_CENTER" | |
15498 */ | |
15499 core.String positionTopUnit; | |
15500 /** | |
15501 * Progressive URL for video asset. This is a read-only field. Applicable to | |
15502 * the following creative types: INSTREAM_VIDEO and all VPAID. | |
15503 */ | |
15504 core.String progressiveServingUrl; | |
15505 /** | |
15506 * Whether the asset pushes down other content. Applicable to the following | |
15507 * creative types: all RICH_MEDIA. Additionally, only applicable when the | |
15508 * asset offsets are 0, the collapsedSize.width matches size.width, and the | |
15509 * collapsedSize.height is less than size.height. | |
15510 */ | |
15511 core.bool pushdown; | |
15512 /** | |
15513 * Pushdown duration in seconds for an asset. Must be between 0 and 9.99. | |
15514 * Applicable to the following creative types: all RICH_MEDIA.Additionally, | |
15515 * only applicable when the asset pushdown field is true, the offsets are 0, | |
15516 * the collapsedSize.width matches size.width, and the collapsedSize.height is | |
15517 * less than size.height. | |
15518 */ | |
15519 core.double pushdownDuration; | |
15520 /** | |
15521 * Role of the asset in relation to creative. Applicable to all but the | |
15522 * following creative types: all REDIRECT and TRACKING_TEXT. This is a | |
15523 * required field. | |
15524 * PRIMARY applies to ENHANCED_BANNER, FLASH_INPAGE, HTML5_BANNER, IMAGE, | |
15525 * IMAGE_GALLERY, all RICH_MEDIA (which may contain multiple primary assets), | |
15526 * and all VPAID creatives. | |
15527 * BACKUP_IMAGE applies to ENHANCED_BANNER, FLASH_INPAGE, HTML5_BANNER, all | |
15528 * RICH_MEDIA, and all VPAID creatives. | |
15529 * ADDITIONAL_IMAGE and ADDITIONAL_FLASH apply to FLASH_INPAGE creatives. | |
15530 * OTHER refers to assets from sources other than DCM, such as Studio uploaded | |
15531 * assets, applicable to all RICH_MEDIA and all VPAID creatives. | |
15532 * PARENT_VIDEO refers to videos uploaded by the user in DCM and is applicable | |
15533 * to INSTREAM_VIDEO and VPAID_LINEAR creatives. | |
15534 * TRANSCODED_VIDEO refers to videos transcoded by DCM from PARENT_VIDEO | |
15535 * assets and is applicable to INSTREAM_VIDEO and VPAID_LINEAR creatives. | |
15536 * ALTERNATE_VIDEO refers to the DCM representation of child asset videos from | |
15537 * Studio, and is applicable to VPAID_LINEAR_VIDEO creatives. These cannot be | |
15538 * added or removed within DCM. | |
15539 * For VPAID_LINEAR creatives, PARENT_VIDEO, TRANSCODED_VIDEO and | |
15540 * ALTERNATE_VIDEO assets that are marked active serve as backup in case the | |
15541 * VPAID creative cannot be served. Only PARENT_VIDEO assets can be added or | |
15542 * removed for an INSTREAM_VIDEO or VPAID_LINEAR creative. | |
15543 * Possible string values are: | |
15544 * - "ADDITIONAL_FLASH" | |
15545 * - "ADDITIONAL_IMAGE" | |
15546 * - "ALTERNATE_VIDEO" | |
15547 * - "BACKUP_IMAGE" | |
15548 * - "OTHER" | |
15549 * - "PARENT_VIDEO" | |
15550 * - "PRIMARY" | |
15551 * - "TRANSCODED_VIDEO" | |
15552 */ | |
15553 core.String role; | |
15554 /** | |
15555 * Size associated with this creative asset. This is a required field when | |
15556 * applicable; however for IMAGE and FLASH_INPAGE creatives, if left blank, | |
15557 * this field will be automatically set using the actual size of the | |
15558 * associated image asset. Applicable to the following creative types: | |
15559 * ENHANCED_IMAGE, FLASH_INPAGE, HTML5_BANNER, IMAGE, and all RICH_MEDIA. | |
15560 * Applicable to ENHANCED_BANNER when the primary asset type is not | |
15561 * HTML_IMAGE. | |
15562 */ | |
15563 Size size; | |
15564 /** | |
15565 * Whether the asset is SSL-compliant. This is a read-only field. Applicable | |
15566 * to all but the following creative types: all REDIRECT and TRACKING_TEXT. | |
15567 */ | |
15568 core.bool sslCompliant; | |
15569 /** | |
15570 * Initial wait time type before making the asset visible. Applicable to the | |
15571 * following creative types: all RICH_MEDIA. | |
15572 * Possible string values are: | |
15573 * - "ASSET_START_TIME_TYPE_CUSTOM" | |
15574 * - "ASSET_START_TIME_TYPE_NONE" | |
15575 */ | |
15576 core.String startTimeType; | |
15577 /** | |
15578 * Streaming URL for video asset. This is a read-only field. Applicable to the | |
15579 * following creative types: INSTREAM_VIDEO and all VPAID. | |
15580 */ | |
15581 core.String streamingServingUrl; | |
15582 /** | |
15583 * Whether the asset is transparent. Applicable to the following creative | |
15584 * types: all RICH_MEDIA. Additionally, only applicable to HTML5 assets. | |
15585 */ | |
15586 core.bool transparency; | |
15587 /** | |
15588 * Whether the asset is vertically locked. This is a read-only field. | |
15589 * Applicable to the following creative types: all RICH_MEDIA. | |
15590 */ | |
15591 core.bool verticallyLocked; | |
15592 /** | |
15593 * Detected video duration for video asset. This is a read-only field. | |
15594 * Applicable to the following creative types: INSTREAM_VIDEO and all VPAID. | |
15595 */ | |
15596 core.double videoDuration; | |
15597 /** | |
15598 * Window mode options for flash assets. Applicable to the following creative | |
15599 * types: FLASH_INPAGE, RICH_MEDIA_EXPANDING, RICH_MEDIA_IM_EXPAND, | |
15600 * RICH_MEDIA_INPAGE, and RICH_MEDIA_INPAGE_FLOATING. | |
15601 * Possible string values are: | |
15602 * - "OPAQUE" | |
15603 * - "TRANSPARENT" | |
15604 * - "WINDOW" | |
15605 */ | |
15606 core.String windowMode; | |
15607 /** | |
15608 * zIndex value of an asset. This is a read-only field. Applicable to the | |
15609 * following creative types: all RICH_MEDIA.Additionally, only applicable to | |
15610 * assets whose displayType is NOT one of the following types: | |
15611 * ASSET_DISPLAY_TYPE_INPAGE or ASSET_DISPLAY_TYPE_OVERLAY. | |
15612 */ | |
15613 core.int zIndex; | |
15614 /** | |
15615 * File name of zip file. This is a read-only field. Applicable to the | |
15616 * following creative types: HTML5_BANNER. | |
15617 */ | |
15618 core.String zipFilename; | |
15619 /** | |
15620 * Size of zip file. This is a read-only field. Applicable to the following | |
15621 * creative types: HTML5_BANNER. | |
15622 */ | |
15623 core.String zipFilesize; | |
15624 | |
15625 CreativeAsset(); | |
15626 | |
15627 CreativeAsset.fromJson(core.Map _json) { | |
15628 if (_json.containsKey("actionScript3")) { | |
15629 actionScript3 = _json["actionScript3"]; | |
15630 } | |
15631 if (_json.containsKey("active")) { | |
15632 active = _json["active"]; | |
15633 } | |
15634 if (_json.containsKey("alignment")) { | |
15635 alignment = _json["alignment"]; | |
15636 } | |
15637 if (_json.containsKey("artworkType")) { | |
15638 artworkType = _json["artworkType"]; | |
15639 } | |
15640 if (_json.containsKey("assetIdentifier")) { | |
15641 assetIdentifier = new CreativeAssetId.fromJson(_json["assetIdentifier"]); | |
15642 } | |
15643 if (_json.containsKey("backupImageExit")) { | |
15644 backupImageExit = new CreativeCustomEvent.fromJson(_json["backupImageExit"
]); | |
15645 } | |
15646 if (_json.containsKey("bitRate")) { | |
15647 bitRate = _json["bitRate"]; | |
15648 } | |
15649 if (_json.containsKey("childAssetType")) { | |
15650 childAssetType = _json["childAssetType"]; | |
15651 } | |
15652 if (_json.containsKey("collapsedSize")) { | |
15653 collapsedSize = new Size.fromJson(_json["collapsedSize"]); | |
15654 } | |
15655 if (_json.containsKey("customStartTimeValue")) { | |
15656 customStartTimeValue = _json["customStartTimeValue"]; | |
15657 } | |
15658 if (_json.containsKey("detectedFeatures")) { | |
15659 detectedFeatures = _json["detectedFeatures"]; | |
15660 } | |
15661 if (_json.containsKey("displayType")) { | |
15662 displayType = _json["displayType"]; | |
15663 } | |
15664 if (_json.containsKey("duration")) { | |
15665 duration = _json["duration"]; | |
15666 } | |
15667 if (_json.containsKey("durationType")) { | |
15668 durationType = _json["durationType"]; | |
15669 } | |
15670 if (_json.containsKey("expandedDimension")) { | |
15671 expandedDimension = new Size.fromJson(_json["expandedDimension"]); | |
15672 } | |
15673 if (_json.containsKey("fileSize")) { | |
15674 fileSize = _json["fileSize"]; | |
15675 } | |
15676 if (_json.containsKey("flashVersion")) { | |
15677 flashVersion = _json["flashVersion"]; | |
15678 } | |
15679 if (_json.containsKey("hideFlashObjects")) { | |
15680 hideFlashObjects = _json["hideFlashObjects"]; | |
15681 } | |
15682 if (_json.containsKey("hideSelectionBoxes")) { | |
15683 hideSelectionBoxes = _json["hideSelectionBoxes"]; | |
15684 } | |
15685 if (_json.containsKey("horizontallyLocked")) { | |
15686 horizontallyLocked = _json["horizontallyLocked"]; | |
15687 } | |
15688 if (_json.containsKey("id")) { | |
15689 id = _json["id"]; | |
15690 } | |
15691 if (_json.containsKey("mimeType")) { | |
15692 mimeType = _json["mimeType"]; | |
15693 } | |
15694 if (_json.containsKey("offset")) { | |
15695 offset = new OffsetPosition.fromJson(_json["offset"]); | |
15696 } | |
15697 if (_json.containsKey("originalBackup")) { | |
15698 originalBackup = _json["originalBackup"]; | |
15699 } | |
15700 if (_json.containsKey("position")) { | |
15701 position = new OffsetPosition.fromJson(_json["position"]); | |
15702 } | |
15703 if (_json.containsKey("positionLeftUnit")) { | |
15704 positionLeftUnit = _json["positionLeftUnit"]; | |
15705 } | |
15706 if (_json.containsKey("positionTopUnit")) { | |
15707 positionTopUnit = _json["positionTopUnit"]; | |
15708 } | |
15709 if (_json.containsKey("progressiveServingUrl")) { | |
15710 progressiveServingUrl = _json["progressiveServingUrl"]; | |
15711 } | |
15712 if (_json.containsKey("pushdown")) { | |
15713 pushdown = _json["pushdown"]; | |
15714 } | |
15715 if (_json.containsKey("pushdownDuration")) { | |
15716 pushdownDuration = _json["pushdownDuration"]; | |
15717 } | |
15718 if (_json.containsKey("role")) { | |
15719 role = _json["role"]; | |
15720 } | |
15721 if (_json.containsKey("size")) { | |
15722 size = new Size.fromJson(_json["size"]); | |
15723 } | |
15724 if (_json.containsKey("sslCompliant")) { | |
15725 sslCompliant = _json["sslCompliant"]; | |
15726 } | |
15727 if (_json.containsKey("startTimeType")) { | |
15728 startTimeType = _json["startTimeType"]; | |
15729 } | |
15730 if (_json.containsKey("streamingServingUrl")) { | |
15731 streamingServingUrl = _json["streamingServingUrl"]; | |
15732 } | |
15733 if (_json.containsKey("transparency")) { | |
15734 transparency = _json["transparency"]; | |
15735 } | |
15736 if (_json.containsKey("verticallyLocked")) { | |
15737 verticallyLocked = _json["verticallyLocked"]; | |
15738 } | |
15739 if (_json.containsKey("videoDuration")) { | |
15740 videoDuration = _json["videoDuration"]; | |
15741 } | |
15742 if (_json.containsKey("windowMode")) { | |
15743 windowMode = _json["windowMode"]; | |
15744 } | |
15745 if (_json.containsKey("zIndex")) { | |
15746 zIndex = _json["zIndex"]; | |
15747 } | |
15748 if (_json.containsKey("zipFilename")) { | |
15749 zipFilename = _json["zipFilename"]; | |
15750 } | |
15751 if (_json.containsKey("zipFilesize")) { | |
15752 zipFilesize = _json["zipFilesize"]; | |
15753 } | |
15754 } | |
15755 | |
15756 core.Map toJson() { | |
15757 var _json = new core.Map(); | |
15758 if (actionScript3 != null) { | |
15759 _json["actionScript3"] = actionScript3; | |
15760 } | |
15761 if (active != null) { | |
15762 _json["active"] = active; | |
15763 } | |
15764 if (alignment != null) { | |
15765 _json["alignment"] = alignment; | |
15766 } | |
15767 if (artworkType != null) { | |
15768 _json["artworkType"] = artworkType; | |
15769 } | |
15770 if (assetIdentifier != null) { | |
15771 _json["assetIdentifier"] = (assetIdentifier).toJson(); | |
15772 } | |
15773 if (backupImageExit != null) { | |
15774 _json["backupImageExit"] = (backupImageExit).toJson(); | |
15775 } | |
15776 if (bitRate != null) { | |
15777 _json["bitRate"] = bitRate; | |
15778 } | |
15779 if (childAssetType != null) { | |
15780 _json["childAssetType"] = childAssetType; | |
15781 } | |
15782 if (collapsedSize != null) { | |
15783 _json["collapsedSize"] = (collapsedSize).toJson(); | |
15784 } | |
15785 if (customStartTimeValue != null) { | |
15786 _json["customStartTimeValue"] = customStartTimeValue; | |
15787 } | |
15788 if (detectedFeatures != null) { | |
15789 _json["detectedFeatures"] = detectedFeatures; | |
15790 } | |
15791 if (displayType != null) { | |
15792 _json["displayType"] = displayType; | |
15793 } | |
15794 if (duration != null) { | |
15795 _json["duration"] = duration; | |
15796 } | |
15797 if (durationType != null) { | |
15798 _json["durationType"] = durationType; | |
15799 } | |
15800 if (expandedDimension != null) { | |
15801 _json["expandedDimension"] = (expandedDimension).toJson(); | |
15802 } | |
15803 if (fileSize != null) { | |
15804 _json["fileSize"] = fileSize; | |
15805 } | |
15806 if (flashVersion != null) { | |
15807 _json["flashVersion"] = flashVersion; | |
15808 } | |
15809 if (hideFlashObjects != null) { | |
15810 _json["hideFlashObjects"] = hideFlashObjects; | |
15811 } | |
15812 if (hideSelectionBoxes != null) { | |
15813 _json["hideSelectionBoxes"] = hideSelectionBoxes; | |
15814 } | |
15815 if (horizontallyLocked != null) { | |
15816 _json["horizontallyLocked"] = horizontallyLocked; | |
15817 } | |
15818 if (id != null) { | |
15819 _json["id"] = id; | |
15820 } | |
15821 if (mimeType != null) { | |
15822 _json["mimeType"] = mimeType; | |
15823 } | |
15824 if (offset != null) { | |
15825 _json["offset"] = (offset).toJson(); | |
15826 } | |
15827 if (originalBackup != null) { | |
15828 _json["originalBackup"] = originalBackup; | |
15829 } | |
15830 if (position != null) { | |
15831 _json["position"] = (position).toJson(); | |
15832 } | |
15833 if (positionLeftUnit != null) { | |
15834 _json["positionLeftUnit"] = positionLeftUnit; | |
15835 } | |
15836 if (positionTopUnit != null) { | |
15837 _json["positionTopUnit"] = positionTopUnit; | |
15838 } | |
15839 if (progressiveServingUrl != null) { | |
15840 _json["progressiveServingUrl"] = progressiveServingUrl; | |
15841 } | |
15842 if (pushdown != null) { | |
15843 _json["pushdown"] = pushdown; | |
15844 } | |
15845 if (pushdownDuration != null) { | |
15846 _json["pushdownDuration"] = pushdownDuration; | |
15847 } | |
15848 if (role != null) { | |
15849 _json["role"] = role; | |
15850 } | |
15851 if (size != null) { | |
15852 _json["size"] = (size).toJson(); | |
15853 } | |
15854 if (sslCompliant != null) { | |
15855 _json["sslCompliant"] = sslCompliant; | |
15856 } | |
15857 if (startTimeType != null) { | |
15858 _json["startTimeType"] = startTimeType; | |
15859 } | |
15860 if (streamingServingUrl != null) { | |
15861 _json["streamingServingUrl"] = streamingServingUrl; | |
15862 } | |
15863 if (transparency != null) { | |
15864 _json["transparency"] = transparency; | |
15865 } | |
15866 if (verticallyLocked != null) { | |
15867 _json["verticallyLocked"] = verticallyLocked; | |
15868 } | |
15869 if (videoDuration != null) { | |
15870 _json["videoDuration"] = videoDuration; | |
15871 } | |
15872 if (windowMode != null) { | |
15873 _json["windowMode"] = windowMode; | |
15874 } | |
15875 if (zIndex != null) { | |
15876 _json["zIndex"] = zIndex; | |
15877 } | |
15878 if (zipFilename != null) { | |
15879 _json["zipFilename"] = zipFilename; | |
15880 } | |
15881 if (zipFilesize != null) { | |
15882 _json["zipFilesize"] = zipFilesize; | |
15883 } | |
15884 return _json; | |
15885 } | |
15886 } | |
15887 | |
15888 /** Creative Asset ID. */ | |
15889 class CreativeAssetId { | |
15890 /** | |
15891 * Name of the creative asset. This is a required field while inserting an | |
15892 * asset. After insertion, this assetIdentifier is used to identify the | |
15893 * uploaded asset. Characters in the name must be alphanumeric or one of the | |
15894 * following: ".-_ ". Spaces are allowed. | |
15895 */ | |
15896 core.String name; | |
15897 /** | |
15898 * Type of asset to upload. This is a required field. IMAGE is solely used for | |
15899 * IMAGE creatives. Other image assets should use HTML_IMAGE. | |
15900 * Possible string values are: | |
15901 * - "FLASH" | |
15902 * - "HTML" | |
15903 * - "HTML_IMAGE" | |
15904 * - "IMAGE" | |
15905 * - "VIDEO" | |
15906 */ | |
15907 core.String type; | |
15908 | |
15909 CreativeAssetId(); | |
15910 | |
15911 CreativeAssetId.fromJson(core.Map _json) { | |
15912 if (_json.containsKey("name")) { | |
15913 name = _json["name"]; | |
15914 } | |
15915 if (_json.containsKey("type")) { | |
15916 type = _json["type"]; | |
15917 } | |
15918 } | |
15919 | |
15920 core.Map toJson() { | |
15921 var _json = new core.Map(); | |
15922 if (name != null) { | |
15923 _json["name"] = name; | |
15924 } | |
15925 if (type != null) { | |
15926 _json["type"] = type; | |
15927 } | |
15928 return _json; | |
15929 } | |
15930 } | |
15931 | |
15932 /** | |
15933 * CreativeAssets contains properties of a creative asset file which will be | |
15934 * uploaded or has already been uploaded. Refer to the creative sample code for | |
15935 * how to upload assets and insert a creative. | |
15936 */ | |
15937 class CreativeAssetMetadata { | |
15938 /** ID of the creative asset. This is a required field. */ | |
15939 CreativeAssetId assetIdentifier; | |
15940 /** | |
15941 * List of detected click tags for assets. This is a read-only auto-generated | |
15942 * field. | |
15943 */ | |
15944 core.List<ClickTag> clickTags; | |
15945 /** | |
15946 * List of feature dependencies for the creative asset that are detected by | |
15947 * DCM. Feature dependencies are features that a browser must be able to | |
15948 * support in order to render your HTML5 creative correctly. This is a | |
15949 * read-only, auto-generated field. | |
15950 */ | |
15951 core.List<core.String> detectedFeatures; | |
15952 /** | |
15953 * Identifies what kind of resource this is. Value: the fixed string | |
15954 * "dfareporting#creativeAssetMetadata". | |
15955 */ | |
15956 core.String kind; | |
15957 /** | |
15958 * Rules validated during code generation that generated a warning. This is a | |
15959 * read-only, auto-generated field. | |
15960 * | |
15961 * Possible values are: | |
15962 * - "ADMOB_REFERENCED" | |
15963 * - "ASSET_FORMAT_UNSUPPORTED_DCM" | |
15964 * - "ASSET_INVALID" | |
15965 * - "CLICK_TAG_HARD_CODED" | |
15966 * - "CLICK_TAG_INVALID" | |
15967 * - "CLICK_TAG_IN_GWD" | |
15968 * - "CLICK_TAG_MISSING" | |
15969 * - "CLICK_TAG_MORE_THAN_ONE" | |
15970 * - "CLICK_TAG_NON_TOP_LEVEL" | |
15971 * - "COMPONENT_UNSUPPORTED_DCM" | |
15972 * - "ENABLER_UNSUPPORTED_METHOD_DCM" | |
15973 * - "EXTERNAL_FILE_REFERENCED" | |
15974 * - "FILE_DETAIL_EMPTY" | |
15975 * - "FILE_TYPE_INVALID" | |
15976 * - "GWD_PROPERTIES_INVALID" | |
15977 * - "HTML5_FEATURE_UNSUPPORTED" | |
15978 * - "LINKED_FILE_NOT_FOUND" | |
15979 * - "MAX_FLASH_VERSION_11" | |
15980 * - "MRAID_REFERENCED" | |
15981 * - "NOT_SSL_COMPLIANT" | |
15982 * - "ORPHANED_ASSET" | |
15983 * - "PRIMARY_HTML_MISSING" | |
15984 * - "SVG_INVALID" | |
15985 * - "ZIP_INVALID" | |
15986 */ | |
15987 core.List<core.String> warnedValidationRules; | |
15988 | |
15989 CreativeAssetMetadata(); | |
15990 | |
15991 CreativeAssetMetadata.fromJson(core.Map _json) { | |
15992 if (_json.containsKey("assetIdentifier")) { | |
15993 assetIdentifier = new CreativeAssetId.fromJson(_json["assetIdentifier"]); | |
15994 } | |
15995 if (_json.containsKey("clickTags")) { | |
15996 clickTags = _json["clickTags"].map((value) => new ClickTag.fromJson(value)
).toList(); | |
15997 } | |
15998 if (_json.containsKey("detectedFeatures")) { | |
15999 detectedFeatures = _json["detectedFeatures"]; | |
16000 } | |
16001 if (_json.containsKey("kind")) { | |
16002 kind = _json["kind"]; | |
16003 } | |
16004 if (_json.containsKey("warnedValidationRules")) { | |
16005 warnedValidationRules = _json["warnedValidationRules"]; | |
16006 } | |
16007 } | |
16008 | |
16009 core.Map toJson() { | |
16010 var _json = new core.Map(); | |
16011 if (assetIdentifier != null) { | |
16012 _json["assetIdentifier"] = (assetIdentifier).toJson(); | |
16013 } | |
16014 if (clickTags != null) { | |
16015 _json["clickTags"] = clickTags.map((value) => (value).toJson()).toList(); | |
16016 } | |
16017 if (detectedFeatures != null) { | |
16018 _json["detectedFeatures"] = detectedFeatures; | |
16019 } | |
16020 if (kind != null) { | |
16021 _json["kind"] = kind; | |
16022 } | |
16023 if (warnedValidationRules != null) { | |
16024 _json["warnedValidationRules"] = warnedValidationRules; | |
16025 } | |
16026 return _json; | |
16027 } | |
16028 } | |
16029 | |
16030 /** Creative Assignment. */ | |
16031 class CreativeAssignment { | |
16032 /** | |
16033 * Whether this creative assignment is active. When true, the creative will be | |
16034 * included in the ad's rotation. | |
16035 */ | |
16036 core.bool active; | |
16037 /** | |
16038 * Whether applicable event tags should fire when this creative assignment is | |
16039 * rendered. If this value is unset when the ad is inserted or updated, it | |
16040 * will default to true for all creative types EXCEPT for INTERNAL_REDIRECT, | |
16041 * INTERSTITIAL_INTERNAL_REDIRECT, and INSTREAM_VIDEO. | |
16042 */ | |
16043 core.bool applyEventTags; | |
16044 /** Click-through URL of the creative assignment. */ | |
16045 ClickThroughUrl clickThroughUrl; | |
16046 /** | |
16047 * Companion creative overrides for this creative assignment. Applicable to | |
16048 * video ads. | |
16049 */ | |
16050 core.List<CompanionClickThroughOverride> companionCreativeOverrides; | |
16051 /** | |
16052 * Creative group assignments for this creative assignment. Only one | |
16053 * assignment per creative group number is allowed for a maximum of two | |
16054 * assignments. | |
16055 */ | |
16056 core.List<CreativeGroupAssignment> creativeGroupAssignments; | |
16057 /** ID of the creative to be assigned. This is a required field. */ | |
16058 core.String creativeId; | |
16059 /** | |
16060 * Dimension value for the ID of the creative. This is a read-only, | |
16061 * auto-generated field. | |
16062 */ | |
16063 DimensionValue creativeIdDimensionValue; | |
16064 /** | |
16065 * Date and time that the assigned creative should stop serving. Must be later | |
16066 * than the start time. | |
16067 */ | |
16068 core.DateTime endTime; | |
16069 /** | |
16070 * Rich media exit overrides for this creative assignment. | |
16071 * Applicable when the creative type is any of the following: | |
16072 * - RICH_MEDIA_INPAGE | |
16073 * - RICH_MEDIA_INPAGE_FLOATING | |
16074 * - RICH_MEDIA_IM_EXPAND | |
16075 * - RICH_MEDIA_EXPANDING | |
16076 * - RICH_MEDIA_INTERSTITIAL_FLOAT | |
16077 * - RICH_MEDIA_MOBILE_IN_APP | |
16078 * - RICH_MEDIA_MULTI_FLOATING | |
16079 * - RICH_MEDIA_PEEL_DOWN | |
16080 * - ADVANCED_BANNER | |
16081 * - VPAID_LINEAR | |
16082 * - VPAID_NON_LINEAR | |
16083 */ | |
16084 core.List<RichMediaExitOverride> richMediaExitOverrides; | |
16085 /** | |
16086 * Sequence number of the creative assignment, applicable when the rotation | |
16087 * type is CREATIVE_ROTATION_TYPE_SEQUENTIAL. | |
16088 */ | |
16089 core.int sequence; | |
16090 /** | |
16091 * Whether the creative to be assigned is SSL-compliant. This is a read-only | |
16092 * field that is auto-generated when the ad is inserted or updated. | |
16093 */ | |
16094 core.bool sslCompliant; | |
16095 /** Date and time that the assigned creative should start serving. */ | |
16096 core.DateTime startTime; | |
16097 /** | |
16098 * Weight of the creative assignment, applicable when the rotation type is | |
16099 * CREATIVE_ROTATION_TYPE_RANDOM. | |
16100 */ | |
16101 core.int weight; | |
16102 | |
16103 CreativeAssignment(); | |
16104 | |
16105 CreativeAssignment.fromJson(core.Map _json) { | |
16106 if (_json.containsKey("active")) { | |
16107 active = _json["active"]; | |
16108 } | |
16109 if (_json.containsKey("applyEventTags")) { | |
16110 applyEventTags = _json["applyEventTags"]; | |
16111 } | |
16112 if (_json.containsKey("clickThroughUrl")) { | |
16113 clickThroughUrl = new ClickThroughUrl.fromJson(_json["clickThroughUrl"]); | |
16114 } | |
16115 if (_json.containsKey("companionCreativeOverrides")) { | |
16116 companionCreativeOverrides = _json["companionCreativeOverrides"].map((valu
e) => new CompanionClickThroughOverride.fromJson(value)).toList(); | |
16117 } | |
16118 if (_json.containsKey("creativeGroupAssignments")) { | |
16119 creativeGroupAssignments = _json["creativeGroupAssignments"].map((value) =
> new CreativeGroupAssignment.fromJson(value)).toList(); | |
16120 } | |
16121 if (_json.containsKey("creativeId")) { | |
16122 creativeId = _json["creativeId"]; | |
16123 } | |
16124 if (_json.containsKey("creativeIdDimensionValue")) { | |
16125 creativeIdDimensionValue = new DimensionValue.fromJson(_json["creativeIdDi
mensionValue"]); | |
16126 } | |
16127 if (_json.containsKey("endTime")) { | |
16128 endTime = core.DateTime.parse(_json["endTime"]); | |
16129 } | |
16130 if (_json.containsKey("richMediaExitOverrides")) { | |
16131 richMediaExitOverrides = _json["richMediaExitOverrides"].map((value) => ne
w RichMediaExitOverride.fromJson(value)).toList(); | |
16132 } | |
16133 if (_json.containsKey("sequence")) { | |
16134 sequence = _json["sequence"]; | |
16135 } | |
16136 if (_json.containsKey("sslCompliant")) { | |
16137 sslCompliant = _json["sslCompliant"]; | |
16138 } | |
16139 if (_json.containsKey("startTime")) { | |
16140 startTime = core.DateTime.parse(_json["startTime"]); | |
16141 } | |
16142 if (_json.containsKey("weight")) { | |
16143 weight = _json["weight"]; | |
16144 } | |
16145 } | |
16146 | |
16147 core.Map toJson() { | |
16148 var _json = new core.Map(); | |
16149 if (active != null) { | |
16150 _json["active"] = active; | |
16151 } | |
16152 if (applyEventTags != null) { | |
16153 _json["applyEventTags"] = applyEventTags; | |
16154 } | |
16155 if (clickThroughUrl != null) { | |
16156 _json["clickThroughUrl"] = (clickThroughUrl).toJson(); | |
16157 } | |
16158 if (companionCreativeOverrides != null) { | |
16159 _json["companionCreativeOverrides"] = companionCreativeOverrides.map((valu
e) => (value).toJson()).toList(); | |
16160 } | |
16161 if (creativeGroupAssignments != null) { | |
16162 _json["creativeGroupAssignments"] = creativeGroupAssignments.map((value) =
> (value).toJson()).toList(); | |
16163 } | |
16164 if (creativeId != null) { | |
16165 _json["creativeId"] = creativeId; | |
16166 } | |
16167 if (creativeIdDimensionValue != null) { | |
16168 _json["creativeIdDimensionValue"] = (creativeIdDimensionValue).toJson(); | |
16169 } | |
16170 if (endTime != null) { | |
16171 _json["endTime"] = (endTime).toIso8601String(); | |
16172 } | |
16173 if (richMediaExitOverrides != null) { | |
16174 _json["richMediaExitOverrides"] = richMediaExitOverrides.map((value) => (v
alue).toJson()).toList(); | |
16175 } | |
16176 if (sequence != null) { | |
16177 _json["sequence"] = sequence; | |
16178 } | |
16179 if (sslCompliant != null) { | |
16180 _json["sslCompliant"] = sslCompliant; | |
16181 } | |
16182 if (startTime != null) { | |
16183 _json["startTime"] = (startTime).toIso8601String(); | |
16184 } | |
16185 if (weight != null) { | |
16186 _json["weight"] = weight; | |
16187 } | |
16188 return _json; | |
16189 } | |
16190 } | |
16191 | |
16192 /** Creative Custom Event. */ | |
16193 class CreativeCustomEvent { | |
16194 /** | |
16195 * Unique ID of this event used by DDM Reporting and Data Transfer. This is a | |
16196 * read-only field. | |
16197 */ | |
16198 core.String advertiserCustomEventId; | |
16199 /** User-entered name for the event. */ | |
16200 core.String advertiserCustomEventName; | |
16201 /** | |
16202 * Type of the event. This is a read-only field. | |
16203 * Possible string values are: | |
16204 * - "ADVERTISER_EVENT_COUNTER" | |
16205 * - "ADVERTISER_EVENT_EXIT" | |
16206 * - "ADVERTISER_EVENT_TIMER" | |
16207 */ | |
16208 core.String advertiserCustomEventType; | |
16209 /** | |
16210 * Artwork label column, used to link events in DCM back to events in Studio. | |
16211 * This is a required field and should not be modified after insertion. | |
16212 */ | |
16213 core.String artworkLabel; | |
16214 /** | |
16215 * Artwork type used by the creative.This is a read-only field. | |
16216 * Possible string values are: | |
16217 * - "ARTWORK_TYPE_FLASH" | |
16218 * - "ARTWORK_TYPE_HTML5" | |
16219 * - "ARTWORK_TYPE_IMAGE" | |
16220 * - "ARTWORK_TYPE_MIXED" | |
16221 */ | |
16222 core.String artworkType; | |
16223 /** Exit URL of the event. This field is used only for exit events. */ | |
16224 core.String exitUrl; | |
16225 /** | |
16226 * ID of this event. This is a required field and should not be modified after | |
16227 * insertion. | |
16228 */ | |
16229 core.String id; | |
16230 /** | |
16231 * Properties for rich media popup windows. This field is used only for exit | |
16232 * events. | |
16233 */ | |
16234 PopupWindowProperties popupWindowProperties; | |
16235 /** | |
16236 * Target type used by the event. | |
16237 * Possible string values are: | |
16238 * - "TARGET_BLANK" | |
16239 * - "TARGET_PARENT" | |
16240 * - "TARGET_POPUP" | |
16241 * - "TARGET_SELF" | |
16242 * - "TARGET_TOP" | |
16243 */ | |
16244 core.String targetType; | |
16245 /** | |
16246 * Video reporting ID, used to differentiate multiple videos in a single | |
16247 * creative. This is a read-only field. | |
16248 */ | |
16249 core.String videoReportingId; | |
16250 | |
16251 CreativeCustomEvent(); | |
16252 | |
16253 CreativeCustomEvent.fromJson(core.Map _json) { | |
16254 if (_json.containsKey("advertiserCustomEventId")) { | |
16255 advertiserCustomEventId = _json["advertiserCustomEventId"]; | |
16256 } | |
16257 if (_json.containsKey("advertiserCustomEventName")) { | |
16258 advertiserCustomEventName = _json["advertiserCustomEventName"]; | |
16259 } | |
16260 if (_json.containsKey("advertiserCustomEventType")) { | |
16261 advertiserCustomEventType = _json["advertiserCustomEventType"]; | |
16262 } | |
16263 if (_json.containsKey("artworkLabel")) { | |
16264 artworkLabel = _json["artworkLabel"]; | |
16265 } | |
16266 if (_json.containsKey("artworkType")) { | |
16267 artworkType = _json["artworkType"]; | |
16268 } | |
16269 if (_json.containsKey("exitUrl")) { | |
16270 exitUrl = _json["exitUrl"]; | |
16271 } | |
16272 if (_json.containsKey("id")) { | |
16273 id = _json["id"]; | |
16274 } | |
16275 if (_json.containsKey("popupWindowProperties")) { | |
16276 popupWindowProperties = new PopupWindowProperties.fromJson(_json["popupWin
dowProperties"]); | |
16277 } | |
16278 if (_json.containsKey("targetType")) { | |
16279 targetType = _json["targetType"]; | |
16280 } | |
16281 if (_json.containsKey("videoReportingId")) { | |
16282 videoReportingId = _json["videoReportingId"]; | |
16283 } | |
16284 } | |
16285 | |
16286 core.Map toJson() { | |
16287 var _json = new core.Map(); | |
16288 if (advertiserCustomEventId != null) { | |
16289 _json["advertiserCustomEventId"] = advertiserCustomEventId; | |
16290 } | |
16291 if (advertiserCustomEventName != null) { | |
16292 _json["advertiserCustomEventName"] = advertiserCustomEventName; | |
16293 } | |
16294 if (advertiserCustomEventType != null) { | |
16295 _json["advertiserCustomEventType"] = advertiserCustomEventType; | |
16296 } | |
16297 if (artworkLabel != null) { | |
16298 _json["artworkLabel"] = artworkLabel; | |
16299 } | |
16300 if (artworkType != null) { | |
16301 _json["artworkType"] = artworkType; | |
16302 } | |
16303 if (exitUrl != null) { | |
16304 _json["exitUrl"] = exitUrl; | |
16305 } | |
16306 if (id != null) { | |
16307 _json["id"] = id; | |
16308 } | |
16309 if (popupWindowProperties != null) { | |
16310 _json["popupWindowProperties"] = (popupWindowProperties).toJson(); | |
16311 } | |
16312 if (targetType != null) { | |
16313 _json["targetType"] = targetType; | |
16314 } | |
16315 if (videoReportingId != null) { | |
16316 _json["videoReportingId"] = videoReportingId; | |
16317 } | |
16318 return _json; | |
16319 } | |
16320 } | |
16321 | |
16322 /** Contains properties of a creative field. */ | |
16323 class CreativeField { | |
16324 /** | |
16325 * Account ID of this creative field. This is a read-only field that can be | |
16326 * left blank. | |
16327 */ | |
16328 core.String accountId; | |
16329 /** | |
16330 * Advertiser ID of this creative field. This is a required field on | |
16331 * insertion. | |
16332 */ | |
16333 core.String advertiserId; | |
16334 /** | |
16335 * Dimension value for the ID of the advertiser. This is a read-only, | |
16336 * auto-generated field. | |
16337 */ | |
16338 DimensionValue advertiserIdDimensionValue; | |
16339 /** ID of this creative field. This is a read-only, auto-generated field. */ | |
16340 core.String id; | |
16341 /** | |
16342 * Identifies what kind of resource this is. Value: the fixed string | |
16343 * "dfareporting#creativeField". | |
16344 */ | |
16345 core.String kind; | |
16346 /** | |
16347 * Name of this creative field. This is a required field and must be less than | |
16348 * 256 characters long and unique among creative fields of the same | |
16349 * advertiser. | |
16350 */ | |
16351 core.String name; | |
16352 /** | |
16353 * Subaccount ID of this creative field. This is a read-only field that can be | |
16354 * left blank. | |
16355 */ | |
16356 core.String subaccountId; | |
16357 | |
16358 CreativeField(); | |
16359 | |
16360 CreativeField.fromJson(core.Map _json) { | |
16361 if (_json.containsKey("accountId")) { | |
16362 accountId = _json["accountId"]; | |
16363 } | |
16364 if (_json.containsKey("advertiserId")) { | |
16365 advertiserId = _json["advertiserId"]; | |
16366 } | |
16367 if (_json.containsKey("advertiserIdDimensionValue")) { | |
16368 advertiserIdDimensionValue = new DimensionValue.fromJson(_json["advertiser
IdDimensionValue"]); | |
16369 } | |
16370 if (_json.containsKey("id")) { | |
16371 id = _json["id"]; | |
16372 } | |
16373 if (_json.containsKey("kind")) { | |
16374 kind = _json["kind"]; | |
16375 } | |
16376 if (_json.containsKey("name")) { | |
16377 name = _json["name"]; | |
16378 } | |
16379 if (_json.containsKey("subaccountId")) { | |
16380 subaccountId = _json["subaccountId"]; | |
16381 } | |
16382 } | |
16383 | |
16384 core.Map toJson() { | |
16385 var _json = new core.Map(); | |
16386 if (accountId != null) { | |
16387 _json["accountId"] = accountId; | |
16388 } | |
16389 if (advertiserId != null) { | |
16390 _json["advertiserId"] = advertiserId; | |
16391 } | |
16392 if (advertiserIdDimensionValue != null) { | |
16393 _json["advertiserIdDimensionValue"] = (advertiserIdDimensionValue).toJson(
); | |
16394 } | |
16395 if (id != null) { | |
16396 _json["id"] = id; | |
16397 } | |
16398 if (kind != null) { | |
16399 _json["kind"] = kind; | |
16400 } | |
16401 if (name != null) { | |
16402 _json["name"] = name; | |
16403 } | |
16404 if (subaccountId != null) { | |
16405 _json["subaccountId"] = subaccountId; | |
16406 } | |
16407 return _json; | |
16408 } | |
16409 } | |
16410 | |
16411 /** Creative Field Assignment. */ | |
16412 class CreativeFieldAssignment { | |
16413 /** ID of the creative field. */ | |
16414 core.String creativeFieldId; | |
16415 /** ID of the creative field value. */ | |
16416 core.String creativeFieldValueId; | |
16417 | |
16418 CreativeFieldAssignment(); | |
16419 | |
16420 CreativeFieldAssignment.fromJson(core.Map _json) { | |
16421 if (_json.containsKey("creativeFieldId")) { | |
16422 creativeFieldId = _json["creativeFieldId"]; | |
16423 } | |
16424 if (_json.containsKey("creativeFieldValueId")) { | |
16425 creativeFieldValueId = _json["creativeFieldValueId"]; | |
16426 } | |
16427 } | |
16428 | |
16429 core.Map toJson() { | |
16430 var _json = new core.Map(); | |
16431 if (creativeFieldId != null) { | |
16432 _json["creativeFieldId"] = creativeFieldId; | |
16433 } | |
16434 if (creativeFieldValueId != null) { | |
16435 _json["creativeFieldValueId"] = creativeFieldValueId; | |
16436 } | |
16437 return _json; | |
16438 } | |
16439 } | |
16440 | |
16441 /** Contains properties of a creative field value. */ | |
16442 class CreativeFieldValue { | |
16443 /** | |
16444 * ID of this creative field value. This is a read-only, auto-generated field. | |
16445 */ | |
16446 core.String id; | |
16447 /** | |
16448 * Identifies what kind of resource this is. Value: the fixed string | |
16449 * "dfareporting#creativeFieldValue". | |
16450 */ | |
16451 core.String kind; | |
16452 /** | |
16453 * Value of this creative field value. It needs to be less than 256 characters | |
16454 * in length and unique per creative field. | |
16455 */ | |
16456 core.String value; | |
16457 | |
16458 CreativeFieldValue(); | |
16459 | |
16460 CreativeFieldValue.fromJson(core.Map _json) { | |
16461 if (_json.containsKey("id")) { | |
16462 id = _json["id"]; | |
16463 } | |
16464 if (_json.containsKey("kind")) { | |
16465 kind = _json["kind"]; | |
16466 } | |
16467 if (_json.containsKey("value")) { | |
16468 value = _json["value"]; | |
16469 } | |
16470 } | |
16471 | |
16472 core.Map toJson() { | |
16473 var _json = new core.Map(); | |
16474 if (id != null) { | |
16475 _json["id"] = id; | |
16476 } | |
16477 if (kind != null) { | |
16478 _json["kind"] = kind; | |
16479 } | |
16480 if (value != null) { | |
16481 _json["value"] = value; | |
16482 } | |
16483 return _json; | |
16484 } | |
16485 } | |
16486 | |
16487 /** Creative Field Value List Response */ | |
16488 class CreativeFieldValuesListResponse { | |
16489 /** Creative field value collection. */ | |
16490 core.List<CreativeFieldValue> creativeFieldValues; | |
16491 /** | |
16492 * Identifies what kind of resource this is. Value: the fixed string | |
16493 * "dfareporting#creativeFieldValuesListResponse". | |
16494 */ | |
16495 core.String kind; | |
16496 /** Pagination token to be used for the next list operation. */ | |
16497 core.String nextPageToken; | |
16498 | |
16499 CreativeFieldValuesListResponse(); | |
16500 | |
16501 CreativeFieldValuesListResponse.fromJson(core.Map _json) { | |
16502 if (_json.containsKey("creativeFieldValues")) { | |
16503 creativeFieldValues = _json["creativeFieldValues"].map((value) => new Crea
tiveFieldValue.fromJson(value)).toList(); | |
16504 } | |
16505 if (_json.containsKey("kind")) { | |
16506 kind = _json["kind"]; | |
16507 } | |
16508 if (_json.containsKey("nextPageToken")) { | |
16509 nextPageToken = _json["nextPageToken"]; | |
16510 } | |
16511 } | |
16512 | |
16513 core.Map toJson() { | |
16514 var _json = new core.Map(); | |
16515 if (creativeFieldValues != null) { | |
16516 _json["creativeFieldValues"] = creativeFieldValues.map((value) => (value).
toJson()).toList(); | |
16517 } | |
16518 if (kind != null) { | |
16519 _json["kind"] = kind; | |
16520 } | |
16521 if (nextPageToken != null) { | |
16522 _json["nextPageToken"] = nextPageToken; | |
16523 } | |
16524 return _json; | |
16525 } | |
16526 } | |
16527 | |
16528 /** Creative Field List Response */ | |
16529 class CreativeFieldsListResponse { | |
16530 /** Creative field collection. */ | |
16531 core.List<CreativeField> creativeFields; | |
16532 /** | |
16533 * Identifies what kind of resource this is. Value: the fixed string | |
16534 * "dfareporting#creativeFieldsListResponse". | |
16535 */ | |
16536 core.String kind; | |
16537 /** Pagination token to be used for the next list operation. */ | |
16538 core.String nextPageToken; | |
16539 | |
16540 CreativeFieldsListResponse(); | |
16541 | |
16542 CreativeFieldsListResponse.fromJson(core.Map _json) { | |
16543 if (_json.containsKey("creativeFields")) { | |
16544 creativeFields = _json["creativeFields"].map((value) => new CreativeField.
fromJson(value)).toList(); | |
16545 } | |
16546 if (_json.containsKey("kind")) { | |
16547 kind = _json["kind"]; | |
16548 } | |
16549 if (_json.containsKey("nextPageToken")) { | |
16550 nextPageToken = _json["nextPageToken"]; | |
16551 } | |
16552 } | |
16553 | |
16554 core.Map toJson() { | |
16555 var _json = new core.Map(); | |
16556 if (creativeFields != null) { | |
16557 _json["creativeFields"] = creativeFields.map((value) => (value).toJson()).
toList(); | |
16558 } | |
16559 if (kind != null) { | |
16560 _json["kind"] = kind; | |
16561 } | |
16562 if (nextPageToken != null) { | |
16563 _json["nextPageToken"] = nextPageToken; | |
16564 } | |
16565 return _json; | |
16566 } | |
16567 } | |
16568 | |
16569 /** Contains properties of a creative group. */ | |
16570 class CreativeGroup { | |
16571 /** | |
16572 * Account ID of this creative group. This is a read-only field that can be | |
16573 * left blank. | |
16574 */ | |
16575 core.String accountId; | |
16576 /** | |
16577 * Advertiser ID of this creative group. This is a required field on | |
16578 * insertion. | |
16579 */ | |
16580 core.String advertiserId; | |
16581 /** | |
16582 * Dimension value for the ID of the advertiser. This is a read-only, | |
16583 * auto-generated field. | |
16584 */ | |
16585 DimensionValue advertiserIdDimensionValue; | |
16586 /** | |
16587 * Subgroup of the creative group. Assign your creative groups to one of the | |
16588 * following subgroups in order to filter or manage them more easily. This | |
16589 * field is required on insertion and is read-only after insertion. | |
16590 * Acceptable values are: | |
16591 * - 1 | |
16592 * - 2 | |
16593 */ | |
16594 core.int groupNumber; | |
16595 /** ID of this creative group. This is a read-only, auto-generated field. */ | |
16596 core.String id; | |
16597 /** | |
16598 * Identifies what kind of resource this is. Value: the fixed string | |
16599 * "dfareporting#creativeGroup". | |
16600 */ | |
16601 core.String kind; | |
16602 /** | |
16603 * Name of this creative group. This is a required field and must be less than | |
16604 * 256 characters long and unique among creative groups of the same | |
16605 * advertiser. | |
16606 */ | |
16607 core.String name; | |
16608 /** | |
16609 * Subaccount ID of this creative group. This is a read-only field that can be | |
16610 * left blank. | |
16611 */ | |
16612 core.String subaccountId; | |
16613 | |
16614 CreativeGroup(); | |
16615 | |
16616 CreativeGroup.fromJson(core.Map _json) { | |
16617 if (_json.containsKey("accountId")) { | |
16618 accountId = _json["accountId"]; | |
16619 } | |
16620 if (_json.containsKey("advertiserId")) { | |
16621 advertiserId = _json["advertiserId"]; | |
16622 } | |
16623 if (_json.containsKey("advertiserIdDimensionValue")) { | |
16624 advertiserIdDimensionValue = new DimensionValue.fromJson(_json["advertiser
IdDimensionValue"]); | |
16625 } | |
16626 if (_json.containsKey("groupNumber")) { | |
16627 groupNumber = _json["groupNumber"]; | |
16628 } | |
16629 if (_json.containsKey("id")) { | |
16630 id = _json["id"]; | |
16631 } | |
16632 if (_json.containsKey("kind")) { | |
16633 kind = _json["kind"]; | |
16634 } | |
16635 if (_json.containsKey("name")) { | |
16636 name = _json["name"]; | |
16637 } | |
16638 if (_json.containsKey("subaccountId")) { | |
16639 subaccountId = _json["subaccountId"]; | |
16640 } | |
16641 } | |
16642 | |
16643 core.Map toJson() { | |
16644 var _json = new core.Map(); | |
16645 if (accountId != null) { | |
16646 _json["accountId"] = accountId; | |
16647 } | |
16648 if (advertiserId != null) { | |
16649 _json["advertiserId"] = advertiserId; | |
16650 } | |
16651 if (advertiserIdDimensionValue != null) { | |
16652 _json["advertiserIdDimensionValue"] = (advertiserIdDimensionValue).toJson(
); | |
16653 } | |
16654 if (groupNumber != null) { | |
16655 _json["groupNumber"] = groupNumber; | |
16656 } | |
16657 if (id != null) { | |
16658 _json["id"] = id; | |
16659 } | |
16660 if (kind != null) { | |
16661 _json["kind"] = kind; | |
16662 } | |
16663 if (name != null) { | |
16664 _json["name"] = name; | |
16665 } | |
16666 if (subaccountId != null) { | |
16667 _json["subaccountId"] = subaccountId; | |
16668 } | |
16669 return _json; | |
16670 } | |
16671 } | |
16672 | |
16673 /** Creative Group Assignment. */ | |
16674 class CreativeGroupAssignment { | |
16675 /** ID of the creative group to be assigned. */ | |
16676 core.String creativeGroupId; | |
16677 /** | |
16678 * Creative group number of the creative group assignment. | |
16679 * Possible string values are: | |
16680 * - "CREATIVE_GROUP_ONE" | |
16681 * - "CREATIVE_GROUP_TWO" | |
16682 */ | |
16683 core.String creativeGroupNumber; | |
16684 | |
16685 CreativeGroupAssignment(); | |
16686 | |
16687 CreativeGroupAssignment.fromJson(core.Map _json) { | |
16688 if (_json.containsKey("creativeGroupId")) { | |
16689 creativeGroupId = _json["creativeGroupId"]; | |
16690 } | |
16691 if (_json.containsKey("creativeGroupNumber")) { | |
16692 creativeGroupNumber = _json["creativeGroupNumber"]; | |
16693 } | |
16694 } | |
16695 | |
16696 core.Map toJson() { | |
16697 var _json = new core.Map(); | |
16698 if (creativeGroupId != null) { | |
16699 _json["creativeGroupId"] = creativeGroupId; | |
16700 } | |
16701 if (creativeGroupNumber != null) { | |
16702 _json["creativeGroupNumber"] = creativeGroupNumber; | |
16703 } | |
16704 return _json; | |
16705 } | |
16706 } | |
16707 | |
16708 /** Creative Group List Response */ | |
16709 class CreativeGroupsListResponse { | |
16710 /** Creative group collection. */ | |
16711 core.List<CreativeGroup> creativeGroups; | |
16712 /** | |
16713 * Identifies what kind of resource this is. Value: the fixed string | |
16714 * "dfareporting#creativeGroupsListResponse". | |
16715 */ | |
16716 core.String kind; | |
16717 /** Pagination token to be used for the next list operation. */ | |
16718 core.String nextPageToken; | |
16719 | |
16720 CreativeGroupsListResponse(); | |
16721 | |
16722 CreativeGroupsListResponse.fromJson(core.Map _json) { | |
16723 if (_json.containsKey("creativeGroups")) { | |
16724 creativeGroups = _json["creativeGroups"].map((value) => new CreativeGroup.
fromJson(value)).toList(); | |
16725 } | |
16726 if (_json.containsKey("kind")) { | |
16727 kind = _json["kind"]; | |
16728 } | |
16729 if (_json.containsKey("nextPageToken")) { | |
16730 nextPageToken = _json["nextPageToken"]; | |
16731 } | |
16732 } | |
16733 | |
16734 core.Map toJson() { | |
16735 var _json = new core.Map(); | |
16736 if (creativeGroups != null) { | |
16737 _json["creativeGroups"] = creativeGroups.map((value) => (value).toJson()).
toList(); | |
16738 } | |
16739 if (kind != null) { | |
16740 _json["kind"] = kind; | |
16741 } | |
16742 if (nextPageToken != null) { | |
16743 _json["nextPageToken"] = nextPageToken; | |
16744 } | |
16745 return _json; | |
16746 } | |
16747 } | |
16748 | |
16749 /** Creative optimization settings. */ | |
16750 class CreativeOptimizationConfiguration { | |
16751 /** | |
16752 * ID of this creative optimization config. This field is auto-generated when | |
16753 * the campaign is inserted or updated. It can be null for existing campaigns. | |
16754 */ | |
16755 core.String id; | |
16756 /** | |
16757 * Name of this creative optimization config. This is a required field and | |
16758 * must be less than 129 characters long. | |
16759 */ | |
16760 core.String name; | |
16761 /** List of optimization activities associated with this configuration. */ | |
16762 core.List<OptimizationActivity> optimizationActivitys; | |
16763 /** | |
16764 * Optimization model for this configuration. | |
16765 * Possible string values are: | |
16766 * - "CLICK" | |
16767 * - "POST_CLICK" | |
16768 * - "POST_CLICK_AND_IMPRESSION" | |
16769 * - "POST_IMPRESSION" | |
16770 * - "VIDEO_COMPLETION" | |
16771 */ | |
16772 core.String optimizationModel; | |
16773 | |
16774 CreativeOptimizationConfiguration(); | |
16775 | |
16776 CreativeOptimizationConfiguration.fromJson(core.Map _json) { | |
16777 if (_json.containsKey("id")) { | |
16778 id = _json["id"]; | |
16779 } | |
16780 if (_json.containsKey("name")) { | |
16781 name = _json["name"]; | |
16782 } | |
16783 if (_json.containsKey("optimizationActivitys")) { | |
16784 optimizationActivitys = _json["optimizationActivitys"].map((value) => new
OptimizationActivity.fromJson(value)).toList(); | |
16785 } | |
16786 if (_json.containsKey("optimizationModel")) { | |
16787 optimizationModel = _json["optimizationModel"]; | |
16788 } | |
16789 } | |
16790 | |
16791 core.Map toJson() { | |
16792 var _json = new core.Map(); | |
16793 if (id != null) { | |
16794 _json["id"] = id; | |
16795 } | |
16796 if (name != null) { | |
16797 _json["name"] = name; | |
16798 } | |
16799 if (optimizationActivitys != null) { | |
16800 _json["optimizationActivitys"] = optimizationActivitys.map((value) => (val
ue).toJson()).toList(); | |
16801 } | |
16802 if (optimizationModel != null) { | |
16803 _json["optimizationModel"] = optimizationModel; | |
16804 } | |
16805 return _json; | |
16806 } | |
16807 } | |
16808 | |
16809 /** Creative Rotation. */ | |
16810 class CreativeRotation { | |
16811 /** Creative assignments in this creative rotation. */ | |
16812 core.List<CreativeAssignment> creativeAssignments; | |
16813 /** | |
16814 * Creative optimization configuration that is used by this ad. It should | |
16815 * refer to one of the existing optimization configurations in the ad's | |
16816 * campaign. If it is unset or set to 0, then the campaign's default | |
16817 * optimization configuration will be used for this ad. | |
16818 */ | |
16819 core.String creativeOptimizationConfigurationId; | |
16820 /** | |
16821 * Type of creative rotation. Can be used to specify whether to use sequential | |
16822 * or random rotation. | |
16823 * Possible string values are: | |
16824 * - "CREATIVE_ROTATION_TYPE_RANDOM" | |
16825 * - "CREATIVE_ROTATION_TYPE_SEQUENTIAL" | |
16826 */ | |
16827 core.String type; | |
16828 /** | |
16829 * Strategy for calculating weights. Used with CREATIVE_ROTATION_TYPE_RANDOM. | |
16830 * Possible string values are: | |
16831 * - "WEIGHT_STRATEGY_CUSTOM" | |
16832 * - "WEIGHT_STRATEGY_EQUAL" | |
16833 * - "WEIGHT_STRATEGY_HIGHEST_CTR" | |
16834 * - "WEIGHT_STRATEGY_OPTIMIZED" | |
16835 */ | |
16836 core.String weightCalculationStrategy; | |
16837 | |
16838 CreativeRotation(); | |
16839 | |
16840 CreativeRotation.fromJson(core.Map _json) { | |
16841 if (_json.containsKey("creativeAssignments")) { | |
16842 creativeAssignments = _json["creativeAssignments"].map((value) => new Crea
tiveAssignment.fromJson(value)).toList(); | |
16843 } | |
16844 if (_json.containsKey("creativeOptimizationConfigurationId")) { | |
16845 creativeOptimizationConfigurationId = _json["creativeOptimizationConfigura
tionId"]; | |
16846 } | |
16847 if (_json.containsKey("type")) { | |
16848 type = _json["type"]; | |
16849 } | |
16850 if (_json.containsKey("weightCalculationStrategy")) { | |
16851 weightCalculationStrategy = _json["weightCalculationStrategy"]; | |
16852 } | |
16853 } | |
16854 | |
16855 core.Map toJson() { | |
16856 var _json = new core.Map(); | |
16857 if (creativeAssignments != null) { | |
16858 _json["creativeAssignments"] = creativeAssignments.map((value) => (value).
toJson()).toList(); | |
16859 } | |
16860 if (creativeOptimizationConfigurationId != null) { | |
16861 _json["creativeOptimizationConfigurationId"] = creativeOptimizationConfigu
rationId; | |
16862 } | |
16863 if (type != null) { | |
16864 _json["type"] = type; | |
16865 } | |
16866 if (weightCalculationStrategy != null) { | |
16867 _json["weightCalculationStrategy"] = weightCalculationStrategy; | |
16868 } | |
16869 return _json; | |
16870 } | |
16871 } | |
16872 | |
16873 /** Creative Settings */ | |
16874 class CreativeSettings { | |
16875 /** | |
16876 * Header text for iFrames for this site. Must be less than or equal to 2000 | |
16877 * characters long. | |
16878 */ | |
16879 core.String iFrameFooter; | |
16880 /** | |
16881 * Header text for iFrames for this site. Must be less than or equal to 2000 | |
16882 * characters long. | |
16883 */ | |
16884 core.String iFrameHeader; | |
16885 | |
16886 CreativeSettings(); | |
16887 | |
16888 CreativeSettings.fromJson(core.Map _json) { | |
16889 if (_json.containsKey("iFrameFooter")) { | |
16890 iFrameFooter = _json["iFrameFooter"]; | |
16891 } | |
16892 if (_json.containsKey("iFrameHeader")) { | |
16893 iFrameHeader = _json["iFrameHeader"]; | |
16894 } | |
16895 } | |
16896 | |
16897 core.Map toJson() { | |
16898 var _json = new core.Map(); | |
16899 if (iFrameFooter != null) { | |
16900 _json["iFrameFooter"] = iFrameFooter; | |
16901 } | |
16902 if (iFrameHeader != null) { | |
16903 _json["iFrameHeader"] = iFrameHeader; | |
16904 } | |
16905 return _json; | |
16906 } | |
16907 } | |
16908 | |
16909 /** Creative List Response */ | |
16910 class CreativesListResponse { | |
16911 /** Creative collection. */ | |
16912 core.List<Creative> creatives; | |
16913 /** | |
16914 * Identifies what kind of resource this is. Value: the fixed string | |
16915 * "dfareporting#creativesListResponse". | |
16916 */ | |
16917 core.String kind; | |
16918 /** Pagination token to be used for the next list operation. */ | |
16919 core.String nextPageToken; | |
16920 | |
16921 CreativesListResponse(); | |
16922 | |
16923 CreativesListResponse.fromJson(core.Map _json) { | |
16924 if (_json.containsKey("creatives")) { | |
16925 creatives = _json["creatives"].map((value) => new Creative.fromJson(value)
).toList(); | |
16926 } | |
16927 if (_json.containsKey("kind")) { | |
16928 kind = _json["kind"]; | |
16929 } | |
16930 if (_json.containsKey("nextPageToken")) { | |
16931 nextPageToken = _json["nextPageToken"]; | |
16932 } | |
16933 } | |
16934 | |
16935 core.Map toJson() { | |
16936 var _json = new core.Map(); | |
16937 if (creatives != null) { | |
16938 _json["creatives"] = creatives.map((value) => (value).toJson()).toList(); | |
16939 } | |
16940 if (kind != null) { | |
16941 _json["kind"] = kind; | |
16942 } | |
16943 if (nextPageToken != null) { | |
16944 _json["nextPageToken"] = nextPageToken; | |
16945 } | |
16946 return _json; | |
16947 } | |
16948 } | |
16949 | |
16950 /** | |
16951 * Represents fields that are compatible to be selected for a report of type | |
16952 * "CROSS_DIMENSION_REACH". | |
16953 */ | |
16954 class CrossDimensionReachReportCompatibleFields { | |
16955 /** | |
16956 * Dimensions which are compatible to be selected in the "breakdown" section | |
16957 * of the report. | |
16958 */ | |
16959 core.List<Dimension> breakdown; | |
16960 /** | |
16961 * Dimensions which are compatible to be selected in the "dimensionFilters" | |
16962 * section of the report. | |
16963 */ | |
16964 core.List<Dimension> dimensionFilters; | |
16965 /** | |
16966 * The kind of resource this is, in this case | |
16967 * dfareporting#crossDimensionReachReportCompatibleFields. | |
16968 */ | |
16969 core.String kind; | |
16970 /** | |
16971 * Metrics which are compatible to be selected in the "metricNames" section of | |
16972 * the report. | |
16973 */ | |
16974 core.List<Metric> metrics; | |
16975 /** | |
16976 * Metrics which are compatible to be selected in the "overlapMetricNames" | |
16977 * section of the report. | |
16978 */ | |
16979 core.List<Metric> overlapMetrics; | |
16980 | |
16981 CrossDimensionReachReportCompatibleFields(); | |
16982 | |
16983 CrossDimensionReachReportCompatibleFields.fromJson(core.Map _json) { | |
16984 if (_json.containsKey("breakdown")) { | |
16985 breakdown = _json["breakdown"].map((value) => new Dimension.fromJson(value
)).toList(); | |
16986 } | |
16987 if (_json.containsKey("dimensionFilters")) { | |
16988 dimensionFilters = _json["dimensionFilters"].map((value) => new Dimension.
fromJson(value)).toList(); | |
16989 } | |
16990 if (_json.containsKey("kind")) { | |
16991 kind = _json["kind"]; | |
16992 } | |
16993 if (_json.containsKey("metrics")) { | |
16994 metrics = _json["metrics"].map((value) => new Metric.fromJson(value)).toLi
st(); | |
16995 } | |
16996 if (_json.containsKey("overlapMetrics")) { | |
16997 overlapMetrics = _json["overlapMetrics"].map((value) => new Metric.fromJso
n(value)).toList(); | |
16998 } | |
16999 } | |
17000 | |
17001 core.Map toJson() { | |
17002 var _json = new core.Map(); | |
17003 if (breakdown != null) { | |
17004 _json["breakdown"] = breakdown.map((value) => (value).toJson()).toList(); | |
17005 } | |
17006 if (dimensionFilters != null) { | |
17007 _json["dimensionFilters"] = dimensionFilters.map((value) => (value).toJson
()).toList(); | |
17008 } | |
17009 if (kind != null) { | |
17010 _json["kind"] = kind; | |
17011 } | |
17012 if (metrics != null) { | |
17013 _json["metrics"] = metrics.map((value) => (value).toJson()).toList(); | |
17014 } | |
17015 if (overlapMetrics != null) { | |
17016 _json["overlapMetrics"] = overlapMetrics.map((value) => (value).toJson()).
toList(); | |
17017 } | |
17018 return _json; | |
17019 } | |
17020 } | |
17021 | |
17022 /** Represents a Custom Rich Media Events group. */ | |
17023 class CustomRichMediaEvents { | |
17024 /** | |
17025 * List of custom rich media event IDs. Dimension values must be all of type | |
17026 * dfa:richMediaEventTypeIdAndName. | |
17027 */ | |
17028 core.List<DimensionValue> filteredEventIds; | |
17029 /** | |
17030 * The kind of resource this is, in this case | |
17031 * dfareporting#customRichMediaEvents. | |
17032 */ | |
17033 core.String kind; | |
17034 | |
17035 CustomRichMediaEvents(); | |
17036 | |
17037 CustomRichMediaEvents.fromJson(core.Map _json) { | |
17038 if (_json.containsKey("filteredEventIds")) { | |
17039 filteredEventIds = _json["filteredEventIds"].map((value) => new DimensionV
alue.fromJson(value)).toList(); | |
17040 } | |
17041 if (_json.containsKey("kind")) { | |
17042 kind = _json["kind"]; | |
17043 } | |
17044 } | |
17045 | |
17046 core.Map toJson() { | |
17047 var _json = new core.Map(); | |
17048 if (filteredEventIds != null) { | |
17049 _json["filteredEventIds"] = filteredEventIds.map((value) => (value).toJson
()).toList(); | |
17050 } | |
17051 if (kind != null) { | |
17052 _json["kind"] = kind; | |
17053 } | |
17054 return _json; | |
17055 } | |
17056 } | |
17057 | |
17058 /** Represents a date range. */ | |
17059 class DateRange { | |
17060 /** | |
17061 * The end date of the date range, inclusive. A string of the format: | |
17062 * "yyyy-MM-dd". | |
17063 */ | |
17064 core.DateTime endDate; | |
17065 /** The kind of resource this is, in this case dfareporting#dateRange. */ | |
17066 core.String kind; | |
17067 /** | |
17068 * The date range relative to the date of when the report is run. | |
17069 * Possible string values are: | |
17070 * - "LAST_24_MONTHS" | |
17071 * - "LAST_30_DAYS" | |
17072 * - "LAST_365_DAYS" | |
17073 * - "LAST_7_DAYS" | |
17074 * - "LAST_90_DAYS" | |
17075 * - "MONTH_TO_DATE" | |
17076 * - "PREVIOUS_MONTH" | |
17077 * - "PREVIOUS_QUARTER" | |
17078 * - "PREVIOUS_WEEK" | |
17079 * - "PREVIOUS_YEAR" | |
17080 * - "QUARTER_TO_DATE" | |
17081 * - "TODAY" | |
17082 * - "WEEK_TO_DATE" | |
17083 * - "YEAR_TO_DATE" | |
17084 * - "YESTERDAY" | |
17085 */ | |
17086 core.String relativeDateRange; | |
17087 /** | |
17088 * The start date of the date range, inclusive. A string of the format: | |
17089 * "yyyy-MM-dd". | |
17090 */ | |
17091 core.DateTime startDate; | |
17092 | |
17093 DateRange(); | |
17094 | |
17095 DateRange.fromJson(core.Map _json) { | |
17096 if (_json.containsKey("endDate")) { | |
17097 endDate = core.DateTime.parse(_json["endDate"]); | |
17098 } | |
17099 if (_json.containsKey("kind")) { | |
17100 kind = _json["kind"]; | |
17101 } | |
17102 if (_json.containsKey("relativeDateRange")) { | |
17103 relativeDateRange = _json["relativeDateRange"]; | |
17104 } | |
17105 if (_json.containsKey("startDate")) { | |
17106 startDate = core.DateTime.parse(_json["startDate"]); | |
17107 } | |
17108 } | |
17109 | |
17110 core.Map toJson() { | |
17111 var _json = new core.Map(); | |
17112 if (endDate != null) { | |
17113 _json["endDate"] = "${(endDate).year.toString().padLeft(4, '0')}-${(endDat
e).month.toString().padLeft(2, '0')}-${(endDate).day.toString().padLeft(2, '0')}
"; | |
17114 } | |
17115 if (kind != null) { | |
17116 _json["kind"] = kind; | |
17117 } | |
17118 if (relativeDateRange != null) { | |
17119 _json["relativeDateRange"] = relativeDateRange; | |
17120 } | |
17121 if (startDate != null) { | |
17122 _json["startDate"] = "${(startDate).year.toString().padLeft(4, '0')}-${(st
artDate).month.toString().padLeft(2, '0')}-${(startDate).day.toString().padLeft(
2, '0')}"; | |
17123 } | |
17124 return _json; | |
17125 } | |
17126 } | |
17127 | |
17128 /** Day Part Targeting. */ | |
17129 class DayPartTargeting { | |
17130 /** | |
17131 * Days of the week when the ad will serve. | |
17132 * | |
17133 * Acceptable values are: | |
17134 * - "SUNDAY" | |
17135 * - "MONDAY" | |
17136 * - "TUESDAY" | |
17137 * - "WEDNESDAY" | |
17138 * - "THURSDAY" | |
17139 * - "FRIDAY" | |
17140 * - "SATURDAY" | |
17141 */ | |
17142 core.List<core.String> daysOfWeek; | |
17143 /** | |
17144 * Hours of the day when the ad will serve. Must be an integer between 0 and | |
17145 * 23 (inclusive), where 0 is midnight to 1 AM, and 23 is 11 PM to midnight. | |
17146 * Can be specified with days of week, in which case the ad would serve during | |
17147 * these hours on the specified days. For example, if Monday, Wednesday, | |
17148 * Friday are the days of week specified and 9-10am, 3-5pm (hours 9, 15, and | |
17149 * 16) is specified, the ad would serve Monday, Wednesdays, and Fridays at | |
17150 * 9-10am and 3-5pm. | |
17151 */ | |
17152 core.List<core.int> hoursOfDay; | |
17153 /** | |
17154 * Whether or not to use the user's local time. If false, the America/New York | |
17155 * time zone applies. | |
17156 */ | |
17157 core.bool userLocalTime; | |
17158 | |
17159 DayPartTargeting(); | |
17160 | |
17161 DayPartTargeting.fromJson(core.Map _json) { | |
17162 if (_json.containsKey("daysOfWeek")) { | |
17163 daysOfWeek = _json["daysOfWeek"]; | |
17164 } | |
17165 if (_json.containsKey("hoursOfDay")) { | |
17166 hoursOfDay = _json["hoursOfDay"]; | |
17167 } | |
17168 if (_json.containsKey("userLocalTime")) { | |
17169 userLocalTime = _json["userLocalTime"]; | |
17170 } | |
17171 } | |
17172 | |
17173 core.Map toJson() { | |
17174 var _json = new core.Map(); | |
17175 if (daysOfWeek != null) { | |
17176 _json["daysOfWeek"] = daysOfWeek; | |
17177 } | |
17178 if (hoursOfDay != null) { | |
17179 _json["hoursOfDay"] = hoursOfDay; | |
17180 } | |
17181 if (userLocalTime != null) { | |
17182 _json["userLocalTime"] = userLocalTime; | |
17183 } | |
17184 return _json; | |
17185 } | |
17186 } | |
17187 | |
17188 /** | |
17189 * Properties of inheriting and overriding the default click-through event tag. | |
17190 * A campaign may override the event tag defined at the advertiser level, and an | |
17191 * ad may also override the campaign's setting further. | |
17192 */ | |
17193 class DefaultClickThroughEventTagProperties { | |
17194 /** | |
17195 * ID of the click-through event tag to apply to all ads in this entity's | |
17196 * scope. | |
17197 */ | |
17198 core.String defaultClickThroughEventTagId; | |
17199 /** | |
17200 * Whether this entity should override the inherited default click-through | |
17201 * event tag with its own defined value. | |
17202 */ | |
17203 core.bool overrideInheritedEventTag; | |
17204 | |
17205 DefaultClickThroughEventTagProperties(); | |
17206 | |
17207 DefaultClickThroughEventTagProperties.fromJson(core.Map _json) { | |
17208 if (_json.containsKey("defaultClickThroughEventTagId")) { | |
17209 defaultClickThroughEventTagId = _json["defaultClickThroughEventTagId"]; | |
17210 } | |
17211 if (_json.containsKey("overrideInheritedEventTag")) { | |
17212 overrideInheritedEventTag = _json["overrideInheritedEventTag"]; | |
17213 } | |
17214 } | |
17215 | |
17216 core.Map toJson() { | |
17217 var _json = new core.Map(); | |
17218 if (defaultClickThroughEventTagId != null) { | |
17219 _json["defaultClickThroughEventTagId"] = defaultClickThroughEventTagId; | |
17220 } | |
17221 if (overrideInheritedEventTag != null) { | |
17222 _json["overrideInheritedEventTag"] = overrideInheritedEventTag; | |
17223 } | |
17224 return _json; | |
17225 } | |
17226 } | |
17227 | |
17228 /** Delivery Schedule. */ | |
17229 class DeliverySchedule { | |
17230 /** | |
17231 * Limit on the number of times an individual user can be served the ad within | |
17232 * a specified period of time. | |
17233 */ | |
17234 FrequencyCap frequencyCap; | |
17235 /** | |
17236 * Whether or not hard cutoff is enabled. If true, the ad will not serve after | |
17237 * the end date and time. Otherwise the ad will continue to be served until it | |
17238 * has reached its delivery goals. | |
17239 */ | |
17240 core.bool hardCutoff; | |
17241 /** | |
17242 * Impression ratio for this ad. This ratio determines how often each ad is | |
17243 * served relative to the others. For example, if ad A has an impression ratio | |
17244 * of 1 and ad B has an impression ratio of 3, then DCM will serve ad B three | |
17245 * times as often as ad A. Must be between 1 and 10. | |
17246 */ | |
17247 core.String impressionRatio; | |
17248 /** | |
17249 * Serving priority of an ad, with respect to other ads. The lower the | |
17250 * priority number, the greater the priority with which it is served. | |
17251 * Possible string values are: | |
17252 * - "AD_PRIORITY_01" | |
17253 * - "AD_PRIORITY_02" | |
17254 * - "AD_PRIORITY_03" | |
17255 * - "AD_PRIORITY_04" | |
17256 * - "AD_PRIORITY_05" | |
17257 * - "AD_PRIORITY_06" | |
17258 * - "AD_PRIORITY_07" | |
17259 * - "AD_PRIORITY_08" | |
17260 * - "AD_PRIORITY_09" | |
17261 * - "AD_PRIORITY_10" | |
17262 * - "AD_PRIORITY_11" | |
17263 * - "AD_PRIORITY_12" | |
17264 * - "AD_PRIORITY_13" | |
17265 * - "AD_PRIORITY_14" | |
17266 * - "AD_PRIORITY_15" | |
17267 * - "AD_PRIORITY_16" | |
17268 */ | |
17269 core.String priority; | |
17270 | |
17271 DeliverySchedule(); | |
17272 | |
17273 DeliverySchedule.fromJson(core.Map _json) { | |
17274 if (_json.containsKey("frequencyCap")) { | |
17275 frequencyCap = new FrequencyCap.fromJson(_json["frequencyCap"]); | |
17276 } | |
17277 if (_json.containsKey("hardCutoff")) { | |
17278 hardCutoff = _json["hardCutoff"]; | |
17279 } | |
17280 if (_json.containsKey("impressionRatio")) { | |
17281 impressionRatio = _json["impressionRatio"]; | |
17282 } | |
17283 if (_json.containsKey("priority")) { | |
17284 priority = _json["priority"]; | |
17285 } | |
17286 } | |
17287 | |
17288 core.Map toJson() { | |
17289 var _json = new core.Map(); | |
17290 if (frequencyCap != null) { | |
17291 _json["frequencyCap"] = (frequencyCap).toJson(); | |
17292 } | |
17293 if (hardCutoff != null) { | |
17294 _json["hardCutoff"] = hardCutoff; | |
17295 } | |
17296 if (impressionRatio != null) { | |
17297 _json["impressionRatio"] = impressionRatio; | |
17298 } | |
17299 if (priority != null) { | |
17300 _json["priority"] = priority; | |
17301 } | |
17302 return _json; | |
17303 } | |
17304 } | |
17305 | |
17306 /** DFP Settings */ | |
17307 class DfpSettings { | |
17308 /** DFP network code for this directory site. */ | |
17309 core.String dfpNetworkCode; | |
17310 /** DFP network name for this directory site. */ | |
17311 core.String dfpNetworkName; | |
17312 /** Whether this directory site accepts programmatic placements. */ | |
17313 core.bool programmaticPlacementAccepted; | |
17314 /** Whether this directory site accepts publisher-paid tags. */ | |
17315 core.bool pubPaidPlacementAccepted; | |
17316 /** | |
17317 * Whether this directory site is available only via DoubleClick Publisher | |
17318 * Portal. | |
17319 */ | |
17320 core.bool publisherPortalOnly; | |
17321 | |
17322 DfpSettings(); | |
17323 | |
17324 DfpSettings.fromJson(core.Map _json) { | |
17325 if (_json.containsKey("dfp_network_code")) { | |
17326 dfpNetworkCode = _json["dfp_network_code"]; | |
17327 } | |
17328 if (_json.containsKey("dfp_network_name")) { | |
17329 dfpNetworkName = _json["dfp_network_name"]; | |
17330 } | |
17331 if (_json.containsKey("programmaticPlacementAccepted")) { | |
17332 programmaticPlacementAccepted = _json["programmaticPlacementAccepted"]; | |
17333 } | |
17334 if (_json.containsKey("pubPaidPlacementAccepted")) { | |
17335 pubPaidPlacementAccepted = _json["pubPaidPlacementAccepted"]; | |
17336 } | |
17337 if (_json.containsKey("publisherPortalOnly")) { | |
17338 publisherPortalOnly = _json["publisherPortalOnly"]; | |
17339 } | |
17340 } | |
17341 | |
17342 core.Map toJson() { | |
17343 var _json = new core.Map(); | |
17344 if (dfpNetworkCode != null) { | |
17345 _json["dfp_network_code"] = dfpNetworkCode; | |
17346 } | |
17347 if (dfpNetworkName != null) { | |
17348 _json["dfp_network_name"] = dfpNetworkName; | |
17349 } | |
17350 if (programmaticPlacementAccepted != null) { | |
17351 _json["programmaticPlacementAccepted"] = programmaticPlacementAccepted; | |
17352 } | |
17353 if (pubPaidPlacementAccepted != null) { | |
17354 _json["pubPaidPlacementAccepted"] = pubPaidPlacementAccepted; | |
17355 } | |
17356 if (publisherPortalOnly != null) { | |
17357 _json["publisherPortalOnly"] = publisherPortalOnly; | |
17358 } | |
17359 return _json; | |
17360 } | |
17361 } | |
17362 | |
17363 /** Represents a dimension. */ | |
17364 class Dimension { | |
17365 /** The kind of resource this is, in this case dfareporting#dimension. */ | |
17366 core.String kind; | |
17367 /** The dimension name, e.g. dfa:advertiser */ | |
17368 core.String name; | |
17369 | |
17370 Dimension(); | |
17371 | |
17372 Dimension.fromJson(core.Map _json) { | |
17373 if (_json.containsKey("kind")) { | |
17374 kind = _json["kind"]; | |
17375 } | |
17376 if (_json.containsKey("name")) { | |
17377 name = _json["name"]; | |
17378 } | |
17379 } | |
17380 | |
17381 core.Map toJson() { | |
17382 var _json = new core.Map(); | |
17383 if (kind != null) { | |
17384 _json["kind"] = kind; | |
17385 } | |
17386 if (name != null) { | |
17387 _json["name"] = name; | |
17388 } | |
17389 return _json; | |
17390 } | |
17391 } | |
17392 | |
17393 /** Represents a dimension filter. */ | |
17394 class DimensionFilter { | |
17395 /** The name of the dimension to filter. */ | |
17396 core.String dimensionName; | |
17397 /** | |
17398 * The kind of resource this is, in this case dfareporting#dimensionFilter. | |
17399 */ | |
17400 core.String kind; | |
17401 /** The value of the dimension to filter. */ | |
17402 core.String value; | |
17403 | |
17404 DimensionFilter(); | |
17405 | |
17406 DimensionFilter.fromJson(core.Map _json) { | |
17407 if (_json.containsKey("dimensionName")) { | |
17408 dimensionName = _json["dimensionName"]; | |
17409 } | |
17410 if (_json.containsKey("kind")) { | |
17411 kind = _json["kind"]; | |
17412 } | |
17413 if (_json.containsKey("value")) { | |
17414 value = _json["value"]; | |
17415 } | |
17416 } | |
17417 | |
17418 core.Map toJson() { | |
17419 var _json = new core.Map(); | |
17420 if (dimensionName != null) { | |
17421 _json["dimensionName"] = dimensionName; | |
17422 } | |
17423 if (kind != null) { | |
17424 _json["kind"] = kind; | |
17425 } | |
17426 if (value != null) { | |
17427 _json["value"] = value; | |
17428 } | |
17429 return _json; | |
17430 } | |
17431 } | |
17432 | |
17433 /** Represents a DimensionValue resource. */ | |
17434 class DimensionValue { | |
17435 /** The name of the dimension. */ | |
17436 core.String dimensionName; | |
17437 /** The eTag of this response for caching purposes. */ | |
17438 core.String etag; | |
17439 /** The ID associated with the value if available. */ | |
17440 core.String id; | |
17441 /** | |
17442 * The kind of resource this is, in this case dfareporting#dimensionValue. | |
17443 */ | |
17444 core.String kind; | |
17445 /** | |
17446 * Determines how the 'value' field is matched when filtering. If not | |
17447 * specified, defaults to EXACT. If set to WILDCARD_EXPRESSION, '*' is allowed | |
17448 * as a placeholder for variable length character sequences, and it can be | |
17449 * escaped with a backslash. Note, only paid search dimensions | |
17450 * ('dfa:paidSearch*') allow a matchType other than EXACT. | |
17451 * Possible string values are: | |
17452 * - "BEGINS_WITH" | |
17453 * - "CONTAINS" | |
17454 * - "EXACT" | |
17455 * - "WILDCARD_EXPRESSION" | |
17456 */ | |
17457 core.String matchType; | |
17458 /** The value of the dimension. */ | |
17459 core.String value; | |
17460 | |
17461 DimensionValue(); | |
17462 | |
17463 DimensionValue.fromJson(core.Map _json) { | |
17464 if (_json.containsKey("dimensionName")) { | |
17465 dimensionName = _json["dimensionName"]; | |
17466 } | |
17467 if (_json.containsKey("etag")) { | |
17468 etag = _json["etag"]; | |
17469 } | |
17470 if (_json.containsKey("id")) { | |
17471 id = _json["id"]; | |
17472 } | |
17473 if (_json.containsKey("kind")) { | |
17474 kind = _json["kind"]; | |
17475 } | |
17476 if (_json.containsKey("matchType")) { | |
17477 matchType = _json["matchType"]; | |
17478 } | |
17479 if (_json.containsKey("value")) { | |
17480 value = _json["value"]; | |
17481 } | |
17482 } | |
17483 | |
17484 core.Map toJson() { | |
17485 var _json = new core.Map(); | |
17486 if (dimensionName != null) { | |
17487 _json["dimensionName"] = dimensionName; | |
17488 } | |
17489 if (etag != null) { | |
17490 _json["etag"] = etag; | |
17491 } | |
17492 if (id != null) { | |
17493 _json["id"] = id; | |
17494 } | |
17495 if (kind != null) { | |
17496 _json["kind"] = kind; | |
17497 } | |
17498 if (matchType != null) { | |
17499 _json["matchType"] = matchType; | |
17500 } | |
17501 if (value != null) { | |
17502 _json["value"] = value; | |
17503 } | |
17504 return _json; | |
17505 } | |
17506 } | |
17507 | |
17508 /** Represents the list of DimensionValue resources. */ | |
17509 class DimensionValueList { | |
17510 /** The eTag of this response for caching purposes. */ | |
17511 core.String etag; | |
17512 /** The dimension values returned in this response. */ | |
17513 core.List<DimensionValue> items; | |
17514 /** | |
17515 * The kind of list this is, in this case dfareporting#dimensionValueList. | |
17516 */ | |
17517 core.String kind; | |
17518 /** | |
17519 * Continuation token used to page through dimension values. To retrieve the | |
17520 * next page of results, set the next request's "pageToken" to the value of | |
17521 * this field. The page token is only valid for a limited amount of time and | |
17522 * should not be persisted. | |
17523 */ | |
17524 core.String nextPageToken; | |
17525 | |
17526 DimensionValueList(); | |
17527 | |
17528 DimensionValueList.fromJson(core.Map _json) { | |
17529 if (_json.containsKey("etag")) { | |
17530 etag = _json["etag"]; | |
17531 } | |
17532 if (_json.containsKey("items")) { | |
17533 items = _json["items"].map((value) => new DimensionValue.fromJson(value)).
toList(); | |
17534 } | |
17535 if (_json.containsKey("kind")) { | |
17536 kind = _json["kind"]; | |
17537 } | |
17538 if (_json.containsKey("nextPageToken")) { | |
17539 nextPageToken = _json["nextPageToken"]; | |
17540 } | |
17541 } | |
17542 | |
17543 core.Map toJson() { | |
17544 var _json = new core.Map(); | |
17545 if (etag != null) { | |
17546 _json["etag"] = etag; | |
17547 } | |
17548 if (items != null) { | |
17549 _json["items"] = items.map((value) => (value).toJson()).toList(); | |
17550 } | |
17551 if (kind != null) { | |
17552 _json["kind"] = kind; | |
17553 } | |
17554 if (nextPageToken != null) { | |
17555 _json["nextPageToken"] = nextPageToken; | |
17556 } | |
17557 return _json; | |
17558 } | |
17559 } | |
17560 | |
17561 /** Represents a DimensionValuesRequest. */ | |
17562 class DimensionValueRequest { | |
17563 /** The name of the dimension for which values should be requested. */ | |
17564 core.String dimensionName; | |
17565 /** | |
17566 * The end date of the date range for which to retrieve dimension values. A | |
17567 * string of the format "yyyy-MM-dd". | |
17568 */ | |
17569 core.DateTime endDate; | |
17570 /** The list of filters by which to filter values. The filters are ANDed. */ | |
17571 core.List<DimensionFilter> filters; | |
17572 /** | |
17573 * The kind of request this is, in this case | |
17574 * dfareporting#dimensionValueRequest. | |
17575 */ | |
17576 core.String kind; | |
17577 /** | |
17578 * The start date of the date range for which to retrieve dimension values. A | |
17579 * string of the format "yyyy-MM-dd". | |
17580 */ | |
17581 core.DateTime startDate; | |
17582 | |
17583 DimensionValueRequest(); | |
17584 | |
17585 DimensionValueRequest.fromJson(core.Map _json) { | |
17586 if (_json.containsKey("dimensionName")) { | |
17587 dimensionName = _json["dimensionName"]; | |
17588 } | |
17589 if (_json.containsKey("endDate")) { | |
17590 endDate = core.DateTime.parse(_json["endDate"]); | |
17591 } | |
17592 if (_json.containsKey("filters")) { | |
17593 filters = _json["filters"].map((value) => new DimensionFilter.fromJson(val
ue)).toList(); | |
17594 } | |
17595 if (_json.containsKey("kind")) { | |
17596 kind = _json["kind"]; | |
17597 } | |
17598 if (_json.containsKey("startDate")) { | |
17599 startDate = core.DateTime.parse(_json["startDate"]); | |
17600 } | |
17601 } | |
17602 | |
17603 core.Map toJson() { | |
17604 var _json = new core.Map(); | |
17605 if (dimensionName != null) { | |
17606 _json["dimensionName"] = dimensionName; | |
17607 } | |
17608 if (endDate != null) { | |
17609 _json["endDate"] = "${(endDate).year.toString().padLeft(4, '0')}-${(endDat
e).month.toString().padLeft(2, '0')}-${(endDate).day.toString().padLeft(2, '0')}
"; | |
17610 } | |
17611 if (filters != null) { | |
17612 _json["filters"] = filters.map((value) => (value).toJson()).toList(); | |
17613 } | |
17614 if (kind != null) { | |
17615 _json["kind"] = kind; | |
17616 } | |
17617 if (startDate != null) { | |
17618 _json["startDate"] = "${(startDate).year.toString().padLeft(4, '0')}-${(st
artDate).month.toString().padLeft(2, '0')}-${(startDate).day.toString().padLeft(
2, '0')}"; | |
17619 } | |
17620 return _json; | |
17621 } | |
17622 } | |
17623 | |
17624 /** | |
17625 * DirectorySites contains properties of a website from the Site Directory. | |
17626 * Sites need to be added to an account via the Sites resource before they can | |
17627 * be assigned to a placement. | |
17628 */ | |
17629 class DirectorySite { | |
17630 /** Whether this directory site is active. */ | |
17631 core.bool active; | |
17632 /** Directory site contacts. */ | |
17633 core.List<DirectorySiteContactAssignment> contactAssignments; | |
17634 /** Country ID of this directory site. */ | |
17635 core.String countryId; | |
17636 /** | |
17637 * Currency ID of this directory site. | |
17638 * Possible values are: | |
17639 * - "1" for USD | |
17640 * - "2" for GBP | |
17641 * - "3" for ESP | |
17642 * - "4" for SEK | |
17643 * - "5" for CAD | |
17644 * - "6" for JPY | |
17645 * - "7" for DEM | |
17646 * - "8" for AUD | |
17647 * - "9" for FRF | |
17648 * - "10" for ITL | |
17649 * - "11" for DKK | |
17650 * - "12" for NOK | |
17651 * - "13" for FIM | |
17652 * - "14" for ZAR | |
17653 * - "15" for IEP | |
17654 * - "16" for NLG | |
17655 * - "17" for EUR | |
17656 * - "18" for KRW | |
17657 * - "19" for TWD | |
17658 * - "20" for SGD | |
17659 * - "21" for CNY | |
17660 * - "22" for HKD | |
17661 * - "23" for NZD | |
17662 * - "24" for MYR | |
17663 * - "25" for BRL | |
17664 * - "26" for PTE | |
17665 * - "27" for MXP | |
17666 * - "28" for CLP | |
17667 * - "29" for TRY | |
17668 * - "30" for ARS | |
17669 * - "31" for PEN | |
17670 * - "32" for ILS | |
17671 * - "33" for CHF | |
17672 * - "34" for VEF | |
17673 * - "35" for COP | |
17674 * - "36" for GTQ | |
17675 * - "37" for PLN | |
17676 * - "39" for INR | |
17677 * - "40" for THB | |
17678 * - "41" for IDR | |
17679 * - "42" for CZK | |
17680 * - "43" for RON | |
17681 * - "44" for HUF | |
17682 * - "45" for RUB | |
17683 * - "46" for AED | |
17684 * - "47" for BGN | |
17685 * - "48" for HRK | |
17686 */ | |
17687 core.String currencyId; | |
17688 /** Description of this directory site. */ | |
17689 core.String description; | |
17690 /** ID of this directory site. This is a read-only, auto-generated field. */ | |
17691 core.String id; | |
17692 /** | |
17693 * Dimension value for the ID of this directory site. This is a read-only, | |
17694 * auto-generated field. | |
17695 */ | |
17696 DimensionValue idDimensionValue; | |
17697 /** | |
17698 * Tag types for regular placements. | |
17699 * | |
17700 * Acceptable values are: | |
17701 * - "STANDARD" | |
17702 * - "IFRAME_JAVASCRIPT_INPAGE" | |
17703 * - "INTERNAL_REDIRECT_INPAGE" | |
17704 * - "JAVASCRIPT_INPAGE" | |
17705 */ | |
17706 core.List<core.String> inpageTagFormats; | |
17707 /** | |
17708 * Tag types for interstitial placements. | |
17709 * | |
17710 * Acceptable values are: | |
17711 * - "IFRAME_JAVASCRIPT_INTERSTITIAL" | |
17712 * - "INTERNAL_REDIRECT_INTERSTITIAL" | |
17713 * - "JAVASCRIPT_INTERSTITIAL" | |
17714 */ | |
17715 core.List<core.String> interstitialTagFormats; | |
17716 /** | |
17717 * Identifies what kind of resource this is. Value: the fixed string | |
17718 * "dfareporting#directorySite". | |
17719 */ | |
17720 core.String kind; | |
17721 /** Name of this directory site. */ | |
17722 core.String name; | |
17723 /** Parent directory site ID. */ | |
17724 core.String parentId; | |
17725 /** Directory site settings. */ | |
17726 DirectorySiteSettings settings; | |
17727 /** URL of this directory site. */ | |
17728 core.String url; | |
17729 | |
17730 DirectorySite(); | |
17731 | |
17732 DirectorySite.fromJson(core.Map _json) { | |
17733 if (_json.containsKey("active")) { | |
17734 active = _json["active"]; | |
17735 } | |
17736 if (_json.containsKey("contactAssignments")) { | |
17737 contactAssignments = _json["contactAssignments"].map((value) => new Direct
orySiteContactAssignment.fromJson(value)).toList(); | |
17738 } | |
17739 if (_json.containsKey("countryId")) { | |
17740 countryId = _json["countryId"]; | |
17741 } | |
17742 if (_json.containsKey("currencyId")) { | |
17743 currencyId = _json["currencyId"]; | |
17744 } | |
17745 if (_json.containsKey("description")) { | |
17746 description = _json["description"]; | |
17747 } | |
17748 if (_json.containsKey("id")) { | |
17749 id = _json["id"]; | |
17750 } | |
17751 if (_json.containsKey("idDimensionValue")) { | |
17752 idDimensionValue = new DimensionValue.fromJson(_json["idDimensionValue"]); | |
17753 } | |
17754 if (_json.containsKey("inpageTagFormats")) { | |
17755 inpageTagFormats = _json["inpageTagFormats"]; | |
17756 } | |
17757 if (_json.containsKey("interstitialTagFormats")) { | |
17758 interstitialTagFormats = _json["interstitialTagFormats"]; | |
17759 } | |
17760 if (_json.containsKey("kind")) { | |
17761 kind = _json["kind"]; | |
17762 } | |
17763 if (_json.containsKey("name")) { | |
17764 name = _json["name"]; | |
17765 } | |
17766 if (_json.containsKey("parentId")) { | |
17767 parentId = _json["parentId"]; | |
17768 } | |
17769 if (_json.containsKey("settings")) { | |
17770 settings = new DirectorySiteSettings.fromJson(_json["settings"]); | |
17771 } | |
17772 if (_json.containsKey("url")) { | |
17773 url = _json["url"]; | |
17774 } | |
17775 } | |
17776 | |
17777 core.Map toJson() { | |
17778 var _json = new core.Map(); | |
17779 if (active != null) { | |
17780 _json["active"] = active; | |
17781 } | |
17782 if (contactAssignments != null) { | |
17783 _json["contactAssignments"] = contactAssignments.map((value) => (value).to
Json()).toList(); | |
17784 } | |
17785 if (countryId != null) { | |
17786 _json["countryId"] = countryId; | |
17787 } | |
17788 if (currencyId != null) { | |
17789 _json["currencyId"] = currencyId; | |
17790 } | |
17791 if (description != null) { | |
17792 _json["description"] = description; | |
17793 } | |
17794 if (id != null) { | |
17795 _json["id"] = id; | |
17796 } | |
17797 if (idDimensionValue != null) { | |
17798 _json["idDimensionValue"] = (idDimensionValue).toJson(); | |
17799 } | |
17800 if (inpageTagFormats != null) { | |
17801 _json["inpageTagFormats"] = inpageTagFormats; | |
17802 } | |
17803 if (interstitialTagFormats != null) { | |
17804 _json["interstitialTagFormats"] = interstitialTagFormats; | |
17805 } | |
17806 if (kind != null) { | |
17807 _json["kind"] = kind; | |
17808 } | |
17809 if (name != null) { | |
17810 _json["name"] = name; | |
17811 } | |
17812 if (parentId != null) { | |
17813 _json["parentId"] = parentId; | |
17814 } | |
17815 if (settings != null) { | |
17816 _json["settings"] = (settings).toJson(); | |
17817 } | |
17818 if (url != null) { | |
17819 _json["url"] = url; | |
17820 } | |
17821 return _json; | |
17822 } | |
17823 } | |
17824 | |
17825 /** Contains properties of a Site Directory contact. */ | |
17826 class DirectorySiteContact { | |
17827 /** Address of this directory site contact. */ | |
17828 core.String address; | |
17829 /** Email address of this directory site contact. */ | |
17830 core.String email; | |
17831 /** First name of this directory site contact. */ | |
17832 core.String firstName; | |
17833 /** | |
17834 * ID of this directory site contact. This is a read-only, auto-generated | |
17835 * field. | |
17836 */ | |
17837 core.String id; | |
17838 /** | |
17839 * Identifies what kind of resource this is. Value: the fixed string | |
17840 * "dfareporting#directorySiteContact". | |
17841 */ | |
17842 core.String kind; | |
17843 /** Last name of this directory site contact. */ | |
17844 core.String lastName; | |
17845 /** Phone number of this directory site contact. */ | |
17846 core.String phone; | |
17847 /** | |
17848 * Directory site contact role. | |
17849 * Possible string values are: | |
17850 * - "ADMIN" | |
17851 * - "EDIT" | |
17852 * - "VIEW" | |
17853 */ | |
17854 core.String role; | |
17855 /** Title or designation of this directory site contact. */ | |
17856 core.String title; | |
17857 /** | |
17858 * Directory site contact type. | |
17859 * Possible string values are: | |
17860 * - "BILLING" | |
17861 * - "OTHER" | |
17862 * - "SALES" | |
17863 * - "TECHNICAL" | |
17864 */ | |
17865 core.String type; | |
17866 | |
17867 DirectorySiteContact(); | |
17868 | |
17869 DirectorySiteContact.fromJson(core.Map _json) { | |
17870 if (_json.containsKey("address")) { | |
17871 address = _json["address"]; | |
17872 } | |
17873 if (_json.containsKey("email")) { | |
17874 email = _json["email"]; | |
17875 } | |
17876 if (_json.containsKey("firstName")) { | |
17877 firstName = _json["firstName"]; | |
17878 } | |
17879 if (_json.containsKey("id")) { | |
17880 id = _json["id"]; | |
17881 } | |
17882 if (_json.containsKey("kind")) { | |
17883 kind = _json["kind"]; | |
17884 } | |
17885 if (_json.containsKey("lastName")) { | |
17886 lastName = _json["lastName"]; | |
17887 } | |
17888 if (_json.containsKey("phone")) { | |
17889 phone = _json["phone"]; | |
17890 } | |
17891 if (_json.containsKey("role")) { | |
17892 role = _json["role"]; | |
17893 } | |
17894 if (_json.containsKey("title")) { | |
17895 title = _json["title"]; | |
17896 } | |
17897 if (_json.containsKey("type")) { | |
17898 type = _json["type"]; | |
17899 } | |
17900 } | |
17901 | |
17902 core.Map toJson() { | |
17903 var _json = new core.Map(); | |
17904 if (address != null) { | |
17905 _json["address"] = address; | |
17906 } | |
17907 if (email != null) { | |
17908 _json["email"] = email; | |
17909 } | |
17910 if (firstName != null) { | |
17911 _json["firstName"] = firstName; | |
17912 } | |
17913 if (id != null) { | |
17914 _json["id"] = id; | |
17915 } | |
17916 if (kind != null) { | |
17917 _json["kind"] = kind; | |
17918 } | |
17919 if (lastName != null) { | |
17920 _json["lastName"] = lastName; | |
17921 } | |
17922 if (phone != null) { | |
17923 _json["phone"] = phone; | |
17924 } | |
17925 if (role != null) { | |
17926 _json["role"] = role; | |
17927 } | |
17928 if (title != null) { | |
17929 _json["title"] = title; | |
17930 } | |
17931 if (type != null) { | |
17932 _json["type"] = type; | |
17933 } | |
17934 return _json; | |
17935 } | |
17936 } | |
17937 | |
17938 /** Directory Site Contact Assignment */ | |
17939 class DirectorySiteContactAssignment { | |
17940 /** | |
17941 * ID of this directory site contact. This is a read-only, auto-generated | |
17942 * field. | |
17943 */ | |
17944 core.String contactId; | |
17945 /** | |
17946 * Visibility of this directory site contact assignment. When set to PUBLIC | |
17947 * this contact assignment is visible to all account and agency users; when | |
17948 * set to PRIVATE it is visible only to the site. | |
17949 * Possible string values are: | |
17950 * - "PRIVATE" | |
17951 * - "PUBLIC" | |
17952 */ | |
17953 core.String visibility; | |
17954 | |
17955 DirectorySiteContactAssignment(); | |
17956 | |
17957 DirectorySiteContactAssignment.fromJson(core.Map _json) { | |
17958 if (_json.containsKey("contactId")) { | |
17959 contactId = _json["contactId"]; | |
17960 } | |
17961 if (_json.containsKey("visibility")) { | |
17962 visibility = _json["visibility"]; | |
17963 } | |
17964 } | |
17965 | |
17966 core.Map toJson() { | |
17967 var _json = new core.Map(); | |
17968 if (contactId != null) { | |
17969 _json["contactId"] = contactId; | |
17970 } | |
17971 if (visibility != null) { | |
17972 _json["visibility"] = visibility; | |
17973 } | |
17974 return _json; | |
17975 } | |
17976 } | |
17977 | |
17978 /** Directory Site Contact List Response */ | |
17979 class DirectorySiteContactsListResponse { | |
17980 /** Directory site contact collection */ | |
17981 core.List<DirectorySiteContact> directorySiteContacts; | |
17982 /** | |
17983 * Identifies what kind of resource this is. Value: the fixed string | |
17984 * "dfareporting#directorySiteContactsListResponse". | |
17985 */ | |
17986 core.String kind; | |
17987 /** Pagination token to be used for the next list operation. */ | |
17988 core.String nextPageToken; | |
17989 | |
17990 DirectorySiteContactsListResponse(); | |
17991 | |
17992 DirectorySiteContactsListResponse.fromJson(core.Map _json) { | |
17993 if (_json.containsKey("directorySiteContacts")) { | |
17994 directorySiteContacts = _json["directorySiteContacts"].map((value) => new
DirectorySiteContact.fromJson(value)).toList(); | |
17995 } | |
17996 if (_json.containsKey("kind")) { | |
17997 kind = _json["kind"]; | |
17998 } | |
17999 if (_json.containsKey("nextPageToken")) { | |
18000 nextPageToken = _json["nextPageToken"]; | |
18001 } | |
18002 } | |
18003 | |
18004 core.Map toJson() { | |
18005 var _json = new core.Map(); | |
18006 if (directorySiteContacts != null) { | |
18007 _json["directorySiteContacts"] = directorySiteContacts.map((value) => (val
ue).toJson()).toList(); | |
18008 } | |
18009 if (kind != null) { | |
18010 _json["kind"] = kind; | |
18011 } | |
18012 if (nextPageToken != null) { | |
18013 _json["nextPageToken"] = nextPageToken; | |
18014 } | |
18015 return _json; | |
18016 } | |
18017 } | |
18018 | |
18019 /** Directory Site Settings */ | |
18020 class DirectorySiteSettings { | |
18021 /** Whether this directory site has disabled active view creatives. */ | |
18022 core.bool activeViewOptOut; | |
18023 /** Directory site DFP settings. */ | |
18024 DfpSettings dfpSettings; | |
18025 /** Whether this site accepts in-stream video ads. */ | |
18026 core.bool instreamVideoPlacementAccepted; | |
18027 /** Whether this site accepts interstitial ads. */ | |
18028 core.bool interstitialPlacementAccepted; | |
18029 /** Whether this directory site has disabled Nielsen OCR reach ratings. */ | |
18030 core.bool nielsenOcrOptOut; | |
18031 /** | |
18032 * Whether this directory site has disabled generation of Verification ins | |
18033 * tags. | |
18034 */ | |
18035 core.bool verificationTagOptOut; | |
18036 /** | |
18037 * Whether this directory site has disabled active view for in-stream video | |
18038 * creatives. | |
18039 */ | |
18040 core.bool videoActiveViewOptOut; | |
18041 | |
18042 DirectorySiteSettings(); | |
18043 | |
18044 DirectorySiteSettings.fromJson(core.Map _json) { | |
18045 if (_json.containsKey("activeViewOptOut")) { | |
18046 activeViewOptOut = _json["activeViewOptOut"]; | |
18047 } | |
18048 if (_json.containsKey("dfp_settings")) { | |
18049 dfpSettings = new DfpSettings.fromJson(_json["dfp_settings"]); | |
18050 } | |
18051 if (_json.containsKey("instream_video_placement_accepted")) { | |
18052 instreamVideoPlacementAccepted = _json["instream_video_placement_accepted"
]; | |
18053 } | |
18054 if (_json.containsKey("interstitialPlacementAccepted")) { | |
18055 interstitialPlacementAccepted = _json["interstitialPlacementAccepted"]; | |
18056 } | |
18057 if (_json.containsKey("nielsenOcrOptOut")) { | |
18058 nielsenOcrOptOut = _json["nielsenOcrOptOut"]; | |
18059 } | |
18060 if (_json.containsKey("verificationTagOptOut")) { | |
18061 verificationTagOptOut = _json["verificationTagOptOut"]; | |
18062 } | |
18063 if (_json.containsKey("videoActiveViewOptOut")) { | |
18064 videoActiveViewOptOut = _json["videoActiveViewOptOut"]; | |
18065 } | |
18066 } | |
18067 | |
18068 core.Map toJson() { | |
18069 var _json = new core.Map(); | |
18070 if (activeViewOptOut != null) { | |
18071 _json["activeViewOptOut"] = activeViewOptOut; | |
18072 } | |
18073 if (dfpSettings != null) { | |
18074 _json["dfp_settings"] = (dfpSettings).toJson(); | |
18075 } | |
18076 if (instreamVideoPlacementAccepted != null) { | |
18077 _json["instream_video_placement_accepted"] = instreamVideoPlacementAccepte
d; | |
18078 } | |
18079 if (interstitialPlacementAccepted != null) { | |
18080 _json["interstitialPlacementAccepted"] = interstitialPlacementAccepted; | |
18081 } | |
18082 if (nielsenOcrOptOut != null) { | |
18083 _json["nielsenOcrOptOut"] = nielsenOcrOptOut; | |
18084 } | |
18085 if (verificationTagOptOut != null) { | |
18086 _json["verificationTagOptOut"] = verificationTagOptOut; | |
18087 } | |
18088 if (videoActiveViewOptOut != null) { | |
18089 _json["videoActiveViewOptOut"] = videoActiveViewOptOut; | |
18090 } | |
18091 return _json; | |
18092 } | |
18093 } | |
18094 | |
18095 /** Directory Site List Response */ | |
18096 class DirectorySitesListResponse { | |
18097 /** Directory site collection. */ | |
18098 core.List<DirectorySite> directorySites; | |
18099 /** | |
18100 * Identifies what kind of resource this is. Value: the fixed string | |
18101 * "dfareporting#directorySitesListResponse". | |
18102 */ | |
18103 core.String kind; | |
18104 /** Pagination token to be used for the next list operation. */ | |
18105 core.String nextPageToken; | |
18106 | |
18107 DirectorySitesListResponse(); | |
18108 | |
18109 DirectorySitesListResponse.fromJson(core.Map _json) { | |
18110 if (_json.containsKey("directorySites")) { | |
18111 directorySites = _json["directorySites"].map((value) => new DirectorySite.
fromJson(value)).toList(); | |
18112 } | |
18113 if (_json.containsKey("kind")) { | |
18114 kind = _json["kind"]; | |
18115 } | |
18116 if (_json.containsKey("nextPageToken")) { | |
18117 nextPageToken = _json["nextPageToken"]; | |
18118 } | |
18119 } | |
18120 | |
18121 core.Map toJson() { | |
18122 var _json = new core.Map(); | |
18123 if (directorySites != null) { | |
18124 _json["directorySites"] = directorySites.map((value) => (value).toJson()).
toList(); | |
18125 } | |
18126 if (kind != null) { | |
18127 _json["kind"] = kind; | |
18128 } | |
18129 if (nextPageToken != null) { | |
18130 _json["nextPageToken"] = nextPageToken; | |
18131 } | |
18132 return _json; | |
18133 } | |
18134 } | |
18135 | |
18136 /** Contains properties of an event tag. */ | |
18137 class EventTag { | |
18138 /** | |
18139 * Account ID of this event tag. This is a read-only field that can be left | |
18140 * blank. | |
18141 */ | |
18142 core.String accountId; | |
18143 /** | |
18144 * Advertiser ID of this event tag. This field or the campaignId field is | |
18145 * required on insertion. | |
18146 */ | |
18147 core.String advertiserId; | |
18148 /** | |
18149 * Dimension value for the ID of the advertiser. This is a read-only, | |
18150 * auto-generated field. | |
18151 */ | |
18152 DimensionValue advertiserIdDimensionValue; | |
18153 /** | |
18154 * Campaign ID of this event tag. This field or the advertiserId field is | |
18155 * required on insertion. | |
18156 */ | |
18157 core.String campaignId; | |
18158 /** | |
18159 * Dimension value for the ID of the campaign. This is a read-only, | |
18160 * auto-generated field. | |
18161 */ | |
18162 DimensionValue campaignIdDimensionValue; | |
18163 /** | |
18164 * Whether this event tag should be automatically enabled for all of the | |
18165 * advertiser's campaigns and ads. | |
18166 */ | |
18167 core.bool enabledByDefault; | |
18168 /** | |
18169 * Whether to remove this event tag from ads that are trafficked through | |
18170 * DoubleClick Bid Manager to Ad Exchange. This may be useful if the event tag | |
18171 * uses a pixel that is unapproved for Ad Exchange bids on one or more | |
18172 * networks, such as the Google Display Network. | |
18173 */ | |
18174 core.bool excludeFromAdxRequests; | |
18175 /** ID of this event tag. This is a read-only, auto-generated field. */ | |
18176 core.String id; | |
18177 /** | |
18178 * Identifies what kind of resource this is. Value: the fixed string | |
18179 * "dfareporting#eventTag". | |
18180 */ | |
18181 core.String kind; | |
18182 /** | |
18183 * Name of this event tag. This is a required field and must be less than 256 | |
18184 * characters long. | |
18185 */ | |
18186 core.String name; | |
18187 /** | |
18188 * Site filter type for this event tag. If no type is specified then the event | |
18189 * tag will be applied to all sites. | |
18190 * Possible string values are: | |
18191 * - "BLACKLIST" | |
18192 * - "WHITELIST" | |
18193 */ | |
18194 core.String siteFilterType; | |
18195 /** | |
18196 * Filter list of site IDs associated with this event tag. The siteFilterType | |
18197 * determines whether this is a whitelist or blacklist filter. | |
18198 */ | |
18199 core.List<core.String> siteIds; | |
18200 /** Whether this tag is SSL-compliant or not. This is a read-only field. */ | |
18201 core.bool sslCompliant; | |
18202 /** | |
18203 * Status of this event tag. Must be ENABLED for this event tag to fire. This | |
18204 * is a required field. | |
18205 * Possible string values are: | |
18206 * - "DISABLED" | |
18207 * - "ENABLED" | |
18208 */ | |
18209 core.String status; | |
18210 /** | |
18211 * Subaccount ID of this event tag. This is a read-only field that can be left | |
18212 * blank. | |
18213 */ | |
18214 core.String subaccountId; | |
18215 /** | |
18216 * Event tag type. Can be used to specify whether to use a third-party pixel, | |
18217 * a third-party JavaScript URL, or a third-party click-through URL for either | |
18218 * impression or click tracking. This is a required field. | |
18219 * Possible string values are: | |
18220 * - "CLICK_THROUGH_EVENT_TAG" | |
18221 * - "IMPRESSION_IMAGE_EVENT_TAG" | |
18222 * - "IMPRESSION_JAVASCRIPT_EVENT_TAG" | |
18223 */ | |
18224 core.String type; | |
18225 /** | |
18226 * Payload URL for this event tag. The URL on a click-through event tag should | |
18227 * have a landing page URL appended to the end of it. This field is required | |
18228 * on insertion. | |
18229 */ | |
18230 core.String url; | |
18231 /** | |
18232 * Number of times the landing page URL should be URL-escaped before being | |
18233 * appended to the click-through event tag URL. Only applies to click-through | |
18234 * event tags as specified by the event tag type. | |
18235 */ | |
18236 core.int urlEscapeLevels; | |
18237 | |
18238 EventTag(); | |
18239 | |
18240 EventTag.fromJson(core.Map _json) { | |
18241 if (_json.containsKey("accountId")) { | |
18242 accountId = _json["accountId"]; | |
18243 } | |
18244 if (_json.containsKey("advertiserId")) { | |
18245 advertiserId = _json["advertiserId"]; | |
18246 } | |
18247 if (_json.containsKey("advertiserIdDimensionValue")) { | |
18248 advertiserIdDimensionValue = new DimensionValue.fromJson(_json["advertiser
IdDimensionValue"]); | |
18249 } | |
18250 if (_json.containsKey("campaignId")) { | |
18251 campaignId = _json["campaignId"]; | |
18252 } | |
18253 if (_json.containsKey("campaignIdDimensionValue")) { | |
18254 campaignIdDimensionValue = new DimensionValue.fromJson(_json["campaignIdDi
mensionValue"]); | |
18255 } | |
18256 if (_json.containsKey("enabledByDefault")) { | |
18257 enabledByDefault = _json["enabledByDefault"]; | |
18258 } | |
18259 if (_json.containsKey("excludeFromAdxRequests")) { | |
18260 excludeFromAdxRequests = _json["excludeFromAdxRequests"]; | |
18261 } | |
18262 if (_json.containsKey("id")) { | |
18263 id = _json["id"]; | |
18264 } | |
18265 if (_json.containsKey("kind")) { | |
18266 kind = _json["kind"]; | |
18267 } | |
18268 if (_json.containsKey("name")) { | |
18269 name = _json["name"]; | |
18270 } | |
18271 if (_json.containsKey("siteFilterType")) { | |
18272 siteFilterType = _json["siteFilterType"]; | |
18273 } | |
18274 if (_json.containsKey("siteIds")) { | |
18275 siteIds = _json["siteIds"]; | |
18276 } | |
18277 if (_json.containsKey("sslCompliant")) { | |
18278 sslCompliant = _json["sslCompliant"]; | |
18279 } | |
18280 if (_json.containsKey("status")) { | |
18281 status = _json["status"]; | |
18282 } | |
18283 if (_json.containsKey("subaccountId")) { | |
18284 subaccountId = _json["subaccountId"]; | |
18285 } | |
18286 if (_json.containsKey("type")) { | |
18287 type = _json["type"]; | |
18288 } | |
18289 if (_json.containsKey("url")) { | |
18290 url = _json["url"]; | |
18291 } | |
18292 if (_json.containsKey("urlEscapeLevels")) { | |
18293 urlEscapeLevels = _json["urlEscapeLevels"]; | |
18294 } | |
18295 } | |
18296 | |
18297 core.Map toJson() { | |
18298 var _json = new core.Map(); | |
18299 if (accountId != null) { | |
18300 _json["accountId"] = accountId; | |
18301 } | |
18302 if (advertiserId != null) { | |
18303 _json["advertiserId"] = advertiserId; | |
18304 } | |
18305 if (advertiserIdDimensionValue != null) { | |
18306 _json["advertiserIdDimensionValue"] = (advertiserIdDimensionValue).toJson(
); | |
18307 } | |
18308 if (campaignId != null) { | |
18309 _json["campaignId"] = campaignId; | |
18310 } | |
18311 if (campaignIdDimensionValue != null) { | |
18312 _json["campaignIdDimensionValue"] = (campaignIdDimensionValue).toJson(); | |
18313 } | |
18314 if (enabledByDefault != null) { | |
18315 _json["enabledByDefault"] = enabledByDefault; | |
18316 } | |
18317 if (excludeFromAdxRequests != null) { | |
18318 _json["excludeFromAdxRequests"] = excludeFromAdxRequests; | |
18319 } | |
18320 if (id != null) { | |
18321 _json["id"] = id; | |
18322 } | |
18323 if (kind != null) { | |
18324 _json["kind"] = kind; | |
18325 } | |
18326 if (name != null) { | |
18327 _json["name"] = name; | |
18328 } | |
18329 if (siteFilterType != null) { | |
18330 _json["siteFilterType"] = siteFilterType; | |
18331 } | |
18332 if (siteIds != null) { | |
18333 _json["siteIds"] = siteIds; | |
18334 } | |
18335 if (sslCompliant != null) { | |
18336 _json["sslCompliant"] = sslCompliant; | |
18337 } | |
18338 if (status != null) { | |
18339 _json["status"] = status; | |
18340 } | |
18341 if (subaccountId != null) { | |
18342 _json["subaccountId"] = subaccountId; | |
18343 } | |
18344 if (type != null) { | |
18345 _json["type"] = type; | |
18346 } | |
18347 if (url != null) { | |
18348 _json["url"] = url; | |
18349 } | |
18350 if (urlEscapeLevels != null) { | |
18351 _json["urlEscapeLevels"] = urlEscapeLevels; | |
18352 } | |
18353 return _json; | |
18354 } | |
18355 } | |
18356 | |
18357 /** Event tag override information. */ | |
18358 class EventTagOverride { | |
18359 /** Whether this override is enabled. */ | |
18360 core.bool enabled; | |
18361 /** | |
18362 * ID of this event tag override. This is a read-only, auto-generated field. | |
18363 */ | |
18364 core.String id; | |
18365 | |
18366 EventTagOverride(); | |
18367 | |
18368 EventTagOverride.fromJson(core.Map _json) { | |
18369 if (_json.containsKey("enabled")) { | |
18370 enabled = _json["enabled"]; | |
18371 } | |
18372 if (_json.containsKey("id")) { | |
18373 id = _json["id"]; | |
18374 } | |
18375 } | |
18376 | |
18377 core.Map toJson() { | |
18378 var _json = new core.Map(); | |
18379 if (enabled != null) { | |
18380 _json["enabled"] = enabled; | |
18381 } | |
18382 if (id != null) { | |
18383 _json["id"] = id; | |
18384 } | |
18385 return _json; | |
18386 } | |
18387 } | |
18388 | |
18389 /** Event Tag List Response */ | |
18390 class EventTagsListResponse { | |
18391 /** Event tag collection. */ | |
18392 core.List<EventTag> eventTags; | |
18393 /** | |
18394 * Identifies what kind of resource this is. Value: the fixed string | |
18395 * "dfareporting#eventTagsListResponse". | |
18396 */ | |
18397 core.String kind; | |
18398 | |
18399 EventTagsListResponse(); | |
18400 | |
18401 EventTagsListResponse.fromJson(core.Map _json) { | |
18402 if (_json.containsKey("eventTags")) { | |
18403 eventTags = _json["eventTags"].map((value) => new EventTag.fromJson(value)
).toList(); | |
18404 } | |
18405 if (_json.containsKey("kind")) { | |
18406 kind = _json["kind"]; | |
18407 } | |
18408 } | |
18409 | |
18410 core.Map toJson() { | |
18411 var _json = new core.Map(); | |
18412 if (eventTags != null) { | |
18413 _json["eventTags"] = eventTags.map((value) => (value).toJson()).toList(); | |
18414 } | |
18415 if (kind != null) { | |
18416 _json["kind"] = kind; | |
18417 } | |
18418 return _json; | |
18419 } | |
18420 } | |
18421 | |
18422 /** The URLs where the completed report file can be downloaded. */ | |
18423 class FileUrls { | |
18424 /** The URL for downloading the report data through the API. */ | |
18425 core.String apiUrl; | |
18426 /** The URL for downloading the report data through a browser. */ | |
18427 core.String browserUrl; | |
18428 | |
18429 FileUrls(); | |
18430 | |
18431 FileUrls.fromJson(core.Map _json) { | |
18432 if (_json.containsKey("apiUrl")) { | |
18433 apiUrl = _json["apiUrl"]; | |
18434 } | |
18435 if (_json.containsKey("browserUrl")) { | |
18436 browserUrl = _json["browserUrl"]; | |
18437 } | |
18438 } | |
18439 | |
18440 core.Map toJson() { | |
18441 var _json = new core.Map(); | |
18442 if (apiUrl != null) { | |
18443 _json["apiUrl"] = apiUrl; | |
18444 } | |
18445 if (browserUrl != null) { | |
18446 _json["browserUrl"] = browserUrl; | |
18447 } | |
18448 return _json; | |
18449 } | |
18450 } | |
18451 | |
18452 /** | |
18453 * Represents a File resource. A file contains the metadata for a report run. It | |
18454 * shows the status of the run and holds the URLs to the generated report data | |
18455 * if the run is finished and the status is "REPORT_AVAILABLE". | |
18456 */ | |
18457 class File { | |
18458 /** | |
18459 * The date range for which the file has report data. The date range will | |
18460 * always be the absolute date range for which the report is run. | |
18461 */ | |
18462 DateRange dateRange; | |
18463 /** The eTag of this response for caching purposes. */ | |
18464 core.String etag; | |
18465 /** The filename of the file. */ | |
18466 core.String fileName; | |
18467 /** | |
18468 * The output format of the report. Only available once the file is available. | |
18469 * Possible string values are: | |
18470 * - "CSV" | |
18471 * - "EXCEL" | |
18472 */ | |
18473 core.String format; | |
18474 /** The unique ID of this report file. */ | |
18475 core.String id; | |
18476 /** The kind of resource this is, in this case dfareporting#file. */ | |
18477 core.String kind; | |
18478 /** | |
18479 * The timestamp in milliseconds since epoch when this file was last modified. | |
18480 */ | |
18481 core.String lastModifiedTime; | |
18482 /** The ID of the report this file was generated from. */ | |
18483 core.String reportId; | |
18484 /** | |
18485 * The status of the report file. | |
18486 * Possible string values are: | |
18487 * - "CANCELLED" | |
18488 * - "FAILED" | |
18489 * - "PROCESSING" | |
18490 * - "REPORT_AVAILABLE" | |
18491 */ | |
18492 core.String status; | |
18493 /** The URLs where the completed report file can be downloaded. */ | |
18494 FileUrls urls; | |
18495 | |
18496 File(); | |
18497 | |
18498 File.fromJson(core.Map _json) { | |
18499 if (_json.containsKey("dateRange")) { | |
18500 dateRange = new DateRange.fromJson(_json["dateRange"]); | |
18501 } | |
18502 if (_json.containsKey("etag")) { | |
18503 etag = _json["etag"]; | |
18504 } | |
18505 if (_json.containsKey("fileName")) { | |
18506 fileName = _json["fileName"]; | |
18507 } | |
18508 if (_json.containsKey("format")) { | |
18509 format = _json["format"]; | |
18510 } | |
18511 if (_json.containsKey("id")) { | |
18512 id = _json["id"]; | |
18513 } | |
18514 if (_json.containsKey("kind")) { | |
18515 kind = _json["kind"]; | |
18516 } | |
18517 if (_json.containsKey("lastModifiedTime")) { | |
18518 lastModifiedTime = _json["lastModifiedTime"]; | |
18519 } | |
18520 if (_json.containsKey("reportId")) { | |
18521 reportId = _json["reportId"]; | |
18522 } | |
18523 if (_json.containsKey("status")) { | |
18524 status = _json["status"]; | |
18525 } | |
18526 if (_json.containsKey("urls")) { | |
18527 urls = new FileUrls.fromJson(_json["urls"]); | |
18528 } | |
18529 } | |
18530 | |
18531 core.Map toJson() { | |
18532 var _json = new core.Map(); | |
18533 if (dateRange != null) { | |
18534 _json["dateRange"] = (dateRange).toJson(); | |
18535 } | |
18536 if (etag != null) { | |
18537 _json["etag"] = etag; | |
18538 } | |
18539 if (fileName != null) { | |
18540 _json["fileName"] = fileName; | |
18541 } | |
18542 if (format != null) { | |
18543 _json["format"] = format; | |
18544 } | |
18545 if (id != null) { | |
18546 _json["id"] = id; | |
18547 } | |
18548 if (kind != null) { | |
18549 _json["kind"] = kind; | |
18550 } | |
18551 if (lastModifiedTime != null) { | |
18552 _json["lastModifiedTime"] = lastModifiedTime; | |
18553 } | |
18554 if (reportId != null) { | |
18555 _json["reportId"] = reportId; | |
18556 } | |
18557 if (status != null) { | |
18558 _json["status"] = status; | |
18559 } | |
18560 if (urls != null) { | |
18561 _json["urls"] = (urls).toJson(); | |
18562 } | |
18563 return _json; | |
18564 } | |
18565 } | |
18566 | |
18567 /** Represents the list of File resources. */ | |
18568 class FileList { | |
18569 /** The eTag of this response for caching purposes. */ | |
18570 core.String etag; | |
18571 /** The files returned in this response. */ | |
18572 core.List<File> items; | |
18573 /** The kind of list this is, in this case dfareporting#fileList. */ | |
18574 core.String kind; | |
18575 /** | |
18576 * Continuation token used to page through files. To retrieve the next page of | |
18577 * results, set the next request's "pageToken" to the value of this field. The | |
18578 * page token is only valid for a limited amount of time and should not be | |
18579 * persisted. | |
18580 */ | |
18581 core.String nextPageToken; | |
18582 | |
18583 FileList(); | |
18584 | |
18585 FileList.fromJson(core.Map _json) { | |
18586 if (_json.containsKey("etag")) { | |
18587 etag = _json["etag"]; | |
18588 } | |
18589 if (_json.containsKey("items")) { | |
18590 items = _json["items"].map((value) => new File.fromJson(value)).toList(); | |
18591 } | |
18592 if (_json.containsKey("kind")) { | |
18593 kind = _json["kind"]; | |
18594 } | |
18595 if (_json.containsKey("nextPageToken")) { | |
18596 nextPageToken = _json["nextPageToken"]; | |
18597 } | |
18598 } | |
18599 | |
18600 core.Map toJson() { | |
18601 var _json = new core.Map(); | |
18602 if (etag != null) { | |
18603 _json["etag"] = etag; | |
18604 } | |
18605 if (items != null) { | |
18606 _json["items"] = items.map((value) => (value).toJson()).toList(); | |
18607 } | |
18608 if (kind != null) { | |
18609 _json["kind"] = kind; | |
18610 } | |
18611 if (nextPageToken != null) { | |
18612 _json["nextPageToken"] = nextPageToken; | |
18613 } | |
18614 return _json; | |
18615 } | |
18616 } | |
18617 | |
18618 /** Flight */ | |
18619 class Flight { | |
18620 /** Inventory item flight end date. */ | |
18621 core.DateTime endDate; | |
18622 /** Rate or cost of this flight. */ | |
18623 core.String rateOrCost; | |
18624 /** Inventory item flight start date. */ | |
18625 core.DateTime startDate; | |
18626 /** Units of this flight. */ | |
18627 core.String units; | |
18628 | |
18629 Flight(); | |
18630 | |
18631 Flight.fromJson(core.Map _json) { | |
18632 if (_json.containsKey("endDate")) { | |
18633 endDate = core.DateTime.parse(_json["endDate"]); | |
18634 } | |
18635 if (_json.containsKey("rateOrCost")) { | |
18636 rateOrCost = _json["rateOrCost"]; | |
18637 } | |
18638 if (_json.containsKey("startDate")) { | |
18639 startDate = core.DateTime.parse(_json["startDate"]); | |
18640 } | |
18641 if (_json.containsKey("units")) { | |
18642 units = _json["units"]; | |
18643 } | |
18644 } | |
18645 | |
18646 core.Map toJson() { | |
18647 var _json = new core.Map(); | |
18648 if (endDate != null) { | |
18649 _json["endDate"] = "${(endDate).year.toString().padLeft(4, '0')}-${(endDat
e).month.toString().padLeft(2, '0')}-${(endDate).day.toString().padLeft(2, '0')}
"; | |
18650 } | |
18651 if (rateOrCost != null) { | |
18652 _json["rateOrCost"] = rateOrCost; | |
18653 } | |
18654 if (startDate != null) { | |
18655 _json["startDate"] = "${(startDate).year.toString().padLeft(4, '0')}-${(st
artDate).month.toString().padLeft(2, '0')}-${(startDate).day.toString().padLeft(
2, '0')}"; | |
18656 } | |
18657 if (units != null) { | |
18658 _json["units"] = units; | |
18659 } | |
18660 return _json; | |
18661 } | |
18662 } | |
18663 | |
18664 /** Floodlight Activity GenerateTag Response */ | |
18665 class FloodlightActivitiesGenerateTagResponse { | |
18666 /** Generated tag for this floodlight activity. */ | |
18667 core.String floodlightActivityTag; | |
18668 /** | |
18669 * Identifies what kind of resource this is. Value: the fixed string | |
18670 * "dfareporting#floodlightActivitiesGenerateTagResponse". | |
18671 */ | |
18672 core.String kind; | |
18673 | |
18674 FloodlightActivitiesGenerateTagResponse(); | |
18675 | |
18676 FloodlightActivitiesGenerateTagResponse.fromJson(core.Map _json) { | |
18677 if (_json.containsKey("floodlightActivityTag")) { | |
18678 floodlightActivityTag = _json["floodlightActivityTag"]; | |
18679 } | |
18680 if (_json.containsKey("kind")) { | |
18681 kind = _json["kind"]; | |
18682 } | |
18683 } | |
18684 | |
18685 core.Map toJson() { | |
18686 var _json = new core.Map(); | |
18687 if (floodlightActivityTag != null) { | |
18688 _json["floodlightActivityTag"] = floodlightActivityTag; | |
18689 } | |
18690 if (kind != null) { | |
18691 _json["kind"] = kind; | |
18692 } | |
18693 return _json; | |
18694 } | |
18695 } | |
18696 | |
18697 /** Floodlight Activity List Response */ | |
18698 class FloodlightActivitiesListResponse { | |
18699 /** Floodlight activity collection. */ | |
18700 core.List<FloodlightActivity> floodlightActivities; | |
18701 /** | |
18702 * Identifies what kind of resource this is. Value: the fixed string | |
18703 * "dfareporting#floodlightActivitiesListResponse". | |
18704 */ | |
18705 core.String kind; | |
18706 /** Pagination token to be used for the next list operation. */ | |
18707 core.String nextPageToken; | |
18708 | |
18709 FloodlightActivitiesListResponse(); | |
18710 | |
18711 FloodlightActivitiesListResponse.fromJson(core.Map _json) { | |
18712 if (_json.containsKey("floodlightActivities")) { | |
18713 floodlightActivities = _json["floodlightActivities"].map((value) => new Fl
oodlightActivity.fromJson(value)).toList(); | |
18714 } | |
18715 if (_json.containsKey("kind")) { | |
18716 kind = _json["kind"]; | |
18717 } | |
18718 if (_json.containsKey("nextPageToken")) { | |
18719 nextPageToken = _json["nextPageToken"]; | |
18720 } | |
18721 } | |
18722 | |
18723 core.Map toJson() { | |
18724 var _json = new core.Map(); | |
18725 if (floodlightActivities != null) { | |
18726 _json["floodlightActivities"] = floodlightActivities.map((value) => (value
).toJson()).toList(); | |
18727 } | |
18728 if (kind != null) { | |
18729 _json["kind"] = kind; | |
18730 } | |
18731 if (nextPageToken != null) { | |
18732 _json["nextPageToken"] = nextPageToken; | |
18733 } | |
18734 return _json; | |
18735 } | |
18736 } | |
18737 | |
18738 /** Contains properties of a Floodlight activity. */ | |
18739 class FloodlightActivity { | |
18740 /** | |
18741 * Account ID of this floodlight activity. This is a read-only field that can | |
18742 * be left blank. | |
18743 */ | |
18744 core.String accountId; | |
18745 /** | |
18746 * Advertiser ID of this floodlight activity. If this field is left blank, the | |
18747 * value will be copied over either from the activity group's advertiser or | |
18748 * the existing activity's advertiser. | |
18749 */ | |
18750 core.String advertiserId; | |
18751 /** | |
18752 * Dimension value for the ID of the advertiser. This is a read-only, | |
18753 * auto-generated field. | |
18754 */ | |
18755 DimensionValue advertiserIdDimensionValue; | |
18756 /** | |
18757 * Code type used for cache busting in the generated tag. | |
18758 * Possible string values are: | |
18759 * - "ACTIVE_SERVER_PAGE" | |
18760 * - "COLD_FUSION" | |
18761 * - "JAVASCRIPT" | |
18762 * - "JSP" | |
18763 * - "PHP" | |
18764 */ | |
18765 core.String cacheBustingType; | |
18766 /** | |
18767 * Counting method for conversions for this floodlight activity. This is a | |
18768 * required field. | |
18769 * Possible string values are: | |
18770 * - "ITEMS_SOLD_COUNTING" | |
18771 * - "SESSION_COUNTING" | |
18772 * - "STANDARD_COUNTING" | |
18773 * - "TRANSACTIONS_COUNTING" | |
18774 * - "UNIQUE_COUNTING" | |
18775 */ | |
18776 core.String countingMethod; | |
18777 /** Dynamic floodlight tags. */ | |
18778 core.List<FloodlightActivityDynamicTag> defaultTags; | |
18779 /** | |
18780 * URL where this tag will be deployed. If specified, must be less than 256 | |
18781 * characters long. | |
18782 */ | |
18783 core.String expectedUrl; | |
18784 /** | |
18785 * Floodlight activity group ID of this floodlight activity. This is a | |
18786 * required field. | |
18787 */ | |
18788 core.String floodlightActivityGroupId; | |
18789 /** | |
18790 * Name of the associated floodlight activity group. This is a read-only | |
18791 * field. | |
18792 */ | |
18793 core.String floodlightActivityGroupName; | |
18794 /** | |
18795 * Tag string of the associated floodlight activity group. This is a read-only | |
18796 * field. | |
18797 */ | |
18798 core.String floodlightActivityGroupTagString; | |
18799 /** | |
18800 * Type of the associated floodlight activity group. This is a read-only | |
18801 * field. | |
18802 * Possible string values are: | |
18803 * - "COUNTER" | |
18804 * - "SALE" | |
18805 */ | |
18806 core.String floodlightActivityGroupType; | |
18807 /** | |
18808 * Floodlight configuration ID of this floodlight activity. If this field is | |
18809 * left blank, the value will be copied over either from the activity group's | |
18810 * floodlight configuration or from the existing activity's floodlight | |
18811 * configuration. | |
18812 */ | |
18813 core.String floodlightConfigurationId; | |
18814 /** | |
18815 * Dimension value for the ID of the floodlight configuration. This is a | |
18816 * read-only, auto-generated field. | |
18817 */ | |
18818 DimensionValue floodlightConfigurationIdDimensionValue; | |
18819 /** Whether this activity is archived. */ | |
18820 core.bool hidden; | |
18821 /** | |
18822 * ID of this floodlight activity. This is a read-only, auto-generated field. | |
18823 */ | |
18824 core.String id; | |
18825 /** | |
18826 * Dimension value for the ID of this floodlight activity. This is a | |
18827 * read-only, auto-generated field. | |
18828 */ | |
18829 DimensionValue idDimensionValue; | |
18830 /** Whether the image tag is enabled for this activity. */ | |
18831 core.bool imageTagEnabled; | |
18832 /** | |
18833 * Identifies what kind of resource this is. Value: the fixed string | |
18834 * "dfareporting#floodlightActivity". | |
18835 */ | |
18836 core.String kind; | |
18837 /** | |
18838 * Name of this floodlight activity. This is a required field. Must be less | |
18839 * than 129 characters long and cannot contain quotes. | |
18840 */ | |
18841 core.String name; | |
18842 /** General notes or implementation instructions for the tag. */ | |
18843 core.String notes; | |
18844 /** Publisher dynamic floodlight tags. */ | |
18845 core.List<FloodlightActivityPublisherDynamicTag> publisherTags; | |
18846 /** Whether this tag should use SSL. */ | |
18847 core.bool secure; | |
18848 /** | |
18849 * Whether the floodlight activity is SSL-compliant. This is a read-only | |
18850 * field, its value detected by the system from the floodlight tags. | |
18851 */ | |
18852 core.bool sslCompliant; | |
18853 /** Whether this floodlight activity must be SSL-compliant. */ | |
18854 core.bool sslRequired; | |
18855 /** | |
18856 * Subaccount ID of this floodlight activity. This is a read-only field that | |
18857 * can be left blank. | |
18858 */ | |
18859 core.String subaccountId; | |
18860 /** | |
18861 * Tag format type for the floodlight activity. If left blank, the tag format | |
18862 * will default to HTML. | |
18863 * Possible string values are: | |
18864 * - "HTML" | |
18865 * - "XHTML" | |
18866 */ | |
18867 core.String tagFormat; | |
18868 /** | |
18869 * Value of the cat= paramter in the floodlight tag, which the ad servers use | |
18870 * to identify the activity. This is optional: if empty, a new tag string will | |
18871 * be generated for you. This string must be 1 to 8 characters long, with | |
18872 * valid characters being [a-z][A-Z][0-9][-][ _ ]. This tag string must also | |
18873 * be unique among activities of the same activity group. This field is | |
18874 * read-only after insertion. | |
18875 */ | |
18876 core.String tagString; | |
18877 /** | |
18878 * List of the user-defined variables used by this conversion tag. These map | |
18879 * to the "u[1-20]=" in the tags. Each of these can have a user defined type. | |
18880 * Acceptable values are: | |
18881 * - "U1" | |
18882 * - "U2" | |
18883 * - "U3" | |
18884 * - "U4" | |
18885 * - "U5" | |
18886 * - "U6" | |
18887 * - "U7" | |
18888 * - "U8" | |
18889 * - "U9" | |
18890 * - "U10" | |
18891 * - "U11" | |
18892 * - "U12" | |
18893 * - "U13" | |
18894 * - "U14" | |
18895 * - "U15" | |
18896 * - "U16" | |
18897 * - "U17" | |
18898 * - "U18" | |
18899 * - "U19" | |
18900 * - "U20" | |
18901 */ | |
18902 core.List<core.String> userDefinedVariableTypes; | |
18903 | |
18904 FloodlightActivity(); | |
18905 | |
18906 FloodlightActivity.fromJson(core.Map _json) { | |
18907 if (_json.containsKey("accountId")) { | |
18908 accountId = _json["accountId"]; | |
18909 } | |
18910 if (_json.containsKey("advertiserId")) { | |
18911 advertiserId = _json["advertiserId"]; | |
18912 } | |
18913 if (_json.containsKey("advertiserIdDimensionValue")) { | |
18914 advertiserIdDimensionValue = new DimensionValue.fromJson(_json["advertiser
IdDimensionValue"]); | |
18915 } | |
18916 if (_json.containsKey("cacheBustingType")) { | |
18917 cacheBustingType = _json["cacheBustingType"]; | |
18918 } | |
18919 if (_json.containsKey("countingMethod")) { | |
18920 countingMethod = _json["countingMethod"]; | |
18921 } | |
18922 if (_json.containsKey("defaultTags")) { | |
18923 defaultTags = _json["defaultTags"].map((value) => new FloodlightActivityDy
namicTag.fromJson(value)).toList(); | |
18924 } | |
18925 if (_json.containsKey("expectedUrl")) { | |
18926 expectedUrl = _json["expectedUrl"]; | |
18927 } | |
18928 if (_json.containsKey("floodlightActivityGroupId")) { | |
18929 floodlightActivityGroupId = _json["floodlightActivityGroupId"]; | |
18930 } | |
18931 if (_json.containsKey("floodlightActivityGroupName")) { | |
18932 floodlightActivityGroupName = _json["floodlightActivityGroupName"]; | |
18933 } | |
18934 if (_json.containsKey("floodlightActivityGroupTagString")) { | |
18935 floodlightActivityGroupTagString = _json["floodlightActivityGroupTagString
"]; | |
18936 } | |
18937 if (_json.containsKey("floodlightActivityGroupType")) { | |
18938 floodlightActivityGroupType = _json["floodlightActivityGroupType"]; | |
18939 } | |
18940 if (_json.containsKey("floodlightConfigurationId")) { | |
18941 floodlightConfigurationId = _json["floodlightConfigurationId"]; | |
18942 } | |
18943 if (_json.containsKey("floodlightConfigurationIdDimensionValue")) { | |
18944 floodlightConfigurationIdDimensionValue = new DimensionValue.fromJson(_jso
n["floodlightConfigurationIdDimensionValue"]); | |
18945 } | |
18946 if (_json.containsKey("hidden")) { | |
18947 hidden = _json["hidden"]; | |
18948 } | |
18949 if (_json.containsKey("id")) { | |
18950 id = _json["id"]; | |
18951 } | |
18952 if (_json.containsKey("idDimensionValue")) { | |
18953 idDimensionValue = new DimensionValue.fromJson(_json["idDimensionValue"]); | |
18954 } | |
18955 if (_json.containsKey("imageTagEnabled")) { | |
18956 imageTagEnabled = _json["imageTagEnabled"]; | |
18957 } | |
18958 if (_json.containsKey("kind")) { | |
18959 kind = _json["kind"]; | |
18960 } | |
18961 if (_json.containsKey("name")) { | |
18962 name = _json["name"]; | |
18963 } | |
18964 if (_json.containsKey("notes")) { | |
18965 notes = _json["notes"]; | |
18966 } | |
18967 if (_json.containsKey("publisherTags")) { | |
18968 publisherTags = _json["publisherTags"].map((value) => new FloodlightActivi
tyPublisherDynamicTag.fromJson(value)).toList(); | |
18969 } | |
18970 if (_json.containsKey("secure")) { | |
18971 secure = _json["secure"]; | |
18972 } | |
18973 if (_json.containsKey("sslCompliant")) { | |
18974 sslCompliant = _json["sslCompliant"]; | |
18975 } | |
18976 if (_json.containsKey("sslRequired")) { | |
18977 sslRequired = _json["sslRequired"]; | |
18978 } | |
18979 if (_json.containsKey("subaccountId")) { | |
18980 subaccountId = _json["subaccountId"]; | |
18981 } | |
18982 if (_json.containsKey("tagFormat")) { | |
18983 tagFormat = _json["tagFormat"]; | |
18984 } | |
18985 if (_json.containsKey("tagString")) { | |
18986 tagString = _json["tagString"]; | |
18987 } | |
18988 if (_json.containsKey("userDefinedVariableTypes")) { | |
18989 userDefinedVariableTypes = _json["userDefinedVariableTypes"]; | |
18990 } | |
18991 } | |
18992 | |
18993 core.Map toJson() { | |
18994 var _json = new core.Map(); | |
18995 if (accountId != null) { | |
18996 _json["accountId"] = accountId; | |
18997 } | |
18998 if (advertiserId != null) { | |
18999 _json["advertiserId"] = advertiserId; | |
19000 } | |
19001 if (advertiserIdDimensionValue != null) { | |
19002 _json["advertiserIdDimensionValue"] = (advertiserIdDimensionValue).toJson(
); | |
19003 } | |
19004 if (cacheBustingType != null) { | |
19005 _json["cacheBustingType"] = cacheBustingType; | |
19006 } | |
19007 if (countingMethod != null) { | |
19008 _json["countingMethod"] = countingMethod; | |
19009 } | |
19010 if (defaultTags != null) { | |
19011 _json["defaultTags"] = defaultTags.map((value) => (value).toJson()).toList
(); | |
19012 } | |
19013 if (expectedUrl != null) { | |
19014 _json["expectedUrl"] = expectedUrl; | |
19015 } | |
19016 if (floodlightActivityGroupId != null) { | |
19017 _json["floodlightActivityGroupId"] = floodlightActivityGroupId; | |
19018 } | |
19019 if (floodlightActivityGroupName != null) { | |
19020 _json["floodlightActivityGroupName"] = floodlightActivityGroupName; | |
19021 } | |
19022 if (floodlightActivityGroupTagString != null) { | |
19023 _json["floodlightActivityGroupTagString"] = floodlightActivityGroupTagStri
ng; | |
19024 } | |
19025 if (floodlightActivityGroupType != null) { | |
19026 _json["floodlightActivityGroupType"] = floodlightActivityGroupType; | |
19027 } | |
19028 if (floodlightConfigurationId != null) { | |
19029 _json["floodlightConfigurationId"] = floodlightConfigurationId; | |
19030 } | |
19031 if (floodlightConfigurationIdDimensionValue != null) { | |
19032 _json["floodlightConfigurationIdDimensionValue"] = (floodlightConfiguratio
nIdDimensionValue).toJson(); | |
19033 } | |
19034 if (hidden != null) { | |
19035 _json["hidden"] = hidden; | |
19036 } | |
19037 if (id != null) { | |
19038 _json["id"] = id; | |
19039 } | |
19040 if (idDimensionValue != null) { | |
19041 _json["idDimensionValue"] = (idDimensionValue).toJson(); | |
19042 } | |
19043 if (imageTagEnabled != null) { | |
19044 _json["imageTagEnabled"] = imageTagEnabled; | |
19045 } | |
19046 if (kind != null) { | |
19047 _json["kind"] = kind; | |
19048 } | |
19049 if (name != null) { | |
19050 _json["name"] = name; | |
19051 } | |
19052 if (notes != null) { | |
19053 _json["notes"] = notes; | |
19054 } | |
19055 if (publisherTags != null) { | |
19056 _json["publisherTags"] = publisherTags.map((value) => (value).toJson()).to
List(); | |
19057 } | |
19058 if (secure != null) { | |
19059 _json["secure"] = secure; | |
19060 } | |
19061 if (sslCompliant != null) { | |
19062 _json["sslCompliant"] = sslCompliant; | |
19063 } | |
19064 if (sslRequired != null) { | |
19065 _json["sslRequired"] = sslRequired; | |
19066 } | |
19067 if (subaccountId != null) { | |
19068 _json["subaccountId"] = subaccountId; | |
19069 } | |
19070 if (tagFormat != null) { | |
19071 _json["tagFormat"] = tagFormat; | |
19072 } | |
19073 if (tagString != null) { | |
19074 _json["tagString"] = tagString; | |
19075 } | |
19076 if (userDefinedVariableTypes != null) { | |
19077 _json["userDefinedVariableTypes"] = userDefinedVariableTypes; | |
19078 } | |
19079 return _json; | |
19080 } | |
19081 } | |
19082 | |
19083 /** Dynamic Tag */ | |
19084 class FloodlightActivityDynamicTag { | |
19085 /** ID of this dynamic tag. This is a read-only, auto-generated field. */ | |
19086 core.String id; | |
19087 /** Name of this tag. */ | |
19088 core.String name; | |
19089 /** Tag code. */ | |
19090 core.String tag; | |
19091 | |
19092 FloodlightActivityDynamicTag(); | |
19093 | |
19094 FloodlightActivityDynamicTag.fromJson(core.Map _json) { | |
19095 if (_json.containsKey("id")) { | |
19096 id = _json["id"]; | |
19097 } | |
19098 if (_json.containsKey("name")) { | |
19099 name = _json["name"]; | |
19100 } | |
19101 if (_json.containsKey("tag")) { | |
19102 tag = _json["tag"]; | |
19103 } | |
19104 } | |
19105 | |
19106 core.Map toJson() { | |
19107 var _json = new core.Map(); | |
19108 if (id != null) { | |
19109 _json["id"] = id; | |
19110 } | |
19111 if (name != null) { | |
19112 _json["name"] = name; | |
19113 } | |
19114 if (tag != null) { | |
19115 _json["tag"] = tag; | |
19116 } | |
19117 return _json; | |
19118 } | |
19119 } | |
19120 | |
19121 /** Contains properties of a Floodlight activity group. */ | |
19122 class FloodlightActivityGroup { | |
19123 /** | |
19124 * Account ID of this floodlight activity group. This is a read-only field | |
19125 * that can be left blank. | |
19126 */ | |
19127 core.String accountId; | |
19128 /** | |
19129 * Advertiser ID of this floodlight activity group. If this field is left | |
19130 * blank, the value will be copied over either from the floodlight | |
19131 * configuration's advertiser or from the existing activity group's | |
19132 * advertiser. | |
19133 */ | |
19134 core.String advertiserId; | |
19135 /** | |
19136 * Dimension value for the ID of the advertiser. This is a read-only, | |
19137 * auto-generated field. | |
19138 */ | |
19139 DimensionValue advertiserIdDimensionValue; | |
19140 /** | |
19141 * Floodlight configuration ID of this floodlight activity group. This is a | |
19142 * required field. | |
19143 */ | |
19144 core.String floodlightConfigurationId; | |
19145 /** | |
19146 * Dimension value for the ID of the floodlight configuration. This is a | |
19147 * read-only, auto-generated field. | |
19148 */ | |
19149 DimensionValue floodlightConfigurationIdDimensionValue; | |
19150 /** | |
19151 * ID of this floodlight activity group. This is a read-only, auto-generated | |
19152 * field. | |
19153 */ | |
19154 core.String id; | |
19155 /** | |
19156 * Dimension value for the ID of this floodlight activity group. This is a | |
19157 * read-only, auto-generated field. | |
19158 */ | |
19159 DimensionValue idDimensionValue; | |
19160 /** | |
19161 * Identifies what kind of resource this is. Value: the fixed string | |
19162 * "dfareporting#floodlightActivityGroup". | |
19163 */ | |
19164 core.String kind; | |
19165 /** | |
19166 * Name of this floodlight activity group. This is a required field. Must be | |
19167 * less than 65 characters long and cannot contain quotes. | |
19168 */ | |
19169 core.String name; | |
19170 /** | |
19171 * Subaccount ID of this floodlight activity group. This is a read-only field | |
19172 * that can be left blank. | |
19173 */ | |
19174 core.String subaccountId; | |
19175 /** | |
19176 * Value of the type= parameter in the floodlight tag, which the ad servers | |
19177 * use to identify the activity group that the activity belongs to. This is | |
19178 * optional: if empty, a new tag string will be generated for you. This string | |
19179 * must be 1 to 8 characters long, with valid characters being | |
19180 * [a-z][A-Z][0-9][-][ _ ]. This tag string must also be unique among activity | |
19181 * groups of the same floodlight configuration. This field is read-only after | |
19182 * insertion. | |
19183 */ | |
19184 core.String tagString; | |
19185 /** | |
19186 * Type of the floodlight activity group. This is a required field that is | |
19187 * read-only after insertion. | |
19188 * Possible string values are: | |
19189 * - "COUNTER" | |
19190 * - "SALE" | |
19191 */ | |
19192 core.String type; | |
19193 | |
19194 FloodlightActivityGroup(); | |
19195 | |
19196 FloodlightActivityGroup.fromJson(core.Map _json) { | |
19197 if (_json.containsKey("accountId")) { | |
19198 accountId = _json["accountId"]; | |
19199 } | |
19200 if (_json.containsKey("advertiserId")) { | |
19201 advertiserId = _json["advertiserId"]; | |
19202 } | |
19203 if (_json.containsKey("advertiserIdDimensionValue")) { | |
19204 advertiserIdDimensionValue = new DimensionValue.fromJson(_json["advertiser
IdDimensionValue"]); | |
19205 } | |
19206 if (_json.containsKey("floodlightConfigurationId")) { | |
19207 floodlightConfigurationId = _json["floodlightConfigurationId"]; | |
19208 } | |
19209 if (_json.containsKey("floodlightConfigurationIdDimensionValue")) { | |
19210 floodlightConfigurationIdDimensionValue = new DimensionValue.fromJson(_jso
n["floodlightConfigurationIdDimensionValue"]); | |
19211 } | |
19212 if (_json.containsKey("id")) { | |
19213 id = _json["id"]; | |
19214 } | |
19215 if (_json.containsKey("idDimensionValue")) { | |
19216 idDimensionValue = new DimensionValue.fromJson(_json["idDimensionValue"]); | |
19217 } | |
19218 if (_json.containsKey("kind")) { | |
19219 kind = _json["kind"]; | |
19220 } | |
19221 if (_json.containsKey("name")) { | |
19222 name = _json["name"]; | |
19223 } | |
19224 if (_json.containsKey("subaccountId")) { | |
19225 subaccountId = _json["subaccountId"]; | |
19226 } | |
19227 if (_json.containsKey("tagString")) { | |
19228 tagString = _json["tagString"]; | |
19229 } | |
19230 if (_json.containsKey("type")) { | |
19231 type = _json["type"]; | |
19232 } | |
19233 } | |
19234 | |
19235 core.Map toJson() { | |
19236 var _json = new core.Map(); | |
19237 if (accountId != null) { | |
19238 _json["accountId"] = accountId; | |
19239 } | |
19240 if (advertiserId != null) { | |
19241 _json["advertiserId"] = advertiserId; | |
19242 } | |
19243 if (advertiserIdDimensionValue != null) { | |
19244 _json["advertiserIdDimensionValue"] = (advertiserIdDimensionValue).toJson(
); | |
19245 } | |
19246 if (floodlightConfigurationId != null) { | |
19247 _json["floodlightConfigurationId"] = floodlightConfigurationId; | |
19248 } | |
19249 if (floodlightConfigurationIdDimensionValue != null) { | |
19250 _json["floodlightConfigurationIdDimensionValue"] = (floodlightConfiguratio
nIdDimensionValue).toJson(); | |
19251 } | |
19252 if (id != null) { | |
19253 _json["id"] = id; | |
19254 } | |
19255 if (idDimensionValue != null) { | |
19256 _json["idDimensionValue"] = (idDimensionValue).toJson(); | |
19257 } | |
19258 if (kind != null) { | |
19259 _json["kind"] = kind; | |
19260 } | |
19261 if (name != null) { | |
19262 _json["name"] = name; | |
19263 } | |
19264 if (subaccountId != null) { | |
19265 _json["subaccountId"] = subaccountId; | |
19266 } | |
19267 if (tagString != null) { | |
19268 _json["tagString"] = tagString; | |
19269 } | |
19270 if (type != null) { | |
19271 _json["type"] = type; | |
19272 } | |
19273 return _json; | |
19274 } | |
19275 } | |
19276 | |
19277 /** Floodlight Activity Group List Response */ | |
19278 class FloodlightActivityGroupsListResponse { | |
19279 /** Floodlight activity group collection. */ | |
19280 core.List<FloodlightActivityGroup> floodlightActivityGroups; | |
19281 /** | |
19282 * Identifies what kind of resource this is. Value: the fixed string | |
19283 * "dfareporting#floodlightActivityGroupsListResponse". | |
19284 */ | |
19285 core.String kind; | |
19286 /** Pagination token to be used for the next list operation. */ | |
19287 core.String nextPageToken; | |
19288 | |
19289 FloodlightActivityGroupsListResponse(); | |
19290 | |
19291 FloodlightActivityGroupsListResponse.fromJson(core.Map _json) { | |
19292 if (_json.containsKey("floodlightActivityGroups")) { | |
19293 floodlightActivityGroups = _json["floodlightActivityGroups"].map((value) =
> new FloodlightActivityGroup.fromJson(value)).toList(); | |
19294 } | |
19295 if (_json.containsKey("kind")) { | |
19296 kind = _json["kind"]; | |
19297 } | |
19298 if (_json.containsKey("nextPageToken")) { | |
19299 nextPageToken = _json["nextPageToken"]; | |
19300 } | |
19301 } | |
19302 | |
19303 core.Map toJson() { | |
19304 var _json = new core.Map(); | |
19305 if (floodlightActivityGroups != null) { | |
19306 _json["floodlightActivityGroups"] = floodlightActivityGroups.map((value) =
> (value).toJson()).toList(); | |
19307 } | |
19308 if (kind != null) { | |
19309 _json["kind"] = kind; | |
19310 } | |
19311 if (nextPageToken != null) { | |
19312 _json["nextPageToken"] = nextPageToken; | |
19313 } | |
19314 return _json; | |
19315 } | |
19316 } | |
19317 | |
19318 /** Publisher Dynamic Tag */ | |
19319 class FloodlightActivityPublisherDynamicTag { | |
19320 /** Whether this tag is applicable only for click-throughs. */ | |
19321 core.bool clickThrough; | |
19322 /** | |
19323 * Directory site ID of this dynamic tag. This is a write-only field that can | |
19324 * be used as an alternative to the siteId field. When this resource is | |
19325 * retrieved, only the siteId field will be populated. | |
19326 */ | |
19327 core.String directorySiteId; | |
19328 /** Dynamic floodlight tag. */ | |
19329 FloodlightActivityDynamicTag dynamicTag; | |
19330 /** Site ID of this dynamic tag. */ | |
19331 core.String siteId; | |
19332 /** | |
19333 * Dimension value for the ID of the site. This is a read-only, auto-generated | |
19334 * field. | |
19335 */ | |
19336 DimensionValue siteIdDimensionValue; | |
19337 /** Whether this tag is applicable only for view-throughs. */ | |
19338 core.bool viewThrough; | |
19339 | |
19340 FloodlightActivityPublisherDynamicTag(); | |
19341 | |
19342 FloodlightActivityPublisherDynamicTag.fromJson(core.Map _json) { | |
19343 if (_json.containsKey("clickThrough")) { | |
19344 clickThrough = _json["clickThrough"]; | |
19345 } | |
19346 if (_json.containsKey("directorySiteId")) { | |
19347 directorySiteId = _json["directorySiteId"]; | |
19348 } | |
19349 if (_json.containsKey("dynamicTag")) { | |
19350 dynamicTag = new FloodlightActivityDynamicTag.fromJson(_json["dynamicTag"]
); | |
19351 } | |
19352 if (_json.containsKey("siteId")) { | |
19353 siteId = _json["siteId"]; | |
19354 } | |
19355 if (_json.containsKey("siteIdDimensionValue")) { | |
19356 siteIdDimensionValue = new DimensionValue.fromJson(_json["siteIdDimensionV
alue"]); | |
19357 } | |
19358 if (_json.containsKey("viewThrough")) { | |
19359 viewThrough = _json["viewThrough"]; | |
19360 } | |
19361 } | |
19362 | |
19363 core.Map toJson() { | |
19364 var _json = new core.Map(); | |
19365 if (clickThrough != null) { | |
19366 _json["clickThrough"] = clickThrough; | |
19367 } | |
19368 if (directorySiteId != null) { | |
19369 _json["directorySiteId"] = directorySiteId; | |
19370 } | |
19371 if (dynamicTag != null) { | |
19372 _json["dynamicTag"] = (dynamicTag).toJson(); | |
19373 } | |
19374 if (siteId != null) { | |
19375 _json["siteId"] = siteId; | |
19376 } | |
19377 if (siteIdDimensionValue != null) { | |
19378 _json["siteIdDimensionValue"] = (siteIdDimensionValue).toJson(); | |
19379 } | |
19380 if (viewThrough != null) { | |
19381 _json["viewThrough"] = viewThrough; | |
19382 } | |
19383 return _json; | |
19384 } | |
19385 } | |
19386 | |
19387 /** Contains properties of a Floodlight configuration. */ | |
19388 class FloodlightConfiguration { | |
19389 /** | |
19390 * Account ID of this floodlight configuration. This is a read-only field that | |
19391 * can be left blank. | |
19392 */ | |
19393 core.String accountId; | |
19394 /** | |
19395 * Advertiser ID of the parent advertiser of this floodlight configuration. | |
19396 */ | |
19397 core.String advertiserId; | |
19398 /** | |
19399 * Dimension value for the ID of the advertiser. This is a read-only, | |
19400 * auto-generated field. | |
19401 */ | |
19402 DimensionValue advertiserIdDimensionValue; | |
19403 /** Whether advertiser data is shared with Google Analytics. */ | |
19404 core.bool analyticsDataSharingEnabled; | |
19405 /** | |
19406 * Whether the exposure-to-conversion report is enabled. This report shows | |
19407 * detailed pathway information on up to 10 of the most recent ad exposures | |
19408 * seen by a user before converting. | |
19409 */ | |
19410 core.bool exposureToConversionEnabled; | |
19411 /** | |
19412 * Day that will be counted as the first day of the week in reports. This is a | |
19413 * required field. | |
19414 * Possible string values are: | |
19415 * - "MONDAY" | |
19416 * - "SUNDAY" | |
19417 */ | |
19418 core.String firstDayOfWeek; | |
19419 /** | |
19420 * ID of this floodlight configuration. This is a read-only, auto-generated | |
19421 * field. | |
19422 */ | |
19423 core.String id; | |
19424 /** | |
19425 * Dimension value for the ID of this floodlight configuration. This is a | |
19426 * read-only, auto-generated field. | |
19427 */ | |
19428 DimensionValue idDimensionValue; | |
19429 /** Whether in-app attribution tracking is enabled. */ | |
19430 core.bool inAppAttributionTrackingEnabled; | |
19431 /** | |
19432 * Identifies what kind of resource this is. Value: the fixed string | |
19433 * "dfareporting#floodlightConfiguration". | |
19434 */ | |
19435 core.String kind; | |
19436 /** Lookback window settings for this floodlight configuration. */ | |
19437 LookbackConfiguration lookbackConfiguration; | |
19438 /** | |
19439 * Types of attribution options for natural search conversions. | |
19440 * Possible string values are: | |
19441 * - "EXCLUDE_NATURAL_SEARCH_CONVERSION_ATTRIBUTION" | |
19442 * - "INCLUDE_NATURAL_SEARCH_CONVERSION_ATTRIBUTION" | |
19443 * - "INCLUDE_NATURAL_SEARCH_TIERED_CONVERSION_ATTRIBUTION" | |
19444 */ | |
19445 core.String naturalSearchConversionAttributionOption; | |
19446 /** Settings for DCM Omniture integration. */ | |
19447 OmnitureSettings omnitureSettings; | |
19448 /** | |
19449 * List of standard variables enabled for this configuration. | |
19450 * | |
19451 * Acceptable values are: | |
19452 * - "ORD" | |
19453 * - "NUM" | |
19454 */ | |
19455 core.List<core.String> standardVariableTypes; | |
19456 /** | |
19457 * Subaccount ID of this floodlight configuration. This is a read-only field | |
19458 * that can be left blank. | |
19459 */ | |
19460 core.String subaccountId; | |
19461 /** Configuration settings for dynamic and image floodlight tags. */ | |
19462 TagSettings tagSettings; | |
19463 /** | |
19464 * List of third-party authentication tokens enabled for this configuration. | |
19465 */ | |
19466 core.List<ThirdPartyAuthenticationToken> thirdPartyAuthenticationTokens; | |
19467 /** List of user defined variables enabled for this configuration. */ | |
19468 core.List<UserDefinedVariableConfiguration> userDefinedVariableConfigurations; | |
19469 | |
19470 FloodlightConfiguration(); | |
19471 | |
19472 FloodlightConfiguration.fromJson(core.Map _json) { | |
19473 if (_json.containsKey("accountId")) { | |
19474 accountId = _json["accountId"]; | |
19475 } | |
19476 if (_json.containsKey("advertiserId")) { | |
19477 advertiserId = _json["advertiserId"]; | |
19478 } | |
19479 if (_json.containsKey("advertiserIdDimensionValue")) { | |
19480 advertiserIdDimensionValue = new DimensionValue.fromJson(_json["advertiser
IdDimensionValue"]); | |
19481 } | |
19482 if (_json.containsKey("analyticsDataSharingEnabled")) { | |
19483 analyticsDataSharingEnabled = _json["analyticsDataSharingEnabled"]; | |
19484 } | |
19485 if (_json.containsKey("exposureToConversionEnabled")) { | |
19486 exposureToConversionEnabled = _json["exposureToConversionEnabled"]; | |
19487 } | |
19488 if (_json.containsKey("firstDayOfWeek")) { | |
19489 firstDayOfWeek = _json["firstDayOfWeek"]; | |
19490 } | |
19491 if (_json.containsKey("id")) { | |
19492 id = _json["id"]; | |
19493 } | |
19494 if (_json.containsKey("idDimensionValue")) { | |
19495 idDimensionValue = new DimensionValue.fromJson(_json["idDimensionValue"]); | |
19496 } | |
19497 if (_json.containsKey("inAppAttributionTrackingEnabled")) { | |
19498 inAppAttributionTrackingEnabled = _json["inAppAttributionTrackingEnabled"]
; | |
19499 } | |
19500 if (_json.containsKey("kind")) { | |
19501 kind = _json["kind"]; | |
19502 } | |
19503 if (_json.containsKey("lookbackConfiguration")) { | |
19504 lookbackConfiguration = new LookbackConfiguration.fromJson(_json["lookback
Configuration"]); | |
19505 } | |
19506 if (_json.containsKey("naturalSearchConversionAttributionOption")) { | |
19507 naturalSearchConversionAttributionOption = _json["naturalSearchConversionA
ttributionOption"]; | |
19508 } | |
19509 if (_json.containsKey("omnitureSettings")) { | |
19510 omnitureSettings = new OmnitureSettings.fromJson(_json["omnitureSettings"]
); | |
19511 } | |
19512 if (_json.containsKey("standardVariableTypes")) { | |
19513 standardVariableTypes = _json["standardVariableTypes"]; | |
19514 } | |
19515 if (_json.containsKey("subaccountId")) { | |
19516 subaccountId = _json["subaccountId"]; | |
19517 } | |
19518 if (_json.containsKey("tagSettings")) { | |
19519 tagSettings = new TagSettings.fromJson(_json["tagSettings"]); | |
19520 } | |
19521 if (_json.containsKey("thirdPartyAuthenticationTokens")) { | |
19522 thirdPartyAuthenticationTokens = _json["thirdPartyAuthenticationTokens"].m
ap((value) => new ThirdPartyAuthenticationToken.fromJson(value)).toList(); | |
19523 } | |
19524 if (_json.containsKey("userDefinedVariableConfigurations")) { | |
19525 userDefinedVariableConfigurations = _json["userDefinedVariableConfiguratio
ns"].map((value) => new UserDefinedVariableConfiguration.fromJson(value)).toList
(); | |
19526 } | |
19527 } | |
19528 | |
19529 core.Map toJson() { | |
19530 var _json = new core.Map(); | |
19531 if (accountId != null) { | |
19532 _json["accountId"] = accountId; | |
19533 } | |
19534 if (advertiserId != null) { | |
19535 _json["advertiserId"] = advertiserId; | |
19536 } | |
19537 if (advertiserIdDimensionValue != null) { | |
19538 _json["advertiserIdDimensionValue"] = (advertiserIdDimensionValue).toJson(
); | |
19539 } | |
19540 if (analyticsDataSharingEnabled != null) { | |
19541 _json["analyticsDataSharingEnabled"] = analyticsDataSharingEnabled; | |
19542 } | |
19543 if (exposureToConversionEnabled != null) { | |
19544 _json["exposureToConversionEnabled"] = exposureToConversionEnabled; | |
19545 } | |
19546 if (firstDayOfWeek != null) { | |
19547 _json["firstDayOfWeek"] = firstDayOfWeek; | |
19548 } | |
19549 if (id != null) { | |
19550 _json["id"] = id; | |
19551 } | |
19552 if (idDimensionValue != null) { | |
19553 _json["idDimensionValue"] = (idDimensionValue).toJson(); | |
19554 } | |
19555 if (inAppAttributionTrackingEnabled != null) { | |
19556 _json["inAppAttributionTrackingEnabled"] = inAppAttributionTrackingEnabled
; | |
19557 } | |
19558 if (kind != null) { | |
19559 _json["kind"] = kind; | |
19560 } | |
19561 if (lookbackConfiguration != null) { | |
19562 _json["lookbackConfiguration"] = (lookbackConfiguration).toJson(); | |
19563 } | |
19564 if (naturalSearchConversionAttributionOption != null) { | |
19565 _json["naturalSearchConversionAttributionOption"] = naturalSearchConversio
nAttributionOption; | |
19566 } | |
19567 if (omnitureSettings != null) { | |
19568 _json["omnitureSettings"] = (omnitureSettings).toJson(); | |
19569 } | |
19570 if (standardVariableTypes != null) { | |
19571 _json["standardVariableTypes"] = standardVariableTypes; | |
19572 } | |
19573 if (subaccountId != null) { | |
19574 _json["subaccountId"] = subaccountId; | |
19575 } | |
19576 if (tagSettings != null) { | |
19577 _json["tagSettings"] = (tagSettings).toJson(); | |
19578 } | |
19579 if (thirdPartyAuthenticationTokens != null) { | |
19580 _json["thirdPartyAuthenticationTokens"] = thirdPartyAuthenticationTokens.m
ap((value) => (value).toJson()).toList(); | |
19581 } | |
19582 if (userDefinedVariableConfigurations != null) { | |
19583 _json["userDefinedVariableConfigurations"] = userDefinedVariableConfigurat
ions.map((value) => (value).toJson()).toList(); | |
19584 } | |
19585 return _json; | |
19586 } | |
19587 } | |
19588 | |
19589 /** Floodlight Configuration List Response */ | |
19590 class FloodlightConfigurationsListResponse { | |
19591 /** Floodlight configuration collection. */ | |
19592 core.List<FloodlightConfiguration> floodlightConfigurations; | |
19593 /** | |
19594 * Identifies what kind of resource this is. Value: the fixed string | |
19595 * "dfareporting#floodlightConfigurationsListResponse". | |
19596 */ | |
19597 core.String kind; | |
19598 | |
19599 FloodlightConfigurationsListResponse(); | |
19600 | |
19601 FloodlightConfigurationsListResponse.fromJson(core.Map _json) { | |
19602 if (_json.containsKey("floodlightConfigurations")) { | |
19603 floodlightConfigurations = _json["floodlightConfigurations"].map((value) =
> new FloodlightConfiguration.fromJson(value)).toList(); | |
19604 } | |
19605 if (_json.containsKey("kind")) { | |
19606 kind = _json["kind"]; | |
19607 } | |
19608 } | |
19609 | |
19610 core.Map toJson() { | |
19611 var _json = new core.Map(); | |
19612 if (floodlightConfigurations != null) { | |
19613 _json["floodlightConfigurations"] = floodlightConfigurations.map((value) =
> (value).toJson()).toList(); | |
19614 } | |
19615 if (kind != null) { | |
19616 _json["kind"] = kind; | |
19617 } | |
19618 return _json; | |
19619 } | |
19620 } | |
19621 | |
19622 /** | |
19623 * Represents fields that are compatible to be selected for a report of type | |
19624 * "FlOODLIGHT". | |
19625 */ | |
19626 class FloodlightReportCompatibleFields { | |
19627 /** | |
19628 * Dimensions which are compatible to be selected in the "dimensionFilters" | |
19629 * section of the report. | |
19630 */ | |
19631 core.List<Dimension> dimensionFilters; | |
19632 /** | |
19633 * Dimensions which are compatible to be selected in the "dimensions" section | |
19634 * of the report. | |
19635 */ | |
19636 core.List<Dimension> dimensions; | |
19637 /** | |
19638 * The kind of resource this is, in this case | |
19639 * dfareporting#floodlightReportCompatibleFields. | |
19640 */ | |
19641 core.String kind; | |
19642 /** | |
19643 * Metrics which are compatible to be selected in the "metricNames" section of | |
19644 * the report. | |
19645 */ | |
19646 core.List<Metric> metrics; | |
19647 | |
19648 FloodlightReportCompatibleFields(); | |
19649 | |
19650 FloodlightReportCompatibleFields.fromJson(core.Map _json) { | |
19651 if (_json.containsKey("dimensionFilters")) { | |
19652 dimensionFilters = _json["dimensionFilters"].map((value) => new Dimension.
fromJson(value)).toList(); | |
19653 } | |
19654 if (_json.containsKey("dimensions")) { | |
19655 dimensions = _json["dimensions"].map((value) => new Dimension.fromJson(val
ue)).toList(); | |
19656 } | |
19657 if (_json.containsKey("kind")) { | |
19658 kind = _json["kind"]; | |
19659 } | |
19660 if (_json.containsKey("metrics")) { | |
19661 metrics = _json["metrics"].map((value) => new Metric.fromJson(value)).toLi
st(); | |
19662 } | |
19663 } | |
19664 | |
19665 core.Map toJson() { | |
19666 var _json = new core.Map(); | |
19667 if (dimensionFilters != null) { | |
19668 _json["dimensionFilters"] = dimensionFilters.map((value) => (value).toJson
()).toList(); | |
19669 } | |
19670 if (dimensions != null) { | |
19671 _json["dimensions"] = dimensions.map((value) => (value).toJson()).toList()
; | |
19672 } | |
19673 if (kind != null) { | |
19674 _json["kind"] = kind; | |
19675 } | |
19676 if (metrics != null) { | |
19677 _json["metrics"] = metrics.map((value) => (value).toJson()).toList(); | |
19678 } | |
19679 return _json; | |
19680 } | |
19681 } | |
19682 | |
19683 /** Frequency Cap. */ | |
19684 class FrequencyCap { | |
19685 /** | |
19686 * Duration of time, in seconds, for this frequency cap. The maximum duration | |
19687 * is 90 days in seconds, or 7,776,000. | |
19688 */ | |
19689 core.String duration; | |
19690 /** | |
19691 * Number of times an individual user can be served the ad within the | |
19692 * specified duration. The maximum allowed is 15. | |
19693 */ | |
19694 core.String impressions; | |
19695 | |
19696 FrequencyCap(); | |
19697 | |
19698 FrequencyCap.fromJson(core.Map _json) { | |
19699 if (_json.containsKey("duration")) { | |
19700 duration = _json["duration"]; | |
19701 } | |
19702 if (_json.containsKey("impressions")) { | |
19703 impressions = _json["impressions"]; | |
19704 } | |
19705 } | |
19706 | |
19707 core.Map toJson() { | |
19708 var _json = new core.Map(); | |
19709 if (duration != null) { | |
19710 _json["duration"] = duration; | |
19711 } | |
19712 if (impressions != null) { | |
19713 _json["impressions"] = impressions; | |
19714 } | |
19715 return _json; | |
19716 } | |
19717 } | |
19718 | |
19719 /** FsCommand. */ | |
19720 class FsCommand { | |
19721 /** | |
19722 * Distance from the left of the browser.Applicable when positionOption is | |
19723 * DISTANCE_FROM_TOP_LEFT_CORNER. | |
19724 */ | |
19725 core.int left; | |
19726 /** | |
19727 * Position in the browser where the window will open. | |
19728 * Possible string values are: | |
19729 * - "CENTERED" | |
19730 * - "DISTANCE_FROM_TOP_LEFT_CORNER" | |
19731 */ | |
19732 core.String positionOption; | |
19733 /** | |
19734 * Distance from the top of the browser. Applicable when positionOption is | |
19735 * DISTANCE_FROM_TOP_LEFT_CORNER. | |
19736 */ | |
19737 core.int top; | |
19738 /** Height of the window. */ | |
19739 core.int windowHeight; | |
19740 /** Width of the window. */ | |
19741 core.int windowWidth; | |
19742 | |
19743 FsCommand(); | |
19744 | |
19745 FsCommand.fromJson(core.Map _json) { | |
19746 if (_json.containsKey("left")) { | |
19747 left = _json["left"]; | |
19748 } | |
19749 if (_json.containsKey("positionOption")) { | |
19750 positionOption = _json["positionOption"]; | |
19751 } | |
19752 if (_json.containsKey("top")) { | |
19753 top = _json["top"]; | |
19754 } | |
19755 if (_json.containsKey("windowHeight")) { | |
19756 windowHeight = _json["windowHeight"]; | |
19757 } | |
19758 if (_json.containsKey("windowWidth")) { | |
19759 windowWidth = _json["windowWidth"]; | |
19760 } | |
19761 } | |
19762 | |
19763 core.Map toJson() { | |
19764 var _json = new core.Map(); | |
19765 if (left != null) { | |
19766 _json["left"] = left; | |
19767 } | |
19768 if (positionOption != null) { | |
19769 _json["positionOption"] = positionOption; | |
19770 } | |
19771 if (top != null) { | |
19772 _json["top"] = top; | |
19773 } | |
19774 if (windowHeight != null) { | |
19775 _json["windowHeight"] = windowHeight; | |
19776 } | |
19777 if (windowWidth != null) { | |
19778 _json["windowWidth"] = windowWidth; | |
19779 } | |
19780 return _json; | |
19781 } | |
19782 } | |
19783 | |
19784 /** Geographical Targeting. */ | |
19785 class GeoTargeting { | |
19786 /** | |
19787 * Cities to be targeted. For each city only dartId is required. The other | |
19788 * fields are populated automatically when the ad is inserted or updated. If | |
19789 * targeting a city, do not target or exclude the country of the city, and do | |
19790 * not target the metro or region of the city. | |
19791 */ | |
19792 core.List<City> cities; | |
19793 /** | |
19794 * Countries to be targeted or excluded from targeting, depending on the | |
19795 * setting of the excludeCountries field. For each country only dartId is | |
19796 * required. The other fields are populated automatically when the ad is | |
19797 * inserted or updated. If targeting or excluding a country, do not target | |
19798 * regions, cities, metros, or postal codes in the same country. | |
19799 */ | |
19800 core.List<Country> countries; | |
19801 /** | |
19802 * Whether or not to exclude the countries in the countries field from | |
19803 * targeting. If false, the countries field refers to countries which will be | |
19804 * targeted by the ad. | |
19805 */ | |
19806 core.bool excludeCountries; | |
19807 /** | |
19808 * Metros to be targeted. For each metro only dmaId is required. The other | |
19809 * fields are populated automatically when the ad is inserted or updated. If | |
19810 * targeting a metro, do not target or exclude the country of the metro. | |
19811 */ | |
19812 core.List<Metro> metros; | |
19813 /** | |
19814 * Postal codes to be targeted. For each postal code only id is required. The | |
19815 * other fields are populated automatically when the ad is inserted or | |
19816 * updated. If targeting a postal code, do not target or exclude the country | |
19817 * of the postal code. | |
19818 */ | |
19819 core.List<PostalCode> postalCodes; | |
19820 /** | |
19821 * Regions to be targeted. For each region only dartId is required. The other | |
19822 * fields are populated automatically when the ad is inserted or updated. If | |
19823 * targeting a region, do not target or exclude the country of the region. | |
19824 */ | |
19825 core.List<Region> regions; | |
19826 | |
19827 GeoTargeting(); | |
19828 | |
19829 GeoTargeting.fromJson(core.Map _json) { | |
19830 if (_json.containsKey("cities")) { | |
19831 cities = _json["cities"].map((value) => new City.fromJson(value)).toList()
; | |
19832 } | |
19833 if (_json.containsKey("countries")) { | |
19834 countries = _json["countries"].map((value) => new Country.fromJson(value))
.toList(); | |
19835 } | |
19836 if (_json.containsKey("excludeCountries")) { | |
19837 excludeCountries = _json["excludeCountries"]; | |
19838 } | |
19839 if (_json.containsKey("metros")) { | |
19840 metros = _json["metros"].map((value) => new Metro.fromJson(value)).toList(
); | |
19841 } | |
19842 if (_json.containsKey("postalCodes")) { | |
19843 postalCodes = _json["postalCodes"].map((value) => new PostalCode.fromJson(
value)).toList(); | |
19844 } | |
19845 if (_json.containsKey("regions")) { | |
19846 regions = _json["regions"].map((value) => new Region.fromJson(value)).toLi
st(); | |
19847 } | |
19848 } | |
19849 | |
19850 core.Map toJson() { | |
19851 var _json = new core.Map(); | |
19852 if (cities != null) { | |
19853 _json["cities"] = cities.map((value) => (value).toJson()).toList(); | |
19854 } | |
19855 if (countries != null) { | |
19856 _json["countries"] = countries.map((value) => (value).toJson()).toList(); | |
19857 } | |
19858 if (excludeCountries != null) { | |
19859 _json["excludeCountries"] = excludeCountries; | |
19860 } | |
19861 if (metros != null) { | |
19862 _json["metros"] = metros.map((value) => (value).toJson()).toList(); | |
19863 } | |
19864 if (postalCodes != null) { | |
19865 _json["postalCodes"] = postalCodes.map((value) => (value).toJson()).toList
(); | |
19866 } | |
19867 if (regions != null) { | |
19868 _json["regions"] = regions.map((value) => (value).toJson()).toList(); | |
19869 } | |
19870 return _json; | |
19871 } | |
19872 } | |
19873 | |
19874 /** Represents a buy from the DoubleClick Planning inventory store. */ | |
19875 class InventoryItem { | |
19876 /** Account ID of this inventory item. */ | |
19877 core.String accountId; | |
19878 /** | |
19879 * Ad slots of this inventory item. If this inventory item represents a | |
19880 * standalone placement, there will be exactly one ad slot. If this inventory | |
19881 * item represents a placement group, there will be more than one ad slot, | |
19882 * each representing one child placement in that placement group. | |
19883 */ | |
19884 core.List<AdSlot> adSlots; | |
19885 /** Advertiser ID of this inventory item. */ | |
19886 core.String advertiserId; | |
19887 /** Content category ID of this inventory item. */ | |
19888 core.String contentCategoryId; | |
19889 /** Estimated click-through rate of this inventory item. */ | |
19890 core.String estimatedClickThroughRate; | |
19891 /** Estimated conversion rate of this inventory item. */ | |
19892 core.String estimatedConversionRate; | |
19893 /** ID of this inventory item. */ | |
19894 core.String id; | |
19895 /** Whether this inventory item is in plan. */ | |
19896 core.bool inPlan; | |
19897 /** | |
19898 * Identifies what kind of resource this is. Value: the fixed string | |
19899 * "dfareporting#inventoryItem". | |
19900 */ | |
19901 core.String kind; | |
19902 /** Information about the most recent modification of this inventory item. */ | |
19903 LastModifiedInfo lastModifiedInfo; | |
19904 /** | |
19905 * Name of this inventory item. For standalone inventory items, this is the | |
19906 * same name as that of its only ad slot. For group inventory items, this can | |
19907 * differ from the name of any of its ad slots. | |
19908 */ | |
19909 core.String name; | |
19910 /** Negotiation channel ID of this inventory item. */ | |
19911 core.String negotiationChannelId; | |
19912 /** Order ID of this inventory item. */ | |
19913 core.String orderId; | |
19914 /** Placement strategy ID of this inventory item. */ | |
19915 core.String placementStrategyId; | |
19916 /** Pricing of this inventory item. */ | |
19917 Pricing pricing; | |
19918 /** Project ID of this inventory item. */ | |
19919 core.String projectId; | |
19920 /** RFP ID of this inventory item. */ | |
19921 core.String rfpId; | |
19922 /** ID of the site this inventory item is associated with. */ | |
19923 core.String siteId; | |
19924 /** Subaccount ID of this inventory item. */ | |
19925 core.String subaccountId; | |
19926 | |
19927 InventoryItem(); | |
19928 | |
19929 InventoryItem.fromJson(core.Map _json) { | |
19930 if (_json.containsKey("accountId")) { | |
19931 accountId = _json["accountId"]; | |
19932 } | |
19933 if (_json.containsKey("adSlots")) { | |
19934 adSlots = _json["adSlots"].map((value) => new AdSlot.fromJson(value)).toLi
st(); | |
19935 } | |
19936 if (_json.containsKey("advertiserId")) { | |
19937 advertiserId = _json["advertiserId"]; | |
19938 } | |
19939 if (_json.containsKey("contentCategoryId")) { | |
19940 contentCategoryId = _json["contentCategoryId"]; | |
19941 } | |
19942 if (_json.containsKey("estimatedClickThroughRate")) { | |
19943 estimatedClickThroughRate = _json["estimatedClickThroughRate"]; | |
19944 } | |
19945 if (_json.containsKey("estimatedConversionRate")) { | |
19946 estimatedConversionRate = _json["estimatedConversionRate"]; | |
19947 } | |
19948 if (_json.containsKey("id")) { | |
19949 id = _json["id"]; | |
19950 } | |
19951 if (_json.containsKey("inPlan")) { | |
19952 inPlan = _json["inPlan"]; | |
19953 } | |
19954 if (_json.containsKey("kind")) { | |
19955 kind = _json["kind"]; | |
19956 } | |
19957 if (_json.containsKey("lastModifiedInfo")) { | |
19958 lastModifiedInfo = new LastModifiedInfo.fromJson(_json["lastModifiedInfo"]
); | |
19959 } | |
19960 if (_json.containsKey("name")) { | |
19961 name = _json["name"]; | |
19962 } | |
19963 if (_json.containsKey("negotiationChannelId")) { | |
19964 negotiationChannelId = _json["negotiationChannelId"]; | |
19965 } | |
19966 if (_json.containsKey("orderId")) { | |
19967 orderId = _json["orderId"]; | |
19968 } | |
19969 if (_json.containsKey("placementStrategyId")) { | |
19970 placementStrategyId = _json["placementStrategyId"]; | |
19971 } | |
19972 if (_json.containsKey("pricing")) { | |
19973 pricing = new Pricing.fromJson(_json["pricing"]); | |
19974 } | |
19975 if (_json.containsKey("projectId")) { | |
19976 projectId = _json["projectId"]; | |
19977 } | |
19978 if (_json.containsKey("rfpId")) { | |
19979 rfpId = _json["rfpId"]; | |
19980 } | |
19981 if (_json.containsKey("siteId")) { | |
19982 siteId = _json["siteId"]; | |
19983 } | |
19984 if (_json.containsKey("subaccountId")) { | |
19985 subaccountId = _json["subaccountId"]; | |
19986 } | |
19987 } | |
19988 | |
19989 core.Map toJson() { | |
19990 var _json = new core.Map(); | |
19991 if (accountId != null) { | |
19992 _json["accountId"] = accountId; | |
19993 } | |
19994 if (adSlots != null) { | |
19995 _json["adSlots"] = adSlots.map((value) => (value).toJson()).toList(); | |
19996 } | |
19997 if (advertiserId != null) { | |
19998 _json["advertiserId"] = advertiserId; | |
19999 } | |
20000 if (contentCategoryId != null) { | |
20001 _json["contentCategoryId"] = contentCategoryId; | |
20002 } | |
20003 if (estimatedClickThroughRate != null) { | |
20004 _json["estimatedClickThroughRate"] = estimatedClickThroughRate; | |
20005 } | |
20006 if (estimatedConversionRate != null) { | |
20007 _json["estimatedConversionRate"] = estimatedConversionRate; | |
20008 } | |
20009 if (id != null) { | |
20010 _json["id"] = id; | |
20011 } | |
20012 if (inPlan != null) { | |
20013 _json["inPlan"] = inPlan; | |
20014 } | |
20015 if (kind != null) { | |
20016 _json["kind"] = kind; | |
20017 } | |
20018 if (lastModifiedInfo != null) { | |
20019 _json["lastModifiedInfo"] = (lastModifiedInfo).toJson(); | |
20020 } | |
20021 if (name != null) { | |
20022 _json["name"] = name; | |
20023 } | |
20024 if (negotiationChannelId != null) { | |
20025 _json["negotiationChannelId"] = negotiationChannelId; | |
20026 } | |
20027 if (orderId != null) { | |
20028 _json["orderId"] = orderId; | |
20029 } | |
20030 if (placementStrategyId != null) { | |
20031 _json["placementStrategyId"] = placementStrategyId; | |
20032 } | |
20033 if (pricing != null) { | |
20034 _json["pricing"] = (pricing).toJson(); | |
20035 } | |
20036 if (projectId != null) { | |
20037 _json["projectId"] = projectId; | |
20038 } | |
20039 if (rfpId != null) { | |
20040 _json["rfpId"] = rfpId; | |
20041 } | |
20042 if (siteId != null) { | |
20043 _json["siteId"] = siteId; | |
20044 } | |
20045 if (subaccountId != null) { | |
20046 _json["subaccountId"] = subaccountId; | |
20047 } | |
20048 return _json; | |
20049 } | |
20050 } | |
20051 | |
20052 /** Inventory item List Response */ | |
20053 class InventoryItemsListResponse { | |
20054 /** Inventory item collection */ | |
20055 core.List<InventoryItem> inventoryItems; | |
20056 /** | |
20057 * Identifies what kind of resource this is. Value: the fixed string | |
20058 * "dfareporting#inventoryItemsListResponse". | |
20059 */ | |
20060 core.String kind; | |
20061 /** Pagination token to be used for the next list operation. */ | |
20062 core.String nextPageToken; | |
20063 | |
20064 InventoryItemsListResponse(); | |
20065 | |
20066 InventoryItemsListResponse.fromJson(core.Map _json) { | |
20067 if (_json.containsKey("inventoryItems")) { | |
20068 inventoryItems = _json["inventoryItems"].map((value) => new InventoryItem.
fromJson(value)).toList(); | |
20069 } | |
20070 if (_json.containsKey("kind")) { | |
20071 kind = _json["kind"]; | |
20072 } | |
20073 if (_json.containsKey("nextPageToken")) { | |
20074 nextPageToken = _json["nextPageToken"]; | |
20075 } | |
20076 } | |
20077 | |
20078 core.Map toJson() { | |
20079 var _json = new core.Map(); | |
20080 if (inventoryItems != null) { | |
20081 _json["inventoryItems"] = inventoryItems.map((value) => (value).toJson()).
toList(); | |
20082 } | |
20083 if (kind != null) { | |
20084 _json["kind"] = kind; | |
20085 } | |
20086 if (nextPageToken != null) { | |
20087 _json["nextPageToken"] = nextPageToken; | |
20088 } | |
20089 return _json; | |
20090 } | |
20091 } | |
20092 | |
20093 /** Key Value Targeting Expression. */ | |
20094 class KeyValueTargetingExpression { | |
20095 /** Keyword expression being targeted by the ad. */ | |
20096 core.String expression; | |
20097 | |
20098 KeyValueTargetingExpression(); | |
20099 | |
20100 KeyValueTargetingExpression.fromJson(core.Map _json) { | |
20101 if (_json.containsKey("expression")) { | |
20102 expression = _json["expression"]; | |
20103 } | |
20104 } | |
20105 | |
20106 core.Map toJson() { | |
20107 var _json = new core.Map(); | |
20108 if (expression != null) { | |
20109 _json["expression"] = expression; | |
20110 } | |
20111 return _json; | |
20112 } | |
20113 } | |
20114 | |
20115 /** | |
20116 * Contains information about where a user's browser is taken after the user | |
20117 * clicks an ad. | |
20118 */ | |
20119 class LandingPage { | |
20120 /** | |
20121 * Whether or not this landing page will be assigned to any ads or creatives | |
20122 * that do not have a landing page assigned explicitly. Only one default | |
20123 * landing page is allowed per campaign. | |
20124 */ | |
20125 core.bool default_; | |
20126 /** ID of this landing page. This is a read-only, auto-generated field. */ | |
20127 core.String id; | |
20128 /** | |
20129 * Identifies what kind of resource this is. Value: the fixed string | |
20130 * "dfareporting#landingPage". | |
20131 */ | |
20132 core.String kind; | |
20133 /** | |
20134 * Name of this landing page. This is a required field. It must be less than | |
20135 * 256 characters long, and must be unique among landing pages of the same | |
20136 * campaign. | |
20137 */ | |
20138 core.String name; | |
20139 /** URL of this landing page. This is a required field. */ | |
20140 core.String url; | |
20141 | |
20142 LandingPage(); | |
20143 | |
20144 LandingPage.fromJson(core.Map _json) { | |
20145 if (_json.containsKey("default")) { | |
20146 default_ = _json["default"]; | |
20147 } | |
20148 if (_json.containsKey("id")) { | |
20149 id = _json["id"]; | |
20150 } | |
20151 if (_json.containsKey("kind")) { | |
20152 kind = _json["kind"]; | |
20153 } | |
20154 if (_json.containsKey("name")) { | |
20155 name = _json["name"]; | |
20156 } | |
20157 if (_json.containsKey("url")) { | |
20158 url = _json["url"]; | |
20159 } | |
20160 } | |
20161 | |
20162 core.Map toJson() { | |
20163 var _json = new core.Map(); | |
20164 if (default_ != null) { | |
20165 _json["default"] = default_; | |
20166 } | |
20167 if (id != null) { | |
20168 _json["id"] = id; | |
20169 } | |
20170 if (kind != null) { | |
20171 _json["kind"] = kind; | |
20172 } | |
20173 if (name != null) { | |
20174 _json["name"] = name; | |
20175 } | |
20176 if (url != null) { | |
20177 _json["url"] = url; | |
20178 } | |
20179 return _json; | |
20180 } | |
20181 } | |
20182 | |
20183 /** Landing Page List Response */ | |
20184 class LandingPagesListResponse { | |
20185 /** | |
20186 * Identifies what kind of resource this is. Value: the fixed string | |
20187 * "dfareporting#landingPagesListResponse". | |
20188 */ | |
20189 core.String kind; | |
20190 /** Landing page collection */ | |
20191 core.List<LandingPage> landingPages; | |
20192 | |
20193 LandingPagesListResponse(); | |
20194 | |
20195 LandingPagesListResponse.fromJson(core.Map _json) { | |
20196 if (_json.containsKey("kind")) { | |
20197 kind = _json["kind"]; | |
20198 } | |
20199 if (_json.containsKey("landingPages")) { | |
20200 landingPages = _json["landingPages"].map((value) => new LandingPage.fromJs
on(value)).toList(); | |
20201 } | |
20202 } | |
20203 | |
20204 core.Map toJson() { | |
20205 var _json = new core.Map(); | |
20206 if (kind != null) { | |
20207 _json["kind"] = kind; | |
20208 } | |
20209 if (landingPages != null) { | |
20210 _json["landingPages"] = landingPages.map((value) => (value).toJson()).toLi
st(); | |
20211 } | |
20212 return _json; | |
20213 } | |
20214 } | |
20215 | |
20216 /** Modification timestamp. */ | |
20217 class LastModifiedInfo { | |
20218 /** Timestamp of the last change in milliseconds since epoch. */ | |
20219 core.String time; | |
20220 | |
20221 LastModifiedInfo(); | |
20222 | |
20223 LastModifiedInfo.fromJson(core.Map _json) { | |
20224 if (_json.containsKey("time")) { | |
20225 time = _json["time"]; | |
20226 } | |
20227 } | |
20228 | |
20229 core.Map toJson() { | |
20230 var _json = new core.Map(); | |
20231 if (time != null) { | |
20232 _json["time"] = time; | |
20233 } | |
20234 return _json; | |
20235 } | |
20236 } | |
20237 | |
20238 /** | |
20239 * A group clause made up of list population terms representing constraints | |
20240 * joined by ORs. | |
20241 */ | |
20242 class ListPopulationClause { | |
20243 /** | |
20244 * Terms of this list population clause. Each clause is made up of list | |
20245 * population terms representing constraints and are joined by ORs. | |
20246 */ | |
20247 core.List<ListPopulationTerm> terms; | |
20248 | |
20249 ListPopulationClause(); | |
20250 | |
20251 ListPopulationClause.fromJson(core.Map _json) { | |
20252 if (_json.containsKey("terms")) { | |
20253 terms = _json["terms"].map((value) => new ListPopulationTerm.fromJson(valu
e)).toList(); | |
20254 } | |
20255 } | |
20256 | |
20257 core.Map toJson() { | |
20258 var _json = new core.Map(); | |
20259 if (terms != null) { | |
20260 _json["terms"] = terms.map((value) => (value).toJson()).toList(); | |
20261 } | |
20262 return _json; | |
20263 } | |
20264 } | |
20265 | |
20266 /** Remarketing List Population Rule. */ | |
20267 class ListPopulationRule { | |
20268 /** | |
20269 * Floodlight activity ID associated with this rule. This field can be left | |
20270 * blank. | |
20271 */ | |
20272 core.String floodlightActivityId; | |
20273 /** | |
20274 * Name of floodlight activity associated with this rule. This is a read-only, | |
20275 * auto-generated field. | |
20276 */ | |
20277 core.String floodlightActivityName; | |
20278 /** | |
20279 * Clauses that make up this list population rule. Clauses are joined by ANDs, | |
20280 * and the clauses themselves are made up of list population terms which are | |
20281 * joined by ORs. | |
20282 */ | |
20283 core.List<ListPopulationClause> listPopulationClauses; | |
20284 | |
20285 ListPopulationRule(); | |
20286 | |
20287 ListPopulationRule.fromJson(core.Map _json) { | |
20288 if (_json.containsKey("floodlightActivityId")) { | |
20289 floodlightActivityId = _json["floodlightActivityId"]; | |
20290 } | |
20291 if (_json.containsKey("floodlightActivityName")) { | |
20292 floodlightActivityName = _json["floodlightActivityName"]; | |
20293 } | |
20294 if (_json.containsKey("listPopulationClauses")) { | |
20295 listPopulationClauses = _json["listPopulationClauses"].map((value) => new
ListPopulationClause.fromJson(value)).toList(); | |
20296 } | |
20297 } | |
20298 | |
20299 core.Map toJson() { | |
20300 var _json = new core.Map(); | |
20301 if (floodlightActivityId != null) { | |
20302 _json["floodlightActivityId"] = floodlightActivityId; | |
20303 } | |
20304 if (floodlightActivityName != null) { | |
20305 _json["floodlightActivityName"] = floodlightActivityName; | |
20306 } | |
20307 if (listPopulationClauses != null) { | |
20308 _json["listPopulationClauses"] = listPopulationClauses.map((value) => (val
ue).toJson()).toList(); | |
20309 } | |
20310 return _json; | |
20311 } | |
20312 } | |
20313 | |
20314 /** Remarketing List Population Rule Term. */ | |
20315 class ListPopulationTerm { | |
20316 /** | |
20317 * Will be true if the term should check if the user is in the list and false | |
20318 * if the term should check if the user is not in the list. This field is only | |
20319 * relevant when type is set to LIST_MEMBERSHIP_TERM. False by default. | |
20320 */ | |
20321 core.bool contains; | |
20322 /** | |
20323 * Whether to negate the comparison result of this term during rule | |
20324 * evaluation. This field is only relevant when type is left unset or set to | |
20325 * CUSTOM_VARIABLE_TERM or REFERRER_TERM. | |
20326 */ | |
20327 core.bool negation; | |
20328 /** | |
20329 * Comparison operator of this term. This field is only relevant when type is | |
20330 * left unset or set to CUSTOM_VARIABLE_TERM or REFERRER_TERM. | |
20331 * Possible string values are: | |
20332 * - "NUM_EQUALS" | |
20333 * - "NUM_GREATER_THAN" | |
20334 * - "NUM_GREATER_THAN_EQUAL" | |
20335 * - "NUM_LESS_THAN" | |
20336 * - "NUM_LESS_THAN_EQUAL" | |
20337 * - "STRING_CONTAINS" | |
20338 * - "STRING_EQUALS" | |
20339 */ | |
20340 core.String operator; | |
20341 /** | |
20342 * ID of the list in question. This field is only relevant when type is set to | |
20343 * LIST_MEMBERSHIP_TERM. | |
20344 */ | |
20345 core.String remarketingListId; | |
20346 /** | |
20347 * List population term type determines the applicable fields in this object. | |
20348 * If left unset or set to CUSTOM_VARIABLE_TERM, then variableName, | |
20349 * variableFriendlyName, operator, value, and negation are applicable. If set | |
20350 * to LIST_MEMBERSHIP_TERM then remarketingListId and contains are applicable. | |
20351 * If set to REFERRER_TERM then operator, value, and negation are applicable. | |
20352 * Possible string values are: | |
20353 * - "CUSTOM_VARIABLE_TERM" | |
20354 * - "LIST_MEMBERSHIP_TERM" | |
20355 * - "REFERRER_TERM" | |
20356 */ | |
20357 core.String type; | |
20358 /** | |
20359 * Literal to compare the variable to. This field is only relevant when type | |
20360 * is left unset or set to CUSTOM_VARIABLE_TERM or REFERRER_TERM. | |
20361 */ | |
20362 core.String value; | |
20363 /** | |
20364 * Friendly name of this term's variable. This is a read-only, auto-generated | |
20365 * field. This field is only relevant when type is left unset or set to | |
20366 * CUSTOM_VARIABLE_TERM. | |
20367 */ | |
20368 core.String variableFriendlyName; | |
20369 /** | |
20370 * Name of the variable (U1, U2, etc.) being compared in this term. This field | |
20371 * is only relevant when type is set to null, CUSTOM_VARIABLE_TERM or | |
20372 * REFERRER_TERM. | |
20373 */ | |
20374 core.String variableName; | |
20375 | |
20376 ListPopulationTerm(); | |
20377 | |
20378 ListPopulationTerm.fromJson(core.Map _json) { | |
20379 if (_json.containsKey("contains")) { | |
20380 contains = _json["contains"]; | |
20381 } | |
20382 if (_json.containsKey("negation")) { | |
20383 negation = _json["negation"]; | |
20384 } | |
20385 if (_json.containsKey("operator")) { | |
20386 operator = _json["operator"]; | |
20387 } | |
20388 if (_json.containsKey("remarketingListId")) { | |
20389 remarketingListId = _json["remarketingListId"]; | |
20390 } | |
20391 if (_json.containsKey("type")) { | |
20392 type = _json["type"]; | |
20393 } | |
20394 if (_json.containsKey("value")) { | |
20395 value = _json["value"]; | |
20396 } | |
20397 if (_json.containsKey("variableFriendlyName")) { | |
20398 variableFriendlyName = _json["variableFriendlyName"]; | |
20399 } | |
20400 if (_json.containsKey("variableName")) { | |
20401 variableName = _json["variableName"]; | |
20402 } | |
20403 } | |
20404 | |
20405 core.Map toJson() { | |
20406 var _json = new core.Map(); | |
20407 if (contains != null) { | |
20408 _json["contains"] = contains; | |
20409 } | |
20410 if (negation != null) { | |
20411 _json["negation"] = negation; | |
20412 } | |
20413 if (operator != null) { | |
20414 _json["operator"] = operator; | |
20415 } | |
20416 if (remarketingListId != null) { | |
20417 _json["remarketingListId"] = remarketingListId; | |
20418 } | |
20419 if (type != null) { | |
20420 _json["type"] = type; | |
20421 } | |
20422 if (value != null) { | |
20423 _json["value"] = value; | |
20424 } | |
20425 if (variableFriendlyName != null) { | |
20426 _json["variableFriendlyName"] = variableFriendlyName; | |
20427 } | |
20428 if (variableName != null) { | |
20429 _json["variableName"] = variableName; | |
20430 } | |
20431 return _json; | |
20432 } | |
20433 } | |
20434 | |
20435 /** Remarketing List Targeting Expression. */ | |
20436 class ListTargetingExpression { | |
20437 /** Expression describing which lists are being targeted by the ad. */ | |
20438 core.String expression; | |
20439 | |
20440 ListTargetingExpression(); | |
20441 | |
20442 ListTargetingExpression.fromJson(core.Map _json) { | |
20443 if (_json.containsKey("expression")) { | |
20444 expression = _json["expression"]; | |
20445 } | |
20446 } | |
20447 | |
20448 core.Map toJson() { | |
20449 var _json = new core.Map(); | |
20450 if (expression != null) { | |
20451 _json["expression"] = expression; | |
20452 } | |
20453 return _json; | |
20454 } | |
20455 } | |
20456 | |
20457 /** Lookback configuration settings. */ | |
20458 class LookbackConfiguration { | |
20459 /** | |
20460 * Lookback window, in days, from the last time a given user clicked on one of | |
20461 * your ads. If you enter 0, clicks will not be considered as triggering | |
20462 * events for floodlight tracking. If you leave this field blank, the default | |
20463 * value for your account will be used. | |
20464 */ | |
20465 core.int clickDuration; | |
20466 /** | |
20467 * Lookback window, in days, from the last time a given user viewed one of | |
20468 * your ads. If you enter 0, impressions will not be considered as triggering | |
20469 * events for floodlight tracking. If you leave this field blank, the default | |
20470 * value for your account will be used. | |
20471 */ | |
20472 core.int postImpressionActivitiesDuration; | |
20473 | |
20474 LookbackConfiguration(); | |
20475 | |
20476 LookbackConfiguration.fromJson(core.Map _json) { | |
20477 if (_json.containsKey("clickDuration")) { | |
20478 clickDuration = _json["clickDuration"]; | |
20479 } | |
20480 if (_json.containsKey("postImpressionActivitiesDuration")) { | |
20481 postImpressionActivitiesDuration = _json["postImpressionActivitiesDuration
"]; | |
20482 } | |
20483 } | |
20484 | |
20485 core.Map toJson() { | |
20486 var _json = new core.Map(); | |
20487 if (clickDuration != null) { | |
20488 _json["clickDuration"] = clickDuration; | |
20489 } | |
20490 if (postImpressionActivitiesDuration != null) { | |
20491 _json["postImpressionActivitiesDuration"] = postImpressionActivitiesDurati
on; | |
20492 } | |
20493 return _json; | |
20494 } | |
20495 } | |
20496 | |
20497 /** Represents a metric. */ | |
20498 class Metric { | |
20499 /** The kind of resource this is, in this case dfareporting#metric. */ | |
20500 core.String kind; | |
20501 /** The metric name, e.g. dfa:impressions */ | |
20502 core.String name; | |
20503 | |
20504 Metric(); | |
20505 | |
20506 Metric.fromJson(core.Map _json) { | |
20507 if (_json.containsKey("kind")) { | |
20508 kind = _json["kind"]; | |
20509 } | |
20510 if (_json.containsKey("name")) { | |
20511 name = _json["name"]; | |
20512 } | |
20513 } | |
20514 | |
20515 core.Map toJson() { | |
20516 var _json = new core.Map(); | |
20517 if (kind != null) { | |
20518 _json["kind"] = kind; | |
20519 } | |
20520 if (name != null) { | |
20521 _json["name"] = name; | |
20522 } | |
20523 return _json; | |
20524 } | |
20525 } | |
20526 | |
20527 /** Contains information about a metro region that can be targeted by ads. */ | |
20528 class Metro { | |
20529 /** Country code of the country to which this metro region belongs. */ | |
20530 core.String countryCode; | |
20531 /** DART ID of the country to which this metro region belongs. */ | |
20532 core.String countryDartId; | |
20533 /** DART ID of this metro region. */ | |
20534 core.String dartId; | |
20535 /** | |
20536 * DMA ID of this metro region. This is the ID used for targeting and | |
20537 * generating reports, and is equivalent to metro_code. | |
20538 */ | |
20539 core.String dmaId; | |
20540 /** | |
20541 * Identifies what kind of resource this is. Value: the fixed string | |
20542 * "dfareporting#metro". | |
20543 */ | |
20544 core.String kind; | |
20545 /** Metro code of this metro region. This is equivalent to dma_id. */ | |
20546 core.String metroCode; | |
20547 /** Name of this metro region. */ | |
20548 core.String name; | |
20549 | |
20550 Metro(); | |
20551 | |
20552 Metro.fromJson(core.Map _json) { | |
20553 if (_json.containsKey("countryCode")) { | |
20554 countryCode = _json["countryCode"]; | |
20555 } | |
20556 if (_json.containsKey("countryDartId")) { | |
20557 countryDartId = _json["countryDartId"]; | |
20558 } | |
20559 if (_json.containsKey("dartId")) { | |
20560 dartId = _json["dartId"]; | |
20561 } | |
20562 if (_json.containsKey("dmaId")) { | |
20563 dmaId = _json["dmaId"]; | |
20564 } | |
20565 if (_json.containsKey("kind")) { | |
20566 kind = _json["kind"]; | |
20567 } | |
20568 if (_json.containsKey("metroCode")) { | |
20569 metroCode = _json["metroCode"]; | |
20570 } | |
20571 if (_json.containsKey("name")) { | |
20572 name = _json["name"]; | |
20573 } | |
20574 } | |
20575 | |
20576 core.Map toJson() { | |
20577 var _json = new core.Map(); | |
20578 if (countryCode != null) { | |
20579 _json["countryCode"] = countryCode; | |
20580 } | |
20581 if (countryDartId != null) { | |
20582 _json["countryDartId"] = countryDartId; | |
20583 } | |
20584 if (dartId != null) { | |
20585 _json["dartId"] = dartId; | |
20586 } | |
20587 if (dmaId != null) { | |
20588 _json["dmaId"] = dmaId; | |
20589 } | |
20590 if (kind != null) { | |
20591 _json["kind"] = kind; | |
20592 } | |
20593 if (metroCode != null) { | |
20594 _json["metroCode"] = metroCode; | |
20595 } | |
20596 if (name != null) { | |
20597 _json["name"] = name; | |
20598 } | |
20599 return _json; | |
20600 } | |
20601 } | |
20602 | |
20603 /** Metro List Response */ | |
20604 class MetrosListResponse { | |
20605 /** | |
20606 * Identifies what kind of resource this is. Value: the fixed string | |
20607 * "dfareporting#metrosListResponse". | |
20608 */ | |
20609 core.String kind; | |
20610 /** Metro collection. */ | |
20611 core.List<Metro> metros; | |
20612 | |
20613 MetrosListResponse(); | |
20614 | |
20615 MetrosListResponse.fromJson(core.Map _json) { | |
20616 if (_json.containsKey("kind")) { | |
20617 kind = _json["kind"]; | |
20618 } | |
20619 if (_json.containsKey("metros")) { | |
20620 metros = _json["metros"].map((value) => new Metro.fromJson(value)).toList(
); | |
20621 } | |
20622 } | |
20623 | |
20624 core.Map toJson() { | |
20625 var _json = new core.Map(); | |
20626 if (kind != null) { | |
20627 _json["kind"] = kind; | |
20628 } | |
20629 if (metros != null) { | |
20630 _json["metros"] = metros.map((value) => (value).toJson()).toList(); | |
20631 } | |
20632 return _json; | |
20633 } | |
20634 } | |
20635 | |
20636 /** Contains information about a mobile carrier that can be targeted by ads. */ | |
20637 class MobileCarrier { | |
20638 /** Country code of the country to which this mobile carrier belongs. */ | |
20639 core.String countryCode; | |
20640 /** DART ID of the country to which this mobile carrier belongs. */ | |
20641 core.String countryDartId; | |
20642 /** ID of this mobile carrier. */ | |
20643 core.String id; | |
20644 /** | |
20645 * Identifies what kind of resource this is. Value: the fixed string | |
20646 * "dfareporting#mobileCarrier". | |
20647 */ | |
20648 core.String kind; | |
20649 /** Name of this mobile carrier. */ | |
20650 core.String name; | |
20651 | |
20652 MobileCarrier(); | |
20653 | |
20654 MobileCarrier.fromJson(core.Map _json) { | |
20655 if (_json.containsKey("countryCode")) { | |
20656 countryCode = _json["countryCode"]; | |
20657 } | |
20658 if (_json.containsKey("countryDartId")) { | |
20659 countryDartId = _json["countryDartId"]; | |
20660 } | |
20661 if (_json.containsKey("id")) { | |
20662 id = _json["id"]; | |
20663 } | |
20664 if (_json.containsKey("kind")) { | |
20665 kind = _json["kind"]; | |
20666 } | |
20667 if (_json.containsKey("name")) { | |
20668 name = _json["name"]; | |
20669 } | |
20670 } | |
20671 | |
20672 core.Map toJson() { | |
20673 var _json = new core.Map(); | |
20674 if (countryCode != null) { | |
20675 _json["countryCode"] = countryCode; | |
20676 } | |
20677 if (countryDartId != null) { | |
20678 _json["countryDartId"] = countryDartId; | |
20679 } | |
20680 if (id != null) { | |
20681 _json["id"] = id; | |
20682 } | |
20683 if (kind != null) { | |
20684 _json["kind"] = kind; | |
20685 } | |
20686 if (name != null) { | |
20687 _json["name"] = name; | |
20688 } | |
20689 return _json; | |
20690 } | |
20691 } | |
20692 | |
20693 /** Mobile Carrier List Response */ | |
20694 class MobileCarriersListResponse { | |
20695 /** | |
20696 * Identifies what kind of resource this is. Value: the fixed string | |
20697 * "dfareporting#mobileCarriersListResponse". | |
20698 */ | |
20699 core.String kind; | |
20700 /** Mobile carrier collection. */ | |
20701 core.List<MobileCarrier> mobileCarriers; | |
20702 | |
20703 MobileCarriersListResponse(); | |
20704 | |
20705 MobileCarriersListResponse.fromJson(core.Map _json) { | |
20706 if (_json.containsKey("kind")) { | |
20707 kind = _json["kind"]; | |
20708 } | |
20709 if (_json.containsKey("mobileCarriers")) { | |
20710 mobileCarriers = _json["mobileCarriers"].map((value) => new MobileCarrier.
fromJson(value)).toList(); | |
20711 } | |
20712 } | |
20713 | |
20714 core.Map toJson() { | |
20715 var _json = new core.Map(); | |
20716 if (kind != null) { | |
20717 _json["kind"] = kind; | |
20718 } | |
20719 if (mobileCarriers != null) { | |
20720 _json["mobileCarriers"] = mobileCarriers.map((value) => (value).toJson()).
toList(); | |
20721 } | |
20722 return _json; | |
20723 } | |
20724 } | |
20725 | |
20726 /** Object Filter. */ | |
20727 class ObjectFilter { | |
20728 /** | |
20729 * Identifies what kind of resource this is. Value: the fixed string | |
20730 * "dfareporting#objectFilter". | |
20731 */ | |
20732 core.String kind; | |
20733 /** | |
20734 * Applicable when status is ASSIGNED. The user has access to objects with | |
20735 * these object IDs. | |
20736 */ | |
20737 core.List<core.String> objectIds; | |
20738 /** | |
20739 * Status of the filter. NONE means the user has access to none of the | |
20740 * objects. ALL means the user has access to all objects. ASSIGNED means the | |
20741 * user has access to the objects with IDs in the objectIds list. | |
20742 * Possible string values are: | |
20743 * - "ALL" | |
20744 * - "ASSIGNED" | |
20745 * - "NONE" | |
20746 */ | |
20747 core.String status; | |
20748 | |
20749 ObjectFilter(); | |
20750 | |
20751 ObjectFilter.fromJson(core.Map _json) { | |
20752 if (_json.containsKey("kind")) { | |
20753 kind = _json["kind"]; | |
20754 } | |
20755 if (_json.containsKey("objectIds")) { | |
20756 objectIds = _json["objectIds"]; | |
20757 } | |
20758 if (_json.containsKey("status")) { | |
20759 status = _json["status"]; | |
20760 } | |
20761 } | |
20762 | |
20763 core.Map toJson() { | |
20764 var _json = new core.Map(); | |
20765 if (kind != null) { | |
20766 _json["kind"] = kind; | |
20767 } | |
20768 if (objectIds != null) { | |
20769 _json["objectIds"] = objectIds; | |
20770 } | |
20771 if (status != null) { | |
20772 _json["status"] = status; | |
20773 } | |
20774 return _json; | |
20775 } | |
20776 } | |
20777 | |
20778 /** Offset Position. */ | |
20779 class OffsetPosition { | |
20780 /** Offset distance from left side of an asset or a window. */ | |
20781 core.int left; | |
20782 /** Offset distance from top side of an asset or a window. */ | |
20783 core.int top; | |
20784 | |
20785 OffsetPosition(); | |
20786 | |
20787 OffsetPosition.fromJson(core.Map _json) { | |
20788 if (_json.containsKey("left")) { | |
20789 left = _json["left"]; | |
20790 } | |
20791 if (_json.containsKey("top")) { | |
20792 top = _json["top"]; | |
20793 } | |
20794 } | |
20795 | |
20796 core.Map toJson() { | |
20797 var _json = new core.Map(); | |
20798 if (left != null) { | |
20799 _json["left"] = left; | |
20800 } | |
20801 if (top != null) { | |
20802 _json["top"] = top; | |
20803 } | |
20804 return _json; | |
20805 } | |
20806 } | |
20807 | |
20808 /** Omniture Integration Settings. */ | |
20809 class OmnitureSettings { | |
20810 /** | |
20811 * Whether placement cost data will be sent to Omniture. This property can be | |
20812 * enabled only if omnitureIntegrationEnabled is true. | |
20813 */ | |
20814 core.bool omnitureCostDataEnabled; | |
20815 /** | |
20816 * Whether Omniture integration is enabled. This property can be enabled only | |
20817 * when the "Advanced Ad Serving" account setting is enabled. | |
20818 */ | |
20819 core.bool omnitureIntegrationEnabled; | |
20820 | |
20821 OmnitureSettings(); | |
20822 | |
20823 OmnitureSettings.fromJson(core.Map _json) { | |
20824 if (_json.containsKey("omnitureCostDataEnabled")) { | |
20825 omnitureCostDataEnabled = _json["omnitureCostDataEnabled"]; | |
20826 } | |
20827 if (_json.containsKey("omnitureIntegrationEnabled")) { | |
20828 omnitureIntegrationEnabled = _json["omnitureIntegrationEnabled"]; | |
20829 } | |
20830 } | |
20831 | |
20832 core.Map toJson() { | |
20833 var _json = new core.Map(); | |
20834 if (omnitureCostDataEnabled != null) { | |
20835 _json["omnitureCostDataEnabled"] = omnitureCostDataEnabled; | |
20836 } | |
20837 if (omnitureIntegrationEnabled != null) { | |
20838 _json["omnitureIntegrationEnabled"] = omnitureIntegrationEnabled; | |
20839 } | |
20840 return _json; | |
20841 } | |
20842 } | |
20843 | |
20844 /** | |
20845 * Contains information about an operating system that can be targeted by ads. | |
20846 */ | |
20847 class OperatingSystem { | |
20848 /** DART ID of this operating system. This is the ID used for targeting. */ | |
20849 core.String dartId; | |
20850 /** Whether this operating system is for desktop. */ | |
20851 core.bool desktop; | |
20852 /** | |
20853 * Identifies what kind of resource this is. Value: the fixed string | |
20854 * "dfareporting#operatingSystem". | |
20855 */ | |
20856 core.String kind; | |
20857 /** Whether this operating system is for mobile. */ | |
20858 core.bool mobile; | |
20859 /** Name of this operating system. */ | |
20860 core.String name; | |
20861 | |
20862 OperatingSystem(); | |
20863 | |
20864 OperatingSystem.fromJson(core.Map _json) { | |
20865 if (_json.containsKey("dartId")) { | |
20866 dartId = _json["dartId"]; | |
20867 } | |
20868 if (_json.containsKey("desktop")) { | |
20869 desktop = _json["desktop"]; | |
20870 } | |
20871 if (_json.containsKey("kind")) { | |
20872 kind = _json["kind"]; | |
20873 } | |
20874 if (_json.containsKey("mobile")) { | |
20875 mobile = _json["mobile"]; | |
20876 } | |
20877 if (_json.containsKey("name")) { | |
20878 name = _json["name"]; | |
20879 } | |
20880 } | |
20881 | |
20882 core.Map toJson() { | |
20883 var _json = new core.Map(); | |
20884 if (dartId != null) { | |
20885 _json["dartId"] = dartId; | |
20886 } | |
20887 if (desktop != null) { | |
20888 _json["desktop"] = desktop; | |
20889 } | |
20890 if (kind != null) { | |
20891 _json["kind"] = kind; | |
20892 } | |
20893 if (mobile != null) { | |
20894 _json["mobile"] = mobile; | |
20895 } | |
20896 if (name != null) { | |
20897 _json["name"] = name; | |
20898 } | |
20899 return _json; | |
20900 } | |
20901 } | |
20902 | |
20903 /** | |
20904 * Contains information about a particular version of an operating system that | |
20905 * can be targeted by ads. | |
20906 */ | |
20907 class OperatingSystemVersion { | |
20908 /** ID of this operating system version. */ | |
20909 core.String id; | |
20910 /** | |
20911 * Identifies what kind of resource this is. Value: the fixed string | |
20912 * "dfareporting#operatingSystemVersion". | |
20913 */ | |
20914 core.String kind; | |
20915 /** Major version (leftmost number) of this operating system version. */ | |
20916 core.String majorVersion; | |
20917 /** | |
20918 * Minor version (number after the first dot) of this operating system | |
20919 * version. | |
20920 */ | |
20921 core.String minorVersion; | |
20922 /** Name of this operating system version. */ | |
20923 core.String name; | |
20924 /** Operating system of this operating system version. */ | |
20925 OperatingSystem operatingSystem; | |
20926 | |
20927 OperatingSystemVersion(); | |
20928 | |
20929 OperatingSystemVersion.fromJson(core.Map _json) { | |
20930 if (_json.containsKey("id")) { | |
20931 id = _json["id"]; | |
20932 } | |
20933 if (_json.containsKey("kind")) { | |
20934 kind = _json["kind"]; | |
20935 } | |
20936 if (_json.containsKey("majorVersion")) { | |
20937 majorVersion = _json["majorVersion"]; | |
20938 } | |
20939 if (_json.containsKey("minorVersion")) { | |
20940 minorVersion = _json["minorVersion"]; | |
20941 } | |
20942 if (_json.containsKey("name")) { | |
20943 name = _json["name"]; | |
20944 } | |
20945 if (_json.containsKey("operatingSystem")) { | |
20946 operatingSystem = new OperatingSystem.fromJson(_json["operatingSystem"]); | |
20947 } | |
20948 } | |
20949 | |
20950 core.Map toJson() { | |
20951 var _json = new core.Map(); | |
20952 if (id != null) { | |
20953 _json["id"] = id; | |
20954 } | |
20955 if (kind != null) { | |
20956 _json["kind"] = kind; | |
20957 } | |
20958 if (majorVersion != null) { | |
20959 _json["majorVersion"] = majorVersion; | |
20960 } | |
20961 if (minorVersion != null) { | |
20962 _json["minorVersion"] = minorVersion; | |
20963 } | |
20964 if (name != null) { | |
20965 _json["name"] = name; | |
20966 } | |
20967 if (operatingSystem != null) { | |
20968 _json["operatingSystem"] = (operatingSystem).toJson(); | |
20969 } | |
20970 return _json; | |
20971 } | |
20972 } | |
20973 | |
20974 /** Operating System Version List Response */ | |
20975 class OperatingSystemVersionsListResponse { | |
20976 /** | |
20977 * Identifies what kind of resource this is. Value: the fixed string | |
20978 * "dfareporting#operatingSystemVersionsListResponse". | |
20979 */ | |
20980 core.String kind; | |
20981 /** Operating system version collection. */ | |
20982 core.List<OperatingSystemVersion> operatingSystemVersions; | |
20983 | |
20984 OperatingSystemVersionsListResponse(); | |
20985 | |
20986 OperatingSystemVersionsListResponse.fromJson(core.Map _json) { | |
20987 if (_json.containsKey("kind")) { | |
20988 kind = _json["kind"]; | |
20989 } | |
20990 if (_json.containsKey("operatingSystemVersions")) { | |
20991 operatingSystemVersions = _json["operatingSystemVersions"].map((value) =>
new OperatingSystemVersion.fromJson(value)).toList(); | |
20992 } | |
20993 } | |
20994 | |
20995 core.Map toJson() { | |
20996 var _json = new core.Map(); | |
20997 if (kind != null) { | |
20998 _json["kind"] = kind; | |
20999 } | |
21000 if (operatingSystemVersions != null) { | |
21001 _json["operatingSystemVersions"] = operatingSystemVersions.map((value) =>
(value).toJson()).toList(); | |
21002 } | |
21003 return _json; | |
21004 } | |
21005 } | |
21006 | |
21007 /** Operating System List Response */ | |
21008 class OperatingSystemsListResponse { | |
21009 /** | |
21010 * Identifies what kind of resource this is. Value: the fixed string | |
21011 * "dfareporting#operatingSystemsListResponse". | |
21012 */ | |
21013 core.String kind; | |
21014 /** Operating system collection. */ | |
21015 core.List<OperatingSystem> operatingSystems; | |
21016 | |
21017 OperatingSystemsListResponse(); | |
21018 | |
21019 OperatingSystemsListResponse.fromJson(core.Map _json) { | |
21020 if (_json.containsKey("kind")) { | |
21021 kind = _json["kind"]; | |
21022 } | |
21023 if (_json.containsKey("operatingSystems")) { | |
21024 operatingSystems = _json["operatingSystems"].map((value) => new OperatingS
ystem.fromJson(value)).toList(); | |
21025 } | |
21026 } | |
21027 | |
21028 core.Map toJson() { | |
21029 var _json = new core.Map(); | |
21030 if (kind != null) { | |
21031 _json["kind"] = kind; | |
21032 } | |
21033 if (operatingSystems != null) { | |
21034 _json["operatingSystems"] = operatingSystems.map((value) => (value).toJson
()).toList(); | |
21035 } | |
21036 return _json; | |
21037 } | |
21038 } | |
21039 | |
21040 /** Creative optimization activity. */ | |
21041 class OptimizationActivity { | |
21042 /** | |
21043 * Floodlight activity ID of this optimization activity. This is a required | |
21044 * field. | |
21045 */ | |
21046 core.String floodlightActivityId; | |
21047 /** | |
21048 * Dimension value for the ID of the floodlight activity. This is a read-only, | |
21049 * auto-generated field. | |
21050 */ | |
21051 DimensionValue floodlightActivityIdDimensionValue; | |
21052 /** | |
21053 * Weight associated with this optimization. Must be greater than 1. The | |
21054 * weight assigned will be understood in proportion to the weights assigned to | |
21055 * the other optimization activities. | |
21056 */ | |
21057 core.int weight; | |
21058 | |
21059 OptimizationActivity(); | |
21060 | |
21061 OptimizationActivity.fromJson(core.Map _json) { | |
21062 if (_json.containsKey("floodlightActivityId")) { | |
21063 floodlightActivityId = _json["floodlightActivityId"]; | |
21064 } | |
21065 if (_json.containsKey("floodlightActivityIdDimensionValue")) { | |
21066 floodlightActivityIdDimensionValue = new DimensionValue.fromJson(_json["fl
oodlightActivityIdDimensionValue"]); | |
21067 } | |
21068 if (_json.containsKey("weight")) { | |
21069 weight = _json["weight"]; | |
21070 } | |
21071 } | |
21072 | |
21073 core.Map toJson() { | |
21074 var _json = new core.Map(); | |
21075 if (floodlightActivityId != null) { | |
21076 _json["floodlightActivityId"] = floodlightActivityId; | |
21077 } | |
21078 if (floodlightActivityIdDimensionValue != null) { | |
21079 _json["floodlightActivityIdDimensionValue"] = (floodlightActivityIdDimensi
onValue).toJson(); | |
21080 } | |
21081 if (weight != null) { | |
21082 _json["weight"] = weight; | |
21083 } | |
21084 return _json; | |
21085 } | |
21086 } | |
21087 | |
21088 /** Describes properties of a DoubleClick Planning order. */ | |
21089 class Order { | |
21090 /** Account ID of this order. */ | |
21091 core.String accountId; | |
21092 /** Advertiser ID of this order. */ | |
21093 core.String advertiserId; | |
21094 /** IDs for users that have to approve documents created for this order. */ | |
21095 core.List<core.String> approverUserProfileIds; | |
21096 /** Buyer invoice ID associated with this order. */ | |
21097 core.String buyerInvoiceId; | |
21098 /** Name of the buyer organization. */ | |
21099 core.String buyerOrganizationName; | |
21100 /** Comments in this order. */ | |
21101 core.String comments; | |
21102 /** Contacts for this order. */ | |
21103 core.List<OrderContact> contacts; | |
21104 /** ID of this order. This is a read-only, auto-generated field. */ | |
21105 core.String id; | |
21106 /** | |
21107 * Identifies what kind of resource this is. Value: the fixed string | |
21108 * "dfareporting#order". | |
21109 */ | |
21110 core.String kind; | |
21111 /** Information about the most recent modification of this order. */ | |
21112 LastModifiedInfo lastModifiedInfo; | |
21113 /** Name of this order. */ | |
21114 core.String name; | |
21115 /** Notes of this order. */ | |
21116 core.String notes; | |
21117 /** ID of the terms and conditions template used in this order. */ | |
21118 core.String planningTermId; | |
21119 /** Project ID of this order. */ | |
21120 core.String projectId; | |
21121 /** Seller order ID associated with this order. */ | |
21122 core.String sellerOrderId; | |
21123 /** Name of the seller organization. */ | |
21124 core.String sellerOrganizationName; | |
21125 /** Site IDs this order is associated with. */ | |
21126 core.List<core.String> siteId; | |
21127 /** Free-form site names this order is associated with. */ | |
21128 core.List<core.String> siteNames; | |
21129 /** Subaccount ID of this order. */ | |
21130 core.String subaccountId; | |
21131 /** Terms and conditions of this order. */ | |
21132 core.String termsAndConditions; | |
21133 | |
21134 Order(); | |
21135 | |
21136 Order.fromJson(core.Map _json) { | |
21137 if (_json.containsKey("accountId")) { | |
21138 accountId = _json["accountId"]; | |
21139 } | |
21140 if (_json.containsKey("advertiserId")) { | |
21141 advertiserId = _json["advertiserId"]; | |
21142 } | |
21143 if (_json.containsKey("approverUserProfileIds")) { | |
21144 approverUserProfileIds = _json["approverUserProfileIds"]; | |
21145 } | |
21146 if (_json.containsKey("buyerInvoiceId")) { | |
21147 buyerInvoiceId = _json["buyerInvoiceId"]; | |
21148 } | |
21149 if (_json.containsKey("buyerOrganizationName")) { | |
21150 buyerOrganizationName = _json["buyerOrganizationName"]; | |
21151 } | |
21152 if (_json.containsKey("comments")) { | |
21153 comments = _json["comments"]; | |
21154 } | |
21155 if (_json.containsKey("contacts")) { | |
21156 contacts = _json["contacts"].map((value) => new OrderContact.fromJson(valu
e)).toList(); | |
21157 } | |
21158 if (_json.containsKey("id")) { | |
21159 id = _json["id"]; | |
21160 } | |
21161 if (_json.containsKey("kind")) { | |
21162 kind = _json["kind"]; | |
21163 } | |
21164 if (_json.containsKey("lastModifiedInfo")) { | |
21165 lastModifiedInfo = new LastModifiedInfo.fromJson(_json["lastModifiedInfo"]
); | |
21166 } | |
21167 if (_json.containsKey("name")) { | |
21168 name = _json["name"]; | |
21169 } | |
21170 if (_json.containsKey("notes")) { | |
21171 notes = _json["notes"]; | |
21172 } | |
21173 if (_json.containsKey("planningTermId")) { | |
21174 planningTermId = _json["planningTermId"]; | |
21175 } | |
21176 if (_json.containsKey("projectId")) { | |
21177 projectId = _json["projectId"]; | |
21178 } | |
21179 if (_json.containsKey("sellerOrderId")) { | |
21180 sellerOrderId = _json["sellerOrderId"]; | |
21181 } | |
21182 if (_json.containsKey("sellerOrganizationName")) { | |
21183 sellerOrganizationName = _json["sellerOrganizationName"]; | |
21184 } | |
21185 if (_json.containsKey("siteId")) { | |
21186 siteId = _json["siteId"]; | |
21187 } | |
21188 if (_json.containsKey("siteNames")) { | |
21189 siteNames = _json["siteNames"]; | |
21190 } | |
21191 if (_json.containsKey("subaccountId")) { | |
21192 subaccountId = _json["subaccountId"]; | |
21193 } | |
21194 if (_json.containsKey("termsAndConditions")) { | |
21195 termsAndConditions = _json["termsAndConditions"]; | |
21196 } | |
21197 } | |
21198 | |
21199 core.Map toJson() { | |
21200 var _json = new core.Map(); | |
21201 if (accountId != null) { | |
21202 _json["accountId"] = accountId; | |
21203 } | |
21204 if (advertiserId != null) { | |
21205 _json["advertiserId"] = advertiserId; | |
21206 } | |
21207 if (approverUserProfileIds != null) { | |
21208 _json["approverUserProfileIds"] = approverUserProfileIds; | |
21209 } | |
21210 if (buyerInvoiceId != null) { | |
21211 _json["buyerInvoiceId"] = buyerInvoiceId; | |
21212 } | |
21213 if (buyerOrganizationName != null) { | |
21214 _json["buyerOrganizationName"] = buyerOrganizationName; | |
21215 } | |
21216 if (comments != null) { | |
21217 _json["comments"] = comments; | |
21218 } | |
21219 if (contacts != null) { | |
21220 _json["contacts"] = contacts.map((value) => (value).toJson()).toList(); | |
21221 } | |
21222 if (id != null) { | |
21223 _json["id"] = id; | |
21224 } | |
21225 if (kind != null) { | |
21226 _json["kind"] = kind; | |
21227 } | |
21228 if (lastModifiedInfo != null) { | |
21229 _json["lastModifiedInfo"] = (lastModifiedInfo).toJson(); | |
21230 } | |
21231 if (name != null) { | |
21232 _json["name"] = name; | |
21233 } | |
21234 if (notes != null) { | |
21235 _json["notes"] = notes; | |
21236 } | |
21237 if (planningTermId != null) { | |
21238 _json["planningTermId"] = planningTermId; | |
21239 } | |
21240 if (projectId != null) { | |
21241 _json["projectId"] = projectId; | |
21242 } | |
21243 if (sellerOrderId != null) { | |
21244 _json["sellerOrderId"] = sellerOrderId; | |
21245 } | |
21246 if (sellerOrganizationName != null) { | |
21247 _json["sellerOrganizationName"] = sellerOrganizationName; | |
21248 } | |
21249 if (siteId != null) { | |
21250 _json["siteId"] = siteId; | |
21251 } | |
21252 if (siteNames != null) { | |
21253 _json["siteNames"] = siteNames; | |
21254 } | |
21255 if (subaccountId != null) { | |
21256 _json["subaccountId"] = subaccountId; | |
21257 } | |
21258 if (termsAndConditions != null) { | |
21259 _json["termsAndConditions"] = termsAndConditions; | |
21260 } | |
21261 return _json; | |
21262 } | |
21263 } | |
21264 | |
21265 /** Contact of an order. */ | |
21266 class OrderContact { | |
21267 /** | |
21268 * Free-form information about this contact. It could be any information | |
21269 * related to this contact in addition to type, title, name, and signature | |
21270 * user profile ID. | |
21271 */ | |
21272 core.String contactInfo; | |
21273 /** Name of this contact. */ | |
21274 core.String contactName; | |
21275 /** Title of this contact. */ | |
21276 core.String contactTitle; | |
21277 /** | |
21278 * Type of this contact. | |
21279 * Possible string values are: | |
21280 * - "PLANNING_ORDER_CONTACT_BUYER_BILLING_CONTACT" | |
21281 * - "PLANNING_ORDER_CONTACT_BUYER_CONTACT" | |
21282 * - "PLANNING_ORDER_CONTACT_SELLER_CONTACT" | |
21283 */ | |
21284 core.String contactType; | |
21285 /** | |
21286 * ID of the user profile containing the signature that will be embedded into | |
21287 * order documents. | |
21288 */ | |
21289 core.String signatureUserProfileId; | |
21290 | |
21291 OrderContact(); | |
21292 | |
21293 OrderContact.fromJson(core.Map _json) { | |
21294 if (_json.containsKey("contactInfo")) { | |
21295 contactInfo = _json["contactInfo"]; | |
21296 } | |
21297 if (_json.containsKey("contactName")) { | |
21298 contactName = _json["contactName"]; | |
21299 } | |
21300 if (_json.containsKey("contactTitle")) { | |
21301 contactTitle = _json["contactTitle"]; | |
21302 } | |
21303 if (_json.containsKey("contactType")) { | |
21304 contactType = _json["contactType"]; | |
21305 } | |
21306 if (_json.containsKey("signatureUserProfileId")) { | |
21307 signatureUserProfileId = _json["signatureUserProfileId"]; | |
21308 } | |
21309 } | |
21310 | |
21311 core.Map toJson() { | |
21312 var _json = new core.Map(); | |
21313 if (contactInfo != null) { | |
21314 _json["contactInfo"] = contactInfo; | |
21315 } | |
21316 if (contactName != null) { | |
21317 _json["contactName"] = contactName; | |
21318 } | |
21319 if (contactTitle != null) { | |
21320 _json["contactTitle"] = contactTitle; | |
21321 } | |
21322 if (contactType != null) { | |
21323 _json["contactType"] = contactType; | |
21324 } | |
21325 if (signatureUserProfileId != null) { | |
21326 _json["signatureUserProfileId"] = signatureUserProfileId; | |
21327 } | |
21328 return _json; | |
21329 } | |
21330 } | |
21331 | |
21332 /** Contains properties of a DoubleClick Planning order document. */ | |
21333 class OrderDocument { | |
21334 /** Account ID of this order document. */ | |
21335 core.String accountId; | |
21336 /** Advertiser ID of this order document. */ | |
21337 core.String advertiserId; | |
21338 /** | |
21339 * The amended order document ID of this order document. An order document can | |
21340 * be created by optionally amending another order document so that the change | |
21341 * history can be preserved. | |
21342 */ | |
21343 core.String amendedOrderDocumentId; | |
21344 /** IDs of users who have approved this order document. */ | |
21345 core.List<core.String> approvedByUserProfileIds; | |
21346 /** Whether this order document is cancelled. */ | |
21347 core.bool cancelled; | |
21348 /** Information about the creation of this order document. */ | |
21349 LastModifiedInfo createdInfo; | |
21350 /** Effective date of this order document. */ | |
21351 core.DateTime effectiveDate; | |
21352 /** ID of this order document. */ | |
21353 core.String id; | |
21354 /** | |
21355 * Identifies what kind of resource this is. Value: the fixed string | |
21356 * "dfareporting#orderDocument". | |
21357 */ | |
21358 core.String kind; | |
21359 /** List of email addresses that received the last sent document. */ | |
21360 core.List<core.String> lastSentRecipients; | |
21361 /** Timestamp of the last email sent with this order document. */ | |
21362 core.DateTime lastSentTime; | |
21363 /** ID of the order from which this order document is created. */ | |
21364 core.String orderId; | |
21365 /** Project ID of this order document. */ | |
21366 core.String projectId; | |
21367 /** Whether this order document has been signed. */ | |
21368 core.bool signed; | |
21369 /** Subaccount ID of this order document. */ | |
21370 core.String subaccountId; | |
21371 /** Title of this order document. */ | |
21372 core.String title; | |
21373 /** | |
21374 * Type of this order document | |
21375 * Possible string values are: | |
21376 * - "PLANNING_ORDER_TYPE_CHANGE_ORDER" | |
21377 * - "PLANNING_ORDER_TYPE_INSERTION_ORDER" | |
21378 */ | |
21379 core.String type; | |
21380 | |
21381 OrderDocument(); | |
21382 | |
21383 OrderDocument.fromJson(core.Map _json) { | |
21384 if (_json.containsKey("accountId")) { | |
21385 accountId = _json["accountId"]; | |
21386 } | |
21387 if (_json.containsKey("advertiserId")) { | |
21388 advertiserId = _json["advertiserId"]; | |
21389 } | |
21390 if (_json.containsKey("amendedOrderDocumentId")) { | |
21391 amendedOrderDocumentId = _json["amendedOrderDocumentId"]; | |
21392 } | |
21393 if (_json.containsKey("approvedByUserProfileIds")) { | |
21394 approvedByUserProfileIds = _json["approvedByUserProfileIds"]; | |
21395 } | |
21396 if (_json.containsKey("cancelled")) { | |
21397 cancelled = _json["cancelled"]; | |
21398 } | |
21399 if (_json.containsKey("createdInfo")) { | |
21400 createdInfo = new LastModifiedInfo.fromJson(_json["createdInfo"]); | |
21401 } | |
21402 if (_json.containsKey("effectiveDate")) { | |
21403 effectiveDate = core.DateTime.parse(_json["effectiveDate"]); | |
21404 } | |
21405 if (_json.containsKey("id")) { | |
21406 id = _json["id"]; | |
21407 } | |
21408 if (_json.containsKey("kind")) { | |
21409 kind = _json["kind"]; | |
21410 } | |
21411 if (_json.containsKey("lastSentRecipients")) { | |
21412 lastSentRecipients = _json["lastSentRecipients"]; | |
21413 } | |
21414 if (_json.containsKey("lastSentTime")) { | |
21415 lastSentTime = core.DateTime.parse(_json["lastSentTime"]); | |
21416 } | |
21417 if (_json.containsKey("orderId")) { | |
21418 orderId = _json["orderId"]; | |
21419 } | |
21420 if (_json.containsKey("projectId")) { | |
21421 projectId = _json["projectId"]; | |
21422 } | |
21423 if (_json.containsKey("signed")) { | |
21424 signed = _json["signed"]; | |
21425 } | |
21426 if (_json.containsKey("subaccountId")) { | |
21427 subaccountId = _json["subaccountId"]; | |
21428 } | |
21429 if (_json.containsKey("title")) { | |
21430 title = _json["title"]; | |
21431 } | |
21432 if (_json.containsKey("type")) { | |
21433 type = _json["type"]; | |
21434 } | |
21435 } | |
21436 | |
21437 core.Map toJson() { | |
21438 var _json = new core.Map(); | |
21439 if (accountId != null) { | |
21440 _json["accountId"] = accountId; | |
21441 } | |
21442 if (advertiserId != null) { | |
21443 _json["advertiserId"] = advertiserId; | |
21444 } | |
21445 if (amendedOrderDocumentId != null) { | |
21446 _json["amendedOrderDocumentId"] = amendedOrderDocumentId; | |
21447 } | |
21448 if (approvedByUserProfileIds != null) { | |
21449 _json["approvedByUserProfileIds"] = approvedByUserProfileIds; | |
21450 } | |
21451 if (cancelled != null) { | |
21452 _json["cancelled"] = cancelled; | |
21453 } | |
21454 if (createdInfo != null) { | |
21455 _json["createdInfo"] = (createdInfo).toJson(); | |
21456 } | |
21457 if (effectiveDate != null) { | |
21458 _json["effectiveDate"] = "${(effectiveDate).year.toString().padLeft(4, '0'
)}-${(effectiveDate).month.toString().padLeft(2, '0')}-${(effectiveDate).day.toS
tring().padLeft(2, '0')}"; | |
21459 } | |
21460 if (id != null) { | |
21461 _json["id"] = id; | |
21462 } | |
21463 if (kind != null) { | |
21464 _json["kind"] = kind; | |
21465 } | |
21466 if (lastSentRecipients != null) { | |
21467 _json["lastSentRecipients"] = lastSentRecipients; | |
21468 } | |
21469 if (lastSentTime != null) { | |
21470 _json["lastSentTime"] = (lastSentTime).toIso8601String(); | |
21471 } | |
21472 if (orderId != null) { | |
21473 _json["orderId"] = orderId; | |
21474 } | |
21475 if (projectId != null) { | |
21476 _json["projectId"] = projectId; | |
21477 } | |
21478 if (signed != null) { | |
21479 _json["signed"] = signed; | |
21480 } | |
21481 if (subaccountId != null) { | |
21482 _json["subaccountId"] = subaccountId; | |
21483 } | |
21484 if (title != null) { | |
21485 _json["title"] = title; | |
21486 } | |
21487 if (type != null) { | |
21488 _json["type"] = type; | |
21489 } | |
21490 return _json; | |
21491 } | |
21492 } | |
21493 | |
21494 /** Order document List Response */ | |
21495 class OrderDocumentsListResponse { | |
21496 /** | |
21497 * Identifies what kind of resource this is. Value: the fixed string | |
21498 * "dfareporting#orderDocumentsListResponse". | |
21499 */ | |
21500 core.String kind; | |
21501 /** Pagination token to be used for the next list operation. */ | |
21502 core.String nextPageToken; | |
21503 /** Order document collection */ | |
21504 core.List<OrderDocument> orderDocuments; | |
21505 | |
21506 OrderDocumentsListResponse(); | |
21507 | |
21508 OrderDocumentsListResponse.fromJson(core.Map _json) { | |
21509 if (_json.containsKey("kind")) { | |
21510 kind = _json["kind"]; | |
21511 } | |
21512 if (_json.containsKey("nextPageToken")) { | |
21513 nextPageToken = _json["nextPageToken"]; | |
21514 } | |
21515 if (_json.containsKey("orderDocuments")) { | |
21516 orderDocuments = _json["orderDocuments"].map((value) => new OrderDocument.
fromJson(value)).toList(); | |
21517 } | |
21518 } | |
21519 | |
21520 core.Map toJson() { | |
21521 var _json = new core.Map(); | |
21522 if (kind != null) { | |
21523 _json["kind"] = kind; | |
21524 } | |
21525 if (nextPageToken != null) { | |
21526 _json["nextPageToken"] = nextPageToken; | |
21527 } | |
21528 if (orderDocuments != null) { | |
21529 _json["orderDocuments"] = orderDocuments.map((value) => (value).toJson()).
toList(); | |
21530 } | |
21531 return _json; | |
21532 } | |
21533 } | |
21534 | |
21535 /** Order List Response */ | |
21536 class OrdersListResponse { | |
21537 /** | |
21538 * Identifies what kind of resource this is. Value: the fixed string | |
21539 * "dfareporting#ordersListResponse". | |
21540 */ | |
21541 core.String kind; | |
21542 /** Pagination token to be used for the next list operation. */ | |
21543 core.String nextPageToken; | |
21544 /** Order collection. */ | |
21545 core.List<Order> orders; | |
21546 | |
21547 OrdersListResponse(); | |
21548 | |
21549 OrdersListResponse.fromJson(core.Map _json) { | |
21550 if (_json.containsKey("kind")) { | |
21551 kind = _json["kind"]; | |
21552 } | |
21553 if (_json.containsKey("nextPageToken")) { | |
21554 nextPageToken = _json["nextPageToken"]; | |
21555 } | |
21556 if (_json.containsKey("orders")) { | |
21557 orders = _json["orders"].map((value) => new Order.fromJson(value)).toList(
); | |
21558 } | |
21559 } | |
21560 | |
21561 core.Map toJson() { | |
21562 var _json = new core.Map(); | |
21563 if (kind != null) { | |
21564 _json["kind"] = kind; | |
21565 } | |
21566 if (nextPageToken != null) { | |
21567 _json["nextPageToken"] = nextPageToken; | |
21568 } | |
21569 if (orders != null) { | |
21570 _json["orders"] = orders.map((value) => (value).toJson()).toList(); | |
21571 } | |
21572 return _json; | |
21573 } | |
21574 } | |
21575 | |
21576 /** | |
21577 * Represents fields that are compatible to be selected for a report of type | |
21578 * "PATH_TO_CONVERSION". | |
21579 */ | |
21580 class PathToConversionReportCompatibleFields { | |
21581 /** | |
21582 * Conversion dimensions which are compatible to be selected in the | |
21583 * "conversionDimensions" section of the report. | |
21584 */ | |
21585 core.List<Dimension> conversionDimensions; | |
21586 /** | |
21587 * Custom floodlight variables which are compatible to be selected in the | |
21588 * "customFloodlightVariables" section of the report. | |
21589 */ | |
21590 core.List<Dimension> customFloodlightVariables; | |
21591 /** | |
21592 * The kind of resource this is, in this case | |
21593 * dfareporting#pathToConversionReportCompatibleFields. | |
21594 */ | |
21595 core.String kind; | |
21596 /** | |
21597 * Metrics which are compatible to be selected in the "metricNames" section of | |
21598 * the report. | |
21599 */ | |
21600 core.List<Metric> metrics; | |
21601 /** | |
21602 * Per-interaction dimensions which are compatible to be selected in the | |
21603 * "perInteractionDimensions" section of the report. | |
21604 */ | |
21605 core.List<Dimension> perInteractionDimensions; | |
21606 | |
21607 PathToConversionReportCompatibleFields(); | |
21608 | |
21609 PathToConversionReportCompatibleFields.fromJson(core.Map _json) { | |
21610 if (_json.containsKey("conversionDimensions")) { | |
21611 conversionDimensions = _json["conversionDimensions"].map((value) => new Di
mension.fromJson(value)).toList(); | |
21612 } | |
21613 if (_json.containsKey("customFloodlightVariables")) { | |
21614 customFloodlightVariables = _json["customFloodlightVariables"].map((value)
=> new Dimension.fromJson(value)).toList(); | |
21615 } | |
21616 if (_json.containsKey("kind")) { | |
21617 kind = _json["kind"]; | |
21618 } | |
21619 if (_json.containsKey("metrics")) { | |
21620 metrics = _json["metrics"].map((value) => new Metric.fromJson(value)).toLi
st(); | |
21621 } | |
21622 if (_json.containsKey("perInteractionDimensions")) { | |
21623 perInteractionDimensions = _json["perInteractionDimensions"].map((value) =
> new Dimension.fromJson(value)).toList(); | |
21624 } | |
21625 } | |
21626 | |
21627 core.Map toJson() { | |
21628 var _json = new core.Map(); | |
21629 if (conversionDimensions != null) { | |
21630 _json["conversionDimensions"] = conversionDimensions.map((value) => (value
).toJson()).toList(); | |
21631 } | |
21632 if (customFloodlightVariables != null) { | |
21633 _json["customFloodlightVariables"] = customFloodlightVariables.map((value)
=> (value).toJson()).toList(); | |
21634 } | |
21635 if (kind != null) { | |
21636 _json["kind"] = kind; | |
21637 } | |
21638 if (metrics != null) { | |
21639 _json["metrics"] = metrics.map((value) => (value).toJson()).toList(); | |
21640 } | |
21641 if (perInteractionDimensions != null) { | |
21642 _json["perInteractionDimensions"] = perInteractionDimensions.map((value) =
> (value).toJson()).toList(); | |
21643 } | |
21644 return _json; | |
21645 } | |
21646 } | |
21647 | |
21648 /** Contains properties of a placement. */ | |
21649 class Placement { | |
21650 /** Account ID of this placement. This field can be left blank. */ | |
21651 core.String accountId; | |
21652 /** Advertiser ID of this placement. This field can be left blank. */ | |
21653 core.String advertiserId; | |
21654 /** | |
21655 * Dimension value for the ID of the advertiser. This is a read-only, | |
21656 * auto-generated field. | |
21657 */ | |
21658 DimensionValue advertiserIdDimensionValue; | |
21659 /** Whether this placement is archived. */ | |
21660 core.bool archived; | |
21661 /** | |
21662 * Campaign ID of this placement. This field is a required field on insertion. | |
21663 */ | |
21664 core.String campaignId; | |
21665 /** | |
21666 * Dimension value for the ID of the campaign. This is a read-only, | |
21667 * auto-generated field. | |
21668 */ | |
21669 DimensionValue campaignIdDimensionValue; | |
21670 /** Comments for this placement. */ | |
21671 core.String comment; | |
21672 /** | |
21673 * Placement compatibility. WEB and WEB_INTERSTITIAL refer to rendering either | |
21674 * on desktop or on mobile devices for regular or interstitial ads, | |
21675 * respectively. APP and APP_INTERSTITIAL are for rendering in mobile apps. | |
21676 * IN_STREAM_VIDEO refers to rendering in in-stream video ads developed with | |
21677 * the VAST standard. This field is required on insertion. | |
21678 * Possible string values are: | |
21679 * - "APP" | |
21680 * - "APP_INTERSTITIAL" | |
21681 * - "IN_STREAM_VIDEO" | |
21682 * - "WEB" | |
21683 * - "WEB_INTERSTITIAL" | |
21684 */ | |
21685 core.String compatibility; | |
21686 /** ID of the content category assigned to this placement. */ | |
21687 core.String contentCategoryId; | |
21688 /** | |
21689 * Information about the creation of this placement. This is a read-only | |
21690 * field. | |
21691 */ | |
21692 LastModifiedInfo createInfo; | |
21693 /** | |
21694 * Directory site ID of this placement. On insert, you must set either this | |
21695 * field or the siteId field to specify the site associated with this | |
21696 * placement. This is a required field that is read-only after insertion. | |
21697 */ | |
21698 core.String directorySiteId; | |
21699 /** | |
21700 * Dimension value for the ID of the directory site. This is a read-only, | |
21701 * auto-generated field. | |
21702 */ | |
21703 DimensionValue directorySiteIdDimensionValue; | |
21704 /** External ID for this placement. */ | |
21705 core.String externalId; | |
21706 /** ID of this placement. This is a read-only, auto-generated field. */ | |
21707 core.String id; | |
21708 /** | |
21709 * Dimension value for the ID of this placement. This is a read-only, | |
21710 * auto-generated field. | |
21711 */ | |
21712 DimensionValue idDimensionValue; | |
21713 /** Key name of this placement. This is a read-only, auto-generated field. */ | |
21714 core.String keyName; | |
21715 /** | |
21716 * Identifies what kind of resource this is. Value: the fixed string | |
21717 * "dfareporting#placement". | |
21718 */ | |
21719 core.String kind; | |
21720 /** | |
21721 * Information about the most recent modification of this placement. This is a | |
21722 * read-only field. | |
21723 */ | |
21724 LastModifiedInfo lastModifiedInfo; | |
21725 /** Lookback window settings for this placement. */ | |
21726 LookbackConfiguration lookbackConfiguration; | |
21727 /** | |
21728 * Name of this placement.This is a required field and must be less than 256 | |
21729 * characters long. | |
21730 */ | |
21731 core.String name; | |
21732 /** | |
21733 * Whether payment was approved for this placement. This is a read-only field | |
21734 * relevant only to publisher-paid placements. | |
21735 */ | |
21736 core.bool paymentApproved; | |
21737 /** | |
21738 * Payment source for this placement. This is a required field that is | |
21739 * read-only after insertion. | |
21740 * Possible string values are: | |
21741 * - "PLACEMENT_AGENCY_PAID" | |
21742 * - "PLACEMENT_PUBLISHER_PAID" | |
21743 */ | |
21744 core.String paymentSource; | |
21745 /** ID of this placement's group, if applicable. */ | |
21746 core.String placementGroupId; | |
21747 /** | |
21748 * Dimension value for the ID of the placement group. This is a read-only, | |
21749 * auto-generated field. | |
21750 */ | |
21751 DimensionValue placementGroupIdDimensionValue; | |
21752 /** ID of the placement strategy assigned to this placement. */ | |
21753 core.String placementStrategyId; | |
21754 /** | |
21755 * Pricing schedule of this placement. This field is required on insertion, | |
21756 * specifically subfields startDate, endDate and pricingType. | |
21757 */ | |
21758 PricingSchedule pricingSchedule; | |
21759 /** | |
21760 * Whether this placement is the primary placement of a roadblock (placement | |
21761 * group). You cannot change this field from true to false. Setting this field | |
21762 * to true will automatically set the primary field on the original primary | |
21763 * placement of the roadblock to false, and it will automatically set the | |
21764 * roadblock's primaryPlacementId field to the ID of this placement. | |
21765 */ | |
21766 core.bool primary; | |
21767 /** | |
21768 * Information about the last publisher update. This is a read-only field. | |
21769 */ | |
21770 LastModifiedInfo publisherUpdateInfo; | |
21771 /** | |
21772 * Site ID associated with this placement. On insert, you must set either this | |
21773 * field or the directorySiteId field to specify the site associated with this | |
21774 * placement. This is a required field that is read-only after insertion. | |
21775 */ | |
21776 core.String siteId; | |
21777 /** | |
21778 * Dimension value for the ID of the site. This is a read-only, auto-generated | |
21779 * field. | |
21780 */ | |
21781 DimensionValue siteIdDimensionValue; | |
21782 /** | |
21783 * Size associated with this placement. When inserting or updating a | |
21784 * placement, only the size ID field is used. This field is required on | |
21785 * insertion. | |
21786 */ | |
21787 Size size; | |
21788 /** Whether creatives assigned to this placement must be SSL-compliant. */ | |
21789 core.bool sslRequired; | |
21790 /** | |
21791 * Third-party placement status. | |
21792 * Possible string values are: | |
21793 * - "ACKNOWLEDGE_ACCEPTANCE" | |
21794 * - "ACKNOWLEDGE_REJECTION" | |
21795 * - "DRAFT" | |
21796 * - "PAYMENT_ACCEPTED" | |
21797 * - "PAYMENT_REJECTED" | |
21798 * - "PENDING_REVIEW" | |
21799 */ | |
21800 core.String status; | |
21801 /** Subaccount ID of this placement. This field can be left blank. */ | |
21802 core.String subaccountId; | |
21803 /** | |
21804 * Tag formats to generate for this placement. This field is required on | |
21805 * insertion. | |
21806 * Acceptable values are: | |
21807 * - "PLACEMENT_TAG_STANDARD" | |
21808 * - "PLACEMENT_TAG_IFRAME_JAVASCRIPT" | |
21809 * - "PLACEMENT_TAG_IFRAME_ILAYER" | |
21810 * - "PLACEMENT_TAG_INTERNAL_REDIRECT" | |
21811 * - "PLACEMENT_TAG_JAVASCRIPT" | |
21812 * - "PLACEMENT_TAG_INTERSTITIAL_IFRAME_JAVASCRIPT" | |
21813 * - "PLACEMENT_TAG_INTERSTITIAL_INTERNAL_REDIRECT" | |
21814 * - "PLACEMENT_TAG_INTERSTITIAL_JAVASCRIPT" | |
21815 * - "PLACEMENT_TAG_CLICK_COMMANDS" | |
21816 * - "PLACEMENT_TAG_INSTREAM_VIDEO_PREFETCH" | |
21817 * - "PLACEMENT_TAG_TRACKING" | |
21818 * - "PLACEMENT_TAG_TRACKING_IFRAME" | |
21819 * - "PLACEMENT_TAG_TRACKING_JAVASCRIPT" | |
21820 */ | |
21821 core.List<core.String> tagFormats; | |
21822 /** Tag settings for this placement. */ | |
21823 TagSetting tagSetting; | |
21824 | |
21825 Placement(); | |
21826 | |
21827 Placement.fromJson(core.Map _json) { | |
21828 if (_json.containsKey("accountId")) { | |
21829 accountId = _json["accountId"]; | |
21830 } | |
21831 if (_json.containsKey("advertiserId")) { | |
21832 advertiserId = _json["advertiserId"]; | |
21833 } | |
21834 if (_json.containsKey("advertiserIdDimensionValue")) { | |
21835 advertiserIdDimensionValue = new DimensionValue.fromJson(_json["advertiser
IdDimensionValue"]); | |
21836 } | |
21837 if (_json.containsKey("archived")) { | |
21838 archived = _json["archived"]; | |
21839 } | |
21840 if (_json.containsKey("campaignId")) { | |
21841 campaignId = _json["campaignId"]; | |
21842 } | |
21843 if (_json.containsKey("campaignIdDimensionValue")) { | |
21844 campaignIdDimensionValue = new DimensionValue.fromJson(_json["campaignIdDi
mensionValue"]); | |
21845 } | |
21846 if (_json.containsKey("comment")) { | |
21847 comment = _json["comment"]; | |
21848 } | |
21849 if (_json.containsKey("compatibility")) { | |
21850 compatibility = _json["compatibility"]; | |
21851 } | |
21852 if (_json.containsKey("contentCategoryId")) { | |
21853 contentCategoryId = _json["contentCategoryId"]; | |
21854 } | |
21855 if (_json.containsKey("createInfo")) { | |
21856 createInfo = new LastModifiedInfo.fromJson(_json["createInfo"]); | |
21857 } | |
21858 if (_json.containsKey("directorySiteId")) { | |
21859 directorySiteId = _json["directorySiteId"]; | |
21860 } | |
21861 if (_json.containsKey("directorySiteIdDimensionValue")) { | |
21862 directorySiteIdDimensionValue = new DimensionValue.fromJson(_json["directo
rySiteIdDimensionValue"]); | |
21863 } | |
21864 if (_json.containsKey("externalId")) { | |
21865 externalId = _json["externalId"]; | |
21866 } | |
21867 if (_json.containsKey("id")) { | |
21868 id = _json["id"]; | |
21869 } | |
21870 if (_json.containsKey("idDimensionValue")) { | |
21871 idDimensionValue = new DimensionValue.fromJson(_json["idDimensionValue"]); | |
21872 } | |
21873 if (_json.containsKey("keyName")) { | |
21874 keyName = _json["keyName"]; | |
21875 } | |
21876 if (_json.containsKey("kind")) { | |
21877 kind = _json["kind"]; | |
21878 } | |
21879 if (_json.containsKey("lastModifiedInfo")) { | |
21880 lastModifiedInfo = new LastModifiedInfo.fromJson(_json["lastModifiedInfo"]
); | |
21881 } | |
21882 if (_json.containsKey("lookbackConfiguration")) { | |
21883 lookbackConfiguration = new LookbackConfiguration.fromJson(_json["lookback
Configuration"]); | |
21884 } | |
21885 if (_json.containsKey("name")) { | |
21886 name = _json["name"]; | |
21887 } | |
21888 if (_json.containsKey("paymentApproved")) { | |
21889 paymentApproved = _json["paymentApproved"]; | |
21890 } | |
21891 if (_json.containsKey("paymentSource")) { | |
21892 paymentSource = _json["paymentSource"]; | |
21893 } | |
21894 if (_json.containsKey("placementGroupId")) { | |
21895 placementGroupId = _json["placementGroupId"]; | |
21896 } | |
21897 if (_json.containsKey("placementGroupIdDimensionValue")) { | |
21898 placementGroupIdDimensionValue = new DimensionValue.fromJson(_json["placem
entGroupIdDimensionValue"]); | |
21899 } | |
21900 if (_json.containsKey("placementStrategyId")) { | |
21901 placementStrategyId = _json["placementStrategyId"]; | |
21902 } | |
21903 if (_json.containsKey("pricingSchedule")) { | |
21904 pricingSchedule = new PricingSchedule.fromJson(_json["pricingSchedule"]); | |
21905 } | |
21906 if (_json.containsKey("primary")) { | |
21907 primary = _json["primary"]; | |
21908 } | |
21909 if (_json.containsKey("publisherUpdateInfo")) { | |
21910 publisherUpdateInfo = new LastModifiedInfo.fromJson(_json["publisherUpdate
Info"]); | |
21911 } | |
21912 if (_json.containsKey("siteId")) { | |
21913 siteId = _json["siteId"]; | |
21914 } | |
21915 if (_json.containsKey("siteIdDimensionValue")) { | |
21916 siteIdDimensionValue = new DimensionValue.fromJson(_json["siteIdDimensionV
alue"]); | |
21917 } | |
21918 if (_json.containsKey("size")) { | |
21919 size = new Size.fromJson(_json["size"]); | |
21920 } | |
21921 if (_json.containsKey("sslRequired")) { | |
21922 sslRequired = _json["sslRequired"]; | |
21923 } | |
21924 if (_json.containsKey("status")) { | |
21925 status = _json["status"]; | |
21926 } | |
21927 if (_json.containsKey("subaccountId")) { | |
21928 subaccountId = _json["subaccountId"]; | |
21929 } | |
21930 if (_json.containsKey("tagFormats")) { | |
21931 tagFormats = _json["tagFormats"]; | |
21932 } | |
21933 if (_json.containsKey("tagSetting")) { | |
21934 tagSetting = new TagSetting.fromJson(_json["tagSetting"]); | |
21935 } | |
21936 } | |
21937 | |
21938 core.Map toJson() { | |
21939 var _json = new core.Map(); | |
21940 if (accountId != null) { | |
21941 _json["accountId"] = accountId; | |
21942 } | |
21943 if (advertiserId != null) { | |
21944 _json["advertiserId"] = advertiserId; | |
21945 } | |
21946 if (advertiserIdDimensionValue != null) { | |
21947 _json["advertiserIdDimensionValue"] = (advertiserIdDimensionValue).toJson(
); | |
21948 } | |
21949 if (archived != null) { | |
21950 _json["archived"] = archived; | |
21951 } | |
21952 if (campaignId != null) { | |
21953 _json["campaignId"] = campaignId; | |
21954 } | |
21955 if (campaignIdDimensionValue != null) { | |
21956 _json["campaignIdDimensionValue"] = (campaignIdDimensionValue).toJson(); | |
21957 } | |
21958 if (comment != null) { | |
21959 _json["comment"] = comment; | |
21960 } | |
21961 if (compatibility != null) { | |
21962 _json["compatibility"] = compatibility; | |
21963 } | |
21964 if (contentCategoryId != null) { | |
21965 _json["contentCategoryId"] = contentCategoryId; | |
21966 } | |
21967 if (createInfo != null) { | |
21968 _json["createInfo"] = (createInfo).toJson(); | |
21969 } | |
21970 if (directorySiteId != null) { | |
21971 _json["directorySiteId"] = directorySiteId; | |
21972 } | |
21973 if (directorySiteIdDimensionValue != null) { | |
21974 _json["directorySiteIdDimensionValue"] = (directorySiteIdDimensionValue).t
oJson(); | |
21975 } | |
21976 if (externalId != null) { | |
21977 _json["externalId"] = externalId; | |
21978 } | |
21979 if (id != null) { | |
21980 _json["id"] = id; | |
21981 } | |
21982 if (idDimensionValue != null) { | |
21983 _json["idDimensionValue"] = (idDimensionValue).toJson(); | |
21984 } | |
21985 if (keyName != null) { | |
21986 _json["keyName"] = keyName; | |
21987 } | |
21988 if (kind != null) { | |
21989 _json["kind"] = kind; | |
21990 } | |
21991 if (lastModifiedInfo != null) { | |
21992 _json["lastModifiedInfo"] = (lastModifiedInfo).toJson(); | |
21993 } | |
21994 if (lookbackConfiguration != null) { | |
21995 _json["lookbackConfiguration"] = (lookbackConfiguration).toJson(); | |
21996 } | |
21997 if (name != null) { | |
21998 _json["name"] = name; | |
21999 } | |
22000 if (paymentApproved != null) { | |
22001 _json["paymentApproved"] = paymentApproved; | |
22002 } | |
22003 if (paymentSource != null) { | |
22004 _json["paymentSource"] = paymentSource; | |
22005 } | |
22006 if (placementGroupId != null) { | |
22007 _json["placementGroupId"] = placementGroupId; | |
22008 } | |
22009 if (placementGroupIdDimensionValue != null) { | |
22010 _json["placementGroupIdDimensionValue"] = (placementGroupIdDimensionValue)
.toJson(); | |
22011 } | |
22012 if (placementStrategyId != null) { | |
22013 _json["placementStrategyId"] = placementStrategyId; | |
22014 } | |
22015 if (pricingSchedule != null) { | |
22016 _json["pricingSchedule"] = (pricingSchedule).toJson(); | |
22017 } | |
22018 if (primary != null) { | |
22019 _json["primary"] = primary; | |
22020 } | |
22021 if (publisherUpdateInfo != null) { | |
22022 _json["publisherUpdateInfo"] = (publisherUpdateInfo).toJson(); | |
22023 } | |
22024 if (siteId != null) { | |
22025 _json["siteId"] = siteId; | |
22026 } | |
22027 if (siteIdDimensionValue != null) { | |
22028 _json["siteIdDimensionValue"] = (siteIdDimensionValue).toJson(); | |
22029 } | |
22030 if (size != null) { | |
22031 _json["size"] = (size).toJson(); | |
22032 } | |
22033 if (sslRequired != null) { | |
22034 _json["sslRequired"] = sslRequired; | |
22035 } | |
22036 if (status != null) { | |
22037 _json["status"] = status; | |
22038 } | |
22039 if (subaccountId != null) { | |
22040 _json["subaccountId"] = subaccountId; | |
22041 } | |
22042 if (tagFormats != null) { | |
22043 _json["tagFormats"] = tagFormats; | |
22044 } | |
22045 if (tagSetting != null) { | |
22046 _json["tagSetting"] = (tagSetting).toJson(); | |
22047 } | |
22048 return _json; | |
22049 } | |
22050 } | |
22051 | |
22052 /** Placement Assignment. */ | |
22053 class PlacementAssignment { | |
22054 /** | |
22055 * Whether this placement assignment is active. When true, the placement will | |
22056 * be included in the ad's rotation. | |
22057 */ | |
22058 core.bool active; | |
22059 /** ID of the placement to be assigned. This is a required field. */ | |
22060 core.String placementId; | |
22061 /** | |
22062 * Dimension value for the ID of the placement. This is a read-only, | |
22063 * auto-generated field. | |
22064 */ | |
22065 DimensionValue placementIdDimensionValue; | |
22066 /** | |
22067 * Whether the placement to be assigned requires SSL. This is a read-only | |
22068 * field that is auto-generated when the ad is inserted or updated. | |
22069 */ | |
22070 core.bool sslRequired; | |
22071 | |
22072 PlacementAssignment(); | |
22073 | |
22074 PlacementAssignment.fromJson(core.Map _json) { | |
22075 if (_json.containsKey("active")) { | |
22076 active = _json["active"]; | |
22077 } | |
22078 if (_json.containsKey("placementId")) { | |
22079 placementId = _json["placementId"]; | |
22080 } | |
22081 if (_json.containsKey("placementIdDimensionValue")) { | |
22082 placementIdDimensionValue = new DimensionValue.fromJson(_json["placementId
DimensionValue"]); | |
22083 } | |
22084 if (_json.containsKey("sslRequired")) { | |
22085 sslRequired = _json["sslRequired"]; | |
22086 } | |
22087 } | |
22088 | |
22089 core.Map toJson() { | |
22090 var _json = new core.Map(); | |
22091 if (active != null) { | |
22092 _json["active"] = active; | |
22093 } | |
22094 if (placementId != null) { | |
22095 _json["placementId"] = placementId; | |
22096 } | |
22097 if (placementIdDimensionValue != null) { | |
22098 _json["placementIdDimensionValue"] = (placementIdDimensionValue).toJson(); | |
22099 } | |
22100 if (sslRequired != null) { | |
22101 _json["sslRequired"] = sslRequired; | |
22102 } | |
22103 return _json; | |
22104 } | |
22105 } | |
22106 | |
22107 /** Contains properties of a package or roadblock. */ | |
22108 class PlacementGroup { | |
22109 /** | |
22110 * Account ID of this placement group. This is a read-only field that can be | |
22111 * left blank. | |
22112 */ | |
22113 core.String accountId; | |
22114 /** | |
22115 * Advertiser ID of this placement group. This is a required field on | |
22116 * insertion. | |
22117 */ | |
22118 core.String advertiserId; | |
22119 /** | |
22120 * Dimension value for the ID of the advertiser. This is a read-only, | |
22121 * auto-generated field. | |
22122 */ | |
22123 DimensionValue advertiserIdDimensionValue; | |
22124 /** Whether this placement group is archived. */ | |
22125 core.bool archived; | |
22126 /** | |
22127 * Campaign ID of this placement group. This field is required on insertion. | |
22128 */ | |
22129 core.String campaignId; | |
22130 /** | |
22131 * Dimension value for the ID of the campaign. This is a read-only, | |
22132 * auto-generated field. | |
22133 */ | |
22134 DimensionValue campaignIdDimensionValue; | |
22135 /** | |
22136 * IDs of placements which are assigned to this placement group. This is a | |
22137 * read-only, auto-generated field. | |
22138 */ | |
22139 core.List<core.String> childPlacementIds; | |
22140 /** Comments for this placement group. */ | |
22141 core.String comment; | |
22142 /** ID of the content category assigned to this placement group. */ | |
22143 core.String contentCategoryId; | |
22144 /** | |
22145 * Information about the creation of this placement group. This is a read-only | |
22146 * field. | |
22147 */ | |
22148 LastModifiedInfo createInfo; | |
22149 /** | |
22150 * Directory site ID associated with this placement group. On insert, you must | |
22151 * set either this field or the site_id field to specify the site associated | |
22152 * with this placement group. This is a required field that is read-only after | |
22153 * insertion. | |
22154 */ | |
22155 core.String directorySiteId; | |
22156 /** | |
22157 * Dimension value for the ID of the directory site. This is a read-only, | |
22158 * auto-generated field. | |
22159 */ | |
22160 DimensionValue directorySiteIdDimensionValue; | |
22161 /** External ID for this placement. */ | |
22162 core.String externalId; | |
22163 /** ID of this placement group. This is a read-only, auto-generated field. */ | |
22164 core.String id; | |
22165 /** | |
22166 * Dimension value for the ID of this placement group. This is a read-only, | |
22167 * auto-generated field. | |
22168 */ | |
22169 DimensionValue idDimensionValue; | |
22170 /** | |
22171 * Identifies what kind of resource this is. Value: the fixed string | |
22172 * "dfareporting#placementGroup". | |
22173 */ | |
22174 core.String kind; | |
22175 /** | |
22176 * Information about the most recent modification of this placement group. | |
22177 * This is a read-only field. | |
22178 */ | |
22179 LastModifiedInfo lastModifiedInfo; | |
22180 /** | |
22181 * Name of this placement group. This is a required field and must be less | |
22182 * than 256 characters long. | |
22183 */ | |
22184 core.String name; | |
22185 /** | |
22186 * Type of this placement group. A package is a simple group of placements | |
22187 * that acts as a single pricing point for a group of tags. A roadblock is a | |
22188 * group of placements that not only acts as a single pricing point, but also | |
22189 * assumes that all the tags in it will be served at the same time. A | |
22190 * roadblock requires one of its assigned placements to be marked as primary | |
22191 * for reporting. This field is required on insertion. | |
22192 * Possible string values are: | |
22193 * - "PLACEMENT_PACKAGE" | |
22194 * - "PLACEMENT_ROADBLOCK" | |
22195 */ | |
22196 core.String placementGroupType; | |
22197 /** ID of the placement strategy assigned to this placement group. */ | |
22198 core.String placementStrategyId; | |
22199 /** | |
22200 * Pricing schedule of this placement group. This field is required on | |
22201 * insertion. | |
22202 */ | |
22203 PricingSchedule pricingSchedule; | |
22204 /** | |
22205 * ID of the primary placement, used to calculate the media cost of a | |
22206 * roadblock (placement group). Modifying this field will automatically modify | |
22207 * the primary field on all affected roadblock child placements. | |
22208 */ | |
22209 core.String primaryPlacementId; | |
22210 /** | |
22211 * Dimension value for the ID of the primary placement. This is a read-only, | |
22212 * auto-generated field. | |
22213 */ | |
22214 DimensionValue primaryPlacementIdDimensionValue; | |
22215 /** | |
22216 * Site ID associated with this placement group. On insert, you must set | |
22217 * either this field or the directorySiteId field to specify the site | |
22218 * associated with this placement group. This is a required field that is | |
22219 * read-only after insertion. | |
22220 */ | |
22221 core.String siteId; | |
22222 /** | |
22223 * Dimension value for the ID of the site. This is a read-only, auto-generated | |
22224 * field. | |
22225 */ | |
22226 DimensionValue siteIdDimensionValue; | |
22227 /** | |
22228 * Subaccount ID of this placement group. This is a read-only field that can | |
22229 * be left blank. | |
22230 */ | |
22231 core.String subaccountId; | |
22232 | |
22233 PlacementGroup(); | |
22234 | |
22235 PlacementGroup.fromJson(core.Map _json) { | |
22236 if (_json.containsKey("accountId")) { | |
22237 accountId = _json["accountId"]; | |
22238 } | |
22239 if (_json.containsKey("advertiserId")) { | |
22240 advertiserId = _json["advertiserId"]; | |
22241 } | |
22242 if (_json.containsKey("advertiserIdDimensionValue")) { | |
22243 advertiserIdDimensionValue = new DimensionValue.fromJson(_json["advertiser
IdDimensionValue"]); | |
22244 } | |
22245 if (_json.containsKey("archived")) { | |
22246 archived = _json["archived"]; | |
22247 } | |
22248 if (_json.containsKey("campaignId")) { | |
22249 campaignId = _json["campaignId"]; | |
22250 } | |
22251 if (_json.containsKey("campaignIdDimensionValue")) { | |
22252 campaignIdDimensionValue = new DimensionValue.fromJson(_json["campaignIdDi
mensionValue"]); | |
22253 } | |
22254 if (_json.containsKey("childPlacementIds")) { | |
22255 childPlacementIds = _json["childPlacementIds"]; | |
22256 } | |
22257 if (_json.containsKey("comment")) { | |
22258 comment = _json["comment"]; | |
22259 } | |
22260 if (_json.containsKey("contentCategoryId")) { | |
22261 contentCategoryId = _json["contentCategoryId"]; | |
22262 } | |
22263 if (_json.containsKey("createInfo")) { | |
22264 createInfo = new LastModifiedInfo.fromJson(_json["createInfo"]); | |
22265 } | |
22266 if (_json.containsKey("directorySiteId")) { | |
22267 directorySiteId = _json["directorySiteId"]; | |
22268 } | |
22269 if (_json.containsKey("directorySiteIdDimensionValue")) { | |
22270 directorySiteIdDimensionValue = new DimensionValue.fromJson(_json["directo
rySiteIdDimensionValue"]); | |
22271 } | |
22272 if (_json.containsKey("externalId")) { | |
22273 externalId = _json["externalId"]; | |
22274 } | |
22275 if (_json.containsKey("id")) { | |
22276 id = _json["id"]; | |
22277 } | |
22278 if (_json.containsKey("idDimensionValue")) { | |
22279 idDimensionValue = new DimensionValue.fromJson(_json["idDimensionValue"]); | |
22280 } | |
22281 if (_json.containsKey("kind")) { | |
22282 kind = _json["kind"]; | |
22283 } | |
22284 if (_json.containsKey("lastModifiedInfo")) { | |
22285 lastModifiedInfo = new LastModifiedInfo.fromJson(_json["lastModifiedInfo"]
); | |
22286 } | |
22287 if (_json.containsKey("name")) { | |
22288 name = _json["name"]; | |
22289 } | |
22290 if (_json.containsKey("placementGroupType")) { | |
22291 placementGroupType = _json["placementGroupType"]; | |
22292 } | |
22293 if (_json.containsKey("placementStrategyId")) { | |
22294 placementStrategyId = _json["placementStrategyId"]; | |
22295 } | |
22296 if (_json.containsKey("pricingSchedule")) { | |
22297 pricingSchedule = new PricingSchedule.fromJson(_json["pricingSchedule"]); | |
22298 } | |
22299 if (_json.containsKey("primaryPlacementId")) { | |
22300 primaryPlacementId = _json["primaryPlacementId"]; | |
22301 } | |
22302 if (_json.containsKey("primaryPlacementIdDimensionValue")) { | |
22303 primaryPlacementIdDimensionValue = new DimensionValue.fromJson(_json["prim
aryPlacementIdDimensionValue"]); | |
22304 } | |
22305 if (_json.containsKey("siteId")) { | |
22306 siteId = _json["siteId"]; | |
22307 } | |
22308 if (_json.containsKey("siteIdDimensionValue")) { | |
22309 siteIdDimensionValue = new DimensionValue.fromJson(_json["siteIdDimensionV
alue"]); | |
22310 } | |
22311 if (_json.containsKey("subaccountId")) { | |
22312 subaccountId = _json["subaccountId"]; | |
22313 } | |
22314 } | |
22315 | |
22316 core.Map toJson() { | |
22317 var _json = new core.Map(); | |
22318 if (accountId != null) { | |
22319 _json["accountId"] = accountId; | |
22320 } | |
22321 if (advertiserId != null) { | |
22322 _json["advertiserId"] = advertiserId; | |
22323 } | |
22324 if (advertiserIdDimensionValue != null) { | |
22325 _json["advertiserIdDimensionValue"] = (advertiserIdDimensionValue).toJson(
); | |
22326 } | |
22327 if (archived != null) { | |
22328 _json["archived"] = archived; | |
22329 } | |
22330 if (campaignId != null) { | |
22331 _json["campaignId"] = campaignId; | |
22332 } | |
22333 if (campaignIdDimensionValue != null) { | |
22334 _json["campaignIdDimensionValue"] = (campaignIdDimensionValue).toJson(); | |
22335 } | |
22336 if (childPlacementIds != null) { | |
22337 _json["childPlacementIds"] = childPlacementIds; | |
22338 } | |
22339 if (comment != null) { | |
22340 _json["comment"] = comment; | |
22341 } | |
22342 if (contentCategoryId != null) { | |
22343 _json["contentCategoryId"] = contentCategoryId; | |
22344 } | |
22345 if (createInfo != null) { | |
22346 _json["createInfo"] = (createInfo).toJson(); | |
22347 } | |
22348 if (directorySiteId != null) { | |
22349 _json["directorySiteId"] = directorySiteId; | |
22350 } | |
22351 if (directorySiteIdDimensionValue != null) { | |
22352 _json["directorySiteIdDimensionValue"] = (directorySiteIdDimensionValue).t
oJson(); | |
22353 } | |
22354 if (externalId != null) { | |
22355 _json["externalId"] = externalId; | |
22356 } | |
22357 if (id != null) { | |
22358 _json["id"] = id; | |
22359 } | |
22360 if (idDimensionValue != null) { | |
22361 _json["idDimensionValue"] = (idDimensionValue).toJson(); | |
22362 } | |
22363 if (kind != null) { | |
22364 _json["kind"] = kind; | |
22365 } | |
22366 if (lastModifiedInfo != null) { | |
22367 _json["lastModifiedInfo"] = (lastModifiedInfo).toJson(); | |
22368 } | |
22369 if (name != null) { | |
22370 _json["name"] = name; | |
22371 } | |
22372 if (placementGroupType != null) { | |
22373 _json["placementGroupType"] = placementGroupType; | |
22374 } | |
22375 if (placementStrategyId != null) { | |
22376 _json["placementStrategyId"] = placementStrategyId; | |
22377 } | |
22378 if (pricingSchedule != null) { | |
22379 _json["pricingSchedule"] = (pricingSchedule).toJson(); | |
22380 } | |
22381 if (primaryPlacementId != null) { | |
22382 _json["primaryPlacementId"] = primaryPlacementId; | |
22383 } | |
22384 if (primaryPlacementIdDimensionValue != null) { | |
22385 _json["primaryPlacementIdDimensionValue"] = (primaryPlacementIdDimensionVa
lue).toJson(); | |
22386 } | |
22387 if (siteId != null) { | |
22388 _json["siteId"] = siteId; | |
22389 } | |
22390 if (siteIdDimensionValue != null) { | |
22391 _json["siteIdDimensionValue"] = (siteIdDimensionValue).toJson(); | |
22392 } | |
22393 if (subaccountId != null) { | |
22394 _json["subaccountId"] = subaccountId; | |
22395 } | |
22396 return _json; | |
22397 } | |
22398 } | |
22399 | |
22400 /** Placement Group List Response */ | |
22401 class PlacementGroupsListResponse { | |
22402 /** | |
22403 * Identifies what kind of resource this is. Value: the fixed string | |
22404 * "dfareporting#placementGroupsListResponse". | |
22405 */ | |
22406 core.String kind; | |
22407 /** Pagination token to be used for the next list operation. */ | |
22408 core.String nextPageToken; | |
22409 /** Placement group collection. */ | |
22410 core.List<PlacementGroup> placementGroups; | |
22411 | |
22412 PlacementGroupsListResponse(); | |
22413 | |
22414 PlacementGroupsListResponse.fromJson(core.Map _json) { | |
22415 if (_json.containsKey("kind")) { | |
22416 kind = _json["kind"]; | |
22417 } | |
22418 if (_json.containsKey("nextPageToken")) { | |
22419 nextPageToken = _json["nextPageToken"]; | |
22420 } | |
22421 if (_json.containsKey("placementGroups")) { | |
22422 placementGroups = _json["placementGroups"].map((value) => new PlacementGro
up.fromJson(value)).toList(); | |
22423 } | |
22424 } | |
22425 | |
22426 core.Map toJson() { | |
22427 var _json = new core.Map(); | |
22428 if (kind != null) { | |
22429 _json["kind"] = kind; | |
22430 } | |
22431 if (nextPageToken != null) { | |
22432 _json["nextPageToken"] = nextPageToken; | |
22433 } | |
22434 if (placementGroups != null) { | |
22435 _json["placementGroups"] = placementGroups.map((value) => (value).toJson()
).toList(); | |
22436 } | |
22437 return _json; | |
22438 } | |
22439 } | |
22440 | |
22441 /** Placement Strategy List Response */ | |
22442 class PlacementStrategiesListResponse { | |
22443 /** | |
22444 * Identifies what kind of resource this is. Value: the fixed string | |
22445 * "dfareporting#placementStrategiesListResponse". | |
22446 */ | |
22447 core.String kind; | |
22448 /** Pagination token to be used for the next list operation. */ | |
22449 core.String nextPageToken; | |
22450 /** Placement strategy collection. */ | |
22451 core.List<PlacementStrategy> placementStrategies; | |
22452 | |
22453 PlacementStrategiesListResponse(); | |
22454 | |
22455 PlacementStrategiesListResponse.fromJson(core.Map _json) { | |
22456 if (_json.containsKey("kind")) { | |
22457 kind = _json["kind"]; | |
22458 } | |
22459 if (_json.containsKey("nextPageToken")) { | |
22460 nextPageToken = _json["nextPageToken"]; | |
22461 } | |
22462 if (_json.containsKey("placementStrategies")) { | |
22463 placementStrategies = _json["placementStrategies"].map((value) => new Plac
ementStrategy.fromJson(value)).toList(); | |
22464 } | |
22465 } | |
22466 | |
22467 core.Map toJson() { | |
22468 var _json = new core.Map(); | |
22469 if (kind != null) { | |
22470 _json["kind"] = kind; | |
22471 } | |
22472 if (nextPageToken != null) { | |
22473 _json["nextPageToken"] = nextPageToken; | |
22474 } | |
22475 if (placementStrategies != null) { | |
22476 _json["placementStrategies"] = placementStrategies.map((value) => (value).
toJson()).toList(); | |
22477 } | |
22478 return _json; | |
22479 } | |
22480 } | |
22481 | |
22482 /** Contains properties of a placement strategy. */ | |
22483 class PlacementStrategy { | |
22484 /** | |
22485 * Account ID of this placement strategy.This is a read-only field that can be | |
22486 * left blank. | |
22487 */ | |
22488 core.String accountId; | |
22489 /** | |
22490 * ID of this placement strategy. This is a read-only, auto-generated field. | |
22491 */ | |
22492 core.String id; | |
22493 /** | |
22494 * Identifies what kind of resource this is. Value: the fixed string | |
22495 * "dfareporting#placementStrategy". | |
22496 */ | |
22497 core.String kind; | |
22498 /** | |
22499 * Name of this placement strategy. This is a required field. It must be less | |
22500 * than 256 characters long and unique among placement strategies of the same | |
22501 * account. | |
22502 */ | |
22503 core.String name; | |
22504 | |
22505 PlacementStrategy(); | |
22506 | |
22507 PlacementStrategy.fromJson(core.Map _json) { | |
22508 if (_json.containsKey("accountId")) { | |
22509 accountId = _json["accountId"]; | |
22510 } | |
22511 if (_json.containsKey("id")) { | |
22512 id = _json["id"]; | |
22513 } | |
22514 if (_json.containsKey("kind")) { | |
22515 kind = _json["kind"]; | |
22516 } | |
22517 if (_json.containsKey("name")) { | |
22518 name = _json["name"]; | |
22519 } | |
22520 } | |
22521 | |
22522 core.Map toJson() { | |
22523 var _json = new core.Map(); | |
22524 if (accountId != null) { | |
22525 _json["accountId"] = accountId; | |
22526 } | |
22527 if (id != null) { | |
22528 _json["id"] = id; | |
22529 } | |
22530 if (kind != null) { | |
22531 _json["kind"] = kind; | |
22532 } | |
22533 if (name != null) { | |
22534 _json["name"] = name; | |
22535 } | |
22536 return _json; | |
22537 } | |
22538 } | |
22539 | |
22540 /** Placement Tag */ | |
22541 class PlacementTag { | |
22542 /** Placement ID */ | |
22543 core.String placementId; | |
22544 /** Tags generated for this placement. */ | |
22545 core.List<TagData> tagDatas; | |
22546 | |
22547 PlacementTag(); | |
22548 | |
22549 PlacementTag.fromJson(core.Map _json) { | |
22550 if (_json.containsKey("placementId")) { | |
22551 placementId = _json["placementId"]; | |
22552 } | |
22553 if (_json.containsKey("tagDatas")) { | |
22554 tagDatas = _json["tagDatas"].map((value) => new TagData.fromJson(value)).t
oList(); | |
22555 } | |
22556 } | |
22557 | |
22558 core.Map toJson() { | |
22559 var _json = new core.Map(); | |
22560 if (placementId != null) { | |
22561 _json["placementId"] = placementId; | |
22562 } | |
22563 if (tagDatas != null) { | |
22564 _json["tagDatas"] = tagDatas.map((value) => (value).toJson()).toList(); | |
22565 } | |
22566 return _json; | |
22567 } | |
22568 } | |
22569 | |
22570 /** Placement GenerateTags Response */ | |
22571 class PlacementsGenerateTagsResponse { | |
22572 /** | |
22573 * Identifies what kind of resource this is. Value: the fixed string | |
22574 * "dfareporting#placementsGenerateTagsResponse". | |
22575 */ | |
22576 core.String kind; | |
22577 /** Set of generated tags for the specified placements. */ | |
22578 core.List<PlacementTag> placementTags; | |
22579 | |
22580 PlacementsGenerateTagsResponse(); | |
22581 | |
22582 PlacementsGenerateTagsResponse.fromJson(core.Map _json) { | |
22583 if (_json.containsKey("kind")) { | |
22584 kind = _json["kind"]; | |
22585 } | |
22586 if (_json.containsKey("placementTags")) { | |
22587 placementTags = _json["placementTags"].map((value) => new PlacementTag.fro
mJson(value)).toList(); | |
22588 } | |
22589 } | |
22590 | |
22591 core.Map toJson() { | |
22592 var _json = new core.Map(); | |
22593 if (kind != null) { | |
22594 _json["kind"] = kind; | |
22595 } | |
22596 if (placementTags != null) { | |
22597 _json["placementTags"] = placementTags.map((value) => (value).toJson()).to
List(); | |
22598 } | |
22599 return _json; | |
22600 } | |
22601 } | |
22602 | |
22603 /** Placement List Response */ | |
22604 class PlacementsListResponse { | |
22605 /** | |
22606 * Identifies what kind of resource this is. Value: the fixed string | |
22607 * "dfareporting#placementsListResponse". | |
22608 */ | |
22609 core.String kind; | |
22610 /** Pagination token to be used for the next list operation. */ | |
22611 core.String nextPageToken; | |
22612 /** Placement collection. */ | |
22613 core.List<Placement> placements; | |
22614 | |
22615 PlacementsListResponse(); | |
22616 | |
22617 PlacementsListResponse.fromJson(core.Map _json) { | |
22618 if (_json.containsKey("kind")) { | |
22619 kind = _json["kind"]; | |
22620 } | |
22621 if (_json.containsKey("nextPageToken")) { | |
22622 nextPageToken = _json["nextPageToken"]; | |
22623 } | |
22624 if (_json.containsKey("placements")) { | |
22625 placements = _json["placements"].map((value) => new Placement.fromJson(val
ue)).toList(); | |
22626 } | |
22627 } | |
22628 | |
22629 core.Map toJson() { | |
22630 var _json = new core.Map(); | |
22631 if (kind != null) { | |
22632 _json["kind"] = kind; | |
22633 } | |
22634 if (nextPageToken != null) { | |
22635 _json["nextPageToken"] = nextPageToken; | |
22636 } | |
22637 if (placements != null) { | |
22638 _json["placements"] = placements.map((value) => (value).toJson()).toList()
; | |
22639 } | |
22640 return _json; | |
22641 } | |
22642 } | |
22643 | |
22644 /** Contains information about a platform type that can be targeted by ads. */ | |
22645 class PlatformType { | |
22646 /** ID of this platform type. */ | |
22647 core.String id; | |
22648 /** | |
22649 * Identifies what kind of resource this is. Value: the fixed string | |
22650 * "dfareporting#platformType". | |
22651 */ | |
22652 core.String kind; | |
22653 /** Name of this platform type. */ | |
22654 core.String name; | |
22655 | |
22656 PlatformType(); | |
22657 | |
22658 PlatformType.fromJson(core.Map _json) { | |
22659 if (_json.containsKey("id")) { | |
22660 id = _json["id"]; | |
22661 } | |
22662 if (_json.containsKey("kind")) { | |
22663 kind = _json["kind"]; | |
22664 } | |
22665 if (_json.containsKey("name")) { | |
22666 name = _json["name"]; | |
22667 } | |
22668 } | |
22669 | |
22670 core.Map toJson() { | |
22671 var _json = new core.Map(); | |
22672 if (id != null) { | |
22673 _json["id"] = id; | |
22674 } | |
22675 if (kind != null) { | |
22676 _json["kind"] = kind; | |
22677 } | |
22678 if (name != null) { | |
22679 _json["name"] = name; | |
22680 } | |
22681 return _json; | |
22682 } | |
22683 } | |
22684 | |
22685 /** Platform Type List Response */ | |
22686 class PlatformTypesListResponse { | |
22687 /** | |
22688 * Identifies what kind of resource this is. Value: the fixed string | |
22689 * "dfareporting#platformTypesListResponse". | |
22690 */ | |
22691 core.String kind; | |
22692 /** Platform type collection. */ | |
22693 core.List<PlatformType> platformTypes; | |
22694 | |
22695 PlatformTypesListResponse(); | |
22696 | |
22697 PlatformTypesListResponse.fromJson(core.Map _json) { | |
22698 if (_json.containsKey("kind")) { | |
22699 kind = _json["kind"]; | |
22700 } | |
22701 if (_json.containsKey("platformTypes")) { | |
22702 platformTypes = _json["platformTypes"].map((value) => new PlatformType.fro
mJson(value)).toList(); | |
22703 } | |
22704 } | |
22705 | |
22706 core.Map toJson() { | |
22707 var _json = new core.Map(); | |
22708 if (kind != null) { | |
22709 _json["kind"] = kind; | |
22710 } | |
22711 if (platformTypes != null) { | |
22712 _json["platformTypes"] = platformTypes.map((value) => (value).toJson()).to
List(); | |
22713 } | |
22714 return _json; | |
22715 } | |
22716 } | |
22717 | |
22718 /** Popup Window Properties. */ | |
22719 class PopupWindowProperties { | |
22720 /** | |
22721 * Popup dimension for a creative. This is a read-only field. Applicable to | |
22722 * the following creative types: all RICH_MEDIA and all VPAID | |
22723 */ | |
22724 Size dimension; | |
22725 /** | |
22726 * Upper-left corner coordinates of the popup window. Applicable if | |
22727 * positionType is COORDINATES. | |
22728 */ | |
22729 OffsetPosition offset; | |
22730 /** | |
22731 * Popup window position either centered or at specific coordinate. | |
22732 * Possible string values are: | |
22733 * - "CENTER" | |
22734 * - "COORDINATES" | |
22735 */ | |
22736 core.String positionType; | |
22737 /** Whether to display the browser address bar. */ | |
22738 core.bool showAddressBar; | |
22739 /** Whether to display the browser menu bar. */ | |
22740 core.bool showMenuBar; | |
22741 /** Whether to display the browser scroll bar. */ | |
22742 core.bool showScrollBar; | |
22743 /** Whether to display the browser status bar. */ | |
22744 core.bool showStatusBar; | |
22745 /** Whether to display the browser tool bar. */ | |
22746 core.bool showToolBar; | |
22747 /** Title of popup window. */ | |
22748 core.String title; | |
22749 | |
22750 PopupWindowProperties(); | |
22751 | |
22752 PopupWindowProperties.fromJson(core.Map _json) { | |
22753 if (_json.containsKey("dimension")) { | |
22754 dimension = new Size.fromJson(_json["dimension"]); | |
22755 } | |
22756 if (_json.containsKey("offset")) { | |
22757 offset = new OffsetPosition.fromJson(_json["offset"]); | |
22758 } | |
22759 if (_json.containsKey("positionType")) { | |
22760 positionType = _json["positionType"]; | |
22761 } | |
22762 if (_json.containsKey("showAddressBar")) { | |
22763 showAddressBar = _json["showAddressBar"]; | |
22764 } | |
22765 if (_json.containsKey("showMenuBar")) { | |
22766 showMenuBar = _json["showMenuBar"]; | |
22767 } | |
22768 if (_json.containsKey("showScrollBar")) { | |
22769 showScrollBar = _json["showScrollBar"]; | |
22770 } | |
22771 if (_json.containsKey("showStatusBar")) { | |
22772 showStatusBar = _json["showStatusBar"]; | |
22773 } | |
22774 if (_json.containsKey("showToolBar")) { | |
22775 showToolBar = _json["showToolBar"]; | |
22776 } | |
22777 if (_json.containsKey("title")) { | |
22778 title = _json["title"]; | |
22779 } | |
22780 } | |
22781 | |
22782 core.Map toJson() { | |
22783 var _json = new core.Map(); | |
22784 if (dimension != null) { | |
22785 _json["dimension"] = (dimension).toJson(); | |
22786 } | |
22787 if (offset != null) { | |
22788 _json["offset"] = (offset).toJson(); | |
22789 } | |
22790 if (positionType != null) { | |
22791 _json["positionType"] = positionType; | |
22792 } | |
22793 if (showAddressBar != null) { | |
22794 _json["showAddressBar"] = showAddressBar; | |
22795 } | |
22796 if (showMenuBar != null) { | |
22797 _json["showMenuBar"] = showMenuBar; | |
22798 } | |
22799 if (showScrollBar != null) { | |
22800 _json["showScrollBar"] = showScrollBar; | |
22801 } | |
22802 if (showStatusBar != null) { | |
22803 _json["showStatusBar"] = showStatusBar; | |
22804 } | |
22805 if (showToolBar != null) { | |
22806 _json["showToolBar"] = showToolBar; | |
22807 } | |
22808 if (title != null) { | |
22809 _json["title"] = title; | |
22810 } | |
22811 return _json; | |
22812 } | |
22813 } | |
22814 | |
22815 /** Contains information about a postal code that can be targeted by ads. */ | |
22816 class PostalCode { | |
22817 /** Postal code. This is equivalent to the id field. */ | |
22818 core.String code; | |
22819 /** Country code of the country to which this postal code belongs. */ | |
22820 core.String countryCode; | |
22821 /** DART ID of the country to which this postal code belongs. */ | |
22822 core.String countryDartId; | |
22823 /** ID of this postal code. */ | |
22824 core.String id; | |
22825 /** | |
22826 * Identifies what kind of resource this is. Value: the fixed string | |
22827 * "dfareporting#postalCode". | |
22828 */ | |
22829 core.String kind; | |
22830 | |
22831 PostalCode(); | |
22832 | |
22833 PostalCode.fromJson(core.Map _json) { | |
22834 if (_json.containsKey("code")) { | |
22835 code = _json["code"]; | |
22836 } | |
22837 if (_json.containsKey("countryCode")) { | |
22838 countryCode = _json["countryCode"]; | |
22839 } | |
22840 if (_json.containsKey("countryDartId")) { | |
22841 countryDartId = _json["countryDartId"]; | |
22842 } | |
22843 if (_json.containsKey("id")) { | |
22844 id = _json["id"]; | |
22845 } | |
22846 if (_json.containsKey("kind")) { | |
22847 kind = _json["kind"]; | |
22848 } | |
22849 } | |
22850 | |
22851 core.Map toJson() { | |
22852 var _json = new core.Map(); | |
22853 if (code != null) { | |
22854 _json["code"] = code; | |
22855 } | |
22856 if (countryCode != null) { | |
22857 _json["countryCode"] = countryCode; | |
22858 } | |
22859 if (countryDartId != null) { | |
22860 _json["countryDartId"] = countryDartId; | |
22861 } | |
22862 if (id != null) { | |
22863 _json["id"] = id; | |
22864 } | |
22865 if (kind != null) { | |
22866 _json["kind"] = kind; | |
22867 } | |
22868 return _json; | |
22869 } | |
22870 } | |
22871 | |
22872 /** Postal Code List Response */ | |
22873 class PostalCodesListResponse { | |
22874 /** | |
22875 * Identifies what kind of resource this is. Value: the fixed string | |
22876 * "dfareporting#postalCodesListResponse". | |
22877 */ | |
22878 core.String kind; | |
22879 /** Postal code collection. */ | |
22880 core.List<PostalCode> postalCodes; | |
22881 | |
22882 PostalCodesListResponse(); | |
22883 | |
22884 PostalCodesListResponse.fromJson(core.Map _json) { | |
22885 if (_json.containsKey("kind")) { | |
22886 kind = _json["kind"]; | |
22887 } | |
22888 if (_json.containsKey("postalCodes")) { | |
22889 postalCodes = _json["postalCodes"].map((value) => new PostalCode.fromJson(
value)).toList(); | |
22890 } | |
22891 } | |
22892 | |
22893 core.Map toJson() { | |
22894 var _json = new core.Map(); | |
22895 if (kind != null) { | |
22896 _json["kind"] = kind; | |
22897 } | |
22898 if (postalCodes != null) { | |
22899 _json["postalCodes"] = postalCodes.map((value) => (value).toJson()).toList
(); | |
22900 } | |
22901 return _json; | |
22902 } | |
22903 } | |
22904 | |
22905 /** Pricing Information */ | |
22906 class Pricing { | |
22907 /** | |
22908 * Cap cost type of this inventory item. | |
22909 * Possible string values are: | |
22910 * - "PLANNING_PLACEMENT_CAP_COST_TYPE_CUMULATIVE" | |
22911 * - "PLANNING_PLACEMENT_CAP_COST_TYPE_MONTHLY" | |
22912 * - "PLANNING_PLACEMENT_CAP_COST_TYPE_NONE" | |
22913 */ | |
22914 core.String capCostType; | |
22915 /** End date of this inventory item. */ | |
22916 core.DateTime endDate; | |
22917 /** | |
22918 * Flights of this inventory item. A flight (a.k.a. pricing period) represents | |
22919 * the inventory item pricing information for a specific period of time. | |
22920 */ | |
22921 core.List<Flight> flights; | |
22922 /** | |
22923 * Group type of this inventory item if it represents a placement group. Is | |
22924 * null otherwise. There are two type of placement groups: | |
22925 * PLANNING_PLACEMENT_GROUP_TYPE_PACKAGE is a simple group of inventory items | |
22926 * that acts as a single pricing point for a group of tags. | |
22927 * PLANNING_PLACEMENT_GROUP_TYPE_ROADBLOCK is a group of inventory items that | |
22928 * not only acts as a single pricing point, but also assumes that all the tags | |
22929 * in it will be served at the same time. A roadblock requires one of its | |
22930 * assigned inventory items to be marked as primary. | |
22931 * Possible string values are: | |
22932 * - "PLANNING_PLACEMENT_GROUP_TYPE_PACKAGE" | |
22933 * - "PLANNING_PLACEMENT_GROUP_TYPE_ROADBLOCK" | |
22934 */ | |
22935 core.String groupType; | |
22936 /** | |
22937 * Pricing type of this inventory item. | |
22938 * Possible string values are: | |
22939 * - "PLANNING_PLACEMENT_PRICING_TYPE_CLICKS" | |
22940 * - "PLANNING_PLACEMENT_PRICING_TYPE_CPA" | |
22941 * - "PLANNING_PLACEMENT_PRICING_TYPE_CPC" | |
22942 * - "PLANNING_PLACEMENT_PRICING_TYPE_CPM" | |
22943 * - "PLANNING_PLACEMENT_PRICING_TYPE_CPM_ACTIVEVIEW" | |
22944 * - "PLANNING_PLACEMENT_PRICING_TYPE_FLAT_RATE_CLICKS" | |
22945 * - "PLANNING_PLACEMENT_PRICING_TYPE_FLAT_RATE_IMPRESSIONS" | |
22946 * - "PLANNING_PLACEMENT_PRICING_TYPE_IMPRESSIONS" | |
22947 */ | |
22948 core.String pricingType; | |
22949 /** Start date of this inventory item. */ | |
22950 core.DateTime startDate; | |
22951 | |
22952 Pricing(); | |
22953 | |
22954 Pricing.fromJson(core.Map _json) { | |
22955 if (_json.containsKey("capCostType")) { | |
22956 capCostType = _json["capCostType"]; | |
22957 } | |
22958 if (_json.containsKey("endDate")) { | |
22959 endDate = core.DateTime.parse(_json["endDate"]); | |
22960 } | |
22961 if (_json.containsKey("flights")) { | |
22962 flights = _json["flights"].map((value) => new Flight.fromJson(value)).toLi
st(); | |
22963 } | |
22964 if (_json.containsKey("groupType")) { | |
22965 groupType = _json["groupType"]; | |
22966 } | |
22967 if (_json.containsKey("pricingType")) { | |
22968 pricingType = _json["pricingType"]; | |
22969 } | |
22970 if (_json.containsKey("startDate")) { | |
22971 startDate = core.DateTime.parse(_json["startDate"]); | |
22972 } | |
22973 } | |
22974 | |
22975 core.Map toJson() { | |
22976 var _json = new core.Map(); | |
22977 if (capCostType != null) { | |
22978 _json["capCostType"] = capCostType; | |
22979 } | |
22980 if (endDate != null) { | |
22981 _json["endDate"] = "${(endDate).year.toString().padLeft(4, '0')}-${(endDat
e).month.toString().padLeft(2, '0')}-${(endDate).day.toString().padLeft(2, '0')}
"; | |
22982 } | |
22983 if (flights != null) { | |
22984 _json["flights"] = flights.map((value) => (value).toJson()).toList(); | |
22985 } | |
22986 if (groupType != null) { | |
22987 _json["groupType"] = groupType; | |
22988 } | |
22989 if (pricingType != null) { | |
22990 _json["pricingType"] = pricingType; | |
22991 } | |
22992 if (startDate != null) { | |
22993 _json["startDate"] = "${(startDate).year.toString().padLeft(4, '0')}-${(st
artDate).month.toString().padLeft(2, '0')}-${(startDate).day.toString().padLeft(
2, '0')}"; | |
22994 } | |
22995 return _json; | |
22996 } | |
22997 } | |
22998 | |
22999 /** Pricing Schedule */ | |
23000 class PricingSchedule { | |
23001 /** | |
23002 * Placement cap cost option. | |
23003 * Possible string values are: | |
23004 * - "CAP_COST_CUMULATIVE" | |
23005 * - "CAP_COST_MONTHLY" | |
23006 * - "CAP_COST_NONE" | |
23007 */ | |
23008 core.String capCostOption; | |
23009 /** Whether cap costs are ignored by ad serving. */ | |
23010 core.bool disregardOverdelivery; | |
23011 /** | |
23012 * Placement end date. This date must be later than, or the same day as, the | |
23013 * placement start date, but not later than the campaign end date. If, for | |
23014 * example, you set 6/25/2015 as both the start and end dates, the effective | |
23015 * placement date is just that day only, 6/25/2015. The hours, minutes, and | |
23016 * seconds of the end date should not be set, as doing so will result in an | |
23017 * error. This field is required on insertion. | |
23018 */ | |
23019 core.DateTime endDate; | |
23020 /** | |
23021 * Whether this placement is flighted. If true, pricing periods will be | |
23022 * computed automatically. | |
23023 */ | |
23024 core.bool flighted; | |
23025 /** | |
23026 * Floodlight activity ID associated with this placement. This field should be | |
23027 * set when placement pricing type is set to PRICING_TYPE_CPA. | |
23028 */ | |
23029 core.String floodlightActivityId; | |
23030 /** Pricing periods for this placement. */ | |
23031 core.List<PricingSchedulePricingPeriod> pricingPeriods; | |
23032 /** | |
23033 * Placement pricing type. This field is required on insertion. | |
23034 * Possible string values are: | |
23035 * - "PRICING_TYPE_CPA" | |
23036 * - "PRICING_TYPE_CPC" | |
23037 * - "PRICING_TYPE_CPM" | |
23038 * - "PRICING_TYPE_CPM_ACTIVEVIEW" | |
23039 * - "PRICING_TYPE_FLAT_RATE_CLICKS" | |
23040 * - "PRICING_TYPE_FLAT_RATE_IMPRESSIONS" | |
23041 */ | |
23042 core.String pricingType; | |
23043 /** | |
23044 * Placement start date. This date must be later than, or the same day as, the | |
23045 * campaign start date. The hours, minutes, and seconds of the start date | |
23046 * should not be set, as doing so will result in an error. This field is | |
23047 * required on insertion. | |
23048 */ | |
23049 core.DateTime startDate; | |
23050 /** | |
23051 * Testing start date of this placement. The hours, minutes, and seconds of | |
23052 * the start date should not be set, as doing so will result in an error. | |
23053 */ | |
23054 core.DateTime testingStartDate; | |
23055 | |
23056 PricingSchedule(); | |
23057 | |
23058 PricingSchedule.fromJson(core.Map _json) { | |
23059 if (_json.containsKey("capCostOption")) { | |
23060 capCostOption = _json["capCostOption"]; | |
23061 } | |
23062 if (_json.containsKey("disregardOverdelivery")) { | |
23063 disregardOverdelivery = _json["disregardOverdelivery"]; | |
23064 } | |
23065 if (_json.containsKey("endDate")) { | |
23066 endDate = core.DateTime.parse(_json["endDate"]); | |
23067 } | |
23068 if (_json.containsKey("flighted")) { | |
23069 flighted = _json["flighted"]; | |
23070 } | |
23071 if (_json.containsKey("floodlightActivityId")) { | |
23072 floodlightActivityId = _json["floodlightActivityId"]; | |
23073 } | |
23074 if (_json.containsKey("pricingPeriods")) { | |
23075 pricingPeriods = _json["pricingPeriods"].map((value) => new PricingSchedul
ePricingPeriod.fromJson(value)).toList(); | |
23076 } | |
23077 if (_json.containsKey("pricingType")) { | |
23078 pricingType = _json["pricingType"]; | |
23079 } | |
23080 if (_json.containsKey("startDate")) { | |
23081 startDate = core.DateTime.parse(_json["startDate"]); | |
23082 } | |
23083 if (_json.containsKey("testingStartDate")) { | |
23084 testingStartDate = core.DateTime.parse(_json["testingStartDate"]); | |
23085 } | |
23086 } | |
23087 | |
23088 core.Map toJson() { | |
23089 var _json = new core.Map(); | |
23090 if (capCostOption != null) { | |
23091 _json["capCostOption"] = capCostOption; | |
23092 } | |
23093 if (disregardOverdelivery != null) { | |
23094 _json["disregardOverdelivery"] = disregardOverdelivery; | |
23095 } | |
23096 if (endDate != null) { | |
23097 _json["endDate"] = "${(endDate).year.toString().padLeft(4, '0')}-${(endDat
e).month.toString().padLeft(2, '0')}-${(endDate).day.toString().padLeft(2, '0')}
"; | |
23098 } | |
23099 if (flighted != null) { | |
23100 _json["flighted"] = flighted; | |
23101 } | |
23102 if (floodlightActivityId != null) { | |
23103 _json["floodlightActivityId"] = floodlightActivityId; | |
23104 } | |
23105 if (pricingPeriods != null) { | |
23106 _json["pricingPeriods"] = pricingPeriods.map((value) => (value).toJson()).
toList(); | |
23107 } | |
23108 if (pricingType != null) { | |
23109 _json["pricingType"] = pricingType; | |
23110 } | |
23111 if (startDate != null) { | |
23112 _json["startDate"] = "${(startDate).year.toString().padLeft(4, '0')}-${(st
artDate).month.toString().padLeft(2, '0')}-${(startDate).day.toString().padLeft(
2, '0')}"; | |
23113 } | |
23114 if (testingStartDate != null) { | |
23115 _json["testingStartDate"] = "${(testingStartDate).year.toString().padLeft(
4, '0')}-${(testingStartDate).month.toString().padLeft(2, '0')}-${(testingStartD
ate).day.toString().padLeft(2, '0')}"; | |
23116 } | |
23117 return _json; | |
23118 } | |
23119 } | |
23120 | |
23121 /** Pricing Period */ | |
23122 class PricingSchedulePricingPeriod { | |
23123 /** | |
23124 * Pricing period end date. This date must be later than, or the same day as, | |
23125 * the pricing period start date, but not later than the placement end date. | |
23126 * The period end date can be the same date as the period start date. If, for | |
23127 * example, you set 6/25/2015 as both the start and end dates, the effective | |
23128 * pricing period date is just that day only, 6/25/2015. The hours, minutes, | |
23129 * and seconds of the end date should not be set, as doing so will result in | |
23130 * an error. | |
23131 */ | |
23132 core.DateTime endDate; | |
23133 /** Comments for this pricing period. */ | |
23134 core.String pricingComment; | |
23135 /** Rate or cost of this pricing period. */ | |
23136 core.String rateOrCostNanos; | |
23137 /** | |
23138 * Pricing period start date. This date must be later than, or the same day | |
23139 * as, the placement start date. The hours, minutes, and seconds of the start | |
23140 * date should not be set, as doing so will result in an error. | |
23141 */ | |
23142 core.DateTime startDate; | |
23143 /** Units of this pricing period. */ | |
23144 core.String units; | |
23145 | |
23146 PricingSchedulePricingPeriod(); | |
23147 | |
23148 PricingSchedulePricingPeriod.fromJson(core.Map _json) { | |
23149 if (_json.containsKey("endDate")) { | |
23150 endDate = core.DateTime.parse(_json["endDate"]); | |
23151 } | |
23152 if (_json.containsKey("pricingComment")) { | |
23153 pricingComment = _json["pricingComment"]; | |
23154 } | |
23155 if (_json.containsKey("rateOrCostNanos")) { | |
23156 rateOrCostNanos = _json["rateOrCostNanos"]; | |
23157 } | |
23158 if (_json.containsKey("startDate")) { | |
23159 startDate = core.DateTime.parse(_json["startDate"]); | |
23160 } | |
23161 if (_json.containsKey("units")) { | |
23162 units = _json["units"]; | |
23163 } | |
23164 } | |
23165 | |
23166 core.Map toJson() { | |
23167 var _json = new core.Map(); | |
23168 if (endDate != null) { | |
23169 _json["endDate"] = "${(endDate).year.toString().padLeft(4, '0')}-${(endDat
e).month.toString().padLeft(2, '0')}-${(endDate).day.toString().padLeft(2, '0')}
"; | |
23170 } | |
23171 if (pricingComment != null) { | |
23172 _json["pricingComment"] = pricingComment; | |
23173 } | |
23174 if (rateOrCostNanos != null) { | |
23175 _json["rateOrCostNanos"] = rateOrCostNanos; | |
23176 } | |
23177 if (startDate != null) { | |
23178 _json["startDate"] = "${(startDate).year.toString().padLeft(4, '0')}-${(st
artDate).month.toString().padLeft(2, '0')}-${(startDate).day.toString().padLeft(
2, '0')}"; | |
23179 } | |
23180 if (units != null) { | |
23181 _json["units"] = units; | |
23182 } | |
23183 return _json; | |
23184 } | |
23185 } | |
23186 | |
23187 /** Contains properties of a DoubleClick Planning project. */ | |
23188 class Project { | |
23189 /** Account ID of this project. */ | |
23190 core.String accountId; | |
23191 /** Advertiser ID of this project. */ | |
23192 core.String advertiserId; | |
23193 /** | |
23194 * Audience age group of this project. | |
23195 * Possible string values are: | |
23196 * - "PLANNING_AUDIENCE_AGE_18_24" | |
23197 * - "PLANNING_AUDIENCE_AGE_25_34" | |
23198 * - "PLANNING_AUDIENCE_AGE_35_44" | |
23199 * - "PLANNING_AUDIENCE_AGE_45_54" | |
23200 * - "PLANNING_AUDIENCE_AGE_55_64" | |
23201 * - "PLANNING_AUDIENCE_AGE_65_OR_MORE" | |
23202 * - "PLANNING_AUDIENCE_AGE_UNKNOWN" | |
23203 */ | |
23204 core.String audienceAgeGroup; | |
23205 /** | |
23206 * Audience gender of this project. | |
23207 * Possible string values are: | |
23208 * - "PLANNING_AUDIENCE_GENDER_FEMALE" | |
23209 * - "PLANNING_AUDIENCE_GENDER_MALE" | |
23210 */ | |
23211 core.String audienceGender; | |
23212 /** | |
23213 * Budget of this project in the currency specified by the current account. | |
23214 * The value stored in this field represents only the non-fractional amount. | |
23215 * For example, for USD, the smallest value that can be represented by this | |
23216 * field is 1 US dollar. | |
23217 */ | |
23218 core.String budget; | |
23219 /** Client billing code of this project. */ | |
23220 core.String clientBillingCode; | |
23221 /** Name of the project client. */ | |
23222 core.String clientName; | |
23223 /** End date of the project. */ | |
23224 core.DateTime endDate; | |
23225 /** ID of this project. This is a read-only, auto-generated field. */ | |
23226 core.String id; | |
23227 /** | |
23228 * Identifies what kind of resource this is. Value: the fixed string | |
23229 * "dfareporting#project". | |
23230 */ | |
23231 core.String kind; | |
23232 /** Information about the most recent modification of this project. */ | |
23233 LastModifiedInfo lastModifiedInfo; | |
23234 /** Name of this project. */ | |
23235 core.String name; | |
23236 /** Overview of this project. */ | |
23237 core.String overview; | |
23238 /** Start date of the project. */ | |
23239 core.DateTime startDate; | |
23240 /** Subaccount ID of this project. */ | |
23241 core.String subaccountId; | |
23242 /** Number of clicks that the advertiser is targeting. */ | |
23243 core.String targetClicks; | |
23244 /** Number of conversions that the advertiser is targeting. */ | |
23245 core.String targetConversions; | |
23246 /** CPA that the advertiser is targeting. */ | |
23247 core.String targetCpaNanos; | |
23248 /** CPC that the advertiser is targeting. */ | |
23249 core.String targetCpcNanos; | |
23250 /** CPM that the advertiser is targeting. */ | |
23251 core.String targetCpmNanos; | |
23252 /** Number of impressions that the advertiser is targeting. */ | |
23253 core.String targetImpressions; | |
23254 | |
23255 Project(); | |
23256 | |
23257 Project.fromJson(core.Map _json) { | |
23258 if (_json.containsKey("accountId")) { | |
23259 accountId = _json["accountId"]; | |
23260 } | |
23261 if (_json.containsKey("advertiserId")) { | |
23262 advertiserId = _json["advertiserId"]; | |
23263 } | |
23264 if (_json.containsKey("audienceAgeGroup")) { | |
23265 audienceAgeGroup = _json["audienceAgeGroup"]; | |
23266 } | |
23267 if (_json.containsKey("audienceGender")) { | |
23268 audienceGender = _json["audienceGender"]; | |
23269 } | |
23270 if (_json.containsKey("budget")) { | |
23271 budget = _json["budget"]; | |
23272 } | |
23273 if (_json.containsKey("clientBillingCode")) { | |
23274 clientBillingCode = _json["clientBillingCode"]; | |
23275 } | |
23276 if (_json.containsKey("clientName")) { | |
23277 clientName = _json["clientName"]; | |
23278 } | |
23279 if (_json.containsKey("endDate")) { | |
23280 endDate = core.DateTime.parse(_json["endDate"]); | |
23281 } | |
23282 if (_json.containsKey("id")) { | |
23283 id = _json["id"]; | |
23284 } | |
23285 if (_json.containsKey("kind")) { | |
23286 kind = _json["kind"]; | |
23287 } | |
23288 if (_json.containsKey("lastModifiedInfo")) { | |
23289 lastModifiedInfo = new LastModifiedInfo.fromJson(_json["lastModifiedInfo"]
); | |
23290 } | |
23291 if (_json.containsKey("name")) { | |
23292 name = _json["name"]; | |
23293 } | |
23294 if (_json.containsKey("overview")) { | |
23295 overview = _json["overview"]; | |
23296 } | |
23297 if (_json.containsKey("startDate")) { | |
23298 startDate = core.DateTime.parse(_json["startDate"]); | |
23299 } | |
23300 if (_json.containsKey("subaccountId")) { | |
23301 subaccountId = _json["subaccountId"]; | |
23302 } | |
23303 if (_json.containsKey("targetClicks")) { | |
23304 targetClicks = _json["targetClicks"]; | |
23305 } | |
23306 if (_json.containsKey("targetConversions")) { | |
23307 targetConversions = _json["targetConversions"]; | |
23308 } | |
23309 if (_json.containsKey("targetCpaNanos")) { | |
23310 targetCpaNanos = _json["targetCpaNanos"]; | |
23311 } | |
23312 if (_json.containsKey("targetCpcNanos")) { | |
23313 targetCpcNanos = _json["targetCpcNanos"]; | |
23314 } | |
23315 if (_json.containsKey("targetCpmNanos")) { | |
23316 targetCpmNanos = _json["targetCpmNanos"]; | |
23317 } | |
23318 if (_json.containsKey("targetImpressions")) { | |
23319 targetImpressions = _json["targetImpressions"]; | |
23320 } | |
23321 } | |
23322 | |
23323 core.Map toJson() { | |
23324 var _json = new core.Map(); | |
23325 if (accountId != null) { | |
23326 _json["accountId"] = accountId; | |
23327 } | |
23328 if (advertiserId != null) { | |
23329 _json["advertiserId"] = advertiserId; | |
23330 } | |
23331 if (audienceAgeGroup != null) { | |
23332 _json["audienceAgeGroup"] = audienceAgeGroup; | |
23333 } | |
23334 if (audienceGender != null) { | |
23335 _json["audienceGender"] = audienceGender; | |
23336 } | |
23337 if (budget != null) { | |
23338 _json["budget"] = budget; | |
23339 } | |
23340 if (clientBillingCode != null) { | |
23341 _json["clientBillingCode"] = clientBillingCode; | |
23342 } | |
23343 if (clientName != null) { | |
23344 _json["clientName"] = clientName; | |
23345 } | |
23346 if (endDate != null) { | |
23347 _json["endDate"] = "${(endDate).year.toString().padLeft(4, '0')}-${(endDat
e).month.toString().padLeft(2, '0')}-${(endDate).day.toString().padLeft(2, '0')}
"; | |
23348 } | |
23349 if (id != null) { | |
23350 _json["id"] = id; | |
23351 } | |
23352 if (kind != null) { | |
23353 _json["kind"] = kind; | |
23354 } | |
23355 if (lastModifiedInfo != null) { | |
23356 _json["lastModifiedInfo"] = (lastModifiedInfo).toJson(); | |
23357 } | |
23358 if (name != null) { | |
23359 _json["name"] = name; | |
23360 } | |
23361 if (overview != null) { | |
23362 _json["overview"] = overview; | |
23363 } | |
23364 if (startDate != null) { | |
23365 _json["startDate"] = "${(startDate).year.toString().padLeft(4, '0')}-${(st
artDate).month.toString().padLeft(2, '0')}-${(startDate).day.toString().padLeft(
2, '0')}"; | |
23366 } | |
23367 if (subaccountId != null) { | |
23368 _json["subaccountId"] = subaccountId; | |
23369 } | |
23370 if (targetClicks != null) { | |
23371 _json["targetClicks"] = targetClicks; | |
23372 } | |
23373 if (targetConversions != null) { | |
23374 _json["targetConversions"] = targetConversions; | |
23375 } | |
23376 if (targetCpaNanos != null) { | |
23377 _json["targetCpaNanos"] = targetCpaNanos; | |
23378 } | |
23379 if (targetCpcNanos != null) { | |
23380 _json["targetCpcNanos"] = targetCpcNanos; | |
23381 } | |
23382 if (targetCpmNanos != null) { | |
23383 _json["targetCpmNanos"] = targetCpmNanos; | |
23384 } | |
23385 if (targetImpressions != null) { | |
23386 _json["targetImpressions"] = targetImpressions; | |
23387 } | |
23388 return _json; | |
23389 } | |
23390 } | |
23391 | |
23392 /** Project List Response */ | |
23393 class ProjectsListResponse { | |
23394 /** | |
23395 * Identifies what kind of resource this is. Value: the fixed string | |
23396 * "dfareporting#projectsListResponse". | |
23397 */ | |
23398 core.String kind; | |
23399 /** Pagination token to be used for the next list operation. */ | |
23400 core.String nextPageToken; | |
23401 /** Project collection. */ | |
23402 core.List<Project> projects; | |
23403 | |
23404 ProjectsListResponse(); | |
23405 | |
23406 ProjectsListResponse.fromJson(core.Map _json) { | |
23407 if (_json.containsKey("kind")) { | |
23408 kind = _json["kind"]; | |
23409 } | |
23410 if (_json.containsKey("nextPageToken")) { | |
23411 nextPageToken = _json["nextPageToken"]; | |
23412 } | |
23413 if (_json.containsKey("projects")) { | |
23414 projects = _json["projects"].map((value) => new Project.fromJson(value)).t
oList(); | |
23415 } | |
23416 } | |
23417 | |
23418 core.Map toJson() { | |
23419 var _json = new core.Map(); | |
23420 if (kind != null) { | |
23421 _json["kind"] = kind; | |
23422 } | |
23423 if (nextPageToken != null) { | |
23424 _json["nextPageToken"] = nextPageToken; | |
23425 } | |
23426 if (projects != null) { | |
23427 _json["projects"] = projects.map((value) => (value).toJson()).toList(); | |
23428 } | |
23429 return _json; | |
23430 } | |
23431 } | |
23432 | |
23433 /** | |
23434 * Represents fields that are compatible to be selected for a report of type | |
23435 * "REACH". | |
23436 */ | |
23437 class ReachReportCompatibleFields { | |
23438 /** | |
23439 * Dimensions which are compatible to be selected in the "dimensionFilters" | |
23440 * section of the report. | |
23441 */ | |
23442 core.List<Dimension> dimensionFilters; | |
23443 /** | |
23444 * Dimensions which are compatible to be selected in the "dimensions" section | |
23445 * of the report. | |
23446 */ | |
23447 core.List<Dimension> dimensions; | |
23448 /** | |
23449 * The kind of resource this is, in this case | |
23450 * dfareporting#reachReportCompatibleFields. | |
23451 */ | |
23452 core.String kind; | |
23453 /** | |
23454 * Metrics which are compatible to be selected in the "metricNames" section of | |
23455 * the report. | |
23456 */ | |
23457 core.List<Metric> metrics; | |
23458 /** | |
23459 * Metrics which are compatible to be selected as activity metrics to pivot on | |
23460 * in the "activities" section of the report. | |
23461 */ | |
23462 core.List<Metric> pivotedActivityMetrics; | |
23463 /** | |
23464 * Metrics which are compatible to be selected in the | |
23465 * "reachByFrequencyMetricNames" section of the report. | |
23466 */ | |
23467 core.List<Metric> reachByFrequencyMetrics; | |
23468 | |
23469 ReachReportCompatibleFields(); | |
23470 | |
23471 ReachReportCompatibleFields.fromJson(core.Map _json) { | |
23472 if (_json.containsKey("dimensionFilters")) { | |
23473 dimensionFilters = _json["dimensionFilters"].map((value) => new Dimension.
fromJson(value)).toList(); | |
23474 } | |
23475 if (_json.containsKey("dimensions")) { | |
23476 dimensions = _json["dimensions"].map((value) => new Dimension.fromJson(val
ue)).toList(); | |
23477 } | |
23478 if (_json.containsKey("kind")) { | |
23479 kind = _json["kind"]; | |
23480 } | |
23481 if (_json.containsKey("metrics")) { | |
23482 metrics = _json["metrics"].map((value) => new Metric.fromJson(value)).toLi
st(); | |
23483 } | |
23484 if (_json.containsKey("pivotedActivityMetrics")) { | |
23485 pivotedActivityMetrics = _json["pivotedActivityMetrics"].map((value) => ne
w Metric.fromJson(value)).toList(); | |
23486 } | |
23487 if (_json.containsKey("reachByFrequencyMetrics")) { | |
23488 reachByFrequencyMetrics = _json["reachByFrequencyMetrics"].map((value) =>
new Metric.fromJson(value)).toList(); | |
23489 } | |
23490 } | |
23491 | |
23492 core.Map toJson() { | |
23493 var _json = new core.Map(); | |
23494 if (dimensionFilters != null) { | |
23495 _json["dimensionFilters"] = dimensionFilters.map((value) => (value).toJson
()).toList(); | |
23496 } | |
23497 if (dimensions != null) { | |
23498 _json["dimensions"] = dimensions.map((value) => (value).toJson()).toList()
; | |
23499 } | |
23500 if (kind != null) { | |
23501 _json["kind"] = kind; | |
23502 } | |
23503 if (metrics != null) { | |
23504 _json["metrics"] = metrics.map((value) => (value).toJson()).toList(); | |
23505 } | |
23506 if (pivotedActivityMetrics != null) { | |
23507 _json["pivotedActivityMetrics"] = pivotedActivityMetrics.map((value) => (v
alue).toJson()).toList(); | |
23508 } | |
23509 if (reachByFrequencyMetrics != null) { | |
23510 _json["reachByFrequencyMetrics"] = reachByFrequencyMetrics.map((value) =>
(value).toJson()).toList(); | |
23511 } | |
23512 return _json; | |
23513 } | |
23514 } | |
23515 | |
23516 /** Represents a recipient. */ | |
23517 class Recipient { | |
23518 /** | |
23519 * The delivery type for the recipient. | |
23520 * Possible string values are: | |
23521 * - "ATTACHMENT" | |
23522 * - "LINK" | |
23523 */ | |
23524 core.String deliveryType; | |
23525 /** The email address of the recipient. */ | |
23526 core.String email; | |
23527 /** The kind of resource this is, in this case dfareporting#recipient. */ | |
23528 core.String kind; | |
23529 | |
23530 Recipient(); | |
23531 | |
23532 Recipient.fromJson(core.Map _json) { | |
23533 if (_json.containsKey("deliveryType")) { | |
23534 deliveryType = _json["deliveryType"]; | |
23535 } | |
23536 if (_json.containsKey("email")) { | |
23537 email = _json["email"]; | |
23538 } | |
23539 if (_json.containsKey("kind")) { | |
23540 kind = _json["kind"]; | |
23541 } | |
23542 } | |
23543 | |
23544 core.Map toJson() { | |
23545 var _json = new core.Map(); | |
23546 if (deliveryType != null) { | |
23547 _json["deliveryType"] = deliveryType; | |
23548 } | |
23549 if (email != null) { | |
23550 _json["email"] = email; | |
23551 } | |
23552 if (kind != null) { | |
23553 _json["kind"] = kind; | |
23554 } | |
23555 return _json; | |
23556 } | |
23557 } | |
23558 | |
23559 /** Contains information about a region that can be targeted by ads. */ | |
23560 class Region { | |
23561 /** Country code of the country to which this region belongs. */ | |
23562 core.String countryCode; | |
23563 /** DART ID of the country to which this region belongs. */ | |
23564 core.String countryDartId; | |
23565 /** DART ID of this region. */ | |
23566 core.String dartId; | |
23567 /** | |
23568 * Identifies what kind of resource this is. Value: the fixed string | |
23569 * "dfareporting#region". | |
23570 */ | |
23571 core.String kind; | |
23572 /** Name of this region. */ | |
23573 core.String name; | |
23574 /** Region code. */ | |
23575 core.String regionCode; | |
23576 | |
23577 Region(); | |
23578 | |
23579 Region.fromJson(core.Map _json) { | |
23580 if (_json.containsKey("countryCode")) { | |
23581 countryCode = _json["countryCode"]; | |
23582 } | |
23583 if (_json.containsKey("countryDartId")) { | |
23584 countryDartId = _json["countryDartId"]; | |
23585 } | |
23586 if (_json.containsKey("dartId")) { | |
23587 dartId = _json["dartId"]; | |
23588 } | |
23589 if (_json.containsKey("kind")) { | |
23590 kind = _json["kind"]; | |
23591 } | |
23592 if (_json.containsKey("name")) { | |
23593 name = _json["name"]; | |
23594 } | |
23595 if (_json.containsKey("regionCode")) { | |
23596 regionCode = _json["regionCode"]; | |
23597 } | |
23598 } | |
23599 | |
23600 core.Map toJson() { | |
23601 var _json = new core.Map(); | |
23602 if (countryCode != null) { | |
23603 _json["countryCode"] = countryCode; | |
23604 } | |
23605 if (countryDartId != null) { | |
23606 _json["countryDartId"] = countryDartId; | |
23607 } | |
23608 if (dartId != null) { | |
23609 _json["dartId"] = dartId; | |
23610 } | |
23611 if (kind != null) { | |
23612 _json["kind"] = kind; | |
23613 } | |
23614 if (name != null) { | |
23615 _json["name"] = name; | |
23616 } | |
23617 if (regionCode != null) { | |
23618 _json["regionCode"] = regionCode; | |
23619 } | |
23620 return _json; | |
23621 } | |
23622 } | |
23623 | |
23624 /** Region List Response */ | |
23625 class RegionsListResponse { | |
23626 /** | |
23627 * Identifies what kind of resource this is. Value: the fixed string | |
23628 * "dfareporting#regionsListResponse". | |
23629 */ | |
23630 core.String kind; | |
23631 /** Region collection. */ | |
23632 core.List<Region> regions; | |
23633 | |
23634 RegionsListResponse(); | |
23635 | |
23636 RegionsListResponse.fromJson(core.Map _json) { | |
23637 if (_json.containsKey("kind")) { | |
23638 kind = _json["kind"]; | |
23639 } | |
23640 if (_json.containsKey("regions")) { | |
23641 regions = _json["regions"].map((value) => new Region.fromJson(value)).toLi
st(); | |
23642 } | |
23643 } | |
23644 | |
23645 core.Map toJson() { | |
23646 var _json = new core.Map(); | |
23647 if (kind != null) { | |
23648 _json["kind"] = kind; | |
23649 } | |
23650 if (regions != null) { | |
23651 _json["regions"] = regions.map((value) => (value).toJson()).toList(); | |
23652 } | |
23653 return _json; | |
23654 } | |
23655 } | |
23656 | |
23657 /** | |
23658 * Contains properties of a remarketing list. Remarketing enables you to create | |
23659 * lists of users who have performed specific actions on a site, then target ads | |
23660 * to members of those lists. This resource can be used to manage remarketing | |
23661 * lists that are owned by your advertisers. To see all remarketing lists that | |
23662 * are visible to your advertisers, including those that are shared to your | |
23663 * advertiser or account, use the TargetableRemarketingLists resource. | |
23664 */ | |
23665 class RemarketingList { | |
23666 /** | |
23667 * Account ID of this remarketing list. This is a read-only, auto-generated | |
23668 * field that is only returned in GET requests. | |
23669 */ | |
23670 core.String accountId; | |
23671 /** Whether this remarketing list is active. */ | |
23672 core.bool active; | |
23673 /** | |
23674 * Dimension value for the advertiser ID that owns this remarketing list. This | |
23675 * is a required field. | |
23676 */ | |
23677 core.String advertiserId; | |
23678 /** | |
23679 * Dimension value for the ID of the advertiser. This is a read-only, | |
23680 * auto-generated field. | |
23681 */ | |
23682 DimensionValue advertiserIdDimensionValue; | |
23683 /** Remarketing list description. */ | |
23684 core.String description; | |
23685 /** Remarketing list ID. This is a read-only, auto-generated field. */ | |
23686 core.String id; | |
23687 /** | |
23688 * Identifies what kind of resource this is. Value: the fixed string | |
23689 * "dfareporting#remarketingList". | |
23690 */ | |
23691 core.String kind; | |
23692 /** | |
23693 * Number of days that a user should remain in the remarketing list without an | |
23694 * impression. | |
23695 */ | |
23696 core.String lifeSpan; | |
23697 /** Rule used to populate the remarketing list with users. */ | |
23698 ListPopulationRule listPopulationRule; | |
23699 /** Number of users currently in the list. This is a read-only field. */ | |
23700 core.String listSize; | |
23701 /** | |
23702 * Product from which this remarketing list was originated. | |
23703 * Possible string values are: | |
23704 * - "REMARKETING_LIST_SOURCE_ADX" | |
23705 * - "REMARKETING_LIST_SOURCE_DBM" | |
23706 * - "REMARKETING_LIST_SOURCE_DFA" | |
23707 * - "REMARKETING_LIST_SOURCE_DFP" | |
23708 * - "REMARKETING_LIST_SOURCE_DMP" | |
23709 * - "REMARKETING_LIST_SOURCE_GA" | |
23710 * - "REMARKETING_LIST_SOURCE_GPLUS" | |
23711 * - "REMARKETING_LIST_SOURCE_OTHER" | |
23712 * - "REMARKETING_LIST_SOURCE_PLAY_STORE" | |
23713 * - "REMARKETING_LIST_SOURCE_XFP" | |
23714 * - "REMARKETING_LIST_SOURCE_YOUTUBE" | |
23715 */ | |
23716 core.String listSource; | |
23717 /** | |
23718 * Name of the remarketing list. This is a required field. Must be no greater | |
23719 * than 128 characters long. | |
23720 */ | |
23721 core.String name; | |
23722 /** | |
23723 * Subaccount ID of this remarketing list. This is a read-only, auto-generated | |
23724 * field that is only returned in GET requests. | |
23725 */ | |
23726 core.String subaccountId; | |
23727 | |
23728 RemarketingList(); | |
23729 | |
23730 RemarketingList.fromJson(core.Map _json) { | |
23731 if (_json.containsKey("accountId")) { | |
23732 accountId = _json["accountId"]; | |
23733 } | |
23734 if (_json.containsKey("active")) { | |
23735 active = _json["active"]; | |
23736 } | |
23737 if (_json.containsKey("advertiserId")) { | |
23738 advertiserId = _json["advertiserId"]; | |
23739 } | |
23740 if (_json.containsKey("advertiserIdDimensionValue")) { | |
23741 advertiserIdDimensionValue = new DimensionValue.fromJson(_json["advertiser
IdDimensionValue"]); | |
23742 } | |
23743 if (_json.containsKey("description")) { | |
23744 description = _json["description"]; | |
23745 } | |
23746 if (_json.containsKey("id")) { | |
23747 id = _json["id"]; | |
23748 } | |
23749 if (_json.containsKey("kind")) { | |
23750 kind = _json["kind"]; | |
23751 } | |
23752 if (_json.containsKey("lifeSpan")) { | |
23753 lifeSpan = _json["lifeSpan"]; | |
23754 } | |
23755 if (_json.containsKey("listPopulationRule")) { | |
23756 listPopulationRule = new ListPopulationRule.fromJson(_json["listPopulation
Rule"]); | |
23757 } | |
23758 if (_json.containsKey("listSize")) { | |
23759 listSize = _json["listSize"]; | |
23760 } | |
23761 if (_json.containsKey("listSource")) { | |
23762 listSource = _json["listSource"]; | |
23763 } | |
23764 if (_json.containsKey("name")) { | |
23765 name = _json["name"]; | |
23766 } | |
23767 if (_json.containsKey("subaccountId")) { | |
23768 subaccountId = _json["subaccountId"]; | |
23769 } | |
23770 } | |
23771 | |
23772 core.Map toJson() { | |
23773 var _json = new core.Map(); | |
23774 if (accountId != null) { | |
23775 _json["accountId"] = accountId; | |
23776 } | |
23777 if (active != null) { | |
23778 _json["active"] = active; | |
23779 } | |
23780 if (advertiserId != null) { | |
23781 _json["advertiserId"] = advertiserId; | |
23782 } | |
23783 if (advertiserIdDimensionValue != null) { | |
23784 _json["advertiserIdDimensionValue"] = (advertiserIdDimensionValue).toJson(
); | |
23785 } | |
23786 if (description != null) { | |
23787 _json["description"] = description; | |
23788 } | |
23789 if (id != null) { | |
23790 _json["id"] = id; | |
23791 } | |
23792 if (kind != null) { | |
23793 _json["kind"] = kind; | |
23794 } | |
23795 if (lifeSpan != null) { | |
23796 _json["lifeSpan"] = lifeSpan; | |
23797 } | |
23798 if (listPopulationRule != null) { | |
23799 _json["listPopulationRule"] = (listPopulationRule).toJson(); | |
23800 } | |
23801 if (listSize != null) { | |
23802 _json["listSize"] = listSize; | |
23803 } | |
23804 if (listSource != null) { | |
23805 _json["listSource"] = listSource; | |
23806 } | |
23807 if (name != null) { | |
23808 _json["name"] = name; | |
23809 } | |
23810 if (subaccountId != null) { | |
23811 _json["subaccountId"] = subaccountId; | |
23812 } | |
23813 return _json; | |
23814 } | |
23815 } | |
23816 | |
23817 /** | |
23818 * Contains properties of a remarketing list's sharing information. Sharing | |
23819 * allows other accounts or advertisers to target to your remarketing lists. | |
23820 * This resource can be used to manage remarketing list sharing to other | |
23821 * accounts and advertisers. | |
23822 */ | |
23823 class RemarketingListShare { | |
23824 /** | |
23825 * Identifies what kind of resource this is. Value: the fixed string | |
23826 * "dfareporting#remarketingListShare". | |
23827 */ | |
23828 core.String kind; | |
23829 /** Remarketing list ID. This is a read-only, auto-generated field. */ | |
23830 core.String remarketingListId; | |
23831 /** Accounts that the remarketing list is shared with. */ | |
23832 core.List<core.String> sharedAccountIds; | |
23833 /** Advertisers that the remarketing list is shared with. */ | |
23834 core.List<core.String> sharedAdvertiserIds; | |
23835 | |
23836 RemarketingListShare(); | |
23837 | |
23838 RemarketingListShare.fromJson(core.Map _json) { | |
23839 if (_json.containsKey("kind")) { | |
23840 kind = _json["kind"]; | |
23841 } | |
23842 if (_json.containsKey("remarketingListId")) { | |
23843 remarketingListId = _json["remarketingListId"]; | |
23844 } | |
23845 if (_json.containsKey("sharedAccountIds")) { | |
23846 sharedAccountIds = _json["sharedAccountIds"]; | |
23847 } | |
23848 if (_json.containsKey("sharedAdvertiserIds")) { | |
23849 sharedAdvertiserIds = _json["sharedAdvertiserIds"]; | |
23850 } | |
23851 } | |
23852 | |
23853 core.Map toJson() { | |
23854 var _json = new core.Map(); | |
23855 if (kind != null) { | |
23856 _json["kind"] = kind; | |
23857 } | |
23858 if (remarketingListId != null) { | |
23859 _json["remarketingListId"] = remarketingListId; | |
23860 } | |
23861 if (sharedAccountIds != null) { | |
23862 _json["sharedAccountIds"] = sharedAccountIds; | |
23863 } | |
23864 if (sharedAdvertiserIds != null) { | |
23865 _json["sharedAdvertiserIds"] = sharedAdvertiserIds; | |
23866 } | |
23867 return _json; | |
23868 } | |
23869 } | |
23870 | |
23871 /** Remarketing list response */ | |
23872 class RemarketingListsListResponse { | |
23873 /** | |
23874 * Identifies what kind of resource this is. Value: the fixed string | |
23875 * "dfareporting#remarketingListsListResponse". | |
23876 */ | |
23877 core.String kind; | |
23878 /** Pagination token to be used for the next list operation. */ | |
23879 core.String nextPageToken; | |
23880 /** Remarketing list collection. */ | |
23881 core.List<RemarketingList> remarketingLists; | |
23882 | |
23883 RemarketingListsListResponse(); | |
23884 | |
23885 RemarketingListsListResponse.fromJson(core.Map _json) { | |
23886 if (_json.containsKey("kind")) { | |
23887 kind = _json["kind"]; | |
23888 } | |
23889 if (_json.containsKey("nextPageToken")) { | |
23890 nextPageToken = _json["nextPageToken"]; | |
23891 } | |
23892 if (_json.containsKey("remarketingLists")) { | |
23893 remarketingLists = _json["remarketingLists"].map((value) => new Remarketin
gList.fromJson(value)).toList(); | |
23894 } | |
23895 } | |
23896 | |
23897 core.Map toJson() { | |
23898 var _json = new core.Map(); | |
23899 if (kind != null) { | |
23900 _json["kind"] = kind; | |
23901 } | |
23902 if (nextPageToken != null) { | |
23903 _json["nextPageToken"] = nextPageToken; | |
23904 } | |
23905 if (remarketingLists != null) { | |
23906 _json["remarketingLists"] = remarketingLists.map((value) => (value).toJson
()).toList(); | |
23907 } | |
23908 return _json; | |
23909 } | |
23910 } | |
23911 | |
23912 /** The report criteria for a report of type "STANDARD". */ | |
23913 class ReportCriteria { | |
23914 /** Activity group. */ | |
23915 Activities activities; | |
23916 /** Custom Rich Media Events group. */ | |
23917 CustomRichMediaEvents customRichMediaEvents; | |
23918 /** The date range for which this report should be run. */ | |
23919 DateRange dateRange; | |
23920 /** | |
23921 * The list of filters on which dimensions are filtered. | |
23922 * Filters for different dimensions are ANDed, filters for the same dimension | |
23923 * are grouped together and ORed. | |
23924 */ | |
23925 core.List<DimensionValue> dimensionFilters; | |
23926 /** The list of standard dimensions the report should include. */ | |
23927 core.List<SortedDimension> dimensions; | |
23928 /** The list of names of metrics the report should include. */ | |
23929 core.List<core.String> metricNames; | |
23930 | |
23931 ReportCriteria(); | |
23932 | |
23933 ReportCriteria.fromJson(core.Map _json) { | |
23934 if (_json.containsKey("activities")) { | |
23935 activities = new Activities.fromJson(_json["activities"]); | |
23936 } | |
23937 if (_json.containsKey("customRichMediaEvents")) { | |
23938 customRichMediaEvents = new CustomRichMediaEvents.fromJson(_json["customRi
chMediaEvents"]); | |
23939 } | |
23940 if (_json.containsKey("dateRange")) { | |
23941 dateRange = new DateRange.fromJson(_json["dateRange"]); | |
23942 } | |
23943 if (_json.containsKey("dimensionFilters")) { | |
23944 dimensionFilters = _json["dimensionFilters"].map((value) => new DimensionV
alue.fromJson(value)).toList(); | |
23945 } | |
23946 if (_json.containsKey("dimensions")) { | |
23947 dimensions = _json["dimensions"].map((value) => new SortedDimension.fromJs
on(value)).toList(); | |
23948 } | |
23949 if (_json.containsKey("metricNames")) { | |
23950 metricNames = _json["metricNames"]; | |
23951 } | |
23952 } | |
23953 | |
23954 core.Map toJson() { | |
23955 var _json = new core.Map(); | |
23956 if (activities != null) { | |
23957 _json["activities"] = (activities).toJson(); | |
23958 } | |
23959 if (customRichMediaEvents != null) { | |
23960 _json["customRichMediaEvents"] = (customRichMediaEvents).toJson(); | |
23961 } | |
23962 if (dateRange != null) { | |
23963 _json["dateRange"] = (dateRange).toJson(); | |
23964 } | |
23965 if (dimensionFilters != null) { | |
23966 _json["dimensionFilters"] = dimensionFilters.map((value) => (value).toJson
()).toList(); | |
23967 } | |
23968 if (dimensions != null) { | |
23969 _json["dimensions"] = dimensions.map((value) => (value).toJson()).toList()
; | |
23970 } | |
23971 if (metricNames != null) { | |
23972 _json["metricNames"] = metricNames; | |
23973 } | |
23974 return _json; | |
23975 } | |
23976 } | |
23977 | |
23978 /** The report criteria for a report of type "CROSS_DIMENSION_REACH". */ | |
23979 class ReportCrossDimensionReachCriteria { | |
23980 /** The list of dimensions the report should include. */ | |
23981 core.List<SortedDimension> breakdown; | |
23982 /** The date range this report should be run for. */ | |
23983 DateRange dateRange; | |
23984 /** | |
23985 * The dimension option. | |
23986 * Possible string values are: | |
23987 * - "ADVERTISER" | |
23988 * - "CAMPAIGN" | |
23989 * - "SITE_BY_ADVERTISER" | |
23990 * - "SITE_BY_CAMPAIGN" | |
23991 */ | |
23992 core.String dimension; | |
23993 /** The list of filters on which dimensions are filtered. */ | |
23994 core.List<DimensionValue> dimensionFilters; | |
23995 /** The list of names of metrics the report should include. */ | |
23996 core.List<core.String> metricNames; | |
23997 /** The list of names of overlap metrics the report should include. */ | |
23998 core.List<core.String> overlapMetricNames; | |
23999 /** Whether the report is pivoted or not. Defaults to true. */ | |
24000 core.bool pivoted; | |
24001 | |
24002 ReportCrossDimensionReachCriteria(); | |
24003 | |
24004 ReportCrossDimensionReachCriteria.fromJson(core.Map _json) { | |
24005 if (_json.containsKey("breakdown")) { | |
24006 breakdown = _json["breakdown"].map((value) => new SortedDimension.fromJson
(value)).toList(); | |
24007 } | |
24008 if (_json.containsKey("dateRange")) { | |
24009 dateRange = new DateRange.fromJson(_json["dateRange"]); | |
24010 } | |
24011 if (_json.containsKey("dimension")) { | |
24012 dimension = _json["dimension"]; | |
24013 } | |
24014 if (_json.containsKey("dimensionFilters")) { | |
24015 dimensionFilters = _json["dimensionFilters"].map((value) => new DimensionV
alue.fromJson(value)).toList(); | |
24016 } | |
24017 if (_json.containsKey("metricNames")) { | |
24018 metricNames = _json["metricNames"]; | |
24019 } | |
24020 if (_json.containsKey("overlapMetricNames")) { | |
24021 overlapMetricNames = _json["overlapMetricNames"]; | |
24022 } | |
24023 if (_json.containsKey("pivoted")) { | |
24024 pivoted = _json["pivoted"]; | |
24025 } | |
24026 } | |
24027 | |
24028 core.Map toJson() { | |
24029 var _json = new core.Map(); | |
24030 if (breakdown != null) { | |
24031 _json["breakdown"] = breakdown.map((value) => (value).toJson()).toList(); | |
24032 } | |
24033 if (dateRange != null) { | |
24034 _json["dateRange"] = (dateRange).toJson(); | |
24035 } | |
24036 if (dimension != null) { | |
24037 _json["dimension"] = dimension; | |
24038 } | |
24039 if (dimensionFilters != null) { | |
24040 _json["dimensionFilters"] = dimensionFilters.map((value) => (value).toJson
()).toList(); | |
24041 } | |
24042 if (metricNames != null) { | |
24043 _json["metricNames"] = metricNames; | |
24044 } | |
24045 if (overlapMetricNames != null) { | |
24046 _json["overlapMetricNames"] = overlapMetricNames; | |
24047 } | |
24048 if (pivoted != null) { | |
24049 _json["pivoted"] = pivoted; | |
24050 } | |
24051 return _json; | |
24052 } | |
24053 } | |
24054 | |
24055 /** The report's email delivery settings. */ | |
24056 class ReportDelivery { | |
24057 /** Whether the report should be emailed to the report owner. */ | |
24058 core.bool emailOwner; | |
24059 /** | |
24060 * The type of delivery for the owner to receive, if enabled. | |
24061 * Possible string values are: | |
24062 * - "ATTACHMENT" | |
24063 * - "LINK" | |
24064 */ | |
24065 core.String emailOwnerDeliveryType; | |
24066 /** The message to be sent with each email. */ | |
24067 core.String message; | |
24068 /** The list of recipients to which to email the report. */ | |
24069 core.List<Recipient> recipients; | |
24070 | |
24071 ReportDelivery(); | |
24072 | |
24073 ReportDelivery.fromJson(core.Map _json) { | |
24074 if (_json.containsKey("emailOwner")) { | |
24075 emailOwner = _json["emailOwner"]; | |
24076 } | |
24077 if (_json.containsKey("emailOwnerDeliveryType")) { | |
24078 emailOwnerDeliveryType = _json["emailOwnerDeliveryType"]; | |
24079 } | |
24080 if (_json.containsKey("message")) { | |
24081 message = _json["message"]; | |
24082 } | |
24083 if (_json.containsKey("recipients")) { | |
24084 recipients = _json["recipients"].map((value) => new Recipient.fromJson(val
ue)).toList(); | |
24085 } | |
24086 } | |
24087 | |
24088 core.Map toJson() { | |
24089 var _json = new core.Map(); | |
24090 if (emailOwner != null) { | |
24091 _json["emailOwner"] = emailOwner; | |
24092 } | |
24093 if (emailOwnerDeliveryType != null) { | |
24094 _json["emailOwnerDeliveryType"] = emailOwnerDeliveryType; | |
24095 } | |
24096 if (message != null) { | |
24097 _json["message"] = message; | |
24098 } | |
24099 if (recipients != null) { | |
24100 _json["recipients"] = recipients.map((value) => (value).toJson()).toList()
; | |
24101 } | |
24102 return _json; | |
24103 } | |
24104 } | |
24105 | |
24106 /** The properties of the report. */ | |
24107 class ReportFloodlightCriteriaReportProperties { | |
24108 /** Include conversions that have no cookie, but do have an exposure path. */ | |
24109 core.bool includeAttributedIPConversions; | |
24110 /** | |
24111 * Include conversions of users with a DoubleClick cookie but without an | |
24112 * exposure. That means the user did not click or see an ad from the | |
24113 * advertiser within the Floodlight group, or that the interaction happened | |
24114 * outside the lookback window. | |
24115 */ | |
24116 core.bool includeUnattributedCookieConversions; | |
24117 /** | |
24118 * Include conversions that have no associated cookies and no exposures. It’s | |
24119 * therefore impossible to know how the user was exposed to your ads during | |
24120 * the lookback window prior to a conversion. | |
24121 */ | |
24122 core.bool includeUnattributedIPConversions; | |
24123 | |
24124 ReportFloodlightCriteriaReportProperties(); | |
24125 | |
24126 ReportFloodlightCriteriaReportProperties.fromJson(core.Map _json) { | |
24127 if (_json.containsKey("includeAttributedIPConversions")) { | |
24128 includeAttributedIPConversions = _json["includeAttributedIPConversions"]; | |
24129 } | |
24130 if (_json.containsKey("includeUnattributedCookieConversions")) { | |
24131 includeUnattributedCookieConversions = _json["includeUnattributedCookieCon
versions"]; | |
24132 } | |
24133 if (_json.containsKey("includeUnattributedIPConversions")) { | |
24134 includeUnattributedIPConversions = _json["includeUnattributedIPConversions
"]; | |
24135 } | |
24136 } | |
24137 | |
24138 core.Map toJson() { | |
24139 var _json = new core.Map(); | |
24140 if (includeAttributedIPConversions != null) { | |
24141 _json["includeAttributedIPConversions"] = includeAttributedIPConversions; | |
24142 } | |
24143 if (includeUnattributedCookieConversions != null) { | |
24144 _json["includeUnattributedCookieConversions"] = includeUnattributedCookieC
onversions; | |
24145 } | |
24146 if (includeUnattributedIPConversions != null) { | |
24147 _json["includeUnattributedIPConversions"] = includeUnattributedIPConversio
ns; | |
24148 } | |
24149 return _json; | |
24150 } | |
24151 } | |
24152 | |
24153 /** The report criteria for a report of type "FLOODLIGHT". */ | |
24154 class ReportFloodlightCriteria { | |
24155 /** The list of custom rich media events to include. */ | |
24156 core.List<DimensionValue> customRichMediaEvents; | |
24157 /** The date range this report should be run for. */ | |
24158 DateRange dateRange; | |
24159 /** | |
24160 * The list of filters on which dimensions are filtered. | |
24161 * Filters for different dimensions are ANDed, filters for the same dimension | |
24162 * are grouped together and ORed. | |
24163 */ | |
24164 core.List<DimensionValue> dimensionFilters; | |
24165 /** The list of dimensions the report should include. */ | |
24166 core.List<SortedDimension> dimensions; | |
24167 /** | |
24168 * The floodlight ID for which to show data in this report. All advertisers | |
24169 * associated with that ID will automatically be added. The dimension of the | |
24170 * value needs to be 'dfa:floodlightConfigId'. | |
24171 */ | |
24172 DimensionValue floodlightConfigId; | |
24173 /** The list of names of metrics the report should include. */ | |
24174 core.List<core.String> metricNames; | |
24175 /** The properties of the report. */ | |
24176 ReportFloodlightCriteriaReportProperties reportProperties; | |
24177 | |
24178 ReportFloodlightCriteria(); | |
24179 | |
24180 ReportFloodlightCriteria.fromJson(core.Map _json) { | |
24181 if (_json.containsKey("customRichMediaEvents")) { | |
24182 customRichMediaEvents = _json["customRichMediaEvents"].map((value) => new
DimensionValue.fromJson(value)).toList(); | |
24183 } | |
24184 if (_json.containsKey("dateRange")) { | |
24185 dateRange = new DateRange.fromJson(_json["dateRange"]); | |
24186 } | |
24187 if (_json.containsKey("dimensionFilters")) { | |
24188 dimensionFilters = _json["dimensionFilters"].map((value) => new DimensionV
alue.fromJson(value)).toList(); | |
24189 } | |
24190 if (_json.containsKey("dimensions")) { | |
24191 dimensions = _json["dimensions"].map((value) => new SortedDimension.fromJs
on(value)).toList(); | |
24192 } | |
24193 if (_json.containsKey("floodlightConfigId")) { | |
24194 floodlightConfigId = new DimensionValue.fromJson(_json["floodlightConfigId
"]); | |
24195 } | |
24196 if (_json.containsKey("metricNames")) { | |
24197 metricNames = _json["metricNames"]; | |
24198 } | |
24199 if (_json.containsKey("reportProperties")) { | |
24200 reportProperties = new ReportFloodlightCriteriaReportProperties.fromJson(_
json["reportProperties"]); | |
24201 } | |
24202 } | |
24203 | |
24204 core.Map toJson() { | |
24205 var _json = new core.Map(); | |
24206 if (customRichMediaEvents != null) { | |
24207 _json["customRichMediaEvents"] = customRichMediaEvents.map((value) => (val
ue).toJson()).toList(); | |
24208 } | |
24209 if (dateRange != null) { | |
24210 _json["dateRange"] = (dateRange).toJson(); | |
24211 } | |
24212 if (dimensionFilters != null) { | |
24213 _json["dimensionFilters"] = dimensionFilters.map((value) => (value).toJson
()).toList(); | |
24214 } | |
24215 if (dimensions != null) { | |
24216 _json["dimensions"] = dimensions.map((value) => (value).toJson()).toList()
; | |
24217 } | |
24218 if (floodlightConfigId != null) { | |
24219 _json["floodlightConfigId"] = (floodlightConfigId).toJson(); | |
24220 } | |
24221 if (metricNames != null) { | |
24222 _json["metricNames"] = metricNames; | |
24223 } | |
24224 if (reportProperties != null) { | |
24225 _json["reportProperties"] = (reportProperties).toJson(); | |
24226 } | |
24227 return _json; | |
24228 } | |
24229 } | |
24230 | |
24231 /** The properties of the report. */ | |
24232 class ReportPathToConversionCriteriaReportProperties { | |
24233 /** | |
24234 * DFA checks to see if a click interaction occurred within the specified | |
24235 * period of time before a conversion. By default the value is pulled from | |
24236 * Floodlight or you can manually enter a custom value. Valid values: 1-90. | |
24237 */ | |
24238 core.int clicksLookbackWindow; | |
24239 /** | |
24240 * DFA checks to see if an impression interaction occurred within the | |
24241 * specified period of time before a conversion. By default the value is | |
24242 * pulled from Floodlight or you can manually enter a custom value. Valid | |
24243 * values: 1-90. | |
24244 */ | |
24245 core.int impressionsLookbackWindow; | |
24246 /** Deprecated: has no effect. */ | |
24247 core.bool includeAttributedIPConversions; | |
24248 /** | |
24249 * Include conversions of users with a DoubleClick cookie but without an | |
24250 * exposure. That means the user did not click or see an ad from the | |
24251 * advertiser within the Floodlight group, or that the interaction happened | |
24252 * outside the lookback window. | |
24253 */ | |
24254 core.bool includeUnattributedCookieConversions; | |
24255 /** | |
24256 * Include conversions that have no associated cookies and no exposures. It’s | |
24257 * therefore impossible to know how the user was exposed to your ads during | |
24258 * the lookback window prior to a conversion. | |
24259 */ | |
24260 core.bool includeUnattributedIPConversions; | |
24261 /** | |
24262 * The maximum number of click interactions to include in the report. | |
24263 * Advertisers currently paying for E2C reports get up to 200 (100 clicks, 100 | |
24264 * impressions). If another advertiser in your network is paying for E2C, you | |
24265 * can have up to 5 total exposures per report. | |
24266 */ | |
24267 core.int maximumClickInteractions; | |
24268 /** | |
24269 * The maximum number of click interactions to include in the report. | |
24270 * Advertisers currently paying for E2C reports get up to 200 (100 clicks, 100 | |
24271 * impressions). If another advertiser in your network is paying for E2C, you | |
24272 * can have up to 5 total exposures per report. | |
24273 */ | |
24274 core.int maximumImpressionInteractions; | |
24275 /** | |
24276 * The maximum amount of time that can take place between interactions (clicks | |
24277 * or impressions) by the same user. Valid values: 1-90. | |
24278 */ | |
24279 core.int maximumInteractionGap; | |
24280 /** Enable pivoting on interaction path. */ | |
24281 core.bool pivotOnInteractionPath; | |
24282 | |
24283 ReportPathToConversionCriteriaReportProperties(); | |
24284 | |
24285 ReportPathToConversionCriteriaReportProperties.fromJson(core.Map _json) { | |
24286 if (_json.containsKey("clicksLookbackWindow")) { | |
24287 clicksLookbackWindow = _json["clicksLookbackWindow"]; | |
24288 } | |
24289 if (_json.containsKey("impressionsLookbackWindow")) { | |
24290 impressionsLookbackWindow = _json["impressionsLookbackWindow"]; | |
24291 } | |
24292 if (_json.containsKey("includeAttributedIPConversions")) { | |
24293 includeAttributedIPConversions = _json["includeAttributedIPConversions"]; | |
24294 } | |
24295 if (_json.containsKey("includeUnattributedCookieConversions")) { | |
24296 includeUnattributedCookieConversions = _json["includeUnattributedCookieCon
versions"]; | |
24297 } | |
24298 if (_json.containsKey("includeUnattributedIPConversions")) { | |
24299 includeUnattributedIPConversions = _json["includeUnattributedIPConversions
"]; | |
24300 } | |
24301 if (_json.containsKey("maximumClickInteractions")) { | |
24302 maximumClickInteractions = _json["maximumClickInteractions"]; | |
24303 } | |
24304 if (_json.containsKey("maximumImpressionInteractions")) { | |
24305 maximumImpressionInteractions = _json["maximumImpressionInteractions"]; | |
24306 } | |
24307 if (_json.containsKey("maximumInteractionGap")) { | |
24308 maximumInteractionGap = _json["maximumInteractionGap"]; | |
24309 } | |
24310 if (_json.containsKey("pivotOnInteractionPath")) { | |
24311 pivotOnInteractionPath = _json["pivotOnInteractionPath"]; | |
24312 } | |
24313 } | |
24314 | |
24315 core.Map toJson() { | |
24316 var _json = new core.Map(); | |
24317 if (clicksLookbackWindow != null) { | |
24318 _json["clicksLookbackWindow"] = clicksLookbackWindow; | |
24319 } | |
24320 if (impressionsLookbackWindow != null) { | |
24321 _json["impressionsLookbackWindow"] = impressionsLookbackWindow; | |
24322 } | |
24323 if (includeAttributedIPConversions != null) { | |
24324 _json["includeAttributedIPConversions"] = includeAttributedIPConversions; | |
24325 } | |
24326 if (includeUnattributedCookieConversions != null) { | |
24327 _json["includeUnattributedCookieConversions"] = includeUnattributedCookieC
onversions; | |
24328 } | |
24329 if (includeUnattributedIPConversions != null) { | |
24330 _json["includeUnattributedIPConversions"] = includeUnattributedIPConversio
ns; | |
24331 } | |
24332 if (maximumClickInteractions != null) { | |
24333 _json["maximumClickInteractions"] = maximumClickInteractions; | |
24334 } | |
24335 if (maximumImpressionInteractions != null) { | |
24336 _json["maximumImpressionInteractions"] = maximumImpressionInteractions; | |
24337 } | |
24338 if (maximumInteractionGap != null) { | |
24339 _json["maximumInteractionGap"] = maximumInteractionGap; | |
24340 } | |
24341 if (pivotOnInteractionPath != null) { | |
24342 _json["pivotOnInteractionPath"] = pivotOnInteractionPath; | |
24343 } | |
24344 return _json; | |
24345 } | |
24346 } | |
24347 | |
24348 /** The report criteria for a report of type "PATH_TO_CONVERSION". */ | |
24349 class ReportPathToConversionCriteria { | |
24350 /** The list of 'dfa:activity' values to filter on. */ | |
24351 core.List<DimensionValue> activityFilters; | |
24352 /** The list of conversion dimensions the report should include. */ | |
24353 core.List<SortedDimension> conversionDimensions; | |
24354 /** The list of custom floodlight variables the report should include. */ | |
24355 core.List<SortedDimension> customFloodlightVariables; | |
24356 /** The list of custom rich media events to include. */ | |
24357 core.List<DimensionValue> customRichMediaEvents; | |
24358 /** The date range this report should be run for. */ | |
24359 DateRange dateRange; | |
24360 /** | |
24361 * The floodlight ID for which to show data in this report. All advertisers | |
24362 * associated with that ID will automatically be added. The dimension of the | |
24363 * value needs to be 'dfa:floodlightConfigId'. | |
24364 */ | |
24365 DimensionValue floodlightConfigId; | |
24366 /** The list of names of metrics the report should include. */ | |
24367 core.List<core.String> metricNames; | |
24368 /** The list of per interaction dimensions the report should include. */ | |
24369 core.List<SortedDimension> perInteractionDimensions; | |
24370 /** The properties of the report. */ | |
24371 ReportPathToConversionCriteriaReportProperties reportProperties; | |
24372 | |
24373 ReportPathToConversionCriteria(); | |
24374 | |
24375 ReportPathToConversionCriteria.fromJson(core.Map _json) { | |
24376 if (_json.containsKey("activityFilters")) { | |
24377 activityFilters = _json["activityFilters"].map((value) => new DimensionVal
ue.fromJson(value)).toList(); | |
24378 } | |
24379 if (_json.containsKey("conversionDimensions")) { | |
24380 conversionDimensions = _json["conversionDimensions"].map((value) => new So
rtedDimension.fromJson(value)).toList(); | |
24381 } | |
24382 if (_json.containsKey("customFloodlightVariables")) { | |
24383 customFloodlightVariables = _json["customFloodlightVariables"].map((value)
=> new SortedDimension.fromJson(value)).toList(); | |
24384 } | |
24385 if (_json.containsKey("customRichMediaEvents")) { | |
24386 customRichMediaEvents = _json["customRichMediaEvents"].map((value) => new
DimensionValue.fromJson(value)).toList(); | |
24387 } | |
24388 if (_json.containsKey("dateRange")) { | |
24389 dateRange = new DateRange.fromJson(_json["dateRange"]); | |
24390 } | |
24391 if (_json.containsKey("floodlightConfigId")) { | |
24392 floodlightConfigId = new DimensionValue.fromJson(_json["floodlightConfigId
"]); | |
24393 } | |
24394 if (_json.containsKey("metricNames")) { | |
24395 metricNames = _json["metricNames"]; | |
24396 } | |
24397 if (_json.containsKey("perInteractionDimensions")) { | |
24398 perInteractionDimensions = _json["perInteractionDimensions"].map((value) =
> new SortedDimension.fromJson(value)).toList(); | |
24399 } | |
24400 if (_json.containsKey("reportProperties")) { | |
24401 reportProperties = new ReportPathToConversionCriteriaReportProperties.from
Json(_json["reportProperties"]); | |
24402 } | |
24403 } | |
24404 | |
24405 core.Map toJson() { | |
24406 var _json = new core.Map(); | |
24407 if (activityFilters != null) { | |
24408 _json["activityFilters"] = activityFilters.map((value) => (value).toJson()
).toList(); | |
24409 } | |
24410 if (conversionDimensions != null) { | |
24411 _json["conversionDimensions"] = conversionDimensions.map((value) => (value
).toJson()).toList(); | |
24412 } | |
24413 if (customFloodlightVariables != null) { | |
24414 _json["customFloodlightVariables"] = customFloodlightVariables.map((value)
=> (value).toJson()).toList(); | |
24415 } | |
24416 if (customRichMediaEvents != null) { | |
24417 _json["customRichMediaEvents"] = customRichMediaEvents.map((value) => (val
ue).toJson()).toList(); | |
24418 } | |
24419 if (dateRange != null) { | |
24420 _json["dateRange"] = (dateRange).toJson(); | |
24421 } | |
24422 if (floodlightConfigId != null) { | |
24423 _json["floodlightConfigId"] = (floodlightConfigId).toJson(); | |
24424 } | |
24425 if (metricNames != null) { | |
24426 _json["metricNames"] = metricNames; | |
24427 } | |
24428 if (perInteractionDimensions != null) { | |
24429 _json["perInteractionDimensions"] = perInteractionDimensions.map((value) =
> (value).toJson()).toList(); | |
24430 } | |
24431 if (reportProperties != null) { | |
24432 _json["reportProperties"] = (reportProperties).toJson(); | |
24433 } | |
24434 return _json; | |
24435 } | |
24436 } | |
24437 | |
24438 /** The report criteria for a report of type "REACH". */ | |
24439 class ReportReachCriteria { | |
24440 /** Activity group. */ | |
24441 Activities activities; | |
24442 /** Custom Rich Media Events group. */ | |
24443 CustomRichMediaEvents customRichMediaEvents; | |
24444 /** The date range this report should be run for. */ | |
24445 DateRange dateRange; | |
24446 /** | |
24447 * The list of filters on which dimensions are filtered. | |
24448 * Filters for different dimensions are ANDed, filters for the same dimension | |
24449 * are grouped together and ORed. | |
24450 */ | |
24451 core.List<DimensionValue> dimensionFilters; | |
24452 /** The list of dimensions the report should include. */ | |
24453 core.List<SortedDimension> dimensions; | |
24454 /** | |
24455 * Whether to enable all reach dimension combinations in the report. Defaults | |
24456 * to false. If enabled, the date range of the report should be within the | |
24457 * last three months. | |
24458 */ | |
24459 core.bool enableAllDimensionCombinations; | |
24460 /** The list of names of metrics the report should include. */ | |
24461 core.List<core.String> metricNames; | |
24462 /** | |
24463 * The list of names of Reach By Frequency metrics the report should include. | |
24464 */ | |
24465 core.List<core.String> reachByFrequencyMetricNames; | |
24466 | |
24467 ReportReachCriteria(); | |
24468 | |
24469 ReportReachCriteria.fromJson(core.Map _json) { | |
24470 if (_json.containsKey("activities")) { | |
24471 activities = new Activities.fromJson(_json["activities"]); | |
24472 } | |
24473 if (_json.containsKey("customRichMediaEvents")) { | |
24474 customRichMediaEvents = new CustomRichMediaEvents.fromJson(_json["customRi
chMediaEvents"]); | |
24475 } | |
24476 if (_json.containsKey("dateRange")) { | |
24477 dateRange = new DateRange.fromJson(_json["dateRange"]); | |
24478 } | |
24479 if (_json.containsKey("dimensionFilters")) { | |
24480 dimensionFilters = _json["dimensionFilters"].map((value) => new DimensionV
alue.fromJson(value)).toList(); | |
24481 } | |
24482 if (_json.containsKey("dimensions")) { | |
24483 dimensions = _json["dimensions"].map((value) => new SortedDimension.fromJs
on(value)).toList(); | |
24484 } | |
24485 if (_json.containsKey("enableAllDimensionCombinations")) { | |
24486 enableAllDimensionCombinations = _json["enableAllDimensionCombinations"]; | |
24487 } | |
24488 if (_json.containsKey("metricNames")) { | |
24489 metricNames = _json["metricNames"]; | |
24490 } | |
24491 if (_json.containsKey("reachByFrequencyMetricNames")) { | |
24492 reachByFrequencyMetricNames = _json["reachByFrequencyMetricNames"]; | |
24493 } | |
24494 } | |
24495 | |
24496 core.Map toJson() { | |
24497 var _json = new core.Map(); | |
24498 if (activities != null) { | |
24499 _json["activities"] = (activities).toJson(); | |
24500 } | |
24501 if (customRichMediaEvents != null) { | |
24502 _json["customRichMediaEvents"] = (customRichMediaEvents).toJson(); | |
24503 } | |
24504 if (dateRange != null) { | |
24505 _json["dateRange"] = (dateRange).toJson(); | |
24506 } | |
24507 if (dimensionFilters != null) { | |
24508 _json["dimensionFilters"] = dimensionFilters.map((value) => (value).toJson
()).toList(); | |
24509 } | |
24510 if (dimensions != null) { | |
24511 _json["dimensions"] = dimensions.map((value) => (value).toJson()).toList()
; | |
24512 } | |
24513 if (enableAllDimensionCombinations != null) { | |
24514 _json["enableAllDimensionCombinations"] = enableAllDimensionCombinations; | |
24515 } | |
24516 if (metricNames != null) { | |
24517 _json["metricNames"] = metricNames; | |
24518 } | |
24519 if (reachByFrequencyMetricNames != null) { | |
24520 _json["reachByFrequencyMetricNames"] = reachByFrequencyMetricNames; | |
24521 } | |
24522 return _json; | |
24523 } | |
24524 } | |
24525 | |
24526 /** | |
24527 * The report's schedule. Can only be set if the report's 'dateRange' is a | |
24528 * relative date range and the relative date range is not "TODAY". | |
24529 */ | |
24530 class ReportSchedule { | |
24531 /** | |
24532 * Whether the schedule is active or not. Must be set to either true or false. | |
24533 */ | |
24534 core.bool active; | |
24535 /** | |
24536 * Defines every how many days, weeks or months the report should be run. | |
24537 * Needs to be set when "repeats" is either "DAILY", "WEEKLY" or "MONTHLY". | |
24538 */ | |
24539 core.int every; | |
24540 /** The expiration date when the scheduled report stops running. */ | |
24541 core.DateTime expirationDate; | |
24542 /** | |
24543 * The interval for which the report is repeated. Note: | |
24544 * - "DAILY" also requires field "every" to be set. | |
24545 * - "WEEKLY" also requires fields "every" and "repeatsOnWeekDays" to be set. | |
24546 * - "MONTHLY" also requires fields "every" and "runsOnDayOfMonth" to be set. | |
24547 */ | |
24548 core.String repeats; | |
24549 /** List of week days "WEEKLY" on which scheduled reports should run. */ | |
24550 core.List<core.String> repeatsOnWeekDays; | |
24551 /** | |
24552 * Enum to define for "MONTHLY" scheduled reports whether reports should be | |
24553 * repeated on the same day of the month as "startDate" or the same day of the | |
24554 * week of the month. | |
24555 * Example: If 'startDate' is Monday, April 2nd 2012 (2012-04-02), | |
24556 * "DAY_OF_MONTH" would run subsequent reports on the 2nd of every Month, and | |
24557 * "WEEK_OF_MONTH" would run subsequent reports on the first Monday of the | |
24558 * month. | |
24559 * Possible string values are: | |
24560 * - "DAY_OF_MONTH" | |
24561 * - "WEEK_OF_MONTH" | |
24562 */ | |
24563 core.String runsOnDayOfMonth; | |
24564 /** Start date of date range for which scheduled reports should be run. */ | |
24565 core.DateTime startDate; | |
24566 | |
24567 ReportSchedule(); | |
24568 | |
24569 ReportSchedule.fromJson(core.Map _json) { | |
24570 if (_json.containsKey("active")) { | |
24571 active = _json["active"]; | |
24572 } | |
24573 if (_json.containsKey("every")) { | |
24574 every = _json["every"]; | |
24575 } | |
24576 if (_json.containsKey("expirationDate")) { | |
24577 expirationDate = core.DateTime.parse(_json["expirationDate"]); | |
24578 } | |
24579 if (_json.containsKey("repeats")) { | |
24580 repeats = _json["repeats"]; | |
24581 } | |
24582 if (_json.containsKey("repeatsOnWeekDays")) { | |
24583 repeatsOnWeekDays = _json["repeatsOnWeekDays"]; | |
24584 } | |
24585 if (_json.containsKey("runsOnDayOfMonth")) { | |
24586 runsOnDayOfMonth = _json["runsOnDayOfMonth"]; | |
24587 } | |
24588 if (_json.containsKey("startDate")) { | |
24589 startDate = core.DateTime.parse(_json["startDate"]); | |
24590 } | |
24591 } | |
24592 | |
24593 core.Map toJson() { | |
24594 var _json = new core.Map(); | |
24595 if (active != null) { | |
24596 _json["active"] = active; | |
24597 } | |
24598 if (every != null) { | |
24599 _json["every"] = every; | |
24600 } | |
24601 if (expirationDate != null) { | |
24602 _json["expirationDate"] = "${(expirationDate).year.toString().padLeft(4, '
0')}-${(expirationDate).month.toString().padLeft(2, '0')}-${(expirationDate).day
.toString().padLeft(2, '0')}"; | |
24603 } | |
24604 if (repeats != null) { | |
24605 _json["repeats"] = repeats; | |
24606 } | |
24607 if (repeatsOnWeekDays != null) { | |
24608 _json["repeatsOnWeekDays"] = repeatsOnWeekDays; | |
24609 } | |
24610 if (runsOnDayOfMonth != null) { | |
24611 _json["runsOnDayOfMonth"] = runsOnDayOfMonth; | |
24612 } | |
24613 if (startDate != null) { | |
24614 _json["startDate"] = "${(startDate).year.toString().padLeft(4, '0')}-${(st
artDate).month.toString().padLeft(2, '0')}-${(startDate).day.toString().padLeft(
2, '0')}"; | |
24615 } | |
24616 return _json; | |
24617 } | |
24618 } | |
24619 | |
24620 /** Represents a Report resource. */ | |
24621 class Report { | |
24622 /** The account ID to which this report belongs. */ | |
24623 core.String accountId; | |
24624 /** The report criteria for a report of type "STANDARD". */ | |
24625 ReportCriteria criteria; | |
24626 /** The report criteria for a report of type "CROSS_DIMENSION_REACH". */ | |
24627 ReportCrossDimensionReachCriteria crossDimensionReachCriteria; | |
24628 /** The report's email delivery settings. */ | |
24629 ReportDelivery delivery; | |
24630 /** The eTag of this response for caching purposes. */ | |
24631 core.String etag; | |
24632 /** The filename used when generating report files for this report. */ | |
24633 core.String fileName; | |
24634 /** The report criteria for a report of type "FLOODLIGHT". */ | |
24635 ReportFloodlightCriteria floodlightCriteria; | |
24636 /** | |
24637 * The output format of the report. If not specified, default format is "CSV". | |
24638 * Note that the actual format in the completed report file might differ if | |
24639 * for instance the report's size exceeds the format's capabilities. "CSV" | |
24640 * will then be the fallback format. | |
24641 * Possible string values are: | |
24642 * - "CSV" | |
24643 * - "EXCEL" | |
24644 */ | |
24645 core.String format; | |
24646 /** The unique ID identifying this report resource. */ | |
24647 core.String id; | |
24648 /** The kind of resource this is, in this case dfareporting#report. */ | |
24649 core.String kind; | |
24650 /** | |
24651 * The timestamp (in milliseconds since epoch) of when this report was last | |
24652 * modified. | |
24653 */ | |
24654 core.String lastModifiedTime; | |
24655 /** The name of the report. */ | |
24656 core.String name; | |
24657 /** The user profile id of the owner of this report. */ | |
24658 core.String ownerProfileId; | |
24659 /** The report criteria for a report of type "PATH_TO_CONVERSION". */ | |
24660 ReportPathToConversionCriteria pathToConversionCriteria; | |
24661 /** The report criteria for a report of type "REACH". */ | |
24662 ReportReachCriteria reachCriteria; | |
24663 /** | |
24664 * The report's schedule. Can only be set if the report's 'dateRange' is a | |
24665 * relative date range and the relative date range is not "TODAY". | |
24666 */ | |
24667 ReportSchedule schedule; | |
24668 /** The subaccount ID to which this report belongs if applicable. */ | |
24669 core.String subAccountId; | |
24670 /** | |
24671 * The type of the report. | |
24672 * Possible string values are: | |
24673 * - "CROSS_DIMENSION_REACH" | |
24674 * - "FLOODLIGHT" | |
24675 * - "PATH_TO_CONVERSION" | |
24676 * - "REACH" | |
24677 * - "STANDARD" | |
24678 */ | |
24679 core.String type; | |
24680 | |
24681 Report(); | |
24682 | |
24683 Report.fromJson(core.Map _json) { | |
24684 if (_json.containsKey("accountId")) { | |
24685 accountId = _json["accountId"]; | |
24686 } | |
24687 if (_json.containsKey("criteria")) { | |
24688 criteria = new ReportCriteria.fromJson(_json["criteria"]); | |
24689 } | |
24690 if (_json.containsKey("crossDimensionReachCriteria")) { | |
24691 crossDimensionReachCriteria = new ReportCrossDimensionReachCriteria.fromJs
on(_json["crossDimensionReachCriteria"]); | |
24692 } | |
24693 if (_json.containsKey("delivery")) { | |
24694 delivery = new ReportDelivery.fromJson(_json["delivery"]); | |
24695 } | |
24696 if (_json.containsKey("etag")) { | |
24697 etag = _json["etag"]; | |
24698 } | |
24699 if (_json.containsKey("fileName")) { | |
24700 fileName = _json["fileName"]; | |
24701 } | |
24702 if (_json.containsKey("floodlightCriteria")) { | |
24703 floodlightCriteria = new ReportFloodlightCriteria.fromJson(_json["floodlig
htCriteria"]); | |
24704 } | |
24705 if (_json.containsKey("format")) { | |
24706 format = _json["format"]; | |
24707 } | |
24708 if (_json.containsKey("id")) { | |
24709 id = _json["id"]; | |
24710 } | |
24711 if (_json.containsKey("kind")) { | |
24712 kind = _json["kind"]; | |
24713 } | |
24714 if (_json.containsKey("lastModifiedTime")) { | |
24715 lastModifiedTime = _json["lastModifiedTime"]; | |
24716 } | |
24717 if (_json.containsKey("name")) { | |
24718 name = _json["name"]; | |
24719 } | |
24720 if (_json.containsKey("ownerProfileId")) { | |
24721 ownerProfileId = _json["ownerProfileId"]; | |
24722 } | |
24723 if (_json.containsKey("pathToConversionCriteria")) { | |
24724 pathToConversionCriteria = new ReportPathToConversionCriteria.fromJson(_js
on["pathToConversionCriteria"]); | |
24725 } | |
24726 if (_json.containsKey("reachCriteria")) { | |
24727 reachCriteria = new ReportReachCriteria.fromJson(_json["reachCriteria"]); | |
24728 } | |
24729 if (_json.containsKey("schedule")) { | |
24730 schedule = new ReportSchedule.fromJson(_json["schedule"]); | |
24731 } | |
24732 if (_json.containsKey("subAccountId")) { | |
24733 subAccountId = _json["subAccountId"]; | |
24734 } | |
24735 if (_json.containsKey("type")) { | |
24736 type = _json["type"]; | |
24737 } | |
24738 } | |
24739 | |
24740 core.Map toJson() { | |
24741 var _json = new core.Map(); | |
24742 if (accountId != null) { | |
24743 _json["accountId"] = accountId; | |
24744 } | |
24745 if (criteria != null) { | |
24746 _json["criteria"] = (criteria).toJson(); | |
24747 } | |
24748 if (crossDimensionReachCriteria != null) { | |
24749 _json["crossDimensionReachCriteria"] = (crossDimensionReachCriteria).toJso
n(); | |
24750 } | |
24751 if (delivery != null) { | |
24752 _json["delivery"] = (delivery).toJson(); | |
24753 } | |
24754 if (etag != null) { | |
24755 _json["etag"] = etag; | |
24756 } | |
24757 if (fileName != null) { | |
24758 _json["fileName"] = fileName; | |
24759 } | |
24760 if (floodlightCriteria != null) { | |
24761 _json["floodlightCriteria"] = (floodlightCriteria).toJson(); | |
24762 } | |
24763 if (format != null) { | |
24764 _json["format"] = format; | |
24765 } | |
24766 if (id != null) { | |
24767 _json["id"] = id; | |
24768 } | |
24769 if (kind != null) { | |
24770 _json["kind"] = kind; | |
24771 } | |
24772 if (lastModifiedTime != null) { | |
24773 _json["lastModifiedTime"] = lastModifiedTime; | |
24774 } | |
24775 if (name != null) { | |
24776 _json["name"] = name; | |
24777 } | |
24778 if (ownerProfileId != null) { | |
24779 _json["ownerProfileId"] = ownerProfileId; | |
24780 } | |
24781 if (pathToConversionCriteria != null) { | |
24782 _json["pathToConversionCriteria"] = (pathToConversionCriteria).toJson(); | |
24783 } | |
24784 if (reachCriteria != null) { | |
24785 _json["reachCriteria"] = (reachCriteria).toJson(); | |
24786 } | |
24787 if (schedule != null) { | |
24788 _json["schedule"] = (schedule).toJson(); | |
24789 } | |
24790 if (subAccountId != null) { | |
24791 _json["subAccountId"] = subAccountId; | |
24792 } | |
24793 if (type != null) { | |
24794 _json["type"] = type; | |
24795 } | |
24796 return _json; | |
24797 } | |
24798 } | |
24799 | |
24800 /** | |
24801 * Represents fields that are compatible to be selected for a report of type | |
24802 * "STANDARD". | |
24803 */ | |
24804 class ReportCompatibleFields { | |
24805 /** | |
24806 * Dimensions which are compatible to be selected in the "dimensionFilters" | |
24807 * section of the report. | |
24808 */ | |
24809 core.List<Dimension> dimensionFilters; | |
24810 /** | |
24811 * Dimensions which are compatible to be selected in the "dimensions" section | |
24812 * of the report. | |
24813 */ | |
24814 core.List<Dimension> dimensions; | |
24815 /** | |
24816 * The kind of resource this is, in this case | |
24817 * dfareporting#reportCompatibleFields. | |
24818 */ | |
24819 core.String kind; | |
24820 /** | |
24821 * Metrics which are compatible to be selected in the "metricNames" section of | |
24822 * the report. | |
24823 */ | |
24824 core.List<Metric> metrics; | |
24825 /** | |
24826 * Metrics which are compatible to be selected as activity metrics to pivot on | |
24827 * in the "activities" section of the report. | |
24828 */ | |
24829 core.List<Metric> pivotedActivityMetrics; | |
24830 | |
24831 ReportCompatibleFields(); | |
24832 | |
24833 ReportCompatibleFields.fromJson(core.Map _json) { | |
24834 if (_json.containsKey("dimensionFilters")) { | |
24835 dimensionFilters = _json["dimensionFilters"].map((value) => new Dimension.
fromJson(value)).toList(); | |
24836 } | |
24837 if (_json.containsKey("dimensions")) { | |
24838 dimensions = _json["dimensions"].map((value) => new Dimension.fromJson(val
ue)).toList(); | |
24839 } | |
24840 if (_json.containsKey("kind")) { | |
24841 kind = _json["kind"]; | |
24842 } | |
24843 if (_json.containsKey("metrics")) { | |
24844 metrics = _json["metrics"].map((value) => new Metric.fromJson(value)).toLi
st(); | |
24845 } | |
24846 if (_json.containsKey("pivotedActivityMetrics")) { | |
24847 pivotedActivityMetrics = _json["pivotedActivityMetrics"].map((value) => ne
w Metric.fromJson(value)).toList(); | |
24848 } | |
24849 } | |
24850 | |
24851 core.Map toJson() { | |
24852 var _json = new core.Map(); | |
24853 if (dimensionFilters != null) { | |
24854 _json["dimensionFilters"] = dimensionFilters.map((value) => (value).toJson
()).toList(); | |
24855 } | |
24856 if (dimensions != null) { | |
24857 _json["dimensions"] = dimensions.map((value) => (value).toJson()).toList()
; | |
24858 } | |
24859 if (kind != null) { | |
24860 _json["kind"] = kind; | |
24861 } | |
24862 if (metrics != null) { | |
24863 _json["metrics"] = metrics.map((value) => (value).toJson()).toList(); | |
24864 } | |
24865 if (pivotedActivityMetrics != null) { | |
24866 _json["pivotedActivityMetrics"] = pivotedActivityMetrics.map((value) => (v
alue).toJson()).toList(); | |
24867 } | |
24868 return _json; | |
24869 } | |
24870 } | |
24871 | |
24872 /** Represents the list of reports. */ | |
24873 class ReportList { | |
24874 /** The eTag of this response for caching purposes. */ | |
24875 core.String etag; | |
24876 /** The reports returned in this response. */ | |
24877 core.List<Report> items; | |
24878 /** The kind of list this is, in this case dfareporting#reportList. */ | |
24879 core.String kind; | |
24880 /** | |
24881 * Continuation token used to page through reports. To retrieve the next page | |
24882 * of results, set the next request's "pageToken" to the value of this field. | |
24883 * The page token is only valid for a limited amount of time and should not be | |
24884 * persisted. | |
24885 */ | |
24886 core.String nextPageToken; | |
24887 | |
24888 ReportList(); | |
24889 | |
24890 ReportList.fromJson(core.Map _json) { | |
24891 if (_json.containsKey("etag")) { | |
24892 etag = _json["etag"]; | |
24893 } | |
24894 if (_json.containsKey("items")) { | |
24895 items = _json["items"].map((value) => new Report.fromJson(value)).toList()
; | |
24896 } | |
24897 if (_json.containsKey("kind")) { | |
24898 kind = _json["kind"]; | |
24899 } | |
24900 if (_json.containsKey("nextPageToken")) { | |
24901 nextPageToken = _json["nextPageToken"]; | |
24902 } | |
24903 } | |
24904 | |
24905 core.Map toJson() { | |
24906 var _json = new core.Map(); | |
24907 if (etag != null) { | |
24908 _json["etag"] = etag; | |
24909 } | |
24910 if (items != null) { | |
24911 _json["items"] = items.map((value) => (value).toJson()).toList(); | |
24912 } | |
24913 if (kind != null) { | |
24914 _json["kind"] = kind; | |
24915 } | |
24916 if (nextPageToken != null) { | |
24917 _json["nextPageToken"] = nextPageToken; | |
24918 } | |
24919 return _json; | |
24920 } | |
24921 } | |
24922 | |
24923 /** Reporting Configuration */ | |
24924 class ReportsConfiguration { | |
24925 /** | |
24926 * Whether the exposure to conversion report is enabled. This report shows | |
24927 * detailed pathway information on up to 10 of the most recent ad exposures | |
24928 * seen by a user before converting. | |
24929 */ | |
24930 core.bool exposureToConversionEnabled; | |
24931 /** Default lookback windows for new advertisers in this account. */ | |
24932 LookbackConfiguration lookbackConfiguration; | |
24933 /** | |
24934 * Report generation time zone ID of this account. This is a required field | |
24935 * that can only be changed by a superuser. | |
24936 * Acceptable values are: | |
24937 * | |
24938 * - "1" for "America/New_York" | |
24939 * - "2" for "Europe/London" | |
24940 * - "3" for "Europe/Paris" | |
24941 * - "4" for "Africa/Johannesburg" | |
24942 * - "5" for "Asia/Jerusalem" | |
24943 * - "6" for "Asia/Shanghai" | |
24944 * - "7" for "Asia/Hong_Kong" | |
24945 * - "8" for "Asia/Tokyo" | |
24946 * - "9" for "Australia/Sydney" | |
24947 * - "10" for "Asia/Dubai" | |
24948 * - "11" for "America/Los_Angeles" | |
24949 * - "12" for "Pacific/Auckland" | |
24950 * - "13" for "America/Sao_Paulo" | |
24951 */ | |
24952 core.String reportGenerationTimeZoneId; | |
24953 | |
24954 ReportsConfiguration(); | |
24955 | |
24956 ReportsConfiguration.fromJson(core.Map _json) { | |
24957 if (_json.containsKey("exposureToConversionEnabled")) { | |
24958 exposureToConversionEnabled = _json["exposureToConversionEnabled"]; | |
24959 } | |
24960 if (_json.containsKey("lookbackConfiguration")) { | |
24961 lookbackConfiguration = new LookbackConfiguration.fromJson(_json["lookback
Configuration"]); | |
24962 } | |
24963 if (_json.containsKey("reportGenerationTimeZoneId")) { | |
24964 reportGenerationTimeZoneId = _json["reportGenerationTimeZoneId"]; | |
24965 } | |
24966 } | |
24967 | |
24968 core.Map toJson() { | |
24969 var _json = new core.Map(); | |
24970 if (exposureToConversionEnabled != null) { | |
24971 _json["exposureToConversionEnabled"] = exposureToConversionEnabled; | |
24972 } | |
24973 if (lookbackConfiguration != null) { | |
24974 _json["lookbackConfiguration"] = (lookbackConfiguration).toJson(); | |
24975 } | |
24976 if (reportGenerationTimeZoneId != null) { | |
24977 _json["reportGenerationTimeZoneId"] = reportGenerationTimeZoneId; | |
24978 } | |
24979 return _json; | |
24980 } | |
24981 } | |
24982 | |
24983 /** Rich Media Exit Override. */ | |
24984 class RichMediaExitOverride { | |
24985 /** | |
24986 * Click-through URL to override the default exit URL. Applicable if the | |
24987 * useCustomExitUrl field is set to true. | |
24988 */ | |
24989 core.String customExitUrl; | |
24990 /** ID for the override to refer to a specific exit in the creative. */ | |
24991 core.String exitId; | |
24992 /** Whether to use the custom exit URL. */ | |
24993 core.bool useCustomExitUrl; | |
24994 | |
24995 RichMediaExitOverride(); | |
24996 | |
24997 RichMediaExitOverride.fromJson(core.Map _json) { | |
24998 if (_json.containsKey("customExitUrl")) { | |
24999 customExitUrl = _json["customExitUrl"]; | |
25000 } | |
25001 if (_json.containsKey("exitId")) { | |
25002 exitId = _json["exitId"]; | |
25003 } | |
25004 if (_json.containsKey("useCustomExitUrl")) { | |
25005 useCustomExitUrl = _json["useCustomExitUrl"]; | |
25006 } | |
25007 } | |
25008 | |
25009 core.Map toJson() { | |
25010 var _json = new core.Map(); | |
25011 if (customExitUrl != null) { | |
25012 _json["customExitUrl"] = customExitUrl; | |
25013 } | |
25014 if (exitId != null) { | |
25015 _json["exitId"] = exitId; | |
25016 } | |
25017 if (useCustomExitUrl != null) { | |
25018 _json["useCustomExitUrl"] = useCustomExitUrl; | |
25019 } | |
25020 return _json; | |
25021 } | |
25022 } | |
25023 | |
25024 /** Contains properties of a site. */ | |
25025 class Site { | |
25026 /** | |
25027 * Account ID of this site. This is a read-only field that can be left blank. | |
25028 */ | |
25029 core.String accountId; | |
25030 /** Whether this site is approved. */ | |
25031 core.bool approved; | |
25032 /** | |
25033 * Directory site associated with this site. This is a required field that is | |
25034 * read-only after insertion. | |
25035 */ | |
25036 core.String directorySiteId; | |
25037 /** | |
25038 * Dimension value for the ID of the directory site. This is a read-only, | |
25039 * auto-generated field. | |
25040 */ | |
25041 DimensionValue directorySiteIdDimensionValue; | |
25042 /** ID of this site. This is a read-only, auto-generated field. */ | |
25043 core.String id; | |
25044 /** | |
25045 * Dimension value for the ID of this site. This is a read-only, | |
25046 * auto-generated field. | |
25047 */ | |
25048 DimensionValue idDimensionValue; | |
25049 /** Key name of this site. This is a read-only, auto-generated field. */ | |
25050 core.String keyName; | |
25051 /** | |
25052 * Identifies what kind of resource this is. Value: the fixed string | |
25053 * "dfareporting#site". | |
25054 */ | |
25055 core.String kind; | |
25056 /** | |
25057 * Name of this site.This is a required field. Must be less than 128 | |
25058 * characters long. If this site is under a subaccount, the name must be | |
25059 * unique among sites of the same subaccount. Otherwise, this site is a | |
25060 * top-level site, and the name must be unique among top-level sites of the | |
25061 * same account. | |
25062 */ | |
25063 core.String name; | |
25064 /** Site contacts. */ | |
25065 core.List<SiteContact> siteContacts; | |
25066 /** Site-wide settings. */ | |
25067 SiteSettings siteSettings; | |
25068 /** | |
25069 * Subaccount ID of this site. This is a read-only field that can be left | |
25070 * blank. | |
25071 */ | |
25072 core.String subaccountId; | |
25073 | |
25074 Site(); | |
25075 | |
25076 Site.fromJson(core.Map _json) { | |
25077 if (_json.containsKey("accountId")) { | |
25078 accountId = _json["accountId"]; | |
25079 } | |
25080 if (_json.containsKey("approved")) { | |
25081 approved = _json["approved"]; | |
25082 } | |
25083 if (_json.containsKey("directorySiteId")) { | |
25084 directorySiteId = _json["directorySiteId"]; | |
25085 } | |
25086 if (_json.containsKey("directorySiteIdDimensionValue")) { | |
25087 directorySiteIdDimensionValue = new DimensionValue.fromJson(_json["directo
rySiteIdDimensionValue"]); | |
25088 } | |
25089 if (_json.containsKey("id")) { | |
25090 id = _json["id"]; | |
25091 } | |
25092 if (_json.containsKey("idDimensionValue")) { | |
25093 idDimensionValue = new DimensionValue.fromJson(_json["idDimensionValue"]); | |
25094 } | |
25095 if (_json.containsKey("keyName")) { | |
25096 keyName = _json["keyName"]; | |
25097 } | |
25098 if (_json.containsKey("kind")) { | |
25099 kind = _json["kind"]; | |
25100 } | |
25101 if (_json.containsKey("name")) { | |
25102 name = _json["name"]; | |
25103 } | |
25104 if (_json.containsKey("siteContacts")) { | |
25105 siteContacts = _json["siteContacts"].map((value) => new SiteContact.fromJs
on(value)).toList(); | |
25106 } | |
25107 if (_json.containsKey("siteSettings")) { | |
25108 siteSettings = new SiteSettings.fromJson(_json["siteSettings"]); | |
25109 } | |
25110 if (_json.containsKey("subaccountId")) { | |
25111 subaccountId = _json["subaccountId"]; | |
25112 } | |
25113 } | |
25114 | |
25115 core.Map toJson() { | |
25116 var _json = new core.Map(); | |
25117 if (accountId != null) { | |
25118 _json["accountId"] = accountId; | |
25119 } | |
25120 if (approved != null) { | |
25121 _json["approved"] = approved; | |
25122 } | |
25123 if (directorySiteId != null) { | |
25124 _json["directorySiteId"] = directorySiteId; | |
25125 } | |
25126 if (directorySiteIdDimensionValue != null) { | |
25127 _json["directorySiteIdDimensionValue"] = (directorySiteIdDimensionValue).t
oJson(); | |
25128 } | |
25129 if (id != null) { | |
25130 _json["id"] = id; | |
25131 } | |
25132 if (idDimensionValue != null) { | |
25133 _json["idDimensionValue"] = (idDimensionValue).toJson(); | |
25134 } | |
25135 if (keyName != null) { | |
25136 _json["keyName"] = keyName; | |
25137 } | |
25138 if (kind != null) { | |
25139 _json["kind"] = kind; | |
25140 } | |
25141 if (name != null) { | |
25142 _json["name"] = name; | |
25143 } | |
25144 if (siteContacts != null) { | |
25145 _json["siteContacts"] = siteContacts.map((value) => (value).toJson()).toLi
st(); | |
25146 } | |
25147 if (siteSettings != null) { | |
25148 _json["siteSettings"] = (siteSettings).toJson(); | |
25149 } | |
25150 if (subaccountId != null) { | |
25151 _json["subaccountId"] = subaccountId; | |
25152 } | |
25153 return _json; | |
25154 } | |
25155 } | |
25156 | |
25157 /** Site Contact */ | |
25158 class SiteContact { | |
25159 /** Address of this site contact. */ | |
25160 core.String address; | |
25161 /** | |
25162 * Site contact type. | |
25163 * Possible string values are: | |
25164 * - "SALES_PERSON" | |
25165 * - "TRAFFICKER" | |
25166 */ | |
25167 core.String contactType; | |
25168 /** Email address of this site contact. This is a required field. */ | |
25169 core.String email; | |
25170 /** First name of this site contact. */ | |
25171 core.String firstName; | |
25172 /** ID of this site contact. This is a read-only, auto-generated field. */ | |
25173 core.String id; | |
25174 /** Last name of this site contact. */ | |
25175 core.String lastName; | |
25176 /** Primary phone number of this site contact. */ | |
25177 core.String phone; | |
25178 /** Title or designation of this site contact. */ | |
25179 core.String title; | |
25180 | |
25181 SiteContact(); | |
25182 | |
25183 SiteContact.fromJson(core.Map _json) { | |
25184 if (_json.containsKey("address")) { | |
25185 address = _json["address"]; | |
25186 } | |
25187 if (_json.containsKey("contactType")) { | |
25188 contactType = _json["contactType"]; | |
25189 } | |
25190 if (_json.containsKey("email")) { | |
25191 email = _json["email"]; | |
25192 } | |
25193 if (_json.containsKey("firstName")) { | |
25194 firstName = _json["firstName"]; | |
25195 } | |
25196 if (_json.containsKey("id")) { | |
25197 id = _json["id"]; | |
25198 } | |
25199 if (_json.containsKey("lastName")) { | |
25200 lastName = _json["lastName"]; | |
25201 } | |
25202 if (_json.containsKey("phone")) { | |
25203 phone = _json["phone"]; | |
25204 } | |
25205 if (_json.containsKey("title")) { | |
25206 title = _json["title"]; | |
25207 } | |
25208 } | |
25209 | |
25210 core.Map toJson() { | |
25211 var _json = new core.Map(); | |
25212 if (address != null) { | |
25213 _json["address"] = address; | |
25214 } | |
25215 if (contactType != null) { | |
25216 _json["contactType"] = contactType; | |
25217 } | |
25218 if (email != null) { | |
25219 _json["email"] = email; | |
25220 } | |
25221 if (firstName != null) { | |
25222 _json["firstName"] = firstName; | |
25223 } | |
25224 if (id != null) { | |
25225 _json["id"] = id; | |
25226 } | |
25227 if (lastName != null) { | |
25228 _json["lastName"] = lastName; | |
25229 } | |
25230 if (phone != null) { | |
25231 _json["phone"] = phone; | |
25232 } | |
25233 if (title != null) { | |
25234 _json["title"] = title; | |
25235 } | |
25236 return _json; | |
25237 } | |
25238 } | |
25239 | |
25240 /** Site Settings */ | |
25241 class SiteSettings { | |
25242 /** Whether active view creatives are disabled for this site. */ | |
25243 core.bool activeViewOptOut; | |
25244 /** Site-wide creative settings. */ | |
25245 CreativeSettings creativeSettings; | |
25246 /** Whether brand safe ads are disabled for this site. */ | |
25247 core.bool disableBrandSafeAds; | |
25248 /** Whether new cookies are disabled for this site. */ | |
25249 core.bool disableNewCookie; | |
25250 /** Lookback window settings for this site. */ | |
25251 LookbackConfiguration lookbackConfiguration; | |
25252 /** Configuration settings for dynamic and image floodlight tags. */ | |
25253 TagSetting tagSetting; | |
25254 /** | |
25255 * Whether Verification and ActiveView are disabled for in-stream video | |
25256 * creatives on this site. The same setting videoActiveViewOptOut exists on | |
25257 * the directory site level -- the opt out occurs if either of these settings | |
25258 * are true. These settings are distinct from | |
25259 * DirectorySites.settings.activeViewOptOut or | |
25260 * Sites.siteSettings.activeViewOptOut which only apply to display ads. | |
25261 * However, Accounts.activeViewOptOut opts out both video traffic, as well as | |
25262 * display ads, from Verification and ActiveView. | |
25263 */ | |
25264 core.bool videoActiveViewOptOut; | |
25265 | |
25266 SiteSettings(); | |
25267 | |
25268 SiteSettings.fromJson(core.Map _json) { | |
25269 if (_json.containsKey("activeViewOptOut")) { | |
25270 activeViewOptOut = _json["activeViewOptOut"]; | |
25271 } | |
25272 if (_json.containsKey("creativeSettings")) { | |
25273 creativeSettings = new CreativeSettings.fromJson(_json["creativeSettings"]
); | |
25274 } | |
25275 if (_json.containsKey("disableBrandSafeAds")) { | |
25276 disableBrandSafeAds = _json["disableBrandSafeAds"]; | |
25277 } | |
25278 if (_json.containsKey("disableNewCookie")) { | |
25279 disableNewCookie = _json["disableNewCookie"]; | |
25280 } | |
25281 if (_json.containsKey("lookbackConfiguration")) { | |
25282 lookbackConfiguration = new LookbackConfiguration.fromJson(_json["lookback
Configuration"]); | |
25283 } | |
25284 if (_json.containsKey("tagSetting")) { | |
25285 tagSetting = new TagSetting.fromJson(_json["tagSetting"]); | |
25286 } | |
25287 if (_json.containsKey("videoActiveViewOptOut")) { | |
25288 videoActiveViewOptOut = _json["videoActiveViewOptOut"]; | |
25289 } | |
25290 } | |
25291 | |
25292 core.Map toJson() { | |
25293 var _json = new core.Map(); | |
25294 if (activeViewOptOut != null) { | |
25295 _json["activeViewOptOut"] = activeViewOptOut; | |
25296 } | |
25297 if (creativeSettings != null) { | |
25298 _json["creativeSettings"] = (creativeSettings).toJson(); | |
25299 } | |
25300 if (disableBrandSafeAds != null) { | |
25301 _json["disableBrandSafeAds"] = disableBrandSafeAds; | |
25302 } | |
25303 if (disableNewCookie != null) { | |
25304 _json["disableNewCookie"] = disableNewCookie; | |
25305 } | |
25306 if (lookbackConfiguration != null) { | |
25307 _json["lookbackConfiguration"] = (lookbackConfiguration).toJson(); | |
25308 } | |
25309 if (tagSetting != null) { | |
25310 _json["tagSetting"] = (tagSetting).toJson(); | |
25311 } | |
25312 if (videoActiveViewOptOut != null) { | |
25313 _json["videoActiveViewOptOut"] = videoActiveViewOptOut; | |
25314 } | |
25315 return _json; | |
25316 } | |
25317 } | |
25318 | |
25319 /** Site List Response */ | |
25320 class SitesListResponse { | |
25321 /** | |
25322 * Identifies what kind of resource this is. Value: the fixed string | |
25323 * "dfareporting#sitesListResponse". | |
25324 */ | |
25325 core.String kind; | |
25326 /** Pagination token to be used for the next list operation. */ | |
25327 core.String nextPageToken; | |
25328 /** Site collection. */ | |
25329 core.List<Site> sites; | |
25330 | |
25331 SitesListResponse(); | |
25332 | |
25333 SitesListResponse.fromJson(core.Map _json) { | |
25334 if (_json.containsKey("kind")) { | |
25335 kind = _json["kind"]; | |
25336 } | |
25337 if (_json.containsKey("nextPageToken")) { | |
25338 nextPageToken = _json["nextPageToken"]; | |
25339 } | |
25340 if (_json.containsKey("sites")) { | |
25341 sites = _json["sites"].map((value) => new Site.fromJson(value)).toList(); | |
25342 } | |
25343 } | |
25344 | |
25345 core.Map toJson() { | |
25346 var _json = new core.Map(); | |
25347 if (kind != null) { | |
25348 _json["kind"] = kind; | |
25349 } | |
25350 if (nextPageToken != null) { | |
25351 _json["nextPageToken"] = nextPageToken; | |
25352 } | |
25353 if (sites != null) { | |
25354 _json["sites"] = sites.map((value) => (value).toJson()).toList(); | |
25355 } | |
25356 return _json; | |
25357 } | |
25358 } | |
25359 | |
25360 /** | |
25361 * Represents the dimensions of ads, placements, creatives, or creative assets. | |
25362 */ | |
25363 class Size { | |
25364 /** Height of this size. */ | |
25365 core.int height; | |
25366 /** IAB standard size. This is a read-only, auto-generated field. */ | |
25367 core.bool iab; | |
25368 /** ID of this size. This is a read-only, auto-generated field. */ | |
25369 core.String id; | |
25370 /** | |
25371 * Identifies what kind of resource this is. Value: the fixed string | |
25372 * "dfareporting#size". | |
25373 */ | |
25374 core.String kind; | |
25375 /** Width of this size. */ | |
25376 core.int width; | |
25377 | |
25378 Size(); | |
25379 | |
25380 Size.fromJson(core.Map _json) { | |
25381 if (_json.containsKey("height")) { | |
25382 height = _json["height"]; | |
25383 } | |
25384 if (_json.containsKey("iab")) { | |
25385 iab = _json["iab"]; | |
25386 } | |
25387 if (_json.containsKey("id")) { | |
25388 id = _json["id"]; | |
25389 } | |
25390 if (_json.containsKey("kind")) { | |
25391 kind = _json["kind"]; | |
25392 } | |
25393 if (_json.containsKey("width")) { | |
25394 width = _json["width"]; | |
25395 } | |
25396 } | |
25397 | |
25398 core.Map toJson() { | |
25399 var _json = new core.Map(); | |
25400 if (height != null) { | |
25401 _json["height"] = height; | |
25402 } | |
25403 if (iab != null) { | |
25404 _json["iab"] = iab; | |
25405 } | |
25406 if (id != null) { | |
25407 _json["id"] = id; | |
25408 } | |
25409 if (kind != null) { | |
25410 _json["kind"] = kind; | |
25411 } | |
25412 if (width != null) { | |
25413 _json["width"] = width; | |
25414 } | |
25415 return _json; | |
25416 } | |
25417 } | |
25418 | |
25419 /** Size List Response */ | |
25420 class SizesListResponse { | |
25421 /** | |
25422 * Identifies what kind of resource this is. Value: the fixed string | |
25423 * "dfareporting#sizesListResponse". | |
25424 */ | |
25425 core.String kind; | |
25426 /** Size collection. */ | |
25427 core.List<Size> sizes; | |
25428 | |
25429 SizesListResponse(); | |
25430 | |
25431 SizesListResponse.fromJson(core.Map _json) { | |
25432 if (_json.containsKey("kind")) { | |
25433 kind = _json["kind"]; | |
25434 } | |
25435 if (_json.containsKey("sizes")) { | |
25436 sizes = _json["sizes"].map((value) => new Size.fromJson(value)).toList(); | |
25437 } | |
25438 } | |
25439 | |
25440 core.Map toJson() { | |
25441 var _json = new core.Map(); | |
25442 if (kind != null) { | |
25443 _json["kind"] = kind; | |
25444 } | |
25445 if (sizes != null) { | |
25446 _json["sizes"] = sizes.map((value) => (value).toJson()).toList(); | |
25447 } | |
25448 return _json; | |
25449 } | |
25450 } | |
25451 | |
25452 /** Represents a sorted dimension. */ | |
25453 class SortedDimension { | |
25454 /** | |
25455 * The kind of resource this is, in this case dfareporting#sortedDimension. | |
25456 */ | |
25457 core.String kind; | |
25458 /** The name of the dimension. */ | |
25459 core.String name; | |
25460 /** | |
25461 * An optional sort order for the dimension column. | |
25462 * Possible string values are: | |
25463 * - "ASCENDING" | |
25464 * - "DESCENDING" | |
25465 */ | |
25466 core.String sortOrder; | |
25467 | |
25468 SortedDimension(); | |
25469 | |
25470 SortedDimension.fromJson(core.Map _json) { | |
25471 if (_json.containsKey("kind")) { | |
25472 kind = _json["kind"]; | |
25473 } | |
25474 if (_json.containsKey("name")) { | |
25475 name = _json["name"]; | |
25476 } | |
25477 if (_json.containsKey("sortOrder")) { | |
25478 sortOrder = _json["sortOrder"]; | |
25479 } | |
25480 } | |
25481 | |
25482 core.Map toJson() { | |
25483 var _json = new core.Map(); | |
25484 if (kind != null) { | |
25485 _json["kind"] = kind; | |
25486 } | |
25487 if (name != null) { | |
25488 _json["name"] = name; | |
25489 } | |
25490 if (sortOrder != null) { | |
25491 _json["sortOrder"] = sortOrder; | |
25492 } | |
25493 return _json; | |
25494 } | |
25495 } | |
25496 | |
25497 /** Contains properties of a DCM subaccount. */ | |
25498 class Subaccount { | |
25499 /** | |
25500 * ID of the account that contains this subaccount. This is a read-only field | |
25501 * that can be left blank. | |
25502 */ | |
25503 core.String accountId; | |
25504 /** IDs of the available user role permissions for this subaccount. */ | |
25505 core.List<core.String> availablePermissionIds; | |
25506 /** ID of this subaccount. This is a read-only, auto-generated field. */ | |
25507 core.String id; | |
25508 /** | |
25509 * Identifies what kind of resource this is. Value: the fixed string | |
25510 * "dfareporting#subaccount". | |
25511 */ | |
25512 core.String kind; | |
25513 /** | |
25514 * Name of this subaccount. This is a required field. Must be less than 128 | |
25515 * characters long and be unique among subaccounts of the same account. | |
25516 */ | |
25517 core.String name; | |
25518 | |
25519 Subaccount(); | |
25520 | |
25521 Subaccount.fromJson(core.Map _json) { | |
25522 if (_json.containsKey("accountId")) { | |
25523 accountId = _json["accountId"]; | |
25524 } | |
25525 if (_json.containsKey("availablePermissionIds")) { | |
25526 availablePermissionIds = _json["availablePermissionIds"]; | |
25527 } | |
25528 if (_json.containsKey("id")) { | |
25529 id = _json["id"]; | |
25530 } | |
25531 if (_json.containsKey("kind")) { | |
25532 kind = _json["kind"]; | |
25533 } | |
25534 if (_json.containsKey("name")) { | |
25535 name = _json["name"]; | |
25536 } | |
25537 } | |
25538 | |
25539 core.Map toJson() { | |
25540 var _json = new core.Map(); | |
25541 if (accountId != null) { | |
25542 _json["accountId"] = accountId; | |
25543 } | |
25544 if (availablePermissionIds != null) { | |
25545 _json["availablePermissionIds"] = availablePermissionIds; | |
25546 } | |
25547 if (id != null) { | |
25548 _json["id"] = id; | |
25549 } | |
25550 if (kind != null) { | |
25551 _json["kind"] = kind; | |
25552 } | |
25553 if (name != null) { | |
25554 _json["name"] = name; | |
25555 } | |
25556 return _json; | |
25557 } | |
25558 } | |
25559 | |
25560 /** Subaccount List Response */ | |
25561 class SubaccountsListResponse { | |
25562 /** | |
25563 * Identifies what kind of resource this is. Value: the fixed string | |
25564 * "dfareporting#subaccountsListResponse". | |
25565 */ | |
25566 core.String kind; | |
25567 /** Pagination token to be used for the next list operation. */ | |
25568 core.String nextPageToken; | |
25569 /** Subaccount collection. */ | |
25570 core.List<Subaccount> subaccounts; | |
25571 | |
25572 SubaccountsListResponse(); | |
25573 | |
25574 SubaccountsListResponse.fromJson(core.Map _json) { | |
25575 if (_json.containsKey("kind")) { | |
25576 kind = _json["kind"]; | |
25577 } | |
25578 if (_json.containsKey("nextPageToken")) { | |
25579 nextPageToken = _json["nextPageToken"]; | |
25580 } | |
25581 if (_json.containsKey("subaccounts")) { | |
25582 subaccounts = _json["subaccounts"].map((value) => new Subaccount.fromJson(
value)).toList(); | |
25583 } | |
25584 } | |
25585 | |
25586 core.Map toJson() { | |
25587 var _json = new core.Map(); | |
25588 if (kind != null) { | |
25589 _json["kind"] = kind; | |
25590 } | |
25591 if (nextPageToken != null) { | |
25592 _json["nextPageToken"] = nextPageToken; | |
25593 } | |
25594 if (subaccounts != null) { | |
25595 _json["subaccounts"] = subaccounts.map((value) => (value).toJson()).toList
(); | |
25596 } | |
25597 return _json; | |
25598 } | |
25599 } | |
25600 | |
25601 /** Placement Tag Data */ | |
25602 class TagData { | |
25603 /** Ad associated with this placement tag. */ | |
25604 core.String adId; | |
25605 /** Tag string to record a click. */ | |
25606 core.String clickTag; | |
25607 /** Creative associated with this placement tag. */ | |
25608 core.String creativeId; | |
25609 /** | |
25610 * TagData tag format of this tag. | |
25611 * Possible string values are: | |
25612 * - "PLACEMENT_TAG_CLICK_COMMANDS" | |
25613 * - "PLACEMENT_TAG_IFRAME_ILAYER" | |
25614 * - "PLACEMENT_TAG_IFRAME_JAVASCRIPT" | |
25615 * - "PLACEMENT_TAG_IFRAME_JAVASCRIPT_LEGACY" | |
25616 * - "PLACEMENT_TAG_INSTREAM_VIDEO_PREFETCH" | |
25617 * - "PLACEMENT_TAG_INSTREAM_VIDEO_PREFETCH_VAST_3" | |
25618 * - "PLACEMENT_TAG_INTERNAL_REDIRECT" | |
25619 * - "PLACEMENT_TAG_INTERSTITIAL_IFRAME_JAVASCRIPT" | |
25620 * - "PLACEMENT_TAG_INTERSTITIAL_IFRAME_JAVASCRIPT_LEGACY" | |
25621 * - "PLACEMENT_TAG_INTERSTITIAL_INTERNAL_REDIRECT" | |
25622 * - "PLACEMENT_TAG_INTERSTITIAL_JAVASCRIPT" | |
25623 * - "PLACEMENT_TAG_INTERSTITIAL_JAVASCRIPT_LEGACY" | |
25624 * - "PLACEMENT_TAG_JAVASCRIPT" | |
25625 * - "PLACEMENT_TAG_JAVASCRIPT_LEGACY" | |
25626 * - "PLACEMENT_TAG_STANDARD" | |
25627 * - "PLACEMENT_TAG_TRACKING" | |
25628 * - "PLACEMENT_TAG_TRACKING_IFRAME" | |
25629 * - "PLACEMENT_TAG_TRACKING_JAVASCRIPT" | |
25630 */ | |
25631 core.String format; | |
25632 /** Tag string for serving an ad. */ | |
25633 core.String impressionTag; | |
25634 | |
25635 TagData(); | |
25636 | |
25637 TagData.fromJson(core.Map _json) { | |
25638 if (_json.containsKey("adId")) { | |
25639 adId = _json["adId"]; | |
25640 } | |
25641 if (_json.containsKey("clickTag")) { | |
25642 clickTag = _json["clickTag"]; | |
25643 } | |
25644 if (_json.containsKey("creativeId")) { | |
25645 creativeId = _json["creativeId"]; | |
25646 } | |
25647 if (_json.containsKey("format")) { | |
25648 format = _json["format"]; | |
25649 } | |
25650 if (_json.containsKey("impressionTag")) { | |
25651 impressionTag = _json["impressionTag"]; | |
25652 } | |
25653 } | |
25654 | |
25655 core.Map toJson() { | |
25656 var _json = new core.Map(); | |
25657 if (adId != null) { | |
25658 _json["adId"] = adId; | |
25659 } | |
25660 if (clickTag != null) { | |
25661 _json["clickTag"] = clickTag; | |
25662 } | |
25663 if (creativeId != null) { | |
25664 _json["creativeId"] = creativeId; | |
25665 } | |
25666 if (format != null) { | |
25667 _json["format"] = format; | |
25668 } | |
25669 if (impressionTag != null) { | |
25670 _json["impressionTag"] = impressionTag; | |
25671 } | |
25672 return _json; | |
25673 } | |
25674 } | |
25675 | |
25676 /** Tag Settings */ | |
25677 class TagSetting { | |
25678 /** | |
25679 * Additional key-values to be included in tags. Each key-value pair must be | |
25680 * of the form key=value, and pairs must be separated by a semicolon (;). Keys | |
25681 * and values must not contain commas. For example, id=2;color=red is a valid | |
25682 * value for this field. | |
25683 */ | |
25684 core.String additionalKeyValues; | |
25685 /** | |
25686 * Whether static landing page URLs should be included in the tags. This | |
25687 * setting applies only to placements. | |
25688 */ | |
25689 core.bool includeClickThroughUrls; | |
25690 /** Whether click-tracking string should be included in the tags. */ | |
25691 core.bool includeClickTracking; | |
25692 /** | |
25693 * Option specifying how keywords are embedded in ad tags. This setting can be | |
25694 * used to specify whether keyword placeholders are inserted in placement tags | |
25695 * for this site. Publishers can then add keywords to those placeholders. | |
25696 * Possible string values are: | |
25697 * - "GENERATE_SEPARATE_TAG_FOR_EACH_KEYWORD" | |
25698 * - "IGNORE" | |
25699 * - "PLACEHOLDER_WITH_LIST_OF_KEYWORDS" | |
25700 */ | |
25701 core.String keywordOption; | |
25702 | |
25703 TagSetting(); | |
25704 | |
25705 TagSetting.fromJson(core.Map _json) { | |
25706 if (_json.containsKey("additionalKeyValues")) { | |
25707 additionalKeyValues = _json["additionalKeyValues"]; | |
25708 } | |
25709 if (_json.containsKey("includeClickThroughUrls")) { | |
25710 includeClickThroughUrls = _json["includeClickThroughUrls"]; | |
25711 } | |
25712 if (_json.containsKey("includeClickTracking")) { | |
25713 includeClickTracking = _json["includeClickTracking"]; | |
25714 } | |
25715 if (_json.containsKey("keywordOption")) { | |
25716 keywordOption = _json["keywordOption"]; | |
25717 } | |
25718 } | |
25719 | |
25720 core.Map toJson() { | |
25721 var _json = new core.Map(); | |
25722 if (additionalKeyValues != null) { | |
25723 _json["additionalKeyValues"] = additionalKeyValues; | |
25724 } | |
25725 if (includeClickThroughUrls != null) { | |
25726 _json["includeClickThroughUrls"] = includeClickThroughUrls; | |
25727 } | |
25728 if (includeClickTracking != null) { | |
25729 _json["includeClickTracking"] = includeClickTracking; | |
25730 } | |
25731 if (keywordOption != null) { | |
25732 _json["keywordOption"] = keywordOption; | |
25733 } | |
25734 return _json; | |
25735 } | |
25736 } | |
25737 | |
25738 /** Dynamic and Image Tag Settings. */ | |
25739 class TagSettings { | |
25740 /** Whether dynamic floodlight tags are enabled. */ | |
25741 core.bool dynamicTagEnabled; | |
25742 /** Whether image tags are enabled. */ | |
25743 core.bool imageTagEnabled; | |
25744 | |
25745 TagSettings(); | |
25746 | |
25747 TagSettings.fromJson(core.Map _json) { | |
25748 if (_json.containsKey("dynamicTagEnabled")) { | |
25749 dynamicTagEnabled = _json["dynamicTagEnabled"]; | |
25750 } | |
25751 if (_json.containsKey("imageTagEnabled")) { | |
25752 imageTagEnabled = _json["imageTagEnabled"]; | |
25753 } | |
25754 } | |
25755 | |
25756 core.Map toJson() { | |
25757 var _json = new core.Map(); | |
25758 if (dynamicTagEnabled != null) { | |
25759 _json["dynamicTagEnabled"] = dynamicTagEnabled; | |
25760 } | |
25761 if (imageTagEnabled != null) { | |
25762 _json["imageTagEnabled"] = imageTagEnabled; | |
25763 } | |
25764 return _json; | |
25765 } | |
25766 } | |
25767 | |
25768 /** Target Window. */ | |
25769 class TargetWindow { | |
25770 /** User-entered value. */ | |
25771 core.String customHtml; | |
25772 /** | |
25773 * Type of browser window for which the backup image of the flash creative can | |
25774 * be displayed. | |
25775 * Possible string values are: | |
25776 * - "CURRENT_WINDOW" | |
25777 * - "CUSTOM" | |
25778 * - "NEW_WINDOW" | |
25779 */ | |
25780 core.String targetWindowOption; | |
25781 | |
25782 TargetWindow(); | |
25783 | |
25784 TargetWindow.fromJson(core.Map _json) { | |
25785 if (_json.containsKey("customHtml")) { | |
25786 customHtml = _json["customHtml"]; | |
25787 } | |
25788 if (_json.containsKey("targetWindowOption")) { | |
25789 targetWindowOption = _json["targetWindowOption"]; | |
25790 } | |
25791 } | |
25792 | |
25793 core.Map toJson() { | |
25794 var _json = new core.Map(); | |
25795 if (customHtml != null) { | |
25796 _json["customHtml"] = customHtml; | |
25797 } | |
25798 if (targetWindowOption != null) { | |
25799 _json["targetWindowOption"] = targetWindowOption; | |
25800 } | |
25801 return _json; | |
25802 } | |
25803 } | |
25804 | |
25805 /** | |
25806 * Contains properties of a targetable remarketing list. Remarketing enables you | |
25807 * to create lists of users who have performed specific actions on a site, then | |
25808 * target ads to members of those lists. This resource is a read-only view of a | |
25809 * remarketing list to be used to faciliate targeting ads to specific lists. | |
25810 * Remarketing lists that are owned by your advertisers and those that are | |
25811 * shared to your advertisers or account are accessible via this resource. To | |
25812 * manage remarketing lists that are owned by your advertisers, use the | |
25813 * RemarketingLists resource. | |
25814 */ | |
25815 class TargetableRemarketingList { | |
25816 /** | |
25817 * Account ID of this remarketing list. This is a read-only, auto-generated | |
25818 * field that is only returned in GET requests. | |
25819 */ | |
25820 core.String accountId; | |
25821 /** Whether this targetable remarketing list is active. */ | |
25822 core.bool active; | |
25823 /** | |
25824 * Dimension value for the advertiser ID that owns this targetable remarketing | |
25825 * list. | |
25826 */ | |
25827 core.String advertiserId; | |
25828 /** Dimension value for the ID of the advertiser. */ | |
25829 DimensionValue advertiserIdDimensionValue; | |
25830 /** Targetable remarketing list description. */ | |
25831 core.String description; | |
25832 /** Targetable remarketing list ID. */ | |
25833 core.String id; | |
25834 /** | |
25835 * Identifies what kind of resource this is. Value: the fixed string | |
25836 * "dfareporting#targetableRemarketingList". | |
25837 */ | |
25838 core.String kind; | |
25839 /** | |
25840 * Number of days that a user should remain in the targetable remarketing list | |
25841 * without an impression. | |
25842 */ | |
25843 core.String lifeSpan; | |
25844 /** Number of users currently in the list. This is a read-only field. */ | |
25845 core.String listSize; | |
25846 /** | |
25847 * Product from which this targetable remarketing list was originated. | |
25848 * Possible string values are: | |
25849 * - "REMARKETING_LIST_SOURCE_ADX" | |
25850 * - "REMARKETING_LIST_SOURCE_DBM" | |
25851 * - "REMARKETING_LIST_SOURCE_DFA" | |
25852 * - "REMARKETING_LIST_SOURCE_DFP" | |
25853 * - "REMARKETING_LIST_SOURCE_DMP" | |
25854 * - "REMARKETING_LIST_SOURCE_GA" | |
25855 * - "REMARKETING_LIST_SOURCE_GPLUS" | |
25856 * - "REMARKETING_LIST_SOURCE_OTHER" | |
25857 * - "REMARKETING_LIST_SOURCE_PLAY_STORE" | |
25858 * - "REMARKETING_LIST_SOURCE_XFP" | |
25859 * - "REMARKETING_LIST_SOURCE_YOUTUBE" | |
25860 */ | |
25861 core.String listSource; | |
25862 /** | |
25863 * Name of the targetable remarketing list. Is no greater than 128 characters | |
25864 * long. | |
25865 */ | |
25866 core.String name; | |
25867 /** | |
25868 * Subaccount ID of this remarketing list. This is a read-only, auto-generated | |
25869 * field that is only returned in GET requests. | |
25870 */ | |
25871 core.String subaccountId; | |
25872 | |
25873 TargetableRemarketingList(); | |
25874 | |
25875 TargetableRemarketingList.fromJson(core.Map _json) { | |
25876 if (_json.containsKey("accountId")) { | |
25877 accountId = _json["accountId"]; | |
25878 } | |
25879 if (_json.containsKey("active")) { | |
25880 active = _json["active"]; | |
25881 } | |
25882 if (_json.containsKey("advertiserId")) { | |
25883 advertiserId = _json["advertiserId"]; | |
25884 } | |
25885 if (_json.containsKey("advertiserIdDimensionValue")) { | |
25886 advertiserIdDimensionValue = new DimensionValue.fromJson(_json["advertiser
IdDimensionValue"]); | |
25887 } | |
25888 if (_json.containsKey("description")) { | |
25889 description = _json["description"]; | |
25890 } | |
25891 if (_json.containsKey("id")) { | |
25892 id = _json["id"]; | |
25893 } | |
25894 if (_json.containsKey("kind")) { | |
25895 kind = _json["kind"]; | |
25896 } | |
25897 if (_json.containsKey("lifeSpan")) { | |
25898 lifeSpan = _json["lifeSpan"]; | |
25899 } | |
25900 if (_json.containsKey("listSize")) { | |
25901 listSize = _json["listSize"]; | |
25902 } | |
25903 if (_json.containsKey("listSource")) { | |
25904 listSource = _json["listSource"]; | |
25905 } | |
25906 if (_json.containsKey("name")) { | |
25907 name = _json["name"]; | |
25908 } | |
25909 if (_json.containsKey("subaccountId")) { | |
25910 subaccountId = _json["subaccountId"]; | |
25911 } | |
25912 } | |
25913 | |
25914 core.Map toJson() { | |
25915 var _json = new core.Map(); | |
25916 if (accountId != null) { | |
25917 _json["accountId"] = accountId; | |
25918 } | |
25919 if (active != null) { | |
25920 _json["active"] = active; | |
25921 } | |
25922 if (advertiserId != null) { | |
25923 _json["advertiserId"] = advertiserId; | |
25924 } | |
25925 if (advertiserIdDimensionValue != null) { | |
25926 _json["advertiserIdDimensionValue"] = (advertiserIdDimensionValue).toJson(
); | |
25927 } | |
25928 if (description != null) { | |
25929 _json["description"] = description; | |
25930 } | |
25931 if (id != null) { | |
25932 _json["id"] = id; | |
25933 } | |
25934 if (kind != null) { | |
25935 _json["kind"] = kind; | |
25936 } | |
25937 if (lifeSpan != null) { | |
25938 _json["lifeSpan"] = lifeSpan; | |
25939 } | |
25940 if (listSize != null) { | |
25941 _json["listSize"] = listSize; | |
25942 } | |
25943 if (listSource != null) { | |
25944 _json["listSource"] = listSource; | |
25945 } | |
25946 if (name != null) { | |
25947 _json["name"] = name; | |
25948 } | |
25949 if (subaccountId != null) { | |
25950 _json["subaccountId"] = subaccountId; | |
25951 } | |
25952 return _json; | |
25953 } | |
25954 } | |
25955 | |
25956 /** Targetable remarketing list response */ | |
25957 class TargetableRemarketingListsListResponse { | |
25958 /** | |
25959 * Identifies what kind of resource this is. Value: the fixed string | |
25960 * "dfareporting#targetableRemarketingListsListResponse". | |
25961 */ | |
25962 core.String kind; | |
25963 /** Pagination token to be used for the next list operation. */ | |
25964 core.String nextPageToken; | |
25965 /** Targetable remarketing list collection. */ | |
25966 core.List<TargetableRemarketingList> targetableRemarketingLists; | |
25967 | |
25968 TargetableRemarketingListsListResponse(); | |
25969 | |
25970 TargetableRemarketingListsListResponse.fromJson(core.Map _json) { | |
25971 if (_json.containsKey("kind")) { | |
25972 kind = _json["kind"]; | |
25973 } | |
25974 if (_json.containsKey("nextPageToken")) { | |
25975 nextPageToken = _json["nextPageToken"]; | |
25976 } | |
25977 if (_json.containsKey("targetableRemarketingLists")) { | |
25978 targetableRemarketingLists = _json["targetableRemarketingLists"].map((valu
e) => new TargetableRemarketingList.fromJson(value)).toList(); | |
25979 } | |
25980 } | |
25981 | |
25982 core.Map toJson() { | |
25983 var _json = new core.Map(); | |
25984 if (kind != null) { | |
25985 _json["kind"] = kind; | |
25986 } | |
25987 if (nextPageToken != null) { | |
25988 _json["nextPageToken"] = nextPageToken; | |
25989 } | |
25990 if (targetableRemarketingLists != null) { | |
25991 _json["targetableRemarketingLists"] = targetableRemarketingLists.map((valu
e) => (value).toJson()).toList(); | |
25992 } | |
25993 return _json; | |
25994 } | |
25995 } | |
25996 | |
25997 /** Technology Targeting. */ | |
25998 class TechnologyTargeting { | |
25999 /** | |
26000 * Browsers that this ad targets. For each browser either set browserVersionId | |
26001 * or dartId along with the version numbers. If both are specified, only | |
26002 * browserVersionId will be used. The other fields are populated automatically | |
26003 * when the ad is inserted or updated. | |
26004 */ | |
26005 core.List<Browser> browsers; | |
26006 /** | |
26007 * Connection types that this ad targets. For each connection type only id is | |
26008 * required. The other fields are populated automatically when the ad is | |
26009 * inserted or updated. | |
26010 */ | |
26011 core.List<ConnectionType> connectionTypes; | |
26012 /** | |
26013 * Mobile carriers that this ad targets. For each mobile carrier only id is | |
26014 * required, and the other fields are populated automatically when the ad is | |
26015 * inserted or updated. If targeting a mobile carrier, do not set targeting | |
26016 * for any zip codes. | |
26017 */ | |
26018 core.List<MobileCarrier> mobileCarriers; | |
26019 /** | |
26020 * Operating system versions that this ad targets. To target all versions, use | |
26021 * operatingSystems. For each operating system version, only id is required. | |
26022 * The other fields are populated automatically when the ad is inserted or | |
26023 * updated. If targeting an operating system version, do not set targeting for | |
26024 * the corresponding operating system in operatingSystems. | |
26025 */ | |
26026 core.List<OperatingSystemVersion> operatingSystemVersions; | |
26027 /** | |
26028 * Operating systems that this ad targets. To target specific versions, use | |
26029 * operatingSystemVersions. For each operating system only dartId is required. | |
26030 * The other fields are populated automatically when the ad is inserted or | |
26031 * updated. If targeting an operating system, do not set targeting for | |
26032 * operating system versions for the same operating system. | |
26033 */ | |
26034 core.List<OperatingSystem> operatingSystems; | |
26035 /** | |
26036 * Platform types that this ad targets. For example, desktop, mobile, or | |
26037 * tablet. For each platform type, only id is required, and the other fields | |
26038 * are populated automatically when the ad is inserted or updated. | |
26039 */ | |
26040 core.List<PlatformType> platformTypes; | |
26041 | |
26042 TechnologyTargeting(); | |
26043 | |
26044 TechnologyTargeting.fromJson(core.Map _json) { | |
26045 if (_json.containsKey("browsers")) { | |
26046 browsers = _json["browsers"].map((value) => new Browser.fromJson(value)).t
oList(); | |
26047 } | |
26048 if (_json.containsKey("connectionTypes")) { | |
26049 connectionTypes = _json["connectionTypes"].map((value) => new ConnectionTy
pe.fromJson(value)).toList(); | |
26050 } | |
26051 if (_json.containsKey("mobileCarriers")) { | |
26052 mobileCarriers = _json["mobileCarriers"].map((value) => new MobileCarrier.
fromJson(value)).toList(); | |
26053 } | |
26054 if (_json.containsKey("operatingSystemVersions")) { | |
26055 operatingSystemVersions = _json["operatingSystemVersions"].map((value) =>
new OperatingSystemVersion.fromJson(value)).toList(); | |
26056 } | |
26057 if (_json.containsKey("operatingSystems")) { | |
26058 operatingSystems = _json["operatingSystems"].map((value) => new OperatingS
ystem.fromJson(value)).toList(); | |
26059 } | |
26060 if (_json.containsKey("platformTypes")) { | |
26061 platformTypes = _json["platformTypes"].map((value) => new PlatformType.fro
mJson(value)).toList(); | |
26062 } | |
26063 } | |
26064 | |
26065 core.Map toJson() { | |
26066 var _json = new core.Map(); | |
26067 if (browsers != null) { | |
26068 _json["browsers"] = browsers.map((value) => (value).toJson()).toList(); | |
26069 } | |
26070 if (connectionTypes != null) { | |
26071 _json["connectionTypes"] = connectionTypes.map((value) => (value).toJson()
).toList(); | |
26072 } | |
26073 if (mobileCarriers != null) { | |
26074 _json["mobileCarriers"] = mobileCarriers.map((value) => (value).toJson()).
toList(); | |
26075 } | |
26076 if (operatingSystemVersions != null) { | |
26077 _json["operatingSystemVersions"] = operatingSystemVersions.map((value) =>
(value).toJson()).toList(); | |
26078 } | |
26079 if (operatingSystems != null) { | |
26080 _json["operatingSystems"] = operatingSystems.map((value) => (value).toJson
()).toList(); | |
26081 } | |
26082 if (platformTypes != null) { | |
26083 _json["platformTypes"] = platformTypes.map((value) => (value).toJson()).to
List(); | |
26084 } | |
26085 return _json; | |
26086 } | |
26087 } | |
26088 | |
26089 /** Third Party Authentication Token */ | |
26090 class ThirdPartyAuthenticationToken { | |
26091 /** Name of the third-party authentication token. */ | |
26092 core.String name; | |
26093 /** | |
26094 * Value of the third-party authentication token. This is a read-only, | |
26095 * auto-generated field. | |
26096 */ | |
26097 core.String value; | |
26098 | |
26099 ThirdPartyAuthenticationToken(); | |
26100 | |
26101 ThirdPartyAuthenticationToken.fromJson(core.Map _json) { | |
26102 if (_json.containsKey("name")) { | |
26103 name = _json["name"]; | |
26104 } | |
26105 if (_json.containsKey("value")) { | |
26106 value = _json["value"]; | |
26107 } | |
26108 } | |
26109 | |
26110 core.Map toJson() { | |
26111 var _json = new core.Map(); | |
26112 if (name != null) { | |
26113 _json["name"] = name; | |
26114 } | |
26115 if (value != null) { | |
26116 _json["value"] = value; | |
26117 } | |
26118 return _json; | |
26119 } | |
26120 } | |
26121 | |
26122 /** Third-party Tracking URL. */ | |
26123 class ThirdPartyTrackingUrl { | |
26124 /** | |
26125 * Third-party URL type for in-stream video creatives. | |
26126 * Possible string values are: | |
26127 * - "CLICK_TRACKING" | |
26128 * - "IMPRESSION" | |
26129 * - "RICH_MEDIA_BACKUP_IMPRESSION" | |
26130 * - "RICH_MEDIA_IMPRESSION" | |
26131 * - "RICH_MEDIA_RM_IMPRESSION" | |
26132 * - "SURVEY" | |
26133 * - "VIDEO_COMPLETE" | |
26134 * - "VIDEO_CUSTOM" | |
26135 * - "VIDEO_FIRST_QUARTILE" | |
26136 * - "VIDEO_FULLSCREEN" | |
26137 * - "VIDEO_MIDPOINT" | |
26138 * - "VIDEO_MUTE" | |
26139 * - "VIDEO_PAUSE" | |
26140 * - "VIDEO_PROGRESS" | |
26141 * - "VIDEO_REWIND" | |
26142 * - "VIDEO_SKIP" | |
26143 * - "VIDEO_START" | |
26144 * - "VIDEO_STOP" | |
26145 * - "VIDEO_THIRD_QUARTILE" | |
26146 */ | |
26147 core.String thirdPartyUrlType; | |
26148 /** URL for the specified third-party URL type. */ | |
26149 core.String url; | |
26150 | |
26151 ThirdPartyTrackingUrl(); | |
26152 | |
26153 ThirdPartyTrackingUrl.fromJson(core.Map _json) { | |
26154 if (_json.containsKey("thirdPartyUrlType")) { | |
26155 thirdPartyUrlType = _json["thirdPartyUrlType"]; | |
26156 } | |
26157 if (_json.containsKey("url")) { | |
26158 url = _json["url"]; | |
26159 } | |
26160 } | |
26161 | |
26162 core.Map toJson() { | |
26163 var _json = new core.Map(); | |
26164 if (thirdPartyUrlType != null) { | |
26165 _json["thirdPartyUrlType"] = thirdPartyUrlType; | |
26166 } | |
26167 if (url != null) { | |
26168 _json["url"] = url; | |
26169 } | |
26170 return _json; | |
26171 } | |
26172 } | |
26173 | |
26174 /** User Defined Variable configuration. */ | |
26175 class UserDefinedVariableConfiguration { | |
26176 /** | |
26177 * Data type for the variable. This is a required field. | |
26178 * Possible string values are: | |
26179 * - "NUMBER" | |
26180 * - "STRING" | |
26181 */ | |
26182 core.String dataType; | |
26183 /** | |
26184 * User-friendly name for the variable which will appear in reports. This is a | |
26185 * required field, must be less than 64 characters long, and cannot contain | |
26186 * the following characters: ""<>". | |
26187 */ | |
26188 core.String reportName; | |
26189 /** | |
26190 * Variable name in the tag. This is a required field. | |
26191 * Possible string values are: | |
26192 * - "U1" | |
26193 * - "U10" | |
26194 * - "U100" | |
26195 * - "U11" | |
26196 * - "U12" | |
26197 * - "U13" | |
26198 * - "U14" | |
26199 * - "U15" | |
26200 * - "U16" | |
26201 * - "U17" | |
26202 * - "U18" | |
26203 * - "U19" | |
26204 * - "U2" | |
26205 * - "U20" | |
26206 * - "U21" | |
26207 * - "U22" | |
26208 * - "U23" | |
26209 * - "U24" | |
26210 * - "U25" | |
26211 * - "U26" | |
26212 * - "U27" | |
26213 * - "U28" | |
26214 * - "U29" | |
26215 * - "U3" | |
26216 * - "U30" | |
26217 * - "U31" | |
26218 * - "U32" | |
26219 * - "U33" | |
26220 * - "U34" | |
26221 * - "U35" | |
26222 * - "U36" | |
26223 * - "U37" | |
26224 * - "U38" | |
26225 * - "U39" | |
26226 * - "U4" | |
26227 * - "U40" | |
26228 * - "U41" | |
26229 * - "U42" | |
26230 * - "U43" | |
26231 * - "U44" | |
26232 * - "U45" | |
26233 * - "U46" | |
26234 * - "U47" | |
26235 * - "U48" | |
26236 * - "U49" | |
26237 * - "U5" | |
26238 * - "U50" | |
26239 * - "U51" | |
26240 * - "U52" | |
26241 * - "U53" | |
26242 * - "U54" | |
26243 * - "U55" | |
26244 * - "U56" | |
26245 * - "U57" | |
26246 * - "U58" | |
26247 * - "U59" | |
26248 * - "U6" | |
26249 * - "U60" | |
26250 * - "U61" | |
26251 * - "U62" | |
26252 * - "U63" | |
26253 * - "U64" | |
26254 * - "U65" | |
26255 * - "U66" | |
26256 * - "U67" | |
26257 * - "U68" | |
26258 * - "U69" | |
26259 * - "U7" | |
26260 * - "U70" | |
26261 * - "U71" | |
26262 * - "U72" | |
26263 * - "U73" | |
26264 * - "U74" | |
26265 * - "U75" | |
26266 * - "U76" | |
26267 * - "U77" | |
26268 * - "U78" | |
26269 * - "U79" | |
26270 * - "U8" | |
26271 * - "U80" | |
26272 * - "U81" | |
26273 * - "U82" | |
26274 * - "U83" | |
26275 * - "U84" | |
26276 * - "U85" | |
26277 * - "U86" | |
26278 * - "U87" | |
26279 * - "U88" | |
26280 * - "U89" | |
26281 * - "U9" | |
26282 * - "U90" | |
26283 * - "U91" | |
26284 * - "U92" | |
26285 * - "U93" | |
26286 * - "U94" | |
26287 * - "U95" | |
26288 * - "U96" | |
26289 * - "U97" | |
26290 * - "U98" | |
26291 * - "U99" | |
26292 */ | |
26293 core.String variableType; | |
26294 | |
26295 UserDefinedVariableConfiguration(); | |
26296 | |
26297 UserDefinedVariableConfiguration.fromJson(core.Map _json) { | |
26298 if (_json.containsKey("dataType")) { | |
26299 dataType = _json["dataType"]; | |
26300 } | |
26301 if (_json.containsKey("reportName")) { | |
26302 reportName = _json["reportName"]; | |
26303 } | |
26304 if (_json.containsKey("variableType")) { | |
26305 variableType = _json["variableType"]; | |
26306 } | |
26307 } | |
26308 | |
26309 core.Map toJson() { | |
26310 var _json = new core.Map(); | |
26311 if (dataType != null) { | |
26312 _json["dataType"] = dataType; | |
26313 } | |
26314 if (reportName != null) { | |
26315 _json["reportName"] = reportName; | |
26316 } | |
26317 if (variableType != null) { | |
26318 _json["variableType"] = variableType; | |
26319 } | |
26320 return _json; | |
26321 } | |
26322 } | |
26323 | |
26324 /** Represents a UserProfile resource. */ | |
26325 class UserProfile { | |
26326 /** The account ID to which this profile belongs. */ | |
26327 core.String accountId; | |
26328 /** The account name this profile belongs to. */ | |
26329 core.String accountName; | |
26330 /** The eTag of this response for caching purposes. */ | |
26331 core.String etag; | |
26332 /** The kind of resource this is, in this case dfareporting#userProfile. */ | |
26333 core.String kind; | |
26334 /** The unique ID of the user profile. */ | |
26335 core.String profileId; | |
26336 /** The sub account ID this profile belongs to if applicable. */ | |
26337 core.String subAccountId; | |
26338 /** The sub account name this profile belongs to if applicable. */ | |
26339 core.String subAccountName; | |
26340 /** The user name. */ | |
26341 core.String userName; | |
26342 | |
26343 UserProfile(); | |
26344 | |
26345 UserProfile.fromJson(core.Map _json) { | |
26346 if (_json.containsKey("accountId")) { | |
26347 accountId = _json["accountId"]; | |
26348 } | |
26349 if (_json.containsKey("accountName")) { | |
26350 accountName = _json["accountName"]; | |
26351 } | |
26352 if (_json.containsKey("etag")) { | |
26353 etag = _json["etag"]; | |
26354 } | |
26355 if (_json.containsKey("kind")) { | |
26356 kind = _json["kind"]; | |
26357 } | |
26358 if (_json.containsKey("profileId")) { | |
26359 profileId = _json["profileId"]; | |
26360 } | |
26361 if (_json.containsKey("subAccountId")) { | |
26362 subAccountId = _json["subAccountId"]; | |
26363 } | |
26364 if (_json.containsKey("subAccountName")) { | |
26365 subAccountName = _json["subAccountName"]; | |
26366 } | |
26367 if (_json.containsKey("userName")) { | |
26368 userName = _json["userName"]; | |
26369 } | |
26370 } | |
26371 | |
26372 core.Map toJson() { | |
26373 var _json = new core.Map(); | |
26374 if (accountId != null) { | |
26375 _json["accountId"] = accountId; | |
26376 } | |
26377 if (accountName != null) { | |
26378 _json["accountName"] = accountName; | |
26379 } | |
26380 if (etag != null) { | |
26381 _json["etag"] = etag; | |
26382 } | |
26383 if (kind != null) { | |
26384 _json["kind"] = kind; | |
26385 } | |
26386 if (profileId != null) { | |
26387 _json["profileId"] = profileId; | |
26388 } | |
26389 if (subAccountId != null) { | |
26390 _json["subAccountId"] = subAccountId; | |
26391 } | |
26392 if (subAccountName != null) { | |
26393 _json["subAccountName"] = subAccountName; | |
26394 } | |
26395 if (userName != null) { | |
26396 _json["userName"] = userName; | |
26397 } | |
26398 return _json; | |
26399 } | |
26400 } | |
26401 | |
26402 /** Represents the list of user profiles. */ | |
26403 class UserProfileList { | |
26404 /** The eTag of this response for caching purposes. */ | |
26405 core.String etag; | |
26406 /** The user profiles returned in this response. */ | |
26407 core.List<UserProfile> items; | |
26408 /** The kind of list this is, in this case dfareporting#userProfileList. */ | |
26409 core.String kind; | |
26410 | |
26411 UserProfileList(); | |
26412 | |
26413 UserProfileList.fromJson(core.Map _json) { | |
26414 if (_json.containsKey("etag")) { | |
26415 etag = _json["etag"]; | |
26416 } | |
26417 if (_json.containsKey("items")) { | |
26418 items = _json["items"].map((value) => new UserProfile.fromJson(value)).toL
ist(); | |
26419 } | |
26420 if (_json.containsKey("kind")) { | |
26421 kind = _json["kind"]; | |
26422 } | |
26423 } | |
26424 | |
26425 core.Map toJson() { | |
26426 var _json = new core.Map(); | |
26427 if (etag != null) { | |
26428 _json["etag"] = etag; | |
26429 } | |
26430 if (items != null) { | |
26431 _json["items"] = items.map((value) => (value).toJson()).toList(); | |
26432 } | |
26433 if (kind != null) { | |
26434 _json["kind"] = kind; | |
26435 } | |
26436 return _json; | |
26437 } | |
26438 } | |
26439 | |
26440 /** Contains properties of auser role, which is used to manage user access. */ | |
26441 class UserRole { | |
26442 /** | |
26443 * Account ID of this user role. This is a read-only field that can be left | |
26444 * blank. | |
26445 */ | |
26446 core.String accountId; | |
26447 /** | |
26448 * Whether this is a default user role. Default user roles are created by the | |
26449 * system for the account/subaccount and cannot be modified or deleted. Each | |
26450 * default user role comes with a basic set of preassigned permissions. | |
26451 */ | |
26452 core.bool defaultUserRole; | |
26453 /** ID of this user role. This is a read-only, auto-generated field. */ | |
26454 core.String id; | |
26455 /** | |
26456 * Identifies what kind of resource this is. Value: the fixed string | |
26457 * "dfareporting#userRole". | |
26458 */ | |
26459 core.String kind; | |
26460 /** | |
26461 * Name of this user role. This is a required field. Must be less than 256 | |
26462 * characters long. If this user role is under a subaccount, the name must be | |
26463 * unique among sites of the same subaccount. Otherwise, this user role is a | |
26464 * top-level user role, and the name must be unique among top-level user roles | |
26465 * of the same account. | |
26466 */ | |
26467 core.String name; | |
26468 /** | |
26469 * ID of the user role that this user role is based on or copied from. This is | |
26470 * a required field. | |
26471 */ | |
26472 core.String parentUserRoleId; | |
26473 /** List of permissions associated with this user role. */ | |
26474 core.List<UserRolePermission> permissions; | |
26475 /** | |
26476 * Subaccount ID of this user role. This is a read-only field that can be left | |
26477 * blank. | |
26478 */ | |
26479 core.String subaccountId; | |
26480 | |
26481 UserRole(); | |
26482 | |
26483 UserRole.fromJson(core.Map _json) { | |
26484 if (_json.containsKey("accountId")) { | |
26485 accountId = _json["accountId"]; | |
26486 } | |
26487 if (_json.containsKey("defaultUserRole")) { | |
26488 defaultUserRole = _json["defaultUserRole"]; | |
26489 } | |
26490 if (_json.containsKey("id")) { | |
26491 id = _json["id"]; | |
26492 } | |
26493 if (_json.containsKey("kind")) { | |
26494 kind = _json["kind"]; | |
26495 } | |
26496 if (_json.containsKey("name")) { | |
26497 name = _json["name"]; | |
26498 } | |
26499 if (_json.containsKey("parentUserRoleId")) { | |
26500 parentUserRoleId = _json["parentUserRoleId"]; | |
26501 } | |
26502 if (_json.containsKey("permissions")) { | |
26503 permissions = _json["permissions"].map((value) => new UserRolePermission.f
romJson(value)).toList(); | |
26504 } | |
26505 if (_json.containsKey("subaccountId")) { | |
26506 subaccountId = _json["subaccountId"]; | |
26507 } | |
26508 } | |
26509 | |
26510 core.Map toJson() { | |
26511 var _json = new core.Map(); | |
26512 if (accountId != null) { | |
26513 _json["accountId"] = accountId; | |
26514 } | |
26515 if (defaultUserRole != null) { | |
26516 _json["defaultUserRole"] = defaultUserRole; | |
26517 } | |
26518 if (id != null) { | |
26519 _json["id"] = id; | |
26520 } | |
26521 if (kind != null) { | |
26522 _json["kind"] = kind; | |
26523 } | |
26524 if (name != null) { | |
26525 _json["name"] = name; | |
26526 } | |
26527 if (parentUserRoleId != null) { | |
26528 _json["parentUserRoleId"] = parentUserRoleId; | |
26529 } | |
26530 if (permissions != null) { | |
26531 _json["permissions"] = permissions.map((value) => (value).toJson()).toList
(); | |
26532 } | |
26533 if (subaccountId != null) { | |
26534 _json["subaccountId"] = subaccountId; | |
26535 } | |
26536 return _json; | |
26537 } | |
26538 } | |
26539 | |
26540 /** Contains properties of a user role permission. */ | |
26541 class UserRolePermission { | |
26542 /** | |
26543 * Levels of availability for a user role permission. | |
26544 * Possible string values are: | |
26545 * - "ACCOUNT_ALWAYS" | |
26546 * - "ACCOUNT_BY_DEFAULT" | |
26547 * - "NOT_AVAILABLE_BY_DEFAULT" | |
26548 * - "SUBACCOUNT_AND_ACCOUNT_ALWAYS" | |
26549 * - "SUBACCOUNT_AND_ACCOUNT_BY_DEFAULT" | |
26550 */ | |
26551 core.String availability; | |
26552 /** ID of this user role permission. */ | |
26553 core.String id; | |
26554 /** | |
26555 * Identifies what kind of resource this is. Value: the fixed string | |
26556 * "dfareporting#userRolePermission". | |
26557 */ | |
26558 core.String kind; | |
26559 /** Name of this user role permission. */ | |
26560 core.String name; | |
26561 /** ID of the permission group that this user role permission belongs to. */ | |
26562 core.String permissionGroupId; | |
26563 | |
26564 UserRolePermission(); | |
26565 | |
26566 UserRolePermission.fromJson(core.Map _json) { | |
26567 if (_json.containsKey("availability")) { | |
26568 availability = _json["availability"]; | |
26569 } | |
26570 if (_json.containsKey("id")) { | |
26571 id = _json["id"]; | |
26572 } | |
26573 if (_json.containsKey("kind")) { | |
26574 kind = _json["kind"]; | |
26575 } | |
26576 if (_json.containsKey("name")) { | |
26577 name = _json["name"]; | |
26578 } | |
26579 if (_json.containsKey("permissionGroupId")) { | |
26580 permissionGroupId = _json["permissionGroupId"]; | |
26581 } | |
26582 } | |
26583 | |
26584 core.Map toJson() { | |
26585 var _json = new core.Map(); | |
26586 if (availability != null) { | |
26587 _json["availability"] = availability; | |
26588 } | |
26589 if (id != null) { | |
26590 _json["id"] = id; | |
26591 } | |
26592 if (kind != null) { | |
26593 _json["kind"] = kind; | |
26594 } | |
26595 if (name != null) { | |
26596 _json["name"] = name; | |
26597 } | |
26598 if (permissionGroupId != null) { | |
26599 _json["permissionGroupId"] = permissionGroupId; | |
26600 } | |
26601 return _json; | |
26602 } | |
26603 } | |
26604 | |
26605 /** Represents a grouping of related user role permissions. */ | |
26606 class UserRolePermissionGroup { | |
26607 /** ID of this user role permission. */ | |
26608 core.String id; | |
26609 /** | |
26610 * Identifies what kind of resource this is. Value: the fixed string | |
26611 * "dfareporting#userRolePermissionGroup". | |
26612 */ | |
26613 core.String kind; | |
26614 /** Name of this user role permission group. */ | |
26615 core.String name; | |
26616 | |
26617 UserRolePermissionGroup(); | |
26618 | |
26619 UserRolePermissionGroup.fromJson(core.Map _json) { | |
26620 if (_json.containsKey("id")) { | |
26621 id = _json["id"]; | |
26622 } | |
26623 if (_json.containsKey("kind")) { | |
26624 kind = _json["kind"]; | |
26625 } | |
26626 if (_json.containsKey("name")) { | |
26627 name = _json["name"]; | |
26628 } | |
26629 } | |
26630 | |
26631 core.Map toJson() { | |
26632 var _json = new core.Map(); | |
26633 if (id != null) { | |
26634 _json["id"] = id; | |
26635 } | |
26636 if (kind != null) { | |
26637 _json["kind"] = kind; | |
26638 } | |
26639 if (name != null) { | |
26640 _json["name"] = name; | |
26641 } | |
26642 return _json; | |
26643 } | |
26644 } | |
26645 | |
26646 /** User Role Permission Group List Response */ | |
26647 class UserRolePermissionGroupsListResponse { | |
26648 /** | |
26649 * Identifies what kind of resource this is. Value: the fixed string | |
26650 * "dfareporting#userRolePermissionGroupsListResponse". | |
26651 */ | |
26652 core.String kind; | |
26653 /** User role permission group collection. */ | |
26654 core.List<UserRolePermissionGroup> userRolePermissionGroups; | |
26655 | |
26656 UserRolePermissionGroupsListResponse(); | |
26657 | |
26658 UserRolePermissionGroupsListResponse.fromJson(core.Map _json) { | |
26659 if (_json.containsKey("kind")) { | |
26660 kind = _json["kind"]; | |
26661 } | |
26662 if (_json.containsKey("userRolePermissionGroups")) { | |
26663 userRolePermissionGroups = _json["userRolePermissionGroups"].map((value) =
> new UserRolePermissionGroup.fromJson(value)).toList(); | |
26664 } | |
26665 } | |
26666 | |
26667 core.Map toJson() { | |
26668 var _json = new core.Map(); | |
26669 if (kind != null) { | |
26670 _json["kind"] = kind; | |
26671 } | |
26672 if (userRolePermissionGroups != null) { | |
26673 _json["userRolePermissionGroups"] = userRolePermissionGroups.map((value) =
> (value).toJson()).toList(); | |
26674 } | |
26675 return _json; | |
26676 } | |
26677 } | |
26678 | |
26679 /** User Role Permission List Response */ | |
26680 class UserRolePermissionsListResponse { | |
26681 /** | |
26682 * Identifies what kind of resource this is. Value: the fixed string | |
26683 * "dfareporting#userRolePermissionsListResponse". | |
26684 */ | |
26685 core.String kind; | |
26686 /** User role permission collection. */ | |
26687 core.List<UserRolePermission> userRolePermissions; | |
26688 | |
26689 UserRolePermissionsListResponse(); | |
26690 | |
26691 UserRolePermissionsListResponse.fromJson(core.Map _json) { | |
26692 if (_json.containsKey("kind")) { | |
26693 kind = _json["kind"]; | |
26694 } | |
26695 if (_json.containsKey("userRolePermissions")) { | |
26696 userRolePermissions = _json["userRolePermissions"].map((value) => new User
RolePermission.fromJson(value)).toList(); | |
26697 } | |
26698 } | |
26699 | |
26700 core.Map toJson() { | |
26701 var _json = new core.Map(); | |
26702 if (kind != null) { | |
26703 _json["kind"] = kind; | |
26704 } | |
26705 if (userRolePermissions != null) { | |
26706 _json["userRolePermissions"] = userRolePermissions.map((value) => (value).
toJson()).toList(); | |
26707 } | |
26708 return _json; | |
26709 } | |
26710 } | |
26711 | |
26712 /** User Role List Response */ | |
26713 class UserRolesListResponse { | |
26714 /** | |
26715 * Identifies what kind of resource this is. Value: the fixed string | |
26716 * "dfareporting#userRolesListResponse". | |
26717 */ | |
26718 core.String kind; | |
26719 /** Pagination token to be used for the next list operation. */ | |
26720 core.String nextPageToken; | |
26721 /** User role collection. */ | |
26722 core.List<UserRole> userRoles; | |
26723 | |
26724 UserRolesListResponse(); | |
26725 | |
26726 UserRolesListResponse.fromJson(core.Map _json) { | |
26727 if (_json.containsKey("kind")) { | |
26728 kind = _json["kind"]; | |
26729 } | |
26730 if (_json.containsKey("nextPageToken")) { | |
26731 nextPageToken = _json["nextPageToken"]; | |
26732 } | |
26733 if (_json.containsKey("userRoles")) { | |
26734 userRoles = _json["userRoles"].map((value) => new UserRole.fromJson(value)
).toList(); | |
26735 } | |
26736 } | |
26737 | |
26738 core.Map toJson() { | |
26739 var _json = new core.Map(); | |
26740 if (kind != null) { | |
26741 _json["kind"] = kind; | |
26742 } | |
26743 if (nextPageToken != null) { | |
26744 _json["nextPageToken"] = nextPageToken; | |
26745 } | |
26746 if (userRoles != null) { | |
26747 _json["userRoles"] = userRoles.map((value) => (value).toJson()).toList(); | |
26748 } | |
26749 return _json; | |
26750 } | |
26751 } | |
OLD | NEW |