1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42 package dfareporting
43
44 import (
45 "bytes"
46 "context"
47 "encoding/json"
48 "errors"
49 "fmt"
50 "io"
51 "net/http"
52 "net/url"
53 "strconv"
54 "strings"
55
56 googleapi "google.golang.org/api/googleapi"
57 gensupport "google.golang.org/api/internal/gensupport"
58 option "google.golang.org/api/option"
59 htransport "google.golang.org/api/transport/http"
60 )
61
62
63
64 var _ = bytes.NewBuffer
65 var _ = strconv.Itoa
66 var _ = fmt.Sprintf
67 var _ = json.NewDecoder
68 var _ = io.Copy
69 var _ = url.Parse
70 var _ = gensupport.MarshalJSON
71 var _ = googleapi.Version
72 var _ = errors.New
73 var _ = strings.Replace
74 var _ = context.Canceled
75
76 const apiId = "dfareporting:v3.2"
77 const apiName = "dfareporting"
78 const apiVersion = "v3.2"
79 const basePath = "https://www.googleapis.com/dfareporting/v3.2/"
80
81
82 const (
83
84 DdmconversionsScope = "https://www.googleapis.com/auth/ddmconversions"
85
86
87 DfareportingScope = "https://www.googleapis.com/auth/dfareporting"
88
89
90
91 DfatraffickingScope = "https://www.googleapis.com/auth/dfatrafficking"
92 )
93
94
95 func NewService(ctx context.Context, opts ...option.ClientOption) (*Service, error) {
96 scopesOption := option.WithScopes(
97 "https://www.googleapis.com/auth/ddmconversions",
98 "https://www.googleapis.com/auth/dfareporting",
99 "https://www.googleapis.com/auth/dfatrafficking",
100 )
101
102 opts = append([]option.ClientOption{scopesOption}, opts...)
103 client, endpoint, err := htransport.NewClient(ctx, opts...)
104 if err != nil {
105 return nil, err
106 }
107 s, err := New(client)
108 if err != nil {
109 return nil, err
110 }
111 if endpoint != "" {
112 s.BasePath = endpoint
113 }
114 return s, nil
115 }
116
117
118
119
120
121
122 func New(client *http.Client) (*Service, error) {
123 if client == nil {
124 return nil, errors.New("client is nil")
125 }
126 s := &Service{client: client, BasePath: basePath}
127 s.AccountActiveAdSummaries = NewAccountActiveAdSummariesService(s)
128 s.AccountPermissionGroups = NewAccountPermissionGroupsService(s)
129 s.AccountPermissions = NewAccountPermissionsService(s)
130 s.AccountUserProfiles = NewAccountUserProfilesService(s)
131 s.Accounts = NewAccountsService(s)
132 s.Ads = NewAdsService(s)
133 s.AdvertiserGroups = NewAdvertiserGroupsService(s)
134 s.AdvertiserLandingPages = NewAdvertiserLandingPagesService(s)
135 s.Advertisers = NewAdvertisersService(s)
136 s.Browsers = NewBrowsersService(s)
137 s.CampaignCreativeAssociations = NewCampaignCreativeAssociationsService(s)
138 s.Campaigns = NewCampaignsService(s)
139 s.ChangeLogs = NewChangeLogsService(s)
140 s.Cities = NewCitiesService(s)
141 s.ConnectionTypes = NewConnectionTypesService(s)
142 s.ContentCategories = NewContentCategoriesService(s)
143 s.Conversions = NewConversionsService(s)
144 s.Countries = NewCountriesService(s)
145 s.CreativeAssets = NewCreativeAssetsService(s)
146 s.CreativeFieldValues = NewCreativeFieldValuesService(s)
147 s.CreativeFields = NewCreativeFieldsService(s)
148 s.CreativeGroups = NewCreativeGroupsService(s)
149 s.Creatives = NewCreativesService(s)
150 s.DimensionValues = NewDimensionValuesService(s)
151 s.DirectorySiteContacts = NewDirectorySiteContactsService(s)
152 s.DirectorySites = NewDirectorySitesService(s)
153 s.DynamicTargetingKeys = NewDynamicTargetingKeysService(s)
154 s.EventTags = NewEventTagsService(s)
155 s.Files = NewFilesService(s)
156 s.FloodlightActivities = NewFloodlightActivitiesService(s)
157 s.FloodlightActivityGroups = NewFloodlightActivityGroupsService(s)
158 s.FloodlightConfigurations = NewFloodlightConfigurationsService(s)
159 s.InventoryItems = NewInventoryItemsService(s)
160 s.Languages = NewLanguagesService(s)
161 s.Metros = NewMetrosService(s)
162 s.MobileApps = NewMobileAppsService(s)
163 s.MobileCarriers = NewMobileCarriersService(s)
164 s.OperatingSystemVersions = NewOperatingSystemVersionsService(s)
165 s.OperatingSystems = NewOperatingSystemsService(s)
166 s.OrderDocuments = NewOrderDocumentsService(s)
167 s.Orders = NewOrdersService(s)
168 s.PlacementGroups = NewPlacementGroupsService(s)
169 s.PlacementStrategies = NewPlacementStrategiesService(s)
170 s.Placements = NewPlacementsService(s)
171 s.PlatformTypes = NewPlatformTypesService(s)
172 s.PostalCodes = NewPostalCodesService(s)
173 s.Projects = NewProjectsService(s)
174 s.Regions = NewRegionsService(s)
175 s.RemarketingListShares = NewRemarketingListSharesService(s)
176 s.RemarketingLists = NewRemarketingListsService(s)
177 s.Reports = NewReportsService(s)
178 s.Sites = NewSitesService(s)
179 s.Sizes = NewSizesService(s)
180 s.Subaccounts = NewSubaccountsService(s)
181 s.TargetableRemarketingLists = NewTargetableRemarketingListsService(s)
182 s.TargetingTemplates = NewTargetingTemplatesService(s)
183 s.UserProfiles = NewUserProfilesService(s)
184 s.UserRolePermissionGroups = NewUserRolePermissionGroupsService(s)
185 s.UserRolePermissions = NewUserRolePermissionsService(s)
186 s.UserRoles = NewUserRolesService(s)
187 s.VideoFormats = NewVideoFormatsService(s)
188 return s, nil
189 }
190
191 type Service struct {
192 client *http.Client
193 BasePath string
194 UserAgent string
195
196 AccountActiveAdSummaries *AccountActiveAdSummariesService
197
198 AccountPermissionGroups *AccountPermissionGroupsService
199
200 AccountPermissions *AccountPermissionsService
201
202 AccountUserProfiles *AccountUserProfilesService
203
204 Accounts *AccountsService
205
206 Ads *AdsService
207
208 AdvertiserGroups *AdvertiserGroupsService
209
210 AdvertiserLandingPages *AdvertiserLandingPagesService
211
212 Advertisers *AdvertisersService
213
214 Browsers *BrowsersService
215
216 CampaignCreativeAssociations *CampaignCreativeAssociationsService
217
218 Campaigns *CampaignsService
219
220 ChangeLogs *ChangeLogsService
221
222 Cities *CitiesService
223
224 ConnectionTypes *ConnectionTypesService
225
226 ContentCategories *ContentCategoriesService
227
228 Conversions *ConversionsService
229
230 Countries *CountriesService
231
232 CreativeAssets *CreativeAssetsService
233
234 CreativeFieldValues *CreativeFieldValuesService
235
236 CreativeFields *CreativeFieldsService
237
238 CreativeGroups *CreativeGroupsService
239
240 Creatives *CreativesService
241
242 DimensionValues *DimensionValuesService
243
244 DirectorySiteContacts *DirectorySiteContactsService
245
246 DirectorySites *DirectorySitesService
247
248 DynamicTargetingKeys *DynamicTargetingKeysService
249
250 EventTags *EventTagsService
251
252 Files *FilesService
253
254 FloodlightActivities *FloodlightActivitiesService
255
256 FloodlightActivityGroups *FloodlightActivityGroupsService
257
258 FloodlightConfigurations *FloodlightConfigurationsService
259
260 InventoryItems *InventoryItemsService
261
262 Languages *LanguagesService
263
264 Metros *MetrosService
265
266 MobileApps *MobileAppsService
267
268 MobileCarriers *MobileCarriersService
269
270 OperatingSystemVersions *OperatingSystemVersionsService
271
272 OperatingSystems *OperatingSystemsService
273
274 OrderDocuments *OrderDocumentsService
275
276 Orders *OrdersService
277
278 PlacementGroups *PlacementGroupsService
279
280 PlacementStrategies *PlacementStrategiesService
281
282 Placements *PlacementsService
283
284 PlatformTypes *PlatformTypesService
285
286 PostalCodes *PostalCodesService
287
288 Projects *ProjectsService
289
290 Regions *RegionsService
291
292 RemarketingListShares *RemarketingListSharesService
293
294 RemarketingLists *RemarketingListsService
295
296 Reports *ReportsService
297
298 Sites *SitesService
299
300 Sizes *SizesService
301
302 Subaccounts *SubaccountsService
303
304 TargetableRemarketingLists *TargetableRemarketingListsService
305
306 TargetingTemplates *TargetingTemplatesService
307
308 UserProfiles *UserProfilesService
309
310 UserRolePermissionGroups *UserRolePermissionGroupsService
311
312 UserRolePermissions *UserRolePermissionsService
313
314 UserRoles *UserRolesService
315
316 VideoFormats *VideoFormatsService
317 }
318
319 func (s *Service) userAgent() string {
320 if s.UserAgent == "" {
321 return googleapi.UserAgent
322 }
323 return googleapi.UserAgent + " " + s.UserAgent
324 }
325
326 func NewAccountActiveAdSummariesService(s *Service) *AccountActiveAdSummariesService {
327 rs := &AccountActiveAdSummariesService{s: s}
328 return rs
329 }
330
331 type AccountActiveAdSummariesService struct {
332 s *Service
333 }
334
335 func NewAccountPermissionGroupsService(s *Service) *AccountPermissionGroupsService {
336 rs := &AccountPermissionGroupsService{s: s}
337 return rs
338 }
339
340 type AccountPermissionGroupsService struct {
341 s *Service
342 }
343
344 func NewAccountPermissionsService(s *Service) *AccountPermissionsService {
345 rs := &AccountPermissionsService{s: s}
346 return rs
347 }
348
349 type AccountPermissionsService struct {
350 s *Service
351 }
352
353 func NewAccountUserProfilesService(s *Service) *AccountUserProfilesService {
354 rs := &AccountUserProfilesService{s: s}
355 return rs
356 }
357
358 type AccountUserProfilesService struct {
359 s *Service
360 }
361
362 func NewAccountsService(s *Service) *AccountsService {
363 rs := &AccountsService{s: s}
364 return rs
365 }
366
367 type AccountsService struct {
368 s *Service
369 }
370
371 func NewAdsService(s *Service) *AdsService {
372 rs := &AdsService{s: s}
373 return rs
374 }
375
376 type AdsService struct {
377 s *Service
378 }
379
380 func NewAdvertiserGroupsService(s *Service) *AdvertiserGroupsService {
381 rs := &AdvertiserGroupsService{s: s}
382 return rs
383 }
384
385 type AdvertiserGroupsService struct {
386 s *Service
387 }
388
389 func NewAdvertiserLandingPagesService(s *Service) *AdvertiserLandingPagesService {
390 rs := &AdvertiserLandingPagesService{s: s}
391 return rs
392 }
393
394 type AdvertiserLandingPagesService struct {
395 s *Service
396 }
397
398 func NewAdvertisersService(s *Service) *AdvertisersService {
399 rs := &AdvertisersService{s: s}
400 return rs
401 }
402
403 type AdvertisersService struct {
404 s *Service
405 }
406
407 func NewBrowsersService(s *Service) *BrowsersService {
408 rs := &BrowsersService{s: s}
409 return rs
410 }
411
412 type BrowsersService struct {
413 s *Service
414 }
415
416 func NewCampaignCreativeAssociationsService(s *Service) *CampaignCreativeAssociationsService {
417 rs := &CampaignCreativeAssociationsService{s: s}
418 return rs
419 }
420
421 type CampaignCreativeAssociationsService struct {
422 s *Service
423 }
424
425 func NewCampaignsService(s *Service) *CampaignsService {
426 rs := &CampaignsService{s: s}
427 return rs
428 }
429
430 type CampaignsService struct {
431 s *Service
432 }
433
434 func NewChangeLogsService(s *Service) *ChangeLogsService {
435 rs := &ChangeLogsService{s: s}
436 return rs
437 }
438
439 type ChangeLogsService struct {
440 s *Service
441 }
442
443 func NewCitiesService(s *Service) *CitiesService {
444 rs := &CitiesService{s: s}
445 return rs
446 }
447
448 type CitiesService struct {
449 s *Service
450 }
451
452 func NewConnectionTypesService(s *Service) *ConnectionTypesService {
453 rs := &ConnectionTypesService{s: s}
454 return rs
455 }
456
457 type ConnectionTypesService struct {
458 s *Service
459 }
460
461 func NewContentCategoriesService(s *Service) *ContentCategoriesService {
462 rs := &ContentCategoriesService{s: s}
463 return rs
464 }
465
466 type ContentCategoriesService struct {
467 s *Service
468 }
469
470 func NewConversionsService(s *Service) *ConversionsService {
471 rs := &ConversionsService{s: s}
472 return rs
473 }
474
475 type ConversionsService struct {
476 s *Service
477 }
478
479 func NewCountriesService(s *Service) *CountriesService {
480 rs := &CountriesService{s: s}
481 return rs
482 }
483
484 type CountriesService struct {
485 s *Service
486 }
487
488 func NewCreativeAssetsService(s *Service) *CreativeAssetsService {
489 rs := &CreativeAssetsService{s: s}
490 return rs
491 }
492
493 type CreativeAssetsService struct {
494 s *Service
495 }
496
497 func NewCreativeFieldValuesService(s *Service) *CreativeFieldValuesService {
498 rs := &CreativeFieldValuesService{s: s}
499 return rs
500 }
501
502 type CreativeFieldValuesService struct {
503 s *Service
504 }
505
506 func NewCreativeFieldsService(s *Service) *CreativeFieldsService {
507 rs := &CreativeFieldsService{s: s}
508 return rs
509 }
510
511 type CreativeFieldsService struct {
512 s *Service
513 }
514
515 func NewCreativeGroupsService(s *Service) *CreativeGroupsService {
516 rs := &CreativeGroupsService{s: s}
517 return rs
518 }
519
520 type CreativeGroupsService struct {
521 s *Service
522 }
523
524 func NewCreativesService(s *Service) *CreativesService {
525 rs := &CreativesService{s: s}
526 return rs
527 }
528
529 type CreativesService struct {
530 s *Service
531 }
532
533 func NewDimensionValuesService(s *Service) *DimensionValuesService {
534 rs := &DimensionValuesService{s: s}
535 return rs
536 }
537
538 type DimensionValuesService struct {
539 s *Service
540 }
541
542 func NewDirectorySiteContactsService(s *Service) *DirectorySiteContactsService {
543 rs := &DirectorySiteContactsService{s: s}
544 return rs
545 }
546
547 type DirectorySiteContactsService struct {
548 s *Service
549 }
550
551 func NewDirectorySitesService(s *Service) *DirectorySitesService {
552 rs := &DirectorySitesService{s: s}
553 return rs
554 }
555
556 type DirectorySitesService struct {
557 s *Service
558 }
559
560 func NewDynamicTargetingKeysService(s *Service) *DynamicTargetingKeysService {
561 rs := &DynamicTargetingKeysService{s: s}
562 return rs
563 }
564
565 type DynamicTargetingKeysService struct {
566 s *Service
567 }
568
569 func NewEventTagsService(s *Service) *EventTagsService {
570 rs := &EventTagsService{s: s}
571 return rs
572 }
573
574 type EventTagsService struct {
575 s *Service
576 }
577
578 func NewFilesService(s *Service) *FilesService {
579 rs := &FilesService{s: s}
580 return rs
581 }
582
583 type FilesService struct {
584 s *Service
585 }
586
587 func NewFloodlightActivitiesService(s *Service) *FloodlightActivitiesService {
588 rs := &FloodlightActivitiesService{s: s}
589 return rs
590 }
591
592 type FloodlightActivitiesService struct {
593 s *Service
594 }
595
596 func NewFloodlightActivityGroupsService(s *Service) *FloodlightActivityGroupsService {
597 rs := &FloodlightActivityGroupsService{s: s}
598 return rs
599 }
600
601 type FloodlightActivityGroupsService struct {
602 s *Service
603 }
604
605 func NewFloodlightConfigurationsService(s *Service) *FloodlightConfigurationsService {
606 rs := &FloodlightConfigurationsService{s: s}
607 return rs
608 }
609
610 type FloodlightConfigurationsService struct {
611 s *Service
612 }
613
614 func NewInventoryItemsService(s *Service) *InventoryItemsService {
615 rs := &InventoryItemsService{s: s}
616 return rs
617 }
618
619 type InventoryItemsService struct {
620 s *Service
621 }
622
623 func NewLanguagesService(s *Service) *LanguagesService {
624 rs := &LanguagesService{s: s}
625 return rs
626 }
627
628 type LanguagesService struct {
629 s *Service
630 }
631
632 func NewMetrosService(s *Service) *MetrosService {
633 rs := &MetrosService{s: s}
634 return rs
635 }
636
637 type MetrosService struct {
638 s *Service
639 }
640
641 func NewMobileAppsService(s *Service) *MobileAppsService {
642 rs := &MobileAppsService{s: s}
643 return rs
644 }
645
646 type MobileAppsService struct {
647 s *Service
648 }
649
650 func NewMobileCarriersService(s *Service) *MobileCarriersService {
651 rs := &MobileCarriersService{s: s}
652 return rs
653 }
654
655 type MobileCarriersService struct {
656 s *Service
657 }
658
659 func NewOperatingSystemVersionsService(s *Service) *OperatingSystemVersionsService {
660 rs := &OperatingSystemVersionsService{s: s}
661 return rs
662 }
663
664 type OperatingSystemVersionsService struct {
665 s *Service
666 }
667
668 func NewOperatingSystemsService(s *Service) *OperatingSystemsService {
669 rs := &OperatingSystemsService{s: s}
670 return rs
671 }
672
673 type OperatingSystemsService struct {
674 s *Service
675 }
676
677 func NewOrderDocumentsService(s *Service) *OrderDocumentsService {
678 rs := &OrderDocumentsService{s: s}
679 return rs
680 }
681
682 type OrderDocumentsService struct {
683 s *Service
684 }
685
686 func NewOrdersService(s *Service) *OrdersService {
687 rs := &OrdersService{s: s}
688 return rs
689 }
690
691 type OrdersService struct {
692 s *Service
693 }
694
695 func NewPlacementGroupsService(s *Service) *PlacementGroupsService {
696 rs := &PlacementGroupsService{s: s}
697 return rs
698 }
699
700 type PlacementGroupsService struct {
701 s *Service
702 }
703
704 func NewPlacementStrategiesService(s *Service) *PlacementStrategiesService {
705 rs := &PlacementStrategiesService{s: s}
706 return rs
707 }
708
709 type PlacementStrategiesService struct {
710 s *Service
711 }
712
713 func NewPlacementsService(s *Service) *PlacementsService {
714 rs := &PlacementsService{s: s}
715 return rs
716 }
717
718 type PlacementsService struct {
719 s *Service
720 }
721
722 func NewPlatformTypesService(s *Service) *PlatformTypesService {
723 rs := &PlatformTypesService{s: s}
724 return rs
725 }
726
727 type PlatformTypesService struct {
728 s *Service
729 }
730
731 func NewPostalCodesService(s *Service) *PostalCodesService {
732 rs := &PostalCodesService{s: s}
733 return rs
734 }
735
736 type PostalCodesService struct {
737 s *Service
738 }
739
740 func NewProjectsService(s *Service) *ProjectsService {
741 rs := &ProjectsService{s: s}
742 return rs
743 }
744
745 type ProjectsService struct {
746 s *Service
747 }
748
749 func NewRegionsService(s *Service) *RegionsService {
750 rs := &RegionsService{s: s}
751 return rs
752 }
753
754 type RegionsService struct {
755 s *Service
756 }
757
758 func NewRemarketingListSharesService(s *Service) *RemarketingListSharesService {
759 rs := &RemarketingListSharesService{s: s}
760 return rs
761 }
762
763 type RemarketingListSharesService struct {
764 s *Service
765 }
766
767 func NewRemarketingListsService(s *Service) *RemarketingListsService {
768 rs := &RemarketingListsService{s: s}
769 return rs
770 }
771
772 type RemarketingListsService struct {
773 s *Service
774 }
775
776 func NewReportsService(s *Service) *ReportsService {
777 rs := &ReportsService{s: s}
778 rs.CompatibleFields = NewReportsCompatibleFieldsService(s)
779 rs.Files = NewReportsFilesService(s)
780 return rs
781 }
782
783 type ReportsService struct {
784 s *Service
785
786 CompatibleFields *ReportsCompatibleFieldsService
787
788 Files *ReportsFilesService
789 }
790
791 func NewReportsCompatibleFieldsService(s *Service) *ReportsCompatibleFieldsService {
792 rs := &ReportsCompatibleFieldsService{s: s}
793 return rs
794 }
795
796 type ReportsCompatibleFieldsService struct {
797 s *Service
798 }
799
800 func NewReportsFilesService(s *Service) *ReportsFilesService {
801 rs := &ReportsFilesService{s: s}
802 return rs
803 }
804
805 type ReportsFilesService struct {
806 s *Service
807 }
808
809 func NewSitesService(s *Service) *SitesService {
810 rs := &SitesService{s: s}
811 return rs
812 }
813
814 type SitesService struct {
815 s *Service
816 }
817
818 func NewSizesService(s *Service) *SizesService {
819 rs := &SizesService{s: s}
820 return rs
821 }
822
823 type SizesService struct {
824 s *Service
825 }
826
827 func NewSubaccountsService(s *Service) *SubaccountsService {
828 rs := &SubaccountsService{s: s}
829 return rs
830 }
831
832 type SubaccountsService struct {
833 s *Service
834 }
835
836 func NewTargetableRemarketingListsService(s *Service) *TargetableRemarketingListsService {
837 rs := &TargetableRemarketingListsService{s: s}
838 return rs
839 }
840
841 type TargetableRemarketingListsService struct {
842 s *Service
843 }
844
845 func NewTargetingTemplatesService(s *Service) *TargetingTemplatesService {
846 rs := &TargetingTemplatesService{s: s}
847 return rs
848 }
849
850 type TargetingTemplatesService struct {
851 s *Service
852 }
853
854 func NewUserProfilesService(s *Service) *UserProfilesService {
855 rs := &UserProfilesService{s: s}
856 return rs
857 }
858
859 type UserProfilesService struct {
860 s *Service
861 }
862
863 func NewUserRolePermissionGroupsService(s *Service) *UserRolePermissionGroupsService {
864 rs := &UserRolePermissionGroupsService{s: s}
865 return rs
866 }
867
868 type UserRolePermissionGroupsService struct {
869 s *Service
870 }
871
872 func NewUserRolePermissionsService(s *Service) *UserRolePermissionsService {
873 rs := &UserRolePermissionsService{s: s}
874 return rs
875 }
876
877 type UserRolePermissionsService struct {
878 s *Service
879 }
880
881 func NewUserRolesService(s *Service) *UserRolesService {
882 rs := &UserRolesService{s: s}
883 return rs
884 }
885
886 type UserRolesService struct {
887 s *Service
888 }
889
890 func NewVideoFormatsService(s *Service) *VideoFormatsService {
891 rs := &VideoFormatsService{s: s}
892 return rs
893 }
894
895 type VideoFormatsService struct {
896 s *Service
897 }
898
899
900 type Account struct {
901
902 AccountPermissionIds googleapi.Int64s `json:"accountPermissionIds,omitempty"`
903
904
905
906
907
908
909
910 AccountProfile string `json:"accountProfile,omitempty"`
911
912
913 Active bool `json:"active,omitempty"`
914
915
916
917
918
919
920
921
922
923
924
925
926
927 ActiveAdsLimitTier string `json:"activeAdsLimitTier,omitempty"`
928
929
930
931
932 ActiveViewOptOut bool `json:"activeViewOptOut,omitempty"`
933
934
935
936 AvailablePermissionIds googleapi.Int64s `json:"availablePermissionIds,omitempty"`
937
938
939 CountryId int64 `json:"countryId,omitempty,string"`
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993 CurrencyId int64 `json:"currencyId,omitempty,string"`
994
995
996 DefaultCreativeSizeId int64 `json:"defaultCreativeSizeId,omitempty,string"`
997
998
999 Description string `json:"description,omitempty"`
1000
1001
1002 Id int64 `json:"id,omitempty,string"`
1003
1004
1005
1006 Kind string `json:"kind,omitempty"`
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026 Locale string `json:"locale,omitempty"`
1027
1028
1029
1030 MaximumImageSize int64 `json:"maximumImageSize,omitempty,string"`
1031
1032
1033
1034 Name string `json:"name,omitempty"`
1035
1036
1037
1038 NielsenOcrEnabled bool `json:"nielsenOcrEnabled,omitempty"`
1039
1040
1041 ReportsConfiguration *ReportsConfiguration `json:"reportsConfiguration,omitempty"`
1042
1043
1044
1045 ShareReportsWithTwitter bool `json:"shareReportsWithTwitter,omitempty"`
1046
1047
1048
1049 TeaserSizeLimit int64 `json:"teaserSizeLimit,omitempty,string"`
1050
1051
1052
1053 googleapi.ServerResponse `json:"-"`
1054
1055
1056
1057
1058
1059
1060
1061
1062 ForceSendFields []string `json:"-"`
1063
1064
1065
1066
1067
1068
1069
1070
1071 NullFields []string `json:"-"`
1072 }
1073
1074 func (s *Account) MarshalJSON() ([]byte, error) {
1075 type NoMethod Account
1076 raw := NoMethod(*s)
1077 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1078 }
1079
1080
1081 type AccountActiveAdSummary struct {
1082
1083 AccountId int64 `json:"accountId,omitempty,string"`
1084
1085
1086 ActiveAds int64 `json:"activeAds,omitempty,string"`
1087
1088
1089
1090
1091
1092
1093
1094
1095
1096
1097
1098
1099
1100 ActiveAdsLimitTier string `json:"activeAdsLimitTier,omitempty"`
1101
1102
1103 AvailableAds int64 `json:"availableAds,omitempty,string"`
1104
1105
1106
1107 Kind string `json:"kind,omitempty"`
1108
1109
1110
1111 googleapi.ServerResponse `json:"-"`
1112
1113
1114
1115
1116
1117
1118
1119 ForceSendFields []string `json:"-"`
1120
1121
1122
1123
1124
1125
1126
1127 NullFields []string `json:"-"`
1128 }
1129
1130 func (s *AccountActiveAdSummary) MarshalJSON() ([]byte, error) {
1131 type NoMethod AccountActiveAdSummary
1132 raw := NoMethod(*s)
1133 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1134 }
1135
1136
1137
1138
1139 type AccountPermission struct {
1140
1141
1142
1143
1144
1145
1146
1147
1148
1149
1150 AccountProfiles []string `json:"accountProfiles,omitempty"`
1151
1152
1153 Id int64 `json:"id,omitempty,string"`
1154
1155
1156
1157 Kind string `json:"kind,omitempty"`
1158
1159
1160
1161
1162
1163
1164
1165 Level string `json:"level,omitempty"`
1166
1167
1168 Name string `json:"name,omitempty"`
1169
1170
1171 PermissionGroupId int64 `json:"permissionGroupId,omitempty,string"`
1172
1173
1174
1175 googleapi.ServerResponse `json:"-"`
1176
1177
1178
1179
1180
1181
1182
1183 ForceSendFields []string `json:"-"`
1184
1185
1186
1187
1188
1189
1190
1191
1192 NullFields []string `json:"-"`
1193 }
1194
1195 func (s *AccountPermission) MarshalJSON() ([]byte, error) {
1196 type NoMethod AccountPermission
1197 raw := NoMethod(*s)
1198 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1199 }
1200
1201
1202
1203
1204 type AccountPermissionGroup struct {
1205
1206 Id int64 `json:"id,omitempty,string"`
1207
1208
1209
1210 Kind string `json:"kind,omitempty"`
1211
1212
1213 Name string `json:"name,omitempty"`
1214
1215
1216
1217 googleapi.ServerResponse `json:"-"`
1218
1219
1220
1221
1222
1223
1224
1225 ForceSendFields []string `json:"-"`
1226
1227
1228
1229
1230
1231
1232
1233 NullFields []string `json:"-"`
1234 }
1235
1236 func (s *AccountPermissionGroup) MarshalJSON() ([]byte, error) {
1237 type NoMethod AccountPermissionGroup
1238 raw := NoMethod(*s)
1239 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1240 }
1241
1242
1243
1244 type AccountPermissionGroupsListResponse struct {
1245
1246 AccountPermissionGroups []*AccountPermissionGroup `json:"accountPermissionGroups,omitempty"`
1247
1248
1249
1250 Kind string `json:"kind,omitempty"`
1251
1252
1253
1254 googleapi.ServerResponse `json:"-"`
1255
1256
1257
1258
1259
1260
1261
1262
1263 ForceSendFields []string `json:"-"`
1264
1265
1266
1267
1268
1269
1270
1271
1272 NullFields []string `json:"-"`
1273 }
1274
1275 func (s *AccountPermissionGroupsListResponse) MarshalJSON() ([]byte, error) {
1276 type NoMethod AccountPermissionGroupsListResponse
1277 raw := NoMethod(*s)
1278 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1279 }
1280
1281
1282 type AccountPermissionsListResponse struct {
1283
1284 AccountPermissions []*AccountPermission `json:"accountPermissions,omitempty"`
1285
1286
1287
1288 Kind string `json:"kind,omitempty"`
1289
1290
1291
1292 googleapi.ServerResponse `json:"-"`
1293
1294
1295
1296
1297
1298
1299
1300 ForceSendFields []string `json:"-"`
1301
1302
1303
1304
1305
1306
1307
1308
1309 NullFields []string `json:"-"`
1310 }
1311
1312 func (s *AccountPermissionsListResponse) MarshalJSON() ([]byte, error) {
1313 type NoMethod AccountPermissionsListResponse
1314 raw := NoMethod(*s)
1315 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1316 }
1317
1318
1319
1320
1321
1322 type AccountUserProfile struct {
1323
1324
1325 AccountId int64 `json:"accountId,omitempty,string"`
1326
1327
1328
1329 Active bool `json:"active,omitempty"`
1330
1331
1332
1333 AdvertiserFilter *ObjectFilter `json:"advertiserFilter,omitempty"`
1334
1335
1336
1337 CampaignFilter *ObjectFilter `json:"campaignFilter,omitempty"`
1338
1339
1340 Comments string `json:"comments,omitempty"`
1341
1342
1343
1344
1345 Email string `json:"email,omitempty"`
1346
1347
1348
1349 Id int64 `json:"id,omitempty,string"`
1350
1351
1352
1353 Kind string `json:"kind,omitempty"`
1354
1355
1356
1357
1358
1359
1360
1361
1362
1363
1364
1365
1366
1367
1368
1369
1370
1371
1372
1373
1374 Locale string `json:"locale,omitempty"`
1375
1376
1377
1378
1379 Name string `json:"name,omitempty"`
1380
1381
1382
1383 SiteFilter *ObjectFilter `json:"siteFilter,omitempty"`
1384
1385
1386
1387 SubaccountId int64 `json:"subaccountId,omitempty,string"`
1388
1389
1390
1391
1392
1393
1394
1395
1396 TraffickerType string `json:"traffickerType,omitempty"`
1397
1398
1399
1400
1401
1402
1403
1404
1405
1406 UserAccessType string `json:"userAccessType,omitempty"`
1407
1408
1409
1410 UserRoleFilter *ObjectFilter `json:"userRoleFilter,omitempty"`
1411
1412
1413
1414 UserRoleId int64 `json:"userRoleId,omitempty,string"`
1415
1416
1417
1418 googleapi.ServerResponse `json:"-"`
1419
1420
1421
1422
1423
1424
1425
1426 ForceSendFields []string `json:"-"`
1427
1428
1429
1430
1431
1432
1433
1434 NullFields []string `json:"-"`
1435 }
1436
1437 func (s *AccountUserProfile) MarshalJSON() ([]byte, error) {
1438 type NoMethod AccountUserProfile
1439 raw := NoMethod(*s)
1440 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1441 }
1442
1443
1444 type AccountUserProfilesListResponse struct {
1445
1446 AccountUserProfiles []*AccountUserProfile `json:"accountUserProfiles,omitempty"`
1447
1448
1449
1450 Kind string `json:"kind,omitempty"`
1451
1452
1453
1454 NextPageToken string `json:"nextPageToken,omitempty"`
1455
1456
1457
1458 googleapi.ServerResponse `json:"-"`
1459
1460
1461
1462
1463
1464
1465
1466 ForceSendFields []string `json:"-"`
1467
1468
1469
1470
1471
1472
1473
1474
1475 NullFields []string `json:"-"`
1476 }
1477
1478 func (s *AccountUserProfilesListResponse) MarshalJSON() ([]byte, error) {
1479 type NoMethod AccountUserProfilesListResponse
1480 raw := NoMethod(*s)
1481 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1482 }
1483
1484
1485 type AccountsListResponse struct {
1486
1487 Accounts []*Account `json:"accounts,omitempty"`
1488
1489
1490
1491 Kind string `json:"kind,omitempty"`
1492
1493
1494
1495 NextPageToken string `json:"nextPageToken,omitempty"`
1496
1497
1498
1499 googleapi.ServerResponse `json:"-"`
1500
1501
1502
1503
1504
1505
1506
1507 ForceSendFields []string `json:"-"`
1508
1509
1510
1511
1512
1513
1514
1515 NullFields []string `json:"-"`
1516 }
1517
1518 func (s *AccountsListResponse) MarshalJSON() ([]byte, error) {
1519 type NoMethod AccountsListResponse
1520 raw := NoMethod(*s)
1521 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1522 }
1523
1524
1525 type Activities struct {
1526
1527
1528 Filters []*DimensionValue `json:"filters,omitempty"`
1529
1530
1531
1532 Kind string `json:"kind,omitempty"`
1533
1534
1535 MetricNames []string `json:"metricNames,omitempty"`
1536
1537
1538
1539
1540
1541
1542
1543 ForceSendFields []string `json:"-"`
1544
1545
1546
1547
1548
1549
1550
1551 NullFields []string `json:"-"`
1552 }
1553
1554 func (s *Activities) MarshalJSON() ([]byte, error) {
1555 type NoMethod Activities
1556 raw := NoMethod(*s)
1557 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1558 }
1559
1560
1561 type Ad struct {
1562
1563
1564 AccountId int64 `json:"accountId,omitempty,string"`
1565
1566
1567 Active bool `json:"active,omitempty"`
1568
1569
1570
1571 AdvertiserId int64 `json:"advertiserId,omitempty,string"`
1572
1573
1574
1575 AdvertiserIdDimensionValue *DimensionValue `json:"advertiserIdDimensionValue,omitempty"`
1576
1577
1578
1579 Archived bool `json:"archived,omitempty"`
1580
1581
1582
1583 AudienceSegmentId int64 `json:"audienceSegmentId,omitempty,string"`
1584
1585
1586
1587 CampaignId int64 `json:"campaignId,omitempty,string"`
1588
1589
1590
1591 CampaignIdDimensionValue *DimensionValue `json:"campaignIdDimensionValue,omitempty"`
1592
1593
1594
1595 ClickThroughUrl *ClickThroughUrl `json:"clickThroughUrl,omitempty"`
1596
1597
1598
1599
1600 ClickThroughUrlSuffixProperties *ClickThroughUrlSuffixProperties `json:"clickThroughUrlSuffixProperties,omitempty"`
1601
1602
1603 Comments string `json:"comments,omitempty"`
1604
1605
1606
1607
1608
1609
1610
1611
1612
1613
1614
1615
1616
1617
1618
1619
1620
1621
1622 Compatibility string `json:"compatibility,omitempty"`
1623
1624
1625
1626 CreateInfo *LastModifiedInfo `json:"createInfo,omitempty"`
1627
1628
1629
1630
1631
1632 CreativeGroupAssignments []*CreativeGroupAssignment `json:"creativeGroupAssignments,omitempty"`
1633
1634
1635
1636
1637
1638 CreativeRotation *CreativeRotation `json:"creativeRotation,omitempty"`
1639
1640
1641
1642
1643 DayPartTargeting *DayPartTargeting `json:"dayPartTargeting,omitempty"`
1644
1645
1646
1647 DefaultClickThroughEventTagProperties *DefaultClickThroughEventTagProperties `json:"defaultClickThroughEventTagProperties,omitempty"`
1648
1649
1650
1651
1652
1653
1654 DeliverySchedule *DeliverySchedule `json:"deliverySchedule,omitempty"`
1655
1656
1657
1658
1659 DynamicClickTracker bool `json:"dynamicClickTracker,omitempty"`
1660
1661
1662
1663 EndTime string `json:"endTime,omitempty"`
1664
1665
1666 EventTagOverrides []*EventTagOverride `json:"eventTagOverrides,omitempty"`
1667
1668
1669
1670
1671 GeoTargeting *GeoTargeting `json:"geoTargeting,omitempty"`
1672
1673
1674 Id int64 `json:"id,omitempty,string"`
1675
1676
1677
1678 IdDimensionValue *DimensionValue `json:"idDimensionValue,omitempty"`
1679
1680
1681
1682
1683 KeyValueTargetingExpression *KeyValueTargetingExpression `json:"keyValueTargetingExpression,omitempty"`
1684
1685
1686
1687 Kind string `json:"kind,omitempty"`
1688
1689
1690
1691
1692 LanguageTargeting *LanguageTargeting `json:"languageTargeting,omitempty"`
1693
1694
1695
1696 LastModifiedInfo *LastModifiedInfo `json:"lastModifiedInfo,omitempty"`
1697
1698
1699
1700 Name string `json:"name,omitempty"`
1701
1702
1703 PlacementAssignments []*PlacementAssignment `json:"placementAssignments,omitempty"`
1704
1705
1706
1707
1708 RemarketingListExpression *ListTargetingExpression `json:"remarketingListExpression,omitempty"`
1709
1710
1711 Size *Size `json:"size,omitempty"`
1712
1713
1714
1715 SslCompliant bool `json:"sslCompliant,omitempty"`
1716
1717
1718
1719 SslRequired bool `json:"sslRequired,omitempty"`
1720
1721
1722
1723
1724 StartTime string `json:"startTime,omitempty"`
1725
1726
1727
1728 SubaccountId int64 `json:"subaccountId,omitempty,string"`
1729
1730
1731
1732
1733
1734
1735
1736 TargetingTemplateId int64 `json:"targetingTemplateId,omitempty,string"`
1737
1738
1739
1740
1741 TechnologyTargeting *TechnologyTargeting `json:"technologyTargeting,omitempty"`
1742
1743
1744
1745
1746
1747
1748
1749
1750
1751
1752 Type string `json:"type,omitempty"`
1753
1754
1755
1756 googleapi.ServerResponse `json:"-"`
1757
1758
1759
1760
1761
1762
1763
1764 ForceSendFields []string `json:"-"`
1765
1766
1767
1768
1769
1770
1771
1772 NullFields []string `json:"-"`
1773 }
1774
1775 func (s *Ad) MarshalJSON() ([]byte, error) {
1776 type NoMethod Ad
1777 raw := NoMethod(*s)
1778 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1779 }
1780
1781
1782 type AdBlockingConfiguration struct {
1783
1784
1785 ClickThroughUrl string `json:"clickThroughUrl,omitempty"`
1786
1787
1788
1789
1790 CreativeBundleId int64 `json:"creativeBundleId,omitempty,string"`
1791
1792
1793
1794
1795
1796
1797 Enabled bool `json:"enabled,omitempty"`
1798
1799
1800
1801
1802
1803 OverrideClickThroughUrl bool `json:"overrideClickThroughUrl,omitempty"`
1804
1805
1806
1807
1808
1809
1810
1811 ForceSendFields []string `json:"-"`
1812
1813
1814
1815
1816
1817
1818
1819
1820 NullFields []string `json:"-"`
1821 }
1822
1823 func (s *AdBlockingConfiguration) MarshalJSON() ([]byte, error) {
1824 type NoMethod AdBlockingConfiguration
1825 raw := NoMethod(*s)
1826 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1827 }
1828
1829
1830 type AdSlot struct {
1831
1832 Comment string `json:"comment,omitempty"`
1833
1834
1835
1836
1837
1838
1839
1840
1841
1842
1843
1844
1845
1846
1847
1848 Compatibility string `json:"compatibility,omitempty"`
1849
1850
1851 Height int64 `json:"height,omitempty,string"`
1852
1853
1854
1855 LinkedPlacementId int64 `json:"linkedPlacementId,omitempty,string"`
1856
1857
1858 Name string `json:"name,omitempty"`
1859
1860
1861
1862
1863
1864
1865 PaymentSourceType string `json:"paymentSourceType,omitempty"`
1866
1867
1868 Primary bool `json:"primary,omitempty"`
1869
1870
1871 Width int64 `json:"width,omitempty,string"`
1872
1873
1874
1875
1876
1877
1878
1879 ForceSendFields []string `json:"-"`
1880
1881
1882
1883
1884
1885
1886
1887 NullFields []string `json:"-"`
1888 }
1889
1890 func (s *AdSlot) MarshalJSON() ([]byte, error) {
1891 type NoMethod AdSlot
1892 raw := NoMethod(*s)
1893 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1894 }
1895
1896
1897 type AdsListResponse struct {
1898
1899 Ads []*Ad `json:"ads,omitempty"`
1900
1901
1902
1903 Kind string `json:"kind,omitempty"`
1904
1905
1906
1907 NextPageToken string `json:"nextPageToken,omitempty"`
1908
1909
1910
1911 googleapi.ServerResponse `json:"-"`
1912
1913
1914
1915
1916
1917
1918
1919 ForceSendFields []string `json:"-"`
1920
1921
1922
1923
1924
1925
1926
1927 NullFields []string `json:"-"`
1928 }
1929
1930 func (s *AdsListResponse) MarshalJSON() ([]byte, error) {
1931 type NoMethod AdsListResponse
1932 raw := NoMethod(*s)
1933 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1934 }
1935
1936
1937 type Advertiser struct {
1938
1939
1940 AccountId int64 `json:"accountId,omitempty,string"`
1941
1942
1943
1944
1945 AdvertiserGroupId int64 `json:"advertiserGroupId,omitempty,string"`
1946
1947
1948
1949
1950 ClickThroughUrlSuffix string `json:"clickThroughUrlSuffix,omitempty"`
1951
1952
1953
1954 DefaultClickThroughEventTagId int64 `json:"defaultClickThroughEventTagId,omitempty,string"`
1955
1956
1957
1958 DefaultEmail string `json:"defaultEmail,omitempty"`
1959
1960
1961
1962
1963
1964
1965
1966
1967
1968
1969
1970
1971 FloodlightConfigurationId int64 `json:"floodlightConfigurationId,omitempty,string"`
1972
1973
1974
1975
1976 FloodlightConfigurationIdDimensionValue *DimensionValue `json:"floodlightConfigurationIdDimensionValue,omitempty"`
1977
1978
1979 Id int64 `json:"id,omitempty,string"`
1980
1981
1982
1983 IdDimensionValue *DimensionValue `json:"idDimensionValue,omitempty"`
1984
1985
1986
1987 Kind string `json:"kind,omitempty"`
1988
1989
1990
1991
1992 Name string `json:"name,omitempty"`
1993
1994
1995
1996
1997
1998
1999
2000 OriginalFloodlightConfigurationId int64 `json:"originalFloodlightConfigurationId,omitempty,string"`
2001
2002
2003
2004
2005
2006
2007 Status string `json:"status,omitempty"`
2008
2009
2010
2011 SubaccountId int64 `json:"subaccountId,omitempty,string"`
2012
2013
2014 Suspended bool `json:"suspended,omitempty"`
2015
2016
2017
2018 googleapi.ServerResponse `json:"-"`
2019
2020
2021
2022
2023
2024
2025
2026 ForceSendFields []string `json:"-"`
2027
2028
2029
2030
2031
2032
2033
2034 NullFields []string `json:"-"`
2035 }
2036
2037 func (s *Advertiser) MarshalJSON() ([]byte, error) {
2038 type NoMethod Advertiser
2039 raw := NoMethod(*s)
2040 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2041 }
2042
2043
2044
2045 type AdvertiserGroup struct {
2046
2047
2048 AccountId int64 `json:"accountId,omitempty,string"`
2049
2050
2051
2052 Id int64 `json:"id,omitempty,string"`
2053
2054
2055
2056 Kind string `json:"kind,omitempty"`
2057
2058
2059
2060
2061 Name string `json:"name,omitempty"`
2062
2063
2064
2065 googleapi.ServerResponse `json:"-"`
2066
2067
2068
2069
2070
2071
2072
2073 ForceSendFields []string `json:"-"`
2074
2075
2076
2077
2078
2079
2080
2081 NullFields []string `json:"-"`
2082 }
2083
2084 func (s *AdvertiserGroup) MarshalJSON() ([]byte, error) {
2085 type NoMethod AdvertiserGroup
2086 raw := NoMethod(*s)
2087 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2088 }
2089
2090
2091 type AdvertiserGroupsListResponse struct {
2092
2093 AdvertiserGroups []*AdvertiserGroup `json:"advertiserGroups,omitempty"`
2094
2095
2096
2097 Kind string `json:"kind,omitempty"`
2098
2099
2100
2101 NextPageToken string `json:"nextPageToken,omitempty"`
2102
2103
2104
2105 googleapi.ServerResponse `json:"-"`
2106
2107
2108
2109
2110
2111
2112
2113 ForceSendFields []string `json:"-"`
2114
2115
2116
2117
2118
2119
2120
2121
2122 NullFields []string `json:"-"`
2123 }
2124
2125 func (s *AdvertiserGroupsListResponse) MarshalJSON() ([]byte, error) {
2126 type NoMethod AdvertiserGroupsListResponse
2127 raw := NoMethod(*s)
2128 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2129 }
2130
2131
2132 type AdvertiserLandingPagesListResponse struct {
2133
2134
2135 Kind string `json:"kind,omitempty"`
2136
2137
2138 LandingPages []*LandingPage `json:"landingPages,omitempty"`
2139
2140
2141
2142 NextPageToken string `json:"nextPageToken,omitempty"`
2143
2144
2145
2146 googleapi.ServerResponse `json:"-"`
2147
2148
2149
2150
2151
2152
2153
2154 ForceSendFields []string `json:"-"`
2155
2156
2157
2158
2159
2160
2161
2162 NullFields []string `json:"-"`
2163 }
2164
2165 func (s *AdvertiserLandingPagesListResponse) MarshalJSON() ([]byte, error) {
2166 type NoMethod AdvertiserLandingPagesListResponse
2167 raw := NoMethod(*s)
2168 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2169 }
2170
2171
2172 type AdvertisersListResponse struct {
2173
2174 Advertisers []*Advertiser `json:"advertisers,omitempty"`
2175
2176
2177
2178 Kind string `json:"kind,omitempty"`
2179
2180
2181
2182 NextPageToken string `json:"nextPageToken,omitempty"`
2183
2184
2185
2186 googleapi.ServerResponse `json:"-"`
2187
2188
2189
2190
2191
2192
2193
2194 ForceSendFields []string `json:"-"`
2195
2196
2197
2198
2199
2200
2201
2202 NullFields []string `json:"-"`
2203 }
2204
2205 func (s *AdvertisersListResponse) MarshalJSON() ([]byte, error) {
2206 type NoMethod AdvertisersListResponse
2207 raw := NoMethod(*s)
2208 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2209 }
2210
2211
2212 type AudienceSegment struct {
2213
2214
2215
2216
2217 Allocation int64 `json:"allocation,omitempty"`
2218
2219
2220
2221 Id int64 `json:"id,omitempty,string"`
2222
2223
2224
2225 Name string `json:"name,omitempty"`
2226
2227
2228
2229
2230
2231
2232
2233 ForceSendFields []string `json:"-"`
2234
2235
2236
2237
2238
2239
2240
2241 NullFields []string `json:"-"`
2242 }
2243
2244 func (s *AudienceSegment) MarshalJSON() ([]byte, error) {
2245 type NoMethod AudienceSegment
2246 raw := NoMethod(*s)
2247 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2248 }
2249
2250
2251 type AudienceSegmentGroup struct {
2252
2253
2254 AudienceSegments []*AudienceSegment `json:"audienceSegments,omitempty"`
2255
2256
2257
2258 Id int64 `json:"id,omitempty,string"`
2259
2260
2261
2262 Name string `json:"name,omitempty"`
2263
2264
2265
2266
2267
2268
2269
2270 ForceSendFields []string `json:"-"`
2271
2272
2273
2274
2275
2276
2277
2278
2279 NullFields []string `json:"-"`
2280 }
2281
2282 func (s *AudienceSegmentGroup) MarshalJSON() ([]byte, error) {
2283 type NoMethod AudienceSegmentGroup
2284 raw := NoMethod(*s)
2285 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2286 }
2287
2288
2289
2290 type Browser struct {
2291
2292
2293 BrowserVersionId int64 `json:"browserVersionId,omitempty,string"`
2294
2295
2296
2297 DartId int64 `json:"dartId,omitempty,string"`
2298
2299
2300
2301 Kind string `json:"kind,omitempty"`
2302
2303
2304
2305
2306
2307
2308
2309
2310
2311
2312 MajorVersion string `json:"majorVersion,omitempty"`
2313
2314
2315
2316
2317
2318
2319
2320
2321
2322
2323 MinorVersion string `json:"minorVersion,omitempty"`
2324
2325
2326 Name string `json:"name,omitempty"`
2327
2328
2329
2330
2331
2332
2333
2334 ForceSendFields []string `json:"-"`
2335
2336
2337
2338
2339
2340
2341
2342
2343 NullFields []string `json:"-"`
2344 }
2345
2346 func (s *Browser) MarshalJSON() ([]byte, error) {
2347 type NoMethod Browser
2348 raw := NoMethod(*s)
2349 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2350 }
2351
2352
2353 type BrowsersListResponse struct {
2354
2355 Browsers []*Browser `json:"browsers,omitempty"`
2356
2357
2358
2359 Kind string `json:"kind,omitempty"`
2360
2361
2362
2363 googleapi.ServerResponse `json:"-"`
2364
2365
2366
2367
2368
2369
2370
2371 ForceSendFields []string `json:"-"`
2372
2373
2374
2375
2376
2377
2378
2379 NullFields []string `json:"-"`
2380 }
2381
2382 func (s *BrowsersListResponse) MarshalJSON() ([]byte, error) {
2383 type NoMethod BrowsersListResponse
2384 raw := NoMethod(*s)
2385 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2386 }
2387
2388
2389 type Campaign struct {
2390
2391
2392 AccountId int64 `json:"accountId,omitempty,string"`
2393
2394
2395 AdBlockingConfiguration *AdBlockingConfiguration `json:"adBlockingConfiguration,omitempty"`
2396
2397
2398
2399 AdditionalCreativeOptimizationConfigurations []*CreativeOptimizationConfiguration `json:"additionalCreativeOptimizationConfigurations,omitempty"`
2400
2401
2402 AdvertiserGroupId int64 `json:"advertiserGroupId,omitempty,string"`
2403
2404
2405
2406 AdvertiserId int64 `json:"advertiserId,omitempty,string"`
2407
2408
2409
2410 AdvertiserIdDimensionValue *DimensionValue `json:"advertiserIdDimensionValue,omitempty"`
2411
2412
2413 Archived bool `json:"archived,omitempty"`
2414
2415
2416
2417 AudienceSegmentGroups []*AudienceSegmentGroup `json:"audienceSegmentGroups,omitempty"`
2418
2419
2420
2421 BillingInvoiceCode string `json:"billingInvoiceCode,omitempty"`
2422
2423
2424
2425 ClickThroughUrlSuffixProperties *ClickThroughUrlSuffixProperties `json:"clickThroughUrlSuffixProperties,omitempty"`
2426
2427
2428
2429 Comment string `json:"comment,omitempty"`
2430
2431
2432
2433 CreateInfo *LastModifiedInfo `json:"createInfo,omitempty"`
2434
2435
2436
2437 CreativeGroupIds googleapi.Int64s `json:"creativeGroupIds,omitempty"`
2438
2439
2440
2441 CreativeOptimizationConfiguration *CreativeOptimizationConfiguration `json:"creativeOptimizationConfiguration,omitempty"`
2442
2443
2444
2445 DefaultClickThroughEventTagProperties *DefaultClickThroughEventTagProperties `json:"defaultClickThroughEventTagProperties,omitempty"`
2446
2447
2448 DefaultLandingPageId int64 `json:"defaultLandingPageId,omitempty,string"`
2449
2450
2451
2452
2453
2454
2455
2456
2457 EndDate string `json:"endDate,omitempty"`
2458
2459
2460
2461 EventTagOverrides []*EventTagOverride `json:"eventTagOverrides,omitempty"`
2462
2463
2464 ExternalId string `json:"externalId,omitempty"`
2465
2466
2467 Id int64 `json:"id,omitempty,string"`
2468
2469
2470
2471 IdDimensionValue *DimensionValue `json:"idDimensionValue,omitempty"`
2472
2473
2474
2475 Kind string `json:"kind,omitempty"`
2476
2477
2478
2479 LastModifiedInfo *LastModifiedInfo `json:"lastModifiedInfo,omitempty"`
2480
2481
2482 LookbackConfiguration *LookbackConfiguration `json:"lookbackConfiguration,omitempty"`
2483
2484
2485
2486
2487 Name string `json:"name,omitempty"`
2488
2489
2490
2491 NielsenOcrEnabled bool `json:"nielsenOcrEnabled,omitempty"`
2492
2493
2494
2495
2496
2497 StartDate string `json:"startDate,omitempty"`
2498
2499
2500
2501 SubaccountId int64 `json:"subaccountId,omitempty,string"`
2502
2503
2504 TraffickerEmails []string `json:"traffickerEmails,omitempty"`
2505
2506
2507
2508 googleapi.ServerResponse `json:"-"`
2509
2510
2511
2512
2513
2514
2515
2516 ForceSendFields []string `json:"-"`
2517
2518
2519
2520
2521
2522
2523
2524 NullFields []string `json:"-"`
2525 }
2526
2527 func (s *Campaign) MarshalJSON() ([]byte, error) {
2528 type NoMethod Campaign
2529 raw := NoMethod(*s)
2530 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2531 }
2532
2533
2534
2535 type CampaignCreativeAssociation struct {
2536
2537
2538 CreativeId int64 `json:"creativeId,omitempty,string"`
2539
2540
2541
2542 Kind string `json:"kind,omitempty"`
2543
2544
2545
2546 googleapi.ServerResponse `json:"-"`
2547
2548
2549
2550
2551
2552
2553
2554 ForceSendFields []string `json:"-"`
2555
2556
2557
2558
2559
2560
2561
2562 NullFields []string `json:"-"`
2563 }
2564
2565 func (s *CampaignCreativeAssociation) MarshalJSON() ([]byte, error) {
2566 type NoMethod CampaignCreativeAssociation
2567 raw := NoMethod(*s)
2568 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2569 }
2570
2571
2572
2573 type CampaignCreativeAssociationsListResponse struct {
2574
2575
2576 CampaignCreativeAssociations []*CampaignCreativeAssociation `json:"campaignCreativeAssociations,omitempty"`
2577
2578
2579
2580 Kind string `json:"kind,omitempty"`
2581
2582
2583
2584 NextPageToken string `json:"nextPageToken,omitempty"`
2585
2586
2587
2588 googleapi.ServerResponse `json:"-"`
2589
2590
2591
2592
2593
2594
2595
2596
2597 ForceSendFields []string `json:"-"`
2598
2599
2600
2601
2602
2603
2604
2605
2606 NullFields []string `json:"-"`
2607 }
2608
2609 func (s *CampaignCreativeAssociationsListResponse) MarshalJSON() ([]byte, error) {
2610 type NoMethod CampaignCreativeAssociationsListResponse
2611 raw := NoMethod(*s)
2612 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2613 }
2614
2615
2616 type CampaignsListResponse struct {
2617
2618 Campaigns []*Campaign `json:"campaigns,omitempty"`
2619
2620
2621
2622 Kind string `json:"kind,omitempty"`
2623
2624
2625
2626 NextPageToken string `json:"nextPageToken,omitempty"`
2627
2628
2629
2630 googleapi.ServerResponse `json:"-"`
2631
2632
2633
2634
2635
2636
2637
2638 ForceSendFields []string `json:"-"`
2639
2640
2641
2642
2643
2644
2645
2646 NullFields []string `json:"-"`
2647 }
2648
2649 func (s *CampaignsListResponse) MarshalJSON() ([]byte, error) {
2650 type NoMethod CampaignsListResponse
2651 raw := NoMethod(*s)
2652 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2653 }
2654
2655
2656 type ChangeLog struct {
2657
2658 AccountId int64 `json:"accountId,omitempty,string"`
2659
2660
2661 Action string `json:"action,omitempty"`
2662
2663
2664 ChangeTime string `json:"changeTime,omitempty"`
2665
2666
2667 FieldName string `json:"fieldName,omitempty"`
2668
2669
2670 Id int64 `json:"id,omitempty,string"`
2671
2672
2673
2674 Kind string `json:"kind,omitempty"`
2675
2676
2677 NewValue string `json:"newValue,omitempty"`
2678
2679
2680
2681 ObjectId int64 `json:"objectId,omitempty,string"`
2682
2683
2684 ObjectType string `json:"objectType,omitempty"`
2685
2686
2687 OldValue string `json:"oldValue,omitempty"`
2688
2689
2690 SubaccountId int64 `json:"subaccountId,omitempty,string"`
2691
2692
2693
2694
2695 TransactionId int64 `json:"transactionId,omitempty,string"`
2696
2697
2698 UserProfileId int64 `json:"userProfileId,omitempty,string"`
2699
2700
2701
2702 UserProfileName string `json:"userProfileName,omitempty"`
2703
2704
2705
2706 googleapi.ServerResponse `json:"-"`
2707
2708
2709
2710
2711
2712
2713
2714 ForceSendFields []string `json:"-"`
2715
2716
2717
2718
2719
2720
2721
2722 NullFields []string `json:"-"`
2723 }
2724
2725 func (s *ChangeLog) MarshalJSON() ([]byte, error) {
2726 type NoMethod ChangeLog
2727 raw := NoMethod(*s)
2728 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2729 }
2730
2731
2732 type ChangeLogsListResponse struct {
2733
2734 ChangeLogs []*ChangeLog `json:"changeLogs,omitempty"`
2735
2736
2737
2738 Kind string `json:"kind,omitempty"`
2739
2740
2741
2742 NextPageToken string `json:"nextPageToken,omitempty"`
2743
2744
2745
2746 googleapi.ServerResponse `json:"-"`
2747
2748
2749
2750
2751
2752
2753
2754 ForceSendFields []string `json:"-"`
2755
2756
2757
2758
2759
2760
2761
2762 NullFields []string `json:"-"`
2763 }
2764
2765 func (s *ChangeLogsListResponse) MarshalJSON() ([]byte, error) {
2766 type NoMethod ChangeLogsListResponse
2767 raw := NoMethod(*s)
2768 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2769 }
2770
2771
2772 type CitiesListResponse struct {
2773
2774 Cities []*City `json:"cities,omitempty"`
2775
2776
2777
2778 Kind string `json:"kind,omitempty"`
2779
2780
2781
2782 googleapi.ServerResponse `json:"-"`
2783
2784
2785
2786
2787
2788
2789
2790 ForceSendFields []string `json:"-"`
2791
2792
2793
2794
2795
2796
2797
2798 NullFields []string `json:"-"`
2799 }
2800
2801 func (s *CitiesListResponse) MarshalJSON() ([]byte, error) {
2802 type NoMethod CitiesListResponse
2803 raw := NoMethod(*s)
2804 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2805 }
2806
2807
2808 type City struct {
2809
2810 CountryCode string `json:"countryCode,omitempty"`
2811
2812
2813 CountryDartId int64 `json:"countryDartId,omitempty,string"`
2814
2815
2816
2817 DartId int64 `json:"dartId,omitempty,string"`
2818
2819
2820
2821 Kind string `json:"kind,omitempty"`
2822
2823
2824
2825 MetroCode string `json:"metroCode,omitempty"`
2826
2827
2828 MetroDmaId int64 `json:"metroDmaId,omitempty,string"`
2829
2830
2831 Name string `json:"name,omitempty"`
2832
2833
2834 RegionCode string `json:"regionCode,omitempty"`
2835
2836
2837 RegionDartId int64 `json:"regionDartId,omitempty,string"`
2838
2839
2840
2841
2842
2843
2844
2845 ForceSendFields []string `json:"-"`
2846
2847
2848
2849
2850
2851
2852
2853 NullFields []string `json:"-"`
2854 }
2855
2856 func (s *City) MarshalJSON() ([]byte, error) {
2857 type NoMethod City
2858 raw := NoMethod(*s)
2859 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2860 }
2861
2862
2863 type ClickTag struct {
2864
2865
2866 ClickThroughUrl *CreativeClickThroughUrl `json:"clickThroughUrl,omitempty"`
2867
2868
2869
2870
2871 EventName string `json:"eventName,omitempty"`
2872
2873
2874
2875
2876 Name string `json:"name,omitempty"`
2877
2878
2879
2880
2881
2882
2883
2884 ForceSendFields []string `json:"-"`
2885
2886
2887
2888
2889
2890
2891
2892
2893 NullFields []string `json:"-"`
2894 }
2895
2896 func (s *ClickTag) MarshalJSON() ([]byte, error) {
2897 type NoMethod ClickTag
2898 raw := NoMethod(*s)
2899 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2900 }
2901
2902
2903 type ClickThroughUrl struct {
2904
2905
2906
2907
2908
2909
2910
2911
2912
2913 ComputedClickThroughUrl string `json:"computedClickThroughUrl,omitempty"`
2914
2915
2916
2917
2918 CustomClickThroughUrl string `json:"customClickThroughUrl,omitempty"`
2919
2920
2921
2922 DefaultLandingPage bool `json:"defaultLandingPage,omitempty"`
2923
2924
2925
2926 LandingPageId int64 `json:"landingPageId,omitempty,string"`
2927
2928
2929
2930
2931
2932
2933
2934
2935 ForceSendFields []string `json:"-"`
2936
2937
2938
2939
2940
2941
2942
2943
2944 NullFields []string `json:"-"`
2945 }
2946
2947 func (s *ClickThroughUrl) MarshalJSON() ([]byte, error) {
2948 type NoMethod ClickThroughUrl
2949 raw := NoMethod(*s)
2950 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2951 }
2952
2953
2954 type ClickThroughUrlSuffixProperties struct {
2955
2956
2957 ClickThroughUrlSuffix string `json:"clickThroughUrlSuffix,omitempty"`
2958
2959
2960
2961 OverrideInheritedSuffix bool `json:"overrideInheritedSuffix,omitempty"`
2962
2963
2964
2965
2966
2967
2968
2969
2970 ForceSendFields []string `json:"-"`
2971
2972
2973
2974
2975
2976
2977
2978
2979 NullFields []string `json:"-"`
2980 }
2981
2982 func (s *ClickThroughUrlSuffixProperties) MarshalJSON() ([]byte, error) {
2983 type NoMethod ClickThroughUrlSuffixProperties
2984 raw := NoMethod(*s)
2985 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2986 }
2987
2988
2989 type CompanionClickThroughOverride struct {
2990
2991
2992 ClickThroughUrl *ClickThroughUrl `json:"clickThroughUrl,omitempty"`
2993
2994
2995
2996 CreativeId int64 `json:"creativeId,omitempty,string"`
2997
2998
2999
3000
3001
3002
3003
3004 ForceSendFields []string `json:"-"`
3005
3006
3007
3008
3009
3010
3011
3012
3013 NullFields []string `json:"-"`
3014 }
3015
3016 func (s *CompanionClickThroughOverride) MarshalJSON() ([]byte, error) {
3017 type NoMethod CompanionClickThroughOverride
3018 raw := NoMethod(*s)
3019 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3020 }
3021
3022
3023 type CompanionSetting struct {
3024
3025
3026 CompanionsDisabled bool `json:"companionsDisabled,omitempty"`
3027
3028
3029
3030
3031 EnabledSizes []*Size `json:"enabledSizes,omitempty"`
3032
3033
3034 ImageOnly bool `json:"imageOnly,omitempty"`
3035
3036
3037
3038 Kind string `json:"kind,omitempty"`
3039
3040
3041
3042
3043
3044
3045
3046 ForceSendFields []string `json:"-"`
3047
3048
3049
3050
3051
3052
3053
3054
3055 NullFields []string `json:"-"`
3056 }
3057
3058 func (s *CompanionSetting) MarshalJSON() ([]byte, error) {
3059 type NoMethod CompanionSetting
3060 raw := NoMethod(*s)
3061 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3062 }
3063
3064
3065
3066 type CompatibleFields struct {
3067
3068
3069
3070 CrossDimensionReachReportCompatibleFields *CrossDimensionReachReportCompatibleFields `json:"crossDimensionReachReportCompatibleFields,omitempty"`
3071
3072
3073
3074 FloodlightReportCompatibleFields *FloodlightReportCompatibleFields `json:"floodlightReportCompatibleFields,omitempty"`
3075
3076
3077
3078 Kind string `json:"kind,omitempty"`
3079
3080
3081
3082 PathToConversionReportCompatibleFields *PathToConversionReportCompatibleFields `json:"pathToConversionReportCompatibleFields,omitempty"`
3083
3084
3085
3086 ReachReportCompatibleFields *ReachReportCompatibleFields `json:"reachReportCompatibleFields,omitempty"`
3087
3088
3089
3090 ReportCompatibleFields *ReportCompatibleFields `json:"reportCompatibleFields,omitempty"`
3091
3092
3093
3094 googleapi.ServerResponse `json:"-"`
3095
3096
3097
3098
3099
3100
3101
3102
3103 ForceSendFields []string `json:"-"`
3104
3105
3106
3107
3108
3109
3110
3111
3112 NullFields []string `json:"-"`
3113 }
3114
3115 func (s *CompatibleFields) MarshalJSON() ([]byte, error) {
3116 type NoMethod CompatibleFields
3117 raw := NoMethod(*s)
3118 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3119 }
3120
3121
3122
3123
3124 type ConnectionType struct {
3125
3126 Id int64 `json:"id,omitempty,string"`
3127
3128
3129
3130 Kind string `json:"kind,omitempty"`
3131
3132
3133 Name string `json:"name,omitempty"`
3134
3135
3136
3137 googleapi.ServerResponse `json:"-"`
3138
3139
3140
3141
3142
3143
3144
3145 ForceSendFields []string `json:"-"`
3146
3147
3148
3149
3150
3151
3152
3153 NullFields []string `json:"-"`
3154 }
3155
3156 func (s *ConnectionType) MarshalJSON() ([]byte, error) {
3157 type NoMethod ConnectionType
3158 raw := NoMethod(*s)
3159 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3160 }
3161
3162
3163 type ConnectionTypesListResponse struct {
3164
3165
3166 ConnectionTypes []*ConnectionType `json:"connectionTypes,omitempty"`
3167
3168
3169
3170 Kind string `json:"kind,omitempty"`
3171
3172
3173
3174 googleapi.ServerResponse `json:"-"`
3175
3176
3177
3178
3179
3180
3181
3182 ForceSendFields []string `json:"-"`
3183
3184
3185
3186
3187
3188
3189
3190
3191 NullFields []string `json:"-"`
3192 }
3193
3194 func (s *ConnectionTypesListResponse) MarshalJSON() ([]byte, error) {
3195 type NoMethod ConnectionTypesListResponse
3196 raw := NoMethod(*s)
3197 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3198 }
3199
3200
3201 type ContentCategoriesListResponse struct {
3202
3203 ContentCategories []*ContentCategory `json:"contentCategories,omitempty"`
3204
3205
3206
3207 Kind string `json:"kind,omitempty"`
3208
3209
3210
3211 NextPageToken string `json:"nextPageToken,omitempty"`
3212
3213
3214
3215 googleapi.ServerResponse `json:"-"`
3216
3217
3218
3219
3220
3221
3222
3223 ForceSendFields []string `json:"-"`
3224
3225
3226
3227
3228
3229
3230
3231
3232 NullFields []string `json:"-"`
3233 }
3234
3235 func (s *ContentCategoriesListResponse) MarshalJSON() ([]byte, error) {
3236 type NoMethod ContentCategoriesListResponse
3237 raw := NoMethod(*s)
3238 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3239 }
3240
3241
3242
3243 type ContentCategory struct {
3244
3245
3246 AccountId int64 `json:"accountId,omitempty,string"`
3247
3248
3249
3250 Id int64 `json:"id,omitempty,string"`
3251
3252
3253
3254 Kind string `json:"kind,omitempty"`
3255
3256
3257
3258
3259 Name string `json:"name,omitempty"`
3260
3261
3262
3263 googleapi.ServerResponse `json:"-"`
3264
3265
3266
3267
3268
3269
3270
3271 ForceSendFields []string `json:"-"`
3272
3273
3274
3275
3276
3277
3278
3279 NullFields []string `json:"-"`
3280 }
3281
3282 func (s *ContentCategory) MarshalJSON() ([]byte, error) {
3283 type NoMethod ContentCategory
3284 raw := NoMethod(*s)
3285 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3286 }
3287
3288
3289
3290 type Conversion struct {
3291
3292
3293 ChildDirectedTreatment bool `json:"childDirectedTreatment,omitempty"`
3294
3295
3296 CustomVariables []*CustomFloodlightVariable `json:"customVariables,omitempty"`
3297
3298
3299
3300
3301
3302
3303 EncryptedUserId string `json:"encryptedUserId,omitempty"`
3304
3305
3306
3307
3308
3309
3310
3311
3312
3313
3314 EncryptedUserIdCandidates []string `json:"encryptedUserIdCandidates,omitempty"`
3315
3316
3317
3318 FloodlightActivityId int64 `json:"floodlightActivityId,omitempty,string"`
3319
3320
3321
3322 FloodlightConfigurationId int64 `json:"floodlightConfigurationId,omitempty,string"`
3323
3324
3325
3326
3327
3328 Gclid string `json:"gclid,omitempty"`
3329
3330
3331
3332 Kind string `json:"kind,omitempty"`
3333
3334
3335
3336
3337 LimitAdTracking bool `json:"limitAdTracking,omitempty"`
3338
3339
3340
3341
3342
3343 MobileDeviceId string `json:"mobileDeviceId,omitempty"`
3344
3345
3346
3347 NonPersonalizedAd bool `json:"nonPersonalizedAd,omitempty"`
3348
3349
3350
3351
3352 Ordinal string `json:"ordinal,omitempty"`
3353
3354
3355 Quantity int64 `json:"quantity,omitempty,string"`
3356
3357
3358
3359 TimestampMicros int64 `json:"timestampMicros,omitempty,string"`
3360
3361
3362
3363
3364 TreatmentForUnderage bool `json:"treatmentForUnderage,omitempty"`
3365
3366
3367 Value float64 `json:"value,omitempty"`
3368
3369
3370
3371
3372
3373
3374
3375
3376 ForceSendFields []string `json:"-"`
3377
3378
3379
3380
3381
3382
3383
3384
3385 NullFields []string `json:"-"`
3386 }
3387
3388 func (s *Conversion) MarshalJSON() ([]byte, error) {
3389 type NoMethod Conversion
3390 raw := NoMethod(*s)
3391 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3392 }
3393
3394 func (s *Conversion) UnmarshalJSON(data []byte) error {
3395 type NoMethod Conversion
3396 var s1 struct {
3397 Value gensupport.JSONFloat64 `json:"value"`
3398 *NoMethod
3399 }
3400 s1.NoMethod = (*NoMethod)(s)
3401 if err := json.Unmarshal(data, &s1); err != nil {
3402 return err
3403 }
3404 s.Value = float64(s1.Value)
3405 return nil
3406 }
3407
3408
3409
3410 type ConversionError struct {
3411
3412
3413
3414
3415
3416
3417
3418 Code string `json:"code,omitempty"`
3419
3420
3421
3422 Kind string `json:"kind,omitempty"`
3423
3424
3425 Message string `json:"message,omitempty"`
3426
3427
3428
3429
3430
3431
3432
3433 ForceSendFields []string `json:"-"`
3434
3435
3436
3437
3438
3439
3440
3441 NullFields []string `json:"-"`
3442 }
3443
3444 func (s *ConversionError) MarshalJSON() ([]byte, error) {
3445 type NoMethod ConversionError
3446 raw := NoMethod(*s)
3447 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3448 }
3449
3450
3451
3452 type ConversionStatus struct {
3453
3454 Conversion *Conversion `json:"conversion,omitempty"`
3455
3456
3457 Errors []*ConversionError `json:"errors,omitempty"`
3458
3459
3460
3461 Kind string `json:"kind,omitempty"`
3462
3463
3464
3465
3466
3467
3468
3469 ForceSendFields []string `json:"-"`
3470
3471
3472
3473
3474
3475
3476
3477 NullFields []string `json:"-"`
3478 }
3479
3480 func (s *ConversionStatus) MarshalJSON() ([]byte, error) {
3481 type NoMethod ConversionStatus
3482 raw := NoMethod(*s)
3483 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3484 }
3485
3486
3487 type ConversionsBatchInsertRequest struct {
3488
3489 Conversions []*Conversion `json:"conversions,omitempty"`
3490
3491
3492
3493
3494 EncryptionInfo *EncryptionInfo `json:"encryptionInfo,omitempty"`
3495
3496
3497
3498 Kind string `json:"kind,omitempty"`
3499
3500
3501
3502
3503
3504
3505
3506 ForceSendFields []string `json:"-"`
3507
3508
3509
3510
3511
3512
3513
3514 NullFields []string `json:"-"`
3515 }
3516
3517 func (s *ConversionsBatchInsertRequest) MarshalJSON() ([]byte, error) {
3518 type NoMethod ConversionsBatchInsertRequest
3519 raw := NoMethod(*s)
3520 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3521 }
3522
3523
3524 type ConversionsBatchInsertResponse struct {
3525
3526 HasFailures bool `json:"hasFailures,omitempty"`
3527
3528
3529
3530 Kind string `json:"kind,omitempty"`
3531
3532
3533
3534 Status []*ConversionStatus `json:"status,omitempty"`
3535
3536
3537
3538 googleapi.ServerResponse `json:"-"`
3539
3540
3541
3542
3543
3544
3545
3546 ForceSendFields []string `json:"-"`
3547
3548
3549
3550
3551
3552
3553
3554 NullFields []string `json:"-"`
3555 }
3556
3557 func (s *ConversionsBatchInsertResponse) MarshalJSON() ([]byte, error) {
3558 type NoMethod ConversionsBatchInsertResponse
3559 raw := NoMethod(*s)
3560 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3561 }
3562
3563
3564 type ConversionsBatchUpdateRequest struct {
3565
3566 Conversions []*Conversion `json:"conversions,omitempty"`
3567
3568
3569
3570 EncryptionInfo *EncryptionInfo `json:"encryptionInfo,omitempty"`
3571
3572
3573
3574 Kind string `json:"kind,omitempty"`
3575
3576
3577
3578
3579
3580
3581
3582 ForceSendFields []string `json:"-"`
3583
3584
3585
3586
3587
3588
3589
3590 NullFields []string `json:"-"`
3591 }
3592
3593 func (s *ConversionsBatchUpdateRequest) MarshalJSON() ([]byte, error) {
3594 type NoMethod ConversionsBatchUpdateRequest
3595 raw := NoMethod(*s)
3596 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3597 }
3598
3599
3600 type ConversionsBatchUpdateResponse struct {
3601
3602 HasFailures bool `json:"hasFailures,omitempty"`
3603
3604
3605
3606 Kind string `json:"kind,omitempty"`
3607
3608
3609
3610 Status []*ConversionStatus `json:"status,omitempty"`
3611
3612
3613
3614 googleapi.ServerResponse `json:"-"`
3615
3616
3617
3618
3619
3620
3621
3622 ForceSendFields []string `json:"-"`
3623
3624
3625
3626
3627
3628
3629
3630 NullFields []string `json:"-"`
3631 }
3632
3633 func (s *ConversionsBatchUpdateResponse) MarshalJSON() ([]byte, error) {
3634 type NoMethod ConversionsBatchUpdateResponse
3635 raw := NoMethod(*s)
3636 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3637 }
3638
3639
3640 type CountriesListResponse struct {
3641
3642 Countries []*Country `json:"countries,omitempty"`
3643
3644
3645
3646 Kind string `json:"kind,omitempty"`
3647
3648
3649
3650 googleapi.ServerResponse `json:"-"`
3651
3652
3653
3654
3655
3656
3657
3658 ForceSendFields []string `json:"-"`
3659
3660
3661
3662
3663
3664
3665
3666 NullFields []string `json:"-"`
3667 }
3668
3669 func (s *CountriesListResponse) MarshalJSON() ([]byte, error) {
3670 type NoMethod CountriesListResponse
3671 raw := NoMethod(*s)
3672 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3673 }
3674
3675
3676
3677 type Country struct {
3678
3679 CountryCode string `json:"countryCode,omitempty"`
3680
3681
3682
3683 DartId int64 `json:"dartId,omitempty,string"`
3684
3685
3686
3687 Kind string `json:"kind,omitempty"`
3688
3689
3690 Name string `json:"name,omitempty"`
3691
3692
3693
3694 SslEnabled bool `json:"sslEnabled,omitempty"`
3695
3696
3697
3698 googleapi.ServerResponse `json:"-"`
3699
3700
3701
3702
3703
3704
3705
3706 ForceSendFields []string `json:"-"`
3707
3708
3709
3710
3711
3712
3713
3714 NullFields []string `json:"-"`
3715 }
3716
3717 func (s *Country) MarshalJSON() ([]byte, error) {
3718 type NoMethod Country
3719 raw := NoMethod(*s)
3720 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3721 }
3722
3723
3724 type Creative struct {
3725
3726
3727
3728 AccountId int64 `json:"accountId,omitempty,string"`
3729
3730
3731
3732 Active bool `json:"active,omitempty"`
3733
3734
3735
3736
3737 AdParameters string `json:"adParameters,omitempty"`
3738
3739
3740
3741
3742
3743
3744
3745 AdTagKeys []string `json:"adTagKeys,omitempty"`
3746
3747
3748
3749
3750
3751 AdditionalSizes []*Size `json:"additionalSizes,omitempty"`
3752
3753
3754
3755 AdvertiserId int64 `json:"advertiserId,omitempty,string"`
3756
3757
3758
3759
3760
3761 AllowScriptAccess bool `json:"allowScriptAccess,omitempty"`
3762
3763
3764
3765 Archived bool `json:"archived,omitempty"`
3766
3767
3768
3769
3770
3771
3772
3773
3774
3775
3776 ArtworkType string `json:"artworkType,omitempty"`
3777
3778
3779
3780
3781
3782
3783
3784
3785
3786 AuthoringSource string `json:"authoringSource,omitempty"`
3787
3788
3789
3790
3791
3792
3793
3794
3795 AuthoringTool string `json:"authoringTool,omitempty"`
3796
3797
3798
3799
3800 AutoAdvanceImages bool `json:"autoAdvanceImages,omitempty"`
3801
3802
3803
3804
3805
3806 BackgroundColor string `json:"backgroundColor,omitempty"`
3807
3808
3809
3810
3811 BackupImageClickThroughUrl *CreativeClickThroughUrl `json:"backupImageClickThroughUrl,omitempty"`
3812
3813
3814
3815
3816
3817
3818
3819
3820
3821
3822
3823
3824
3825
3826
3827
3828
3829
3830
3831
3832
3833
3834
3835
3836
3837
3838
3839
3840
3841
3842
3843
3844
3845
3846
3847
3848
3849
3850
3851
3852
3853
3854
3855
3856
3857
3858
3859
3860
3861
3862
3863
3864
3865
3866
3867
3868
3869
3870
3871
3872
3873
3874
3875
3876
3877
3878
3879
3880
3881
3882
3883
3884
3885
3886
3887
3888
3889
3890
3891 BackupImageFeatures []string `json:"backupImageFeatures,omitempty"`
3892
3893
3894
3895
3896 BackupImageReportingLabel string `json:"backupImageReportingLabel,omitempty"`
3897
3898
3899
3900
3901 BackupImageTargetWindow *TargetWindow `json:"backupImageTargetWindow,omitempty"`
3902
3903
3904
3905
3906
3907
3908
3909
3910
3911
3912
3913
3914
3915
3916 ClickTags []*ClickTag `json:"clickTags,omitempty"`
3917
3918
3919
3920 CommercialId string `json:"commercialId,omitempty"`
3921
3922
3923
3924
3925
3926
3927 CompanionCreatives googleapi.Int64s `json:"companionCreatives,omitempty"`
3928
3929
3930
3931
3932
3933
3934
3935
3936
3937
3938
3939
3940
3941
3942
3943
3944
3945
3946
3947
3948
3949
3950
3951
3952
3953
3954
3955
3956 Compatibility []string `json:"compatibility,omitempty"`
3957
3958
3959
3960
3961
3962
3963
3964 ConvertFlashToHtml5 bool `json:"convertFlashToHtml5,omitempty"`
3965
3966
3967
3968
3969
3970 CounterCustomEvents []*CreativeCustomEvent `json:"counterCustomEvents,omitempty"`
3971
3972
3973 CreativeAssetSelection *CreativeAssetSelection `json:"creativeAssetSelection,omitempty"`
3974
3975
3976
3977
3978 CreativeAssets []*CreativeAsset `json:"creativeAssets,omitempty"`
3979
3980
3981
3982 CreativeFieldAssignments []*CreativeFieldAssignment `json:"creativeFieldAssignments,omitempty"`
3983
3984
3985
3986
3987
3988
3989
3990 CustomKeyValues []string `json:"customKeyValues,omitempty"`
3991
3992
3993
3994
3995
3996
3997
3998 DynamicAssetSelection bool `json:"dynamicAssetSelection,omitempty"`
3999
4000
4001
4002
4003
4004
4005
4006
4007 ExitCustomEvents []*CreativeCustomEvent `json:"exitCustomEvents,omitempty"`
4008
4009
4010
4011
4012
4013
4014 FsCommand *FsCommand `json:"fsCommand,omitempty"`
4015
4016
4017
4018
4019
4020 HtmlCode string `json:"htmlCode,omitempty"`
4021
4022
4023
4024
4025
4026 HtmlCodeLocked bool `json:"htmlCodeLocked,omitempty"`
4027
4028
4029
4030 Id int64 `json:"id,omitempty,string"`
4031
4032
4033
4034 IdDimensionValue *DimensionValue `json:"idDimensionValue,omitempty"`
4035
4036
4037
4038 Kind string `json:"kind,omitempty"`
4039
4040
4041
4042 LastModifiedInfo *LastModifiedInfo `json:"lastModifiedInfo,omitempty"`
4043
4044
4045
4046
4047
4048 LatestTraffickedCreativeId int64 `json:"latestTraffickedCreativeId,omitempty,string"`
4049
4050
4051
4052
4053 MediaDescription string `json:"mediaDescription,omitempty"`
4054
4055
4056
4057
4058 MediaDuration float64 `json:"mediaDuration,omitempty"`
4059
4060
4061
4062 Name string `json:"name,omitempty"`
4063
4064
4065
4066 OverrideCss string `json:"overrideCss,omitempty"`
4067
4068
4069
4070 PoliteLoadAssetId int64 `json:"politeLoadAssetId,omitempty,string"`
4071
4072
4073
4074 ProgressOffset *VideoOffset `json:"progressOffset,omitempty"`
4075
4076
4077
4078
4079
4080
4081
4082
4083 RedirectUrl string `json:"redirectUrl,omitempty"`
4084
4085
4086
4087 RenderingId int64 `json:"renderingId,omitempty,string"`
4088
4089
4090
4091
4092 RenderingIdDimensionValue *DimensionValue `json:"renderingIdDimensionValue,omitempty"`
4093
4094
4095
4096
4097
4098 RequiredFlashPluginVersion string `json:"requiredFlashPluginVersion,omitempty"`
4099
4100
4101
4102
4103
4104 RequiredFlashVersion int64 `json:"requiredFlashVersion,omitempty"`
4105
4106
4107
4108
4109
4110
4111
4112
4113
4114
4115 Size *Size `json:"size,omitempty"`
4116
4117
4118
4119
4120 SkipOffset *VideoOffset `json:"skipOffset,omitempty"`
4121
4122
4123
4124
4125 Skippable bool `json:"skippable,omitempty"`
4126
4127
4128
4129 SslCompliant bool `json:"sslCompliant,omitempty"`
4130
4131
4132
4133 SslOverride bool `json:"sslOverride,omitempty"`
4134
4135
4136
4137
4138 StudioAdvertiserId int64 `json:"studioAdvertiserId,omitempty,string"`
4139
4140
4141
4142
4143 StudioCreativeId int64 `json:"studioCreativeId,omitempty,string"`
4144
4145
4146
4147
4148
4149 StudioTraffickedCreativeId int64 `json:"studioTraffickedCreativeId,omitempty,string"`
4150
4151
4152
4153
4154 SubaccountId int64 `json:"subaccountId,omitempty,string"`
4155
4156
4157
4158
4159 ThirdPartyBackupImageImpressionsUrl string `json:"thirdPartyBackupImageImpressionsUrl,omitempty"`
4160
4161
4162
4163
4164 ThirdPartyRichMediaImpressionsUrl string `json:"thirdPartyRichMediaImpressionsUrl,omitempty"`
4165
4166
4167
4168
4169 ThirdPartyUrls []*ThirdPartyTrackingUrl `json:"thirdPartyUrls,omitempty"`
4170
4171
4172
4173
4174
4175
4176 TimerCustomEvents []*CreativeCustomEvent `json:"timerCustomEvents,omitempty"`
4177
4178
4179
4180
4181 TotalFileSize int64 `json:"totalFileSize,omitempty,string"`
4182
4183
4184
4185
4186
4187
4188
4189
4190
4191
4192
4193
4194
4195
4196
4197
4198
4199
4200
4201
4202
4203
4204
4205
4206
4207
4208
4209
4210
4211
4212
4213
4214
4215
4216 Type string `json:"type,omitempty"`
4217
4218
4219
4220
4221 UniversalAdId *UniversalAdId `json:"universalAdId,omitempty"`
4222
4223
4224
4225
4226
4227
4228
4229
4230
4231 Version int64 `json:"version,omitempty"`
4232
4233
4234
4235 googleapi.ServerResponse `json:"-"`
4236
4237
4238
4239
4240
4241
4242
4243 ForceSendFields []string `json:"-"`
4244
4245
4246
4247
4248
4249
4250
4251 NullFields []string `json:"-"`
4252 }
4253
4254 func (s *Creative) MarshalJSON() ([]byte, error) {
4255 type NoMethod Creative
4256 raw := NoMethod(*s)
4257 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
4258 }
4259
4260 func (s *Creative) UnmarshalJSON(data []byte) error {
4261 type NoMethod Creative
4262 var s1 struct {
4263 MediaDuration gensupport.JSONFloat64 `json:"mediaDuration"`
4264 *NoMethod
4265 }
4266 s1.NoMethod = (*NoMethod)(s)
4267 if err := json.Unmarshal(data, &s1); err != nil {
4268 return err
4269 }
4270 s.MediaDuration = float64(s1.MediaDuration)
4271 return nil
4272 }
4273
4274
4275 type CreativeAsset struct {
4276
4277
4278
4279
4280 ActionScript3 bool `json:"actionScript3,omitempty"`
4281
4282
4283
4284
4285
4286 Active bool `json:"active,omitempty"`
4287
4288
4289
4290
4291 AdditionalSizes []*Size `json:"additionalSizes,omitempty"`
4292
4293
4294
4295
4296
4297
4298
4299
4300
4301
4302 Alignment string `json:"alignment,omitempty"`
4303
4304
4305
4306
4307
4308
4309
4310
4311
4312 ArtworkType string `json:"artworkType,omitempty"`
4313
4314
4315
4316
4317
4318 AssetIdentifier *CreativeAssetId `json:"assetIdentifier,omitempty"`
4319
4320
4321
4322 BackupImageExit *CreativeCustomEvent `json:"backupImageExit,omitempty"`
4323
4324
4325
4326
4327 BitRate int64 `json:"bitRate,omitempty"`
4328
4329
4330
4331
4332
4333
4334
4335
4336
4337 ChildAssetType string `json:"childAssetType,omitempty"`
4338
4339
4340
4341
4342
4343 CollapsedSize *Size `json:"collapsedSize,omitempty"`
4344
4345
4346
4347
4348
4349 CompanionCreativeIds googleapi.Int64s `json:"companionCreativeIds,omitempty"`
4350
4351
4352
4353
4354 CustomStartTimeValue int64 `json:"customStartTimeValue,omitempty"`
4355
4356
4357
4358
4359
4360
4361
4362
4363
4364
4365
4366
4367
4368
4369
4370
4371
4372
4373
4374
4375
4376
4377
4378
4379
4380
4381
4382
4383
4384
4385
4386
4387
4388
4389
4390
4391
4392
4393
4394
4395
4396
4397
4398
4399
4400
4401
4402
4403
4404
4405
4406
4407
4408
4409
4410
4411
4412
4413
4414
4415
4416
4417
4418
4419
4420
4421
4422
4423
4424
4425
4426
4427
4428
4429
4430 DetectedFeatures []string `json:"detectedFeatures,omitempty"`
4431
4432
4433
4434
4435
4436
4437
4438
4439
4440
4441
4442
4443
4444
4445
4446 DisplayType string `json:"displayType,omitempty"`
4447
4448
4449
4450
4451
4452 Duration int64 `json:"duration,omitempty"`
4453
4454
4455
4456
4457
4458
4459
4460
4461 DurationType string `json:"durationType,omitempty"`
4462
4463
4464
4465
4466 ExpandedDimension *Size `json:"expandedDimension,omitempty"`
4467
4468
4469
4470
4471 FileSize int64 `json:"fileSize,omitempty,string"`
4472
4473
4474
4475
4476
4477 FlashVersion int64 `json:"flashVersion,omitempty"`
4478
4479
4480
4481 HideFlashObjects bool `json:"hideFlashObjects,omitempty"`
4482
4483
4484
4485 HideSelectionBoxes bool `json:"hideSelectionBoxes,omitempty"`
4486
4487
4488
4489
4490 HorizontallyLocked bool `json:"horizontallyLocked,omitempty"`
4491
4492
4493
4494
4495 Id int64 `json:"id,omitempty,string"`
4496
4497
4498
4499 IdDimensionValue *DimensionValue `json:"idDimensionValue,omitempty"`
4500
4501
4502
4503
4504 MediaDuration float64 `json:"mediaDuration,omitempty"`
4505
4506
4507
4508
4509 MimeType string `json:"mimeType,omitempty"`
4510
4511
4512
4513
4514
4515
4516 Offset *OffsetPosition `json:"offset,omitempty"`
4517
4518
4519
4520
4521
4522
4523
4524
4525 Orientation string `json:"orientation,omitempty"`
4526
4527
4528
4529
4530 OriginalBackup bool `json:"originalBackup,omitempty"`
4531
4532
4533
4534 Position *OffsetPosition `json:"position,omitempty"`
4535
4536
4537
4538
4539
4540
4541
4542
4543 PositionLeftUnit string `json:"positionLeftUnit,omitempty"`
4544
4545
4546
4547
4548
4549
4550
4551
4552
4553 PositionTopUnit string `json:"positionTopUnit,omitempty"`
4554
4555
4556
4557
4558 ProgressiveServingUrl string `json:"progressiveServingUrl,omitempty"`
4559
4560
4561
4562
4563
4564
4565 Pushdown bool `json:"pushdown,omitempty"`
4566
4567
4568
4569
4570
4571
4572
4573 PushdownDuration float64 `json:"pushdownDuration,omitempty"`
4574
4575
4576
4577
4578
4579
4580
4581
4582
4583
4584
4585
4586
4587
4588
4589
4590
4591
4592
4593
4594
4595
4596
4597
4598
4599
4600
4601
4602
4603
4604
4605
4606
4607
4608
4609
4610
4611
4612
4613
4614
4615
4616
4617
4618
4619
4620
4621 Role string `json:"role,omitempty"`
4622
4623
4624
4625
4626
4627
4628
4629
4630 Size *Size `json:"size,omitempty"`
4631
4632
4633
4634
4635 SslCompliant bool `json:"sslCompliant,omitempty"`
4636
4637
4638
4639
4640
4641
4642
4643 StartTimeType string `json:"startTimeType,omitempty"`
4644
4645
4646
4647
4648 StreamingServingUrl string `json:"streamingServingUrl,omitempty"`
4649
4650
4651
4652
4653 Transparency bool `json:"transparency,omitempty"`
4654
4655
4656
4657
4658 VerticallyLocked bool `json:"verticallyLocked,omitempty"`
4659
4660
4661
4662
4663
4664
4665
4666
4667
4668
4669 WindowMode string `json:"windowMode,omitempty"`
4670
4671
4672
4673
4674
4675
4676 ZIndex int64 `json:"zIndex,omitempty"`
4677
4678
4679
4680 ZipFilename string `json:"zipFilename,omitempty"`
4681
4682
4683
4684 ZipFilesize string `json:"zipFilesize,omitempty"`
4685
4686
4687
4688
4689
4690
4691
4692 ForceSendFields []string `json:"-"`
4693
4694
4695
4696
4697
4698
4699
4700 NullFields []string `json:"-"`
4701 }
4702
4703 func (s *CreativeAsset) MarshalJSON() ([]byte, error) {
4704 type NoMethod CreativeAsset
4705 raw := NoMethod(*s)
4706 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
4707 }
4708
4709 func (s *CreativeAsset) UnmarshalJSON(data []byte) error {
4710 type NoMethod CreativeAsset
4711 var s1 struct {
4712 MediaDuration gensupport.JSONFloat64 `json:"mediaDuration"`
4713 PushdownDuration gensupport.JSONFloat64 `json:"pushdownDuration"`
4714 *NoMethod
4715 }
4716 s1.NoMethod = (*NoMethod)(s)
4717 if err := json.Unmarshal(data, &s1); err != nil {
4718 return err
4719 }
4720 s.MediaDuration = float64(s1.MediaDuration)
4721 s.PushdownDuration = float64(s1.PushdownDuration)
4722 return nil
4723 }
4724
4725
4726 type CreativeAssetId struct {
4727
4728
4729
4730
4731 Name string `json:"name,omitempty"`
4732
4733
4734
4735
4736
4737
4738
4739
4740
4741
4742
4743
4744 Type string `json:"type,omitempty"`
4745
4746
4747
4748
4749
4750
4751
4752 ForceSendFields []string `json:"-"`
4753
4754
4755
4756
4757
4758
4759
4760 NullFields []string `json:"-"`
4761 }
4762
4763 func (s *CreativeAssetId) MarshalJSON() ([]byte, error) {
4764 type NoMethod CreativeAssetId
4765 raw := NoMethod(*s)
4766 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
4767 }
4768
4769
4770
4771
4772
4773 type CreativeAssetMetadata struct {
4774
4775 AssetIdentifier *CreativeAssetId `json:"assetIdentifier,omitempty"`
4776
4777
4778
4779 ClickTags []*ClickTag `json:"clickTags,omitempty"`
4780
4781
4782
4783
4784
4785
4786
4787
4788
4789
4790
4791
4792
4793
4794
4795
4796
4797
4798
4799
4800
4801
4802
4803
4804
4805
4806
4807
4808
4809
4810
4811
4812
4813
4814
4815
4816
4817
4818
4819
4820
4821
4822
4823
4824
4825
4826
4827
4828
4829
4830
4831
4832
4833
4834
4835
4836
4837
4838
4839
4840
4841
4842
4843
4844
4845
4846
4847
4848
4849
4850
4851
4852
4853
4854 DetectedFeatures []string `json:"detectedFeatures,omitempty"`
4855
4856
4857
4858 Id int64 `json:"id,omitempty,string"`
4859
4860
4861
4862 IdDimensionValue *DimensionValue `json:"idDimensionValue,omitempty"`
4863
4864
4865
4866 Kind string `json:"kind,omitempty"`
4867
4868
4869
4870
4871
4872
4873
4874
4875
4876
4877
4878
4879
4880
4881
4882
4883
4884
4885
4886
4887
4888
4889
4890
4891
4892
4893
4894
4895
4896
4897
4898
4899
4900
4901
4902
4903
4904
4905
4906
4907
4908
4909
4910
4911
4912
4913
4914
4915
4916
4917
4918
4919
4920
4921
4922
4923 WarnedValidationRules []string `json:"warnedValidationRules,omitempty"`
4924
4925
4926
4927 googleapi.ServerResponse `json:"-"`
4928
4929
4930
4931
4932
4933
4934
4935 ForceSendFields []string `json:"-"`
4936
4937
4938
4939
4940
4941
4942
4943
4944 NullFields []string `json:"-"`
4945 }
4946
4947 func (s *CreativeAssetMetadata) MarshalJSON() ([]byte, error) {
4948 type NoMethod CreativeAssetMetadata
4949 raw := NoMethod(*s)
4950 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
4951 }
4952
4953
4954
4955
4956 type CreativeAssetSelection struct {
4957
4958
4959
4960 DefaultAssetId int64 `json:"defaultAssetId,omitempty,string"`
4961
4962
4963
4964
4965
4966 Rules []*Rule `json:"rules,omitempty"`
4967
4968
4969
4970
4971
4972
4973
4974 ForceSendFields []string `json:"-"`
4975
4976
4977
4978
4979
4980
4981
4982
4983 NullFields []string `json:"-"`
4984 }
4985
4986 func (s *CreativeAssetSelection) MarshalJSON() ([]byte, error) {
4987 type NoMethod CreativeAssetSelection
4988 raw := NoMethod(*s)
4989 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
4990 }
4991
4992
4993 type CreativeAssignment struct {
4994
4995
4996 Active bool `json:"active,omitempty"`
4997
4998
4999
5000
5001
5002
5003 ApplyEventTags bool `json:"applyEventTags,omitempty"`
5004
5005
5006 ClickThroughUrl *ClickThroughUrl `json:"clickThroughUrl,omitempty"`
5007
5008
5009
5010 CompanionCreativeOverrides []*CompanionClickThroughOverride `json:"companionCreativeOverrides,omitempty"`
5011
5012
5013
5014
5015 CreativeGroupAssignments []*CreativeGroupAssignment `json:"creativeGroupAssignments,omitempty"`
5016
5017
5018
5019 CreativeId int64 `json:"creativeId,omitempty,string"`
5020
5021
5022
5023 CreativeIdDimensionValue *DimensionValue `json:"creativeIdDimensionValue,omitempty"`
5024
5025
5026
5027 EndTime string `json:"endTime,omitempty"`
5028
5029
5030
5031
5032
5033
5034
5035
5036
5037
5038
5039
5040
5041
5042
5043 RichMediaExitOverrides []*RichMediaExitOverride `json:"richMediaExitOverrides,omitempty"`
5044
5045
5046
5047
5048 Sequence int64 `json:"sequence,omitempty"`
5049
5050
5051
5052
5053 SslCompliant bool `json:"sslCompliant,omitempty"`
5054
5055
5056
5057 StartTime string `json:"startTime,omitempty"`
5058
5059
5060
5061
5062 Weight int64 `json:"weight,omitempty"`
5063
5064
5065
5066
5067
5068
5069
5070 ForceSendFields []string `json:"-"`
5071
5072
5073
5074
5075
5076
5077
5078 NullFields []string `json:"-"`
5079 }
5080
5081 func (s *CreativeAssignment) MarshalJSON() ([]byte, error) {
5082 type NoMethod CreativeAssignment
5083 raw := NoMethod(*s)
5084 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5085 }
5086
5087
5088 type CreativeClickThroughUrl struct {
5089
5090
5091
5092
5093
5094
5095 ComputedClickThroughUrl string `json:"computedClickThroughUrl,omitempty"`
5096
5097
5098
5099 CustomClickThroughUrl string `json:"customClickThroughUrl,omitempty"`
5100
5101
5102 LandingPageId int64 `json:"landingPageId,omitempty,string"`
5103
5104
5105
5106
5107
5108
5109
5110
5111 ForceSendFields []string `json:"-"`
5112
5113
5114
5115
5116
5117
5118
5119
5120 NullFields []string `json:"-"`
5121 }
5122
5123 func (s *CreativeClickThroughUrl) MarshalJSON() ([]byte, error) {
5124 type NoMethod CreativeClickThroughUrl
5125 raw := NoMethod(*s)
5126 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5127 }
5128
5129
5130 type CreativeCustomEvent struct {
5131
5132
5133 AdvertiserCustomEventId int64 `json:"advertiserCustomEventId,omitempty,string"`
5134
5135
5136 AdvertiserCustomEventName string `json:"advertiserCustomEventName,omitempty"`
5137
5138
5139
5140
5141
5142
5143
5144
5145 AdvertiserCustomEventType string `json:"advertiserCustomEventType,omitempty"`
5146
5147
5148
5149
5150 ArtworkLabel string `json:"artworkLabel,omitempty"`
5151
5152
5153
5154
5155
5156
5157
5158
5159
5160 ArtworkType string `json:"artworkType,omitempty"`
5161
5162
5163
5164 ExitClickThroughUrl *CreativeClickThroughUrl `json:"exitClickThroughUrl,omitempty"`
5165
5166
5167
5168 Id int64 `json:"id,omitempty,string"`
5169
5170
5171
5172 PopupWindowProperties *PopupWindowProperties `json:"popupWindowProperties,omitempty"`
5173
5174
5175
5176
5177
5178
5179
5180
5181
5182 TargetType string `json:"targetType,omitempty"`
5183
5184
5185
5186 VideoReportingId string `json:"videoReportingId,omitempty"`
5187
5188
5189
5190
5191
5192
5193
5194
5195 ForceSendFields []string `json:"-"`
5196
5197
5198
5199
5200
5201
5202
5203
5204 NullFields []string `json:"-"`
5205 }
5206
5207 func (s *CreativeCustomEvent) MarshalJSON() ([]byte, error) {
5208 type NoMethod CreativeCustomEvent
5209 raw := NoMethod(*s)
5210 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5211 }
5212
5213
5214 type CreativeField struct {
5215
5216
5217 AccountId int64 `json:"accountId,omitempty,string"`
5218
5219
5220
5221 AdvertiserId int64 `json:"advertiserId,omitempty,string"`
5222
5223
5224
5225 AdvertiserIdDimensionValue *DimensionValue `json:"advertiserIdDimensionValue,omitempty"`
5226
5227
5228
5229 Id int64 `json:"id,omitempty,string"`
5230
5231
5232
5233 Kind string `json:"kind,omitempty"`
5234
5235
5236
5237
5238 Name string `json:"name,omitempty"`
5239
5240
5241
5242 SubaccountId int64 `json:"subaccountId,omitempty,string"`
5243
5244
5245
5246 googleapi.ServerResponse `json:"-"`
5247
5248
5249
5250
5251
5252
5253
5254 ForceSendFields []string `json:"-"`
5255
5256
5257
5258
5259
5260
5261
5262 NullFields []string `json:"-"`
5263 }
5264
5265 func (s *CreativeField) MarshalJSON() ([]byte, error) {
5266 type NoMethod CreativeField
5267 raw := NoMethod(*s)
5268 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5269 }
5270
5271
5272 type CreativeFieldAssignment struct {
5273
5274 CreativeFieldId int64 `json:"creativeFieldId,omitempty,string"`
5275
5276
5277 CreativeFieldValueId int64 `json:"creativeFieldValueId,omitempty,string"`
5278
5279
5280
5281
5282
5283
5284
5285 ForceSendFields []string `json:"-"`
5286
5287
5288
5289
5290
5291
5292
5293
5294 NullFields []string `json:"-"`
5295 }
5296
5297 func (s *CreativeFieldAssignment) MarshalJSON() ([]byte, error) {
5298 type NoMethod CreativeFieldAssignment
5299 raw := NoMethod(*s)
5300 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5301 }
5302
5303
5304 type CreativeFieldValue struct {
5305
5306
5307 Id int64 `json:"id,omitempty,string"`
5308
5309
5310
5311 Kind string `json:"kind,omitempty"`
5312
5313
5314
5315 Value string `json:"value,omitempty"`
5316
5317
5318
5319 googleapi.ServerResponse `json:"-"`
5320
5321
5322
5323
5324
5325
5326
5327 ForceSendFields []string `json:"-"`
5328
5329
5330
5331
5332
5333
5334
5335 NullFields []string `json:"-"`
5336 }
5337
5338 func (s *CreativeFieldValue) MarshalJSON() ([]byte, error) {
5339 type NoMethod CreativeFieldValue
5340 raw := NoMethod(*s)
5341 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5342 }
5343
5344
5345 type CreativeFieldValuesListResponse struct {
5346
5347 CreativeFieldValues []*CreativeFieldValue `json:"creativeFieldValues,omitempty"`
5348
5349
5350
5351 Kind string `json:"kind,omitempty"`
5352
5353
5354
5355 NextPageToken string `json:"nextPageToken,omitempty"`
5356
5357
5358
5359 googleapi.ServerResponse `json:"-"`
5360
5361
5362
5363
5364
5365
5366
5367 ForceSendFields []string `json:"-"`
5368
5369
5370
5371
5372
5373
5374
5375
5376 NullFields []string `json:"-"`
5377 }
5378
5379 func (s *CreativeFieldValuesListResponse) MarshalJSON() ([]byte, error) {
5380 type NoMethod CreativeFieldValuesListResponse
5381 raw := NoMethod(*s)
5382 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5383 }
5384
5385
5386 type CreativeFieldsListResponse struct {
5387
5388 CreativeFields []*CreativeField `json:"creativeFields,omitempty"`
5389
5390
5391
5392 Kind string `json:"kind,omitempty"`
5393
5394
5395
5396 NextPageToken string `json:"nextPageToken,omitempty"`
5397
5398
5399
5400 googleapi.ServerResponse `json:"-"`
5401
5402
5403
5404
5405
5406
5407
5408 ForceSendFields []string `json:"-"`
5409
5410
5411
5412
5413
5414
5415
5416
5417 NullFields []string `json:"-"`
5418 }
5419
5420 func (s *CreativeFieldsListResponse) MarshalJSON() ([]byte, error) {
5421 type NoMethod CreativeFieldsListResponse
5422 raw := NoMethod(*s)
5423 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5424 }
5425
5426
5427 type CreativeGroup struct {
5428
5429
5430 AccountId int64 `json:"accountId,omitempty,string"`
5431
5432
5433
5434 AdvertiserId int64 `json:"advertiserId,omitempty,string"`
5435
5436
5437
5438 AdvertiserIdDimensionValue *DimensionValue `json:"advertiserIdDimensionValue,omitempty"`
5439
5440
5441
5442
5443
5444 GroupNumber int64 `json:"groupNumber,omitempty"`
5445
5446
5447
5448 Id int64 `json:"id,omitempty,string"`
5449
5450
5451
5452 Kind string `json:"kind,omitempty"`
5453
5454
5455
5456
5457 Name string `json:"name,omitempty"`
5458
5459
5460
5461 SubaccountId int64 `json:"subaccountId,omitempty,string"`
5462
5463
5464
5465 googleapi.ServerResponse `json:"-"`
5466
5467
5468
5469
5470
5471
5472
5473 ForceSendFields []string `json:"-"`
5474
5475
5476
5477
5478
5479
5480
5481 NullFields []string `json:"-"`
5482 }
5483
5484 func (s *CreativeGroup) MarshalJSON() ([]byte, error) {
5485 type NoMethod CreativeGroup
5486 raw := NoMethod(*s)
5487 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5488 }
5489
5490
5491 type CreativeGroupAssignment struct {
5492
5493 CreativeGroupId int64 `json:"creativeGroupId,omitempty,string"`
5494
5495
5496
5497
5498
5499
5500
5501 CreativeGroupNumber string `json:"creativeGroupNumber,omitempty"`
5502
5503
5504
5505
5506
5507
5508
5509 ForceSendFields []string `json:"-"`
5510
5511
5512
5513
5514
5515
5516
5517
5518 NullFields []string `json:"-"`
5519 }
5520
5521 func (s *CreativeGroupAssignment) MarshalJSON() ([]byte, error) {
5522 type NoMethod CreativeGroupAssignment
5523 raw := NoMethod(*s)
5524 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5525 }
5526
5527
5528 type CreativeGroupsListResponse struct {
5529
5530 CreativeGroups []*CreativeGroup `json:"creativeGroups,omitempty"`
5531
5532
5533
5534 Kind string `json:"kind,omitempty"`
5535
5536
5537
5538 NextPageToken string `json:"nextPageToken,omitempty"`
5539
5540
5541
5542 googleapi.ServerResponse `json:"-"`
5543
5544
5545
5546
5547
5548
5549
5550 ForceSendFields []string `json:"-"`
5551
5552
5553
5554
5555
5556
5557
5558
5559 NullFields []string `json:"-"`
5560 }
5561
5562 func (s *CreativeGroupsListResponse) MarshalJSON() ([]byte, error) {
5563 type NoMethod CreativeGroupsListResponse
5564 raw := NoMethod(*s)
5565 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5566 }
5567
5568
5569 type CreativeOptimizationConfiguration struct {
5570
5571
5572
5573 Id int64 `json:"id,omitempty,string"`
5574
5575
5576
5577 Name string `json:"name,omitempty"`
5578
5579
5580
5581 OptimizationActivitys []*OptimizationActivity `json:"optimizationActivitys,omitempty"`
5582
5583
5584
5585
5586
5587
5588
5589
5590
5591 OptimizationModel string `json:"optimizationModel,omitempty"`
5592
5593
5594
5595
5596
5597
5598
5599 ForceSendFields []string `json:"-"`
5600
5601
5602
5603
5604
5605
5606
5607 NullFields []string `json:"-"`
5608 }
5609
5610 func (s *CreativeOptimizationConfiguration) MarshalJSON() ([]byte, error) {
5611 type NoMethod CreativeOptimizationConfiguration
5612 raw := NoMethod(*s)
5613 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5614 }
5615
5616
5617 type CreativeRotation struct {
5618
5619 CreativeAssignments []*CreativeAssignment `json:"creativeAssignments,omitempty"`
5620
5621
5622
5623
5624
5625
5626 CreativeOptimizationConfigurationId int64 `json:"creativeOptimizationConfigurationId,omitempty,string"`
5627
5628
5629
5630
5631
5632
5633
5634 Type string `json:"type,omitempty"`
5635
5636
5637
5638
5639
5640
5641
5642
5643
5644 WeightCalculationStrategy string `json:"weightCalculationStrategy,omitempty"`
5645
5646
5647
5648
5649
5650
5651
5652 ForceSendFields []string `json:"-"`
5653
5654
5655
5656
5657
5658
5659
5660
5661 NullFields []string `json:"-"`
5662 }
5663
5664 func (s *CreativeRotation) MarshalJSON() ([]byte, error) {
5665 type NoMethod CreativeRotation
5666 raw := NoMethod(*s)
5667 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5668 }
5669
5670
5671 type CreativeSettings struct {
5672
5673
5674 IFrameFooter string `json:"iFrameFooter,omitempty"`
5675
5676
5677
5678 IFrameHeader string `json:"iFrameHeader,omitempty"`
5679
5680
5681
5682
5683
5684
5685
5686 ForceSendFields []string `json:"-"`
5687
5688
5689
5690
5691
5692
5693
5694 NullFields []string `json:"-"`
5695 }
5696
5697 func (s *CreativeSettings) MarshalJSON() ([]byte, error) {
5698 type NoMethod CreativeSettings
5699 raw := NoMethod(*s)
5700 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5701 }
5702
5703
5704 type CreativesListResponse struct {
5705
5706 Creatives []*Creative `json:"creatives,omitempty"`
5707
5708
5709
5710 Kind string `json:"kind,omitempty"`
5711
5712
5713
5714 NextPageToken string `json:"nextPageToken,omitempty"`
5715
5716
5717
5718 googleapi.ServerResponse `json:"-"`
5719
5720
5721
5722
5723
5724
5725
5726 ForceSendFields []string `json:"-"`
5727
5728
5729
5730
5731
5732
5733
5734 NullFields []string `json:"-"`
5735 }
5736
5737 func (s *CreativesListResponse) MarshalJSON() ([]byte, error) {
5738 type NoMethod CreativesListResponse
5739 raw := NoMethod(*s)
5740 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5741 }
5742
5743
5744
5745
5746 type CrossDimensionReachReportCompatibleFields struct {
5747
5748
5749 Breakdown []*Dimension `json:"breakdown,omitempty"`
5750
5751
5752
5753 DimensionFilters []*Dimension `json:"dimensionFilters,omitempty"`
5754
5755
5756
5757 Kind string `json:"kind,omitempty"`
5758
5759
5760
5761 Metrics []*Metric `json:"metrics,omitempty"`
5762
5763
5764
5765 OverlapMetrics []*Metric `json:"overlapMetrics,omitempty"`
5766
5767
5768
5769
5770
5771
5772
5773 ForceSendFields []string `json:"-"`
5774
5775
5776
5777
5778
5779
5780
5781 NullFields []string `json:"-"`
5782 }
5783
5784 func (s *CrossDimensionReachReportCompatibleFields) MarshalJSON() ([]byte, error) {
5785 type NoMethod CrossDimensionReachReportCompatibleFields
5786 raw := NoMethod(*s)
5787 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5788 }
5789
5790
5791 type CustomFloodlightVariable struct {
5792
5793
5794 Kind string `json:"kind,omitempty"`
5795
5796
5797
5798
5799
5800
5801
5802
5803
5804
5805
5806
5807
5808
5809
5810
5811
5812
5813
5814
5815
5816
5817
5818
5819
5820
5821
5822
5823
5824
5825
5826
5827
5828
5829
5830
5831
5832
5833
5834
5835
5836
5837
5838
5839
5840
5841
5842
5843
5844
5845
5846
5847
5848
5849
5850
5851
5852
5853
5854
5855
5856
5857
5858
5859
5860
5861
5862
5863
5864
5865
5866
5867
5868
5869
5870
5871
5872
5873
5874
5875
5876
5877
5878
5879
5880
5881
5882
5883
5884
5885
5886
5887
5888
5889
5890
5891
5892
5893
5894
5895
5896
5897
5898
5899
5900 Type string `json:"type,omitempty"`
5901
5902
5903
5904 Value string `json:"value,omitempty"`
5905
5906
5907
5908
5909
5910
5911
5912 ForceSendFields []string `json:"-"`
5913
5914
5915
5916
5917
5918
5919
5920 NullFields []string `json:"-"`
5921 }
5922
5923 func (s *CustomFloodlightVariable) MarshalJSON() ([]byte, error) {
5924 type NoMethod CustomFloodlightVariable
5925 raw := NoMethod(*s)
5926 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5927 }
5928
5929
5930 type CustomRichMediaEvents struct {
5931
5932
5933 FilteredEventIds []*DimensionValue `json:"filteredEventIds,omitempty"`
5934
5935
5936
5937 Kind string `json:"kind,omitempty"`
5938
5939
5940
5941
5942
5943
5944
5945 ForceSendFields []string `json:"-"`
5946
5947
5948
5949
5950
5951
5952
5953
5954 NullFields []string `json:"-"`
5955 }
5956
5957 func (s *CustomRichMediaEvents) MarshalJSON() ([]byte, error) {
5958 type NoMethod CustomRichMediaEvents
5959 raw := NoMethod(*s)
5960 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5961 }
5962
5963
5964 type DateRange struct {
5965
5966
5967 EndDate string `json:"endDate,omitempty"`
5968
5969
5970
5971 Kind string `json:"kind,omitempty"`
5972
5973
5974
5975
5976
5977
5978
5979
5980
5981
5982
5983
5984
5985
5986
5987
5988
5989
5990
5991
5992
5993
5994 RelativeDateRange string `json:"relativeDateRange,omitempty"`
5995
5996
5997
5998 StartDate string `json:"startDate,omitempty"`
5999
6000
6001
6002
6003
6004
6005
6006 ForceSendFields []string `json:"-"`
6007
6008
6009
6010
6011
6012
6013
6014 NullFields []string `json:"-"`
6015 }
6016
6017 func (s *DateRange) MarshalJSON() ([]byte, error) {
6018 type NoMethod DateRange
6019 raw := NoMethod(*s)
6020 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6021 }
6022
6023
6024 type DayPartTargeting struct {
6025
6026
6027
6028
6029
6030
6031
6032
6033
6034
6035
6036
6037
6038
6039
6040
6041
6042
6043
6044 DaysOfWeek []string `json:"daysOfWeek,omitempty"`
6045
6046
6047
6048
6049
6050
6051
6052
6053 HoursOfDay []int64 `json:"hoursOfDay,omitempty"`
6054
6055
6056
6057 UserLocalTime bool `json:"userLocalTime,omitempty"`
6058
6059
6060
6061
6062
6063
6064
6065 ForceSendFields []string `json:"-"`
6066
6067
6068
6069
6070
6071
6072
6073 NullFields []string `json:"-"`
6074 }
6075
6076 func (s *DayPartTargeting) MarshalJSON() ([]byte, error) {
6077 type NoMethod DayPartTargeting
6078 raw := NoMethod(*s)
6079 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6080 }
6081
6082
6083 type DeepLink struct {
6084
6085 AppUrl string `json:"appUrl,omitempty"`
6086
6087
6088
6089 FallbackUrl string `json:"fallbackUrl,omitempty"`
6090
6091
6092
6093 Kind string `json:"kind,omitempty"`
6094
6095
6096 MobileApp *MobileApp `json:"mobileApp,omitempty"`
6097
6098
6099
6100
6101 RemarketingListIds googleapi.Int64s `json:"remarketingListIds,omitempty"`
6102
6103
6104
6105
6106
6107
6108
6109 ForceSendFields []string `json:"-"`
6110
6111
6112
6113
6114
6115
6116
6117 NullFields []string `json:"-"`
6118 }
6119
6120 func (s *DeepLink) MarshalJSON() ([]byte, error) {
6121 type NoMethod DeepLink
6122 raw := NoMethod(*s)
6123 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6124 }
6125
6126
6127
6128
6129
6130 type DefaultClickThroughEventTagProperties struct {
6131
6132
6133 DefaultClickThroughEventTagId int64 `json:"defaultClickThroughEventTagId,omitempty,string"`
6134
6135
6136
6137 OverrideInheritedEventTag bool `json:"overrideInheritedEventTag,omitempty"`
6138
6139
6140
6141
6142
6143
6144
6145
6146 ForceSendFields []string `json:"-"`
6147
6148
6149
6150
6151
6152
6153
6154
6155 NullFields []string `json:"-"`
6156 }
6157
6158 func (s *DefaultClickThroughEventTagProperties) MarshalJSON() ([]byte, error) {
6159 type NoMethod DefaultClickThroughEventTagProperties
6160 raw := NoMethod(*s)
6161 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6162 }
6163
6164
6165 type DeliverySchedule struct {
6166
6167
6168 FrequencyCap *FrequencyCap `json:"frequencyCap,omitempty"`
6169
6170
6171
6172
6173 HardCutoff bool `json:"hardCutoff,omitempty"`
6174
6175
6176
6177
6178
6179
6180 ImpressionRatio int64 `json:"impressionRatio,omitempty,string"`
6181
6182
6183
6184
6185
6186
6187
6188
6189
6190
6191
6192
6193
6194
6195
6196
6197
6198
6199
6200
6201
6202
6203 Priority string `json:"priority,omitempty"`
6204
6205
6206
6207
6208
6209
6210
6211 ForceSendFields []string `json:"-"`
6212
6213
6214
6215
6216
6217
6218
6219 NullFields []string `json:"-"`
6220 }
6221
6222 func (s *DeliverySchedule) MarshalJSON() ([]byte, error) {
6223 type NoMethod DeliverySchedule
6224 raw := NoMethod(*s)
6225 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6226 }
6227
6228
6229 type DfpSettings struct {
6230
6231 DfpNetworkCode string `json:"dfpNetworkCode,omitempty"`
6232
6233
6234 DfpNetworkName string `json:"dfpNetworkName,omitempty"`
6235
6236
6237
6238 ProgrammaticPlacementAccepted bool `json:"programmaticPlacementAccepted,omitempty"`
6239
6240
6241
6242 PubPaidPlacementAccepted bool `json:"pubPaidPlacementAccepted,omitempty"`
6243
6244
6245
6246 PublisherPortalOnly bool `json:"publisherPortalOnly,omitempty"`
6247
6248
6249
6250
6251
6252
6253
6254 ForceSendFields []string `json:"-"`
6255
6256
6257
6258
6259
6260
6261
6262
6263 NullFields []string `json:"-"`
6264 }
6265
6266 func (s *DfpSettings) MarshalJSON() ([]byte, error) {
6267 type NoMethod DfpSettings
6268 raw := NoMethod(*s)
6269 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6270 }
6271
6272
6273 type Dimension struct {
6274
6275
6276 Kind string `json:"kind,omitempty"`
6277
6278
6279 Name string `json:"name,omitempty"`
6280
6281
6282
6283
6284
6285
6286
6287 ForceSendFields []string `json:"-"`
6288
6289
6290
6291
6292
6293
6294
6295 NullFields []string `json:"-"`
6296 }
6297
6298 func (s *Dimension) MarshalJSON() ([]byte, error) {
6299 type NoMethod Dimension
6300 raw := NoMethod(*s)
6301 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6302 }
6303
6304
6305 type DimensionFilter struct {
6306
6307 DimensionName string `json:"dimensionName,omitempty"`
6308
6309
6310
6311 Kind string `json:"kind,omitempty"`
6312
6313
6314 Value string `json:"value,omitempty"`
6315
6316
6317
6318
6319
6320
6321
6322 ForceSendFields []string `json:"-"`
6323
6324
6325
6326
6327
6328
6329
6330 NullFields []string `json:"-"`
6331 }
6332
6333 func (s *DimensionFilter) MarshalJSON() ([]byte, error) {
6334 type NoMethod DimensionFilter
6335 raw := NoMethod(*s)
6336 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6337 }
6338
6339
6340 type DimensionValue struct {
6341
6342 DimensionName string `json:"dimensionName,omitempty"`
6343
6344
6345 Etag string `json:"etag,omitempty"`
6346
6347
6348 Id string `json:"id,omitempty"`
6349
6350
6351
6352 Kind string `json:"kind,omitempty"`
6353
6354
6355
6356
6357
6358
6359
6360
6361
6362
6363
6364
6365
6366 MatchType string `json:"matchType,omitempty"`
6367
6368
6369 Value string `json:"value,omitempty"`
6370
6371
6372
6373
6374
6375
6376
6377 ForceSendFields []string `json:"-"`
6378
6379
6380
6381
6382
6383
6384
6385 NullFields []string `json:"-"`
6386 }
6387
6388 func (s *DimensionValue) MarshalJSON() ([]byte, error) {
6389 type NoMethod DimensionValue
6390 raw := NoMethod(*s)
6391 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6392 }
6393
6394
6395 type DimensionValueList struct {
6396
6397 Etag string `json:"etag,omitempty"`
6398
6399
6400 Items []*DimensionValue `json:"items,omitempty"`
6401
6402
6403
6404 Kind string `json:"kind,omitempty"`
6405
6406
6407
6408
6409
6410 NextPageToken string `json:"nextPageToken,omitempty"`
6411
6412
6413
6414 googleapi.ServerResponse `json:"-"`
6415
6416
6417
6418
6419
6420
6421
6422 ForceSendFields []string `json:"-"`
6423
6424
6425
6426
6427
6428
6429
6430 NullFields []string `json:"-"`
6431 }
6432
6433 func (s *DimensionValueList) MarshalJSON() ([]byte, error) {
6434 type NoMethod DimensionValueList
6435 raw := NoMethod(*s)
6436 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6437 }
6438
6439
6440 type DimensionValueRequest struct {
6441
6442
6443 DimensionName string `json:"dimensionName,omitempty"`
6444
6445
6446
6447 EndDate string `json:"endDate,omitempty"`
6448
6449
6450
6451 Filters []*DimensionFilter `json:"filters,omitempty"`
6452
6453
6454
6455 Kind string `json:"kind,omitempty"`
6456
6457
6458
6459 StartDate string `json:"startDate,omitempty"`
6460
6461
6462
6463
6464
6465
6466
6467 ForceSendFields []string `json:"-"`
6468
6469
6470
6471
6472
6473
6474
6475 NullFields []string `json:"-"`
6476 }
6477
6478 func (s *DimensionValueRequest) MarshalJSON() ([]byte, error) {
6479 type NoMethod DimensionValueRequest
6480 raw := NoMethod(*s)
6481 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6482 }
6483
6484
6485
6486
6487 type DirectorySite struct {
6488
6489 Active bool `json:"active,omitempty"`
6490
6491
6492 ContactAssignments []*DirectorySiteContactAssignment `json:"contactAssignments,omitempty"`
6493
6494
6495
6496 CountryId int64 `json:"countryId,omitempty,string"`
6497
6498
6499
6500
6501
6502
6503
6504
6505
6506
6507
6508
6509
6510
6511
6512
6513
6514
6515
6516
6517
6518
6519
6520
6521
6522
6523
6524
6525
6526
6527
6528
6529
6530
6531
6532
6533
6534
6535
6536
6537
6538
6539
6540
6541
6542
6543
6544
6545
6546
6547
6548
6549
6550 CurrencyId int64 `json:"currencyId,omitempty,string"`
6551
6552
6553
6554 Description string `json:"description,omitempty"`
6555
6556
6557
6558 Id int64 `json:"id,omitempty,string"`
6559
6560
6561
6562 IdDimensionValue *DimensionValue `json:"idDimensionValue,omitempty"`
6563
6564
6565
6566
6567
6568
6569
6570
6571
6572
6573
6574
6575
6576
6577 InpageTagFormats []string `json:"inpageTagFormats,omitempty"`
6578
6579
6580
6581
6582
6583
6584
6585
6586
6587
6588
6589
6590
6591 InterstitialTagFormats []string `json:"interstitialTagFormats,omitempty"`
6592
6593
6594
6595 Kind string `json:"kind,omitempty"`
6596
6597
6598 Name string `json:"name,omitempty"`
6599
6600
6601 ParentId int64 `json:"parentId,omitempty,string"`
6602
6603
6604 Settings *DirectorySiteSettings `json:"settings,omitempty"`
6605
6606
6607 Url string `json:"url,omitempty"`
6608
6609
6610
6611 googleapi.ServerResponse `json:"-"`
6612
6613
6614
6615
6616
6617
6618
6619 ForceSendFields []string `json:"-"`
6620
6621
6622
6623
6624
6625
6626
6627 NullFields []string `json:"-"`
6628 }
6629
6630 func (s *DirectorySite) MarshalJSON() ([]byte, error) {
6631 type NoMethod DirectorySite
6632 raw := NoMethod(*s)
6633 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6634 }
6635
6636
6637
6638 type DirectorySiteContact struct {
6639
6640 Address string `json:"address,omitempty"`
6641
6642
6643 Email string `json:"email,omitempty"`
6644
6645
6646 FirstName string `json:"firstName,omitempty"`
6647
6648
6649
6650 Id int64 `json:"id,omitempty,string"`
6651
6652
6653
6654 Kind string `json:"kind,omitempty"`
6655
6656
6657 LastName string `json:"lastName,omitempty"`
6658
6659
6660 Phone string `json:"phone,omitempty"`
6661
6662
6663
6664
6665
6666
6667
6668 Role string `json:"role,omitempty"`
6669
6670
6671 Title string `json:"title,omitempty"`
6672
6673
6674
6675
6676
6677
6678
6679
6680 Type string `json:"type,omitempty"`
6681
6682
6683
6684 googleapi.ServerResponse `json:"-"`
6685
6686
6687
6688
6689
6690
6691
6692 ForceSendFields []string `json:"-"`
6693
6694
6695
6696
6697
6698
6699
6700 NullFields []string `json:"-"`
6701 }
6702
6703 func (s *DirectorySiteContact) MarshalJSON() ([]byte, error) {
6704 type NoMethod DirectorySiteContact
6705 raw := NoMethod(*s)
6706 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6707 }
6708
6709
6710 type DirectorySiteContactAssignment struct {
6711
6712
6713 ContactId int64 `json:"contactId,omitempty,string"`
6714
6715
6716
6717
6718
6719
6720
6721
6722 Visibility string `json:"visibility,omitempty"`
6723
6724
6725
6726
6727
6728
6729
6730 ForceSendFields []string `json:"-"`
6731
6732
6733
6734
6735
6736
6737
6738 NullFields []string `json:"-"`
6739 }
6740
6741 func (s *DirectorySiteContactAssignment) MarshalJSON() ([]byte, error) {
6742 type NoMethod DirectorySiteContactAssignment
6743 raw := NoMethod(*s)
6744 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6745 }
6746
6747
6748
6749 type DirectorySiteContactsListResponse struct {
6750
6751 DirectorySiteContacts []*DirectorySiteContact `json:"directorySiteContacts,omitempty"`
6752
6753
6754
6755 Kind string `json:"kind,omitempty"`
6756
6757
6758
6759 NextPageToken string `json:"nextPageToken,omitempty"`
6760
6761
6762
6763 googleapi.ServerResponse `json:"-"`
6764
6765
6766
6767
6768
6769
6770
6771
6772 ForceSendFields []string `json:"-"`
6773
6774
6775
6776
6777
6778
6779
6780
6781 NullFields []string `json:"-"`
6782 }
6783
6784 func (s *DirectorySiteContactsListResponse) MarshalJSON() ([]byte, error) {
6785 type NoMethod DirectorySiteContactsListResponse
6786 raw := NoMethod(*s)
6787 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6788 }
6789
6790
6791 type DirectorySiteSettings struct {
6792
6793
6794 ActiveViewOptOut bool `json:"activeViewOptOut,omitempty"`
6795
6796
6797 DfpSettings *DfpSettings `json:"dfpSettings,omitempty"`
6798
6799
6800
6801 InstreamVideoPlacementAccepted bool `json:"instreamVideoPlacementAccepted,omitempty"`
6802
6803
6804
6805 InterstitialPlacementAccepted bool `json:"interstitialPlacementAccepted,omitempty"`
6806
6807
6808
6809 NielsenOcrOptOut bool `json:"nielsenOcrOptOut,omitempty"`
6810
6811
6812
6813 VerificationTagOptOut bool `json:"verificationTagOptOut,omitempty"`
6814
6815
6816
6817 VideoActiveViewOptOut bool `json:"videoActiveViewOptOut,omitempty"`
6818
6819
6820
6821
6822
6823
6824
6825 ForceSendFields []string `json:"-"`
6826
6827
6828
6829
6830
6831
6832
6833
6834 NullFields []string `json:"-"`
6835 }
6836
6837 func (s *DirectorySiteSettings) MarshalJSON() ([]byte, error) {
6838 type NoMethod DirectorySiteSettings
6839 raw := NoMethod(*s)
6840 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6841 }
6842
6843
6844 type DirectorySitesListResponse struct {
6845
6846 DirectorySites []*DirectorySite `json:"directorySites,omitempty"`
6847
6848
6849
6850 Kind string `json:"kind,omitempty"`
6851
6852
6853
6854 NextPageToken string `json:"nextPageToken,omitempty"`
6855
6856
6857
6858 googleapi.ServerResponse `json:"-"`
6859
6860
6861
6862
6863
6864
6865
6866 ForceSendFields []string `json:"-"`
6867
6868
6869
6870
6871
6872
6873
6874
6875 NullFields []string `json:"-"`
6876 }
6877
6878 func (s *DirectorySitesListResponse) MarshalJSON() ([]byte, error) {
6879 type NoMethod DirectorySitesListResponse
6880 raw := NoMethod(*s)
6881 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6882 }
6883
6884
6885
6886
6887
6888
6889
6890 type DynamicTargetingKey struct {
6891
6892
6893 Kind string `json:"kind,omitempty"`
6894
6895
6896
6897
6898 Name string `json:"name,omitempty"`
6899
6900
6901
6902 ObjectId int64 `json:"objectId,omitempty,string"`
6903
6904
6905
6906
6907
6908
6909
6910
6911
6912 ObjectType string `json:"objectType,omitempty"`
6913
6914
6915
6916 googleapi.ServerResponse `json:"-"`
6917
6918
6919
6920
6921
6922
6923
6924 ForceSendFields []string `json:"-"`
6925
6926
6927
6928
6929
6930
6931
6932 NullFields []string `json:"-"`
6933 }
6934
6935 func (s *DynamicTargetingKey) MarshalJSON() ([]byte, error) {
6936 type NoMethod DynamicTargetingKey
6937 raw := NoMethod(*s)
6938 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6939 }
6940
6941
6942 type DynamicTargetingKeysListResponse struct {
6943
6944 DynamicTargetingKeys []*DynamicTargetingKey `json:"dynamicTargetingKeys,omitempty"`
6945
6946
6947
6948 Kind string `json:"kind,omitempty"`
6949
6950
6951
6952 googleapi.ServerResponse `json:"-"`
6953
6954
6955
6956
6957
6958
6959
6960
6961 ForceSendFields []string `json:"-"`
6962
6963
6964
6965
6966
6967
6968
6969
6970 NullFields []string `json:"-"`
6971 }
6972
6973 func (s *DynamicTargetingKeysListResponse) MarshalJSON() ([]byte, error) {
6974 type NoMethod DynamicTargetingKeysListResponse
6975 raw := NoMethod(*s)
6976 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6977 }
6978
6979
6980 type EncryptionInfo struct {
6981
6982
6983 EncryptionEntityId int64 `json:"encryptionEntityId,omitempty,string"`
6984
6985
6986
6987
6988
6989
6990
6991
6992
6993
6994
6995
6996 EncryptionEntityType string `json:"encryptionEntityType,omitempty"`
6997
6998
6999
7000
7001
7002
7003
7004
7005 EncryptionSource string `json:"encryptionSource,omitempty"`
7006
7007
7008
7009 Kind string `json:"kind,omitempty"`
7010
7011
7012
7013
7014
7015
7016
7017 ForceSendFields []string `json:"-"`
7018
7019
7020
7021
7022
7023
7024
7025
7026 NullFields []string `json:"-"`
7027 }
7028
7029 func (s *EncryptionInfo) MarshalJSON() ([]byte, error) {
7030 type NoMethod EncryptionInfo
7031 raw := NoMethod(*s)
7032 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7033 }
7034
7035
7036 type EventTag struct {
7037
7038
7039 AccountId int64 `json:"accountId,omitempty,string"`
7040
7041
7042
7043 AdvertiserId int64 `json:"advertiserId,omitempty,string"`
7044
7045
7046
7047 AdvertiserIdDimensionValue *DimensionValue `json:"advertiserIdDimensionValue,omitempty"`
7048
7049
7050
7051 CampaignId int64 `json:"campaignId,omitempty,string"`
7052
7053
7054
7055 CampaignIdDimensionValue *DimensionValue `json:"campaignIdDimensionValue,omitempty"`
7056
7057
7058
7059 EnabledByDefault bool `json:"enabledByDefault,omitempty"`
7060
7061
7062
7063
7064
7065
7066 ExcludeFromAdxRequests bool `json:"excludeFromAdxRequests,omitempty"`
7067
7068
7069 Id int64 `json:"id,omitempty,string"`
7070
7071
7072
7073 Kind string `json:"kind,omitempty"`
7074
7075
7076
7077 Name string `json:"name,omitempty"`
7078
7079
7080
7081
7082
7083
7084
7085 SiteFilterType string `json:"siteFilterType,omitempty"`
7086
7087
7088
7089
7090 SiteIds googleapi.Int64s `json:"siteIds,omitempty"`
7091
7092
7093
7094 SslCompliant bool `json:"sslCompliant,omitempty"`
7095
7096
7097
7098
7099
7100
7101
7102 Status string `json:"status,omitempty"`
7103
7104
7105
7106 SubaccountId int64 `json:"subaccountId,omitempty,string"`
7107
7108
7109
7110
7111
7112
7113
7114
7115
7116
7117 Type string `json:"type,omitempty"`
7118
7119
7120
7121
7122 Url string `json:"url,omitempty"`
7123
7124
7125
7126
7127
7128 UrlEscapeLevels int64 `json:"urlEscapeLevels,omitempty"`
7129
7130
7131
7132 googleapi.ServerResponse `json:"-"`
7133
7134
7135
7136
7137
7138
7139
7140 ForceSendFields []string `json:"-"`
7141
7142
7143
7144
7145
7146
7147
7148 NullFields []string `json:"-"`
7149 }
7150
7151 func (s *EventTag) MarshalJSON() ([]byte, error) {
7152 type NoMethod EventTag
7153 raw := NoMethod(*s)
7154 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7155 }
7156
7157
7158 type EventTagOverride struct {
7159
7160 Enabled bool `json:"enabled,omitempty"`
7161
7162
7163
7164 Id int64 `json:"id,omitempty,string"`
7165
7166
7167
7168
7169
7170
7171
7172 ForceSendFields []string `json:"-"`
7173
7174
7175
7176
7177
7178
7179
7180 NullFields []string `json:"-"`
7181 }
7182
7183 func (s *EventTagOverride) MarshalJSON() ([]byte, error) {
7184 type NoMethod EventTagOverride
7185 raw := NoMethod(*s)
7186 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7187 }
7188
7189
7190 type EventTagsListResponse struct {
7191
7192 EventTags []*EventTag `json:"eventTags,omitempty"`
7193
7194
7195
7196 Kind string `json:"kind,omitempty"`
7197
7198
7199
7200 googleapi.ServerResponse `json:"-"`
7201
7202
7203
7204
7205
7206
7207
7208 ForceSendFields []string `json:"-"`
7209
7210
7211
7212
7213
7214
7215
7216 NullFields []string `json:"-"`
7217 }
7218
7219 func (s *EventTagsListResponse) MarshalJSON() ([]byte, error) {
7220 type NoMethod EventTagsListResponse
7221 raw := NoMethod(*s)
7222 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7223 }
7224
7225
7226
7227
7228
7229 type File struct {
7230
7231
7232
7233 DateRange *DateRange `json:"dateRange,omitempty"`
7234
7235
7236 Etag string `json:"etag,omitempty"`
7237
7238
7239 FileName string `json:"fileName,omitempty"`
7240
7241
7242
7243
7244
7245
7246
7247 Format string `json:"format,omitempty"`
7248
7249
7250 Id int64 `json:"id,omitempty,string"`
7251
7252
7253 Kind string `json:"kind,omitempty"`
7254
7255
7256
7257 LastModifiedTime int64 `json:"lastModifiedTime,omitempty,string"`
7258
7259
7260 ReportId int64 `json:"reportId,omitempty,string"`
7261
7262
7263
7264
7265
7266
7267
7268
7269 Status string `json:"status,omitempty"`
7270
7271
7272 Urls *FileUrls `json:"urls,omitempty"`
7273
7274
7275
7276 googleapi.ServerResponse `json:"-"`
7277
7278
7279
7280
7281
7282
7283
7284 ForceSendFields []string `json:"-"`
7285
7286
7287
7288
7289
7290
7291
7292 NullFields []string `json:"-"`
7293 }
7294
7295 func (s *File) MarshalJSON() ([]byte, error) {
7296 type NoMethod File
7297 raw := NoMethod(*s)
7298 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7299 }
7300
7301
7302 type FileUrls struct {
7303
7304 ApiUrl string `json:"apiUrl,omitempty"`
7305
7306
7307
7308 BrowserUrl string `json:"browserUrl,omitempty"`
7309
7310
7311
7312
7313
7314
7315
7316 ForceSendFields []string `json:"-"`
7317
7318
7319
7320
7321
7322
7323
7324 NullFields []string `json:"-"`
7325 }
7326
7327 func (s *FileUrls) MarshalJSON() ([]byte, error) {
7328 type NoMethod FileUrls
7329 raw := NoMethod(*s)
7330 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7331 }
7332
7333
7334 type FileList struct {
7335
7336 Etag string `json:"etag,omitempty"`
7337
7338
7339 Items []*File `json:"items,omitempty"`
7340
7341
7342 Kind string `json:"kind,omitempty"`
7343
7344
7345
7346
7347
7348 NextPageToken string `json:"nextPageToken,omitempty"`
7349
7350
7351
7352 googleapi.ServerResponse `json:"-"`
7353
7354
7355
7356
7357
7358
7359
7360 ForceSendFields []string `json:"-"`
7361
7362
7363
7364
7365
7366
7367
7368 NullFields []string `json:"-"`
7369 }
7370
7371 func (s *FileList) MarshalJSON() ([]byte, error) {
7372 type NoMethod FileList
7373 raw := NoMethod(*s)
7374 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7375 }
7376
7377
7378 type Flight struct {
7379
7380 EndDate string `json:"endDate,omitempty"`
7381
7382
7383 RateOrCost int64 `json:"rateOrCost,omitempty,string"`
7384
7385
7386 StartDate string `json:"startDate,omitempty"`
7387
7388
7389 Units int64 `json:"units,omitempty,string"`
7390
7391
7392
7393
7394
7395
7396
7397 ForceSendFields []string `json:"-"`
7398
7399
7400
7401
7402
7403
7404
7405 NullFields []string `json:"-"`
7406 }
7407
7408 func (s *Flight) MarshalJSON() ([]byte, error) {
7409 type NoMethod Flight
7410 raw := NoMethod(*s)
7411 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7412 }
7413
7414
7415
7416 type FloodlightActivitiesGenerateTagResponse struct {
7417
7418
7419 FloodlightActivityTag string `json:"floodlightActivityTag,omitempty"`
7420
7421
7422
7423
7424
7425 GlobalSiteTagGlobalSnippet string `json:"globalSiteTagGlobalSnippet,omitempty"`
7426
7427
7428
7429 Kind string `json:"kind,omitempty"`
7430
7431
7432
7433 googleapi.ServerResponse `json:"-"`
7434
7435
7436
7437
7438
7439
7440
7441
7442 ForceSendFields []string `json:"-"`
7443
7444
7445
7446
7447
7448
7449
7450
7451 NullFields []string `json:"-"`
7452 }
7453
7454 func (s *FloodlightActivitiesGenerateTagResponse) MarshalJSON() ([]byte, error) {
7455 type NoMethod FloodlightActivitiesGenerateTagResponse
7456 raw := NoMethod(*s)
7457 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7458 }
7459
7460
7461 type FloodlightActivitiesListResponse struct {
7462
7463 FloodlightActivities []*FloodlightActivity `json:"floodlightActivities,omitempty"`
7464
7465
7466
7467 Kind string `json:"kind,omitempty"`
7468
7469
7470
7471 NextPageToken string `json:"nextPageToken,omitempty"`
7472
7473
7474
7475 googleapi.ServerResponse `json:"-"`
7476
7477
7478
7479
7480
7481
7482
7483
7484 ForceSendFields []string `json:"-"`
7485
7486
7487
7488
7489
7490
7491
7492
7493 NullFields []string `json:"-"`
7494 }
7495
7496 func (s *FloodlightActivitiesListResponse) MarshalJSON() ([]byte, error) {
7497 type NoMethod FloodlightActivitiesListResponse
7498 raw := NoMethod(*s)
7499 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7500 }
7501
7502
7503 type FloodlightActivity struct {
7504
7505
7506 AccountId int64 `json:"accountId,omitempty,string"`
7507
7508
7509
7510
7511 AdvertiserId int64 `json:"advertiserId,omitempty,string"`
7512
7513
7514
7515 AdvertiserIdDimensionValue *DimensionValue `json:"advertiserIdDimensionValue,omitempty"`
7516
7517
7518
7519
7520
7521
7522
7523
7524
7525
7526
7527 CacheBustingType string `json:"cacheBustingType,omitempty"`
7528
7529
7530
7531
7532
7533
7534
7535
7536
7537
7538 CountingMethod string `json:"countingMethod,omitempty"`
7539
7540
7541 DefaultTags []*FloodlightActivityDynamicTag `json:"defaultTags,omitempty"`
7542
7543
7544
7545 ExpectedUrl string `json:"expectedUrl,omitempty"`
7546
7547
7548
7549 FloodlightActivityGroupId int64 `json:"floodlightActivityGroupId,omitempty,string"`
7550
7551
7552
7553 FloodlightActivityGroupName string `json:"floodlightActivityGroupName,omitempty"`
7554
7555
7556
7557 FloodlightActivityGroupTagString string `json:"floodlightActivityGroupTagString,omitempty"`
7558
7559
7560
7561
7562
7563
7564
7565 FloodlightActivityGroupType string `json:"floodlightActivityGroupType,omitempty"`
7566
7567
7568
7569
7570
7571 FloodlightConfigurationId int64 `json:"floodlightConfigurationId,omitempty,string"`
7572
7573
7574
7575
7576 FloodlightConfigurationIdDimensionValue *DimensionValue `json:"floodlightConfigurationIdDimensionValue,omitempty"`
7577
7578
7579
7580
7581
7582
7583
7584
7585 FloodlightTagType string `json:"floodlightTagType,omitempty"`
7586
7587
7588 Hidden bool `json:"hidden,omitempty"`
7589
7590
7591
7592 Id int64 `json:"id,omitempty,string"`
7593
7594
7595
7596 IdDimensionValue *DimensionValue `json:"idDimensionValue,omitempty"`
7597
7598
7599
7600 Kind string `json:"kind,omitempty"`
7601
7602
7603
7604 Name string `json:"name,omitempty"`
7605
7606
7607 Notes string `json:"notes,omitempty"`
7608
7609
7610 PublisherTags []*FloodlightActivityPublisherDynamicTag `json:"publisherTags,omitempty"`
7611
7612
7613 Secure bool `json:"secure,omitempty"`
7614
7615
7616
7617
7618 SslCompliant bool `json:"sslCompliant,omitempty"`
7619
7620
7621 SslRequired bool `json:"sslRequired,omitempty"`
7622
7623
7624
7625 SubaccountId int64 `json:"subaccountId,omitempty,string"`
7626
7627
7628
7629
7630
7631
7632
7633 TagFormat string `json:"tagFormat,omitempty"`
7634
7635
7636
7637
7638
7639
7640
7641
7642 TagString string `json:"tagString,omitempty"`
7643
7644
7645
7646
7647
7648
7649
7650
7651
7652
7653
7654
7655
7656
7657
7658
7659
7660
7661
7662
7663
7664
7665
7666
7667
7668
7669
7670
7671
7672
7673
7674
7675
7676
7677
7678
7679
7680
7681
7682
7683
7684
7685
7686
7687
7688
7689
7690
7691
7692
7693
7694
7695
7696
7697
7698
7699
7700
7701
7702
7703
7704
7705
7706
7707
7708
7709
7710
7711
7712
7713
7714
7715
7716
7717
7718
7719
7720
7721
7722
7723
7724
7725
7726
7727
7728
7729
7730
7731
7732
7733
7734
7735
7736
7737
7738
7739
7740
7741
7742
7743
7744
7745
7746
7747
7748
7749
7750 UserDefinedVariableTypes []string `json:"userDefinedVariableTypes,omitempty"`
7751
7752
7753
7754 googleapi.ServerResponse `json:"-"`
7755
7756
7757
7758
7759
7760
7761
7762 ForceSendFields []string `json:"-"`
7763
7764
7765
7766
7767
7768
7769
7770 NullFields []string `json:"-"`
7771 }
7772
7773 func (s *FloodlightActivity) MarshalJSON() ([]byte, error) {
7774 type NoMethod FloodlightActivity
7775 raw := NoMethod(*s)
7776 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7777 }
7778
7779
7780 type FloodlightActivityDynamicTag struct {
7781
7782
7783 Id int64 `json:"id,omitempty,string"`
7784
7785
7786 Name string `json:"name,omitempty"`
7787
7788
7789 Tag string `json:"tag,omitempty"`
7790
7791
7792
7793
7794
7795
7796
7797 ForceSendFields []string `json:"-"`
7798
7799
7800
7801
7802
7803
7804
7805 NullFields []string `json:"-"`
7806 }
7807
7808 func (s *FloodlightActivityDynamicTag) MarshalJSON() ([]byte, error) {
7809 type NoMethod FloodlightActivityDynamicTag
7810 raw := NoMethod(*s)
7811 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7812 }
7813
7814
7815
7816 type FloodlightActivityGroup struct {
7817
7818
7819 AccountId int64 `json:"accountId,omitempty,string"`
7820
7821
7822
7823
7824
7825 AdvertiserId int64 `json:"advertiserId,omitempty,string"`
7826
7827
7828
7829 AdvertiserIdDimensionValue *DimensionValue `json:"advertiserIdDimensionValue,omitempty"`
7830
7831
7832
7833 FloodlightConfigurationId int64 `json:"floodlightConfigurationId,omitempty,string"`
7834
7835
7836
7837
7838 FloodlightConfigurationIdDimensionValue *DimensionValue `json:"floodlightConfigurationIdDimensionValue,omitempty"`
7839
7840
7841
7842 Id int64 `json:"id,omitempty,string"`
7843
7844
7845
7846 IdDimensionValue *DimensionValue `json:"idDimensionValue,omitempty"`
7847
7848
7849
7850 Kind string `json:"kind,omitempty"`
7851
7852
7853
7854
7855 Name string `json:"name,omitempty"`
7856
7857
7858
7859 SubaccountId int64 `json:"subaccountId,omitempty,string"`
7860
7861
7862
7863
7864
7865
7866
7867
7868 TagString string `json:"tagString,omitempty"`
7869
7870
7871
7872
7873
7874
7875
7876 Type string `json:"type,omitempty"`
7877
7878
7879
7880 googleapi.ServerResponse `json:"-"`
7881
7882
7883
7884
7885
7886
7887
7888 ForceSendFields []string `json:"-"`
7889
7890
7891
7892
7893
7894
7895
7896 NullFields []string `json:"-"`
7897 }
7898
7899 func (s *FloodlightActivityGroup) MarshalJSON() ([]byte, error) {
7900 type NoMethod FloodlightActivityGroup
7901 raw := NoMethod(*s)
7902 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7903 }
7904
7905
7906
7907 type FloodlightActivityGroupsListResponse struct {
7908
7909 FloodlightActivityGroups []*FloodlightActivityGroup `json:"floodlightActivityGroups,omitempty"`
7910
7911
7912
7913 Kind string `json:"kind,omitempty"`
7914
7915
7916
7917 NextPageToken string `json:"nextPageToken,omitempty"`
7918
7919
7920
7921 googleapi.ServerResponse `json:"-"`
7922
7923
7924
7925
7926
7927
7928
7929
7930 ForceSendFields []string `json:"-"`
7931
7932
7933
7934
7935
7936
7937
7938
7939 NullFields []string `json:"-"`
7940 }
7941
7942 func (s *FloodlightActivityGroupsListResponse) MarshalJSON() ([]byte, error) {
7943 type NoMethod FloodlightActivityGroupsListResponse
7944 raw := NoMethod(*s)
7945 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7946 }
7947
7948
7949 type FloodlightActivityPublisherDynamicTag struct {
7950
7951 ClickThrough bool `json:"clickThrough,omitempty"`
7952
7953
7954
7955
7956
7957 DirectorySiteId int64 `json:"directorySiteId,omitempty,string"`
7958
7959
7960 DynamicTag *FloodlightActivityDynamicTag `json:"dynamicTag,omitempty"`
7961
7962
7963 SiteId int64 `json:"siteId,omitempty,string"`
7964
7965
7966
7967 SiteIdDimensionValue *DimensionValue `json:"siteIdDimensionValue,omitempty"`
7968
7969
7970 ViewThrough bool `json:"viewThrough,omitempty"`
7971
7972
7973
7974
7975
7976
7977
7978 ForceSendFields []string `json:"-"`
7979
7980
7981
7982
7983
7984
7985
7986 NullFields []string `json:"-"`
7987 }
7988
7989 func (s *FloodlightActivityPublisherDynamicTag) MarshalJSON() ([]byte, error) {
7990 type NoMethod FloodlightActivityPublisherDynamicTag
7991 raw := NoMethod(*s)
7992 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7993 }
7994
7995
7996
7997 type FloodlightConfiguration struct {
7998
7999
8000 AccountId int64 `json:"accountId,omitempty,string"`
8001
8002
8003
8004 AdvertiserId int64 `json:"advertiserId,omitempty,string"`
8005
8006
8007
8008 AdvertiserIdDimensionValue *DimensionValue `json:"advertiserIdDimensionValue,omitempty"`
8009
8010
8011
8012 AnalyticsDataSharingEnabled bool `json:"analyticsDataSharingEnabled,omitempty"`
8013
8014
8015
8016
8017
8018 ExposureToConversionEnabled bool `json:"exposureToConversionEnabled,omitempty"`
8019
8020
8021
8022
8023
8024
8025
8026 FirstDayOfWeek string `json:"firstDayOfWeek,omitempty"`
8027
8028
8029
8030 Id int64 `json:"id,omitempty,string"`
8031
8032
8033
8034 IdDimensionValue *DimensionValue `json:"idDimensionValue,omitempty"`
8035
8036
8037
8038 InAppAttributionTrackingEnabled bool `json:"inAppAttributionTrackingEnabled,omitempty"`
8039
8040
8041
8042 Kind string `json:"kind,omitempty"`
8043
8044
8045
8046 LookbackConfiguration *LookbackConfiguration `json:"lookbackConfiguration,omitempty"`
8047
8048
8049
8050
8051
8052
8053
8054
8055 NaturalSearchConversionAttributionOption string `json:"naturalSearchConversionAttributionOption,omitempty"`
8056
8057
8058 OmnitureSettings *OmnitureSettings `json:"omnitureSettings,omitempty"`
8059
8060
8061
8062 SubaccountId int64 `json:"subaccountId,omitempty,string"`
8063
8064
8065
8066 TagSettings *TagSettings `json:"tagSettings,omitempty"`
8067
8068
8069
8070 ThirdPartyAuthenticationTokens []*ThirdPartyAuthenticationToken `json:"thirdPartyAuthenticationTokens,omitempty"`
8071
8072
8073
8074 UserDefinedVariableConfigurations []*UserDefinedVariableConfiguration `json:"userDefinedVariableConfigurations,omitempty"`
8075
8076
8077
8078 googleapi.ServerResponse `json:"-"`
8079
8080
8081
8082
8083
8084
8085
8086 ForceSendFields []string `json:"-"`
8087
8088
8089
8090
8091
8092
8093
8094 NullFields []string `json:"-"`
8095 }
8096
8097 func (s *FloodlightConfiguration) MarshalJSON() ([]byte, error) {
8098 type NoMethod FloodlightConfiguration
8099 raw := NoMethod(*s)
8100 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8101 }
8102
8103
8104
8105 type FloodlightConfigurationsListResponse struct {
8106
8107 FloodlightConfigurations []*FloodlightConfiguration `json:"floodlightConfigurations,omitempty"`
8108
8109
8110
8111 Kind string `json:"kind,omitempty"`
8112
8113
8114
8115 googleapi.ServerResponse `json:"-"`
8116
8117
8118
8119
8120
8121
8122
8123
8124 ForceSendFields []string `json:"-"`
8125
8126
8127
8128
8129
8130
8131
8132
8133 NullFields []string `json:"-"`
8134 }
8135
8136 func (s *FloodlightConfigurationsListResponse) MarshalJSON() ([]byte, error) {
8137 type NoMethod FloodlightConfigurationsListResponse
8138 raw := NoMethod(*s)
8139 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8140 }
8141
8142
8143
8144 type FloodlightReportCompatibleFields struct {
8145
8146
8147 DimensionFilters []*Dimension `json:"dimensionFilters,omitempty"`
8148
8149
8150
8151 Dimensions []*Dimension `json:"dimensions,omitempty"`
8152
8153
8154
8155 Kind string `json:"kind,omitempty"`
8156
8157
8158
8159 Metrics []*Metric `json:"metrics,omitempty"`
8160
8161
8162
8163
8164
8165
8166
8167 ForceSendFields []string `json:"-"`
8168
8169
8170
8171
8172
8173
8174
8175
8176 NullFields []string `json:"-"`
8177 }
8178
8179 func (s *FloodlightReportCompatibleFields) MarshalJSON() ([]byte, error) {
8180 type NoMethod FloodlightReportCompatibleFields
8181 raw := NoMethod(*s)
8182 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8183 }
8184
8185
8186 type FrequencyCap struct {
8187
8188
8189
8190 Duration int64 `json:"duration,omitempty,string"`
8191
8192
8193
8194
8195 Impressions int64 `json:"impressions,omitempty,string"`
8196
8197
8198
8199
8200
8201
8202
8203 ForceSendFields []string `json:"-"`
8204
8205
8206
8207
8208
8209
8210
8211 NullFields []string `json:"-"`
8212 }
8213
8214 func (s *FrequencyCap) MarshalJSON() ([]byte, error) {
8215 type NoMethod FrequencyCap
8216 raw := NoMethod(*s)
8217 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8218 }
8219
8220
8221 type FsCommand struct {
8222
8223
8224 Left int64 `json:"left,omitempty"`
8225
8226
8227
8228
8229
8230
8231 PositionOption string `json:"positionOption,omitempty"`
8232
8233
8234
8235 Top int64 `json:"top,omitempty"`
8236
8237
8238 WindowHeight int64 `json:"windowHeight,omitempty"`
8239
8240
8241 WindowWidth int64 `json:"windowWidth,omitempty"`
8242
8243
8244
8245
8246
8247
8248
8249 ForceSendFields []string `json:"-"`
8250
8251
8252
8253
8254
8255
8256
8257 NullFields []string `json:"-"`
8258 }
8259
8260 func (s *FsCommand) MarshalJSON() ([]byte, error) {
8261 type NoMethod FsCommand
8262 raw := NoMethod(*s)
8263 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8264 }
8265
8266
8267 type GeoTargeting struct {
8268
8269
8270
8271
8272 Cities []*City `json:"cities,omitempty"`
8273
8274
8275
8276
8277
8278
8279
8280 Countries []*Country `json:"countries,omitempty"`
8281
8282
8283
8284
8285 ExcludeCountries bool `json:"excludeCountries,omitempty"`
8286
8287
8288
8289
8290
8291 Metros []*Metro `json:"metros,omitempty"`
8292
8293
8294
8295
8296
8297 PostalCodes []*PostalCode `json:"postalCodes,omitempty"`
8298
8299
8300
8301
8302
8303 Regions []*Region `json:"regions,omitempty"`
8304
8305
8306
8307
8308
8309
8310
8311 ForceSendFields []string `json:"-"`
8312
8313
8314
8315
8316
8317
8318
8319 NullFields []string `json:"-"`
8320 }
8321
8322 func (s *GeoTargeting) MarshalJSON() ([]byte, error) {
8323 type NoMethod GeoTargeting
8324 raw := NoMethod(*s)
8325 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8326 }
8327
8328
8329 type InventoryItem struct {
8330
8331 AccountId int64 `json:"accountId,omitempty,string"`
8332
8333
8334
8335
8336
8337
8338 AdSlots []*AdSlot `json:"adSlots,omitempty"`
8339
8340
8341 AdvertiserId int64 `json:"advertiserId,omitempty,string"`
8342
8343
8344 ContentCategoryId int64 `json:"contentCategoryId,omitempty,string"`
8345
8346
8347
8348 EstimatedClickThroughRate int64 `json:"estimatedClickThroughRate,omitempty,string"`
8349
8350
8351
8352 EstimatedConversionRate int64 `json:"estimatedConversionRate,omitempty,string"`
8353
8354
8355 Id int64 `json:"id,omitempty,string"`
8356
8357
8358 InPlan bool `json:"inPlan,omitempty"`
8359
8360
8361
8362 Kind string `json:"kind,omitempty"`
8363
8364
8365
8366 LastModifiedInfo *LastModifiedInfo `json:"lastModifiedInfo,omitempty"`
8367
8368
8369
8370
8371
8372 Name string `json:"name,omitempty"`
8373
8374
8375 NegotiationChannelId int64 `json:"negotiationChannelId,omitempty,string"`
8376
8377
8378 OrderId int64 `json:"orderId,omitempty,string"`
8379
8380
8381 PlacementStrategyId int64 `json:"placementStrategyId,omitempty,string"`
8382
8383
8384 Pricing *Pricing `json:"pricing,omitempty"`
8385
8386
8387 ProjectId int64 `json:"projectId,omitempty,string"`
8388
8389
8390 RfpId int64 `json:"rfpId,omitempty,string"`
8391
8392
8393 SiteId int64 `json:"siteId,omitempty,string"`
8394
8395
8396 SubaccountId int64 `json:"subaccountId,omitempty,string"`
8397
8398
8399
8400
8401
8402
8403 Type string `json:"type,omitempty"`
8404
8405
8406
8407 googleapi.ServerResponse `json:"-"`
8408
8409
8410
8411
8412
8413
8414
8415 ForceSendFields []string `json:"-"`
8416
8417
8418
8419
8420
8421
8422
8423 NullFields []string `json:"-"`
8424 }
8425
8426 func (s *InventoryItem) MarshalJSON() ([]byte, error) {
8427 type NoMethod InventoryItem
8428 raw := NoMethod(*s)
8429 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8430 }
8431
8432
8433 type InventoryItemsListResponse struct {
8434
8435 InventoryItems []*InventoryItem `json:"inventoryItems,omitempty"`
8436
8437
8438
8439 Kind string `json:"kind,omitempty"`
8440
8441
8442
8443 NextPageToken string `json:"nextPageToken,omitempty"`
8444
8445
8446
8447 googleapi.ServerResponse `json:"-"`
8448
8449
8450
8451
8452
8453
8454
8455 ForceSendFields []string `json:"-"`
8456
8457
8458
8459
8460
8461
8462
8463
8464 NullFields []string `json:"-"`
8465 }
8466
8467 func (s *InventoryItemsListResponse) MarshalJSON() ([]byte, error) {
8468 type NoMethod InventoryItemsListResponse
8469 raw := NoMethod(*s)
8470 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8471 }
8472
8473
8474 type KeyValueTargetingExpression struct {
8475
8476 Expression string `json:"expression,omitempty"`
8477
8478
8479
8480
8481
8482
8483
8484 ForceSendFields []string `json:"-"`
8485
8486
8487
8488
8489
8490
8491
8492 NullFields []string `json:"-"`
8493 }
8494
8495 func (s *KeyValueTargetingExpression) MarshalJSON() ([]byte, error) {
8496 type NoMethod KeyValueTargetingExpression
8497 raw := NoMethod(*s)
8498 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8499 }
8500
8501
8502
8503 type LandingPage struct {
8504
8505
8506 AdvertiserId int64 `json:"advertiserId,omitempty,string"`
8507
8508
8509 Archived bool `json:"archived,omitempty"`
8510
8511
8512
8513 DeepLinks []*DeepLink `json:"deepLinks,omitempty"`
8514
8515
8516
8517 Id int64 `json:"id,omitempty,string"`
8518
8519
8520
8521 Kind string `json:"kind,omitempty"`
8522
8523
8524
8525 Name string `json:"name,omitempty"`
8526
8527
8528 Url string `json:"url,omitempty"`
8529
8530
8531
8532 googleapi.ServerResponse `json:"-"`
8533
8534
8535
8536
8537
8538
8539
8540 ForceSendFields []string `json:"-"`
8541
8542
8543
8544
8545
8546
8547
8548 NullFields []string `json:"-"`
8549 }
8550
8551 func (s *LandingPage) MarshalJSON() ([]byte, error) {
8552 type NoMethod LandingPage
8553 raw := NoMethod(*s)
8554 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8555 }
8556
8557
8558
8559 type Language struct {
8560
8561
8562 Id int64 `json:"id,omitempty,string"`
8563
8564
8565
8566 Kind string `json:"kind,omitempty"`
8567
8568
8569
8570
8571
8572 LanguageCode string `json:"languageCode,omitempty"`
8573
8574
8575 Name string `json:"name,omitempty"`
8576
8577
8578
8579
8580
8581
8582
8583 ForceSendFields []string `json:"-"`
8584
8585
8586
8587
8588
8589
8590
8591 NullFields []string `json:"-"`
8592 }
8593
8594 func (s *Language) MarshalJSON() ([]byte, error) {
8595 type NoMethod Language
8596 raw := NoMethod(*s)
8597 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8598 }
8599
8600
8601 type LanguageTargeting struct {
8602
8603
8604
8605 Languages []*Language `json:"languages,omitempty"`
8606
8607
8608
8609
8610
8611
8612
8613 ForceSendFields []string `json:"-"`
8614
8615
8616
8617
8618
8619
8620
8621 NullFields []string `json:"-"`
8622 }
8623
8624 func (s *LanguageTargeting) MarshalJSON() ([]byte, error) {
8625 type NoMethod LanguageTargeting
8626 raw := NoMethod(*s)
8627 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8628 }
8629
8630
8631 type LanguagesListResponse struct {
8632
8633
8634 Kind string `json:"kind,omitempty"`
8635
8636
8637 Languages []*Language `json:"languages,omitempty"`
8638
8639
8640
8641 googleapi.ServerResponse `json:"-"`
8642
8643
8644
8645
8646
8647
8648
8649 ForceSendFields []string `json:"-"`
8650
8651
8652
8653
8654
8655
8656
8657 NullFields []string `json:"-"`
8658 }
8659
8660 func (s *LanguagesListResponse) MarshalJSON() ([]byte, error) {
8661 type NoMethod LanguagesListResponse
8662 raw := NoMethod(*s)
8663 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8664 }
8665
8666
8667 type LastModifiedInfo struct {
8668
8669 Time int64 `json:"time,omitempty,string"`
8670
8671
8672
8673
8674
8675
8676
8677 ForceSendFields []string `json:"-"`
8678
8679
8680
8681
8682
8683
8684
8685 NullFields []string `json:"-"`
8686 }
8687
8688 func (s *LastModifiedInfo) MarshalJSON() ([]byte, error) {
8689 type NoMethod LastModifiedInfo
8690 raw := NoMethod(*s)
8691 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8692 }
8693
8694
8695
8696 type ListPopulationClause struct {
8697
8698
8699
8700 Terms []*ListPopulationTerm `json:"terms,omitempty"`
8701
8702
8703
8704
8705
8706
8707
8708 ForceSendFields []string `json:"-"`
8709
8710
8711
8712
8713
8714
8715
8716 NullFields []string `json:"-"`
8717 }
8718
8719 func (s *ListPopulationClause) MarshalJSON() ([]byte, error) {
8720 type NoMethod ListPopulationClause
8721 raw := NoMethod(*s)
8722 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8723 }
8724
8725
8726 type ListPopulationRule struct {
8727
8728
8729 FloodlightActivityId int64 `json:"floodlightActivityId,omitempty,string"`
8730
8731
8732
8733 FloodlightActivityName string `json:"floodlightActivityName,omitempty"`
8734
8735
8736
8737
8738 ListPopulationClauses []*ListPopulationClause `json:"listPopulationClauses,omitempty"`
8739
8740
8741
8742
8743
8744
8745
8746
8747 ForceSendFields []string `json:"-"`
8748
8749
8750
8751
8752
8753
8754
8755
8756 NullFields []string `json:"-"`
8757 }
8758
8759 func (s *ListPopulationRule) MarshalJSON() ([]byte, error) {
8760 type NoMethod ListPopulationRule
8761 raw := NoMethod(*s)
8762 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8763 }
8764
8765
8766 type ListPopulationTerm struct {
8767
8768
8769
8770
8771 Contains bool `json:"contains,omitempty"`
8772
8773
8774
8775
8776 Negation bool `json:"negation,omitempty"`
8777
8778
8779
8780
8781
8782
8783
8784
8785
8786
8787
8788
8789
8790 Operator string `json:"operator,omitempty"`
8791
8792
8793
8794 RemarketingListId int64 `json:"remarketingListId,omitempty,string"`
8795
8796
8797
8798
8799
8800
8801
8802
8803
8804
8805
8806
8807 Type string `json:"type,omitempty"`
8808
8809
8810
8811
8812 Value string `json:"value,omitempty"`
8813
8814
8815
8816
8817 VariableFriendlyName string `json:"variableFriendlyName,omitempty"`
8818
8819
8820
8821
8822 VariableName string `json:"variableName,omitempty"`
8823
8824
8825
8826
8827
8828
8829
8830 ForceSendFields []string `json:"-"`
8831
8832
8833
8834
8835
8836
8837
8838 NullFields []string `json:"-"`
8839 }
8840
8841 func (s *ListPopulationTerm) MarshalJSON() ([]byte, error) {
8842 type NoMethod ListPopulationTerm
8843 raw := NoMethod(*s)
8844 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8845 }
8846
8847
8848 type ListTargetingExpression struct {
8849
8850
8851 Expression string `json:"expression,omitempty"`
8852
8853
8854
8855
8856
8857
8858
8859 ForceSendFields []string `json:"-"`
8860
8861
8862
8863
8864
8865
8866
8867 NullFields []string `json:"-"`
8868 }
8869
8870 func (s *ListTargetingExpression) MarshalJSON() ([]byte, error) {
8871 type NoMethod ListTargetingExpression
8872 raw := NoMethod(*s)
8873 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8874 }
8875
8876
8877 type LookbackConfiguration struct {
8878
8879
8880
8881
8882
8883 ClickDuration int64 `json:"clickDuration,omitempty"`
8884
8885
8886
8887
8888
8889
8890
8891 PostImpressionActivitiesDuration int64 `json:"postImpressionActivitiesDuration,omitempty"`
8892
8893
8894
8895
8896
8897
8898
8899 ForceSendFields []string `json:"-"`
8900
8901
8902
8903
8904
8905
8906
8907 NullFields []string `json:"-"`
8908 }
8909
8910 func (s *LookbackConfiguration) MarshalJSON() ([]byte, error) {
8911 type NoMethod LookbackConfiguration
8912 raw := NoMethod(*s)
8913 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8914 }
8915
8916
8917 type Metric struct {
8918
8919 Kind string `json:"kind,omitempty"`
8920
8921
8922 Name string `json:"name,omitempty"`
8923
8924
8925
8926
8927
8928
8929
8930 ForceSendFields []string `json:"-"`
8931
8932
8933
8934
8935
8936
8937
8938 NullFields []string `json:"-"`
8939 }
8940
8941 func (s *Metric) MarshalJSON() ([]byte, error) {
8942 type NoMethod Metric
8943 raw := NoMethod(*s)
8944 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8945 }
8946
8947
8948
8949 type Metro struct {
8950
8951
8952 CountryCode string `json:"countryCode,omitempty"`
8953
8954
8955
8956 CountryDartId int64 `json:"countryDartId,omitempty,string"`
8957
8958
8959 DartId int64 `json:"dartId,omitempty,string"`
8960
8961
8962
8963 DmaId int64 `json:"dmaId,omitempty,string"`
8964
8965
8966
8967 Kind string `json:"kind,omitempty"`
8968
8969
8970
8971 MetroCode string `json:"metroCode,omitempty"`
8972
8973
8974 Name string `json:"name,omitempty"`
8975
8976
8977
8978
8979
8980
8981
8982 ForceSendFields []string `json:"-"`
8983
8984
8985
8986
8987
8988
8989
8990 NullFields []string `json:"-"`
8991 }
8992
8993 func (s *Metro) MarshalJSON() ([]byte, error) {
8994 type NoMethod Metro
8995 raw := NoMethod(*s)
8996 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8997 }
8998
8999
9000 type MetrosListResponse struct {
9001
9002
9003 Kind string `json:"kind,omitempty"`
9004
9005
9006 Metros []*Metro `json:"metros,omitempty"`
9007
9008
9009
9010 googleapi.ServerResponse `json:"-"`
9011
9012
9013
9014
9015
9016
9017
9018 ForceSendFields []string `json:"-"`
9019
9020
9021
9022
9023
9024
9025
9026 NullFields []string `json:"-"`
9027 }
9028
9029 func (s *MetrosListResponse) MarshalJSON() ([]byte, error) {
9030 type NoMethod MetrosListResponse
9031 raw := NoMethod(*s)
9032 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9033 }
9034
9035
9036
9037 type MobileApp struct {
9038
9039
9040
9041
9042
9043
9044 Directory string `json:"directory,omitempty"`
9045
9046
9047 Id string `json:"id,omitempty"`
9048
9049
9050
9051 Kind string `json:"kind,omitempty"`
9052
9053
9054 PublisherName string `json:"publisherName,omitempty"`
9055
9056
9057 Title string `json:"title,omitempty"`
9058
9059
9060
9061 googleapi.ServerResponse `json:"-"`
9062
9063
9064
9065
9066
9067
9068
9069 ForceSendFields []string `json:"-"`
9070
9071
9072
9073
9074
9075
9076
9077 NullFields []string `json:"-"`
9078 }
9079
9080 func (s *MobileApp) MarshalJSON() ([]byte, error) {
9081 type NoMethod MobileApp
9082 raw := NoMethod(*s)
9083 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9084 }
9085
9086
9087 type MobileAppsListResponse struct {
9088
9089
9090 Kind string `json:"kind,omitempty"`
9091
9092
9093 MobileApps []*MobileApp `json:"mobileApps,omitempty"`
9094
9095
9096
9097 NextPageToken string `json:"nextPageToken,omitempty"`
9098
9099
9100
9101 googleapi.ServerResponse `json:"-"`
9102
9103
9104
9105
9106
9107
9108
9109 ForceSendFields []string `json:"-"`
9110
9111
9112
9113
9114
9115
9116
9117 NullFields []string `json:"-"`
9118 }
9119
9120 func (s *MobileAppsListResponse) MarshalJSON() ([]byte, error) {
9121 type NoMethod MobileAppsListResponse
9122 raw := NoMethod(*s)
9123 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9124 }
9125
9126
9127
9128 type MobileCarrier struct {
9129
9130
9131 CountryCode string `json:"countryCode,omitempty"`
9132
9133
9134
9135 CountryDartId int64 `json:"countryDartId,omitempty,string"`
9136
9137
9138 Id int64 `json:"id,omitempty,string"`
9139
9140
9141
9142 Kind string `json:"kind,omitempty"`
9143
9144
9145 Name string `json:"name,omitempty"`
9146
9147
9148
9149 googleapi.ServerResponse `json:"-"`
9150
9151
9152
9153
9154
9155
9156
9157 ForceSendFields []string `json:"-"`
9158
9159
9160
9161
9162
9163
9164
9165 NullFields []string `json:"-"`
9166 }
9167
9168 func (s *MobileCarrier) MarshalJSON() ([]byte, error) {
9169 type NoMethod MobileCarrier
9170 raw := NoMethod(*s)
9171 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9172 }
9173
9174
9175 type MobileCarriersListResponse struct {
9176
9177
9178 Kind string `json:"kind,omitempty"`
9179
9180
9181 MobileCarriers []*MobileCarrier `json:"mobileCarriers,omitempty"`
9182
9183
9184
9185 googleapi.ServerResponse `json:"-"`
9186
9187
9188
9189
9190
9191
9192
9193 ForceSendFields []string `json:"-"`
9194
9195
9196
9197
9198
9199
9200
9201 NullFields []string `json:"-"`
9202 }
9203
9204 func (s *MobileCarriersListResponse) MarshalJSON() ([]byte, error) {
9205 type NoMethod MobileCarriersListResponse
9206 raw := NoMethod(*s)
9207 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9208 }
9209
9210
9211 type ObjectFilter struct {
9212
9213
9214 Kind string `json:"kind,omitempty"`
9215
9216
9217
9218 ObjectIds googleapi.Int64s `json:"objectIds,omitempty"`
9219
9220
9221
9222
9223
9224
9225
9226
9227
9228
9229 Status string `json:"status,omitempty"`
9230
9231
9232
9233
9234
9235
9236
9237 ForceSendFields []string `json:"-"`
9238
9239
9240
9241
9242
9243
9244
9245 NullFields []string `json:"-"`
9246 }
9247
9248 func (s *ObjectFilter) MarshalJSON() ([]byte, error) {
9249 type NoMethod ObjectFilter
9250 raw := NoMethod(*s)
9251 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9252 }
9253
9254
9255 type OffsetPosition struct {
9256
9257 Left int64 `json:"left,omitempty"`
9258
9259
9260 Top int64 `json:"top,omitempty"`
9261
9262
9263
9264
9265
9266
9267
9268 ForceSendFields []string `json:"-"`
9269
9270
9271
9272
9273
9274
9275
9276 NullFields []string `json:"-"`
9277 }
9278
9279 func (s *OffsetPosition) MarshalJSON() ([]byte, error) {
9280 type NoMethod OffsetPosition
9281 raw := NoMethod(*s)
9282 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9283 }
9284
9285
9286 type OmnitureSettings struct {
9287
9288
9289
9290 OmnitureCostDataEnabled bool `json:"omnitureCostDataEnabled,omitempty"`
9291
9292
9293
9294
9295 OmnitureIntegrationEnabled bool `json:"omnitureIntegrationEnabled,omitempty"`
9296
9297
9298
9299
9300
9301
9302
9303
9304 ForceSendFields []string `json:"-"`
9305
9306
9307
9308
9309
9310
9311
9312
9313 NullFields []string `json:"-"`
9314 }
9315
9316 func (s *OmnitureSettings) MarshalJSON() ([]byte, error) {
9317 type NoMethod OmnitureSettings
9318 raw := NoMethod(*s)
9319 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9320 }
9321
9322
9323
9324 type OperatingSystem struct {
9325
9326
9327 DartId int64 `json:"dartId,omitempty,string"`
9328
9329
9330 Desktop bool `json:"desktop,omitempty"`
9331
9332
9333
9334 Kind string `json:"kind,omitempty"`
9335
9336
9337 Mobile bool `json:"mobile,omitempty"`
9338
9339
9340 Name string `json:"name,omitempty"`
9341
9342
9343
9344 googleapi.ServerResponse `json:"-"`
9345
9346
9347
9348
9349
9350
9351
9352 ForceSendFields []string `json:"-"`
9353
9354
9355
9356
9357
9358
9359
9360 NullFields []string `json:"-"`
9361 }
9362
9363 func (s *OperatingSystem) MarshalJSON() ([]byte, error) {
9364 type NoMethod OperatingSystem
9365 raw := NoMethod(*s)
9366 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9367 }
9368
9369
9370
9371 type OperatingSystemVersion struct {
9372
9373 Id int64 `json:"id,omitempty,string"`
9374
9375
9376
9377 Kind string `json:"kind,omitempty"`
9378
9379
9380
9381 MajorVersion string `json:"majorVersion,omitempty"`
9382
9383
9384
9385 MinorVersion string `json:"minorVersion,omitempty"`
9386
9387
9388 Name string `json:"name,omitempty"`
9389
9390
9391 OperatingSystem *OperatingSystem `json:"operatingSystem,omitempty"`
9392
9393
9394
9395 googleapi.ServerResponse `json:"-"`
9396
9397
9398
9399
9400
9401
9402
9403 ForceSendFields []string `json:"-"`
9404
9405
9406
9407
9408
9409
9410
9411 NullFields []string `json:"-"`
9412 }
9413
9414 func (s *OperatingSystemVersion) MarshalJSON() ([]byte, error) {
9415 type NoMethod OperatingSystemVersion
9416 raw := NoMethod(*s)
9417 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9418 }
9419
9420
9421
9422 type OperatingSystemVersionsListResponse struct {
9423
9424
9425 Kind string `json:"kind,omitempty"`
9426
9427
9428 OperatingSystemVersions []*OperatingSystemVersion `json:"operatingSystemVersions,omitempty"`
9429
9430
9431
9432 googleapi.ServerResponse `json:"-"`
9433
9434
9435
9436
9437
9438
9439
9440 ForceSendFields []string `json:"-"`
9441
9442
9443
9444
9445
9446
9447
9448 NullFields []string `json:"-"`
9449 }
9450
9451 func (s *OperatingSystemVersionsListResponse) MarshalJSON() ([]byte, error) {
9452 type NoMethod OperatingSystemVersionsListResponse
9453 raw := NoMethod(*s)
9454 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9455 }
9456
9457
9458 type OperatingSystemsListResponse struct {
9459
9460
9461 Kind string `json:"kind,omitempty"`
9462
9463
9464 OperatingSystems []*OperatingSystem `json:"operatingSystems,omitempty"`
9465
9466
9467
9468 googleapi.ServerResponse `json:"-"`
9469
9470
9471
9472
9473
9474
9475
9476 ForceSendFields []string `json:"-"`
9477
9478
9479
9480
9481
9482
9483
9484 NullFields []string `json:"-"`
9485 }
9486
9487 func (s *OperatingSystemsListResponse) MarshalJSON() ([]byte, error) {
9488 type NoMethod OperatingSystemsListResponse
9489 raw := NoMethod(*s)
9490 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9491 }
9492
9493
9494 type OptimizationActivity struct {
9495
9496
9497 FloodlightActivityId int64 `json:"floodlightActivityId,omitempty,string"`
9498
9499
9500
9501 FloodlightActivityIdDimensionValue *DimensionValue `json:"floodlightActivityIdDimensionValue,omitempty"`
9502
9503
9504
9505
9506 Weight int64 `json:"weight,omitempty"`
9507
9508
9509
9510
9511
9512
9513
9514
9515 ForceSendFields []string `json:"-"`
9516
9517
9518
9519
9520
9521
9522
9523
9524 NullFields []string `json:"-"`
9525 }
9526
9527 func (s *OptimizationActivity) MarshalJSON() ([]byte, error) {
9528 type NoMethod OptimizationActivity
9529 raw := NoMethod(*s)
9530 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9531 }
9532
9533
9534 type Order struct {
9535
9536 AccountId int64 `json:"accountId,omitempty,string"`
9537
9538
9539 AdvertiserId int64 `json:"advertiserId,omitempty,string"`
9540
9541
9542
9543 ApproverUserProfileIds googleapi.Int64s `json:"approverUserProfileIds,omitempty"`
9544
9545
9546 BuyerInvoiceId string `json:"buyerInvoiceId,omitempty"`
9547
9548
9549 BuyerOrganizationName string `json:"buyerOrganizationName,omitempty"`
9550
9551
9552 Comments string `json:"comments,omitempty"`
9553
9554
9555 Contacts []*OrderContact `json:"contacts,omitempty"`
9556
9557
9558 Id int64 `json:"id,omitempty,string"`
9559
9560
9561
9562 Kind string `json:"kind,omitempty"`
9563
9564
9565
9566 LastModifiedInfo *LastModifiedInfo `json:"lastModifiedInfo,omitempty"`
9567
9568
9569 Name string `json:"name,omitempty"`
9570
9571
9572 Notes string `json:"notes,omitempty"`
9573
9574
9575
9576 PlanningTermId int64 `json:"planningTermId,omitempty,string"`
9577
9578
9579 ProjectId int64 `json:"projectId,omitempty,string"`
9580
9581
9582 SellerOrderId string `json:"sellerOrderId,omitempty"`
9583
9584
9585 SellerOrganizationName string `json:"sellerOrganizationName,omitempty"`
9586
9587
9588 SiteId googleapi.Int64s `json:"siteId,omitempty"`
9589
9590
9591 SiteNames []string `json:"siteNames,omitempty"`
9592
9593
9594 SubaccountId int64 `json:"subaccountId,omitempty,string"`
9595
9596
9597 TermsAndConditions string `json:"termsAndConditions,omitempty"`
9598
9599
9600
9601 googleapi.ServerResponse `json:"-"`
9602
9603
9604
9605
9606
9607
9608
9609 ForceSendFields []string `json:"-"`
9610
9611
9612
9613
9614
9615
9616
9617 NullFields []string `json:"-"`
9618 }
9619
9620 func (s *Order) MarshalJSON() ([]byte, error) {
9621 type NoMethod Order
9622 raw := NoMethod(*s)
9623 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9624 }
9625
9626
9627 type OrderContact struct {
9628
9629
9630
9631 ContactInfo string `json:"contactInfo,omitempty"`
9632
9633
9634 ContactName string `json:"contactName,omitempty"`
9635
9636
9637 ContactTitle string `json:"contactTitle,omitempty"`
9638
9639
9640
9641
9642
9643
9644
9645 ContactType string `json:"contactType,omitempty"`
9646
9647
9648
9649 SignatureUserProfileId int64 `json:"signatureUserProfileId,omitempty,string"`
9650
9651
9652
9653
9654
9655
9656
9657 ForceSendFields []string `json:"-"`
9658
9659
9660
9661
9662
9663
9664
9665 NullFields []string `json:"-"`
9666 }
9667
9668 func (s *OrderContact) MarshalJSON() ([]byte, error) {
9669 type NoMethod OrderContact
9670 raw := NoMethod(*s)
9671 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9672 }
9673
9674
9675 type OrderDocument struct {
9676
9677 AccountId int64 `json:"accountId,omitempty,string"`
9678
9679
9680 AdvertiserId int64 `json:"advertiserId,omitempty,string"`
9681
9682
9683
9684
9685 AmendedOrderDocumentId int64 `json:"amendedOrderDocumentId,omitempty,string"`
9686
9687
9688
9689 ApprovedByUserProfileIds googleapi.Int64s `json:"approvedByUserProfileIds,omitempty"`
9690
9691
9692 Cancelled bool `json:"cancelled,omitempty"`
9693
9694
9695 CreatedInfo *LastModifiedInfo `json:"createdInfo,omitempty"`
9696
9697
9698 EffectiveDate string `json:"effectiveDate,omitempty"`
9699
9700
9701 Id int64 `json:"id,omitempty,string"`
9702
9703
9704
9705 Kind string `json:"kind,omitempty"`
9706
9707
9708
9709 LastSentRecipients []string `json:"lastSentRecipients,omitempty"`
9710
9711
9712
9713 LastSentTime string `json:"lastSentTime,omitempty"`
9714
9715
9716 OrderId int64 `json:"orderId,omitempty,string"`
9717
9718
9719 ProjectId int64 `json:"projectId,omitempty,string"`
9720
9721
9722 Signed bool `json:"signed,omitempty"`
9723
9724
9725 SubaccountId int64 `json:"subaccountId,omitempty,string"`
9726
9727
9728 Title string `json:"title,omitempty"`
9729
9730
9731
9732
9733
9734
9735 Type string `json:"type,omitempty"`
9736
9737
9738
9739 googleapi.ServerResponse `json:"-"`
9740
9741
9742
9743
9744
9745
9746
9747 ForceSendFields []string `json:"-"`
9748
9749
9750
9751
9752
9753
9754
9755 NullFields []string `json:"-"`
9756 }
9757
9758 func (s *OrderDocument) MarshalJSON() ([]byte, error) {
9759 type NoMethod OrderDocument
9760 raw := NoMethod(*s)
9761 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9762 }
9763
9764
9765 type OrderDocumentsListResponse struct {
9766
9767
9768 Kind string `json:"kind,omitempty"`
9769
9770
9771
9772 NextPageToken string `json:"nextPageToken,omitempty"`
9773
9774
9775 OrderDocuments []*OrderDocument `json:"orderDocuments,omitempty"`
9776
9777
9778
9779 googleapi.ServerResponse `json:"-"`
9780
9781
9782
9783
9784
9785
9786
9787 ForceSendFields []string `json:"-"`
9788
9789
9790
9791
9792
9793
9794
9795 NullFields []string `json:"-"`
9796 }
9797
9798 func (s *OrderDocumentsListResponse) MarshalJSON() ([]byte, error) {
9799 type NoMethod OrderDocumentsListResponse
9800 raw := NoMethod(*s)
9801 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9802 }
9803
9804
9805 type OrdersListResponse struct {
9806
9807
9808 Kind string `json:"kind,omitempty"`
9809
9810
9811
9812 NextPageToken string `json:"nextPageToken,omitempty"`
9813
9814
9815 Orders []*Order `json:"orders,omitempty"`
9816
9817
9818
9819 googleapi.ServerResponse `json:"-"`
9820
9821
9822
9823
9824
9825
9826
9827 ForceSendFields []string `json:"-"`
9828
9829
9830
9831
9832
9833
9834
9835 NullFields []string `json:"-"`
9836 }
9837
9838 func (s *OrdersListResponse) MarshalJSON() ([]byte, error) {
9839 type NoMethod OrdersListResponse
9840 raw := NoMethod(*s)
9841 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9842 }
9843
9844
9845
9846 type PathToConversionReportCompatibleFields struct {
9847
9848
9849 ConversionDimensions []*Dimension `json:"conversionDimensions,omitempty"`
9850
9851
9852
9853
9854 CustomFloodlightVariables []*Dimension `json:"customFloodlightVariables,omitempty"`
9855
9856
9857
9858 Kind string `json:"kind,omitempty"`
9859
9860
9861
9862 Metrics []*Metric `json:"metrics,omitempty"`
9863
9864
9865
9866
9867 PerInteractionDimensions []*Dimension `json:"perInteractionDimensions,omitempty"`
9868
9869
9870
9871
9872
9873
9874
9875
9876 ForceSendFields []string `json:"-"`
9877
9878
9879
9880
9881
9882
9883
9884
9885 NullFields []string `json:"-"`
9886 }
9887
9888 func (s *PathToConversionReportCompatibleFields) MarshalJSON() ([]byte, error) {
9889 type NoMethod PathToConversionReportCompatibleFields
9890 raw := NoMethod(*s)
9891 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9892 }
9893
9894
9895 type Placement struct {
9896
9897
9898 AccountId int64 `json:"accountId,omitempty,string"`
9899
9900
9901
9902
9903 AdBlockingOptOut bool `json:"adBlockingOptOut,omitempty"`
9904
9905
9906
9907
9908 AdditionalSizes []*Size `json:"additionalSizes,omitempty"`
9909
9910
9911
9912 AdvertiserId int64 `json:"advertiserId,omitempty,string"`
9913
9914
9915
9916 AdvertiserIdDimensionValue *DimensionValue `json:"advertiserIdDimensionValue,omitempty"`
9917
9918
9919 Archived bool `json:"archived,omitempty"`
9920
9921
9922
9923 CampaignId int64 `json:"campaignId,omitempty,string"`
9924
9925
9926
9927 CampaignIdDimensionValue *DimensionValue `json:"campaignIdDimensionValue,omitempty"`
9928
9929
9930 Comment string `json:"comment,omitempty"`
9931
9932
9933
9934
9935
9936
9937
9938
9939
9940
9941
9942
9943
9944
9945
9946
9947 Compatibility string `json:"compatibility,omitempty"`
9948
9949
9950
9951 ContentCategoryId int64 `json:"contentCategoryId,omitempty,string"`
9952
9953
9954
9955 CreateInfo *LastModifiedInfo `json:"createInfo,omitempty"`
9956
9957
9958
9959
9960
9961 DirectorySiteId int64 `json:"directorySiteId,omitempty,string"`
9962
9963
9964
9965 DirectorySiteIdDimensionValue *DimensionValue `json:"directorySiteIdDimensionValue,omitempty"`
9966
9967
9968 ExternalId string `json:"externalId,omitempty"`
9969
9970
9971 Id int64 `json:"id,omitempty,string"`
9972
9973
9974
9975 IdDimensionValue *DimensionValue `json:"idDimensionValue,omitempty"`
9976
9977
9978
9979 KeyName string `json:"keyName,omitempty"`
9980
9981
9982
9983 Kind string `json:"kind,omitempty"`
9984
9985
9986
9987 LastModifiedInfo *LastModifiedInfo `json:"lastModifiedInfo,omitempty"`
9988
9989
9990 LookbackConfiguration *LookbackConfiguration `json:"lookbackConfiguration,omitempty"`
9991
9992
9993
9994 Name string `json:"name,omitempty"`
9995
9996
9997
9998 PaymentApproved bool `json:"paymentApproved,omitempty"`
9999
10000
10001
10002
10003
10004
10005
10006 PaymentSource string `json:"paymentSource,omitempty"`
10007
10008
10009 PlacementGroupId int64 `json:"placementGroupId,omitempty,string"`
10010
10011
10012
10013 PlacementGroupIdDimensionValue *DimensionValue `json:"placementGroupIdDimensionValue,omitempty"`
10014
10015
10016
10017 PlacementStrategyId int64 `json:"placementStrategyId,omitempty,string"`
10018
10019
10020
10021
10022 PricingSchedule *PricingSchedule `json:"pricingSchedule,omitempty"`
10023
10024
10025
10026
10027
10028
10029
10030 Primary bool `json:"primary,omitempty"`
10031
10032
10033
10034 PublisherUpdateInfo *LastModifiedInfo `json:"publisherUpdateInfo,omitempty"`
10035
10036
10037
10038
10039
10040 SiteId int64 `json:"siteId,omitempty,string"`
10041
10042
10043
10044 SiteIdDimensionValue *DimensionValue `json:"siteIdDimensionValue,omitempty"`
10045
10046
10047
10048
10049 Size *Size `json:"size,omitempty"`
10050
10051
10052
10053 SslRequired bool `json:"sslRequired,omitempty"`
10054
10055
10056
10057
10058
10059
10060
10061
10062
10063
10064 Status string `json:"status,omitempty"`
10065
10066
10067
10068 SubaccountId int64 `json:"subaccountId,omitempty,string"`
10069
10070
10071
10072
10073
10074
10075
10076
10077
10078
10079
10080
10081
10082
10083
10084
10085
10086
10087
10088
10089
10090
10091
10092
10093
10094
10095
10096
10097
10098
10099
10100
10101
10102
10103
10104
10105
10106
10107
10108
10109 TagFormats []string `json:"tagFormats,omitempty"`
10110
10111
10112 TagSetting *TagSetting `json:"tagSetting,omitempty"`
10113
10114
10115
10116
10117
10118
10119
10120
10121
10122 VideoActiveViewOptOut bool `json:"videoActiveViewOptOut,omitempty"`
10123
10124
10125
10126
10127 VideoSettings *VideoSettings `json:"videoSettings,omitempty"`
10128
10129
10130
10131
10132
10133
10134
10135
10136
10137
10138
10139
10140
10141 VpaidAdapterChoice string `json:"vpaidAdapterChoice,omitempty"`
10142
10143
10144
10145 googleapi.ServerResponse `json:"-"`
10146
10147
10148
10149
10150
10151
10152
10153 ForceSendFields []string `json:"-"`
10154
10155
10156
10157
10158
10159
10160
10161 NullFields []string `json:"-"`
10162 }
10163
10164 func (s *Placement) MarshalJSON() ([]byte, error) {
10165 type NoMethod Placement
10166 raw := NoMethod(*s)
10167 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10168 }
10169
10170
10171 type PlacementAssignment struct {
10172
10173
10174 Active bool `json:"active,omitempty"`
10175
10176
10177
10178 PlacementId int64 `json:"placementId,omitempty,string"`
10179
10180
10181
10182 PlacementIdDimensionValue *DimensionValue `json:"placementIdDimensionValue,omitempty"`
10183
10184
10185
10186
10187 SslRequired bool `json:"sslRequired,omitempty"`
10188
10189
10190
10191
10192
10193
10194
10195 ForceSendFields []string `json:"-"`
10196
10197
10198
10199
10200
10201
10202
10203 NullFields []string `json:"-"`
10204 }
10205
10206 func (s *PlacementAssignment) MarshalJSON() ([]byte, error) {
10207 type NoMethod PlacementAssignment
10208 raw := NoMethod(*s)
10209 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10210 }
10211
10212
10213 type PlacementGroup struct {
10214
10215
10216 AccountId int64 `json:"accountId,omitempty,string"`
10217
10218
10219
10220 AdvertiserId int64 `json:"advertiserId,omitempty,string"`
10221
10222
10223
10224 AdvertiserIdDimensionValue *DimensionValue `json:"advertiserIdDimensionValue,omitempty"`
10225
10226
10227 Archived bool `json:"archived,omitempty"`
10228
10229
10230
10231 CampaignId int64 `json:"campaignId,omitempty,string"`
10232
10233
10234
10235 CampaignIdDimensionValue *DimensionValue `json:"campaignIdDimensionValue,omitempty"`
10236
10237
10238
10239 ChildPlacementIds googleapi.Int64s `json:"childPlacementIds,omitempty"`
10240
10241
10242 Comment string `json:"comment,omitempty"`
10243
10244
10245
10246 ContentCategoryId int64 `json:"contentCategoryId,omitempty,string"`
10247
10248
10249
10250 CreateInfo *LastModifiedInfo `json:"createInfo,omitempty"`
10251
10252
10253
10254
10255
10256 DirectorySiteId int64 `json:"directorySiteId,omitempty,string"`
10257
10258
10259
10260 DirectorySiteIdDimensionValue *DimensionValue `json:"directorySiteIdDimensionValue,omitempty"`
10261
10262
10263 ExternalId string `json:"externalId,omitempty"`
10264
10265
10266
10267 Id int64 `json:"id,omitempty,string"`
10268
10269
10270
10271 IdDimensionValue *DimensionValue `json:"idDimensionValue,omitempty"`
10272
10273
10274
10275 Kind string `json:"kind,omitempty"`
10276
10277
10278
10279 LastModifiedInfo *LastModifiedInfo `json:"lastModifiedInfo,omitempty"`
10280
10281
10282
10283 Name string `json:"name,omitempty"`
10284
10285
10286
10287
10288
10289
10290
10291
10292
10293
10294
10295
10296 PlacementGroupType string `json:"placementGroupType,omitempty"`
10297
10298
10299
10300 PlacementStrategyId int64 `json:"placementStrategyId,omitempty,string"`
10301
10302
10303
10304 PricingSchedule *PricingSchedule `json:"pricingSchedule,omitempty"`
10305
10306
10307
10308
10309
10310 PrimaryPlacementId int64 `json:"primaryPlacementId,omitempty,string"`
10311
10312
10313
10314 PrimaryPlacementIdDimensionValue *DimensionValue `json:"primaryPlacementIdDimensionValue,omitempty"`
10315
10316
10317
10318
10319
10320 SiteId int64 `json:"siteId,omitempty,string"`
10321
10322
10323
10324 SiteIdDimensionValue *DimensionValue `json:"siteIdDimensionValue,omitempty"`
10325
10326
10327
10328 SubaccountId int64 `json:"subaccountId,omitempty,string"`
10329
10330
10331
10332 googleapi.ServerResponse `json:"-"`
10333
10334
10335
10336
10337
10338
10339
10340 ForceSendFields []string `json:"-"`
10341
10342
10343
10344
10345
10346
10347
10348 NullFields []string `json:"-"`
10349 }
10350
10351 func (s *PlacementGroup) MarshalJSON() ([]byte, error) {
10352 type NoMethod PlacementGroup
10353 raw := NoMethod(*s)
10354 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10355 }
10356
10357
10358 type PlacementGroupsListResponse struct {
10359
10360
10361 Kind string `json:"kind,omitempty"`
10362
10363
10364
10365 NextPageToken string `json:"nextPageToken,omitempty"`
10366
10367
10368 PlacementGroups []*PlacementGroup `json:"placementGroups,omitempty"`
10369
10370
10371
10372 googleapi.ServerResponse `json:"-"`
10373
10374
10375
10376
10377
10378
10379
10380 ForceSendFields []string `json:"-"`
10381
10382
10383
10384
10385
10386
10387
10388 NullFields []string `json:"-"`
10389 }
10390
10391 func (s *PlacementGroupsListResponse) MarshalJSON() ([]byte, error) {
10392 type NoMethod PlacementGroupsListResponse
10393 raw := NoMethod(*s)
10394 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10395 }
10396
10397
10398 type PlacementStrategiesListResponse struct {
10399
10400
10401 Kind string `json:"kind,omitempty"`
10402
10403
10404
10405 NextPageToken string `json:"nextPageToken,omitempty"`
10406
10407
10408 PlacementStrategies []*PlacementStrategy `json:"placementStrategies,omitempty"`
10409
10410
10411
10412 googleapi.ServerResponse `json:"-"`
10413
10414
10415
10416
10417
10418
10419
10420 ForceSendFields []string `json:"-"`
10421
10422
10423
10424
10425
10426
10427
10428 NullFields []string `json:"-"`
10429 }
10430
10431 func (s *PlacementStrategiesListResponse) MarshalJSON() ([]byte, error) {
10432 type NoMethod PlacementStrategiesListResponse
10433 raw := NoMethod(*s)
10434 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10435 }
10436
10437
10438 type PlacementStrategy struct {
10439
10440
10441 AccountId int64 `json:"accountId,omitempty,string"`
10442
10443
10444
10445 Id int64 `json:"id,omitempty,string"`
10446
10447
10448
10449 Kind string `json:"kind,omitempty"`
10450
10451
10452
10453
10454 Name string `json:"name,omitempty"`
10455
10456
10457
10458 googleapi.ServerResponse `json:"-"`
10459
10460
10461
10462
10463
10464
10465
10466 ForceSendFields []string `json:"-"`
10467
10468
10469
10470
10471
10472
10473
10474 NullFields []string `json:"-"`
10475 }
10476
10477 func (s *PlacementStrategy) MarshalJSON() ([]byte, error) {
10478 type NoMethod PlacementStrategy
10479 raw := NoMethod(*s)
10480 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10481 }
10482
10483
10484 type PlacementTag struct {
10485
10486 PlacementId int64 `json:"placementId,omitempty,string"`
10487
10488
10489 TagDatas []*TagData `json:"tagDatas,omitempty"`
10490
10491
10492
10493
10494
10495
10496
10497 ForceSendFields []string `json:"-"`
10498
10499
10500
10501
10502
10503
10504
10505 NullFields []string `json:"-"`
10506 }
10507
10508 func (s *PlacementTag) MarshalJSON() ([]byte, error) {
10509 type NoMethod PlacementTag
10510 raw := NoMethod(*s)
10511 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10512 }
10513
10514
10515 type PlacementsGenerateTagsResponse struct {
10516
10517
10518 Kind string `json:"kind,omitempty"`
10519
10520
10521 PlacementTags []*PlacementTag `json:"placementTags,omitempty"`
10522
10523
10524
10525 googleapi.ServerResponse `json:"-"`
10526
10527
10528
10529
10530
10531
10532
10533 ForceSendFields []string `json:"-"`
10534
10535
10536
10537
10538
10539
10540
10541 NullFields []string `json:"-"`
10542 }
10543
10544 func (s *PlacementsGenerateTagsResponse) MarshalJSON() ([]byte, error) {
10545 type NoMethod PlacementsGenerateTagsResponse
10546 raw := NoMethod(*s)
10547 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10548 }
10549
10550
10551 type PlacementsListResponse struct {
10552
10553
10554 Kind string `json:"kind,omitempty"`
10555
10556
10557
10558 NextPageToken string `json:"nextPageToken,omitempty"`
10559
10560
10561 Placements []*Placement `json:"placements,omitempty"`
10562
10563
10564
10565 googleapi.ServerResponse `json:"-"`
10566
10567
10568
10569
10570
10571
10572
10573 ForceSendFields []string `json:"-"`
10574
10575
10576
10577
10578
10579
10580
10581 NullFields []string `json:"-"`
10582 }
10583
10584 func (s *PlacementsListResponse) MarshalJSON() ([]byte, error) {
10585 type NoMethod PlacementsListResponse
10586 raw := NoMethod(*s)
10587 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10588 }
10589
10590
10591
10592 type PlatformType struct {
10593
10594 Id int64 `json:"id,omitempty,string"`
10595
10596
10597
10598 Kind string `json:"kind,omitempty"`
10599
10600
10601 Name string `json:"name,omitempty"`
10602
10603
10604
10605 googleapi.ServerResponse `json:"-"`
10606
10607
10608
10609
10610
10611
10612
10613 ForceSendFields []string `json:"-"`
10614
10615
10616
10617
10618
10619
10620
10621 NullFields []string `json:"-"`
10622 }
10623
10624 func (s *PlatformType) MarshalJSON() ([]byte, error) {
10625 type NoMethod PlatformType
10626 raw := NoMethod(*s)
10627 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10628 }
10629
10630
10631 type PlatformTypesListResponse struct {
10632
10633
10634 Kind string `json:"kind,omitempty"`
10635
10636
10637 PlatformTypes []*PlatformType `json:"platformTypes,omitempty"`
10638
10639
10640
10641 googleapi.ServerResponse `json:"-"`
10642
10643
10644
10645
10646
10647
10648
10649 ForceSendFields []string `json:"-"`
10650
10651
10652
10653
10654
10655
10656
10657 NullFields []string `json:"-"`
10658 }
10659
10660 func (s *PlatformTypesListResponse) MarshalJSON() ([]byte, error) {
10661 type NoMethod PlatformTypesListResponse
10662 raw := NoMethod(*s)
10663 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10664 }
10665
10666
10667 type PopupWindowProperties struct {
10668
10669
10670
10671 Dimension *Size `json:"dimension,omitempty"`
10672
10673
10674
10675 Offset *OffsetPosition `json:"offset,omitempty"`
10676
10677
10678
10679
10680
10681
10682
10683 PositionType string `json:"positionType,omitempty"`
10684
10685
10686 ShowAddressBar bool `json:"showAddressBar,omitempty"`
10687
10688
10689 ShowMenuBar bool `json:"showMenuBar,omitempty"`
10690
10691
10692 ShowScrollBar bool `json:"showScrollBar,omitempty"`
10693
10694
10695 ShowStatusBar bool `json:"showStatusBar,omitempty"`
10696
10697
10698 ShowToolBar bool `json:"showToolBar,omitempty"`
10699
10700
10701 Title string `json:"title,omitempty"`
10702
10703
10704
10705
10706
10707
10708
10709 ForceSendFields []string `json:"-"`
10710
10711
10712
10713
10714
10715
10716
10717 NullFields []string `json:"-"`
10718 }
10719
10720 func (s *PopupWindowProperties) MarshalJSON() ([]byte, error) {
10721 type NoMethod PopupWindowProperties
10722 raw := NoMethod(*s)
10723 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10724 }
10725
10726
10727
10728 type PostalCode struct {
10729
10730 Code string `json:"code,omitempty"`
10731
10732
10733
10734 CountryCode string `json:"countryCode,omitempty"`
10735
10736
10737
10738 CountryDartId int64 `json:"countryDartId,omitempty,string"`
10739
10740
10741 Id string `json:"id,omitempty"`
10742
10743
10744
10745 Kind string `json:"kind,omitempty"`
10746
10747
10748
10749 googleapi.ServerResponse `json:"-"`
10750
10751
10752
10753
10754
10755
10756
10757 ForceSendFields []string `json:"-"`
10758
10759
10760
10761
10762
10763
10764
10765 NullFields []string `json:"-"`
10766 }
10767
10768 func (s *PostalCode) MarshalJSON() ([]byte, error) {
10769 type NoMethod PostalCode
10770 raw := NoMethod(*s)
10771 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10772 }
10773
10774
10775 type PostalCodesListResponse struct {
10776
10777
10778 Kind string `json:"kind,omitempty"`
10779
10780
10781 PostalCodes []*PostalCode `json:"postalCodes,omitempty"`
10782
10783
10784
10785 googleapi.ServerResponse `json:"-"`
10786
10787
10788
10789
10790
10791
10792
10793 ForceSendFields []string `json:"-"`
10794
10795
10796
10797
10798
10799
10800
10801 NullFields []string `json:"-"`
10802 }
10803
10804 func (s *PostalCodesListResponse) MarshalJSON() ([]byte, error) {
10805 type NoMethod PostalCodesListResponse
10806 raw := NoMethod(*s)
10807 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10808 }
10809
10810
10811 type Pricing struct {
10812
10813
10814
10815
10816
10817
10818 CapCostType string `json:"capCostType,omitempty"`
10819
10820
10821 EndDate string `json:"endDate,omitempty"`
10822
10823
10824
10825
10826 Flights []*Flight `json:"flights,omitempty"`
10827
10828
10829
10830
10831
10832
10833
10834
10835
10836
10837
10838
10839
10840 GroupType string `json:"groupType,omitempty"`
10841
10842
10843
10844
10845
10846
10847
10848
10849
10850
10851
10852
10853 PricingType string `json:"pricingType,omitempty"`
10854
10855
10856 StartDate string `json:"startDate,omitempty"`
10857
10858
10859
10860
10861
10862
10863
10864 ForceSendFields []string `json:"-"`
10865
10866
10867
10868
10869
10870
10871
10872 NullFields []string `json:"-"`
10873 }
10874
10875 func (s *Pricing) MarshalJSON() ([]byte, error) {
10876 type NoMethod Pricing
10877 raw := NoMethod(*s)
10878 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10879 }
10880
10881
10882 type PricingSchedule struct {
10883
10884
10885
10886
10887
10888
10889 CapCostOption string `json:"capCostOption,omitempty"`
10890
10891
10892 DisregardOverdelivery bool `json:"disregardOverdelivery,omitempty"`
10893
10894
10895
10896
10897
10898
10899
10900
10901 EndDate string `json:"endDate,omitempty"`
10902
10903
10904
10905 Flighted bool `json:"flighted,omitempty"`
10906
10907
10908
10909
10910 FloodlightActivityId int64 `json:"floodlightActivityId,omitempty,string"`
10911
10912
10913 PricingPeriods []*PricingSchedulePricingPeriod `json:"pricingPeriods,omitempty"`
10914
10915
10916
10917
10918
10919
10920
10921
10922
10923
10924
10925 PricingType string `json:"pricingType,omitempty"`
10926
10927
10928
10929
10930
10931 StartDate string `json:"startDate,omitempty"`
10932
10933
10934
10935
10936 TestingStartDate string `json:"testingStartDate,omitempty"`
10937
10938
10939
10940
10941
10942
10943
10944 ForceSendFields []string `json:"-"`
10945
10946
10947
10948
10949
10950
10951
10952 NullFields []string `json:"-"`
10953 }
10954
10955 func (s *PricingSchedule) MarshalJSON() ([]byte, error) {
10956 type NoMethod PricingSchedule
10957 raw := NoMethod(*s)
10958 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10959 }
10960
10961
10962 type PricingSchedulePricingPeriod struct {
10963
10964
10965
10966
10967
10968
10969
10970 EndDate string `json:"endDate,omitempty"`
10971
10972
10973 PricingComment string `json:"pricingComment,omitempty"`
10974
10975
10976
10977
10978 RateOrCostNanos int64 `json:"rateOrCostNanos,omitempty,string"`
10979
10980
10981
10982
10983
10984 StartDate string `json:"startDate,omitempty"`
10985
10986
10987
10988 Units int64 `json:"units,omitempty,string"`
10989
10990
10991
10992
10993
10994
10995
10996 ForceSendFields []string `json:"-"`
10997
10998
10999
11000
11001
11002
11003
11004 NullFields []string `json:"-"`
11005 }
11006
11007 func (s *PricingSchedulePricingPeriod) MarshalJSON() ([]byte, error) {
11008 type NoMethod PricingSchedulePricingPeriod
11009 raw := NoMethod(*s)
11010 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11011 }
11012
11013
11014 type Project struct {
11015
11016 AccountId int64 `json:"accountId,omitempty,string"`
11017
11018
11019 AdvertiserId int64 `json:"advertiserId,omitempty,string"`
11020
11021
11022
11023
11024
11025
11026
11027
11028
11029
11030
11031 AudienceAgeGroup string `json:"audienceAgeGroup,omitempty"`
11032
11033
11034
11035
11036
11037
11038 AudienceGender string `json:"audienceGender,omitempty"`
11039
11040
11041
11042
11043
11044 Budget int64 `json:"budget,omitempty,string"`
11045
11046
11047 ClientBillingCode string `json:"clientBillingCode,omitempty"`
11048
11049
11050 ClientName string `json:"clientName,omitempty"`
11051
11052
11053 EndDate string `json:"endDate,omitempty"`
11054
11055
11056 Id int64 `json:"id,omitempty,string"`
11057
11058
11059
11060 Kind string `json:"kind,omitempty"`
11061
11062
11063
11064 LastModifiedInfo *LastModifiedInfo `json:"lastModifiedInfo,omitempty"`
11065
11066
11067 Name string `json:"name,omitempty"`
11068
11069
11070 Overview string `json:"overview,omitempty"`
11071
11072
11073 StartDate string `json:"startDate,omitempty"`
11074
11075
11076 SubaccountId int64 `json:"subaccountId,omitempty,string"`
11077
11078
11079 TargetClicks int64 `json:"targetClicks,omitempty,string"`
11080
11081
11082
11083 TargetConversions int64 `json:"targetConversions,omitempty,string"`
11084
11085
11086 TargetCpaNanos int64 `json:"targetCpaNanos,omitempty,string"`
11087
11088
11089 TargetCpcNanos int64 `json:"targetCpcNanos,omitempty,string"`
11090
11091
11092
11093 TargetCpmActiveViewNanos int64 `json:"targetCpmActiveViewNanos,omitempty,string"`
11094
11095
11096 TargetCpmNanos int64 `json:"targetCpmNanos,omitempty,string"`
11097
11098
11099
11100 TargetImpressions int64 `json:"targetImpressions,omitempty,string"`
11101
11102
11103
11104 googleapi.ServerResponse `json:"-"`
11105
11106
11107
11108
11109
11110
11111
11112 ForceSendFields []string `json:"-"`
11113
11114
11115
11116
11117
11118
11119
11120 NullFields []string `json:"-"`
11121 }
11122
11123 func (s *Project) MarshalJSON() ([]byte, error) {
11124 type NoMethod Project
11125 raw := NoMethod(*s)
11126 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11127 }
11128
11129
11130 type ProjectsListResponse struct {
11131
11132
11133 Kind string `json:"kind,omitempty"`
11134
11135
11136
11137 NextPageToken string `json:"nextPageToken,omitempty"`
11138
11139
11140 Projects []*Project `json:"projects,omitempty"`
11141
11142
11143
11144 googleapi.ServerResponse `json:"-"`
11145
11146
11147
11148
11149
11150
11151
11152 ForceSendFields []string `json:"-"`
11153
11154
11155
11156
11157
11158
11159
11160 NullFields []string `json:"-"`
11161 }
11162
11163 func (s *ProjectsListResponse) MarshalJSON() ([]byte, error) {
11164 type NoMethod ProjectsListResponse
11165 raw := NoMethod(*s)
11166 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11167 }
11168
11169
11170
11171 type ReachReportCompatibleFields struct {
11172
11173
11174 DimensionFilters []*Dimension `json:"dimensionFilters,omitempty"`
11175
11176
11177
11178 Dimensions []*Dimension `json:"dimensions,omitempty"`
11179
11180
11181
11182 Kind string `json:"kind,omitempty"`
11183
11184
11185
11186 Metrics []*Metric `json:"metrics,omitempty"`
11187
11188
11189
11190
11191 PivotedActivityMetrics []*Metric `json:"pivotedActivityMetrics,omitempty"`
11192
11193
11194
11195 ReachByFrequencyMetrics []*Metric `json:"reachByFrequencyMetrics,omitempty"`
11196
11197
11198
11199
11200
11201
11202
11203 ForceSendFields []string `json:"-"`
11204
11205
11206
11207
11208
11209
11210
11211
11212 NullFields []string `json:"-"`
11213 }
11214
11215 func (s *ReachReportCompatibleFields) MarshalJSON() ([]byte, error) {
11216 type NoMethod ReachReportCompatibleFields
11217 raw := NoMethod(*s)
11218 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11219 }
11220
11221
11222 type Recipient struct {
11223
11224
11225
11226
11227
11228 DeliveryType string `json:"deliveryType,omitempty"`
11229
11230
11231 Email string `json:"email,omitempty"`
11232
11233
11234
11235 Kind string `json:"kind,omitempty"`
11236
11237
11238
11239
11240
11241
11242
11243 ForceSendFields []string `json:"-"`
11244
11245
11246
11247
11248
11249
11250
11251 NullFields []string `json:"-"`
11252 }
11253
11254 func (s *Recipient) MarshalJSON() ([]byte, error) {
11255 type NoMethod Recipient
11256 raw := NoMethod(*s)
11257 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11258 }
11259
11260
11261
11262 type Region struct {
11263
11264
11265 CountryCode string `json:"countryCode,omitempty"`
11266
11267
11268 CountryDartId int64 `json:"countryDartId,omitempty,string"`
11269
11270
11271 DartId int64 `json:"dartId,omitempty,string"`
11272
11273
11274
11275 Kind string `json:"kind,omitempty"`
11276
11277
11278 Name string `json:"name,omitempty"`
11279
11280
11281 RegionCode string `json:"regionCode,omitempty"`
11282
11283
11284
11285
11286
11287
11288
11289 ForceSendFields []string `json:"-"`
11290
11291
11292
11293
11294
11295
11296
11297 NullFields []string `json:"-"`
11298 }
11299
11300 func (s *Region) MarshalJSON() ([]byte, error) {
11301 type NoMethod Region
11302 raw := NoMethod(*s)
11303 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11304 }
11305
11306
11307 type RegionsListResponse struct {
11308
11309
11310 Kind string `json:"kind,omitempty"`
11311
11312
11313 Regions []*Region `json:"regions,omitempty"`
11314
11315
11316
11317 googleapi.ServerResponse `json:"-"`
11318
11319
11320
11321
11322
11323
11324
11325 ForceSendFields []string `json:"-"`
11326
11327
11328
11329
11330
11331
11332
11333 NullFields []string `json:"-"`
11334 }
11335
11336 func (s *RegionsListResponse) MarshalJSON() ([]byte, error) {
11337 type NoMethod RegionsListResponse
11338 raw := NoMethod(*s)
11339 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11340 }
11341
11342
11343
11344
11345
11346
11347
11348
11349 type RemarketingList struct {
11350
11351
11352 AccountId int64 `json:"accountId,omitempty,string"`
11353
11354
11355 Active bool `json:"active,omitempty"`
11356
11357
11358
11359 AdvertiserId int64 `json:"advertiserId,omitempty,string"`
11360
11361
11362
11363 AdvertiserIdDimensionValue *DimensionValue `json:"advertiserIdDimensionValue,omitempty"`
11364
11365
11366 Description string `json:"description,omitempty"`
11367
11368
11369 Id int64 `json:"id,omitempty,string"`
11370
11371
11372
11373 Kind string `json:"kind,omitempty"`
11374
11375
11376
11377
11378 LifeSpan int64 `json:"lifeSpan,omitempty,string"`
11379
11380
11381
11382 ListPopulationRule *ListPopulationRule `json:"listPopulationRule,omitempty"`
11383
11384
11385
11386 ListSize int64 `json:"listSize,omitempty,string"`
11387
11388
11389
11390
11391
11392
11393
11394
11395
11396
11397
11398
11399
11400
11401
11402 ListSource string `json:"listSource,omitempty"`
11403
11404
11405
11406 Name string `json:"name,omitempty"`
11407
11408
11409
11410
11411 SubaccountId int64 `json:"subaccountId,omitempty,string"`
11412
11413
11414
11415 googleapi.ServerResponse `json:"-"`
11416
11417
11418
11419
11420
11421
11422
11423 ForceSendFields []string `json:"-"`
11424
11425
11426
11427
11428
11429
11430
11431 NullFields []string `json:"-"`
11432 }
11433
11434 func (s *RemarketingList) MarshalJSON() ([]byte, error) {
11435 type NoMethod RemarketingList
11436 raw := NoMethod(*s)
11437 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11438 }
11439
11440
11441
11442
11443
11444 type RemarketingListShare struct {
11445
11446
11447 Kind string `json:"kind,omitempty"`
11448
11449
11450
11451 RemarketingListId int64 `json:"remarketingListId,omitempty,string"`
11452
11453
11454 SharedAccountIds googleapi.Int64s `json:"sharedAccountIds,omitempty"`
11455
11456
11457
11458 SharedAdvertiserIds googleapi.Int64s `json:"sharedAdvertiserIds,omitempty"`
11459
11460
11461
11462 googleapi.ServerResponse `json:"-"`
11463
11464
11465
11466
11467
11468
11469
11470 ForceSendFields []string `json:"-"`
11471
11472
11473
11474
11475
11476
11477
11478 NullFields []string `json:"-"`
11479 }
11480
11481 func (s *RemarketingListShare) MarshalJSON() ([]byte, error) {
11482 type NoMethod RemarketingListShare
11483 raw := NoMethod(*s)
11484 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11485 }
11486
11487
11488 type RemarketingListsListResponse struct {
11489
11490
11491 Kind string `json:"kind,omitempty"`
11492
11493
11494
11495 NextPageToken string `json:"nextPageToken,omitempty"`
11496
11497
11498 RemarketingLists []*RemarketingList `json:"remarketingLists,omitempty"`
11499
11500
11501
11502 googleapi.ServerResponse `json:"-"`
11503
11504
11505
11506
11507
11508
11509
11510 ForceSendFields []string `json:"-"`
11511
11512
11513
11514
11515
11516
11517
11518 NullFields []string `json:"-"`
11519 }
11520
11521 func (s *RemarketingListsListResponse) MarshalJSON() ([]byte, error) {
11522 type NoMethod RemarketingListsListResponse
11523 raw := NoMethod(*s)
11524 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11525 }
11526
11527
11528 type Report struct {
11529
11530 AccountId int64 `json:"accountId,omitempty,string"`
11531
11532
11533 Criteria *ReportCriteria `json:"criteria,omitempty"`
11534
11535
11536
11537 CrossDimensionReachCriteria *ReportCrossDimensionReachCriteria `json:"crossDimensionReachCriteria,omitempty"`
11538
11539
11540 Delivery *ReportDelivery `json:"delivery,omitempty"`
11541
11542
11543 Etag string `json:"etag,omitempty"`
11544
11545
11546
11547 FileName string `json:"fileName,omitempty"`
11548
11549
11550
11551 FloodlightCriteria *ReportFloodlightCriteria `json:"floodlightCriteria,omitempty"`
11552
11553
11554
11555
11556
11557
11558
11559
11560
11561 Format string `json:"format,omitempty"`
11562
11563
11564 Id int64 `json:"id,omitempty,string"`
11565
11566
11567 Kind string `json:"kind,omitempty"`
11568
11569
11570
11571 LastModifiedTime uint64 `json:"lastModifiedTime,omitempty,string"`
11572
11573
11574 Name string `json:"name,omitempty"`
11575
11576
11577 OwnerProfileId int64 `json:"ownerProfileId,omitempty,string"`
11578
11579
11580
11581 PathToConversionCriteria *ReportPathToConversionCriteria `json:"pathToConversionCriteria,omitempty"`
11582
11583
11584 ReachCriteria *ReportReachCriteria `json:"reachCriteria,omitempty"`
11585
11586
11587
11588
11589 Schedule *ReportSchedule `json:"schedule,omitempty"`
11590
11591
11592
11593 SubAccountId int64 `json:"subAccountId,omitempty,string"`
11594
11595
11596
11597
11598
11599
11600
11601
11602
11603 Type string `json:"type,omitempty"`
11604
11605
11606
11607 googleapi.ServerResponse `json:"-"`
11608
11609
11610
11611
11612
11613
11614
11615 ForceSendFields []string `json:"-"`
11616
11617
11618
11619
11620
11621
11622
11623 NullFields []string `json:"-"`
11624 }
11625
11626 func (s *Report) MarshalJSON() ([]byte, error) {
11627 type NoMethod Report
11628 raw := NoMethod(*s)
11629 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11630 }
11631
11632
11633 type ReportCriteria struct {
11634
11635 Activities *Activities `json:"activities,omitempty"`
11636
11637
11638 CustomRichMediaEvents *CustomRichMediaEvents `json:"customRichMediaEvents,omitempty"`
11639
11640
11641 DateRange *DateRange `json:"dateRange,omitempty"`
11642
11643
11644
11645
11646
11647 DimensionFilters []*DimensionValue `json:"dimensionFilters,omitempty"`
11648
11649
11650
11651 Dimensions []*SortedDimension `json:"dimensions,omitempty"`
11652
11653
11654 MetricNames []string `json:"metricNames,omitempty"`
11655
11656
11657
11658
11659
11660
11661
11662 ForceSendFields []string `json:"-"`
11663
11664
11665
11666
11667
11668
11669
11670 NullFields []string `json:"-"`
11671 }
11672
11673 func (s *ReportCriteria) MarshalJSON() ([]byte, error) {
11674 type NoMethod ReportCriteria
11675 raw := NoMethod(*s)
11676 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11677 }
11678
11679
11680
11681 type ReportCrossDimensionReachCriteria struct {
11682
11683 Breakdown []*SortedDimension `json:"breakdown,omitempty"`
11684
11685
11686 DateRange *DateRange `json:"dateRange,omitempty"`
11687
11688
11689
11690
11691
11692
11693
11694
11695 Dimension string `json:"dimension,omitempty"`
11696
11697
11698
11699 DimensionFilters []*DimensionValue `json:"dimensionFilters,omitempty"`
11700
11701
11702 MetricNames []string `json:"metricNames,omitempty"`
11703
11704
11705
11706 OverlapMetricNames []string `json:"overlapMetricNames,omitempty"`
11707
11708
11709 Pivoted bool `json:"pivoted,omitempty"`
11710
11711
11712
11713
11714
11715
11716
11717 ForceSendFields []string `json:"-"`
11718
11719
11720
11721
11722
11723
11724
11725 NullFields []string `json:"-"`
11726 }
11727
11728 func (s *ReportCrossDimensionReachCriteria) MarshalJSON() ([]byte, error) {
11729 type NoMethod ReportCrossDimensionReachCriteria
11730 raw := NoMethod(*s)
11731 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11732 }
11733
11734
11735 type ReportDelivery struct {
11736
11737 EmailOwner bool `json:"emailOwner,omitempty"`
11738
11739
11740
11741
11742
11743
11744
11745 EmailOwnerDeliveryType string `json:"emailOwnerDeliveryType,omitempty"`
11746
11747
11748 Message string `json:"message,omitempty"`
11749
11750
11751 Recipients []*Recipient `json:"recipients,omitempty"`
11752
11753
11754
11755
11756
11757
11758
11759 ForceSendFields []string `json:"-"`
11760
11761
11762
11763
11764
11765
11766
11767 NullFields []string `json:"-"`
11768 }
11769
11770 func (s *ReportDelivery) MarshalJSON() ([]byte, error) {
11771 type NoMethod ReportDelivery
11772 raw := NoMethod(*s)
11773 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11774 }
11775
11776
11777
11778 type ReportFloodlightCriteria struct {
11779
11780
11781 CustomRichMediaEvents []*DimensionValue `json:"customRichMediaEvents,omitempty"`
11782
11783
11784 DateRange *DateRange `json:"dateRange,omitempty"`
11785
11786
11787
11788
11789
11790 DimensionFilters []*DimensionValue `json:"dimensionFilters,omitempty"`
11791
11792
11793 Dimensions []*SortedDimension `json:"dimensions,omitempty"`
11794
11795
11796
11797
11798
11799 FloodlightConfigId *DimensionValue `json:"floodlightConfigId,omitempty"`
11800
11801
11802 MetricNames []string `json:"metricNames,omitempty"`
11803
11804
11805 ReportProperties *ReportFloodlightCriteriaReportProperties `json:"reportProperties,omitempty"`
11806
11807
11808
11809
11810
11811
11812
11813
11814 ForceSendFields []string `json:"-"`
11815
11816
11817
11818
11819
11820
11821
11822
11823 NullFields []string `json:"-"`
11824 }
11825
11826 func (s *ReportFloodlightCriteria) MarshalJSON() ([]byte, error) {
11827 type NoMethod ReportFloodlightCriteria
11828 raw := NoMethod(*s)
11829 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11830 }
11831
11832
11833
11834 type ReportFloodlightCriteriaReportProperties struct {
11835
11836
11837 IncludeAttributedIPConversions bool `json:"includeAttributedIPConversions,omitempty"`
11838
11839
11840
11841
11842
11843
11844 IncludeUnattributedCookieConversions bool `json:"includeUnattributedCookieConversions,omitempty"`
11845
11846
11847
11848
11849
11850 IncludeUnattributedIPConversions bool `json:"includeUnattributedIPConversions,omitempty"`
11851
11852
11853
11854
11855
11856
11857
11858
11859 ForceSendFields []string `json:"-"`
11860
11861
11862
11863
11864
11865
11866
11867
11868 NullFields []string `json:"-"`
11869 }
11870
11871 func (s *ReportFloodlightCriteriaReportProperties) MarshalJSON() ([]byte, error) {
11872 type NoMethod ReportFloodlightCriteriaReportProperties
11873 raw := NoMethod(*s)
11874 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11875 }
11876
11877
11878
11879 type ReportPathToConversionCriteria struct {
11880
11881 ActivityFilters []*DimensionValue `json:"activityFilters,omitempty"`
11882
11883
11884
11885 ConversionDimensions []*SortedDimension `json:"conversionDimensions,omitempty"`
11886
11887
11888
11889 CustomFloodlightVariables []*SortedDimension `json:"customFloodlightVariables,omitempty"`
11890
11891
11892
11893 CustomRichMediaEvents []*DimensionValue `json:"customRichMediaEvents,omitempty"`
11894
11895
11896 DateRange *DateRange `json:"dateRange,omitempty"`
11897
11898
11899
11900
11901
11902 FloodlightConfigId *DimensionValue `json:"floodlightConfigId,omitempty"`
11903
11904
11905 MetricNames []string `json:"metricNames,omitempty"`
11906
11907
11908
11909 PerInteractionDimensions []*SortedDimension `json:"perInteractionDimensions,omitempty"`
11910
11911
11912 ReportProperties *ReportPathToConversionCriteriaReportProperties `json:"reportProperties,omitempty"`
11913
11914
11915
11916
11917
11918
11919
11920 ForceSendFields []string `json:"-"`
11921
11922
11923
11924
11925
11926
11927
11928
11929 NullFields []string `json:"-"`
11930 }
11931
11932 func (s *ReportPathToConversionCriteria) MarshalJSON() ([]byte, error) {
11933 type NoMethod ReportPathToConversionCriteria
11934 raw := NoMethod(*s)
11935 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11936 }
11937
11938
11939
11940 type ReportPathToConversionCriteriaReportProperties struct {
11941
11942
11943
11944
11945 ClicksLookbackWindow int64 `json:"clicksLookbackWindow,omitempty"`
11946
11947
11948
11949
11950
11951 ImpressionsLookbackWindow int64 `json:"impressionsLookbackWindow,omitempty"`
11952
11953
11954 IncludeAttributedIPConversions bool `json:"includeAttributedIPConversions,omitempty"`
11955
11956
11957
11958
11959
11960
11961 IncludeUnattributedCookieConversions bool `json:"includeUnattributedCookieConversions,omitempty"`
11962
11963
11964
11965
11966
11967 IncludeUnattributedIPConversions bool `json:"includeUnattributedIPConversions,omitempty"`
11968
11969
11970
11971
11972
11973
11974 MaximumClickInteractions int64 `json:"maximumClickInteractions,omitempty"`
11975
11976
11977
11978
11979
11980
11981 MaximumImpressionInteractions int64 `json:"maximumImpressionInteractions,omitempty"`
11982
11983
11984
11985
11986 MaximumInteractionGap int64 `json:"maximumInteractionGap,omitempty"`
11987
11988
11989 PivotOnInteractionPath bool `json:"pivotOnInteractionPath,omitempty"`
11990
11991
11992
11993
11994
11995
11996
11997
11998 ForceSendFields []string `json:"-"`
11999
12000
12001
12002
12003
12004
12005
12006
12007 NullFields []string `json:"-"`
12008 }
12009
12010 func (s *ReportPathToConversionCriteriaReportProperties) MarshalJSON() ([]byte, error) {
12011 type NoMethod ReportPathToConversionCriteriaReportProperties
12012 raw := NoMethod(*s)
12013 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12014 }
12015
12016
12017
12018 type ReportReachCriteria struct {
12019
12020 Activities *Activities `json:"activities,omitempty"`
12021
12022
12023 CustomRichMediaEvents *CustomRichMediaEvents `json:"customRichMediaEvents,omitempty"`
12024
12025
12026 DateRange *DateRange `json:"dateRange,omitempty"`
12027
12028
12029
12030
12031
12032 DimensionFilters []*DimensionValue `json:"dimensionFilters,omitempty"`
12033
12034
12035 Dimensions []*SortedDimension `json:"dimensions,omitempty"`
12036
12037
12038
12039
12040 EnableAllDimensionCombinations bool `json:"enableAllDimensionCombinations,omitempty"`
12041
12042
12043 MetricNames []string `json:"metricNames,omitempty"`
12044
12045
12046
12047 ReachByFrequencyMetricNames []string `json:"reachByFrequencyMetricNames,omitempty"`
12048
12049
12050
12051
12052
12053
12054
12055 ForceSendFields []string `json:"-"`
12056
12057
12058
12059
12060
12061
12062
12063 NullFields []string `json:"-"`
12064 }
12065
12066 func (s *ReportReachCriteria) MarshalJSON() ([]byte, error) {
12067 type NoMethod ReportReachCriteria
12068 raw := NoMethod(*s)
12069 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12070 }
12071
12072
12073
12074
12075 type ReportSchedule struct {
12076
12077
12078 Active bool `json:"active,omitempty"`
12079
12080
12081
12082
12083 Every int64 `json:"every,omitempty"`
12084
12085
12086
12087 ExpirationDate string `json:"expirationDate,omitempty"`
12088
12089
12090
12091
12092
12093
12094
12095 Repeats string `json:"repeats,omitempty"`
12096
12097
12098
12099
12100
12101
12102
12103
12104
12105
12106
12107
12108 RepeatsOnWeekDays []string `json:"repeatsOnWeekDays,omitempty"`
12109
12110
12111
12112
12113
12114
12115
12116
12117
12118
12119
12120
12121 RunsOnDayOfMonth string `json:"runsOnDayOfMonth,omitempty"`
12122
12123
12124
12125 StartDate string `json:"startDate,omitempty"`
12126
12127
12128
12129
12130
12131
12132
12133 ForceSendFields []string `json:"-"`
12134
12135
12136
12137
12138
12139
12140
12141 NullFields []string `json:"-"`
12142 }
12143
12144 func (s *ReportSchedule) MarshalJSON() ([]byte, error) {
12145 type NoMethod ReportSchedule
12146 raw := NoMethod(*s)
12147 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12148 }
12149
12150
12151
12152 type ReportCompatibleFields struct {
12153
12154
12155 DimensionFilters []*Dimension `json:"dimensionFilters,omitempty"`
12156
12157
12158
12159 Dimensions []*Dimension `json:"dimensions,omitempty"`
12160
12161
12162
12163 Kind string `json:"kind,omitempty"`
12164
12165
12166
12167 Metrics []*Metric `json:"metrics,omitempty"`
12168
12169
12170
12171
12172 PivotedActivityMetrics []*Metric `json:"pivotedActivityMetrics,omitempty"`
12173
12174
12175
12176
12177
12178
12179
12180 ForceSendFields []string `json:"-"`
12181
12182
12183
12184
12185
12186
12187
12188
12189 NullFields []string `json:"-"`
12190 }
12191
12192 func (s *ReportCompatibleFields) MarshalJSON() ([]byte, error) {
12193 type NoMethod ReportCompatibleFields
12194 raw := NoMethod(*s)
12195 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12196 }
12197
12198
12199 type ReportList struct {
12200
12201 Etag string `json:"etag,omitempty"`
12202
12203
12204 Items []*Report `json:"items,omitempty"`
12205
12206
12207 Kind string `json:"kind,omitempty"`
12208
12209
12210
12211
12212
12213 NextPageToken string `json:"nextPageToken,omitempty"`
12214
12215
12216
12217 googleapi.ServerResponse `json:"-"`
12218
12219
12220
12221
12222
12223
12224
12225 ForceSendFields []string `json:"-"`
12226
12227
12228
12229
12230
12231
12232
12233 NullFields []string `json:"-"`
12234 }
12235
12236 func (s *ReportList) MarshalJSON() ([]byte, error) {
12237 type NoMethod ReportList
12238 raw := NoMethod(*s)
12239 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12240 }
12241
12242
12243 type ReportsConfiguration struct {
12244
12245
12246
12247
12248 ExposureToConversionEnabled bool `json:"exposureToConversionEnabled,omitempty"`
12249
12250
12251
12252 LookbackConfiguration *LookbackConfiguration `json:"lookbackConfiguration,omitempty"`
12253
12254
12255
12256
12257
12258
12259
12260
12261
12262
12263
12264
12265
12266
12267
12268
12269
12270
12271
12272 ReportGenerationTimeZoneId int64 `json:"reportGenerationTimeZoneId,omitempty,string"`
12273
12274
12275
12276
12277
12278
12279
12280
12281 ForceSendFields []string `json:"-"`
12282
12283
12284
12285
12286
12287
12288
12289
12290 NullFields []string `json:"-"`
12291 }
12292
12293 func (s *ReportsConfiguration) MarshalJSON() ([]byte, error) {
12294 type NoMethod ReportsConfiguration
12295 raw := NoMethod(*s)
12296 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12297 }
12298
12299
12300 type RichMediaExitOverride struct {
12301
12302
12303 ClickThroughUrl *ClickThroughUrl `json:"clickThroughUrl,omitempty"`
12304
12305
12306
12307 Enabled bool `json:"enabled,omitempty"`
12308
12309
12310
12311 ExitId int64 `json:"exitId,omitempty,string"`
12312
12313
12314
12315
12316
12317
12318
12319 ForceSendFields []string `json:"-"`
12320
12321
12322
12323
12324
12325
12326
12327
12328 NullFields []string `json:"-"`
12329 }
12330
12331 func (s *RichMediaExitOverride) MarshalJSON() ([]byte, error) {
12332 type NoMethod RichMediaExitOverride
12333 raw := NoMethod(*s)
12334 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12335 }
12336
12337
12338
12339 type Rule struct {
12340
12341
12342 AssetId int64 `json:"assetId,omitempty,string"`
12343
12344
12345 Name string `json:"name,omitempty"`
12346
12347
12348
12349
12350 TargetingTemplateId int64 `json:"targetingTemplateId,omitempty,string"`
12351
12352
12353
12354
12355
12356
12357
12358 ForceSendFields []string `json:"-"`
12359
12360
12361
12362
12363
12364
12365
12366 NullFields []string `json:"-"`
12367 }
12368
12369 func (s *Rule) MarshalJSON() ([]byte, error) {
12370 type NoMethod Rule
12371 raw := NoMethod(*s)
12372 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12373 }
12374
12375
12376 type Site struct {
12377
12378
12379 AccountId int64 `json:"accountId,omitempty,string"`
12380
12381
12382 Approved bool `json:"approved,omitempty"`
12383
12384
12385
12386 DirectorySiteId int64 `json:"directorySiteId,omitempty,string"`
12387
12388
12389
12390 DirectorySiteIdDimensionValue *DimensionValue `json:"directorySiteIdDimensionValue,omitempty"`
12391
12392
12393 Id int64 `json:"id,omitempty,string"`
12394
12395
12396
12397 IdDimensionValue *DimensionValue `json:"idDimensionValue,omitempty"`
12398
12399
12400
12401 KeyName string `json:"keyName,omitempty"`
12402
12403
12404
12405 Kind string `json:"kind,omitempty"`
12406
12407
12408
12409
12410
12411
12412 Name string `json:"name,omitempty"`
12413
12414
12415 SiteContacts []*SiteContact `json:"siteContacts,omitempty"`
12416
12417
12418 SiteSettings *SiteSettings `json:"siteSettings,omitempty"`
12419
12420
12421
12422 SubaccountId int64 `json:"subaccountId,omitempty,string"`
12423
12424
12425
12426 googleapi.ServerResponse `json:"-"`
12427
12428
12429
12430
12431
12432
12433
12434 ForceSendFields []string `json:"-"`
12435
12436
12437
12438
12439
12440
12441
12442 NullFields []string `json:"-"`
12443 }
12444
12445 func (s *Site) MarshalJSON() ([]byte, error) {
12446 type NoMethod Site
12447 raw := NoMethod(*s)
12448 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12449 }
12450
12451
12452 type SiteContact struct {
12453
12454 Address string `json:"address,omitempty"`
12455
12456
12457
12458
12459
12460
12461 ContactType string `json:"contactType,omitempty"`
12462
12463
12464 Email string `json:"email,omitempty"`
12465
12466
12467 FirstName string `json:"firstName,omitempty"`
12468
12469
12470
12471 Id int64 `json:"id,omitempty,string"`
12472
12473
12474 LastName string `json:"lastName,omitempty"`
12475
12476
12477 Phone string `json:"phone,omitempty"`
12478
12479
12480 Title string `json:"title,omitempty"`
12481
12482
12483
12484
12485
12486
12487
12488 ForceSendFields []string `json:"-"`
12489
12490
12491
12492
12493
12494
12495
12496 NullFields []string `json:"-"`
12497 }
12498
12499 func (s *SiteContact) MarshalJSON() ([]byte, error) {
12500 type NoMethod SiteContact
12501 raw := NoMethod(*s)
12502 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12503 }
12504
12505
12506 type SiteSettings struct {
12507
12508
12509 ActiveViewOptOut bool `json:"activeViewOptOut,omitempty"`
12510
12511
12512
12513
12514
12515 AdBlockingOptOut bool `json:"adBlockingOptOut,omitempty"`
12516
12517
12518 CreativeSettings *CreativeSettings `json:"creativeSettings,omitempty"`
12519
12520
12521 DisableNewCookie bool `json:"disableNewCookie,omitempty"`
12522
12523
12524 LookbackConfiguration *LookbackConfiguration `json:"lookbackConfiguration,omitempty"`
12525
12526
12527
12528 TagSetting *TagSetting `json:"tagSetting,omitempty"`
12529
12530
12531
12532
12533
12534
12535 VideoActiveViewOptOutTemplate bool `json:"videoActiveViewOptOutTemplate,omitempty"`
12536
12537
12538
12539
12540
12541
12542
12543
12544
12545
12546
12547
12548
12549
12550
12551
12552
12553
12554
12555 VpaidAdapterChoiceTemplate string `json:"vpaidAdapterChoiceTemplate,omitempty"`
12556
12557
12558
12559
12560
12561
12562
12563 ForceSendFields []string `json:"-"`
12564
12565
12566
12567
12568
12569
12570
12571
12572 NullFields []string `json:"-"`
12573 }
12574
12575 func (s *SiteSettings) MarshalJSON() ([]byte, error) {
12576 type NoMethod SiteSettings
12577 raw := NoMethod(*s)
12578 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12579 }
12580
12581
12582 type SitesListResponse struct {
12583
12584
12585 Kind string `json:"kind,omitempty"`
12586
12587
12588
12589 NextPageToken string `json:"nextPageToken,omitempty"`
12590
12591
12592 Sites []*Site `json:"sites,omitempty"`
12593
12594
12595
12596 googleapi.ServerResponse `json:"-"`
12597
12598
12599
12600
12601
12602
12603
12604 ForceSendFields []string `json:"-"`
12605
12606
12607
12608
12609
12610
12611
12612 NullFields []string `json:"-"`
12613 }
12614
12615 func (s *SitesListResponse) MarshalJSON() ([]byte, error) {
12616 type NoMethod SitesListResponse
12617 raw := NoMethod(*s)
12618 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12619 }
12620
12621
12622
12623 type Size struct {
12624
12625
12626 Height int64 `json:"height,omitempty"`
12627
12628
12629 Iab bool `json:"iab,omitempty"`
12630
12631
12632 Id int64 `json:"id,omitempty,string"`
12633
12634
12635
12636 Kind string `json:"kind,omitempty"`
12637
12638
12639
12640 Width int64 `json:"width,omitempty"`
12641
12642
12643
12644 googleapi.ServerResponse `json:"-"`
12645
12646
12647
12648
12649
12650
12651
12652 ForceSendFields []string `json:"-"`
12653
12654
12655
12656
12657
12658
12659
12660 NullFields []string `json:"-"`
12661 }
12662
12663 func (s *Size) MarshalJSON() ([]byte, error) {
12664 type NoMethod Size
12665 raw := NoMethod(*s)
12666 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12667 }
12668
12669
12670 type SizesListResponse struct {
12671
12672
12673 Kind string `json:"kind,omitempty"`
12674
12675
12676 Sizes []*Size `json:"sizes,omitempty"`
12677
12678
12679
12680 googleapi.ServerResponse `json:"-"`
12681
12682
12683
12684
12685
12686
12687
12688 ForceSendFields []string `json:"-"`
12689
12690
12691
12692
12693
12694
12695
12696 NullFields []string `json:"-"`
12697 }
12698
12699 func (s *SizesListResponse) MarshalJSON() ([]byte, error) {
12700 type NoMethod SizesListResponse
12701 raw := NoMethod(*s)
12702 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12703 }
12704
12705
12706 type SkippableSetting struct {
12707
12708
12709 Kind string `json:"kind,omitempty"`
12710
12711
12712
12713 ProgressOffset *VideoOffset `json:"progressOffset,omitempty"`
12714
12715
12716
12717
12718 SkipOffset *VideoOffset `json:"skipOffset,omitempty"`
12719
12720
12721
12722 Skippable bool `json:"skippable,omitempty"`
12723
12724
12725
12726
12727
12728
12729
12730 ForceSendFields []string `json:"-"`
12731
12732
12733
12734
12735
12736
12737
12738 NullFields []string `json:"-"`
12739 }
12740
12741 func (s *SkippableSetting) MarshalJSON() ([]byte, error) {
12742 type NoMethod SkippableSetting
12743 raw := NoMethod(*s)
12744 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12745 }
12746
12747
12748 type SortedDimension struct {
12749
12750
12751 Kind string `json:"kind,omitempty"`
12752
12753
12754 Name string `json:"name,omitempty"`
12755
12756
12757
12758
12759
12760
12761 SortOrder string `json:"sortOrder,omitempty"`
12762
12763
12764
12765
12766
12767
12768
12769 ForceSendFields []string `json:"-"`
12770
12771
12772
12773
12774
12775
12776
12777 NullFields []string `json:"-"`
12778 }
12779
12780 func (s *SortedDimension) MarshalJSON() ([]byte, error) {
12781 type NoMethod SortedDimension
12782 raw := NoMethod(*s)
12783 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12784 }
12785
12786
12787 type Subaccount struct {
12788
12789
12790 AccountId int64 `json:"accountId,omitempty,string"`
12791
12792
12793
12794 AvailablePermissionIds googleapi.Int64s `json:"availablePermissionIds,omitempty"`
12795
12796
12797 Id int64 `json:"id,omitempty,string"`
12798
12799
12800
12801 Kind string `json:"kind,omitempty"`
12802
12803
12804
12805
12806 Name string `json:"name,omitempty"`
12807
12808
12809
12810 googleapi.ServerResponse `json:"-"`
12811
12812
12813
12814
12815
12816
12817
12818 ForceSendFields []string `json:"-"`
12819
12820
12821
12822
12823
12824
12825
12826 NullFields []string `json:"-"`
12827 }
12828
12829 func (s *Subaccount) MarshalJSON() ([]byte, error) {
12830 type NoMethod Subaccount
12831 raw := NoMethod(*s)
12832 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12833 }
12834
12835
12836 type SubaccountsListResponse struct {
12837
12838
12839 Kind string `json:"kind,omitempty"`
12840
12841
12842
12843 NextPageToken string `json:"nextPageToken,omitempty"`
12844
12845
12846 Subaccounts []*Subaccount `json:"subaccounts,omitempty"`
12847
12848
12849
12850 googleapi.ServerResponse `json:"-"`
12851
12852
12853
12854
12855
12856
12857
12858 ForceSendFields []string `json:"-"`
12859
12860
12861
12862
12863
12864
12865
12866 NullFields []string `json:"-"`
12867 }
12868
12869 func (s *SubaccountsListResponse) MarshalJSON() ([]byte, error) {
12870 type NoMethod SubaccountsListResponse
12871 raw := NoMethod(*s)
12872 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12873 }
12874
12875
12876 type TagData struct {
12877
12878
12879 AdId int64 `json:"adId,omitempty,string"`
12880
12881
12882 ClickTag string `json:"clickTag,omitempty"`
12883
12884
12885
12886 CreativeId int64 `json:"creativeId,omitempty,string"`
12887
12888
12889
12890
12891
12892
12893
12894
12895
12896
12897
12898
12899
12900
12901
12902
12903
12904
12905
12906
12907
12908
12909
12910 Format string `json:"format,omitempty"`
12911
12912
12913 ImpressionTag string `json:"impressionTag,omitempty"`
12914
12915
12916
12917
12918
12919
12920
12921 ForceSendFields []string `json:"-"`
12922
12923
12924
12925
12926
12927
12928
12929 NullFields []string `json:"-"`
12930 }
12931
12932 func (s *TagData) MarshalJSON() ([]byte, error) {
12933 type NoMethod TagData
12934 raw := NoMethod(*s)
12935 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12936 }
12937
12938
12939 type TagSetting struct {
12940
12941
12942
12943
12944 AdditionalKeyValues string `json:"additionalKeyValues,omitempty"`
12945
12946
12947
12948 IncludeClickThroughUrls bool `json:"includeClickThroughUrls,omitempty"`
12949
12950
12951
12952 IncludeClickTracking bool `json:"includeClickTracking,omitempty"`
12953
12954
12955
12956
12957
12958
12959
12960
12961
12962
12963 KeywordOption string `json:"keywordOption,omitempty"`
12964
12965
12966
12967
12968
12969
12970
12971 ForceSendFields []string `json:"-"`
12972
12973
12974
12975
12976
12977
12978
12979
12980 NullFields []string `json:"-"`
12981 }
12982
12983 func (s *TagSetting) MarshalJSON() ([]byte, error) {
12984 type NoMethod TagSetting
12985 raw := NoMethod(*s)
12986 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12987 }
12988
12989
12990 type TagSettings struct {
12991
12992 DynamicTagEnabled bool `json:"dynamicTagEnabled,omitempty"`
12993
12994
12995 ImageTagEnabled bool `json:"imageTagEnabled,omitempty"`
12996
12997
12998
12999
13000
13001
13002
13003 ForceSendFields []string `json:"-"`
13004
13005
13006
13007
13008
13009
13010
13011
13012 NullFields []string `json:"-"`
13013 }
13014
13015 func (s *TagSettings) MarshalJSON() ([]byte, error) {
13016 type NoMethod TagSettings
13017 raw := NoMethod(*s)
13018 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13019 }
13020
13021
13022 type TargetWindow struct {
13023
13024 CustomHtml string `json:"customHtml,omitempty"`
13025
13026
13027
13028
13029
13030
13031
13032
13033 TargetWindowOption string `json:"targetWindowOption,omitempty"`
13034
13035
13036
13037
13038
13039
13040
13041 ForceSendFields []string `json:"-"`
13042
13043
13044
13045
13046
13047
13048
13049 NullFields []string `json:"-"`
13050 }
13051
13052 func (s *TargetWindow) MarshalJSON() ([]byte, error) {
13053 type NoMethod TargetWindow
13054 raw := NoMethod(*s)
13055 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13056 }
13057
13058
13059
13060
13061
13062
13063
13064
13065
13066
13067 type TargetableRemarketingList struct {
13068
13069
13070 AccountId int64 `json:"accountId,omitempty,string"`
13071
13072
13073 Active bool `json:"active,omitempty"`
13074
13075
13076
13077 AdvertiserId int64 `json:"advertiserId,omitempty,string"`
13078
13079
13080
13081 AdvertiserIdDimensionValue *DimensionValue `json:"advertiserIdDimensionValue,omitempty"`
13082
13083
13084 Description string `json:"description,omitempty"`
13085
13086
13087 Id int64 `json:"id,omitempty,string"`
13088
13089
13090
13091 Kind string `json:"kind,omitempty"`
13092
13093
13094
13095 LifeSpan int64 `json:"lifeSpan,omitempty,string"`
13096
13097
13098
13099 ListSize int64 `json:"listSize,omitempty,string"`
13100
13101
13102
13103
13104
13105
13106
13107
13108
13109
13110
13111
13112
13113
13114
13115
13116 ListSource string `json:"listSource,omitempty"`
13117
13118
13119
13120 Name string `json:"name,omitempty"`
13121
13122
13123
13124
13125 SubaccountId int64 `json:"subaccountId,omitempty,string"`
13126
13127
13128
13129 googleapi.ServerResponse `json:"-"`
13130
13131
13132
13133
13134
13135
13136
13137 ForceSendFields []string `json:"-"`
13138
13139
13140
13141
13142
13143
13144
13145 NullFields []string `json:"-"`
13146 }
13147
13148 func (s *TargetableRemarketingList) MarshalJSON() ([]byte, error) {
13149 type NoMethod TargetableRemarketingList
13150 raw := NoMethod(*s)
13151 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13152 }
13153
13154
13155
13156 type TargetableRemarketingListsListResponse struct {
13157
13158
13159 Kind string `json:"kind,omitempty"`
13160
13161
13162
13163 NextPageToken string `json:"nextPageToken,omitempty"`
13164
13165
13166 TargetableRemarketingLists []*TargetableRemarketingList `json:"targetableRemarketingLists,omitempty"`
13167
13168
13169
13170 googleapi.ServerResponse `json:"-"`
13171
13172
13173
13174
13175
13176
13177
13178 ForceSendFields []string `json:"-"`
13179
13180
13181
13182
13183
13184
13185
13186 NullFields []string `json:"-"`
13187 }
13188
13189 func (s *TargetableRemarketingListsListResponse) MarshalJSON() ([]byte, error) {
13190 type NoMethod TargetableRemarketingListsListResponse
13191 raw := NoMethod(*s)
13192 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13193 }
13194
13195
13196
13197
13198 type TargetingTemplate struct {
13199
13200
13201
13202 AccountId int64 `json:"accountId,omitempty,string"`
13203
13204
13205
13206 AdvertiserId int64 `json:"advertiserId,omitempty,string"`
13207
13208
13209
13210 AdvertiserIdDimensionValue *DimensionValue `json:"advertiserIdDimensionValue,omitempty"`
13211
13212
13213 DayPartTargeting *DayPartTargeting `json:"dayPartTargeting,omitempty"`
13214
13215
13216 GeoTargeting *GeoTargeting `json:"geoTargeting,omitempty"`
13217
13218
13219
13220 Id int64 `json:"id,omitempty,string"`
13221
13222
13223 KeyValueTargetingExpression *KeyValueTargetingExpression `json:"keyValueTargetingExpression,omitempty"`
13224
13225
13226
13227 Kind string `json:"kind,omitempty"`
13228
13229
13230 LanguageTargeting *LanguageTargeting `json:"languageTargeting,omitempty"`
13231
13232
13233 ListTargetingExpression *ListTargetingExpression `json:"listTargetingExpression,omitempty"`
13234
13235
13236
13237
13238 Name string `json:"name,omitempty"`
13239
13240
13241
13242
13243 SubaccountId int64 `json:"subaccountId,omitempty,string"`
13244
13245
13246 TechnologyTargeting *TechnologyTargeting `json:"technologyTargeting,omitempty"`
13247
13248
13249
13250 googleapi.ServerResponse `json:"-"`
13251
13252
13253
13254
13255
13256
13257
13258 ForceSendFields []string `json:"-"`
13259
13260
13261
13262
13263
13264
13265
13266 NullFields []string `json:"-"`
13267 }
13268
13269 func (s *TargetingTemplate) MarshalJSON() ([]byte, error) {
13270 type NoMethod TargetingTemplate
13271 raw := NoMethod(*s)
13272 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13273 }
13274
13275
13276 type TargetingTemplatesListResponse struct {
13277
13278
13279 Kind string `json:"kind,omitempty"`
13280
13281
13282
13283 NextPageToken string `json:"nextPageToken,omitempty"`
13284
13285
13286 TargetingTemplates []*TargetingTemplate `json:"targetingTemplates,omitempty"`
13287
13288
13289
13290 googleapi.ServerResponse `json:"-"`
13291
13292
13293
13294
13295
13296
13297
13298 ForceSendFields []string `json:"-"`
13299
13300
13301
13302
13303
13304
13305
13306 NullFields []string `json:"-"`
13307 }
13308
13309 func (s *TargetingTemplatesListResponse) MarshalJSON() ([]byte, error) {
13310 type NoMethod TargetingTemplatesListResponse
13311 raw := NoMethod(*s)
13312 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13313 }
13314
13315
13316 type TechnologyTargeting struct {
13317
13318
13319
13320
13321 Browsers []*Browser `json:"browsers,omitempty"`
13322
13323
13324
13325
13326 ConnectionTypes []*ConnectionType `json:"connectionTypes,omitempty"`
13327
13328
13329
13330
13331
13332 MobileCarriers []*MobileCarrier `json:"mobileCarriers,omitempty"`
13333
13334
13335
13336
13337
13338
13339
13340 OperatingSystemVersions []*OperatingSystemVersion `json:"operatingSystemVersions,omitempty"`
13341
13342
13343
13344
13345
13346
13347
13348 OperatingSystems []*OperatingSystem `json:"operatingSystems,omitempty"`
13349
13350
13351
13352
13353
13354 PlatformTypes []*PlatformType `json:"platformTypes,omitempty"`
13355
13356
13357
13358
13359
13360
13361
13362 ForceSendFields []string `json:"-"`
13363
13364
13365
13366
13367
13368
13369
13370 NullFields []string `json:"-"`
13371 }
13372
13373 func (s *TechnologyTargeting) MarshalJSON() ([]byte, error) {
13374 type NoMethod TechnologyTargeting
13375 raw := NoMethod(*s)
13376 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13377 }
13378
13379
13380 type ThirdPartyAuthenticationToken struct {
13381
13382 Name string `json:"name,omitempty"`
13383
13384
13385
13386 Value string `json:"value,omitempty"`
13387
13388
13389
13390
13391
13392
13393
13394 ForceSendFields []string `json:"-"`
13395
13396
13397
13398
13399
13400
13401
13402 NullFields []string `json:"-"`
13403 }
13404
13405 func (s *ThirdPartyAuthenticationToken) MarshalJSON() ([]byte, error) {
13406 type NoMethod ThirdPartyAuthenticationToken
13407 raw := NoMethod(*s)
13408 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13409 }
13410
13411
13412 type ThirdPartyTrackingUrl struct {
13413
13414
13415
13416
13417
13418
13419
13420
13421
13422
13423
13424
13425
13426
13427
13428
13429
13430
13431
13432
13433
13434
13435
13436 ThirdPartyUrlType string `json:"thirdPartyUrlType,omitempty"`
13437
13438
13439 Url string `json:"url,omitempty"`
13440
13441
13442
13443
13444
13445
13446
13447 ForceSendFields []string `json:"-"`
13448
13449
13450
13451
13452
13453
13454
13455
13456 NullFields []string `json:"-"`
13457 }
13458
13459 func (s *ThirdPartyTrackingUrl) MarshalJSON() ([]byte, error) {
13460 type NoMethod ThirdPartyTrackingUrl
13461 raw := NoMethod(*s)
13462 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13463 }
13464
13465
13466 type TranscodeSetting struct {
13467
13468
13469 EnabledVideoFormats []int64 `json:"enabledVideoFormats,omitempty"`
13470
13471
13472
13473 Kind string `json:"kind,omitempty"`
13474
13475
13476
13477
13478
13479
13480
13481 ForceSendFields []string `json:"-"`
13482
13483
13484
13485
13486
13487
13488
13489
13490 NullFields []string `json:"-"`
13491 }
13492
13493 func (s *TranscodeSetting) MarshalJSON() ([]byte, error) {
13494 type NoMethod TranscodeSetting
13495 raw := NoMethod(*s)
13496 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13497 }
13498
13499
13500
13501
13502 type UniversalAdId struct {
13503
13504
13505
13506
13507
13508
13509
13510 Registry string `json:"registry,omitempty"`
13511
13512
13513
13514
13515 Value string `json:"value,omitempty"`
13516
13517
13518
13519
13520
13521
13522
13523 ForceSendFields []string `json:"-"`
13524
13525
13526
13527
13528
13529
13530
13531 NullFields []string `json:"-"`
13532 }
13533
13534 func (s *UniversalAdId) MarshalJSON() ([]byte, error) {
13535 type NoMethod UniversalAdId
13536 raw := NoMethod(*s)
13537 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13538 }
13539
13540
13541
13542 type UserDefinedVariableConfiguration struct {
13543
13544
13545
13546
13547
13548 DataType string `json:"dataType,omitempty"`
13549
13550
13551
13552
13553 ReportName string `json:"reportName,omitempty"`
13554
13555
13556
13557
13558
13559
13560
13561
13562
13563
13564
13565
13566
13567
13568
13569
13570
13571
13572
13573
13574
13575
13576
13577
13578
13579
13580
13581
13582
13583
13584
13585
13586
13587
13588
13589
13590
13591
13592
13593
13594
13595
13596
13597
13598
13599
13600
13601
13602
13603
13604
13605
13606
13607
13608
13609
13610
13611
13612
13613
13614
13615
13616
13617
13618
13619
13620
13621
13622
13623
13624
13625
13626
13627
13628
13629
13630
13631
13632
13633
13634
13635
13636
13637
13638
13639
13640
13641
13642
13643
13644
13645
13646
13647
13648
13649
13650
13651
13652
13653
13654
13655
13656
13657
13658 VariableType string `json:"variableType,omitempty"`
13659
13660
13661
13662
13663
13664
13665
13666 ForceSendFields []string `json:"-"`
13667
13668
13669
13670
13671
13672
13673
13674 NullFields []string `json:"-"`
13675 }
13676
13677 func (s *UserDefinedVariableConfiguration) MarshalJSON() ([]byte, error) {
13678 type NoMethod UserDefinedVariableConfiguration
13679 raw := NoMethod(*s)
13680 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13681 }
13682
13683
13684 type UserProfile struct {
13685
13686 AccountId int64 `json:"accountId,omitempty,string"`
13687
13688
13689 AccountName string `json:"accountName,omitempty"`
13690
13691
13692 Etag string `json:"etag,omitempty"`
13693
13694
13695
13696 Kind string `json:"kind,omitempty"`
13697
13698
13699 ProfileId int64 `json:"profileId,omitempty,string"`
13700
13701
13702
13703 SubAccountId int64 `json:"subAccountId,omitempty,string"`
13704
13705
13706
13707 SubAccountName string `json:"subAccountName,omitempty"`
13708
13709
13710 UserName string `json:"userName,omitempty"`
13711
13712
13713
13714 googleapi.ServerResponse `json:"-"`
13715
13716
13717
13718
13719
13720
13721
13722 ForceSendFields []string `json:"-"`
13723
13724
13725
13726
13727
13728
13729
13730 NullFields []string `json:"-"`
13731 }
13732
13733 func (s *UserProfile) MarshalJSON() ([]byte, error) {
13734 type NoMethod UserProfile
13735 raw := NoMethod(*s)
13736 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13737 }
13738
13739
13740 type UserProfileList struct {
13741
13742 Etag string `json:"etag,omitempty"`
13743
13744
13745 Items []*UserProfile `json:"items,omitempty"`
13746
13747
13748
13749 Kind string `json:"kind,omitempty"`
13750
13751
13752
13753 googleapi.ServerResponse `json:"-"`
13754
13755
13756
13757
13758
13759
13760
13761 ForceSendFields []string `json:"-"`
13762
13763
13764
13765
13766
13767
13768
13769 NullFields []string `json:"-"`
13770 }
13771
13772 func (s *UserProfileList) MarshalJSON() ([]byte, error) {
13773 type NoMethod UserProfileList
13774 raw := NoMethod(*s)
13775 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13776 }
13777
13778
13779
13780 type UserRole struct {
13781
13782
13783 AccountId int64 `json:"accountId,omitempty,string"`
13784
13785
13786
13787
13788
13789 DefaultUserRole bool `json:"defaultUserRole,omitempty"`
13790
13791
13792 Id int64 `json:"id,omitempty,string"`
13793
13794
13795
13796 Kind string `json:"kind,omitempty"`
13797
13798
13799
13800
13801
13802
13803 Name string `json:"name,omitempty"`
13804
13805
13806
13807 ParentUserRoleId int64 `json:"parentUserRoleId,omitempty,string"`
13808
13809
13810 Permissions []*UserRolePermission `json:"permissions,omitempty"`
13811
13812
13813
13814 SubaccountId int64 `json:"subaccountId,omitempty,string"`
13815
13816
13817
13818 googleapi.ServerResponse `json:"-"`
13819
13820
13821
13822
13823
13824
13825
13826 ForceSendFields []string `json:"-"`
13827
13828
13829
13830
13831
13832
13833
13834 NullFields []string `json:"-"`
13835 }
13836
13837 func (s *UserRole) MarshalJSON() ([]byte, error) {
13838 type NoMethod UserRole
13839 raw := NoMethod(*s)
13840 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13841 }
13842
13843
13844 type UserRolePermission struct {
13845
13846
13847
13848
13849
13850
13851
13852
13853 Availability string `json:"availability,omitempty"`
13854
13855
13856 Id int64 `json:"id,omitempty,string"`
13857
13858
13859
13860 Kind string `json:"kind,omitempty"`
13861
13862
13863 Name string `json:"name,omitempty"`
13864
13865
13866
13867 PermissionGroupId int64 `json:"permissionGroupId,omitempty,string"`
13868
13869
13870
13871 googleapi.ServerResponse `json:"-"`
13872
13873
13874
13875
13876
13877
13878
13879 ForceSendFields []string `json:"-"`
13880
13881
13882
13883
13884
13885
13886
13887 NullFields []string `json:"-"`
13888 }
13889
13890 func (s *UserRolePermission) MarshalJSON() ([]byte, error) {
13891 type NoMethod UserRolePermission
13892 raw := NoMethod(*s)
13893 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13894 }
13895
13896
13897
13898 type UserRolePermissionGroup struct {
13899
13900 Id int64 `json:"id,omitempty,string"`
13901
13902
13903
13904 Kind string `json:"kind,omitempty"`
13905
13906
13907 Name string `json:"name,omitempty"`
13908
13909
13910
13911 googleapi.ServerResponse `json:"-"`
13912
13913
13914
13915
13916
13917
13918
13919 ForceSendFields []string `json:"-"`
13920
13921
13922
13923
13924
13925
13926
13927 NullFields []string `json:"-"`
13928 }
13929
13930 func (s *UserRolePermissionGroup) MarshalJSON() ([]byte, error) {
13931 type NoMethod UserRolePermissionGroup
13932 raw := NoMethod(*s)
13933 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13934 }
13935
13936
13937
13938 type UserRolePermissionGroupsListResponse struct {
13939
13940
13941 Kind string `json:"kind,omitempty"`
13942
13943
13944 UserRolePermissionGroups []*UserRolePermissionGroup `json:"userRolePermissionGroups,omitempty"`
13945
13946
13947
13948 googleapi.ServerResponse `json:"-"`
13949
13950
13951
13952
13953
13954
13955
13956 ForceSendFields []string `json:"-"`
13957
13958
13959
13960
13961
13962
13963
13964 NullFields []string `json:"-"`
13965 }
13966
13967 func (s *UserRolePermissionGroupsListResponse) MarshalJSON() ([]byte, error) {
13968 type NoMethod UserRolePermissionGroupsListResponse
13969 raw := NoMethod(*s)
13970 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13971 }
13972
13973
13974 type UserRolePermissionsListResponse struct {
13975
13976
13977 Kind string `json:"kind,omitempty"`
13978
13979
13980 UserRolePermissions []*UserRolePermission `json:"userRolePermissions,omitempty"`
13981
13982
13983
13984 googleapi.ServerResponse `json:"-"`
13985
13986
13987
13988
13989
13990
13991
13992 ForceSendFields []string `json:"-"`
13993
13994
13995
13996
13997
13998
13999
14000 NullFields []string `json:"-"`
14001 }
14002
14003 func (s *UserRolePermissionsListResponse) MarshalJSON() ([]byte, error) {
14004 type NoMethod UserRolePermissionsListResponse
14005 raw := NoMethod(*s)
14006 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14007 }
14008
14009
14010 type UserRolesListResponse struct {
14011
14012
14013 Kind string `json:"kind,omitempty"`
14014
14015
14016
14017 NextPageToken string `json:"nextPageToken,omitempty"`
14018
14019
14020 UserRoles []*UserRole `json:"userRoles,omitempty"`
14021
14022
14023
14024 googleapi.ServerResponse `json:"-"`
14025
14026
14027
14028
14029
14030
14031
14032 ForceSendFields []string `json:"-"`
14033
14034
14035
14036
14037
14038
14039
14040 NullFields []string `json:"-"`
14041 }
14042
14043 func (s *UserRolesListResponse) MarshalJSON() ([]byte, error) {
14044 type NoMethod UserRolesListResponse
14045 raw := NoMethod(*s)
14046 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14047 }
14048
14049
14050 type VideoFormat struct {
14051
14052
14053
14054
14055
14056
14057
14058
14059 FileType string `json:"fileType,omitempty"`
14060
14061
14062 Id int64 `json:"id,omitempty"`
14063
14064
14065
14066 Kind string `json:"kind,omitempty"`
14067
14068
14069 Resolution *Size `json:"resolution,omitempty"`
14070
14071
14072 TargetBitRate int64 `json:"targetBitRate,omitempty"`
14073
14074
14075
14076 googleapi.ServerResponse `json:"-"`
14077
14078
14079
14080
14081
14082
14083
14084 ForceSendFields []string `json:"-"`
14085
14086
14087
14088
14089
14090
14091
14092 NullFields []string `json:"-"`
14093 }
14094
14095 func (s *VideoFormat) MarshalJSON() ([]byte, error) {
14096 type NoMethod VideoFormat
14097 raw := NoMethod(*s)
14098 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14099 }
14100
14101
14102 type VideoFormatsListResponse struct {
14103
14104
14105 Kind string `json:"kind,omitempty"`
14106
14107
14108 VideoFormats []*VideoFormat `json:"videoFormats,omitempty"`
14109
14110
14111
14112 googleapi.ServerResponse `json:"-"`
14113
14114
14115
14116
14117
14118
14119
14120 ForceSendFields []string `json:"-"`
14121
14122
14123
14124
14125
14126
14127
14128 NullFields []string `json:"-"`
14129 }
14130
14131 func (s *VideoFormatsListResponse) MarshalJSON() ([]byte, error) {
14132 type NoMethod VideoFormatsListResponse
14133 raw := NoMethod(*s)
14134 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14135 }
14136
14137
14138 type VideoOffset struct {
14139
14140
14141
14142 OffsetPercentage int64 `json:"offsetPercentage,omitempty"`
14143
14144
14145
14146 OffsetSeconds int64 `json:"offsetSeconds,omitempty"`
14147
14148
14149
14150
14151
14152
14153
14154 ForceSendFields []string `json:"-"`
14155
14156
14157
14158
14159
14160
14161
14162
14163 NullFields []string `json:"-"`
14164 }
14165
14166 func (s *VideoOffset) MarshalJSON() ([]byte, error) {
14167 type NoMethod VideoOffset
14168 raw := NoMethod(*s)
14169 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14170 }
14171
14172
14173 type VideoSettings struct {
14174
14175
14176 CompanionSettings *CompanionSetting `json:"companionSettings,omitempty"`
14177
14178
14179
14180 Kind string `json:"kind,omitempty"`
14181
14182
14183
14184
14185
14186
14187
14188
14189 Orientation string `json:"orientation,omitempty"`
14190
14191
14192
14193
14194 SkippableSettings *SkippableSetting `json:"skippableSettings,omitempty"`
14195
14196
14197
14198
14199 TranscodeSettings *TranscodeSetting `json:"transcodeSettings,omitempty"`
14200
14201
14202
14203
14204
14205
14206
14207 ForceSendFields []string `json:"-"`
14208
14209
14210
14211
14212
14213
14214
14215
14216 NullFields []string `json:"-"`
14217 }
14218
14219 func (s *VideoSettings) MarshalJSON() ([]byte, error) {
14220 type NoMethod VideoSettings
14221 raw := NoMethod(*s)
14222 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14223 }
14224
14225
14226
14227 type AccountActiveAdSummariesGetCall struct {
14228 s *Service
14229 profileId int64
14230 summaryAccountId int64
14231 urlParams_ gensupport.URLParams
14232 ifNoneMatch_ string
14233 ctx_ context.Context
14234 header_ http.Header
14235 }
14236
14237
14238 func (r *AccountActiveAdSummariesService) Get(profileId int64, summaryAccountId int64) *AccountActiveAdSummariesGetCall {
14239 c := &AccountActiveAdSummariesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
14240 c.profileId = profileId
14241 c.summaryAccountId = summaryAccountId
14242 return c
14243 }
14244
14245
14246
14247
14248 func (c *AccountActiveAdSummariesGetCall) Fields(s ...googleapi.Field) *AccountActiveAdSummariesGetCall {
14249 c.urlParams_.Set("fields", googleapi.CombineFields(s))
14250 return c
14251 }
14252
14253
14254
14255
14256
14257
14258 func (c *AccountActiveAdSummariesGetCall) IfNoneMatch(entityTag string) *AccountActiveAdSummariesGetCall {
14259 c.ifNoneMatch_ = entityTag
14260 return c
14261 }
14262
14263
14264
14265
14266 func (c *AccountActiveAdSummariesGetCall) Context(ctx context.Context) *AccountActiveAdSummariesGetCall {
14267 c.ctx_ = ctx
14268 return c
14269 }
14270
14271
14272
14273 func (c *AccountActiveAdSummariesGetCall) Header() http.Header {
14274 if c.header_ == nil {
14275 c.header_ = make(http.Header)
14276 }
14277 return c.header_
14278 }
14279
14280 func (c *AccountActiveAdSummariesGetCall) doRequest(alt string) (*http.Response, error) {
14281 reqHeaders := make(http.Header)
14282 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
14283 for k, v := range c.header_ {
14284 reqHeaders[k] = v
14285 }
14286 reqHeaders.Set("User-Agent", c.s.userAgent())
14287 if c.ifNoneMatch_ != "" {
14288 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
14289 }
14290 var body io.Reader = nil
14291 c.urlParams_.Set("alt", alt)
14292 c.urlParams_.Set("prettyPrint", "false")
14293 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/accountActiveAdSummaries/{summaryAccountId}")
14294 urls += "?" + c.urlParams_.Encode()
14295 req, err := http.NewRequest("GET", urls, body)
14296 if err != nil {
14297 return nil, err
14298 }
14299 req.Header = reqHeaders
14300 googleapi.Expand(req.URL, map[string]string{
14301 "profileId": strconv.FormatInt(c.profileId, 10),
14302 "summaryAccountId": strconv.FormatInt(c.summaryAccountId, 10),
14303 })
14304 return gensupport.SendRequest(c.ctx_, c.s.client, req)
14305 }
14306
14307
14308
14309
14310
14311
14312
14313
14314 func (c *AccountActiveAdSummariesGetCall) Do(opts ...googleapi.CallOption) (*AccountActiveAdSummary, error) {
14315 gensupport.SetOptions(c.urlParams_, opts...)
14316 res, err := c.doRequest("json")
14317 if res != nil && res.StatusCode == http.StatusNotModified {
14318 if res.Body != nil {
14319 res.Body.Close()
14320 }
14321 return nil, &googleapi.Error{
14322 Code: res.StatusCode,
14323 Header: res.Header,
14324 }
14325 }
14326 if err != nil {
14327 return nil, err
14328 }
14329 defer googleapi.CloseBody(res)
14330 if err := googleapi.CheckResponse(res); err != nil {
14331 return nil, err
14332 }
14333 ret := &AccountActiveAdSummary{
14334 ServerResponse: googleapi.ServerResponse{
14335 Header: res.Header,
14336 HTTPStatusCode: res.StatusCode,
14337 },
14338 }
14339 target := &ret
14340 if err := gensupport.DecodeResponse(target, res); err != nil {
14341 return nil, err
14342 }
14343 return ret, nil
14344
14345
14346
14347
14348
14349
14350
14351
14352
14353
14354
14355
14356
14357
14358
14359
14360
14361
14362
14363
14364
14365
14366
14367
14368
14369
14370
14371
14372
14373
14374
14375
14376
14377 }
14378
14379
14380
14381 type AccountPermissionGroupsGetCall struct {
14382 s *Service
14383 profileId int64
14384 id int64
14385 urlParams_ gensupport.URLParams
14386 ifNoneMatch_ string
14387 ctx_ context.Context
14388 header_ http.Header
14389 }
14390
14391
14392 func (r *AccountPermissionGroupsService) Get(profileId int64, id int64) *AccountPermissionGroupsGetCall {
14393 c := &AccountPermissionGroupsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
14394 c.profileId = profileId
14395 c.id = id
14396 return c
14397 }
14398
14399
14400
14401
14402 func (c *AccountPermissionGroupsGetCall) Fields(s ...googleapi.Field) *AccountPermissionGroupsGetCall {
14403 c.urlParams_.Set("fields", googleapi.CombineFields(s))
14404 return c
14405 }
14406
14407
14408
14409
14410
14411
14412 func (c *AccountPermissionGroupsGetCall) IfNoneMatch(entityTag string) *AccountPermissionGroupsGetCall {
14413 c.ifNoneMatch_ = entityTag
14414 return c
14415 }
14416
14417
14418
14419
14420 func (c *AccountPermissionGroupsGetCall) Context(ctx context.Context) *AccountPermissionGroupsGetCall {
14421 c.ctx_ = ctx
14422 return c
14423 }
14424
14425
14426
14427 func (c *AccountPermissionGroupsGetCall) Header() http.Header {
14428 if c.header_ == nil {
14429 c.header_ = make(http.Header)
14430 }
14431 return c.header_
14432 }
14433
14434 func (c *AccountPermissionGroupsGetCall) doRequest(alt string) (*http.Response, error) {
14435 reqHeaders := make(http.Header)
14436 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
14437 for k, v := range c.header_ {
14438 reqHeaders[k] = v
14439 }
14440 reqHeaders.Set("User-Agent", c.s.userAgent())
14441 if c.ifNoneMatch_ != "" {
14442 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
14443 }
14444 var body io.Reader = nil
14445 c.urlParams_.Set("alt", alt)
14446 c.urlParams_.Set("prettyPrint", "false")
14447 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/accountPermissionGroups/{id}")
14448 urls += "?" + c.urlParams_.Encode()
14449 req, err := http.NewRequest("GET", urls, body)
14450 if err != nil {
14451 return nil, err
14452 }
14453 req.Header = reqHeaders
14454 googleapi.Expand(req.URL, map[string]string{
14455 "profileId": strconv.FormatInt(c.profileId, 10),
14456 "id": strconv.FormatInt(c.id, 10),
14457 })
14458 return gensupport.SendRequest(c.ctx_, c.s.client, req)
14459 }
14460
14461
14462
14463
14464
14465
14466
14467
14468 func (c *AccountPermissionGroupsGetCall) Do(opts ...googleapi.CallOption) (*AccountPermissionGroup, error) {
14469 gensupport.SetOptions(c.urlParams_, opts...)
14470 res, err := c.doRequest("json")
14471 if res != nil && res.StatusCode == http.StatusNotModified {
14472 if res.Body != nil {
14473 res.Body.Close()
14474 }
14475 return nil, &googleapi.Error{
14476 Code: res.StatusCode,
14477 Header: res.Header,
14478 }
14479 }
14480 if err != nil {
14481 return nil, err
14482 }
14483 defer googleapi.CloseBody(res)
14484 if err := googleapi.CheckResponse(res); err != nil {
14485 return nil, err
14486 }
14487 ret := &AccountPermissionGroup{
14488 ServerResponse: googleapi.ServerResponse{
14489 Header: res.Header,
14490 HTTPStatusCode: res.StatusCode,
14491 },
14492 }
14493 target := &ret
14494 if err := gensupport.DecodeResponse(target, res); err != nil {
14495 return nil, err
14496 }
14497 return ret, nil
14498
14499
14500
14501
14502
14503
14504
14505
14506
14507
14508
14509
14510
14511
14512
14513
14514
14515
14516
14517
14518
14519
14520
14521
14522
14523
14524
14525
14526
14527
14528
14529
14530
14531 }
14532
14533
14534
14535 type AccountPermissionGroupsListCall struct {
14536 s *Service
14537 profileId int64
14538 urlParams_ gensupport.URLParams
14539 ifNoneMatch_ string
14540 ctx_ context.Context
14541 header_ http.Header
14542 }
14543
14544
14545 func (r *AccountPermissionGroupsService) List(profileId int64) *AccountPermissionGroupsListCall {
14546 c := &AccountPermissionGroupsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
14547 c.profileId = profileId
14548 return c
14549 }
14550
14551
14552
14553
14554 func (c *AccountPermissionGroupsListCall) Fields(s ...googleapi.Field) *AccountPermissionGroupsListCall {
14555 c.urlParams_.Set("fields", googleapi.CombineFields(s))
14556 return c
14557 }
14558
14559
14560
14561
14562
14563
14564 func (c *AccountPermissionGroupsListCall) IfNoneMatch(entityTag string) *AccountPermissionGroupsListCall {
14565 c.ifNoneMatch_ = entityTag
14566 return c
14567 }
14568
14569
14570
14571
14572 func (c *AccountPermissionGroupsListCall) Context(ctx context.Context) *AccountPermissionGroupsListCall {
14573 c.ctx_ = ctx
14574 return c
14575 }
14576
14577
14578
14579 func (c *AccountPermissionGroupsListCall) Header() http.Header {
14580 if c.header_ == nil {
14581 c.header_ = make(http.Header)
14582 }
14583 return c.header_
14584 }
14585
14586 func (c *AccountPermissionGroupsListCall) doRequest(alt string) (*http.Response, error) {
14587 reqHeaders := make(http.Header)
14588 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
14589 for k, v := range c.header_ {
14590 reqHeaders[k] = v
14591 }
14592 reqHeaders.Set("User-Agent", c.s.userAgent())
14593 if c.ifNoneMatch_ != "" {
14594 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
14595 }
14596 var body io.Reader = nil
14597 c.urlParams_.Set("alt", alt)
14598 c.urlParams_.Set("prettyPrint", "false")
14599 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/accountPermissionGroups")
14600 urls += "?" + c.urlParams_.Encode()
14601 req, err := http.NewRequest("GET", urls, body)
14602 if err != nil {
14603 return nil, err
14604 }
14605 req.Header = reqHeaders
14606 googleapi.Expand(req.URL, map[string]string{
14607 "profileId": strconv.FormatInt(c.profileId, 10),
14608 })
14609 return gensupport.SendRequest(c.ctx_, c.s.client, req)
14610 }
14611
14612
14613
14614
14615
14616
14617
14618
14619
14620 func (c *AccountPermissionGroupsListCall) Do(opts ...googleapi.CallOption) (*AccountPermissionGroupsListResponse, error) {
14621 gensupport.SetOptions(c.urlParams_, opts...)
14622 res, err := c.doRequest("json")
14623 if res != nil && res.StatusCode == http.StatusNotModified {
14624 if res.Body != nil {
14625 res.Body.Close()
14626 }
14627 return nil, &googleapi.Error{
14628 Code: res.StatusCode,
14629 Header: res.Header,
14630 }
14631 }
14632 if err != nil {
14633 return nil, err
14634 }
14635 defer googleapi.CloseBody(res)
14636 if err := googleapi.CheckResponse(res); err != nil {
14637 return nil, err
14638 }
14639 ret := &AccountPermissionGroupsListResponse{
14640 ServerResponse: googleapi.ServerResponse{
14641 Header: res.Header,
14642 HTTPStatusCode: res.StatusCode,
14643 },
14644 }
14645 target := &ret
14646 if err := gensupport.DecodeResponse(target, res); err != nil {
14647 return nil, err
14648 }
14649 return ret, nil
14650
14651
14652
14653
14654
14655
14656
14657
14658
14659
14660
14661
14662
14663
14664
14665
14666
14667
14668
14669
14670
14671
14672
14673
14674
14675 }
14676
14677
14678
14679 type AccountPermissionsGetCall struct {
14680 s *Service
14681 profileId int64
14682 id int64
14683 urlParams_ gensupport.URLParams
14684 ifNoneMatch_ string
14685 ctx_ context.Context
14686 header_ http.Header
14687 }
14688
14689
14690 func (r *AccountPermissionsService) Get(profileId int64, id int64) *AccountPermissionsGetCall {
14691 c := &AccountPermissionsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
14692 c.profileId = profileId
14693 c.id = id
14694 return c
14695 }
14696
14697
14698
14699
14700 func (c *AccountPermissionsGetCall) Fields(s ...googleapi.Field) *AccountPermissionsGetCall {
14701 c.urlParams_.Set("fields", googleapi.CombineFields(s))
14702 return c
14703 }
14704
14705
14706
14707
14708
14709
14710 func (c *AccountPermissionsGetCall) IfNoneMatch(entityTag string) *AccountPermissionsGetCall {
14711 c.ifNoneMatch_ = entityTag
14712 return c
14713 }
14714
14715
14716
14717
14718 func (c *AccountPermissionsGetCall) Context(ctx context.Context) *AccountPermissionsGetCall {
14719 c.ctx_ = ctx
14720 return c
14721 }
14722
14723
14724
14725 func (c *AccountPermissionsGetCall) Header() http.Header {
14726 if c.header_ == nil {
14727 c.header_ = make(http.Header)
14728 }
14729 return c.header_
14730 }
14731
14732 func (c *AccountPermissionsGetCall) doRequest(alt string) (*http.Response, error) {
14733 reqHeaders := make(http.Header)
14734 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
14735 for k, v := range c.header_ {
14736 reqHeaders[k] = v
14737 }
14738 reqHeaders.Set("User-Agent", c.s.userAgent())
14739 if c.ifNoneMatch_ != "" {
14740 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
14741 }
14742 var body io.Reader = nil
14743 c.urlParams_.Set("alt", alt)
14744 c.urlParams_.Set("prettyPrint", "false")
14745 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/accountPermissions/{id}")
14746 urls += "?" + c.urlParams_.Encode()
14747 req, err := http.NewRequest("GET", urls, body)
14748 if err != nil {
14749 return nil, err
14750 }
14751 req.Header = reqHeaders
14752 googleapi.Expand(req.URL, map[string]string{
14753 "profileId": strconv.FormatInt(c.profileId, 10),
14754 "id": strconv.FormatInt(c.id, 10),
14755 })
14756 return gensupport.SendRequest(c.ctx_, c.s.client, req)
14757 }
14758
14759
14760
14761
14762
14763
14764
14765
14766 func (c *AccountPermissionsGetCall) Do(opts ...googleapi.CallOption) (*AccountPermission, error) {
14767 gensupport.SetOptions(c.urlParams_, opts...)
14768 res, err := c.doRequest("json")
14769 if res != nil && res.StatusCode == http.StatusNotModified {
14770 if res.Body != nil {
14771 res.Body.Close()
14772 }
14773 return nil, &googleapi.Error{
14774 Code: res.StatusCode,
14775 Header: res.Header,
14776 }
14777 }
14778 if err != nil {
14779 return nil, err
14780 }
14781 defer googleapi.CloseBody(res)
14782 if err := googleapi.CheckResponse(res); err != nil {
14783 return nil, err
14784 }
14785 ret := &AccountPermission{
14786 ServerResponse: googleapi.ServerResponse{
14787 Header: res.Header,
14788 HTTPStatusCode: res.StatusCode,
14789 },
14790 }
14791 target := &ret
14792 if err := gensupport.DecodeResponse(target, res); err != nil {
14793 return nil, err
14794 }
14795 return ret, nil
14796
14797
14798
14799
14800
14801
14802
14803
14804
14805
14806
14807
14808
14809
14810
14811
14812
14813
14814
14815
14816
14817
14818
14819
14820
14821
14822
14823
14824
14825
14826
14827
14828
14829 }
14830
14831
14832
14833 type AccountPermissionsListCall struct {
14834 s *Service
14835 profileId int64
14836 urlParams_ gensupport.URLParams
14837 ifNoneMatch_ string
14838 ctx_ context.Context
14839 header_ http.Header
14840 }
14841
14842
14843 func (r *AccountPermissionsService) List(profileId int64) *AccountPermissionsListCall {
14844 c := &AccountPermissionsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
14845 c.profileId = profileId
14846 return c
14847 }
14848
14849
14850
14851
14852 func (c *AccountPermissionsListCall) Fields(s ...googleapi.Field) *AccountPermissionsListCall {
14853 c.urlParams_.Set("fields", googleapi.CombineFields(s))
14854 return c
14855 }
14856
14857
14858
14859
14860
14861
14862 func (c *AccountPermissionsListCall) IfNoneMatch(entityTag string) *AccountPermissionsListCall {
14863 c.ifNoneMatch_ = entityTag
14864 return c
14865 }
14866
14867
14868
14869
14870 func (c *AccountPermissionsListCall) Context(ctx context.Context) *AccountPermissionsListCall {
14871 c.ctx_ = ctx
14872 return c
14873 }
14874
14875
14876
14877 func (c *AccountPermissionsListCall) Header() http.Header {
14878 if c.header_ == nil {
14879 c.header_ = make(http.Header)
14880 }
14881 return c.header_
14882 }
14883
14884 func (c *AccountPermissionsListCall) doRequest(alt string) (*http.Response, error) {
14885 reqHeaders := make(http.Header)
14886 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
14887 for k, v := range c.header_ {
14888 reqHeaders[k] = v
14889 }
14890 reqHeaders.Set("User-Agent", c.s.userAgent())
14891 if c.ifNoneMatch_ != "" {
14892 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
14893 }
14894 var body io.Reader = nil
14895 c.urlParams_.Set("alt", alt)
14896 c.urlParams_.Set("prettyPrint", "false")
14897 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/accountPermissions")
14898 urls += "?" + c.urlParams_.Encode()
14899 req, err := http.NewRequest("GET", urls, body)
14900 if err != nil {
14901 return nil, err
14902 }
14903 req.Header = reqHeaders
14904 googleapi.Expand(req.URL, map[string]string{
14905 "profileId": strconv.FormatInt(c.profileId, 10),
14906 })
14907 return gensupport.SendRequest(c.ctx_, c.s.client, req)
14908 }
14909
14910
14911
14912
14913
14914
14915
14916
14917 func (c *AccountPermissionsListCall) Do(opts ...googleapi.CallOption) (*AccountPermissionsListResponse, error) {
14918 gensupport.SetOptions(c.urlParams_, opts...)
14919 res, err := c.doRequest("json")
14920 if res != nil && res.StatusCode == http.StatusNotModified {
14921 if res.Body != nil {
14922 res.Body.Close()
14923 }
14924 return nil, &googleapi.Error{
14925 Code: res.StatusCode,
14926 Header: res.Header,
14927 }
14928 }
14929 if err != nil {
14930 return nil, err
14931 }
14932 defer googleapi.CloseBody(res)
14933 if err := googleapi.CheckResponse(res); err != nil {
14934 return nil, err
14935 }
14936 ret := &AccountPermissionsListResponse{
14937 ServerResponse: googleapi.ServerResponse{
14938 Header: res.Header,
14939 HTTPStatusCode: res.StatusCode,
14940 },
14941 }
14942 target := &ret
14943 if err := gensupport.DecodeResponse(target, res); err != nil {
14944 return nil, err
14945 }
14946 return ret, nil
14947
14948
14949
14950
14951
14952
14953
14954
14955
14956
14957
14958
14959
14960
14961
14962
14963
14964
14965
14966
14967
14968
14969
14970
14971
14972 }
14973
14974
14975
14976 type AccountUserProfilesGetCall struct {
14977 s *Service
14978 profileId int64
14979 id int64
14980 urlParams_ gensupport.URLParams
14981 ifNoneMatch_ string
14982 ctx_ context.Context
14983 header_ http.Header
14984 }
14985
14986
14987 func (r *AccountUserProfilesService) Get(profileId int64, id int64) *AccountUserProfilesGetCall {
14988 c := &AccountUserProfilesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
14989 c.profileId = profileId
14990 c.id = id
14991 return c
14992 }
14993
14994
14995
14996
14997 func (c *AccountUserProfilesGetCall) Fields(s ...googleapi.Field) *AccountUserProfilesGetCall {
14998 c.urlParams_.Set("fields", googleapi.CombineFields(s))
14999 return c
15000 }
15001
15002
15003
15004
15005
15006
15007 func (c *AccountUserProfilesGetCall) IfNoneMatch(entityTag string) *AccountUserProfilesGetCall {
15008 c.ifNoneMatch_ = entityTag
15009 return c
15010 }
15011
15012
15013
15014
15015 func (c *AccountUserProfilesGetCall) Context(ctx context.Context) *AccountUserProfilesGetCall {
15016 c.ctx_ = ctx
15017 return c
15018 }
15019
15020
15021
15022 func (c *AccountUserProfilesGetCall) Header() http.Header {
15023 if c.header_ == nil {
15024 c.header_ = make(http.Header)
15025 }
15026 return c.header_
15027 }
15028
15029 func (c *AccountUserProfilesGetCall) doRequest(alt string) (*http.Response, error) {
15030 reqHeaders := make(http.Header)
15031 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
15032 for k, v := range c.header_ {
15033 reqHeaders[k] = v
15034 }
15035 reqHeaders.Set("User-Agent", c.s.userAgent())
15036 if c.ifNoneMatch_ != "" {
15037 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
15038 }
15039 var body io.Reader = nil
15040 c.urlParams_.Set("alt", alt)
15041 c.urlParams_.Set("prettyPrint", "false")
15042 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/accountUserProfiles/{id}")
15043 urls += "?" + c.urlParams_.Encode()
15044 req, err := http.NewRequest("GET", urls, body)
15045 if err != nil {
15046 return nil, err
15047 }
15048 req.Header = reqHeaders
15049 googleapi.Expand(req.URL, map[string]string{
15050 "profileId": strconv.FormatInt(c.profileId, 10),
15051 "id": strconv.FormatInt(c.id, 10),
15052 })
15053 return gensupport.SendRequest(c.ctx_, c.s.client, req)
15054 }
15055
15056
15057
15058
15059
15060
15061
15062
15063 func (c *AccountUserProfilesGetCall) Do(opts ...googleapi.CallOption) (*AccountUserProfile, error) {
15064 gensupport.SetOptions(c.urlParams_, opts...)
15065 res, err := c.doRequest("json")
15066 if res != nil && res.StatusCode == http.StatusNotModified {
15067 if res.Body != nil {
15068 res.Body.Close()
15069 }
15070 return nil, &googleapi.Error{
15071 Code: res.StatusCode,
15072 Header: res.Header,
15073 }
15074 }
15075 if err != nil {
15076 return nil, err
15077 }
15078 defer googleapi.CloseBody(res)
15079 if err := googleapi.CheckResponse(res); err != nil {
15080 return nil, err
15081 }
15082 ret := &AccountUserProfile{
15083 ServerResponse: googleapi.ServerResponse{
15084 Header: res.Header,
15085 HTTPStatusCode: res.StatusCode,
15086 },
15087 }
15088 target := &ret
15089 if err := gensupport.DecodeResponse(target, res); err != nil {
15090 return nil, err
15091 }
15092 return ret, nil
15093
15094
15095
15096
15097
15098
15099
15100
15101
15102
15103
15104
15105
15106
15107
15108
15109
15110
15111
15112
15113
15114
15115
15116
15117
15118
15119
15120
15121
15122
15123
15124
15125
15126 }
15127
15128
15129
15130 type AccountUserProfilesInsertCall struct {
15131 s *Service
15132 profileId int64
15133 accountuserprofile *AccountUserProfile
15134 urlParams_ gensupport.URLParams
15135 ctx_ context.Context
15136 header_ http.Header
15137 }
15138
15139
15140 func (r *AccountUserProfilesService) Insert(profileId int64, accountuserprofile *AccountUserProfile) *AccountUserProfilesInsertCall {
15141 c := &AccountUserProfilesInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
15142 c.profileId = profileId
15143 c.accountuserprofile = accountuserprofile
15144 return c
15145 }
15146
15147
15148
15149
15150 func (c *AccountUserProfilesInsertCall) Fields(s ...googleapi.Field) *AccountUserProfilesInsertCall {
15151 c.urlParams_.Set("fields", googleapi.CombineFields(s))
15152 return c
15153 }
15154
15155
15156
15157
15158 func (c *AccountUserProfilesInsertCall) Context(ctx context.Context) *AccountUserProfilesInsertCall {
15159 c.ctx_ = ctx
15160 return c
15161 }
15162
15163
15164
15165 func (c *AccountUserProfilesInsertCall) Header() http.Header {
15166 if c.header_ == nil {
15167 c.header_ = make(http.Header)
15168 }
15169 return c.header_
15170 }
15171
15172 func (c *AccountUserProfilesInsertCall) doRequest(alt string) (*http.Response, error) {
15173 reqHeaders := make(http.Header)
15174 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
15175 for k, v := range c.header_ {
15176 reqHeaders[k] = v
15177 }
15178 reqHeaders.Set("User-Agent", c.s.userAgent())
15179 var body io.Reader = nil
15180 body, err := googleapi.WithoutDataWrapper.JSONReader(c.accountuserprofile)
15181 if err != nil {
15182 return nil, err
15183 }
15184 reqHeaders.Set("Content-Type", "application/json")
15185 c.urlParams_.Set("alt", alt)
15186 c.urlParams_.Set("prettyPrint", "false")
15187 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/accountUserProfiles")
15188 urls += "?" + c.urlParams_.Encode()
15189 req, err := http.NewRequest("POST", urls, body)
15190 if err != nil {
15191 return nil, err
15192 }
15193 req.Header = reqHeaders
15194 googleapi.Expand(req.URL, map[string]string{
15195 "profileId": strconv.FormatInt(c.profileId, 10),
15196 })
15197 return gensupport.SendRequest(c.ctx_, c.s.client, req)
15198 }
15199
15200
15201
15202
15203
15204
15205
15206
15207 func (c *AccountUserProfilesInsertCall) Do(opts ...googleapi.CallOption) (*AccountUserProfile, error) {
15208 gensupport.SetOptions(c.urlParams_, opts...)
15209 res, err := c.doRequest("json")
15210 if res != nil && res.StatusCode == http.StatusNotModified {
15211 if res.Body != nil {
15212 res.Body.Close()
15213 }
15214 return nil, &googleapi.Error{
15215 Code: res.StatusCode,
15216 Header: res.Header,
15217 }
15218 }
15219 if err != nil {
15220 return nil, err
15221 }
15222 defer googleapi.CloseBody(res)
15223 if err := googleapi.CheckResponse(res); err != nil {
15224 return nil, err
15225 }
15226 ret := &AccountUserProfile{
15227 ServerResponse: googleapi.ServerResponse{
15228 Header: res.Header,
15229 HTTPStatusCode: res.StatusCode,
15230 },
15231 }
15232 target := &ret
15233 if err := gensupport.DecodeResponse(target, res); err != nil {
15234 return nil, err
15235 }
15236 return ret, nil
15237
15238
15239
15240
15241
15242
15243
15244
15245
15246
15247
15248
15249
15250
15251
15252
15253
15254
15255
15256
15257
15258
15259
15260
15261
15262
15263
15264
15265 }
15266
15267
15268
15269 type AccountUserProfilesListCall struct {
15270 s *Service
15271 profileId int64
15272 urlParams_ gensupport.URLParams
15273 ifNoneMatch_ string
15274 ctx_ context.Context
15275 header_ http.Header
15276 }
15277
15278
15279
15280 func (r *AccountUserProfilesService) List(profileId int64) *AccountUserProfilesListCall {
15281 c := &AccountUserProfilesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
15282 c.profileId = profileId
15283 return c
15284 }
15285
15286
15287
15288 func (c *AccountUserProfilesListCall) Active(active bool) *AccountUserProfilesListCall {
15289 c.urlParams_.Set("active", fmt.Sprint(active))
15290 return c
15291 }
15292
15293
15294
15295 func (c *AccountUserProfilesListCall) Ids(ids ...int64) *AccountUserProfilesListCall {
15296 var ids_ []string
15297 for _, v := range ids {
15298 ids_ = append(ids_, fmt.Sprint(v))
15299 }
15300 c.urlParams_.SetMulti("ids", ids_)
15301 return c
15302 }
15303
15304
15305
15306 func (c *AccountUserProfilesListCall) MaxResults(maxResults int64) *AccountUserProfilesListCall {
15307 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
15308 return c
15309 }
15310
15311
15312
15313 func (c *AccountUserProfilesListCall) PageToken(pageToken string) *AccountUserProfilesListCall {
15314 c.urlParams_.Set("pageToken", pageToken)
15315 return c
15316 }
15317
15318
15319
15320
15321
15322
15323
15324
15325
15326
15327 func (c *AccountUserProfilesListCall) SearchString(searchString string) *AccountUserProfilesListCall {
15328 c.urlParams_.Set("searchString", searchString)
15329 return c
15330 }
15331
15332
15333
15334
15335
15336
15337
15338
15339 func (c *AccountUserProfilesListCall) SortField(sortField string) *AccountUserProfilesListCall {
15340 c.urlParams_.Set("sortField", sortField)
15341 return c
15342 }
15343
15344
15345
15346
15347
15348
15349
15350
15351 func (c *AccountUserProfilesListCall) SortOrder(sortOrder string) *AccountUserProfilesListCall {
15352 c.urlParams_.Set("sortOrder", sortOrder)
15353 return c
15354 }
15355
15356
15357
15358 func (c *AccountUserProfilesListCall) SubaccountId(subaccountId int64) *AccountUserProfilesListCall {
15359 c.urlParams_.Set("subaccountId", fmt.Sprint(subaccountId))
15360 return c
15361 }
15362
15363
15364
15365 func (c *AccountUserProfilesListCall) UserRoleId(userRoleId int64) *AccountUserProfilesListCall {
15366 c.urlParams_.Set("userRoleId", fmt.Sprint(userRoleId))
15367 return c
15368 }
15369
15370
15371
15372
15373 func (c *AccountUserProfilesListCall) Fields(s ...googleapi.Field) *AccountUserProfilesListCall {
15374 c.urlParams_.Set("fields", googleapi.CombineFields(s))
15375 return c
15376 }
15377
15378
15379
15380
15381
15382
15383 func (c *AccountUserProfilesListCall) IfNoneMatch(entityTag string) *AccountUserProfilesListCall {
15384 c.ifNoneMatch_ = entityTag
15385 return c
15386 }
15387
15388
15389
15390
15391 func (c *AccountUserProfilesListCall) Context(ctx context.Context) *AccountUserProfilesListCall {
15392 c.ctx_ = ctx
15393 return c
15394 }
15395
15396
15397
15398 func (c *AccountUserProfilesListCall) Header() http.Header {
15399 if c.header_ == nil {
15400 c.header_ = make(http.Header)
15401 }
15402 return c.header_
15403 }
15404
15405 func (c *AccountUserProfilesListCall) doRequest(alt string) (*http.Response, error) {
15406 reqHeaders := make(http.Header)
15407 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
15408 for k, v := range c.header_ {
15409 reqHeaders[k] = v
15410 }
15411 reqHeaders.Set("User-Agent", c.s.userAgent())
15412 if c.ifNoneMatch_ != "" {
15413 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
15414 }
15415 var body io.Reader = nil
15416 c.urlParams_.Set("alt", alt)
15417 c.urlParams_.Set("prettyPrint", "false")
15418 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/accountUserProfiles")
15419 urls += "?" + c.urlParams_.Encode()
15420 req, err := http.NewRequest("GET", urls, body)
15421 if err != nil {
15422 return nil, err
15423 }
15424 req.Header = reqHeaders
15425 googleapi.Expand(req.URL, map[string]string{
15426 "profileId": strconv.FormatInt(c.profileId, 10),
15427 })
15428 return gensupport.SendRequest(c.ctx_, c.s.client, req)
15429 }
15430
15431
15432
15433
15434
15435
15436
15437
15438 func (c *AccountUserProfilesListCall) Do(opts ...googleapi.CallOption) (*AccountUserProfilesListResponse, error) {
15439 gensupport.SetOptions(c.urlParams_, opts...)
15440 res, err := c.doRequest("json")
15441 if res != nil && res.StatusCode == http.StatusNotModified {
15442 if res.Body != nil {
15443 res.Body.Close()
15444 }
15445 return nil, &googleapi.Error{
15446 Code: res.StatusCode,
15447 Header: res.Header,
15448 }
15449 }
15450 if err != nil {
15451 return nil, err
15452 }
15453 defer googleapi.CloseBody(res)
15454 if err := googleapi.CheckResponse(res); err != nil {
15455 return nil, err
15456 }
15457 ret := &AccountUserProfilesListResponse{
15458 ServerResponse: googleapi.ServerResponse{
15459 Header: res.Header,
15460 HTTPStatusCode: res.StatusCode,
15461 },
15462 }
15463 target := &ret
15464 if err := gensupport.DecodeResponse(target, res); err != nil {
15465 return nil, err
15466 }
15467 return ret, nil
15468
15469
15470
15471
15472
15473
15474
15475
15476
15477
15478
15479
15480
15481
15482
15483
15484
15485
15486
15487
15488
15489
15490
15491
15492
15493
15494
15495
15496
15497
15498
15499
15500
15501
15502
15503
15504
15505
15506
15507
15508
15509
15510
15511
15512
15513
15514
15515
15516
15517
15518
15519
15520
15521
15522
15523
15524
15525
15526
15527
15528
15529
15530
15531
15532
15533
15534
15535
15536
15537
15538
15539
15540
15541
15542
15543
15544
15545
15546
15547
15548
15549
15550
15551
15552
15553
15554
15555
15556
15557
15558
15559
15560
15561
15562
15563
15564 }
15565
15566
15567
15568
15569 func (c *AccountUserProfilesListCall) Pages(ctx context.Context, f func(*AccountUserProfilesListResponse) error) error {
15570 c.ctx_ = ctx
15571 defer c.PageToken(c.urlParams_.Get("pageToken"))
15572 for {
15573 x, err := c.Do()
15574 if err != nil {
15575 return err
15576 }
15577 if err := f(x); err != nil {
15578 return err
15579 }
15580 if x.NextPageToken == "" {
15581 return nil
15582 }
15583 c.PageToken(x.NextPageToken)
15584 }
15585 }
15586
15587
15588
15589 type AccountUserProfilesPatchCall struct {
15590 s *Service
15591 profileId int64
15592 accountuserprofile *AccountUserProfile
15593 urlParams_ gensupport.URLParams
15594 ctx_ context.Context
15595 header_ http.Header
15596 }
15597
15598
15599
15600 func (r *AccountUserProfilesService) Patch(profileId int64, id int64, accountuserprofile *AccountUserProfile) *AccountUserProfilesPatchCall {
15601 c := &AccountUserProfilesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
15602 c.profileId = profileId
15603 c.urlParams_.Set("id", fmt.Sprint(id))
15604 c.accountuserprofile = accountuserprofile
15605 return c
15606 }
15607
15608
15609
15610
15611 func (c *AccountUserProfilesPatchCall) Fields(s ...googleapi.Field) *AccountUserProfilesPatchCall {
15612 c.urlParams_.Set("fields", googleapi.CombineFields(s))
15613 return c
15614 }
15615
15616
15617
15618
15619 func (c *AccountUserProfilesPatchCall) Context(ctx context.Context) *AccountUserProfilesPatchCall {
15620 c.ctx_ = ctx
15621 return c
15622 }
15623
15624
15625
15626 func (c *AccountUserProfilesPatchCall) Header() http.Header {
15627 if c.header_ == nil {
15628 c.header_ = make(http.Header)
15629 }
15630 return c.header_
15631 }
15632
15633 func (c *AccountUserProfilesPatchCall) doRequest(alt string) (*http.Response, error) {
15634 reqHeaders := make(http.Header)
15635 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
15636 for k, v := range c.header_ {
15637 reqHeaders[k] = v
15638 }
15639 reqHeaders.Set("User-Agent", c.s.userAgent())
15640 var body io.Reader = nil
15641 body, err := googleapi.WithoutDataWrapper.JSONReader(c.accountuserprofile)
15642 if err != nil {
15643 return nil, err
15644 }
15645 reqHeaders.Set("Content-Type", "application/json")
15646 c.urlParams_.Set("alt", alt)
15647 c.urlParams_.Set("prettyPrint", "false")
15648 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/accountUserProfiles")
15649 urls += "?" + c.urlParams_.Encode()
15650 req, err := http.NewRequest("PATCH", urls, body)
15651 if err != nil {
15652 return nil, err
15653 }
15654 req.Header = reqHeaders
15655 googleapi.Expand(req.URL, map[string]string{
15656 "profileId": strconv.FormatInt(c.profileId, 10),
15657 })
15658 return gensupport.SendRequest(c.ctx_, c.s.client, req)
15659 }
15660
15661
15662
15663
15664
15665
15666
15667
15668 func (c *AccountUserProfilesPatchCall) Do(opts ...googleapi.CallOption) (*AccountUserProfile, error) {
15669 gensupport.SetOptions(c.urlParams_, opts...)
15670 res, err := c.doRequest("json")
15671 if res != nil && res.StatusCode == http.StatusNotModified {
15672 if res.Body != nil {
15673 res.Body.Close()
15674 }
15675 return nil, &googleapi.Error{
15676 Code: res.StatusCode,
15677 Header: res.Header,
15678 }
15679 }
15680 if err != nil {
15681 return nil, err
15682 }
15683 defer googleapi.CloseBody(res)
15684 if err := googleapi.CheckResponse(res); err != nil {
15685 return nil, err
15686 }
15687 ret := &AccountUserProfile{
15688 ServerResponse: googleapi.ServerResponse{
15689 Header: res.Header,
15690 HTTPStatusCode: res.StatusCode,
15691 },
15692 }
15693 target := &ret
15694 if err := gensupport.DecodeResponse(target, res); err != nil {
15695 return nil, err
15696 }
15697 return ret, nil
15698
15699
15700
15701
15702
15703
15704
15705
15706
15707
15708
15709
15710
15711
15712
15713
15714
15715
15716
15717
15718
15719
15720
15721
15722
15723
15724
15725
15726
15727
15728
15729
15730
15731
15732
15733
15734 }
15735
15736
15737
15738 type AccountUserProfilesUpdateCall struct {
15739 s *Service
15740 profileId int64
15741 accountuserprofile *AccountUserProfile
15742 urlParams_ gensupport.URLParams
15743 ctx_ context.Context
15744 header_ http.Header
15745 }
15746
15747
15748 func (r *AccountUserProfilesService) Update(profileId int64, accountuserprofile *AccountUserProfile) *AccountUserProfilesUpdateCall {
15749 c := &AccountUserProfilesUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
15750 c.profileId = profileId
15751 c.accountuserprofile = accountuserprofile
15752 return c
15753 }
15754
15755
15756
15757
15758 func (c *AccountUserProfilesUpdateCall) Fields(s ...googleapi.Field) *AccountUserProfilesUpdateCall {
15759 c.urlParams_.Set("fields", googleapi.CombineFields(s))
15760 return c
15761 }
15762
15763
15764
15765
15766 func (c *AccountUserProfilesUpdateCall) Context(ctx context.Context) *AccountUserProfilesUpdateCall {
15767 c.ctx_ = ctx
15768 return c
15769 }
15770
15771
15772
15773 func (c *AccountUserProfilesUpdateCall) Header() http.Header {
15774 if c.header_ == nil {
15775 c.header_ = make(http.Header)
15776 }
15777 return c.header_
15778 }
15779
15780 func (c *AccountUserProfilesUpdateCall) doRequest(alt string) (*http.Response, error) {
15781 reqHeaders := make(http.Header)
15782 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
15783 for k, v := range c.header_ {
15784 reqHeaders[k] = v
15785 }
15786 reqHeaders.Set("User-Agent", c.s.userAgent())
15787 var body io.Reader = nil
15788 body, err := googleapi.WithoutDataWrapper.JSONReader(c.accountuserprofile)
15789 if err != nil {
15790 return nil, err
15791 }
15792 reqHeaders.Set("Content-Type", "application/json")
15793 c.urlParams_.Set("alt", alt)
15794 c.urlParams_.Set("prettyPrint", "false")
15795 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/accountUserProfiles")
15796 urls += "?" + c.urlParams_.Encode()
15797 req, err := http.NewRequest("PUT", urls, body)
15798 if err != nil {
15799 return nil, err
15800 }
15801 req.Header = reqHeaders
15802 googleapi.Expand(req.URL, map[string]string{
15803 "profileId": strconv.FormatInt(c.profileId, 10),
15804 })
15805 return gensupport.SendRequest(c.ctx_, c.s.client, req)
15806 }
15807
15808
15809
15810
15811
15812
15813
15814
15815 func (c *AccountUserProfilesUpdateCall) Do(opts ...googleapi.CallOption) (*AccountUserProfile, error) {
15816 gensupport.SetOptions(c.urlParams_, opts...)
15817 res, err := c.doRequest("json")
15818 if res != nil && res.StatusCode == http.StatusNotModified {
15819 if res.Body != nil {
15820 res.Body.Close()
15821 }
15822 return nil, &googleapi.Error{
15823 Code: res.StatusCode,
15824 Header: res.Header,
15825 }
15826 }
15827 if err != nil {
15828 return nil, err
15829 }
15830 defer googleapi.CloseBody(res)
15831 if err := googleapi.CheckResponse(res); err != nil {
15832 return nil, err
15833 }
15834 ret := &AccountUserProfile{
15835 ServerResponse: googleapi.ServerResponse{
15836 Header: res.Header,
15837 HTTPStatusCode: res.StatusCode,
15838 },
15839 }
15840 target := &ret
15841 if err := gensupport.DecodeResponse(target, res); err != nil {
15842 return nil, err
15843 }
15844 return ret, nil
15845
15846
15847
15848
15849
15850
15851
15852
15853
15854
15855
15856
15857
15858
15859
15860
15861
15862
15863
15864
15865
15866
15867
15868
15869
15870
15871
15872
15873 }
15874
15875
15876
15877 type AccountsGetCall struct {
15878 s *Service
15879 profileId int64
15880 id int64
15881 urlParams_ gensupport.URLParams
15882 ifNoneMatch_ string
15883 ctx_ context.Context
15884 header_ http.Header
15885 }
15886
15887
15888 func (r *AccountsService) Get(profileId int64, id int64) *AccountsGetCall {
15889 c := &AccountsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
15890 c.profileId = profileId
15891 c.id = id
15892 return c
15893 }
15894
15895
15896
15897
15898 func (c *AccountsGetCall) Fields(s ...googleapi.Field) *AccountsGetCall {
15899 c.urlParams_.Set("fields", googleapi.CombineFields(s))
15900 return c
15901 }
15902
15903
15904
15905
15906
15907
15908 func (c *AccountsGetCall) IfNoneMatch(entityTag string) *AccountsGetCall {
15909 c.ifNoneMatch_ = entityTag
15910 return c
15911 }
15912
15913
15914
15915
15916 func (c *AccountsGetCall) Context(ctx context.Context) *AccountsGetCall {
15917 c.ctx_ = ctx
15918 return c
15919 }
15920
15921
15922
15923 func (c *AccountsGetCall) Header() http.Header {
15924 if c.header_ == nil {
15925 c.header_ = make(http.Header)
15926 }
15927 return c.header_
15928 }
15929
15930 func (c *AccountsGetCall) doRequest(alt string) (*http.Response, error) {
15931 reqHeaders := make(http.Header)
15932 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
15933 for k, v := range c.header_ {
15934 reqHeaders[k] = v
15935 }
15936 reqHeaders.Set("User-Agent", c.s.userAgent())
15937 if c.ifNoneMatch_ != "" {
15938 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
15939 }
15940 var body io.Reader = nil
15941 c.urlParams_.Set("alt", alt)
15942 c.urlParams_.Set("prettyPrint", "false")
15943 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/accounts/{id}")
15944 urls += "?" + c.urlParams_.Encode()
15945 req, err := http.NewRequest("GET", urls, body)
15946 if err != nil {
15947 return nil, err
15948 }
15949 req.Header = reqHeaders
15950 googleapi.Expand(req.URL, map[string]string{
15951 "profileId": strconv.FormatInt(c.profileId, 10),
15952 "id": strconv.FormatInt(c.id, 10),
15953 })
15954 return gensupport.SendRequest(c.ctx_, c.s.client, req)
15955 }
15956
15957
15958
15959
15960
15961
15962
15963
15964 func (c *AccountsGetCall) Do(opts ...googleapi.CallOption) (*Account, error) {
15965 gensupport.SetOptions(c.urlParams_, opts...)
15966 res, err := c.doRequest("json")
15967 if res != nil && res.StatusCode == http.StatusNotModified {
15968 if res.Body != nil {
15969 res.Body.Close()
15970 }
15971 return nil, &googleapi.Error{
15972 Code: res.StatusCode,
15973 Header: res.Header,
15974 }
15975 }
15976 if err != nil {
15977 return nil, err
15978 }
15979 defer googleapi.CloseBody(res)
15980 if err := googleapi.CheckResponse(res); err != nil {
15981 return nil, err
15982 }
15983 ret := &Account{
15984 ServerResponse: googleapi.ServerResponse{
15985 Header: res.Header,
15986 HTTPStatusCode: res.StatusCode,
15987 },
15988 }
15989 target := &ret
15990 if err := gensupport.DecodeResponse(target, res); err != nil {
15991 return nil, err
15992 }
15993 return ret, nil
15994
15995
15996
15997
15998
15999
16000
16001
16002
16003
16004
16005
16006
16007
16008
16009
16010
16011
16012
16013
16014
16015
16016
16017
16018
16019
16020
16021
16022
16023
16024
16025
16026
16027 }
16028
16029
16030
16031 type AccountsListCall struct {
16032 s *Service
16033 profileId int64
16034 urlParams_ gensupport.URLParams
16035 ifNoneMatch_ string
16036 ctx_ context.Context
16037 header_ http.Header
16038 }
16039
16040
16041
16042 func (r *AccountsService) List(profileId int64) *AccountsListCall {
16043 c := &AccountsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
16044 c.profileId = profileId
16045 return c
16046 }
16047
16048
16049
16050
16051 func (c *AccountsListCall) Active(active bool) *AccountsListCall {
16052 c.urlParams_.Set("active", fmt.Sprint(active))
16053 return c
16054 }
16055
16056
16057
16058 func (c *AccountsListCall) Ids(ids ...int64) *AccountsListCall {
16059 var ids_ []string
16060 for _, v := range ids {
16061 ids_ = append(ids_, fmt.Sprint(v))
16062 }
16063 c.urlParams_.SetMulti("ids", ids_)
16064 return c
16065 }
16066
16067
16068
16069 func (c *AccountsListCall) MaxResults(maxResults int64) *AccountsListCall {
16070 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
16071 return c
16072 }
16073
16074
16075
16076 func (c *AccountsListCall) PageToken(pageToken string) *AccountsListCall {
16077 c.urlParams_.Set("pageToken", pageToken)
16078 return c
16079 }
16080
16081
16082
16083
16084
16085
16086
16087
16088
16089 func (c *AccountsListCall) SearchString(searchString string) *AccountsListCall {
16090 c.urlParams_.Set("searchString", searchString)
16091 return c
16092 }
16093
16094
16095
16096
16097
16098
16099
16100
16101 func (c *AccountsListCall) SortField(sortField string) *AccountsListCall {
16102 c.urlParams_.Set("sortField", sortField)
16103 return c
16104 }
16105
16106
16107
16108
16109
16110
16111
16112
16113 func (c *AccountsListCall) SortOrder(sortOrder string) *AccountsListCall {
16114 c.urlParams_.Set("sortOrder", sortOrder)
16115 return c
16116 }
16117
16118
16119
16120
16121 func (c *AccountsListCall) Fields(s ...googleapi.Field) *AccountsListCall {
16122 c.urlParams_.Set("fields", googleapi.CombineFields(s))
16123 return c
16124 }
16125
16126
16127
16128
16129
16130
16131 func (c *AccountsListCall) IfNoneMatch(entityTag string) *AccountsListCall {
16132 c.ifNoneMatch_ = entityTag
16133 return c
16134 }
16135
16136
16137
16138
16139 func (c *AccountsListCall) Context(ctx context.Context) *AccountsListCall {
16140 c.ctx_ = ctx
16141 return c
16142 }
16143
16144
16145
16146 func (c *AccountsListCall) Header() http.Header {
16147 if c.header_ == nil {
16148 c.header_ = make(http.Header)
16149 }
16150 return c.header_
16151 }
16152
16153 func (c *AccountsListCall) doRequest(alt string) (*http.Response, error) {
16154 reqHeaders := make(http.Header)
16155 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
16156 for k, v := range c.header_ {
16157 reqHeaders[k] = v
16158 }
16159 reqHeaders.Set("User-Agent", c.s.userAgent())
16160 if c.ifNoneMatch_ != "" {
16161 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
16162 }
16163 var body io.Reader = nil
16164 c.urlParams_.Set("alt", alt)
16165 c.urlParams_.Set("prettyPrint", "false")
16166 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/accounts")
16167 urls += "?" + c.urlParams_.Encode()
16168 req, err := http.NewRequest("GET", urls, body)
16169 if err != nil {
16170 return nil, err
16171 }
16172 req.Header = reqHeaders
16173 googleapi.Expand(req.URL, map[string]string{
16174 "profileId": strconv.FormatInt(c.profileId, 10),
16175 })
16176 return gensupport.SendRequest(c.ctx_, c.s.client, req)
16177 }
16178
16179
16180
16181
16182
16183
16184
16185
16186 func (c *AccountsListCall) Do(opts ...googleapi.CallOption) (*AccountsListResponse, error) {
16187 gensupport.SetOptions(c.urlParams_, opts...)
16188 res, err := c.doRequest("json")
16189 if res != nil && res.StatusCode == http.StatusNotModified {
16190 if res.Body != nil {
16191 res.Body.Close()
16192 }
16193 return nil, &googleapi.Error{
16194 Code: res.StatusCode,
16195 Header: res.Header,
16196 }
16197 }
16198 if err != nil {
16199 return nil, err
16200 }
16201 defer googleapi.CloseBody(res)
16202 if err := googleapi.CheckResponse(res); err != nil {
16203 return nil, err
16204 }
16205 ret := &AccountsListResponse{
16206 ServerResponse: googleapi.ServerResponse{
16207 Header: res.Header,
16208 HTTPStatusCode: res.StatusCode,
16209 },
16210 }
16211 target := &ret
16212 if err := gensupport.DecodeResponse(target, res); err != nil {
16213 return nil, err
16214 }
16215 return ret, nil
16216
16217
16218
16219
16220
16221
16222
16223
16224
16225
16226
16227
16228
16229
16230
16231
16232
16233
16234
16235
16236
16237
16238
16239
16240
16241
16242
16243
16244
16245
16246
16247
16248
16249
16250
16251
16252
16253
16254
16255
16256
16257
16258
16259
16260
16261
16262
16263
16264
16265
16266
16267
16268
16269
16270
16271
16272
16273
16274
16275
16276
16277
16278
16279
16280
16281
16282
16283
16284
16285
16286
16287
16288
16289
16290
16291
16292
16293
16294
16295
16296
16297
16298
16299
16300 }
16301
16302
16303
16304
16305 func (c *AccountsListCall) Pages(ctx context.Context, f func(*AccountsListResponse) error) error {
16306 c.ctx_ = ctx
16307 defer c.PageToken(c.urlParams_.Get("pageToken"))
16308 for {
16309 x, err := c.Do()
16310 if err != nil {
16311 return err
16312 }
16313 if err := f(x); err != nil {
16314 return err
16315 }
16316 if x.NextPageToken == "" {
16317 return nil
16318 }
16319 c.PageToken(x.NextPageToken)
16320 }
16321 }
16322
16323
16324
16325 type AccountsPatchCall struct {
16326 s *Service
16327 profileId int64
16328 account *Account
16329 urlParams_ gensupport.URLParams
16330 ctx_ context.Context
16331 header_ http.Header
16332 }
16333
16334
16335
16336 func (r *AccountsService) Patch(profileId int64, id int64, account *Account) *AccountsPatchCall {
16337 c := &AccountsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
16338 c.profileId = profileId
16339 c.urlParams_.Set("id", fmt.Sprint(id))
16340 c.account = account
16341 return c
16342 }
16343
16344
16345
16346
16347 func (c *AccountsPatchCall) Fields(s ...googleapi.Field) *AccountsPatchCall {
16348 c.urlParams_.Set("fields", googleapi.CombineFields(s))
16349 return c
16350 }
16351
16352
16353
16354
16355 func (c *AccountsPatchCall) Context(ctx context.Context) *AccountsPatchCall {
16356 c.ctx_ = ctx
16357 return c
16358 }
16359
16360
16361
16362 func (c *AccountsPatchCall) Header() http.Header {
16363 if c.header_ == nil {
16364 c.header_ = make(http.Header)
16365 }
16366 return c.header_
16367 }
16368
16369 func (c *AccountsPatchCall) doRequest(alt string) (*http.Response, error) {
16370 reqHeaders := make(http.Header)
16371 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
16372 for k, v := range c.header_ {
16373 reqHeaders[k] = v
16374 }
16375 reqHeaders.Set("User-Agent", c.s.userAgent())
16376 var body io.Reader = nil
16377 body, err := googleapi.WithoutDataWrapper.JSONReader(c.account)
16378 if err != nil {
16379 return nil, err
16380 }
16381 reqHeaders.Set("Content-Type", "application/json")
16382 c.urlParams_.Set("alt", alt)
16383 c.urlParams_.Set("prettyPrint", "false")
16384 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/accounts")
16385 urls += "?" + c.urlParams_.Encode()
16386 req, err := http.NewRequest("PATCH", urls, body)
16387 if err != nil {
16388 return nil, err
16389 }
16390 req.Header = reqHeaders
16391 googleapi.Expand(req.URL, map[string]string{
16392 "profileId": strconv.FormatInt(c.profileId, 10),
16393 })
16394 return gensupport.SendRequest(c.ctx_, c.s.client, req)
16395 }
16396
16397
16398
16399
16400
16401
16402
16403
16404 func (c *AccountsPatchCall) Do(opts ...googleapi.CallOption) (*Account, error) {
16405 gensupport.SetOptions(c.urlParams_, opts...)
16406 res, err := c.doRequest("json")
16407 if res != nil && res.StatusCode == http.StatusNotModified {
16408 if res.Body != nil {
16409 res.Body.Close()
16410 }
16411 return nil, &googleapi.Error{
16412 Code: res.StatusCode,
16413 Header: res.Header,
16414 }
16415 }
16416 if err != nil {
16417 return nil, err
16418 }
16419 defer googleapi.CloseBody(res)
16420 if err := googleapi.CheckResponse(res); err != nil {
16421 return nil, err
16422 }
16423 ret := &Account{
16424 ServerResponse: googleapi.ServerResponse{
16425 Header: res.Header,
16426 HTTPStatusCode: res.StatusCode,
16427 },
16428 }
16429 target := &ret
16430 if err := gensupport.DecodeResponse(target, res); err != nil {
16431 return nil, err
16432 }
16433 return ret, nil
16434
16435
16436
16437
16438
16439
16440
16441
16442
16443
16444
16445
16446
16447
16448
16449
16450
16451
16452
16453
16454
16455
16456
16457
16458
16459
16460
16461
16462
16463
16464
16465
16466
16467
16468
16469
16470 }
16471
16472
16473
16474 type AccountsUpdateCall struct {
16475 s *Service
16476 profileId int64
16477 account *Account
16478 urlParams_ gensupport.URLParams
16479 ctx_ context.Context
16480 header_ http.Header
16481 }
16482
16483
16484 func (r *AccountsService) Update(profileId int64, account *Account) *AccountsUpdateCall {
16485 c := &AccountsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
16486 c.profileId = profileId
16487 c.account = account
16488 return c
16489 }
16490
16491
16492
16493
16494 func (c *AccountsUpdateCall) Fields(s ...googleapi.Field) *AccountsUpdateCall {
16495 c.urlParams_.Set("fields", googleapi.CombineFields(s))
16496 return c
16497 }
16498
16499
16500
16501
16502 func (c *AccountsUpdateCall) Context(ctx context.Context) *AccountsUpdateCall {
16503 c.ctx_ = ctx
16504 return c
16505 }
16506
16507
16508
16509 func (c *AccountsUpdateCall) Header() http.Header {
16510 if c.header_ == nil {
16511 c.header_ = make(http.Header)
16512 }
16513 return c.header_
16514 }
16515
16516 func (c *AccountsUpdateCall) doRequest(alt string) (*http.Response, error) {
16517 reqHeaders := make(http.Header)
16518 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
16519 for k, v := range c.header_ {
16520 reqHeaders[k] = v
16521 }
16522 reqHeaders.Set("User-Agent", c.s.userAgent())
16523 var body io.Reader = nil
16524 body, err := googleapi.WithoutDataWrapper.JSONReader(c.account)
16525 if err != nil {
16526 return nil, err
16527 }
16528 reqHeaders.Set("Content-Type", "application/json")
16529 c.urlParams_.Set("alt", alt)
16530 c.urlParams_.Set("prettyPrint", "false")
16531 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/accounts")
16532 urls += "?" + c.urlParams_.Encode()
16533 req, err := http.NewRequest("PUT", urls, body)
16534 if err != nil {
16535 return nil, err
16536 }
16537 req.Header = reqHeaders
16538 googleapi.Expand(req.URL, map[string]string{
16539 "profileId": strconv.FormatInt(c.profileId, 10),
16540 })
16541 return gensupport.SendRequest(c.ctx_, c.s.client, req)
16542 }
16543
16544
16545
16546
16547
16548
16549
16550
16551 func (c *AccountsUpdateCall) Do(opts ...googleapi.CallOption) (*Account, error) {
16552 gensupport.SetOptions(c.urlParams_, opts...)
16553 res, err := c.doRequest("json")
16554 if res != nil && res.StatusCode == http.StatusNotModified {
16555 if res.Body != nil {
16556 res.Body.Close()
16557 }
16558 return nil, &googleapi.Error{
16559 Code: res.StatusCode,
16560 Header: res.Header,
16561 }
16562 }
16563 if err != nil {
16564 return nil, err
16565 }
16566 defer googleapi.CloseBody(res)
16567 if err := googleapi.CheckResponse(res); err != nil {
16568 return nil, err
16569 }
16570 ret := &Account{
16571 ServerResponse: googleapi.ServerResponse{
16572 Header: res.Header,
16573 HTTPStatusCode: res.StatusCode,
16574 },
16575 }
16576 target := &ret
16577 if err := gensupport.DecodeResponse(target, res); err != nil {
16578 return nil, err
16579 }
16580 return ret, nil
16581
16582
16583
16584
16585
16586
16587
16588
16589
16590
16591
16592
16593
16594
16595
16596
16597
16598
16599
16600
16601
16602
16603
16604
16605
16606
16607
16608
16609 }
16610
16611
16612
16613 type AdsGetCall struct {
16614 s *Service
16615 profileId int64
16616 id int64
16617 urlParams_ gensupport.URLParams
16618 ifNoneMatch_ string
16619 ctx_ context.Context
16620 header_ http.Header
16621 }
16622
16623
16624 func (r *AdsService) Get(profileId int64, id int64) *AdsGetCall {
16625 c := &AdsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
16626 c.profileId = profileId
16627 c.id = id
16628 return c
16629 }
16630
16631
16632
16633
16634 func (c *AdsGetCall) Fields(s ...googleapi.Field) *AdsGetCall {
16635 c.urlParams_.Set("fields", googleapi.CombineFields(s))
16636 return c
16637 }
16638
16639
16640
16641
16642
16643
16644 func (c *AdsGetCall) IfNoneMatch(entityTag string) *AdsGetCall {
16645 c.ifNoneMatch_ = entityTag
16646 return c
16647 }
16648
16649
16650
16651
16652 func (c *AdsGetCall) Context(ctx context.Context) *AdsGetCall {
16653 c.ctx_ = ctx
16654 return c
16655 }
16656
16657
16658
16659 func (c *AdsGetCall) Header() http.Header {
16660 if c.header_ == nil {
16661 c.header_ = make(http.Header)
16662 }
16663 return c.header_
16664 }
16665
16666 func (c *AdsGetCall) doRequest(alt string) (*http.Response, error) {
16667 reqHeaders := make(http.Header)
16668 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
16669 for k, v := range c.header_ {
16670 reqHeaders[k] = v
16671 }
16672 reqHeaders.Set("User-Agent", c.s.userAgent())
16673 if c.ifNoneMatch_ != "" {
16674 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
16675 }
16676 var body io.Reader = nil
16677 c.urlParams_.Set("alt", alt)
16678 c.urlParams_.Set("prettyPrint", "false")
16679 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/ads/{id}")
16680 urls += "?" + c.urlParams_.Encode()
16681 req, err := http.NewRequest("GET", urls, body)
16682 if err != nil {
16683 return nil, err
16684 }
16685 req.Header = reqHeaders
16686 googleapi.Expand(req.URL, map[string]string{
16687 "profileId": strconv.FormatInt(c.profileId, 10),
16688 "id": strconv.FormatInt(c.id, 10),
16689 })
16690 return gensupport.SendRequest(c.ctx_, c.s.client, req)
16691 }
16692
16693
16694
16695
16696
16697
16698
16699
16700 func (c *AdsGetCall) Do(opts ...googleapi.CallOption) (*Ad, error) {
16701 gensupport.SetOptions(c.urlParams_, opts...)
16702 res, err := c.doRequest("json")
16703 if res != nil && res.StatusCode == http.StatusNotModified {
16704 if res.Body != nil {
16705 res.Body.Close()
16706 }
16707 return nil, &googleapi.Error{
16708 Code: res.StatusCode,
16709 Header: res.Header,
16710 }
16711 }
16712 if err != nil {
16713 return nil, err
16714 }
16715 defer googleapi.CloseBody(res)
16716 if err := googleapi.CheckResponse(res); err != nil {
16717 return nil, err
16718 }
16719 ret := &Ad{
16720 ServerResponse: googleapi.ServerResponse{
16721 Header: res.Header,
16722 HTTPStatusCode: res.StatusCode,
16723 },
16724 }
16725 target := &ret
16726 if err := gensupport.DecodeResponse(target, res); err != nil {
16727 return nil, err
16728 }
16729 return ret, nil
16730
16731
16732
16733
16734
16735
16736
16737
16738
16739
16740
16741
16742
16743
16744
16745
16746
16747
16748
16749
16750
16751
16752
16753
16754
16755
16756
16757
16758
16759
16760
16761
16762
16763 }
16764
16765
16766
16767 type AdsInsertCall struct {
16768 s *Service
16769 profileId int64
16770 ad *Ad
16771 urlParams_ gensupport.URLParams
16772 ctx_ context.Context
16773 header_ http.Header
16774 }
16775
16776
16777 func (r *AdsService) Insert(profileId int64, ad *Ad) *AdsInsertCall {
16778 c := &AdsInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
16779 c.profileId = profileId
16780 c.ad = ad
16781 return c
16782 }
16783
16784
16785
16786
16787 func (c *AdsInsertCall) Fields(s ...googleapi.Field) *AdsInsertCall {
16788 c.urlParams_.Set("fields", googleapi.CombineFields(s))
16789 return c
16790 }
16791
16792
16793
16794
16795 func (c *AdsInsertCall) Context(ctx context.Context) *AdsInsertCall {
16796 c.ctx_ = ctx
16797 return c
16798 }
16799
16800
16801
16802 func (c *AdsInsertCall) Header() http.Header {
16803 if c.header_ == nil {
16804 c.header_ = make(http.Header)
16805 }
16806 return c.header_
16807 }
16808
16809 func (c *AdsInsertCall) doRequest(alt string) (*http.Response, error) {
16810 reqHeaders := make(http.Header)
16811 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
16812 for k, v := range c.header_ {
16813 reqHeaders[k] = v
16814 }
16815 reqHeaders.Set("User-Agent", c.s.userAgent())
16816 var body io.Reader = nil
16817 body, err := googleapi.WithoutDataWrapper.JSONReader(c.ad)
16818 if err != nil {
16819 return nil, err
16820 }
16821 reqHeaders.Set("Content-Type", "application/json")
16822 c.urlParams_.Set("alt", alt)
16823 c.urlParams_.Set("prettyPrint", "false")
16824 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/ads")
16825 urls += "?" + c.urlParams_.Encode()
16826 req, err := http.NewRequest("POST", urls, body)
16827 if err != nil {
16828 return nil, err
16829 }
16830 req.Header = reqHeaders
16831 googleapi.Expand(req.URL, map[string]string{
16832 "profileId": strconv.FormatInt(c.profileId, 10),
16833 })
16834 return gensupport.SendRequest(c.ctx_, c.s.client, req)
16835 }
16836
16837
16838
16839
16840
16841
16842
16843
16844 func (c *AdsInsertCall) Do(opts ...googleapi.CallOption) (*Ad, error) {
16845 gensupport.SetOptions(c.urlParams_, opts...)
16846 res, err := c.doRequest("json")
16847 if res != nil && res.StatusCode == http.StatusNotModified {
16848 if res.Body != nil {
16849 res.Body.Close()
16850 }
16851 return nil, &googleapi.Error{
16852 Code: res.StatusCode,
16853 Header: res.Header,
16854 }
16855 }
16856 if err != nil {
16857 return nil, err
16858 }
16859 defer googleapi.CloseBody(res)
16860 if err := googleapi.CheckResponse(res); err != nil {
16861 return nil, err
16862 }
16863 ret := &Ad{
16864 ServerResponse: googleapi.ServerResponse{
16865 Header: res.Header,
16866 HTTPStatusCode: res.StatusCode,
16867 },
16868 }
16869 target := &ret
16870 if err := gensupport.DecodeResponse(target, res); err != nil {
16871 return nil, err
16872 }
16873 return ret, nil
16874
16875
16876
16877
16878
16879
16880
16881
16882
16883
16884
16885
16886
16887
16888
16889
16890
16891
16892
16893
16894
16895
16896
16897
16898
16899
16900
16901
16902 }
16903
16904
16905
16906 type AdsListCall struct {
16907 s *Service
16908 profileId int64
16909 urlParams_ gensupport.URLParams
16910 ifNoneMatch_ string
16911 ctx_ context.Context
16912 header_ http.Header
16913 }
16914
16915
16916
16917 func (r *AdsService) List(profileId int64) *AdsListCall {
16918 c := &AdsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
16919 c.profileId = profileId
16920 return c
16921 }
16922
16923
16924 func (c *AdsListCall) Active(active bool) *AdsListCall {
16925 c.urlParams_.Set("active", fmt.Sprint(active))
16926 return c
16927 }
16928
16929
16930
16931 func (c *AdsListCall) AdvertiserId(advertiserId int64) *AdsListCall {
16932 c.urlParams_.Set("advertiserId", fmt.Sprint(advertiserId))
16933 return c
16934 }
16935
16936
16937
16938 func (c *AdsListCall) Archived(archived bool) *AdsListCall {
16939 c.urlParams_.Set("archived", fmt.Sprint(archived))
16940 return c
16941 }
16942
16943
16944
16945 func (c *AdsListCall) AudienceSegmentIds(audienceSegmentIds ...int64) *AdsListCall {
16946 var audienceSegmentIds_ []string
16947 for _, v := range audienceSegmentIds {
16948 audienceSegmentIds_ = append(audienceSegmentIds_, fmt.Sprint(v))
16949 }
16950 c.urlParams_.SetMulti("audienceSegmentIds", audienceSegmentIds_)
16951 return c
16952 }
16953
16954
16955
16956 func (c *AdsListCall) CampaignIds(campaignIds ...int64) *AdsListCall {
16957 var campaignIds_ []string
16958 for _, v := range campaignIds {
16959 campaignIds_ = append(campaignIds_, fmt.Sprint(v))
16960 }
16961 c.urlParams_.SetMulti("campaignIds", campaignIds_)
16962 return c
16963 }
16964
16965
16966
16967
16968
16969
16970
16971
16972
16973
16974
16975
16976
16977
16978
16979
16980
16981 func (c *AdsListCall) Compatibility(compatibility string) *AdsListCall {
16982 c.urlParams_.Set("compatibility", compatibility)
16983 return c
16984 }
16985
16986
16987
16988 func (c *AdsListCall) CreativeIds(creativeIds ...int64) *AdsListCall {
16989 var creativeIds_ []string
16990 for _, v := range creativeIds {
16991 creativeIds_ = append(creativeIds_, fmt.Sprint(v))
16992 }
16993 c.urlParams_.SetMulti("creativeIds", creativeIds_)
16994 return c
16995 }
16996
16997
16998
16999
17000 func (c *AdsListCall) CreativeOptimizationConfigurationIds(creativeOptimizationConfigurationIds ...int64) *AdsListCall {
17001 var creativeOptimizationConfigurationIds_ []string
17002 for _, v := range creativeOptimizationConfigurationIds {
17003 creativeOptimizationConfigurationIds_ = append(creativeOptimizationConfigurationIds_, fmt.Sprint(v))
17004 }
17005 c.urlParams_.SetMulti("creativeOptimizationConfigurationIds", creativeOptimizationConfigurationIds_)
17006 return c
17007 }
17008
17009
17010
17011
17012
17013
17014 func (c *AdsListCall) DynamicClickTracker(dynamicClickTracker bool) *AdsListCall {
17015 c.urlParams_.Set("dynamicClickTracker", fmt.Sprint(dynamicClickTracker))
17016 return c
17017 }
17018
17019
17020
17021 func (c *AdsListCall) Ids(ids ...int64) *AdsListCall {
17022 var ids_ []string
17023 for _, v := range ids {
17024 ids_ = append(ids_, fmt.Sprint(v))
17025 }
17026 c.urlParams_.SetMulti("ids", ids_)
17027 return c
17028 }
17029
17030
17031
17032 func (c *AdsListCall) LandingPageIds(landingPageIds ...int64) *AdsListCall {
17033 var landingPageIds_ []string
17034 for _, v := range landingPageIds {
17035 landingPageIds_ = append(landingPageIds_, fmt.Sprint(v))
17036 }
17037 c.urlParams_.SetMulti("landingPageIds", landingPageIds_)
17038 return c
17039 }
17040
17041
17042
17043 func (c *AdsListCall) MaxResults(maxResults int64) *AdsListCall {
17044 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
17045 return c
17046 }
17047
17048
17049
17050
17051 func (c *AdsListCall) OverriddenEventTagId(overriddenEventTagId int64) *AdsListCall {
17052 c.urlParams_.Set("overriddenEventTagId", fmt.Sprint(overriddenEventTagId))
17053 return c
17054 }
17055
17056
17057
17058 func (c *AdsListCall) PageToken(pageToken string) *AdsListCall {
17059 c.urlParams_.Set("pageToken", pageToken)
17060 return c
17061 }
17062
17063
17064
17065 func (c *AdsListCall) PlacementIds(placementIds ...int64) *AdsListCall {
17066 var placementIds_ []string
17067 for _, v := range placementIds {
17068 placementIds_ = append(placementIds_, fmt.Sprint(v))
17069 }
17070 c.urlParams_.SetMulti("placementIds", placementIds_)
17071 return c
17072 }
17073
17074
17075
17076
17077 func (c *AdsListCall) RemarketingListIds(remarketingListIds ...int64) *AdsListCall {
17078 var remarketingListIds_ []string
17079 for _, v := range remarketingListIds {
17080 remarketingListIds_ = append(remarketingListIds_, fmt.Sprint(v))
17081 }
17082 c.urlParams_.SetMulti("remarketingListIds", remarketingListIds_)
17083 return c
17084 }
17085
17086
17087
17088
17089
17090
17091
17092
17093 func (c *AdsListCall) SearchString(searchString string) *AdsListCall {
17094 c.urlParams_.Set("searchString", searchString)
17095 return c
17096 }
17097
17098
17099
17100 func (c *AdsListCall) SizeIds(sizeIds ...int64) *AdsListCall {
17101 var sizeIds_ []string
17102 for _, v := range sizeIds {
17103 sizeIds_ = append(sizeIds_, fmt.Sprint(v))
17104 }
17105 c.urlParams_.SetMulti("sizeIds", sizeIds_)
17106 return c
17107 }
17108
17109
17110
17111
17112
17113
17114
17115
17116 func (c *AdsListCall) SortField(sortField string) *AdsListCall {
17117 c.urlParams_.Set("sortField", sortField)
17118 return c
17119 }
17120
17121
17122
17123
17124
17125
17126
17127
17128 func (c *AdsListCall) SortOrder(sortOrder string) *AdsListCall {
17129 c.urlParams_.Set("sortOrder", sortOrder)
17130 return c
17131 }
17132
17133
17134
17135 func (c *AdsListCall) SslCompliant(sslCompliant bool) *AdsListCall {
17136 c.urlParams_.Set("sslCompliant", fmt.Sprint(sslCompliant))
17137 return c
17138 }
17139
17140
17141
17142 func (c *AdsListCall) SslRequired(sslRequired bool) *AdsListCall {
17143 c.urlParams_.Set("sslRequired", fmt.Sprint(sslRequired))
17144 return c
17145 }
17146
17147
17148
17149
17150
17151
17152
17153
17154
17155
17156 func (c *AdsListCall) Type(type_ ...string) *AdsListCall {
17157 c.urlParams_.SetMulti("type", append([]string{}, type_...))
17158 return c
17159 }
17160
17161
17162
17163
17164 func (c *AdsListCall) Fields(s ...googleapi.Field) *AdsListCall {
17165 c.urlParams_.Set("fields", googleapi.CombineFields(s))
17166 return c
17167 }
17168
17169
17170
17171
17172
17173
17174 func (c *AdsListCall) IfNoneMatch(entityTag string) *AdsListCall {
17175 c.ifNoneMatch_ = entityTag
17176 return c
17177 }
17178
17179
17180
17181
17182 func (c *AdsListCall) Context(ctx context.Context) *AdsListCall {
17183 c.ctx_ = ctx
17184 return c
17185 }
17186
17187
17188
17189 func (c *AdsListCall) Header() http.Header {
17190 if c.header_ == nil {
17191 c.header_ = make(http.Header)
17192 }
17193 return c.header_
17194 }
17195
17196 func (c *AdsListCall) doRequest(alt string) (*http.Response, error) {
17197 reqHeaders := make(http.Header)
17198 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
17199 for k, v := range c.header_ {
17200 reqHeaders[k] = v
17201 }
17202 reqHeaders.Set("User-Agent", c.s.userAgent())
17203 if c.ifNoneMatch_ != "" {
17204 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
17205 }
17206 var body io.Reader = nil
17207 c.urlParams_.Set("alt", alt)
17208 c.urlParams_.Set("prettyPrint", "false")
17209 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/ads")
17210 urls += "?" + c.urlParams_.Encode()
17211 req, err := http.NewRequest("GET", urls, body)
17212 if err != nil {
17213 return nil, err
17214 }
17215 req.Header = reqHeaders
17216 googleapi.Expand(req.URL, map[string]string{
17217 "profileId": strconv.FormatInt(c.profileId, 10),
17218 })
17219 return gensupport.SendRequest(c.ctx_, c.s.client, req)
17220 }
17221
17222
17223
17224
17225
17226
17227
17228
17229 func (c *AdsListCall) Do(opts ...googleapi.CallOption) (*AdsListResponse, error) {
17230 gensupport.SetOptions(c.urlParams_, opts...)
17231 res, err := c.doRequest("json")
17232 if res != nil && res.StatusCode == http.StatusNotModified {
17233 if res.Body != nil {
17234 res.Body.Close()
17235 }
17236 return nil, &googleapi.Error{
17237 Code: res.StatusCode,
17238 Header: res.Header,
17239 }
17240 }
17241 if err != nil {
17242 return nil, err
17243 }
17244 defer googleapi.CloseBody(res)
17245 if err := googleapi.CheckResponse(res); err != nil {
17246 return nil, err
17247 }
17248 ret := &AdsListResponse{
17249 ServerResponse: googleapi.ServerResponse{
17250 Header: res.Header,
17251 HTTPStatusCode: res.StatusCode,
17252 },
17253 }
17254 target := &ret
17255 if err := gensupport.DecodeResponse(target, res); err != nil {
17256 return nil, err
17257 }
17258 return ret, nil
17259
17260
17261
17262
17263
17264
17265
17266
17267
17268
17269
17270
17271
17272
17273
17274
17275
17276
17277
17278
17279
17280
17281
17282
17283
17284
17285
17286
17287
17288
17289
17290
17291
17292
17293
17294
17295
17296
17297
17298
17299
17300
17301
17302
17303
17304
17305
17306
17307
17308
17309
17310
17311
17312
17313
17314
17315
17316
17317
17318
17319
17320
17321
17322
17323
17324
17325
17326
17327
17328
17329
17330
17331
17332
17333
17334
17335
17336
17337
17338
17339
17340
17341
17342
17343
17344
17345
17346
17347
17348
17349
17350
17351
17352
17353
17354
17355
17356
17357
17358
17359
17360
17361
17362
17363
17364
17365
17366
17367
17368
17369
17370
17371
17372
17373
17374
17375
17376
17377
17378
17379
17380
17381
17382
17383
17384
17385
17386
17387
17388
17389
17390
17391
17392
17393
17394
17395
17396
17397
17398
17399
17400
17401
17402
17403
17404
17405
17406
17407
17408
17409
17410
17411
17412
17413
17414
17415
17416
17417
17418
17419
17420
17421
17422
17423
17424
17425
17426
17427
17428
17429
17430
17431
17432
17433
17434
17435
17436
17437
17438
17439
17440
17441
17442
17443
17444
17445
17446
17447
17448
17449
17450
17451
17452
17453
17454
17455
17456
17457
17458
17459
17460
17461
17462
17463
17464
17465
17466
17467
17468
17469
17470 }
17471
17472
17473
17474
17475 func (c *AdsListCall) Pages(ctx context.Context, f func(*AdsListResponse) error) error {
17476 c.ctx_ = ctx
17477 defer c.PageToken(c.urlParams_.Get("pageToken"))
17478 for {
17479 x, err := c.Do()
17480 if err != nil {
17481 return err
17482 }
17483 if err := f(x); err != nil {
17484 return err
17485 }
17486 if x.NextPageToken == "" {
17487 return nil
17488 }
17489 c.PageToken(x.NextPageToken)
17490 }
17491 }
17492
17493
17494
17495 type AdsPatchCall struct {
17496 s *Service
17497 profileId int64
17498 ad *Ad
17499 urlParams_ gensupport.URLParams
17500 ctx_ context.Context
17501 header_ http.Header
17502 }
17503
17504
17505 func (r *AdsService) Patch(profileId int64, id int64, ad *Ad) *AdsPatchCall {
17506 c := &AdsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
17507 c.profileId = profileId
17508 c.urlParams_.Set("id", fmt.Sprint(id))
17509 c.ad = ad
17510 return c
17511 }
17512
17513
17514
17515
17516 func (c *AdsPatchCall) Fields(s ...googleapi.Field) *AdsPatchCall {
17517 c.urlParams_.Set("fields", googleapi.CombineFields(s))
17518 return c
17519 }
17520
17521
17522
17523
17524 func (c *AdsPatchCall) Context(ctx context.Context) *AdsPatchCall {
17525 c.ctx_ = ctx
17526 return c
17527 }
17528
17529
17530
17531 func (c *AdsPatchCall) Header() http.Header {
17532 if c.header_ == nil {
17533 c.header_ = make(http.Header)
17534 }
17535 return c.header_
17536 }
17537
17538 func (c *AdsPatchCall) doRequest(alt string) (*http.Response, error) {
17539 reqHeaders := make(http.Header)
17540 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
17541 for k, v := range c.header_ {
17542 reqHeaders[k] = v
17543 }
17544 reqHeaders.Set("User-Agent", c.s.userAgent())
17545 var body io.Reader = nil
17546 body, err := googleapi.WithoutDataWrapper.JSONReader(c.ad)
17547 if err != nil {
17548 return nil, err
17549 }
17550 reqHeaders.Set("Content-Type", "application/json")
17551 c.urlParams_.Set("alt", alt)
17552 c.urlParams_.Set("prettyPrint", "false")
17553 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/ads")
17554 urls += "?" + c.urlParams_.Encode()
17555 req, err := http.NewRequest("PATCH", urls, body)
17556 if err != nil {
17557 return nil, err
17558 }
17559 req.Header = reqHeaders
17560 googleapi.Expand(req.URL, map[string]string{
17561 "profileId": strconv.FormatInt(c.profileId, 10),
17562 })
17563 return gensupport.SendRequest(c.ctx_, c.s.client, req)
17564 }
17565
17566
17567
17568
17569
17570
17571
17572
17573 func (c *AdsPatchCall) Do(opts ...googleapi.CallOption) (*Ad, error) {
17574 gensupport.SetOptions(c.urlParams_, opts...)
17575 res, err := c.doRequest("json")
17576 if res != nil && res.StatusCode == http.StatusNotModified {
17577 if res.Body != nil {
17578 res.Body.Close()
17579 }
17580 return nil, &googleapi.Error{
17581 Code: res.StatusCode,
17582 Header: res.Header,
17583 }
17584 }
17585 if err != nil {
17586 return nil, err
17587 }
17588 defer googleapi.CloseBody(res)
17589 if err := googleapi.CheckResponse(res); err != nil {
17590 return nil, err
17591 }
17592 ret := &Ad{
17593 ServerResponse: googleapi.ServerResponse{
17594 Header: res.Header,
17595 HTTPStatusCode: res.StatusCode,
17596 },
17597 }
17598 target := &ret
17599 if err := gensupport.DecodeResponse(target, res); err != nil {
17600 return nil, err
17601 }
17602 return ret, nil
17603
17604
17605
17606
17607
17608
17609
17610
17611
17612
17613
17614
17615
17616
17617
17618
17619
17620
17621
17622
17623
17624
17625
17626
17627
17628
17629
17630
17631
17632
17633
17634
17635
17636
17637
17638
17639 }
17640
17641
17642
17643 type AdsUpdateCall struct {
17644 s *Service
17645 profileId int64
17646 ad *Ad
17647 urlParams_ gensupport.URLParams
17648 ctx_ context.Context
17649 header_ http.Header
17650 }
17651
17652
17653 func (r *AdsService) Update(profileId int64, ad *Ad) *AdsUpdateCall {
17654 c := &AdsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
17655 c.profileId = profileId
17656 c.ad = ad
17657 return c
17658 }
17659
17660
17661
17662
17663 func (c *AdsUpdateCall) Fields(s ...googleapi.Field) *AdsUpdateCall {
17664 c.urlParams_.Set("fields", googleapi.CombineFields(s))
17665 return c
17666 }
17667
17668
17669
17670
17671 func (c *AdsUpdateCall) Context(ctx context.Context) *AdsUpdateCall {
17672 c.ctx_ = ctx
17673 return c
17674 }
17675
17676
17677
17678 func (c *AdsUpdateCall) Header() http.Header {
17679 if c.header_ == nil {
17680 c.header_ = make(http.Header)
17681 }
17682 return c.header_
17683 }
17684
17685 func (c *AdsUpdateCall) doRequest(alt string) (*http.Response, error) {
17686 reqHeaders := make(http.Header)
17687 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
17688 for k, v := range c.header_ {
17689 reqHeaders[k] = v
17690 }
17691 reqHeaders.Set("User-Agent", c.s.userAgent())
17692 var body io.Reader = nil
17693 body, err := googleapi.WithoutDataWrapper.JSONReader(c.ad)
17694 if err != nil {
17695 return nil, err
17696 }
17697 reqHeaders.Set("Content-Type", "application/json")
17698 c.urlParams_.Set("alt", alt)
17699 c.urlParams_.Set("prettyPrint", "false")
17700 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/ads")
17701 urls += "?" + c.urlParams_.Encode()
17702 req, err := http.NewRequest("PUT", urls, body)
17703 if err != nil {
17704 return nil, err
17705 }
17706 req.Header = reqHeaders
17707 googleapi.Expand(req.URL, map[string]string{
17708 "profileId": strconv.FormatInt(c.profileId, 10),
17709 })
17710 return gensupport.SendRequest(c.ctx_, c.s.client, req)
17711 }
17712
17713
17714
17715
17716
17717
17718
17719
17720 func (c *AdsUpdateCall) Do(opts ...googleapi.CallOption) (*Ad, error) {
17721 gensupport.SetOptions(c.urlParams_, opts...)
17722 res, err := c.doRequest("json")
17723 if res != nil && res.StatusCode == http.StatusNotModified {
17724 if res.Body != nil {
17725 res.Body.Close()
17726 }
17727 return nil, &googleapi.Error{
17728 Code: res.StatusCode,
17729 Header: res.Header,
17730 }
17731 }
17732 if err != nil {
17733 return nil, err
17734 }
17735 defer googleapi.CloseBody(res)
17736 if err := googleapi.CheckResponse(res); err != nil {
17737 return nil, err
17738 }
17739 ret := &Ad{
17740 ServerResponse: googleapi.ServerResponse{
17741 Header: res.Header,
17742 HTTPStatusCode: res.StatusCode,
17743 },
17744 }
17745 target := &ret
17746 if err := gensupport.DecodeResponse(target, res); err != nil {
17747 return nil, err
17748 }
17749 return ret, nil
17750
17751
17752
17753
17754
17755
17756
17757
17758
17759
17760
17761
17762
17763
17764
17765
17766
17767
17768
17769
17770
17771
17772
17773
17774
17775
17776
17777
17778 }
17779
17780
17781
17782 type AdvertiserGroupsDeleteCall struct {
17783 s *Service
17784 profileId int64
17785 id int64
17786 urlParams_ gensupport.URLParams
17787 ctx_ context.Context
17788 header_ http.Header
17789 }
17790
17791
17792 func (r *AdvertiserGroupsService) Delete(profileId int64, id int64) *AdvertiserGroupsDeleteCall {
17793 c := &AdvertiserGroupsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
17794 c.profileId = profileId
17795 c.id = id
17796 return c
17797 }
17798
17799
17800
17801
17802 func (c *AdvertiserGroupsDeleteCall) Fields(s ...googleapi.Field) *AdvertiserGroupsDeleteCall {
17803 c.urlParams_.Set("fields", googleapi.CombineFields(s))
17804 return c
17805 }
17806
17807
17808
17809
17810 func (c *AdvertiserGroupsDeleteCall) Context(ctx context.Context) *AdvertiserGroupsDeleteCall {
17811 c.ctx_ = ctx
17812 return c
17813 }
17814
17815
17816
17817 func (c *AdvertiserGroupsDeleteCall) Header() http.Header {
17818 if c.header_ == nil {
17819 c.header_ = make(http.Header)
17820 }
17821 return c.header_
17822 }
17823
17824 func (c *AdvertiserGroupsDeleteCall) doRequest(alt string) (*http.Response, error) {
17825 reqHeaders := make(http.Header)
17826 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
17827 for k, v := range c.header_ {
17828 reqHeaders[k] = v
17829 }
17830 reqHeaders.Set("User-Agent", c.s.userAgent())
17831 var body io.Reader = nil
17832 c.urlParams_.Set("alt", alt)
17833 c.urlParams_.Set("prettyPrint", "false")
17834 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/advertiserGroups/{id}")
17835 urls += "?" + c.urlParams_.Encode()
17836 req, err := http.NewRequest("DELETE", urls, body)
17837 if err != nil {
17838 return nil, err
17839 }
17840 req.Header = reqHeaders
17841 googleapi.Expand(req.URL, map[string]string{
17842 "profileId": strconv.FormatInt(c.profileId, 10),
17843 "id": strconv.FormatInt(c.id, 10),
17844 })
17845 return gensupport.SendRequest(c.ctx_, c.s.client, req)
17846 }
17847
17848
17849 func (c *AdvertiserGroupsDeleteCall) Do(opts ...googleapi.CallOption) error {
17850 gensupport.SetOptions(c.urlParams_, opts...)
17851 res, err := c.doRequest("json")
17852 if err != nil {
17853 return err
17854 }
17855 defer googleapi.CloseBody(res)
17856 if err := googleapi.CheckResponse(res); err != nil {
17857 return err
17858 }
17859 return nil
17860
17861
17862
17863
17864
17865
17866
17867
17868
17869
17870
17871
17872
17873
17874
17875
17876
17877
17878
17879
17880
17881
17882
17883
17884
17885
17886
17887
17888
17889
17890 }
17891
17892
17893
17894 type AdvertiserGroupsGetCall struct {
17895 s *Service
17896 profileId int64
17897 id int64
17898 urlParams_ gensupport.URLParams
17899 ifNoneMatch_ string
17900 ctx_ context.Context
17901 header_ http.Header
17902 }
17903
17904
17905 func (r *AdvertiserGroupsService) Get(profileId int64, id int64) *AdvertiserGroupsGetCall {
17906 c := &AdvertiserGroupsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
17907 c.profileId = profileId
17908 c.id = id
17909 return c
17910 }
17911
17912
17913
17914
17915 func (c *AdvertiserGroupsGetCall) Fields(s ...googleapi.Field) *AdvertiserGroupsGetCall {
17916 c.urlParams_.Set("fields", googleapi.CombineFields(s))
17917 return c
17918 }
17919
17920
17921
17922
17923
17924
17925 func (c *AdvertiserGroupsGetCall) IfNoneMatch(entityTag string) *AdvertiserGroupsGetCall {
17926 c.ifNoneMatch_ = entityTag
17927 return c
17928 }
17929
17930
17931
17932
17933 func (c *AdvertiserGroupsGetCall) Context(ctx context.Context) *AdvertiserGroupsGetCall {
17934 c.ctx_ = ctx
17935 return c
17936 }
17937
17938
17939
17940 func (c *AdvertiserGroupsGetCall) Header() http.Header {
17941 if c.header_ == nil {
17942 c.header_ = make(http.Header)
17943 }
17944 return c.header_
17945 }
17946
17947 func (c *AdvertiserGroupsGetCall) doRequest(alt string) (*http.Response, error) {
17948 reqHeaders := make(http.Header)
17949 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
17950 for k, v := range c.header_ {
17951 reqHeaders[k] = v
17952 }
17953 reqHeaders.Set("User-Agent", c.s.userAgent())
17954 if c.ifNoneMatch_ != "" {
17955 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
17956 }
17957 var body io.Reader = nil
17958 c.urlParams_.Set("alt", alt)
17959 c.urlParams_.Set("prettyPrint", "false")
17960 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/advertiserGroups/{id}")
17961 urls += "?" + c.urlParams_.Encode()
17962 req, err := http.NewRequest("GET", urls, body)
17963 if err != nil {
17964 return nil, err
17965 }
17966 req.Header = reqHeaders
17967 googleapi.Expand(req.URL, map[string]string{
17968 "profileId": strconv.FormatInt(c.profileId, 10),
17969 "id": strconv.FormatInt(c.id, 10),
17970 })
17971 return gensupport.SendRequest(c.ctx_, c.s.client, req)
17972 }
17973
17974
17975
17976
17977
17978
17979
17980
17981 func (c *AdvertiserGroupsGetCall) Do(opts ...googleapi.CallOption) (*AdvertiserGroup, error) {
17982 gensupport.SetOptions(c.urlParams_, opts...)
17983 res, err := c.doRequest("json")
17984 if res != nil && res.StatusCode == http.StatusNotModified {
17985 if res.Body != nil {
17986 res.Body.Close()
17987 }
17988 return nil, &googleapi.Error{
17989 Code: res.StatusCode,
17990 Header: res.Header,
17991 }
17992 }
17993 if err != nil {
17994 return nil, err
17995 }
17996 defer googleapi.CloseBody(res)
17997 if err := googleapi.CheckResponse(res); err != nil {
17998 return nil, err
17999 }
18000 ret := &AdvertiserGroup{
18001 ServerResponse: googleapi.ServerResponse{
18002 Header: res.Header,
18003 HTTPStatusCode: res.StatusCode,
18004 },
18005 }
18006 target := &ret
18007 if err := gensupport.DecodeResponse(target, res); err != nil {
18008 return nil, err
18009 }
18010 return ret, nil
18011
18012
18013
18014
18015
18016
18017
18018
18019
18020
18021
18022
18023
18024
18025
18026
18027
18028
18029
18030
18031
18032
18033
18034
18035
18036
18037
18038
18039
18040
18041
18042
18043
18044 }
18045
18046
18047
18048 type AdvertiserGroupsInsertCall struct {
18049 s *Service
18050 profileId int64
18051 advertisergroup *AdvertiserGroup
18052 urlParams_ gensupport.URLParams
18053 ctx_ context.Context
18054 header_ http.Header
18055 }
18056
18057
18058 func (r *AdvertiserGroupsService) Insert(profileId int64, advertisergroup *AdvertiserGroup) *AdvertiserGroupsInsertCall {
18059 c := &AdvertiserGroupsInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
18060 c.profileId = profileId
18061 c.advertisergroup = advertisergroup
18062 return c
18063 }
18064
18065
18066
18067
18068 func (c *AdvertiserGroupsInsertCall) Fields(s ...googleapi.Field) *AdvertiserGroupsInsertCall {
18069 c.urlParams_.Set("fields", googleapi.CombineFields(s))
18070 return c
18071 }
18072
18073
18074
18075
18076 func (c *AdvertiserGroupsInsertCall) Context(ctx context.Context) *AdvertiserGroupsInsertCall {
18077 c.ctx_ = ctx
18078 return c
18079 }
18080
18081
18082
18083 func (c *AdvertiserGroupsInsertCall) Header() http.Header {
18084 if c.header_ == nil {
18085 c.header_ = make(http.Header)
18086 }
18087 return c.header_
18088 }
18089
18090 func (c *AdvertiserGroupsInsertCall) doRequest(alt string) (*http.Response, error) {
18091 reqHeaders := make(http.Header)
18092 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
18093 for k, v := range c.header_ {
18094 reqHeaders[k] = v
18095 }
18096 reqHeaders.Set("User-Agent", c.s.userAgent())
18097 var body io.Reader = nil
18098 body, err := googleapi.WithoutDataWrapper.JSONReader(c.advertisergroup)
18099 if err != nil {
18100 return nil, err
18101 }
18102 reqHeaders.Set("Content-Type", "application/json")
18103 c.urlParams_.Set("alt", alt)
18104 c.urlParams_.Set("prettyPrint", "false")
18105 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/advertiserGroups")
18106 urls += "?" + c.urlParams_.Encode()
18107 req, err := http.NewRequest("POST", urls, body)
18108 if err != nil {
18109 return nil, err
18110 }
18111 req.Header = reqHeaders
18112 googleapi.Expand(req.URL, map[string]string{
18113 "profileId": strconv.FormatInt(c.profileId, 10),
18114 })
18115 return gensupport.SendRequest(c.ctx_, c.s.client, req)
18116 }
18117
18118
18119
18120
18121
18122
18123
18124
18125 func (c *AdvertiserGroupsInsertCall) Do(opts ...googleapi.CallOption) (*AdvertiserGroup, error) {
18126 gensupport.SetOptions(c.urlParams_, opts...)
18127 res, err := c.doRequest("json")
18128 if res != nil && res.StatusCode == http.StatusNotModified {
18129 if res.Body != nil {
18130 res.Body.Close()
18131 }
18132 return nil, &googleapi.Error{
18133 Code: res.StatusCode,
18134 Header: res.Header,
18135 }
18136 }
18137 if err != nil {
18138 return nil, err
18139 }
18140 defer googleapi.CloseBody(res)
18141 if err := googleapi.CheckResponse(res); err != nil {
18142 return nil, err
18143 }
18144 ret := &AdvertiserGroup{
18145 ServerResponse: googleapi.ServerResponse{
18146 Header: res.Header,
18147 HTTPStatusCode: res.StatusCode,
18148 },
18149 }
18150 target := &ret
18151 if err := gensupport.DecodeResponse(target, res); err != nil {
18152 return nil, err
18153 }
18154 return ret, nil
18155
18156
18157
18158
18159
18160
18161
18162
18163
18164
18165
18166
18167
18168
18169
18170
18171
18172
18173
18174
18175
18176
18177
18178
18179
18180
18181
18182
18183 }
18184
18185
18186
18187 type AdvertiserGroupsListCall struct {
18188 s *Service
18189 profileId int64
18190 urlParams_ gensupport.URLParams
18191 ifNoneMatch_ string
18192 ctx_ context.Context
18193 header_ http.Header
18194 }
18195
18196
18197
18198 func (r *AdvertiserGroupsService) List(profileId int64) *AdvertiserGroupsListCall {
18199 c := &AdvertiserGroupsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
18200 c.profileId = profileId
18201 return c
18202 }
18203
18204
18205
18206 func (c *AdvertiserGroupsListCall) Ids(ids ...int64) *AdvertiserGroupsListCall {
18207 var ids_ []string
18208 for _, v := range ids {
18209 ids_ = append(ids_, fmt.Sprint(v))
18210 }
18211 c.urlParams_.SetMulti("ids", ids_)
18212 return c
18213 }
18214
18215
18216
18217 func (c *AdvertiserGroupsListCall) MaxResults(maxResults int64) *AdvertiserGroupsListCall {
18218 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
18219 return c
18220 }
18221
18222
18223
18224 func (c *AdvertiserGroupsListCall) PageToken(pageToken string) *AdvertiserGroupsListCall {
18225 c.urlParams_.Set("pageToken", pageToken)
18226 return c
18227 }
18228
18229
18230
18231
18232
18233
18234
18235
18236
18237
18238 func (c *AdvertiserGroupsListCall) SearchString(searchString string) *AdvertiserGroupsListCall {
18239 c.urlParams_.Set("searchString", searchString)
18240 return c
18241 }
18242
18243
18244
18245
18246
18247
18248
18249
18250 func (c *AdvertiserGroupsListCall) SortField(sortField string) *AdvertiserGroupsListCall {
18251 c.urlParams_.Set("sortField", sortField)
18252 return c
18253 }
18254
18255
18256
18257
18258
18259
18260
18261
18262 func (c *AdvertiserGroupsListCall) SortOrder(sortOrder string) *AdvertiserGroupsListCall {
18263 c.urlParams_.Set("sortOrder", sortOrder)
18264 return c
18265 }
18266
18267
18268
18269
18270 func (c *AdvertiserGroupsListCall) Fields(s ...googleapi.Field) *AdvertiserGroupsListCall {
18271 c.urlParams_.Set("fields", googleapi.CombineFields(s))
18272 return c
18273 }
18274
18275
18276
18277
18278
18279
18280 func (c *AdvertiserGroupsListCall) IfNoneMatch(entityTag string) *AdvertiserGroupsListCall {
18281 c.ifNoneMatch_ = entityTag
18282 return c
18283 }
18284
18285
18286
18287
18288 func (c *AdvertiserGroupsListCall) Context(ctx context.Context) *AdvertiserGroupsListCall {
18289 c.ctx_ = ctx
18290 return c
18291 }
18292
18293
18294
18295 func (c *AdvertiserGroupsListCall) Header() http.Header {
18296 if c.header_ == nil {
18297 c.header_ = make(http.Header)
18298 }
18299 return c.header_
18300 }
18301
18302 func (c *AdvertiserGroupsListCall) doRequest(alt string) (*http.Response, error) {
18303 reqHeaders := make(http.Header)
18304 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
18305 for k, v := range c.header_ {
18306 reqHeaders[k] = v
18307 }
18308 reqHeaders.Set("User-Agent", c.s.userAgent())
18309 if c.ifNoneMatch_ != "" {
18310 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
18311 }
18312 var body io.Reader = nil
18313 c.urlParams_.Set("alt", alt)
18314 c.urlParams_.Set("prettyPrint", "false")
18315 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/advertiserGroups")
18316 urls += "?" + c.urlParams_.Encode()
18317 req, err := http.NewRequest("GET", urls, body)
18318 if err != nil {
18319 return nil, err
18320 }
18321 req.Header = reqHeaders
18322 googleapi.Expand(req.URL, map[string]string{
18323 "profileId": strconv.FormatInt(c.profileId, 10),
18324 })
18325 return gensupport.SendRequest(c.ctx_, c.s.client, req)
18326 }
18327
18328
18329
18330
18331
18332
18333
18334
18335 func (c *AdvertiserGroupsListCall) Do(opts ...googleapi.CallOption) (*AdvertiserGroupsListResponse, error) {
18336 gensupport.SetOptions(c.urlParams_, opts...)
18337 res, err := c.doRequest("json")
18338 if res != nil && res.StatusCode == http.StatusNotModified {
18339 if res.Body != nil {
18340 res.Body.Close()
18341 }
18342 return nil, &googleapi.Error{
18343 Code: res.StatusCode,
18344 Header: res.Header,
18345 }
18346 }
18347 if err != nil {
18348 return nil, err
18349 }
18350 defer googleapi.CloseBody(res)
18351 if err := googleapi.CheckResponse(res); err != nil {
18352 return nil, err
18353 }
18354 ret := &AdvertiserGroupsListResponse{
18355 ServerResponse: googleapi.ServerResponse{
18356 Header: res.Header,
18357 HTTPStatusCode: res.StatusCode,
18358 },
18359 }
18360 target := &ret
18361 if err := gensupport.DecodeResponse(target, res); err != nil {
18362 return nil, err
18363 }
18364 return ret, nil
18365
18366
18367
18368
18369
18370
18371
18372
18373
18374
18375
18376
18377
18378
18379
18380
18381
18382
18383
18384
18385
18386
18387
18388
18389
18390
18391
18392
18393
18394
18395
18396
18397
18398
18399
18400
18401
18402
18403
18404
18405
18406
18407
18408
18409
18410
18411
18412
18413
18414
18415
18416
18417
18418
18419
18420
18421
18422
18423
18424
18425
18426
18427
18428
18429
18430
18431
18432
18433
18434
18435
18436
18437
18438
18439
18440
18441
18442
18443
18444 }
18445
18446
18447
18448
18449 func (c *AdvertiserGroupsListCall) Pages(ctx context.Context, f func(*AdvertiserGroupsListResponse) error) error {
18450 c.ctx_ = ctx
18451 defer c.PageToken(c.urlParams_.Get("pageToken"))
18452 for {
18453 x, err := c.Do()
18454 if err != nil {
18455 return err
18456 }
18457 if err := f(x); err != nil {
18458 return err
18459 }
18460 if x.NextPageToken == "" {
18461 return nil
18462 }
18463 c.PageToken(x.NextPageToken)
18464 }
18465 }
18466
18467
18468
18469 type AdvertiserGroupsPatchCall struct {
18470 s *Service
18471 profileId int64
18472 advertisergroup *AdvertiserGroup
18473 urlParams_ gensupport.URLParams
18474 ctx_ context.Context
18475 header_ http.Header
18476 }
18477
18478
18479
18480 func (r *AdvertiserGroupsService) Patch(profileId int64, id int64, advertisergroup *AdvertiserGroup) *AdvertiserGroupsPatchCall {
18481 c := &AdvertiserGroupsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
18482 c.profileId = profileId
18483 c.urlParams_.Set("id", fmt.Sprint(id))
18484 c.advertisergroup = advertisergroup
18485 return c
18486 }
18487
18488
18489
18490
18491 func (c *AdvertiserGroupsPatchCall) Fields(s ...googleapi.Field) *AdvertiserGroupsPatchCall {
18492 c.urlParams_.Set("fields", googleapi.CombineFields(s))
18493 return c
18494 }
18495
18496
18497
18498
18499 func (c *AdvertiserGroupsPatchCall) Context(ctx context.Context) *AdvertiserGroupsPatchCall {
18500 c.ctx_ = ctx
18501 return c
18502 }
18503
18504
18505
18506 func (c *AdvertiserGroupsPatchCall) Header() http.Header {
18507 if c.header_ == nil {
18508 c.header_ = make(http.Header)
18509 }
18510 return c.header_
18511 }
18512
18513 func (c *AdvertiserGroupsPatchCall) doRequest(alt string) (*http.Response, error) {
18514 reqHeaders := make(http.Header)
18515 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
18516 for k, v := range c.header_ {
18517 reqHeaders[k] = v
18518 }
18519 reqHeaders.Set("User-Agent", c.s.userAgent())
18520 var body io.Reader = nil
18521 body, err := googleapi.WithoutDataWrapper.JSONReader(c.advertisergroup)
18522 if err != nil {
18523 return nil, err
18524 }
18525 reqHeaders.Set("Content-Type", "application/json")
18526 c.urlParams_.Set("alt", alt)
18527 c.urlParams_.Set("prettyPrint", "false")
18528 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/advertiserGroups")
18529 urls += "?" + c.urlParams_.Encode()
18530 req, err := http.NewRequest("PATCH", urls, body)
18531 if err != nil {
18532 return nil, err
18533 }
18534 req.Header = reqHeaders
18535 googleapi.Expand(req.URL, map[string]string{
18536 "profileId": strconv.FormatInt(c.profileId, 10),
18537 })
18538 return gensupport.SendRequest(c.ctx_, c.s.client, req)
18539 }
18540
18541
18542
18543
18544
18545
18546
18547
18548 func (c *AdvertiserGroupsPatchCall) Do(opts ...googleapi.CallOption) (*AdvertiserGroup, error) {
18549 gensupport.SetOptions(c.urlParams_, opts...)
18550 res, err := c.doRequest("json")
18551 if res != nil && res.StatusCode == http.StatusNotModified {
18552 if res.Body != nil {
18553 res.Body.Close()
18554 }
18555 return nil, &googleapi.Error{
18556 Code: res.StatusCode,
18557 Header: res.Header,
18558 }
18559 }
18560 if err != nil {
18561 return nil, err
18562 }
18563 defer googleapi.CloseBody(res)
18564 if err := googleapi.CheckResponse(res); err != nil {
18565 return nil, err
18566 }
18567 ret := &AdvertiserGroup{
18568 ServerResponse: googleapi.ServerResponse{
18569 Header: res.Header,
18570 HTTPStatusCode: res.StatusCode,
18571 },
18572 }
18573 target := &ret
18574 if err := gensupport.DecodeResponse(target, res); err != nil {
18575 return nil, err
18576 }
18577 return ret, nil
18578
18579
18580
18581
18582
18583
18584
18585
18586
18587
18588
18589
18590
18591
18592
18593
18594
18595
18596
18597
18598
18599
18600
18601
18602
18603
18604
18605
18606
18607
18608
18609
18610
18611
18612
18613
18614 }
18615
18616
18617
18618 type AdvertiserGroupsUpdateCall struct {
18619 s *Service
18620 profileId int64
18621 advertisergroup *AdvertiserGroup
18622 urlParams_ gensupport.URLParams
18623 ctx_ context.Context
18624 header_ http.Header
18625 }
18626
18627
18628 func (r *AdvertiserGroupsService) Update(profileId int64, advertisergroup *AdvertiserGroup) *AdvertiserGroupsUpdateCall {
18629 c := &AdvertiserGroupsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
18630 c.profileId = profileId
18631 c.advertisergroup = advertisergroup
18632 return c
18633 }
18634
18635
18636
18637
18638 func (c *AdvertiserGroupsUpdateCall) Fields(s ...googleapi.Field) *AdvertiserGroupsUpdateCall {
18639 c.urlParams_.Set("fields", googleapi.CombineFields(s))
18640 return c
18641 }
18642
18643
18644
18645
18646 func (c *AdvertiserGroupsUpdateCall) Context(ctx context.Context) *AdvertiserGroupsUpdateCall {
18647 c.ctx_ = ctx
18648 return c
18649 }
18650
18651
18652
18653 func (c *AdvertiserGroupsUpdateCall) Header() http.Header {
18654 if c.header_ == nil {
18655 c.header_ = make(http.Header)
18656 }
18657 return c.header_
18658 }
18659
18660 func (c *AdvertiserGroupsUpdateCall) doRequest(alt string) (*http.Response, error) {
18661 reqHeaders := make(http.Header)
18662 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
18663 for k, v := range c.header_ {
18664 reqHeaders[k] = v
18665 }
18666 reqHeaders.Set("User-Agent", c.s.userAgent())
18667 var body io.Reader = nil
18668 body, err := googleapi.WithoutDataWrapper.JSONReader(c.advertisergroup)
18669 if err != nil {
18670 return nil, err
18671 }
18672 reqHeaders.Set("Content-Type", "application/json")
18673 c.urlParams_.Set("alt", alt)
18674 c.urlParams_.Set("prettyPrint", "false")
18675 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/advertiserGroups")
18676 urls += "?" + c.urlParams_.Encode()
18677 req, err := http.NewRequest("PUT", urls, body)
18678 if err != nil {
18679 return nil, err
18680 }
18681 req.Header = reqHeaders
18682 googleapi.Expand(req.URL, map[string]string{
18683 "profileId": strconv.FormatInt(c.profileId, 10),
18684 })
18685 return gensupport.SendRequest(c.ctx_, c.s.client, req)
18686 }
18687
18688
18689
18690
18691
18692
18693
18694
18695 func (c *AdvertiserGroupsUpdateCall) Do(opts ...googleapi.CallOption) (*AdvertiserGroup, error) {
18696 gensupport.SetOptions(c.urlParams_, opts...)
18697 res, err := c.doRequest("json")
18698 if res != nil && res.StatusCode == http.StatusNotModified {
18699 if res.Body != nil {
18700 res.Body.Close()
18701 }
18702 return nil, &googleapi.Error{
18703 Code: res.StatusCode,
18704 Header: res.Header,
18705 }
18706 }
18707 if err != nil {
18708 return nil, err
18709 }
18710 defer googleapi.CloseBody(res)
18711 if err := googleapi.CheckResponse(res); err != nil {
18712 return nil, err
18713 }
18714 ret := &AdvertiserGroup{
18715 ServerResponse: googleapi.ServerResponse{
18716 Header: res.Header,
18717 HTTPStatusCode: res.StatusCode,
18718 },
18719 }
18720 target := &ret
18721 if err := gensupport.DecodeResponse(target, res); err != nil {
18722 return nil, err
18723 }
18724 return ret, nil
18725
18726
18727
18728
18729
18730
18731
18732
18733
18734
18735
18736
18737
18738
18739
18740
18741
18742
18743
18744
18745
18746
18747
18748
18749
18750
18751
18752
18753 }
18754
18755
18756
18757 type AdvertiserLandingPagesGetCall struct {
18758 s *Service
18759 profileId int64
18760 id int64
18761 urlParams_ gensupport.URLParams
18762 ifNoneMatch_ string
18763 ctx_ context.Context
18764 header_ http.Header
18765 }
18766
18767
18768 func (r *AdvertiserLandingPagesService) Get(profileId int64, id int64) *AdvertiserLandingPagesGetCall {
18769 c := &AdvertiserLandingPagesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
18770 c.profileId = profileId
18771 c.id = id
18772 return c
18773 }
18774
18775
18776
18777
18778 func (c *AdvertiserLandingPagesGetCall) Fields(s ...googleapi.Field) *AdvertiserLandingPagesGetCall {
18779 c.urlParams_.Set("fields", googleapi.CombineFields(s))
18780 return c
18781 }
18782
18783
18784
18785
18786
18787
18788 func (c *AdvertiserLandingPagesGetCall) IfNoneMatch(entityTag string) *AdvertiserLandingPagesGetCall {
18789 c.ifNoneMatch_ = entityTag
18790 return c
18791 }
18792
18793
18794
18795
18796 func (c *AdvertiserLandingPagesGetCall) Context(ctx context.Context) *AdvertiserLandingPagesGetCall {
18797 c.ctx_ = ctx
18798 return c
18799 }
18800
18801
18802
18803 func (c *AdvertiserLandingPagesGetCall) Header() http.Header {
18804 if c.header_ == nil {
18805 c.header_ = make(http.Header)
18806 }
18807 return c.header_
18808 }
18809
18810 func (c *AdvertiserLandingPagesGetCall) doRequest(alt string) (*http.Response, error) {
18811 reqHeaders := make(http.Header)
18812 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
18813 for k, v := range c.header_ {
18814 reqHeaders[k] = v
18815 }
18816 reqHeaders.Set("User-Agent", c.s.userAgent())
18817 if c.ifNoneMatch_ != "" {
18818 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
18819 }
18820 var body io.Reader = nil
18821 c.urlParams_.Set("alt", alt)
18822 c.urlParams_.Set("prettyPrint", "false")
18823 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/advertiserLandingPages/{id}")
18824 urls += "?" + c.urlParams_.Encode()
18825 req, err := http.NewRequest("GET", urls, body)
18826 if err != nil {
18827 return nil, err
18828 }
18829 req.Header = reqHeaders
18830 googleapi.Expand(req.URL, map[string]string{
18831 "profileId": strconv.FormatInt(c.profileId, 10),
18832 "id": strconv.FormatInt(c.id, 10),
18833 })
18834 return gensupport.SendRequest(c.ctx_, c.s.client, req)
18835 }
18836
18837
18838
18839
18840
18841
18842
18843
18844 func (c *AdvertiserLandingPagesGetCall) Do(opts ...googleapi.CallOption) (*LandingPage, error) {
18845 gensupport.SetOptions(c.urlParams_, opts...)
18846 res, err := c.doRequest("json")
18847 if res != nil && res.StatusCode == http.StatusNotModified {
18848 if res.Body != nil {
18849 res.Body.Close()
18850 }
18851 return nil, &googleapi.Error{
18852 Code: res.StatusCode,
18853 Header: res.Header,
18854 }
18855 }
18856 if err != nil {
18857 return nil, err
18858 }
18859 defer googleapi.CloseBody(res)
18860 if err := googleapi.CheckResponse(res); err != nil {
18861 return nil, err
18862 }
18863 ret := &LandingPage{
18864 ServerResponse: googleapi.ServerResponse{
18865 Header: res.Header,
18866 HTTPStatusCode: res.StatusCode,
18867 },
18868 }
18869 target := &ret
18870 if err := gensupport.DecodeResponse(target, res); err != nil {
18871 return nil, err
18872 }
18873 return ret, nil
18874
18875
18876
18877
18878
18879
18880
18881
18882
18883
18884
18885
18886
18887
18888
18889
18890
18891
18892
18893
18894
18895
18896
18897
18898
18899
18900
18901
18902
18903
18904
18905
18906
18907 }
18908
18909
18910
18911 type AdvertiserLandingPagesInsertCall struct {
18912 s *Service
18913 profileId int64
18914 landingpage *LandingPage
18915 urlParams_ gensupport.URLParams
18916 ctx_ context.Context
18917 header_ http.Header
18918 }
18919
18920
18921 func (r *AdvertiserLandingPagesService) Insert(profileId int64, landingpage *LandingPage) *AdvertiserLandingPagesInsertCall {
18922 c := &AdvertiserLandingPagesInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
18923 c.profileId = profileId
18924 c.landingpage = landingpage
18925 return c
18926 }
18927
18928
18929
18930
18931 func (c *AdvertiserLandingPagesInsertCall) Fields(s ...googleapi.Field) *AdvertiserLandingPagesInsertCall {
18932 c.urlParams_.Set("fields", googleapi.CombineFields(s))
18933 return c
18934 }
18935
18936
18937
18938
18939 func (c *AdvertiserLandingPagesInsertCall) Context(ctx context.Context) *AdvertiserLandingPagesInsertCall {
18940 c.ctx_ = ctx
18941 return c
18942 }
18943
18944
18945
18946 func (c *AdvertiserLandingPagesInsertCall) Header() http.Header {
18947 if c.header_ == nil {
18948 c.header_ = make(http.Header)
18949 }
18950 return c.header_
18951 }
18952
18953 func (c *AdvertiserLandingPagesInsertCall) doRequest(alt string) (*http.Response, error) {
18954 reqHeaders := make(http.Header)
18955 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
18956 for k, v := range c.header_ {
18957 reqHeaders[k] = v
18958 }
18959 reqHeaders.Set("User-Agent", c.s.userAgent())
18960 var body io.Reader = nil
18961 body, err := googleapi.WithoutDataWrapper.JSONReader(c.landingpage)
18962 if err != nil {
18963 return nil, err
18964 }
18965 reqHeaders.Set("Content-Type", "application/json")
18966 c.urlParams_.Set("alt", alt)
18967 c.urlParams_.Set("prettyPrint", "false")
18968 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/advertiserLandingPages")
18969 urls += "?" + c.urlParams_.Encode()
18970 req, err := http.NewRequest("POST", urls, body)
18971 if err != nil {
18972 return nil, err
18973 }
18974 req.Header = reqHeaders
18975 googleapi.Expand(req.URL, map[string]string{
18976 "profileId": strconv.FormatInt(c.profileId, 10),
18977 })
18978 return gensupport.SendRequest(c.ctx_, c.s.client, req)
18979 }
18980
18981
18982
18983
18984
18985
18986
18987
18988 func (c *AdvertiserLandingPagesInsertCall) Do(opts ...googleapi.CallOption) (*LandingPage, error) {
18989 gensupport.SetOptions(c.urlParams_, opts...)
18990 res, err := c.doRequest("json")
18991 if res != nil && res.StatusCode == http.StatusNotModified {
18992 if res.Body != nil {
18993 res.Body.Close()
18994 }
18995 return nil, &googleapi.Error{
18996 Code: res.StatusCode,
18997 Header: res.Header,
18998 }
18999 }
19000 if err != nil {
19001 return nil, err
19002 }
19003 defer googleapi.CloseBody(res)
19004 if err := googleapi.CheckResponse(res); err != nil {
19005 return nil, err
19006 }
19007 ret := &LandingPage{
19008 ServerResponse: googleapi.ServerResponse{
19009 Header: res.Header,
19010 HTTPStatusCode: res.StatusCode,
19011 },
19012 }
19013 target := &ret
19014 if err := gensupport.DecodeResponse(target, res); err != nil {
19015 return nil, err
19016 }
19017 return ret, nil
19018
19019
19020
19021
19022
19023
19024
19025
19026
19027
19028
19029
19030
19031
19032
19033
19034
19035
19036
19037
19038
19039
19040
19041
19042
19043
19044
19045
19046 }
19047
19048
19049
19050 type AdvertiserLandingPagesListCall struct {
19051 s *Service
19052 profileId int64
19053 urlParams_ gensupport.URLParams
19054 ifNoneMatch_ string
19055 ctx_ context.Context
19056 header_ http.Header
19057 }
19058
19059
19060 func (r *AdvertiserLandingPagesService) List(profileId int64) *AdvertiserLandingPagesListCall {
19061 c := &AdvertiserLandingPagesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
19062 c.profileId = profileId
19063 return c
19064 }
19065
19066
19067
19068 func (c *AdvertiserLandingPagesListCall) AdvertiserIds(advertiserIds ...int64) *AdvertiserLandingPagesListCall {
19069 var advertiserIds_ []string
19070 for _, v := range advertiserIds {
19071 advertiserIds_ = append(advertiserIds_, fmt.Sprint(v))
19072 }
19073 c.urlParams_.SetMulti("advertiserIds", advertiserIds_)
19074 return c
19075 }
19076
19077
19078
19079
19080 func (c *AdvertiserLandingPagesListCall) Archived(archived bool) *AdvertiserLandingPagesListCall {
19081 c.urlParams_.Set("archived", fmt.Sprint(archived))
19082 return c
19083 }
19084
19085
19086
19087 func (c *AdvertiserLandingPagesListCall) CampaignIds(campaignIds ...int64) *AdvertiserLandingPagesListCall {
19088 var campaignIds_ []string
19089 for _, v := range campaignIds {
19090 campaignIds_ = append(campaignIds_, fmt.Sprint(v))
19091 }
19092 c.urlParams_.SetMulti("campaignIds", campaignIds_)
19093 return c
19094 }
19095
19096
19097
19098 func (c *AdvertiserLandingPagesListCall) Ids(ids ...int64) *AdvertiserLandingPagesListCall {
19099 var ids_ []string
19100 for _, v := range ids {
19101 ids_ = append(ids_, fmt.Sprint(v))
19102 }
19103 c.urlParams_.SetMulti("ids", ids_)
19104 return c
19105 }
19106
19107
19108
19109 func (c *AdvertiserLandingPagesListCall) MaxResults(maxResults int64) *AdvertiserLandingPagesListCall {
19110 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
19111 return c
19112 }
19113
19114
19115
19116 func (c *AdvertiserLandingPagesListCall) PageToken(pageToken string) *AdvertiserLandingPagesListCall {
19117 c.urlParams_.Set("pageToken", pageToken)
19118 return c
19119 }
19120
19121
19122
19123
19124
19125
19126
19127
19128
19129 func (c *AdvertiserLandingPagesListCall) SearchString(searchString string) *AdvertiserLandingPagesListCall {
19130 c.urlParams_.Set("searchString", searchString)
19131 return c
19132 }
19133
19134
19135
19136
19137
19138
19139
19140
19141 func (c *AdvertiserLandingPagesListCall) SortField(sortField string) *AdvertiserLandingPagesListCall {
19142 c.urlParams_.Set("sortField", sortField)
19143 return c
19144 }
19145
19146
19147
19148
19149
19150
19151
19152
19153 func (c *AdvertiserLandingPagesListCall) SortOrder(sortOrder string) *AdvertiserLandingPagesListCall {
19154 c.urlParams_.Set("sortOrder", sortOrder)
19155 return c
19156 }
19157
19158
19159
19160 func (c *AdvertiserLandingPagesListCall) SubaccountId(subaccountId int64) *AdvertiserLandingPagesListCall {
19161 c.urlParams_.Set("subaccountId", fmt.Sprint(subaccountId))
19162 return c
19163 }
19164
19165
19166
19167
19168 func (c *AdvertiserLandingPagesListCall) Fields(s ...googleapi.Field) *AdvertiserLandingPagesListCall {
19169 c.urlParams_.Set("fields", googleapi.CombineFields(s))
19170 return c
19171 }
19172
19173
19174
19175
19176
19177
19178 func (c *AdvertiserLandingPagesListCall) IfNoneMatch(entityTag string) *AdvertiserLandingPagesListCall {
19179 c.ifNoneMatch_ = entityTag
19180 return c
19181 }
19182
19183
19184
19185
19186 func (c *AdvertiserLandingPagesListCall) Context(ctx context.Context) *AdvertiserLandingPagesListCall {
19187 c.ctx_ = ctx
19188 return c
19189 }
19190
19191
19192
19193 func (c *AdvertiserLandingPagesListCall) Header() http.Header {
19194 if c.header_ == nil {
19195 c.header_ = make(http.Header)
19196 }
19197 return c.header_
19198 }
19199
19200 func (c *AdvertiserLandingPagesListCall) doRequest(alt string) (*http.Response, error) {
19201 reqHeaders := make(http.Header)
19202 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
19203 for k, v := range c.header_ {
19204 reqHeaders[k] = v
19205 }
19206 reqHeaders.Set("User-Agent", c.s.userAgent())
19207 if c.ifNoneMatch_ != "" {
19208 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
19209 }
19210 var body io.Reader = nil
19211 c.urlParams_.Set("alt", alt)
19212 c.urlParams_.Set("prettyPrint", "false")
19213 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/advertiserLandingPages")
19214 urls += "?" + c.urlParams_.Encode()
19215 req, err := http.NewRequest("GET", urls, body)
19216 if err != nil {
19217 return nil, err
19218 }
19219 req.Header = reqHeaders
19220 googleapi.Expand(req.URL, map[string]string{
19221 "profileId": strconv.FormatInt(c.profileId, 10),
19222 })
19223 return gensupport.SendRequest(c.ctx_, c.s.client, req)
19224 }
19225
19226
19227
19228
19229
19230
19231
19232
19233
19234 func (c *AdvertiserLandingPagesListCall) Do(opts ...googleapi.CallOption) (*AdvertiserLandingPagesListResponse, error) {
19235 gensupport.SetOptions(c.urlParams_, opts...)
19236 res, err := c.doRequest("json")
19237 if res != nil && res.StatusCode == http.StatusNotModified {
19238 if res.Body != nil {
19239 res.Body.Close()
19240 }
19241 return nil, &googleapi.Error{
19242 Code: res.StatusCode,
19243 Header: res.Header,
19244 }
19245 }
19246 if err != nil {
19247 return nil, err
19248 }
19249 defer googleapi.CloseBody(res)
19250 if err := googleapi.CheckResponse(res); err != nil {
19251 return nil, err
19252 }
19253 ret := &AdvertiserLandingPagesListResponse{
19254 ServerResponse: googleapi.ServerResponse{
19255 Header: res.Header,
19256 HTTPStatusCode: res.StatusCode,
19257 },
19258 }
19259 target := &ret
19260 if err := gensupport.DecodeResponse(target, res); err != nil {
19261 return nil, err
19262 }
19263 return ret, nil
19264
19265
19266
19267
19268
19269
19270
19271
19272
19273
19274
19275
19276
19277
19278
19279
19280
19281
19282
19283
19284
19285
19286
19287
19288
19289
19290
19291
19292
19293
19294
19295
19296
19297
19298
19299
19300
19301
19302
19303
19304
19305
19306
19307
19308
19309
19310
19311
19312
19313
19314
19315
19316
19317
19318
19319
19320
19321
19322
19323
19324
19325
19326
19327
19328
19329
19330
19331
19332
19333
19334
19335
19336
19337
19338
19339
19340
19341
19342
19343
19344
19345
19346
19347
19348
19349
19350
19351
19352
19353
19354
19355
19356
19357
19358
19359
19360
19361
19362
19363
19364
19365
19366
19367
19368 }
19369
19370
19371
19372
19373 func (c *AdvertiserLandingPagesListCall) Pages(ctx context.Context, f func(*AdvertiserLandingPagesListResponse) error) error {
19374 c.ctx_ = ctx
19375 defer c.PageToken(c.urlParams_.Get("pageToken"))
19376 for {
19377 x, err := c.Do()
19378 if err != nil {
19379 return err
19380 }
19381 if err := f(x); err != nil {
19382 return err
19383 }
19384 if x.NextPageToken == "" {
19385 return nil
19386 }
19387 c.PageToken(x.NextPageToken)
19388 }
19389 }
19390
19391
19392
19393 type AdvertiserLandingPagesPatchCall struct {
19394 s *Service
19395 profileId int64
19396 landingpage *LandingPage
19397 urlParams_ gensupport.URLParams
19398 ctx_ context.Context
19399 header_ http.Header
19400 }
19401
19402
19403
19404 func (r *AdvertiserLandingPagesService) Patch(profileId int64, id int64, landingpage *LandingPage) *AdvertiserLandingPagesPatchCall {
19405 c := &AdvertiserLandingPagesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
19406 c.profileId = profileId
19407 c.urlParams_.Set("id", fmt.Sprint(id))
19408 c.landingpage = landingpage
19409 return c
19410 }
19411
19412
19413
19414
19415 func (c *AdvertiserLandingPagesPatchCall) Fields(s ...googleapi.Field) *AdvertiserLandingPagesPatchCall {
19416 c.urlParams_.Set("fields", googleapi.CombineFields(s))
19417 return c
19418 }
19419
19420
19421
19422
19423 func (c *AdvertiserLandingPagesPatchCall) Context(ctx context.Context) *AdvertiserLandingPagesPatchCall {
19424 c.ctx_ = ctx
19425 return c
19426 }
19427
19428
19429
19430 func (c *AdvertiserLandingPagesPatchCall) Header() http.Header {
19431 if c.header_ == nil {
19432 c.header_ = make(http.Header)
19433 }
19434 return c.header_
19435 }
19436
19437 func (c *AdvertiserLandingPagesPatchCall) doRequest(alt string) (*http.Response, error) {
19438 reqHeaders := make(http.Header)
19439 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
19440 for k, v := range c.header_ {
19441 reqHeaders[k] = v
19442 }
19443 reqHeaders.Set("User-Agent", c.s.userAgent())
19444 var body io.Reader = nil
19445 body, err := googleapi.WithoutDataWrapper.JSONReader(c.landingpage)
19446 if err != nil {
19447 return nil, err
19448 }
19449 reqHeaders.Set("Content-Type", "application/json")
19450 c.urlParams_.Set("alt", alt)
19451 c.urlParams_.Set("prettyPrint", "false")
19452 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/advertiserLandingPages")
19453 urls += "?" + c.urlParams_.Encode()
19454 req, err := http.NewRequest("PATCH", urls, body)
19455 if err != nil {
19456 return nil, err
19457 }
19458 req.Header = reqHeaders
19459 googleapi.Expand(req.URL, map[string]string{
19460 "profileId": strconv.FormatInt(c.profileId, 10),
19461 })
19462 return gensupport.SendRequest(c.ctx_, c.s.client, req)
19463 }
19464
19465
19466
19467
19468
19469
19470
19471
19472 func (c *AdvertiserLandingPagesPatchCall) Do(opts ...googleapi.CallOption) (*LandingPage, error) {
19473 gensupport.SetOptions(c.urlParams_, opts...)
19474 res, err := c.doRequest("json")
19475 if res != nil && res.StatusCode == http.StatusNotModified {
19476 if res.Body != nil {
19477 res.Body.Close()
19478 }
19479 return nil, &googleapi.Error{
19480 Code: res.StatusCode,
19481 Header: res.Header,
19482 }
19483 }
19484 if err != nil {
19485 return nil, err
19486 }
19487 defer googleapi.CloseBody(res)
19488 if err := googleapi.CheckResponse(res); err != nil {
19489 return nil, err
19490 }
19491 ret := &LandingPage{
19492 ServerResponse: googleapi.ServerResponse{
19493 Header: res.Header,
19494 HTTPStatusCode: res.StatusCode,
19495 },
19496 }
19497 target := &ret
19498 if err := gensupport.DecodeResponse(target, res); err != nil {
19499 return nil, err
19500 }
19501 return ret, nil
19502
19503
19504
19505
19506
19507
19508
19509
19510
19511
19512
19513
19514
19515
19516
19517
19518
19519
19520
19521
19522
19523
19524
19525
19526
19527
19528
19529
19530
19531
19532
19533
19534
19535
19536
19537
19538 }
19539
19540
19541
19542 type AdvertiserLandingPagesUpdateCall struct {
19543 s *Service
19544 profileId int64
19545 landingpage *LandingPage
19546 urlParams_ gensupport.URLParams
19547 ctx_ context.Context
19548 header_ http.Header
19549 }
19550
19551
19552 func (r *AdvertiserLandingPagesService) Update(profileId int64, landingpage *LandingPage) *AdvertiserLandingPagesUpdateCall {
19553 c := &AdvertiserLandingPagesUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
19554 c.profileId = profileId
19555 c.landingpage = landingpage
19556 return c
19557 }
19558
19559
19560
19561
19562 func (c *AdvertiserLandingPagesUpdateCall) Fields(s ...googleapi.Field) *AdvertiserLandingPagesUpdateCall {
19563 c.urlParams_.Set("fields", googleapi.CombineFields(s))
19564 return c
19565 }
19566
19567
19568
19569
19570 func (c *AdvertiserLandingPagesUpdateCall) Context(ctx context.Context) *AdvertiserLandingPagesUpdateCall {
19571 c.ctx_ = ctx
19572 return c
19573 }
19574
19575
19576
19577 func (c *AdvertiserLandingPagesUpdateCall) Header() http.Header {
19578 if c.header_ == nil {
19579 c.header_ = make(http.Header)
19580 }
19581 return c.header_
19582 }
19583
19584 func (c *AdvertiserLandingPagesUpdateCall) doRequest(alt string) (*http.Response, error) {
19585 reqHeaders := make(http.Header)
19586 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
19587 for k, v := range c.header_ {
19588 reqHeaders[k] = v
19589 }
19590 reqHeaders.Set("User-Agent", c.s.userAgent())
19591 var body io.Reader = nil
19592 body, err := googleapi.WithoutDataWrapper.JSONReader(c.landingpage)
19593 if err != nil {
19594 return nil, err
19595 }
19596 reqHeaders.Set("Content-Type", "application/json")
19597 c.urlParams_.Set("alt", alt)
19598 c.urlParams_.Set("prettyPrint", "false")
19599 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/advertiserLandingPages")
19600 urls += "?" + c.urlParams_.Encode()
19601 req, err := http.NewRequest("PUT", urls, body)
19602 if err != nil {
19603 return nil, err
19604 }
19605 req.Header = reqHeaders
19606 googleapi.Expand(req.URL, map[string]string{
19607 "profileId": strconv.FormatInt(c.profileId, 10),
19608 })
19609 return gensupport.SendRequest(c.ctx_, c.s.client, req)
19610 }
19611
19612
19613
19614
19615
19616
19617
19618
19619 func (c *AdvertiserLandingPagesUpdateCall) Do(opts ...googleapi.CallOption) (*LandingPage, error) {
19620 gensupport.SetOptions(c.urlParams_, opts...)
19621 res, err := c.doRequest("json")
19622 if res != nil && res.StatusCode == http.StatusNotModified {
19623 if res.Body != nil {
19624 res.Body.Close()
19625 }
19626 return nil, &googleapi.Error{
19627 Code: res.StatusCode,
19628 Header: res.Header,
19629 }
19630 }
19631 if err != nil {
19632 return nil, err
19633 }
19634 defer googleapi.CloseBody(res)
19635 if err := googleapi.CheckResponse(res); err != nil {
19636 return nil, err
19637 }
19638 ret := &LandingPage{
19639 ServerResponse: googleapi.ServerResponse{
19640 Header: res.Header,
19641 HTTPStatusCode: res.StatusCode,
19642 },
19643 }
19644 target := &ret
19645 if err := gensupport.DecodeResponse(target, res); err != nil {
19646 return nil, err
19647 }
19648 return ret, nil
19649
19650
19651
19652
19653
19654
19655
19656
19657
19658
19659
19660
19661
19662
19663
19664
19665
19666
19667
19668
19669
19670
19671
19672
19673
19674
19675
19676
19677 }
19678
19679
19680
19681 type AdvertisersGetCall struct {
19682 s *Service
19683 profileId int64
19684 id int64
19685 urlParams_ gensupport.URLParams
19686 ifNoneMatch_ string
19687 ctx_ context.Context
19688 header_ http.Header
19689 }
19690
19691
19692 func (r *AdvertisersService) Get(profileId int64, id int64) *AdvertisersGetCall {
19693 c := &AdvertisersGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
19694 c.profileId = profileId
19695 c.id = id
19696 return c
19697 }
19698
19699
19700
19701
19702 func (c *AdvertisersGetCall) Fields(s ...googleapi.Field) *AdvertisersGetCall {
19703 c.urlParams_.Set("fields", googleapi.CombineFields(s))
19704 return c
19705 }
19706
19707
19708
19709
19710
19711
19712 func (c *AdvertisersGetCall) IfNoneMatch(entityTag string) *AdvertisersGetCall {
19713 c.ifNoneMatch_ = entityTag
19714 return c
19715 }
19716
19717
19718
19719
19720 func (c *AdvertisersGetCall) Context(ctx context.Context) *AdvertisersGetCall {
19721 c.ctx_ = ctx
19722 return c
19723 }
19724
19725
19726
19727 func (c *AdvertisersGetCall) Header() http.Header {
19728 if c.header_ == nil {
19729 c.header_ = make(http.Header)
19730 }
19731 return c.header_
19732 }
19733
19734 func (c *AdvertisersGetCall) doRequest(alt string) (*http.Response, error) {
19735 reqHeaders := make(http.Header)
19736 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
19737 for k, v := range c.header_ {
19738 reqHeaders[k] = v
19739 }
19740 reqHeaders.Set("User-Agent", c.s.userAgent())
19741 if c.ifNoneMatch_ != "" {
19742 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
19743 }
19744 var body io.Reader = nil
19745 c.urlParams_.Set("alt", alt)
19746 c.urlParams_.Set("prettyPrint", "false")
19747 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/advertisers/{id}")
19748 urls += "?" + c.urlParams_.Encode()
19749 req, err := http.NewRequest("GET", urls, body)
19750 if err != nil {
19751 return nil, err
19752 }
19753 req.Header = reqHeaders
19754 googleapi.Expand(req.URL, map[string]string{
19755 "profileId": strconv.FormatInt(c.profileId, 10),
19756 "id": strconv.FormatInt(c.id, 10),
19757 })
19758 return gensupport.SendRequest(c.ctx_, c.s.client, req)
19759 }
19760
19761
19762
19763
19764
19765
19766
19767
19768 func (c *AdvertisersGetCall) Do(opts ...googleapi.CallOption) (*Advertiser, error) {
19769 gensupport.SetOptions(c.urlParams_, opts...)
19770 res, err := c.doRequest("json")
19771 if res != nil && res.StatusCode == http.StatusNotModified {
19772 if res.Body != nil {
19773 res.Body.Close()
19774 }
19775 return nil, &googleapi.Error{
19776 Code: res.StatusCode,
19777 Header: res.Header,
19778 }
19779 }
19780 if err != nil {
19781 return nil, err
19782 }
19783 defer googleapi.CloseBody(res)
19784 if err := googleapi.CheckResponse(res); err != nil {
19785 return nil, err
19786 }
19787 ret := &Advertiser{
19788 ServerResponse: googleapi.ServerResponse{
19789 Header: res.Header,
19790 HTTPStatusCode: res.StatusCode,
19791 },
19792 }
19793 target := &ret
19794 if err := gensupport.DecodeResponse(target, res); err != nil {
19795 return nil, err
19796 }
19797 return ret, nil
19798
19799
19800
19801
19802
19803
19804
19805
19806
19807
19808
19809
19810
19811
19812
19813
19814
19815
19816
19817
19818
19819
19820
19821
19822
19823
19824
19825
19826
19827
19828
19829
19830
19831 }
19832
19833
19834
19835 type AdvertisersInsertCall struct {
19836 s *Service
19837 profileId int64
19838 advertiser *Advertiser
19839 urlParams_ gensupport.URLParams
19840 ctx_ context.Context
19841 header_ http.Header
19842 }
19843
19844
19845 func (r *AdvertisersService) Insert(profileId int64, advertiser *Advertiser) *AdvertisersInsertCall {
19846 c := &AdvertisersInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
19847 c.profileId = profileId
19848 c.advertiser = advertiser
19849 return c
19850 }
19851
19852
19853
19854
19855 func (c *AdvertisersInsertCall) Fields(s ...googleapi.Field) *AdvertisersInsertCall {
19856 c.urlParams_.Set("fields", googleapi.CombineFields(s))
19857 return c
19858 }
19859
19860
19861
19862
19863 func (c *AdvertisersInsertCall) Context(ctx context.Context) *AdvertisersInsertCall {
19864 c.ctx_ = ctx
19865 return c
19866 }
19867
19868
19869
19870 func (c *AdvertisersInsertCall) Header() http.Header {
19871 if c.header_ == nil {
19872 c.header_ = make(http.Header)
19873 }
19874 return c.header_
19875 }
19876
19877 func (c *AdvertisersInsertCall) doRequest(alt string) (*http.Response, error) {
19878 reqHeaders := make(http.Header)
19879 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
19880 for k, v := range c.header_ {
19881 reqHeaders[k] = v
19882 }
19883 reqHeaders.Set("User-Agent", c.s.userAgent())
19884 var body io.Reader = nil
19885 body, err := googleapi.WithoutDataWrapper.JSONReader(c.advertiser)
19886 if err != nil {
19887 return nil, err
19888 }
19889 reqHeaders.Set("Content-Type", "application/json")
19890 c.urlParams_.Set("alt", alt)
19891 c.urlParams_.Set("prettyPrint", "false")
19892 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/advertisers")
19893 urls += "?" + c.urlParams_.Encode()
19894 req, err := http.NewRequest("POST", urls, body)
19895 if err != nil {
19896 return nil, err
19897 }
19898 req.Header = reqHeaders
19899 googleapi.Expand(req.URL, map[string]string{
19900 "profileId": strconv.FormatInt(c.profileId, 10),
19901 })
19902 return gensupport.SendRequest(c.ctx_, c.s.client, req)
19903 }
19904
19905
19906
19907
19908
19909
19910
19911
19912 func (c *AdvertisersInsertCall) Do(opts ...googleapi.CallOption) (*Advertiser, error) {
19913 gensupport.SetOptions(c.urlParams_, opts...)
19914 res, err := c.doRequest("json")
19915 if res != nil && res.StatusCode == http.StatusNotModified {
19916 if res.Body != nil {
19917 res.Body.Close()
19918 }
19919 return nil, &googleapi.Error{
19920 Code: res.StatusCode,
19921 Header: res.Header,
19922 }
19923 }
19924 if err != nil {
19925 return nil, err
19926 }
19927 defer googleapi.CloseBody(res)
19928 if err := googleapi.CheckResponse(res); err != nil {
19929 return nil, err
19930 }
19931 ret := &Advertiser{
19932 ServerResponse: googleapi.ServerResponse{
19933 Header: res.Header,
19934 HTTPStatusCode: res.StatusCode,
19935 },
19936 }
19937 target := &ret
19938 if err := gensupport.DecodeResponse(target, res); err != nil {
19939 return nil, err
19940 }
19941 return ret, nil
19942
19943
19944
19945
19946
19947
19948
19949
19950
19951
19952
19953
19954
19955
19956
19957
19958
19959
19960
19961
19962
19963
19964
19965
19966
19967
19968
19969
19970 }
19971
19972
19973
19974 type AdvertisersListCall struct {
19975 s *Service
19976 profileId int64
19977 urlParams_ gensupport.URLParams
19978 ifNoneMatch_ string
19979 ctx_ context.Context
19980 header_ http.Header
19981 }
19982
19983
19984
19985 func (r *AdvertisersService) List(profileId int64) *AdvertisersListCall {
19986 c := &AdvertisersListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
19987 c.profileId = profileId
19988 return c
19989 }
19990
19991
19992
19993 func (c *AdvertisersListCall) AdvertiserGroupIds(advertiserGroupIds ...int64) *AdvertisersListCall {
19994 var advertiserGroupIds_ []string
19995 for _, v := range advertiserGroupIds {
19996 advertiserGroupIds_ = append(advertiserGroupIds_, fmt.Sprint(v))
19997 }
19998 c.urlParams_.SetMulti("advertiserGroupIds", advertiserGroupIds_)
19999 return c
20000 }
20001
20002
20003
20004
20005 func (c *AdvertisersListCall) FloodlightConfigurationIds(floodlightConfigurationIds ...int64) *AdvertisersListCall {
20006 var floodlightConfigurationIds_ []string
20007 for _, v := range floodlightConfigurationIds {
20008 floodlightConfigurationIds_ = append(floodlightConfigurationIds_, fmt.Sprint(v))
20009 }
20010 c.urlParams_.SetMulti("floodlightConfigurationIds", floodlightConfigurationIds_)
20011 return c
20012 }
20013
20014
20015
20016 func (c *AdvertisersListCall) Ids(ids ...int64) *AdvertisersListCall {
20017 var ids_ []string
20018 for _, v := range ids {
20019 ids_ = append(ids_, fmt.Sprint(v))
20020 }
20021 c.urlParams_.SetMulti("ids", ids_)
20022 return c
20023 }
20024
20025
20026
20027
20028 func (c *AdvertisersListCall) IncludeAdvertisersWithoutGroupsOnly(includeAdvertisersWithoutGroupsOnly bool) *AdvertisersListCall {
20029 c.urlParams_.Set("includeAdvertisersWithoutGroupsOnly", fmt.Sprint(includeAdvertisersWithoutGroupsOnly))
20030 return c
20031 }
20032
20033
20034
20035 func (c *AdvertisersListCall) MaxResults(maxResults int64) *AdvertisersListCall {
20036 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
20037 return c
20038 }
20039
20040
20041
20042 func (c *AdvertisersListCall) OnlyParent(onlyParent bool) *AdvertisersListCall {
20043 c.urlParams_.Set("onlyParent", fmt.Sprint(onlyParent))
20044 return c
20045 }
20046
20047
20048
20049 func (c *AdvertisersListCall) PageToken(pageToken string) *AdvertisersListCall {
20050 c.urlParams_.Set("pageToken", pageToken)
20051 return c
20052 }
20053
20054
20055
20056
20057
20058
20059
20060
20061
20062 func (c *AdvertisersListCall) SearchString(searchString string) *AdvertisersListCall {
20063 c.urlParams_.Set("searchString", searchString)
20064 return c
20065 }
20066
20067
20068
20069
20070
20071
20072
20073
20074 func (c *AdvertisersListCall) SortField(sortField string) *AdvertisersListCall {
20075 c.urlParams_.Set("sortField", sortField)
20076 return c
20077 }
20078
20079
20080
20081
20082
20083
20084
20085
20086 func (c *AdvertisersListCall) SortOrder(sortOrder string) *AdvertisersListCall {
20087 c.urlParams_.Set("sortOrder", sortOrder)
20088 return c
20089 }
20090
20091
20092
20093
20094
20095
20096
20097
20098 func (c *AdvertisersListCall) Status(status string) *AdvertisersListCall {
20099 c.urlParams_.Set("status", status)
20100 return c
20101 }
20102
20103
20104
20105 func (c *AdvertisersListCall) SubaccountId(subaccountId int64) *AdvertisersListCall {
20106 c.urlParams_.Set("subaccountId", fmt.Sprint(subaccountId))
20107 return c
20108 }
20109
20110
20111
20112
20113 func (c *AdvertisersListCall) Fields(s ...googleapi.Field) *AdvertisersListCall {
20114 c.urlParams_.Set("fields", googleapi.CombineFields(s))
20115 return c
20116 }
20117
20118
20119
20120
20121
20122
20123 func (c *AdvertisersListCall) IfNoneMatch(entityTag string) *AdvertisersListCall {
20124 c.ifNoneMatch_ = entityTag
20125 return c
20126 }
20127
20128
20129
20130
20131 func (c *AdvertisersListCall) Context(ctx context.Context) *AdvertisersListCall {
20132 c.ctx_ = ctx
20133 return c
20134 }
20135
20136
20137
20138 func (c *AdvertisersListCall) Header() http.Header {
20139 if c.header_ == nil {
20140 c.header_ = make(http.Header)
20141 }
20142 return c.header_
20143 }
20144
20145 func (c *AdvertisersListCall) doRequest(alt string) (*http.Response, error) {
20146 reqHeaders := make(http.Header)
20147 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
20148 for k, v := range c.header_ {
20149 reqHeaders[k] = v
20150 }
20151 reqHeaders.Set("User-Agent", c.s.userAgent())
20152 if c.ifNoneMatch_ != "" {
20153 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
20154 }
20155 var body io.Reader = nil
20156 c.urlParams_.Set("alt", alt)
20157 c.urlParams_.Set("prettyPrint", "false")
20158 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/advertisers")
20159 urls += "?" + c.urlParams_.Encode()
20160 req, err := http.NewRequest("GET", urls, body)
20161 if err != nil {
20162 return nil, err
20163 }
20164 req.Header = reqHeaders
20165 googleapi.Expand(req.URL, map[string]string{
20166 "profileId": strconv.FormatInt(c.profileId, 10),
20167 })
20168 return gensupport.SendRequest(c.ctx_, c.s.client, req)
20169 }
20170
20171
20172
20173
20174
20175
20176
20177
20178 func (c *AdvertisersListCall) Do(opts ...googleapi.CallOption) (*AdvertisersListResponse, error) {
20179 gensupport.SetOptions(c.urlParams_, opts...)
20180 res, err := c.doRequest("json")
20181 if res != nil && res.StatusCode == http.StatusNotModified {
20182 if res.Body != nil {
20183 res.Body.Close()
20184 }
20185 return nil, &googleapi.Error{
20186 Code: res.StatusCode,
20187 Header: res.Header,
20188 }
20189 }
20190 if err != nil {
20191 return nil, err
20192 }
20193 defer googleapi.CloseBody(res)
20194 if err := googleapi.CheckResponse(res); err != nil {
20195 return nil, err
20196 }
20197 ret := &AdvertisersListResponse{
20198 ServerResponse: googleapi.ServerResponse{
20199 Header: res.Header,
20200 HTTPStatusCode: res.StatusCode,
20201 },
20202 }
20203 target := &ret
20204 if err := gensupport.DecodeResponse(target, res); err != nil {
20205 return nil, err
20206 }
20207 return ret, nil
20208
20209
20210
20211
20212
20213
20214
20215
20216
20217
20218
20219
20220
20221
20222
20223
20224
20225
20226
20227
20228
20229
20230
20231
20232
20233
20234
20235
20236
20237
20238
20239
20240
20241
20242
20243
20244
20245
20246
20247
20248
20249
20250
20251
20252
20253
20254
20255
20256
20257
20258
20259
20260
20261
20262
20263
20264
20265
20266
20267
20268
20269
20270
20271
20272
20273
20274
20275
20276
20277
20278
20279
20280
20281
20282
20283
20284
20285
20286
20287
20288
20289
20290
20291
20292
20293
20294
20295
20296
20297
20298
20299
20300
20301
20302
20303
20304
20305
20306
20307
20308
20309
20310
20311
20312
20313
20314
20315
20316
20317
20318
20319
20320
20321
20322
20323
20324
20325
20326
20327
20328
20329
20330 }
20331
20332
20333
20334
20335 func (c *AdvertisersListCall) Pages(ctx context.Context, f func(*AdvertisersListResponse) error) error {
20336 c.ctx_ = ctx
20337 defer c.PageToken(c.urlParams_.Get("pageToken"))
20338 for {
20339 x, err := c.Do()
20340 if err != nil {
20341 return err
20342 }
20343 if err := f(x); err != nil {
20344 return err
20345 }
20346 if x.NextPageToken == "" {
20347 return nil
20348 }
20349 c.PageToken(x.NextPageToken)
20350 }
20351 }
20352
20353
20354
20355 type AdvertisersPatchCall struct {
20356 s *Service
20357 profileId int64
20358 advertiser *Advertiser
20359 urlParams_ gensupport.URLParams
20360 ctx_ context.Context
20361 header_ http.Header
20362 }
20363
20364
20365
20366 func (r *AdvertisersService) Patch(profileId int64, id int64, advertiser *Advertiser) *AdvertisersPatchCall {
20367 c := &AdvertisersPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
20368 c.profileId = profileId
20369 c.urlParams_.Set("id", fmt.Sprint(id))
20370 c.advertiser = advertiser
20371 return c
20372 }
20373
20374
20375
20376
20377 func (c *AdvertisersPatchCall) Fields(s ...googleapi.Field) *AdvertisersPatchCall {
20378 c.urlParams_.Set("fields", googleapi.CombineFields(s))
20379 return c
20380 }
20381
20382
20383
20384
20385 func (c *AdvertisersPatchCall) Context(ctx context.Context) *AdvertisersPatchCall {
20386 c.ctx_ = ctx
20387 return c
20388 }
20389
20390
20391
20392 func (c *AdvertisersPatchCall) Header() http.Header {
20393 if c.header_ == nil {
20394 c.header_ = make(http.Header)
20395 }
20396 return c.header_
20397 }
20398
20399 func (c *AdvertisersPatchCall) doRequest(alt string) (*http.Response, error) {
20400 reqHeaders := make(http.Header)
20401 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
20402 for k, v := range c.header_ {
20403 reqHeaders[k] = v
20404 }
20405 reqHeaders.Set("User-Agent", c.s.userAgent())
20406 var body io.Reader = nil
20407 body, err := googleapi.WithoutDataWrapper.JSONReader(c.advertiser)
20408 if err != nil {
20409 return nil, err
20410 }
20411 reqHeaders.Set("Content-Type", "application/json")
20412 c.urlParams_.Set("alt", alt)
20413 c.urlParams_.Set("prettyPrint", "false")
20414 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/advertisers")
20415 urls += "?" + c.urlParams_.Encode()
20416 req, err := http.NewRequest("PATCH", urls, body)
20417 if err != nil {
20418 return nil, err
20419 }
20420 req.Header = reqHeaders
20421 googleapi.Expand(req.URL, map[string]string{
20422 "profileId": strconv.FormatInt(c.profileId, 10),
20423 })
20424 return gensupport.SendRequest(c.ctx_, c.s.client, req)
20425 }
20426
20427
20428
20429
20430
20431
20432
20433
20434 func (c *AdvertisersPatchCall) Do(opts ...googleapi.CallOption) (*Advertiser, error) {
20435 gensupport.SetOptions(c.urlParams_, opts...)
20436 res, err := c.doRequest("json")
20437 if res != nil && res.StatusCode == http.StatusNotModified {
20438 if res.Body != nil {
20439 res.Body.Close()
20440 }
20441 return nil, &googleapi.Error{
20442 Code: res.StatusCode,
20443 Header: res.Header,
20444 }
20445 }
20446 if err != nil {
20447 return nil, err
20448 }
20449 defer googleapi.CloseBody(res)
20450 if err := googleapi.CheckResponse(res); err != nil {
20451 return nil, err
20452 }
20453 ret := &Advertiser{
20454 ServerResponse: googleapi.ServerResponse{
20455 Header: res.Header,
20456 HTTPStatusCode: res.StatusCode,
20457 },
20458 }
20459 target := &ret
20460 if err := gensupport.DecodeResponse(target, res); err != nil {
20461 return nil, err
20462 }
20463 return ret, nil
20464
20465
20466
20467
20468
20469
20470
20471
20472
20473
20474
20475
20476
20477
20478
20479
20480
20481
20482
20483
20484
20485
20486
20487
20488
20489
20490
20491
20492
20493
20494
20495
20496
20497
20498
20499
20500 }
20501
20502
20503
20504 type AdvertisersUpdateCall struct {
20505 s *Service
20506 profileId int64
20507 advertiser *Advertiser
20508 urlParams_ gensupport.URLParams
20509 ctx_ context.Context
20510 header_ http.Header
20511 }
20512
20513
20514 func (r *AdvertisersService) Update(profileId int64, advertiser *Advertiser) *AdvertisersUpdateCall {
20515 c := &AdvertisersUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
20516 c.profileId = profileId
20517 c.advertiser = advertiser
20518 return c
20519 }
20520
20521
20522
20523
20524 func (c *AdvertisersUpdateCall) Fields(s ...googleapi.Field) *AdvertisersUpdateCall {
20525 c.urlParams_.Set("fields", googleapi.CombineFields(s))
20526 return c
20527 }
20528
20529
20530
20531
20532 func (c *AdvertisersUpdateCall) Context(ctx context.Context) *AdvertisersUpdateCall {
20533 c.ctx_ = ctx
20534 return c
20535 }
20536
20537
20538
20539 func (c *AdvertisersUpdateCall) Header() http.Header {
20540 if c.header_ == nil {
20541 c.header_ = make(http.Header)
20542 }
20543 return c.header_
20544 }
20545
20546 func (c *AdvertisersUpdateCall) doRequest(alt string) (*http.Response, error) {
20547 reqHeaders := make(http.Header)
20548 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
20549 for k, v := range c.header_ {
20550 reqHeaders[k] = v
20551 }
20552 reqHeaders.Set("User-Agent", c.s.userAgent())
20553 var body io.Reader = nil
20554 body, err := googleapi.WithoutDataWrapper.JSONReader(c.advertiser)
20555 if err != nil {
20556 return nil, err
20557 }
20558 reqHeaders.Set("Content-Type", "application/json")
20559 c.urlParams_.Set("alt", alt)
20560 c.urlParams_.Set("prettyPrint", "false")
20561 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/advertisers")
20562 urls += "?" + c.urlParams_.Encode()
20563 req, err := http.NewRequest("PUT", urls, body)
20564 if err != nil {
20565 return nil, err
20566 }
20567 req.Header = reqHeaders
20568 googleapi.Expand(req.URL, map[string]string{
20569 "profileId": strconv.FormatInt(c.profileId, 10),
20570 })
20571 return gensupport.SendRequest(c.ctx_, c.s.client, req)
20572 }
20573
20574
20575
20576
20577
20578
20579
20580
20581 func (c *AdvertisersUpdateCall) Do(opts ...googleapi.CallOption) (*Advertiser, error) {
20582 gensupport.SetOptions(c.urlParams_, opts...)
20583 res, err := c.doRequest("json")
20584 if res != nil && res.StatusCode == http.StatusNotModified {
20585 if res.Body != nil {
20586 res.Body.Close()
20587 }
20588 return nil, &googleapi.Error{
20589 Code: res.StatusCode,
20590 Header: res.Header,
20591 }
20592 }
20593 if err != nil {
20594 return nil, err
20595 }
20596 defer googleapi.CloseBody(res)
20597 if err := googleapi.CheckResponse(res); err != nil {
20598 return nil, err
20599 }
20600 ret := &Advertiser{
20601 ServerResponse: googleapi.ServerResponse{
20602 Header: res.Header,
20603 HTTPStatusCode: res.StatusCode,
20604 },
20605 }
20606 target := &ret
20607 if err := gensupport.DecodeResponse(target, res); err != nil {
20608 return nil, err
20609 }
20610 return ret, nil
20611
20612
20613
20614
20615
20616
20617
20618
20619
20620
20621
20622
20623
20624
20625
20626
20627
20628
20629
20630
20631
20632
20633
20634
20635
20636
20637
20638
20639 }
20640
20641
20642
20643 type BrowsersListCall struct {
20644 s *Service
20645 profileId int64
20646 urlParams_ gensupport.URLParams
20647 ifNoneMatch_ string
20648 ctx_ context.Context
20649 header_ http.Header
20650 }
20651
20652
20653 func (r *BrowsersService) List(profileId int64) *BrowsersListCall {
20654 c := &BrowsersListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
20655 c.profileId = profileId
20656 return c
20657 }
20658
20659
20660
20661
20662 func (c *BrowsersListCall) Fields(s ...googleapi.Field) *BrowsersListCall {
20663 c.urlParams_.Set("fields", googleapi.CombineFields(s))
20664 return c
20665 }
20666
20667
20668
20669
20670
20671
20672 func (c *BrowsersListCall) IfNoneMatch(entityTag string) *BrowsersListCall {
20673 c.ifNoneMatch_ = entityTag
20674 return c
20675 }
20676
20677
20678
20679
20680 func (c *BrowsersListCall) Context(ctx context.Context) *BrowsersListCall {
20681 c.ctx_ = ctx
20682 return c
20683 }
20684
20685
20686
20687 func (c *BrowsersListCall) Header() http.Header {
20688 if c.header_ == nil {
20689 c.header_ = make(http.Header)
20690 }
20691 return c.header_
20692 }
20693
20694 func (c *BrowsersListCall) doRequest(alt string) (*http.Response, error) {
20695 reqHeaders := make(http.Header)
20696 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
20697 for k, v := range c.header_ {
20698 reqHeaders[k] = v
20699 }
20700 reqHeaders.Set("User-Agent", c.s.userAgent())
20701 if c.ifNoneMatch_ != "" {
20702 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
20703 }
20704 var body io.Reader = nil
20705 c.urlParams_.Set("alt", alt)
20706 c.urlParams_.Set("prettyPrint", "false")
20707 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/browsers")
20708 urls += "?" + c.urlParams_.Encode()
20709 req, err := http.NewRequest("GET", urls, body)
20710 if err != nil {
20711 return nil, err
20712 }
20713 req.Header = reqHeaders
20714 googleapi.Expand(req.URL, map[string]string{
20715 "profileId": strconv.FormatInt(c.profileId, 10),
20716 })
20717 return gensupport.SendRequest(c.ctx_, c.s.client, req)
20718 }
20719
20720
20721
20722
20723
20724
20725
20726
20727 func (c *BrowsersListCall) Do(opts ...googleapi.CallOption) (*BrowsersListResponse, error) {
20728 gensupport.SetOptions(c.urlParams_, opts...)
20729 res, err := c.doRequest("json")
20730 if res != nil && res.StatusCode == http.StatusNotModified {
20731 if res.Body != nil {
20732 res.Body.Close()
20733 }
20734 return nil, &googleapi.Error{
20735 Code: res.StatusCode,
20736 Header: res.Header,
20737 }
20738 }
20739 if err != nil {
20740 return nil, err
20741 }
20742 defer googleapi.CloseBody(res)
20743 if err := googleapi.CheckResponse(res); err != nil {
20744 return nil, err
20745 }
20746 ret := &BrowsersListResponse{
20747 ServerResponse: googleapi.ServerResponse{
20748 Header: res.Header,
20749 HTTPStatusCode: res.StatusCode,
20750 },
20751 }
20752 target := &ret
20753 if err := gensupport.DecodeResponse(target, res); err != nil {
20754 return nil, err
20755 }
20756 return ret, nil
20757
20758
20759
20760
20761
20762
20763
20764
20765
20766
20767
20768
20769
20770
20771
20772
20773
20774
20775
20776
20777
20778
20779
20780
20781
20782 }
20783
20784
20785
20786 type CampaignCreativeAssociationsInsertCall struct {
20787 s *Service
20788 profileId int64
20789 campaignId int64
20790 campaigncreativeassociation *CampaignCreativeAssociation
20791 urlParams_ gensupport.URLParams
20792 ctx_ context.Context
20793 header_ http.Header
20794 }
20795
20796
20797
20798
20799 func (r *CampaignCreativeAssociationsService) Insert(profileId int64, campaignId int64, campaigncreativeassociation *CampaignCreativeAssociation) *CampaignCreativeAssociationsInsertCall {
20800 c := &CampaignCreativeAssociationsInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
20801 c.profileId = profileId
20802 c.campaignId = campaignId
20803 c.campaigncreativeassociation = campaigncreativeassociation
20804 return c
20805 }
20806
20807
20808
20809
20810 func (c *CampaignCreativeAssociationsInsertCall) Fields(s ...googleapi.Field) *CampaignCreativeAssociationsInsertCall {
20811 c.urlParams_.Set("fields", googleapi.CombineFields(s))
20812 return c
20813 }
20814
20815
20816
20817
20818 func (c *CampaignCreativeAssociationsInsertCall) Context(ctx context.Context) *CampaignCreativeAssociationsInsertCall {
20819 c.ctx_ = ctx
20820 return c
20821 }
20822
20823
20824
20825 func (c *CampaignCreativeAssociationsInsertCall) Header() http.Header {
20826 if c.header_ == nil {
20827 c.header_ = make(http.Header)
20828 }
20829 return c.header_
20830 }
20831
20832 func (c *CampaignCreativeAssociationsInsertCall) doRequest(alt string) (*http.Response, error) {
20833 reqHeaders := make(http.Header)
20834 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
20835 for k, v := range c.header_ {
20836 reqHeaders[k] = v
20837 }
20838 reqHeaders.Set("User-Agent", c.s.userAgent())
20839 var body io.Reader = nil
20840 body, err := googleapi.WithoutDataWrapper.JSONReader(c.campaigncreativeassociation)
20841 if err != nil {
20842 return nil, err
20843 }
20844 reqHeaders.Set("Content-Type", "application/json")
20845 c.urlParams_.Set("alt", alt)
20846 c.urlParams_.Set("prettyPrint", "false")
20847 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/campaigns/{campaignId}/campaignCreativeAssociations")
20848 urls += "?" + c.urlParams_.Encode()
20849 req, err := http.NewRequest("POST", urls, body)
20850 if err != nil {
20851 return nil, err
20852 }
20853 req.Header = reqHeaders
20854 googleapi.Expand(req.URL, map[string]string{
20855 "profileId": strconv.FormatInt(c.profileId, 10),
20856 "campaignId": strconv.FormatInt(c.campaignId, 10),
20857 })
20858 return gensupport.SendRequest(c.ctx_, c.s.client, req)
20859 }
20860
20861
20862
20863
20864
20865
20866
20867
20868 func (c *CampaignCreativeAssociationsInsertCall) Do(opts ...googleapi.CallOption) (*CampaignCreativeAssociation, error) {
20869 gensupport.SetOptions(c.urlParams_, opts...)
20870 res, err := c.doRequest("json")
20871 if res != nil && res.StatusCode == http.StatusNotModified {
20872 if res.Body != nil {
20873 res.Body.Close()
20874 }
20875 return nil, &googleapi.Error{
20876 Code: res.StatusCode,
20877 Header: res.Header,
20878 }
20879 }
20880 if err != nil {
20881 return nil, err
20882 }
20883 defer googleapi.CloseBody(res)
20884 if err := googleapi.CheckResponse(res); err != nil {
20885 return nil, err
20886 }
20887 ret := &CampaignCreativeAssociation{
20888 ServerResponse: googleapi.ServerResponse{
20889 Header: res.Header,
20890 HTTPStatusCode: res.StatusCode,
20891 },
20892 }
20893 target := &ret
20894 if err := gensupport.DecodeResponse(target, res); err != nil {
20895 return nil, err
20896 }
20897 return ret, nil
20898
20899
20900
20901
20902
20903
20904
20905
20906
20907
20908
20909
20910
20911
20912
20913
20914
20915
20916
20917
20918
20919
20920
20921
20922
20923
20924
20925
20926
20927
20928
20929
20930
20931
20932
20933
20934 }
20935
20936
20937
20938 type CampaignCreativeAssociationsListCall struct {
20939 s *Service
20940 profileId int64
20941 campaignId int64
20942 urlParams_ gensupport.URLParams
20943 ifNoneMatch_ string
20944 ctx_ context.Context
20945 header_ http.Header
20946 }
20947
20948
20949
20950 func (r *CampaignCreativeAssociationsService) List(profileId int64, campaignId int64) *CampaignCreativeAssociationsListCall {
20951 c := &CampaignCreativeAssociationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
20952 c.profileId = profileId
20953 c.campaignId = campaignId
20954 return c
20955 }
20956
20957
20958
20959 func (c *CampaignCreativeAssociationsListCall) MaxResults(maxResults int64) *CampaignCreativeAssociationsListCall {
20960 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
20961 return c
20962 }
20963
20964
20965
20966 func (c *CampaignCreativeAssociationsListCall) PageToken(pageToken string) *CampaignCreativeAssociationsListCall {
20967 c.urlParams_.Set("pageToken", pageToken)
20968 return c
20969 }
20970
20971
20972
20973
20974
20975
20976
20977
20978 func (c *CampaignCreativeAssociationsListCall) SortOrder(sortOrder string) *CampaignCreativeAssociationsListCall {
20979 c.urlParams_.Set("sortOrder", sortOrder)
20980 return c
20981 }
20982
20983
20984
20985
20986 func (c *CampaignCreativeAssociationsListCall) Fields(s ...googleapi.Field) *CampaignCreativeAssociationsListCall {
20987 c.urlParams_.Set("fields", googleapi.CombineFields(s))
20988 return c
20989 }
20990
20991
20992
20993
20994
20995
20996 func (c *CampaignCreativeAssociationsListCall) IfNoneMatch(entityTag string) *CampaignCreativeAssociationsListCall {
20997 c.ifNoneMatch_ = entityTag
20998 return c
20999 }
21000
21001
21002
21003
21004 func (c *CampaignCreativeAssociationsListCall) Context(ctx context.Context) *CampaignCreativeAssociationsListCall {
21005 c.ctx_ = ctx
21006 return c
21007 }
21008
21009
21010
21011 func (c *CampaignCreativeAssociationsListCall) Header() http.Header {
21012 if c.header_ == nil {
21013 c.header_ = make(http.Header)
21014 }
21015 return c.header_
21016 }
21017
21018 func (c *CampaignCreativeAssociationsListCall) doRequest(alt string) (*http.Response, error) {
21019 reqHeaders := make(http.Header)
21020 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
21021 for k, v := range c.header_ {
21022 reqHeaders[k] = v
21023 }
21024 reqHeaders.Set("User-Agent", c.s.userAgent())
21025 if c.ifNoneMatch_ != "" {
21026 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
21027 }
21028 var body io.Reader = nil
21029 c.urlParams_.Set("alt", alt)
21030 c.urlParams_.Set("prettyPrint", "false")
21031 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/campaigns/{campaignId}/campaignCreativeAssociations")
21032 urls += "?" + c.urlParams_.Encode()
21033 req, err := http.NewRequest("GET", urls, body)
21034 if err != nil {
21035 return nil, err
21036 }
21037 req.Header = reqHeaders
21038 googleapi.Expand(req.URL, map[string]string{
21039 "profileId": strconv.FormatInt(c.profileId, 10),
21040 "campaignId": strconv.FormatInt(c.campaignId, 10),
21041 })
21042 return gensupport.SendRequest(c.ctx_, c.s.client, req)
21043 }
21044
21045
21046
21047
21048
21049
21050
21051
21052
21053
21054 func (c *CampaignCreativeAssociationsListCall) Do(opts ...googleapi.CallOption) (*CampaignCreativeAssociationsListResponse, error) {
21055 gensupport.SetOptions(c.urlParams_, opts...)
21056 res, err := c.doRequest("json")
21057 if res != nil && res.StatusCode == http.StatusNotModified {
21058 if res.Body != nil {
21059 res.Body.Close()
21060 }
21061 return nil, &googleapi.Error{
21062 Code: res.StatusCode,
21063 Header: res.Header,
21064 }
21065 }
21066 if err != nil {
21067 return nil, err
21068 }
21069 defer googleapi.CloseBody(res)
21070 if err := googleapi.CheckResponse(res); err != nil {
21071 return nil, err
21072 }
21073 ret := &CampaignCreativeAssociationsListResponse{
21074 ServerResponse: googleapi.ServerResponse{
21075 Header: res.Header,
21076 HTTPStatusCode: res.StatusCode,
21077 },
21078 }
21079 target := &ret
21080 if err := gensupport.DecodeResponse(target, res); err != nil {
21081 return nil, err
21082 }
21083 return ret, nil
21084
21085
21086
21087
21088
21089
21090
21091
21092
21093
21094
21095
21096
21097
21098
21099
21100
21101
21102
21103
21104
21105
21106
21107
21108
21109
21110
21111
21112
21113
21114
21115
21116
21117
21118
21119
21120
21121
21122
21123
21124
21125
21126
21127
21128
21129
21130
21131
21132
21133
21134
21135
21136
21137
21138
21139
21140
21141
21142
21143
21144
21145 }
21146
21147
21148
21149
21150 func (c *CampaignCreativeAssociationsListCall) Pages(ctx context.Context, f func(*CampaignCreativeAssociationsListResponse) error) error {
21151 c.ctx_ = ctx
21152 defer c.PageToken(c.urlParams_.Get("pageToken"))
21153 for {
21154 x, err := c.Do()
21155 if err != nil {
21156 return err
21157 }
21158 if err := f(x); err != nil {
21159 return err
21160 }
21161 if x.NextPageToken == "" {
21162 return nil
21163 }
21164 c.PageToken(x.NextPageToken)
21165 }
21166 }
21167
21168
21169
21170 type CampaignsGetCall struct {
21171 s *Service
21172 profileId int64
21173 id int64
21174 urlParams_ gensupport.URLParams
21175 ifNoneMatch_ string
21176 ctx_ context.Context
21177 header_ http.Header
21178 }
21179
21180
21181 func (r *CampaignsService) Get(profileId int64, id int64) *CampaignsGetCall {
21182 c := &CampaignsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
21183 c.profileId = profileId
21184 c.id = id
21185 return c
21186 }
21187
21188
21189
21190
21191 func (c *CampaignsGetCall) Fields(s ...googleapi.Field) *CampaignsGetCall {
21192 c.urlParams_.Set("fields", googleapi.CombineFields(s))
21193 return c
21194 }
21195
21196
21197
21198
21199
21200
21201 func (c *CampaignsGetCall) IfNoneMatch(entityTag string) *CampaignsGetCall {
21202 c.ifNoneMatch_ = entityTag
21203 return c
21204 }
21205
21206
21207
21208
21209 func (c *CampaignsGetCall) Context(ctx context.Context) *CampaignsGetCall {
21210 c.ctx_ = ctx
21211 return c
21212 }
21213
21214
21215
21216 func (c *CampaignsGetCall) Header() http.Header {
21217 if c.header_ == nil {
21218 c.header_ = make(http.Header)
21219 }
21220 return c.header_
21221 }
21222
21223 func (c *CampaignsGetCall) doRequest(alt string) (*http.Response, error) {
21224 reqHeaders := make(http.Header)
21225 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
21226 for k, v := range c.header_ {
21227 reqHeaders[k] = v
21228 }
21229 reqHeaders.Set("User-Agent", c.s.userAgent())
21230 if c.ifNoneMatch_ != "" {
21231 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
21232 }
21233 var body io.Reader = nil
21234 c.urlParams_.Set("alt", alt)
21235 c.urlParams_.Set("prettyPrint", "false")
21236 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/campaigns/{id}")
21237 urls += "?" + c.urlParams_.Encode()
21238 req, err := http.NewRequest("GET", urls, body)
21239 if err != nil {
21240 return nil, err
21241 }
21242 req.Header = reqHeaders
21243 googleapi.Expand(req.URL, map[string]string{
21244 "profileId": strconv.FormatInt(c.profileId, 10),
21245 "id": strconv.FormatInt(c.id, 10),
21246 })
21247 return gensupport.SendRequest(c.ctx_, c.s.client, req)
21248 }
21249
21250
21251
21252
21253
21254
21255
21256
21257 func (c *CampaignsGetCall) Do(opts ...googleapi.CallOption) (*Campaign, error) {
21258 gensupport.SetOptions(c.urlParams_, opts...)
21259 res, err := c.doRequest("json")
21260 if res != nil && res.StatusCode == http.StatusNotModified {
21261 if res.Body != nil {
21262 res.Body.Close()
21263 }
21264 return nil, &googleapi.Error{
21265 Code: res.StatusCode,
21266 Header: res.Header,
21267 }
21268 }
21269 if err != nil {
21270 return nil, err
21271 }
21272 defer googleapi.CloseBody(res)
21273 if err := googleapi.CheckResponse(res); err != nil {
21274 return nil, err
21275 }
21276 ret := &Campaign{
21277 ServerResponse: googleapi.ServerResponse{
21278 Header: res.Header,
21279 HTTPStatusCode: res.StatusCode,
21280 },
21281 }
21282 target := &ret
21283 if err := gensupport.DecodeResponse(target, res); err != nil {
21284 return nil, err
21285 }
21286 return ret, nil
21287
21288
21289
21290
21291
21292
21293
21294
21295
21296
21297
21298
21299
21300
21301
21302
21303
21304
21305
21306
21307
21308
21309
21310
21311
21312
21313
21314
21315
21316
21317
21318
21319
21320 }
21321
21322
21323
21324 type CampaignsInsertCall struct {
21325 s *Service
21326 profileId int64
21327 campaign *Campaign
21328 urlParams_ gensupport.URLParams
21329 ctx_ context.Context
21330 header_ http.Header
21331 }
21332
21333
21334 func (r *CampaignsService) Insert(profileId int64, campaign *Campaign) *CampaignsInsertCall {
21335 c := &CampaignsInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
21336 c.profileId = profileId
21337 c.campaign = campaign
21338 return c
21339 }
21340
21341
21342
21343
21344 func (c *CampaignsInsertCall) Fields(s ...googleapi.Field) *CampaignsInsertCall {
21345 c.urlParams_.Set("fields", googleapi.CombineFields(s))
21346 return c
21347 }
21348
21349
21350
21351
21352 func (c *CampaignsInsertCall) Context(ctx context.Context) *CampaignsInsertCall {
21353 c.ctx_ = ctx
21354 return c
21355 }
21356
21357
21358
21359 func (c *CampaignsInsertCall) Header() http.Header {
21360 if c.header_ == nil {
21361 c.header_ = make(http.Header)
21362 }
21363 return c.header_
21364 }
21365
21366 func (c *CampaignsInsertCall) doRequest(alt string) (*http.Response, error) {
21367 reqHeaders := make(http.Header)
21368 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
21369 for k, v := range c.header_ {
21370 reqHeaders[k] = v
21371 }
21372 reqHeaders.Set("User-Agent", c.s.userAgent())
21373 var body io.Reader = nil
21374 body, err := googleapi.WithoutDataWrapper.JSONReader(c.campaign)
21375 if err != nil {
21376 return nil, err
21377 }
21378 reqHeaders.Set("Content-Type", "application/json")
21379 c.urlParams_.Set("alt", alt)
21380 c.urlParams_.Set("prettyPrint", "false")
21381 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/campaigns")
21382 urls += "?" + c.urlParams_.Encode()
21383 req, err := http.NewRequest("POST", urls, body)
21384 if err != nil {
21385 return nil, err
21386 }
21387 req.Header = reqHeaders
21388 googleapi.Expand(req.URL, map[string]string{
21389 "profileId": strconv.FormatInt(c.profileId, 10),
21390 })
21391 return gensupport.SendRequest(c.ctx_, c.s.client, req)
21392 }
21393
21394
21395
21396
21397
21398
21399
21400
21401 func (c *CampaignsInsertCall) Do(opts ...googleapi.CallOption) (*Campaign, error) {
21402 gensupport.SetOptions(c.urlParams_, opts...)
21403 res, err := c.doRequest("json")
21404 if res != nil && res.StatusCode == http.StatusNotModified {
21405 if res.Body != nil {
21406 res.Body.Close()
21407 }
21408 return nil, &googleapi.Error{
21409 Code: res.StatusCode,
21410 Header: res.Header,
21411 }
21412 }
21413 if err != nil {
21414 return nil, err
21415 }
21416 defer googleapi.CloseBody(res)
21417 if err := googleapi.CheckResponse(res); err != nil {
21418 return nil, err
21419 }
21420 ret := &Campaign{
21421 ServerResponse: googleapi.ServerResponse{
21422 Header: res.Header,
21423 HTTPStatusCode: res.StatusCode,
21424 },
21425 }
21426 target := &ret
21427 if err := gensupport.DecodeResponse(target, res); err != nil {
21428 return nil, err
21429 }
21430 return ret, nil
21431
21432
21433
21434
21435
21436
21437
21438
21439
21440
21441
21442
21443
21444
21445
21446
21447
21448
21449
21450
21451
21452
21453
21454
21455
21456
21457
21458
21459 }
21460
21461
21462
21463 type CampaignsListCall struct {
21464 s *Service
21465 profileId int64
21466 urlParams_ gensupport.URLParams
21467 ifNoneMatch_ string
21468 ctx_ context.Context
21469 header_ http.Header
21470 }
21471
21472
21473
21474 func (r *CampaignsService) List(profileId int64) *CampaignsListCall {
21475 c := &CampaignsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
21476 c.profileId = profileId
21477 return c
21478 }
21479
21480
21481
21482
21483 func (c *CampaignsListCall) AdvertiserGroupIds(advertiserGroupIds ...int64) *CampaignsListCall {
21484 var advertiserGroupIds_ []string
21485 for _, v := range advertiserGroupIds {
21486 advertiserGroupIds_ = append(advertiserGroupIds_, fmt.Sprint(v))
21487 }
21488 c.urlParams_.SetMulti("advertiserGroupIds", advertiserGroupIds_)
21489 return c
21490 }
21491
21492
21493
21494 func (c *CampaignsListCall) AdvertiserIds(advertiserIds ...int64) *CampaignsListCall {
21495 var advertiserIds_ []string
21496 for _, v := range advertiserIds {
21497 advertiserIds_ = append(advertiserIds_, fmt.Sprint(v))
21498 }
21499 c.urlParams_.SetMulti("advertiserIds", advertiserIds_)
21500 return c
21501 }
21502
21503
21504
21505
21506 func (c *CampaignsListCall) Archived(archived bool) *CampaignsListCall {
21507 c.urlParams_.Set("archived", fmt.Sprint(archived))
21508 return c
21509 }
21510
21511
21512
21513
21514 func (c *CampaignsListCall) AtLeastOneOptimizationActivity(atLeastOneOptimizationActivity bool) *CampaignsListCall {
21515 c.urlParams_.Set("atLeastOneOptimizationActivity", fmt.Sprint(atLeastOneOptimizationActivity))
21516 return c
21517 }
21518
21519
21520
21521 func (c *CampaignsListCall) ExcludedIds(excludedIds ...int64) *CampaignsListCall {
21522 var excludedIds_ []string
21523 for _, v := range excludedIds {
21524 excludedIds_ = append(excludedIds_, fmt.Sprint(v))
21525 }
21526 c.urlParams_.SetMulti("excludedIds", excludedIds_)
21527 return c
21528 }
21529
21530
21531
21532 func (c *CampaignsListCall) Ids(ids ...int64) *CampaignsListCall {
21533 var ids_ []string
21534 for _, v := range ids {
21535 ids_ = append(ids_, fmt.Sprint(v))
21536 }
21537 c.urlParams_.SetMulti("ids", ids_)
21538 return c
21539 }
21540
21541
21542
21543 func (c *CampaignsListCall) MaxResults(maxResults int64) *CampaignsListCall {
21544 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
21545 return c
21546 }
21547
21548
21549
21550
21551 func (c *CampaignsListCall) OverriddenEventTagId(overriddenEventTagId int64) *CampaignsListCall {
21552 c.urlParams_.Set("overriddenEventTagId", fmt.Sprint(overriddenEventTagId))
21553 return c
21554 }
21555
21556
21557
21558 func (c *CampaignsListCall) PageToken(pageToken string) *CampaignsListCall {
21559 c.urlParams_.Set("pageToken", pageToken)
21560 return c
21561 }
21562
21563
21564
21565
21566
21567
21568
21569
21570
21571 func (c *CampaignsListCall) SearchString(searchString string) *CampaignsListCall {
21572 c.urlParams_.Set("searchString", searchString)
21573 return c
21574 }
21575
21576
21577
21578
21579
21580
21581
21582
21583 func (c *CampaignsListCall) SortField(sortField string) *CampaignsListCall {
21584 c.urlParams_.Set("sortField", sortField)
21585 return c
21586 }
21587
21588
21589
21590
21591
21592
21593
21594
21595 func (c *CampaignsListCall) SortOrder(sortOrder string) *CampaignsListCall {
21596 c.urlParams_.Set("sortOrder", sortOrder)
21597 return c
21598 }
21599
21600
21601
21602 func (c *CampaignsListCall) SubaccountId(subaccountId int64) *CampaignsListCall {
21603 c.urlParams_.Set("subaccountId", fmt.Sprint(subaccountId))
21604 return c
21605 }
21606
21607
21608
21609
21610 func (c *CampaignsListCall) Fields(s ...googleapi.Field) *CampaignsListCall {
21611 c.urlParams_.Set("fields", googleapi.CombineFields(s))
21612 return c
21613 }
21614
21615
21616
21617
21618
21619
21620 func (c *CampaignsListCall) IfNoneMatch(entityTag string) *CampaignsListCall {
21621 c.ifNoneMatch_ = entityTag
21622 return c
21623 }
21624
21625
21626
21627
21628 func (c *CampaignsListCall) Context(ctx context.Context) *CampaignsListCall {
21629 c.ctx_ = ctx
21630 return c
21631 }
21632
21633
21634
21635 func (c *CampaignsListCall) Header() http.Header {
21636 if c.header_ == nil {
21637 c.header_ = make(http.Header)
21638 }
21639 return c.header_
21640 }
21641
21642 func (c *CampaignsListCall) doRequest(alt string) (*http.Response, error) {
21643 reqHeaders := make(http.Header)
21644 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
21645 for k, v := range c.header_ {
21646 reqHeaders[k] = v
21647 }
21648 reqHeaders.Set("User-Agent", c.s.userAgent())
21649 if c.ifNoneMatch_ != "" {
21650 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
21651 }
21652 var body io.Reader = nil
21653 c.urlParams_.Set("alt", alt)
21654 c.urlParams_.Set("prettyPrint", "false")
21655 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/campaigns")
21656 urls += "?" + c.urlParams_.Encode()
21657 req, err := http.NewRequest("GET", urls, body)
21658 if err != nil {
21659 return nil, err
21660 }
21661 req.Header = reqHeaders
21662 googleapi.Expand(req.URL, map[string]string{
21663 "profileId": strconv.FormatInt(c.profileId, 10),
21664 })
21665 return gensupport.SendRequest(c.ctx_, c.s.client, req)
21666 }
21667
21668
21669
21670
21671
21672
21673
21674
21675 func (c *CampaignsListCall) Do(opts ...googleapi.CallOption) (*CampaignsListResponse, error) {
21676 gensupport.SetOptions(c.urlParams_, opts...)
21677 res, err := c.doRequest("json")
21678 if res != nil && res.StatusCode == http.StatusNotModified {
21679 if res.Body != nil {
21680 res.Body.Close()
21681 }
21682 return nil, &googleapi.Error{
21683 Code: res.StatusCode,
21684 Header: res.Header,
21685 }
21686 }
21687 if err != nil {
21688 return nil, err
21689 }
21690 defer googleapi.CloseBody(res)
21691 if err := googleapi.CheckResponse(res); err != nil {
21692 return nil, err
21693 }
21694 ret := &CampaignsListResponse{
21695 ServerResponse: googleapi.ServerResponse{
21696 Header: res.Header,
21697 HTTPStatusCode: res.StatusCode,
21698 },
21699 }
21700 target := &ret
21701 if err := gensupport.DecodeResponse(target, res); err != nil {
21702 return nil, err
21703 }
21704 return ret, nil
21705
21706
21707
21708
21709
21710
21711
21712
21713
21714
21715
21716
21717
21718
21719
21720
21721
21722
21723
21724
21725
21726
21727
21728
21729
21730
21731
21732
21733
21734
21735
21736
21737
21738
21739
21740
21741
21742
21743
21744
21745
21746
21747
21748
21749
21750
21751
21752
21753
21754
21755
21756
21757
21758
21759
21760
21761
21762
21763
21764
21765
21766
21767
21768
21769
21770
21771
21772
21773
21774
21775
21776
21777
21778
21779
21780
21781
21782
21783
21784
21785
21786
21787
21788
21789
21790
21791
21792
21793
21794
21795
21796
21797
21798
21799
21800
21801
21802
21803
21804
21805
21806
21807
21808
21809
21810
21811
21812
21813
21814
21815
21816
21817
21818
21819
21820
21821
21822
21823
21824
21825
21826
21827 }
21828
21829
21830
21831
21832 func (c *CampaignsListCall) Pages(ctx context.Context, f func(*CampaignsListResponse) error) error {
21833 c.ctx_ = ctx
21834 defer c.PageToken(c.urlParams_.Get("pageToken"))
21835 for {
21836 x, err := c.Do()
21837 if err != nil {
21838 return err
21839 }
21840 if err := f(x); err != nil {
21841 return err
21842 }
21843 if x.NextPageToken == "" {
21844 return nil
21845 }
21846 c.PageToken(x.NextPageToken)
21847 }
21848 }
21849
21850
21851
21852 type CampaignsPatchCall struct {
21853 s *Service
21854 profileId int64
21855 campaign *Campaign
21856 urlParams_ gensupport.URLParams
21857 ctx_ context.Context
21858 header_ http.Header
21859 }
21860
21861
21862
21863 func (r *CampaignsService) Patch(profileId int64, id int64, campaign *Campaign) *CampaignsPatchCall {
21864 c := &CampaignsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
21865 c.profileId = profileId
21866 c.urlParams_.Set("id", fmt.Sprint(id))
21867 c.campaign = campaign
21868 return c
21869 }
21870
21871
21872
21873
21874 func (c *CampaignsPatchCall) Fields(s ...googleapi.Field) *CampaignsPatchCall {
21875 c.urlParams_.Set("fields", googleapi.CombineFields(s))
21876 return c
21877 }
21878
21879
21880
21881
21882 func (c *CampaignsPatchCall) Context(ctx context.Context) *CampaignsPatchCall {
21883 c.ctx_ = ctx
21884 return c
21885 }
21886
21887
21888
21889 func (c *CampaignsPatchCall) Header() http.Header {
21890 if c.header_ == nil {
21891 c.header_ = make(http.Header)
21892 }
21893 return c.header_
21894 }
21895
21896 func (c *CampaignsPatchCall) doRequest(alt string) (*http.Response, error) {
21897 reqHeaders := make(http.Header)
21898 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
21899 for k, v := range c.header_ {
21900 reqHeaders[k] = v
21901 }
21902 reqHeaders.Set("User-Agent", c.s.userAgent())
21903 var body io.Reader = nil
21904 body, err := googleapi.WithoutDataWrapper.JSONReader(c.campaign)
21905 if err != nil {
21906 return nil, err
21907 }
21908 reqHeaders.Set("Content-Type", "application/json")
21909 c.urlParams_.Set("alt", alt)
21910 c.urlParams_.Set("prettyPrint", "false")
21911 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/campaigns")
21912 urls += "?" + c.urlParams_.Encode()
21913 req, err := http.NewRequest("PATCH", urls, body)
21914 if err != nil {
21915 return nil, err
21916 }
21917 req.Header = reqHeaders
21918 googleapi.Expand(req.URL, map[string]string{
21919 "profileId": strconv.FormatInt(c.profileId, 10),
21920 })
21921 return gensupport.SendRequest(c.ctx_, c.s.client, req)
21922 }
21923
21924
21925
21926
21927
21928
21929
21930
21931 func (c *CampaignsPatchCall) Do(opts ...googleapi.CallOption) (*Campaign, error) {
21932 gensupport.SetOptions(c.urlParams_, opts...)
21933 res, err := c.doRequest("json")
21934 if res != nil && res.StatusCode == http.StatusNotModified {
21935 if res.Body != nil {
21936 res.Body.Close()
21937 }
21938 return nil, &googleapi.Error{
21939 Code: res.StatusCode,
21940 Header: res.Header,
21941 }
21942 }
21943 if err != nil {
21944 return nil, err
21945 }
21946 defer googleapi.CloseBody(res)
21947 if err := googleapi.CheckResponse(res); err != nil {
21948 return nil, err
21949 }
21950 ret := &Campaign{
21951 ServerResponse: googleapi.ServerResponse{
21952 Header: res.Header,
21953 HTTPStatusCode: res.StatusCode,
21954 },
21955 }
21956 target := &ret
21957 if err := gensupport.DecodeResponse(target, res); err != nil {
21958 return nil, err
21959 }
21960 return ret, nil
21961
21962
21963
21964
21965
21966
21967
21968
21969
21970
21971
21972
21973
21974
21975
21976
21977
21978
21979
21980
21981
21982
21983
21984
21985
21986
21987
21988
21989
21990
21991
21992
21993
21994
21995
21996
21997 }
21998
21999
22000
22001 type CampaignsUpdateCall struct {
22002 s *Service
22003 profileId int64
22004 campaign *Campaign
22005 urlParams_ gensupport.URLParams
22006 ctx_ context.Context
22007 header_ http.Header
22008 }
22009
22010
22011 func (r *CampaignsService) Update(profileId int64, campaign *Campaign) *CampaignsUpdateCall {
22012 c := &CampaignsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
22013 c.profileId = profileId
22014 c.campaign = campaign
22015 return c
22016 }
22017
22018
22019
22020
22021 func (c *CampaignsUpdateCall) Fields(s ...googleapi.Field) *CampaignsUpdateCall {
22022 c.urlParams_.Set("fields", googleapi.CombineFields(s))
22023 return c
22024 }
22025
22026
22027
22028
22029 func (c *CampaignsUpdateCall) Context(ctx context.Context) *CampaignsUpdateCall {
22030 c.ctx_ = ctx
22031 return c
22032 }
22033
22034
22035
22036 func (c *CampaignsUpdateCall) Header() http.Header {
22037 if c.header_ == nil {
22038 c.header_ = make(http.Header)
22039 }
22040 return c.header_
22041 }
22042
22043 func (c *CampaignsUpdateCall) doRequest(alt string) (*http.Response, error) {
22044 reqHeaders := make(http.Header)
22045 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
22046 for k, v := range c.header_ {
22047 reqHeaders[k] = v
22048 }
22049 reqHeaders.Set("User-Agent", c.s.userAgent())
22050 var body io.Reader = nil
22051 body, err := googleapi.WithoutDataWrapper.JSONReader(c.campaign)
22052 if err != nil {
22053 return nil, err
22054 }
22055 reqHeaders.Set("Content-Type", "application/json")
22056 c.urlParams_.Set("alt", alt)
22057 c.urlParams_.Set("prettyPrint", "false")
22058 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/campaigns")
22059 urls += "?" + c.urlParams_.Encode()
22060 req, err := http.NewRequest("PUT", urls, body)
22061 if err != nil {
22062 return nil, err
22063 }
22064 req.Header = reqHeaders
22065 googleapi.Expand(req.URL, map[string]string{
22066 "profileId": strconv.FormatInt(c.profileId, 10),
22067 })
22068 return gensupport.SendRequest(c.ctx_, c.s.client, req)
22069 }
22070
22071
22072
22073
22074
22075
22076
22077
22078 func (c *CampaignsUpdateCall) Do(opts ...googleapi.CallOption) (*Campaign, error) {
22079 gensupport.SetOptions(c.urlParams_, opts...)
22080 res, err := c.doRequest("json")
22081 if res != nil && res.StatusCode == http.StatusNotModified {
22082 if res.Body != nil {
22083 res.Body.Close()
22084 }
22085 return nil, &googleapi.Error{
22086 Code: res.StatusCode,
22087 Header: res.Header,
22088 }
22089 }
22090 if err != nil {
22091 return nil, err
22092 }
22093 defer googleapi.CloseBody(res)
22094 if err := googleapi.CheckResponse(res); err != nil {
22095 return nil, err
22096 }
22097 ret := &Campaign{
22098 ServerResponse: googleapi.ServerResponse{
22099 Header: res.Header,
22100 HTTPStatusCode: res.StatusCode,
22101 },
22102 }
22103 target := &ret
22104 if err := gensupport.DecodeResponse(target, res); err != nil {
22105 return nil, err
22106 }
22107 return ret, nil
22108
22109
22110
22111
22112
22113
22114
22115
22116
22117
22118
22119
22120
22121
22122
22123
22124
22125
22126
22127
22128
22129
22130
22131
22132
22133
22134
22135
22136 }
22137
22138
22139
22140 type ChangeLogsGetCall struct {
22141 s *Service
22142 profileId int64
22143 id int64
22144 urlParams_ gensupport.URLParams
22145 ifNoneMatch_ string
22146 ctx_ context.Context
22147 header_ http.Header
22148 }
22149
22150
22151 func (r *ChangeLogsService) Get(profileId int64, id int64) *ChangeLogsGetCall {
22152 c := &ChangeLogsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
22153 c.profileId = profileId
22154 c.id = id
22155 return c
22156 }
22157
22158
22159
22160
22161 func (c *ChangeLogsGetCall) Fields(s ...googleapi.Field) *ChangeLogsGetCall {
22162 c.urlParams_.Set("fields", googleapi.CombineFields(s))
22163 return c
22164 }
22165
22166
22167
22168
22169
22170
22171 func (c *ChangeLogsGetCall) IfNoneMatch(entityTag string) *ChangeLogsGetCall {
22172 c.ifNoneMatch_ = entityTag
22173 return c
22174 }
22175
22176
22177
22178
22179 func (c *ChangeLogsGetCall) Context(ctx context.Context) *ChangeLogsGetCall {
22180 c.ctx_ = ctx
22181 return c
22182 }
22183
22184
22185
22186 func (c *ChangeLogsGetCall) Header() http.Header {
22187 if c.header_ == nil {
22188 c.header_ = make(http.Header)
22189 }
22190 return c.header_
22191 }
22192
22193 func (c *ChangeLogsGetCall) doRequest(alt string) (*http.Response, error) {
22194 reqHeaders := make(http.Header)
22195 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
22196 for k, v := range c.header_ {
22197 reqHeaders[k] = v
22198 }
22199 reqHeaders.Set("User-Agent", c.s.userAgent())
22200 if c.ifNoneMatch_ != "" {
22201 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
22202 }
22203 var body io.Reader = nil
22204 c.urlParams_.Set("alt", alt)
22205 c.urlParams_.Set("prettyPrint", "false")
22206 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/changeLogs/{id}")
22207 urls += "?" + c.urlParams_.Encode()
22208 req, err := http.NewRequest("GET", urls, body)
22209 if err != nil {
22210 return nil, err
22211 }
22212 req.Header = reqHeaders
22213 googleapi.Expand(req.URL, map[string]string{
22214 "profileId": strconv.FormatInt(c.profileId, 10),
22215 "id": strconv.FormatInt(c.id, 10),
22216 })
22217 return gensupport.SendRequest(c.ctx_, c.s.client, req)
22218 }
22219
22220
22221
22222
22223
22224
22225
22226
22227 func (c *ChangeLogsGetCall) Do(opts ...googleapi.CallOption) (*ChangeLog, error) {
22228 gensupport.SetOptions(c.urlParams_, opts...)
22229 res, err := c.doRequest("json")
22230 if res != nil && res.StatusCode == http.StatusNotModified {
22231 if res.Body != nil {
22232 res.Body.Close()
22233 }
22234 return nil, &googleapi.Error{
22235 Code: res.StatusCode,
22236 Header: res.Header,
22237 }
22238 }
22239 if err != nil {
22240 return nil, err
22241 }
22242 defer googleapi.CloseBody(res)
22243 if err := googleapi.CheckResponse(res); err != nil {
22244 return nil, err
22245 }
22246 ret := &ChangeLog{
22247 ServerResponse: googleapi.ServerResponse{
22248 Header: res.Header,
22249 HTTPStatusCode: res.StatusCode,
22250 },
22251 }
22252 target := &ret
22253 if err := gensupport.DecodeResponse(target, res); err != nil {
22254 return nil, err
22255 }
22256 return ret, nil
22257
22258
22259
22260
22261
22262
22263
22264
22265
22266
22267
22268
22269
22270
22271
22272
22273
22274
22275
22276
22277
22278
22279
22280
22281
22282
22283
22284
22285
22286
22287
22288
22289
22290 }
22291
22292
22293
22294 type ChangeLogsListCall struct {
22295 s *Service
22296 profileId int64
22297 urlParams_ gensupport.URLParams
22298 ifNoneMatch_ string
22299 ctx_ context.Context
22300 header_ http.Header
22301 }
22302
22303
22304 func (r *ChangeLogsService) List(profileId int64) *ChangeLogsListCall {
22305 c := &ChangeLogsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
22306 c.profileId = profileId
22307 return c
22308 }
22309
22310
22311
22312
22313
22314
22315
22316
22317
22318
22319
22320
22321
22322
22323
22324
22325
22326
22327
22328
22329
22330
22331
22332 func (c *ChangeLogsListCall) Action(action string) *ChangeLogsListCall {
22333 c.urlParams_.Set("action", action)
22334 return c
22335 }
22336
22337
22338
22339 func (c *ChangeLogsListCall) Ids(ids ...int64) *ChangeLogsListCall {
22340 var ids_ []string
22341 for _, v := range ids {
22342 ids_ = append(ids_, fmt.Sprint(v))
22343 }
22344 c.urlParams_.SetMulti("ids", ids_)
22345 return c
22346 }
22347
22348
22349
22350
22351
22352
22353
22354
22355
22356 func (c *ChangeLogsListCall) MaxChangeTime(maxChangeTime string) *ChangeLogsListCall {
22357 c.urlParams_.Set("maxChangeTime", maxChangeTime)
22358 return c
22359 }
22360
22361
22362
22363 func (c *ChangeLogsListCall) MaxResults(maxResults int64) *ChangeLogsListCall {
22364 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
22365 return c
22366 }
22367
22368
22369
22370
22371
22372
22373
22374
22375
22376 func (c *ChangeLogsListCall) MinChangeTime(minChangeTime string) *ChangeLogsListCall {
22377 c.urlParams_.Set("minChangeTime", minChangeTime)
22378 return c
22379 }
22380
22381
22382
22383 func (c *ChangeLogsListCall) ObjectIds(objectIds ...int64) *ChangeLogsListCall {
22384 var objectIds_ []string
22385 for _, v := range objectIds {
22386 objectIds_ = append(objectIds_, fmt.Sprint(v))
22387 }
22388 c.urlParams_.SetMulti("objectIds", objectIds_)
22389 return c
22390 }
22391
22392
22393
22394
22395
22396
22397
22398
22399
22400
22401
22402
22403
22404
22405
22406
22407
22408
22409
22410
22411
22412
22413
22414
22415
22416
22417
22418
22419
22420
22421
22422
22423
22424
22425
22426
22427
22428
22429
22430
22431
22432
22433
22434
22435
22436
22437 func (c *ChangeLogsListCall) ObjectType(objectType string) *ChangeLogsListCall {
22438 c.urlParams_.Set("objectType", objectType)
22439 return c
22440 }
22441
22442
22443
22444 func (c *ChangeLogsListCall) PageToken(pageToken string) *ChangeLogsListCall {
22445 c.urlParams_.Set("pageToken", pageToken)
22446 return c
22447 }
22448
22449
22450
22451
22452 func (c *ChangeLogsListCall) SearchString(searchString string) *ChangeLogsListCall {
22453 c.urlParams_.Set("searchString", searchString)
22454 return c
22455 }
22456
22457
22458
22459 func (c *ChangeLogsListCall) UserProfileIds(userProfileIds ...int64) *ChangeLogsListCall {
22460 var userProfileIds_ []string
22461 for _, v := range userProfileIds {
22462 userProfileIds_ = append(userProfileIds_, fmt.Sprint(v))
22463 }
22464 c.urlParams_.SetMulti("userProfileIds", userProfileIds_)
22465 return c
22466 }
22467
22468
22469
22470
22471 func (c *ChangeLogsListCall) Fields(s ...googleapi.Field) *ChangeLogsListCall {
22472 c.urlParams_.Set("fields", googleapi.CombineFields(s))
22473 return c
22474 }
22475
22476
22477
22478
22479
22480
22481 func (c *ChangeLogsListCall) IfNoneMatch(entityTag string) *ChangeLogsListCall {
22482 c.ifNoneMatch_ = entityTag
22483 return c
22484 }
22485
22486
22487
22488
22489 func (c *ChangeLogsListCall) Context(ctx context.Context) *ChangeLogsListCall {
22490 c.ctx_ = ctx
22491 return c
22492 }
22493
22494
22495
22496 func (c *ChangeLogsListCall) Header() http.Header {
22497 if c.header_ == nil {
22498 c.header_ = make(http.Header)
22499 }
22500 return c.header_
22501 }
22502
22503 func (c *ChangeLogsListCall) doRequest(alt string) (*http.Response, error) {
22504 reqHeaders := make(http.Header)
22505 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
22506 for k, v := range c.header_ {
22507 reqHeaders[k] = v
22508 }
22509 reqHeaders.Set("User-Agent", c.s.userAgent())
22510 if c.ifNoneMatch_ != "" {
22511 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
22512 }
22513 var body io.Reader = nil
22514 c.urlParams_.Set("alt", alt)
22515 c.urlParams_.Set("prettyPrint", "false")
22516 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/changeLogs")
22517 urls += "?" + c.urlParams_.Encode()
22518 req, err := http.NewRequest("GET", urls, body)
22519 if err != nil {
22520 return nil, err
22521 }
22522 req.Header = reqHeaders
22523 googleapi.Expand(req.URL, map[string]string{
22524 "profileId": strconv.FormatInt(c.profileId, 10),
22525 })
22526 return gensupport.SendRequest(c.ctx_, c.s.client, req)
22527 }
22528
22529
22530
22531
22532
22533
22534
22535
22536 func (c *ChangeLogsListCall) Do(opts ...googleapi.CallOption) (*ChangeLogsListResponse, error) {
22537 gensupport.SetOptions(c.urlParams_, opts...)
22538 res, err := c.doRequest("json")
22539 if res != nil && res.StatusCode == http.StatusNotModified {
22540 if res.Body != nil {
22541 res.Body.Close()
22542 }
22543 return nil, &googleapi.Error{
22544 Code: res.StatusCode,
22545 Header: res.Header,
22546 }
22547 }
22548 if err != nil {
22549 return nil, err
22550 }
22551 defer googleapi.CloseBody(res)
22552 if err := googleapi.CheckResponse(res); err != nil {
22553 return nil, err
22554 }
22555 ret := &ChangeLogsListResponse{
22556 ServerResponse: googleapi.ServerResponse{
22557 Header: res.Header,
22558 HTTPStatusCode: res.StatusCode,
22559 },
22560 }
22561 target := &ret
22562 if err := gensupport.DecodeResponse(target, res); err != nil {
22563 return nil, err
22564 }
22565 return ret, nil
22566
22567
22568
22569
22570
22571
22572
22573
22574
22575
22576
22577
22578
22579
22580
22581
22582
22583
22584
22585
22586
22587
22588
22589
22590
22591
22592
22593
22594
22595
22596
22597
22598
22599
22600
22601
22602
22603
22604
22605
22606
22607
22608
22609
22610
22611
22612
22613
22614
22615
22616
22617
22618
22619
22620
22621
22622
22623
22624
22625
22626
22627
22628
22629
22630
22631
22632
22633
22634
22635
22636
22637
22638
22639
22640
22641
22642
22643
22644
22645
22646
22647
22648
22649
22650
22651
22652
22653
22654
22655
22656
22657
22658
22659
22660
22661
22662
22663
22664
22665
22666
22667
22668
22669
22670
22671
22672
22673
22674
22675
22676
22677
22678
22679
22680
22681
22682
22683
22684
22685
22686
22687
22688
22689
22690
22691
22692
22693
22694
22695
22696
22697
22698
22699
22700
22701
22702
22703
22704
22705
22706
22707
22708
22709
22710
22711
22712
22713
22714
22715
22716
22717
22718
22719
22720
22721
22722
22723
22724
22725
22726
22727
22728
22729
22730
22731
22732
22733
22734
22735
22736
22737
22738
22739
22740
22741
22742
22743
22744
22745
22746
22747
22748
22749
22750
22751
22752
22753
22754
22755
22756
22757
22758
22759
22760
22761
22762
22763
22764
22765
22766
22767
22768
22769
22770
22771
22772
22773 }
22774
22775
22776
22777
22778 func (c *ChangeLogsListCall) Pages(ctx context.Context, f func(*ChangeLogsListResponse) error) error {
22779 c.ctx_ = ctx
22780 defer c.PageToken(c.urlParams_.Get("pageToken"))
22781 for {
22782 x, err := c.Do()
22783 if err != nil {
22784 return err
22785 }
22786 if err := f(x); err != nil {
22787 return err
22788 }
22789 if x.NextPageToken == "" {
22790 return nil
22791 }
22792 c.PageToken(x.NextPageToken)
22793 }
22794 }
22795
22796
22797
22798 type CitiesListCall struct {
22799 s *Service
22800 profileId int64
22801 urlParams_ gensupport.URLParams
22802 ifNoneMatch_ string
22803 ctx_ context.Context
22804 header_ http.Header
22805 }
22806
22807
22808 func (r *CitiesService) List(profileId int64) *CitiesListCall {
22809 c := &CitiesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
22810 c.profileId = profileId
22811 return c
22812 }
22813
22814
22815
22816 func (c *CitiesListCall) CountryDartIds(countryDartIds ...int64) *CitiesListCall {
22817 var countryDartIds_ []string
22818 for _, v := range countryDartIds {
22819 countryDartIds_ = append(countryDartIds_, fmt.Sprint(v))
22820 }
22821 c.urlParams_.SetMulti("countryDartIds", countryDartIds_)
22822 return c
22823 }
22824
22825
22826
22827 func (c *CitiesListCall) DartIds(dartIds ...int64) *CitiesListCall {
22828 var dartIds_ []string
22829 for _, v := range dartIds {
22830 dartIds_ = append(dartIds_, fmt.Sprint(v))
22831 }
22832 c.urlParams_.SetMulti("dartIds", dartIds_)
22833 return c
22834 }
22835
22836
22837
22838 func (c *CitiesListCall) NamePrefix(namePrefix string) *CitiesListCall {
22839 c.urlParams_.Set("namePrefix", namePrefix)
22840 return c
22841 }
22842
22843
22844
22845 func (c *CitiesListCall) RegionDartIds(regionDartIds ...int64) *CitiesListCall {
22846 var regionDartIds_ []string
22847 for _, v := range regionDartIds {
22848 regionDartIds_ = append(regionDartIds_, fmt.Sprint(v))
22849 }
22850 c.urlParams_.SetMulti("regionDartIds", regionDartIds_)
22851 return c
22852 }
22853
22854
22855
22856
22857 func (c *CitiesListCall) Fields(s ...googleapi.Field) *CitiesListCall {
22858 c.urlParams_.Set("fields", googleapi.CombineFields(s))
22859 return c
22860 }
22861
22862
22863
22864
22865
22866
22867 func (c *CitiesListCall) IfNoneMatch(entityTag string) *CitiesListCall {
22868 c.ifNoneMatch_ = entityTag
22869 return c
22870 }
22871
22872
22873
22874
22875 func (c *CitiesListCall) Context(ctx context.Context) *CitiesListCall {
22876 c.ctx_ = ctx
22877 return c
22878 }
22879
22880
22881
22882 func (c *CitiesListCall) Header() http.Header {
22883 if c.header_ == nil {
22884 c.header_ = make(http.Header)
22885 }
22886 return c.header_
22887 }
22888
22889 func (c *CitiesListCall) doRequest(alt string) (*http.Response, error) {
22890 reqHeaders := make(http.Header)
22891 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
22892 for k, v := range c.header_ {
22893 reqHeaders[k] = v
22894 }
22895 reqHeaders.Set("User-Agent", c.s.userAgent())
22896 if c.ifNoneMatch_ != "" {
22897 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
22898 }
22899 var body io.Reader = nil
22900 c.urlParams_.Set("alt", alt)
22901 c.urlParams_.Set("prettyPrint", "false")
22902 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/cities")
22903 urls += "?" + c.urlParams_.Encode()
22904 req, err := http.NewRequest("GET", urls, body)
22905 if err != nil {
22906 return nil, err
22907 }
22908 req.Header = reqHeaders
22909 googleapi.Expand(req.URL, map[string]string{
22910 "profileId": strconv.FormatInt(c.profileId, 10),
22911 })
22912 return gensupport.SendRequest(c.ctx_, c.s.client, req)
22913 }
22914
22915
22916
22917
22918
22919
22920
22921
22922 func (c *CitiesListCall) Do(opts ...googleapi.CallOption) (*CitiesListResponse, error) {
22923 gensupport.SetOptions(c.urlParams_, opts...)
22924 res, err := c.doRequest("json")
22925 if res != nil && res.StatusCode == http.StatusNotModified {
22926 if res.Body != nil {
22927 res.Body.Close()
22928 }
22929 return nil, &googleapi.Error{
22930 Code: res.StatusCode,
22931 Header: res.Header,
22932 }
22933 }
22934 if err != nil {
22935 return nil, err
22936 }
22937 defer googleapi.CloseBody(res)
22938 if err := googleapi.CheckResponse(res); err != nil {
22939 return nil, err
22940 }
22941 ret := &CitiesListResponse{
22942 ServerResponse: googleapi.ServerResponse{
22943 Header: res.Header,
22944 HTTPStatusCode: res.StatusCode,
22945 },
22946 }
22947 target := &ret
22948 if err := gensupport.DecodeResponse(target, res); err != nil {
22949 return nil, err
22950 }
22951 return ret, nil
22952
22953
22954
22955
22956
22957
22958
22959
22960
22961
22962
22963
22964
22965
22966
22967
22968
22969
22970
22971
22972
22973
22974
22975
22976
22977
22978
22979
22980
22981
22982
22983
22984
22985
22986
22987
22988
22989
22990
22991
22992
22993
22994
22995
22996
22997
22998
22999
23000
23001
23002
23003 }
23004
23005
23006
23007 type ConnectionTypesGetCall struct {
23008 s *Service
23009 profileId int64
23010 id int64
23011 urlParams_ gensupport.URLParams
23012 ifNoneMatch_ string
23013 ctx_ context.Context
23014 header_ http.Header
23015 }
23016
23017
23018 func (r *ConnectionTypesService) Get(profileId int64, id int64) *ConnectionTypesGetCall {
23019 c := &ConnectionTypesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
23020 c.profileId = profileId
23021 c.id = id
23022 return c
23023 }
23024
23025
23026
23027
23028 func (c *ConnectionTypesGetCall) Fields(s ...googleapi.Field) *ConnectionTypesGetCall {
23029 c.urlParams_.Set("fields", googleapi.CombineFields(s))
23030 return c
23031 }
23032
23033
23034
23035
23036
23037
23038 func (c *ConnectionTypesGetCall) IfNoneMatch(entityTag string) *ConnectionTypesGetCall {
23039 c.ifNoneMatch_ = entityTag
23040 return c
23041 }
23042
23043
23044
23045
23046 func (c *ConnectionTypesGetCall) Context(ctx context.Context) *ConnectionTypesGetCall {
23047 c.ctx_ = ctx
23048 return c
23049 }
23050
23051
23052
23053 func (c *ConnectionTypesGetCall) Header() http.Header {
23054 if c.header_ == nil {
23055 c.header_ = make(http.Header)
23056 }
23057 return c.header_
23058 }
23059
23060 func (c *ConnectionTypesGetCall) doRequest(alt string) (*http.Response, error) {
23061 reqHeaders := make(http.Header)
23062 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
23063 for k, v := range c.header_ {
23064 reqHeaders[k] = v
23065 }
23066 reqHeaders.Set("User-Agent", c.s.userAgent())
23067 if c.ifNoneMatch_ != "" {
23068 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
23069 }
23070 var body io.Reader = nil
23071 c.urlParams_.Set("alt", alt)
23072 c.urlParams_.Set("prettyPrint", "false")
23073 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/connectionTypes/{id}")
23074 urls += "?" + c.urlParams_.Encode()
23075 req, err := http.NewRequest("GET", urls, body)
23076 if err != nil {
23077 return nil, err
23078 }
23079 req.Header = reqHeaders
23080 googleapi.Expand(req.URL, map[string]string{
23081 "profileId": strconv.FormatInt(c.profileId, 10),
23082 "id": strconv.FormatInt(c.id, 10),
23083 })
23084 return gensupport.SendRequest(c.ctx_, c.s.client, req)
23085 }
23086
23087
23088
23089
23090
23091
23092
23093
23094 func (c *ConnectionTypesGetCall) Do(opts ...googleapi.CallOption) (*ConnectionType, error) {
23095 gensupport.SetOptions(c.urlParams_, opts...)
23096 res, err := c.doRequest("json")
23097 if res != nil && res.StatusCode == http.StatusNotModified {
23098 if res.Body != nil {
23099 res.Body.Close()
23100 }
23101 return nil, &googleapi.Error{
23102 Code: res.StatusCode,
23103 Header: res.Header,
23104 }
23105 }
23106 if err != nil {
23107 return nil, err
23108 }
23109 defer googleapi.CloseBody(res)
23110 if err := googleapi.CheckResponse(res); err != nil {
23111 return nil, err
23112 }
23113 ret := &ConnectionType{
23114 ServerResponse: googleapi.ServerResponse{
23115 Header: res.Header,
23116 HTTPStatusCode: res.StatusCode,
23117 },
23118 }
23119 target := &ret
23120 if err := gensupport.DecodeResponse(target, res); err != nil {
23121 return nil, err
23122 }
23123 return ret, nil
23124
23125
23126
23127
23128
23129
23130
23131
23132
23133
23134
23135
23136
23137
23138
23139
23140
23141
23142
23143
23144
23145
23146
23147
23148
23149
23150
23151
23152
23153
23154
23155
23156
23157 }
23158
23159
23160
23161 type ConnectionTypesListCall struct {
23162 s *Service
23163 profileId int64
23164 urlParams_ gensupport.URLParams
23165 ifNoneMatch_ string
23166 ctx_ context.Context
23167 header_ http.Header
23168 }
23169
23170
23171 func (r *ConnectionTypesService) List(profileId int64) *ConnectionTypesListCall {
23172 c := &ConnectionTypesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
23173 c.profileId = profileId
23174 return c
23175 }
23176
23177
23178
23179
23180 func (c *ConnectionTypesListCall) Fields(s ...googleapi.Field) *ConnectionTypesListCall {
23181 c.urlParams_.Set("fields", googleapi.CombineFields(s))
23182 return c
23183 }
23184
23185
23186
23187
23188
23189
23190 func (c *ConnectionTypesListCall) IfNoneMatch(entityTag string) *ConnectionTypesListCall {
23191 c.ifNoneMatch_ = entityTag
23192 return c
23193 }
23194
23195
23196
23197
23198 func (c *ConnectionTypesListCall) Context(ctx context.Context) *ConnectionTypesListCall {
23199 c.ctx_ = ctx
23200 return c
23201 }
23202
23203
23204
23205 func (c *ConnectionTypesListCall) Header() http.Header {
23206 if c.header_ == nil {
23207 c.header_ = make(http.Header)
23208 }
23209 return c.header_
23210 }
23211
23212 func (c *ConnectionTypesListCall) doRequest(alt string) (*http.Response, error) {
23213 reqHeaders := make(http.Header)
23214 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
23215 for k, v := range c.header_ {
23216 reqHeaders[k] = v
23217 }
23218 reqHeaders.Set("User-Agent", c.s.userAgent())
23219 if c.ifNoneMatch_ != "" {
23220 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
23221 }
23222 var body io.Reader = nil
23223 c.urlParams_.Set("alt", alt)
23224 c.urlParams_.Set("prettyPrint", "false")
23225 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/connectionTypes")
23226 urls += "?" + c.urlParams_.Encode()
23227 req, err := http.NewRequest("GET", urls, body)
23228 if err != nil {
23229 return nil, err
23230 }
23231 req.Header = reqHeaders
23232 googleapi.Expand(req.URL, map[string]string{
23233 "profileId": strconv.FormatInt(c.profileId, 10),
23234 })
23235 return gensupport.SendRequest(c.ctx_, c.s.client, req)
23236 }
23237
23238
23239
23240
23241
23242
23243
23244
23245 func (c *ConnectionTypesListCall) Do(opts ...googleapi.CallOption) (*ConnectionTypesListResponse, error) {
23246 gensupport.SetOptions(c.urlParams_, opts...)
23247 res, err := c.doRequest("json")
23248 if res != nil && res.StatusCode == http.StatusNotModified {
23249 if res.Body != nil {
23250 res.Body.Close()
23251 }
23252 return nil, &googleapi.Error{
23253 Code: res.StatusCode,
23254 Header: res.Header,
23255 }
23256 }
23257 if err != nil {
23258 return nil, err
23259 }
23260 defer googleapi.CloseBody(res)
23261 if err := googleapi.CheckResponse(res); err != nil {
23262 return nil, err
23263 }
23264 ret := &ConnectionTypesListResponse{
23265 ServerResponse: googleapi.ServerResponse{
23266 Header: res.Header,
23267 HTTPStatusCode: res.StatusCode,
23268 },
23269 }
23270 target := &ret
23271 if err := gensupport.DecodeResponse(target, res); err != nil {
23272 return nil, err
23273 }
23274 return ret, nil
23275
23276
23277
23278
23279
23280
23281
23282
23283
23284
23285
23286
23287
23288
23289
23290
23291
23292
23293
23294
23295
23296
23297
23298
23299
23300 }
23301
23302
23303
23304 type ContentCategoriesDeleteCall struct {
23305 s *Service
23306 profileId int64
23307 id int64
23308 urlParams_ gensupport.URLParams
23309 ctx_ context.Context
23310 header_ http.Header
23311 }
23312
23313
23314 func (r *ContentCategoriesService) Delete(profileId int64, id int64) *ContentCategoriesDeleteCall {
23315 c := &ContentCategoriesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
23316 c.profileId = profileId
23317 c.id = id
23318 return c
23319 }
23320
23321
23322
23323
23324 func (c *ContentCategoriesDeleteCall) Fields(s ...googleapi.Field) *ContentCategoriesDeleteCall {
23325 c.urlParams_.Set("fields", googleapi.CombineFields(s))
23326 return c
23327 }
23328
23329
23330
23331
23332 func (c *ContentCategoriesDeleteCall) Context(ctx context.Context) *ContentCategoriesDeleteCall {
23333 c.ctx_ = ctx
23334 return c
23335 }
23336
23337
23338
23339 func (c *ContentCategoriesDeleteCall) Header() http.Header {
23340 if c.header_ == nil {
23341 c.header_ = make(http.Header)
23342 }
23343 return c.header_
23344 }
23345
23346 func (c *ContentCategoriesDeleteCall) doRequest(alt string) (*http.Response, error) {
23347 reqHeaders := make(http.Header)
23348 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
23349 for k, v := range c.header_ {
23350 reqHeaders[k] = v
23351 }
23352 reqHeaders.Set("User-Agent", c.s.userAgent())
23353 var body io.Reader = nil
23354 c.urlParams_.Set("alt", alt)
23355 c.urlParams_.Set("prettyPrint", "false")
23356 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/contentCategories/{id}")
23357 urls += "?" + c.urlParams_.Encode()
23358 req, err := http.NewRequest("DELETE", urls, body)
23359 if err != nil {
23360 return nil, err
23361 }
23362 req.Header = reqHeaders
23363 googleapi.Expand(req.URL, map[string]string{
23364 "profileId": strconv.FormatInt(c.profileId, 10),
23365 "id": strconv.FormatInt(c.id, 10),
23366 })
23367 return gensupport.SendRequest(c.ctx_, c.s.client, req)
23368 }
23369
23370
23371 func (c *ContentCategoriesDeleteCall) Do(opts ...googleapi.CallOption) error {
23372 gensupport.SetOptions(c.urlParams_, opts...)
23373 res, err := c.doRequest("json")
23374 if err != nil {
23375 return err
23376 }
23377 defer googleapi.CloseBody(res)
23378 if err := googleapi.CheckResponse(res); err != nil {
23379 return err
23380 }
23381 return nil
23382
23383
23384
23385
23386
23387
23388
23389
23390
23391
23392
23393
23394
23395
23396
23397
23398
23399
23400
23401
23402
23403
23404
23405
23406
23407
23408
23409
23410
23411
23412 }
23413
23414
23415
23416 type ContentCategoriesGetCall struct {
23417 s *Service
23418 profileId int64
23419 id int64
23420 urlParams_ gensupport.URLParams
23421 ifNoneMatch_ string
23422 ctx_ context.Context
23423 header_ http.Header
23424 }
23425
23426
23427 func (r *ContentCategoriesService) Get(profileId int64, id int64) *ContentCategoriesGetCall {
23428 c := &ContentCategoriesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
23429 c.profileId = profileId
23430 c.id = id
23431 return c
23432 }
23433
23434
23435
23436
23437 func (c *ContentCategoriesGetCall) Fields(s ...googleapi.Field) *ContentCategoriesGetCall {
23438 c.urlParams_.Set("fields", googleapi.CombineFields(s))
23439 return c
23440 }
23441
23442
23443
23444
23445
23446
23447 func (c *ContentCategoriesGetCall) IfNoneMatch(entityTag string) *ContentCategoriesGetCall {
23448 c.ifNoneMatch_ = entityTag
23449 return c
23450 }
23451
23452
23453
23454
23455 func (c *ContentCategoriesGetCall) Context(ctx context.Context) *ContentCategoriesGetCall {
23456 c.ctx_ = ctx
23457 return c
23458 }
23459
23460
23461
23462 func (c *ContentCategoriesGetCall) Header() http.Header {
23463 if c.header_ == nil {
23464 c.header_ = make(http.Header)
23465 }
23466 return c.header_
23467 }
23468
23469 func (c *ContentCategoriesGetCall) doRequest(alt string) (*http.Response, error) {
23470 reqHeaders := make(http.Header)
23471 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
23472 for k, v := range c.header_ {
23473 reqHeaders[k] = v
23474 }
23475 reqHeaders.Set("User-Agent", c.s.userAgent())
23476 if c.ifNoneMatch_ != "" {
23477 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
23478 }
23479 var body io.Reader = nil
23480 c.urlParams_.Set("alt", alt)
23481 c.urlParams_.Set("prettyPrint", "false")
23482 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/contentCategories/{id}")
23483 urls += "?" + c.urlParams_.Encode()
23484 req, err := http.NewRequest("GET", urls, body)
23485 if err != nil {
23486 return nil, err
23487 }
23488 req.Header = reqHeaders
23489 googleapi.Expand(req.URL, map[string]string{
23490 "profileId": strconv.FormatInt(c.profileId, 10),
23491 "id": strconv.FormatInt(c.id, 10),
23492 })
23493 return gensupport.SendRequest(c.ctx_, c.s.client, req)
23494 }
23495
23496
23497
23498
23499
23500
23501
23502
23503 func (c *ContentCategoriesGetCall) Do(opts ...googleapi.CallOption) (*ContentCategory, error) {
23504 gensupport.SetOptions(c.urlParams_, opts...)
23505 res, err := c.doRequest("json")
23506 if res != nil && res.StatusCode == http.StatusNotModified {
23507 if res.Body != nil {
23508 res.Body.Close()
23509 }
23510 return nil, &googleapi.Error{
23511 Code: res.StatusCode,
23512 Header: res.Header,
23513 }
23514 }
23515 if err != nil {
23516 return nil, err
23517 }
23518 defer googleapi.CloseBody(res)
23519 if err := googleapi.CheckResponse(res); err != nil {
23520 return nil, err
23521 }
23522 ret := &ContentCategory{
23523 ServerResponse: googleapi.ServerResponse{
23524 Header: res.Header,
23525 HTTPStatusCode: res.StatusCode,
23526 },
23527 }
23528 target := &ret
23529 if err := gensupport.DecodeResponse(target, res); err != nil {
23530 return nil, err
23531 }
23532 return ret, nil
23533
23534
23535
23536
23537
23538
23539
23540
23541
23542
23543
23544
23545
23546
23547
23548
23549
23550
23551
23552
23553
23554
23555
23556
23557
23558
23559
23560
23561
23562
23563
23564
23565
23566 }
23567
23568
23569
23570 type ContentCategoriesInsertCall struct {
23571 s *Service
23572 profileId int64
23573 contentcategory *ContentCategory
23574 urlParams_ gensupport.URLParams
23575 ctx_ context.Context
23576 header_ http.Header
23577 }
23578
23579
23580 func (r *ContentCategoriesService) Insert(profileId int64, contentcategory *ContentCategory) *ContentCategoriesInsertCall {
23581 c := &ContentCategoriesInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
23582 c.profileId = profileId
23583 c.contentcategory = contentcategory
23584 return c
23585 }
23586
23587
23588
23589
23590 func (c *ContentCategoriesInsertCall) Fields(s ...googleapi.Field) *ContentCategoriesInsertCall {
23591 c.urlParams_.Set("fields", googleapi.CombineFields(s))
23592 return c
23593 }
23594
23595
23596
23597
23598 func (c *ContentCategoriesInsertCall) Context(ctx context.Context) *ContentCategoriesInsertCall {
23599 c.ctx_ = ctx
23600 return c
23601 }
23602
23603
23604
23605 func (c *ContentCategoriesInsertCall) Header() http.Header {
23606 if c.header_ == nil {
23607 c.header_ = make(http.Header)
23608 }
23609 return c.header_
23610 }
23611
23612 func (c *ContentCategoriesInsertCall) doRequest(alt string) (*http.Response, error) {
23613 reqHeaders := make(http.Header)
23614 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
23615 for k, v := range c.header_ {
23616 reqHeaders[k] = v
23617 }
23618 reqHeaders.Set("User-Agent", c.s.userAgent())
23619 var body io.Reader = nil
23620 body, err := googleapi.WithoutDataWrapper.JSONReader(c.contentcategory)
23621 if err != nil {
23622 return nil, err
23623 }
23624 reqHeaders.Set("Content-Type", "application/json")
23625 c.urlParams_.Set("alt", alt)
23626 c.urlParams_.Set("prettyPrint", "false")
23627 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/contentCategories")
23628 urls += "?" + c.urlParams_.Encode()
23629 req, err := http.NewRequest("POST", urls, body)
23630 if err != nil {
23631 return nil, err
23632 }
23633 req.Header = reqHeaders
23634 googleapi.Expand(req.URL, map[string]string{
23635 "profileId": strconv.FormatInt(c.profileId, 10),
23636 })
23637 return gensupport.SendRequest(c.ctx_, c.s.client, req)
23638 }
23639
23640
23641
23642
23643
23644
23645
23646
23647 func (c *ContentCategoriesInsertCall) Do(opts ...googleapi.CallOption) (*ContentCategory, error) {
23648 gensupport.SetOptions(c.urlParams_, opts...)
23649 res, err := c.doRequest("json")
23650 if res != nil && res.StatusCode == http.StatusNotModified {
23651 if res.Body != nil {
23652 res.Body.Close()
23653 }
23654 return nil, &googleapi.Error{
23655 Code: res.StatusCode,
23656 Header: res.Header,
23657 }
23658 }
23659 if err != nil {
23660 return nil, err
23661 }
23662 defer googleapi.CloseBody(res)
23663 if err := googleapi.CheckResponse(res); err != nil {
23664 return nil, err
23665 }
23666 ret := &ContentCategory{
23667 ServerResponse: googleapi.ServerResponse{
23668 Header: res.Header,
23669 HTTPStatusCode: res.StatusCode,
23670 },
23671 }
23672 target := &ret
23673 if err := gensupport.DecodeResponse(target, res); err != nil {
23674 return nil, err
23675 }
23676 return ret, nil
23677
23678
23679
23680
23681
23682
23683
23684
23685
23686
23687
23688
23689
23690
23691
23692
23693
23694
23695
23696
23697
23698
23699
23700
23701
23702
23703
23704
23705 }
23706
23707
23708
23709 type ContentCategoriesListCall struct {
23710 s *Service
23711 profileId int64
23712 urlParams_ gensupport.URLParams
23713 ifNoneMatch_ string
23714 ctx_ context.Context
23715 header_ http.Header
23716 }
23717
23718
23719
23720 func (r *ContentCategoriesService) List(profileId int64) *ContentCategoriesListCall {
23721 c := &ContentCategoriesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
23722 c.profileId = profileId
23723 return c
23724 }
23725
23726
23727
23728 func (c *ContentCategoriesListCall) Ids(ids ...int64) *ContentCategoriesListCall {
23729 var ids_ []string
23730 for _, v := range ids {
23731 ids_ = append(ids_, fmt.Sprint(v))
23732 }
23733 c.urlParams_.SetMulti("ids", ids_)
23734 return c
23735 }
23736
23737
23738
23739 func (c *ContentCategoriesListCall) MaxResults(maxResults int64) *ContentCategoriesListCall {
23740 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
23741 return c
23742 }
23743
23744
23745
23746 func (c *ContentCategoriesListCall) PageToken(pageToken string) *ContentCategoriesListCall {
23747 c.urlParams_.Set("pageToken", pageToken)
23748 return c
23749 }
23750
23751
23752
23753
23754
23755
23756
23757
23758
23759
23760 func (c *ContentCategoriesListCall) SearchString(searchString string) *ContentCategoriesListCall {
23761 c.urlParams_.Set("searchString", searchString)
23762 return c
23763 }
23764
23765
23766
23767
23768
23769
23770
23771
23772 func (c *ContentCategoriesListCall) SortField(sortField string) *ContentCategoriesListCall {
23773 c.urlParams_.Set("sortField", sortField)
23774 return c
23775 }
23776
23777
23778
23779
23780
23781
23782
23783
23784 func (c *ContentCategoriesListCall) SortOrder(sortOrder string) *ContentCategoriesListCall {
23785 c.urlParams_.Set("sortOrder", sortOrder)
23786 return c
23787 }
23788
23789
23790
23791
23792 func (c *ContentCategoriesListCall) Fields(s ...googleapi.Field) *ContentCategoriesListCall {
23793 c.urlParams_.Set("fields", googleapi.CombineFields(s))
23794 return c
23795 }
23796
23797
23798
23799
23800
23801
23802 func (c *ContentCategoriesListCall) IfNoneMatch(entityTag string) *ContentCategoriesListCall {
23803 c.ifNoneMatch_ = entityTag
23804 return c
23805 }
23806
23807
23808
23809
23810 func (c *ContentCategoriesListCall) Context(ctx context.Context) *ContentCategoriesListCall {
23811 c.ctx_ = ctx
23812 return c
23813 }
23814
23815
23816
23817 func (c *ContentCategoriesListCall) Header() http.Header {
23818 if c.header_ == nil {
23819 c.header_ = make(http.Header)
23820 }
23821 return c.header_
23822 }
23823
23824 func (c *ContentCategoriesListCall) doRequest(alt string) (*http.Response, error) {
23825 reqHeaders := make(http.Header)
23826 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
23827 for k, v := range c.header_ {
23828 reqHeaders[k] = v
23829 }
23830 reqHeaders.Set("User-Agent", c.s.userAgent())
23831 if c.ifNoneMatch_ != "" {
23832 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
23833 }
23834 var body io.Reader = nil
23835 c.urlParams_.Set("alt", alt)
23836 c.urlParams_.Set("prettyPrint", "false")
23837 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/contentCategories")
23838 urls += "?" + c.urlParams_.Encode()
23839 req, err := http.NewRequest("GET", urls, body)
23840 if err != nil {
23841 return nil, err
23842 }
23843 req.Header = reqHeaders
23844 googleapi.Expand(req.URL, map[string]string{
23845 "profileId": strconv.FormatInt(c.profileId, 10),
23846 })
23847 return gensupport.SendRequest(c.ctx_, c.s.client, req)
23848 }
23849
23850
23851
23852
23853
23854
23855
23856
23857 func (c *ContentCategoriesListCall) Do(opts ...googleapi.CallOption) (*ContentCategoriesListResponse, error) {
23858 gensupport.SetOptions(c.urlParams_, opts...)
23859 res, err := c.doRequest("json")
23860 if res != nil && res.StatusCode == http.StatusNotModified {
23861 if res.Body != nil {
23862 res.Body.Close()
23863 }
23864 return nil, &googleapi.Error{
23865 Code: res.StatusCode,
23866 Header: res.Header,
23867 }
23868 }
23869 if err != nil {
23870 return nil, err
23871 }
23872 defer googleapi.CloseBody(res)
23873 if err := googleapi.CheckResponse(res); err != nil {
23874 return nil, err
23875 }
23876 ret := &ContentCategoriesListResponse{
23877 ServerResponse: googleapi.ServerResponse{
23878 Header: res.Header,
23879 HTTPStatusCode: res.StatusCode,
23880 },
23881 }
23882 target := &ret
23883 if err := gensupport.DecodeResponse(target, res); err != nil {
23884 return nil, err
23885 }
23886 return ret, nil
23887
23888
23889
23890
23891
23892
23893
23894
23895
23896
23897
23898
23899
23900
23901
23902
23903
23904
23905
23906
23907
23908
23909
23910
23911
23912
23913
23914
23915
23916
23917
23918
23919
23920
23921
23922
23923
23924
23925
23926
23927
23928
23929
23930
23931
23932
23933
23934
23935
23936
23937
23938
23939
23940
23941
23942
23943
23944
23945
23946
23947
23948
23949
23950
23951
23952
23953
23954
23955
23956
23957
23958
23959
23960
23961
23962
23963
23964
23965
23966 }
23967
23968
23969
23970
23971 func (c *ContentCategoriesListCall) Pages(ctx context.Context, f func(*ContentCategoriesListResponse) error) error {
23972 c.ctx_ = ctx
23973 defer c.PageToken(c.urlParams_.Get("pageToken"))
23974 for {
23975 x, err := c.Do()
23976 if err != nil {
23977 return err
23978 }
23979 if err := f(x); err != nil {
23980 return err
23981 }
23982 if x.NextPageToken == "" {
23983 return nil
23984 }
23985 c.PageToken(x.NextPageToken)
23986 }
23987 }
23988
23989
23990
23991 type ContentCategoriesPatchCall struct {
23992 s *Service
23993 profileId int64
23994 contentcategory *ContentCategory
23995 urlParams_ gensupport.URLParams
23996 ctx_ context.Context
23997 header_ http.Header
23998 }
23999
24000
24001
24002 func (r *ContentCategoriesService) Patch(profileId int64, id int64, contentcategory *ContentCategory) *ContentCategoriesPatchCall {
24003 c := &ContentCategoriesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
24004 c.profileId = profileId
24005 c.urlParams_.Set("id", fmt.Sprint(id))
24006 c.contentcategory = contentcategory
24007 return c
24008 }
24009
24010
24011
24012
24013 func (c *ContentCategoriesPatchCall) Fields(s ...googleapi.Field) *ContentCategoriesPatchCall {
24014 c.urlParams_.Set("fields", googleapi.CombineFields(s))
24015 return c
24016 }
24017
24018
24019
24020
24021 func (c *ContentCategoriesPatchCall) Context(ctx context.Context) *ContentCategoriesPatchCall {
24022 c.ctx_ = ctx
24023 return c
24024 }
24025
24026
24027
24028 func (c *ContentCategoriesPatchCall) Header() http.Header {
24029 if c.header_ == nil {
24030 c.header_ = make(http.Header)
24031 }
24032 return c.header_
24033 }
24034
24035 func (c *ContentCategoriesPatchCall) doRequest(alt string) (*http.Response, error) {
24036 reqHeaders := make(http.Header)
24037 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
24038 for k, v := range c.header_ {
24039 reqHeaders[k] = v
24040 }
24041 reqHeaders.Set("User-Agent", c.s.userAgent())
24042 var body io.Reader = nil
24043 body, err := googleapi.WithoutDataWrapper.JSONReader(c.contentcategory)
24044 if err != nil {
24045 return nil, err
24046 }
24047 reqHeaders.Set("Content-Type", "application/json")
24048 c.urlParams_.Set("alt", alt)
24049 c.urlParams_.Set("prettyPrint", "false")
24050 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/contentCategories")
24051 urls += "?" + c.urlParams_.Encode()
24052 req, err := http.NewRequest("PATCH", urls, body)
24053 if err != nil {
24054 return nil, err
24055 }
24056 req.Header = reqHeaders
24057 googleapi.Expand(req.URL, map[string]string{
24058 "profileId": strconv.FormatInt(c.profileId, 10),
24059 })
24060 return gensupport.SendRequest(c.ctx_, c.s.client, req)
24061 }
24062
24063
24064
24065
24066
24067
24068
24069
24070 func (c *ContentCategoriesPatchCall) Do(opts ...googleapi.CallOption) (*ContentCategory, error) {
24071 gensupport.SetOptions(c.urlParams_, opts...)
24072 res, err := c.doRequest("json")
24073 if res != nil && res.StatusCode == http.StatusNotModified {
24074 if res.Body != nil {
24075 res.Body.Close()
24076 }
24077 return nil, &googleapi.Error{
24078 Code: res.StatusCode,
24079 Header: res.Header,
24080 }
24081 }
24082 if err != nil {
24083 return nil, err
24084 }
24085 defer googleapi.CloseBody(res)
24086 if err := googleapi.CheckResponse(res); err != nil {
24087 return nil, err
24088 }
24089 ret := &ContentCategory{
24090 ServerResponse: googleapi.ServerResponse{
24091 Header: res.Header,
24092 HTTPStatusCode: res.StatusCode,
24093 },
24094 }
24095 target := &ret
24096 if err := gensupport.DecodeResponse(target, res); err != nil {
24097 return nil, err
24098 }
24099 return ret, nil
24100
24101
24102
24103
24104
24105
24106
24107
24108
24109
24110
24111
24112
24113
24114
24115
24116
24117
24118
24119
24120
24121
24122
24123
24124
24125
24126
24127
24128
24129
24130
24131
24132
24133
24134
24135
24136 }
24137
24138
24139
24140 type ContentCategoriesUpdateCall struct {
24141 s *Service
24142 profileId int64
24143 contentcategory *ContentCategory
24144 urlParams_ gensupport.URLParams
24145 ctx_ context.Context
24146 header_ http.Header
24147 }
24148
24149
24150 func (r *ContentCategoriesService) Update(profileId int64, contentcategory *ContentCategory) *ContentCategoriesUpdateCall {
24151 c := &ContentCategoriesUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
24152 c.profileId = profileId
24153 c.contentcategory = contentcategory
24154 return c
24155 }
24156
24157
24158
24159
24160 func (c *ContentCategoriesUpdateCall) Fields(s ...googleapi.Field) *ContentCategoriesUpdateCall {
24161 c.urlParams_.Set("fields", googleapi.CombineFields(s))
24162 return c
24163 }
24164
24165
24166
24167
24168 func (c *ContentCategoriesUpdateCall) Context(ctx context.Context) *ContentCategoriesUpdateCall {
24169 c.ctx_ = ctx
24170 return c
24171 }
24172
24173
24174
24175 func (c *ContentCategoriesUpdateCall) Header() http.Header {
24176 if c.header_ == nil {
24177 c.header_ = make(http.Header)
24178 }
24179 return c.header_
24180 }
24181
24182 func (c *ContentCategoriesUpdateCall) doRequest(alt string) (*http.Response, error) {
24183 reqHeaders := make(http.Header)
24184 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
24185 for k, v := range c.header_ {
24186 reqHeaders[k] = v
24187 }
24188 reqHeaders.Set("User-Agent", c.s.userAgent())
24189 var body io.Reader = nil
24190 body, err := googleapi.WithoutDataWrapper.JSONReader(c.contentcategory)
24191 if err != nil {
24192 return nil, err
24193 }
24194 reqHeaders.Set("Content-Type", "application/json")
24195 c.urlParams_.Set("alt", alt)
24196 c.urlParams_.Set("prettyPrint", "false")
24197 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/contentCategories")
24198 urls += "?" + c.urlParams_.Encode()
24199 req, err := http.NewRequest("PUT", urls, body)
24200 if err != nil {
24201 return nil, err
24202 }
24203 req.Header = reqHeaders
24204 googleapi.Expand(req.URL, map[string]string{
24205 "profileId": strconv.FormatInt(c.profileId, 10),
24206 })
24207 return gensupport.SendRequest(c.ctx_, c.s.client, req)
24208 }
24209
24210
24211
24212
24213
24214
24215
24216
24217 func (c *ContentCategoriesUpdateCall) Do(opts ...googleapi.CallOption) (*ContentCategory, error) {
24218 gensupport.SetOptions(c.urlParams_, opts...)
24219 res, err := c.doRequest("json")
24220 if res != nil && res.StatusCode == http.StatusNotModified {
24221 if res.Body != nil {
24222 res.Body.Close()
24223 }
24224 return nil, &googleapi.Error{
24225 Code: res.StatusCode,
24226 Header: res.Header,
24227 }
24228 }
24229 if err != nil {
24230 return nil, err
24231 }
24232 defer googleapi.CloseBody(res)
24233 if err := googleapi.CheckResponse(res); err != nil {
24234 return nil, err
24235 }
24236 ret := &ContentCategory{
24237 ServerResponse: googleapi.ServerResponse{
24238 Header: res.Header,
24239 HTTPStatusCode: res.StatusCode,
24240 },
24241 }
24242 target := &ret
24243 if err := gensupport.DecodeResponse(target, res); err != nil {
24244 return nil, err
24245 }
24246 return ret, nil
24247
24248
24249
24250
24251
24252
24253
24254
24255
24256
24257
24258
24259
24260
24261
24262
24263
24264
24265
24266
24267
24268
24269
24270
24271
24272
24273
24274
24275 }
24276
24277
24278
24279 type ConversionsBatchinsertCall struct {
24280 s *Service
24281 profileId int64
24282 conversionsbatchinsertrequest *ConversionsBatchInsertRequest
24283 urlParams_ gensupport.URLParams
24284 ctx_ context.Context
24285 header_ http.Header
24286 }
24287
24288
24289 func (r *ConversionsService) Batchinsert(profileId int64, conversionsbatchinsertrequest *ConversionsBatchInsertRequest) *ConversionsBatchinsertCall {
24290 c := &ConversionsBatchinsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
24291 c.profileId = profileId
24292 c.conversionsbatchinsertrequest = conversionsbatchinsertrequest
24293 return c
24294 }
24295
24296
24297
24298
24299 func (c *ConversionsBatchinsertCall) Fields(s ...googleapi.Field) *ConversionsBatchinsertCall {
24300 c.urlParams_.Set("fields", googleapi.CombineFields(s))
24301 return c
24302 }
24303
24304
24305
24306
24307 func (c *ConversionsBatchinsertCall) Context(ctx context.Context) *ConversionsBatchinsertCall {
24308 c.ctx_ = ctx
24309 return c
24310 }
24311
24312
24313
24314 func (c *ConversionsBatchinsertCall) Header() http.Header {
24315 if c.header_ == nil {
24316 c.header_ = make(http.Header)
24317 }
24318 return c.header_
24319 }
24320
24321 func (c *ConversionsBatchinsertCall) doRequest(alt string) (*http.Response, error) {
24322 reqHeaders := make(http.Header)
24323 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
24324 for k, v := range c.header_ {
24325 reqHeaders[k] = v
24326 }
24327 reqHeaders.Set("User-Agent", c.s.userAgent())
24328 var body io.Reader = nil
24329 body, err := googleapi.WithoutDataWrapper.JSONReader(c.conversionsbatchinsertrequest)
24330 if err != nil {
24331 return nil, err
24332 }
24333 reqHeaders.Set("Content-Type", "application/json")
24334 c.urlParams_.Set("alt", alt)
24335 c.urlParams_.Set("prettyPrint", "false")
24336 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/conversions/batchinsert")
24337 urls += "?" + c.urlParams_.Encode()
24338 req, err := http.NewRequest("POST", urls, body)
24339 if err != nil {
24340 return nil, err
24341 }
24342 req.Header = reqHeaders
24343 googleapi.Expand(req.URL, map[string]string{
24344 "profileId": strconv.FormatInt(c.profileId, 10),
24345 })
24346 return gensupport.SendRequest(c.ctx_, c.s.client, req)
24347 }
24348
24349
24350
24351
24352
24353
24354
24355
24356 func (c *ConversionsBatchinsertCall) Do(opts ...googleapi.CallOption) (*ConversionsBatchInsertResponse, error) {
24357 gensupport.SetOptions(c.urlParams_, opts...)
24358 res, err := c.doRequest("json")
24359 if res != nil && res.StatusCode == http.StatusNotModified {
24360 if res.Body != nil {
24361 res.Body.Close()
24362 }
24363 return nil, &googleapi.Error{
24364 Code: res.StatusCode,
24365 Header: res.Header,
24366 }
24367 }
24368 if err != nil {
24369 return nil, err
24370 }
24371 defer googleapi.CloseBody(res)
24372 if err := googleapi.CheckResponse(res); err != nil {
24373 return nil, err
24374 }
24375 ret := &ConversionsBatchInsertResponse{
24376 ServerResponse: googleapi.ServerResponse{
24377 Header: res.Header,
24378 HTTPStatusCode: res.StatusCode,
24379 },
24380 }
24381 target := &ret
24382 if err := gensupport.DecodeResponse(target, res); err != nil {
24383 return nil, err
24384 }
24385 return ret, nil
24386
24387
24388
24389
24390
24391
24392
24393
24394
24395
24396
24397
24398
24399
24400
24401
24402
24403
24404
24405
24406
24407
24408
24409
24410
24411
24412
24413
24414 }
24415
24416
24417
24418 type ConversionsBatchupdateCall struct {
24419 s *Service
24420 profileId int64
24421 conversionsbatchupdaterequest *ConversionsBatchUpdateRequest
24422 urlParams_ gensupport.URLParams
24423 ctx_ context.Context
24424 header_ http.Header
24425 }
24426
24427
24428 func (r *ConversionsService) Batchupdate(profileId int64, conversionsbatchupdaterequest *ConversionsBatchUpdateRequest) *ConversionsBatchupdateCall {
24429 c := &ConversionsBatchupdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
24430 c.profileId = profileId
24431 c.conversionsbatchupdaterequest = conversionsbatchupdaterequest
24432 return c
24433 }
24434
24435
24436
24437
24438 func (c *ConversionsBatchupdateCall) Fields(s ...googleapi.Field) *ConversionsBatchupdateCall {
24439 c.urlParams_.Set("fields", googleapi.CombineFields(s))
24440 return c
24441 }
24442
24443
24444
24445
24446 func (c *ConversionsBatchupdateCall) Context(ctx context.Context) *ConversionsBatchupdateCall {
24447 c.ctx_ = ctx
24448 return c
24449 }
24450
24451
24452
24453 func (c *ConversionsBatchupdateCall) Header() http.Header {
24454 if c.header_ == nil {
24455 c.header_ = make(http.Header)
24456 }
24457 return c.header_
24458 }
24459
24460 func (c *ConversionsBatchupdateCall) doRequest(alt string) (*http.Response, error) {
24461 reqHeaders := make(http.Header)
24462 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
24463 for k, v := range c.header_ {
24464 reqHeaders[k] = v
24465 }
24466 reqHeaders.Set("User-Agent", c.s.userAgent())
24467 var body io.Reader = nil
24468 body, err := googleapi.WithoutDataWrapper.JSONReader(c.conversionsbatchupdaterequest)
24469 if err != nil {
24470 return nil, err
24471 }
24472 reqHeaders.Set("Content-Type", "application/json")
24473 c.urlParams_.Set("alt", alt)
24474 c.urlParams_.Set("prettyPrint", "false")
24475 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/conversions/batchupdate")
24476 urls += "?" + c.urlParams_.Encode()
24477 req, err := http.NewRequest("POST", urls, body)
24478 if err != nil {
24479 return nil, err
24480 }
24481 req.Header = reqHeaders
24482 googleapi.Expand(req.URL, map[string]string{
24483 "profileId": strconv.FormatInt(c.profileId, 10),
24484 })
24485 return gensupport.SendRequest(c.ctx_, c.s.client, req)
24486 }
24487
24488
24489
24490
24491
24492
24493
24494
24495 func (c *ConversionsBatchupdateCall) Do(opts ...googleapi.CallOption) (*ConversionsBatchUpdateResponse, error) {
24496 gensupport.SetOptions(c.urlParams_, opts...)
24497 res, err := c.doRequest("json")
24498 if res != nil && res.StatusCode == http.StatusNotModified {
24499 if res.Body != nil {
24500 res.Body.Close()
24501 }
24502 return nil, &googleapi.Error{
24503 Code: res.StatusCode,
24504 Header: res.Header,
24505 }
24506 }
24507 if err != nil {
24508 return nil, err
24509 }
24510 defer googleapi.CloseBody(res)
24511 if err := googleapi.CheckResponse(res); err != nil {
24512 return nil, err
24513 }
24514 ret := &ConversionsBatchUpdateResponse{
24515 ServerResponse: googleapi.ServerResponse{
24516 Header: res.Header,
24517 HTTPStatusCode: res.StatusCode,
24518 },
24519 }
24520 target := &ret
24521 if err := gensupport.DecodeResponse(target, res); err != nil {
24522 return nil, err
24523 }
24524 return ret, nil
24525
24526
24527
24528
24529
24530
24531
24532
24533
24534
24535
24536
24537
24538
24539
24540
24541
24542
24543
24544
24545
24546
24547
24548
24549
24550
24551
24552
24553 }
24554
24555
24556
24557 type CountriesGetCall struct {
24558 s *Service
24559 profileId int64
24560 dartId int64
24561 urlParams_ gensupport.URLParams
24562 ifNoneMatch_ string
24563 ctx_ context.Context
24564 header_ http.Header
24565 }
24566
24567
24568 func (r *CountriesService) Get(profileId int64, dartId int64) *CountriesGetCall {
24569 c := &CountriesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
24570 c.profileId = profileId
24571 c.dartId = dartId
24572 return c
24573 }
24574
24575
24576
24577
24578 func (c *CountriesGetCall) Fields(s ...googleapi.Field) *CountriesGetCall {
24579 c.urlParams_.Set("fields", googleapi.CombineFields(s))
24580 return c
24581 }
24582
24583
24584
24585
24586
24587
24588 func (c *CountriesGetCall) IfNoneMatch(entityTag string) *CountriesGetCall {
24589 c.ifNoneMatch_ = entityTag
24590 return c
24591 }
24592
24593
24594
24595
24596 func (c *CountriesGetCall) Context(ctx context.Context) *CountriesGetCall {
24597 c.ctx_ = ctx
24598 return c
24599 }
24600
24601
24602
24603 func (c *CountriesGetCall) Header() http.Header {
24604 if c.header_ == nil {
24605 c.header_ = make(http.Header)
24606 }
24607 return c.header_
24608 }
24609
24610 func (c *CountriesGetCall) doRequest(alt string) (*http.Response, error) {
24611 reqHeaders := make(http.Header)
24612 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
24613 for k, v := range c.header_ {
24614 reqHeaders[k] = v
24615 }
24616 reqHeaders.Set("User-Agent", c.s.userAgent())
24617 if c.ifNoneMatch_ != "" {
24618 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
24619 }
24620 var body io.Reader = nil
24621 c.urlParams_.Set("alt", alt)
24622 c.urlParams_.Set("prettyPrint", "false")
24623 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/countries/{dartId}")
24624 urls += "?" + c.urlParams_.Encode()
24625 req, err := http.NewRequest("GET", urls, body)
24626 if err != nil {
24627 return nil, err
24628 }
24629 req.Header = reqHeaders
24630 googleapi.Expand(req.URL, map[string]string{
24631 "profileId": strconv.FormatInt(c.profileId, 10),
24632 "dartId": strconv.FormatInt(c.dartId, 10),
24633 })
24634 return gensupport.SendRequest(c.ctx_, c.s.client, req)
24635 }
24636
24637
24638
24639
24640
24641
24642
24643
24644 func (c *CountriesGetCall) Do(opts ...googleapi.CallOption) (*Country, error) {
24645 gensupport.SetOptions(c.urlParams_, opts...)
24646 res, err := c.doRequest("json")
24647 if res != nil && res.StatusCode == http.StatusNotModified {
24648 if res.Body != nil {
24649 res.Body.Close()
24650 }
24651 return nil, &googleapi.Error{
24652 Code: res.StatusCode,
24653 Header: res.Header,
24654 }
24655 }
24656 if err != nil {
24657 return nil, err
24658 }
24659 defer googleapi.CloseBody(res)
24660 if err := googleapi.CheckResponse(res); err != nil {
24661 return nil, err
24662 }
24663 ret := &Country{
24664 ServerResponse: googleapi.ServerResponse{
24665 Header: res.Header,
24666 HTTPStatusCode: res.StatusCode,
24667 },
24668 }
24669 target := &ret
24670 if err := gensupport.DecodeResponse(target, res); err != nil {
24671 return nil, err
24672 }
24673 return ret, nil
24674
24675
24676
24677
24678
24679
24680
24681
24682
24683
24684
24685
24686
24687
24688
24689
24690
24691
24692
24693
24694
24695
24696
24697
24698
24699
24700
24701
24702
24703
24704
24705
24706
24707 }
24708
24709
24710
24711 type CountriesListCall struct {
24712 s *Service
24713 profileId int64
24714 urlParams_ gensupport.URLParams
24715 ifNoneMatch_ string
24716 ctx_ context.Context
24717 header_ http.Header
24718 }
24719
24720
24721 func (r *CountriesService) List(profileId int64) *CountriesListCall {
24722 c := &CountriesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
24723 c.profileId = profileId
24724 return c
24725 }
24726
24727
24728
24729
24730 func (c *CountriesListCall) Fields(s ...googleapi.Field) *CountriesListCall {
24731 c.urlParams_.Set("fields", googleapi.CombineFields(s))
24732 return c
24733 }
24734
24735
24736
24737
24738
24739
24740 func (c *CountriesListCall) IfNoneMatch(entityTag string) *CountriesListCall {
24741 c.ifNoneMatch_ = entityTag
24742 return c
24743 }
24744
24745
24746
24747
24748 func (c *CountriesListCall) Context(ctx context.Context) *CountriesListCall {
24749 c.ctx_ = ctx
24750 return c
24751 }
24752
24753
24754
24755 func (c *CountriesListCall) Header() http.Header {
24756 if c.header_ == nil {
24757 c.header_ = make(http.Header)
24758 }
24759 return c.header_
24760 }
24761
24762 func (c *CountriesListCall) doRequest(alt string) (*http.Response, error) {
24763 reqHeaders := make(http.Header)
24764 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
24765 for k, v := range c.header_ {
24766 reqHeaders[k] = v
24767 }
24768 reqHeaders.Set("User-Agent", c.s.userAgent())
24769 if c.ifNoneMatch_ != "" {
24770 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
24771 }
24772 var body io.Reader = nil
24773 c.urlParams_.Set("alt", alt)
24774 c.urlParams_.Set("prettyPrint", "false")
24775 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/countries")
24776 urls += "?" + c.urlParams_.Encode()
24777 req, err := http.NewRequest("GET", urls, body)
24778 if err != nil {
24779 return nil, err
24780 }
24781 req.Header = reqHeaders
24782 googleapi.Expand(req.URL, map[string]string{
24783 "profileId": strconv.FormatInt(c.profileId, 10),
24784 })
24785 return gensupport.SendRequest(c.ctx_, c.s.client, req)
24786 }
24787
24788
24789
24790
24791
24792
24793
24794
24795 func (c *CountriesListCall) Do(opts ...googleapi.CallOption) (*CountriesListResponse, error) {
24796 gensupport.SetOptions(c.urlParams_, opts...)
24797 res, err := c.doRequest("json")
24798 if res != nil && res.StatusCode == http.StatusNotModified {
24799 if res.Body != nil {
24800 res.Body.Close()
24801 }
24802 return nil, &googleapi.Error{
24803 Code: res.StatusCode,
24804 Header: res.Header,
24805 }
24806 }
24807 if err != nil {
24808 return nil, err
24809 }
24810 defer googleapi.CloseBody(res)
24811 if err := googleapi.CheckResponse(res); err != nil {
24812 return nil, err
24813 }
24814 ret := &CountriesListResponse{
24815 ServerResponse: googleapi.ServerResponse{
24816 Header: res.Header,
24817 HTTPStatusCode: res.StatusCode,
24818 },
24819 }
24820 target := &ret
24821 if err := gensupport.DecodeResponse(target, res); err != nil {
24822 return nil, err
24823 }
24824 return ret, nil
24825
24826
24827
24828
24829
24830
24831
24832
24833
24834
24835
24836
24837
24838
24839
24840
24841
24842
24843
24844
24845
24846
24847
24848
24849
24850 }
24851
24852
24853
24854 type CreativeAssetsInsertCall struct {
24855 s *Service
24856 profileId int64
24857 advertiserId int64
24858 creativeassetmetadata *CreativeAssetMetadata
24859 urlParams_ gensupport.URLParams
24860 mediaInfo_ *gensupport.MediaInfo
24861 ctx_ context.Context
24862 header_ http.Header
24863 }
24864
24865
24866 func (r *CreativeAssetsService) Insert(profileId int64, advertiserId int64, creativeassetmetadata *CreativeAssetMetadata) *CreativeAssetsInsertCall {
24867 c := &CreativeAssetsInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
24868 c.profileId = profileId
24869 c.advertiserId = advertiserId
24870 c.creativeassetmetadata = creativeassetmetadata
24871 return c
24872 }
24873
24874
24875
24876
24877
24878
24879
24880
24881
24882 func (c *CreativeAssetsInsertCall) Media(r io.Reader, options ...googleapi.MediaOption) *CreativeAssetsInsertCall {
24883 c.mediaInfo_ = gensupport.NewInfoFromMedia(r, options)
24884 return c
24885 }
24886
24887
24888
24889
24890
24891
24892
24893
24894
24895
24896 func (c *CreativeAssetsInsertCall) ResumableMedia(ctx context.Context, r io.ReaderAt, size int64, mediaType string) *CreativeAssetsInsertCall {
24897 c.ctx_ = ctx
24898 c.mediaInfo_ = gensupport.NewInfoFromResumableMedia(r, size, mediaType)
24899 return c
24900 }
24901
24902
24903
24904
24905
24906 func (c *CreativeAssetsInsertCall) ProgressUpdater(pu googleapi.ProgressUpdater) *CreativeAssetsInsertCall {
24907 c.mediaInfo_.SetProgressUpdater(pu)
24908 return c
24909 }
24910
24911
24912
24913
24914 func (c *CreativeAssetsInsertCall) Fields(s ...googleapi.Field) *CreativeAssetsInsertCall {
24915 c.urlParams_.Set("fields", googleapi.CombineFields(s))
24916 return c
24917 }
24918
24919
24920
24921
24922
24923
24924 func (c *CreativeAssetsInsertCall) Context(ctx context.Context) *CreativeAssetsInsertCall {
24925 c.ctx_ = ctx
24926 return c
24927 }
24928
24929
24930
24931 func (c *CreativeAssetsInsertCall) Header() http.Header {
24932 if c.header_ == nil {
24933 c.header_ = make(http.Header)
24934 }
24935 return c.header_
24936 }
24937
24938 func (c *CreativeAssetsInsertCall) doRequest(alt string) (*http.Response, error) {
24939 reqHeaders := make(http.Header)
24940 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
24941 for k, v := range c.header_ {
24942 reqHeaders[k] = v
24943 }
24944 reqHeaders.Set("User-Agent", c.s.userAgent())
24945 var body io.Reader = nil
24946 body, err := googleapi.WithoutDataWrapper.JSONReader(c.creativeassetmetadata)
24947 if err != nil {
24948 return nil, err
24949 }
24950 reqHeaders.Set("Content-Type", "application/json")
24951 c.urlParams_.Set("alt", alt)
24952 c.urlParams_.Set("prettyPrint", "false")
24953 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeAssets/{advertiserId}/creativeAssets")
24954 if c.mediaInfo_ != nil {
24955 urls = googleapi.ResolveRelative(c.s.BasePath, "/upload/dfareporting/v3.2/userprofiles/{profileId}/creativeAssets/{advertiserId}/creativeAssets")
24956 c.urlParams_.Set("uploadType", c.mediaInfo_.UploadType())
24957 }
24958 if body == nil {
24959 body = new(bytes.Buffer)
24960 reqHeaders.Set("Content-Type", "application/json")
24961 }
24962 body, getBody, cleanup := c.mediaInfo_.UploadRequest(reqHeaders, body)
24963 defer cleanup()
24964 urls += "?" + c.urlParams_.Encode()
24965 req, err := http.NewRequest("POST", urls, body)
24966 if err != nil {
24967 return nil, err
24968 }
24969 req.Header = reqHeaders
24970 req.GetBody = getBody
24971 googleapi.Expand(req.URL, map[string]string{
24972 "profileId": strconv.FormatInt(c.profileId, 10),
24973 "advertiserId": strconv.FormatInt(c.advertiserId, 10),
24974 })
24975 return gensupport.SendRequest(c.ctx_, c.s.client, req)
24976 }
24977
24978
24979
24980
24981
24982
24983
24984
24985 func (c *CreativeAssetsInsertCall) Do(opts ...googleapi.CallOption) (*CreativeAssetMetadata, error) {
24986 gensupport.SetOptions(c.urlParams_, opts...)
24987 res, err := c.doRequest("json")
24988 if res != nil && res.StatusCode == http.StatusNotModified {
24989 if res.Body != nil {
24990 res.Body.Close()
24991 }
24992 return nil, &googleapi.Error{
24993 Code: res.StatusCode,
24994 Header: res.Header,
24995 }
24996 }
24997 if err != nil {
24998 return nil, err
24999 }
25000 defer googleapi.CloseBody(res)
25001 if err := googleapi.CheckResponse(res); err != nil {
25002 return nil, err
25003 }
25004 rx := c.mediaInfo_.ResumableUpload(res.Header.Get("Location"))
25005 if rx != nil {
25006 rx.Client = c.s.client
25007 rx.UserAgent = c.s.userAgent()
25008 ctx := c.ctx_
25009 if ctx == nil {
25010 ctx = context.TODO()
25011 }
25012 res, err = rx.Upload(ctx)
25013 if err != nil {
25014 return nil, err
25015 }
25016 defer res.Body.Close()
25017 if err := googleapi.CheckResponse(res); err != nil {
25018 return nil, err
25019 }
25020 }
25021 ret := &CreativeAssetMetadata{
25022 ServerResponse: googleapi.ServerResponse{
25023 Header: res.Header,
25024 HTTPStatusCode: res.StatusCode,
25025 },
25026 }
25027 target := &ret
25028 if err := gensupport.DecodeResponse(target, res); err != nil {
25029 return nil, err
25030 }
25031 return ret, nil
25032
25033
25034
25035
25036
25037
25038
25039
25040
25041
25042
25043
25044
25045
25046
25047
25048
25049
25050
25051
25052
25053
25054
25055
25056
25057
25058
25059
25060
25061
25062
25063
25064
25065
25066
25067
25068
25069
25070
25071
25072
25073
25074
25075
25076
25077
25078
25079
25080
25081
25082
25083
25084
25085 }
25086
25087
25088
25089 type CreativeFieldValuesDeleteCall struct {
25090 s *Service
25091 profileId int64
25092 creativeFieldId int64
25093 id int64
25094 urlParams_ gensupport.URLParams
25095 ctx_ context.Context
25096 header_ http.Header
25097 }
25098
25099
25100 func (r *CreativeFieldValuesService) Delete(profileId int64, creativeFieldId int64, id int64) *CreativeFieldValuesDeleteCall {
25101 c := &CreativeFieldValuesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
25102 c.profileId = profileId
25103 c.creativeFieldId = creativeFieldId
25104 c.id = id
25105 return c
25106 }
25107
25108
25109
25110
25111 func (c *CreativeFieldValuesDeleteCall) Fields(s ...googleapi.Field) *CreativeFieldValuesDeleteCall {
25112 c.urlParams_.Set("fields", googleapi.CombineFields(s))
25113 return c
25114 }
25115
25116
25117
25118
25119 func (c *CreativeFieldValuesDeleteCall) Context(ctx context.Context) *CreativeFieldValuesDeleteCall {
25120 c.ctx_ = ctx
25121 return c
25122 }
25123
25124
25125
25126 func (c *CreativeFieldValuesDeleteCall) Header() http.Header {
25127 if c.header_ == nil {
25128 c.header_ = make(http.Header)
25129 }
25130 return c.header_
25131 }
25132
25133 func (c *CreativeFieldValuesDeleteCall) doRequest(alt string) (*http.Response, error) {
25134 reqHeaders := make(http.Header)
25135 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
25136 for k, v := range c.header_ {
25137 reqHeaders[k] = v
25138 }
25139 reqHeaders.Set("User-Agent", c.s.userAgent())
25140 var body io.Reader = nil
25141 c.urlParams_.Set("alt", alt)
25142 c.urlParams_.Set("prettyPrint", "false")
25143 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeFields/{creativeFieldId}/creativeFieldValues/{id}")
25144 urls += "?" + c.urlParams_.Encode()
25145 req, err := http.NewRequest("DELETE", urls, body)
25146 if err != nil {
25147 return nil, err
25148 }
25149 req.Header = reqHeaders
25150 googleapi.Expand(req.URL, map[string]string{
25151 "profileId": strconv.FormatInt(c.profileId, 10),
25152 "creativeFieldId": strconv.FormatInt(c.creativeFieldId, 10),
25153 "id": strconv.FormatInt(c.id, 10),
25154 })
25155 return gensupport.SendRequest(c.ctx_, c.s.client, req)
25156 }
25157
25158
25159 func (c *CreativeFieldValuesDeleteCall) Do(opts ...googleapi.CallOption) error {
25160 gensupport.SetOptions(c.urlParams_, opts...)
25161 res, err := c.doRequest("json")
25162 if err != nil {
25163 return err
25164 }
25165 defer googleapi.CloseBody(res)
25166 if err := googleapi.CheckResponse(res); err != nil {
25167 return err
25168 }
25169 return nil
25170
25171
25172
25173
25174
25175
25176
25177
25178
25179
25180
25181
25182
25183
25184
25185
25186
25187
25188
25189
25190
25191
25192
25193
25194
25195
25196
25197
25198
25199
25200
25201
25202
25203
25204
25205
25206
25207
25208 }
25209
25210
25211
25212 type CreativeFieldValuesGetCall struct {
25213 s *Service
25214 profileId int64
25215 creativeFieldId int64
25216 id int64
25217 urlParams_ gensupport.URLParams
25218 ifNoneMatch_ string
25219 ctx_ context.Context
25220 header_ http.Header
25221 }
25222
25223
25224 func (r *CreativeFieldValuesService) Get(profileId int64, creativeFieldId int64, id int64) *CreativeFieldValuesGetCall {
25225 c := &CreativeFieldValuesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
25226 c.profileId = profileId
25227 c.creativeFieldId = creativeFieldId
25228 c.id = id
25229 return c
25230 }
25231
25232
25233
25234
25235 func (c *CreativeFieldValuesGetCall) Fields(s ...googleapi.Field) *CreativeFieldValuesGetCall {
25236 c.urlParams_.Set("fields", googleapi.CombineFields(s))
25237 return c
25238 }
25239
25240
25241
25242
25243
25244
25245 func (c *CreativeFieldValuesGetCall) IfNoneMatch(entityTag string) *CreativeFieldValuesGetCall {
25246 c.ifNoneMatch_ = entityTag
25247 return c
25248 }
25249
25250
25251
25252
25253 func (c *CreativeFieldValuesGetCall) Context(ctx context.Context) *CreativeFieldValuesGetCall {
25254 c.ctx_ = ctx
25255 return c
25256 }
25257
25258
25259
25260 func (c *CreativeFieldValuesGetCall) Header() http.Header {
25261 if c.header_ == nil {
25262 c.header_ = make(http.Header)
25263 }
25264 return c.header_
25265 }
25266
25267 func (c *CreativeFieldValuesGetCall) doRequest(alt string) (*http.Response, error) {
25268 reqHeaders := make(http.Header)
25269 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
25270 for k, v := range c.header_ {
25271 reqHeaders[k] = v
25272 }
25273 reqHeaders.Set("User-Agent", c.s.userAgent())
25274 if c.ifNoneMatch_ != "" {
25275 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
25276 }
25277 var body io.Reader = nil
25278 c.urlParams_.Set("alt", alt)
25279 c.urlParams_.Set("prettyPrint", "false")
25280 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeFields/{creativeFieldId}/creativeFieldValues/{id}")
25281 urls += "?" + c.urlParams_.Encode()
25282 req, err := http.NewRequest("GET", urls, body)
25283 if err != nil {
25284 return nil, err
25285 }
25286 req.Header = reqHeaders
25287 googleapi.Expand(req.URL, map[string]string{
25288 "profileId": strconv.FormatInt(c.profileId, 10),
25289 "creativeFieldId": strconv.FormatInt(c.creativeFieldId, 10),
25290 "id": strconv.FormatInt(c.id, 10),
25291 })
25292 return gensupport.SendRequest(c.ctx_, c.s.client, req)
25293 }
25294
25295
25296
25297
25298
25299
25300
25301
25302 func (c *CreativeFieldValuesGetCall) Do(opts ...googleapi.CallOption) (*CreativeFieldValue, error) {
25303 gensupport.SetOptions(c.urlParams_, opts...)
25304 res, err := c.doRequest("json")
25305 if res != nil && res.StatusCode == http.StatusNotModified {
25306 if res.Body != nil {
25307 res.Body.Close()
25308 }
25309 return nil, &googleapi.Error{
25310 Code: res.StatusCode,
25311 Header: res.Header,
25312 }
25313 }
25314 if err != nil {
25315 return nil, err
25316 }
25317 defer googleapi.CloseBody(res)
25318 if err := googleapi.CheckResponse(res); err != nil {
25319 return nil, err
25320 }
25321 ret := &CreativeFieldValue{
25322 ServerResponse: googleapi.ServerResponse{
25323 Header: res.Header,
25324 HTTPStatusCode: res.StatusCode,
25325 },
25326 }
25327 target := &ret
25328 if err := gensupport.DecodeResponse(target, res); err != nil {
25329 return nil, err
25330 }
25331 return ret, nil
25332
25333
25334
25335
25336
25337
25338
25339
25340
25341
25342
25343
25344
25345
25346
25347
25348
25349
25350
25351
25352
25353
25354
25355
25356
25357
25358
25359
25360
25361
25362
25363
25364
25365
25366
25367
25368
25369
25370
25371
25372
25373 }
25374
25375
25376
25377 type CreativeFieldValuesInsertCall struct {
25378 s *Service
25379 profileId int64
25380 creativeFieldId int64
25381 creativefieldvalue *CreativeFieldValue
25382 urlParams_ gensupport.URLParams
25383 ctx_ context.Context
25384 header_ http.Header
25385 }
25386
25387
25388 func (r *CreativeFieldValuesService) Insert(profileId int64, creativeFieldId int64, creativefieldvalue *CreativeFieldValue) *CreativeFieldValuesInsertCall {
25389 c := &CreativeFieldValuesInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
25390 c.profileId = profileId
25391 c.creativeFieldId = creativeFieldId
25392 c.creativefieldvalue = creativefieldvalue
25393 return c
25394 }
25395
25396
25397
25398
25399 func (c *CreativeFieldValuesInsertCall) Fields(s ...googleapi.Field) *CreativeFieldValuesInsertCall {
25400 c.urlParams_.Set("fields", googleapi.CombineFields(s))
25401 return c
25402 }
25403
25404
25405
25406
25407 func (c *CreativeFieldValuesInsertCall) Context(ctx context.Context) *CreativeFieldValuesInsertCall {
25408 c.ctx_ = ctx
25409 return c
25410 }
25411
25412
25413
25414 func (c *CreativeFieldValuesInsertCall) Header() http.Header {
25415 if c.header_ == nil {
25416 c.header_ = make(http.Header)
25417 }
25418 return c.header_
25419 }
25420
25421 func (c *CreativeFieldValuesInsertCall) doRequest(alt string) (*http.Response, error) {
25422 reqHeaders := make(http.Header)
25423 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
25424 for k, v := range c.header_ {
25425 reqHeaders[k] = v
25426 }
25427 reqHeaders.Set("User-Agent", c.s.userAgent())
25428 var body io.Reader = nil
25429 body, err := googleapi.WithoutDataWrapper.JSONReader(c.creativefieldvalue)
25430 if err != nil {
25431 return nil, err
25432 }
25433 reqHeaders.Set("Content-Type", "application/json")
25434 c.urlParams_.Set("alt", alt)
25435 c.urlParams_.Set("prettyPrint", "false")
25436 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeFields/{creativeFieldId}/creativeFieldValues")
25437 urls += "?" + c.urlParams_.Encode()
25438 req, err := http.NewRequest("POST", urls, body)
25439 if err != nil {
25440 return nil, err
25441 }
25442 req.Header = reqHeaders
25443 googleapi.Expand(req.URL, map[string]string{
25444 "profileId": strconv.FormatInt(c.profileId, 10),
25445 "creativeFieldId": strconv.FormatInt(c.creativeFieldId, 10),
25446 })
25447 return gensupport.SendRequest(c.ctx_, c.s.client, req)
25448 }
25449
25450
25451
25452
25453
25454
25455
25456
25457 func (c *CreativeFieldValuesInsertCall) Do(opts ...googleapi.CallOption) (*CreativeFieldValue, error) {
25458 gensupport.SetOptions(c.urlParams_, opts...)
25459 res, err := c.doRequest("json")
25460 if res != nil && res.StatusCode == http.StatusNotModified {
25461 if res.Body != nil {
25462 res.Body.Close()
25463 }
25464 return nil, &googleapi.Error{
25465 Code: res.StatusCode,
25466 Header: res.Header,
25467 }
25468 }
25469 if err != nil {
25470 return nil, err
25471 }
25472 defer googleapi.CloseBody(res)
25473 if err := googleapi.CheckResponse(res); err != nil {
25474 return nil, err
25475 }
25476 ret := &CreativeFieldValue{
25477 ServerResponse: googleapi.ServerResponse{
25478 Header: res.Header,
25479 HTTPStatusCode: res.StatusCode,
25480 },
25481 }
25482 target := &ret
25483 if err := gensupport.DecodeResponse(target, res); err != nil {
25484 return nil, err
25485 }
25486 return ret, nil
25487
25488
25489
25490
25491
25492
25493
25494
25495
25496
25497
25498
25499
25500
25501
25502
25503
25504
25505
25506
25507
25508
25509
25510
25511
25512
25513
25514
25515
25516
25517
25518
25519
25520
25521
25522
25523 }
25524
25525
25526
25527 type CreativeFieldValuesListCall struct {
25528 s *Service
25529 profileId int64
25530 creativeFieldId int64
25531 urlParams_ gensupport.URLParams
25532 ifNoneMatch_ string
25533 ctx_ context.Context
25534 header_ http.Header
25535 }
25536
25537
25538
25539 func (r *CreativeFieldValuesService) List(profileId int64, creativeFieldId int64) *CreativeFieldValuesListCall {
25540 c := &CreativeFieldValuesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
25541 c.profileId = profileId
25542 c.creativeFieldId = creativeFieldId
25543 return c
25544 }
25545
25546
25547
25548 func (c *CreativeFieldValuesListCall) Ids(ids ...int64) *CreativeFieldValuesListCall {
25549 var ids_ []string
25550 for _, v := range ids {
25551 ids_ = append(ids_, fmt.Sprint(v))
25552 }
25553 c.urlParams_.SetMulti("ids", ids_)
25554 return c
25555 }
25556
25557
25558
25559 func (c *CreativeFieldValuesListCall) MaxResults(maxResults int64) *CreativeFieldValuesListCall {
25560 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
25561 return c
25562 }
25563
25564
25565
25566 func (c *CreativeFieldValuesListCall) PageToken(pageToken string) *CreativeFieldValuesListCall {
25567 c.urlParams_.Set("pageToken", pageToken)
25568 return c
25569 }
25570
25571
25572
25573
25574 func (c *CreativeFieldValuesListCall) SearchString(searchString string) *CreativeFieldValuesListCall {
25575 c.urlParams_.Set("searchString", searchString)
25576 return c
25577 }
25578
25579
25580
25581
25582
25583
25584
25585
25586 func (c *CreativeFieldValuesListCall) SortField(sortField string) *CreativeFieldValuesListCall {
25587 c.urlParams_.Set("sortField", sortField)
25588 return c
25589 }
25590
25591
25592
25593
25594
25595
25596
25597
25598 func (c *CreativeFieldValuesListCall) SortOrder(sortOrder string) *CreativeFieldValuesListCall {
25599 c.urlParams_.Set("sortOrder", sortOrder)
25600 return c
25601 }
25602
25603
25604
25605
25606 func (c *CreativeFieldValuesListCall) Fields(s ...googleapi.Field) *CreativeFieldValuesListCall {
25607 c.urlParams_.Set("fields", googleapi.CombineFields(s))
25608 return c
25609 }
25610
25611
25612
25613
25614
25615
25616 func (c *CreativeFieldValuesListCall) IfNoneMatch(entityTag string) *CreativeFieldValuesListCall {
25617 c.ifNoneMatch_ = entityTag
25618 return c
25619 }
25620
25621
25622
25623
25624 func (c *CreativeFieldValuesListCall) Context(ctx context.Context) *CreativeFieldValuesListCall {
25625 c.ctx_ = ctx
25626 return c
25627 }
25628
25629
25630
25631 func (c *CreativeFieldValuesListCall) Header() http.Header {
25632 if c.header_ == nil {
25633 c.header_ = make(http.Header)
25634 }
25635 return c.header_
25636 }
25637
25638 func (c *CreativeFieldValuesListCall) doRequest(alt string) (*http.Response, error) {
25639 reqHeaders := make(http.Header)
25640 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
25641 for k, v := range c.header_ {
25642 reqHeaders[k] = v
25643 }
25644 reqHeaders.Set("User-Agent", c.s.userAgent())
25645 if c.ifNoneMatch_ != "" {
25646 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
25647 }
25648 var body io.Reader = nil
25649 c.urlParams_.Set("alt", alt)
25650 c.urlParams_.Set("prettyPrint", "false")
25651 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeFields/{creativeFieldId}/creativeFieldValues")
25652 urls += "?" + c.urlParams_.Encode()
25653 req, err := http.NewRequest("GET", urls, body)
25654 if err != nil {
25655 return nil, err
25656 }
25657 req.Header = reqHeaders
25658 googleapi.Expand(req.URL, map[string]string{
25659 "profileId": strconv.FormatInt(c.profileId, 10),
25660 "creativeFieldId": strconv.FormatInt(c.creativeFieldId, 10),
25661 })
25662 return gensupport.SendRequest(c.ctx_, c.s.client, req)
25663 }
25664
25665
25666
25667
25668
25669
25670
25671
25672 func (c *CreativeFieldValuesListCall) Do(opts ...googleapi.CallOption) (*CreativeFieldValuesListResponse, error) {
25673 gensupport.SetOptions(c.urlParams_, opts...)
25674 res, err := c.doRequest("json")
25675 if res != nil && res.StatusCode == http.StatusNotModified {
25676 if res.Body != nil {
25677 res.Body.Close()
25678 }
25679 return nil, &googleapi.Error{
25680 Code: res.StatusCode,
25681 Header: res.Header,
25682 }
25683 }
25684 if err != nil {
25685 return nil, err
25686 }
25687 defer googleapi.CloseBody(res)
25688 if err := googleapi.CheckResponse(res); err != nil {
25689 return nil, err
25690 }
25691 ret := &CreativeFieldValuesListResponse{
25692 ServerResponse: googleapi.ServerResponse{
25693 Header: res.Header,
25694 HTTPStatusCode: res.StatusCode,
25695 },
25696 }
25697 target := &ret
25698 if err := gensupport.DecodeResponse(target, res); err != nil {
25699 return nil, err
25700 }
25701 return ret, nil
25702
25703
25704
25705
25706
25707
25708
25709
25710
25711
25712
25713
25714
25715
25716
25717
25718
25719
25720
25721
25722
25723
25724
25725
25726
25727
25728
25729
25730
25731
25732
25733
25734
25735
25736
25737
25738
25739
25740
25741
25742
25743
25744
25745
25746
25747
25748
25749
25750
25751
25752
25753
25754
25755
25756
25757
25758
25759
25760
25761
25762
25763
25764
25765
25766
25767
25768
25769
25770
25771
25772
25773
25774
25775
25776
25777
25778
25779
25780
25781
25782
25783
25784
25785
25786
25787
25788
25789 }
25790
25791
25792
25793
25794 func (c *CreativeFieldValuesListCall) Pages(ctx context.Context, f func(*CreativeFieldValuesListResponse) error) error {
25795 c.ctx_ = ctx
25796 defer c.PageToken(c.urlParams_.Get("pageToken"))
25797 for {
25798 x, err := c.Do()
25799 if err != nil {
25800 return err
25801 }
25802 if err := f(x); err != nil {
25803 return err
25804 }
25805 if x.NextPageToken == "" {
25806 return nil
25807 }
25808 c.PageToken(x.NextPageToken)
25809 }
25810 }
25811
25812
25813
25814 type CreativeFieldValuesPatchCall struct {
25815 s *Service
25816 profileId int64
25817 creativeFieldId int64
25818 creativefieldvalue *CreativeFieldValue
25819 urlParams_ gensupport.URLParams
25820 ctx_ context.Context
25821 header_ http.Header
25822 }
25823
25824
25825
25826 func (r *CreativeFieldValuesService) Patch(profileId int64, creativeFieldId int64, id int64, creativefieldvalue *CreativeFieldValue) *CreativeFieldValuesPatchCall {
25827 c := &CreativeFieldValuesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
25828 c.profileId = profileId
25829 c.creativeFieldId = creativeFieldId
25830 c.urlParams_.Set("id", fmt.Sprint(id))
25831 c.creativefieldvalue = creativefieldvalue
25832 return c
25833 }
25834
25835
25836
25837
25838 func (c *CreativeFieldValuesPatchCall) Fields(s ...googleapi.Field) *CreativeFieldValuesPatchCall {
25839 c.urlParams_.Set("fields", googleapi.CombineFields(s))
25840 return c
25841 }
25842
25843
25844
25845
25846 func (c *CreativeFieldValuesPatchCall) Context(ctx context.Context) *CreativeFieldValuesPatchCall {
25847 c.ctx_ = ctx
25848 return c
25849 }
25850
25851
25852
25853 func (c *CreativeFieldValuesPatchCall) Header() http.Header {
25854 if c.header_ == nil {
25855 c.header_ = make(http.Header)
25856 }
25857 return c.header_
25858 }
25859
25860 func (c *CreativeFieldValuesPatchCall) doRequest(alt string) (*http.Response, error) {
25861 reqHeaders := make(http.Header)
25862 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
25863 for k, v := range c.header_ {
25864 reqHeaders[k] = v
25865 }
25866 reqHeaders.Set("User-Agent", c.s.userAgent())
25867 var body io.Reader = nil
25868 body, err := googleapi.WithoutDataWrapper.JSONReader(c.creativefieldvalue)
25869 if err != nil {
25870 return nil, err
25871 }
25872 reqHeaders.Set("Content-Type", "application/json")
25873 c.urlParams_.Set("alt", alt)
25874 c.urlParams_.Set("prettyPrint", "false")
25875 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeFields/{creativeFieldId}/creativeFieldValues")
25876 urls += "?" + c.urlParams_.Encode()
25877 req, err := http.NewRequest("PATCH", urls, body)
25878 if err != nil {
25879 return nil, err
25880 }
25881 req.Header = reqHeaders
25882 googleapi.Expand(req.URL, map[string]string{
25883 "profileId": strconv.FormatInt(c.profileId, 10),
25884 "creativeFieldId": strconv.FormatInt(c.creativeFieldId, 10),
25885 })
25886 return gensupport.SendRequest(c.ctx_, c.s.client, req)
25887 }
25888
25889
25890
25891
25892
25893
25894
25895
25896 func (c *CreativeFieldValuesPatchCall) Do(opts ...googleapi.CallOption) (*CreativeFieldValue, error) {
25897 gensupport.SetOptions(c.urlParams_, opts...)
25898 res, err := c.doRequest("json")
25899 if res != nil && res.StatusCode == http.StatusNotModified {
25900 if res.Body != nil {
25901 res.Body.Close()
25902 }
25903 return nil, &googleapi.Error{
25904 Code: res.StatusCode,
25905 Header: res.Header,
25906 }
25907 }
25908 if err != nil {
25909 return nil, err
25910 }
25911 defer googleapi.CloseBody(res)
25912 if err := googleapi.CheckResponse(res); err != nil {
25913 return nil, err
25914 }
25915 ret := &CreativeFieldValue{
25916 ServerResponse: googleapi.ServerResponse{
25917 Header: res.Header,
25918 HTTPStatusCode: res.StatusCode,
25919 },
25920 }
25921 target := &ret
25922 if err := gensupport.DecodeResponse(target, res); err != nil {
25923 return nil, err
25924 }
25925 return ret, nil
25926
25927
25928
25929
25930
25931
25932
25933
25934
25935
25936
25937
25938
25939
25940
25941
25942
25943
25944
25945
25946
25947
25948
25949
25950
25951
25952
25953
25954
25955
25956
25957
25958
25959
25960
25961
25962
25963
25964
25965
25966
25967
25968
25969
25970 }
25971
25972
25973
25974 type CreativeFieldValuesUpdateCall struct {
25975 s *Service
25976 profileId int64
25977 creativeFieldId int64
25978 creativefieldvalue *CreativeFieldValue
25979 urlParams_ gensupport.URLParams
25980 ctx_ context.Context
25981 header_ http.Header
25982 }
25983
25984
25985 func (r *CreativeFieldValuesService) Update(profileId int64, creativeFieldId int64, creativefieldvalue *CreativeFieldValue) *CreativeFieldValuesUpdateCall {
25986 c := &CreativeFieldValuesUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
25987 c.profileId = profileId
25988 c.creativeFieldId = creativeFieldId
25989 c.creativefieldvalue = creativefieldvalue
25990 return c
25991 }
25992
25993
25994
25995
25996 func (c *CreativeFieldValuesUpdateCall) Fields(s ...googleapi.Field) *CreativeFieldValuesUpdateCall {
25997 c.urlParams_.Set("fields", googleapi.CombineFields(s))
25998 return c
25999 }
26000
26001
26002
26003
26004 func (c *CreativeFieldValuesUpdateCall) Context(ctx context.Context) *CreativeFieldValuesUpdateCall {
26005 c.ctx_ = ctx
26006 return c
26007 }
26008
26009
26010
26011 func (c *CreativeFieldValuesUpdateCall) Header() http.Header {
26012 if c.header_ == nil {
26013 c.header_ = make(http.Header)
26014 }
26015 return c.header_
26016 }
26017
26018 func (c *CreativeFieldValuesUpdateCall) doRequest(alt string) (*http.Response, error) {
26019 reqHeaders := make(http.Header)
26020 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
26021 for k, v := range c.header_ {
26022 reqHeaders[k] = v
26023 }
26024 reqHeaders.Set("User-Agent", c.s.userAgent())
26025 var body io.Reader = nil
26026 body, err := googleapi.WithoutDataWrapper.JSONReader(c.creativefieldvalue)
26027 if err != nil {
26028 return nil, err
26029 }
26030 reqHeaders.Set("Content-Type", "application/json")
26031 c.urlParams_.Set("alt", alt)
26032 c.urlParams_.Set("prettyPrint", "false")
26033 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeFields/{creativeFieldId}/creativeFieldValues")
26034 urls += "?" + c.urlParams_.Encode()
26035 req, err := http.NewRequest("PUT", urls, body)
26036 if err != nil {
26037 return nil, err
26038 }
26039 req.Header = reqHeaders
26040 googleapi.Expand(req.URL, map[string]string{
26041 "profileId": strconv.FormatInt(c.profileId, 10),
26042 "creativeFieldId": strconv.FormatInt(c.creativeFieldId, 10),
26043 })
26044 return gensupport.SendRequest(c.ctx_, c.s.client, req)
26045 }
26046
26047
26048
26049
26050
26051
26052
26053
26054 func (c *CreativeFieldValuesUpdateCall) Do(opts ...googleapi.CallOption) (*CreativeFieldValue, error) {
26055 gensupport.SetOptions(c.urlParams_, opts...)
26056 res, err := c.doRequest("json")
26057 if res != nil && res.StatusCode == http.StatusNotModified {
26058 if res.Body != nil {
26059 res.Body.Close()
26060 }
26061 return nil, &googleapi.Error{
26062 Code: res.StatusCode,
26063 Header: res.Header,
26064 }
26065 }
26066 if err != nil {
26067 return nil, err
26068 }
26069 defer googleapi.CloseBody(res)
26070 if err := googleapi.CheckResponse(res); err != nil {
26071 return nil, err
26072 }
26073 ret := &CreativeFieldValue{
26074 ServerResponse: googleapi.ServerResponse{
26075 Header: res.Header,
26076 HTTPStatusCode: res.StatusCode,
26077 },
26078 }
26079 target := &ret
26080 if err := gensupport.DecodeResponse(target, res); err != nil {
26081 return nil, err
26082 }
26083 return ret, nil
26084
26085
26086
26087
26088
26089
26090
26091
26092
26093
26094
26095
26096
26097
26098
26099
26100
26101
26102
26103
26104
26105
26106
26107
26108
26109
26110
26111
26112
26113
26114
26115
26116
26117
26118
26119
26120 }
26121
26122
26123
26124 type CreativeFieldsDeleteCall struct {
26125 s *Service
26126 profileId int64
26127 id int64
26128 urlParams_ gensupport.URLParams
26129 ctx_ context.Context
26130 header_ http.Header
26131 }
26132
26133
26134 func (r *CreativeFieldsService) Delete(profileId int64, id int64) *CreativeFieldsDeleteCall {
26135 c := &CreativeFieldsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
26136 c.profileId = profileId
26137 c.id = id
26138 return c
26139 }
26140
26141
26142
26143
26144 func (c *CreativeFieldsDeleteCall) Fields(s ...googleapi.Field) *CreativeFieldsDeleteCall {
26145 c.urlParams_.Set("fields", googleapi.CombineFields(s))
26146 return c
26147 }
26148
26149
26150
26151
26152 func (c *CreativeFieldsDeleteCall) Context(ctx context.Context) *CreativeFieldsDeleteCall {
26153 c.ctx_ = ctx
26154 return c
26155 }
26156
26157
26158
26159 func (c *CreativeFieldsDeleteCall) Header() http.Header {
26160 if c.header_ == nil {
26161 c.header_ = make(http.Header)
26162 }
26163 return c.header_
26164 }
26165
26166 func (c *CreativeFieldsDeleteCall) doRequest(alt string) (*http.Response, error) {
26167 reqHeaders := make(http.Header)
26168 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
26169 for k, v := range c.header_ {
26170 reqHeaders[k] = v
26171 }
26172 reqHeaders.Set("User-Agent", c.s.userAgent())
26173 var body io.Reader = nil
26174 c.urlParams_.Set("alt", alt)
26175 c.urlParams_.Set("prettyPrint", "false")
26176 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeFields/{id}")
26177 urls += "?" + c.urlParams_.Encode()
26178 req, err := http.NewRequest("DELETE", urls, body)
26179 if err != nil {
26180 return nil, err
26181 }
26182 req.Header = reqHeaders
26183 googleapi.Expand(req.URL, map[string]string{
26184 "profileId": strconv.FormatInt(c.profileId, 10),
26185 "id": strconv.FormatInt(c.id, 10),
26186 })
26187 return gensupport.SendRequest(c.ctx_, c.s.client, req)
26188 }
26189
26190
26191 func (c *CreativeFieldsDeleteCall) Do(opts ...googleapi.CallOption) error {
26192 gensupport.SetOptions(c.urlParams_, opts...)
26193 res, err := c.doRequest("json")
26194 if err != nil {
26195 return err
26196 }
26197 defer googleapi.CloseBody(res)
26198 if err := googleapi.CheckResponse(res); err != nil {
26199 return err
26200 }
26201 return nil
26202
26203
26204
26205
26206
26207
26208
26209
26210
26211
26212
26213
26214
26215
26216
26217
26218
26219
26220
26221
26222
26223
26224
26225
26226
26227
26228
26229
26230
26231
26232 }
26233
26234
26235
26236 type CreativeFieldsGetCall struct {
26237 s *Service
26238 profileId int64
26239 id int64
26240 urlParams_ gensupport.URLParams
26241 ifNoneMatch_ string
26242 ctx_ context.Context
26243 header_ http.Header
26244 }
26245
26246
26247 func (r *CreativeFieldsService) Get(profileId int64, id int64) *CreativeFieldsGetCall {
26248 c := &CreativeFieldsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
26249 c.profileId = profileId
26250 c.id = id
26251 return c
26252 }
26253
26254
26255
26256
26257 func (c *CreativeFieldsGetCall) Fields(s ...googleapi.Field) *CreativeFieldsGetCall {
26258 c.urlParams_.Set("fields", googleapi.CombineFields(s))
26259 return c
26260 }
26261
26262
26263
26264
26265
26266
26267 func (c *CreativeFieldsGetCall) IfNoneMatch(entityTag string) *CreativeFieldsGetCall {
26268 c.ifNoneMatch_ = entityTag
26269 return c
26270 }
26271
26272
26273
26274
26275 func (c *CreativeFieldsGetCall) Context(ctx context.Context) *CreativeFieldsGetCall {
26276 c.ctx_ = ctx
26277 return c
26278 }
26279
26280
26281
26282 func (c *CreativeFieldsGetCall) Header() http.Header {
26283 if c.header_ == nil {
26284 c.header_ = make(http.Header)
26285 }
26286 return c.header_
26287 }
26288
26289 func (c *CreativeFieldsGetCall) doRequest(alt string) (*http.Response, error) {
26290 reqHeaders := make(http.Header)
26291 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
26292 for k, v := range c.header_ {
26293 reqHeaders[k] = v
26294 }
26295 reqHeaders.Set("User-Agent", c.s.userAgent())
26296 if c.ifNoneMatch_ != "" {
26297 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
26298 }
26299 var body io.Reader = nil
26300 c.urlParams_.Set("alt", alt)
26301 c.urlParams_.Set("prettyPrint", "false")
26302 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeFields/{id}")
26303 urls += "?" + c.urlParams_.Encode()
26304 req, err := http.NewRequest("GET", urls, body)
26305 if err != nil {
26306 return nil, err
26307 }
26308 req.Header = reqHeaders
26309 googleapi.Expand(req.URL, map[string]string{
26310 "profileId": strconv.FormatInt(c.profileId, 10),
26311 "id": strconv.FormatInt(c.id, 10),
26312 })
26313 return gensupport.SendRequest(c.ctx_, c.s.client, req)
26314 }
26315
26316
26317
26318
26319
26320
26321
26322
26323 func (c *CreativeFieldsGetCall) Do(opts ...googleapi.CallOption) (*CreativeField, error) {
26324 gensupport.SetOptions(c.urlParams_, opts...)
26325 res, err := c.doRequest("json")
26326 if res != nil && res.StatusCode == http.StatusNotModified {
26327 if res.Body != nil {
26328 res.Body.Close()
26329 }
26330 return nil, &googleapi.Error{
26331 Code: res.StatusCode,
26332 Header: res.Header,
26333 }
26334 }
26335 if err != nil {
26336 return nil, err
26337 }
26338 defer googleapi.CloseBody(res)
26339 if err := googleapi.CheckResponse(res); err != nil {
26340 return nil, err
26341 }
26342 ret := &CreativeField{
26343 ServerResponse: googleapi.ServerResponse{
26344 Header: res.Header,
26345 HTTPStatusCode: res.StatusCode,
26346 },
26347 }
26348 target := &ret
26349 if err := gensupport.DecodeResponse(target, res); err != nil {
26350 return nil, err
26351 }
26352 return ret, nil
26353
26354
26355
26356
26357
26358
26359
26360
26361
26362
26363
26364
26365
26366
26367
26368
26369
26370
26371
26372
26373
26374
26375
26376
26377
26378
26379
26380
26381
26382
26383
26384
26385
26386 }
26387
26388
26389
26390 type CreativeFieldsInsertCall struct {
26391 s *Service
26392 profileId int64
26393 creativefield *CreativeField
26394 urlParams_ gensupport.URLParams
26395 ctx_ context.Context
26396 header_ http.Header
26397 }
26398
26399
26400 func (r *CreativeFieldsService) Insert(profileId int64, creativefield *CreativeField) *CreativeFieldsInsertCall {
26401 c := &CreativeFieldsInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
26402 c.profileId = profileId
26403 c.creativefield = creativefield
26404 return c
26405 }
26406
26407
26408
26409
26410 func (c *CreativeFieldsInsertCall) Fields(s ...googleapi.Field) *CreativeFieldsInsertCall {
26411 c.urlParams_.Set("fields", googleapi.CombineFields(s))
26412 return c
26413 }
26414
26415
26416
26417
26418 func (c *CreativeFieldsInsertCall) Context(ctx context.Context) *CreativeFieldsInsertCall {
26419 c.ctx_ = ctx
26420 return c
26421 }
26422
26423
26424
26425 func (c *CreativeFieldsInsertCall) Header() http.Header {
26426 if c.header_ == nil {
26427 c.header_ = make(http.Header)
26428 }
26429 return c.header_
26430 }
26431
26432 func (c *CreativeFieldsInsertCall) doRequest(alt string) (*http.Response, error) {
26433 reqHeaders := make(http.Header)
26434 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
26435 for k, v := range c.header_ {
26436 reqHeaders[k] = v
26437 }
26438 reqHeaders.Set("User-Agent", c.s.userAgent())
26439 var body io.Reader = nil
26440 body, err := googleapi.WithoutDataWrapper.JSONReader(c.creativefield)
26441 if err != nil {
26442 return nil, err
26443 }
26444 reqHeaders.Set("Content-Type", "application/json")
26445 c.urlParams_.Set("alt", alt)
26446 c.urlParams_.Set("prettyPrint", "false")
26447 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeFields")
26448 urls += "?" + c.urlParams_.Encode()
26449 req, err := http.NewRequest("POST", urls, body)
26450 if err != nil {
26451 return nil, err
26452 }
26453 req.Header = reqHeaders
26454 googleapi.Expand(req.URL, map[string]string{
26455 "profileId": strconv.FormatInt(c.profileId, 10),
26456 })
26457 return gensupport.SendRequest(c.ctx_, c.s.client, req)
26458 }
26459
26460
26461
26462
26463
26464
26465
26466
26467 func (c *CreativeFieldsInsertCall) Do(opts ...googleapi.CallOption) (*CreativeField, error) {
26468 gensupport.SetOptions(c.urlParams_, opts...)
26469 res, err := c.doRequest("json")
26470 if res != nil && res.StatusCode == http.StatusNotModified {
26471 if res.Body != nil {
26472 res.Body.Close()
26473 }
26474 return nil, &googleapi.Error{
26475 Code: res.StatusCode,
26476 Header: res.Header,
26477 }
26478 }
26479 if err != nil {
26480 return nil, err
26481 }
26482 defer googleapi.CloseBody(res)
26483 if err := googleapi.CheckResponse(res); err != nil {
26484 return nil, err
26485 }
26486 ret := &CreativeField{
26487 ServerResponse: googleapi.ServerResponse{
26488 Header: res.Header,
26489 HTTPStatusCode: res.StatusCode,
26490 },
26491 }
26492 target := &ret
26493 if err := gensupport.DecodeResponse(target, res); err != nil {
26494 return nil, err
26495 }
26496 return ret, nil
26497
26498
26499
26500
26501
26502
26503
26504
26505
26506
26507
26508
26509
26510
26511
26512
26513
26514
26515
26516
26517
26518
26519
26520
26521
26522
26523
26524
26525 }
26526
26527
26528
26529 type CreativeFieldsListCall struct {
26530 s *Service
26531 profileId int64
26532 urlParams_ gensupport.URLParams
26533 ifNoneMatch_ string
26534 ctx_ context.Context
26535 header_ http.Header
26536 }
26537
26538
26539
26540 func (r *CreativeFieldsService) List(profileId int64) *CreativeFieldsListCall {
26541 c := &CreativeFieldsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
26542 c.profileId = profileId
26543 return c
26544 }
26545
26546
26547
26548 func (c *CreativeFieldsListCall) AdvertiserIds(advertiserIds ...int64) *CreativeFieldsListCall {
26549 var advertiserIds_ []string
26550 for _, v := range advertiserIds {
26551 advertiserIds_ = append(advertiserIds_, fmt.Sprint(v))
26552 }
26553 c.urlParams_.SetMulti("advertiserIds", advertiserIds_)
26554 return c
26555 }
26556
26557
26558
26559 func (c *CreativeFieldsListCall) Ids(ids ...int64) *CreativeFieldsListCall {
26560 var ids_ []string
26561 for _, v := range ids {
26562 ids_ = append(ids_, fmt.Sprint(v))
26563 }
26564 c.urlParams_.SetMulti("ids", ids_)
26565 return c
26566 }
26567
26568
26569
26570 func (c *CreativeFieldsListCall) MaxResults(maxResults int64) *CreativeFieldsListCall {
26571 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
26572 return c
26573 }
26574
26575
26576
26577 func (c *CreativeFieldsListCall) PageToken(pageToken string) *CreativeFieldsListCall {
26578 c.urlParams_.Set("pageToken", pageToken)
26579 return c
26580 }
26581
26582
26583
26584
26585
26586
26587
26588
26589
26590
26591 func (c *CreativeFieldsListCall) SearchString(searchString string) *CreativeFieldsListCall {
26592 c.urlParams_.Set("searchString", searchString)
26593 return c
26594 }
26595
26596
26597
26598
26599
26600
26601
26602
26603 func (c *CreativeFieldsListCall) SortField(sortField string) *CreativeFieldsListCall {
26604 c.urlParams_.Set("sortField", sortField)
26605 return c
26606 }
26607
26608
26609
26610
26611
26612
26613
26614
26615 func (c *CreativeFieldsListCall) SortOrder(sortOrder string) *CreativeFieldsListCall {
26616 c.urlParams_.Set("sortOrder", sortOrder)
26617 return c
26618 }
26619
26620
26621
26622
26623 func (c *CreativeFieldsListCall) Fields(s ...googleapi.Field) *CreativeFieldsListCall {
26624 c.urlParams_.Set("fields", googleapi.CombineFields(s))
26625 return c
26626 }
26627
26628
26629
26630
26631
26632
26633 func (c *CreativeFieldsListCall) IfNoneMatch(entityTag string) *CreativeFieldsListCall {
26634 c.ifNoneMatch_ = entityTag
26635 return c
26636 }
26637
26638
26639
26640
26641 func (c *CreativeFieldsListCall) Context(ctx context.Context) *CreativeFieldsListCall {
26642 c.ctx_ = ctx
26643 return c
26644 }
26645
26646
26647
26648 func (c *CreativeFieldsListCall) Header() http.Header {
26649 if c.header_ == nil {
26650 c.header_ = make(http.Header)
26651 }
26652 return c.header_
26653 }
26654
26655 func (c *CreativeFieldsListCall) doRequest(alt string) (*http.Response, error) {
26656 reqHeaders := make(http.Header)
26657 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
26658 for k, v := range c.header_ {
26659 reqHeaders[k] = v
26660 }
26661 reqHeaders.Set("User-Agent", c.s.userAgent())
26662 if c.ifNoneMatch_ != "" {
26663 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
26664 }
26665 var body io.Reader = nil
26666 c.urlParams_.Set("alt", alt)
26667 c.urlParams_.Set("prettyPrint", "false")
26668 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeFields")
26669 urls += "?" + c.urlParams_.Encode()
26670 req, err := http.NewRequest("GET", urls, body)
26671 if err != nil {
26672 return nil, err
26673 }
26674 req.Header = reqHeaders
26675 googleapi.Expand(req.URL, map[string]string{
26676 "profileId": strconv.FormatInt(c.profileId, 10),
26677 })
26678 return gensupport.SendRequest(c.ctx_, c.s.client, req)
26679 }
26680
26681
26682
26683
26684
26685
26686
26687
26688 func (c *CreativeFieldsListCall) Do(opts ...googleapi.CallOption) (*CreativeFieldsListResponse, error) {
26689 gensupport.SetOptions(c.urlParams_, opts...)
26690 res, err := c.doRequest("json")
26691 if res != nil && res.StatusCode == http.StatusNotModified {
26692 if res.Body != nil {
26693 res.Body.Close()
26694 }
26695 return nil, &googleapi.Error{
26696 Code: res.StatusCode,
26697 Header: res.Header,
26698 }
26699 }
26700 if err != nil {
26701 return nil, err
26702 }
26703 defer googleapi.CloseBody(res)
26704 if err := googleapi.CheckResponse(res); err != nil {
26705 return nil, err
26706 }
26707 ret := &CreativeFieldsListResponse{
26708 ServerResponse: googleapi.ServerResponse{
26709 Header: res.Header,
26710 HTTPStatusCode: res.StatusCode,
26711 },
26712 }
26713 target := &ret
26714 if err := gensupport.DecodeResponse(target, res); err != nil {
26715 return nil, err
26716 }
26717 return ret, nil
26718
26719
26720
26721
26722
26723
26724
26725
26726
26727
26728
26729
26730
26731
26732
26733
26734
26735
26736
26737
26738
26739
26740
26741
26742
26743
26744
26745
26746
26747
26748
26749
26750
26751
26752
26753
26754
26755
26756
26757
26758
26759
26760
26761
26762
26763
26764
26765
26766
26767
26768
26769
26770
26771
26772
26773
26774
26775
26776
26777
26778
26779
26780
26781
26782
26783
26784
26785
26786
26787
26788
26789
26790
26791
26792
26793
26794
26795
26796
26797
26798
26799
26800
26801
26802
26803
26804 }
26805
26806
26807
26808
26809 func (c *CreativeFieldsListCall) Pages(ctx context.Context, f func(*CreativeFieldsListResponse) error) error {
26810 c.ctx_ = ctx
26811 defer c.PageToken(c.urlParams_.Get("pageToken"))
26812 for {
26813 x, err := c.Do()
26814 if err != nil {
26815 return err
26816 }
26817 if err := f(x); err != nil {
26818 return err
26819 }
26820 if x.NextPageToken == "" {
26821 return nil
26822 }
26823 c.PageToken(x.NextPageToken)
26824 }
26825 }
26826
26827
26828
26829 type CreativeFieldsPatchCall struct {
26830 s *Service
26831 profileId int64
26832 creativefield *CreativeField
26833 urlParams_ gensupport.URLParams
26834 ctx_ context.Context
26835 header_ http.Header
26836 }
26837
26838
26839
26840 func (r *CreativeFieldsService) Patch(profileId int64, id int64, creativefield *CreativeField) *CreativeFieldsPatchCall {
26841 c := &CreativeFieldsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
26842 c.profileId = profileId
26843 c.urlParams_.Set("id", fmt.Sprint(id))
26844 c.creativefield = creativefield
26845 return c
26846 }
26847
26848
26849
26850
26851 func (c *CreativeFieldsPatchCall) Fields(s ...googleapi.Field) *CreativeFieldsPatchCall {
26852 c.urlParams_.Set("fields", googleapi.CombineFields(s))
26853 return c
26854 }
26855
26856
26857
26858
26859 func (c *CreativeFieldsPatchCall) Context(ctx context.Context) *CreativeFieldsPatchCall {
26860 c.ctx_ = ctx
26861 return c
26862 }
26863
26864
26865
26866 func (c *CreativeFieldsPatchCall) Header() http.Header {
26867 if c.header_ == nil {
26868 c.header_ = make(http.Header)
26869 }
26870 return c.header_
26871 }
26872
26873 func (c *CreativeFieldsPatchCall) doRequest(alt string) (*http.Response, error) {
26874 reqHeaders := make(http.Header)
26875 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
26876 for k, v := range c.header_ {
26877 reqHeaders[k] = v
26878 }
26879 reqHeaders.Set("User-Agent", c.s.userAgent())
26880 var body io.Reader = nil
26881 body, err := googleapi.WithoutDataWrapper.JSONReader(c.creativefield)
26882 if err != nil {
26883 return nil, err
26884 }
26885 reqHeaders.Set("Content-Type", "application/json")
26886 c.urlParams_.Set("alt", alt)
26887 c.urlParams_.Set("prettyPrint", "false")
26888 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeFields")
26889 urls += "?" + c.urlParams_.Encode()
26890 req, err := http.NewRequest("PATCH", urls, body)
26891 if err != nil {
26892 return nil, err
26893 }
26894 req.Header = reqHeaders
26895 googleapi.Expand(req.URL, map[string]string{
26896 "profileId": strconv.FormatInt(c.profileId, 10),
26897 })
26898 return gensupport.SendRequest(c.ctx_, c.s.client, req)
26899 }
26900
26901
26902
26903
26904
26905
26906
26907
26908 func (c *CreativeFieldsPatchCall) Do(opts ...googleapi.CallOption) (*CreativeField, error) {
26909 gensupport.SetOptions(c.urlParams_, opts...)
26910 res, err := c.doRequest("json")
26911 if res != nil && res.StatusCode == http.StatusNotModified {
26912 if res.Body != nil {
26913 res.Body.Close()
26914 }
26915 return nil, &googleapi.Error{
26916 Code: res.StatusCode,
26917 Header: res.Header,
26918 }
26919 }
26920 if err != nil {
26921 return nil, err
26922 }
26923 defer googleapi.CloseBody(res)
26924 if err := googleapi.CheckResponse(res); err != nil {
26925 return nil, err
26926 }
26927 ret := &CreativeField{
26928 ServerResponse: googleapi.ServerResponse{
26929 Header: res.Header,
26930 HTTPStatusCode: res.StatusCode,
26931 },
26932 }
26933 target := &ret
26934 if err := gensupport.DecodeResponse(target, res); err != nil {
26935 return nil, err
26936 }
26937 return ret, nil
26938
26939
26940
26941
26942
26943
26944
26945
26946
26947
26948
26949
26950
26951
26952
26953
26954
26955
26956
26957
26958
26959
26960
26961
26962
26963
26964
26965
26966
26967
26968
26969
26970
26971
26972
26973
26974 }
26975
26976
26977
26978 type CreativeFieldsUpdateCall struct {
26979 s *Service
26980 profileId int64
26981 creativefield *CreativeField
26982 urlParams_ gensupport.URLParams
26983 ctx_ context.Context
26984 header_ http.Header
26985 }
26986
26987
26988 func (r *CreativeFieldsService) Update(profileId int64, creativefield *CreativeField) *CreativeFieldsUpdateCall {
26989 c := &CreativeFieldsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
26990 c.profileId = profileId
26991 c.creativefield = creativefield
26992 return c
26993 }
26994
26995
26996
26997
26998 func (c *CreativeFieldsUpdateCall) Fields(s ...googleapi.Field) *CreativeFieldsUpdateCall {
26999 c.urlParams_.Set("fields", googleapi.CombineFields(s))
27000 return c
27001 }
27002
27003
27004
27005
27006 func (c *CreativeFieldsUpdateCall) Context(ctx context.Context) *CreativeFieldsUpdateCall {
27007 c.ctx_ = ctx
27008 return c
27009 }
27010
27011
27012
27013 func (c *CreativeFieldsUpdateCall) Header() http.Header {
27014 if c.header_ == nil {
27015 c.header_ = make(http.Header)
27016 }
27017 return c.header_
27018 }
27019
27020 func (c *CreativeFieldsUpdateCall) doRequest(alt string) (*http.Response, error) {
27021 reqHeaders := make(http.Header)
27022 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
27023 for k, v := range c.header_ {
27024 reqHeaders[k] = v
27025 }
27026 reqHeaders.Set("User-Agent", c.s.userAgent())
27027 var body io.Reader = nil
27028 body, err := googleapi.WithoutDataWrapper.JSONReader(c.creativefield)
27029 if err != nil {
27030 return nil, err
27031 }
27032 reqHeaders.Set("Content-Type", "application/json")
27033 c.urlParams_.Set("alt", alt)
27034 c.urlParams_.Set("prettyPrint", "false")
27035 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeFields")
27036 urls += "?" + c.urlParams_.Encode()
27037 req, err := http.NewRequest("PUT", urls, body)
27038 if err != nil {
27039 return nil, err
27040 }
27041 req.Header = reqHeaders
27042 googleapi.Expand(req.URL, map[string]string{
27043 "profileId": strconv.FormatInt(c.profileId, 10),
27044 })
27045 return gensupport.SendRequest(c.ctx_, c.s.client, req)
27046 }
27047
27048
27049
27050
27051
27052
27053
27054
27055 func (c *CreativeFieldsUpdateCall) Do(opts ...googleapi.CallOption) (*CreativeField, error) {
27056 gensupport.SetOptions(c.urlParams_, opts...)
27057 res, err := c.doRequest("json")
27058 if res != nil && res.StatusCode == http.StatusNotModified {
27059 if res.Body != nil {
27060 res.Body.Close()
27061 }
27062 return nil, &googleapi.Error{
27063 Code: res.StatusCode,
27064 Header: res.Header,
27065 }
27066 }
27067 if err != nil {
27068 return nil, err
27069 }
27070 defer googleapi.CloseBody(res)
27071 if err := googleapi.CheckResponse(res); err != nil {
27072 return nil, err
27073 }
27074 ret := &CreativeField{
27075 ServerResponse: googleapi.ServerResponse{
27076 Header: res.Header,
27077 HTTPStatusCode: res.StatusCode,
27078 },
27079 }
27080 target := &ret
27081 if err := gensupport.DecodeResponse(target, res); err != nil {
27082 return nil, err
27083 }
27084 return ret, nil
27085
27086
27087
27088
27089
27090
27091
27092
27093
27094
27095
27096
27097
27098
27099
27100
27101
27102
27103
27104
27105
27106
27107
27108
27109
27110
27111
27112
27113 }
27114
27115
27116
27117 type CreativeGroupsGetCall struct {
27118 s *Service
27119 profileId int64
27120 id int64
27121 urlParams_ gensupport.URLParams
27122 ifNoneMatch_ string
27123 ctx_ context.Context
27124 header_ http.Header
27125 }
27126
27127
27128 func (r *CreativeGroupsService) Get(profileId int64, id int64) *CreativeGroupsGetCall {
27129 c := &CreativeGroupsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
27130 c.profileId = profileId
27131 c.id = id
27132 return c
27133 }
27134
27135
27136
27137
27138 func (c *CreativeGroupsGetCall) Fields(s ...googleapi.Field) *CreativeGroupsGetCall {
27139 c.urlParams_.Set("fields", googleapi.CombineFields(s))
27140 return c
27141 }
27142
27143
27144
27145
27146
27147
27148 func (c *CreativeGroupsGetCall) IfNoneMatch(entityTag string) *CreativeGroupsGetCall {
27149 c.ifNoneMatch_ = entityTag
27150 return c
27151 }
27152
27153
27154
27155
27156 func (c *CreativeGroupsGetCall) Context(ctx context.Context) *CreativeGroupsGetCall {
27157 c.ctx_ = ctx
27158 return c
27159 }
27160
27161
27162
27163 func (c *CreativeGroupsGetCall) Header() http.Header {
27164 if c.header_ == nil {
27165 c.header_ = make(http.Header)
27166 }
27167 return c.header_
27168 }
27169
27170 func (c *CreativeGroupsGetCall) doRequest(alt string) (*http.Response, error) {
27171 reqHeaders := make(http.Header)
27172 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
27173 for k, v := range c.header_ {
27174 reqHeaders[k] = v
27175 }
27176 reqHeaders.Set("User-Agent", c.s.userAgent())
27177 if c.ifNoneMatch_ != "" {
27178 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
27179 }
27180 var body io.Reader = nil
27181 c.urlParams_.Set("alt", alt)
27182 c.urlParams_.Set("prettyPrint", "false")
27183 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeGroups/{id}")
27184 urls += "?" + c.urlParams_.Encode()
27185 req, err := http.NewRequest("GET", urls, body)
27186 if err != nil {
27187 return nil, err
27188 }
27189 req.Header = reqHeaders
27190 googleapi.Expand(req.URL, map[string]string{
27191 "profileId": strconv.FormatInt(c.profileId, 10),
27192 "id": strconv.FormatInt(c.id, 10),
27193 })
27194 return gensupport.SendRequest(c.ctx_, c.s.client, req)
27195 }
27196
27197
27198
27199
27200
27201
27202
27203
27204 func (c *CreativeGroupsGetCall) Do(opts ...googleapi.CallOption) (*CreativeGroup, error) {
27205 gensupport.SetOptions(c.urlParams_, opts...)
27206 res, err := c.doRequest("json")
27207 if res != nil && res.StatusCode == http.StatusNotModified {
27208 if res.Body != nil {
27209 res.Body.Close()
27210 }
27211 return nil, &googleapi.Error{
27212 Code: res.StatusCode,
27213 Header: res.Header,
27214 }
27215 }
27216 if err != nil {
27217 return nil, err
27218 }
27219 defer googleapi.CloseBody(res)
27220 if err := googleapi.CheckResponse(res); err != nil {
27221 return nil, err
27222 }
27223 ret := &CreativeGroup{
27224 ServerResponse: googleapi.ServerResponse{
27225 Header: res.Header,
27226 HTTPStatusCode: res.StatusCode,
27227 },
27228 }
27229 target := &ret
27230 if err := gensupport.DecodeResponse(target, res); err != nil {
27231 return nil, err
27232 }
27233 return ret, nil
27234
27235
27236
27237
27238
27239
27240
27241
27242
27243
27244
27245
27246
27247
27248
27249
27250
27251
27252
27253
27254
27255
27256
27257
27258
27259
27260
27261
27262
27263
27264
27265
27266
27267 }
27268
27269
27270
27271 type CreativeGroupsInsertCall struct {
27272 s *Service
27273 profileId int64
27274 creativegroup *CreativeGroup
27275 urlParams_ gensupport.URLParams
27276 ctx_ context.Context
27277 header_ http.Header
27278 }
27279
27280
27281 func (r *CreativeGroupsService) Insert(profileId int64, creativegroup *CreativeGroup) *CreativeGroupsInsertCall {
27282 c := &CreativeGroupsInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
27283 c.profileId = profileId
27284 c.creativegroup = creativegroup
27285 return c
27286 }
27287
27288
27289
27290
27291 func (c *CreativeGroupsInsertCall) Fields(s ...googleapi.Field) *CreativeGroupsInsertCall {
27292 c.urlParams_.Set("fields", googleapi.CombineFields(s))
27293 return c
27294 }
27295
27296
27297
27298
27299 func (c *CreativeGroupsInsertCall) Context(ctx context.Context) *CreativeGroupsInsertCall {
27300 c.ctx_ = ctx
27301 return c
27302 }
27303
27304
27305
27306 func (c *CreativeGroupsInsertCall) Header() http.Header {
27307 if c.header_ == nil {
27308 c.header_ = make(http.Header)
27309 }
27310 return c.header_
27311 }
27312
27313 func (c *CreativeGroupsInsertCall) doRequest(alt string) (*http.Response, error) {
27314 reqHeaders := make(http.Header)
27315 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
27316 for k, v := range c.header_ {
27317 reqHeaders[k] = v
27318 }
27319 reqHeaders.Set("User-Agent", c.s.userAgent())
27320 var body io.Reader = nil
27321 body, err := googleapi.WithoutDataWrapper.JSONReader(c.creativegroup)
27322 if err != nil {
27323 return nil, err
27324 }
27325 reqHeaders.Set("Content-Type", "application/json")
27326 c.urlParams_.Set("alt", alt)
27327 c.urlParams_.Set("prettyPrint", "false")
27328 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeGroups")
27329 urls += "?" + c.urlParams_.Encode()
27330 req, err := http.NewRequest("POST", urls, body)
27331 if err != nil {
27332 return nil, err
27333 }
27334 req.Header = reqHeaders
27335 googleapi.Expand(req.URL, map[string]string{
27336 "profileId": strconv.FormatInt(c.profileId, 10),
27337 })
27338 return gensupport.SendRequest(c.ctx_, c.s.client, req)
27339 }
27340
27341
27342
27343
27344
27345
27346
27347
27348 func (c *CreativeGroupsInsertCall) Do(opts ...googleapi.CallOption) (*CreativeGroup, error) {
27349 gensupport.SetOptions(c.urlParams_, opts...)
27350 res, err := c.doRequest("json")
27351 if res != nil && res.StatusCode == http.StatusNotModified {
27352 if res.Body != nil {
27353 res.Body.Close()
27354 }
27355 return nil, &googleapi.Error{
27356 Code: res.StatusCode,
27357 Header: res.Header,
27358 }
27359 }
27360 if err != nil {
27361 return nil, err
27362 }
27363 defer googleapi.CloseBody(res)
27364 if err := googleapi.CheckResponse(res); err != nil {
27365 return nil, err
27366 }
27367 ret := &CreativeGroup{
27368 ServerResponse: googleapi.ServerResponse{
27369 Header: res.Header,
27370 HTTPStatusCode: res.StatusCode,
27371 },
27372 }
27373 target := &ret
27374 if err := gensupport.DecodeResponse(target, res); err != nil {
27375 return nil, err
27376 }
27377 return ret, nil
27378
27379
27380
27381
27382
27383
27384
27385
27386
27387
27388
27389
27390
27391
27392
27393
27394
27395
27396
27397
27398
27399
27400
27401
27402
27403
27404
27405
27406 }
27407
27408
27409
27410 type CreativeGroupsListCall struct {
27411 s *Service
27412 profileId int64
27413 urlParams_ gensupport.URLParams
27414 ifNoneMatch_ string
27415 ctx_ context.Context
27416 header_ http.Header
27417 }
27418
27419
27420
27421 func (r *CreativeGroupsService) List(profileId int64) *CreativeGroupsListCall {
27422 c := &CreativeGroupsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
27423 c.profileId = profileId
27424 return c
27425 }
27426
27427
27428
27429 func (c *CreativeGroupsListCall) AdvertiserIds(advertiserIds ...int64) *CreativeGroupsListCall {
27430 var advertiserIds_ []string
27431 for _, v := range advertiserIds {
27432 advertiserIds_ = append(advertiserIds_, fmt.Sprint(v))
27433 }
27434 c.urlParams_.SetMulti("advertiserIds", advertiserIds_)
27435 return c
27436 }
27437
27438
27439
27440 func (c *CreativeGroupsListCall) GroupNumber(groupNumber int64) *CreativeGroupsListCall {
27441 c.urlParams_.Set("groupNumber", fmt.Sprint(groupNumber))
27442 return c
27443 }
27444
27445
27446
27447 func (c *CreativeGroupsListCall) Ids(ids ...int64) *CreativeGroupsListCall {
27448 var ids_ []string
27449 for _, v := range ids {
27450 ids_ = append(ids_, fmt.Sprint(v))
27451 }
27452 c.urlParams_.SetMulti("ids", ids_)
27453 return c
27454 }
27455
27456
27457
27458 func (c *CreativeGroupsListCall) MaxResults(maxResults int64) *CreativeGroupsListCall {
27459 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
27460 return c
27461 }
27462
27463
27464
27465 func (c *CreativeGroupsListCall) PageToken(pageToken string) *CreativeGroupsListCall {
27466 c.urlParams_.Set("pageToken", pageToken)
27467 return c
27468 }
27469
27470
27471
27472
27473
27474
27475
27476
27477
27478
27479 func (c *CreativeGroupsListCall) SearchString(searchString string) *CreativeGroupsListCall {
27480 c.urlParams_.Set("searchString", searchString)
27481 return c
27482 }
27483
27484
27485
27486
27487
27488
27489
27490
27491 func (c *CreativeGroupsListCall) SortField(sortField string) *CreativeGroupsListCall {
27492 c.urlParams_.Set("sortField", sortField)
27493 return c
27494 }
27495
27496
27497
27498
27499
27500
27501
27502
27503 func (c *CreativeGroupsListCall) SortOrder(sortOrder string) *CreativeGroupsListCall {
27504 c.urlParams_.Set("sortOrder", sortOrder)
27505 return c
27506 }
27507
27508
27509
27510
27511 func (c *CreativeGroupsListCall) Fields(s ...googleapi.Field) *CreativeGroupsListCall {
27512 c.urlParams_.Set("fields", googleapi.CombineFields(s))
27513 return c
27514 }
27515
27516
27517
27518
27519
27520
27521 func (c *CreativeGroupsListCall) IfNoneMatch(entityTag string) *CreativeGroupsListCall {
27522 c.ifNoneMatch_ = entityTag
27523 return c
27524 }
27525
27526
27527
27528
27529 func (c *CreativeGroupsListCall) Context(ctx context.Context) *CreativeGroupsListCall {
27530 c.ctx_ = ctx
27531 return c
27532 }
27533
27534
27535
27536 func (c *CreativeGroupsListCall) Header() http.Header {
27537 if c.header_ == nil {
27538 c.header_ = make(http.Header)
27539 }
27540 return c.header_
27541 }
27542
27543 func (c *CreativeGroupsListCall) doRequest(alt string) (*http.Response, error) {
27544 reqHeaders := make(http.Header)
27545 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
27546 for k, v := range c.header_ {
27547 reqHeaders[k] = v
27548 }
27549 reqHeaders.Set("User-Agent", c.s.userAgent())
27550 if c.ifNoneMatch_ != "" {
27551 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
27552 }
27553 var body io.Reader = nil
27554 c.urlParams_.Set("alt", alt)
27555 c.urlParams_.Set("prettyPrint", "false")
27556 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeGroups")
27557 urls += "?" + c.urlParams_.Encode()
27558 req, err := http.NewRequest("GET", urls, body)
27559 if err != nil {
27560 return nil, err
27561 }
27562 req.Header = reqHeaders
27563 googleapi.Expand(req.URL, map[string]string{
27564 "profileId": strconv.FormatInt(c.profileId, 10),
27565 })
27566 return gensupport.SendRequest(c.ctx_, c.s.client, req)
27567 }
27568
27569
27570
27571
27572
27573
27574
27575
27576 func (c *CreativeGroupsListCall) Do(opts ...googleapi.CallOption) (*CreativeGroupsListResponse, error) {
27577 gensupport.SetOptions(c.urlParams_, opts...)
27578 res, err := c.doRequest("json")
27579 if res != nil && res.StatusCode == http.StatusNotModified {
27580 if res.Body != nil {
27581 res.Body.Close()
27582 }
27583 return nil, &googleapi.Error{
27584 Code: res.StatusCode,
27585 Header: res.Header,
27586 }
27587 }
27588 if err != nil {
27589 return nil, err
27590 }
27591 defer googleapi.CloseBody(res)
27592 if err := googleapi.CheckResponse(res); err != nil {
27593 return nil, err
27594 }
27595 ret := &CreativeGroupsListResponse{
27596 ServerResponse: googleapi.ServerResponse{
27597 Header: res.Header,
27598 HTTPStatusCode: res.StatusCode,
27599 },
27600 }
27601 target := &ret
27602 if err := gensupport.DecodeResponse(target, res); err != nil {
27603 return nil, err
27604 }
27605 return ret, nil
27606
27607
27608
27609
27610
27611
27612
27613
27614
27615
27616
27617
27618
27619
27620
27621
27622
27623
27624
27625
27626
27627
27628
27629
27630
27631
27632
27633
27634
27635
27636
27637
27638
27639
27640
27641
27642
27643
27644
27645
27646
27647
27648
27649
27650
27651
27652
27653
27654
27655
27656
27657
27658
27659
27660
27661
27662
27663
27664
27665
27666
27667
27668
27669
27670
27671
27672
27673
27674
27675
27676
27677
27678
27679
27680
27681
27682
27683
27684
27685
27686
27687
27688
27689
27690
27691
27692
27693
27694
27695
27696
27697
27698
27699
27700 }
27701
27702
27703
27704
27705 func (c *CreativeGroupsListCall) Pages(ctx context.Context, f func(*CreativeGroupsListResponse) error) error {
27706 c.ctx_ = ctx
27707 defer c.PageToken(c.urlParams_.Get("pageToken"))
27708 for {
27709 x, err := c.Do()
27710 if err != nil {
27711 return err
27712 }
27713 if err := f(x); err != nil {
27714 return err
27715 }
27716 if x.NextPageToken == "" {
27717 return nil
27718 }
27719 c.PageToken(x.NextPageToken)
27720 }
27721 }
27722
27723
27724
27725 type CreativeGroupsPatchCall struct {
27726 s *Service
27727 profileId int64
27728 creativegroup *CreativeGroup
27729 urlParams_ gensupport.URLParams
27730 ctx_ context.Context
27731 header_ http.Header
27732 }
27733
27734
27735
27736 func (r *CreativeGroupsService) Patch(profileId int64, id int64, creativegroup *CreativeGroup) *CreativeGroupsPatchCall {
27737 c := &CreativeGroupsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
27738 c.profileId = profileId
27739 c.urlParams_.Set("id", fmt.Sprint(id))
27740 c.creativegroup = creativegroup
27741 return c
27742 }
27743
27744
27745
27746
27747 func (c *CreativeGroupsPatchCall) Fields(s ...googleapi.Field) *CreativeGroupsPatchCall {
27748 c.urlParams_.Set("fields", googleapi.CombineFields(s))
27749 return c
27750 }
27751
27752
27753
27754
27755 func (c *CreativeGroupsPatchCall) Context(ctx context.Context) *CreativeGroupsPatchCall {
27756 c.ctx_ = ctx
27757 return c
27758 }
27759
27760
27761
27762 func (c *CreativeGroupsPatchCall) Header() http.Header {
27763 if c.header_ == nil {
27764 c.header_ = make(http.Header)
27765 }
27766 return c.header_
27767 }
27768
27769 func (c *CreativeGroupsPatchCall) doRequest(alt string) (*http.Response, error) {
27770 reqHeaders := make(http.Header)
27771 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
27772 for k, v := range c.header_ {
27773 reqHeaders[k] = v
27774 }
27775 reqHeaders.Set("User-Agent", c.s.userAgent())
27776 var body io.Reader = nil
27777 body, err := googleapi.WithoutDataWrapper.JSONReader(c.creativegroup)
27778 if err != nil {
27779 return nil, err
27780 }
27781 reqHeaders.Set("Content-Type", "application/json")
27782 c.urlParams_.Set("alt", alt)
27783 c.urlParams_.Set("prettyPrint", "false")
27784 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeGroups")
27785 urls += "?" + c.urlParams_.Encode()
27786 req, err := http.NewRequest("PATCH", urls, body)
27787 if err != nil {
27788 return nil, err
27789 }
27790 req.Header = reqHeaders
27791 googleapi.Expand(req.URL, map[string]string{
27792 "profileId": strconv.FormatInt(c.profileId, 10),
27793 })
27794 return gensupport.SendRequest(c.ctx_, c.s.client, req)
27795 }
27796
27797
27798
27799
27800
27801
27802
27803
27804 func (c *CreativeGroupsPatchCall) Do(opts ...googleapi.CallOption) (*CreativeGroup, error) {
27805 gensupport.SetOptions(c.urlParams_, opts...)
27806 res, err := c.doRequest("json")
27807 if res != nil && res.StatusCode == http.StatusNotModified {
27808 if res.Body != nil {
27809 res.Body.Close()
27810 }
27811 return nil, &googleapi.Error{
27812 Code: res.StatusCode,
27813 Header: res.Header,
27814 }
27815 }
27816 if err != nil {
27817 return nil, err
27818 }
27819 defer googleapi.CloseBody(res)
27820 if err := googleapi.CheckResponse(res); err != nil {
27821 return nil, err
27822 }
27823 ret := &CreativeGroup{
27824 ServerResponse: googleapi.ServerResponse{
27825 Header: res.Header,
27826 HTTPStatusCode: res.StatusCode,
27827 },
27828 }
27829 target := &ret
27830 if err := gensupport.DecodeResponse(target, res); err != nil {
27831 return nil, err
27832 }
27833 return ret, nil
27834
27835
27836
27837
27838
27839
27840
27841
27842
27843
27844
27845
27846
27847
27848
27849
27850
27851
27852
27853
27854
27855
27856
27857
27858
27859
27860
27861
27862
27863
27864
27865
27866
27867
27868
27869
27870 }
27871
27872
27873
27874 type CreativeGroupsUpdateCall struct {
27875 s *Service
27876 profileId int64
27877 creativegroup *CreativeGroup
27878 urlParams_ gensupport.URLParams
27879 ctx_ context.Context
27880 header_ http.Header
27881 }
27882
27883
27884 func (r *CreativeGroupsService) Update(profileId int64, creativegroup *CreativeGroup) *CreativeGroupsUpdateCall {
27885 c := &CreativeGroupsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
27886 c.profileId = profileId
27887 c.creativegroup = creativegroup
27888 return c
27889 }
27890
27891
27892
27893
27894 func (c *CreativeGroupsUpdateCall) Fields(s ...googleapi.Field) *CreativeGroupsUpdateCall {
27895 c.urlParams_.Set("fields", googleapi.CombineFields(s))
27896 return c
27897 }
27898
27899
27900
27901
27902 func (c *CreativeGroupsUpdateCall) Context(ctx context.Context) *CreativeGroupsUpdateCall {
27903 c.ctx_ = ctx
27904 return c
27905 }
27906
27907
27908
27909 func (c *CreativeGroupsUpdateCall) Header() http.Header {
27910 if c.header_ == nil {
27911 c.header_ = make(http.Header)
27912 }
27913 return c.header_
27914 }
27915
27916 func (c *CreativeGroupsUpdateCall) doRequest(alt string) (*http.Response, error) {
27917 reqHeaders := make(http.Header)
27918 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
27919 for k, v := range c.header_ {
27920 reqHeaders[k] = v
27921 }
27922 reqHeaders.Set("User-Agent", c.s.userAgent())
27923 var body io.Reader = nil
27924 body, err := googleapi.WithoutDataWrapper.JSONReader(c.creativegroup)
27925 if err != nil {
27926 return nil, err
27927 }
27928 reqHeaders.Set("Content-Type", "application/json")
27929 c.urlParams_.Set("alt", alt)
27930 c.urlParams_.Set("prettyPrint", "false")
27931 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeGroups")
27932 urls += "?" + c.urlParams_.Encode()
27933 req, err := http.NewRequest("PUT", urls, body)
27934 if err != nil {
27935 return nil, err
27936 }
27937 req.Header = reqHeaders
27938 googleapi.Expand(req.URL, map[string]string{
27939 "profileId": strconv.FormatInt(c.profileId, 10),
27940 })
27941 return gensupport.SendRequest(c.ctx_, c.s.client, req)
27942 }
27943
27944
27945
27946
27947
27948
27949
27950
27951 func (c *CreativeGroupsUpdateCall) Do(opts ...googleapi.CallOption) (*CreativeGroup, error) {
27952 gensupport.SetOptions(c.urlParams_, opts...)
27953 res, err := c.doRequest("json")
27954 if res != nil && res.StatusCode == http.StatusNotModified {
27955 if res.Body != nil {
27956 res.Body.Close()
27957 }
27958 return nil, &googleapi.Error{
27959 Code: res.StatusCode,
27960 Header: res.Header,
27961 }
27962 }
27963 if err != nil {
27964 return nil, err
27965 }
27966 defer googleapi.CloseBody(res)
27967 if err := googleapi.CheckResponse(res); err != nil {
27968 return nil, err
27969 }
27970 ret := &CreativeGroup{
27971 ServerResponse: googleapi.ServerResponse{
27972 Header: res.Header,
27973 HTTPStatusCode: res.StatusCode,
27974 },
27975 }
27976 target := &ret
27977 if err := gensupport.DecodeResponse(target, res); err != nil {
27978 return nil, err
27979 }
27980 return ret, nil
27981
27982
27983
27984
27985
27986
27987
27988
27989
27990
27991
27992
27993
27994
27995
27996
27997
27998
27999
28000
28001
28002
28003
28004
28005
28006
28007
28008
28009 }
28010
28011
28012
28013 type CreativesGetCall struct {
28014 s *Service
28015 profileId int64
28016 id int64
28017 urlParams_ gensupport.URLParams
28018 ifNoneMatch_ string
28019 ctx_ context.Context
28020 header_ http.Header
28021 }
28022
28023
28024 func (r *CreativesService) Get(profileId int64, id int64) *CreativesGetCall {
28025 c := &CreativesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
28026 c.profileId = profileId
28027 c.id = id
28028 return c
28029 }
28030
28031
28032
28033
28034 func (c *CreativesGetCall) Fields(s ...googleapi.Field) *CreativesGetCall {
28035 c.urlParams_.Set("fields", googleapi.CombineFields(s))
28036 return c
28037 }
28038
28039
28040
28041
28042
28043
28044 func (c *CreativesGetCall) IfNoneMatch(entityTag string) *CreativesGetCall {
28045 c.ifNoneMatch_ = entityTag
28046 return c
28047 }
28048
28049
28050
28051
28052 func (c *CreativesGetCall) Context(ctx context.Context) *CreativesGetCall {
28053 c.ctx_ = ctx
28054 return c
28055 }
28056
28057
28058
28059 func (c *CreativesGetCall) Header() http.Header {
28060 if c.header_ == nil {
28061 c.header_ = make(http.Header)
28062 }
28063 return c.header_
28064 }
28065
28066 func (c *CreativesGetCall) doRequest(alt string) (*http.Response, error) {
28067 reqHeaders := make(http.Header)
28068 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
28069 for k, v := range c.header_ {
28070 reqHeaders[k] = v
28071 }
28072 reqHeaders.Set("User-Agent", c.s.userAgent())
28073 if c.ifNoneMatch_ != "" {
28074 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
28075 }
28076 var body io.Reader = nil
28077 c.urlParams_.Set("alt", alt)
28078 c.urlParams_.Set("prettyPrint", "false")
28079 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creatives/{id}")
28080 urls += "?" + c.urlParams_.Encode()
28081 req, err := http.NewRequest("GET", urls, body)
28082 if err != nil {
28083 return nil, err
28084 }
28085 req.Header = reqHeaders
28086 googleapi.Expand(req.URL, map[string]string{
28087 "profileId": strconv.FormatInt(c.profileId, 10),
28088 "id": strconv.FormatInt(c.id, 10),
28089 })
28090 return gensupport.SendRequest(c.ctx_, c.s.client, req)
28091 }
28092
28093
28094
28095
28096
28097
28098
28099
28100 func (c *CreativesGetCall) Do(opts ...googleapi.CallOption) (*Creative, error) {
28101 gensupport.SetOptions(c.urlParams_, opts...)
28102 res, err := c.doRequest("json")
28103 if res != nil && res.StatusCode == http.StatusNotModified {
28104 if res.Body != nil {
28105 res.Body.Close()
28106 }
28107 return nil, &googleapi.Error{
28108 Code: res.StatusCode,
28109 Header: res.Header,
28110 }
28111 }
28112 if err != nil {
28113 return nil, err
28114 }
28115 defer googleapi.CloseBody(res)
28116 if err := googleapi.CheckResponse(res); err != nil {
28117 return nil, err
28118 }
28119 ret := &Creative{
28120 ServerResponse: googleapi.ServerResponse{
28121 Header: res.Header,
28122 HTTPStatusCode: res.StatusCode,
28123 },
28124 }
28125 target := &ret
28126 if err := gensupport.DecodeResponse(target, res); err != nil {
28127 return nil, err
28128 }
28129 return ret, nil
28130
28131
28132
28133
28134
28135
28136
28137
28138
28139
28140
28141
28142
28143
28144
28145
28146
28147
28148
28149
28150
28151
28152
28153
28154
28155
28156
28157
28158
28159
28160
28161
28162
28163 }
28164
28165
28166
28167 type CreativesInsertCall struct {
28168 s *Service
28169 profileId int64
28170 creative *Creative
28171 urlParams_ gensupport.URLParams
28172 ctx_ context.Context
28173 header_ http.Header
28174 }
28175
28176
28177 func (r *CreativesService) Insert(profileId int64, creative *Creative) *CreativesInsertCall {
28178 c := &CreativesInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
28179 c.profileId = profileId
28180 c.creative = creative
28181 return c
28182 }
28183
28184
28185
28186
28187 func (c *CreativesInsertCall) Fields(s ...googleapi.Field) *CreativesInsertCall {
28188 c.urlParams_.Set("fields", googleapi.CombineFields(s))
28189 return c
28190 }
28191
28192
28193
28194
28195 func (c *CreativesInsertCall) Context(ctx context.Context) *CreativesInsertCall {
28196 c.ctx_ = ctx
28197 return c
28198 }
28199
28200
28201
28202 func (c *CreativesInsertCall) Header() http.Header {
28203 if c.header_ == nil {
28204 c.header_ = make(http.Header)
28205 }
28206 return c.header_
28207 }
28208
28209 func (c *CreativesInsertCall) doRequest(alt string) (*http.Response, error) {
28210 reqHeaders := make(http.Header)
28211 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
28212 for k, v := range c.header_ {
28213 reqHeaders[k] = v
28214 }
28215 reqHeaders.Set("User-Agent", c.s.userAgent())
28216 var body io.Reader = nil
28217 body, err := googleapi.WithoutDataWrapper.JSONReader(c.creative)
28218 if err != nil {
28219 return nil, err
28220 }
28221 reqHeaders.Set("Content-Type", "application/json")
28222 c.urlParams_.Set("alt", alt)
28223 c.urlParams_.Set("prettyPrint", "false")
28224 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creatives")
28225 urls += "?" + c.urlParams_.Encode()
28226 req, err := http.NewRequest("POST", urls, body)
28227 if err != nil {
28228 return nil, err
28229 }
28230 req.Header = reqHeaders
28231 googleapi.Expand(req.URL, map[string]string{
28232 "profileId": strconv.FormatInt(c.profileId, 10),
28233 })
28234 return gensupport.SendRequest(c.ctx_, c.s.client, req)
28235 }
28236
28237
28238
28239
28240
28241
28242
28243
28244 func (c *CreativesInsertCall) Do(opts ...googleapi.CallOption) (*Creative, error) {
28245 gensupport.SetOptions(c.urlParams_, opts...)
28246 res, err := c.doRequest("json")
28247 if res != nil && res.StatusCode == http.StatusNotModified {
28248 if res.Body != nil {
28249 res.Body.Close()
28250 }
28251 return nil, &googleapi.Error{
28252 Code: res.StatusCode,
28253 Header: res.Header,
28254 }
28255 }
28256 if err != nil {
28257 return nil, err
28258 }
28259 defer googleapi.CloseBody(res)
28260 if err := googleapi.CheckResponse(res); err != nil {
28261 return nil, err
28262 }
28263 ret := &Creative{
28264 ServerResponse: googleapi.ServerResponse{
28265 Header: res.Header,
28266 HTTPStatusCode: res.StatusCode,
28267 },
28268 }
28269 target := &ret
28270 if err := gensupport.DecodeResponse(target, res); err != nil {
28271 return nil, err
28272 }
28273 return ret, nil
28274
28275
28276
28277
28278
28279
28280
28281
28282
28283
28284
28285
28286
28287
28288
28289
28290
28291
28292
28293
28294
28295
28296
28297
28298
28299
28300
28301
28302 }
28303
28304
28305
28306 type CreativesListCall struct {
28307 s *Service
28308 profileId int64
28309 urlParams_ gensupport.URLParams
28310 ifNoneMatch_ string
28311 ctx_ context.Context
28312 header_ http.Header
28313 }
28314
28315
28316
28317 func (r *CreativesService) List(profileId int64) *CreativesListCall {
28318 c := &CreativesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
28319 c.profileId = profileId
28320 return c
28321 }
28322
28323
28324
28325 func (c *CreativesListCall) Active(active bool) *CreativesListCall {
28326 c.urlParams_.Set("active", fmt.Sprint(active))
28327 return c
28328 }
28329
28330
28331
28332 func (c *CreativesListCall) AdvertiserId(advertiserId int64) *CreativesListCall {
28333 c.urlParams_.Set("advertiserId", fmt.Sprint(advertiserId))
28334 return c
28335 }
28336
28337
28338
28339 func (c *CreativesListCall) Archived(archived bool) *CreativesListCall {
28340 c.urlParams_.Set("archived", fmt.Sprint(archived))
28341 return c
28342 }
28343
28344
28345
28346 func (c *CreativesListCall) CampaignId(campaignId int64) *CreativesListCall {
28347 c.urlParams_.Set("campaignId", fmt.Sprint(campaignId))
28348 return c
28349 }
28350
28351
28352
28353
28354 func (c *CreativesListCall) CompanionCreativeIds(companionCreativeIds ...int64) *CreativesListCall {
28355 var companionCreativeIds_ []string
28356 for _, v := range companionCreativeIds {
28357 companionCreativeIds_ = append(companionCreativeIds_, fmt.Sprint(v))
28358 }
28359 c.urlParams_.SetMulti("companionCreativeIds", companionCreativeIds_)
28360 return c
28361 }
28362
28363
28364
28365 func (c *CreativesListCall) CreativeFieldIds(creativeFieldIds ...int64) *CreativesListCall {
28366 var creativeFieldIds_ []string
28367 for _, v := range creativeFieldIds {
28368 creativeFieldIds_ = append(creativeFieldIds_, fmt.Sprint(v))
28369 }
28370 c.urlParams_.SetMulti("creativeFieldIds", creativeFieldIds_)
28371 return c
28372 }
28373
28374
28375
28376 func (c *CreativesListCall) Ids(ids ...int64) *CreativesListCall {
28377 var ids_ []string
28378 for _, v := range ids {
28379 ids_ = append(ids_, fmt.Sprint(v))
28380 }
28381 c.urlParams_.SetMulti("ids", ids_)
28382 return c
28383 }
28384
28385
28386
28387 func (c *CreativesListCall) MaxResults(maxResults int64) *CreativesListCall {
28388 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
28389 return c
28390 }
28391
28392
28393
28394 func (c *CreativesListCall) PageToken(pageToken string) *CreativesListCall {
28395 c.urlParams_.Set("pageToken", pageToken)
28396 return c
28397 }
28398
28399
28400
28401 func (c *CreativesListCall) RenderingIds(renderingIds ...int64) *CreativesListCall {
28402 var renderingIds_ []string
28403 for _, v := range renderingIds {
28404 renderingIds_ = append(renderingIds_, fmt.Sprint(v))
28405 }
28406 c.urlParams_.SetMulti("renderingIds", renderingIds_)
28407 return c
28408 }
28409
28410
28411
28412
28413
28414
28415
28416
28417
28418 func (c *CreativesListCall) SearchString(searchString string) *CreativesListCall {
28419 c.urlParams_.Set("searchString", searchString)
28420 return c
28421 }
28422
28423
28424
28425 func (c *CreativesListCall) SizeIds(sizeIds ...int64) *CreativesListCall {
28426 var sizeIds_ []string
28427 for _, v := range sizeIds {
28428 sizeIds_ = append(sizeIds_, fmt.Sprint(v))
28429 }
28430 c.urlParams_.SetMulti("sizeIds", sizeIds_)
28431 return c
28432 }
28433
28434
28435
28436
28437
28438
28439
28440
28441 func (c *CreativesListCall) SortField(sortField string) *CreativesListCall {
28442 c.urlParams_.Set("sortField", sortField)
28443 return c
28444 }
28445
28446
28447
28448
28449
28450
28451
28452
28453 func (c *CreativesListCall) SortOrder(sortOrder string) *CreativesListCall {
28454 c.urlParams_.Set("sortOrder", sortOrder)
28455 return c
28456 }
28457
28458
28459
28460 func (c *CreativesListCall) StudioCreativeId(studioCreativeId int64) *CreativesListCall {
28461 c.urlParams_.Set("studioCreativeId", fmt.Sprint(studioCreativeId))
28462 return c
28463 }
28464
28465
28466
28467
28468
28469
28470
28471
28472
28473
28474
28475
28476
28477
28478
28479
28480
28481
28482
28483
28484
28485
28486
28487
28488
28489
28490
28491
28492
28493
28494
28495 func (c *CreativesListCall) Types(types ...string) *CreativesListCall {
28496 c.urlParams_.SetMulti("types", append([]string{}, types...))
28497 return c
28498 }
28499
28500
28501
28502
28503 func (c *CreativesListCall) Fields(s ...googleapi.Field) *CreativesListCall {
28504 c.urlParams_.Set("fields", googleapi.CombineFields(s))
28505 return c
28506 }
28507
28508
28509
28510
28511
28512
28513 func (c *CreativesListCall) IfNoneMatch(entityTag string) *CreativesListCall {
28514 c.ifNoneMatch_ = entityTag
28515 return c
28516 }
28517
28518
28519
28520
28521 func (c *CreativesListCall) Context(ctx context.Context) *CreativesListCall {
28522 c.ctx_ = ctx
28523 return c
28524 }
28525
28526
28527
28528 func (c *CreativesListCall) Header() http.Header {
28529 if c.header_ == nil {
28530 c.header_ = make(http.Header)
28531 }
28532 return c.header_
28533 }
28534
28535 func (c *CreativesListCall) doRequest(alt string) (*http.Response, error) {
28536 reqHeaders := make(http.Header)
28537 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
28538 for k, v := range c.header_ {
28539 reqHeaders[k] = v
28540 }
28541 reqHeaders.Set("User-Agent", c.s.userAgent())
28542 if c.ifNoneMatch_ != "" {
28543 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
28544 }
28545 var body io.Reader = nil
28546 c.urlParams_.Set("alt", alt)
28547 c.urlParams_.Set("prettyPrint", "false")
28548 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creatives")
28549 urls += "?" + c.urlParams_.Encode()
28550 req, err := http.NewRequest("GET", urls, body)
28551 if err != nil {
28552 return nil, err
28553 }
28554 req.Header = reqHeaders
28555 googleapi.Expand(req.URL, map[string]string{
28556 "profileId": strconv.FormatInt(c.profileId, 10),
28557 })
28558 return gensupport.SendRequest(c.ctx_, c.s.client, req)
28559 }
28560
28561
28562
28563
28564
28565
28566
28567
28568 func (c *CreativesListCall) Do(opts ...googleapi.CallOption) (*CreativesListResponse, error) {
28569 gensupport.SetOptions(c.urlParams_, opts...)
28570 res, err := c.doRequest("json")
28571 if res != nil && res.StatusCode == http.StatusNotModified {
28572 if res.Body != nil {
28573 res.Body.Close()
28574 }
28575 return nil, &googleapi.Error{
28576 Code: res.StatusCode,
28577 Header: res.Header,
28578 }
28579 }
28580 if err != nil {
28581 return nil, err
28582 }
28583 defer googleapi.CloseBody(res)
28584 if err := googleapi.CheckResponse(res); err != nil {
28585 return nil, err
28586 }
28587 ret := &CreativesListResponse{
28588 ServerResponse: googleapi.ServerResponse{
28589 Header: res.Header,
28590 HTTPStatusCode: res.StatusCode,
28591 },
28592 }
28593 target := &ret
28594 if err := gensupport.DecodeResponse(target, res); err != nil {
28595 return nil, err
28596 }
28597 return ret, nil
28598
28599
28600
28601
28602
28603
28604
28605
28606
28607
28608
28609
28610
28611
28612
28613
28614
28615
28616
28617
28618
28619
28620
28621
28622
28623
28624
28625
28626
28627
28628
28629
28630
28631
28632
28633
28634
28635
28636
28637
28638
28639
28640
28641
28642
28643
28644
28645
28646
28647
28648
28649
28650
28651
28652
28653
28654
28655
28656
28657
28658
28659
28660
28661
28662
28663
28664
28665
28666
28667
28668
28669
28670
28671
28672
28673
28674
28675
28676
28677
28678
28679
28680
28681
28682
28683
28684
28685
28686
28687
28688
28689
28690
28691
28692
28693
28694
28695
28696
28697
28698
28699
28700
28701
28702
28703
28704
28705
28706
28707
28708
28709
28710
28711
28712
28713
28714
28715
28716
28717
28718
28719
28720
28721
28722
28723
28724
28725
28726
28727
28728
28729
28730
28731
28732
28733
28734
28735
28736
28737
28738
28739
28740
28741
28742
28743
28744
28745
28746
28747
28748
28749
28750
28751
28752
28753
28754
28755
28756
28757
28758
28759
28760
28761
28762
28763
28764
28765
28766
28767
28768
28769
28770
28771
28772
28773
28774
28775
28776
28777
28778
28779
28780
28781
28782
28783
28784
28785
28786
28787
28788
28789
28790
28791
28792
28793 }
28794
28795
28796
28797
28798 func (c *CreativesListCall) Pages(ctx context.Context, f func(*CreativesListResponse) error) error {
28799 c.ctx_ = ctx
28800 defer c.PageToken(c.urlParams_.Get("pageToken"))
28801 for {
28802 x, err := c.Do()
28803 if err != nil {
28804 return err
28805 }
28806 if err := f(x); err != nil {
28807 return err
28808 }
28809 if x.NextPageToken == "" {
28810 return nil
28811 }
28812 c.PageToken(x.NextPageToken)
28813 }
28814 }
28815
28816
28817
28818 type CreativesPatchCall struct {
28819 s *Service
28820 profileId int64
28821 creative *Creative
28822 urlParams_ gensupport.URLParams
28823 ctx_ context.Context
28824 header_ http.Header
28825 }
28826
28827
28828
28829 func (r *CreativesService) Patch(profileId int64, id int64, creative *Creative) *CreativesPatchCall {
28830 c := &CreativesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
28831 c.profileId = profileId
28832 c.urlParams_.Set("id", fmt.Sprint(id))
28833 c.creative = creative
28834 return c
28835 }
28836
28837
28838
28839
28840 func (c *CreativesPatchCall) Fields(s ...googleapi.Field) *CreativesPatchCall {
28841 c.urlParams_.Set("fields", googleapi.CombineFields(s))
28842 return c
28843 }
28844
28845
28846
28847
28848 func (c *CreativesPatchCall) Context(ctx context.Context) *CreativesPatchCall {
28849 c.ctx_ = ctx
28850 return c
28851 }
28852
28853
28854
28855 func (c *CreativesPatchCall) Header() http.Header {
28856 if c.header_ == nil {
28857 c.header_ = make(http.Header)
28858 }
28859 return c.header_
28860 }
28861
28862 func (c *CreativesPatchCall) doRequest(alt string) (*http.Response, error) {
28863 reqHeaders := make(http.Header)
28864 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
28865 for k, v := range c.header_ {
28866 reqHeaders[k] = v
28867 }
28868 reqHeaders.Set("User-Agent", c.s.userAgent())
28869 var body io.Reader = nil
28870 body, err := googleapi.WithoutDataWrapper.JSONReader(c.creative)
28871 if err != nil {
28872 return nil, err
28873 }
28874 reqHeaders.Set("Content-Type", "application/json")
28875 c.urlParams_.Set("alt", alt)
28876 c.urlParams_.Set("prettyPrint", "false")
28877 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creatives")
28878 urls += "?" + c.urlParams_.Encode()
28879 req, err := http.NewRequest("PATCH", urls, body)
28880 if err != nil {
28881 return nil, err
28882 }
28883 req.Header = reqHeaders
28884 googleapi.Expand(req.URL, map[string]string{
28885 "profileId": strconv.FormatInt(c.profileId, 10),
28886 })
28887 return gensupport.SendRequest(c.ctx_, c.s.client, req)
28888 }
28889
28890
28891
28892
28893
28894
28895
28896
28897 func (c *CreativesPatchCall) Do(opts ...googleapi.CallOption) (*Creative, error) {
28898 gensupport.SetOptions(c.urlParams_, opts...)
28899 res, err := c.doRequest("json")
28900 if res != nil && res.StatusCode == http.StatusNotModified {
28901 if res.Body != nil {
28902 res.Body.Close()
28903 }
28904 return nil, &googleapi.Error{
28905 Code: res.StatusCode,
28906 Header: res.Header,
28907 }
28908 }
28909 if err != nil {
28910 return nil, err
28911 }
28912 defer googleapi.CloseBody(res)
28913 if err := googleapi.CheckResponse(res); err != nil {
28914 return nil, err
28915 }
28916 ret := &Creative{
28917 ServerResponse: googleapi.ServerResponse{
28918 Header: res.Header,
28919 HTTPStatusCode: res.StatusCode,
28920 },
28921 }
28922 target := &ret
28923 if err := gensupport.DecodeResponse(target, res); err != nil {
28924 return nil, err
28925 }
28926 return ret, nil
28927
28928
28929
28930
28931
28932
28933
28934
28935
28936
28937
28938
28939
28940
28941
28942
28943
28944
28945
28946
28947
28948
28949
28950
28951
28952
28953
28954
28955
28956
28957
28958
28959
28960
28961
28962
28963 }
28964
28965
28966
28967 type CreativesUpdateCall struct {
28968 s *Service
28969 profileId int64
28970 creative *Creative
28971 urlParams_ gensupport.URLParams
28972 ctx_ context.Context
28973 header_ http.Header
28974 }
28975
28976
28977 func (r *CreativesService) Update(profileId int64, creative *Creative) *CreativesUpdateCall {
28978 c := &CreativesUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
28979 c.profileId = profileId
28980 c.creative = creative
28981 return c
28982 }
28983
28984
28985
28986
28987 func (c *CreativesUpdateCall) Fields(s ...googleapi.Field) *CreativesUpdateCall {
28988 c.urlParams_.Set("fields", googleapi.CombineFields(s))
28989 return c
28990 }
28991
28992
28993
28994
28995 func (c *CreativesUpdateCall) Context(ctx context.Context) *CreativesUpdateCall {
28996 c.ctx_ = ctx
28997 return c
28998 }
28999
29000
29001
29002 func (c *CreativesUpdateCall) Header() http.Header {
29003 if c.header_ == nil {
29004 c.header_ = make(http.Header)
29005 }
29006 return c.header_
29007 }
29008
29009 func (c *CreativesUpdateCall) doRequest(alt string) (*http.Response, error) {
29010 reqHeaders := make(http.Header)
29011 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
29012 for k, v := range c.header_ {
29013 reqHeaders[k] = v
29014 }
29015 reqHeaders.Set("User-Agent", c.s.userAgent())
29016 var body io.Reader = nil
29017 body, err := googleapi.WithoutDataWrapper.JSONReader(c.creative)
29018 if err != nil {
29019 return nil, err
29020 }
29021 reqHeaders.Set("Content-Type", "application/json")
29022 c.urlParams_.Set("alt", alt)
29023 c.urlParams_.Set("prettyPrint", "false")
29024 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creatives")
29025 urls += "?" + c.urlParams_.Encode()
29026 req, err := http.NewRequest("PUT", urls, body)
29027 if err != nil {
29028 return nil, err
29029 }
29030 req.Header = reqHeaders
29031 googleapi.Expand(req.URL, map[string]string{
29032 "profileId": strconv.FormatInt(c.profileId, 10),
29033 })
29034 return gensupport.SendRequest(c.ctx_, c.s.client, req)
29035 }
29036
29037
29038
29039
29040
29041
29042
29043
29044 func (c *CreativesUpdateCall) Do(opts ...googleapi.CallOption) (*Creative, error) {
29045 gensupport.SetOptions(c.urlParams_, opts...)
29046 res, err := c.doRequest("json")
29047 if res != nil && res.StatusCode == http.StatusNotModified {
29048 if res.Body != nil {
29049 res.Body.Close()
29050 }
29051 return nil, &googleapi.Error{
29052 Code: res.StatusCode,
29053 Header: res.Header,
29054 }
29055 }
29056 if err != nil {
29057 return nil, err
29058 }
29059 defer googleapi.CloseBody(res)
29060 if err := googleapi.CheckResponse(res); err != nil {
29061 return nil, err
29062 }
29063 ret := &Creative{
29064 ServerResponse: googleapi.ServerResponse{
29065 Header: res.Header,
29066 HTTPStatusCode: res.StatusCode,
29067 },
29068 }
29069 target := &ret
29070 if err := gensupport.DecodeResponse(target, res); err != nil {
29071 return nil, err
29072 }
29073 return ret, nil
29074
29075
29076
29077
29078
29079
29080
29081
29082
29083
29084
29085
29086
29087
29088
29089
29090
29091
29092
29093
29094
29095
29096
29097
29098
29099
29100
29101
29102 }
29103
29104
29105
29106 type DimensionValuesQueryCall struct {
29107 s *Service
29108 profileId int64
29109 dimensionvaluerequest *DimensionValueRequest
29110 urlParams_ gensupport.URLParams
29111 ctx_ context.Context
29112 header_ http.Header
29113 }
29114
29115
29116
29117 func (r *DimensionValuesService) Query(profileId int64, dimensionvaluerequest *DimensionValueRequest) *DimensionValuesQueryCall {
29118 c := &DimensionValuesQueryCall{s: r.s, urlParams_: make(gensupport.URLParams)}
29119 c.profileId = profileId
29120 c.dimensionvaluerequest = dimensionvaluerequest
29121 return c
29122 }
29123
29124
29125
29126 func (c *DimensionValuesQueryCall) MaxResults(maxResults int64) *DimensionValuesQueryCall {
29127 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
29128 return c
29129 }
29130
29131
29132
29133 func (c *DimensionValuesQueryCall) PageToken(pageToken string) *DimensionValuesQueryCall {
29134 c.urlParams_.Set("pageToken", pageToken)
29135 return c
29136 }
29137
29138
29139
29140
29141 func (c *DimensionValuesQueryCall) Fields(s ...googleapi.Field) *DimensionValuesQueryCall {
29142 c.urlParams_.Set("fields", googleapi.CombineFields(s))
29143 return c
29144 }
29145
29146
29147
29148
29149 func (c *DimensionValuesQueryCall) Context(ctx context.Context) *DimensionValuesQueryCall {
29150 c.ctx_ = ctx
29151 return c
29152 }
29153
29154
29155
29156 func (c *DimensionValuesQueryCall) Header() http.Header {
29157 if c.header_ == nil {
29158 c.header_ = make(http.Header)
29159 }
29160 return c.header_
29161 }
29162
29163 func (c *DimensionValuesQueryCall) doRequest(alt string) (*http.Response, error) {
29164 reqHeaders := make(http.Header)
29165 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
29166 for k, v := range c.header_ {
29167 reqHeaders[k] = v
29168 }
29169 reqHeaders.Set("User-Agent", c.s.userAgent())
29170 var body io.Reader = nil
29171 body, err := googleapi.WithoutDataWrapper.JSONReader(c.dimensionvaluerequest)
29172 if err != nil {
29173 return nil, err
29174 }
29175 reqHeaders.Set("Content-Type", "application/json")
29176 c.urlParams_.Set("alt", alt)
29177 c.urlParams_.Set("prettyPrint", "false")
29178 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/dimensionvalues/query")
29179 urls += "?" + c.urlParams_.Encode()
29180 req, err := http.NewRequest("POST", urls, body)
29181 if err != nil {
29182 return nil, err
29183 }
29184 req.Header = reqHeaders
29185 googleapi.Expand(req.URL, map[string]string{
29186 "profileId": strconv.FormatInt(c.profileId, 10),
29187 })
29188 return gensupport.SendRequest(c.ctx_, c.s.client, req)
29189 }
29190
29191
29192
29193
29194
29195
29196
29197
29198 func (c *DimensionValuesQueryCall) Do(opts ...googleapi.CallOption) (*DimensionValueList, error) {
29199 gensupport.SetOptions(c.urlParams_, opts...)
29200 res, err := c.doRequest("json")
29201 if res != nil && res.StatusCode == http.StatusNotModified {
29202 if res.Body != nil {
29203 res.Body.Close()
29204 }
29205 return nil, &googleapi.Error{
29206 Code: res.StatusCode,
29207 Header: res.Header,
29208 }
29209 }
29210 if err != nil {
29211 return nil, err
29212 }
29213 defer googleapi.CloseBody(res)
29214 if err := googleapi.CheckResponse(res); err != nil {
29215 return nil, err
29216 }
29217 ret := &DimensionValueList{
29218 ServerResponse: googleapi.ServerResponse{
29219 Header: res.Header,
29220 HTTPStatusCode: res.StatusCode,
29221 },
29222 }
29223 target := &ret
29224 if err := gensupport.DecodeResponse(target, res); err != nil {
29225 return nil, err
29226 }
29227 return ret, nil
29228
29229
29230
29231
29232
29233
29234
29235
29236
29237
29238
29239
29240
29241
29242
29243
29244
29245
29246
29247
29248
29249
29250
29251
29252
29253
29254
29255
29256
29257
29258
29259
29260
29261
29262
29263
29264
29265
29266
29267
29268
29269
29270 }
29271
29272
29273
29274
29275 func (c *DimensionValuesQueryCall) Pages(ctx context.Context, f func(*DimensionValueList) error) error {
29276 c.ctx_ = ctx
29277 defer c.PageToken(c.urlParams_.Get("pageToken"))
29278 for {
29279 x, err := c.Do()
29280 if err != nil {
29281 return err
29282 }
29283 if err := f(x); err != nil {
29284 return err
29285 }
29286 if x.NextPageToken == "" {
29287 return nil
29288 }
29289 c.PageToken(x.NextPageToken)
29290 }
29291 }
29292
29293
29294
29295 type DirectorySiteContactsGetCall struct {
29296 s *Service
29297 profileId int64
29298 id int64
29299 urlParams_ gensupport.URLParams
29300 ifNoneMatch_ string
29301 ctx_ context.Context
29302 header_ http.Header
29303 }
29304
29305
29306 func (r *DirectorySiteContactsService) Get(profileId int64, id int64) *DirectorySiteContactsGetCall {
29307 c := &DirectorySiteContactsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
29308 c.profileId = profileId
29309 c.id = id
29310 return c
29311 }
29312
29313
29314
29315
29316 func (c *DirectorySiteContactsGetCall) Fields(s ...googleapi.Field) *DirectorySiteContactsGetCall {
29317 c.urlParams_.Set("fields", googleapi.CombineFields(s))
29318 return c
29319 }
29320
29321
29322
29323
29324
29325
29326 func (c *DirectorySiteContactsGetCall) IfNoneMatch(entityTag string) *DirectorySiteContactsGetCall {
29327 c.ifNoneMatch_ = entityTag
29328 return c
29329 }
29330
29331
29332
29333
29334 func (c *DirectorySiteContactsGetCall) Context(ctx context.Context) *DirectorySiteContactsGetCall {
29335 c.ctx_ = ctx
29336 return c
29337 }
29338
29339
29340
29341 func (c *DirectorySiteContactsGetCall) Header() http.Header {
29342 if c.header_ == nil {
29343 c.header_ = make(http.Header)
29344 }
29345 return c.header_
29346 }
29347
29348 func (c *DirectorySiteContactsGetCall) doRequest(alt string) (*http.Response, error) {
29349 reqHeaders := make(http.Header)
29350 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
29351 for k, v := range c.header_ {
29352 reqHeaders[k] = v
29353 }
29354 reqHeaders.Set("User-Agent", c.s.userAgent())
29355 if c.ifNoneMatch_ != "" {
29356 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
29357 }
29358 var body io.Reader = nil
29359 c.urlParams_.Set("alt", alt)
29360 c.urlParams_.Set("prettyPrint", "false")
29361 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/directorySiteContacts/{id}")
29362 urls += "?" + c.urlParams_.Encode()
29363 req, err := http.NewRequest("GET", urls, body)
29364 if err != nil {
29365 return nil, err
29366 }
29367 req.Header = reqHeaders
29368 googleapi.Expand(req.URL, map[string]string{
29369 "profileId": strconv.FormatInt(c.profileId, 10),
29370 "id": strconv.FormatInt(c.id, 10),
29371 })
29372 return gensupport.SendRequest(c.ctx_, c.s.client, req)
29373 }
29374
29375
29376
29377
29378
29379
29380
29381
29382 func (c *DirectorySiteContactsGetCall) Do(opts ...googleapi.CallOption) (*DirectorySiteContact, error) {
29383 gensupport.SetOptions(c.urlParams_, opts...)
29384 res, err := c.doRequest("json")
29385 if res != nil && res.StatusCode == http.StatusNotModified {
29386 if res.Body != nil {
29387 res.Body.Close()
29388 }
29389 return nil, &googleapi.Error{
29390 Code: res.StatusCode,
29391 Header: res.Header,
29392 }
29393 }
29394 if err != nil {
29395 return nil, err
29396 }
29397 defer googleapi.CloseBody(res)
29398 if err := googleapi.CheckResponse(res); err != nil {
29399 return nil, err
29400 }
29401 ret := &DirectorySiteContact{
29402 ServerResponse: googleapi.ServerResponse{
29403 Header: res.Header,
29404 HTTPStatusCode: res.StatusCode,
29405 },
29406 }
29407 target := &ret
29408 if err := gensupport.DecodeResponse(target, res); err != nil {
29409 return nil, err
29410 }
29411 return ret, nil
29412
29413
29414
29415
29416
29417
29418
29419
29420
29421
29422
29423
29424
29425
29426
29427
29428
29429
29430
29431
29432
29433
29434
29435
29436
29437
29438
29439
29440
29441
29442
29443
29444
29445 }
29446
29447
29448
29449 type DirectorySiteContactsListCall struct {
29450 s *Service
29451 profileId int64
29452 urlParams_ gensupport.URLParams
29453 ifNoneMatch_ string
29454 ctx_ context.Context
29455 header_ http.Header
29456 }
29457
29458
29459
29460 func (r *DirectorySiteContactsService) List(profileId int64) *DirectorySiteContactsListCall {
29461 c := &DirectorySiteContactsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
29462 c.profileId = profileId
29463 return c
29464 }
29465
29466
29467
29468
29469 func (c *DirectorySiteContactsListCall) DirectorySiteIds(directorySiteIds ...int64) *DirectorySiteContactsListCall {
29470 var directorySiteIds_ []string
29471 for _, v := range directorySiteIds {
29472 directorySiteIds_ = append(directorySiteIds_, fmt.Sprint(v))
29473 }
29474 c.urlParams_.SetMulti("directorySiteIds", directorySiteIds_)
29475 return c
29476 }
29477
29478
29479
29480 func (c *DirectorySiteContactsListCall) Ids(ids ...int64) *DirectorySiteContactsListCall {
29481 var ids_ []string
29482 for _, v := range ids {
29483 ids_ = append(ids_, fmt.Sprint(v))
29484 }
29485 c.urlParams_.SetMulti("ids", ids_)
29486 return c
29487 }
29488
29489
29490
29491 func (c *DirectorySiteContactsListCall) MaxResults(maxResults int64) *DirectorySiteContactsListCall {
29492 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
29493 return c
29494 }
29495
29496
29497
29498 func (c *DirectorySiteContactsListCall) PageToken(pageToken string) *DirectorySiteContactsListCall {
29499 c.urlParams_.Set("pageToken", pageToken)
29500 return c
29501 }
29502
29503
29504
29505
29506
29507
29508
29509
29510
29511
29512
29513 func (c *DirectorySiteContactsListCall) SearchString(searchString string) *DirectorySiteContactsListCall {
29514 c.urlParams_.Set("searchString", searchString)
29515 return c
29516 }
29517
29518
29519
29520
29521
29522
29523
29524
29525 func (c *DirectorySiteContactsListCall) SortField(sortField string) *DirectorySiteContactsListCall {
29526 c.urlParams_.Set("sortField", sortField)
29527 return c
29528 }
29529
29530
29531
29532
29533
29534
29535
29536
29537 func (c *DirectorySiteContactsListCall) SortOrder(sortOrder string) *DirectorySiteContactsListCall {
29538 c.urlParams_.Set("sortOrder", sortOrder)
29539 return c
29540 }
29541
29542
29543
29544
29545 func (c *DirectorySiteContactsListCall) Fields(s ...googleapi.Field) *DirectorySiteContactsListCall {
29546 c.urlParams_.Set("fields", googleapi.CombineFields(s))
29547 return c
29548 }
29549
29550
29551
29552
29553
29554
29555 func (c *DirectorySiteContactsListCall) IfNoneMatch(entityTag string) *DirectorySiteContactsListCall {
29556 c.ifNoneMatch_ = entityTag
29557 return c
29558 }
29559
29560
29561
29562
29563 func (c *DirectorySiteContactsListCall) Context(ctx context.Context) *DirectorySiteContactsListCall {
29564 c.ctx_ = ctx
29565 return c
29566 }
29567
29568
29569
29570 func (c *DirectorySiteContactsListCall) Header() http.Header {
29571 if c.header_ == nil {
29572 c.header_ = make(http.Header)
29573 }
29574 return c.header_
29575 }
29576
29577 func (c *DirectorySiteContactsListCall) doRequest(alt string) (*http.Response, error) {
29578 reqHeaders := make(http.Header)
29579 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
29580 for k, v := range c.header_ {
29581 reqHeaders[k] = v
29582 }
29583 reqHeaders.Set("User-Agent", c.s.userAgent())
29584 if c.ifNoneMatch_ != "" {
29585 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
29586 }
29587 var body io.Reader = nil
29588 c.urlParams_.Set("alt", alt)
29589 c.urlParams_.Set("prettyPrint", "false")
29590 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/directorySiteContacts")
29591 urls += "?" + c.urlParams_.Encode()
29592 req, err := http.NewRequest("GET", urls, body)
29593 if err != nil {
29594 return nil, err
29595 }
29596 req.Header = reqHeaders
29597 googleapi.Expand(req.URL, map[string]string{
29598 "profileId": strconv.FormatInt(c.profileId, 10),
29599 })
29600 return gensupport.SendRequest(c.ctx_, c.s.client, req)
29601 }
29602
29603
29604
29605
29606
29607
29608
29609
29610
29611 func (c *DirectorySiteContactsListCall) Do(opts ...googleapi.CallOption) (*DirectorySiteContactsListResponse, error) {
29612 gensupport.SetOptions(c.urlParams_, opts...)
29613 res, err := c.doRequest("json")
29614 if res != nil && res.StatusCode == http.StatusNotModified {
29615 if res.Body != nil {
29616 res.Body.Close()
29617 }
29618 return nil, &googleapi.Error{
29619 Code: res.StatusCode,
29620 Header: res.Header,
29621 }
29622 }
29623 if err != nil {
29624 return nil, err
29625 }
29626 defer googleapi.CloseBody(res)
29627 if err := googleapi.CheckResponse(res); err != nil {
29628 return nil, err
29629 }
29630 ret := &DirectorySiteContactsListResponse{
29631 ServerResponse: googleapi.ServerResponse{
29632 Header: res.Header,
29633 HTTPStatusCode: res.StatusCode,
29634 },
29635 }
29636 target := &ret
29637 if err := gensupport.DecodeResponse(target, res); err != nil {
29638 return nil, err
29639 }
29640 return ret, nil
29641
29642
29643
29644
29645
29646
29647
29648
29649
29650
29651
29652
29653
29654
29655
29656
29657
29658
29659
29660
29661
29662
29663
29664
29665
29666
29667
29668
29669
29670
29671
29672
29673
29674
29675
29676
29677
29678
29679
29680
29681
29682
29683
29684
29685
29686
29687
29688
29689
29690
29691
29692
29693
29694
29695
29696
29697
29698
29699
29700
29701
29702
29703
29704
29705
29706
29707
29708
29709
29710
29711
29712
29713
29714
29715
29716
29717
29718
29719
29720
29721
29722
29723
29724
29725
29726
29727 }
29728
29729
29730
29731
29732 func (c *DirectorySiteContactsListCall) Pages(ctx context.Context, f func(*DirectorySiteContactsListResponse) error) error {
29733 c.ctx_ = ctx
29734 defer c.PageToken(c.urlParams_.Get("pageToken"))
29735 for {
29736 x, err := c.Do()
29737 if err != nil {
29738 return err
29739 }
29740 if err := f(x); err != nil {
29741 return err
29742 }
29743 if x.NextPageToken == "" {
29744 return nil
29745 }
29746 c.PageToken(x.NextPageToken)
29747 }
29748 }
29749
29750
29751
29752 type DirectorySitesGetCall struct {
29753 s *Service
29754 profileId int64
29755 id int64
29756 urlParams_ gensupport.URLParams
29757 ifNoneMatch_ string
29758 ctx_ context.Context
29759 header_ http.Header
29760 }
29761
29762
29763 func (r *DirectorySitesService) Get(profileId int64, id int64) *DirectorySitesGetCall {
29764 c := &DirectorySitesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
29765 c.profileId = profileId
29766 c.id = id
29767 return c
29768 }
29769
29770
29771
29772
29773 func (c *DirectorySitesGetCall) Fields(s ...googleapi.Field) *DirectorySitesGetCall {
29774 c.urlParams_.Set("fields", googleapi.CombineFields(s))
29775 return c
29776 }
29777
29778
29779
29780
29781
29782
29783 func (c *DirectorySitesGetCall) IfNoneMatch(entityTag string) *DirectorySitesGetCall {
29784 c.ifNoneMatch_ = entityTag
29785 return c
29786 }
29787
29788
29789
29790
29791 func (c *DirectorySitesGetCall) Context(ctx context.Context) *DirectorySitesGetCall {
29792 c.ctx_ = ctx
29793 return c
29794 }
29795
29796
29797
29798 func (c *DirectorySitesGetCall) Header() http.Header {
29799 if c.header_ == nil {
29800 c.header_ = make(http.Header)
29801 }
29802 return c.header_
29803 }
29804
29805 func (c *DirectorySitesGetCall) doRequest(alt string) (*http.Response, error) {
29806 reqHeaders := make(http.Header)
29807 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
29808 for k, v := range c.header_ {
29809 reqHeaders[k] = v
29810 }
29811 reqHeaders.Set("User-Agent", c.s.userAgent())
29812 if c.ifNoneMatch_ != "" {
29813 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
29814 }
29815 var body io.Reader = nil
29816 c.urlParams_.Set("alt", alt)
29817 c.urlParams_.Set("prettyPrint", "false")
29818 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/directorySites/{id}")
29819 urls += "?" + c.urlParams_.Encode()
29820 req, err := http.NewRequest("GET", urls, body)
29821 if err != nil {
29822 return nil, err
29823 }
29824 req.Header = reqHeaders
29825 googleapi.Expand(req.URL, map[string]string{
29826 "profileId": strconv.FormatInt(c.profileId, 10),
29827 "id": strconv.FormatInt(c.id, 10),
29828 })
29829 return gensupport.SendRequest(c.ctx_, c.s.client, req)
29830 }
29831
29832
29833
29834
29835
29836
29837
29838
29839 func (c *DirectorySitesGetCall) Do(opts ...googleapi.CallOption) (*DirectorySite, error) {
29840 gensupport.SetOptions(c.urlParams_, opts...)
29841 res, err := c.doRequest("json")
29842 if res != nil && res.StatusCode == http.StatusNotModified {
29843 if res.Body != nil {
29844 res.Body.Close()
29845 }
29846 return nil, &googleapi.Error{
29847 Code: res.StatusCode,
29848 Header: res.Header,
29849 }
29850 }
29851 if err != nil {
29852 return nil, err
29853 }
29854 defer googleapi.CloseBody(res)
29855 if err := googleapi.CheckResponse(res); err != nil {
29856 return nil, err
29857 }
29858 ret := &DirectorySite{
29859 ServerResponse: googleapi.ServerResponse{
29860 Header: res.Header,
29861 HTTPStatusCode: res.StatusCode,
29862 },
29863 }
29864 target := &ret
29865 if err := gensupport.DecodeResponse(target, res); err != nil {
29866 return nil, err
29867 }
29868 return ret, nil
29869
29870
29871
29872
29873
29874
29875
29876
29877
29878
29879
29880
29881
29882
29883
29884
29885
29886
29887
29888
29889
29890
29891
29892
29893
29894
29895
29896
29897
29898
29899
29900
29901
29902 }
29903
29904
29905
29906 type DirectorySitesInsertCall struct {
29907 s *Service
29908 profileId int64
29909 directorysite *DirectorySite
29910 urlParams_ gensupport.URLParams
29911 ctx_ context.Context
29912 header_ http.Header
29913 }
29914
29915
29916 func (r *DirectorySitesService) Insert(profileId int64, directorysite *DirectorySite) *DirectorySitesInsertCall {
29917 c := &DirectorySitesInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
29918 c.profileId = profileId
29919 c.directorysite = directorysite
29920 return c
29921 }
29922
29923
29924
29925
29926 func (c *DirectorySitesInsertCall) Fields(s ...googleapi.Field) *DirectorySitesInsertCall {
29927 c.urlParams_.Set("fields", googleapi.CombineFields(s))
29928 return c
29929 }
29930
29931
29932
29933
29934 func (c *DirectorySitesInsertCall) Context(ctx context.Context) *DirectorySitesInsertCall {
29935 c.ctx_ = ctx
29936 return c
29937 }
29938
29939
29940
29941 func (c *DirectorySitesInsertCall) Header() http.Header {
29942 if c.header_ == nil {
29943 c.header_ = make(http.Header)
29944 }
29945 return c.header_
29946 }
29947
29948 func (c *DirectorySitesInsertCall) doRequest(alt string) (*http.Response, error) {
29949 reqHeaders := make(http.Header)
29950 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
29951 for k, v := range c.header_ {
29952 reqHeaders[k] = v
29953 }
29954 reqHeaders.Set("User-Agent", c.s.userAgent())
29955 var body io.Reader = nil
29956 body, err := googleapi.WithoutDataWrapper.JSONReader(c.directorysite)
29957 if err != nil {
29958 return nil, err
29959 }
29960 reqHeaders.Set("Content-Type", "application/json")
29961 c.urlParams_.Set("alt", alt)
29962 c.urlParams_.Set("prettyPrint", "false")
29963 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/directorySites")
29964 urls += "?" + c.urlParams_.Encode()
29965 req, err := http.NewRequest("POST", urls, body)
29966 if err != nil {
29967 return nil, err
29968 }
29969 req.Header = reqHeaders
29970 googleapi.Expand(req.URL, map[string]string{
29971 "profileId": strconv.FormatInt(c.profileId, 10),
29972 })
29973 return gensupport.SendRequest(c.ctx_, c.s.client, req)
29974 }
29975
29976
29977
29978
29979
29980
29981
29982
29983 func (c *DirectorySitesInsertCall) Do(opts ...googleapi.CallOption) (*DirectorySite, error) {
29984 gensupport.SetOptions(c.urlParams_, opts...)
29985 res, err := c.doRequest("json")
29986 if res != nil && res.StatusCode == http.StatusNotModified {
29987 if res.Body != nil {
29988 res.Body.Close()
29989 }
29990 return nil, &googleapi.Error{
29991 Code: res.StatusCode,
29992 Header: res.Header,
29993 }
29994 }
29995 if err != nil {
29996 return nil, err
29997 }
29998 defer googleapi.CloseBody(res)
29999 if err := googleapi.CheckResponse(res); err != nil {
30000 return nil, err
30001 }
30002 ret := &DirectorySite{
30003 ServerResponse: googleapi.ServerResponse{
30004 Header: res.Header,
30005 HTTPStatusCode: res.StatusCode,
30006 },
30007 }
30008 target := &ret
30009 if err := gensupport.DecodeResponse(target, res); err != nil {
30010 return nil, err
30011 }
30012 return ret, nil
30013
30014
30015
30016
30017
30018
30019
30020
30021
30022
30023
30024
30025
30026
30027
30028
30029
30030
30031
30032
30033
30034
30035
30036
30037
30038
30039
30040
30041 }
30042
30043
30044
30045 type DirectorySitesListCall struct {
30046 s *Service
30047 profileId int64
30048 urlParams_ gensupport.URLParams
30049 ifNoneMatch_ string
30050 ctx_ context.Context
30051 header_ http.Header
30052 }
30053
30054
30055
30056 func (r *DirectorySitesService) List(profileId int64) *DirectorySitesListCall {
30057 c := &DirectorySitesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
30058 c.profileId = profileId
30059 return c
30060 }
30061
30062
30063
30064
30065 func (c *DirectorySitesListCall) AcceptsInStreamVideoPlacements(acceptsInStreamVideoPlacements bool) *DirectorySitesListCall {
30066 c.urlParams_.Set("acceptsInStreamVideoPlacements", fmt.Sprint(acceptsInStreamVideoPlacements))
30067 return c
30068 }
30069
30070
30071
30072
30073 func (c *DirectorySitesListCall) AcceptsInterstitialPlacements(acceptsInterstitialPlacements bool) *DirectorySitesListCall {
30074 c.urlParams_.Set("acceptsInterstitialPlacements", fmt.Sprint(acceptsInterstitialPlacements))
30075 return c
30076 }
30077
30078
30079
30080
30081 func (c *DirectorySitesListCall) AcceptsPublisherPaidPlacements(acceptsPublisherPaidPlacements bool) *DirectorySitesListCall {
30082 c.urlParams_.Set("acceptsPublisherPaidPlacements", fmt.Sprint(acceptsPublisherPaidPlacements))
30083 return c
30084 }
30085
30086
30087
30088
30089 func (c *DirectorySitesListCall) Active(active bool) *DirectorySitesListCall {
30090 c.urlParams_.Set("active", fmt.Sprint(active))
30091 return c
30092 }
30093
30094
30095
30096 func (c *DirectorySitesListCall) CountryId(countryId int64) *DirectorySitesListCall {
30097 c.urlParams_.Set("countryId", fmt.Sprint(countryId))
30098 return c
30099 }
30100
30101
30102
30103 func (c *DirectorySitesListCall) DfpNetworkCode(dfpNetworkCode string) *DirectorySitesListCall {
30104 c.urlParams_.Set("dfpNetworkCode", dfpNetworkCode)
30105 return c
30106 }
30107
30108
30109
30110 func (c *DirectorySitesListCall) Ids(ids ...int64) *DirectorySitesListCall {
30111 var ids_ []string
30112 for _, v := range ids {
30113 ids_ = append(ids_, fmt.Sprint(v))
30114 }
30115 c.urlParams_.SetMulti("ids", ids_)
30116 return c
30117 }
30118
30119
30120
30121 func (c *DirectorySitesListCall) MaxResults(maxResults int64) *DirectorySitesListCall {
30122 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
30123 return c
30124 }
30125
30126
30127
30128 func (c *DirectorySitesListCall) PageToken(pageToken string) *DirectorySitesListCall {
30129 c.urlParams_.Set("pageToken", pageToken)
30130 return c
30131 }
30132
30133
30134
30135 func (c *DirectorySitesListCall) ParentId(parentId int64) *DirectorySitesListCall {
30136 c.urlParams_.Set("parentId", fmt.Sprint(parentId))
30137 return c
30138 }
30139
30140
30141
30142
30143
30144
30145
30146
30147
30148
30149 func (c *DirectorySitesListCall) SearchString(searchString string) *DirectorySitesListCall {
30150 c.urlParams_.Set("searchString", searchString)
30151 return c
30152 }
30153
30154
30155
30156
30157
30158
30159
30160
30161 func (c *DirectorySitesListCall) SortField(sortField string) *DirectorySitesListCall {
30162 c.urlParams_.Set("sortField", sortField)
30163 return c
30164 }
30165
30166
30167
30168
30169
30170
30171
30172
30173 func (c *DirectorySitesListCall) SortOrder(sortOrder string) *DirectorySitesListCall {
30174 c.urlParams_.Set("sortOrder", sortOrder)
30175 return c
30176 }
30177
30178
30179
30180
30181 func (c *DirectorySitesListCall) Fields(s ...googleapi.Field) *DirectorySitesListCall {
30182 c.urlParams_.Set("fields", googleapi.CombineFields(s))
30183 return c
30184 }
30185
30186
30187
30188
30189
30190
30191 func (c *DirectorySitesListCall) IfNoneMatch(entityTag string) *DirectorySitesListCall {
30192 c.ifNoneMatch_ = entityTag
30193 return c
30194 }
30195
30196
30197
30198
30199 func (c *DirectorySitesListCall) Context(ctx context.Context) *DirectorySitesListCall {
30200 c.ctx_ = ctx
30201 return c
30202 }
30203
30204
30205
30206 func (c *DirectorySitesListCall) Header() http.Header {
30207 if c.header_ == nil {
30208 c.header_ = make(http.Header)
30209 }
30210 return c.header_
30211 }
30212
30213 func (c *DirectorySitesListCall) doRequest(alt string) (*http.Response, error) {
30214 reqHeaders := make(http.Header)
30215 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
30216 for k, v := range c.header_ {
30217 reqHeaders[k] = v
30218 }
30219 reqHeaders.Set("User-Agent", c.s.userAgent())
30220 if c.ifNoneMatch_ != "" {
30221 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
30222 }
30223 var body io.Reader = nil
30224 c.urlParams_.Set("alt", alt)
30225 c.urlParams_.Set("prettyPrint", "false")
30226 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/directorySites")
30227 urls += "?" + c.urlParams_.Encode()
30228 req, err := http.NewRequest("GET", urls, body)
30229 if err != nil {
30230 return nil, err
30231 }
30232 req.Header = reqHeaders
30233 googleapi.Expand(req.URL, map[string]string{
30234 "profileId": strconv.FormatInt(c.profileId, 10),
30235 })
30236 return gensupport.SendRequest(c.ctx_, c.s.client, req)
30237 }
30238
30239
30240
30241
30242
30243
30244
30245
30246 func (c *DirectorySitesListCall) Do(opts ...googleapi.CallOption) (*DirectorySitesListResponse, error) {
30247 gensupport.SetOptions(c.urlParams_, opts...)
30248 res, err := c.doRequest("json")
30249 if res != nil && res.StatusCode == http.StatusNotModified {
30250 if res.Body != nil {
30251 res.Body.Close()
30252 }
30253 return nil, &googleapi.Error{
30254 Code: res.StatusCode,
30255 Header: res.Header,
30256 }
30257 }
30258 if err != nil {
30259 return nil, err
30260 }
30261 defer googleapi.CloseBody(res)
30262 if err := googleapi.CheckResponse(res); err != nil {
30263 return nil, err
30264 }
30265 ret := &DirectorySitesListResponse{
30266 ServerResponse: googleapi.ServerResponse{
30267 Header: res.Header,
30268 HTTPStatusCode: res.StatusCode,
30269 },
30270 }
30271 target := &ret
30272 if err := gensupport.DecodeResponse(target, res); err != nil {
30273 return nil, err
30274 }
30275 return ret, nil
30276
30277
30278
30279
30280
30281
30282
30283
30284
30285
30286
30287
30288
30289
30290
30291
30292
30293
30294
30295
30296
30297
30298
30299
30300
30301
30302
30303
30304
30305
30306
30307
30308
30309
30310
30311
30312
30313
30314
30315
30316
30317
30318
30319
30320
30321
30322
30323
30324
30325
30326
30327
30328
30329
30330
30331
30332
30333
30334
30335
30336
30337
30338
30339
30340
30341
30342
30343
30344
30345
30346
30347
30348
30349
30350
30351
30352
30353
30354
30355
30356
30357
30358
30359
30360
30361
30362
30363
30364
30365
30366
30367
30368
30369
30370
30371
30372
30373
30374
30375
30376
30377
30378
30379
30380
30381
30382
30383
30384
30385
30386
30387
30388
30389
30390
30391
30392 }
30393
30394
30395
30396
30397 func (c *DirectorySitesListCall) Pages(ctx context.Context, f func(*DirectorySitesListResponse) error) error {
30398 c.ctx_ = ctx
30399 defer c.PageToken(c.urlParams_.Get("pageToken"))
30400 for {
30401 x, err := c.Do()
30402 if err != nil {
30403 return err
30404 }
30405 if err := f(x); err != nil {
30406 return err
30407 }
30408 if x.NextPageToken == "" {
30409 return nil
30410 }
30411 c.PageToken(x.NextPageToken)
30412 }
30413 }
30414
30415
30416
30417 type DynamicTargetingKeysDeleteCall struct {
30418 s *Service
30419 profileId int64
30420 objectId int64
30421 urlParams_ gensupport.URLParams
30422 ctx_ context.Context
30423 header_ http.Header
30424 }
30425
30426
30427 func (r *DynamicTargetingKeysService) Delete(profileId int64, objectId int64, name string, objectType string) *DynamicTargetingKeysDeleteCall {
30428 c := &DynamicTargetingKeysDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
30429 c.profileId = profileId
30430 c.objectId = objectId
30431 c.urlParams_.Set("name", name)
30432 c.urlParams_.Set("objectType", objectType)
30433 return c
30434 }
30435
30436
30437
30438
30439 func (c *DynamicTargetingKeysDeleteCall) Fields(s ...googleapi.Field) *DynamicTargetingKeysDeleteCall {
30440 c.urlParams_.Set("fields", googleapi.CombineFields(s))
30441 return c
30442 }
30443
30444
30445
30446
30447 func (c *DynamicTargetingKeysDeleteCall) Context(ctx context.Context) *DynamicTargetingKeysDeleteCall {
30448 c.ctx_ = ctx
30449 return c
30450 }
30451
30452
30453
30454 func (c *DynamicTargetingKeysDeleteCall) Header() http.Header {
30455 if c.header_ == nil {
30456 c.header_ = make(http.Header)
30457 }
30458 return c.header_
30459 }
30460
30461 func (c *DynamicTargetingKeysDeleteCall) doRequest(alt string) (*http.Response, error) {
30462 reqHeaders := make(http.Header)
30463 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
30464 for k, v := range c.header_ {
30465 reqHeaders[k] = v
30466 }
30467 reqHeaders.Set("User-Agent", c.s.userAgent())
30468 var body io.Reader = nil
30469 c.urlParams_.Set("alt", alt)
30470 c.urlParams_.Set("prettyPrint", "false")
30471 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/dynamicTargetingKeys/{objectId}")
30472 urls += "?" + c.urlParams_.Encode()
30473 req, err := http.NewRequest("DELETE", urls, body)
30474 if err != nil {
30475 return nil, err
30476 }
30477 req.Header = reqHeaders
30478 googleapi.Expand(req.URL, map[string]string{
30479 "profileId": strconv.FormatInt(c.profileId, 10),
30480 "objectId": strconv.FormatInt(c.objectId, 10),
30481 })
30482 return gensupport.SendRequest(c.ctx_, c.s.client, req)
30483 }
30484
30485
30486 func (c *DynamicTargetingKeysDeleteCall) Do(opts ...googleapi.CallOption) error {
30487 gensupport.SetOptions(c.urlParams_, opts...)
30488 res, err := c.doRequest("json")
30489 if err != nil {
30490 return err
30491 }
30492 defer googleapi.CloseBody(res)
30493 if err := googleapi.CheckResponse(res); err != nil {
30494 return err
30495 }
30496 return nil
30497
30498
30499
30500
30501
30502
30503
30504
30505
30506
30507
30508
30509
30510
30511
30512
30513
30514
30515
30516
30517
30518
30519
30520
30521
30522
30523
30524
30525
30526
30527
30528
30529
30530
30531
30532
30533
30534
30535
30536
30537
30538
30539
30540
30541
30542
30543
30544
30545
30546
30547
30548
30549
30550
30551
30552
30553 }
30554
30555
30556
30557 type DynamicTargetingKeysInsertCall struct {
30558 s *Service
30559 profileId int64
30560 dynamictargetingkey *DynamicTargetingKey
30561 urlParams_ gensupport.URLParams
30562 ctx_ context.Context
30563 header_ http.Header
30564 }
30565
30566
30567
30568
30569
30570
30571 func (r *DynamicTargetingKeysService) Insert(profileId int64, dynamictargetingkey *DynamicTargetingKey) *DynamicTargetingKeysInsertCall {
30572 c := &DynamicTargetingKeysInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
30573 c.profileId = profileId
30574 c.dynamictargetingkey = dynamictargetingkey
30575 return c
30576 }
30577
30578
30579
30580
30581 func (c *DynamicTargetingKeysInsertCall) Fields(s ...googleapi.Field) *DynamicTargetingKeysInsertCall {
30582 c.urlParams_.Set("fields", googleapi.CombineFields(s))
30583 return c
30584 }
30585
30586
30587
30588
30589 func (c *DynamicTargetingKeysInsertCall) Context(ctx context.Context) *DynamicTargetingKeysInsertCall {
30590 c.ctx_ = ctx
30591 return c
30592 }
30593
30594
30595
30596 func (c *DynamicTargetingKeysInsertCall) Header() http.Header {
30597 if c.header_ == nil {
30598 c.header_ = make(http.Header)
30599 }
30600 return c.header_
30601 }
30602
30603 func (c *DynamicTargetingKeysInsertCall) doRequest(alt string) (*http.Response, error) {
30604 reqHeaders := make(http.Header)
30605 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
30606 for k, v := range c.header_ {
30607 reqHeaders[k] = v
30608 }
30609 reqHeaders.Set("User-Agent", c.s.userAgent())
30610 var body io.Reader = nil
30611 body, err := googleapi.WithoutDataWrapper.JSONReader(c.dynamictargetingkey)
30612 if err != nil {
30613 return nil, err
30614 }
30615 reqHeaders.Set("Content-Type", "application/json")
30616 c.urlParams_.Set("alt", alt)
30617 c.urlParams_.Set("prettyPrint", "false")
30618 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/dynamicTargetingKeys")
30619 urls += "?" + c.urlParams_.Encode()
30620 req, err := http.NewRequest("POST", urls, body)
30621 if err != nil {
30622 return nil, err
30623 }
30624 req.Header = reqHeaders
30625 googleapi.Expand(req.URL, map[string]string{
30626 "profileId": strconv.FormatInt(c.profileId, 10),
30627 })
30628 return gensupport.SendRequest(c.ctx_, c.s.client, req)
30629 }
30630
30631
30632
30633
30634
30635
30636
30637
30638 func (c *DynamicTargetingKeysInsertCall) Do(opts ...googleapi.CallOption) (*DynamicTargetingKey, error) {
30639 gensupport.SetOptions(c.urlParams_, opts...)
30640 res, err := c.doRequest("json")
30641 if res != nil && res.StatusCode == http.StatusNotModified {
30642 if res.Body != nil {
30643 res.Body.Close()
30644 }
30645 return nil, &googleapi.Error{
30646 Code: res.StatusCode,
30647 Header: res.Header,
30648 }
30649 }
30650 if err != nil {
30651 return nil, err
30652 }
30653 defer googleapi.CloseBody(res)
30654 if err := googleapi.CheckResponse(res); err != nil {
30655 return nil, err
30656 }
30657 ret := &DynamicTargetingKey{
30658 ServerResponse: googleapi.ServerResponse{
30659 Header: res.Header,
30660 HTTPStatusCode: res.StatusCode,
30661 },
30662 }
30663 target := &ret
30664 if err := gensupport.DecodeResponse(target, res); err != nil {
30665 return nil, err
30666 }
30667 return ret, nil
30668
30669
30670
30671
30672
30673
30674
30675
30676
30677
30678
30679
30680
30681
30682
30683
30684
30685
30686
30687
30688
30689
30690
30691
30692
30693
30694
30695
30696 }
30697
30698
30699
30700 type DynamicTargetingKeysListCall struct {
30701 s *Service
30702 profileId int64
30703 urlParams_ gensupport.URLParams
30704 ifNoneMatch_ string
30705 ctx_ context.Context
30706 header_ http.Header
30707 }
30708
30709
30710 func (r *DynamicTargetingKeysService) List(profileId int64) *DynamicTargetingKeysListCall {
30711 c := &DynamicTargetingKeysListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
30712 c.profileId = profileId
30713 return c
30714 }
30715
30716
30717
30718 func (c *DynamicTargetingKeysListCall) AdvertiserId(advertiserId int64) *DynamicTargetingKeysListCall {
30719 c.urlParams_.Set("advertiserId", fmt.Sprint(advertiserId))
30720 return c
30721 }
30722
30723
30724
30725 func (c *DynamicTargetingKeysListCall) Names(names ...string) *DynamicTargetingKeysListCall {
30726 c.urlParams_.SetMulti("names", append([]string{}, names...))
30727 return c
30728 }
30729
30730
30731
30732 func (c *DynamicTargetingKeysListCall) ObjectId(objectId int64) *DynamicTargetingKeysListCall {
30733 c.urlParams_.Set("objectId", fmt.Sprint(objectId))
30734 return c
30735 }
30736
30737
30738
30739
30740
30741
30742
30743
30744
30745
30746 func (c *DynamicTargetingKeysListCall) ObjectType(objectType string) *DynamicTargetingKeysListCall {
30747 c.urlParams_.Set("objectType", objectType)
30748 return c
30749 }
30750
30751
30752
30753
30754 func (c *DynamicTargetingKeysListCall) Fields(s ...googleapi.Field) *DynamicTargetingKeysListCall {
30755 c.urlParams_.Set("fields", googleapi.CombineFields(s))
30756 return c
30757 }
30758
30759
30760
30761
30762
30763
30764 func (c *DynamicTargetingKeysListCall) IfNoneMatch(entityTag string) *DynamicTargetingKeysListCall {
30765 c.ifNoneMatch_ = entityTag
30766 return c
30767 }
30768
30769
30770
30771
30772 func (c *DynamicTargetingKeysListCall) Context(ctx context.Context) *DynamicTargetingKeysListCall {
30773 c.ctx_ = ctx
30774 return c
30775 }
30776
30777
30778
30779 func (c *DynamicTargetingKeysListCall) Header() http.Header {
30780 if c.header_ == nil {
30781 c.header_ = make(http.Header)
30782 }
30783 return c.header_
30784 }
30785
30786 func (c *DynamicTargetingKeysListCall) doRequest(alt string) (*http.Response, error) {
30787 reqHeaders := make(http.Header)
30788 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
30789 for k, v := range c.header_ {
30790 reqHeaders[k] = v
30791 }
30792 reqHeaders.Set("User-Agent", c.s.userAgent())
30793 if c.ifNoneMatch_ != "" {
30794 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
30795 }
30796 var body io.Reader = nil
30797 c.urlParams_.Set("alt", alt)
30798 c.urlParams_.Set("prettyPrint", "false")
30799 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/dynamicTargetingKeys")
30800 urls += "?" + c.urlParams_.Encode()
30801 req, err := http.NewRequest("GET", urls, body)
30802 if err != nil {
30803 return nil, err
30804 }
30805 req.Header = reqHeaders
30806 googleapi.Expand(req.URL, map[string]string{
30807 "profileId": strconv.FormatInt(c.profileId, 10),
30808 })
30809 return gensupport.SendRequest(c.ctx_, c.s.client, req)
30810 }
30811
30812
30813
30814
30815
30816
30817
30818
30819 func (c *DynamicTargetingKeysListCall) Do(opts ...googleapi.CallOption) (*DynamicTargetingKeysListResponse, error) {
30820 gensupport.SetOptions(c.urlParams_, opts...)
30821 res, err := c.doRequest("json")
30822 if res != nil && res.StatusCode == http.StatusNotModified {
30823 if res.Body != nil {
30824 res.Body.Close()
30825 }
30826 return nil, &googleapi.Error{
30827 Code: res.StatusCode,
30828 Header: res.Header,
30829 }
30830 }
30831 if err != nil {
30832 return nil, err
30833 }
30834 defer googleapi.CloseBody(res)
30835 if err := googleapi.CheckResponse(res); err != nil {
30836 return nil, err
30837 }
30838 ret := &DynamicTargetingKeysListResponse{
30839 ServerResponse: googleapi.ServerResponse{
30840 Header: res.Header,
30841 HTTPStatusCode: res.StatusCode,
30842 },
30843 }
30844 target := &ret
30845 if err := gensupport.DecodeResponse(target, res); err != nil {
30846 return nil, err
30847 }
30848 return ret, nil
30849
30850
30851
30852
30853
30854
30855
30856
30857
30858
30859
30860
30861
30862
30863
30864
30865
30866
30867
30868
30869
30870
30871
30872
30873
30874
30875
30876
30877
30878
30879
30880
30881
30882
30883
30884
30885
30886
30887
30888
30889
30890
30891
30892
30893
30894
30895
30896
30897
30898
30899
30900
30901
30902
30903
30904
30905
30906
30907
30908
30909 }
30910
30911
30912
30913 type EventTagsDeleteCall struct {
30914 s *Service
30915 profileId int64
30916 id int64
30917 urlParams_ gensupport.URLParams
30918 ctx_ context.Context
30919 header_ http.Header
30920 }
30921
30922
30923 func (r *EventTagsService) Delete(profileId int64, id int64) *EventTagsDeleteCall {
30924 c := &EventTagsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
30925 c.profileId = profileId
30926 c.id = id
30927 return c
30928 }
30929
30930
30931
30932
30933 func (c *EventTagsDeleteCall) Fields(s ...googleapi.Field) *EventTagsDeleteCall {
30934 c.urlParams_.Set("fields", googleapi.CombineFields(s))
30935 return c
30936 }
30937
30938
30939
30940
30941 func (c *EventTagsDeleteCall) Context(ctx context.Context) *EventTagsDeleteCall {
30942 c.ctx_ = ctx
30943 return c
30944 }
30945
30946
30947
30948 func (c *EventTagsDeleteCall) Header() http.Header {
30949 if c.header_ == nil {
30950 c.header_ = make(http.Header)
30951 }
30952 return c.header_
30953 }
30954
30955 func (c *EventTagsDeleteCall) doRequest(alt string) (*http.Response, error) {
30956 reqHeaders := make(http.Header)
30957 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
30958 for k, v := range c.header_ {
30959 reqHeaders[k] = v
30960 }
30961 reqHeaders.Set("User-Agent", c.s.userAgent())
30962 var body io.Reader = nil
30963 c.urlParams_.Set("alt", alt)
30964 c.urlParams_.Set("prettyPrint", "false")
30965 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/eventTags/{id}")
30966 urls += "?" + c.urlParams_.Encode()
30967 req, err := http.NewRequest("DELETE", urls, body)
30968 if err != nil {
30969 return nil, err
30970 }
30971 req.Header = reqHeaders
30972 googleapi.Expand(req.URL, map[string]string{
30973 "profileId": strconv.FormatInt(c.profileId, 10),
30974 "id": strconv.FormatInt(c.id, 10),
30975 })
30976 return gensupport.SendRequest(c.ctx_, c.s.client, req)
30977 }
30978
30979
30980 func (c *EventTagsDeleteCall) Do(opts ...googleapi.CallOption) error {
30981 gensupport.SetOptions(c.urlParams_, opts...)
30982 res, err := c.doRequest("json")
30983 if err != nil {
30984 return err
30985 }
30986 defer googleapi.CloseBody(res)
30987 if err := googleapi.CheckResponse(res); err != nil {
30988 return err
30989 }
30990 return nil
30991
30992
30993
30994
30995
30996
30997
30998
30999
31000
31001
31002
31003
31004
31005
31006
31007
31008
31009
31010
31011
31012
31013
31014
31015
31016
31017
31018
31019
31020
31021 }
31022
31023
31024
31025 type EventTagsGetCall struct {
31026 s *Service
31027 profileId int64
31028 id int64
31029 urlParams_ gensupport.URLParams
31030 ifNoneMatch_ string
31031 ctx_ context.Context
31032 header_ http.Header
31033 }
31034
31035
31036 func (r *EventTagsService) Get(profileId int64, id int64) *EventTagsGetCall {
31037 c := &EventTagsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
31038 c.profileId = profileId
31039 c.id = id
31040 return c
31041 }
31042
31043
31044
31045
31046 func (c *EventTagsGetCall) Fields(s ...googleapi.Field) *EventTagsGetCall {
31047 c.urlParams_.Set("fields", googleapi.CombineFields(s))
31048 return c
31049 }
31050
31051
31052
31053
31054
31055
31056 func (c *EventTagsGetCall) IfNoneMatch(entityTag string) *EventTagsGetCall {
31057 c.ifNoneMatch_ = entityTag
31058 return c
31059 }
31060
31061
31062
31063
31064 func (c *EventTagsGetCall) Context(ctx context.Context) *EventTagsGetCall {
31065 c.ctx_ = ctx
31066 return c
31067 }
31068
31069
31070
31071 func (c *EventTagsGetCall) Header() http.Header {
31072 if c.header_ == nil {
31073 c.header_ = make(http.Header)
31074 }
31075 return c.header_
31076 }
31077
31078 func (c *EventTagsGetCall) doRequest(alt string) (*http.Response, error) {
31079 reqHeaders := make(http.Header)
31080 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
31081 for k, v := range c.header_ {
31082 reqHeaders[k] = v
31083 }
31084 reqHeaders.Set("User-Agent", c.s.userAgent())
31085 if c.ifNoneMatch_ != "" {
31086 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
31087 }
31088 var body io.Reader = nil
31089 c.urlParams_.Set("alt", alt)
31090 c.urlParams_.Set("prettyPrint", "false")
31091 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/eventTags/{id}")
31092 urls += "?" + c.urlParams_.Encode()
31093 req, err := http.NewRequest("GET", urls, body)
31094 if err != nil {
31095 return nil, err
31096 }
31097 req.Header = reqHeaders
31098 googleapi.Expand(req.URL, map[string]string{
31099 "profileId": strconv.FormatInt(c.profileId, 10),
31100 "id": strconv.FormatInt(c.id, 10),
31101 })
31102 return gensupport.SendRequest(c.ctx_, c.s.client, req)
31103 }
31104
31105
31106
31107
31108
31109
31110
31111
31112 func (c *EventTagsGetCall) Do(opts ...googleapi.CallOption) (*EventTag, error) {
31113 gensupport.SetOptions(c.urlParams_, opts...)
31114 res, err := c.doRequest("json")
31115 if res != nil && res.StatusCode == http.StatusNotModified {
31116 if res.Body != nil {
31117 res.Body.Close()
31118 }
31119 return nil, &googleapi.Error{
31120 Code: res.StatusCode,
31121 Header: res.Header,
31122 }
31123 }
31124 if err != nil {
31125 return nil, err
31126 }
31127 defer googleapi.CloseBody(res)
31128 if err := googleapi.CheckResponse(res); err != nil {
31129 return nil, err
31130 }
31131 ret := &EventTag{
31132 ServerResponse: googleapi.ServerResponse{
31133 Header: res.Header,
31134 HTTPStatusCode: res.StatusCode,
31135 },
31136 }
31137 target := &ret
31138 if err := gensupport.DecodeResponse(target, res); err != nil {
31139 return nil, err
31140 }
31141 return ret, nil
31142
31143
31144
31145
31146
31147
31148
31149
31150
31151
31152
31153
31154
31155
31156
31157
31158
31159
31160
31161
31162
31163
31164
31165
31166
31167
31168
31169
31170
31171
31172
31173
31174
31175 }
31176
31177
31178
31179 type EventTagsInsertCall struct {
31180 s *Service
31181 profileId int64
31182 eventtag *EventTag
31183 urlParams_ gensupport.URLParams
31184 ctx_ context.Context
31185 header_ http.Header
31186 }
31187
31188
31189 func (r *EventTagsService) Insert(profileId int64, eventtag *EventTag) *EventTagsInsertCall {
31190 c := &EventTagsInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
31191 c.profileId = profileId
31192 c.eventtag = eventtag
31193 return c
31194 }
31195
31196
31197
31198
31199 func (c *EventTagsInsertCall) Fields(s ...googleapi.Field) *EventTagsInsertCall {
31200 c.urlParams_.Set("fields", googleapi.CombineFields(s))
31201 return c
31202 }
31203
31204
31205
31206
31207 func (c *EventTagsInsertCall) Context(ctx context.Context) *EventTagsInsertCall {
31208 c.ctx_ = ctx
31209 return c
31210 }
31211
31212
31213
31214 func (c *EventTagsInsertCall) Header() http.Header {
31215 if c.header_ == nil {
31216 c.header_ = make(http.Header)
31217 }
31218 return c.header_
31219 }
31220
31221 func (c *EventTagsInsertCall) doRequest(alt string) (*http.Response, error) {
31222 reqHeaders := make(http.Header)
31223 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
31224 for k, v := range c.header_ {
31225 reqHeaders[k] = v
31226 }
31227 reqHeaders.Set("User-Agent", c.s.userAgent())
31228 var body io.Reader = nil
31229 body, err := googleapi.WithoutDataWrapper.JSONReader(c.eventtag)
31230 if err != nil {
31231 return nil, err
31232 }
31233 reqHeaders.Set("Content-Type", "application/json")
31234 c.urlParams_.Set("alt", alt)
31235 c.urlParams_.Set("prettyPrint", "false")
31236 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/eventTags")
31237 urls += "?" + c.urlParams_.Encode()
31238 req, err := http.NewRequest("POST", urls, body)
31239 if err != nil {
31240 return nil, err
31241 }
31242 req.Header = reqHeaders
31243 googleapi.Expand(req.URL, map[string]string{
31244 "profileId": strconv.FormatInt(c.profileId, 10),
31245 })
31246 return gensupport.SendRequest(c.ctx_, c.s.client, req)
31247 }
31248
31249
31250
31251
31252
31253
31254
31255
31256 func (c *EventTagsInsertCall) Do(opts ...googleapi.CallOption) (*EventTag, error) {
31257 gensupport.SetOptions(c.urlParams_, opts...)
31258 res, err := c.doRequest("json")
31259 if res != nil && res.StatusCode == http.StatusNotModified {
31260 if res.Body != nil {
31261 res.Body.Close()
31262 }
31263 return nil, &googleapi.Error{
31264 Code: res.StatusCode,
31265 Header: res.Header,
31266 }
31267 }
31268 if err != nil {
31269 return nil, err
31270 }
31271 defer googleapi.CloseBody(res)
31272 if err := googleapi.CheckResponse(res); err != nil {
31273 return nil, err
31274 }
31275 ret := &EventTag{
31276 ServerResponse: googleapi.ServerResponse{
31277 Header: res.Header,
31278 HTTPStatusCode: res.StatusCode,
31279 },
31280 }
31281 target := &ret
31282 if err := gensupport.DecodeResponse(target, res); err != nil {
31283 return nil, err
31284 }
31285 return ret, nil
31286
31287
31288
31289
31290
31291
31292
31293
31294
31295
31296
31297
31298
31299
31300
31301
31302
31303
31304
31305
31306
31307
31308
31309
31310
31311
31312
31313
31314 }
31315
31316
31317
31318 type EventTagsListCall struct {
31319 s *Service
31320 profileId int64
31321 urlParams_ gensupport.URLParams
31322 ifNoneMatch_ string
31323 ctx_ context.Context
31324 header_ http.Header
31325 }
31326
31327
31328 func (r *EventTagsService) List(profileId int64) *EventTagsListCall {
31329 c := &EventTagsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
31330 c.profileId = profileId
31331 return c
31332 }
31333
31334
31335
31336 func (c *EventTagsListCall) AdId(adId int64) *EventTagsListCall {
31337 c.urlParams_.Set("adId", fmt.Sprint(adId))
31338 return c
31339 }
31340
31341
31342
31343 func (c *EventTagsListCall) AdvertiserId(advertiserId int64) *EventTagsListCall {
31344 c.urlParams_.Set("advertiserId", fmt.Sprint(advertiserId))
31345 return c
31346 }
31347
31348
31349
31350 func (c *EventTagsListCall) CampaignId(campaignId int64) *EventTagsListCall {
31351 c.urlParams_.Set("campaignId", fmt.Sprint(campaignId))
31352 return c
31353 }
31354
31355
31356
31357
31358
31359
31360
31361
31362
31363 func (c *EventTagsListCall) DefinitionsOnly(definitionsOnly bool) *EventTagsListCall {
31364 c.urlParams_.Set("definitionsOnly", fmt.Sprint(definitionsOnly))
31365 return c
31366 }
31367
31368
31369
31370
31371
31372
31373
31374
31375
31376 func (c *EventTagsListCall) Enabled(enabled bool) *EventTagsListCall {
31377 c.urlParams_.Set("enabled", fmt.Sprint(enabled))
31378 return c
31379 }
31380
31381
31382
31383
31384
31385
31386
31387
31388
31389
31390
31391
31392 func (c *EventTagsListCall) EventTagTypes(eventTagTypes ...string) *EventTagsListCall {
31393 c.urlParams_.SetMulti("eventTagTypes", append([]string{}, eventTagTypes...))
31394 return c
31395 }
31396
31397
31398
31399 func (c *EventTagsListCall) Ids(ids ...int64) *EventTagsListCall {
31400 var ids_ []string
31401 for _, v := range ids {
31402 ids_ = append(ids_, fmt.Sprint(v))
31403 }
31404 c.urlParams_.SetMulti("ids", ids_)
31405 return c
31406 }
31407
31408
31409
31410
31411
31412
31413
31414
31415
31416 func (c *EventTagsListCall) SearchString(searchString string) *EventTagsListCall {
31417 c.urlParams_.Set("searchString", searchString)
31418 return c
31419 }
31420
31421
31422
31423
31424
31425
31426
31427
31428 func (c *EventTagsListCall) SortField(sortField string) *EventTagsListCall {
31429 c.urlParams_.Set("sortField", sortField)
31430 return c
31431 }
31432
31433
31434
31435
31436
31437
31438
31439
31440 func (c *EventTagsListCall) SortOrder(sortOrder string) *EventTagsListCall {
31441 c.urlParams_.Set("sortOrder", sortOrder)
31442 return c
31443 }
31444
31445
31446
31447
31448 func (c *EventTagsListCall) Fields(s ...googleapi.Field) *EventTagsListCall {
31449 c.urlParams_.Set("fields", googleapi.CombineFields(s))
31450 return c
31451 }
31452
31453
31454
31455
31456
31457
31458 func (c *EventTagsListCall) IfNoneMatch(entityTag string) *EventTagsListCall {
31459 c.ifNoneMatch_ = entityTag
31460 return c
31461 }
31462
31463
31464
31465
31466 func (c *EventTagsListCall) Context(ctx context.Context) *EventTagsListCall {
31467 c.ctx_ = ctx
31468 return c
31469 }
31470
31471
31472
31473 func (c *EventTagsListCall) Header() http.Header {
31474 if c.header_ == nil {
31475 c.header_ = make(http.Header)
31476 }
31477 return c.header_
31478 }
31479
31480 func (c *EventTagsListCall) doRequest(alt string) (*http.Response, error) {
31481 reqHeaders := make(http.Header)
31482 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
31483 for k, v := range c.header_ {
31484 reqHeaders[k] = v
31485 }
31486 reqHeaders.Set("User-Agent", c.s.userAgent())
31487 if c.ifNoneMatch_ != "" {
31488 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
31489 }
31490 var body io.Reader = nil
31491 c.urlParams_.Set("alt", alt)
31492 c.urlParams_.Set("prettyPrint", "false")
31493 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/eventTags")
31494 urls += "?" + c.urlParams_.Encode()
31495 req, err := http.NewRequest("GET", urls, body)
31496 if err != nil {
31497 return nil, err
31498 }
31499 req.Header = reqHeaders
31500 googleapi.Expand(req.URL, map[string]string{
31501 "profileId": strconv.FormatInt(c.profileId, 10),
31502 })
31503 return gensupport.SendRequest(c.ctx_, c.s.client, req)
31504 }
31505
31506
31507
31508
31509
31510
31511
31512
31513 func (c *EventTagsListCall) Do(opts ...googleapi.CallOption) (*EventTagsListResponse, error) {
31514 gensupport.SetOptions(c.urlParams_, opts...)
31515 res, err := c.doRequest("json")
31516 if res != nil && res.StatusCode == http.StatusNotModified {
31517 if res.Body != nil {
31518 res.Body.Close()
31519 }
31520 return nil, &googleapi.Error{
31521 Code: res.StatusCode,
31522 Header: res.Header,
31523 }
31524 }
31525 if err != nil {
31526 return nil, err
31527 }
31528 defer googleapi.CloseBody(res)
31529 if err := googleapi.CheckResponse(res); err != nil {
31530 return nil, err
31531 }
31532 ret := &EventTagsListResponse{
31533 ServerResponse: googleapi.ServerResponse{
31534 Header: res.Header,
31535 HTTPStatusCode: res.StatusCode,
31536 },
31537 }
31538 target := &ret
31539 if err := gensupport.DecodeResponse(target, res); err != nil {
31540 return nil, err
31541 }
31542 return ret, nil
31543
31544
31545
31546
31547
31548
31549
31550
31551
31552
31553
31554
31555
31556
31557
31558
31559
31560
31561
31562
31563
31564
31565
31566
31567
31568
31569
31570
31571
31572
31573
31574
31575
31576
31577
31578
31579
31580
31581
31582
31583
31584
31585
31586
31587
31588
31589
31590
31591
31592
31593
31594
31595
31596
31597
31598
31599
31600
31601
31602
31603
31604
31605
31606
31607
31608
31609
31610
31611
31612
31613
31614
31615
31616
31617
31618
31619
31620
31621
31622
31623
31624
31625
31626
31627
31628
31629
31630
31631
31632
31633
31634
31635
31636
31637
31638
31639
31640
31641
31642
31643
31644
31645
31646
31647
31648
31649
31650
31651
31652 }
31653
31654
31655
31656 type EventTagsPatchCall struct {
31657 s *Service
31658 profileId int64
31659 eventtag *EventTag
31660 urlParams_ gensupport.URLParams
31661 ctx_ context.Context
31662 header_ http.Header
31663 }
31664
31665
31666
31667 func (r *EventTagsService) Patch(profileId int64, id int64, eventtag *EventTag) *EventTagsPatchCall {
31668 c := &EventTagsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
31669 c.profileId = profileId
31670 c.urlParams_.Set("id", fmt.Sprint(id))
31671 c.eventtag = eventtag
31672 return c
31673 }
31674
31675
31676
31677
31678 func (c *EventTagsPatchCall) Fields(s ...googleapi.Field) *EventTagsPatchCall {
31679 c.urlParams_.Set("fields", googleapi.CombineFields(s))
31680 return c
31681 }
31682
31683
31684
31685
31686 func (c *EventTagsPatchCall) Context(ctx context.Context) *EventTagsPatchCall {
31687 c.ctx_ = ctx
31688 return c
31689 }
31690
31691
31692
31693 func (c *EventTagsPatchCall) Header() http.Header {
31694 if c.header_ == nil {
31695 c.header_ = make(http.Header)
31696 }
31697 return c.header_
31698 }
31699
31700 func (c *EventTagsPatchCall) doRequest(alt string) (*http.Response, error) {
31701 reqHeaders := make(http.Header)
31702 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
31703 for k, v := range c.header_ {
31704 reqHeaders[k] = v
31705 }
31706 reqHeaders.Set("User-Agent", c.s.userAgent())
31707 var body io.Reader = nil
31708 body, err := googleapi.WithoutDataWrapper.JSONReader(c.eventtag)
31709 if err != nil {
31710 return nil, err
31711 }
31712 reqHeaders.Set("Content-Type", "application/json")
31713 c.urlParams_.Set("alt", alt)
31714 c.urlParams_.Set("prettyPrint", "false")
31715 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/eventTags")
31716 urls += "?" + c.urlParams_.Encode()
31717 req, err := http.NewRequest("PATCH", urls, body)
31718 if err != nil {
31719 return nil, err
31720 }
31721 req.Header = reqHeaders
31722 googleapi.Expand(req.URL, map[string]string{
31723 "profileId": strconv.FormatInt(c.profileId, 10),
31724 })
31725 return gensupport.SendRequest(c.ctx_, c.s.client, req)
31726 }
31727
31728
31729
31730
31731
31732
31733
31734
31735 func (c *EventTagsPatchCall) Do(opts ...googleapi.CallOption) (*EventTag, error) {
31736 gensupport.SetOptions(c.urlParams_, opts...)
31737 res, err := c.doRequest("json")
31738 if res != nil && res.StatusCode == http.StatusNotModified {
31739 if res.Body != nil {
31740 res.Body.Close()
31741 }
31742 return nil, &googleapi.Error{
31743 Code: res.StatusCode,
31744 Header: res.Header,
31745 }
31746 }
31747 if err != nil {
31748 return nil, err
31749 }
31750 defer googleapi.CloseBody(res)
31751 if err := googleapi.CheckResponse(res); err != nil {
31752 return nil, err
31753 }
31754 ret := &EventTag{
31755 ServerResponse: googleapi.ServerResponse{
31756 Header: res.Header,
31757 HTTPStatusCode: res.StatusCode,
31758 },
31759 }
31760 target := &ret
31761 if err := gensupport.DecodeResponse(target, res); err != nil {
31762 return nil, err
31763 }
31764 return ret, nil
31765
31766
31767
31768
31769
31770
31771
31772
31773
31774
31775
31776
31777
31778
31779
31780
31781
31782
31783
31784
31785
31786
31787
31788
31789
31790
31791
31792
31793
31794
31795
31796
31797
31798
31799
31800
31801 }
31802
31803
31804
31805 type EventTagsUpdateCall struct {
31806 s *Service
31807 profileId int64
31808 eventtag *EventTag
31809 urlParams_ gensupport.URLParams
31810 ctx_ context.Context
31811 header_ http.Header
31812 }
31813
31814
31815 func (r *EventTagsService) Update(profileId int64, eventtag *EventTag) *EventTagsUpdateCall {
31816 c := &EventTagsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
31817 c.profileId = profileId
31818 c.eventtag = eventtag
31819 return c
31820 }
31821
31822
31823
31824
31825 func (c *EventTagsUpdateCall) Fields(s ...googleapi.Field) *EventTagsUpdateCall {
31826 c.urlParams_.Set("fields", googleapi.CombineFields(s))
31827 return c
31828 }
31829
31830
31831
31832
31833 func (c *EventTagsUpdateCall) Context(ctx context.Context) *EventTagsUpdateCall {
31834 c.ctx_ = ctx
31835 return c
31836 }
31837
31838
31839
31840 func (c *EventTagsUpdateCall) Header() http.Header {
31841 if c.header_ == nil {
31842 c.header_ = make(http.Header)
31843 }
31844 return c.header_
31845 }
31846
31847 func (c *EventTagsUpdateCall) doRequest(alt string) (*http.Response, error) {
31848 reqHeaders := make(http.Header)
31849 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
31850 for k, v := range c.header_ {
31851 reqHeaders[k] = v
31852 }
31853 reqHeaders.Set("User-Agent", c.s.userAgent())
31854 var body io.Reader = nil
31855 body, err := googleapi.WithoutDataWrapper.JSONReader(c.eventtag)
31856 if err != nil {
31857 return nil, err
31858 }
31859 reqHeaders.Set("Content-Type", "application/json")
31860 c.urlParams_.Set("alt", alt)
31861 c.urlParams_.Set("prettyPrint", "false")
31862 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/eventTags")
31863 urls += "?" + c.urlParams_.Encode()
31864 req, err := http.NewRequest("PUT", urls, body)
31865 if err != nil {
31866 return nil, err
31867 }
31868 req.Header = reqHeaders
31869 googleapi.Expand(req.URL, map[string]string{
31870 "profileId": strconv.FormatInt(c.profileId, 10),
31871 })
31872 return gensupport.SendRequest(c.ctx_, c.s.client, req)
31873 }
31874
31875
31876
31877
31878
31879
31880
31881
31882 func (c *EventTagsUpdateCall) Do(opts ...googleapi.CallOption) (*EventTag, error) {
31883 gensupport.SetOptions(c.urlParams_, opts...)
31884 res, err := c.doRequest("json")
31885 if res != nil && res.StatusCode == http.StatusNotModified {
31886 if res.Body != nil {
31887 res.Body.Close()
31888 }
31889 return nil, &googleapi.Error{
31890 Code: res.StatusCode,
31891 Header: res.Header,
31892 }
31893 }
31894 if err != nil {
31895 return nil, err
31896 }
31897 defer googleapi.CloseBody(res)
31898 if err := googleapi.CheckResponse(res); err != nil {
31899 return nil, err
31900 }
31901 ret := &EventTag{
31902 ServerResponse: googleapi.ServerResponse{
31903 Header: res.Header,
31904 HTTPStatusCode: res.StatusCode,
31905 },
31906 }
31907 target := &ret
31908 if err := gensupport.DecodeResponse(target, res); err != nil {
31909 return nil, err
31910 }
31911 return ret, nil
31912
31913
31914
31915
31916
31917
31918
31919
31920
31921
31922
31923
31924
31925
31926
31927
31928
31929
31930
31931
31932
31933
31934
31935
31936
31937
31938
31939
31940 }
31941
31942
31943
31944 type FilesGetCall struct {
31945 s *Service
31946 reportId int64
31947 fileId int64
31948 urlParams_ gensupport.URLParams
31949 ifNoneMatch_ string
31950 ctx_ context.Context
31951 header_ http.Header
31952 }
31953
31954
31955
31956 func (r *FilesService) Get(reportId int64, fileId int64) *FilesGetCall {
31957 c := &FilesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
31958 c.reportId = reportId
31959 c.fileId = fileId
31960 return c
31961 }
31962
31963
31964
31965
31966 func (c *FilesGetCall) Fields(s ...googleapi.Field) *FilesGetCall {
31967 c.urlParams_.Set("fields", googleapi.CombineFields(s))
31968 return c
31969 }
31970
31971
31972
31973
31974
31975
31976 func (c *FilesGetCall) IfNoneMatch(entityTag string) *FilesGetCall {
31977 c.ifNoneMatch_ = entityTag
31978 return c
31979 }
31980
31981
31982
31983
31984 func (c *FilesGetCall) Context(ctx context.Context) *FilesGetCall {
31985 c.ctx_ = ctx
31986 return c
31987 }
31988
31989
31990
31991 func (c *FilesGetCall) Header() http.Header {
31992 if c.header_ == nil {
31993 c.header_ = make(http.Header)
31994 }
31995 return c.header_
31996 }
31997
31998 func (c *FilesGetCall) doRequest(alt string) (*http.Response, error) {
31999 reqHeaders := make(http.Header)
32000 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
32001 for k, v := range c.header_ {
32002 reqHeaders[k] = v
32003 }
32004 reqHeaders.Set("User-Agent", c.s.userAgent())
32005 if c.ifNoneMatch_ != "" {
32006 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
32007 }
32008 var body io.Reader = nil
32009 c.urlParams_.Set("alt", alt)
32010 c.urlParams_.Set("prettyPrint", "false")
32011 urls := googleapi.ResolveRelative(c.s.BasePath, "reports/{reportId}/files/{fileId}")
32012 urls += "?" + c.urlParams_.Encode()
32013 req, err := http.NewRequest("GET", urls, body)
32014 if err != nil {
32015 return nil, err
32016 }
32017 req.Header = reqHeaders
32018 googleapi.Expand(req.URL, map[string]string{
32019 "reportId": strconv.FormatInt(c.reportId, 10),
32020 "fileId": strconv.FormatInt(c.fileId, 10),
32021 })
32022 return gensupport.SendRequest(c.ctx_, c.s.client, req)
32023 }
32024
32025
32026
32027
32028 func (c *FilesGetCall) Download(opts ...googleapi.CallOption) (*http.Response, error) {
32029 gensupport.SetOptions(c.urlParams_, opts...)
32030 res, err := c.doRequest("media")
32031 if err != nil {
32032 return nil, err
32033 }
32034 if err := googleapi.CheckMediaResponse(res); err != nil {
32035 res.Body.Close()
32036 return nil, err
32037 }
32038 return res, nil
32039 }
32040
32041
32042
32043
32044
32045
32046
32047
32048 func (c *FilesGetCall) Do(opts ...googleapi.CallOption) (*File, error) {
32049 gensupport.SetOptions(c.urlParams_, opts...)
32050 res, err := c.doRequest("json")
32051 if res != nil && res.StatusCode == http.StatusNotModified {
32052 if res.Body != nil {
32053 res.Body.Close()
32054 }
32055 return nil, &googleapi.Error{
32056 Code: res.StatusCode,
32057 Header: res.Header,
32058 }
32059 }
32060 if err != nil {
32061 return nil, err
32062 }
32063 defer googleapi.CloseBody(res)
32064 if err := googleapi.CheckResponse(res); err != nil {
32065 return nil, err
32066 }
32067 ret := &File{
32068 ServerResponse: googleapi.ServerResponse{
32069 Header: res.Header,
32070 HTTPStatusCode: res.StatusCode,
32071 },
32072 }
32073 target := &ret
32074 if err := gensupport.DecodeResponse(target, res); err != nil {
32075 return nil, err
32076 }
32077 return ret, nil
32078
32079
32080
32081
32082
32083
32084
32085
32086
32087
32088
32089
32090
32091
32092
32093
32094
32095
32096
32097
32098
32099
32100
32101
32102
32103
32104
32105
32106
32107
32108
32109
32110
32111
32112 }
32113
32114
32115
32116 type FilesListCall struct {
32117 s *Service
32118 profileId int64
32119 urlParams_ gensupport.URLParams
32120 ifNoneMatch_ string
32121 ctx_ context.Context
32122 header_ http.Header
32123 }
32124
32125
32126 func (r *FilesService) List(profileId int64) *FilesListCall {
32127 c := &FilesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
32128 c.profileId = profileId
32129 return c
32130 }
32131
32132
32133
32134 func (c *FilesListCall) MaxResults(maxResults int64) *FilesListCall {
32135 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
32136 return c
32137 }
32138
32139
32140
32141 func (c *FilesListCall) PageToken(pageToken string) *FilesListCall {
32142 c.urlParams_.Set("pageToken", pageToken)
32143 return c
32144 }
32145
32146
32147
32148
32149
32150
32151
32152
32153
32154 func (c *FilesListCall) Scope(scope string) *FilesListCall {
32155 c.urlParams_.Set("scope", scope)
32156 return c
32157 }
32158
32159
32160
32161
32162
32163
32164
32165
32166 func (c *FilesListCall) SortField(sortField string) *FilesListCall {
32167 c.urlParams_.Set("sortField", sortField)
32168 return c
32169 }
32170
32171
32172
32173
32174
32175
32176
32177
32178 func (c *FilesListCall) SortOrder(sortOrder string) *FilesListCall {
32179 c.urlParams_.Set("sortOrder", sortOrder)
32180 return c
32181 }
32182
32183
32184
32185
32186 func (c *FilesListCall) Fields(s ...googleapi.Field) *FilesListCall {
32187 c.urlParams_.Set("fields", googleapi.CombineFields(s))
32188 return c
32189 }
32190
32191
32192
32193
32194
32195
32196 func (c *FilesListCall) IfNoneMatch(entityTag string) *FilesListCall {
32197 c.ifNoneMatch_ = entityTag
32198 return c
32199 }
32200
32201
32202
32203
32204 func (c *FilesListCall) Context(ctx context.Context) *FilesListCall {
32205 c.ctx_ = ctx
32206 return c
32207 }
32208
32209
32210
32211 func (c *FilesListCall) Header() http.Header {
32212 if c.header_ == nil {
32213 c.header_ = make(http.Header)
32214 }
32215 return c.header_
32216 }
32217
32218 func (c *FilesListCall) doRequest(alt string) (*http.Response, error) {
32219 reqHeaders := make(http.Header)
32220 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
32221 for k, v := range c.header_ {
32222 reqHeaders[k] = v
32223 }
32224 reqHeaders.Set("User-Agent", c.s.userAgent())
32225 if c.ifNoneMatch_ != "" {
32226 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
32227 }
32228 var body io.Reader = nil
32229 c.urlParams_.Set("alt", alt)
32230 c.urlParams_.Set("prettyPrint", "false")
32231 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/files")
32232 urls += "?" + c.urlParams_.Encode()
32233 req, err := http.NewRequest("GET", urls, body)
32234 if err != nil {
32235 return nil, err
32236 }
32237 req.Header = reqHeaders
32238 googleapi.Expand(req.URL, map[string]string{
32239 "profileId": strconv.FormatInt(c.profileId, 10),
32240 })
32241 return gensupport.SendRequest(c.ctx_, c.s.client, req)
32242 }
32243
32244
32245
32246
32247
32248
32249
32250
32251 func (c *FilesListCall) Do(opts ...googleapi.CallOption) (*FileList, error) {
32252 gensupport.SetOptions(c.urlParams_, opts...)
32253 res, err := c.doRequest("json")
32254 if res != nil && res.StatusCode == http.StatusNotModified {
32255 if res.Body != nil {
32256 res.Body.Close()
32257 }
32258 return nil, &googleapi.Error{
32259 Code: res.StatusCode,
32260 Header: res.Header,
32261 }
32262 }
32263 if err != nil {
32264 return nil, err
32265 }
32266 defer googleapi.CloseBody(res)
32267 if err := googleapi.CheckResponse(res); err != nil {
32268 return nil, err
32269 }
32270 ret := &FileList{
32271 ServerResponse: googleapi.ServerResponse{
32272 Header: res.Header,
32273 HTTPStatusCode: res.StatusCode,
32274 },
32275 }
32276 target := &ret
32277 if err := gensupport.DecodeResponse(target, res); err != nil {
32278 return nil, err
32279 }
32280 return ret, nil
32281
32282
32283
32284
32285
32286
32287
32288
32289
32290
32291
32292
32293
32294
32295
32296
32297
32298
32299
32300
32301
32302
32303
32304
32305
32306
32307
32308
32309
32310
32311
32312
32313
32314
32315
32316
32317
32318
32319
32320
32321
32322
32323
32324
32325
32326
32327
32328
32329
32330
32331
32332
32333
32334
32335
32336
32337
32338
32339
32340
32341
32342
32343
32344
32345
32346
32347
32348
32349
32350
32351
32352
32353
32354
32355
32356
32357
32358
32359
32360
32361
32362
32363
32364 }
32365
32366
32367
32368
32369 func (c *FilesListCall) Pages(ctx context.Context, f func(*FileList) error) error {
32370 c.ctx_ = ctx
32371 defer c.PageToken(c.urlParams_.Get("pageToken"))
32372 for {
32373 x, err := c.Do()
32374 if err != nil {
32375 return err
32376 }
32377 if err := f(x); err != nil {
32378 return err
32379 }
32380 if x.NextPageToken == "" {
32381 return nil
32382 }
32383 c.PageToken(x.NextPageToken)
32384 }
32385 }
32386
32387
32388
32389 type FloodlightActivitiesDeleteCall struct {
32390 s *Service
32391 profileId int64
32392 id int64
32393 urlParams_ gensupport.URLParams
32394 ctx_ context.Context
32395 header_ http.Header
32396 }
32397
32398
32399 func (r *FloodlightActivitiesService) Delete(profileId int64, id int64) *FloodlightActivitiesDeleteCall {
32400 c := &FloodlightActivitiesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
32401 c.profileId = profileId
32402 c.id = id
32403 return c
32404 }
32405
32406
32407
32408
32409 func (c *FloodlightActivitiesDeleteCall) Fields(s ...googleapi.Field) *FloodlightActivitiesDeleteCall {
32410 c.urlParams_.Set("fields", googleapi.CombineFields(s))
32411 return c
32412 }
32413
32414
32415
32416
32417 func (c *FloodlightActivitiesDeleteCall) Context(ctx context.Context) *FloodlightActivitiesDeleteCall {
32418 c.ctx_ = ctx
32419 return c
32420 }
32421
32422
32423
32424 func (c *FloodlightActivitiesDeleteCall) Header() http.Header {
32425 if c.header_ == nil {
32426 c.header_ = make(http.Header)
32427 }
32428 return c.header_
32429 }
32430
32431 func (c *FloodlightActivitiesDeleteCall) doRequest(alt string) (*http.Response, error) {
32432 reqHeaders := make(http.Header)
32433 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
32434 for k, v := range c.header_ {
32435 reqHeaders[k] = v
32436 }
32437 reqHeaders.Set("User-Agent", c.s.userAgent())
32438 var body io.Reader = nil
32439 c.urlParams_.Set("alt", alt)
32440 c.urlParams_.Set("prettyPrint", "false")
32441 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/floodlightActivities/{id}")
32442 urls += "?" + c.urlParams_.Encode()
32443 req, err := http.NewRequest("DELETE", urls, body)
32444 if err != nil {
32445 return nil, err
32446 }
32447 req.Header = reqHeaders
32448 googleapi.Expand(req.URL, map[string]string{
32449 "profileId": strconv.FormatInt(c.profileId, 10),
32450 "id": strconv.FormatInt(c.id, 10),
32451 })
32452 return gensupport.SendRequest(c.ctx_, c.s.client, req)
32453 }
32454
32455
32456 func (c *FloodlightActivitiesDeleteCall) Do(opts ...googleapi.CallOption) error {
32457 gensupport.SetOptions(c.urlParams_, opts...)
32458 res, err := c.doRequest("json")
32459 if err != nil {
32460 return err
32461 }
32462 defer googleapi.CloseBody(res)
32463 if err := googleapi.CheckResponse(res); err != nil {
32464 return err
32465 }
32466 return nil
32467
32468
32469
32470
32471
32472
32473
32474
32475
32476
32477
32478
32479
32480
32481
32482
32483
32484
32485
32486
32487
32488
32489
32490
32491
32492
32493
32494
32495
32496
32497 }
32498
32499
32500
32501 type FloodlightActivitiesGeneratetagCall struct {
32502 s *Service
32503 profileId int64
32504 urlParams_ gensupport.URLParams
32505 ctx_ context.Context
32506 header_ http.Header
32507 }
32508
32509
32510 func (r *FloodlightActivitiesService) Generatetag(profileId int64) *FloodlightActivitiesGeneratetagCall {
32511 c := &FloodlightActivitiesGeneratetagCall{s: r.s, urlParams_: make(gensupport.URLParams)}
32512 c.profileId = profileId
32513 return c
32514 }
32515
32516
32517
32518
32519 func (c *FloodlightActivitiesGeneratetagCall) FloodlightActivityId(floodlightActivityId int64) *FloodlightActivitiesGeneratetagCall {
32520 c.urlParams_.Set("floodlightActivityId", fmt.Sprint(floodlightActivityId))
32521 return c
32522 }
32523
32524
32525
32526
32527 func (c *FloodlightActivitiesGeneratetagCall) Fields(s ...googleapi.Field) *FloodlightActivitiesGeneratetagCall {
32528 c.urlParams_.Set("fields", googleapi.CombineFields(s))
32529 return c
32530 }
32531
32532
32533
32534
32535 func (c *FloodlightActivitiesGeneratetagCall) Context(ctx context.Context) *FloodlightActivitiesGeneratetagCall {
32536 c.ctx_ = ctx
32537 return c
32538 }
32539
32540
32541
32542 func (c *FloodlightActivitiesGeneratetagCall) Header() http.Header {
32543 if c.header_ == nil {
32544 c.header_ = make(http.Header)
32545 }
32546 return c.header_
32547 }
32548
32549 func (c *FloodlightActivitiesGeneratetagCall) doRequest(alt string) (*http.Response, error) {
32550 reqHeaders := make(http.Header)
32551 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
32552 for k, v := range c.header_ {
32553 reqHeaders[k] = v
32554 }
32555 reqHeaders.Set("User-Agent", c.s.userAgent())
32556 var body io.Reader = nil
32557 c.urlParams_.Set("alt", alt)
32558 c.urlParams_.Set("prettyPrint", "false")
32559 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/floodlightActivities/generatetag")
32560 urls += "?" + c.urlParams_.Encode()
32561 req, err := http.NewRequest("POST", urls, body)
32562 if err != nil {
32563 return nil, err
32564 }
32565 req.Header = reqHeaders
32566 googleapi.Expand(req.URL, map[string]string{
32567 "profileId": strconv.FormatInt(c.profileId, 10),
32568 })
32569 return gensupport.SendRequest(c.ctx_, c.s.client, req)
32570 }
32571
32572
32573
32574
32575
32576
32577
32578
32579
32580 func (c *FloodlightActivitiesGeneratetagCall) Do(opts ...googleapi.CallOption) (*FloodlightActivitiesGenerateTagResponse, error) {
32581 gensupport.SetOptions(c.urlParams_, opts...)
32582 res, err := c.doRequest("json")
32583 if res != nil && res.StatusCode == http.StatusNotModified {
32584 if res.Body != nil {
32585 res.Body.Close()
32586 }
32587 return nil, &googleapi.Error{
32588 Code: res.StatusCode,
32589 Header: res.Header,
32590 }
32591 }
32592 if err != nil {
32593 return nil, err
32594 }
32595 defer googleapi.CloseBody(res)
32596 if err := googleapi.CheckResponse(res); err != nil {
32597 return nil, err
32598 }
32599 ret := &FloodlightActivitiesGenerateTagResponse{
32600 ServerResponse: googleapi.ServerResponse{
32601 Header: res.Header,
32602 HTTPStatusCode: res.StatusCode,
32603 },
32604 }
32605 target := &ret
32606 if err := gensupport.DecodeResponse(target, res); err != nil {
32607 return nil, err
32608 }
32609 return ret, nil
32610
32611
32612
32613
32614
32615
32616
32617
32618
32619
32620
32621
32622
32623
32624
32625
32626
32627
32628
32629
32630
32631
32632
32633
32634
32635
32636
32637
32638
32639
32640
32641 }
32642
32643
32644
32645 type FloodlightActivitiesGetCall struct {
32646 s *Service
32647 profileId int64
32648 id int64
32649 urlParams_ gensupport.URLParams
32650 ifNoneMatch_ string
32651 ctx_ context.Context
32652 header_ http.Header
32653 }
32654
32655
32656 func (r *FloodlightActivitiesService) Get(profileId int64, id int64) *FloodlightActivitiesGetCall {
32657 c := &FloodlightActivitiesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
32658 c.profileId = profileId
32659 c.id = id
32660 return c
32661 }
32662
32663
32664
32665
32666 func (c *FloodlightActivitiesGetCall) Fields(s ...googleapi.Field) *FloodlightActivitiesGetCall {
32667 c.urlParams_.Set("fields", googleapi.CombineFields(s))
32668 return c
32669 }
32670
32671
32672
32673
32674
32675
32676 func (c *FloodlightActivitiesGetCall) IfNoneMatch(entityTag string) *FloodlightActivitiesGetCall {
32677 c.ifNoneMatch_ = entityTag
32678 return c
32679 }
32680
32681
32682
32683
32684 func (c *FloodlightActivitiesGetCall) Context(ctx context.Context) *FloodlightActivitiesGetCall {
32685 c.ctx_ = ctx
32686 return c
32687 }
32688
32689
32690
32691 func (c *FloodlightActivitiesGetCall) Header() http.Header {
32692 if c.header_ == nil {
32693 c.header_ = make(http.Header)
32694 }
32695 return c.header_
32696 }
32697
32698 func (c *FloodlightActivitiesGetCall) doRequest(alt string) (*http.Response, error) {
32699 reqHeaders := make(http.Header)
32700 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
32701 for k, v := range c.header_ {
32702 reqHeaders[k] = v
32703 }
32704 reqHeaders.Set("User-Agent", c.s.userAgent())
32705 if c.ifNoneMatch_ != "" {
32706 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
32707 }
32708 var body io.Reader = nil
32709 c.urlParams_.Set("alt", alt)
32710 c.urlParams_.Set("prettyPrint", "false")
32711 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/floodlightActivities/{id}")
32712 urls += "?" + c.urlParams_.Encode()
32713 req, err := http.NewRequest("GET", urls, body)
32714 if err != nil {
32715 return nil, err
32716 }
32717 req.Header = reqHeaders
32718 googleapi.Expand(req.URL, map[string]string{
32719 "profileId": strconv.FormatInt(c.profileId, 10),
32720 "id": strconv.FormatInt(c.id, 10),
32721 })
32722 return gensupport.SendRequest(c.ctx_, c.s.client, req)
32723 }
32724
32725
32726
32727
32728
32729
32730
32731
32732 func (c *FloodlightActivitiesGetCall) Do(opts ...googleapi.CallOption) (*FloodlightActivity, error) {
32733 gensupport.SetOptions(c.urlParams_, opts...)
32734 res, err := c.doRequest("json")
32735 if res != nil && res.StatusCode == http.StatusNotModified {
32736 if res.Body != nil {
32737 res.Body.Close()
32738 }
32739 return nil, &googleapi.Error{
32740 Code: res.StatusCode,
32741 Header: res.Header,
32742 }
32743 }
32744 if err != nil {
32745 return nil, err
32746 }
32747 defer googleapi.CloseBody(res)
32748 if err := googleapi.CheckResponse(res); err != nil {
32749 return nil, err
32750 }
32751 ret := &FloodlightActivity{
32752 ServerResponse: googleapi.ServerResponse{
32753 Header: res.Header,
32754 HTTPStatusCode: res.StatusCode,
32755 },
32756 }
32757 target := &ret
32758 if err := gensupport.DecodeResponse(target, res); err != nil {
32759 return nil, err
32760 }
32761 return ret, nil
32762
32763
32764
32765
32766
32767
32768
32769
32770
32771
32772
32773
32774
32775
32776
32777
32778
32779
32780
32781
32782
32783
32784
32785
32786
32787
32788
32789
32790
32791
32792
32793
32794
32795 }
32796
32797
32798
32799 type FloodlightActivitiesInsertCall struct {
32800 s *Service
32801 profileId int64
32802 floodlightactivity *FloodlightActivity
32803 urlParams_ gensupport.URLParams
32804 ctx_ context.Context
32805 header_ http.Header
32806 }
32807
32808
32809 func (r *FloodlightActivitiesService) Insert(profileId int64, floodlightactivity *FloodlightActivity) *FloodlightActivitiesInsertCall {
32810 c := &FloodlightActivitiesInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
32811 c.profileId = profileId
32812 c.floodlightactivity = floodlightactivity
32813 return c
32814 }
32815
32816
32817
32818
32819 func (c *FloodlightActivitiesInsertCall) Fields(s ...googleapi.Field) *FloodlightActivitiesInsertCall {
32820 c.urlParams_.Set("fields", googleapi.CombineFields(s))
32821 return c
32822 }
32823
32824
32825
32826
32827 func (c *FloodlightActivitiesInsertCall) Context(ctx context.Context) *FloodlightActivitiesInsertCall {
32828 c.ctx_ = ctx
32829 return c
32830 }
32831
32832
32833
32834 func (c *FloodlightActivitiesInsertCall) Header() http.Header {
32835 if c.header_ == nil {
32836 c.header_ = make(http.Header)
32837 }
32838 return c.header_
32839 }
32840
32841 func (c *FloodlightActivitiesInsertCall) doRequest(alt string) (*http.Response, error) {
32842 reqHeaders := make(http.Header)
32843 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
32844 for k, v := range c.header_ {
32845 reqHeaders[k] = v
32846 }
32847 reqHeaders.Set("User-Agent", c.s.userAgent())
32848 var body io.Reader = nil
32849 body, err := googleapi.WithoutDataWrapper.JSONReader(c.floodlightactivity)
32850 if err != nil {
32851 return nil, err
32852 }
32853 reqHeaders.Set("Content-Type", "application/json")
32854 c.urlParams_.Set("alt", alt)
32855 c.urlParams_.Set("prettyPrint", "false")
32856 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/floodlightActivities")
32857 urls += "?" + c.urlParams_.Encode()
32858 req, err := http.NewRequest("POST", urls, body)
32859 if err != nil {
32860 return nil, err
32861 }
32862 req.Header = reqHeaders
32863 googleapi.Expand(req.URL, map[string]string{
32864 "profileId": strconv.FormatInt(c.profileId, 10),
32865 })
32866 return gensupport.SendRequest(c.ctx_, c.s.client, req)
32867 }
32868
32869
32870
32871
32872
32873
32874
32875
32876 func (c *FloodlightActivitiesInsertCall) Do(opts ...googleapi.CallOption) (*FloodlightActivity, error) {
32877 gensupport.SetOptions(c.urlParams_, opts...)
32878 res, err := c.doRequest("json")
32879 if res != nil && res.StatusCode == http.StatusNotModified {
32880 if res.Body != nil {
32881 res.Body.Close()
32882 }
32883 return nil, &googleapi.Error{
32884 Code: res.StatusCode,
32885 Header: res.Header,
32886 }
32887 }
32888 if err != nil {
32889 return nil, err
32890 }
32891 defer googleapi.CloseBody(res)
32892 if err := googleapi.CheckResponse(res); err != nil {
32893 return nil, err
32894 }
32895 ret := &FloodlightActivity{
32896 ServerResponse: googleapi.ServerResponse{
32897 Header: res.Header,
32898 HTTPStatusCode: res.StatusCode,
32899 },
32900 }
32901 target := &ret
32902 if err := gensupport.DecodeResponse(target, res); err != nil {
32903 return nil, err
32904 }
32905 return ret, nil
32906
32907
32908
32909
32910
32911
32912
32913
32914
32915
32916
32917
32918
32919
32920
32921
32922
32923
32924
32925
32926
32927
32928
32929
32930
32931
32932
32933
32934 }
32935
32936
32937
32938 type FloodlightActivitiesListCall struct {
32939 s *Service
32940 profileId int64
32941 urlParams_ gensupport.URLParams
32942 ifNoneMatch_ string
32943 ctx_ context.Context
32944 header_ http.Header
32945 }
32946
32947
32948
32949 func (r *FloodlightActivitiesService) List(profileId int64) *FloodlightActivitiesListCall {
32950 c := &FloodlightActivitiesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
32951 c.profileId = profileId
32952 return c
32953 }
32954
32955
32956
32957
32958
32959 func (c *FloodlightActivitiesListCall) AdvertiserId(advertiserId int64) *FloodlightActivitiesListCall {
32960 c.urlParams_.Set("advertiserId", fmt.Sprint(advertiserId))
32961 return c
32962 }
32963
32964
32965
32966
32967 func (c *FloodlightActivitiesListCall) FloodlightActivityGroupIds(floodlightActivityGroupIds ...int64) *FloodlightActivitiesListCall {
32968 var floodlightActivityGroupIds_ []string
32969 for _, v := range floodlightActivityGroupIds {
32970 floodlightActivityGroupIds_ = append(floodlightActivityGroupIds_, fmt.Sprint(v))
32971 }
32972 c.urlParams_.SetMulti("floodlightActivityGroupIds", floodlightActivityGroupIds_)
32973 return c
32974 }
32975
32976
32977
32978
32979 func (c *FloodlightActivitiesListCall) FloodlightActivityGroupName(floodlightActivityGroupName string) *FloodlightActivitiesListCall {
32980 c.urlParams_.Set("floodlightActivityGroupName", floodlightActivityGroupName)
32981 return c
32982 }
32983
32984
32985
32986
32987 func (c *FloodlightActivitiesListCall) FloodlightActivityGroupTagString(floodlightActivityGroupTagString string) *FloodlightActivitiesListCall {
32988 c.urlParams_.Set("floodlightActivityGroupTagString", floodlightActivityGroupTagString)
32989 return c
32990 }
32991
32992
32993
32994
32995
32996
32997
32998
32999
33000 func (c *FloodlightActivitiesListCall) FloodlightActivityGroupType(floodlightActivityGroupType string) *FloodlightActivitiesListCall {
33001 c.urlParams_.Set("floodlightActivityGroupType", floodlightActivityGroupType)
33002 return c
33003 }
33004
33005
33006
33007
33008
33009 func (c *FloodlightActivitiesListCall) FloodlightConfigurationId(floodlightConfigurationId int64) *FloodlightActivitiesListCall {
33010 c.urlParams_.Set("floodlightConfigurationId", fmt.Sprint(floodlightConfigurationId))
33011 return c
33012 }
33013
33014
33015
33016
33017 func (c *FloodlightActivitiesListCall) Ids(ids ...int64) *FloodlightActivitiesListCall {
33018 var ids_ []string
33019 for _, v := range ids {
33020 ids_ = append(ids_, fmt.Sprint(v))
33021 }
33022 c.urlParams_.SetMulti("ids", ids_)
33023 return c
33024 }
33025
33026
33027
33028 func (c *FloodlightActivitiesListCall) MaxResults(maxResults int64) *FloodlightActivitiesListCall {
33029 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
33030 return c
33031 }
33032
33033
33034
33035 func (c *FloodlightActivitiesListCall) PageToken(pageToken string) *FloodlightActivitiesListCall {
33036 c.urlParams_.Set("pageToken", pageToken)
33037 return c
33038 }
33039
33040
33041
33042
33043
33044
33045
33046
33047
33048
33049 func (c *FloodlightActivitiesListCall) SearchString(searchString string) *FloodlightActivitiesListCall {
33050 c.urlParams_.Set("searchString", searchString)
33051 return c
33052 }
33053
33054
33055
33056
33057
33058
33059
33060
33061 func (c *FloodlightActivitiesListCall) SortField(sortField string) *FloodlightActivitiesListCall {
33062 c.urlParams_.Set("sortField", sortField)
33063 return c
33064 }
33065
33066
33067
33068
33069
33070
33071
33072
33073 func (c *FloodlightActivitiesListCall) SortOrder(sortOrder string) *FloodlightActivitiesListCall {
33074 c.urlParams_.Set("sortOrder", sortOrder)
33075 return c
33076 }
33077
33078
33079
33080 func (c *FloodlightActivitiesListCall) TagString(tagString string) *FloodlightActivitiesListCall {
33081 c.urlParams_.Set("tagString", tagString)
33082 return c
33083 }
33084
33085
33086
33087
33088 func (c *FloodlightActivitiesListCall) Fields(s ...googleapi.Field) *FloodlightActivitiesListCall {
33089 c.urlParams_.Set("fields", googleapi.CombineFields(s))
33090 return c
33091 }
33092
33093
33094
33095
33096
33097
33098 func (c *FloodlightActivitiesListCall) IfNoneMatch(entityTag string) *FloodlightActivitiesListCall {
33099 c.ifNoneMatch_ = entityTag
33100 return c
33101 }
33102
33103
33104
33105
33106 func (c *FloodlightActivitiesListCall) Context(ctx context.Context) *FloodlightActivitiesListCall {
33107 c.ctx_ = ctx
33108 return c
33109 }
33110
33111
33112
33113 func (c *FloodlightActivitiesListCall) Header() http.Header {
33114 if c.header_ == nil {
33115 c.header_ = make(http.Header)
33116 }
33117 return c.header_
33118 }
33119
33120 func (c *FloodlightActivitiesListCall) doRequest(alt string) (*http.Response, error) {
33121 reqHeaders := make(http.Header)
33122 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
33123 for k, v := range c.header_ {
33124 reqHeaders[k] = v
33125 }
33126 reqHeaders.Set("User-Agent", c.s.userAgent())
33127 if c.ifNoneMatch_ != "" {
33128 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
33129 }
33130 var body io.Reader = nil
33131 c.urlParams_.Set("alt", alt)
33132 c.urlParams_.Set("prettyPrint", "false")
33133 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/floodlightActivities")
33134 urls += "?" + c.urlParams_.Encode()
33135 req, err := http.NewRequest("GET", urls, body)
33136 if err != nil {
33137 return nil, err
33138 }
33139 req.Header = reqHeaders
33140 googleapi.Expand(req.URL, map[string]string{
33141 "profileId": strconv.FormatInt(c.profileId, 10),
33142 })
33143 return gensupport.SendRequest(c.ctx_, c.s.client, req)
33144 }
33145
33146
33147
33148
33149
33150
33151
33152
33153 func (c *FloodlightActivitiesListCall) Do(opts ...googleapi.CallOption) (*FloodlightActivitiesListResponse, error) {
33154 gensupport.SetOptions(c.urlParams_, opts...)
33155 res, err := c.doRequest("json")
33156 if res != nil && res.StatusCode == http.StatusNotModified {
33157 if res.Body != nil {
33158 res.Body.Close()
33159 }
33160 return nil, &googleapi.Error{
33161 Code: res.StatusCode,
33162 Header: res.Header,
33163 }
33164 }
33165 if err != nil {
33166 return nil, err
33167 }
33168 defer googleapi.CloseBody(res)
33169 if err := googleapi.CheckResponse(res); err != nil {
33170 return nil, err
33171 }
33172 ret := &FloodlightActivitiesListResponse{
33173 ServerResponse: googleapi.ServerResponse{
33174 Header: res.Header,
33175 HTTPStatusCode: res.StatusCode,
33176 },
33177 }
33178 target := &ret
33179 if err := gensupport.DecodeResponse(target, res); err != nil {
33180 return nil, err
33181 }
33182 return ret, nil
33183
33184
33185
33186
33187
33188
33189
33190
33191
33192
33193
33194
33195
33196
33197
33198
33199
33200
33201
33202
33203
33204
33205
33206
33207
33208
33209
33210
33211
33212
33213
33214
33215
33216
33217
33218
33219
33220
33221
33222
33223
33224
33225
33226
33227
33228
33229
33230
33231
33232
33233
33234
33235
33236
33237
33238
33239
33240
33241
33242
33243
33244
33245
33246
33247
33248
33249
33250
33251
33252
33253
33254
33255
33256
33257
33258
33259
33260
33261
33262
33263
33264
33265
33266
33267
33268
33269
33270
33271
33272
33273
33274
33275
33276
33277
33278
33279
33280
33281
33282
33283
33284
33285
33286
33287
33288
33289
33290
33291
33292
33293
33294
33295
33296
33297
33298
33299
33300
33301
33302
33303
33304
33305
33306
33307
33308
33309 }
33310
33311
33312
33313
33314 func (c *FloodlightActivitiesListCall) Pages(ctx context.Context, f func(*FloodlightActivitiesListResponse) error) error {
33315 c.ctx_ = ctx
33316 defer c.PageToken(c.urlParams_.Get("pageToken"))
33317 for {
33318 x, err := c.Do()
33319 if err != nil {
33320 return err
33321 }
33322 if err := f(x); err != nil {
33323 return err
33324 }
33325 if x.NextPageToken == "" {
33326 return nil
33327 }
33328 c.PageToken(x.NextPageToken)
33329 }
33330 }
33331
33332
33333
33334 type FloodlightActivitiesPatchCall struct {
33335 s *Service
33336 profileId int64
33337 floodlightactivity *FloodlightActivity
33338 urlParams_ gensupport.URLParams
33339 ctx_ context.Context
33340 header_ http.Header
33341 }
33342
33343
33344
33345 func (r *FloodlightActivitiesService) Patch(profileId int64, id int64, floodlightactivity *FloodlightActivity) *FloodlightActivitiesPatchCall {
33346 c := &FloodlightActivitiesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
33347 c.profileId = profileId
33348 c.urlParams_.Set("id", fmt.Sprint(id))
33349 c.floodlightactivity = floodlightactivity
33350 return c
33351 }
33352
33353
33354
33355
33356 func (c *FloodlightActivitiesPatchCall) Fields(s ...googleapi.Field) *FloodlightActivitiesPatchCall {
33357 c.urlParams_.Set("fields", googleapi.CombineFields(s))
33358 return c
33359 }
33360
33361
33362
33363
33364 func (c *FloodlightActivitiesPatchCall) Context(ctx context.Context) *FloodlightActivitiesPatchCall {
33365 c.ctx_ = ctx
33366 return c
33367 }
33368
33369
33370
33371 func (c *FloodlightActivitiesPatchCall) Header() http.Header {
33372 if c.header_ == nil {
33373 c.header_ = make(http.Header)
33374 }
33375 return c.header_
33376 }
33377
33378 func (c *FloodlightActivitiesPatchCall) doRequest(alt string) (*http.Response, error) {
33379 reqHeaders := make(http.Header)
33380 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
33381 for k, v := range c.header_ {
33382 reqHeaders[k] = v
33383 }
33384 reqHeaders.Set("User-Agent", c.s.userAgent())
33385 var body io.Reader = nil
33386 body, err := googleapi.WithoutDataWrapper.JSONReader(c.floodlightactivity)
33387 if err != nil {
33388 return nil, err
33389 }
33390 reqHeaders.Set("Content-Type", "application/json")
33391 c.urlParams_.Set("alt", alt)
33392 c.urlParams_.Set("prettyPrint", "false")
33393 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/floodlightActivities")
33394 urls += "?" + c.urlParams_.Encode()
33395 req, err := http.NewRequest("PATCH", urls, body)
33396 if err != nil {
33397 return nil, err
33398 }
33399 req.Header = reqHeaders
33400 googleapi.Expand(req.URL, map[string]string{
33401 "profileId": strconv.FormatInt(c.profileId, 10),
33402 })
33403 return gensupport.SendRequest(c.ctx_, c.s.client, req)
33404 }
33405
33406
33407
33408
33409
33410
33411
33412
33413 func (c *FloodlightActivitiesPatchCall) Do(opts ...googleapi.CallOption) (*FloodlightActivity, error) {
33414 gensupport.SetOptions(c.urlParams_, opts...)
33415 res, err := c.doRequest("json")
33416 if res != nil && res.StatusCode == http.StatusNotModified {
33417 if res.Body != nil {
33418 res.Body.Close()
33419 }
33420 return nil, &googleapi.Error{
33421 Code: res.StatusCode,
33422 Header: res.Header,
33423 }
33424 }
33425 if err != nil {
33426 return nil, err
33427 }
33428 defer googleapi.CloseBody(res)
33429 if err := googleapi.CheckResponse(res); err != nil {
33430 return nil, err
33431 }
33432 ret := &FloodlightActivity{
33433 ServerResponse: googleapi.ServerResponse{
33434 Header: res.Header,
33435 HTTPStatusCode: res.StatusCode,
33436 },
33437 }
33438 target := &ret
33439 if err := gensupport.DecodeResponse(target, res); err != nil {
33440 return nil, err
33441 }
33442 return ret, nil
33443
33444
33445
33446
33447
33448
33449
33450
33451
33452
33453
33454
33455
33456
33457
33458
33459
33460
33461
33462
33463
33464
33465
33466
33467
33468
33469
33470
33471
33472
33473
33474
33475
33476
33477
33478
33479 }
33480
33481
33482
33483 type FloodlightActivitiesUpdateCall struct {
33484 s *Service
33485 profileId int64
33486 floodlightactivity *FloodlightActivity
33487 urlParams_ gensupport.URLParams
33488 ctx_ context.Context
33489 header_ http.Header
33490 }
33491
33492
33493 func (r *FloodlightActivitiesService) Update(profileId int64, floodlightactivity *FloodlightActivity) *FloodlightActivitiesUpdateCall {
33494 c := &FloodlightActivitiesUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
33495 c.profileId = profileId
33496 c.floodlightactivity = floodlightactivity
33497 return c
33498 }
33499
33500
33501
33502
33503 func (c *FloodlightActivitiesUpdateCall) Fields(s ...googleapi.Field) *FloodlightActivitiesUpdateCall {
33504 c.urlParams_.Set("fields", googleapi.CombineFields(s))
33505 return c
33506 }
33507
33508
33509
33510
33511 func (c *FloodlightActivitiesUpdateCall) Context(ctx context.Context) *FloodlightActivitiesUpdateCall {
33512 c.ctx_ = ctx
33513 return c
33514 }
33515
33516
33517
33518 func (c *FloodlightActivitiesUpdateCall) Header() http.Header {
33519 if c.header_ == nil {
33520 c.header_ = make(http.Header)
33521 }
33522 return c.header_
33523 }
33524
33525 func (c *FloodlightActivitiesUpdateCall) doRequest(alt string) (*http.Response, error) {
33526 reqHeaders := make(http.Header)
33527 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
33528 for k, v := range c.header_ {
33529 reqHeaders[k] = v
33530 }
33531 reqHeaders.Set("User-Agent", c.s.userAgent())
33532 var body io.Reader = nil
33533 body, err := googleapi.WithoutDataWrapper.JSONReader(c.floodlightactivity)
33534 if err != nil {
33535 return nil, err
33536 }
33537 reqHeaders.Set("Content-Type", "application/json")
33538 c.urlParams_.Set("alt", alt)
33539 c.urlParams_.Set("prettyPrint", "false")
33540 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/floodlightActivities")
33541 urls += "?" + c.urlParams_.Encode()
33542 req, err := http.NewRequest("PUT", urls, body)
33543 if err != nil {
33544 return nil, err
33545 }
33546 req.Header = reqHeaders
33547 googleapi.Expand(req.URL, map[string]string{
33548 "profileId": strconv.FormatInt(c.profileId, 10),
33549 })
33550 return gensupport.SendRequest(c.ctx_, c.s.client, req)
33551 }
33552
33553
33554
33555
33556
33557
33558
33559
33560 func (c *FloodlightActivitiesUpdateCall) Do(opts ...googleapi.CallOption) (*FloodlightActivity, error) {
33561 gensupport.SetOptions(c.urlParams_, opts...)
33562 res, err := c.doRequest("json")
33563 if res != nil && res.StatusCode == http.StatusNotModified {
33564 if res.Body != nil {
33565 res.Body.Close()
33566 }
33567 return nil, &googleapi.Error{
33568 Code: res.StatusCode,
33569 Header: res.Header,
33570 }
33571 }
33572 if err != nil {
33573 return nil, err
33574 }
33575 defer googleapi.CloseBody(res)
33576 if err := googleapi.CheckResponse(res); err != nil {
33577 return nil, err
33578 }
33579 ret := &FloodlightActivity{
33580 ServerResponse: googleapi.ServerResponse{
33581 Header: res.Header,
33582 HTTPStatusCode: res.StatusCode,
33583 },
33584 }
33585 target := &ret
33586 if err := gensupport.DecodeResponse(target, res); err != nil {
33587 return nil, err
33588 }
33589 return ret, nil
33590
33591
33592
33593
33594
33595
33596
33597
33598
33599
33600
33601
33602
33603
33604
33605
33606
33607
33608
33609
33610
33611
33612
33613
33614
33615
33616
33617
33618 }
33619
33620
33621
33622 type FloodlightActivityGroupsGetCall struct {
33623 s *Service
33624 profileId int64
33625 id int64
33626 urlParams_ gensupport.URLParams
33627 ifNoneMatch_ string
33628 ctx_ context.Context
33629 header_ http.Header
33630 }
33631
33632
33633 func (r *FloodlightActivityGroupsService) Get(profileId int64, id int64) *FloodlightActivityGroupsGetCall {
33634 c := &FloodlightActivityGroupsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
33635 c.profileId = profileId
33636 c.id = id
33637 return c
33638 }
33639
33640
33641
33642
33643 func (c *FloodlightActivityGroupsGetCall) Fields(s ...googleapi.Field) *FloodlightActivityGroupsGetCall {
33644 c.urlParams_.Set("fields", googleapi.CombineFields(s))
33645 return c
33646 }
33647
33648
33649
33650
33651
33652
33653 func (c *FloodlightActivityGroupsGetCall) IfNoneMatch(entityTag string) *FloodlightActivityGroupsGetCall {
33654 c.ifNoneMatch_ = entityTag
33655 return c
33656 }
33657
33658
33659
33660
33661 func (c *FloodlightActivityGroupsGetCall) Context(ctx context.Context) *FloodlightActivityGroupsGetCall {
33662 c.ctx_ = ctx
33663 return c
33664 }
33665
33666
33667
33668 func (c *FloodlightActivityGroupsGetCall) Header() http.Header {
33669 if c.header_ == nil {
33670 c.header_ = make(http.Header)
33671 }
33672 return c.header_
33673 }
33674
33675 func (c *FloodlightActivityGroupsGetCall) doRequest(alt string) (*http.Response, error) {
33676 reqHeaders := make(http.Header)
33677 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
33678 for k, v := range c.header_ {
33679 reqHeaders[k] = v
33680 }
33681 reqHeaders.Set("User-Agent", c.s.userAgent())
33682 if c.ifNoneMatch_ != "" {
33683 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
33684 }
33685 var body io.Reader = nil
33686 c.urlParams_.Set("alt", alt)
33687 c.urlParams_.Set("prettyPrint", "false")
33688 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/floodlightActivityGroups/{id}")
33689 urls += "?" + c.urlParams_.Encode()
33690 req, err := http.NewRequest("GET", urls, body)
33691 if err != nil {
33692 return nil, err
33693 }
33694 req.Header = reqHeaders
33695 googleapi.Expand(req.URL, map[string]string{
33696 "profileId": strconv.FormatInt(c.profileId, 10),
33697 "id": strconv.FormatInt(c.id, 10),
33698 })
33699 return gensupport.SendRequest(c.ctx_, c.s.client, req)
33700 }
33701
33702
33703
33704
33705
33706
33707
33708
33709 func (c *FloodlightActivityGroupsGetCall) Do(opts ...googleapi.CallOption) (*FloodlightActivityGroup, error) {
33710 gensupport.SetOptions(c.urlParams_, opts...)
33711 res, err := c.doRequest("json")
33712 if res != nil && res.StatusCode == http.StatusNotModified {
33713 if res.Body != nil {
33714 res.Body.Close()
33715 }
33716 return nil, &googleapi.Error{
33717 Code: res.StatusCode,
33718 Header: res.Header,
33719 }
33720 }
33721 if err != nil {
33722 return nil, err
33723 }
33724 defer googleapi.CloseBody(res)
33725 if err := googleapi.CheckResponse(res); err != nil {
33726 return nil, err
33727 }
33728 ret := &FloodlightActivityGroup{
33729 ServerResponse: googleapi.ServerResponse{
33730 Header: res.Header,
33731 HTTPStatusCode: res.StatusCode,
33732 },
33733 }
33734 target := &ret
33735 if err := gensupport.DecodeResponse(target, res); err != nil {
33736 return nil, err
33737 }
33738 return ret, nil
33739
33740
33741
33742
33743
33744
33745
33746
33747
33748
33749
33750
33751
33752
33753
33754
33755
33756
33757
33758
33759
33760
33761
33762
33763
33764
33765
33766
33767
33768
33769
33770
33771
33772 }
33773
33774
33775
33776 type FloodlightActivityGroupsInsertCall struct {
33777 s *Service
33778 profileId int64
33779 floodlightactivitygroup *FloodlightActivityGroup
33780 urlParams_ gensupport.URLParams
33781 ctx_ context.Context
33782 header_ http.Header
33783 }
33784
33785
33786 func (r *FloodlightActivityGroupsService) Insert(profileId int64, floodlightactivitygroup *FloodlightActivityGroup) *FloodlightActivityGroupsInsertCall {
33787 c := &FloodlightActivityGroupsInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
33788 c.profileId = profileId
33789 c.floodlightactivitygroup = floodlightactivitygroup
33790 return c
33791 }
33792
33793
33794
33795
33796 func (c *FloodlightActivityGroupsInsertCall) Fields(s ...googleapi.Field) *FloodlightActivityGroupsInsertCall {
33797 c.urlParams_.Set("fields", googleapi.CombineFields(s))
33798 return c
33799 }
33800
33801
33802
33803
33804 func (c *FloodlightActivityGroupsInsertCall) Context(ctx context.Context) *FloodlightActivityGroupsInsertCall {
33805 c.ctx_ = ctx
33806 return c
33807 }
33808
33809
33810
33811 func (c *FloodlightActivityGroupsInsertCall) Header() http.Header {
33812 if c.header_ == nil {
33813 c.header_ = make(http.Header)
33814 }
33815 return c.header_
33816 }
33817
33818 func (c *FloodlightActivityGroupsInsertCall) doRequest(alt string) (*http.Response, error) {
33819 reqHeaders := make(http.Header)
33820 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
33821 for k, v := range c.header_ {
33822 reqHeaders[k] = v
33823 }
33824 reqHeaders.Set("User-Agent", c.s.userAgent())
33825 var body io.Reader = nil
33826 body, err := googleapi.WithoutDataWrapper.JSONReader(c.floodlightactivitygroup)
33827 if err != nil {
33828 return nil, err
33829 }
33830 reqHeaders.Set("Content-Type", "application/json")
33831 c.urlParams_.Set("alt", alt)
33832 c.urlParams_.Set("prettyPrint", "false")
33833 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/floodlightActivityGroups")
33834 urls += "?" + c.urlParams_.Encode()
33835 req, err := http.NewRequest("POST", urls, body)
33836 if err != nil {
33837 return nil, err
33838 }
33839 req.Header = reqHeaders
33840 googleapi.Expand(req.URL, map[string]string{
33841 "profileId": strconv.FormatInt(c.profileId, 10),
33842 })
33843 return gensupport.SendRequest(c.ctx_, c.s.client, req)
33844 }
33845
33846
33847
33848
33849
33850
33851
33852
33853 func (c *FloodlightActivityGroupsInsertCall) Do(opts ...googleapi.CallOption) (*FloodlightActivityGroup, error) {
33854 gensupport.SetOptions(c.urlParams_, opts...)
33855 res, err := c.doRequest("json")
33856 if res != nil && res.StatusCode == http.StatusNotModified {
33857 if res.Body != nil {
33858 res.Body.Close()
33859 }
33860 return nil, &googleapi.Error{
33861 Code: res.StatusCode,
33862 Header: res.Header,
33863 }
33864 }
33865 if err != nil {
33866 return nil, err
33867 }
33868 defer googleapi.CloseBody(res)
33869 if err := googleapi.CheckResponse(res); err != nil {
33870 return nil, err
33871 }
33872 ret := &FloodlightActivityGroup{
33873 ServerResponse: googleapi.ServerResponse{
33874 Header: res.Header,
33875 HTTPStatusCode: res.StatusCode,
33876 },
33877 }
33878 target := &ret
33879 if err := gensupport.DecodeResponse(target, res); err != nil {
33880 return nil, err
33881 }
33882 return ret, nil
33883
33884
33885
33886
33887
33888
33889
33890
33891
33892
33893
33894
33895
33896
33897
33898
33899
33900
33901
33902
33903
33904
33905
33906
33907
33908
33909
33910
33911 }
33912
33913
33914
33915 type FloodlightActivityGroupsListCall struct {
33916 s *Service
33917 profileId int64
33918 urlParams_ gensupport.URLParams
33919 ifNoneMatch_ string
33920 ctx_ context.Context
33921 header_ http.Header
33922 }
33923
33924
33925
33926 func (r *FloodlightActivityGroupsService) List(profileId int64) *FloodlightActivityGroupsListCall {
33927 c := &FloodlightActivityGroupsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
33928 c.profileId = profileId
33929 return c
33930 }
33931
33932
33933
33934
33935
33936 func (c *FloodlightActivityGroupsListCall) AdvertiserId(advertiserId int64) *FloodlightActivityGroupsListCall {
33937 c.urlParams_.Set("advertiserId", fmt.Sprint(advertiserId))
33938 return c
33939 }
33940
33941
33942
33943
33944
33945 func (c *FloodlightActivityGroupsListCall) FloodlightConfigurationId(floodlightConfigurationId int64) *FloodlightActivityGroupsListCall {
33946 c.urlParams_.Set("floodlightConfigurationId", fmt.Sprint(floodlightConfigurationId))
33947 return c
33948 }
33949
33950
33951
33952
33953 func (c *FloodlightActivityGroupsListCall) Ids(ids ...int64) *FloodlightActivityGroupsListCall {
33954 var ids_ []string
33955 for _, v := range ids {
33956 ids_ = append(ids_, fmt.Sprint(v))
33957 }
33958 c.urlParams_.SetMulti("ids", ids_)
33959 return c
33960 }
33961
33962
33963
33964 func (c *FloodlightActivityGroupsListCall) MaxResults(maxResults int64) *FloodlightActivityGroupsListCall {
33965 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
33966 return c
33967 }
33968
33969
33970
33971 func (c *FloodlightActivityGroupsListCall) PageToken(pageToken string) *FloodlightActivityGroupsListCall {
33972 c.urlParams_.Set("pageToken", pageToken)
33973 return c
33974 }
33975
33976
33977
33978
33979
33980
33981
33982
33983
33984
33985
33986 func (c *FloodlightActivityGroupsListCall) SearchString(searchString string) *FloodlightActivityGroupsListCall {
33987 c.urlParams_.Set("searchString", searchString)
33988 return c
33989 }
33990
33991
33992
33993
33994
33995
33996
33997
33998 func (c *FloodlightActivityGroupsListCall) SortField(sortField string) *FloodlightActivityGroupsListCall {
33999 c.urlParams_.Set("sortField", sortField)
34000 return c
34001 }
34002
34003
34004
34005
34006
34007
34008
34009
34010 func (c *FloodlightActivityGroupsListCall) SortOrder(sortOrder string) *FloodlightActivityGroupsListCall {
34011 c.urlParams_.Set("sortOrder", sortOrder)
34012 return c
34013 }
34014
34015
34016
34017
34018
34019
34020
34021
34022 func (c *FloodlightActivityGroupsListCall) Type(type_ string) *FloodlightActivityGroupsListCall {
34023 c.urlParams_.Set("type", type_)
34024 return c
34025 }
34026
34027
34028
34029
34030 func (c *FloodlightActivityGroupsListCall) Fields(s ...googleapi.Field) *FloodlightActivityGroupsListCall {
34031 c.urlParams_.Set("fields", googleapi.CombineFields(s))
34032 return c
34033 }
34034
34035
34036
34037
34038
34039
34040 func (c *FloodlightActivityGroupsListCall) IfNoneMatch(entityTag string) *FloodlightActivityGroupsListCall {
34041 c.ifNoneMatch_ = entityTag
34042 return c
34043 }
34044
34045
34046
34047
34048 func (c *FloodlightActivityGroupsListCall) Context(ctx context.Context) *FloodlightActivityGroupsListCall {
34049 c.ctx_ = ctx
34050 return c
34051 }
34052
34053
34054
34055 func (c *FloodlightActivityGroupsListCall) Header() http.Header {
34056 if c.header_ == nil {
34057 c.header_ = make(http.Header)
34058 }
34059 return c.header_
34060 }
34061
34062 func (c *FloodlightActivityGroupsListCall) doRequest(alt string) (*http.Response, error) {
34063 reqHeaders := make(http.Header)
34064 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
34065 for k, v := range c.header_ {
34066 reqHeaders[k] = v
34067 }
34068 reqHeaders.Set("User-Agent", c.s.userAgent())
34069 if c.ifNoneMatch_ != "" {
34070 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
34071 }
34072 var body io.Reader = nil
34073 c.urlParams_.Set("alt", alt)
34074 c.urlParams_.Set("prettyPrint", "false")
34075 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/floodlightActivityGroups")
34076 urls += "?" + c.urlParams_.Encode()
34077 req, err := http.NewRequest("GET", urls, body)
34078 if err != nil {
34079 return nil, err
34080 }
34081 req.Header = reqHeaders
34082 googleapi.Expand(req.URL, map[string]string{
34083 "profileId": strconv.FormatInt(c.profileId, 10),
34084 })
34085 return gensupport.SendRequest(c.ctx_, c.s.client, req)
34086 }
34087
34088
34089
34090
34091
34092
34093
34094
34095
34096 func (c *FloodlightActivityGroupsListCall) Do(opts ...googleapi.CallOption) (*FloodlightActivityGroupsListResponse, error) {
34097 gensupport.SetOptions(c.urlParams_, opts...)
34098 res, err := c.doRequest("json")
34099 if res != nil && res.StatusCode == http.StatusNotModified {
34100 if res.Body != nil {
34101 res.Body.Close()
34102 }
34103 return nil, &googleapi.Error{
34104 Code: res.StatusCode,
34105 Header: res.Header,
34106 }
34107 }
34108 if err != nil {
34109 return nil, err
34110 }
34111 defer googleapi.CloseBody(res)
34112 if err := googleapi.CheckResponse(res); err != nil {
34113 return nil, err
34114 }
34115 ret := &FloodlightActivityGroupsListResponse{
34116 ServerResponse: googleapi.ServerResponse{
34117 Header: res.Header,
34118 HTTPStatusCode: res.StatusCode,
34119 },
34120 }
34121 target := &ret
34122 if err := gensupport.DecodeResponse(target, res); err != nil {
34123 return nil, err
34124 }
34125 return ret, nil
34126
34127
34128
34129
34130
34131
34132
34133
34134
34135
34136
34137
34138
34139
34140
34141
34142
34143
34144
34145
34146
34147
34148
34149
34150
34151
34152
34153
34154
34155
34156
34157
34158
34159
34160
34161
34162
34163
34164
34165
34166
34167
34168
34169
34170
34171
34172
34173
34174
34175
34176
34177
34178
34179
34180
34181
34182
34183
34184
34185
34186
34187
34188
34189
34190
34191
34192
34193
34194
34195
34196
34197
34198
34199
34200
34201
34202
34203
34204
34205
34206
34207
34208
34209
34210
34211
34212
34213
34214
34215
34216
34217
34218
34219
34220
34221
34222
34223
34224
34225
34226
34227
34228
34229
34230 }
34231
34232
34233
34234
34235 func (c *FloodlightActivityGroupsListCall) Pages(ctx context.Context, f func(*FloodlightActivityGroupsListResponse) error) error {
34236 c.ctx_ = ctx
34237 defer c.PageToken(c.urlParams_.Get("pageToken"))
34238 for {
34239 x, err := c.Do()
34240 if err != nil {
34241 return err
34242 }
34243 if err := f(x); err != nil {
34244 return err
34245 }
34246 if x.NextPageToken == "" {
34247 return nil
34248 }
34249 c.PageToken(x.NextPageToken)
34250 }
34251 }
34252
34253
34254
34255 type FloodlightActivityGroupsPatchCall struct {
34256 s *Service
34257 profileId int64
34258 floodlightactivitygroup *FloodlightActivityGroup
34259 urlParams_ gensupport.URLParams
34260 ctx_ context.Context
34261 header_ http.Header
34262 }
34263
34264
34265
34266 func (r *FloodlightActivityGroupsService) Patch(profileId int64, id int64, floodlightactivitygroup *FloodlightActivityGroup) *FloodlightActivityGroupsPatchCall {
34267 c := &FloodlightActivityGroupsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
34268 c.profileId = profileId
34269 c.urlParams_.Set("id", fmt.Sprint(id))
34270 c.floodlightactivitygroup = floodlightactivitygroup
34271 return c
34272 }
34273
34274
34275
34276
34277 func (c *FloodlightActivityGroupsPatchCall) Fields(s ...googleapi.Field) *FloodlightActivityGroupsPatchCall {
34278 c.urlParams_.Set("fields", googleapi.CombineFields(s))
34279 return c
34280 }
34281
34282
34283
34284
34285 func (c *FloodlightActivityGroupsPatchCall) Context(ctx context.Context) *FloodlightActivityGroupsPatchCall {
34286 c.ctx_ = ctx
34287 return c
34288 }
34289
34290
34291
34292 func (c *FloodlightActivityGroupsPatchCall) Header() http.Header {
34293 if c.header_ == nil {
34294 c.header_ = make(http.Header)
34295 }
34296 return c.header_
34297 }
34298
34299 func (c *FloodlightActivityGroupsPatchCall) doRequest(alt string) (*http.Response, error) {
34300 reqHeaders := make(http.Header)
34301 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
34302 for k, v := range c.header_ {
34303 reqHeaders[k] = v
34304 }
34305 reqHeaders.Set("User-Agent", c.s.userAgent())
34306 var body io.Reader = nil
34307 body, err := googleapi.WithoutDataWrapper.JSONReader(c.floodlightactivitygroup)
34308 if err != nil {
34309 return nil, err
34310 }
34311 reqHeaders.Set("Content-Type", "application/json")
34312 c.urlParams_.Set("alt", alt)
34313 c.urlParams_.Set("prettyPrint", "false")
34314 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/floodlightActivityGroups")
34315 urls += "?" + c.urlParams_.Encode()
34316 req, err := http.NewRequest("PATCH", urls, body)
34317 if err != nil {
34318 return nil, err
34319 }
34320 req.Header = reqHeaders
34321 googleapi.Expand(req.URL, map[string]string{
34322 "profileId": strconv.FormatInt(c.profileId, 10),
34323 })
34324 return gensupport.SendRequest(c.ctx_, c.s.client, req)
34325 }
34326
34327
34328
34329
34330
34331
34332
34333
34334 func (c *FloodlightActivityGroupsPatchCall) Do(opts ...googleapi.CallOption) (*FloodlightActivityGroup, error) {
34335 gensupport.SetOptions(c.urlParams_, opts...)
34336 res, err := c.doRequest("json")
34337 if res != nil && res.StatusCode == http.StatusNotModified {
34338 if res.Body != nil {
34339 res.Body.Close()
34340 }
34341 return nil, &googleapi.Error{
34342 Code: res.StatusCode,
34343 Header: res.Header,
34344 }
34345 }
34346 if err != nil {
34347 return nil, err
34348 }
34349 defer googleapi.CloseBody(res)
34350 if err := googleapi.CheckResponse(res); err != nil {
34351 return nil, err
34352 }
34353 ret := &FloodlightActivityGroup{
34354 ServerResponse: googleapi.ServerResponse{
34355 Header: res.Header,
34356 HTTPStatusCode: res.StatusCode,
34357 },
34358 }
34359 target := &ret
34360 if err := gensupport.DecodeResponse(target, res); err != nil {
34361 return nil, err
34362 }
34363 return ret, nil
34364
34365
34366
34367
34368
34369
34370
34371
34372
34373
34374
34375
34376
34377
34378
34379
34380
34381
34382
34383
34384
34385
34386
34387
34388
34389
34390
34391
34392
34393
34394
34395
34396
34397
34398
34399
34400 }
34401
34402
34403
34404 type FloodlightActivityGroupsUpdateCall struct {
34405 s *Service
34406 profileId int64
34407 floodlightactivitygroup *FloodlightActivityGroup
34408 urlParams_ gensupport.URLParams
34409 ctx_ context.Context
34410 header_ http.Header
34411 }
34412
34413
34414 func (r *FloodlightActivityGroupsService) Update(profileId int64, floodlightactivitygroup *FloodlightActivityGroup) *FloodlightActivityGroupsUpdateCall {
34415 c := &FloodlightActivityGroupsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
34416 c.profileId = profileId
34417 c.floodlightactivitygroup = floodlightactivitygroup
34418 return c
34419 }
34420
34421
34422
34423
34424 func (c *FloodlightActivityGroupsUpdateCall) Fields(s ...googleapi.Field) *FloodlightActivityGroupsUpdateCall {
34425 c.urlParams_.Set("fields", googleapi.CombineFields(s))
34426 return c
34427 }
34428
34429
34430
34431
34432 func (c *FloodlightActivityGroupsUpdateCall) Context(ctx context.Context) *FloodlightActivityGroupsUpdateCall {
34433 c.ctx_ = ctx
34434 return c
34435 }
34436
34437
34438
34439 func (c *FloodlightActivityGroupsUpdateCall) Header() http.Header {
34440 if c.header_ == nil {
34441 c.header_ = make(http.Header)
34442 }
34443 return c.header_
34444 }
34445
34446 func (c *FloodlightActivityGroupsUpdateCall) doRequest(alt string) (*http.Response, error) {
34447 reqHeaders := make(http.Header)
34448 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
34449 for k, v := range c.header_ {
34450 reqHeaders[k] = v
34451 }
34452 reqHeaders.Set("User-Agent", c.s.userAgent())
34453 var body io.Reader = nil
34454 body, err := googleapi.WithoutDataWrapper.JSONReader(c.floodlightactivitygroup)
34455 if err != nil {
34456 return nil, err
34457 }
34458 reqHeaders.Set("Content-Type", "application/json")
34459 c.urlParams_.Set("alt", alt)
34460 c.urlParams_.Set("prettyPrint", "false")
34461 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/floodlightActivityGroups")
34462 urls += "?" + c.urlParams_.Encode()
34463 req, err := http.NewRequest("PUT", urls, body)
34464 if err != nil {
34465 return nil, err
34466 }
34467 req.Header = reqHeaders
34468 googleapi.Expand(req.URL, map[string]string{
34469 "profileId": strconv.FormatInt(c.profileId, 10),
34470 })
34471 return gensupport.SendRequest(c.ctx_, c.s.client, req)
34472 }
34473
34474
34475
34476
34477
34478
34479
34480
34481 func (c *FloodlightActivityGroupsUpdateCall) Do(opts ...googleapi.CallOption) (*FloodlightActivityGroup, error) {
34482 gensupport.SetOptions(c.urlParams_, opts...)
34483 res, err := c.doRequest("json")
34484 if res != nil && res.StatusCode == http.StatusNotModified {
34485 if res.Body != nil {
34486 res.Body.Close()
34487 }
34488 return nil, &googleapi.Error{
34489 Code: res.StatusCode,
34490 Header: res.Header,
34491 }
34492 }
34493 if err != nil {
34494 return nil, err
34495 }
34496 defer googleapi.CloseBody(res)
34497 if err := googleapi.CheckResponse(res); err != nil {
34498 return nil, err
34499 }
34500 ret := &FloodlightActivityGroup{
34501 ServerResponse: googleapi.ServerResponse{
34502 Header: res.Header,
34503 HTTPStatusCode: res.StatusCode,
34504 },
34505 }
34506 target := &ret
34507 if err := gensupport.DecodeResponse(target, res); err != nil {
34508 return nil, err
34509 }
34510 return ret, nil
34511
34512
34513
34514
34515
34516
34517
34518
34519
34520
34521
34522
34523
34524
34525
34526
34527
34528
34529
34530
34531
34532
34533
34534
34535
34536
34537
34538
34539 }
34540
34541
34542
34543 type FloodlightConfigurationsGetCall struct {
34544 s *Service
34545 profileId int64
34546 id int64
34547 urlParams_ gensupport.URLParams
34548 ifNoneMatch_ string
34549 ctx_ context.Context
34550 header_ http.Header
34551 }
34552
34553
34554 func (r *FloodlightConfigurationsService) Get(profileId int64, id int64) *FloodlightConfigurationsGetCall {
34555 c := &FloodlightConfigurationsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
34556 c.profileId = profileId
34557 c.id = id
34558 return c
34559 }
34560
34561
34562
34563
34564 func (c *FloodlightConfigurationsGetCall) Fields(s ...googleapi.Field) *FloodlightConfigurationsGetCall {
34565 c.urlParams_.Set("fields", googleapi.CombineFields(s))
34566 return c
34567 }
34568
34569
34570
34571
34572
34573
34574 func (c *FloodlightConfigurationsGetCall) IfNoneMatch(entityTag string) *FloodlightConfigurationsGetCall {
34575 c.ifNoneMatch_ = entityTag
34576 return c
34577 }
34578
34579
34580
34581
34582 func (c *FloodlightConfigurationsGetCall) Context(ctx context.Context) *FloodlightConfigurationsGetCall {
34583 c.ctx_ = ctx
34584 return c
34585 }
34586
34587
34588
34589 func (c *FloodlightConfigurationsGetCall) Header() http.Header {
34590 if c.header_ == nil {
34591 c.header_ = make(http.Header)
34592 }
34593 return c.header_
34594 }
34595
34596 func (c *FloodlightConfigurationsGetCall) doRequest(alt string) (*http.Response, error) {
34597 reqHeaders := make(http.Header)
34598 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
34599 for k, v := range c.header_ {
34600 reqHeaders[k] = v
34601 }
34602 reqHeaders.Set("User-Agent", c.s.userAgent())
34603 if c.ifNoneMatch_ != "" {
34604 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
34605 }
34606 var body io.Reader = nil
34607 c.urlParams_.Set("alt", alt)
34608 c.urlParams_.Set("prettyPrint", "false")
34609 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/floodlightConfigurations/{id}")
34610 urls += "?" + c.urlParams_.Encode()
34611 req, err := http.NewRequest("GET", urls, body)
34612 if err != nil {
34613 return nil, err
34614 }
34615 req.Header = reqHeaders
34616 googleapi.Expand(req.URL, map[string]string{
34617 "profileId": strconv.FormatInt(c.profileId, 10),
34618 "id": strconv.FormatInt(c.id, 10),
34619 })
34620 return gensupport.SendRequest(c.ctx_, c.s.client, req)
34621 }
34622
34623
34624
34625
34626
34627
34628
34629
34630 func (c *FloodlightConfigurationsGetCall) Do(opts ...googleapi.CallOption) (*FloodlightConfiguration, error) {
34631 gensupport.SetOptions(c.urlParams_, opts...)
34632 res, err := c.doRequest("json")
34633 if res != nil && res.StatusCode == http.StatusNotModified {
34634 if res.Body != nil {
34635 res.Body.Close()
34636 }
34637 return nil, &googleapi.Error{
34638 Code: res.StatusCode,
34639 Header: res.Header,
34640 }
34641 }
34642 if err != nil {
34643 return nil, err
34644 }
34645 defer googleapi.CloseBody(res)
34646 if err := googleapi.CheckResponse(res); err != nil {
34647 return nil, err
34648 }
34649 ret := &FloodlightConfiguration{
34650 ServerResponse: googleapi.ServerResponse{
34651 Header: res.Header,
34652 HTTPStatusCode: res.StatusCode,
34653 },
34654 }
34655 target := &ret
34656 if err := gensupport.DecodeResponse(target, res); err != nil {
34657 return nil, err
34658 }
34659 return ret, nil
34660
34661
34662
34663
34664
34665
34666
34667
34668
34669
34670
34671
34672
34673
34674
34675
34676
34677
34678
34679
34680
34681
34682
34683
34684
34685
34686
34687
34688
34689
34690
34691
34692
34693 }
34694
34695
34696
34697 type FloodlightConfigurationsListCall struct {
34698 s *Service
34699 profileId int64
34700 urlParams_ gensupport.URLParams
34701 ifNoneMatch_ string
34702 ctx_ context.Context
34703 header_ http.Header
34704 }
34705
34706
34707
34708 func (r *FloodlightConfigurationsService) List(profileId int64) *FloodlightConfigurationsListCall {
34709 c := &FloodlightConfigurationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
34710 c.profileId = profileId
34711 return c
34712 }
34713
34714
34715
34716
34717 func (c *FloodlightConfigurationsListCall) Ids(ids ...int64) *FloodlightConfigurationsListCall {
34718 var ids_ []string
34719 for _, v := range ids {
34720 ids_ = append(ids_, fmt.Sprint(v))
34721 }
34722 c.urlParams_.SetMulti("ids", ids_)
34723 return c
34724 }
34725
34726
34727
34728
34729 func (c *FloodlightConfigurationsListCall) Fields(s ...googleapi.Field) *FloodlightConfigurationsListCall {
34730 c.urlParams_.Set("fields", googleapi.CombineFields(s))
34731 return c
34732 }
34733
34734
34735
34736
34737
34738
34739 func (c *FloodlightConfigurationsListCall) IfNoneMatch(entityTag string) *FloodlightConfigurationsListCall {
34740 c.ifNoneMatch_ = entityTag
34741 return c
34742 }
34743
34744
34745
34746
34747 func (c *FloodlightConfigurationsListCall) Context(ctx context.Context) *FloodlightConfigurationsListCall {
34748 c.ctx_ = ctx
34749 return c
34750 }
34751
34752
34753
34754 func (c *FloodlightConfigurationsListCall) Header() http.Header {
34755 if c.header_ == nil {
34756 c.header_ = make(http.Header)
34757 }
34758 return c.header_
34759 }
34760
34761 func (c *FloodlightConfigurationsListCall) doRequest(alt string) (*http.Response, error) {
34762 reqHeaders := make(http.Header)
34763 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
34764 for k, v := range c.header_ {
34765 reqHeaders[k] = v
34766 }
34767 reqHeaders.Set("User-Agent", c.s.userAgent())
34768 if c.ifNoneMatch_ != "" {
34769 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
34770 }
34771 var body io.Reader = nil
34772 c.urlParams_.Set("alt", alt)
34773 c.urlParams_.Set("prettyPrint", "false")
34774 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/floodlightConfigurations")
34775 urls += "?" + c.urlParams_.Encode()
34776 req, err := http.NewRequest("GET", urls, body)
34777 if err != nil {
34778 return nil, err
34779 }
34780 req.Header = reqHeaders
34781 googleapi.Expand(req.URL, map[string]string{
34782 "profileId": strconv.FormatInt(c.profileId, 10),
34783 })
34784 return gensupport.SendRequest(c.ctx_, c.s.client, req)
34785 }
34786
34787
34788
34789
34790
34791
34792
34793
34794
34795 func (c *FloodlightConfigurationsListCall) Do(opts ...googleapi.CallOption) (*FloodlightConfigurationsListResponse, error) {
34796 gensupport.SetOptions(c.urlParams_, opts...)
34797 res, err := c.doRequest("json")
34798 if res != nil && res.StatusCode == http.StatusNotModified {
34799 if res.Body != nil {
34800 res.Body.Close()
34801 }
34802 return nil, &googleapi.Error{
34803 Code: res.StatusCode,
34804 Header: res.Header,
34805 }
34806 }
34807 if err != nil {
34808 return nil, err
34809 }
34810 defer googleapi.CloseBody(res)
34811 if err := googleapi.CheckResponse(res); err != nil {
34812 return nil, err
34813 }
34814 ret := &FloodlightConfigurationsListResponse{
34815 ServerResponse: googleapi.ServerResponse{
34816 Header: res.Header,
34817 HTTPStatusCode: res.StatusCode,
34818 },
34819 }
34820 target := &ret
34821 if err := gensupport.DecodeResponse(target, res); err != nil {
34822 return nil, err
34823 }
34824 return ret, nil
34825
34826
34827
34828
34829
34830
34831
34832
34833
34834
34835
34836
34837
34838
34839
34840
34841
34842
34843
34844
34845
34846
34847
34848
34849
34850
34851
34852
34853
34854
34855
34856
34857 }
34858
34859
34860
34861 type FloodlightConfigurationsPatchCall struct {
34862 s *Service
34863 profileId int64
34864 floodlightconfiguration *FloodlightConfiguration
34865 urlParams_ gensupport.URLParams
34866 ctx_ context.Context
34867 header_ http.Header
34868 }
34869
34870
34871
34872 func (r *FloodlightConfigurationsService) Patch(profileId int64, id int64, floodlightconfiguration *FloodlightConfiguration) *FloodlightConfigurationsPatchCall {
34873 c := &FloodlightConfigurationsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
34874 c.profileId = profileId
34875 c.urlParams_.Set("id", fmt.Sprint(id))
34876 c.floodlightconfiguration = floodlightconfiguration
34877 return c
34878 }
34879
34880
34881
34882
34883 func (c *FloodlightConfigurationsPatchCall) Fields(s ...googleapi.Field) *FloodlightConfigurationsPatchCall {
34884 c.urlParams_.Set("fields", googleapi.CombineFields(s))
34885 return c
34886 }
34887
34888
34889
34890
34891 func (c *FloodlightConfigurationsPatchCall) Context(ctx context.Context) *FloodlightConfigurationsPatchCall {
34892 c.ctx_ = ctx
34893 return c
34894 }
34895
34896
34897
34898 func (c *FloodlightConfigurationsPatchCall) Header() http.Header {
34899 if c.header_ == nil {
34900 c.header_ = make(http.Header)
34901 }
34902 return c.header_
34903 }
34904
34905 func (c *FloodlightConfigurationsPatchCall) doRequest(alt string) (*http.Response, error) {
34906 reqHeaders := make(http.Header)
34907 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
34908 for k, v := range c.header_ {
34909 reqHeaders[k] = v
34910 }
34911 reqHeaders.Set("User-Agent", c.s.userAgent())
34912 var body io.Reader = nil
34913 body, err := googleapi.WithoutDataWrapper.JSONReader(c.floodlightconfiguration)
34914 if err != nil {
34915 return nil, err
34916 }
34917 reqHeaders.Set("Content-Type", "application/json")
34918 c.urlParams_.Set("alt", alt)
34919 c.urlParams_.Set("prettyPrint", "false")
34920 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/floodlightConfigurations")
34921 urls += "?" + c.urlParams_.Encode()
34922 req, err := http.NewRequest("PATCH", urls, body)
34923 if err != nil {
34924 return nil, err
34925 }
34926 req.Header = reqHeaders
34927 googleapi.Expand(req.URL, map[string]string{
34928 "profileId": strconv.FormatInt(c.profileId, 10),
34929 })
34930 return gensupport.SendRequest(c.ctx_, c.s.client, req)
34931 }
34932
34933
34934
34935
34936
34937
34938
34939
34940 func (c *FloodlightConfigurationsPatchCall) Do(opts ...googleapi.CallOption) (*FloodlightConfiguration, error) {
34941 gensupport.SetOptions(c.urlParams_, opts...)
34942 res, err := c.doRequest("json")
34943 if res != nil && res.StatusCode == http.StatusNotModified {
34944 if res.Body != nil {
34945 res.Body.Close()
34946 }
34947 return nil, &googleapi.Error{
34948 Code: res.StatusCode,
34949 Header: res.Header,
34950 }
34951 }
34952 if err != nil {
34953 return nil, err
34954 }
34955 defer googleapi.CloseBody(res)
34956 if err := googleapi.CheckResponse(res); err != nil {
34957 return nil, err
34958 }
34959 ret := &FloodlightConfiguration{
34960 ServerResponse: googleapi.ServerResponse{
34961 Header: res.Header,
34962 HTTPStatusCode: res.StatusCode,
34963 },
34964 }
34965 target := &ret
34966 if err := gensupport.DecodeResponse(target, res); err != nil {
34967 return nil, err
34968 }
34969 return ret, nil
34970
34971
34972
34973
34974
34975
34976
34977
34978
34979
34980
34981
34982
34983
34984
34985
34986
34987
34988
34989
34990
34991
34992
34993
34994
34995
34996
34997
34998
34999
35000
35001
35002
35003
35004
35005
35006 }
35007
35008
35009
35010 type FloodlightConfigurationsUpdateCall struct {
35011 s *Service
35012 profileId int64
35013 floodlightconfiguration *FloodlightConfiguration
35014 urlParams_ gensupport.URLParams
35015 ctx_ context.Context
35016 header_ http.Header
35017 }
35018
35019
35020 func (r *FloodlightConfigurationsService) Update(profileId int64, floodlightconfiguration *FloodlightConfiguration) *FloodlightConfigurationsUpdateCall {
35021 c := &FloodlightConfigurationsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
35022 c.profileId = profileId
35023 c.floodlightconfiguration = floodlightconfiguration
35024 return c
35025 }
35026
35027
35028
35029
35030 func (c *FloodlightConfigurationsUpdateCall) Fields(s ...googleapi.Field) *FloodlightConfigurationsUpdateCall {
35031 c.urlParams_.Set("fields", googleapi.CombineFields(s))
35032 return c
35033 }
35034
35035
35036
35037
35038 func (c *FloodlightConfigurationsUpdateCall) Context(ctx context.Context) *FloodlightConfigurationsUpdateCall {
35039 c.ctx_ = ctx
35040 return c
35041 }
35042
35043
35044
35045 func (c *FloodlightConfigurationsUpdateCall) Header() http.Header {
35046 if c.header_ == nil {
35047 c.header_ = make(http.Header)
35048 }
35049 return c.header_
35050 }
35051
35052 func (c *FloodlightConfigurationsUpdateCall) doRequest(alt string) (*http.Response, error) {
35053 reqHeaders := make(http.Header)
35054 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
35055 for k, v := range c.header_ {
35056 reqHeaders[k] = v
35057 }
35058 reqHeaders.Set("User-Agent", c.s.userAgent())
35059 var body io.Reader = nil
35060 body, err := googleapi.WithoutDataWrapper.JSONReader(c.floodlightconfiguration)
35061 if err != nil {
35062 return nil, err
35063 }
35064 reqHeaders.Set("Content-Type", "application/json")
35065 c.urlParams_.Set("alt", alt)
35066 c.urlParams_.Set("prettyPrint", "false")
35067 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/floodlightConfigurations")
35068 urls += "?" + c.urlParams_.Encode()
35069 req, err := http.NewRequest("PUT", urls, body)
35070 if err != nil {
35071 return nil, err
35072 }
35073 req.Header = reqHeaders
35074 googleapi.Expand(req.URL, map[string]string{
35075 "profileId": strconv.FormatInt(c.profileId, 10),
35076 })
35077 return gensupport.SendRequest(c.ctx_, c.s.client, req)
35078 }
35079
35080
35081
35082
35083
35084
35085
35086
35087 func (c *FloodlightConfigurationsUpdateCall) Do(opts ...googleapi.CallOption) (*FloodlightConfiguration, error) {
35088 gensupport.SetOptions(c.urlParams_, opts...)
35089 res, err := c.doRequest("json")
35090 if res != nil && res.StatusCode == http.StatusNotModified {
35091 if res.Body != nil {
35092 res.Body.Close()
35093 }
35094 return nil, &googleapi.Error{
35095 Code: res.StatusCode,
35096 Header: res.Header,
35097 }
35098 }
35099 if err != nil {
35100 return nil, err
35101 }
35102 defer googleapi.CloseBody(res)
35103 if err := googleapi.CheckResponse(res); err != nil {
35104 return nil, err
35105 }
35106 ret := &FloodlightConfiguration{
35107 ServerResponse: googleapi.ServerResponse{
35108 Header: res.Header,
35109 HTTPStatusCode: res.StatusCode,
35110 },
35111 }
35112 target := &ret
35113 if err := gensupport.DecodeResponse(target, res); err != nil {
35114 return nil, err
35115 }
35116 return ret, nil
35117
35118
35119
35120
35121
35122
35123
35124
35125
35126
35127
35128
35129
35130
35131
35132
35133
35134
35135
35136
35137
35138
35139
35140
35141
35142
35143
35144
35145 }
35146
35147
35148
35149 type InventoryItemsGetCall struct {
35150 s *Service
35151 profileId int64
35152 projectId int64
35153 id int64
35154 urlParams_ gensupport.URLParams
35155 ifNoneMatch_ string
35156 ctx_ context.Context
35157 header_ http.Header
35158 }
35159
35160
35161 func (r *InventoryItemsService) Get(profileId int64, projectId int64, id int64) *InventoryItemsGetCall {
35162 c := &InventoryItemsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
35163 c.profileId = profileId
35164 c.projectId = projectId
35165 c.id = id
35166 return c
35167 }
35168
35169
35170
35171
35172 func (c *InventoryItemsGetCall) Fields(s ...googleapi.Field) *InventoryItemsGetCall {
35173 c.urlParams_.Set("fields", googleapi.CombineFields(s))
35174 return c
35175 }
35176
35177
35178
35179
35180
35181
35182 func (c *InventoryItemsGetCall) IfNoneMatch(entityTag string) *InventoryItemsGetCall {
35183 c.ifNoneMatch_ = entityTag
35184 return c
35185 }
35186
35187
35188
35189
35190 func (c *InventoryItemsGetCall) Context(ctx context.Context) *InventoryItemsGetCall {
35191 c.ctx_ = ctx
35192 return c
35193 }
35194
35195
35196
35197 func (c *InventoryItemsGetCall) Header() http.Header {
35198 if c.header_ == nil {
35199 c.header_ = make(http.Header)
35200 }
35201 return c.header_
35202 }
35203
35204 func (c *InventoryItemsGetCall) doRequest(alt string) (*http.Response, error) {
35205 reqHeaders := make(http.Header)
35206 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
35207 for k, v := range c.header_ {
35208 reqHeaders[k] = v
35209 }
35210 reqHeaders.Set("User-Agent", c.s.userAgent())
35211 if c.ifNoneMatch_ != "" {
35212 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
35213 }
35214 var body io.Reader = nil
35215 c.urlParams_.Set("alt", alt)
35216 c.urlParams_.Set("prettyPrint", "false")
35217 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/projects/{projectId}/inventoryItems/{id}")
35218 urls += "?" + c.urlParams_.Encode()
35219 req, err := http.NewRequest("GET", urls, body)
35220 if err != nil {
35221 return nil, err
35222 }
35223 req.Header = reqHeaders
35224 googleapi.Expand(req.URL, map[string]string{
35225 "profileId": strconv.FormatInt(c.profileId, 10),
35226 "projectId": strconv.FormatInt(c.projectId, 10),
35227 "id": strconv.FormatInt(c.id, 10),
35228 })
35229 return gensupport.SendRequest(c.ctx_, c.s.client, req)
35230 }
35231
35232
35233
35234
35235
35236
35237
35238
35239 func (c *InventoryItemsGetCall) Do(opts ...googleapi.CallOption) (*InventoryItem, error) {
35240 gensupport.SetOptions(c.urlParams_, opts...)
35241 res, err := c.doRequest("json")
35242 if res != nil && res.StatusCode == http.StatusNotModified {
35243 if res.Body != nil {
35244 res.Body.Close()
35245 }
35246 return nil, &googleapi.Error{
35247 Code: res.StatusCode,
35248 Header: res.Header,
35249 }
35250 }
35251 if err != nil {
35252 return nil, err
35253 }
35254 defer googleapi.CloseBody(res)
35255 if err := googleapi.CheckResponse(res); err != nil {
35256 return nil, err
35257 }
35258 ret := &InventoryItem{
35259 ServerResponse: googleapi.ServerResponse{
35260 Header: res.Header,
35261 HTTPStatusCode: res.StatusCode,
35262 },
35263 }
35264 target := &ret
35265 if err := gensupport.DecodeResponse(target, res); err != nil {
35266 return nil, err
35267 }
35268 return ret, nil
35269
35270
35271
35272
35273
35274
35275
35276
35277
35278
35279
35280
35281
35282
35283
35284
35285
35286
35287
35288
35289
35290
35291
35292
35293
35294
35295
35296
35297
35298
35299
35300
35301
35302
35303
35304
35305
35306
35307
35308
35309
35310 }
35311
35312
35313
35314 type InventoryItemsListCall struct {
35315 s *Service
35316 profileId int64
35317 projectId int64
35318 urlParams_ gensupport.URLParams
35319 ifNoneMatch_ string
35320 ctx_ context.Context
35321 header_ http.Header
35322 }
35323
35324
35325
35326 func (r *InventoryItemsService) List(profileId int64, projectId int64) *InventoryItemsListCall {
35327 c := &InventoryItemsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
35328 c.profileId = profileId
35329 c.projectId = projectId
35330 return c
35331 }
35332
35333
35334
35335 func (c *InventoryItemsListCall) Ids(ids ...int64) *InventoryItemsListCall {
35336 var ids_ []string
35337 for _, v := range ids {
35338 ids_ = append(ids_, fmt.Sprint(v))
35339 }
35340 c.urlParams_.SetMulti("ids", ids_)
35341 return c
35342 }
35343
35344
35345
35346 func (c *InventoryItemsListCall) InPlan(inPlan bool) *InventoryItemsListCall {
35347 c.urlParams_.Set("inPlan", fmt.Sprint(inPlan))
35348 return c
35349 }
35350
35351
35352
35353 func (c *InventoryItemsListCall) MaxResults(maxResults int64) *InventoryItemsListCall {
35354 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
35355 return c
35356 }
35357
35358
35359
35360 func (c *InventoryItemsListCall) OrderId(orderId ...int64) *InventoryItemsListCall {
35361 var orderId_ []string
35362 for _, v := range orderId {
35363 orderId_ = append(orderId_, fmt.Sprint(v))
35364 }
35365 c.urlParams_.SetMulti("orderId", orderId_)
35366 return c
35367 }
35368
35369
35370
35371 func (c *InventoryItemsListCall) PageToken(pageToken string) *InventoryItemsListCall {
35372 c.urlParams_.Set("pageToken", pageToken)
35373 return c
35374 }
35375
35376
35377
35378 func (c *InventoryItemsListCall) SiteId(siteId ...int64) *InventoryItemsListCall {
35379 var siteId_ []string
35380 for _, v := range siteId {
35381 siteId_ = append(siteId_, fmt.Sprint(v))
35382 }
35383 c.urlParams_.SetMulti("siteId", siteId_)
35384 return c
35385 }
35386
35387
35388
35389
35390
35391
35392
35393
35394 func (c *InventoryItemsListCall) SortField(sortField string) *InventoryItemsListCall {
35395 c.urlParams_.Set("sortField", sortField)
35396 return c
35397 }
35398
35399
35400
35401
35402
35403
35404
35405
35406 func (c *InventoryItemsListCall) SortOrder(sortOrder string) *InventoryItemsListCall {
35407 c.urlParams_.Set("sortOrder", sortOrder)
35408 return c
35409 }
35410
35411
35412
35413
35414
35415
35416
35417
35418 func (c *InventoryItemsListCall) Type(type_ string) *InventoryItemsListCall {
35419 c.urlParams_.Set("type", type_)
35420 return c
35421 }
35422
35423
35424
35425
35426 func (c *InventoryItemsListCall) Fields(s ...googleapi.Field) *InventoryItemsListCall {
35427 c.urlParams_.Set("fields", googleapi.CombineFields(s))
35428 return c
35429 }
35430
35431
35432
35433
35434
35435
35436 func (c *InventoryItemsListCall) IfNoneMatch(entityTag string) *InventoryItemsListCall {
35437 c.ifNoneMatch_ = entityTag
35438 return c
35439 }
35440
35441
35442
35443
35444 func (c *InventoryItemsListCall) Context(ctx context.Context) *InventoryItemsListCall {
35445 c.ctx_ = ctx
35446 return c
35447 }
35448
35449
35450
35451 func (c *InventoryItemsListCall) Header() http.Header {
35452 if c.header_ == nil {
35453 c.header_ = make(http.Header)
35454 }
35455 return c.header_
35456 }
35457
35458 func (c *InventoryItemsListCall) doRequest(alt string) (*http.Response, error) {
35459 reqHeaders := make(http.Header)
35460 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
35461 for k, v := range c.header_ {
35462 reqHeaders[k] = v
35463 }
35464 reqHeaders.Set("User-Agent", c.s.userAgent())
35465 if c.ifNoneMatch_ != "" {
35466 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
35467 }
35468 var body io.Reader = nil
35469 c.urlParams_.Set("alt", alt)
35470 c.urlParams_.Set("prettyPrint", "false")
35471 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/projects/{projectId}/inventoryItems")
35472 urls += "?" + c.urlParams_.Encode()
35473 req, err := http.NewRequest("GET", urls, body)
35474 if err != nil {
35475 return nil, err
35476 }
35477 req.Header = reqHeaders
35478 googleapi.Expand(req.URL, map[string]string{
35479 "profileId": strconv.FormatInt(c.profileId, 10),
35480 "projectId": strconv.FormatInt(c.projectId, 10),
35481 })
35482 return gensupport.SendRequest(c.ctx_, c.s.client, req)
35483 }
35484
35485
35486
35487
35488
35489
35490
35491
35492 func (c *InventoryItemsListCall) Do(opts ...googleapi.CallOption) (*InventoryItemsListResponse, error) {
35493 gensupport.SetOptions(c.urlParams_, opts...)
35494 res, err := c.doRequest("json")
35495 if res != nil && res.StatusCode == http.StatusNotModified {
35496 if res.Body != nil {
35497 res.Body.Close()
35498 }
35499 return nil, &googleapi.Error{
35500 Code: res.StatusCode,
35501 Header: res.Header,
35502 }
35503 }
35504 if err != nil {
35505 return nil, err
35506 }
35507 defer googleapi.CloseBody(res)
35508 if err := googleapi.CheckResponse(res); err != nil {
35509 return nil, err
35510 }
35511 ret := &InventoryItemsListResponse{
35512 ServerResponse: googleapi.ServerResponse{
35513 Header: res.Header,
35514 HTTPStatusCode: res.StatusCode,
35515 },
35516 }
35517 target := &ret
35518 if err := gensupport.DecodeResponse(target, res); err != nil {
35519 return nil, err
35520 }
35521 return ret, nil
35522
35523
35524
35525
35526
35527
35528
35529
35530
35531
35532
35533
35534
35535
35536
35537
35538
35539
35540
35541
35542
35543
35544
35545
35546
35547
35548
35549
35550
35551
35552
35553
35554
35555
35556
35557
35558
35559
35560
35561
35562
35563
35564
35565
35566
35567
35568
35569
35570
35571
35572
35573
35574
35575
35576
35577
35578
35579
35580
35581
35582
35583
35584
35585
35586
35587
35588
35589
35590
35591
35592
35593
35594
35595
35596
35597
35598
35599
35600
35601
35602
35603
35604
35605
35606
35607
35608
35609
35610
35611
35612
35613
35614
35615
35616
35617
35618
35619
35620
35621
35622
35623
35624
35625
35626
35627
35628
35629
35630
35631
35632
35633
35634
35635
35636 }
35637
35638
35639
35640
35641 func (c *InventoryItemsListCall) Pages(ctx context.Context, f func(*InventoryItemsListResponse) error) error {
35642 c.ctx_ = ctx
35643 defer c.PageToken(c.urlParams_.Get("pageToken"))
35644 for {
35645 x, err := c.Do()
35646 if err != nil {
35647 return err
35648 }
35649 if err := f(x); err != nil {
35650 return err
35651 }
35652 if x.NextPageToken == "" {
35653 return nil
35654 }
35655 c.PageToken(x.NextPageToken)
35656 }
35657 }
35658
35659
35660
35661 type LanguagesListCall struct {
35662 s *Service
35663 profileId int64
35664 urlParams_ gensupport.URLParams
35665 ifNoneMatch_ string
35666 ctx_ context.Context
35667 header_ http.Header
35668 }
35669
35670
35671 func (r *LanguagesService) List(profileId int64) *LanguagesListCall {
35672 c := &LanguagesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
35673 c.profileId = profileId
35674 return c
35675 }
35676
35677
35678
35679
35680 func (c *LanguagesListCall) Fields(s ...googleapi.Field) *LanguagesListCall {
35681 c.urlParams_.Set("fields", googleapi.CombineFields(s))
35682 return c
35683 }
35684
35685
35686
35687
35688
35689
35690 func (c *LanguagesListCall) IfNoneMatch(entityTag string) *LanguagesListCall {
35691 c.ifNoneMatch_ = entityTag
35692 return c
35693 }
35694
35695
35696
35697
35698 func (c *LanguagesListCall) Context(ctx context.Context) *LanguagesListCall {
35699 c.ctx_ = ctx
35700 return c
35701 }
35702
35703
35704
35705 func (c *LanguagesListCall) Header() http.Header {
35706 if c.header_ == nil {
35707 c.header_ = make(http.Header)
35708 }
35709 return c.header_
35710 }
35711
35712 func (c *LanguagesListCall) doRequest(alt string) (*http.Response, error) {
35713 reqHeaders := make(http.Header)
35714 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
35715 for k, v := range c.header_ {
35716 reqHeaders[k] = v
35717 }
35718 reqHeaders.Set("User-Agent", c.s.userAgent())
35719 if c.ifNoneMatch_ != "" {
35720 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
35721 }
35722 var body io.Reader = nil
35723 c.urlParams_.Set("alt", alt)
35724 c.urlParams_.Set("prettyPrint", "false")
35725 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/languages")
35726 urls += "?" + c.urlParams_.Encode()
35727 req, err := http.NewRequest("GET", urls, body)
35728 if err != nil {
35729 return nil, err
35730 }
35731 req.Header = reqHeaders
35732 googleapi.Expand(req.URL, map[string]string{
35733 "profileId": strconv.FormatInt(c.profileId, 10),
35734 })
35735 return gensupport.SendRequest(c.ctx_, c.s.client, req)
35736 }
35737
35738
35739
35740
35741
35742
35743
35744
35745 func (c *LanguagesListCall) Do(opts ...googleapi.CallOption) (*LanguagesListResponse, error) {
35746 gensupport.SetOptions(c.urlParams_, opts...)
35747 res, err := c.doRequest("json")
35748 if res != nil && res.StatusCode == http.StatusNotModified {
35749 if res.Body != nil {
35750 res.Body.Close()
35751 }
35752 return nil, &googleapi.Error{
35753 Code: res.StatusCode,
35754 Header: res.Header,
35755 }
35756 }
35757 if err != nil {
35758 return nil, err
35759 }
35760 defer googleapi.CloseBody(res)
35761 if err := googleapi.CheckResponse(res); err != nil {
35762 return nil, err
35763 }
35764 ret := &LanguagesListResponse{
35765 ServerResponse: googleapi.ServerResponse{
35766 Header: res.Header,
35767 HTTPStatusCode: res.StatusCode,
35768 },
35769 }
35770 target := &ret
35771 if err := gensupport.DecodeResponse(target, res); err != nil {
35772 return nil, err
35773 }
35774 return ret, nil
35775
35776
35777
35778
35779
35780
35781
35782
35783
35784
35785
35786
35787
35788
35789
35790
35791
35792
35793
35794
35795
35796
35797
35798
35799
35800 }
35801
35802
35803
35804 type MetrosListCall struct {
35805 s *Service
35806 profileId int64
35807 urlParams_ gensupport.URLParams
35808 ifNoneMatch_ string
35809 ctx_ context.Context
35810 header_ http.Header
35811 }
35812
35813
35814 func (r *MetrosService) List(profileId int64) *MetrosListCall {
35815 c := &MetrosListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
35816 c.profileId = profileId
35817 return c
35818 }
35819
35820
35821
35822
35823 func (c *MetrosListCall) Fields(s ...googleapi.Field) *MetrosListCall {
35824 c.urlParams_.Set("fields", googleapi.CombineFields(s))
35825 return c
35826 }
35827
35828
35829
35830
35831
35832
35833 func (c *MetrosListCall) IfNoneMatch(entityTag string) *MetrosListCall {
35834 c.ifNoneMatch_ = entityTag
35835 return c
35836 }
35837
35838
35839
35840
35841 func (c *MetrosListCall) Context(ctx context.Context) *MetrosListCall {
35842 c.ctx_ = ctx
35843 return c
35844 }
35845
35846
35847
35848 func (c *MetrosListCall) Header() http.Header {
35849 if c.header_ == nil {
35850 c.header_ = make(http.Header)
35851 }
35852 return c.header_
35853 }
35854
35855 func (c *MetrosListCall) doRequest(alt string) (*http.Response, error) {
35856 reqHeaders := make(http.Header)
35857 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
35858 for k, v := range c.header_ {
35859 reqHeaders[k] = v
35860 }
35861 reqHeaders.Set("User-Agent", c.s.userAgent())
35862 if c.ifNoneMatch_ != "" {
35863 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
35864 }
35865 var body io.Reader = nil
35866 c.urlParams_.Set("alt", alt)
35867 c.urlParams_.Set("prettyPrint", "false")
35868 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/metros")
35869 urls += "?" + c.urlParams_.Encode()
35870 req, err := http.NewRequest("GET", urls, body)
35871 if err != nil {
35872 return nil, err
35873 }
35874 req.Header = reqHeaders
35875 googleapi.Expand(req.URL, map[string]string{
35876 "profileId": strconv.FormatInt(c.profileId, 10),
35877 })
35878 return gensupport.SendRequest(c.ctx_, c.s.client, req)
35879 }
35880
35881
35882
35883
35884
35885
35886
35887
35888 func (c *MetrosListCall) Do(opts ...googleapi.CallOption) (*MetrosListResponse, error) {
35889 gensupport.SetOptions(c.urlParams_, opts...)
35890 res, err := c.doRequest("json")
35891 if res != nil && res.StatusCode == http.StatusNotModified {
35892 if res.Body != nil {
35893 res.Body.Close()
35894 }
35895 return nil, &googleapi.Error{
35896 Code: res.StatusCode,
35897 Header: res.Header,
35898 }
35899 }
35900 if err != nil {
35901 return nil, err
35902 }
35903 defer googleapi.CloseBody(res)
35904 if err := googleapi.CheckResponse(res); err != nil {
35905 return nil, err
35906 }
35907 ret := &MetrosListResponse{
35908 ServerResponse: googleapi.ServerResponse{
35909 Header: res.Header,
35910 HTTPStatusCode: res.StatusCode,
35911 },
35912 }
35913 target := &ret
35914 if err := gensupport.DecodeResponse(target, res); err != nil {
35915 return nil, err
35916 }
35917 return ret, nil
35918
35919
35920
35921
35922
35923
35924
35925
35926
35927
35928
35929
35930
35931
35932
35933
35934
35935
35936
35937
35938
35939
35940
35941
35942
35943 }
35944
35945
35946
35947 type MobileAppsGetCall struct {
35948 s *Service
35949 profileId int64
35950 id string
35951 urlParams_ gensupport.URLParams
35952 ifNoneMatch_ string
35953 ctx_ context.Context
35954 header_ http.Header
35955 }
35956
35957
35958 func (r *MobileAppsService) Get(profileId int64, id string) *MobileAppsGetCall {
35959 c := &MobileAppsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
35960 c.profileId = profileId
35961 c.id = id
35962 return c
35963 }
35964
35965
35966
35967
35968 func (c *MobileAppsGetCall) Fields(s ...googleapi.Field) *MobileAppsGetCall {
35969 c.urlParams_.Set("fields", googleapi.CombineFields(s))
35970 return c
35971 }
35972
35973
35974
35975
35976
35977
35978 func (c *MobileAppsGetCall) IfNoneMatch(entityTag string) *MobileAppsGetCall {
35979 c.ifNoneMatch_ = entityTag
35980 return c
35981 }
35982
35983
35984
35985
35986 func (c *MobileAppsGetCall) Context(ctx context.Context) *MobileAppsGetCall {
35987 c.ctx_ = ctx
35988 return c
35989 }
35990
35991
35992
35993 func (c *MobileAppsGetCall) Header() http.Header {
35994 if c.header_ == nil {
35995 c.header_ = make(http.Header)
35996 }
35997 return c.header_
35998 }
35999
36000 func (c *MobileAppsGetCall) doRequest(alt string) (*http.Response, error) {
36001 reqHeaders := make(http.Header)
36002 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
36003 for k, v := range c.header_ {
36004 reqHeaders[k] = v
36005 }
36006 reqHeaders.Set("User-Agent", c.s.userAgent())
36007 if c.ifNoneMatch_ != "" {
36008 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
36009 }
36010 var body io.Reader = nil
36011 c.urlParams_.Set("alt", alt)
36012 c.urlParams_.Set("prettyPrint", "false")
36013 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/mobileApps/{id}")
36014 urls += "?" + c.urlParams_.Encode()
36015 req, err := http.NewRequest("GET", urls, body)
36016 if err != nil {
36017 return nil, err
36018 }
36019 req.Header = reqHeaders
36020 googleapi.Expand(req.URL, map[string]string{
36021 "profileId": strconv.FormatInt(c.profileId, 10),
36022 "id": c.id,
36023 })
36024 return gensupport.SendRequest(c.ctx_, c.s.client, req)
36025 }
36026
36027
36028
36029
36030
36031
36032
36033
36034 func (c *MobileAppsGetCall) Do(opts ...googleapi.CallOption) (*MobileApp, error) {
36035 gensupport.SetOptions(c.urlParams_, opts...)
36036 res, err := c.doRequest("json")
36037 if res != nil && res.StatusCode == http.StatusNotModified {
36038 if res.Body != nil {
36039 res.Body.Close()
36040 }
36041 return nil, &googleapi.Error{
36042 Code: res.StatusCode,
36043 Header: res.Header,
36044 }
36045 }
36046 if err != nil {
36047 return nil, err
36048 }
36049 defer googleapi.CloseBody(res)
36050 if err := googleapi.CheckResponse(res); err != nil {
36051 return nil, err
36052 }
36053 ret := &MobileApp{
36054 ServerResponse: googleapi.ServerResponse{
36055 Header: res.Header,
36056 HTTPStatusCode: res.StatusCode,
36057 },
36058 }
36059 target := &ret
36060 if err := gensupport.DecodeResponse(target, res); err != nil {
36061 return nil, err
36062 }
36063 return ret, nil
36064
36065
36066
36067
36068
36069
36070
36071
36072
36073
36074
36075
36076
36077
36078
36079
36080
36081
36082
36083
36084
36085
36086
36087
36088
36089
36090
36091
36092
36093
36094
36095
36096 }
36097
36098
36099
36100 type MobileAppsListCall struct {
36101 s *Service
36102 profileId int64
36103 urlParams_ gensupport.URLParams
36104 ifNoneMatch_ string
36105 ctx_ context.Context
36106 header_ http.Header
36107 }
36108
36109
36110 func (r *MobileAppsService) List(profileId int64) *MobileAppsListCall {
36111 c := &MobileAppsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
36112 c.profileId = profileId
36113 return c
36114 }
36115
36116
36117
36118
36119
36120
36121
36122
36123
36124 func (c *MobileAppsListCall) Directories(directories ...string) *MobileAppsListCall {
36125 c.urlParams_.SetMulti("directories", append([]string{}, directories...))
36126 return c
36127 }
36128
36129
36130
36131 func (c *MobileAppsListCall) Ids(ids ...string) *MobileAppsListCall {
36132 c.urlParams_.SetMulti("ids", append([]string{}, ids...))
36133 return c
36134 }
36135
36136
36137
36138 func (c *MobileAppsListCall) MaxResults(maxResults int64) *MobileAppsListCall {
36139 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
36140 return c
36141 }
36142
36143
36144
36145 func (c *MobileAppsListCall) PageToken(pageToken string) *MobileAppsListCall {
36146 c.urlParams_.Set("pageToken", pageToken)
36147 return c
36148 }
36149
36150
36151
36152
36153
36154
36155
36156
36157 func (c *MobileAppsListCall) SearchString(searchString string) *MobileAppsListCall {
36158 c.urlParams_.Set("searchString", searchString)
36159 return c
36160 }
36161
36162
36163
36164
36165 func (c *MobileAppsListCall) Fields(s ...googleapi.Field) *MobileAppsListCall {
36166 c.urlParams_.Set("fields", googleapi.CombineFields(s))
36167 return c
36168 }
36169
36170
36171
36172
36173
36174
36175 func (c *MobileAppsListCall) IfNoneMatch(entityTag string) *MobileAppsListCall {
36176 c.ifNoneMatch_ = entityTag
36177 return c
36178 }
36179
36180
36181
36182
36183 func (c *MobileAppsListCall) Context(ctx context.Context) *MobileAppsListCall {
36184 c.ctx_ = ctx
36185 return c
36186 }
36187
36188
36189
36190 func (c *MobileAppsListCall) Header() http.Header {
36191 if c.header_ == nil {
36192 c.header_ = make(http.Header)
36193 }
36194 return c.header_
36195 }
36196
36197 func (c *MobileAppsListCall) doRequest(alt string) (*http.Response, error) {
36198 reqHeaders := make(http.Header)
36199 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
36200 for k, v := range c.header_ {
36201 reqHeaders[k] = v
36202 }
36203 reqHeaders.Set("User-Agent", c.s.userAgent())
36204 if c.ifNoneMatch_ != "" {
36205 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
36206 }
36207 var body io.Reader = nil
36208 c.urlParams_.Set("alt", alt)
36209 c.urlParams_.Set("prettyPrint", "false")
36210 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/mobileApps")
36211 urls += "?" + c.urlParams_.Encode()
36212 req, err := http.NewRequest("GET", urls, body)
36213 if err != nil {
36214 return nil, err
36215 }
36216 req.Header = reqHeaders
36217 googleapi.Expand(req.URL, map[string]string{
36218 "profileId": strconv.FormatInt(c.profileId, 10),
36219 })
36220 return gensupport.SendRequest(c.ctx_, c.s.client, req)
36221 }
36222
36223
36224
36225
36226
36227
36228
36229
36230 func (c *MobileAppsListCall) Do(opts ...googleapi.CallOption) (*MobileAppsListResponse, error) {
36231 gensupport.SetOptions(c.urlParams_, opts...)
36232 res, err := c.doRequest("json")
36233 if res != nil && res.StatusCode == http.StatusNotModified {
36234 if res.Body != nil {
36235 res.Body.Close()
36236 }
36237 return nil, &googleapi.Error{
36238 Code: res.StatusCode,
36239 Header: res.Header,
36240 }
36241 }
36242 if err != nil {
36243 return nil, err
36244 }
36245 defer googleapi.CloseBody(res)
36246 if err := googleapi.CheckResponse(res); err != nil {
36247 return nil, err
36248 }
36249 ret := &MobileAppsListResponse{
36250 ServerResponse: googleapi.ServerResponse{
36251 Header: res.Header,
36252 HTTPStatusCode: res.StatusCode,
36253 },
36254 }
36255 target := &ret
36256 if err := gensupport.DecodeResponse(target, res); err != nil {
36257 return nil, err
36258 }
36259 return ret, nil
36260
36261
36262
36263
36264
36265
36266
36267
36268
36269
36270
36271
36272
36273
36274
36275
36276
36277
36278
36279
36280
36281
36282
36283
36284
36285
36286
36287
36288
36289
36290
36291
36292
36293
36294
36295
36296
36297
36298
36299
36300
36301
36302
36303
36304
36305
36306
36307
36308
36309
36310
36311
36312
36313
36314
36315
36316
36317
36318
36319
36320
36321
36322
36323
36324
36325
36326 }
36327
36328
36329
36330
36331 func (c *MobileAppsListCall) Pages(ctx context.Context, f func(*MobileAppsListResponse) error) error {
36332 c.ctx_ = ctx
36333 defer c.PageToken(c.urlParams_.Get("pageToken"))
36334 for {
36335 x, err := c.Do()
36336 if err != nil {
36337 return err
36338 }
36339 if err := f(x); err != nil {
36340 return err
36341 }
36342 if x.NextPageToken == "" {
36343 return nil
36344 }
36345 c.PageToken(x.NextPageToken)
36346 }
36347 }
36348
36349
36350
36351 type MobileCarriersGetCall struct {
36352 s *Service
36353 profileId int64
36354 id int64
36355 urlParams_ gensupport.URLParams
36356 ifNoneMatch_ string
36357 ctx_ context.Context
36358 header_ http.Header
36359 }
36360
36361
36362 func (r *MobileCarriersService) Get(profileId int64, id int64) *MobileCarriersGetCall {
36363 c := &MobileCarriersGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
36364 c.profileId = profileId
36365 c.id = id
36366 return c
36367 }
36368
36369
36370
36371
36372 func (c *MobileCarriersGetCall) Fields(s ...googleapi.Field) *MobileCarriersGetCall {
36373 c.urlParams_.Set("fields", googleapi.CombineFields(s))
36374 return c
36375 }
36376
36377
36378
36379
36380
36381
36382 func (c *MobileCarriersGetCall) IfNoneMatch(entityTag string) *MobileCarriersGetCall {
36383 c.ifNoneMatch_ = entityTag
36384 return c
36385 }
36386
36387
36388
36389
36390 func (c *MobileCarriersGetCall) Context(ctx context.Context) *MobileCarriersGetCall {
36391 c.ctx_ = ctx
36392 return c
36393 }
36394
36395
36396
36397 func (c *MobileCarriersGetCall) Header() http.Header {
36398 if c.header_ == nil {
36399 c.header_ = make(http.Header)
36400 }
36401 return c.header_
36402 }
36403
36404 func (c *MobileCarriersGetCall) doRequest(alt string) (*http.Response, error) {
36405 reqHeaders := make(http.Header)
36406 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
36407 for k, v := range c.header_ {
36408 reqHeaders[k] = v
36409 }
36410 reqHeaders.Set("User-Agent", c.s.userAgent())
36411 if c.ifNoneMatch_ != "" {
36412 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
36413 }
36414 var body io.Reader = nil
36415 c.urlParams_.Set("alt", alt)
36416 c.urlParams_.Set("prettyPrint", "false")
36417 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/mobileCarriers/{id}")
36418 urls += "?" + c.urlParams_.Encode()
36419 req, err := http.NewRequest("GET", urls, body)
36420 if err != nil {
36421 return nil, err
36422 }
36423 req.Header = reqHeaders
36424 googleapi.Expand(req.URL, map[string]string{
36425 "profileId": strconv.FormatInt(c.profileId, 10),
36426 "id": strconv.FormatInt(c.id, 10),
36427 })
36428 return gensupport.SendRequest(c.ctx_, c.s.client, req)
36429 }
36430
36431
36432
36433
36434
36435
36436
36437
36438 func (c *MobileCarriersGetCall) Do(opts ...googleapi.CallOption) (*MobileCarrier, error) {
36439 gensupport.SetOptions(c.urlParams_, opts...)
36440 res, err := c.doRequest("json")
36441 if res != nil && res.StatusCode == http.StatusNotModified {
36442 if res.Body != nil {
36443 res.Body.Close()
36444 }
36445 return nil, &googleapi.Error{
36446 Code: res.StatusCode,
36447 Header: res.Header,
36448 }
36449 }
36450 if err != nil {
36451 return nil, err
36452 }
36453 defer googleapi.CloseBody(res)
36454 if err := googleapi.CheckResponse(res); err != nil {
36455 return nil, err
36456 }
36457 ret := &MobileCarrier{
36458 ServerResponse: googleapi.ServerResponse{
36459 Header: res.Header,
36460 HTTPStatusCode: res.StatusCode,
36461 },
36462 }
36463 target := &ret
36464 if err := gensupport.DecodeResponse(target, res); err != nil {
36465 return nil, err
36466 }
36467 return ret, nil
36468
36469
36470
36471
36472
36473
36474
36475
36476
36477
36478
36479
36480
36481
36482
36483
36484
36485
36486
36487
36488
36489
36490
36491
36492
36493
36494
36495
36496
36497
36498
36499
36500
36501 }
36502
36503
36504
36505 type MobileCarriersListCall struct {
36506 s *Service
36507 profileId int64
36508 urlParams_ gensupport.URLParams
36509 ifNoneMatch_ string
36510 ctx_ context.Context
36511 header_ http.Header
36512 }
36513
36514
36515 func (r *MobileCarriersService) List(profileId int64) *MobileCarriersListCall {
36516 c := &MobileCarriersListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
36517 c.profileId = profileId
36518 return c
36519 }
36520
36521
36522
36523
36524 func (c *MobileCarriersListCall) Fields(s ...googleapi.Field) *MobileCarriersListCall {
36525 c.urlParams_.Set("fields", googleapi.CombineFields(s))
36526 return c
36527 }
36528
36529
36530
36531
36532
36533
36534 func (c *MobileCarriersListCall) IfNoneMatch(entityTag string) *MobileCarriersListCall {
36535 c.ifNoneMatch_ = entityTag
36536 return c
36537 }
36538
36539
36540
36541
36542 func (c *MobileCarriersListCall) Context(ctx context.Context) *MobileCarriersListCall {
36543 c.ctx_ = ctx
36544 return c
36545 }
36546
36547
36548
36549 func (c *MobileCarriersListCall) Header() http.Header {
36550 if c.header_ == nil {
36551 c.header_ = make(http.Header)
36552 }
36553 return c.header_
36554 }
36555
36556 func (c *MobileCarriersListCall) doRequest(alt string) (*http.Response, error) {
36557 reqHeaders := make(http.Header)
36558 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
36559 for k, v := range c.header_ {
36560 reqHeaders[k] = v
36561 }
36562 reqHeaders.Set("User-Agent", c.s.userAgent())
36563 if c.ifNoneMatch_ != "" {
36564 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
36565 }
36566 var body io.Reader = nil
36567 c.urlParams_.Set("alt", alt)
36568 c.urlParams_.Set("prettyPrint", "false")
36569 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/mobileCarriers")
36570 urls += "?" + c.urlParams_.Encode()
36571 req, err := http.NewRequest("GET", urls, body)
36572 if err != nil {
36573 return nil, err
36574 }
36575 req.Header = reqHeaders
36576 googleapi.Expand(req.URL, map[string]string{
36577 "profileId": strconv.FormatInt(c.profileId, 10),
36578 })
36579 return gensupport.SendRequest(c.ctx_, c.s.client, req)
36580 }
36581
36582
36583
36584
36585
36586
36587
36588
36589 func (c *MobileCarriersListCall) Do(opts ...googleapi.CallOption) (*MobileCarriersListResponse, error) {
36590 gensupport.SetOptions(c.urlParams_, opts...)
36591 res, err := c.doRequest("json")
36592 if res != nil && res.StatusCode == http.StatusNotModified {
36593 if res.Body != nil {
36594 res.Body.Close()
36595 }
36596 return nil, &googleapi.Error{
36597 Code: res.StatusCode,
36598 Header: res.Header,
36599 }
36600 }
36601 if err != nil {
36602 return nil, err
36603 }
36604 defer googleapi.CloseBody(res)
36605 if err := googleapi.CheckResponse(res); err != nil {
36606 return nil, err
36607 }
36608 ret := &MobileCarriersListResponse{
36609 ServerResponse: googleapi.ServerResponse{
36610 Header: res.Header,
36611 HTTPStatusCode: res.StatusCode,
36612 },
36613 }
36614 target := &ret
36615 if err := gensupport.DecodeResponse(target, res); err != nil {
36616 return nil, err
36617 }
36618 return ret, nil
36619
36620
36621
36622
36623
36624
36625
36626
36627
36628
36629
36630
36631
36632
36633
36634
36635
36636
36637
36638
36639
36640
36641
36642
36643
36644 }
36645
36646
36647
36648 type OperatingSystemVersionsGetCall struct {
36649 s *Service
36650 profileId int64
36651 id int64
36652 urlParams_ gensupport.URLParams
36653 ifNoneMatch_ string
36654 ctx_ context.Context
36655 header_ http.Header
36656 }
36657
36658
36659 func (r *OperatingSystemVersionsService) Get(profileId int64, id int64) *OperatingSystemVersionsGetCall {
36660 c := &OperatingSystemVersionsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
36661 c.profileId = profileId
36662 c.id = id
36663 return c
36664 }
36665
36666
36667
36668
36669 func (c *OperatingSystemVersionsGetCall) Fields(s ...googleapi.Field) *OperatingSystemVersionsGetCall {
36670 c.urlParams_.Set("fields", googleapi.CombineFields(s))
36671 return c
36672 }
36673
36674
36675
36676
36677
36678
36679 func (c *OperatingSystemVersionsGetCall) IfNoneMatch(entityTag string) *OperatingSystemVersionsGetCall {
36680 c.ifNoneMatch_ = entityTag
36681 return c
36682 }
36683
36684
36685
36686
36687 func (c *OperatingSystemVersionsGetCall) Context(ctx context.Context) *OperatingSystemVersionsGetCall {
36688 c.ctx_ = ctx
36689 return c
36690 }
36691
36692
36693
36694 func (c *OperatingSystemVersionsGetCall) Header() http.Header {
36695 if c.header_ == nil {
36696 c.header_ = make(http.Header)
36697 }
36698 return c.header_
36699 }
36700
36701 func (c *OperatingSystemVersionsGetCall) doRequest(alt string) (*http.Response, error) {
36702 reqHeaders := make(http.Header)
36703 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
36704 for k, v := range c.header_ {
36705 reqHeaders[k] = v
36706 }
36707 reqHeaders.Set("User-Agent", c.s.userAgent())
36708 if c.ifNoneMatch_ != "" {
36709 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
36710 }
36711 var body io.Reader = nil
36712 c.urlParams_.Set("alt", alt)
36713 c.urlParams_.Set("prettyPrint", "false")
36714 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/operatingSystemVersions/{id}")
36715 urls += "?" + c.urlParams_.Encode()
36716 req, err := http.NewRequest("GET", urls, body)
36717 if err != nil {
36718 return nil, err
36719 }
36720 req.Header = reqHeaders
36721 googleapi.Expand(req.URL, map[string]string{
36722 "profileId": strconv.FormatInt(c.profileId, 10),
36723 "id": strconv.FormatInt(c.id, 10),
36724 })
36725 return gensupport.SendRequest(c.ctx_, c.s.client, req)
36726 }
36727
36728
36729
36730
36731
36732
36733
36734
36735 func (c *OperatingSystemVersionsGetCall) Do(opts ...googleapi.CallOption) (*OperatingSystemVersion, error) {
36736 gensupport.SetOptions(c.urlParams_, opts...)
36737 res, err := c.doRequest("json")
36738 if res != nil && res.StatusCode == http.StatusNotModified {
36739 if res.Body != nil {
36740 res.Body.Close()
36741 }
36742 return nil, &googleapi.Error{
36743 Code: res.StatusCode,
36744 Header: res.Header,
36745 }
36746 }
36747 if err != nil {
36748 return nil, err
36749 }
36750 defer googleapi.CloseBody(res)
36751 if err := googleapi.CheckResponse(res); err != nil {
36752 return nil, err
36753 }
36754 ret := &OperatingSystemVersion{
36755 ServerResponse: googleapi.ServerResponse{
36756 Header: res.Header,
36757 HTTPStatusCode: res.StatusCode,
36758 },
36759 }
36760 target := &ret
36761 if err := gensupport.DecodeResponse(target, res); err != nil {
36762 return nil, err
36763 }
36764 return ret, nil
36765
36766
36767
36768
36769
36770
36771
36772
36773
36774
36775
36776
36777
36778
36779
36780
36781
36782
36783
36784
36785
36786
36787
36788
36789
36790
36791
36792
36793
36794
36795
36796
36797
36798 }
36799
36800
36801
36802 type OperatingSystemVersionsListCall struct {
36803 s *Service
36804 profileId int64
36805 urlParams_ gensupport.URLParams
36806 ifNoneMatch_ string
36807 ctx_ context.Context
36808 header_ http.Header
36809 }
36810
36811
36812 func (r *OperatingSystemVersionsService) List(profileId int64) *OperatingSystemVersionsListCall {
36813 c := &OperatingSystemVersionsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
36814 c.profileId = profileId
36815 return c
36816 }
36817
36818
36819
36820
36821 func (c *OperatingSystemVersionsListCall) Fields(s ...googleapi.Field) *OperatingSystemVersionsListCall {
36822 c.urlParams_.Set("fields", googleapi.CombineFields(s))
36823 return c
36824 }
36825
36826
36827
36828
36829
36830
36831 func (c *OperatingSystemVersionsListCall) IfNoneMatch(entityTag string) *OperatingSystemVersionsListCall {
36832 c.ifNoneMatch_ = entityTag
36833 return c
36834 }
36835
36836
36837
36838
36839 func (c *OperatingSystemVersionsListCall) Context(ctx context.Context) *OperatingSystemVersionsListCall {
36840 c.ctx_ = ctx
36841 return c
36842 }
36843
36844
36845
36846 func (c *OperatingSystemVersionsListCall) Header() http.Header {
36847 if c.header_ == nil {
36848 c.header_ = make(http.Header)
36849 }
36850 return c.header_
36851 }
36852
36853 func (c *OperatingSystemVersionsListCall) doRequest(alt string) (*http.Response, error) {
36854 reqHeaders := make(http.Header)
36855 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
36856 for k, v := range c.header_ {
36857 reqHeaders[k] = v
36858 }
36859 reqHeaders.Set("User-Agent", c.s.userAgent())
36860 if c.ifNoneMatch_ != "" {
36861 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
36862 }
36863 var body io.Reader = nil
36864 c.urlParams_.Set("alt", alt)
36865 c.urlParams_.Set("prettyPrint", "false")
36866 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/operatingSystemVersions")
36867 urls += "?" + c.urlParams_.Encode()
36868 req, err := http.NewRequest("GET", urls, body)
36869 if err != nil {
36870 return nil, err
36871 }
36872 req.Header = reqHeaders
36873 googleapi.Expand(req.URL, map[string]string{
36874 "profileId": strconv.FormatInt(c.profileId, 10),
36875 })
36876 return gensupport.SendRequest(c.ctx_, c.s.client, req)
36877 }
36878
36879
36880
36881
36882
36883
36884
36885
36886
36887 func (c *OperatingSystemVersionsListCall) Do(opts ...googleapi.CallOption) (*OperatingSystemVersionsListResponse, error) {
36888 gensupport.SetOptions(c.urlParams_, opts...)
36889 res, err := c.doRequest("json")
36890 if res != nil && res.StatusCode == http.StatusNotModified {
36891 if res.Body != nil {
36892 res.Body.Close()
36893 }
36894 return nil, &googleapi.Error{
36895 Code: res.StatusCode,
36896 Header: res.Header,
36897 }
36898 }
36899 if err != nil {
36900 return nil, err
36901 }
36902 defer googleapi.CloseBody(res)
36903 if err := googleapi.CheckResponse(res); err != nil {
36904 return nil, err
36905 }
36906 ret := &OperatingSystemVersionsListResponse{
36907 ServerResponse: googleapi.ServerResponse{
36908 Header: res.Header,
36909 HTTPStatusCode: res.StatusCode,
36910 },
36911 }
36912 target := &ret
36913 if err := gensupport.DecodeResponse(target, res); err != nil {
36914 return nil, err
36915 }
36916 return ret, nil
36917
36918
36919
36920
36921
36922
36923
36924
36925
36926
36927
36928
36929
36930
36931
36932
36933
36934
36935
36936
36937
36938
36939
36940
36941
36942 }
36943
36944
36945
36946 type OperatingSystemsGetCall struct {
36947 s *Service
36948 profileId int64
36949 dartId int64
36950 urlParams_ gensupport.URLParams
36951 ifNoneMatch_ string
36952 ctx_ context.Context
36953 header_ http.Header
36954 }
36955
36956
36957 func (r *OperatingSystemsService) Get(profileId int64, dartId int64) *OperatingSystemsGetCall {
36958 c := &OperatingSystemsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
36959 c.profileId = profileId
36960 c.dartId = dartId
36961 return c
36962 }
36963
36964
36965
36966
36967 func (c *OperatingSystemsGetCall) Fields(s ...googleapi.Field) *OperatingSystemsGetCall {
36968 c.urlParams_.Set("fields", googleapi.CombineFields(s))
36969 return c
36970 }
36971
36972
36973
36974
36975
36976
36977 func (c *OperatingSystemsGetCall) IfNoneMatch(entityTag string) *OperatingSystemsGetCall {
36978 c.ifNoneMatch_ = entityTag
36979 return c
36980 }
36981
36982
36983
36984
36985 func (c *OperatingSystemsGetCall) Context(ctx context.Context) *OperatingSystemsGetCall {
36986 c.ctx_ = ctx
36987 return c
36988 }
36989
36990
36991
36992 func (c *OperatingSystemsGetCall) Header() http.Header {
36993 if c.header_ == nil {
36994 c.header_ = make(http.Header)
36995 }
36996 return c.header_
36997 }
36998
36999 func (c *OperatingSystemsGetCall) doRequest(alt string) (*http.Response, error) {
37000 reqHeaders := make(http.Header)
37001 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
37002 for k, v := range c.header_ {
37003 reqHeaders[k] = v
37004 }
37005 reqHeaders.Set("User-Agent", c.s.userAgent())
37006 if c.ifNoneMatch_ != "" {
37007 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
37008 }
37009 var body io.Reader = nil
37010 c.urlParams_.Set("alt", alt)
37011 c.urlParams_.Set("prettyPrint", "false")
37012 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/operatingSystems/{dartId}")
37013 urls += "?" + c.urlParams_.Encode()
37014 req, err := http.NewRequest("GET", urls, body)
37015 if err != nil {
37016 return nil, err
37017 }
37018 req.Header = reqHeaders
37019 googleapi.Expand(req.URL, map[string]string{
37020 "profileId": strconv.FormatInt(c.profileId, 10),
37021 "dartId": strconv.FormatInt(c.dartId, 10),
37022 })
37023 return gensupport.SendRequest(c.ctx_, c.s.client, req)
37024 }
37025
37026
37027
37028
37029
37030
37031
37032
37033 func (c *OperatingSystemsGetCall) Do(opts ...googleapi.CallOption) (*OperatingSystem, error) {
37034 gensupport.SetOptions(c.urlParams_, opts...)
37035 res, err := c.doRequest("json")
37036 if res != nil && res.StatusCode == http.StatusNotModified {
37037 if res.Body != nil {
37038 res.Body.Close()
37039 }
37040 return nil, &googleapi.Error{
37041 Code: res.StatusCode,
37042 Header: res.Header,
37043 }
37044 }
37045 if err != nil {
37046 return nil, err
37047 }
37048 defer googleapi.CloseBody(res)
37049 if err := googleapi.CheckResponse(res); err != nil {
37050 return nil, err
37051 }
37052 ret := &OperatingSystem{
37053 ServerResponse: googleapi.ServerResponse{
37054 Header: res.Header,
37055 HTTPStatusCode: res.StatusCode,
37056 },
37057 }
37058 target := &ret
37059 if err := gensupport.DecodeResponse(target, res); err != nil {
37060 return nil, err
37061 }
37062 return ret, nil
37063
37064
37065
37066
37067
37068
37069
37070
37071
37072
37073
37074
37075
37076
37077
37078
37079
37080
37081
37082
37083
37084
37085
37086
37087
37088
37089
37090
37091
37092
37093
37094
37095
37096 }
37097
37098
37099
37100 type OperatingSystemsListCall struct {
37101 s *Service
37102 profileId int64
37103 urlParams_ gensupport.URLParams
37104 ifNoneMatch_ string
37105 ctx_ context.Context
37106 header_ http.Header
37107 }
37108
37109
37110 func (r *OperatingSystemsService) List(profileId int64) *OperatingSystemsListCall {
37111 c := &OperatingSystemsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
37112 c.profileId = profileId
37113 return c
37114 }
37115
37116
37117
37118
37119 func (c *OperatingSystemsListCall) Fields(s ...googleapi.Field) *OperatingSystemsListCall {
37120 c.urlParams_.Set("fields", googleapi.CombineFields(s))
37121 return c
37122 }
37123
37124
37125
37126
37127
37128
37129 func (c *OperatingSystemsListCall) IfNoneMatch(entityTag string) *OperatingSystemsListCall {
37130 c.ifNoneMatch_ = entityTag
37131 return c
37132 }
37133
37134
37135
37136
37137 func (c *OperatingSystemsListCall) Context(ctx context.Context) *OperatingSystemsListCall {
37138 c.ctx_ = ctx
37139 return c
37140 }
37141
37142
37143
37144 func (c *OperatingSystemsListCall) Header() http.Header {
37145 if c.header_ == nil {
37146 c.header_ = make(http.Header)
37147 }
37148 return c.header_
37149 }
37150
37151 func (c *OperatingSystemsListCall) doRequest(alt string) (*http.Response, error) {
37152 reqHeaders := make(http.Header)
37153 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
37154 for k, v := range c.header_ {
37155 reqHeaders[k] = v
37156 }
37157 reqHeaders.Set("User-Agent", c.s.userAgent())
37158 if c.ifNoneMatch_ != "" {
37159 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
37160 }
37161 var body io.Reader = nil
37162 c.urlParams_.Set("alt", alt)
37163 c.urlParams_.Set("prettyPrint", "false")
37164 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/operatingSystems")
37165 urls += "?" + c.urlParams_.Encode()
37166 req, err := http.NewRequest("GET", urls, body)
37167 if err != nil {
37168 return nil, err
37169 }
37170 req.Header = reqHeaders
37171 googleapi.Expand(req.URL, map[string]string{
37172 "profileId": strconv.FormatInt(c.profileId, 10),
37173 })
37174 return gensupport.SendRequest(c.ctx_, c.s.client, req)
37175 }
37176
37177
37178
37179
37180
37181
37182
37183
37184 func (c *OperatingSystemsListCall) Do(opts ...googleapi.CallOption) (*OperatingSystemsListResponse, error) {
37185 gensupport.SetOptions(c.urlParams_, opts...)
37186 res, err := c.doRequest("json")
37187 if res != nil && res.StatusCode == http.StatusNotModified {
37188 if res.Body != nil {
37189 res.Body.Close()
37190 }
37191 return nil, &googleapi.Error{
37192 Code: res.StatusCode,
37193 Header: res.Header,
37194 }
37195 }
37196 if err != nil {
37197 return nil, err
37198 }
37199 defer googleapi.CloseBody(res)
37200 if err := googleapi.CheckResponse(res); err != nil {
37201 return nil, err
37202 }
37203 ret := &OperatingSystemsListResponse{
37204 ServerResponse: googleapi.ServerResponse{
37205 Header: res.Header,
37206 HTTPStatusCode: res.StatusCode,
37207 },
37208 }
37209 target := &ret
37210 if err := gensupport.DecodeResponse(target, res); err != nil {
37211 return nil, err
37212 }
37213 return ret, nil
37214
37215
37216
37217
37218
37219
37220
37221
37222
37223
37224
37225
37226
37227
37228
37229
37230
37231
37232
37233
37234
37235
37236
37237
37238
37239 }
37240
37241
37242
37243 type OrderDocumentsGetCall struct {
37244 s *Service
37245 profileId int64
37246 projectId int64
37247 id int64
37248 urlParams_ gensupport.URLParams
37249 ifNoneMatch_ string
37250 ctx_ context.Context
37251 header_ http.Header
37252 }
37253
37254
37255 func (r *OrderDocumentsService) Get(profileId int64, projectId int64, id int64) *OrderDocumentsGetCall {
37256 c := &OrderDocumentsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
37257 c.profileId = profileId
37258 c.projectId = projectId
37259 c.id = id
37260 return c
37261 }
37262
37263
37264
37265
37266 func (c *OrderDocumentsGetCall) Fields(s ...googleapi.Field) *OrderDocumentsGetCall {
37267 c.urlParams_.Set("fields", googleapi.CombineFields(s))
37268 return c
37269 }
37270
37271
37272
37273
37274
37275
37276 func (c *OrderDocumentsGetCall) IfNoneMatch(entityTag string) *OrderDocumentsGetCall {
37277 c.ifNoneMatch_ = entityTag
37278 return c
37279 }
37280
37281
37282
37283
37284 func (c *OrderDocumentsGetCall) Context(ctx context.Context) *OrderDocumentsGetCall {
37285 c.ctx_ = ctx
37286 return c
37287 }
37288
37289
37290
37291 func (c *OrderDocumentsGetCall) Header() http.Header {
37292 if c.header_ == nil {
37293 c.header_ = make(http.Header)
37294 }
37295 return c.header_
37296 }
37297
37298 func (c *OrderDocumentsGetCall) doRequest(alt string) (*http.Response, error) {
37299 reqHeaders := make(http.Header)
37300 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
37301 for k, v := range c.header_ {
37302 reqHeaders[k] = v
37303 }
37304 reqHeaders.Set("User-Agent", c.s.userAgent())
37305 if c.ifNoneMatch_ != "" {
37306 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
37307 }
37308 var body io.Reader = nil
37309 c.urlParams_.Set("alt", alt)
37310 c.urlParams_.Set("prettyPrint", "false")
37311 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/projects/{projectId}/orderDocuments/{id}")
37312 urls += "?" + c.urlParams_.Encode()
37313 req, err := http.NewRequest("GET", urls, body)
37314 if err != nil {
37315 return nil, err
37316 }
37317 req.Header = reqHeaders
37318 googleapi.Expand(req.URL, map[string]string{
37319 "profileId": strconv.FormatInt(c.profileId, 10),
37320 "projectId": strconv.FormatInt(c.projectId, 10),
37321 "id": strconv.FormatInt(c.id, 10),
37322 })
37323 return gensupport.SendRequest(c.ctx_, c.s.client, req)
37324 }
37325
37326
37327
37328
37329
37330
37331
37332
37333 func (c *OrderDocumentsGetCall) Do(opts ...googleapi.CallOption) (*OrderDocument, error) {
37334 gensupport.SetOptions(c.urlParams_, opts...)
37335 res, err := c.doRequest("json")
37336 if res != nil && res.StatusCode == http.StatusNotModified {
37337 if res.Body != nil {
37338 res.Body.Close()
37339 }
37340 return nil, &googleapi.Error{
37341 Code: res.StatusCode,
37342 Header: res.Header,
37343 }
37344 }
37345 if err != nil {
37346 return nil, err
37347 }
37348 defer googleapi.CloseBody(res)
37349 if err := googleapi.CheckResponse(res); err != nil {
37350 return nil, err
37351 }
37352 ret := &OrderDocument{
37353 ServerResponse: googleapi.ServerResponse{
37354 Header: res.Header,
37355 HTTPStatusCode: res.StatusCode,
37356 },
37357 }
37358 target := &ret
37359 if err := gensupport.DecodeResponse(target, res); err != nil {
37360 return nil, err
37361 }
37362 return ret, nil
37363
37364
37365
37366
37367
37368
37369
37370
37371
37372
37373
37374
37375
37376
37377
37378
37379
37380
37381
37382
37383
37384
37385
37386
37387
37388
37389
37390
37391
37392
37393
37394
37395
37396
37397
37398
37399
37400
37401
37402
37403
37404 }
37405
37406
37407
37408 type OrderDocumentsListCall struct {
37409 s *Service
37410 profileId int64
37411 projectId int64
37412 urlParams_ gensupport.URLParams
37413 ifNoneMatch_ string
37414 ctx_ context.Context
37415 header_ http.Header
37416 }
37417
37418
37419
37420 func (r *OrderDocumentsService) List(profileId int64, projectId int64) *OrderDocumentsListCall {
37421 c := &OrderDocumentsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
37422 c.profileId = profileId
37423 c.projectId = projectId
37424 return c
37425 }
37426
37427
37428
37429 func (c *OrderDocumentsListCall) Approved(approved bool) *OrderDocumentsListCall {
37430 c.urlParams_.Set("approved", fmt.Sprint(approved))
37431 return c
37432 }
37433
37434
37435
37436 func (c *OrderDocumentsListCall) Ids(ids ...int64) *OrderDocumentsListCall {
37437 var ids_ []string
37438 for _, v := range ids {
37439 ids_ = append(ids_, fmt.Sprint(v))
37440 }
37441 c.urlParams_.SetMulti("ids", ids_)
37442 return c
37443 }
37444
37445
37446
37447 func (c *OrderDocumentsListCall) MaxResults(maxResults int64) *OrderDocumentsListCall {
37448 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
37449 return c
37450 }
37451
37452
37453
37454 func (c *OrderDocumentsListCall) OrderId(orderId ...int64) *OrderDocumentsListCall {
37455 var orderId_ []string
37456 for _, v := range orderId {
37457 orderId_ = append(orderId_, fmt.Sprint(v))
37458 }
37459 c.urlParams_.SetMulti("orderId", orderId_)
37460 return c
37461 }
37462
37463
37464
37465 func (c *OrderDocumentsListCall) PageToken(pageToken string) *OrderDocumentsListCall {
37466 c.urlParams_.Set("pageToken", pageToken)
37467 return c
37468 }
37469
37470
37471
37472
37473
37474
37475
37476
37477
37478
37479 func (c *OrderDocumentsListCall) SearchString(searchString string) *OrderDocumentsListCall {
37480 c.urlParams_.Set("searchString", searchString)
37481 return c
37482 }
37483
37484
37485
37486 func (c *OrderDocumentsListCall) SiteId(siteId ...int64) *OrderDocumentsListCall {
37487 var siteId_ []string
37488 for _, v := range siteId {
37489 siteId_ = append(siteId_, fmt.Sprint(v))
37490 }
37491 c.urlParams_.SetMulti("siteId", siteId_)
37492 return c
37493 }
37494
37495
37496
37497
37498
37499
37500
37501
37502 func (c *OrderDocumentsListCall) SortField(sortField string) *OrderDocumentsListCall {
37503 c.urlParams_.Set("sortField", sortField)
37504 return c
37505 }
37506
37507
37508
37509
37510
37511
37512
37513
37514 func (c *OrderDocumentsListCall) SortOrder(sortOrder string) *OrderDocumentsListCall {
37515 c.urlParams_.Set("sortOrder", sortOrder)
37516 return c
37517 }
37518
37519
37520
37521
37522 func (c *OrderDocumentsListCall) Fields(s ...googleapi.Field) *OrderDocumentsListCall {
37523 c.urlParams_.Set("fields", googleapi.CombineFields(s))
37524 return c
37525 }
37526
37527
37528
37529
37530
37531
37532 func (c *OrderDocumentsListCall) IfNoneMatch(entityTag string) *OrderDocumentsListCall {
37533 c.ifNoneMatch_ = entityTag
37534 return c
37535 }
37536
37537
37538
37539
37540 func (c *OrderDocumentsListCall) Context(ctx context.Context) *OrderDocumentsListCall {
37541 c.ctx_ = ctx
37542 return c
37543 }
37544
37545
37546
37547 func (c *OrderDocumentsListCall) Header() http.Header {
37548 if c.header_ == nil {
37549 c.header_ = make(http.Header)
37550 }
37551 return c.header_
37552 }
37553
37554 func (c *OrderDocumentsListCall) doRequest(alt string) (*http.Response, error) {
37555 reqHeaders := make(http.Header)
37556 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
37557 for k, v := range c.header_ {
37558 reqHeaders[k] = v
37559 }
37560 reqHeaders.Set("User-Agent", c.s.userAgent())
37561 if c.ifNoneMatch_ != "" {
37562 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
37563 }
37564 var body io.Reader = nil
37565 c.urlParams_.Set("alt", alt)
37566 c.urlParams_.Set("prettyPrint", "false")
37567 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/projects/{projectId}/orderDocuments")
37568 urls += "?" + c.urlParams_.Encode()
37569 req, err := http.NewRequest("GET", urls, body)
37570 if err != nil {
37571 return nil, err
37572 }
37573 req.Header = reqHeaders
37574 googleapi.Expand(req.URL, map[string]string{
37575 "profileId": strconv.FormatInt(c.profileId, 10),
37576 "projectId": strconv.FormatInt(c.projectId, 10),
37577 })
37578 return gensupport.SendRequest(c.ctx_, c.s.client, req)
37579 }
37580
37581
37582
37583
37584
37585
37586
37587
37588 func (c *OrderDocumentsListCall) Do(opts ...googleapi.CallOption) (*OrderDocumentsListResponse, error) {
37589 gensupport.SetOptions(c.urlParams_, opts...)
37590 res, err := c.doRequest("json")
37591 if res != nil && res.StatusCode == http.StatusNotModified {
37592 if res.Body != nil {
37593 res.Body.Close()
37594 }
37595 return nil, &googleapi.Error{
37596 Code: res.StatusCode,
37597 Header: res.Header,
37598 }
37599 }
37600 if err != nil {
37601 return nil, err
37602 }
37603 defer googleapi.CloseBody(res)
37604 if err := googleapi.CheckResponse(res); err != nil {
37605 return nil, err
37606 }
37607 ret := &OrderDocumentsListResponse{
37608 ServerResponse: googleapi.ServerResponse{
37609 Header: res.Header,
37610 HTTPStatusCode: res.StatusCode,
37611 },
37612 }
37613 target := &ret
37614 if err := gensupport.DecodeResponse(target, res); err != nil {
37615 return nil, err
37616 }
37617 return ret, nil
37618
37619
37620
37621
37622
37623
37624
37625
37626
37627
37628
37629
37630
37631
37632
37633
37634
37635
37636
37637
37638
37639
37640
37641
37642
37643
37644
37645
37646
37647
37648
37649
37650
37651
37652
37653
37654
37655
37656
37657
37658
37659
37660
37661
37662
37663
37664
37665
37666
37667
37668
37669
37670
37671
37672
37673
37674
37675
37676
37677
37678
37679
37680
37681
37682
37683
37684
37685
37686
37687
37688
37689
37690
37691
37692
37693
37694
37695
37696
37697
37698
37699
37700
37701
37702
37703
37704
37705
37706
37707
37708
37709
37710
37711
37712
37713
37714
37715
37716
37717
37718
37719
37720
37721
37722
37723
37724 }
37725
37726
37727
37728
37729 func (c *OrderDocumentsListCall) Pages(ctx context.Context, f func(*OrderDocumentsListResponse) error) error {
37730 c.ctx_ = ctx
37731 defer c.PageToken(c.urlParams_.Get("pageToken"))
37732 for {
37733 x, err := c.Do()
37734 if err != nil {
37735 return err
37736 }
37737 if err := f(x); err != nil {
37738 return err
37739 }
37740 if x.NextPageToken == "" {
37741 return nil
37742 }
37743 c.PageToken(x.NextPageToken)
37744 }
37745 }
37746
37747
37748
37749 type OrdersGetCall struct {
37750 s *Service
37751 profileId int64
37752 projectId int64
37753 id int64
37754 urlParams_ gensupport.URLParams
37755 ifNoneMatch_ string
37756 ctx_ context.Context
37757 header_ http.Header
37758 }
37759
37760
37761 func (r *OrdersService) Get(profileId int64, projectId int64, id int64) *OrdersGetCall {
37762 c := &OrdersGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
37763 c.profileId = profileId
37764 c.projectId = projectId
37765 c.id = id
37766 return c
37767 }
37768
37769
37770
37771
37772 func (c *OrdersGetCall) Fields(s ...googleapi.Field) *OrdersGetCall {
37773 c.urlParams_.Set("fields", googleapi.CombineFields(s))
37774 return c
37775 }
37776
37777
37778
37779
37780
37781
37782 func (c *OrdersGetCall) IfNoneMatch(entityTag string) *OrdersGetCall {
37783 c.ifNoneMatch_ = entityTag
37784 return c
37785 }
37786
37787
37788
37789
37790 func (c *OrdersGetCall) Context(ctx context.Context) *OrdersGetCall {
37791 c.ctx_ = ctx
37792 return c
37793 }
37794
37795
37796
37797 func (c *OrdersGetCall) Header() http.Header {
37798 if c.header_ == nil {
37799 c.header_ = make(http.Header)
37800 }
37801 return c.header_
37802 }
37803
37804 func (c *OrdersGetCall) doRequest(alt string) (*http.Response, error) {
37805 reqHeaders := make(http.Header)
37806 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
37807 for k, v := range c.header_ {
37808 reqHeaders[k] = v
37809 }
37810 reqHeaders.Set("User-Agent", c.s.userAgent())
37811 if c.ifNoneMatch_ != "" {
37812 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
37813 }
37814 var body io.Reader = nil
37815 c.urlParams_.Set("alt", alt)
37816 c.urlParams_.Set("prettyPrint", "false")
37817 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/projects/{projectId}/orders/{id}")
37818 urls += "?" + c.urlParams_.Encode()
37819 req, err := http.NewRequest("GET", urls, body)
37820 if err != nil {
37821 return nil, err
37822 }
37823 req.Header = reqHeaders
37824 googleapi.Expand(req.URL, map[string]string{
37825 "profileId": strconv.FormatInt(c.profileId, 10),
37826 "projectId": strconv.FormatInt(c.projectId, 10),
37827 "id": strconv.FormatInt(c.id, 10),
37828 })
37829 return gensupport.SendRequest(c.ctx_, c.s.client, req)
37830 }
37831
37832
37833
37834
37835
37836
37837
37838
37839 func (c *OrdersGetCall) Do(opts ...googleapi.CallOption) (*Order, error) {
37840 gensupport.SetOptions(c.urlParams_, opts...)
37841 res, err := c.doRequest("json")
37842 if res != nil && res.StatusCode == http.StatusNotModified {
37843 if res.Body != nil {
37844 res.Body.Close()
37845 }
37846 return nil, &googleapi.Error{
37847 Code: res.StatusCode,
37848 Header: res.Header,
37849 }
37850 }
37851 if err != nil {
37852 return nil, err
37853 }
37854 defer googleapi.CloseBody(res)
37855 if err := googleapi.CheckResponse(res); err != nil {
37856 return nil, err
37857 }
37858 ret := &Order{
37859 ServerResponse: googleapi.ServerResponse{
37860 Header: res.Header,
37861 HTTPStatusCode: res.StatusCode,
37862 },
37863 }
37864 target := &ret
37865 if err := gensupport.DecodeResponse(target, res); err != nil {
37866 return nil, err
37867 }
37868 return ret, nil
37869
37870
37871
37872
37873
37874
37875
37876
37877
37878
37879
37880
37881
37882
37883
37884
37885
37886
37887
37888
37889
37890
37891
37892
37893
37894
37895
37896
37897
37898
37899
37900
37901
37902
37903
37904
37905
37906
37907
37908
37909
37910 }
37911
37912
37913
37914 type OrdersListCall struct {
37915 s *Service
37916 profileId int64
37917 projectId int64
37918 urlParams_ gensupport.URLParams
37919 ifNoneMatch_ string
37920 ctx_ context.Context
37921 header_ http.Header
37922 }
37923
37924
37925
37926 func (r *OrdersService) List(profileId int64, projectId int64) *OrdersListCall {
37927 c := &OrdersListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
37928 c.profileId = profileId
37929 c.projectId = projectId
37930 return c
37931 }
37932
37933
37934
37935 func (c *OrdersListCall) Ids(ids ...int64) *OrdersListCall {
37936 var ids_ []string
37937 for _, v := range ids {
37938 ids_ = append(ids_, fmt.Sprint(v))
37939 }
37940 c.urlParams_.SetMulti("ids", ids_)
37941 return c
37942 }
37943
37944
37945
37946 func (c *OrdersListCall) MaxResults(maxResults int64) *OrdersListCall {
37947 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
37948 return c
37949 }
37950
37951
37952
37953 func (c *OrdersListCall) PageToken(pageToken string) *OrdersListCall {
37954 c.urlParams_.Set("pageToken", pageToken)
37955 return c
37956 }
37957
37958
37959
37960
37961
37962
37963
37964
37965 func (c *OrdersListCall) SearchString(searchString string) *OrdersListCall {
37966 c.urlParams_.Set("searchString", searchString)
37967 return c
37968 }
37969
37970
37971
37972 func (c *OrdersListCall) SiteId(siteId ...int64) *OrdersListCall {
37973 var siteId_ []string
37974 for _, v := range siteId {
37975 siteId_ = append(siteId_, fmt.Sprint(v))
37976 }
37977 c.urlParams_.SetMulti("siteId", siteId_)
37978 return c
37979 }
37980
37981
37982
37983
37984
37985
37986
37987
37988 func (c *OrdersListCall) SortField(sortField string) *OrdersListCall {
37989 c.urlParams_.Set("sortField", sortField)
37990 return c
37991 }
37992
37993
37994
37995
37996
37997
37998
37999
38000 func (c *OrdersListCall) SortOrder(sortOrder string) *OrdersListCall {
38001 c.urlParams_.Set("sortOrder", sortOrder)
38002 return c
38003 }
38004
38005
38006
38007
38008 func (c *OrdersListCall) Fields(s ...googleapi.Field) *OrdersListCall {
38009 c.urlParams_.Set("fields", googleapi.CombineFields(s))
38010 return c
38011 }
38012
38013
38014
38015
38016
38017
38018 func (c *OrdersListCall) IfNoneMatch(entityTag string) *OrdersListCall {
38019 c.ifNoneMatch_ = entityTag
38020 return c
38021 }
38022
38023
38024
38025
38026 func (c *OrdersListCall) Context(ctx context.Context) *OrdersListCall {
38027 c.ctx_ = ctx
38028 return c
38029 }
38030
38031
38032
38033 func (c *OrdersListCall) Header() http.Header {
38034 if c.header_ == nil {
38035 c.header_ = make(http.Header)
38036 }
38037 return c.header_
38038 }
38039
38040 func (c *OrdersListCall) doRequest(alt string) (*http.Response, error) {
38041 reqHeaders := make(http.Header)
38042 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
38043 for k, v := range c.header_ {
38044 reqHeaders[k] = v
38045 }
38046 reqHeaders.Set("User-Agent", c.s.userAgent())
38047 if c.ifNoneMatch_ != "" {
38048 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
38049 }
38050 var body io.Reader = nil
38051 c.urlParams_.Set("alt", alt)
38052 c.urlParams_.Set("prettyPrint", "false")
38053 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/projects/{projectId}/orders")
38054 urls += "?" + c.urlParams_.Encode()
38055 req, err := http.NewRequest("GET", urls, body)
38056 if err != nil {
38057 return nil, err
38058 }
38059 req.Header = reqHeaders
38060 googleapi.Expand(req.URL, map[string]string{
38061 "profileId": strconv.FormatInt(c.profileId, 10),
38062 "projectId": strconv.FormatInt(c.projectId, 10),
38063 })
38064 return gensupport.SendRequest(c.ctx_, c.s.client, req)
38065 }
38066
38067
38068
38069
38070
38071
38072
38073
38074 func (c *OrdersListCall) Do(opts ...googleapi.CallOption) (*OrdersListResponse, error) {
38075 gensupport.SetOptions(c.urlParams_, opts...)
38076 res, err := c.doRequest("json")
38077 if res != nil && res.StatusCode == http.StatusNotModified {
38078 if res.Body != nil {
38079 res.Body.Close()
38080 }
38081 return nil, &googleapi.Error{
38082 Code: res.StatusCode,
38083 Header: res.Header,
38084 }
38085 }
38086 if err != nil {
38087 return nil, err
38088 }
38089 defer googleapi.CloseBody(res)
38090 if err := googleapi.CheckResponse(res); err != nil {
38091 return nil, err
38092 }
38093 ret := &OrdersListResponse{
38094 ServerResponse: googleapi.ServerResponse{
38095 Header: res.Header,
38096 HTTPStatusCode: res.StatusCode,
38097 },
38098 }
38099 target := &ret
38100 if err := gensupport.DecodeResponse(target, res); err != nil {
38101 return nil, err
38102 }
38103 return ret, nil
38104
38105
38106
38107
38108
38109
38110
38111
38112
38113
38114
38115
38116
38117
38118
38119
38120
38121
38122
38123
38124
38125
38126
38127
38128
38129
38130
38131
38132
38133
38134
38135
38136
38137
38138
38139
38140
38141
38142
38143
38144
38145
38146
38147
38148
38149
38150
38151
38152
38153
38154
38155
38156
38157
38158
38159
38160
38161
38162
38163
38164
38165
38166
38167
38168
38169
38170
38171
38172
38173
38174
38175
38176
38177
38178
38179
38180
38181
38182
38183
38184
38185
38186
38187
38188
38189
38190
38191
38192
38193
38194
38195
38196
38197
38198 }
38199
38200
38201
38202
38203 func (c *OrdersListCall) Pages(ctx context.Context, f func(*OrdersListResponse) error) error {
38204 c.ctx_ = ctx
38205 defer c.PageToken(c.urlParams_.Get("pageToken"))
38206 for {
38207 x, err := c.Do()
38208 if err != nil {
38209 return err
38210 }
38211 if err := f(x); err != nil {
38212 return err
38213 }
38214 if x.NextPageToken == "" {
38215 return nil
38216 }
38217 c.PageToken(x.NextPageToken)
38218 }
38219 }
38220
38221
38222
38223 type PlacementGroupsGetCall struct {
38224 s *Service
38225 profileId int64
38226 id int64
38227 urlParams_ gensupport.URLParams
38228 ifNoneMatch_ string
38229 ctx_ context.Context
38230 header_ http.Header
38231 }
38232
38233
38234 func (r *PlacementGroupsService) Get(profileId int64, id int64) *PlacementGroupsGetCall {
38235 c := &PlacementGroupsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
38236 c.profileId = profileId
38237 c.id = id
38238 return c
38239 }
38240
38241
38242
38243
38244 func (c *PlacementGroupsGetCall) Fields(s ...googleapi.Field) *PlacementGroupsGetCall {
38245 c.urlParams_.Set("fields", googleapi.CombineFields(s))
38246 return c
38247 }
38248
38249
38250
38251
38252
38253
38254 func (c *PlacementGroupsGetCall) IfNoneMatch(entityTag string) *PlacementGroupsGetCall {
38255 c.ifNoneMatch_ = entityTag
38256 return c
38257 }
38258
38259
38260
38261
38262 func (c *PlacementGroupsGetCall) Context(ctx context.Context) *PlacementGroupsGetCall {
38263 c.ctx_ = ctx
38264 return c
38265 }
38266
38267
38268
38269 func (c *PlacementGroupsGetCall) Header() http.Header {
38270 if c.header_ == nil {
38271 c.header_ = make(http.Header)
38272 }
38273 return c.header_
38274 }
38275
38276 func (c *PlacementGroupsGetCall) doRequest(alt string) (*http.Response, error) {
38277 reqHeaders := make(http.Header)
38278 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
38279 for k, v := range c.header_ {
38280 reqHeaders[k] = v
38281 }
38282 reqHeaders.Set("User-Agent", c.s.userAgent())
38283 if c.ifNoneMatch_ != "" {
38284 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
38285 }
38286 var body io.Reader = nil
38287 c.urlParams_.Set("alt", alt)
38288 c.urlParams_.Set("prettyPrint", "false")
38289 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/placementGroups/{id}")
38290 urls += "?" + c.urlParams_.Encode()
38291 req, err := http.NewRequest("GET", urls, body)
38292 if err != nil {
38293 return nil, err
38294 }
38295 req.Header = reqHeaders
38296 googleapi.Expand(req.URL, map[string]string{
38297 "profileId": strconv.FormatInt(c.profileId, 10),
38298 "id": strconv.FormatInt(c.id, 10),
38299 })
38300 return gensupport.SendRequest(c.ctx_, c.s.client, req)
38301 }
38302
38303
38304
38305
38306
38307
38308
38309
38310 func (c *PlacementGroupsGetCall) Do(opts ...googleapi.CallOption) (*PlacementGroup, error) {
38311 gensupport.SetOptions(c.urlParams_, opts...)
38312 res, err := c.doRequest("json")
38313 if res != nil && res.StatusCode == http.StatusNotModified {
38314 if res.Body != nil {
38315 res.Body.Close()
38316 }
38317 return nil, &googleapi.Error{
38318 Code: res.StatusCode,
38319 Header: res.Header,
38320 }
38321 }
38322 if err != nil {
38323 return nil, err
38324 }
38325 defer googleapi.CloseBody(res)
38326 if err := googleapi.CheckResponse(res); err != nil {
38327 return nil, err
38328 }
38329 ret := &PlacementGroup{
38330 ServerResponse: googleapi.ServerResponse{
38331 Header: res.Header,
38332 HTTPStatusCode: res.StatusCode,
38333 },
38334 }
38335 target := &ret
38336 if err := gensupport.DecodeResponse(target, res); err != nil {
38337 return nil, err
38338 }
38339 return ret, nil
38340
38341
38342
38343
38344
38345
38346
38347
38348
38349
38350
38351
38352
38353
38354
38355
38356
38357
38358
38359
38360
38361
38362
38363
38364
38365
38366
38367
38368
38369
38370
38371
38372
38373 }
38374
38375
38376
38377 type PlacementGroupsInsertCall struct {
38378 s *Service
38379 profileId int64
38380 placementgroup *PlacementGroup
38381 urlParams_ gensupport.URLParams
38382 ctx_ context.Context
38383 header_ http.Header
38384 }
38385
38386
38387 func (r *PlacementGroupsService) Insert(profileId int64, placementgroup *PlacementGroup) *PlacementGroupsInsertCall {
38388 c := &PlacementGroupsInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
38389 c.profileId = profileId
38390 c.placementgroup = placementgroup
38391 return c
38392 }
38393
38394
38395
38396
38397 func (c *PlacementGroupsInsertCall) Fields(s ...googleapi.Field) *PlacementGroupsInsertCall {
38398 c.urlParams_.Set("fields", googleapi.CombineFields(s))
38399 return c
38400 }
38401
38402
38403
38404
38405 func (c *PlacementGroupsInsertCall) Context(ctx context.Context) *PlacementGroupsInsertCall {
38406 c.ctx_ = ctx
38407 return c
38408 }
38409
38410
38411
38412 func (c *PlacementGroupsInsertCall) Header() http.Header {
38413 if c.header_ == nil {
38414 c.header_ = make(http.Header)
38415 }
38416 return c.header_
38417 }
38418
38419 func (c *PlacementGroupsInsertCall) doRequest(alt string) (*http.Response, error) {
38420 reqHeaders := make(http.Header)
38421 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
38422 for k, v := range c.header_ {
38423 reqHeaders[k] = v
38424 }
38425 reqHeaders.Set("User-Agent", c.s.userAgent())
38426 var body io.Reader = nil
38427 body, err := googleapi.WithoutDataWrapper.JSONReader(c.placementgroup)
38428 if err != nil {
38429 return nil, err
38430 }
38431 reqHeaders.Set("Content-Type", "application/json")
38432 c.urlParams_.Set("alt", alt)
38433 c.urlParams_.Set("prettyPrint", "false")
38434 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/placementGroups")
38435 urls += "?" + c.urlParams_.Encode()
38436 req, err := http.NewRequest("POST", urls, body)
38437 if err != nil {
38438 return nil, err
38439 }
38440 req.Header = reqHeaders
38441 googleapi.Expand(req.URL, map[string]string{
38442 "profileId": strconv.FormatInt(c.profileId, 10),
38443 })
38444 return gensupport.SendRequest(c.ctx_, c.s.client, req)
38445 }
38446
38447
38448
38449
38450
38451
38452
38453
38454 func (c *PlacementGroupsInsertCall) Do(opts ...googleapi.CallOption) (*PlacementGroup, error) {
38455 gensupport.SetOptions(c.urlParams_, opts...)
38456 res, err := c.doRequest("json")
38457 if res != nil && res.StatusCode == http.StatusNotModified {
38458 if res.Body != nil {
38459 res.Body.Close()
38460 }
38461 return nil, &googleapi.Error{
38462 Code: res.StatusCode,
38463 Header: res.Header,
38464 }
38465 }
38466 if err != nil {
38467 return nil, err
38468 }
38469 defer googleapi.CloseBody(res)
38470 if err := googleapi.CheckResponse(res); err != nil {
38471 return nil, err
38472 }
38473 ret := &PlacementGroup{
38474 ServerResponse: googleapi.ServerResponse{
38475 Header: res.Header,
38476 HTTPStatusCode: res.StatusCode,
38477 },
38478 }
38479 target := &ret
38480 if err := gensupport.DecodeResponse(target, res); err != nil {
38481 return nil, err
38482 }
38483 return ret, nil
38484
38485
38486
38487
38488
38489
38490
38491
38492
38493
38494
38495
38496
38497
38498
38499
38500
38501
38502
38503
38504
38505
38506
38507
38508
38509
38510
38511
38512 }
38513
38514
38515
38516 type PlacementGroupsListCall struct {
38517 s *Service
38518 profileId int64
38519 urlParams_ gensupport.URLParams
38520 ifNoneMatch_ string
38521 ctx_ context.Context
38522 header_ http.Header
38523 }
38524
38525
38526
38527 func (r *PlacementGroupsService) List(profileId int64) *PlacementGroupsListCall {
38528 c := &PlacementGroupsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
38529 c.profileId = profileId
38530 return c
38531 }
38532
38533
38534
38535 func (c *PlacementGroupsListCall) AdvertiserIds(advertiserIds ...int64) *PlacementGroupsListCall {
38536 var advertiserIds_ []string
38537 for _, v := range advertiserIds {
38538 advertiserIds_ = append(advertiserIds_, fmt.Sprint(v))
38539 }
38540 c.urlParams_.SetMulti("advertiserIds", advertiserIds_)
38541 return c
38542 }
38543
38544
38545
38546
38547 func (c *PlacementGroupsListCall) Archived(archived bool) *PlacementGroupsListCall {
38548 c.urlParams_.Set("archived", fmt.Sprint(archived))
38549 return c
38550 }
38551
38552
38553
38554 func (c *PlacementGroupsListCall) CampaignIds(campaignIds ...int64) *PlacementGroupsListCall {
38555 var campaignIds_ []string
38556 for _, v := range campaignIds {
38557 campaignIds_ = append(campaignIds_, fmt.Sprint(v))
38558 }
38559 c.urlParams_.SetMulti("campaignIds", campaignIds_)
38560 return c
38561 }
38562
38563
38564
38565
38566 func (c *PlacementGroupsListCall) ContentCategoryIds(contentCategoryIds ...int64) *PlacementGroupsListCall {
38567 var contentCategoryIds_ []string
38568 for _, v := range contentCategoryIds {
38569 contentCategoryIds_ = append(contentCategoryIds_, fmt.Sprint(v))
38570 }
38571 c.urlParams_.SetMulti("contentCategoryIds", contentCategoryIds_)
38572 return c
38573 }
38574
38575
38576
38577
38578 func (c *PlacementGroupsListCall) DirectorySiteIds(directorySiteIds ...int64) *PlacementGroupsListCall {
38579 var directorySiteIds_ []string
38580 for _, v := range directorySiteIds {
38581 directorySiteIds_ = append(directorySiteIds_, fmt.Sprint(v))
38582 }
38583 c.urlParams_.SetMulti("directorySiteIds", directorySiteIds_)
38584 return c
38585 }
38586
38587
38588
38589 func (c *PlacementGroupsListCall) Ids(ids ...int64) *PlacementGroupsListCall {
38590 var ids_ []string
38591 for _, v := range ids {
38592 ids_ = append(ids_, fmt.Sprint(v))
38593 }
38594 c.urlParams_.SetMulti("ids", ids_)
38595 return c
38596 }
38597
38598
38599
38600
38601 func (c *PlacementGroupsListCall) MaxEndDate(maxEndDate string) *PlacementGroupsListCall {
38602 c.urlParams_.Set("maxEndDate", maxEndDate)
38603 return c
38604 }
38605
38606
38607
38608 func (c *PlacementGroupsListCall) MaxResults(maxResults int64) *PlacementGroupsListCall {
38609 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
38610 return c
38611 }
38612
38613
38614
38615
38616 func (c *PlacementGroupsListCall) MaxStartDate(maxStartDate string) *PlacementGroupsListCall {
38617 c.urlParams_.Set("maxStartDate", maxStartDate)
38618 return c
38619 }
38620
38621
38622
38623
38624 func (c *PlacementGroupsListCall) MinEndDate(minEndDate string) *PlacementGroupsListCall {
38625 c.urlParams_.Set("minEndDate", minEndDate)
38626 return c
38627 }
38628
38629
38630
38631
38632 func (c *PlacementGroupsListCall) MinStartDate(minStartDate string) *PlacementGroupsListCall {
38633 c.urlParams_.Set("minStartDate", minStartDate)
38634 return c
38635 }
38636
38637
38638
38639 func (c *PlacementGroupsListCall) PageToken(pageToken string) *PlacementGroupsListCall {
38640 c.urlParams_.Set("pageToken", pageToken)
38641 return c
38642 }
38643
38644
38645
38646
38647
38648
38649
38650
38651
38652
38653
38654
38655
38656 func (c *PlacementGroupsListCall) PlacementGroupType(placementGroupType string) *PlacementGroupsListCall {
38657 c.urlParams_.Set("placementGroupType", placementGroupType)
38658 return c
38659 }
38660
38661
38662
38663
38664 func (c *PlacementGroupsListCall) PlacementStrategyIds(placementStrategyIds ...int64) *PlacementGroupsListCall {
38665 var placementStrategyIds_ []string
38666 for _, v := range placementStrategyIds {
38667 placementStrategyIds_ = append(placementStrategyIds_, fmt.Sprint(v))
38668 }
38669 c.urlParams_.SetMulti("placementStrategyIds", placementStrategyIds_)
38670 return c
38671 }
38672
38673
38674
38675
38676
38677
38678
38679
38680
38681
38682
38683
38684 func (c *PlacementGroupsListCall) PricingTypes(pricingTypes ...string) *PlacementGroupsListCall {
38685 c.urlParams_.SetMulti("pricingTypes", append([]string{}, pricingTypes...))
38686 return c
38687 }
38688
38689
38690
38691
38692
38693
38694
38695
38696
38697
38698 func (c *PlacementGroupsListCall) SearchString(searchString string) *PlacementGroupsListCall {
38699 c.urlParams_.Set("searchString", searchString)
38700 return c
38701 }
38702
38703
38704
38705 func (c *PlacementGroupsListCall) SiteIds(siteIds ...int64) *PlacementGroupsListCall {
38706 var siteIds_ []string
38707 for _, v := range siteIds {
38708 siteIds_ = append(siteIds_, fmt.Sprint(v))
38709 }
38710 c.urlParams_.SetMulti("siteIds", siteIds_)
38711 return c
38712 }
38713
38714
38715
38716
38717
38718
38719
38720
38721 func (c *PlacementGroupsListCall) SortField(sortField string) *PlacementGroupsListCall {
38722 c.urlParams_.Set("sortField", sortField)
38723 return c
38724 }
38725
38726
38727
38728
38729
38730
38731
38732
38733 func (c *PlacementGroupsListCall) SortOrder(sortOrder string) *PlacementGroupsListCall {
38734 c.urlParams_.Set("sortOrder", sortOrder)
38735 return c
38736 }
38737
38738
38739
38740
38741 func (c *PlacementGroupsListCall) Fields(s ...googleapi.Field) *PlacementGroupsListCall {
38742 c.urlParams_.Set("fields", googleapi.CombineFields(s))
38743 return c
38744 }
38745
38746
38747
38748
38749
38750
38751 func (c *PlacementGroupsListCall) IfNoneMatch(entityTag string) *PlacementGroupsListCall {
38752 c.ifNoneMatch_ = entityTag
38753 return c
38754 }
38755
38756
38757
38758
38759 func (c *PlacementGroupsListCall) Context(ctx context.Context) *PlacementGroupsListCall {
38760 c.ctx_ = ctx
38761 return c
38762 }
38763
38764
38765
38766 func (c *PlacementGroupsListCall) Header() http.Header {
38767 if c.header_ == nil {
38768 c.header_ = make(http.Header)
38769 }
38770 return c.header_
38771 }
38772
38773 func (c *PlacementGroupsListCall) doRequest(alt string) (*http.Response, error) {
38774 reqHeaders := make(http.Header)
38775 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
38776 for k, v := range c.header_ {
38777 reqHeaders[k] = v
38778 }
38779 reqHeaders.Set("User-Agent", c.s.userAgent())
38780 if c.ifNoneMatch_ != "" {
38781 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
38782 }
38783 var body io.Reader = nil
38784 c.urlParams_.Set("alt", alt)
38785 c.urlParams_.Set("prettyPrint", "false")
38786 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/placementGroups")
38787 urls += "?" + c.urlParams_.Encode()
38788 req, err := http.NewRequest("GET", urls, body)
38789 if err != nil {
38790 return nil, err
38791 }
38792 req.Header = reqHeaders
38793 googleapi.Expand(req.URL, map[string]string{
38794 "profileId": strconv.FormatInt(c.profileId, 10),
38795 })
38796 return gensupport.SendRequest(c.ctx_, c.s.client, req)
38797 }
38798
38799
38800
38801
38802
38803
38804
38805
38806 func (c *PlacementGroupsListCall) Do(opts ...googleapi.CallOption) (*PlacementGroupsListResponse, error) {
38807 gensupport.SetOptions(c.urlParams_, opts...)
38808 res, err := c.doRequest("json")
38809 if res != nil && res.StatusCode == http.StatusNotModified {
38810 if res.Body != nil {
38811 res.Body.Close()
38812 }
38813 return nil, &googleapi.Error{
38814 Code: res.StatusCode,
38815 Header: res.Header,
38816 }
38817 }
38818 if err != nil {
38819 return nil, err
38820 }
38821 defer googleapi.CloseBody(res)
38822 if err := googleapi.CheckResponse(res); err != nil {
38823 return nil, err
38824 }
38825 ret := &PlacementGroupsListResponse{
38826 ServerResponse: googleapi.ServerResponse{
38827 Header: res.Header,
38828 HTTPStatusCode: res.StatusCode,
38829 },
38830 }
38831 target := &ret
38832 if err := gensupport.DecodeResponse(target, res); err != nil {
38833 return nil, err
38834 }
38835 return ret, nil
38836
38837
38838
38839
38840
38841
38842
38843
38844
38845
38846
38847
38848
38849
38850
38851
38852
38853
38854
38855
38856
38857
38858
38859
38860
38861
38862
38863
38864
38865
38866
38867
38868
38869
38870
38871
38872
38873
38874
38875
38876
38877
38878
38879
38880
38881
38882
38883
38884
38885
38886
38887
38888
38889
38890
38891
38892
38893
38894
38895
38896
38897
38898
38899
38900
38901
38902
38903
38904
38905
38906
38907
38908
38909
38910
38911
38912
38913
38914
38915
38916
38917
38918
38919
38920
38921
38922
38923
38924
38925
38926
38927
38928
38929
38930
38931
38932
38933
38934
38935
38936
38937
38938
38939
38940
38941
38942
38943
38944
38945
38946
38947
38948
38949
38950
38951
38952
38953
38954
38955
38956
38957
38958
38959
38960
38961
38962
38963
38964
38965
38966
38967
38968
38969
38970
38971
38972
38973
38974
38975
38976
38977
38978
38979
38980
38981
38982
38983
38984
38985
38986
38987
38988
38989
38990
38991
38992
38993
38994
38995
38996
38997
38998
38999
39000
39001
39002
39003
39004
39005
39006
39007
39008
39009
39010
39011
39012
39013
39014
39015
39016
39017 }
39018
39019
39020
39021
39022 func (c *PlacementGroupsListCall) Pages(ctx context.Context, f func(*PlacementGroupsListResponse) error) error {
39023 c.ctx_ = ctx
39024 defer c.PageToken(c.urlParams_.Get("pageToken"))
39025 for {
39026 x, err := c.Do()
39027 if err != nil {
39028 return err
39029 }
39030 if err := f(x); err != nil {
39031 return err
39032 }
39033 if x.NextPageToken == "" {
39034 return nil
39035 }
39036 c.PageToken(x.NextPageToken)
39037 }
39038 }
39039
39040
39041
39042 type PlacementGroupsPatchCall struct {
39043 s *Service
39044 profileId int64
39045 placementgroup *PlacementGroup
39046 urlParams_ gensupport.URLParams
39047 ctx_ context.Context
39048 header_ http.Header
39049 }
39050
39051
39052
39053 func (r *PlacementGroupsService) Patch(profileId int64, id int64, placementgroup *PlacementGroup) *PlacementGroupsPatchCall {
39054 c := &PlacementGroupsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
39055 c.profileId = profileId
39056 c.urlParams_.Set("id", fmt.Sprint(id))
39057 c.placementgroup = placementgroup
39058 return c
39059 }
39060
39061
39062
39063
39064 func (c *PlacementGroupsPatchCall) Fields(s ...googleapi.Field) *PlacementGroupsPatchCall {
39065 c.urlParams_.Set("fields", googleapi.CombineFields(s))
39066 return c
39067 }
39068
39069
39070
39071
39072 func (c *PlacementGroupsPatchCall) Context(ctx context.Context) *PlacementGroupsPatchCall {
39073 c.ctx_ = ctx
39074 return c
39075 }
39076
39077
39078
39079 func (c *PlacementGroupsPatchCall) Header() http.Header {
39080 if c.header_ == nil {
39081 c.header_ = make(http.Header)
39082 }
39083 return c.header_
39084 }
39085
39086 func (c *PlacementGroupsPatchCall) doRequest(alt string) (*http.Response, error) {
39087 reqHeaders := make(http.Header)
39088 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
39089 for k, v := range c.header_ {
39090 reqHeaders[k] = v
39091 }
39092 reqHeaders.Set("User-Agent", c.s.userAgent())
39093 var body io.Reader = nil
39094 body, err := googleapi.WithoutDataWrapper.JSONReader(c.placementgroup)
39095 if err != nil {
39096 return nil, err
39097 }
39098 reqHeaders.Set("Content-Type", "application/json")
39099 c.urlParams_.Set("alt", alt)
39100 c.urlParams_.Set("prettyPrint", "false")
39101 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/placementGroups")
39102 urls += "?" + c.urlParams_.Encode()
39103 req, err := http.NewRequest("PATCH", urls, body)
39104 if err != nil {
39105 return nil, err
39106 }
39107 req.Header = reqHeaders
39108 googleapi.Expand(req.URL, map[string]string{
39109 "profileId": strconv.FormatInt(c.profileId, 10),
39110 })
39111 return gensupport.SendRequest(c.ctx_, c.s.client, req)
39112 }
39113
39114
39115
39116
39117
39118
39119
39120
39121 func (c *PlacementGroupsPatchCall) Do(opts ...googleapi.CallOption) (*PlacementGroup, error) {
39122 gensupport.SetOptions(c.urlParams_, opts...)
39123 res, err := c.doRequest("json")
39124 if res != nil && res.StatusCode == http.StatusNotModified {
39125 if res.Body != nil {
39126 res.Body.Close()
39127 }
39128 return nil, &googleapi.Error{
39129 Code: res.StatusCode,
39130 Header: res.Header,
39131 }
39132 }
39133 if err != nil {
39134 return nil, err
39135 }
39136 defer googleapi.CloseBody(res)
39137 if err := googleapi.CheckResponse(res); err != nil {
39138 return nil, err
39139 }
39140 ret := &PlacementGroup{
39141 ServerResponse: googleapi.ServerResponse{
39142 Header: res.Header,
39143 HTTPStatusCode: res.StatusCode,
39144 },
39145 }
39146 target := &ret
39147 if err := gensupport.DecodeResponse(target, res); err != nil {
39148 return nil, err
39149 }
39150 return ret, nil
39151
39152
39153
39154
39155
39156
39157
39158
39159
39160
39161
39162
39163
39164
39165
39166
39167
39168
39169
39170
39171
39172
39173
39174
39175
39176
39177
39178
39179
39180
39181
39182
39183
39184
39185
39186
39187 }
39188
39189
39190
39191 type PlacementGroupsUpdateCall struct {
39192 s *Service
39193 profileId int64
39194 placementgroup *PlacementGroup
39195 urlParams_ gensupport.URLParams
39196 ctx_ context.Context
39197 header_ http.Header
39198 }
39199
39200
39201 func (r *PlacementGroupsService) Update(profileId int64, placementgroup *PlacementGroup) *PlacementGroupsUpdateCall {
39202 c := &PlacementGroupsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
39203 c.profileId = profileId
39204 c.placementgroup = placementgroup
39205 return c
39206 }
39207
39208
39209
39210
39211 func (c *PlacementGroupsUpdateCall) Fields(s ...googleapi.Field) *PlacementGroupsUpdateCall {
39212 c.urlParams_.Set("fields", googleapi.CombineFields(s))
39213 return c
39214 }
39215
39216
39217
39218
39219 func (c *PlacementGroupsUpdateCall) Context(ctx context.Context) *PlacementGroupsUpdateCall {
39220 c.ctx_ = ctx
39221 return c
39222 }
39223
39224
39225
39226 func (c *PlacementGroupsUpdateCall) Header() http.Header {
39227 if c.header_ == nil {
39228 c.header_ = make(http.Header)
39229 }
39230 return c.header_
39231 }
39232
39233 func (c *PlacementGroupsUpdateCall) doRequest(alt string) (*http.Response, error) {
39234 reqHeaders := make(http.Header)
39235 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
39236 for k, v := range c.header_ {
39237 reqHeaders[k] = v
39238 }
39239 reqHeaders.Set("User-Agent", c.s.userAgent())
39240 var body io.Reader = nil
39241 body, err := googleapi.WithoutDataWrapper.JSONReader(c.placementgroup)
39242 if err != nil {
39243 return nil, err
39244 }
39245 reqHeaders.Set("Content-Type", "application/json")
39246 c.urlParams_.Set("alt", alt)
39247 c.urlParams_.Set("prettyPrint", "false")
39248 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/placementGroups")
39249 urls += "?" + c.urlParams_.Encode()
39250 req, err := http.NewRequest("PUT", urls, body)
39251 if err != nil {
39252 return nil, err
39253 }
39254 req.Header = reqHeaders
39255 googleapi.Expand(req.URL, map[string]string{
39256 "profileId": strconv.FormatInt(c.profileId, 10),
39257 })
39258 return gensupport.SendRequest(c.ctx_, c.s.client, req)
39259 }
39260
39261
39262
39263
39264
39265
39266
39267
39268 func (c *PlacementGroupsUpdateCall) Do(opts ...googleapi.CallOption) (*PlacementGroup, error) {
39269 gensupport.SetOptions(c.urlParams_, opts...)
39270 res, err := c.doRequest("json")
39271 if res != nil && res.StatusCode == http.StatusNotModified {
39272 if res.Body != nil {
39273 res.Body.Close()
39274 }
39275 return nil, &googleapi.Error{
39276 Code: res.StatusCode,
39277 Header: res.Header,
39278 }
39279 }
39280 if err != nil {
39281 return nil, err
39282 }
39283 defer googleapi.CloseBody(res)
39284 if err := googleapi.CheckResponse(res); err != nil {
39285 return nil, err
39286 }
39287 ret := &PlacementGroup{
39288 ServerResponse: googleapi.ServerResponse{
39289 Header: res.Header,
39290 HTTPStatusCode: res.StatusCode,
39291 },
39292 }
39293 target := &ret
39294 if err := gensupport.DecodeResponse(target, res); err != nil {
39295 return nil, err
39296 }
39297 return ret, nil
39298
39299
39300
39301
39302
39303
39304
39305
39306
39307
39308
39309
39310
39311
39312
39313
39314
39315
39316
39317
39318
39319
39320
39321
39322
39323
39324
39325
39326 }
39327
39328
39329
39330 type PlacementStrategiesDeleteCall struct {
39331 s *Service
39332 profileId int64
39333 id int64
39334 urlParams_ gensupport.URLParams
39335 ctx_ context.Context
39336 header_ http.Header
39337 }
39338
39339
39340 func (r *PlacementStrategiesService) Delete(profileId int64, id int64) *PlacementStrategiesDeleteCall {
39341 c := &PlacementStrategiesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
39342 c.profileId = profileId
39343 c.id = id
39344 return c
39345 }
39346
39347
39348
39349
39350 func (c *PlacementStrategiesDeleteCall) Fields(s ...googleapi.Field) *PlacementStrategiesDeleteCall {
39351 c.urlParams_.Set("fields", googleapi.CombineFields(s))
39352 return c
39353 }
39354
39355
39356
39357
39358 func (c *PlacementStrategiesDeleteCall) Context(ctx context.Context) *PlacementStrategiesDeleteCall {
39359 c.ctx_ = ctx
39360 return c
39361 }
39362
39363
39364
39365 func (c *PlacementStrategiesDeleteCall) Header() http.Header {
39366 if c.header_ == nil {
39367 c.header_ = make(http.Header)
39368 }
39369 return c.header_
39370 }
39371
39372 func (c *PlacementStrategiesDeleteCall) doRequest(alt string) (*http.Response, error) {
39373 reqHeaders := make(http.Header)
39374 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
39375 for k, v := range c.header_ {
39376 reqHeaders[k] = v
39377 }
39378 reqHeaders.Set("User-Agent", c.s.userAgent())
39379 var body io.Reader = nil
39380 c.urlParams_.Set("alt", alt)
39381 c.urlParams_.Set("prettyPrint", "false")
39382 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/placementStrategies/{id}")
39383 urls += "?" + c.urlParams_.Encode()
39384 req, err := http.NewRequest("DELETE", urls, body)
39385 if err != nil {
39386 return nil, err
39387 }
39388 req.Header = reqHeaders
39389 googleapi.Expand(req.URL, map[string]string{
39390 "profileId": strconv.FormatInt(c.profileId, 10),
39391 "id": strconv.FormatInt(c.id, 10),
39392 })
39393 return gensupport.SendRequest(c.ctx_, c.s.client, req)
39394 }
39395
39396
39397 func (c *PlacementStrategiesDeleteCall) Do(opts ...googleapi.CallOption) error {
39398 gensupport.SetOptions(c.urlParams_, opts...)
39399 res, err := c.doRequest("json")
39400 if err != nil {
39401 return err
39402 }
39403 defer googleapi.CloseBody(res)
39404 if err := googleapi.CheckResponse(res); err != nil {
39405 return err
39406 }
39407 return nil
39408
39409
39410
39411
39412
39413
39414
39415
39416
39417
39418
39419
39420
39421
39422
39423
39424
39425
39426
39427
39428
39429
39430
39431
39432
39433
39434
39435
39436
39437
39438 }
39439
39440
39441
39442 type PlacementStrategiesGetCall struct {
39443 s *Service
39444 profileId int64
39445 id int64
39446 urlParams_ gensupport.URLParams
39447 ifNoneMatch_ string
39448 ctx_ context.Context
39449 header_ http.Header
39450 }
39451
39452
39453 func (r *PlacementStrategiesService) Get(profileId int64, id int64) *PlacementStrategiesGetCall {
39454 c := &PlacementStrategiesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
39455 c.profileId = profileId
39456 c.id = id
39457 return c
39458 }
39459
39460
39461
39462
39463 func (c *PlacementStrategiesGetCall) Fields(s ...googleapi.Field) *PlacementStrategiesGetCall {
39464 c.urlParams_.Set("fields", googleapi.CombineFields(s))
39465 return c
39466 }
39467
39468
39469
39470
39471
39472
39473 func (c *PlacementStrategiesGetCall) IfNoneMatch(entityTag string) *PlacementStrategiesGetCall {
39474 c.ifNoneMatch_ = entityTag
39475 return c
39476 }
39477
39478
39479
39480
39481 func (c *PlacementStrategiesGetCall) Context(ctx context.Context) *PlacementStrategiesGetCall {
39482 c.ctx_ = ctx
39483 return c
39484 }
39485
39486
39487
39488 func (c *PlacementStrategiesGetCall) Header() http.Header {
39489 if c.header_ == nil {
39490 c.header_ = make(http.Header)
39491 }
39492 return c.header_
39493 }
39494
39495 func (c *PlacementStrategiesGetCall) doRequest(alt string) (*http.Response, error) {
39496 reqHeaders := make(http.Header)
39497 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
39498 for k, v := range c.header_ {
39499 reqHeaders[k] = v
39500 }
39501 reqHeaders.Set("User-Agent", c.s.userAgent())
39502 if c.ifNoneMatch_ != "" {
39503 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
39504 }
39505 var body io.Reader = nil
39506 c.urlParams_.Set("alt", alt)
39507 c.urlParams_.Set("prettyPrint", "false")
39508 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/placementStrategies/{id}")
39509 urls += "?" + c.urlParams_.Encode()
39510 req, err := http.NewRequest("GET", urls, body)
39511 if err != nil {
39512 return nil, err
39513 }
39514 req.Header = reqHeaders
39515 googleapi.Expand(req.URL, map[string]string{
39516 "profileId": strconv.FormatInt(c.profileId, 10),
39517 "id": strconv.FormatInt(c.id, 10),
39518 })
39519 return gensupport.SendRequest(c.ctx_, c.s.client, req)
39520 }
39521
39522
39523
39524
39525
39526
39527
39528
39529 func (c *PlacementStrategiesGetCall) Do(opts ...googleapi.CallOption) (*PlacementStrategy, error) {
39530 gensupport.SetOptions(c.urlParams_, opts...)
39531 res, err := c.doRequest("json")
39532 if res != nil && res.StatusCode == http.StatusNotModified {
39533 if res.Body != nil {
39534 res.Body.Close()
39535 }
39536 return nil, &googleapi.Error{
39537 Code: res.StatusCode,
39538 Header: res.Header,
39539 }
39540 }
39541 if err != nil {
39542 return nil, err
39543 }
39544 defer googleapi.CloseBody(res)
39545 if err := googleapi.CheckResponse(res); err != nil {
39546 return nil, err
39547 }
39548 ret := &PlacementStrategy{
39549 ServerResponse: googleapi.ServerResponse{
39550 Header: res.Header,
39551 HTTPStatusCode: res.StatusCode,
39552 },
39553 }
39554 target := &ret
39555 if err := gensupport.DecodeResponse(target, res); err != nil {
39556 return nil, err
39557 }
39558 return ret, nil
39559
39560
39561
39562
39563
39564
39565
39566
39567
39568
39569
39570
39571
39572
39573
39574
39575
39576
39577
39578
39579
39580
39581
39582
39583
39584
39585
39586
39587
39588
39589
39590
39591
39592 }
39593
39594
39595
39596 type PlacementStrategiesInsertCall struct {
39597 s *Service
39598 profileId int64
39599 placementstrategy *PlacementStrategy
39600 urlParams_ gensupport.URLParams
39601 ctx_ context.Context
39602 header_ http.Header
39603 }
39604
39605
39606 func (r *PlacementStrategiesService) Insert(profileId int64, placementstrategy *PlacementStrategy) *PlacementStrategiesInsertCall {
39607 c := &PlacementStrategiesInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
39608 c.profileId = profileId
39609 c.placementstrategy = placementstrategy
39610 return c
39611 }
39612
39613
39614
39615
39616 func (c *PlacementStrategiesInsertCall) Fields(s ...googleapi.Field) *PlacementStrategiesInsertCall {
39617 c.urlParams_.Set("fields", googleapi.CombineFields(s))
39618 return c
39619 }
39620
39621
39622
39623
39624 func (c *PlacementStrategiesInsertCall) Context(ctx context.Context) *PlacementStrategiesInsertCall {
39625 c.ctx_ = ctx
39626 return c
39627 }
39628
39629
39630
39631 func (c *PlacementStrategiesInsertCall) Header() http.Header {
39632 if c.header_ == nil {
39633 c.header_ = make(http.Header)
39634 }
39635 return c.header_
39636 }
39637
39638 func (c *PlacementStrategiesInsertCall) doRequest(alt string) (*http.Response, error) {
39639 reqHeaders := make(http.Header)
39640 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
39641 for k, v := range c.header_ {
39642 reqHeaders[k] = v
39643 }
39644 reqHeaders.Set("User-Agent", c.s.userAgent())
39645 var body io.Reader = nil
39646 body, err := googleapi.WithoutDataWrapper.JSONReader(c.placementstrategy)
39647 if err != nil {
39648 return nil, err
39649 }
39650 reqHeaders.Set("Content-Type", "application/json")
39651 c.urlParams_.Set("alt", alt)
39652 c.urlParams_.Set("prettyPrint", "false")
39653 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/placementStrategies")
39654 urls += "?" + c.urlParams_.Encode()
39655 req, err := http.NewRequest("POST", urls, body)
39656 if err != nil {
39657 return nil, err
39658 }
39659 req.Header = reqHeaders
39660 googleapi.Expand(req.URL, map[string]string{
39661 "profileId": strconv.FormatInt(c.profileId, 10),
39662 })
39663 return gensupport.SendRequest(c.ctx_, c.s.client, req)
39664 }
39665
39666
39667
39668
39669
39670
39671
39672
39673 func (c *PlacementStrategiesInsertCall) Do(opts ...googleapi.CallOption) (*PlacementStrategy, error) {
39674 gensupport.SetOptions(c.urlParams_, opts...)
39675 res, err := c.doRequest("json")
39676 if res != nil && res.StatusCode == http.StatusNotModified {
39677 if res.Body != nil {
39678 res.Body.Close()
39679 }
39680 return nil, &googleapi.Error{
39681 Code: res.StatusCode,
39682 Header: res.Header,
39683 }
39684 }
39685 if err != nil {
39686 return nil, err
39687 }
39688 defer googleapi.CloseBody(res)
39689 if err := googleapi.CheckResponse(res); err != nil {
39690 return nil, err
39691 }
39692 ret := &PlacementStrategy{
39693 ServerResponse: googleapi.ServerResponse{
39694 Header: res.Header,
39695 HTTPStatusCode: res.StatusCode,
39696 },
39697 }
39698 target := &ret
39699 if err := gensupport.DecodeResponse(target, res); err != nil {
39700 return nil, err
39701 }
39702 return ret, nil
39703
39704
39705
39706
39707
39708
39709
39710
39711
39712
39713
39714
39715
39716
39717
39718
39719
39720
39721
39722
39723
39724
39725
39726
39727
39728
39729
39730
39731 }
39732
39733
39734
39735 type PlacementStrategiesListCall struct {
39736 s *Service
39737 profileId int64
39738 urlParams_ gensupport.URLParams
39739 ifNoneMatch_ string
39740 ctx_ context.Context
39741 header_ http.Header
39742 }
39743
39744
39745
39746 func (r *PlacementStrategiesService) List(profileId int64) *PlacementStrategiesListCall {
39747 c := &PlacementStrategiesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
39748 c.profileId = profileId
39749 return c
39750 }
39751
39752
39753
39754 func (c *PlacementStrategiesListCall) Ids(ids ...int64) *PlacementStrategiesListCall {
39755 var ids_ []string
39756 for _, v := range ids {
39757 ids_ = append(ids_, fmt.Sprint(v))
39758 }
39759 c.urlParams_.SetMulti("ids", ids_)
39760 return c
39761 }
39762
39763
39764
39765 func (c *PlacementStrategiesListCall) MaxResults(maxResults int64) *PlacementStrategiesListCall {
39766 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
39767 return c
39768 }
39769
39770
39771
39772 func (c *PlacementStrategiesListCall) PageToken(pageToken string) *PlacementStrategiesListCall {
39773 c.urlParams_.Set("pageToken", pageToken)
39774 return c
39775 }
39776
39777
39778
39779
39780
39781
39782
39783
39784
39785
39786 func (c *PlacementStrategiesListCall) SearchString(searchString string) *PlacementStrategiesListCall {
39787 c.urlParams_.Set("searchString", searchString)
39788 return c
39789 }
39790
39791
39792
39793
39794
39795
39796
39797
39798 func (c *PlacementStrategiesListCall) SortField(sortField string) *PlacementStrategiesListCall {
39799 c.urlParams_.Set("sortField", sortField)
39800 return c
39801 }
39802
39803
39804
39805
39806
39807
39808
39809
39810 func (c *PlacementStrategiesListCall) SortOrder(sortOrder string) *PlacementStrategiesListCall {
39811 c.urlParams_.Set("sortOrder", sortOrder)
39812 return c
39813 }
39814
39815
39816
39817
39818 func (c *PlacementStrategiesListCall) Fields(s ...googleapi.Field) *PlacementStrategiesListCall {
39819 c.urlParams_.Set("fields", googleapi.CombineFields(s))
39820 return c
39821 }
39822
39823
39824
39825
39826
39827
39828 func (c *PlacementStrategiesListCall) IfNoneMatch(entityTag string) *PlacementStrategiesListCall {
39829 c.ifNoneMatch_ = entityTag
39830 return c
39831 }
39832
39833
39834
39835
39836 func (c *PlacementStrategiesListCall) Context(ctx context.Context) *PlacementStrategiesListCall {
39837 c.ctx_ = ctx
39838 return c
39839 }
39840
39841
39842
39843 func (c *PlacementStrategiesListCall) Header() http.Header {
39844 if c.header_ == nil {
39845 c.header_ = make(http.Header)
39846 }
39847 return c.header_
39848 }
39849
39850 func (c *PlacementStrategiesListCall) doRequest(alt string) (*http.Response, error) {
39851 reqHeaders := make(http.Header)
39852 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
39853 for k, v := range c.header_ {
39854 reqHeaders[k] = v
39855 }
39856 reqHeaders.Set("User-Agent", c.s.userAgent())
39857 if c.ifNoneMatch_ != "" {
39858 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
39859 }
39860 var body io.Reader = nil
39861 c.urlParams_.Set("alt", alt)
39862 c.urlParams_.Set("prettyPrint", "false")
39863 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/placementStrategies")
39864 urls += "?" + c.urlParams_.Encode()
39865 req, err := http.NewRequest("GET", urls, body)
39866 if err != nil {
39867 return nil, err
39868 }
39869 req.Header = reqHeaders
39870 googleapi.Expand(req.URL, map[string]string{
39871 "profileId": strconv.FormatInt(c.profileId, 10),
39872 })
39873 return gensupport.SendRequest(c.ctx_, c.s.client, req)
39874 }
39875
39876
39877
39878
39879
39880
39881
39882
39883 func (c *PlacementStrategiesListCall) Do(opts ...googleapi.CallOption) (*PlacementStrategiesListResponse, error) {
39884 gensupport.SetOptions(c.urlParams_, opts...)
39885 res, err := c.doRequest("json")
39886 if res != nil && res.StatusCode == http.StatusNotModified {
39887 if res.Body != nil {
39888 res.Body.Close()
39889 }
39890 return nil, &googleapi.Error{
39891 Code: res.StatusCode,
39892 Header: res.Header,
39893 }
39894 }
39895 if err != nil {
39896 return nil, err
39897 }
39898 defer googleapi.CloseBody(res)
39899 if err := googleapi.CheckResponse(res); err != nil {
39900 return nil, err
39901 }
39902 ret := &PlacementStrategiesListResponse{
39903 ServerResponse: googleapi.ServerResponse{
39904 Header: res.Header,
39905 HTTPStatusCode: res.StatusCode,
39906 },
39907 }
39908 target := &ret
39909 if err := gensupport.DecodeResponse(target, res); err != nil {
39910 return nil, err
39911 }
39912 return ret, nil
39913
39914
39915
39916
39917
39918
39919
39920
39921
39922
39923
39924
39925
39926
39927
39928
39929
39930
39931
39932
39933
39934
39935
39936
39937
39938
39939
39940
39941
39942
39943
39944
39945
39946
39947
39948
39949
39950
39951
39952
39953
39954
39955
39956
39957
39958
39959
39960
39961
39962
39963
39964
39965
39966
39967
39968
39969
39970
39971
39972
39973
39974
39975
39976
39977
39978
39979
39980
39981
39982
39983
39984
39985
39986
39987
39988
39989
39990
39991
39992 }
39993
39994
39995
39996
39997 func (c *PlacementStrategiesListCall) Pages(ctx context.Context, f func(*PlacementStrategiesListResponse) error) error {
39998 c.ctx_ = ctx
39999 defer c.PageToken(c.urlParams_.Get("pageToken"))
40000 for {
40001 x, err := c.Do()
40002 if err != nil {
40003 return err
40004 }
40005 if err := f(x); err != nil {
40006 return err
40007 }
40008 if x.NextPageToken == "" {
40009 return nil
40010 }
40011 c.PageToken(x.NextPageToken)
40012 }
40013 }
40014
40015
40016
40017 type PlacementStrategiesPatchCall struct {
40018 s *Service
40019 profileId int64
40020 placementstrategy *PlacementStrategy
40021 urlParams_ gensupport.URLParams
40022 ctx_ context.Context
40023 header_ http.Header
40024 }
40025
40026
40027
40028 func (r *PlacementStrategiesService) Patch(profileId int64, id int64, placementstrategy *PlacementStrategy) *PlacementStrategiesPatchCall {
40029 c := &PlacementStrategiesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
40030 c.profileId = profileId
40031 c.urlParams_.Set("id", fmt.Sprint(id))
40032 c.placementstrategy = placementstrategy
40033 return c
40034 }
40035
40036
40037
40038
40039 func (c *PlacementStrategiesPatchCall) Fields(s ...googleapi.Field) *PlacementStrategiesPatchCall {
40040 c.urlParams_.Set("fields", googleapi.CombineFields(s))
40041 return c
40042 }
40043
40044
40045
40046
40047 func (c *PlacementStrategiesPatchCall) Context(ctx context.Context) *PlacementStrategiesPatchCall {
40048 c.ctx_ = ctx
40049 return c
40050 }
40051
40052
40053
40054 func (c *PlacementStrategiesPatchCall) Header() http.Header {
40055 if c.header_ == nil {
40056 c.header_ = make(http.Header)
40057 }
40058 return c.header_
40059 }
40060
40061 func (c *PlacementStrategiesPatchCall) doRequest(alt string) (*http.Response, error) {
40062 reqHeaders := make(http.Header)
40063 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
40064 for k, v := range c.header_ {
40065 reqHeaders[k] = v
40066 }
40067 reqHeaders.Set("User-Agent", c.s.userAgent())
40068 var body io.Reader = nil
40069 body, err := googleapi.WithoutDataWrapper.JSONReader(c.placementstrategy)
40070 if err != nil {
40071 return nil, err
40072 }
40073 reqHeaders.Set("Content-Type", "application/json")
40074 c.urlParams_.Set("alt", alt)
40075 c.urlParams_.Set("prettyPrint", "false")
40076 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/placementStrategies")
40077 urls += "?" + c.urlParams_.Encode()
40078 req, err := http.NewRequest("PATCH", urls, body)
40079 if err != nil {
40080 return nil, err
40081 }
40082 req.Header = reqHeaders
40083 googleapi.Expand(req.URL, map[string]string{
40084 "profileId": strconv.FormatInt(c.profileId, 10),
40085 })
40086 return gensupport.SendRequest(c.ctx_, c.s.client, req)
40087 }
40088
40089
40090
40091
40092
40093
40094
40095
40096 func (c *PlacementStrategiesPatchCall) Do(opts ...googleapi.CallOption) (*PlacementStrategy, error) {
40097 gensupport.SetOptions(c.urlParams_, opts...)
40098 res, err := c.doRequest("json")
40099 if res != nil && res.StatusCode == http.StatusNotModified {
40100 if res.Body != nil {
40101 res.Body.Close()
40102 }
40103 return nil, &googleapi.Error{
40104 Code: res.StatusCode,
40105 Header: res.Header,
40106 }
40107 }
40108 if err != nil {
40109 return nil, err
40110 }
40111 defer googleapi.CloseBody(res)
40112 if err := googleapi.CheckResponse(res); err != nil {
40113 return nil, err
40114 }
40115 ret := &PlacementStrategy{
40116 ServerResponse: googleapi.ServerResponse{
40117 Header: res.Header,
40118 HTTPStatusCode: res.StatusCode,
40119 },
40120 }
40121 target := &ret
40122 if err := gensupport.DecodeResponse(target, res); err != nil {
40123 return nil, err
40124 }
40125 return ret, nil
40126
40127
40128
40129
40130
40131
40132
40133
40134
40135
40136
40137
40138
40139
40140
40141
40142
40143
40144
40145
40146
40147
40148
40149
40150
40151
40152
40153
40154
40155
40156
40157
40158
40159
40160
40161
40162 }
40163
40164
40165
40166 type PlacementStrategiesUpdateCall struct {
40167 s *Service
40168 profileId int64
40169 placementstrategy *PlacementStrategy
40170 urlParams_ gensupport.URLParams
40171 ctx_ context.Context
40172 header_ http.Header
40173 }
40174
40175
40176 func (r *PlacementStrategiesService) Update(profileId int64, placementstrategy *PlacementStrategy) *PlacementStrategiesUpdateCall {
40177 c := &PlacementStrategiesUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
40178 c.profileId = profileId
40179 c.placementstrategy = placementstrategy
40180 return c
40181 }
40182
40183
40184
40185
40186 func (c *PlacementStrategiesUpdateCall) Fields(s ...googleapi.Field) *PlacementStrategiesUpdateCall {
40187 c.urlParams_.Set("fields", googleapi.CombineFields(s))
40188 return c
40189 }
40190
40191
40192
40193
40194 func (c *PlacementStrategiesUpdateCall) Context(ctx context.Context) *PlacementStrategiesUpdateCall {
40195 c.ctx_ = ctx
40196 return c
40197 }
40198
40199
40200
40201 func (c *PlacementStrategiesUpdateCall) Header() http.Header {
40202 if c.header_ == nil {
40203 c.header_ = make(http.Header)
40204 }
40205 return c.header_
40206 }
40207
40208 func (c *PlacementStrategiesUpdateCall) doRequest(alt string) (*http.Response, error) {
40209 reqHeaders := make(http.Header)
40210 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
40211 for k, v := range c.header_ {
40212 reqHeaders[k] = v
40213 }
40214 reqHeaders.Set("User-Agent", c.s.userAgent())
40215 var body io.Reader = nil
40216 body, err := googleapi.WithoutDataWrapper.JSONReader(c.placementstrategy)
40217 if err != nil {
40218 return nil, err
40219 }
40220 reqHeaders.Set("Content-Type", "application/json")
40221 c.urlParams_.Set("alt", alt)
40222 c.urlParams_.Set("prettyPrint", "false")
40223 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/placementStrategies")
40224 urls += "?" + c.urlParams_.Encode()
40225 req, err := http.NewRequest("PUT", urls, body)
40226 if err != nil {
40227 return nil, err
40228 }
40229 req.Header = reqHeaders
40230 googleapi.Expand(req.URL, map[string]string{
40231 "profileId": strconv.FormatInt(c.profileId, 10),
40232 })
40233 return gensupport.SendRequest(c.ctx_, c.s.client, req)
40234 }
40235
40236
40237
40238
40239
40240
40241
40242
40243 func (c *PlacementStrategiesUpdateCall) Do(opts ...googleapi.CallOption) (*PlacementStrategy, error) {
40244 gensupport.SetOptions(c.urlParams_, opts...)
40245 res, err := c.doRequest("json")
40246 if res != nil && res.StatusCode == http.StatusNotModified {
40247 if res.Body != nil {
40248 res.Body.Close()
40249 }
40250 return nil, &googleapi.Error{
40251 Code: res.StatusCode,
40252 Header: res.Header,
40253 }
40254 }
40255 if err != nil {
40256 return nil, err
40257 }
40258 defer googleapi.CloseBody(res)
40259 if err := googleapi.CheckResponse(res); err != nil {
40260 return nil, err
40261 }
40262 ret := &PlacementStrategy{
40263 ServerResponse: googleapi.ServerResponse{
40264 Header: res.Header,
40265 HTTPStatusCode: res.StatusCode,
40266 },
40267 }
40268 target := &ret
40269 if err := gensupport.DecodeResponse(target, res); err != nil {
40270 return nil, err
40271 }
40272 return ret, nil
40273
40274
40275
40276
40277
40278
40279
40280
40281
40282
40283
40284
40285
40286
40287
40288
40289
40290
40291
40292
40293
40294
40295
40296
40297
40298
40299
40300
40301 }
40302
40303
40304
40305 type PlacementsGeneratetagsCall struct {
40306 s *Service
40307 profileId int64
40308 urlParams_ gensupport.URLParams
40309 ctx_ context.Context
40310 header_ http.Header
40311 }
40312
40313
40314 func (r *PlacementsService) Generatetags(profileId int64) *PlacementsGeneratetagsCall {
40315 c := &PlacementsGeneratetagsCall{s: r.s, urlParams_: make(gensupport.URLParams)}
40316 c.profileId = profileId
40317 return c
40318 }
40319
40320
40321
40322 func (c *PlacementsGeneratetagsCall) CampaignId(campaignId int64) *PlacementsGeneratetagsCall {
40323 c.urlParams_.Set("campaignId", fmt.Sprint(campaignId))
40324 return c
40325 }
40326
40327
40328
40329 func (c *PlacementsGeneratetagsCall) PlacementIds(placementIds ...int64) *PlacementsGeneratetagsCall {
40330 var placementIds_ []string
40331 for _, v := range placementIds {
40332 placementIds_ = append(placementIds_, fmt.Sprint(v))
40333 }
40334 c.urlParams_.SetMulti("placementIds", placementIds_)
40335 return c
40336 }
40337
40338
40339
40340
40341
40342
40343
40344
40345
40346
40347
40348
40349
40350
40351
40352
40353
40354
40355
40356
40357
40358
40359
40360
40361
40362
40363
40364
40365 func (c *PlacementsGeneratetagsCall) TagFormats(tagFormats ...string) *PlacementsGeneratetagsCall {
40366 c.urlParams_.SetMulti("tagFormats", append([]string{}, tagFormats...))
40367 return c
40368 }
40369
40370
40371
40372
40373 func (c *PlacementsGeneratetagsCall) Fields(s ...googleapi.Field) *PlacementsGeneratetagsCall {
40374 c.urlParams_.Set("fields", googleapi.CombineFields(s))
40375 return c
40376 }
40377
40378
40379
40380
40381 func (c *PlacementsGeneratetagsCall) Context(ctx context.Context) *PlacementsGeneratetagsCall {
40382 c.ctx_ = ctx
40383 return c
40384 }
40385
40386
40387
40388 func (c *PlacementsGeneratetagsCall) Header() http.Header {
40389 if c.header_ == nil {
40390 c.header_ = make(http.Header)
40391 }
40392 return c.header_
40393 }
40394
40395 func (c *PlacementsGeneratetagsCall) doRequest(alt string) (*http.Response, error) {
40396 reqHeaders := make(http.Header)
40397 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
40398 for k, v := range c.header_ {
40399 reqHeaders[k] = v
40400 }
40401 reqHeaders.Set("User-Agent", c.s.userAgent())
40402 var body io.Reader = nil
40403 c.urlParams_.Set("alt", alt)
40404 c.urlParams_.Set("prettyPrint", "false")
40405 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/placements/generatetags")
40406 urls += "?" + c.urlParams_.Encode()
40407 req, err := http.NewRequest("POST", urls, body)
40408 if err != nil {
40409 return nil, err
40410 }
40411 req.Header = reqHeaders
40412 googleapi.Expand(req.URL, map[string]string{
40413 "profileId": strconv.FormatInt(c.profileId, 10),
40414 })
40415 return gensupport.SendRequest(c.ctx_, c.s.client, req)
40416 }
40417
40418
40419
40420
40421
40422
40423
40424
40425 func (c *PlacementsGeneratetagsCall) Do(opts ...googleapi.CallOption) (*PlacementsGenerateTagsResponse, error) {
40426 gensupport.SetOptions(c.urlParams_, opts...)
40427 res, err := c.doRequest("json")
40428 if res != nil && res.StatusCode == http.StatusNotModified {
40429 if res.Body != nil {
40430 res.Body.Close()
40431 }
40432 return nil, &googleapi.Error{
40433 Code: res.StatusCode,
40434 Header: res.Header,
40435 }
40436 }
40437 if err != nil {
40438 return nil, err
40439 }
40440 defer googleapi.CloseBody(res)
40441 if err := googleapi.CheckResponse(res); err != nil {
40442 return nil, err
40443 }
40444 ret := &PlacementsGenerateTagsResponse{
40445 ServerResponse: googleapi.ServerResponse{
40446 Header: res.Header,
40447 HTTPStatusCode: res.StatusCode,
40448 },
40449 }
40450 target := &ret
40451 if err := gensupport.DecodeResponse(target, res); err != nil {
40452 return nil, err
40453 }
40454 return ret, nil
40455
40456
40457
40458
40459
40460
40461
40462
40463
40464
40465
40466
40467
40468
40469
40470
40471
40472
40473
40474
40475
40476
40477
40478
40479
40480
40481
40482
40483
40484
40485
40486
40487
40488
40489
40490
40491
40492
40493
40494
40495
40496
40497
40498
40499
40500
40501
40502
40503
40504
40505
40506
40507
40508
40509
40510
40511
40512
40513
40514
40515
40516
40517
40518
40519
40520
40521
40522
40523
40524
40525
40526
40527
40528
40529
40530
40531
40532
40533
40534
40535
40536
40537
40538
40539
40540
40541 }
40542
40543
40544
40545 type PlacementsGetCall struct {
40546 s *Service
40547 profileId int64
40548 id int64
40549 urlParams_ gensupport.URLParams
40550 ifNoneMatch_ string
40551 ctx_ context.Context
40552 header_ http.Header
40553 }
40554
40555
40556 func (r *PlacementsService) Get(profileId int64, id int64) *PlacementsGetCall {
40557 c := &PlacementsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
40558 c.profileId = profileId
40559 c.id = id
40560 return c
40561 }
40562
40563
40564
40565
40566 func (c *PlacementsGetCall) Fields(s ...googleapi.Field) *PlacementsGetCall {
40567 c.urlParams_.Set("fields", googleapi.CombineFields(s))
40568 return c
40569 }
40570
40571
40572
40573
40574
40575
40576 func (c *PlacementsGetCall) IfNoneMatch(entityTag string) *PlacementsGetCall {
40577 c.ifNoneMatch_ = entityTag
40578 return c
40579 }
40580
40581
40582
40583
40584 func (c *PlacementsGetCall) Context(ctx context.Context) *PlacementsGetCall {
40585 c.ctx_ = ctx
40586 return c
40587 }
40588
40589
40590
40591 func (c *PlacementsGetCall) Header() http.Header {
40592 if c.header_ == nil {
40593 c.header_ = make(http.Header)
40594 }
40595 return c.header_
40596 }
40597
40598 func (c *PlacementsGetCall) doRequest(alt string) (*http.Response, error) {
40599 reqHeaders := make(http.Header)
40600 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
40601 for k, v := range c.header_ {
40602 reqHeaders[k] = v
40603 }
40604 reqHeaders.Set("User-Agent", c.s.userAgent())
40605 if c.ifNoneMatch_ != "" {
40606 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
40607 }
40608 var body io.Reader = nil
40609 c.urlParams_.Set("alt", alt)
40610 c.urlParams_.Set("prettyPrint", "false")
40611 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/placements/{id}")
40612 urls += "?" + c.urlParams_.Encode()
40613 req, err := http.NewRequest("GET", urls, body)
40614 if err != nil {
40615 return nil, err
40616 }
40617 req.Header = reqHeaders
40618 googleapi.Expand(req.URL, map[string]string{
40619 "profileId": strconv.FormatInt(c.profileId, 10),
40620 "id": strconv.FormatInt(c.id, 10),
40621 })
40622 return gensupport.SendRequest(c.ctx_, c.s.client, req)
40623 }
40624
40625
40626
40627
40628
40629
40630
40631
40632 func (c *PlacementsGetCall) Do(opts ...googleapi.CallOption) (*Placement, error) {
40633 gensupport.SetOptions(c.urlParams_, opts...)
40634 res, err := c.doRequest("json")
40635 if res != nil && res.StatusCode == http.StatusNotModified {
40636 if res.Body != nil {
40637 res.Body.Close()
40638 }
40639 return nil, &googleapi.Error{
40640 Code: res.StatusCode,
40641 Header: res.Header,
40642 }
40643 }
40644 if err != nil {
40645 return nil, err
40646 }
40647 defer googleapi.CloseBody(res)
40648 if err := googleapi.CheckResponse(res); err != nil {
40649 return nil, err
40650 }
40651 ret := &Placement{
40652 ServerResponse: googleapi.ServerResponse{
40653 Header: res.Header,
40654 HTTPStatusCode: res.StatusCode,
40655 },
40656 }
40657 target := &ret
40658 if err := gensupport.DecodeResponse(target, res); err != nil {
40659 return nil, err
40660 }
40661 return ret, nil
40662
40663
40664
40665
40666
40667
40668
40669
40670
40671
40672
40673
40674
40675
40676
40677
40678
40679
40680
40681
40682
40683
40684
40685
40686
40687
40688
40689
40690
40691
40692
40693
40694
40695 }
40696
40697
40698
40699 type PlacementsInsertCall struct {
40700 s *Service
40701 profileId int64
40702 placement *Placement
40703 urlParams_ gensupport.URLParams
40704 ctx_ context.Context
40705 header_ http.Header
40706 }
40707
40708
40709 func (r *PlacementsService) Insert(profileId int64, placement *Placement) *PlacementsInsertCall {
40710 c := &PlacementsInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
40711 c.profileId = profileId
40712 c.placement = placement
40713 return c
40714 }
40715
40716
40717
40718
40719 func (c *PlacementsInsertCall) Fields(s ...googleapi.Field) *PlacementsInsertCall {
40720 c.urlParams_.Set("fields", googleapi.CombineFields(s))
40721 return c
40722 }
40723
40724
40725
40726
40727 func (c *PlacementsInsertCall) Context(ctx context.Context) *PlacementsInsertCall {
40728 c.ctx_ = ctx
40729 return c
40730 }
40731
40732
40733
40734 func (c *PlacementsInsertCall) Header() http.Header {
40735 if c.header_ == nil {
40736 c.header_ = make(http.Header)
40737 }
40738 return c.header_
40739 }
40740
40741 func (c *PlacementsInsertCall) doRequest(alt string) (*http.Response, error) {
40742 reqHeaders := make(http.Header)
40743 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
40744 for k, v := range c.header_ {
40745 reqHeaders[k] = v
40746 }
40747 reqHeaders.Set("User-Agent", c.s.userAgent())
40748 var body io.Reader = nil
40749 body, err := googleapi.WithoutDataWrapper.JSONReader(c.placement)
40750 if err != nil {
40751 return nil, err
40752 }
40753 reqHeaders.Set("Content-Type", "application/json")
40754 c.urlParams_.Set("alt", alt)
40755 c.urlParams_.Set("prettyPrint", "false")
40756 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/placements")
40757 urls += "?" + c.urlParams_.Encode()
40758 req, err := http.NewRequest("POST", urls, body)
40759 if err != nil {
40760 return nil, err
40761 }
40762 req.Header = reqHeaders
40763 googleapi.Expand(req.URL, map[string]string{
40764 "profileId": strconv.FormatInt(c.profileId, 10),
40765 })
40766 return gensupport.SendRequest(c.ctx_, c.s.client, req)
40767 }
40768
40769
40770
40771
40772
40773
40774
40775
40776 func (c *PlacementsInsertCall) Do(opts ...googleapi.CallOption) (*Placement, error) {
40777 gensupport.SetOptions(c.urlParams_, opts...)
40778 res, err := c.doRequest("json")
40779 if res != nil && res.StatusCode == http.StatusNotModified {
40780 if res.Body != nil {
40781 res.Body.Close()
40782 }
40783 return nil, &googleapi.Error{
40784 Code: res.StatusCode,
40785 Header: res.Header,
40786 }
40787 }
40788 if err != nil {
40789 return nil, err
40790 }
40791 defer googleapi.CloseBody(res)
40792 if err := googleapi.CheckResponse(res); err != nil {
40793 return nil, err
40794 }
40795 ret := &Placement{
40796 ServerResponse: googleapi.ServerResponse{
40797 Header: res.Header,
40798 HTTPStatusCode: res.StatusCode,
40799 },
40800 }
40801 target := &ret
40802 if err := gensupport.DecodeResponse(target, res); err != nil {
40803 return nil, err
40804 }
40805 return ret, nil
40806
40807
40808
40809
40810
40811
40812
40813
40814
40815
40816
40817
40818
40819
40820
40821
40822
40823
40824
40825
40826
40827
40828
40829
40830
40831
40832
40833
40834 }
40835
40836
40837
40838 type PlacementsListCall struct {
40839 s *Service
40840 profileId int64
40841 urlParams_ gensupport.URLParams
40842 ifNoneMatch_ string
40843 ctx_ context.Context
40844 header_ http.Header
40845 }
40846
40847
40848
40849 func (r *PlacementsService) List(profileId int64) *PlacementsListCall {
40850 c := &PlacementsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
40851 c.profileId = profileId
40852 return c
40853 }
40854
40855
40856
40857 func (c *PlacementsListCall) AdvertiserIds(advertiserIds ...int64) *PlacementsListCall {
40858 var advertiserIds_ []string
40859 for _, v := range advertiserIds {
40860 advertiserIds_ = append(advertiserIds_, fmt.Sprint(v))
40861 }
40862 c.urlParams_.SetMulti("advertiserIds", advertiserIds_)
40863 return c
40864 }
40865
40866
40867
40868
40869 func (c *PlacementsListCall) Archived(archived bool) *PlacementsListCall {
40870 c.urlParams_.Set("archived", fmt.Sprint(archived))
40871 return c
40872 }
40873
40874
40875
40876 func (c *PlacementsListCall) CampaignIds(campaignIds ...int64) *PlacementsListCall {
40877 var campaignIds_ []string
40878 for _, v := range campaignIds {
40879 campaignIds_ = append(campaignIds_, fmt.Sprint(v))
40880 }
40881 c.urlParams_.SetMulti("campaignIds", campaignIds_)
40882 return c
40883 }
40884
40885
40886
40887
40888
40889
40890
40891
40892
40893
40894
40895
40896
40897
40898
40899
40900
40901 func (c *PlacementsListCall) Compatibilities(compatibilities ...string) *PlacementsListCall {
40902 c.urlParams_.SetMulti("compatibilities", append([]string{}, compatibilities...))
40903 return c
40904 }
40905
40906
40907
40908
40909 func (c *PlacementsListCall) ContentCategoryIds(contentCategoryIds ...int64) *PlacementsListCall {
40910 var contentCategoryIds_ []string
40911 for _, v := range contentCategoryIds {
40912 contentCategoryIds_ = append(contentCategoryIds_, fmt.Sprint(v))
40913 }
40914 c.urlParams_.SetMulti("contentCategoryIds", contentCategoryIds_)
40915 return c
40916 }
40917
40918
40919
40920
40921 func (c *PlacementsListCall) DirectorySiteIds(directorySiteIds ...int64) *PlacementsListCall {
40922 var directorySiteIds_ []string
40923 for _, v := range directorySiteIds {
40924 directorySiteIds_ = append(directorySiteIds_, fmt.Sprint(v))
40925 }
40926 c.urlParams_.SetMulti("directorySiteIds", directorySiteIds_)
40927 return c
40928 }
40929
40930
40931
40932 func (c *PlacementsListCall) GroupIds(groupIds ...int64) *PlacementsListCall {
40933 var groupIds_ []string
40934 for _, v := range groupIds {
40935 groupIds_ = append(groupIds_, fmt.Sprint(v))
40936 }
40937 c.urlParams_.SetMulti("groupIds", groupIds_)
40938 return c
40939 }
40940
40941
40942
40943 func (c *PlacementsListCall) Ids(ids ...int64) *PlacementsListCall {
40944 var ids_ []string
40945 for _, v := range ids {
40946 ids_ = append(ids_, fmt.Sprint(v))
40947 }
40948 c.urlParams_.SetMulti("ids", ids_)
40949 return c
40950 }
40951
40952
40953
40954
40955 func (c *PlacementsListCall) MaxEndDate(maxEndDate string) *PlacementsListCall {
40956 c.urlParams_.Set("maxEndDate", maxEndDate)
40957 return c
40958 }
40959
40960
40961
40962 func (c *PlacementsListCall) MaxResults(maxResults int64) *PlacementsListCall {
40963 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
40964 return c
40965 }
40966
40967
40968
40969
40970 func (c *PlacementsListCall) MaxStartDate(maxStartDate string) *PlacementsListCall {
40971 c.urlParams_.Set("maxStartDate", maxStartDate)
40972 return c
40973 }
40974
40975
40976
40977
40978 func (c *PlacementsListCall) MinEndDate(minEndDate string) *PlacementsListCall {
40979 c.urlParams_.Set("minEndDate", minEndDate)
40980 return c
40981 }
40982
40983
40984
40985
40986 func (c *PlacementsListCall) MinStartDate(minStartDate string) *PlacementsListCall {
40987 c.urlParams_.Set("minStartDate", minStartDate)
40988 return c
40989 }
40990
40991
40992
40993 func (c *PlacementsListCall) PageToken(pageToken string) *PlacementsListCall {
40994 c.urlParams_.Set("pageToken", pageToken)
40995 return c
40996 }
40997
40998
40999
41000
41001
41002
41003
41004
41005 func (c *PlacementsListCall) PaymentSource(paymentSource string) *PlacementsListCall {
41006 c.urlParams_.Set("paymentSource", paymentSource)
41007 return c
41008 }
41009
41010
41011
41012
41013 func (c *PlacementsListCall) PlacementStrategyIds(placementStrategyIds ...int64) *PlacementsListCall {
41014 var placementStrategyIds_ []string
41015 for _, v := range placementStrategyIds {
41016 placementStrategyIds_ = append(placementStrategyIds_, fmt.Sprint(v))
41017 }
41018 c.urlParams_.SetMulti("placementStrategyIds", placementStrategyIds_)
41019 return c
41020 }
41021
41022
41023
41024
41025
41026
41027
41028
41029
41030
41031
41032
41033 func (c *PlacementsListCall) PricingTypes(pricingTypes ...string) *PlacementsListCall {
41034 c.urlParams_.SetMulti("pricingTypes", append([]string{}, pricingTypes...))
41035 return c
41036 }
41037
41038
41039
41040
41041
41042
41043
41044
41045
41046 func (c *PlacementsListCall) SearchString(searchString string) *PlacementsListCall {
41047 c.urlParams_.Set("searchString", searchString)
41048 return c
41049 }
41050
41051
41052
41053 func (c *PlacementsListCall) SiteIds(siteIds ...int64) *PlacementsListCall {
41054 var siteIds_ []string
41055 for _, v := range siteIds {
41056 siteIds_ = append(siteIds_, fmt.Sprint(v))
41057 }
41058 c.urlParams_.SetMulti("siteIds", siteIds_)
41059 return c
41060 }
41061
41062
41063
41064 func (c *PlacementsListCall) SizeIds(sizeIds ...int64) *PlacementsListCall {
41065 var sizeIds_ []string
41066 for _, v := range sizeIds {
41067 sizeIds_ = append(sizeIds_, fmt.Sprint(v))
41068 }
41069 c.urlParams_.SetMulti("sizeIds", sizeIds_)
41070 return c
41071 }
41072
41073
41074
41075
41076
41077
41078
41079
41080 func (c *PlacementsListCall) SortField(sortField string) *PlacementsListCall {
41081 c.urlParams_.Set("sortField", sortField)
41082 return c
41083 }
41084
41085
41086
41087
41088
41089
41090
41091
41092 func (c *PlacementsListCall) SortOrder(sortOrder string) *PlacementsListCall {
41093 c.urlParams_.Set("sortOrder", sortOrder)
41094 return c
41095 }
41096
41097
41098
41099
41100 func (c *PlacementsListCall) Fields(s ...googleapi.Field) *PlacementsListCall {
41101 c.urlParams_.Set("fields", googleapi.CombineFields(s))
41102 return c
41103 }
41104
41105
41106
41107
41108
41109
41110 func (c *PlacementsListCall) IfNoneMatch(entityTag string) *PlacementsListCall {
41111 c.ifNoneMatch_ = entityTag
41112 return c
41113 }
41114
41115
41116
41117
41118 func (c *PlacementsListCall) Context(ctx context.Context) *PlacementsListCall {
41119 c.ctx_ = ctx
41120 return c
41121 }
41122
41123
41124
41125 func (c *PlacementsListCall) Header() http.Header {
41126 if c.header_ == nil {
41127 c.header_ = make(http.Header)
41128 }
41129 return c.header_
41130 }
41131
41132 func (c *PlacementsListCall) doRequest(alt string) (*http.Response, error) {
41133 reqHeaders := make(http.Header)
41134 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
41135 for k, v := range c.header_ {
41136 reqHeaders[k] = v
41137 }
41138 reqHeaders.Set("User-Agent", c.s.userAgent())
41139 if c.ifNoneMatch_ != "" {
41140 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
41141 }
41142 var body io.Reader = nil
41143 c.urlParams_.Set("alt", alt)
41144 c.urlParams_.Set("prettyPrint", "false")
41145 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/placements")
41146 urls += "?" + c.urlParams_.Encode()
41147 req, err := http.NewRequest("GET", urls, body)
41148 if err != nil {
41149 return nil, err
41150 }
41151 req.Header = reqHeaders
41152 googleapi.Expand(req.URL, map[string]string{
41153 "profileId": strconv.FormatInt(c.profileId, 10),
41154 })
41155 return gensupport.SendRequest(c.ctx_, c.s.client, req)
41156 }
41157
41158
41159
41160
41161
41162
41163
41164
41165 func (c *PlacementsListCall) Do(opts ...googleapi.CallOption) (*PlacementsListResponse, error) {
41166 gensupport.SetOptions(c.urlParams_, opts...)
41167 res, err := c.doRequest("json")
41168 if res != nil && res.StatusCode == http.StatusNotModified {
41169 if res.Body != nil {
41170 res.Body.Close()
41171 }
41172 return nil, &googleapi.Error{
41173 Code: res.StatusCode,
41174 Header: res.Header,
41175 }
41176 }
41177 if err != nil {
41178 return nil, err
41179 }
41180 defer googleapi.CloseBody(res)
41181 if err := googleapi.CheckResponse(res); err != nil {
41182 return nil, err
41183 }
41184 ret := &PlacementsListResponse{
41185 ServerResponse: googleapi.ServerResponse{
41186 Header: res.Header,
41187 HTTPStatusCode: res.StatusCode,
41188 },
41189 }
41190 target := &ret
41191 if err := gensupport.DecodeResponse(target, res); err != nil {
41192 return nil, err
41193 }
41194 return ret, nil
41195
41196
41197
41198
41199
41200
41201
41202
41203
41204
41205
41206
41207
41208
41209
41210
41211
41212
41213
41214
41215
41216
41217
41218
41219
41220
41221
41222
41223
41224
41225
41226
41227
41228
41229
41230
41231
41232
41233
41234
41235
41236
41237
41238
41239
41240
41241
41242
41243
41244
41245
41246
41247
41248
41249
41250
41251
41252
41253
41254
41255
41256
41257
41258
41259
41260
41261
41262
41263
41264
41265
41266
41267
41268
41269
41270
41271
41272
41273
41274
41275
41276
41277
41278
41279
41280
41281
41282
41283
41284
41285
41286
41287
41288
41289
41290
41291
41292
41293
41294
41295
41296
41297
41298
41299
41300
41301
41302
41303
41304
41305
41306
41307
41308
41309
41310
41311
41312
41313
41314
41315
41316
41317
41318
41319
41320
41321
41322
41323
41324
41325
41326
41327
41328
41329
41330
41331
41332
41333
41334
41335
41336
41337
41338
41339
41340
41341
41342
41343
41344
41345
41346
41347
41348
41349
41350
41351
41352
41353
41354
41355
41356
41357
41358
41359
41360
41361
41362
41363
41364
41365
41366
41367
41368
41369
41370
41371
41372
41373
41374
41375
41376
41377
41378
41379
41380
41381
41382
41383
41384
41385
41386
41387
41388
41389
41390
41391
41392
41393
41394
41395
41396
41397
41398
41399
41400
41401
41402
41403
41404
41405
41406
41407
41408
41409
41410
41411
41412 }
41413
41414
41415
41416
41417 func (c *PlacementsListCall) Pages(ctx context.Context, f func(*PlacementsListResponse) error) error {
41418 c.ctx_ = ctx
41419 defer c.PageToken(c.urlParams_.Get("pageToken"))
41420 for {
41421 x, err := c.Do()
41422 if err != nil {
41423 return err
41424 }
41425 if err := f(x); err != nil {
41426 return err
41427 }
41428 if x.NextPageToken == "" {
41429 return nil
41430 }
41431 c.PageToken(x.NextPageToken)
41432 }
41433 }
41434
41435
41436
41437 type PlacementsPatchCall struct {
41438 s *Service
41439 profileId int64
41440 placement *Placement
41441 urlParams_ gensupport.URLParams
41442 ctx_ context.Context
41443 header_ http.Header
41444 }
41445
41446
41447
41448 func (r *PlacementsService) Patch(profileId int64, id int64, placement *Placement) *PlacementsPatchCall {
41449 c := &PlacementsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
41450 c.profileId = profileId
41451 c.urlParams_.Set("id", fmt.Sprint(id))
41452 c.placement = placement
41453 return c
41454 }
41455
41456
41457
41458
41459 func (c *PlacementsPatchCall) Fields(s ...googleapi.Field) *PlacementsPatchCall {
41460 c.urlParams_.Set("fields", googleapi.CombineFields(s))
41461 return c
41462 }
41463
41464
41465
41466
41467 func (c *PlacementsPatchCall) Context(ctx context.Context) *PlacementsPatchCall {
41468 c.ctx_ = ctx
41469 return c
41470 }
41471
41472
41473
41474 func (c *PlacementsPatchCall) Header() http.Header {
41475 if c.header_ == nil {
41476 c.header_ = make(http.Header)
41477 }
41478 return c.header_
41479 }
41480
41481 func (c *PlacementsPatchCall) doRequest(alt string) (*http.Response, error) {
41482 reqHeaders := make(http.Header)
41483 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
41484 for k, v := range c.header_ {
41485 reqHeaders[k] = v
41486 }
41487 reqHeaders.Set("User-Agent", c.s.userAgent())
41488 var body io.Reader = nil
41489 body, err := googleapi.WithoutDataWrapper.JSONReader(c.placement)
41490 if err != nil {
41491 return nil, err
41492 }
41493 reqHeaders.Set("Content-Type", "application/json")
41494 c.urlParams_.Set("alt", alt)
41495 c.urlParams_.Set("prettyPrint", "false")
41496 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/placements")
41497 urls += "?" + c.urlParams_.Encode()
41498 req, err := http.NewRequest("PATCH", urls, body)
41499 if err != nil {
41500 return nil, err
41501 }
41502 req.Header = reqHeaders
41503 googleapi.Expand(req.URL, map[string]string{
41504 "profileId": strconv.FormatInt(c.profileId, 10),
41505 })
41506 return gensupport.SendRequest(c.ctx_, c.s.client, req)
41507 }
41508
41509
41510
41511
41512
41513
41514
41515
41516 func (c *PlacementsPatchCall) Do(opts ...googleapi.CallOption) (*Placement, error) {
41517 gensupport.SetOptions(c.urlParams_, opts...)
41518 res, err := c.doRequest("json")
41519 if res != nil && res.StatusCode == http.StatusNotModified {
41520 if res.Body != nil {
41521 res.Body.Close()
41522 }
41523 return nil, &googleapi.Error{
41524 Code: res.StatusCode,
41525 Header: res.Header,
41526 }
41527 }
41528 if err != nil {
41529 return nil, err
41530 }
41531 defer googleapi.CloseBody(res)
41532 if err := googleapi.CheckResponse(res); err != nil {
41533 return nil, err
41534 }
41535 ret := &Placement{
41536 ServerResponse: googleapi.ServerResponse{
41537 Header: res.Header,
41538 HTTPStatusCode: res.StatusCode,
41539 },
41540 }
41541 target := &ret
41542 if err := gensupport.DecodeResponse(target, res); err != nil {
41543 return nil, err
41544 }
41545 return ret, nil
41546
41547
41548
41549
41550
41551
41552
41553
41554
41555
41556
41557
41558
41559
41560
41561
41562
41563
41564
41565
41566
41567
41568
41569
41570
41571
41572
41573
41574
41575
41576
41577
41578
41579
41580
41581
41582 }
41583
41584
41585
41586 type PlacementsUpdateCall struct {
41587 s *Service
41588 profileId int64
41589 placement *Placement
41590 urlParams_ gensupport.URLParams
41591 ctx_ context.Context
41592 header_ http.Header
41593 }
41594
41595
41596 func (r *PlacementsService) Update(profileId int64, placement *Placement) *PlacementsUpdateCall {
41597 c := &PlacementsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
41598 c.profileId = profileId
41599 c.placement = placement
41600 return c
41601 }
41602
41603
41604
41605
41606 func (c *PlacementsUpdateCall) Fields(s ...googleapi.Field) *PlacementsUpdateCall {
41607 c.urlParams_.Set("fields", googleapi.CombineFields(s))
41608 return c
41609 }
41610
41611
41612
41613
41614 func (c *PlacementsUpdateCall) Context(ctx context.Context) *PlacementsUpdateCall {
41615 c.ctx_ = ctx
41616 return c
41617 }
41618
41619
41620
41621 func (c *PlacementsUpdateCall) Header() http.Header {
41622 if c.header_ == nil {
41623 c.header_ = make(http.Header)
41624 }
41625 return c.header_
41626 }
41627
41628 func (c *PlacementsUpdateCall) doRequest(alt string) (*http.Response, error) {
41629 reqHeaders := make(http.Header)
41630 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
41631 for k, v := range c.header_ {
41632 reqHeaders[k] = v
41633 }
41634 reqHeaders.Set("User-Agent", c.s.userAgent())
41635 var body io.Reader = nil
41636 body, err := googleapi.WithoutDataWrapper.JSONReader(c.placement)
41637 if err != nil {
41638 return nil, err
41639 }
41640 reqHeaders.Set("Content-Type", "application/json")
41641 c.urlParams_.Set("alt", alt)
41642 c.urlParams_.Set("prettyPrint", "false")
41643 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/placements")
41644 urls += "?" + c.urlParams_.Encode()
41645 req, err := http.NewRequest("PUT", urls, body)
41646 if err != nil {
41647 return nil, err
41648 }
41649 req.Header = reqHeaders
41650 googleapi.Expand(req.URL, map[string]string{
41651 "profileId": strconv.FormatInt(c.profileId, 10),
41652 })
41653 return gensupport.SendRequest(c.ctx_, c.s.client, req)
41654 }
41655
41656
41657
41658
41659
41660
41661
41662
41663 func (c *PlacementsUpdateCall) Do(opts ...googleapi.CallOption) (*Placement, error) {
41664 gensupport.SetOptions(c.urlParams_, opts...)
41665 res, err := c.doRequest("json")
41666 if res != nil && res.StatusCode == http.StatusNotModified {
41667 if res.Body != nil {
41668 res.Body.Close()
41669 }
41670 return nil, &googleapi.Error{
41671 Code: res.StatusCode,
41672 Header: res.Header,
41673 }
41674 }
41675 if err != nil {
41676 return nil, err
41677 }
41678 defer googleapi.CloseBody(res)
41679 if err := googleapi.CheckResponse(res); err != nil {
41680 return nil, err
41681 }
41682 ret := &Placement{
41683 ServerResponse: googleapi.ServerResponse{
41684 Header: res.Header,
41685 HTTPStatusCode: res.StatusCode,
41686 },
41687 }
41688 target := &ret
41689 if err := gensupport.DecodeResponse(target, res); err != nil {
41690 return nil, err
41691 }
41692 return ret, nil
41693
41694
41695
41696
41697
41698
41699
41700
41701
41702
41703
41704
41705
41706
41707
41708
41709
41710
41711
41712
41713
41714
41715
41716
41717
41718
41719
41720
41721 }
41722
41723
41724
41725 type PlatformTypesGetCall struct {
41726 s *Service
41727 profileId int64
41728 id int64
41729 urlParams_ gensupport.URLParams
41730 ifNoneMatch_ string
41731 ctx_ context.Context
41732 header_ http.Header
41733 }
41734
41735
41736 func (r *PlatformTypesService) Get(profileId int64, id int64) *PlatformTypesGetCall {
41737 c := &PlatformTypesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
41738 c.profileId = profileId
41739 c.id = id
41740 return c
41741 }
41742
41743
41744
41745
41746 func (c *PlatformTypesGetCall) Fields(s ...googleapi.Field) *PlatformTypesGetCall {
41747 c.urlParams_.Set("fields", googleapi.CombineFields(s))
41748 return c
41749 }
41750
41751
41752
41753
41754
41755
41756 func (c *PlatformTypesGetCall) IfNoneMatch(entityTag string) *PlatformTypesGetCall {
41757 c.ifNoneMatch_ = entityTag
41758 return c
41759 }
41760
41761
41762
41763
41764 func (c *PlatformTypesGetCall) Context(ctx context.Context) *PlatformTypesGetCall {
41765 c.ctx_ = ctx
41766 return c
41767 }
41768
41769
41770
41771 func (c *PlatformTypesGetCall) Header() http.Header {
41772 if c.header_ == nil {
41773 c.header_ = make(http.Header)
41774 }
41775 return c.header_
41776 }
41777
41778 func (c *PlatformTypesGetCall) doRequest(alt string) (*http.Response, error) {
41779 reqHeaders := make(http.Header)
41780 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
41781 for k, v := range c.header_ {
41782 reqHeaders[k] = v
41783 }
41784 reqHeaders.Set("User-Agent", c.s.userAgent())
41785 if c.ifNoneMatch_ != "" {
41786 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
41787 }
41788 var body io.Reader = nil
41789 c.urlParams_.Set("alt", alt)
41790 c.urlParams_.Set("prettyPrint", "false")
41791 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/platformTypes/{id}")
41792 urls += "?" + c.urlParams_.Encode()
41793 req, err := http.NewRequest("GET", urls, body)
41794 if err != nil {
41795 return nil, err
41796 }
41797 req.Header = reqHeaders
41798 googleapi.Expand(req.URL, map[string]string{
41799 "profileId": strconv.FormatInt(c.profileId, 10),
41800 "id": strconv.FormatInt(c.id, 10),
41801 })
41802 return gensupport.SendRequest(c.ctx_, c.s.client, req)
41803 }
41804
41805
41806
41807
41808
41809
41810
41811
41812 func (c *PlatformTypesGetCall) Do(opts ...googleapi.CallOption) (*PlatformType, error) {
41813 gensupport.SetOptions(c.urlParams_, opts...)
41814 res, err := c.doRequest("json")
41815 if res != nil && res.StatusCode == http.StatusNotModified {
41816 if res.Body != nil {
41817 res.Body.Close()
41818 }
41819 return nil, &googleapi.Error{
41820 Code: res.StatusCode,
41821 Header: res.Header,
41822 }
41823 }
41824 if err != nil {
41825 return nil, err
41826 }
41827 defer googleapi.CloseBody(res)
41828 if err := googleapi.CheckResponse(res); err != nil {
41829 return nil, err
41830 }
41831 ret := &PlatformType{
41832 ServerResponse: googleapi.ServerResponse{
41833 Header: res.Header,
41834 HTTPStatusCode: res.StatusCode,
41835 },
41836 }
41837 target := &ret
41838 if err := gensupport.DecodeResponse(target, res); err != nil {
41839 return nil, err
41840 }
41841 return ret, nil
41842
41843
41844
41845
41846
41847
41848
41849
41850
41851
41852
41853
41854
41855
41856
41857
41858
41859
41860
41861
41862
41863
41864
41865
41866
41867
41868
41869
41870
41871
41872
41873
41874
41875 }
41876
41877
41878
41879 type PlatformTypesListCall struct {
41880 s *Service
41881 profileId int64
41882 urlParams_ gensupport.URLParams
41883 ifNoneMatch_ string
41884 ctx_ context.Context
41885 header_ http.Header
41886 }
41887
41888
41889 func (r *PlatformTypesService) List(profileId int64) *PlatformTypesListCall {
41890 c := &PlatformTypesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
41891 c.profileId = profileId
41892 return c
41893 }
41894
41895
41896
41897
41898 func (c *PlatformTypesListCall) Fields(s ...googleapi.Field) *PlatformTypesListCall {
41899 c.urlParams_.Set("fields", googleapi.CombineFields(s))
41900 return c
41901 }
41902
41903
41904
41905
41906
41907
41908 func (c *PlatformTypesListCall) IfNoneMatch(entityTag string) *PlatformTypesListCall {
41909 c.ifNoneMatch_ = entityTag
41910 return c
41911 }
41912
41913
41914
41915
41916 func (c *PlatformTypesListCall) Context(ctx context.Context) *PlatformTypesListCall {
41917 c.ctx_ = ctx
41918 return c
41919 }
41920
41921
41922
41923 func (c *PlatformTypesListCall) Header() http.Header {
41924 if c.header_ == nil {
41925 c.header_ = make(http.Header)
41926 }
41927 return c.header_
41928 }
41929
41930 func (c *PlatformTypesListCall) doRequest(alt string) (*http.Response, error) {
41931 reqHeaders := make(http.Header)
41932 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
41933 for k, v := range c.header_ {
41934 reqHeaders[k] = v
41935 }
41936 reqHeaders.Set("User-Agent", c.s.userAgent())
41937 if c.ifNoneMatch_ != "" {
41938 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
41939 }
41940 var body io.Reader = nil
41941 c.urlParams_.Set("alt", alt)
41942 c.urlParams_.Set("prettyPrint", "false")
41943 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/platformTypes")
41944 urls += "?" + c.urlParams_.Encode()
41945 req, err := http.NewRequest("GET", urls, body)
41946 if err != nil {
41947 return nil, err
41948 }
41949 req.Header = reqHeaders
41950 googleapi.Expand(req.URL, map[string]string{
41951 "profileId": strconv.FormatInt(c.profileId, 10),
41952 })
41953 return gensupport.SendRequest(c.ctx_, c.s.client, req)
41954 }
41955
41956
41957
41958
41959
41960
41961
41962
41963 func (c *PlatformTypesListCall) Do(opts ...googleapi.CallOption) (*PlatformTypesListResponse, error) {
41964 gensupport.SetOptions(c.urlParams_, opts...)
41965 res, err := c.doRequest("json")
41966 if res != nil && res.StatusCode == http.StatusNotModified {
41967 if res.Body != nil {
41968 res.Body.Close()
41969 }
41970 return nil, &googleapi.Error{
41971 Code: res.StatusCode,
41972 Header: res.Header,
41973 }
41974 }
41975 if err != nil {
41976 return nil, err
41977 }
41978 defer googleapi.CloseBody(res)
41979 if err := googleapi.CheckResponse(res); err != nil {
41980 return nil, err
41981 }
41982 ret := &PlatformTypesListResponse{
41983 ServerResponse: googleapi.ServerResponse{
41984 Header: res.Header,
41985 HTTPStatusCode: res.StatusCode,
41986 },
41987 }
41988 target := &ret
41989 if err := gensupport.DecodeResponse(target, res); err != nil {
41990 return nil, err
41991 }
41992 return ret, nil
41993
41994
41995
41996
41997
41998
41999
42000
42001
42002
42003
42004
42005
42006
42007
42008
42009
42010
42011
42012
42013
42014
42015
42016
42017
42018 }
42019
42020
42021
42022 type PostalCodesGetCall struct {
42023 s *Service
42024 profileId int64
42025 code string
42026 urlParams_ gensupport.URLParams
42027 ifNoneMatch_ string
42028 ctx_ context.Context
42029 header_ http.Header
42030 }
42031
42032
42033 func (r *PostalCodesService) Get(profileId int64, code string) *PostalCodesGetCall {
42034 c := &PostalCodesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
42035 c.profileId = profileId
42036 c.code = code
42037 return c
42038 }
42039
42040
42041
42042
42043 func (c *PostalCodesGetCall) Fields(s ...googleapi.Field) *PostalCodesGetCall {
42044 c.urlParams_.Set("fields", googleapi.CombineFields(s))
42045 return c
42046 }
42047
42048
42049
42050
42051
42052
42053 func (c *PostalCodesGetCall) IfNoneMatch(entityTag string) *PostalCodesGetCall {
42054 c.ifNoneMatch_ = entityTag
42055 return c
42056 }
42057
42058
42059
42060
42061 func (c *PostalCodesGetCall) Context(ctx context.Context) *PostalCodesGetCall {
42062 c.ctx_ = ctx
42063 return c
42064 }
42065
42066
42067
42068 func (c *PostalCodesGetCall) Header() http.Header {
42069 if c.header_ == nil {
42070 c.header_ = make(http.Header)
42071 }
42072 return c.header_
42073 }
42074
42075 func (c *PostalCodesGetCall) doRequest(alt string) (*http.Response, error) {
42076 reqHeaders := make(http.Header)
42077 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
42078 for k, v := range c.header_ {
42079 reqHeaders[k] = v
42080 }
42081 reqHeaders.Set("User-Agent", c.s.userAgent())
42082 if c.ifNoneMatch_ != "" {
42083 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
42084 }
42085 var body io.Reader = nil
42086 c.urlParams_.Set("alt", alt)
42087 c.urlParams_.Set("prettyPrint", "false")
42088 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/postalCodes/{code}")
42089 urls += "?" + c.urlParams_.Encode()
42090 req, err := http.NewRequest("GET", urls, body)
42091 if err != nil {
42092 return nil, err
42093 }
42094 req.Header = reqHeaders
42095 googleapi.Expand(req.URL, map[string]string{
42096 "profileId": strconv.FormatInt(c.profileId, 10),
42097 "code": c.code,
42098 })
42099 return gensupport.SendRequest(c.ctx_, c.s.client, req)
42100 }
42101
42102
42103
42104
42105
42106
42107
42108
42109 func (c *PostalCodesGetCall) Do(opts ...googleapi.CallOption) (*PostalCode, error) {
42110 gensupport.SetOptions(c.urlParams_, opts...)
42111 res, err := c.doRequest("json")
42112 if res != nil && res.StatusCode == http.StatusNotModified {
42113 if res.Body != nil {
42114 res.Body.Close()
42115 }
42116 return nil, &googleapi.Error{
42117 Code: res.StatusCode,
42118 Header: res.Header,
42119 }
42120 }
42121 if err != nil {
42122 return nil, err
42123 }
42124 defer googleapi.CloseBody(res)
42125 if err := googleapi.CheckResponse(res); err != nil {
42126 return nil, err
42127 }
42128 ret := &PostalCode{
42129 ServerResponse: googleapi.ServerResponse{
42130 Header: res.Header,
42131 HTTPStatusCode: res.StatusCode,
42132 },
42133 }
42134 target := &ret
42135 if err := gensupport.DecodeResponse(target, res); err != nil {
42136 return nil, err
42137 }
42138 return ret, nil
42139
42140
42141
42142
42143
42144
42145
42146
42147
42148
42149
42150
42151
42152
42153
42154
42155
42156
42157
42158
42159
42160
42161
42162
42163
42164
42165
42166
42167
42168
42169
42170
42171 }
42172
42173
42174
42175 type PostalCodesListCall struct {
42176 s *Service
42177 profileId int64
42178 urlParams_ gensupport.URLParams
42179 ifNoneMatch_ string
42180 ctx_ context.Context
42181 header_ http.Header
42182 }
42183
42184
42185 func (r *PostalCodesService) List(profileId int64) *PostalCodesListCall {
42186 c := &PostalCodesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
42187 c.profileId = profileId
42188 return c
42189 }
42190
42191
42192
42193
42194 func (c *PostalCodesListCall) Fields(s ...googleapi.Field) *PostalCodesListCall {
42195 c.urlParams_.Set("fields", googleapi.CombineFields(s))
42196 return c
42197 }
42198
42199
42200
42201
42202
42203
42204 func (c *PostalCodesListCall) IfNoneMatch(entityTag string) *PostalCodesListCall {
42205 c.ifNoneMatch_ = entityTag
42206 return c
42207 }
42208
42209
42210
42211
42212 func (c *PostalCodesListCall) Context(ctx context.Context) *PostalCodesListCall {
42213 c.ctx_ = ctx
42214 return c
42215 }
42216
42217
42218
42219 func (c *PostalCodesListCall) Header() http.Header {
42220 if c.header_ == nil {
42221 c.header_ = make(http.Header)
42222 }
42223 return c.header_
42224 }
42225
42226 func (c *PostalCodesListCall) doRequest(alt string) (*http.Response, error) {
42227 reqHeaders := make(http.Header)
42228 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
42229 for k, v := range c.header_ {
42230 reqHeaders[k] = v
42231 }
42232 reqHeaders.Set("User-Agent", c.s.userAgent())
42233 if c.ifNoneMatch_ != "" {
42234 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
42235 }
42236 var body io.Reader = nil
42237 c.urlParams_.Set("alt", alt)
42238 c.urlParams_.Set("prettyPrint", "false")
42239 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/postalCodes")
42240 urls += "?" + c.urlParams_.Encode()
42241 req, err := http.NewRequest("GET", urls, body)
42242 if err != nil {
42243 return nil, err
42244 }
42245 req.Header = reqHeaders
42246 googleapi.Expand(req.URL, map[string]string{
42247 "profileId": strconv.FormatInt(c.profileId, 10),
42248 })
42249 return gensupport.SendRequest(c.ctx_, c.s.client, req)
42250 }
42251
42252
42253
42254
42255
42256
42257
42258
42259 func (c *PostalCodesListCall) Do(opts ...googleapi.CallOption) (*PostalCodesListResponse, error) {
42260 gensupport.SetOptions(c.urlParams_, opts...)
42261 res, err := c.doRequest("json")
42262 if res != nil && res.StatusCode == http.StatusNotModified {
42263 if res.Body != nil {
42264 res.Body.Close()
42265 }
42266 return nil, &googleapi.Error{
42267 Code: res.StatusCode,
42268 Header: res.Header,
42269 }
42270 }
42271 if err != nil {
42272 return nil, err
42273 }
42274 defer googleapi.CloseBody(res)
42275 if err := googleapi.CheckResponse(res); err != nil {
42276 return nil, err
42277 }
42278 ret := &PostalCodesListResponse{
42279 ServerResponse: googleapi.ServerResponse{
42280 Header: res.Header,
42281 HTTPStatusCode: res.StatusCode,
42282 },
42283 }
42284 target := &ret
42285 if err := gensupport.DecodeResponse(target, res); err != nil {
42286 return nil, err
42287 }
42288 return ret, nil
42289
42290
42291
42292
42293
42294
42295
42296
42297
42298
42299
42300
42301
42302
42303
42304
42305
42306
42307
42308
42309
42310
42311
42312
42313
42314 }
42315
42316
42317
42318 type ProjectsGetCall struct {
42319 s *Service
42320 profileId int64
42321 id int64
42322 urlParams_ gensupport.URLParams
42323 ifNoneMatch_ string
42324 ctx_ context.Context
42325 header_ http.Header
42326 }
42327
42328
42329 func (r *ProjectsService) Get(profileId int64, id int64) *ProjectsGetCall {
42330 c := &ProjectsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
42331 c.profileId = profileId
42332 c.id = id
42333 return c
42334 }
42335
42336
42337
42338
42339 func (c *ProjectsGetCall) Fields(s ...googleapi.Field) *ProjectsGetCall {
42340 c.urlParams_.Set("fields", googleapi.CombineFields(s))
42341 return c
42342 }
42343
42344
42345
42346
42347
42348
42349 func (c *ProjectsGetCall) IfNoneMatch(entityTag string) *ProjectsGetCall {
42350 c.ifNoneMatch_ = entityTag
42351 return c
42352 }
42353
42354
42355
42356
42357 func (c *ProjectsGetCall) Context(ctx context.Context) *ProjectsGetCall {
42358 c.ctx_ = ctx
42359 return c
42360 }
42361
42362
42363
42364 func (c *ProjectsGetCall) Header() http.Header {
42365 if c.header_ == nil {
42366 c.header_ = make(http.Header)
42367 }
42368 return c.header_
42369 }
42370
42371 func (c *ProjectsGetCall) doRequest(alt string) (*http.Response, error) {
42372 reqHeaders := make(http.Header)
42373 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
42374 for k, v := range c.header_ {
42375 reqHeaders[k] = v
42376 }
42377 reqHeaders.Set("User-Agent", c.s.userAgent())
42378 if c.ifNoneMatch_ != "" {
42379 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
42380 }
42381 var body io.Reader = nil
42382 c.urlParams_.Set("alt", alt)
42383 c.urlParams_.Set("prettyPrint", "false")
42384 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/projects/{id}")
42385 urls += "?" + c.urlParams_.Encode()
42386 req, err := http.NewRequest("GET", urls, body)
42387 if err != nil {
42388 return nil, err
42389 }
42390 req.Header = reqHeaders
42391 googleapi.Expand(req.URL, map[string]string{
42392 "profileId": strconv.FormatInt(c.profileId, 10),
42393 "id": strconv.FormatInt(c.id, 10),
42394 })
42395 return gensupport.SendRequest(c.ctx_, c.s.client, req)
42396 }
42397
42398
42399
42400
42401
42402
42403
42404
42405 func (c *ProjectsGetCall) Do(opts ...googleapi.CallOption) (*Project, error) {
42406 gensupport.SetOptions(c.urlParams_, opts...)
42407 res, err := c.doRequest("json")
42408 if res != nil && res.StatusCode == http.StatusNotModified {
42409 if res.Body != nil {
42410 res.Body.Close()
42411 }
42412 return nil, &googleapi.Error{
42413 Code: res.StatusCode,
42414 Header: res.Header,
42415 }
42416 }
42417 if err != nil {
42418 return nil, err
42419 }
42420 defer googleapi.CloseBody(res)
42421 if err := googleapi.CheckResponse(res); err != nil {
42422 return nil, err
42423 }
42424 ret := &Project{
42425 ServerResponse: googleapi.ServerResponse{
42426 Header: res.Header,
42427 HTTPStatusCode: res.StatusCode,
42428 },
42429 }
42430 target := &ret
42431 if err := gensupport.DecodeResponse(target, res); err != nil {
42432 return nil, err
42433 }
42434 return ret, nil
42435
42436
42437
42438
42439
42440
42441
42442
42443
42444
42445
42446
42447
42448
42449
42450
42451
42452
42453
42454
42455
42456
42457
42458
42459
42460
42461
42462
42463
42464
42465
42466
42467
42468 }
42469
42470
42471
42472 type ProjectsListCall struct {
42473 s *Service
42474 profileId int64
42475 urlParams_ gensupport.URLParams
42476 ifNoneMatch_ string
42477 ctx_ context.Context
42478 header_ http.Header
42479 }
42480
42481
42482
42483 func (r *ProjectsService) List(profileId int64) *ProjectsListCall {
42484 c := &ProjectsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
42485 c.profileId = profileId
42486 return c
42487 }
42488
42489
42490
42491 func (c *ProjectsListCall) AdvertiserIds(advertiserIds ...int64) *ProjectsListCall {
42492 var advertiserIds_ []string
42493 for _, v := range advertiserIds {
42494 advertiserIds_ = append(advertiserIds_, fmt.Sprint(v))
42495 }
42496 c.urlParams_.SetMulti("advertiserIds", advertiserIds_)
42497 return c
42498 }
42499
42500
42501
42502 func (c *ProjectsListCall) Ids(ids ...int64) *ProjectsListCall {
42503 var ids_ []string
42504 for _, v := range ids {
42505 ids_ = append(ids_, fmt.Sprint(v))
42506 }
42507 c.urlParams_.SetMulti("ids", ids_)
42508 return c
42509 }
42510
42511
42512
42513 func (c *ProjectsListCall) MaxResults(maxResults int64) *ProjectsListCall {
42514 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
42515 return c
42516 }
42517
42518
42519
42520 func (c *ProjectsListCall) PageToken(pageToken string) *ProjectsListCall {
42521 c.urlParams_.Set("pageToken", pageToken)
42522 return c
42523 }
42524
42525
42526
42527
42528
42529
42530
42531
42532
42533 func (c *ProjectsListCall) SearchString(searchString string) *ProjectsListCall {
42534 c.urlParams_.Set("searchString", searchString)
42535 return c
42536 }
42537
42538
42539
42540
42541
42542
42543
42544
42545 func (c *ProjectsListCall) SortField(sortField string) *ProjectsListCall {
42546 c.urlParams_.Set("sortField", sortField)
42547 return c
42548 }
42549
42550
42551
42552
42553
42554
42555
42556
42557 func (c *ProjectsListCall) SortOrder(sortOrder string) *ProjectsListCall {
42558 c.urlParams_.Set("sortOrder", sortOrder)
42559 return c
42560 }
42561
42562
42563
42564
42565 func (c *ProjectsListCall) Fields(s ...googleapi.Field) *ProjectsListCall {
42566 c.urlParams_.Set("fields", googleapi.CombineFields(s))
42567 return c
42568 }
42569
42570
42571
42572
42573
42574
42575 func (c *ProjectsListCall) IfNoneMatch(entityTag string) *ProjectsListCall {
42576 c.ifNoneMatch_ = entityTag
42577 return c
42578 }
42579
42580
42581
42582
42583 func (c *ProjectsListCall) Context(ctx context.Context) *ProjectsListCall {
42584 c.ctx_ = ctx
42585 return c
42586 }
42587
42588
42589
42590 func (c *ProjectsListCall) Header() http.Header {
42591 if c.header_ == nil {
42592 c.header_ = make(http.Header)
42593 }
42594 return c.header_
42595 }
42596
42597 func (c *ProjectsListCall) doRequest(alt string) (*http.Response, error) {
42598 reqHeaders := make(http.Header)
42599 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
42600 for k, v := range c.header_ {
42601 reqHeaders[k] = v
42602 }
42603 reqHeaders.Set("User-Agent", c.s.userAgent())
42604 if c.ifNoneMatch_ != "" {
42605 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
42606 }
42607 var body io.Reader = nil
42608 c.urlParams_.Set("alt", alt)
42609 c.urlParams_.Set("prettyPrint", "false")
42610 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/projects")
42611 urls += "?" + c.urlParams_.Encode()
42612 req, err := http.NewRequest("GET", urls, body)
42613 if err != nil {
42614 return nil, err
42615 }
42616 req.Header = reqHeaders
42617 googleapi.Expand(req.URL, map[string]string{
42618 "profileId": strconv.FormatInt(c.profileId, 10),
42619 })
42620 return gensupport.SendRequest(c.ctx_, c.s.client, req)
42621 }
42622
42623
42624
42625
42626
42627
42628
42629
42630 func (c *ProjectsListCall) Do(opts ...googleapi.CallOption) (*ProjectsListResponse, error) {
42631 gensupport.SetOptions(c.urlParams_, opts...)
42632 res, err := c.doRequest("json")
42633 if res != nil && res.StatusCode == http.StatusNotModified {
42634 if res.Body != nil {
42635 res.Body.Close()
42636 }
42637 return nil, &googleapi.Error{
42638 Code: res.StatusCode,
42639 Header: res.Header,
42640 }
42641 }
42642 if err != nil {
42643 return nil, err
42644 }
42645 defer googleapi.CloseBody(res)
42646 if err := googleapi.CheckResponse(res); err != nil {
42647 return nil, err
42648 }
42649 ret := &ProjectsListResponse{
42650 ServerResponse: googleapi.ServerResponse{
42651 Header: res.Header,
42652 HTTPStatusCode: res.StatusCode,
42653 },
42654 }
42655 target := &ret
42656 if err := gensupport.DecodeResponse(target, res); err != nil {
42657 return nil, err
42658 }
42659 return ret, nil
42660
42661
42662
42663
42664
42665
42666
42667
42668
42669
42670
42671
42672
42673
42674
42675
42676
42677
42678
42679
42680
42681
42682
42683
42684
42685
42686
42687
42688
42689
42690
42691
42692
42693
42694
42695
42696
42697
42698
42699
42700
42701
42702
42703
42704
42705
42706
42707
42708
42709
42710
42711
42712
42713
42714
42715
42716
42717
42718
42719
42720
42721
42722
42723
42724
42725
42726
42727
42728
42729
42730
42731
42732
42733
42734
42735
42736
42737
42738
42739
42740
42741
42742
42743
42744
42745
42746 }
42747
42748
42749
42750
42751 func (c *ProjectsListCall) Pages(ctx context.Context, f func(*ProjectsListResponse) error) error {
42752 c.ctx_ = ctx
42753 defer c.PageToken(c.urlParams_.Get("pageToken"))
42754 for {
42755 x, err := c.Do()
42756 if err != nil {
42757 return err
42758 }
42759 if err := f(x); err != nil {
42760 return err
42761 }
42762 if x.NextPageToken == "" {
42763 return nil
42764 }
42765 c.PageToken(x.NextPageToken)
42766 }
42767 }
42768
42769
42770
42771 type RegionsListCall struct {
42772 s *Service
42773 profileId int64
42774 urlParams_ gensupport.URLParams
42775 ifNoneMatch_ string
42776 ctx_ context.Context
42777 header_ http.Header
42778 }
42779
42780
42781 func (r *RegionsService) List(profileId int64) *RegionsListCall {
42782 c := &RegionsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
42783 c.profileId = profileId
42784 return c
42785 }
42786
42787
42788
42789
42790 func (c *RegionsListCall) Fields(s ...googleapi.Field) *RegionsListCall {
42791 c.urlParams_.Set("fields", googleapi.CombineFields(s))
42792 return c
42793 }
42794
42795
42796
42797
42798
42799
42800 func (c *RegionsListCall) IfNoneMatch(entityTag string) *RegionsListCall {
42801 c.ifNoneMatch_ = entityTag
42802 return c
42803 }
42804
42805
42806
42807
42808 func (c *RegionsListCall) Context(ctx context.Context) *RegionsListCall {
42809 c.ctx_ = ctx
42810 return c
42811 }
42812
42813
42814
42815 func (c *RegionsListCall) Header() http.Header {
42816 if c.header_ == nil {
42817 c.header_ = make(http.Header)
42818 }
42819 return c.header_
42820 }
42821
42822 func (c *RegionsListCall) doRequest(alt string) (*http.Response, error) {
42823 reqHeaders := make(http.Header)
42824 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
42825 for k, v := range c.header_ {
42826 reqHeaders[k] = v
42827 }
42828 reqHeaders.Set("User-Agent", c.s.userAgent())
42829 if c.ifNoneMatch_ != "" {
42830 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
42831 }
42832 var body io.Reader = nil
42833 c.urlParams_.Set("alt", alt)
42834 c.urlParams_.Set("prettyPrint", "false")
42835 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/regions")
42836 urls += "?" + c.urlParams_.Encode()
42837 req, err := http.NewRequest("GET", urls, body)
42838 if err != nil {
42839 return nil, err
42840 }
42841 req.Header = reqHeaders
42842 googleapi.Expand(req.URL, map[string]string{
42843 "profileId": strconv.FormatInt(c.profileId, 10),
42844 })
42845 return gensupport.SendRequest(c.ctx_, c.s.client, req)
42846 }
42847
42848
42849
42850
42851
42852
42853
42854
42855 func (c *RegionsListCall) Do(opts ...googleapi.CallOption) (*RegionsListResponse, error) {
42856 gensupport.SetOptions(c.urlParams_, opts...)
42857 res, err := c.doRequest("json")
42858 if res != nil && res.StatusCode == http.StatusNotModified {
42859 if res.Body != nil {
42860 res.Body.Close()
42861 }
42862 return nil, &googleapi.Error{
42863 Code: res.StatusCode,
42864 Header: res.Header,
42865 }
42866 }
42867 if err != nil {
42868 return nil, err
42869 }
42870 defer googleapi.CloseBody(res)
42871 if err := googleapi.CheckResponse(res); err != nil {
42872 return nil, err
42873 }
42874 ret := &RegionsListResponse{
42875 ServerResponse: googleapi.ServerResponse{
42876 Header: res.Header,
42877 HTTPStatusCode: res.StatusCode,
42878 },
42879 }
42880 target := &ret
42881 if err := gensupport.DecodeResponse(target, res); err != nil {
42882 return nil, err
42883 }
42884 return ret, nil
42885
42886
42887
42888
42889
42890
42891
42892
42893
42894
42895
42896
42897
42898
42899
42900
42901
42902
42903
42904
42905
42906
42907
42908
42909
42910 }
42911
42912
42913
42914 type RemarketingListSharesGetCall struct {
42915 s *Service
42916 profileId int64
42917 remarketingListId int64
42918 urlParams_ gensupport.URLParams
42919 ifNoneMatch_ string
42920 ctx_ context.Context
42921 header_ http.Header
42922 }
42923
42924
42925 func (r *RemarketingListSharesService) Get(profileId int64, remarketingListId int64) *RemarketingListSharesGetCall {
42926 c := &RemarketingListSharesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
42927 c.profileId = profileId
42928 c.remarketingListId = remarketingListId
42929 return c
42930 }
42931
42932
42933
42934
42935 func (c *RemarketingListSharesGetCall) Fields(s ...googleapi.Field) *RemarketingListSharesGetCall {
42936 c.urlParams_.Set("fields", googleapi.CombineFields(s))
42937 return c
42938 }
42939
42940
42941
42942
42943
42944
42945 func (c *RemarketingListSharesGetCall) IfNoneMatch(entityTag string) *RemarketingListSharesGetCall {
42946 c.ifNoneMatch_ = entityTag
42947 return c
42948 }
42949
42950
42951
42952
42953 func (c *RemarketingListSharesGetCall) Context(ctx context.Context) *RemarketingListSharesGetCall {
42954 c.ctx_ = ctx
42955 return c
42956 }
42957
42958
42959
42960 func (c *RemarketingListSharesGetCall) Header() http.Header {
42961 if c.header_ == nil {
42962 c.header_ = make(http.Header)
42963 }
42964 return c.header_
42965 }
42966
42967 func (c *RemarketingListSharesGetCall) doRequest(alt string) (*http.Response, error) {
42968 reqHeaders := make(http.Header)
42969 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
42970 for k, v := range c.header_ {
42971 reqHeaders[k] = v
42972 }
42973 reqHeaders.Set("User-Agent", c.s.userAgent())
42974 if c.ifNoneMatch_ != "" {
42975 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
42976 }
42977 var body io.Reader = nil
42978 c.urlParams_.Set("alt", alt)
42979 c.urlParams_.Set("prettyPrint", "false")
42980 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/remarketingListShares/{remarketingListId}")
42981 urls += "?" + c.urlParams_.Encode()
42982 req, err := http.NewRequest("GET", urls, body)
42983 if err != nil {
42984 return nil, err
42985 }
42986 req.Header = reqHeaders
42987 googleapi.Expand(req.URL, map[string]string{
42988 "profileId": strconv.FormatInt(c.profileId, 10),
42989 "remarketingListId": strconv.FormatInt(c.remarketingListId, 10),
42990 })
42991 return gensupport.SendRequest(c.ctx_, c.s.client, req)
42992 }
42993
42994
42995
42996
42997
42998
42999
43000
43001 func (c *RemarketingListSharesGetCall) Do(opts ...googleapi.CallOption) (*RemarketingListShare, error) {
43002 gensupport.SetOptions(c.urlParams_, opts...)
43003 res, err := c.doRequest("json")
43004 if res != nil && res.StatusCode == http.StatusNotModified {
43005 if res.Body != nil {
43006 res.Body.Close()
43007 }
43008 return nil, &googleapi.Error{
43009 Code: res.StatusCode,
43010 Header: res.Header,
43011 }
43012 }
43013 if err != nil {
43014 return nil, err
43015 }
43016 defer googleapi.CloseBody(res)
43017 if err := googleapi.CheckResponse(res); err != nil {
43018 return nil, err
43019 }
43020 ret := &RemarketingListShare{
43021 ServerResponse: googleapi.ServerResponse{
43022 Header: res.Header,
43023 HTTPStatusCode: res.StatusCode,
43024 },
43025 }
43026 target := &ret
43027 if err := gensupport.DecodeResponse(target, res); err != nil {
43028 return nil, err
43029 }
43030 return ret, nil
43031
43032
43033
43034
43035
43036
43037
43038
43039
43040
43041
43042
43043
43044
43045
43046
43047
43048
43049
43050
43051
43052
43053
43054
43055
43056
43057
43058
43059
43060
43061
43062
43063
43064 }
43065
43066
43067
43068 type RemarketingListSharesPatchCall struct {
43069 s *Service
43070 profileId int64
43071 remarketinglistshare *RemarketingListShare
43072 urlParams_ gensupport.URLParams
43073 ctx_ context.Context
43074 header_ http.Header
43075 }
43076
43077
43078
43079 func (r *RemarketingListSharesService) Patch(profileId int64, remarketingListId int64, remarketinglistshare *RemarketingListShare) *RemarketingListSharesPatchCall {
43080 c := &RemarketingListSharesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
43081 c.profileId = profileId
43082 c.urlParams_.Set("remarketingListId", fmt.Sprint(remarketingListId))
43083 c.remarketinglistshare = remarketinglistshare
43084 return c
43085 }
43086
43087
43088
43089
43090 func (c *RemarketingListSharesPatchCall) Fields(s ...googleapi.Field) *RemarketingListSharesPatchCall {
43091 c.urlParams_.Set("fields", googleapi.CombineFields(s))
43092 return c
43093 }
43094
43095
43096
43097
43098 func (c *RemarketingListSharesPatchCall) Context(ctx context.Context) *RemarketingListSharesPatchCall {
43099 c.ctx_ = ctx
43100 return c
43101 }
43102
43103
43104
43105 func (c *RemarketingListSharesPatchCall) Header() http.Header {
43106 if c.header_ == nil {
43107 c.header_ = make(http.Header)
43108 }
43109 return c.header_
43110 }
43111
43112 func (c *RemarketingListSharesPatchCall) doRequest(alt string) (*http.Response, error) {
43113 reqHeaders := make(http.Header)
43114 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
43115 for k, v := range c.header_ {
43116 reqHeaders[k] = v
43117 }
43118 reqHeaders.Set("User-Agent", c.s.userAgent())
43119 var body io.Reader = nil
43120 body, err := googleapi.WithoutDataWrapper.JSONReader(c.remarketinglistshare)
43121 if err != nil {
43122 return nil, err
43123 }
43124 reqHeaders.Set("Content-Type", "application/json")
43125 c.urlParams_.Set("alt", alt)
43126 c.urlParams_.Set("prettyPrint", "false")
43127 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/remarketingListShares")
43128 urls += "?" + c.urlParams_.Encode()
43129 req, err := http.NewRequest("PATCH", urls, body)
43130 if err != nil {
43131 return nil, err
43132 }
43133 req.Header = reqHeaders
43134 googleapi.Expand(req.URL, map[string]string{
43135 "profileId": strconv.FormatInt(c.profileId, 10),
43136 })
43137 return gensupport.SendRequest(c.ctx_, c.s.client, req)
43138 }
43139
43140
43141
43142
43143
43144
43145
43146
43147 func (c *RemarketingListSharesPatchCall) Do(opts ...googleapi.CallOption) (*RemarketingListShare, error) {
43148 gensupport.SetOptions(c.urlParams_, opts...)
43149 res, err := c.doRequest("json")
43150 if res != nil && res.StatusCode == http.StatusNotModified {
43151 if res.Body != nil {
43152 res.Body.Close()
43153 }
43154 return nil, &googleapi.Error{
43155 Code: res.StatusCode,
43156 Header: res.Header,
43157 }
43158 }
43159 if err != nil {
43160 return nil, err
43161 }
43162 defer googleapi.CloseBody(res)
43163 if err := googleapi.CheckResponse(res); err != nil {
43164 return nil, err
43165 }
43166 ret := &RemarketingListShare{
43167 ServerResponse: googleapi.ServerResponse{
43168 Header: res.Header,
43169 HTTPStatusCode: res.StatusCode,
43170 },
43171 }
43172 target := &ret
43173 if err := gensupport.DecodeResponse(target, res); err != nil {
43174 return nil, err
43175 }
43176 return ret, nil
43177
43178
43179
43180
43181
43182
43183
43184
43185
43186
43187
43188
43189
43190
43191
43192
43193
43194
43195
43196
43197
43198
43199
43200
43201
43202
43203
43204
43205
43206
43207
43208
43209
43210
43211
43212
43213 }
43214
43215
43216
43217 type RemarketingListSharesUpdateCall struct {
43218 s *Service
43219 profileId int64
43220 remarketinglistshare *RemarketingListShare
43221 urlParams_ gensupport.URLParams
43222 ctx_ context.Context
43223 header_ http.Header
43224 }
43225
43226
43227 func (r *RemarketingListSharesService) Update(profileId int64, remarketinglistshare *RemarketingListShare) *RemarketingListSharesUpdateCall {
43228 c := &RemarketingListSharesUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
43229 c.profileId = profileId
43230 c.remarketinglistshare = remarketinglistshare
43231 return c
43232 }
43233
43234
43235
43236
43237 func (c *RemarketingListSharesUpdateCall) Fields(s ...googleapi.Field) *RemarketingListSharesUpdateCall {
43238 c.urlParams_.Set("fields", googleapi.CombineFields(s))
43239 return c
43240 }
43241
43242
43243
43244
43245 func (c *RemarketingListSharesUpdateCall) Context(ctx context.Context) *RemarketingListSharesUpdateCall {
43246 c.ctx_ = ctx
43247 return c
43248 }
43249
43250
43251
43252 func (c *RemarketingListSharesUpdateCall) Header() http.Header {
43253 if c.header_ == nil {
43254 c.header_ = make(http.Header)
43255 }
43256 return c.header_
43257 }
43258
43259 func (c *RemarketingListSharesUpdateCall) doRequest(alt string) (*http.Response, error) {
43260 reqHeaders := make(http.Header)
43261 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
43262 for k, v := range c.header_ {
43263 reqHeaders[k] = v
43264 }
43265 reqHeaders.Set("User-Agent", c.s.userAgent())
43266 var body io.Reader = nil
43267 body, err := googleapi.WithoutDataWrapper.JSONReader(c.remarketinglistshare)
43268 if err != nil {
43269 return nil, err
43270 }
43271 reqHeaders.Set("Content-Type", "application/json")
43272 c.urlParams_.Set("alt", alt)
43273 c.urlParams_.Set("prettyPrint", "false")
43274 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/remarketingListShares")
43275 urls += "?" + c.urlParams_.Encode()
43276 req, err := http.NewRequest("PUT", urls, body)
43277 if err != nil {
43278 return nil, err
43279 }
43280 req.Header = reqHeaders
43281 googleapi.Expand(req.URL, map[string]string{
43282 "profileId": strconv.FormatInt(c.profileId, 10),
43283 })
43284 return gensupport.SendRequest(c.ctx_, c.s.client, req)
43285 }
43286
43287
43288
43289
43290
43291
43292
43293
43294 func (c *RemarketingListSharesUpdateCall) Do(opts ...googleapi.CallOption) (*RemarketingListShare, error) {
43295 gensupport.SetOptions(c.urlParams_, opts...)
43296 res, err := c.doRequest("json")
43297 if res != nil && res.StatusCode == http.StatusNotModified {
43298 if res.Body != nil {
43299 res.Body.Close()
43300 }
43301 return nil, &googleapi.Error{
43302 Code: res.StatusCode,
43303 Header: res.Header,
43304 }
43305 }
43306 if err != nil {
43307 return nil, err
43308 }
43309 defer googleapi.CloseBody(res)
43310 if err := googleapi.CheckResponse(res); err != nil {
43311 return nil, err
43312 }
43313 ret := &RemarketingListShare{
43314 ServerResponse: googleapi.ServerResponse{
43315 Header: res.Header,
43316 HTTPStatusCode: res.StatusCode,
43317 },
43318 }
43319 target := &ret
43320 if err := gensupport.DecodeResponse(target, res); err != nil {
43321 return nil, err
43322 }
43323 return ret, nil
43324
43325
43326
43327
43328
43329
43330
43331
43332
43333
43334
43335
43336
43337
43338
43339
43340
43341
43342
43343
43344
43345
43346
43347
43348
43349
43350
43351
43352 }
43353
43354
43355
43356 type RemarketingListsGetCall struct {
43357 s *Service
43358 profileId int64
43359 id int64
43360 urlParams_ gensupport.URLParams
43361 ifNoneMatch_ string
43362 ctx_ context.Context
43363 header_ http.Header
43364 }
43365
43366
43367 func (r *RemarketingListsService) Get(profileId int64, id int64) *RemarketingListsGetCall {
43368 c := &RemarketingListsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
43369 c.profileId = profileId
43370 c.id = id
43371 return c
43372 }
43373
43374
43375
43376
43377 func (c *RemarketingListsGetCall) Fields(s ...googleapi.Field) *RemarketingListsGetCall {
43378 c.urlParams_.Set("fields", googleapi.CombineFields(s))
43379 return c
43380 }
43381
43382
43383
43384
43385
43386
43387 func (c *RemarketingListsGetCall) IfNoneMatch(entityTag string) *RemarketingListsGetCall {
43388 c.ifNoneMatch_ = entityTag
43389 return c
43390 }
43391
43392
43393
43394
43395 func (c *RemarketingListsGetCall) Context(ctx context.Context) *RemarketingListsGetCall {
43396 c.ctx_ = ctx
43397 return c
43398 }
43399
43400
43401
43402 func (c *RemarketingListsGetCall) Header() http.Header {
43403 if c.header_ == nil {
43404 c.header_ = make(http.Header)
43405 }
43406 return c.header_
43407 }
43408
43409 func (c *RemarketingListsGetCall) doRequest(alt string) (*http.Response, error) {
43410 reqHeaders := make(http.Header)
43411 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
43412 for k, v := range c.header_ {
43413 reqHeaders[k] = v
43414 }
43415 reqHeaders.Set("User-Agent", c.s.userAgent())
43416 if c.ifNoneMatch_ != "" {
43417 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
43418 }
43419 var body io.Reader = nil
43420 c.urlParams_.Set("alt", alt)
43421 c.urlParams_.Set("prettyPrint", "false")
43422 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/remarketingLists/{id}")
43423 urls += "?" + c.urlParams_.Encode()
43424 req, err := http.NewRequest("GET", urls, body)
43425 if err != nil {
43426 return nil, err
43427 }
43428 req.Header = reqHeaders
43429 googleapi.Expand(req.URL, map[string]string{
43430 "profileId": strconv.FormatInt(c.profileId, 10),
43431 "id": strconv.FormatInt(c.id, 10),
43432 })
43433 return gensupport.SendRequest(c.ctx_, c.s.client, req)
43434 }
43435
43436
43437
43438
43439
43440
43441
43442
43443 func (c *RemarketingListsGetCall) Do(opts ...googleapi.CallOption) (*RemarketingList, error) {
43444 gensupport.SetOptions(c.urlParams_, opts...)
43445 res, err := c.doRequest("json")
43446 if res != nil && res.StatusCode == http.StatusNotModified {
43447 if res.Body != nil {
43448 res.Body.Close()
43449 }
43450 return nil, &googleapi.Error{
43451 Code: res.StatusCode,
43452 Header: res.Header,
43453 }
43454 }
43455 if err != nil {
43456 return nil, err
43457 }
43458 defer googleapi.CloseBody(res)
43459 if err := googleapi.CheckResponse(res); err != nil {
43460 return nil, err
43461 }
43462 ret := &RemarketingList{
43463 ServerResponse: googleapi.ServerResponse{
43464 Header: res.Header,
43465 HTTPStatusCode: res.StatusCode,
43466 },
43467 }
43468 target := &ret
43469 if err := gensupport.DecodeResponse(target, res); err != nil {
43470 return nil, err
43471 }
43472 return ret, nil
43473
43474
43475
43476
43477
43478
43479
43480
43481
43482
43483
43484
43485
43486
43487
43488
43489
43490
43491
43492
43493
43494
43495
43496
43497
43498
43499
43500
43501
43502
43503
43504
43505
43506 }
43507
43508
43509
43510 type RemarketingListsInsertCall struct {
43511 s *Service
43512 profileId int64
43513 remarketinglist *RemarketingList
43514 urlParams_ gensupport.URLParams
43515 ctx_ context.Context
43516 header_ http.Header
43517 }
43518
43519
43520 func (r *RemarketingListsService) Insert(profileId int64, remarketinglist *RemarketingList) *RemarketingListsInsertCall {
43521 c := &RemarketingListsInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
43522 c.profileId = profileId
43523 c.remarketinglist = remarketinglist
43524 return c
43525 }
43526
43527
43528
43529
43530 func (c *RemarketingListsInsertCall) Fields(s ...googleapi.Field) *RemarketingListsInsertCall {
43531 c.urlParams_.Set("fields", googleapi.CombineFields(s))
43532 return c
43533 }
43534
43535
43536
43537
43538 func (c *RemarketingListsInsertCall) Context(ctx context.Context) *RemarketingListsInsertCall {
43539 c.ctx_ = ctx
43540 return c
43541 }
43542
43543
43544
43545 func (c *RemarketingListsInsertCall) Header() http.Header {
43546 if c.header_ == nil {
43547 c.header_ = make(http.Header)
43548 }
43549 return c.header_
43550 }
43551
43552 func (c *RemarketingListsInsertCall) doRequest(alt string) (*http.Response, error) {
43553 reqHeaders := make(http.Header)
43554 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
43555 for k, v := range c.header_ {
43556 reqHeaders[k] = v
43557 }
43558 reqHeaders.Set("User-Agent", c.s.userAgent())
43559 var body io.Reader = nil
43560 body, err := googleapi.WithoutDataWrapper.JSONReader(c.remarketinglist)
43561 if err != nil {
43562 return nil, err
43563 }
43564 reqHeaders.Set("Content-Type", "application/json")
43565 c.urlParams_.Set("alt", alt)
43566 c.urlParams_.Set("prettyPrint", "false")
43567 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/remarketingLists")
43568 urls += "?" + c.urlParams_.Encode()
43569 req, err := http.NewRequest("POST", urls, body)
43570 if err != nil {
43571 return nil, err
43572 }
43573 req.Header = reqHeaders
43574 googleapi.Expand(req.URL, map[string]string{
43575 "profileId": strconv.FormatInt(c.profileId, 10),
43576 })
43577 return gensupport.SendRequest(c.ctx_, c.s.client, req)
43578 }
43579
43580
43581
43582
43583
43584
43585
43586
43587 func (c *RemarketingListsInsertCall) Do(opts ...googleapi.CallOption) (*RemarketingList, error) {
43588 gensupport.SetOptions(c.urlParams_, opts...)
43589 res, err := c.doRequest("json")
43590 if res != nil && res.StatusCode == http.StatusNotModified {
43591 if res.Body != nil {
43592 res.Body.Close()
43593 }
43594 return nil, &googleapi.Error{
43595 Code: res.StatusCode,
43596 Header: res.Header,
43597 }
43598 }
43599 if err != nil {
43600 return nil, err
43601 }
43602 defer googleapi.CloseBody(res)
43603 if err := googleapi.CheckResponse(res); err != nil {
43604 return nil, err
43605 }
43606 ret := &RemarketingList{
43607 ServerResponse: googleapi.ServerResponse{
43608 Header: res.Header,
43609 HTTPStatusCode: res.StatusCode,
43610 },
43611 }
43612 target := &ret
43613 if err := gensupport.DecodeResponse(target, res); err != nil {
43614 return nil, err
43615 }
43616 return ret, nil
43617
43618
43619
43620
43621
43622
43623
43624
43625
43626
43627
43628
43629
43630
43631
43632
43633
43634
43635
43636
43637
43638
43639
43640
43641
43642
43643
43644
43645 }
43646
43647
43648
43649 type RemarketingListsListCall struct {
43650 s *Service
43651 profileId int64
43652 urlParams_ gensupport.URLParams
43653 ifNoneMatch_ string
43654 ctx_ context.Context
43655 header_ http.Header
43656 }
43657
43658
43659
43660 func (r *RemarketingListsService) List(profileId int64, advertiserId int64) *RemarketingListsListCall {
43661 c := &RemarketingListsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
43662 c.profileId = profileId
43663 c.urlParams_.Set("advertiserId", fmt.Sprint(advertiserId))
43664 return c
43665 }
43666
43667
43668
43669 func (c *RemarketingListsListCall) Active(active bool) *RemarketingListsListCall {
43670 c.urlParams_.Set("active", fmt.Sprint(active))
43671 return c
43672 }
43673
43674
43675
43676
43677 func (c *RemarketingListsListCall) FloodlightActivityId(floodlightActivityId int64) *RemarketingListsListCall {
43678 c.urlParams_.Set("floodlightActivityId", fmt.Sprint(floodlightActivityId))
43679 return c
43680 }
43681
43682
43683
43684 func (c *RemarketingListsListCall) MaxResults(maxResults int64) *RemarketingListsListCall {
43685 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
43686 return c
43687 }
43688
43689
43690
43691
43692
43693
43694
43695
43696
43697 func (c *RemarketingListsListCall) Name(name string) *RemarketingListsListCall {
43698 c.urlParams_.Set("name", name)
43699 return c
43700 }
43701
43702
43703
43704 func (c *RemarketingListsListCall) PageToken(pageToken string) *RemarketingListsListCall {
43705 c.urlParams_.Set("pageToken", pageToken)
43706 return c
43707 }
43708
43709
43710
43711
43712
43713
43714
43715
43716 func (c *RemarketingListsListCall) SortField(sortField string) *RemarketingListsListCall {
43717 c.urlParams_.Set("sortField", sortField)
43718 return c
43719 }
43720
43721
43722
43723
43724
43725
43726
43727
43728 func (c *RemarketingListsListCall) SortOrder(sortOrder string) *RemarketingListsListCall {
43729 c.urlParams_.Set("sortOrder", sortOrder)
43730 return c
43731 }
43732
43733
43734
43735
43736 func (c *RemarketingListsListCall) Fields(s ...googleapi.Field) *RemarketingListsListCall {
43737 c.urlParams_.Set("fields", googleapi.CombineFields(s))
43738 return c
43739 }
43740
43741
43742
43743
43744
43745
43746 func (c *RemarketingListsListCall) IfNoneMatch(entityTag string) *RemarketingListsListCall {
43747 c.ifNoneMatch_ = entityTag
43748 return c
43749 }
43750
43751
43752
43753
43754 func (c *RemarketingListsListCall) Context(ctx context.Context) *RemarketingListsListCall {
43755 c.ctx_ = ctx
43756 return c
43757 }
43758
43759
43760
43761 func (c *RemarketingListsListCall) Header() http.Header {
43762 if c.header_ == nil {
43763 c.header_ = make(http.Header)
43764 }
43765 return c.header_
43766 }
43767
43768 func (c *RemarketingListsListCall) doRequest(alt string) (*http.Response, error) {
43769 reqHeaders := make(http.Header)
43770 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
43771 for k, v := range c.header_ {
43772 reqHeaders[k] = v
43773 }
43774 reqHeaders.Set("User-Agent", c.s.userAgent())
43775 if c.ifNoneMatch_ != "" {
43776 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
43777 }
43778 var body io.Reader = nil
43779 c.urlParams_.Set("alt", alt)
43780 c.urlParams_.Set("prettyPrint", "false")
43781 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/remarketingLists")
43782 urls += "?" + c.urlParams_.Encode()
43783 req, err := http.NewRequest("GET", urls, body)
43784 if err != nil {
43785 return nil, err
43786 }
43787 req.Header = reqHeaders
43788 googleapi.Expand(req.URL, map[string]string{
43789 "profileId": strconv.FormatInt(c.profileId, 10),
43790 })
43791 return gensupport.SendRequest(c.ctx_, c.s.client, req)
43792 }
43793
43794
43795
43796
43797
43798
43799
43800
43801 func (c *RemarketingListsListCall) Do(opts ...googleapi.CallOption) (*RemarketingListsListResponse, error) {
43802 gensupport.SetOptions(c.urlParams_, opts...)
43803 res, err := c.doRequest("json")
43804 if res != nil && res.StatusCode == http.StatusNotModified {
43805 if res.Body != nil {
43806 res.Body.Close()
43807 }
43808 return nil, &googleapi.Error{
43809 Code: res.StatusCode,
43810 Header: res.Header,
43811 }
43812 }
43813 if err != nil {
43814 return nil, err
43815 }
43816 defer googleapi.CloseBody(res)
43817 if err := googleapi.CheckResponse(res); err != nil {
43818 return nil, err
43819 }
43820 ret := &RemarketingListsListResponse{
43821 ServerResponse: googleapi.ServerResponse{
43822 Header: res.Header,
43823 HTTPStatusCode: res.StatusCode,
43824 },
43825 }
43826 target := &ret
43827 if err := gensupport.DecodeResponse(target, res); err != nil {
43828 return nil, err
43829 }
43830 return ret, nil
43831
43832
43833
43834
43835
43836
43837
43838
43839
43840
43841
43842
43843
43844
43845
43846
43847
43848
43849
43850
43851
43852
43853
43854
43855
43856
43857
43858
43859
43860
43861
43862
43863
43864
43865
43866
43867
43868
43869
43870
43871
43872
43873
43874
43875
43876
43877
43878
43879
43880
43881
43882
43883
43884
43885
43886
43887
43888
43889
43890
43891
43892
43893
43894
43895
43896
43897
43898
43899
43900
43901
43902
43903
43904
43905
43906
43907
43908
43909
43910
43911
43912
43913
43914
43915
43916
43917
43918
43919
43920
43921
43922 }
43923
43924
43925
43926
43927 func (c *RemarketingListsListCall) Pages(ctx context.Context, f func(*RemarketingListsListResponse) error) error {
43928 c.ctx_ = ctx
43929 defer c.PageToken(c.urlParams_.Get("pageToken"))
43930 for {
43931 x, err := c.Do()
43932 if err != nil {
43933 return err
43934 }
43935 if err := f(x); err != nil {
43936 return err
43937 }
43938 if x.NextPageToken == "" {
43939 return nil
43940 }
43941 c.PageToken(x.NextPageToken)
43942 }
43943 }
43944
43945
43946
43947 type RemarketingListsPatchCall struct {
43948 s *Service
43949 profileId int64
43950 remarketinglist *RemarketingList
43951 urlParams_ gensupport.URLParams
43952 ctx_ context.Context
43953 header_ http.Header
43954 }
43955
43956
43957
43958 func (r *RemarketingListsService) Patch(profileId int64, id int64, remarketinglist *RemarketingList) *RemarketingListsPatchCall {
43959 c := &RemarketingListsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
43960 c.profileId = profileId
43961 c.urlParams_.Set("id", fmt.Sprint(id))
43962 c.remarketinglist = remarketinglist
43963 return c
43964 }
43965
43966
43967
43968
43969 func (c *RemarketingListsPatchCall) Fields(s ...googleapi.Field) *RemarketingListsPatchCall {
43970 c.urlParams_.Set("fields", googleapi.CombineFields(s))
43971 return c
43972 }
43973
43974
43975
43976
43977 func (c *RemarketingListsPatchCall) Context(ctx context.Context) *RemarketingListsPatchCall {
43978 c.ctx_ = ctx
43979 return c
43980 }
43981
43982
43983
43984 func (c *RemarketingListsPatchCall) Header() http.Header {
43985 if c.header_ == nil {
43986 c.header_ = make(http.Header)
43987 }
43988 return c.header_
43989 }
43990
43991 func (c *RemarketingListsPatchCall) doRequest(alt string) (*http.Response, error) {
43992 reqHeaders := make(http.Header)
43993 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
43994 for k, v := range c.header_ {
43995 reqHeaders[k] = v
43996 }
43997 reqHeaders.Set("User-Agent", c.s.userAgent())
43998 var body io.Reader = nil
43999 body, err := googleapi.WithoutDataWrapper.JSONReader(c.remarketinglist)
44000 if err != nil {
44001 return nil, err
44002 }
44003 reqHeaders.Set("Content-Type", "application/json")
44004 c.urlParams_.Set("alt", alt)
44005 c.urlParams_.Set("prettyPrint", "false")
44006 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/remarketingLists")
44007 urls += "?" + c.urlParams_.Encode()
44008 req, err := http.NewRequest("PATCH", urls, body)
44009 if err != nil {
44010 return nil, err
44011 }
44012 req.Header = reqHeaders
44013 googleapi.Expand(req.URL, map[string]string{
44014 "profileId": strconv.FormatInt(c.profileId, 10),
44015 })
44016 return gensupport.SendRequest(c.ctx_, c.s.client, req)
44017 }
44018
44019
44020
44021
44022
44023
44024
44025
44026 func (c *RemarketingListsPatchCall) Do(opts ...googleapi.CallOption) (*RemarketingList, error) {
44027 gensupport.SetOptions(c.urlParams_, opts...)
44028 res, err := c.doRequest("json")
44029 if res != nil && res.StatusCode == http.StatusNotModified {
44030 if res.Body != nil {
44031 res.Body.Close()
44032 }
44033 return nil, &googleapi.Error{
44034 Code: res.StatusCode,
44035 Header: res.Header,
44036 }
44037 }
44038 if err != nil {
44039 return nil, err
44040 }
44041 defer googleapi.CloseBody(res)
44042 if err := googleapi.CheckResponse(res); err != nil {
44043 return nil, err
44044 }
44045 ret := &RemarketingList{
44046 ServerResponse: googleapi.ServerResponse{
44047 Header: res.Header,
44048 HTTPStatusCode: res.StatusCode,
44049 },
44050 }
44051 target := &ret
44052 if err := gensupport.DecodeResponse(target, res); err != nil {
44053 return nil, err
44054 }
44055 return ret, nil
44056
44057
44058
44059
44060
44061
44062
44063
44064
44065
44066
44067
44068
44069
44070
44071
44072
44073
44074
44075
44076
44077
44078
44079
44080
44081
44082
44083
44084
44085
44086
44087
44088
44089
44090
44091
44092 }
44093
44094
44095
44096 type RemarketingListsUpdateCall struct {
44097 s *Service
44098 profileId int64
44099 remarketinglist *RemarketingList
44100 urlParams_ gensupport.URLParams
44101 ctx_ context.Context
44102 header_ http.Header
44103 }
44104
44105
44106 func (r *RemarketingListsService) Update(profileId int64, remarketinglist *RemarketingList) *RemarketingListsUpdateCall {
44107 c := &RemarketingListsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
44108 c.profileId = profileId
44109 c.remarketinglist = remarketinglist
44110 return c
44111 }
44112
44113
44114
44115
44116 func (c *RemarketingListsUpdateCall) Fields(s ...googleapi.Field) *RemarketingListsUpdateCall {
44117 c.urlParams_.Set("fields", googleapi.CombineFields(s))
44118 return c
44119 }
44120
44121
44122
44123
44124 func (c *RemarketingListsUpdateCall) Context(ctx context.Context) *RemarketingListsUpdateCall {
44125 c.ctx_ = ctx
44126 return c
44127 }
44128
44129
44130
44131 func (c *RemarketingListsUpdateCall) Header() http.Header {
44132 if c.header_ == nil {
44133 c.header_ = make(http.Header)
44134 }
44135 return c.header_
44136 }
44137
44138 func (c *RemarketingListsUpdateCall) doRequest(alt string) (*http.Response, error) {
44139 reqHeaders := make(http.Header)
44140 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
44141 for k, v := range c.header_ {
44142 reqHeaders[k] = v
44143 }
44144 reqHeaders.Set("User-Agent", c.s.userAgent())
44145 var body io.Reader = nil
44146 body, err := googleapi.WithoutDataWrapper.JSONReader(c.remarketinglist)
44147 if err != nil {
44148 return nil, err
44149 }
44150 reqHeaders.Set("Content-Type", "application/json")
44151 c.urlParams_.Set("alt", alt)
44152 c.urlParams_.Set("prettyPrint", "false")
44153 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/remarketingLists")
44154 urls += "?" + c.urlParams_.Encode()
44155 req, err := http.NewRequest("PUT", urls, body)
44156 if err != nil {
44157 return nil, err
44158 }
44159 req.Header = reqHeaders
44160 googleapi.Expand(req.URL, map[string]string{
44161 "profileId": strconv.FormatInt(c.profileId, 10),
44162 })
44163 return gensupport.SendRequest(c.ctx_, c.s.client, req)
44164 }
44165
44166
44167
44168
44169
44170
44171
44172
44173 func (c *RemarketingListsUpdateCall) Do(opts ...googleapi.CallOption) (*RemarketingList, error) {
44174 gensupport.SetOptions(c.urlParams_, opts...)
44175 res, err := c.doRequest("json")
44176 if res != nil && res.StatusCode == http.StatusNotModified {
44177 if res.Body != nil {
44178 res.Body.Close()
44179 }
44180 return nil, &googleapi.Error{
44181 Code: res.StatusCode,
44182 Header: res.Header,
44183 }
44184 }
44185 if err != nil {
44186 return nil, err
44187 }
44188 defer googleapi.CloseBody(res)
44189 if err := googleapi.CheckResponse(res); err != nil {
44190 return nil, err
44191 }
44192 ret := &RemarketingList{
44193 ServerResponse: googleapi.ServerResponse{
44194 Header: res.Header,
44195 HTTPStatusCode: res.StatusCode,
44196 },
44197 }
44198 target := &ret
44199 if err := gensupport.DecodeResponse(target, res); err != nil {
44200 return nil, err
44201 }
44202 return ret, nil
44203
44204
44205
44206
44207
44208
44209
44210
44211
44212
44213
44214
44215
44216
44217
44218
44219
44220
44221
44222
44223
44224
44225
44226
44227
44228
44229
44230
44231 }
44232
44233
44234
44235 type ReportsDeleteCall struct {
44236 s *Service
44237 profileId int64
44238 reportId int64
44239 urlParams_ gensupport.URLParams
44240 ctx_ context.Context
44241 header_ http.Header
44242 }
44243
44244
44245 func (r *ReportsService) Delete(profileId int64, reportId int64) *ReportsDeleteCall {
44246 c := &ReportsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
44247 c.profileId = profileId
44248 c.reportId = reportId
44249 return c
44250 }
44251
44252
44253
44254
44255 func (c *ReportsDeleteCall) Fields(s ...googleapi.Field) *ReportsDeleteCall {
44256 c.urlParams_.Set("fields", googleapi.CombineFields(s))
44257 return c
44258 }
44259
44260
44261
44262
44263 func (c *ReportsDeleteCall) Context(ctx context.Context) *ReportsDeleteCall {
44264 c.ctx_ = ctx
44265 return c
44266 }
44267
44268
44269
44270 func (c *ReportsDeleteCall) Header() http.Header {
44271 if c.header_ == nil {
44272 c.header_ = make(http.Header)
44273 }
44274 return c.header_
44275 }
44276
44277 func (c *ReportsDeleteCall) doRequest(alt string) (*http.Response, error) {
44278 reqHeaders := make(http.Header)
44279 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
44280 for k, v := range c.header_ {
44281 reqHeaders[k] = v
44282 }
44283 reqHeaders.Set("User-Agent", c.s.userAgent())
44284 var body io.Reader = nil
44285 c.urlParams_.Set("alt", alt)
44286 c.urlParams_.Set("prettyPrint", "false")
44287 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/reports/{reportId}")
44288 urls += "?" + c.urlParams_.Encode()
44289 req, err := http.NewRequest("DELETE", urls, body)
44290 if err != nil {
44291 return nil, err
44292 }
44293 req.Header = reqHeaders
44294 googleapi.Expand(req.URL, map[string]string{
44295 "profileId": strconv.FormatInt(c.profileId, 10),
44296 "reportId": strconv.FormatInt(c.reportId, 10),
44297 })
44298 return gensupport.SendRequest(c.ctx_, c.s.client, req)
44299 }
44300
44301
44302 func (c *ReportsDeleteCall) Do(opts ...googleapi.CallOption) error {
44303 gensupport.SetOptions(c.urlParams_, opts...)
44304 res, err := c.doRequest("json")
44305 if err != nil {
44306 return err
44307 }
44308 defer googleapi.CloseBody(res)
44309 if err := googleapi.CheckResponse(res); err != nil {
44310 return err
44311 }
44312 return nil
44313
44314
44315
44316
44317
44318
44319
44320
44321
44322
44323
44324
44325
44326
44327
44328
44329
44330
44331
44332
44333
44334
44335
44336
44337
44338
44339
44340
44341
44342
44343 }
44344
44345
44346
44347 type ReportsGetCall struct {
44348 s *Service
44349 profileId int64
44350 reportId int64
44351 urlParams_ gensupport.URLParams
44352 ifNoneMatch_ string
44353 ctx_ context.Context
44354 header_ http.Header
44355 }
44356
44357
44358 func (r *ReportsService) Get(profileId int64, reportId int64) *ReportsGetCall {
44359 c := &ReportsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
44360 c.profileId = profileId
44361 c.reportId = reportId
44362 return c
44363 }
44364
44365
44366
44367
44368 func (c *ReportsGetCall) Fields(s ...googleapi.Field) *ReportsGetCall {
44369 c.urlParams_.Set("fields", googleapi.CombineFields(s))
44370 return c
44371 }
44372
44373
44374
44375
44376
44377
44378 func (c *ReportsGetCall) IfNoneMatch(entityTag string) *ReportsGetCall {
44379 c.ifNoneMatch_ = entityTag
44380 return c
44381 }
44382
44383
44384
44385
44386 func (c *ReportsGetCall) Context(ctx context.Context) *ReportsGetCall {
44387 c.ctx_ = ctx
44388 return c
44389 }
44390
44391
44392
44393 func (c *ReportsGetCall) Header() http.Header {
44394 if c.header_ == nil {
44395 c.header_ = make(http.Header)
44396 }
44397 return c.header_
44398 }
44399
44400 func (c *ReportsGetCall) doRequest(alt string) (*http.Response, error) {
44401 reqHeaders := make(http.Header)
44402 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
44403 for k, v := range c.header_ {
44404 reqHeaders[k] = v
44405 }
44406 reqHeaders.Set("User-Agent", c.s.userAgent())
44407 if c.ifNoneMatch_ != "" {
44408 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
44409 }
44410 var body io.Reader = nil
44411 c.urlParams_.Set("alt", alt)
44412 c.urlParams_.Set("prettyPrint", "false")
44413 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/reports/{reportId}")
44414 urls += "?" + c.urlParams_.Encode()
44415 req, err := http.NewRequest("GET", urls, body)
44416 if err != nil {
44417 return nil, err
44418 }
44419 req.Header = reqHeaders
44420 googleapi.Expand(req.URL, map[string]string{
44421 "profileId": strconv.FormatInt(c.profileId, 10),
44422 "reportId": strconv.FormatInt(c.reportId, 10),
44423 })
44424 return gensupport.SendRequest(c.ctx_, c.s.client, req)
44425 }
44426
44427
44428
44429
44430
44431
44432
44433
44434 func (c *ReportsGetCall) Do(opts ...googleapi.CallOption) (*Report, error) {
44435 gensupport.SetOptions(c.urlParams_, opts...)
44436 res, err := c.doRequest("json")
44437 if res != nil && res.StatusCode == http.StatusNotModified {
44438 if res.Body != nil {
44439 res.Body.Close()
44440 }
44441 return nil, &googleapi.Error{
44442 Code: res.StatusCode,
44443 Header: res.Header,
44444 }
44445 }
44446 if err != nil {
44447 return nil, err
44448 }
44449 defer googleapi.CloseBody(res)
44450 if err := googleapi.CheckResponse(res); err != nil {
44451 return nil, err
44452 }
44453 ret := &Report{
44454 ServerResponse: googleapi.ServerResponse{
44455 Header: res.Header,
44456 HTTPStatusCode: res.StatusCode,
44457 },
44458 }
44459 target := &ret
44460 if err := gensupport.DecodeResponse(target, res); err != nil {
44461 return nil, err
44462 }
44463 return ret, nil
44464
44465
44466
44467
44468
44469
44470
44471
44472
44473
44474
44475
44476
44477
44478
44479
44480
44481
44482
44483
44484
44485
44486
44487
44488
44489
44490
44491
44492
44493
44494
44495
44496
44497 }
44498
44499
44500
44501 type ReportsInsertCall struct {
44502 s *Service
44503 profileId int64
44504 report *Report
44505 urlParams_ gensupport.URLParams
44506 ctx_ context.Context
44507 header_ http.Header
44508 }
44509
44510
44511 func (r *ReportsService) Insert(profileId int64, report *Report) *ReportsInsertCall {
44512 c := &ReportsInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
44513 c.profileId = profileId
44514 c.report = report
44515 return c
44516 }
44517
44518
44519
44520
44521 func (c *ReportsInsertCall) Fields(s ...googleapi.Field) *ReportsInsertCall {
44522 c.urlParams_.Set("fields", googleapi.CombineFields(s))
44523 return c
44524 }
44525
44526
44527
44528
44529 func (c *ReportsInsertCall) Context(ctx context.Context) *ReportsInsertCall {
44530 c.ctx_ = ctx
44531 return c
44532 }
44533
44534
44535
44536 func (c *ReportsInsertCall) Header() http.Header {
44537 if c.header_ == nil {
44538 c.header_ = make(http.Header)
44539 }
44540 return c.header_
44541 }
44542
44543 func (c *ReportsInsertCall) doRequest(alt string) (*http.Response, error) {
44544 reqHeaders := make(http.Header)
44545 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
44546 for k, v := range c.header_ {
44547 reqHeaders[k] = v
44548 }
44549 reqHeaders.Set("User-Agent", c.s.userAgent())
44550 var body io.Reader = nil
44551 body, err := googleapi.WithoutDataWrapper.JSONReader(c.report)
44552 if err != nil {
44553 return nil, err
44554 }
44555 reqHeaders.Set("Content-Type", "application/json")
44556 c.urlParams_.Set("alt", alt)
44557 c.urlParams_.Set("prettyPrint", "false")
44558 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/reports")
44559 urls += "?" + c.urlParams_.Encode()
44560 req, err := http.NewRequest("POST", urls, body)
44561 if err != nil {
44562 return nil, err
44563 }
44564 req.Header = reqHeaders
44565 googleapi.Expand(req.URL, map[string]string{
44566 "profileId": strconv.FormatInt(c.profileId, 10),
44567 })
44568 return gensupport.SendRequest(c.ctx_, c.s.client, req)
44569 }
44570
44571
44572
44573
44574
44575
44576
44577
44578 func (c *ReportsInsertCall) Do(opts ...googleapi.CallOption) (*Report, error) {
44579 gensupport.SetOptions(c.urlParams_, opts...)
44580 res, err := c.doRequest("json")
44581 if res != nil && res.StatusCode == http.StatusNotModified {
44582 if res.Body != nil {
44583 res.Body.Close()
44584 }
44585 return nil, &googleapi.Error{
44586 Code: res.StatusCode,
44587 Header: res.Header,
44588 }
44589 }
44590 if err != nil {
44591 return nil, err
44592 }
44593 defer googleapi.CloseBody(res)
44594 if err := googleapi.CheckResponse(res); err != nil {
44595 return nil, err
44596 }
44597 ret := &Report{
44598 ServerResponse: googleapi.ServerResponse{
44599 Header: res.Header,
44600 HTTPStatusCode: res.StatusCode,
44601 },
44602 }
44603 target := &ret
44604 if err := gensupport.DecodeResponse(target, res); err != nil {
44605 return nil, err
44606 }
44607 return ret, nil
44608
44609
44610
44611
44612
44613
44614
44615
44616
44617
44618
44619
44620
44621
44622
44623
44624
44625
44626
44627
44628
44629
44630
44631
44632
44633
44634
44635
44636 }
44637
44638
44639
44640 type ReportsListCall struct {
44641 s *Service
44642 profileId int64
44643 urlParams_ gensupport.URLParams
44644 ifNoneMatch_ string
44645 ctx_ context.Context
44646 header_ http.Header
44647 }
44648
44649
44650 func (r *ReportsService) List(profileId int64) *ReportsListCall {
44651 c := &ReportsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
44652 c.profileId = profileId
44653 return c
44654 }
44655
44656
44657
44658 func (c *ReportsListCall) MaxResults(maxResults int64) *ReportsListCall {
44659 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
44660 return c
44661 }
44662
44663
44664
44665 func (c *ReportsListCall) PageToken(pageToken string) *ReportsListCall {
44666 c.urlParams_.Set("pageToken", pageToken)
44667 return c
44668 }
44669
44670
44671
44672
44673
44674
44675
44676
44677 func (c *ReportsListCall) Scope(scope string) *ReportsListCall {
44678 c.urlParams_.Set("scope", scope)
44679 return c
44680 }
44681
44682
44683
44684
44685
44686
44687
44688
44689
44690 func (c *ReportsListCall) SortField(sortField string) *ReportsListCall {
44691 c.urlParams_.Set("sortField", sortField)
44692 return c
44693 }
44694
44695
44696
44697
44698
44699
44700
44701
44702 func (c *ReportsListCall) SortOrder(sortOrder string) *ReportsListCall {
44703 c.urlParams_.Set("sortOrder", sortOrder)
44704 return c
44705 }
44706
44707
44708
44709
44710 func (c *ReportsListCall) Fields(s ...googleapi.Field) *ReportsListCall {
44711 c.urlParams_.Set("fields", googleapi.CombineFields(s))
44712 return c
44713 }
44714
44715
44716
44717
44718
44719
44720 func (c *ReportsListCall) IfNoneMatch(entityTag string) *ReportsListCall {
44721 c.ifNoneMatch_ = entityTag
44722 return c
44723 }
44724
44725
44726
44727
44728 func (c *ReportsListCall) Context(ctx context.Context) *ReportsListCall {
44729 c.ctx_ = ctx
44730 return c
44731 }
44732
44733
44734
44735 func (c *ReportsListCall) Header() http.Header {
44736 if c.header_ == nil {
44737 c.header_ = make(http.Header)
44738 }
44739 return c.header_
44740 }
44741
44742 func (c *ReportsListCall) doRequest(alt string) (*http.Response, error) {
44743 reqHeaders := make(http.Header)
44744 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
44745 for k, v := range c.header_ {
44746 reqHeaders[k] = v
44747 }
44748 reqHeaders.Set("User-Agent", c.s.userAgent())
44749 if c.ifNoneMatch_ != "" {
44750 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
44751 }
44752 var body io.Reader = nil
44753 c.urlParams_.Set("alt", alt)
44754 c.urlParams_.Set("prettyPrint", "false")
44755 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/reports")
44756 urls += "?" + c.urlParams_.Encode()
44757 req, err := http.NewRequest("GET", urls, body)
44758 if err != nil {
44759 return nil, err
44760 }
44761 req.Header = reqHeaders
44762 googleapi.Expand(req.URL, map[string]string{
44763 "profileId": strconv.FormatInt(c.profileId, 10),
44764 })
44765 return gensupport.SendRequest(c.ctx_, c.s.client, req)
44766 }
44767
44768
44769
44770
44771
44772
44773
44774
44775 func (c *ReportsListCall) Do(opts ...googleapi.CallOption) (*ReportList, error) {
44776 gensupport.SetOptions(c.urlParams_, opts...)
44777 res, err := c.doRequest("json")
44778 if res != nil && res.StatusCode == http.StatusNotModified {
44779 if res.Body != nil {
44780 res.Body.Close()
44781 }
44782 return nil, &googleapi.Error{
44783 Code: res.StatusCode,
44784 Header: res.Header,
44785 }
44786 }
44787 if err != nil {
44788 return nil, err
44789 }
44790 defer googleapi.CloseBody(res)
44791 if err := googleapi.CheckResponse(res); err != nil {
44792 return nil, err
44793 }
44794 ret := &ReportList{
44795 ServerResponse: googleapi.ServerResponse{
44796 Header: res.Header,
44797 HTTPStatusCode: res.StatusCode,
44798 },
44799 }
44800 target := &ret
44801 if err := gensupport.DecodeResponse(target, res); err != nil {
44802 return nil, err
44803 }
44804 return ret, nil
44805
44806
44807
44808
44809
44810
44811
44812
44813
44814
44815
44816
44817
44818
44819
44820
44821
44822
44823
44824
44825
44826
44827
44828
44829
44830
44831
44832
44833
44834
44835
44836
44837
44838
44839
44840
44841
44842
44843
44844
44845
44846
44847
44848
44849
44850
44851
44852
44853
44854
44855
44856
44857
44858
44859
44860
44861
44862
44863
44864
44865
44866
44867
44868
44869
44870
44871
44872
44873
44874
44875
44876
44877
44878
44879
44880
44881
44882
44883
44884
44885
44886
44887
44888 }
44889
44890
44891
44892
44893 func (c *ReportsListCall) Pages(ctx context.Context, f func(*ReportList) error) error {
44894 c.ctx_ = ctx
44895 defer c.PageToken(c.urlParams_.Get("pageToken"))
44896 for {
44897 x, err := c.Do()
44898 if err != nil {
44899 return err
44900 }
44901 if err := f(x); err != nil {
44902 return err
44903 }
44904 if x.NextPageToken == "" {
44905 return nil
44906 }
44907 c.PageToken(x.NextPageToken)
44908 }
44909 }
44910
44911
44912
44913 type ReportsPatchCall struct {
44914 s *Service
44915 profileId int64
44916 reportId int64
44917 report *Report
44918 urlParams_ gensupport.URLParams
44919 ctx_ context.Context
44920 header_ http.Header
44921 }
44922
44923
44924 func (r *ReportsService) Patch(profileId int64, reportId int64, report *Report) *ReportsPatchCall {
44925 c := &ReportsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
44926 c.profileId = profileId
44927 c.reportId = reportId
44928 c.report = report
44929 return c
44930 }
44931
44932
44933
44934
44935 func (c *ReportsPatchCall) Fields(s ...googleapi.Field) *ReportsPatchCall {
44936 c.urlParams_.Set("fields", googleapi.CombineFields(s))
44937 return c
44938 }
44939
44940
44941
44942
44943 func (c *ReportsPatchCall) Context(ctx context.Context) *ReportsPatchCall {
44944 c.ctx_ = ctx
44945 return c
44946 }
44947
44948
44949
44950 func (c *ReportsPatchCall) Header() http.Header {
44951 if c.header_ == nil {
44952 c.header_ = make(http.Header)
44953 }
44954 return c.header_
44955 }
44956
44957 func (c *ReportsPatchCall) doRequest(alt string) (*http.Response, error) {
44958 reqHeaders := make(http.Header)
44959 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
44960 for k, v := range c.header_ {
44961 reqHeaders[k] = v
44962 }
44963 reqHeaders.Set("User-Agent", c.s.userAgent())
44964 var body io.Reader = nil
44965 body, err := googleapi.WithoutDataWrapper.JSONReader(c.report)
44966 if err != nil {
44967 return nil, err
44968 }
44969 reqHeaders.Set("Content-Type", "application/json")
44970 c.urlParams_.Set("alt", alt)
44971 c.urlParams_.Set("prettyPrint", "false")
44972 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/reports/{reportId}")
44973 urls += "?" + c.urlParams_.Encode()
44974 req, err := http.NewRequest("PATCH", urls, body)
44975 if err != nil {
44976 return nil, err
44977 }
44978 req.Header = reqHeaders
44979 googleapi.Expand(req.URL, map[string]string{
44980 "profileId": strconv.FormatInt(c.profileId, 10),
44981 "reportId": strconv.FormatInt(c.reportId, 10),
44982 })
44983 return gensupport.SendRequest(c.ctx_, c.s.client, req)
44984 }
44985
44986
44987
44988
44989
44990
44991
44992
44993 func (c *ReportsPatchCall) Do(opts ...googleapi.CallOption) (*Report, error) {
44994 gensupport.SetOptions(c.urlParams_, opts...)
44995 res, err := c.doRequest("json")
44996 if res != nil && res.StatusCode == http.StatusNotModified {
44997 if res.Body != nil {
44998 res.Body.Close()
44999 }
45000 return nil, &googleapi.Error{
45001 Code: res.StatusCode,
45002 Header: res.Header,
45003 }
45004 }
45005 if err != nil {
45006 return nil, err
45007 }
45008 defer googleapi.CloseBody(res)
45009 if err := googleapi.CheckResponse(res); err != nil {
45010 return nil, err
45011 }
45012 ret := &Report{
45013 ServerResponse: googleapi.ServerResponse{
45014 Header: res.Header,
45015 HTTPStatusCode: res.StatusCode,
45016 },
45017 }
45018 target := &ret
45019 if err := gensupport.DecodeResponse(target, res); err != nil {
45020 return nil, err
45021 }
45022 return ret, nil
45023
45024
45025
45026
45027
45028
45029
45030
45031
45032
45033
45034
45035
45036
45037
45038
45039
45040
45041
45042
45043
45044
45045
45046
45047
45048
45049
45050
45051
45052
45053
45054
45055
45056
45057
45058
45059 }
45060
45061
45062
45063 type ReportsRunCall struct {
45064 s *Service
45065 profileId int64
45066 reportId int64
45067 urlParams_ gensupport.URLParams
45068 ctx_ context.Context
45069 header_ http.Header
45070 }
45071
45072
45073 func (r *ReportsService) Run(profileId int64, reportId int64) *ReportsRunCall {
45074 c := &ReportsRunCall{s: r.s, urlParams_: make(gensupport.URLParams)}
45075 c.profileId = profileId
45076 c.reportId = reportId
45077 return c
45078 }
45079
45080
45081
45082 func (c *ReportsRunCall) Synchronous(synchronous bool) *ReportsRunCall {
45083 c.urlParams_.Set("synchronous", fmt.Sprint(synchronous))
45084 return c
45085 }
45086
45087
45088
45089
45090 func (c *ReportsRunCall) Fields(s ...googleapi.Field) *ReportsRunCall {
45091 c.urlParams_.Set("fields", googleapi.CombineFields(s))
45092 return c
45093 }
45094
45095
45096
45097
45098 func (c *ReportsRunCall) Context(ctx context.Context) *ReportsRunCall {
45099 c.ctx_ = ctx
45100 return c
45101 }
45102
45103
45104
45105 func (c *ReportsRunCall) Header() http.Header {
45106 if c.header_ == nil {
45107 c.header_ = make(http.Header)
45108 }
45109 return c.header_
45110 }
45111
45112 func (c *ReportsRunCall) doRequest(alt string) (*http.Response, error) {
45113 reqHeaders := make(http.Header)
45114 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
45115 for k, v := range c.header_ {
45116 reqHeaders[k] = v
45117 }
45118 reqHeaders.Set("User-Agent", c.s.userAgent())
45119 var body io.Reader = nil
45120 c.urlParams_.Set("alt", alt)
45121 c.urlParams_.Set("prettyPrint", "false")
45122 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/reports/{reportId}/run")
45123 urls += "?" + c.urlParams_.Encode()
45124 req, err := http.NewRequest("POST", urls, body)
45125 if err != nil {
45126 return nil, err
45127 }
45128 req.Header = reqHeaders
45129 googleapi.Expand(req.URL, map[string]string{
45130 "profileId": strconv.FormatInt(c.profileId, 10),
45131 "reportId": strconv.FormatInt(c.reportId, 10),
45132 })
45133 return gensupport.SendRequest(c.ctx_, c.s.client, req)
45134 }
45135
45136
45137
45138
45139
45140
45141
45142
45143 func (c *ReportsRunCall) Do(opts ...googleapi.CallOption) (*File, error) {
45144 gensupport.SetOptions(c.urlParams_, opts...)
45145 res, err := c.doRequest("json")
45146 if res != nil && res.StatusCode == http.StatusNotModified {
45147 if res.Body != nil {
45148 res.Body.Close()
45149 }
45150 return nil, &googleapi.Error{
45151 Code: res.StatusCode,
45152 Header: res.Header,
45153 }
45154 }
45155 if err != nil {
45156 return nil, err
45157 }
45158 defer googleapi.CloseBody(res)
45159 if err := googleapi.CheckResponse(res); err != nil {
45160 return nil, err
45161 }
45162 ret := &File{
45163 ServerResponse: googleapi.ServerResponse{
45164 Header: res.Header,
45165 HTTPStatusCode: res.StatusCode,
45166 },
45167 }
45168 target := &ret
45169 if err := gensupport.DecodeResponse(target, res); err != nil {
45170 return nil, err
45171 }
45172 return ret, nil
45173
45174
45175
45176
45177
45178
45179
45180
45181
45182
45183
45184
45185
45186
45187
45188
45189
45190
45191
45192
45193
45194
45195
45196
45197
45198
45199
45200
45201
45202
45203
45204
45205
45206
45207
45208
45209
45210
45211
45212 }
45213
45214
45215
45216 type ReportsUpdateCall struct {
45217 s *Service
45218 profileId int64
45219 reportId int64
45220 report *Report
45221 urlParams_ gensupport.URLParams
45222 ctx_ context.Context
45223 header_ http.Header
45224 }
45225
45226
45227 func (r *ReportsService) Update(profileId int64, reportId int64, report *Report) *ReportsUpdateCall {
45228 c := &ReportsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
45229 c.profileId = profileId
45230 c.reportId = reportId
45231 c.report = report
45232 return c
45233 }
45234
45235
45236
45237
45238 func (c *ReportsUpdateCall) Fields(s ...googleapi.Field) *ReportsUpdateCall {
45239 c.urlParams_.Set("fields", googleapi.CombineFields(s))
45240 return c
45241 }
45242
45243
45244
45245
45246 func (c *ReportsUpdateCall) Context(ctx context.Context) *ReportsUpdateCall {
45247 c.ctx_ = ctx
45248 return c
45249 }
45250
45251
45252
45253 func (c *ReportsUpdateCall) Header() http.Header {
45254 if c.header_ == nil {
45255 c.header_ = make(http.Header)
45256 }
45257 return c.header_
45258 }
45259
45260 func (c *ReportsUpdateCall) doRequest(alt string) (*http.Response, error) {
45261 reqHeaders := make(http.Header)
45262 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
45263 for k, v := range c.header_ {
45264 reqHeaders[k] = v
45265 }
45266 reqHeaders.Set("User-Agent", c.s.userAgent())
45267 var body io.Reader = nil
45268 body, err := googleapi.WithoutDataWrapper.JSONReader(c.report)
45269 if err != nil {
45270 return nil, err
45271 }
45272 reqHeaders.Set("Content-Type", "application/json")
45273 c.urlParams_.Set("alt", alt)
45274 c.urlParams_.Set("prettyPrint", "false")
45275 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/reports/{reportId}")
45276 urls += "?" + c.urlParams_.Encode()
45277 req, err := http.NewRequest("PUT", urls, body)
45278 if err != nil {
45279 return nil, err
45280 }
45281 req.Header = reqHeaders
45282 googleapi.Expand(req.URL, map[string]string{
45283 "profileId": strconv.FormatInt(c.profileId, 10),
45284 "reportId": strconv.FormatInt(c.reportId, 10),
45285 })
45286 return gensupport.SendRequest(c.ctx_, c.s.client, req)
45287 }
45288
45289
45290
45291
45292
45293
45294
45295
45296 func (c *ReportsUpdateCall) Do(opts ...googleapi.CallOption) (*Report, error) {
45297 gensupport.SetOptions(c.urlParams_, opts...)
45298 res, err := c.doRequest("json")
45299 if res != nil && res.StatusCode == http.StatusNotModified {
45300 if res.Body != nil {
45301 res.Body.Close()
45302 }
45303 return nil, &googleapi.Error{
45304 Code: res.StatusCode,
45305 Header: res.Header,
45306 }
45307 }
45308 if err != nil {
45309 return nil, err
45310 }
45311 defer googleapi.CloseBody(res)
45312 if err := googleapi.CheckResponse(res); err != nil {
45313 return nil, err
45314 }
45315 ret := &Report{
45316 ServerResponse: googleapi.ServerResponse{
45317 Header: res.Header,
45318 HTTPStatusCode: res.StatusCode,
45319 },
45320 }
45321 target := &ret
45322 if err := gensupport.DecodeResponse(target, res); err != nil {
45323 return nil, err
45324 }
45325 return ret, nil
45326
45327
45328
45329
45330
45331
45332
45333
45334
45335
45336
45337
45338
45339
45340
45341
45342
45343
45344
45345
45346
45347
45348
45349
45350
45351
45352
45353
45354
45355
45356
45357
45358
45359
45360
45361
45362 }
45363
45364
45365
45366 type ReportsCompatibleFieldsQueryCall struct {
45367 s *Service
45368 profileId int64
45369 report *Report
45370 urlParams_ gensupport.URLParams
45371 ctx_ context.Context
45372 header_ http.Header
45373 }
45374
45375
45376
45377
45378 func (r *ReportsCompatibleFieldsService) Query(profileId int64, report *Report) *ReportsCompatibleFieldsQueryCall {
45379 c := &ReportsCompatibleFieldsQueryCall{s: r.s, urlParams_: make(gensupport.URLParams)}
45380 c.profileId = profileId
45381 c.report = report
45382 return c
45383 }
45384
45385
45386
45387
45388 func (c *ReportsCompatibleFieldsQueryCall) Fields(s ...googleapi.Field) *ReportsCompatibleFieldsQueryCall {
45389 c.urlParams_.Set("fields", googleapi.CombineFields(s))
45390 return c
45391 }
45392
45393
45394
45395
45396 func (c *ReportsCompatibleFieldsQueryCall) Context(ctx context.Context) *ReportsCompatibleFieldsQueryCall {
45397 c.ctx_ = ctx
45398 return c
45399 }
45400
45401
45402
45403 func (c *ReportsCompatibleFieldsQueryCall) Header() http.Header {
45404 if c.header_ == nil {
45405 c.header_ = make(http.Header)
45406 }
45407 return c.header_
45408 }
45409
45410 func (c *ReportsCompatibleFieldsQueryCall) doRequest(alt string) (*http.Response, error) {
45411 reqHeaders := make(http.Header)
45412 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
45413 for k, v := range c.header_ {
45414 reqHeaders[k] = v
45415 }
45416 reqHeaders.Set("User-Agent", c.s.userAgent())
45417 var body io.Reader = nil
45418 body, err := googleapi.WithoutDataWrapper.JSONReader(c.report)
45419 if err != nil {
45420 return nil, err
45421 }
45422 reqHeaders.Set("Content-Type", "application/json")
45423 c.urlParams_.Set("alt", alt)
45424 c.urlParams_.Set("prettyPrint", "false")
45425 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/reports/compatiblefields/query")
45426 urls += "?" + c.urlParams_.Encode()
45427 req, err := http.NewRequest("POST", urls, body)
45428 if err != nil {
45429 return nil, err
45430 }
45431 req.Header = reqHeaders
45432 googleapi.Expand(req.URL, map[string]string{
45433 "profileId": strconv.FormatInt(c.profileId, 10),
45434 })
45435 return gensupport.SendRequest(c.ctx_, c.s.client, req)
45436 }
45437
45438
45439
45440
45441
45442
45443
45444
45445 func (c *ReportsCompatibleFieldsQueryCall) Do(opts ...googleapi.CallOption) (*CompatibleFields, error) {
45446 gensupport.SetOptions(c.urlParams_, opts...)
45447 res, err := c.doRequest("json")
45448 if res != nil && res.StatusCode == http.StatusNotModified {
45449 if res.Body != nil {
45450 res.Body.Close()
45451 }
45452 return nil, &googleapi.Error{
45453 Code: res.StatusCode,
45454 Header: res.Header,
45455 }
45456 }
45457 if err != nil {
45458 return nil, err
45459 }
45460 defer googleapi.CloseBody(res)
45461 if err := googleapi.CheckResponse(res); err != nil {
45462 return nil, err
45463 }
45464 ret := &CompatibleFields{
45465 ServerResponse: googleapi.ServerResponse{
45466 Header: res.Header,
45467 HTTPStatusCode: res.StatusCode,
45468 },
45469 }
45470 target := &ret
45471 if err := gensupport.DecodeResponse(target, res); err != nil {
45472 return nil, err
45473 }
45474 return ret, nil
45475
45476
45477
45478
45479
45480
45481
45482
45483
45484
45485
45486
45487
45488
45489
45490
45491
45492
45493
45494
45495
45496
45497
45498
45499
45500
45501
45502
45503 }
45504
45505
45506
45507 type ReportsFilesGetCall struct {
45508 s *Service
45509 profileId int64
45510 reportId int64
45511 fileId int64
45512 urlParams_ gensupport.URLParams
45513 ifNoneMatch_ string
45514 ctx_ context.Context
45515 header_ http.Header
45516 }
45517
45518
45519 func (r *ReportsFilesService) Get(profileId int64, reportId int64, fileId int64) *ReportsFilesGetCall {
45520 c := &ReportsFilesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
45521 c.profileId = profileId
45522 c.reportId = reportId
45523 c.fileId = fileId
45524 return c
45525 }
45526
45527
45528
45529
45530 func (c *ReportsFilesGetCall) Fields(s ...googleapi.Field) *ReportsFilesGetCall {
45531 c.urlParams_.Set("fields", googleapi.CombineFields(s))
45532 return c
45533 }
45534
45535
45536
45537
45538
45539
45540 func (c *ReportsFilesGetCall) IfNoneMatch(entityTag string) *ReportsFilesGetCall {
45541 c.ifNoneMatch_ = entityTag
45542 return c
45543 }
45544
45545
45546
45547
45548 func (c *ReportsFilesGetCall) Context(ctx context.Context) *ReportsFilesGetCall {
45549 c.ctx_ = ctx
45550 return c
45551 }
45552
45553
45554
45555 func (c *ReportsFilesGetCall) Header() http.Header {
45556 if c.header_ == nil {
45557 c.header_ = make(http.Header)
45558 }
45559 return c.header_
45560 }
45561
45562 func (c *ReportsFilesGetCall) doRequest(alt string) (*http.Response, error) {
45563 reqHeaders := make(http.Header)
45564 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
45565 for k, v := range c.header_ {
45566 reqHeaders[k] = v
45567 }
45568 reqHeaders.Set("User-Agent", c.s.userAgent())
45569 if c.ifNoneMatch_ != "" {
45570 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
45571 }
45572 var body io.Reader = nil
45573 c.urlParams_.Set("alt", alt)
45574 c.urlParams_.Set("prettyPrint", "false")
45575 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/reports/{reportId}/files/{fileId}")
45576 urls += "?" + c.urlParams_.Encode()
45577 req, err := http.NewRequest("GET", urls, body)
45578 if err != nil {
45579 return nil, err
45580 }
45581 req.Header = reqHeaders
45582 googleapi.Expand(req.URL, map[string]string{
45583 "profileId": strconv.FormatInt(c.profileId, 10),
45584 "reportId": strconv.FormatInt(c.reportId, 10),
45585 "fileId": strconv.FormatInt(c.fileId, 10),
45586 })
45587 return gensupport.SendRequest(c.ctx_, c.s.client, req)
45588 }
45589
45590
45591
45592
45593 func (c *ReportsFilesGetCall) Download(opts ...googleapi.CallOption) (*http.Response, error) {
45594 gensupport.SetOptions(c.urlParams_, opts...)
45595 res, err := c.doRequest("media")
45596 if err != nil {
45597 return nil, err
45598 }
45599 if err := googleapi.CheckMediaResponse(res); err != nil {
45600 res.Body.Close()
45601 return nil, err
45602 }
45603 return res, nil
45604 }
45605
45606
45607
45608
45609
45610
45611
45612
45613 func (c *ReportsFilesGetCall) Do(opts ...googleapi.CallOption) (*File, error) {
45614 gensupport.SetOptions(c.urlParams_, opts...)
45615 res, err := c.doRequest("json")
45616 if res != nil && res.StatusCode == http.StatusNotModified {
45617 if res.Body != nil {
45618 res.Body.Close()
45619 }
45620 return nil, &googleapi.Error{
45621 Code: res.StatusCode,
45622 Header: res.Header,
45623 }
45624 }
45625 if err != nil {
45626 return nil, err
45627 }
45628 defer googleapi.CloseBody(res)
45629 if err := googleapi.CheckResponse(res); err != nil {
45630 return nil, err
45631 }
45632 ret := &File{
45633 ServerResponse: googleapi.ServerResponse{
45634 Header: res.Header,
45635 HTTPStatusCode: res.StatusCode,
45636 },
45637 }
45638 target := &ret
45639 if err := gensupport.DecodeResponse(target, res); err != nil {
45640 return nil, err
45641 }
45642 return ret, nil
45643
45644
45645
45646
45647
45648
45649
45650
45651
45652
45653
45654
45655
45656
45657
45658
45659
45660
45661
45662
45663
45664
45665
45666
45667
45668
45669
45670
45671
45672
45673
45674
45675
45676
45677
45678
45679
45680
45681
45682
45683
45684
45685 }
45686
45687
45688
45689 type ReportsFilesListCall struct {
45690 s *Service
45691 profileId int64
45692 reportId int64
45693 urlParams_ gensupport.URLParams
45694 ifNoneMatch_ string
45695 ctx_ context.Context
45696 header_ http.Header
45697 }
45698
45699
45700 func (r *ReportsFilesService) List(profileId int64, reportId int64) *ReportsFilesListCall {
45701 c := &ReportsFilesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
45702 c.profileId = profileId
45703 c.reportId = reportId
45704 return c
45705 }
45706
45707
45708
45709 func (c *ReportsFilesListCall) MaxResults(maxResults int64) *ReportsFilesListCall {
45710 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
45711 return c
45712 }
45713
45714
45715
45716 func (c *ReportsFilesListCall) PageToken(pageToken string) *ReportsFilesListCall {
45717 c.urlParams_.Set("pageToken", pageToken)
45718 return c
45719 }
45720
45721
45722
45723
45724
45725
45726
45727
45728 func (c *ReportsFilesListCall) SortField(sortField string) *ReportsFilesListCall {
45729 c.urlParams_.Set("sortField", sortField)
45730 return c
45731 }
45732
45733
45734
45735
45736
45737
45738
45739
45740 func (c *ReportsFilesListCall) SortOrder(sortOrder string) *ReportsFilesListCall {
45741 c.urlParams_.Set("sortOrder", sortOrder)
45742 return c
45743 }
45744
45745
45746
45747
45748 func (c *ReportsFilesListCall) Fields(s ...googleapi.Field) *ReportsFilesListCall {
45749 c.urlParams_.Set("fields", googleapi.CombineFields(s))
45750 return c
45751 }
45752
45753
45754
45755
45756
45757
45758 func (c *ReportsFilesListCall) IfNoneMatch(entityTag string) *ReportsFilesListCall {
45759 c.ifNoneMatch_ = entityTag
45760 return c
45761 }
45762
45763
45764
45765
45766 func (c *ReportsFilesListCall) Context(ctx context.Context) *ReportsFilesListCall {
45767 c.ctx_ = ctx
45768 return c
45769 }
45770
45771
45772
45773 func (c *ReportsFilesListCall) Header() http.Header {
45774 if c.header_ == nil {
45775 c.header_ = make(http.Header)
45776 }
45777 return c.header_
45778 }
45779
45780 func (c *ReportsFilesListCall) doRequest(alt string) (*http.Response, error) {
45781 reqHeaders := make(http.Header)
45782 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
45783 for k, v := range c.header_ {
45784 reqHeaders[k] = v
45785 }
45786 reqHeaders.Set("User-Agent", c.s.userAgent())
45787 if c.ifNoneMatch_ != "" {
45788 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
45789 }
45790 var body io.Reader = nil
45791 c.urlParams_.Set("alt", alt)
45792 c.urlParams_.Set("prettyPrint", "false")
45793 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/reports/{reportId}/files")
45794 urls += "?" + c.urlParams_.Encode()
45795 req, err := http.NewRequest("GET", urls, body)
45796 if err != nil {
45797 return nil, err
45798 }
45799 req.Header = reqHeaders
45800 googleapi.Expand(req.URL, map[string]string{
45801 "profileId": strconv.FormatInt(c.profileId, 10),
45802 "reportId": strconv.FormatInt(c.reportId, 10),
45803 })
45804 return gensupport.SendRequest(c.ctx_, c.s.client, req)
45805 }
45806
45807
45808
45809
45810
45811
45812
45813
45814 func (c *ReportsFilesListCall) Do(opts ...googleapi.CallOption) (*FileList, error) {
45815 gensupport.SetOptions(c.urlParams_, opts...)
45816 res, err := c.doRequest("json")
45817 if res != nil && res.StatusCode == http.StatusNotModified {
45818 if res.Body != nil {
45819 res.Body.Close()
45820 }
45821 return nil, &googleapi.Error{
45822 Code: res.StatusCode,
45823 Header: res.Header,
45824 }
45825 }
45826 if err != nil {
45827 return nil, err
45828 }
45829 defer googleapi.CloseBody(res)
45830 if err := googleapi.CheckResponse(res); err != nil {
45831 return nil, err
45832 }
45833 ret := &FileList{
45834 ServerResponse: googleapi.ServerResponse{
45835 Header: res.Header,
45836 HTTPStatusCode: res.StatusCode,
45837 },
45838 }
45839 target := &ret
45840 if err := gensupport.DecodeResponse(target, res); err != nil {
45841 return nil, err
45842 }
45843 return ret, nil
45844
45845
45846
45847
45848
45849
45850
45851
45852
45853
45854
45855
45856
45857
45858
45859
45860
45861
45862
45863
45864
45865
45866
45867
45868
45869
45870
45871
45872
45873
45874
45875
45876
45877
45878
45879
45880
45881
45882
45883
45884
45885
45886
45887
45888
45889
45890
45891
45892
45893
45894
45895
45896
45897
45898
45899
45900
45901
45902
45903
45904
45905
45906
45907
45908
45909
45910
45911
45912
45913
45914
45915
45916
45917
45918
45919 }
45920
45921
45922
45923
45924 func (c *ReportsFilesListCall) Pages(ctx context.Context, f func(*FileList) error) error {
45925 c.ctx_ = ctx
45926 defer c.PageToken(c.urlParams_.Get("pageToken"))
45927 for {
45928 x, err := c.Do()
45929 if err != nil {
45930 return err
45931 }
45932 if err := f(x); err != nil {
45933 return err
45934 }
45935 if x.NextPageToken == "" {
45936 return nil
45937 }
45938 c.PageToken(x.NextPageToken)
45939 }
45940 }
45941
45942
45943
45944 type SitesGetCall struct {
45945 s *Service
45946 profileId int64
45947 id int64
45948 urlParams_ gensupport.URLParams
45949 ifNoneMatch_ string
45950 ctx_ context.Context
45951 header_ http.Header
45952 }
45953
45954
45955 func (r *SitesService) Get(profileId int64, id int64) *SitesGetCall {
45956 c := &SitesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
45957 c.profileId = profileId
45958 c.id = id
45959 return c
45960 }
45961
45962
45963
45964
45965 func (c *SitesGetCall) Fields(s ...googleapi.Field) *SitesGetCall {
45966 c.urlParams_.Set("fields", googleapi.CombineFields(s))
45967 return c
45968 }
45969
45970
45971
45972
45973
45974
45975 func (c *SitesGetCall) IfNoneMatch(entityTag string) *SitesGetCall {
45976 c.ifNoneMatch_ = entityTag
45977 return c
45978 }
45979
45980
45981
45982
45983 func (c *SitesGetCall) Context(ctx context.Context) *SitesGetCall {
45984 c.ctx_ = ctx
45985 return c
45986 }
45987
45988
45989
45990 func (c *SitesGetCall) Header() http.Header {
45991 if c.header_ == nil {
45992 c.header_ = make(http.Header)
45993 }
45994 return c.header_
45995 }
45996
45997 func (c *SitesGetCall) doRequest(alt string) (*http.Response, error) {
45998 reqHeaders := make(http.Header)
45999 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
46000 for k, v := range c.header_ {
46001 reqHeaders[k] = v
46002 }
46003 reqHeaders.Set("User-Agent", c.s.userAgent())
46004 if c.ifNoneMatch_ != "" {
46005 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
46006 }
46007 var body io.Reader = nil
46008 c.urlParams_.Set("alt", alt)
46009 c.urlParams_.Set("prettyPrint", "false")
46010 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/sites/{id}")
46011 urls += "?" + c.urlParams_.Encode()
46012 req, err := http.NewRequest("GET", urls, body)
46013 if err != nil {
46014 return nil, err
46015 }
46016 req.Header = reqHeaders
46017 googleapi.Expand(req.URL, map[string]string{
46018 "profileId": strconv.FormatInt(c.profileId, 10),
46019 "id": strconv.FormatInt(c.id, 10),
46020 })
46021 return gensupport.SendRequest(c.ctx_, c.s.client, req)
46022 }
46023
46024
46025
46026
46027
46028
46029
46030
46031 func (c *SitesGetCall) Do(opts ...googleapi.CallOption) (*Site, error) {
46032 gensupport.SetOptions(c.urlParams_, opts...)
46033 res, err := c.doRequest("json")
46034 if res != nil && res.StatusCode == http.StatusNotModified {
46035 if res.Body != nil {
46036 res.Body.Close()
46037 }
46038 return nil, &googleapi.Error{
46039 Code: res.StatusCode,
46040 Header: res.Header,
46041 }
46042 }
46043 if err != nil {
46044 return nil, err
46045 }
46046 defer googleapi.CloseBody(res)
46047 if err := googleapi.CheckResponse(res); err != nil {
46048 return nil, err
46049 }
46050 ret := &Site{
46051 ServerResponse: googleapi.ServerResponse{
46052 Header: res.Header,
46053 HTTPStatusCode: res.StatusCode,
46054 },
46055 }
46056 target := &ret
46057 if err := gensupport.DecodeResponse(target, res); err != nil {
46058 return nil, err
46059 }
46060 return ret, nil
46061
46062
46063
46064
46065
46066
46067
46068
46069
46070
46071
46072
46073
46074
46075
46076
46077
46078
46079
46080
46081
46082
46083
46084
46085
46086
46087
46088
46089
46090
46091
46092
46093
46094 }
46095
46096
46097
46098 type SitesInsertCall struct {
46099 s *Service
46100 profileId int64
46101 site *Site
46102 urlParams_ gensupport.URLParams
46103 ctx_ context.Context
46104 header_ http.Header
46105 }
46106
46107
46108 func (r *SitesService) Insert(profileId int64, site *Site) *SitesInsertCall {
46109 c := &SitesInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
46110 c.profileId = profileId
46111 c.site = site
46112 return c
46113 }
46114
46115
46116
46117
46118 func (c *SitesInsertCall) Fields(s ...googleapi.Field) *SitesInsertCall {
46119 c.urlParams_.Set("fields", googleapi.CombineFields(s))
46120 return c
46121 }
46122
46123
46124
46125
46126 func (c *SitesInsertCall) Context(ctx context.Context) *SitesInsertCall {
46127 c.ctx_ = ctx
46128 return c
46129 }
46130
46131
46132
46133 func (c *SitesInsertCall) Header() http.Header {
46134 if c.header_ == nil {
46135 c.header_ = make(http.Header)
46136 }
46137 return c.header_
46138 }
46139
46140 func (c *SitesInsertCall) doRequest(alt string) (*http.Response, error) {
46141 reqHeaders := make(http.Header)
46142 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
46143 for k, v := range c.header_ {
46144 reqHeaders[k] = v
46145 }
46146 reqHeaders.Set("User-Agent", c.s.userAgent())
46147 var body io.Reader = nil
46148 body, err := googleapi.WithoutDataWrapper.JSONReader(c.site)
46149 if err != nil {
46150 return nil, err
46151 }
46152 reqHeaders.Set("Content-Type", "application/json")
46153 c.urlParams_.Set("alt", alt)
46154 c.urlParams_.Set("prettyPrint", "false")
46155 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/sites")
46156 urls += "?" + c.urlParams_.Encode()
46157 req, err := http.NewRequest("POST", urls, body)
46158 if err != nil {
46159 return nil, err
46160 }
46161 req.Header = reqHeaders
46162 googleapi.Expand(req.URL, map[string]string{
46163 "profileId": strconv.FormatInt(c.profileId, 10),
46164 })
46165 return gensupport.SendRequest(c.ctx_, c.s.client, req)
46166 }
46167
46168
46169
46170
46171
46172
46173
46174
46175 func (c *SitesInsertCall) Do(opts ...googleapi.CallOption) (*Site, error) {
46176 gensupport.SetOptions(c.urlParams_, opts...)
46177 res, err := c.doRequest("json")
46178 if res != nil && res.StatusCode == http.StatusNotModified {
46179 if res.Body != nil {
46180 res.Body.Close()
46181 }
46182 return nil, &googleapi.Error{
46183 Code: res.StatusCode,
46184 Header: res.Header,
46185 }
46186 }
46187 if err != nil {
46188 return nil, err
46189 }
46190 defer googleapi.CloseBody(res)
46191 if err := googleapi.CheckResponse(res); err != nil {
46192 return nil, err
46193 }
46194 ret := &Site{
46195 ServerResponse: googleapi.ServerResponse{
46196 Header: res.Header,
46197 HTTPStatusCode: res.StatusCode,
46198 },
46199 }
46200 target := &ret
46201 if err := gensupport.DecodeResponse(target, res); err != nil {
46202 return nil, err
46203 }
46204 return ret, nil
46205
46206
46207
46208
46209
46210
46211
46212
46213
46214
46215
46216
46217
46218
46219
46220
46221
46222
46223
46224
46225
46226
46227
46228
46229
46230
46231
46232
46233 }
46234
46235
46236
46237 type SitesListCall struct {
46238 s *Service
46239 profileId int64
46240 urlParams_ gensupport.URLParams
46241 ifNoneMatch_ string
46242 ctx_ context.Context
46243 header_ http.Header
46244 }
46245
46246
46247
46248 func (r *SitesService) List(profileId int64) *SitesListCall {
46249 c := &SitesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
46250 c.profileId = profileId
46251 return c
46252 }
46253
46254
46255
46256
46257 func (c *SitesListCall) AcceptsInStreamVideoPlacements(acceptsInStreamVideoPlacements bool) *SitesListCall {
46258 c.urlParams_.Set("acceptsInStreamVideoPlacements", fmt.Sprint(acceptsInStreamVideoPlacements))
46259 return c
46260 }
46261
46262
46263
46264
46265 func (c *SitesListCall) AcceptsInterstitialPlacements(acceptsInterstitialPlacements bool) *SitesListCall {
46266 c.urlParams_.Set("acceptsInterstitialPlacements", fmt.Sprint(acceptsInterstitialPlacements))
46267 return c
46268 }
46269
46270
46271
46272
46273 func (c *SitesListCall) AcceptsPublisherPaidPlacements(acceptsPublisherPaidPlacements bool) *SitesListCall {
46274 c.urlParams_.Set("acceptsPublisherPaidPlacements", fmt.Sprint(acceptsPublisherPaidPlacements))
46275 return c
46276 }
46277
46278
46279
46280 func (c *SitesListCall) AdWordsSite(adWordsSite bool) *SitesListCall {
46281 c.urlParams_.Set("adWordsSite", fmt.Sprint(adWordsSite))
46282 return c
46283 }
46284
46285
46286
46287 func (c *SitesListCall) Approved(approved bool) *SitesListCall {
46288 c.urlParams_.Set("approved", fmt.Sprint(approved))
46289 return c
46290 }
46291
46292
46293
46294 func (c *SitesListCall) CampaignIds(campaignIds ...int64) *SitesListCall {
46295 var campaignIds_ []string
46296 for _, v := range campaignIds {
46297 campaignIds_ = append(campaignIds_, fmt.Sprint(v))
46298 }
46299 c.urlParams_.SetMulti("campaignIds", campaignIds_)
46300 return c
46301 }
46302
46303
46304
46305 func (c *SitesListCall) DirectorySiteIds(directorySiteIds ...int64) *SitesListCall {
46306 var directorySiteIds_ []string
46307 for _, v := range directorySiteIds {
46308 directorySiteIds_ = append(directorySiteIds_, fmt.Sprint(v))
46309 }
46310 c.urlParams_.SetMulti("directorySiteIds", directorySiteIds_)
46311 return c
46312 }
46313
46314
46315
46316 func (c *SitesListCall) Ids(ids ...int64) *SitesListCall {
46317 var ids_ []string
46318 for _, v := range ids {
46319 ids_ = append(ids_, fmt.Sprint(v))
46320 }
46321 c.urlParams_.SetMulti("ids", ids_)
46322 return c
46323 }
46324
46325
46326
46327 func (c *SitesListCall) MaxResults(maxResults int64) *SitesListCall {
46328 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
46329 return c
46330 }
46331
46332
46333
46334 func (c *SitesListCall) PageToken(pageToken string) *SitesListCall {
46335 c.urlParams_.Set("pageToken", pageToken)
46336 return c
46337 }
46338
46339
46340
46341
46342
46343
46344
46345
46346 func (c *SitesListCall) SearchString(searchString string) *SitesListCall {
46347 c.urlParams_.Set("searchString", searchString)
46348 return c
46349 }
46350
46351
46352
46353
46354
46355
46356
46357
46358 func (c *SitesListCall) SortField(sortField string) *SitesListCall {
46359 c.urlParams_.Set("sortField", sortField)
46360 return c
46361 }
46362
46363
46364
46365
46366
46367
46368
46369
46370 func (c *SitesListCall) SortOrder(sortOrder string) *SitesListCall {
46371 c.urlParams_.Set("sortOrder", sortOrder)
46372 return c
46373 }
46374
46375
46376
46377 func (c *SitesListCall) SubaccountId(subaccountId int64) *SitesListCall {
46378 c.urlParams_.Set("subaccountId", fmt.Sprint(subaccountId))
46379 return c
46380 }
46381
46382
46383
46384 func (c *SitesListCall) UnmappedSite(unmappedSite bool) *SitesListCall {
46385 c.urlParams_.Set("unmappedSite", fmt.Sprint(unmappedSite))
46386 return c
46387 }
46388
46389
46390
46391
46392 func (c *SitesListCall) Fields(s ...googleapi.Field) *SitesListCall {
46393 c.urlParams_.Set("fields", googleapi.CombineFields(s))
46394 return c
46395 }
46396
46397
46398
46399
46400
46401
46402 func (c *SitesListCall) IfNoneMatch(entityTag string) *SitesListCall {
46403 c.ifNoneMatch_ = entityTag
46404 return c
46405 }
46406
46407
46408
46409
46410 func (c *SitesListCall) Context(ctx context.Context) *SitesListCall {
46411 c.ctx_ = ctx
46412 return c
46413 }
46414
46415
46416
46417 func (c *SitesListCall) Header() http.Header {
46418 if c.header_ == nil {
46419 c.header_ = make(http.Header)
46420 }
46421 return c.header_
46422 }
46423
46424 func (c *SitesListCall) doRequest(alt string) (*http.Response, error) {
46425 reqHeaders := make(http.Header)
46426 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
46427 for k, v := range c.header_ {
46428 reqHeaders[k] = v
46429 }
46430 reqHeaders.Set("User-Agent", c.s.userAgent())
46431 if c.ifNoneMatch_ != "" {
46432 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
46433 }
46434 var body io.Reader = nil
46435 c.urlParams_.Set("alt", alt)
46436 c.urlParams_.Set("prettyPrint", "false")
46437 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/sites")
46438 urls += "?" + c.urlParams_.Encode()
46439 req, err := http.NewRequest("GET", urls, body)
46440 if err != nil {
46441 return nil, err
46442 }
46443 req.Header = reqHeaders
46444 googleapi.Expand(req.URL, map[string]string{
46445 "profileId": strconv.FormatInt(c.profileId, 10),
46446 })
46447 return gensupport.SendRequest(c.ctx_, c.s.client, req)
46448 }
46449
46450
46451
46452
46453
46454
46455
46456
46457 func (c *SitesListCall) Do(opts ...googleapi.CallOption) (*SitesListResponse, error) {
46458 gensupport.SetOptions(c.urlParams_, opts...)
46459 res, err := c.doRequest("json")
46460 if res != nil && res.StatusCode == http.StatusNotModified {
46461 if res.Body != nil {
46462 res.Body.Close()
46463 }
46464 return nil, &googleapi.Error{
46465 Code: res.StatusCode,
46466 Header: res.Header,
46467 }
46468 }
46469 if err != nil {
46470 return nil, err
46471 }
46472 defer googleapi.CloseBody(res)
46473 if err := googleapi.CheckResponse(res); err != nil {
46474 return nil, err
46475 }
46476 ret := &SitesListResponse{
46477 ServerResponse: googleapi.ServerResponse{
46478 Header: res.Header,
46479 HTTPStatusCode: res.StatusCode,
46480 },
46481 }
46482 target := &ret
46483 if err := gensupport.DecodeResponse(target, res); err != nil {
46484 return nil, err
46485 }
46486 return ret, nil
46487
46488
46489
46490
46491
46492
46493
46494
46495
46496
46497
46498
46499
46500
46501
46502
46503
46504
46505
46506
46507
46508
46509
46510
46511
46512
46513
46514
46515
46516
46517
46518
46519
46520
46521
46522
46523
46524
46525
46526
46527
46528
46529
46530
46531
46532
46533
46534
46535
46536
46537
46538
46539
46540
46541
46542
46543
46544
46545
46546
46547
46548
46549
46550
46551
46552
46553
46554
46555
46556
46557
46558
46559
46560
46561
46562
46563
46564
46565
46566
46567
46568
46569
46570
46571
46572
46573
46574
46575
46576
46577
46578
46579
46580
46581
46582
46583
46584
46585
46586
46587
46588
46589
46590
46591
46592
46593
46594
46595
46596
46597
46598
46599
46600
46601
46602
46603
46604
46605
46606
46607
46608
46609
46610
46611
46612
46613
46614
46615
46616 }
46617
46618
46619
46620
46621 func (c *SitesListCall) Pages(ctx context.Context, f func(*SitesListResponse) error) error {
46622 c.ctx_ = ctx
46623 defer c.PageToken(c.urlParams_.Get("pageToken"))
46624 for {
46625 x, err := c.Do()
46626 if err != nil {
46627 return err
46628 }
46629 if err := f(x); err != nil {
46630 return err
46631 }
46632 if x.NextPageToken == "" {
46633 return nil
46634 }
46635 c.PageToken(x.NextPageToken)
46636 }
46637 }
46638
46639
46640
46641 type SitesPatchCall struct {
46642 s *Service
46643 profileId int64
46644 site *Site
46645 urlParams_ gensupport.URLParams
46646 ctx_ context.Context
46647 header_ http.Header
46648 }
46649
46650
46651
46652 func (r *SitesService) Patch(profileId int64, id int64, site *Site) *SitesPatchCall {
46653 c := &SitesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
46654 c.profileId = profileId
46655 c.urlParams_.Set("id", fmt.Sprint(id))
46656 c.site = site
46657 return c
46658 }
46659
46660
46661
46662
46663 func (c *SitesPatchCall) Fields(s ...googleapi.Field) *SitesPatchCall {
46664 c.urlParams_.Set("fields", googleapi.CombineFields(s))
46665 return c
46666 }
46667
46668
46669
46670
46671 func (c *SitesPatchCall) Context(ctx context.Context) *SitesPatchCall {
46672 c.ctx_ = ctx
46673 return c
46674 }
46675
46676
46677
46678 func (c *SitesPatchCall) Header() http.Header {
46679 if c.header_ == nil {
46680 c.header_ = make(http.Header)
46681 }
46682 return c.header_
46683 }
46684
46685 func (c *SitesPatchCall) doRequest(alt string) (*http.Response, error) {
46686 reqHeaders := make(http.Header)
46687 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
46688 for k, v := range c.header_ {
46689 reqHeaders[k] = v
46690 }
46691 reqHeaders.Set("User-Agent", c.s.userAgent())
46692 var body io.Reader = nil
46693 body, err := googleapi.WithoutDataWrapper.JSONReader(c.site)
46694 if err != nil {
46695 return nil, err
46696 }
46697 reqHeaders.Set("Content-Type", "application/json")
46698 c.urlParams_.Set("alt", alt)
46699 c.urlParams_.Set("prettyPrint", "false")
46700 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/sites")
46701 urls += "?" + c.urlParams_.Encode()
46702 req, err := http.NewRequest("PATCH", urls, body)
46703 if err != nil {
46704 return nil, err
46705 }
46706 req.Header = reqHeaders
46707 googleapi.Expand(req.URL, map[string]string{
46708 "profileId": strconv.FormatInt(c.profileId, 10),
46709 })
46710 return gensupport.SendRequest(c.ctx_, c.s.client, req)
46711 }
46712
46713
46714
46715
46716
46717
46718
46719
46720 func (c *SitesPatchCall) Do(opts ...googleapi.CallOption) (*Site, error) {
46721 gensupport.SetOptions(c.urlParams_, opts...)
46722 res, err := c.doRequest("json")
46723 if res != nil && res.StatusCode == http.StatusNotModified {
46724 if res.Body != nil {
46725 res.Body.Close()
46726 }
46727 return nil, &googleapi.Error{
46728 Code: res.StatusCode,
46729 Header: res.Header,
46730 }
46731 }
46732 if err != nil {
46733 return nil, err
46734 }
46735 defer googleapi.CloseBody(res)
46736 if err := googleapi.CheckResponse(res); err != nil {
46737 return nil, err
46738 }
46739 ret := &Site{
46740 ServerResponse: googleapi.ServerResponse{
46741 Header: res.Header,
46742 HTTPStatusCode: res.StatusCode,
46743 },
46744 }
46745 target := &ret
46746 if err := gensupport.DecodeResponse(target, res); err != nil {
46747 return nil, err
46748 }
46749 return ret, nil
46750
46751
46752
46753
46754
46755
46756
46757
46758
46759
46760
46761
46762
46763
46764
46765
46766
46767
46768
46769
46770
46771
46772
46773
46774
46775
46776
46777
46778
46779
46780
46781
46782
46783
46784
46785
46786 }
46787
46788
46789
46790 type SitesUpdateCall struct {
46791 s *Service
46792 profileId int64
46793 site *Site
46794 urlParams_ gensupport.URLParams
46795 ctx_ context.Context
46796 header_ http.Header
46797 }
46798
46799
46800 func (r *SitesService) Update(profileId int64, site *Site) *SitesUpdateCall {
46801 c := &SitesUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
46802 c.profileId = profileId
46803 c.site = site
46804 return c
46805 }
46806
46807
46808
46809
46810 func (c *SitesUpdateCall) Fields(s ...googleapi.Field) *SitesUpdateCall {
46811 c.urlParams_.Set("fields", googleapi.CombineFields(s))
46812 return c
46813 }
46814
46815
46816
46817
46818 func (c *SitesUpdateCall) Context(ctx context.Context) *SitesUpdateCall {
46819 c.ctx_ = ctx
46820 return c
46821 }
46822
46823
46824
46825 func (c *SitesUpdateCall) Header() http.Header {
46826 if c.header_ == nil {
46827 c.header_ = make(http.Header)
46828 }
46829 return c.header_
46830 }
46831
46832 func (c *SitesUpdateCall) doRequest(alt string) (*http.Response, error) {
46833 reqHeaders := make(http.Header)
46834 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
46835 for k, v := range c.header_ {
46836 reqHeaders[k] = v
46837 }
46838 reqHeaders.Set("User-Agent", c.s.userAgent())
46839 var body io.Reader = nil
46840 body, err := googleapi.WithoutDataWrapper.JSONReader(c.site)
46841 if err != nil {
46842 return nil, err
46843 }
46844 reqHeaders.Set("Content-Type", "application/json")
46845 c.urlParams_.Set("alt", alt)
46846 c.urlParams_.Set("prettyPrint", "false")
46847 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/sites")
46848 urls += "?" + c.urlParams_.Encode()
46849 req, err := http.NewRequest("PUT", urls, body)
46850 if err != nil {
46851 return nil, err
46852 }
46853 req.Header = reqHeaders
46854 googleapi.Expand(req.URL, map[string]string{
46855 "profileId": strconv.FormatInt(c.profileId, 10),
46856 })
46857 return gensupport.SendRequest(c.ctx_, c.s.client, req)
46858 }
46859
46860
46861
46862
46863
46864
46865
46866
46867 func (c *SitesUpdateCall) Do(opts ...googleapi.CallOption) (*Site, error) {
46868 gensupport.SetOptions(c.urlParams_, opts...)
46869 res, err := c.doRequest("json")
46870 if res != nil && res.StatusCode == http.StatusNotModified {
46871 if res.Body != nil {
46872 res.Body.Close()
46873 }
46874 return nil, &googleapi.Error{
46875 Code: res.StatusCode,
46876 Header: res.Header,
46877 }
46878 }
46879 if err != nil {
46880 return nil, err
46881 }
46882 defer googleapi.CloseBody(res)
46883 if err := googleapi.CheckResponse(res); err != nil {
46884 return nil, err
46885 }
46886 ret := &Site{
46887 ServerResponse: googleapi.ServerResponse{
46888 Header: res.Header,
46889 HTTPStatusCode: res.StatusCode,
46890 },
46891 }
46892 target := &ret
46893 if err := gensupport.DecodeResponse(target, res); err != nil {
46894 return nil, err
46895 }
46896 return ret, nil
46897
46898
46899
46900
46901
46902
46903
46904
46905
46906
46907
46908
46909
46910
46911
46912
46913
46914
46915
46916
46917
46918
46919
46920
46921
46922
46923
46924
46925 }
46926
46927
46928
46929 type SizesGetCall struct {
46930 s *Service
46931 profileId int64
46932 id int64
46933 urlParams_ gensupport.URLParams
46934 ifNoneMatch_ string
46935 ctx_ context.Context
46936 header_ http.Header
46937 }
46938
46939
46940 func (r *SizesService) Get(profileId int64, id int64) *SizesGetCall {
46941 c := &SizesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
46942 c.profileId = profileId
46943 c.id = id
46944 return c
46945 }
46946
46947
46948
46949
46950 func (c *SizesGetCall) Fields(s ...googleapi.Field) *SizesGetCall {
46951 c.urlParams_.Set("fields", googleapi.CombineFields(s))
46952 return c
46953 }
46954
46955
46956
46957
46958
46959
46960 func (c *SizesGetCall) IfNoneMatch(entityTag string) *SizesGetCall {
46961 c.ifNoneMatch_ = entityTag
46962 return c
46963 }
46964
46965
46966
46967
46968 func (c *SizesGetCall) Context(ctx context.Context) *SizesGetCall {
46969 c.ctx_ = ctx
46970 return c
46971 }
46972
46973
46974
46975 func (c *SizesGetCall) Header() http.Header {
46976 if c.header_ == nil {
46977 c.header_ = make(http.Header)
46978 }
46979 return c.header_
46980 }
46981
46982 func (c *SizesGetCall) doRequest(alt string) (*http.Response, error) {
46983 reqHeaders := make(http.Header)
46984 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
46985 for k, v := range c.header_ {
46986 reqHeaders[k] = v
46987 }
46988 reqHeaders.Set("User-Agent", c.s.userAgent())
46989 if c.ifNoneMatch_ != "" {
46990 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
46991 }
46992 var body io.Reader = nil
46993 c.urlParams_.Set("alt", alt)
46994 c.urlParams_.Set("prettyPrint", "false")
46995 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/sizes/{id}")
46996 urls += "?" + c.urlParams_.Encode()
46997 req, err := http.NewRequest("GET", urls, body)
46998 if err != nil {
46999 return nil, err
47000 }
47001 req.Header = reqHeaders
47002 googleapi.Expand(req.URL, map[string]string{
47003 "profileId": strconv.FormatInt(c.profileId, 10),
47004 "id": strconv.FormatInt(c.id, 10),
47005 })
47006 return gensupport.SendRequest(c.ctx_, c.s.client, req)
47007 }
47008
47009
47010
47011
47012
47013
47014
47015
47016 func (c *SizesGetCall) Do(opts ...googleapi.CallOption) (*Size, error) {
47017 gensupport.SetOptions(c.urlParams_, opts...)
47018 res, err := c.doRequest("json")
47019 if res != nil && res.StatusCode == http.StatusNotModified {
47020 if res.Body != nil {
47021 res.Body.Close()
47022 }
47023 return nil, &googleapi.Error{
47024 Code: res.StatusCode,
47025 Header: res.Header,
47026 }
47027 }
47028 if err != nil {
47029 return nil, err
47030 }
47031 defer googleapi.CloseBody(res)
47032 if err := googleapi.CheckResponse(res); err != nil {
47033 return nil, err
47034 }
47035 ret := &Size{
47036 ServerResponse: googleapi.ServerResponse{
47037 Header: res.Header,
47038 HTTPStatusCode: res.StatusCode,
47039 },
47040 }
47041 target := &ret
47042 if err := gensupport.DecodeResponse(target, res); err != nil {
47043 return nil, err
47044 }
47045 return ret, nil
47046
47047
47048
47049
47050
47051
47052
47053
47054
47055
47056
47057
47058
47059
47060
47061
47062
47063
47064
47065
47066
47067
47068
47069
47070
47071
47072
47073
47074
47075
47076
47077
47078
47079 }
47080
47081
47082
47083 type SizesInsertCall struct {
47084 s *Service
47085 profileId int64
47086 size *Size
47087 urlParams_ gensupport.URLParams
47088 ctx_ context.Context
47089 header_ http.Header
47090 }
47091
47092
47093 func (r *SizesService) Insert(profileId int64, size *Size) *SizesInsertCall {
47094 c := &SizesInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
47095 c.profileId = profileId
47096 c.size = size
47097 return c
47098 }
47099
47100
47101
47102
47103 func (c *SizesInsertCall) Fields(s ...googleapi.Field) *SizesInsertCall {
47104 c.urlParams_.Set("fields", googleapi.CombineFields(s))
47105 return c
47106 }
47107
47108
47109
47110
47111 func (c *SizesInsertCall) Context(ctx context.Context) *SizesInsertCall {
47112 c.ctx_ = ctx
47113 return c
47114 }
47115
47116
47117
47118 func (c *SizesInsertCall) Header() http.Header {
47119 if c.header_ == nil {
47120 c.header_ = make(http.Header)
47121 }
47122 return c.header_
47123 }
47124
47125 func (c *SizesInsertCall) doRequest(alt string) (*http.Response, error) {
47126 reqHeaders := make(http.Header)
47127 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
47128 for k, v := range c.header_ {
47129 reqHeaders[k] = v
47130 }
47131 reqHeaders.Set("User-Agent", c.s.userAgent())
47132 var body io.Reader = nil
47133 body, err := googleapi.WithoutDataWrapper.JSONReader(c.size)
47134 if err != nil {
47135 return nil, err
47136 }
47137 reqHeaders.Set("Content-Type", "application/json")
47138 c.urlParams_.Set("alt", alt)
47139 c.urlParams_.Set("prettyPrint", "false")
47140 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/sizes")
47141 urls += "?" + c.urlParams_.Encode()
47142 req, err := http.NewRequest("POST", urls, body)
47143 if err != nil {
47144 return nil, err
47145 }
47146 req.Header = reqHeaders
47147 googleapi.Expand(req.URL, map[string]string{
47148 "profileId": strconv.FormatInt(c.profileId, 10),
47149 })
47150 return gensupport.SendRequest(c.ctx_, c.s.client, req)
47151 }
47152
47153
47154
47155
47156
47157
47158
47159
47160 func (c *SizesInsertCall) Do(opts ...googleapi.CallOption) (*Size, error) {
47161 gensupport.SetOptions(c.urlParams_, opts...)
47162 res, err := c.doRequest("json")
47163 if res != nil && res.StatusCode == http.StatusNotModified {
47164 if res.Body != nil {
47165 res.Body.Close()
47166 }
47167 return nil, &googleapi.Error{
47168 Code: res.StatusCode,
47169 Header: res.Header,
47170 }
47171 }
47172 if err != nil {
47173 return nil, err
47174 }
47175 defer googleapi.CloseBody(res)
47176 if err := googleapi.CheckResponse(res); err != nil {
47177 return nil, err
47178 }
47179 ret := &Size{
47180 ServerResponse: googleapi.ServerResponse{
47181 Header: res.Header,
47182 HTTPStatusCode: res.StatusCode,
47183 },
47184 }
47185 target := &ret
47186 if err := gensupport.DecodeResponse(target, res); err != nil {
47187 return nil, err
47188 }
47189 return ret, nil
47190
47191
47192
47193
47194
47195
47196
47197
47198
47199
47200
47201
47202
47203
47204
47205
47206
47207
47208
47209
47210
47211
47212
47213
47214
47215
47216
47217
47218 }
47219
47220
47221
47222 type SizesListCall struct {
47223 s *Service
47224 profileId int64
47225 urlParams_ gensupport.URLParams
47226 ifNoneMatch_ string
47227 ctx_ context.Context
47228 header_ http.Header
47229 }
47230
47231
47232
47233
47234
47235 func (r *SizesService) List(profileId int64) *SizesListCall {
47236 c := &SizesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
47237 c.profileId = profileId
47238 return c
47239 }
47240
47241
47242
47243 func (c *SizesListCall) Height(height int64) *SizesListCall {
47244 c.urlParams_.Set("height", fmt.Sprint(height))
47245 return c
47246 }
47247
47248
47249
47250 func (c *SizesListCall) IabStandard(iabStandard bool) *SizesListCall {
47251 c.urlParams_.Set("iabStandard", fmt.Sprint(iabStandard))
47252 return c
47253 }
47254
47255
47256
47257 func (c *SizesListCall) Ids(ids ...int64) *SizesListCall {
47258 var ids_ []string
47259 for _, v := range ids {
47260 ids_ = append(ids_, fmt.Sprint(v))
47261 }
47262 c.urlParams_.SetMulti("ids", ids_)
47263 return c
47264 }
47265
47266
47267
47268 func (c *SizesListCall) Width(width int64) *SizesListCall {
47269 c.urlParams_.Set("width", fmt.Sprint(width))
47270 return c
47271 }
47272
47273
47274
47275
47276 func (c *SizesListCall) Fields(s ...googleapi.Field) *SizesListCall {
47277 c.urlParams_.Set("fields", googleapi.CombineFields(s))
47278 return c
47279 }
47280
47281
47282
47283
47284
47285
47286 func (c *SizesListCall) IfNoneMatch(entityTag string) *SizesListCall {
47287 c.ifNoneMatch_ = entityTag
47288 return c
47289 }
47290
47291
47292
47293
47294 func (c *SizesListCall) Context(ctx context.Context) *SizesListCall {
47295 c.ctx_ = ctx
47296 return c
47297 }
47298
47299
47300
47301 func (c *SizesListCall) Header() http.Header {
47302 if c.header_ == nil {
47303 c.header_ = make(http.Header)
47304 }
47305 return c.header_
47306 }
47307
47308 func (c *SizesListCall) doRequest(alt string) (*http.Response, error) {
47309 reqHeaders := make(http.Header)
47310 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
47311 for k, v := range c.header_ {
47312 reqHeaders[k] = v
47313 }
47314 reqHeaders.Set("User-Agent", c.s.userAgent())
47315 if c.ifNoneMatch_ != "" {
47316 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
47317 }
47318 var body io.Reader = nil
47319 c.urlParams_.Set("alt", alt)
47320 c.urlParams_.Set("prettyPrint", "false")
47321 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/sizes")
47322 urls += "?" + c.urlParams_.Encode()
47323 req, err := http.NewRequest("GET", urls, body)
47324 if err != nil {
47325 return nil, err
47326 }
47327 req.Header = reqHeaders
47328 googleapi.Expand(req.URL, map[string]string{
47329 "profileId": strconv.FormatInt(c.profileId, 10),
47330 })
47331 return gensupport.SendRequest(c.ctx_, c.s.client, req)
47332 }
47333
47334
47335
47336
47337
47338
47339
47340
47341 func (c *SizesListCall) Do(opts ...googleapi.CallOption) (*SizesListResponse, error) {
47342 gensupport.SetOptions(c.urlParams_, opts...)
47343 res, err := c.doRequest("json")
47344 if res != nil && res.StatusCode == http.StatusNotModified {
47345 if res.Body != nil {
47346 res.Body.Close()
47347 }
47348 return nil, &googleapi.Error{
47349 Code: res.StatusCode,
47350 Header: res.Header,
47351 }
47352 }
47353 if err != nil {
47354 return nil, err
47355 }
47356 defer googleapi.CloseBody(res)
47357 if err := googleapi.CheckResponse(res); err != nil {
47358 return nil, err
47359 }
47360 ret := &SizesListResponse{
47361 ServerResponse: googleapi.ServerResponse{
47362 Header: res.Header,
47363 HTTPStatusCode: res.StatusCode,
47364 },
47365 }
47366 target := &ret
47367 if err := gensupport.DecodeResponse(target, res); err != nil {
47368 return nil, err
47369 }
47370 return ret, nil
47371
47372
47373
47374
47375
47376
47377
47378
47379
47380
47381
47382
47383
47384
47385
47386
47387
47388
47389
47390
47391
47392
47393
47394
47395
47396
47397
47398
47399
47400
47401
47402
47403
47404
47405
47406
47407
47408
47409
47410
47411
47412
47413
47414
47415
47416
47417
47418
47419
47420
47421
47422
47423
47424 }
47425
47426
47427
47428 type SubaccountsGetCall struct {
47429 s *Service
47430 profileId int64
47431 id int64
47432 urlParams_ gensupport.URLParams
47433 ifNoneMatch_ string
47434 ctx_ context.Context
47435 header_ http.Header
47436 }
47437
47438
47439 func (r *SubaccountsService) Get(profileId int64, id int64) *SubaccountsGetCall {
47440 c := &SubaccountsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
47441 c.profileId = profileId
47442 c.id = id
47443 return c
47444 }
47445
47446
47447
47448
47449 func (c *SubaccountsGetCall) Fields(s ...googleapi.Field) *SubaccountsGetCall {
47450 c.urlParams_.Set("fields", googleapi.CombineFields(s))
47451 return c
47452 }
47453
47454
47455
47456
47457
47458
47459 func (c *SubaccountsGetCall) IfNoneMatch(entityTag string) *SubaccountsGetCall {
47460 c.ifNoneMatch_ = entityTag
47461 return c
47462 }
47463
47464
47465
47466
47467 func (c *SubaccountsGetCall) Context(ctx context.Context) *SubaccountsGetCall {
47468 c.ctx_ = ctx
47469 return c
47470 }
47471
47472
47473
47474 func (c *SubaccountsGetCall) Header() http.Header {
47475 if c.header_ == nil {
47476 c.header_ = make(http.Header)
47477 }
47478 return c.header_
47479 }
47480
47481 func (c *SubaccountsGetCall) doRequest(alt string) (*http.Response, error) {
47482 reqHeaders := make(http.Header)
47483 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
47484 for k, v := range c.header_ {
47485 reqHeaders[k] = v
47486 }
47487 reqHeaders.Set("User-Agent", c.s.userAgent())
47488 if c.ifNoneMatch_ != "" {
47489 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
47490 }
47491 var body io.Reader = nil
47492 c.urlParams_.Set("alt", alt)
47493 c.urlParams_.Set("prettyPrint", "false")
47494 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/subaccounts/{id}")
47495 urls += "?" + c.urlParams_.Encode()
47496 req, err := http.NewRequest("GET", urls, body)
47497 if err != nil {
47498 return nil, err
47499 }
47500 req.Header = reqHeaders
47501 googleapi.Expand(req.URL, map[string]string{
47502 "profileId": strconv.FormatInt(c.profileId, 10),
47503 "id": strconv.FormatInt(c.id, 10),
47504 })
47505 return gensupport.SendRequest(c.ctx_, c.s.client, req)
47506 }
47507
47508
47509
47510
47511
47512
47513
47514
47515 func (c *SubaccountsGetCall) Do(opts ...googleapi.CallOption) (*Subaccount, error) {
47516 gensupport.SetOptions(c.urlParams_, opts...)
47517 res, err := c.doRequest("json")
47518 if res != nil && res.StatusCode == http.StatusNotModified {
47519 if res.Body != nil {
47520 res.Body.Close()
47521 }
47522 return nil, &googleapi.Error{
47523 Code: res.StatusCode,
47524 Header: res.Header,
47525 }
47526 }
47527 if err != nil {
47528 return nil, err
47529 }
47530 defer googleapi.CloseBody(res)
47531 if err := googleapi.CheckResponse(res); err != nil {
47532 return nil, err
47533 }
47534 ret := &Subaccount{
47535 ServerResponse: googleapi.ServerResponse{
47536 Header: res.Header,
47537 HTTPStatusCode: res.StatusCode,
47538 },
47539 }
47540 target := &ret
47541 if err := gensupport.DecodeResponse(target, res); err != nil {
47542 return nil, err
47543 }
47544 return ret, nil
47545
47546
47547
47548
47549
47550
47551
47552
47553
47554
47555
47556
47557
47558
47559
47560
47561
47562
47563
47564
47565
47566
47567
47568
47569
47570
47571
47572
47573
47574
47575
47576
47577
47578 }
47579
47580
47581
47582 type SubaccountsInsertCall struct {
47583 s *Service
47584 profileId int64
47585 subaccount *Subaccount
47586 urlParams_ gensupport.URLParams
47587 ctx_ context.Context
47588 header_ http.Header
47589 }
47590
47591
47592 func (r *SubaccountsService) Insert(profileId int64, subaccount *Subaccount) *SubaccountsInsertCall {
47593 c := &SubaccountsInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
47594 c.profileId = profileId
47595 c.subaccount = subaccount
47596 return c
47597 }
47598
47599
47600
47601
47602 func (c *SubaccountsInsertCall) Fields(s ...googleapi.Field) *SubaccountsInsertCall {
47603 c.urlParams_.Set("fields", googleapi.CombineFields(s))
47604 return c
47605 }
47606
47607
47608
47609
47610 func (c *SubaccountsInsertCall) Context(ctx context.Context) *SubaccountsInsertCall {
47611 c.ctx_ = ctx
47612 return c
47613 }
47614
47615
47616
47617 func (c *SubaccountsInsertCall) Header() http.Header {
47618 if c.header_ == nil {
47619 c.header_ = make(http.Header)
47620 }
47621 return c.header_
47622 }
47623
47624 func (c *SubaccountsInsertCall) doRequest(alt string) (*http.Response, error) {
47625 reqHeaders := make(http.Header)
47626 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
47627 for k, v := range c.header_ {
47628 reqHeaders[k] = v
47629 }
47630 reqHeaders.Set("User-Agent", c.s.userAgent())
47631 var body io.Reader = nil
47632 body, err := googleapi.WithoutDataWrapper.JSONReader(c.subaccount)
47633 if err != nil {
47634 return nil, err
47635 }
47636 reqHeaders.Set("Content-Type", "application/json")
47637 c.urlParams_.Set("alt", alt)
47638 c.urlParams_.Set("prettyPrint", "false")
47639 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/subaccounts")
47640 urls += "?" + c.urlParams_.Encode()
47641 req, err := http.NewRequest("POST", urls, body)
47642 if err != nil {
47643 return nil, err
47644 }
47645 req.Header = reqHeaders
47646 googleapi.Expand(req.URL, map[string]string{
47647 "profileId": strconv.FormatInt(c.profileId, 10),
47648 })
47649 return gensupport.SendRequest(c.ctx_, c.s.client, req)
47650 }
47651
47652
47653
47654
47655
47656
47657
47658
47659 func (c *SubaccountsInsertCall) Do(opts ...googleapi.CallOption) (*Subaccount, error) {
47660 gensupport.SetOptions(c.urlParams_, opts...)
47661 res, err := c.doRequest("json")
47662 if res != nil && res.StatusCode == http.StatusNotModified {
47663 if res.Body != nil {
47664 res.Body.Close()
47665 }
47666 return nil, &googleapi.Error{
47667 Code: res.StatusCode,
47668 Header: res.Header,
47669 }
47670 }
47671 if err != nil {
47672 return nil, err
47673 }
47674 defer googleapi.CloseBody(res)
47675 if err := googleapi.CheckResponse(res); err != nil {
47676 return nil, err
47677 }
47678 ret := &Subaccount{
47679 ServerResponse: googleapi.ServerResponse{
47680 Header: res.Header,
47681 HTTPStatusCode: res.StatusCode,
47682 },
47683 }
47684 target := &ret
47685 if err := gensupport.DecodeResponse(target, res); err != nil {
47686 return nil, err
47687 }
47688 return ret, nil
47689
47690
47691
47692
47693
47694
47695
47696
47697
47698
47699
47700
47701
47702
47703
47704
47705
47706
47707
47708
47709
47710
47711
47712
47713
47714
47715
47716
47717 }
47718
47719
47720
47721 type SubaccountsListCall struct {
47722 s *Service
47723 profileId int64
47724 urlParams_ gensupport.URLParams
47725 ifNoneMatch_ string
47726 ctx_ context.Context
47727 header_ http.Header
47728 }
47729
47730
47731
47732 func (r *SubaccountsService) List(profileId int64) *SubaccountsListCall {
47733 c := &SubaccountsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
47734 c.profileId = profileId
47735 return c
47736 }
47737
47738
47739
47740 func (c *SubaccountsListCall) Ids(ids ...int64) *SubaccountsListCall {
47741 var ids_ []string
47742 for _, v := range ids {
47743 ids_ = append(ids_, fmt.Sprint(v))
47744 }
47745 c.urlParams_.SetMulti("ids", ids_)
47746 return c
47747 }
47748
47749
47750
47751 func (c *SubaccountsListCall) MaxResults(maxResults int64) *SubaccountsListCall {
47752 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
47753 return c
47754 }
47755
47756
47757
47758 func (c *SubaccountsListCall) PageToken(pageToken string) *SubaccountsListCall {
47759 c.urlParams_.Set("pageToken", pageToken)
47760 return c
47761 }
47762
47763
47764
47765
47766
47767
47768
47769
47770
47771 func (c *SubaccountsListCall) SearchString(searchString string) *SubaccountsListCall {
47772 c.urlParams_.Set("searchString", searchString)
47773 return c
47774 }
47775
47776
47777
47778
47779
47780
47781
47782
47783 func (c *SubaccountsListCall) SortField(sortField string) *SubaccountsListCall {
47784 c.urlParams_.Set("sortField", sortField)
47785 return c
47786 }
47787
47788
47789
47790
47791
47792
47793
47794
47795 func (c *SubaccountsListCall) SortOrder(sortOrder string) *SubaccountsListCall {
47796 c.urlParams_.Set("sortOrder", sortOrder)
47797 return c
47798 }
47799
47800
47801
47802
47803 func (c *SubaccountsListCall) Fields(s ...googleapi.Field) *SubaccountsListCall {
47804 c.urlParams_.Set("fields", googleapi.CombineFields(s))
47805 return c
47806 }
47807
47808
47809
47810
47811
47812
47813 func (c *SubaccountsListCall) IfNoneMatch(entityTag string) *SubaccountsListCall {
47814 c.ifNoneMatch_ = entityTag
47815 return c
47816 }
47817
47818
47819
47820
47821 func (c *SubaccountsListCall) Context(ctx context.Context) *SubaccountsListCall {
47822 c.ctx_ = ctx
47823 return c
47824 }
47825
47826
47827
47828 func (c *SubaccountsListCall) Header() http.Header {
47829 if c.header_ == nil {
47830 c.header_ = make(http.Header)
47831 }
47832 return c.header_
47833 }
47834
47835 func (c *SubaccountsListCall) doRequest(alt string) (*http.Response, error) {
47836 reqHeaders := make(http.Header)
47837 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
47838 for k, v := range c.header_ {
47839 reqHeaders[k] = v
47840 }
47841 reqHeaders.Set("User-Agent", c.s.userAgent())
47842 if c.ifNoneMatch_ != "" {
47843 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
47844 }
47845 var body io.Reader = nil
47846 c.urlParams_.Set("alt", alt)
47847 c.urlParams_.Set("prettyPrint", "false")
47848 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/subaccounts")
47849 urls += "?" + c.urlParams_.Encode()
47850 req, err := http.NewRequest("GET", urls, body)
47851 if err != nil {
47852 return nil, err
47853 }
47854 req.Header = reqHeaders
47855 googleapi.Expand(req.URL, map[string]string{
47856 "profileId": strconv.FormatInt(c.profileId, 10),
47857 })
47858 return gensupport.SendRequest(c.ctx_, c.s.client, req)
47859 }
47860
47861
47862
47863
47864
47865
47866
47867
47868 func (c *SubaccountsListCall) Do(opts ...googleapi.CallOption) (*SubaccountsListResponse, error) {
47869 gensupport.SetOptions(c.urlParams_, opts...)
47870 res, err := c.doRequest("json")
47871 if res != nil && res.StatusCode == http.StatusNotModified {
47872 if res.Body != nil {
47873 res.Body.Close()
47874 }
47875 return nil, &googleapi.Error{
47876 Code: res.StatusCode,
47877 Header: res.Header,
47878 }
47879 }
47880 if err != nil {
47881 return nil, err
47882 }
47883 defer googleapi.CloseBody(res)
47884 if err := googleapi.CheckResponse(res); err != nil {
47885 return nil, err
47886 }
47887 ret := &SubaccountsListResponse{
47888 ServerResponse: googleapi.ServerResponse{
47889 Header: res.Header,
47890 HTTPStatusCode: res.StatusCode,
47891 },
47892 }
47893 target := &ret
47894 if err := gensupport.DecodeResponse(target, res); err != nil {
47895 return nil, err
47896 }
47897 return ret, nil
47898
47899
47900
47901
47902
47903
47904
47905
47906
47907
47908
47909
47910
47911
47912
47913
47914
47915
47916
47917
47918
47919
47920
47921
47922
47923
47924
47925
47926
47927
47928
47929
47930
47931
47932
47933
47934
47935
47936
47937
47938
47939
47940
47941
47942
47943
47944
47945
47946
47947
47948
47949
47950
47951
47952
47953
47954
47955
47956
47957
47958
47959
47960
47961
47962
47963
47964
47965
47966
47967
47968
47969
47970
47971
47972
47973
47974
47975
47976
47977 }
47978
47979
47980
47981
47982 func (c *SubaccountsListCall) Pages(ctx context.Context, f func(*SubaccountsListResponse) error) error {
47983 c.ctx_ = ctx
47984 defer c.PageToken(c.urlParams_.Get("pageToken"))
47985 for {
47986 x, err := c.Do()
47987 if err != nil {
47988 return err
47989 }
47990 if err := f(x); err != nil {
47991 return err
47992 }
47993 if x.NextPageToken == "" {
47994 return nil
47995 }
47996 c.PageToken(x.NextPageToken)
47997 }
47998 }
47999
48000
48001
48002 type SubaccountsPatchCall struct {
48003 s *Service
48004 profileId int64
48005 subaccount *Subaccount
48006 urlParams_ gensupport.URLParams
48007 ctx_ context.Context
48008 header_ http.Header
48009 }
48010
48011
48012
48013 func (r *SubaccountsService) Patch(profileId int64, id int64, subaccount *Subaccount) *SubaccountsPatchCall {
48014 c := &SubaccountsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
48015 c.profileId = profileId
48016 c.urlParams_.Set("id", fmt.Sprint(id))
48017 c.subaccount = subaccount
48018 return c
48019 }
48020
48021
48022
48023
48024 func (c *SubaccountsPatchCall) Fields(s ...googleapi.Field) *SubaccountsPatchCall {
48025 c.urlParams_.Set("fields", googleapi.CombineFields(s))
48026 return c
48027 }
48028
48029
48030
48031
48032 func (c *SubaccountsPatchCall) Context(ctx context.Context) *SubaccountsPatchCall {
48033 c.ctx_ = ctx
48034 return c
48035 }
48036
48037
48038
48039 func (c *SubaccountsPatchCall) Header() http.Header {
48040 if c.header_ == nil {
48041 c.header_ = make(http.Header)
48042 }
48043 return c.header_
48044 }
48045
48046 func (c *SubaccountsPatchCall) doRequest(alt string) (*http.Response, error) {
48047 reqHeaders := make(http.Header)
48048 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
48049 for k, v := range c.header_ {
48050 reqHeaders[k] = v
48051 }
48052 reqHeaders.Set("User-Agent", c.s.userAgent())
48053 var body io.Reader = nil
48054 body, err := googleapi.WithoutDataWrapper.JSONReader(c.subaccount)
48055 if err != nil {
48056 return nil, err
48057 }
48058 reqHeaders.Set("Content-Type", "application/json")
48059 c.urlParams_.Set("alt", alt)
48060 c.urlParams_.Set("prettyPrint", "false")
48061 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/subaccounts")
48062 urls += "?" + c.urlParams_.Encode()
48063 req, err := http.NewRequest("PATCH", urls, body)
48064 if err != nil {
48065 return nil, err
48066 }
48067 req.Header = reqHeaders
48068 googleapi.Expand(req.URL, map[string]string{
48069 "profileId": strconv.FormatInt(c.profileId, 10),
48070 })
48071 return gensupport.SendRequest(c.ctx_, c.s.client, req)
48072 }
48073
48074
48075
48076
48077
48078
48079
48080
48081 func (c *SubaccountsPatchCall) Do(opts ...googleapi.CallOption) (*Subaccount, error) {
48082 gensupport.SetOptions(c.urlParams_, opts...)
48083 res, err := c.doRequest("json")
48084 if res != nil && res.StatusCode == http.StatusNotModified {
48085 if res.Body != nil {
48086 res.Body.Close()
48087 }
48088 return nil, &googleapi.Error{
48089 Code: res.StatusCode,
48090 Header: res.Header,
48091 }
48092 }
48093 if err != nil {
48094 return nil, err
48095 }
48096 defer googleapi.CloseBody(res)
48097 if err := googleapi.CheckResponse(res); err != nil {
48098 return nil, err
48099 }
48100 ret := &Subaccount{
48101 ServerResponse: googleapi.ServerResponse{
48102 Header: res.Header,
48103 HTTPStatusCode: res.StatusCode,
48104 },
48105 }
48106 target := &ret
48107 if err := gensupport.DecodeResponse(target, res); err != nil {
48108 return nil, err
48109 }
48110 return ret, nil
48111
48112
48113
48114
48115
48116
48117
48118
48119
48120
48121
48122
48123
48124
48125
48126
48127
48128
48129
48130
48131
48132
48133
48134
48135
48136
48137
48138
48139
48140
48141
48142
48143
48144
48145
48146
48147 }
48148
48149
48150
48151 type SubaccountsUpdateCall struct {
48152 s *Service
48153 profileId int64
48154 subaccount *Subaccount
48155 urlParams_ gensupport.URLParams
48156 ctx_ context.Context
48157 header_ http.Header
48158 }
48159
48160
48161 func (r *SubaccountsService) Update(profileId int64, subaccount *Subaccount) *SubaccountsUpdateCall {
48162 c := &SubaccountsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
48163 c.profileId = profileId
48164 c.subaccount = subaccount
48165 return c
48166 }
48167
48168
48169
48170
48171 func (c *SubaccountsUpdateCall) Fields(s ...googleapi.Field) *SubaccountsUpdateCall {
48172 c.urlParams_.Set("fields", googleapi.CombineFields(s))
48173 return c
48174 }
48175
48176
48177
48178
48179 func (c *SubaccountsUpdateCall) Context(ctx context.Context) *SubaccountsUpdateCall {
48180 c.ctx_ = ctx
48181 return c
48182 }
48183
48184
48185
48186 func (c *SubaccountsUpdateCall) Header() http.Header {
48187 if c.header_ == nil {
48188 c.header_ = make(http.Header)
48189 }
48190 return c.header_
48191 }
48192
48193 func (c *SubaccountsUpdateCall) doRequest(alt string) (*http.Response, error) {
48194 reqHeaders := make(http.Header)
48195 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
48196 for k, v := range c.header_ {
48197 reqHeaders[k] = v
48198 }
48199 reqHeaders.Set("User-Agent", c.s.userAgent())
48200 var body io.Reader = nil
48201 body, err := googleapi.WithoutDataWrapper.JSONReader(c.subaccount)
48202 if err != nil {
48203 return nil, err
48204 }
48205 reqHeaders.Set("Content-Type", "application/json")
48206 c.urlParams_.Set("alt", alt)
48207 c.urlParams_.Set("prettyPrint", "false")
48208 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/subaccounts")
48209 urls += "?" + c.urlParams_.Encode()
48210 req, err := http.NewRequest("PUT", urls, body)
48211 if err != nil {
48212 return nil, err
48213 }
48214 req.Header = reqHeaders
48215 googleapi.Expand(req.URL, map[string]string{
48216 "profileId": strconv.FormatInt(c.profileId, 10),
48217 })
48218 return gensupport.SendRequest(c.ctx_, c.s.client, req)
48219 }
48220
48221
48222
48223
48224
48225
48226
48227
48228 func (c *SubaccountsUpdateCall) Do(opts ...googleapi.CallOption) (*Subaccount, error) {
48229 gensupport.SetOptions(c.urlParams_, opts...)
48230 res, err := c.doRequest("json")
48231 if res != nil && res.StatusCode == http.StatusNotModified {
48232 if res.Body != nil {
48233 res.Body.Close()
48234 }
48235 return nil, &googleapi.Error{
48236 Code: res.StatusCode,
48237 Header: res.Header,
48238 }
48239 }
48240 if err != nil {
48241 return nil, err
48242 }
48243 defer googleapi.CloseBody(res)
48244 if err := googleapi.CheckResponse(res); err != nil {
48245 return nil, err
48246 }
48247 ret := &Subaccount{
48248 ServerResponse: googleapi.ServerResponse{
48249 Header: res.Header,
48250 HTTPStatusCode: res.StatusCode,
48251 },
48252 }
48253 target := &ret
48254 if err := gensupport.DecodeResponse(target, res); err != nil {
48255 return nil, err
48256 }
48257 return ret, nil
48258
48259
48260
48261
48262
48263
48264
48265
48266
48267
48268
48269
48270
48271
48272
48273
48274
48275
48276
48277
48278
48279
48280
48281
48282
48283
48284
48285
48286 }
48287
48288
48289
48290 type TargetableRemarketingListsGetCall struct {
48291 s *Service
48292 profileId int64
48293 id int64
48294 urlParams_ gensupport.URLParams
48295 ifNoneMatch_ string
48296 ctx_ context.Context
48297 header_ http.Header
48298 }
48299
48300
48301 func (r *TargetableRemarketingListsService) Get(profileId int64, id int64) *TargetableRemarketingListsGetCall {
48302 c := &TargetableRemarketingListsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
48303 c.profileId = profileId
48304 c.id = id
48305 return c
48306 }
48307
48308
48309
48310
48311 func (c *TargetableRemarketingListsGetCall) Fields(s ...googleapi.Field) *TargetableRemarketingListsGetCall {
48312 c.urlParams_.Set("fields", googleapi.CombineFields(s))
48313 return c
48314 }
48315
48316
48317
48318
48319
48320
48321 func (c *TargetableRemarketingListsGetCall) IfNoneMatch(entityTag string) *TargetableRemarketingListsGetCall {
48322 c.ifNoneMatch_ = entityTag
48323 return c
48324 }
48325
48326
48327
48328
48329 func (c *TargetableRemarketingListsGetCall) Context(ctx context.Context) *TargetableRemarketingListsGetCall {
48330 c.ctx_ = ctx
48331 return c
48332 }
48333
48334
48335
48336 func (c *TargetableRemarketingListsGetCall) Header() http.Header {
48337 if c.header_ == nil {
48338 c.header_ = make(http.Header)
48339 }
48340 return c.header_
48341 }
48342
48343 func (c *TargetableRemarketingListsGetCall) doRequest(alt string) (*http.Response, error) {
48344 reqHeaders := make(http.Header)
48345 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
48346 for k, v := range c.header_ {
48347 reqHeaders[k] = v
48348 }
48349 reqHeaders.Set("User-Agent", c.s.userAgent())
48350 if c.ifNoneMatch_ != "" {
48351 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
48352 }
48353 var body io.Reader = nil
48354 c.urlParams_.Set("alt", alt)
48355 c.urlParams_.Set("prettyPrint", "false")
48356 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/targetableRemarketingLists/{id}")
48357 urls += "?" + c.urlParams_.Encode()
48358 req, err := http.NewRequest("GET", urls, body)
48359 if err != nil {
48360 return nil, err
48361 }
48362 req.Header = reqHeaders
48363 googleapi.Expand(req.URL, map[string]string{
48364 "profileId": strconv.FormatInt(c.profileId, 10),
48365 "id": strconv.FormatInt(c.id, 10),
48366 })
48367 return gensupport.SendRequest(c.ctx_, c.s.client, req)
48368 }
48369
48370
48371
48372
48373
48374
48375
48376
48377 func (c *TargetableRemarketingListsGetCall) Do(opts ...googleapi.CallOption) (*TargetableRemarketingList, error) {
48378 gensupport.SetOptions(c.urlParams_, opts...)
48379 res, err := c.doRequest("json")
48380 if res != nil && res.StatusCode == http.StatusNotModified {
48381 if res.Body != nil {
48382 res.Body.Close()
48383 }
48384 return nil, &googleapi.Error{
48385 Code: res.StatusCode,
48386 Header: res.Header,
48387 }
48388 }
48389 if err != nil {
48390 return nil, err
48391 }
48392 defer googleapi.CloseBody(res)
48393 if err := googleapi.CheckResponse(res); err != nil {
48394 return nil, err
48395 }
48396 ret := &TargetableRemarketingList{
48397 ServerResponse: googleapi.ServerResponse{
48398 Header: res.Header,
48399 HTTPStatusCode: res.StatusCode,
48400 },
48401 }
48402 target := &ret
48403 if err := gensupport.DecodeResponse(target, res); err != nil {
48404 return nil, err
48405 }
48406 return ret, nil
48407
48408
48409
48410
48411
48412
48413
48414
48415
48416
48417
48418
48419
48420
48421
48422
48423
48424
48425
48426
48427
48428
48429
48430
48431
48432
48433
48434
48435
48436
48437
48438
48439
48440 }
48441
48442
48443
48444 type TargetableRemarketingListsListCall struct {
48445 s *Service
48446 profileId int64
48447 urlParams_ gensupport.URLParams
48448 ifNoneMatch_ string
48449 ctx_ context.Context
48450 header_ http.Header
48451 }
48452
48453
48454
48455 func (r *TargetableRemarketingListsService) List(profileId int64, advertiserId int64) *TargetableRemarketingListsListCall {
48456 c := &TargetableRemarketingListsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
48457 c.profileId = profileId
48458 c.urlParams_.Set("advertiserId", fmt.Sprint(advertiserId))
48459 return c
48460 }
48461
48462
48463
48464 func (c *TargetableRemarketingListsListCall) Active(active bool) *TargetableRemarketingListsListCall {
48465 c.urlParams_.Set("active", fmt.Sprint(active))
48466 return c
48467 }
48468
48469
48470
48471 func (c *TargetableRemarketingListsListCall) MaxResults(maxResults int64) *TargetableRemarketingListsListCall {
48472 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
48473 return c
48474 }
48475
48476
48477
48478
48479
48480
48481
48482
48483
48484 func (c *TargetableRemarketingListsListCall) Name(name string) *TargetableRemarketingListsListCall {
48485 c.urlParams_.Set("name", name)
48486 return c
48487 }
48488
48489
48490
48491 func (c *TargetableRemarketingListsListCall) PageToken(pageToken string) *TargetableRemarketingListsListCall {
48492 c.urlParams_.Set("pageToken", pageToken)
48493 return c
48494 }
48495
48496
48497
48498
48499
48500
48501
48502
48503 func (c *TargetableRemarketingListsListCall) SortField(sortField string) *TargetableRemarketingListsListCall {
48504 c.urlParams_.Set("sortField", sortField)
48505 return c
48506 }
48507
48508
48509
48510
48511
48512
48513
48514
48515 func (c *TargetableRemarketingListsListCall) SortOrder(sortOrder string) *TargetableRemarketingListsListCall {
48516 c.urlParams_.Set("sortOrder", sortOrder)
48517 return c
48518 }
48519
48520
48521
48522
48523 func (c *TargetableRemarketingListsListCall) Fields(s ...googleapi.Field) *TargetableRemarketingListsListCall {
48524 c.urlParams_.Set("fields", googleapi.CombineFields(s))
48525 return c
48526 }
48527
48528
48529
48530
48531
48532
48533 func (c *TargetableRemarketingListsListCall) IfNoneMatch(entityTag string) *TargetableRemarketingListsListCall {
48534 c.ifNoneMatch_ = entityTag
48535 return c
48536 }
48537
48538
48539
48540
48541 func (c *TargetableRemarketingListsListCall) Context(ctx context.Context) *TargetableRemarketingListsListCall {
48542 c.ctx_ = ctx
48543 return c
48544 }
48545
48546
48547
48548 func (c *TargetableRemarketingListsListCall) Header() http.Header {
48549 if c.header_ == nil {
48550 c.header_ = make(http.Header)
48551 }
48552 return c.header_
48553 }
48554
48555 func (c *TargetableRemarketingListsListCall) doRequest(alt string) (*http.Response, error) {
48556 reqHeaders := make(http.Header)
48557 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
48558 for k, v := range c.header_ {
48559 reqHeaders[k] = v
48560 }
48561 reqHeaders.Set("User-Agent", c.s.userAgent())
48562 if c.ifNoneMatch_ != "" {
48563 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
48564 }
48565 var body io.Reader = nil
48566 c.urlParams_.Set("alt", alt)
48567 c.urlParams_.Set("prettyPrint", "false")
48568 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/targetableRemarketingLists")
48569 urls += "?" + c.urlParams_.Encode()
48570 req, err := http.NewRequest("GET", urls, body)
48571 if err != nil {
48572 return nil, err
48573 }
48574 req.Header = reqHeaders
48575 googleapi.Expand(req.URL, map[string]string{
48576 "profileId": strconv.FormatInt(c.profileId, 10),
48577 })
48578 return gensupport.SendRequest(c.ctx_, c.s.client, req)
48579 }
48580
48581
48582
48583
48584
48585
48586
48587
48588
48589 func (c *TargetableRemarketingListsListCall) Do(opts ...googleapi.CallOption) (*TargetableRemarketingListsListResponse, error) {
48590 gensupport.SetOptions(c.urlParams_, opts...)
48591 res, err := c.doRequest("json")
48592 if res != nil && res.StatusCode == http.StatusNotModified {
48593 if res.Body != nil {
48594 res.Body.Close()
48595 }
48596 return nil, &googleapi.Error{
48597 Code: res.StatusCode,
48598 Header: res.Header,
48599 }
48600 }
48601 if err != nil {
48602 return nil, err
48603 }
48604 defer googleapi.CloseBody(res)
48605 if err := googleapi.CheckResponse(res); err != nil {
48606 return nil, err
48607 }
48608 ret := &TargetableRemarketingListsListResponse{
48609 ServerResponse: googleapi.ServerResponse{
48610 Header: res.Header,
48611 HTTPStatusCode: res.StatusCode,
48612 },
48613 }
48614 target := &ret
48615 if err := gensupport.DecodeResponse(target, res); err != nil {
48616 return nil, err
48617 }
48618 return ret, nil
48619
48620
48621
48622
48623
48624
48625
48626
48627
48628
48629
48630
48631
48632
48633
48634
48635
48636
48637
48638
48639
48640
48641
48642
48643
48644
48645
48646
48647
48648
48649
48650
48651
48652
48653
48654
48655
48656
48657
48658
48659
48660
48661
48662
48663
48664
48665
48666
48667
48668
48669
48670
48671
48672
48673
48674
48675
48676
48677
48678
48679
48680
48681
48682
48683
48684
48685
48686
48687
48688
48689
48690
48691
48692
48693
48694
48695
48696
48697
48698
48699
48700
48701
48702
48703
48704 }
48705
48706
48707
48708
48709 func (c *TargetableRemarketingListsListCall) Pages(ctx context.Context, f func(*TargetableRemarketingListsListResponse) error) error {
48710 c.ctx_ = ctx
48711 defer c.PageToken(c.urlParams_.Get("pageToken"))
48712 for {
48713 x, err := c.Do()
48714 if err != nil {
48715 return err
48716 }
48717 if err := f(x); err != nil {
48718 return err
48719 }
48720 if x.NextPageToken == "" {
48721 return nil
48722 }
48723 c.PageToken(x.NextPageToken)
48724 }
48725 }
48726
48727
48728
48729 type TargetingTemplatesGetCall struct {
48730 s *Service
48731 profileId int64
48732 id int64
48733 urlParams_ gensupport.URLParams
48734 ifNoneMatch_ string
48735 ctx_ context.Context
48736 header_ http.Header
48737 }
48738
48739
48740 func (r *TargetingTemplatesService) Get(profileId int64, id int64) *TargetingTemplatesGetCall {
48741 c := &TargetingTemplatesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
48742 c.profileId = profileId
48743 c.id = id
48744 return c
48745 }
48746
48747
48748
48749
48750 func (c *TargetingTemplatesGetCall) Fields(s ...googleapi.Field) *TargetingTemplatesGetCall {
48751 c.urlParams_.Set("fields", googleapi.CombineFields(s))
48752 return c
48753 }
48754
48755
48756
48757
48758
48759
48760 func (c *TargetingTemplatesGetCall) IfNoneMatch(entityTag string) *TargetingTemplatesGetCall {
48761 c.ifNoneMatch_ = entityTag
48762 return c
48763 }
48764
48765
48766
48767
48768 func (c *TargetingTemplatesGetCall) Context(ctx context.Context) *TargetingTemplatesGetCall {
48769 c.ctx_ = ctx
48770 return c
48771 }
48772
48773
48774
48775 func (c *TargetingTemplatesGetCall) Header() http.Header {
48776 if c.header_ == nil {
48777 c.header_ = make(http.Header)
48778 }
48779 return c.header_
48780 }
48781
48782 func (c *TargetingTemplatesGetCall) doRequest(alt string) (*http.Response, error) {
48783 reqHeaders := make(http.Header)
48784 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
48785 for k, v := range c.header_ {
48786 reqHeaders[k] = v
48787 }
48788 reqHeaders.Set("User-Agent", c.s.userAgent())
48789 if c.ifNoneMatch_ != "" {
48790 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
48791 }
48792 var body io.Reader = nil
48793 c.urlParams_.Set("alt", alt)
48794 c.urlParams_.Set("prettyPrint", "false")
48795 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/targetingTemplates/{id}")
48796 urls += "?" + c.urlParams_.Encode()
48797 req, err := http.NewRequest("GET", urls, body)
48798 if err != nil {
48799 return nil, err
48800 }
48801 req.Header = reqHeaders
48802 googleapi.Expand(req.URL, map[string]string{
48803 "profileId": strconv.FormatInt(c.profileId, 10),
48804 "id": strconv.FormatInt(c.id, 10),
48805 })
48806 return gensupport.SendRequest(c.ctx_, c.s.client, req)
48807 }
48808
48809
48810
48811
48812
48813
48814
48815
48816 func (c *TargetingTemplatesGetCall) Do(opts ...googleapi.CallOption) (*TargetingTemplate, error) {
48817 gensupport.SetOptions(c.urlParams_, opts...)
48818 res, err := c.doRequest("json")
48819 if res != nil && res.StatusCode == http.StatusNotModified {
48820 if res.Body != nil {
48821 res.Body.Close()
48822 }
48823 return nil, &googleapi.Error{
48824 Code: res.StatusCode,
48825 Header: res.Header,
48826 }
48827 }
48828 if err != nil {
48829 return nil, err
48830 }
48831 defer googleapi.CloseBody(res)
48832 if err := googleapi.CheckResponse(res); err != nil {
48833 return nil, err
48834 }
48835 ret := &TargetingTemplate{
48836 ServerResponse: googleapi.ServerResponse{
48837 Header: res.Header,
48838 HTTPStatusCode: res.StatusCode,
48839 },
48840 }
48841 target := &ret
48842 if err := gensupport.DecodeResponse(target, res); err != nil {
48843 return nil, err
48844 }
48845 return ret, nil
48846
48847
48848
48849
48850
48851
48852
48853
48854
48855
48856
48857
48858
48859
48860
48861
48862
48863
48864
48865
48866
48867
48868
48869
48870
48871
48872
48873
48874
48875
48876
48877
48878
48879 }
48880
48881
48882
48883 type TargetingTemplatesInsertCall struct {
48884 s *Service
48885 profileId int64
48886 targetingtemplate *TargetingTemplate
48887 urlParams_ gensupport.URLParams
48888 ctx_ context.Context
48889 header_ http.Header
48890 }
48891
48892
48893 func (r *TargetingTemplatesService) Insert(profileId int64, targetingtemplate *TargetingTemplate) *TargetingTemplatesInsertCall {
48894 c := &TargetingTemplatesInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
48895 c.profileId = profileId
48896 c.targetingtemplate = targetingtemplate
48897 return c
48898 }
48899
48900
48901
48902
48903 func (c *TargetingTemplatesInsertCall) Fields(s ...googleapi.Field) *TargetingTemplatesInsertCall {
48904 c.urlParams_.Set("fields", googleapi.CombineFields(s))
48905 return c
48906 }
48907
48908
48909
48910
48911 func (c *TargetingTemplatesInsertCall) Context(ctx context.Context) *TargetingTemplatesInsertCall {
48912 c.ctx_ = ctx
48913 return c
48914 }
48915
48916
48917
48918 func (c *TargetingTemplatesInsertCall) Header() http.Header {
48919 if c.header_ == nil {
48920 c.header_ = make(http.Header)
48921 }
48922 return c.header_
48923 }
48924
48925 func (c *TargetingTemplatesInsertCall) doRequest(alt string) (*http.Response, error) {
48926 reqHeaders := make(http.Header)
48927 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
48928 for k, v := range c.header_ {
48929 reqHeaders[k] = v
48930 }
48931 reqHeaders.Set("User-Agent", c.s.userAgent())
48932 var body io.Reader = nil
48933 body, err := googleapi.WithoutDataWrapper.JSONReader(c.targetingtemplate)
48934 if err != nil {
48935 return nil, err
48936 }
48937 reqHeaders.Set("Content-Type", "application/json")
48938 c.urlParams_.Set("alt", alt)
48939 c.urlParams_.Set("prettyPrint", "false")
48940 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/targetingTemplates")
48941 urls += "?" + c.urlParams_.Encode()
48942 req, err := http.NewRequest("POST", urls, body)
48943 if err != nil {
48944 return nil, err
48945 }
48946 req.Header = reqHeaders
48947 googleapi.Expand(req.URL, map[string]string{
48948 "profileId": strconv.FormatInt(c.profileId, 10),
48949 })
48950 return gensupport.SendRequest(c.ctx_, c.s.client, req)
48951 }
48952
48953
48954
48955
48956
48957
48958
48959
48960 func (c *TargetingTemplatesInsertCall) Do(opts ...googleapi.CallOption) (*TargetingTemplate, error) {
48961 gensupport.SetOptions(c.urlParams_, opts...)
48962 res, err := c.doRequest("json")
48963 if res != nil && res.StatusCode == http.StatusNotModified {
48964 if res.Body != nil {
48965 res.Body.Close()
48966 }
48967 return nil, &googleapi.Error{
48968 Code: res.StatusCode,
48969 Header: res.Header,
48970 }
48971 }
48972 if err != nil {
48973 return nil, err
48974 }
48975 defer googleapi.CloseBody(res)
48976 if err := googleapi.CheckResponse(res); err != nil {
48977 return nil, err
48978 }
48979 ret := &TargetingTemplate{
48980 ServerResponse: googleapi.ServerResponse{
48981 Header: res.Header,
48982 HTTPStatusCode: res.StatusCode,
48983 },
48984 }
48985 target := &ret
48986 if err := gensupport.DecodeResponse(target, res); err != nil {
48987 return nil, err
48988 }
48989 return ret, nil
48990
48991
48992
48993
48994
48995
48996
48997
48998
48999
49000
49001
49002
49003
49004
49005
49006
49007
49008
49009
49010
49011
49012
49013
49014
49015
49016
49017
49018 }
49019
49020
49021
49022 type TargetingTemplatesListCall struct {
49023 s *Service
49024 profileId int64
49025 urlParams_ gensupport.URLParams
49026 ifNoneMatch_ string
49027 ctx_ context.Context
49028 header_ http.Header
49029 }
49030
49031
49032
49033 func (r *TargetingTemplatesService) List(profileId int64) *TargetingTemplatesListCall {
49034 c := &TargetingTemplatesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
49035 c.profileId = profileId
49036 return c
49037 }
49038
49039
49040
49041 func (c *TargetingTemplatesListCall) AdvertiserId(advertiserId int64) *TargetingTemplatesListCall {
49042 c.urlParams_.Set("advertiserId", fmt.Sprint(advertiserId))
49043 return c
49044 }
49045
49046
49047
49048 func (c *TargetingTemplatesListCall) Ids(ids ...int64) *TargetingTemplatesListCall {
49049 var ids_ []string
49050 for _, v := range ids {
49051 ids_ = append(ids_, fmt.Sprint(v))
49052 }
49053 c.urlParams_.SetMulti("ids", ids_)
49054 return c
49055 }
49056
49057
49058
49059 func (c *TargetingTemplatesListCall) MaxResults(maxResults int64) *TargetingTemplatesListCall {
49060 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
49061 return c
49062 }
49063
49064
49065
49066 func (c *TargetingTemplatesListCall) PageToken(pageToken string) *TargetingTemplatesListCall {
49067 c.urlParams_.Set("pageToken", pageToken)
49068 return c
49069 }
49070
49071
49072
49073
49074
49075
49076
49077
49078
49079 func (c *TargetingTemplatesListCall) SearchString(searchString string) *TargetingTemplatesListCall {
49080 c.urlParams_.Set("searchString", searchString)
49081 return c
49082 }
49083
49084
49085
49086
49087
49088
49089
49090
49091 func (c *TargetingTemplatesListCall) SortField(sortField string) *TargetingTemplatesListCall {
49092 c.urlParams_.Set("sortField", sortField)
49093 return c
49094 }
49095
49096
49097
49098
49099
49100
49101
49102
49103 func (c *TargetingTemplatesListCall) SortOrder(sortOrder string) *TargetingTemplatesListCall {
49104 c.urlParams_.Set("sortOrder", sortOrder)
49105 return c
49106 }
49107
49108
49109
49110
49111 func (c *TargetingTemplatesListCall) Fields(s ...googleapi.Field) *TargetingTemplatesListCall {
49112 c.urlParams_.Set("fields", googleapi.CombineFields(s))
49113 return c
49114 }
49115
49116
49117
49118
49119
49120
49121 func (c *TargetingTemplatesListCall) IfNoneMatch(entityTag string) *TargetingTemplatesListCall {
49122 c.ifNoneMatch_ = entityTag
49123 return c
49124 }
49125
49126
49127
49128
49129 func (c *TargetingTemplatesListCall) Context(ctx context.Context) *TargetingTemplatesListCall {
49130 c.ctx_ = ctx
49131 return c
49132 }
49133
49134
49135
49136 func (c *TargetingTemplatesListCall) Header() http.Header {
49137 if c.header_ == nil {
49138 c.header_ = make(http.Header)
49139 }
49140 return c.header_
49141 }
49142
49143 func (c *TargetingTemplatesListCall) doRequest(alt string) (*http.Response, error) {
49144 reqHeaders := make(http.Header)
49145 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
49146 for k, v := range c.header_ {
49147 reqHeaders[k] = v
49148 }
49149 reqHeaders.Set("User-Agent", c.s.userAgent())
49150 if c.ifNoneMatch_ != "" {
49151 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
49152 }
49153 var body io.Reader = nil
49154 c.urlParams_.Set("alt", alt)
49155 c.urlParams_.Set("prettyPrint", "false")
49156 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/targetingTemplates")
49157 urls += "?" + c.urlParams_.Encode()
49158 req, err := http.NewRequest("GET", urls, body)
49159 if err != nil {
49160 return nil, err
49161 }
49162 req.Header = reqHeaders
49163 googleapi.Expand(req.URL, map[string]string{
49164 "profileId": strconv.FormatInt(c.profileId, 10),
49165 })
49166 return gensupport.SendRequest(c.ctx_, c.s.client, req)
49167 }
49168
49169
49170
49171
49172
49173
49174
49175
49176 func (c *TargetingTemplatesListCall) Do(opts ...googleapi.CallOption) (*TargetingTemplatesListResponse, error) {
49177 gensupport.SetOptions(c.urlParams_, opts...)
49178 res, err := c.doRequest("json")
49179 if res != nil && res.StatusCode == http.StatusNotModified {
49180 if res.Body != nil {
49181 res.Body.Close()
49182 }
49183 return nil, &googleapi.Error{
49184 Code: res.StatusCode,
49185 Header: res.Header,
49186 }
49187 }
49188 if err != nil {
49189 return nil, err
49190 }
49191 defer googleapi.CloseBody(res)
49192 if err := googleapi.CheckResponse(res); err != nil {
49193 return nil, err
49194 }
49195 ret := &TargetingTemplatesListResponse{
49196 ServerResponse: googleapi.ServerResponse{
49197 Header: res.Header,
49198 HTTPStatusCode: res.StatusCode,
49199 },
49200 }
49201 target := &ret
49202 if err := gensupport.DecodeResponse(target, res); err != nil {
49203 return nil, err
49204 }
49205 return ret, nil
49206
49207
49208
49209
49210
49211
49212
49213
49214
49215
49216
49217
49218
49219
49220
49221
49222
49223
49224
49225
49226
49227
49228
49229
49230
49231
49232
49233
49234
49235
49236
49237
49238
49239
49240
49241
49242
49243
49244
49245
49246
49247
49248
49249
49250
49251
49252
49253
49254
49255
49256
49257
49258
49259
49260
49261
49262
49263
49264
49265
49266
49267
49268
49269
49270
49271
49272
49273
49274
49275
49276
49277
49278
49279
49280
49281
49282
49283
49284
49285
49286
49287
49288
49289
49290
49291 }
49292
49293
49294
49295
49296 func (c *TargetingTemplatesListCall) Pages(ctx context.Context, f func(*TargetingTemplatesListResponse) error) error {
49297 c.ctx_ = ctx
49298 defer c.PageToken(c.urlParams_.Get("pageToken"))
49299 for {
49300 x, err := c.Do()
49301 if err != nil {
49302 return err
49303 }
49304 if err := f(x); err != nil {
49305 return err
49306 }
49307 if x.NextPageToken == "" {
49308 return nil
49309 }
49310 c.PageToken(x.NextPageToken)
49311 }
49312 }
49313
49314
49315
49316 type TargetingTemplatesPatchCall struct {
49317 s *Service
49318 profileId int64
49319 targetingtemplate *TargetingTemplate
49320 urlParams_ gensupport.URLParams
49321 ctx_ context.Context
49322 header_ http.Header
49323 }
49324
49325
49326
49327 func (r *TargetingTemplatesService) Patch(profileId int64, id int64, targetingtemplate *TargetingTemplate) *TargetingTemplatesPatchCall {
49328 c := &TargetingTemplatesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
49329 c.profileId = profileId
49330 c.urlParams_.Set("id", fmt.Sprint(id))
49331 c.targetingtemplate = targetingtemplate
49332 return c
49333 }
49334
49335
49336
49337
49338 func (c *TargetingTemplatesPatchCall) Fields(s ...googleapi.Field) *TargetingTemplatesPatchCall {
49339 c.urlParams_.Set("fields", googleapi.CombineFields(s))
49340 return c
49341 }
49342
49343
49344
49345
49346 func (c *TargetingTemplatesPatchCall) Context(ctx context.Context) *TargetingTemplatesPatchCall {
49347 c.ctx_ = ctx
49348 return c
49349 }
49350
49351
49352
49353 func (c *TargetingTemplatesPatchCall) Header() http.Header {
49354 if c.header_ == nil {
49355 c.header_ = make(http.Header)
49356 }
49357 return c.header_
49358 }
49359
49360 func (c *TargetingTemplatesPatchCall) doRequest(alt string) (*http.Response, error) {
49361 reqHeaders := make(http.Header)
49362 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
49363 for k, v := range c.header_ {
49364 reqHeaders[k] = v
49365 }
49366 reqHeaders.Set("User-Agent", c.s.userAgent())
49367 var body io.Reader = nil
49368 body, err := googleapi.WithoutDataWrapper.JSONReader(c.targetingtemplate)
49369 if err != nil {
49370 return nil, err
49371 }
49372 reqHeaders.Set("Content-Type", "application/json")
49373 c.urlParams_.Set("alt", alt)
49374 c.urlParams_.Set("prettyPrint", "false")
49375 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/targetingTemplates")
49376 urls += "?" + c.urlParams_.Encode()
49377 req, err := http.NewRequest("PATCH", urls, body)
49378 if err != nil {
49379 return nil, err
49380 }
49381 req.Header = reqHeaders
49382 googleapi.Expand(req.URL, map[string]string{
49383 "profileId": strconv.FormatInt(c.profileId, 10),
49384 })
49385 return gensupport.SendRequest(c.ctx_, c.s.client, req)
49386 }
49387
49388
49389
49390
49391
49392
49393
49394
49395 func (c *TargetingTemplatesPatchCall) Do(opts ...googleapi.CallOption) (*TargetingTemplate, error) {
49396 gensupport.SetOptions(c.urlParams_, opts...)
49397 res, err := c.doRequest("json")
49398 if res != nil && res.StatusCode == http.StatusNotModified {
49399 if res.Body != nil {
49400 res.Body.Close()
49401 }
49402 return nil, &googleapi.Error{
49403 Code: res.StatusCode,
49404 Header: res.Header,
49405 }
49406 }
49407 if err != nil {
49408 return nil, err
49409 }
49410 defer googleapi.CloseBody(res)
49411 if err := googleapi.CheckResponse(res); err != nil {
49412 return nil, err
49413 }
49414 ret := &TargetingTemplate{
49415 ServerResponse: googleapi.ServerResponse{
49416 Header: res.Header,
49417 HTTPStatusCode: res.StatusCode,
49418 },
49419 }
49420 target := &ret
49421 if err := gensupport.DecodeResponse(target, res); err != nil {
49422 return nil, err
49423 }
49424 return ret, nil
49425
49426
49427
49428
49429
49430
49431
49432
49433
49434
49435
49436
49437
49438
49439
49440
49441
49442
49443
49444
49445
49446
49447
49448
49449
49450
49451
49452
49453
49454
49455
49456
49457
49458
49459
49460
49461 }
49462
49463
49464
49465 type TargetingTemplatesUpdateCall struct {
49466 s *Service
49467 profileId int64
49468 targetingtemplate *TargetingTemplate
49469 urlParams_ gensupport.URLParams
49470 ctx_ context.Context
49471 header_ http.Header
49472 }
49473
49474
49475 func (r *TargetingTemplatesService) Update(profileId int64, targetingtemplate *TargetingTemplate) *TargetingTemplatesUpdateCall {
49476 c := &TargetingTemplatesUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
49477 c.profileId = profileId
49478 c.targetingtemplate = targetingtemplate
49479 return c
49480 }
49481
49482
49483
49484
49485 func (c *TargetingTemplatesUpdateCall) Fields(s ...googleapi.Field) *TargetingTemplatesUpdateCall {
49486 c.urlParams_.Set("fields", googleapi.CombineFields(s))
49487 return c
49488 }
49489
49490
49491
49492
49493 func (c *TargetingTemplatesUpdateCall) Context(ctx context.Context) *TargetingTemplatesUpdateCall {
49494 c.ctx_ = ctx
49495 return c
49496 }
49497
49498
49499
49500 func (c *TargetingTemplatesUpdateCall) Header() http.Header {
49501 if c.header_ == nil {
49502 c.header_ = make(http.Header)
49503 }
49504 return c.header_
49505 }
49506
49507 func (c *TargetingTemplatesUpdateCall) doRequest(alt string) (*http.Response, error) {
49508 reqHeaders := make(http.Header)
49509 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
49510 for k, v := range c.header_ {
49511 reqHeaders[k] = v
49512 }
49513 reqHeaders.Set("User-Agent", c.s.userAgent())
49514 var body io.Reader = nil
49515 body, err := googleapi.WithoutDataWrapper.JSONReader(c.targetingtemplate)
49516 if err != nil {
49517 return nil, err
49518 }
49519 reqHeaders.Set("Content-Type", "application/json")
49520 c.urlParams_.Set("alt", alt)
49521 c.urlParams_.Set("prettyPrint", "false")
49522 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/targetingTemplates")
49523 urls += "?" + c.urlParams_.Encode()
49524 req, err := http.NewRequest("PUT", urls, body)
49525 if err != nil {
49526 return nil, err
49527 }
49528 req.Header = reqHeaders
49529 googleapi.Expand(req.URL, map[string]string{
49530 "profileId": strconv.FormatInt(c.profileId, 10),
49531 })
49532 return gensupport.SendRequest(c.ctx_, c.s.client, req)
49533 }
49534
49535
49536
49537
49538
49539
49540
49541
49542 func (c *TargetingTemplatesUpdateCall) Do(opts ...googleapi.CallOption) (*TargetingTemplate, error) {
49543 gensupport.SetOptions(c.urlParams_, opts...)
49544 res, err := c.doRequest("json")
49545 if res != nil && res.StatusCode == http.StatusNotModified {
49546 if res.Body != nil {
49547 res.Body.Close()
49548 }
49549 return nil, &googleapi.Error{
49550 Code: res.StatusCode,
49551 Header: res.Header,
49552 }
49553 }
49554 if err != nil {
49555 return nil, err
49556 }
49557 defer googleapi.CloseBody(res)
49558 if err := googleapi.CheckResponse(res); err != nil {
49559 return nil, err
49560 }
49561 ret := &TargetingTemplate{
49562 ServerResponse: googleapi.ServerResponse{
49563 Header: res.Header,
49564 HTTPStatusCode: res.StatusCode,
49565 },
49566 }
49567 target := &ret
49568 if err := gensupport.DecodeResponse(target, res); err != nil {
49569 return nil, err
49570 }
49571 return ret, nil
49572
49573
49574
49575
49576
49577
49578
49579
49580
49581
49582
49583
49584
49585
49586
49587
49588
49589
49590
49591
49592
49593
49594
49595
49596
49597
49598
49599
49600 }
49601
49602
49603
49604 type UserProfilesGetCall struct {
49605 s *Service
49606 profileId int64
49607 urlParams_ gensupport.URLParams
49608 ifNoneMatch_ string
49609 ctx_ context.Context
49610 header_ http.Header
49611 }
49612
49613
49614 func (r *UserProfilesService) Get(profileId int64) *UserProfilesGetCall {
49615 c := &UserProfilesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
49616 c.profileId = profileId
49617 return c
49618 }
49619
49620
49621
49622
49623 func (c *UserProfilesGetCall) Fields(s ...googleapi.Field) *UserProfilesGetCall {
49624 c.urlParams_.Set("fields", googleapi.CombineFields(s))
49625 return c
49626 }
49627
49628
49629
49630
49631
49632
49633 func (c *UserProfilesGetCall) IfNoneMatch(entityTag string) *UserProfilesGetCall {
49634 c.ifNoneMatch_ = entityTag
49635 return c
49636 }
49637
49638
49639
49640
49641 func (c *UserProfilesGetCall) Context(ctx context.Context) *UserProfilesGetCall {
49642 c.ctx_ = ctx
49643 return c
49644 }
49645
49646
49647
49648 func (c *UserProfilesGetCall) Header() http.Header {
49649 if c.header_ == nil {
49650 c.header_ = make(http.Header)
49651 }
49652 return c.header_
49653 }
49654
49655 func (c *UserProfilesGetCall) doRequest(alt string) (*http.Response, error) {
49656 reqHeaders := make(http.Header)
49657 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
49658 for k, v := range c.header_ {
49659 reqHeaders[k] = v
49660 }
49661 reqHeaders.Set("User-Agent", c.s.userAgent())
49662 if c.ifNoneMatch_ != "" {
49663 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
49664 }
49665 var body io.Reader = nil
49666 c.urlParams_.Set("alt", alt)
49667 c.urlParams_.Set("prettyPrint", "false")
49668 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}")
49669 urls += "?" + c.urlParams_.Encode()
49670 req, err := http.NewRequest("GET", urls, body)
49671 if err != nil {
49672 return nil, err
49673 }
49674 req.Header = reqHeaders
49675 googleapi.Expand(req.URL, map[string]string{
49676 "profileId": strconv.FormatInt(c.profileId, 10),
49677 })
49678 return gensupport.SendRequest(c.ctx_, c.s.client, req)
49679 }
49680
49681
49682
49683
49684
49685
49686
49687
49688 func (c *UserProfilesGetCall) Do(opts ...googleapi.CallOption) (*UserProfile, error) {
49689 gensupport.SetOptions(c.urlParams_, opts...)
49690 res, err := c.doRequest("json")
49691 if res != nil && res.StatusCode == http.StatusNotModified {
49692 if res.Body != nil {
49693 res.Body.Close()
49694 }
49695 return nil, &googleapi.Error{
49696 Code: res.StatusCode,
49697 Header: res.Header,
49698 }
49699 }
49700 if err != nil {
49701 return nil, err
49702 }
49703 defer googleapi.CloseBody(res)
49704 if err := googleapi.CheckResponse(res); err != nil {
49705 return nil, err
49706 }
49707 ret := &UserProfile{
49708 ServerResponse: googleapi.ServerResponse{
49709 Header: res.Header,
49710 HTTPStatusCode: res.StatusCode,
49711 },
49712 }
49713 target := &ret
49714 if err := gensupport.DecodeResponse(target, res); err != nil {
49715 return nil, err
49716 }
49717 return ret, nil
49718
49719
49720
49721
49722
49723
49724
49725
49726
49727
49728
49729
49730
49731
49732
49733
49734
49735
49736
49737
49738
49739
49740
49741
49742
49743
49744 }
49745
49746
49747
49748 type UserProfilesListCall struct {
49749 s *Service
49750 urlParams_ gensupport.URLParams
49751 ifNoneMatch_ string
49752 ctx_ context.Context
49753 header_ http.Header
49754 }
49755
49756
49757 func (r *UserProfilesService) List() *UserProfilesListCall {
49758 c := &UserProfilesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
49759 return c
49760 }
49761
49762
49763
49764
49765 func (c *UserProfilesListCall) Fields(s ...googleapi.Field) *UserProfilesListCall {
49766 c.urlParams_.Set("fields", googleapi.CombineFields(s))
49767 return c
49768 }
49769
49770
49771
49772
49773
49774
49775 func (c *UserProfilesListCall) IfNoneMatch(entityTag string) *UserProfilesListCall {
49776 c.ifNoneMatch_ = entityTag
49777 return c
49778 }
49779
49780
49781
49782
49783 func (c *UserProfilesListCall) Context(ctx context.Context) *UserProfilesListCall {
49784 c.ctx_ = ctx
49785 return c
49786 }
49787
49788
49789
49790 func (c *UserProfilesListCall) Header() http.Header {
49791 if c.header_ == nil {
49792 c.header_ = make(http.Header)
49793 }
49794 return c.header_
49795 }
49796
49797 func (c *UserProfilesListCall) doRequest(alt string) (*http.Response, error) {
49798 reqHeaders := make(http.Header)
49799 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
49800 for k, v := range c.header_ {
49801 reqHeaders[k] = v
49802 }
49803 reqHeaders.Set("User-Agent", c.s.userAgent())
49804 if c.ifNoneMatch_ != "" {
49805 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
49806 }
49807 var body io.Reader = nil
49808 c.urlParams_.Set("alt", alt)
49809 c.urlParams_.Set("prettyPrint", "false")
49810 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles")
49811 urls += "?" + c.urlParams_.Encode()
49812 req, err := http.NewRequest("GET", urls, body)
49813 if err != nil {
49814 return nil, err
49815 }
49816 req.Header = reqHeaders
49817 return gensupport.SendRequest(c.ctx_, c.s.client, req)
49818 }
49819
49820
49821
49822
49823
49824
49825
49826
49827 func (c *UserProfilesListCall) Do(opts ...googleapi.CallOption) (*UserProfileList, error) {
49828 gensupport.SetOptions(c.urlParams_, opts...)
49829 res, err := c.doRequest("json")
49830 if res != nil && res.StatusCode == http.StatusNotModified {
49831 if res.Body != nil {
49832 res.Body.Close()
49833 }
49834 return nil, &googleapi.Error{
49835 Code: res.StatusCode,
49836 Header: res.Header,
49837 }
49838 }
49839 if err != nil {
49840 return nil, err
49841 }
49842 defer googleapi.CloseBody(res)
49843 if err := googleapi.CheckResponse(res); err != nil {
49844 return nil, err
49845 }
49846 ret := &UserProfileList{
49847 ServerResponse: googleapi.ServerResponse{
49848 Header: res.Header,
49849 HTTPStatusCode: res.StatusCode,
49850 },
49851 }
49852 target := &ret
49853 if err := gensupport.DecodeResponse(target, res); err != nil {
49854 return nil, err
49855 }
49856 return ret, nil
49857
49858
49859
49860
49861
49862
49863
49864
49865
49866
49867
49868
49869
49870
49871 }
49872
49873
49874
49875 type UserRolePermissionGroupsGetCall struct {
49876 s *Service
49877 profileId int64
49878 id int64
49879 urlParams_ gensupport.URLParams
49880 ifNoneMatch_ string
49881 ctx_ context.Context
49882 header_ http.Header
49883 }
49884
49885
49886 func (r *UserRolePermissionGroupsService) Get(profileId int64, id int64) *UserRolePermissionGroupsGetCall {
49887 c := &UserRolePermissionGroupsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
49888 c.profileId = profileId
49889 c.id = id
49890 return c
49891 }
49892
49893
49894
49895
49896 func (c *UserRolePermissionGroupsGetCall) Fields(s ...googleapi.Field) *UserRolePermissionGroupsGetCall {
49897 c.urlParams_.Set("fields", googleapi.CombineFields(s))
49898 return c
49899 }
49900
49901
49902
49903
49904
49905
49906 func (c *UserRolePermissionGroupsGetCall) IfNoneMatch(entityTag string) *UserRolePermissionGroupsGetCall {
49907 c.ifNoneMatch_ = entityTag
49908 return c
49909 }
49910
49911
49912
49913
49914 func (c *UserRolePermissionGroupsGetCall) Context(ctx context.Context) *UserRolePermissionGroupsGetCall {
49915 c.ctx_ = ctx
49916 return c
49917 }
49918
49919
49920
49921 func (c *UserRolePermissionGroupsGetCall) Header() http.Header {
49922 if c.header_ == nil {
49923 c.header_ = make(http.Header)
49924 }
49925 return c.header_
49926 }
49927
49928 func (c *UserRolePermissionGroupsGetCall) doRequest(alt string) (*http.Response, error) {
49929 reqHeaders := make(http.Header)
49930 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
49931 for k, v := range c.header_ {
49932 reqHeaders[k] = v
49933 }
49934 reqHeaders.Set("User-Agent", c.s.userAgent())
49935 if c.ifNoneMatch_ != "" {
49936 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
49937 }
49938 var body io.Reader = nil
49939 c.urlParams_.Set("alt", alt)
49940 c.urlParams_.Set("prettyPrint", "false")
49941 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/userRolePermissionGroups/{id}")
49942 urls += "?" + c.urlParams_.Encode()
49943 req, err := http.NewRequest("GET", urls, body)
49944 if err != nil {
49945 return nil, err
49946 }
49947 req.Header = reqHeaders
49948 googleapi.Expand(req.URL, map[string]string{
49949 "profileId": strconv.FormatInt(c.profileId, 10),
49950 "id": strconv.FormatInt(c.id, 10),
49951 })
49952 return gensupport.SendRequest(c.ctx_, c.s.client, req)
49953 }
49954
49955
49956
49957
49958
49959
49960
49961
49962 func (c *UserRolePermissionGroupsGetCall) Do(opts ...googleapi.CallOption) (*UserRolePermissionGroup, error) {
49963 gensupport.SetOptions(c.urlParams_, opts...)
49964 res, err := c.doRequest("json")
49965 if res != nil && res.StatusCode == http.StatusNotModified {
49966 if res.Body != nil {
49967 res.Body.Close()
49968 }
49969 return nil, &googleapi.Error{
49970 Code: res.StatusCode,
49971 Header: res.Header,
49972 }
49973 }
49974 if err != nil {
49975 return nil, err
49976 }
49977 defer googleapi.CloseBody(res)
49978 if err := googleapi.CheckResponse(res); err != nil {
49979 return nil, err
49980 }
49981 ret := &UserRolePermissionGroup{
49982 ServerResponse: googleapi.ServerResponse{
49983 Header: res.Header,
49984 HTTPStatusCode: res.StatusCode,
49985 },
49986 }
49987 target := &ret
49988 if err := gensupport.DecodeResponse(target, res); err != nil {
49989 return nil, err
49990 }
49991 return ret, nil
49992
49993
49994
49995
49996
49997
49998
49999
50000
50001
50002
50003
50004
50005
50006
50007
50008
50009
50010
50011
50012
50013
50014
50015
50016
50017
50018
50019
50020
50021
50022
50023
50024
50025 }
50026
50027
50028
50029 type UserRolePermissionGroupsListCall struct {
50030 s *Service
50031 profileId int64
50032 urlParams_ gensupport.URLParams
50033 ifNoneMatch_ string
50034 ctx_ context.Context
50035 header_ http.Header
50036 }
50037
50038
50039 func (r *UserRolePermissionGroupsService) List(profileId int64) *UserRolePermissionGroupsListCall {
50040 c := &UserRolePermissionGroupsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
50041 c.profileId = profileId
50042 return c
50043 }
50044
50045
50046
50047
50048 func (c *UserRolePermissionGroupsListCall) Fields(s ...googleapi.Field) *UserRolePermissionGroupsListCall {
50049 c.urlParams_.Set("fields", googleapi.CombineFields(s))
50050 return c
50051 }
50052
50053
50054
50055
50056
50057
50058 func (c *UserRolePermissionGroupsListCall) IfNoneMatch(entityTag string) *UserRolePermissionGroupsListCall {
50059 c.ifNoneMatch_ = entityTag
50060 return c
50061 }
50062
50063
50064
50065
50066 func (c *UserRolePermissionGroupsListCall) Context(ctx context.Context) *UserRolePermissionGroupsListCall {
50067 c.ctx_ = ctx
50068 return c
50069 }
50070
50071
50072
50073 func (c *UserRolePermissionGroupsListCall) Header() http.Header {
50074 if c.header_ == nil {
50075 c.header_ = make(http.Header)
50076 }
50077 return c.header_
50078 }
50079
50080 func (c *UserRolePermissionGroupsListCall) doRequest(alt string) (*http.Response, error) {
50081 reqHeaders := make(http.Header)
50082 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
50083 for k, v := range c.header_ {
50084 reqHeaders[k] = v
50085 }
50086 reqHeaders.Set("User-Agent", c.s.userAgent())
50087 if c.ifNoneMatch_ != "" {
50088 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
50089 }
50090 var body io.Reader = nil
50091 c.urlParams_.Set("alt", alt)
50092 c.urlParams_.Set("prettyPrint", "false")
50093 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/userRolePermissionGroups")
50094 urls += "?" + c.urlParams_.Encode()
50095 req, err := http.NewRequest("GET", urls, body)
50096 if err != nil {
50097 return nil, err
50098 }
50099 req.Header = reqHeaders
50100 googleapi.Expand(req.URL, map[string]string{
50101 "profileId": strconv.FormatInt(c.profileId, 10),
50102 })
50103 return gensupport.SendRequest(c.ctx_, c.s.client, req)
50104 }
50105
50106
50107
50108
50109
50110
50111
50112
50113
50114 func (c *UserRolePermissionGroupsListCall) Do(opts ...googleapi.CallOption) (*UserRolePermissionGroupsListResponse, error) {
50115 gensupport.SetOptions(c.urlParams_, opts...)
50116 res, err := c.doRequest("json")
50117 if res != nil && res.StatusCode == http.StatusNotModified {
50118 if res.Body != nil {
50119 res.Body.Close()
50120 }
50121 return nil, &googleapi.Error{
50122 Code: res.StatusCode,
50123 Header: res.Header,
50124 }
50125 }
50126 if err != nil {
50127 return nil, err
50128 }
50129 defer googleapi.CloseBody(res)
50130 if err := googleapi.CheckResponse(res); err != nil {
50131 return nil, err
50132 }
50133 ret := &UserRolePermissionGroupsListResponse{
50134 ServerResponse: googleapi.ServerResponse{
50135 Header: res.Header,
50136 HTTPStatusCode: res.StatusCode,
50137 },
50138 }
50139 target := &ret
50140 if err := gensupport.DecodeResponse(target, res); err != nil {
50141 return nil, err
50142 }
50143 return ret, nil
50144
50145
50146
50147
50148
50149
50150
50151
50152
50153
50154
50155
50156
50157
50158
50159
50160
50161
50162
50163
50164
50165
50166
50167
50168
50169 }
50170
50171
50172
50173 type UserRolePermissionsGetCall struct {
50174 s *Service
50175 profileId int64
50176 id int64
50177 urlParams_ gensupport.URLParams
50178 ifNoneMatch_ string
50179 ctx_ context.Context
50180 header_ http.Header
50181 }
50182
50183
50184 func (r *UserRolePermissionsService) Get(profileId int64, id int64) *UserRolePermissionsGetCall {
50185 c := &UserRolePermissionsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
50186 c.profileId = profileId
50187 c.id = id
50188 return c
50189 }
50190
50191
50192
50193
50194 func (c *UserRolePermissionsGetCall) Fields(s ...googleapi.Field) *UserRolePermissionsGetCall {
50195 c.urlParams_.Set("fields", googleapi.CombineFields(s))
50196 return c
50197 }
50198
50199
50200
50201
50202
50203
50204 func (c *UserRolePermissionsGetCall) IfNoneMatch(entityTag string) *UserRolePermissionsGetCall {
50205 c.ifNoneMatch_ = entityTag
50206 return c
50207 }
50208
50209
50210
50211
50212 func (c *UserRolePermissionsGetCall) Context(ctx context.Context) *UserRolePermissionsGetCall {
50213 c.ctx_ = ctx
50214 return c
50215 }
50216
50217
50218
50219 func (c *UserRolePermissionsGetCall) Header() http.Header {
50220 if c.header_ == nil {
50221 c.header_ = make(http.Header)
50222 }
50223 return c.header_
50224 }
50225
50226 func (c *UserRolePermissionsGetCall) doRequest(alt string) (*http.Response, error) {
50227 reqHeaders := make(http.Header)
50228 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
50229 for k, v := range c.header_ {
50230 reqHeaders[k] = v
50231 }
50232 reqHeaders.Set("User-Agent", c.s.userAgent())
50233 if c.ifNoneMatch_ != "" {
50234 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
50235 }
50236 var body io.Reader = nil
50237 c.urlParams_.Set("alt", alt)
50238 c.urlParams_.Set("prettyPrint", "false")
50239 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/userRolePermissions/{id}")
50240 urls += "?" + c.urlParams_.Encode()
50241 req, err := http.NewRequest("GET", urls, body)
50242 if err != nil {
50243 return nil, err
50244 }
50245 req.Header = reqHeaders
50246 googleapi.Expand(req.URL, map[string]string{
50247 "profileId": strconv.FormatInt(c.profileId, 10),
50248 "id": strconv.FormatInt(c.id, 10),
50249 })
50250 return gensupport.SendRequest(c.ctx_, c.s.client, req)
50251 }
50252
50253
50254
50255
50256
50257
50258
50259
50260 func (c *UserRolePermissionsGetCall) Do(opts ...googleapi.CallOption) (*UserRolePermission, error) {
50261 gensupport.SetOptions(c.urlParams_, opts...)
50262 res, err := c.doRequest("json")
50263 if res != nil && res.StatusCode == http.StatusNotModified {
50264 if res.Body != nil {
50265 res.Body.Close()
50266 }
50267 return nil, &googleapi.Error{
50268 Code: res.StatusCode,
50269 Header: res.Header,
50270 }
50271 }
50272 if err != nil {
50273 return nil, err
50274 }
50275 defer googleapi.CloseBody(res)
50276 if err := googleapi.CheckResponse(res); err != nil {
50277 return nil, err
50278 }
50279 ret := &UserRolePermission{
50280 ServerResponse: googleapi.ServerResponse{
50281 Header: res.Header,
50282 HTTPStatusCode: res.StatusCode,
50283 },
50284 }
50285 target := &ret
50286 if err := gensupport.DecodeResponse(target, res); err != nil {
50287 return nil, err
50288 }
50289 return ret, nil
50290
50291
50292
50293
50294
50295
50296
50297
50298
50299
50300
50301
50302
50303
50304
50305
50306
50307
50308
50309
50310
50311
50312
50313
50314
50315
50316
50317
50318
50319
50320
50321
50322
50323 }
50324
50325
50326
50327 type UserRolePermissionsListCall struct {
50328 s *Service
50329 profileId int64
50330 urlParams_ gensupport.URLParams
50331 ifNoneMatch_ string
50332 ctx_ context.Context
50333 header_ http.Header
50334 }
50335
50336
50337 func (r *UserRolePermissionsService) List(profileId int64) *UserRolePermissionsListCall {
50338 c := &UserRolePermissionsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
50339 c.profileId = profileId
50340 return c
50341 }
50342
50343
50344
50345 func (c *UserRolePermissionsListCall) Ids(ids ...int64) *UserRolePermissionsListCall {
50346 var ids_ []string
50347 for _, v := range ids {
50348 ids_ = append(ids_, fmt.Sprint(v))
50349 }
50350 c.urlParams_.SetMulti("ids", ids_)
50351 return c
50352 }
50353
50354
50355
50356
50357 func (c *UserRolePermissionsListCall) Fields(s ...googleapi.Field) *UserRolePermissionsListCall {
50358 c.urlParams_.Set("fields", googleapi.CombineFields(s))
50359 return c
50360 }
50361
50362
50363
50364
50365
50366
50367 func (c *UserRolePermissionsListCall) IfNoneMatch(entityTag string) *UserRolePermissionsListCall {
50368 c.ifNoneMatch_ = entityTag
50369 return c
50370 }
50371
50372
50373
50374
50375 func (c *UserRolePermissionsListCall) Context(ctx context.Context) *UserRolePermissionsListCall {
50376 c.ctx_ = ctx
50377 return c
50378 }
50379
50380
50381
50382 func (c *UserRolePermissionsListCall) Header() http.Header {
50383 if c.header_ == nil {
50384 c.header_ = make(http.Header)
50385 }
50386 return c.header_
50387 }
50388
50389 func (c *UserRolePermissionsListCall) doRequest(alt string) (*http.Response, error) {
50390 reqHeaders := make(http.Header)
50391 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
50392 for k, v := range c.header_ {
50393 reqHeaders[k] = v
50394 }
50395 reqHeaders.Set("User-Agent", c.s.userAgent())
50396 if c.ifNoneMatch_ != "" {
50397 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
50398 }
50399 var body io.Reader = nil
50400 c.urlParams_.Set("alt", alt)
50401 c.urlParams_.Set("prettyPrint", "false")
50402 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/userRolePermissions")
50403 urls += "?" + c.urlParams_.Encode()
50404 req, err := http.NewRequest("GET", urls, body)
50405 if err != nil {
50406 return nil, err
50407 }
50408 req.Header = reqHeaders
50409 googleapi.Expand(req.URL, map[string]string{
50410 "profileId": strconv.FormatInt(c.profileId, 10),
50411 })
50412 return gensupport.SendRequest(c.ctx_, c.s.client, req)
50413 }
50414
50415
50416
50417
50418
50419
50420
50421
50422 func (c *UserRolePermissionsListCall) Do(opts ...googleapi.CallOption) (*UserRolePermissionsListResponse, error) {
50423 gensupport.SetOptions(c.urlParams_, opts...)
50424 res, err := c.doRequest("json")
50425 if res != nil && res.StatusCode == http.StatusNotModified {
50426 if res.Body != nil {
50427 res.Body.Close()
50428 }
50429 return nil, &googleapi.Error{
50430 Code: res.StatusCode,
50431 Header: res.Header,
50432 }
50433 }
50434 if err != nil {
50435 return nil, err
50436 }
50437 defer googleapi.CloseBody(res)
50438 if err := googleapi.CheckResponse(res); err != nil {
50439 return nil, err
50440 }
50441 ret := &UserRolePermissionsListResponse{
50442 ServerResponse: googleapi.ServerResponse{
50443 Header: res.Header,
50444 HTTPStatusCode: res.StatusCode,
50445 },
50446 }
50447 target := &ret
50448 if err := gensupport.DecodeResponse(target, res); err != nil {
50449 return nil, err
50450 }
50451 return ret, nil
50452
50453
50454
50455
50456
50457
50458
50459
50460
50461
50462
50463
50464
50465
50466
50467
50468
50469
50470
50471
50472
50473
50474
50475
50476
50477
50478
50479
50480
50481
50482
50483
50484 }
50485
50486
50487
50488 type UserRolesDeleteCall struct {
50489 s *Service
50490 profileId int64
50491 id int64
50492 urlParams_ gensupport.URLParams
50493 ctx_ context.Context
50494 header_ http.Header
50495 }
50496
50497
50498 func (r *UserRolesService) Delete(profileId int64, id int64) *UserRolesDeleteCall {
50499 c := &UserRolesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
50500 c.profileId = profileId
50501 c.id = id
50502 return c
50503 }
50504
50505
50506
50507
50508 func (c *UserRolesDeleteCall) Fields(s ...googleapi.Field) *UserRolesDeleteCall {
50509 c.urlParams_.Set("fields", googleapi.CombineFields(s))
50510 return c
50511 }
50512
50513
50514
50515
50516 func (c *UserRolesDeleteCall) Context(ctx context.Context) *UserRolesDeleteCall {
50517 c.ctx_ = ctx
50518 return c
50519 }
50520
50521
50522
50523 func (c *UserRolesDeleteCall) Header() http.Header {
50524 if c.header_ == nil {
50525 c.header_ = make(http.Header)
50526 }
50527 return c.header_
50528 }
50529
50530 func (c *UserRolesDeleteCall) doRequest(alt string) (*http.Response, error) {
50531 reqHeaders := make(http.Header)
50532 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
50533 for k, v := range c.header_ {
50534 reqHeaders[k] = v
50535 }
50536 reqHeaders.Set("User-Agent", c.s.userAgent())
50537 var body io.Reader = nil
50538 c.urlParams_.Set("alt", alt)
50539 c.urlParams_.Set("prettyPrint", "false")
50540 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/userRoles/{id}")
50541 urls += "?" + c.urlParams_.Encode()
50542 req, err := http.NewRequest("DELETE", urls, body)
50543 if err != nil {
50544 return nil, err
50545 }
50546 req.Header = reqHeaders
50547 googleapi.Expand(req.URL, map[string]string{
50548 "profileId": strconv.FormatInt(c.profileId, 10),
50549 "id": strconv.FormatInt(c.id, 10),
50550 })
50551 return gensupport.SendRequest(c.ctx_, c.s.client, req)
50552 }
50553
50554
50555 func (c *UserRolesDeleteCall) Do(opts ...googleapi.CallOption) error {
50556 gensupport.SetOptions(c.urlParams_, opts...)
50557 res, err := c.doRequest("json")
50558 if err != nil {
50559 return err
50560 }
50561 defer googleapi.CloseBody(res)
50562 if err := googleapi.CheckResponse(res); err != nil {
50563 return err
50564 }
50565 return nil
50566
50567
50568
50569
50570
50571
50572
50573
50574
50575
50576
50577
50578
50579
50580
50581
50582
50583
50584
50585
50586
50587
50588
50589
50590
50591
50592
50593
50594
50595
50596 }
50597
50598
50599
50600 type UserRolesGetCall struct {
50601 s *Service
50602 profileId int64
50603 id int64
50604 urlParams_ gensupport.URLParams
50605 ifNoneMatch_ string
50606 ctx_ context.Context
50607 header_ http.Header
50608 }
50609
50610
50611 func (r *UserRolesService) Get(profileId int64, id int64) *UserRolesGetCall {
50612 c := &UserRolesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
50613 c.profileId = profileId
50614 c.id = id
50615 return c
50616 }
50617
50618
50619
50620
50621 func (c *UserRolesGetCall) Fields(s ...googleapi.Field) *UserRolesGetCall {
50622 c.urlParams_.Set("fields", googleapi.CombineFields(s))
50623 return c
50624 }
50625
50626
50627
50628
50629
50630
50631 func (c *UserRolesGetCall) IfNoneMatch(entityTag string) *UserRolesGetCall {
50632 c.ifNoneMatch_ = entityTag
50633 return c
50634 }
50635
50636
50637
50638
50639 func (c *UserRolesGetCall) Context(ctx context.Context) *UserRolesGetCall {
50640 c.ctx_ = ctx
50641 return c
50642 }
50643
50644
50645
50646 func (c *UserRolesGetCall) Header() http.Header {
50647 if c.header_ == nil {
50648 c.header_ = make(http.Header)
50649 }
50650 return c.header_
50651 }
50652
50653 func (c *UserRolesGetCall) doRequest(alt string) (*http.Response, error) {
50654 reqHeaders := make(http.Header)
50655 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
50656 for k, v := range c.header_ {
50657 reqHeaders[k] = v
50658 }
50659 reqHeaders.Set("User-Agent", c.s.userAgent())
50660 if c.ifNoneMatch_ != "" {
50661 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
50662 }
50663 var body io.Reader = nil
50664 c.urlParams_.Set("alt", alt)
50665 c.urlParams_.Set("prettyPrint", "false")
50666 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/userRoles/{id}")
50667 urls += "?" + c.urlParams_.Encode()
50668 req, err := http.NewRequest("GET", urls, body)
50669 if err != nil {
50670 return nil, err
50671 }
50672 req.Header = reqHeaders
50673 googleapi.Expand(req.URL, map[string]string{
50674 "profileId": strconv.FormatInt(c.profileId, 10),
50675 "id": strconv.FormatInt(c.id, 10),
50676 })
50677 return gensupport.SendRequest(c.ctx_, c.s.client, req)
50678 }
50679
50680
50681
50682
50683
50684
50685
50686
50687 func (c *UserRolesGetCall) Do(opts ...googleapi.CallOption) (*UserRole, error) {
50688 gensupport.SetOptions(c.urlParams_, opts...)
50689 res, err := c.doRequest("json")
50690 if res != nil && res.StatusCode == http.StatusNotModified {
50691 if res.Body != nil {
50692 res.Body.Close()
50693 }
50694 return nil, &googleapi.Error{
50695 Code: res.StatusCode,
50696 Header: res.Header,
50697 }
50698 }
50699 if err != nil {
50700 return nil, err
50701 }
50702 defer googleapi.CloseBody(res)
50703 if err := googleapi.CheckResponse(res); err != nil {
50704 return nil, err
50705 }
50706 ret := &UserRole{
50707 ServerResponse: googleapi.ServerResponse{
50708 Header: res.Header,
50709 HTTPStatusCode: res.StatusCode,
50710 },
50711 }
50712 target := &ret
50713 if err := gensupport.DecodeResponse(target, res); err != nil {
50714 return nil, err
50715 }
50716 return ret, nil
50717
50718
50719
50720
50721
50722
50723
50724
50725
50726
50727
50728
50729
50730
50731
50732
50733
50734
50735
50736
50737
50738
50739
50740
50741
50742
50743
50744
50745
50746
50747
50748
50749
50750 }
50751
50752
50753
50754 type UserRolesInsertCall struct {
50755 s *Service
50756 profileId int64
50757 userrole *UserRole
50758 urlParams_ gensupport.URLParams
50759 ctx_ context.Context
50760 header_ http.Header
50761 }
50762
50763
50764 func (r *UserRolesService) Insert(profileId int64, userrole *UserRole) *UserRolesInsertCall {
50765 c := &UserRolesInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
50766 c.profileId = profileId
50767 c.userrole = userrole
50768 return c
50769 }
50770
50771
50772
50773
50774 func (c *UserRolesInsertCall) Fields(s ...googleapi.Field) *UserRolesInsertCall {
50775 c.urlParams_.Set("fields", googleapi.CombineFields(s))
50776 return c
50777 }
50778
50779
50780
50781
50782 func (c *UserRolesInsertCall) Context(ctx context.Context) *UserRolesInsertCall {
50783 c.ctx_ = ctx
50784 return c
50785 }
50786
50787
50788
50789 func (c *UserRolesInsertCall) Header() http.Header {
50790 if c.header_ == nil {
50791 c.header_ = make(http.Header)
50792 }
50793 return c.header_
50794 }
50795
50796 func (c *UserRolesInsertCall) doRequest(alt string) (*http.Response, error) {
50797 reqHeaders := make(http.Header)
50798 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
50799 for k, v := range c.header_ {
50800 reqHeaders[k] = v
50801 }
50802 reqHeaders.Set("User-Agent", c.s.userAgent())
50803 var body io.Reader = nil
50804 body, err := googleapi.WithoutDataWrapper.JSONReader(c.userrole)
50805 if err != nil {
50806 return nil, err
50807 }
50808 reqHeaders.Set("Content-Type", "application/json")
50809 c.urlParams_.Set("alt", alt)
50810 c.urlParams_.Set("prettyPrint", "false")
50811 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/userRoles")
50812 urls += "?" + c.urlParams_.Encode()
50813 req, err := http.NewRequest("POST", urls, body)
50814 if err != nil {
50815 return nil, err
50816 }
50817 req.Header = reqHeaders
50818 googleapi.Expand(req.URL, map[string]string{
50819 "profileId": strconv.FormatInt(c.profileId, 10),
50820 })
50821 return gensupport.SendRequest(c.ctx_, c.s.client, req)
50822 }
50823
50824
50825
50826
50827
50828
50829
50830
50831 func (c *UserRolesInsertCall) Do(opts ...googleapi.CallOption) (*UserRole, error) {
50832 gensupport.SetOptions(c.urlParams_, opts...)
50833 res, err := c.doRequest("json")
50834 if res != nil && res.StatusCode == http.StatusNotModified {
50835 if res.Body != nil {
50836 res.Body.Close()
50837 }
50838 return nil, &googleapi.Error{
50839 Code: res.StatusCode,
50840 Header: res.Header,
50841 }
50842 }
50843 if err != nil {
50844 return nil, err
50845 }
50846 defer googleapi.CloseBody(res)
50847 if err := googleapi.CheckResponse(res); err != nil {
50848 return nil, err
50849 }
50850 ret := &UserRole{
50851 ServerResponse: googleapi.ServerResponse{
50852 Header: res.Header,
50853 HTTPStatusCode: res.StatusCode,
50854 },
50855 }
50856 target := &ret
50857 if err := gensupport.DecodeResponse(target, res); err != nil {
50858 return nil, err
50859 }
50860 return ret, nil
50861
50862
50863
50864
50865
50866
50867
50868
50869
50870
50871
50872
50873
50874
50875
50876
50877
50878
50879
50880
50881
50882
50883
50884
50885
50886
50887
50888
50889 }
50890
50891
50892
50893 type UserRolesListCall struct {
50894 s *Service
50895 profileId int64
50896 urlParams_ gensupport.URLParams
50897 ifNoneMatch_ string
50898 ctx_ context.Context
50899 header_ http.Header
50900 }
50901
50902
50903
50904 func (r *UserRolesService) List(profileId int64) *UserRolesListCall {
50905 c := &UserRolesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
50906 c.profileId = profileId
50907 return c
50908 }
50909
50910
50911
50912
50913 func (c *UserRolesListCall) AccountUserRoleOnly(accountUserRoleOnly bool) *UserRolesListCall {
50914 c.urlParams_.Set("accountUserRoleOnly", fmt.Sprint(accountUserRoleOnly))
50915 return c
50916 }
50917
50918
50919
50920 func (c *UserRolesListCall) Ids(ids ...int64) *UserRolesListCall {
50921 var ids_ []string
50922 for _, v := range ids {
50923 ids_ = append(ids_, fmt.Sprint(v))
50924 }
50925 c.urlParams_.SetMulti("ids", ids_)
50926 return c
50927 }
50928
50929
50930
50931 func (c *UserRolesListCall) MaxResults(maxResults int64) *UserRolesListCall {
50932 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
50933 return c
50934 }
50935
50936
50937
50938 func (c *UserRolesListCall) PageToken(pageToken string) *UserRolesListCall {
50939 c.urlParams_.Set("pageToken", pageToken)
50940 return c
50941 }
50942
50943
50944
50945
50946
50947
50948
50949
50950
50951 func (c *UserRolesListCall) SearchString(searchString string) *UserRolesListCall {
50952 c.urlParams_.Set("searchString", searchString)
50953 return c
50954 }
50955
50956
50957
50958
50959
50960
50961
50962
50963 func (c *UserRolesListCall) SortField(sortField string) *UserRolesListCall {
50964 c.urlParams_.Set("sortField", sortField)
50965 return c
50966 }
50967
50968
50969
50970
50971
50972
50973
50974
50975 func (c *UserRolesListCall) SortOrder(sortOrder string) *UserRolesListCall {
50976 c.urlParams_.Set("sortOrder", sortOrder)
50977 return c
50978 }
50979
50980
50981
50982 func (c *UserRolesListCall) SubaccountId(subaccountId int64) *UserRolesListCall {
50983 c.urlParams_.Set("subaccountId", fmt.Sprint(subaccountId))
50984 return c
50985 }
50986
50987
50988
50989
50990 func (c *UserRolesListCall) Fields(s ...googleapi.Field) *UserRolesListCall {
50991 c.urlParams_.Set("fields", googleapi.CombineFields(s))
50992 return c
50993 }
50994
50995
50996
50997
50998
50999
51000 func (c *UserRolesListCall) IfNoneMatch(entityTag string) *UserRolesListCall {
51001 c.ifNoneMatch_ = entityTag
51002 return c
51003 }
51004
51005
51006
51007
51008 func (c *UserRolesListCall) Context(ctx context.Context) *UserRolesListCall {
51009 c.ctx_ = ctx
51010 return c
51011 }
51012
51013
51014
51015 func (c *UserRolesListCall) Header() http.Header {
51016 if c.header_ == nil {
51017 c.header_ = make(http.Header)
51018 }
51019 return c.header_
51020 }
51021
51022 func (c *UserRolesListCall) doRequest(alt string) (*http.Response, error) {
51023 reqHeaders := make(http.Header)
51024 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
51025 for k, v := range c.header_ {
51026 reqHeaders[k] = v
51027 }
51028 reqHeaders.Set("User-Agent", c.s.userAgent())
51029 if c.ifNoneMatch_ != "" {
51030 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
51031 }
51032 var body io.Reader = nil
51033 c.urlParams_.Set("alt", alt)
51034 c.urlParams_.Set("prettyPrint", "false")
51035 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/userRoles")
51036 urls += "?" + c.urlParams_.Encode()
51037 req, err := http.NewRequest("GET", urls, body)
51038 if err != nil {
51039 return nil, err
51040 }
51041 req.Header = reqHeaders
51042 googleapi.Expand(req.URL, map[string]string{
51043 "profileId": strconv.FormatInt(c.profileId, 10),
51044 })
51045 return gensupport.SendRequest(c.ctx_, c.s.client, req)
51046 }
51047
51048
51049
51050
51051
51052
51053
51054
51055 func (c *UserRolesListCall) Do(opts ...googleapi.CallOption) (*UserRolesListResponse, error) {
51056 gensupport.SetOptions(c.urlParams_, opts...)
51057 res, err := c.doRequest("json")
51058 if res != nil && res.StatusCode == http.StatusNotModified {
51059 if res.Body != nil {
51060 res.Body.Close()
51061 }
51062 return nil, &googleapi.Error{
51063 Code: res.StatusCode,
51064 Header: res.Header,
51065 }
51066 }
51067 if err != nil {
51068 return nil, err
51069 }
51070 defer googleapi.CloseBody(res)
51071 if err := googleapi.CheckResponse(res); err != nil {
51072 return nil, err
51073 }
51074 ret := &UserRolesListResponse{
51075 ServerResponse: googleapi.ServerResponse{
51076 Header: res.Header,
51077 HTTPStatusCode: res.StatusCode,
51078 },
51079 }
51080 target := &ret
51081 if err := gensupport.DecodeResponse(target, res); err != nil {
51082 return nil, err
51083 }
51084 return ret, nil
51085
51086
51087
51088
51089
51090
51091
51092
51093
51094
51095
51096
51097
51098
51099
51100
51101
51102
51103
51104
51105
51106
51107
51108
51109
51110
51111
51112
51113
51114
51115
51116
51117
51118
51119
51120
51121
51122
51123
51124
51125
51126
51127
51128
51129
51130
51131
51132
51133
51134
51135
51136
51137
51138
51139
51140
51141
51142
51143
51144
51145
51146
51147
51148
51149
51150
51151
51152
51153
51154
51155
51156
51157
51158
51159
51160
51161
51162
51163
51164
51165
51166
51167
51168
51169
51170
51171
51172
51173
51174
51175 }
51176
51177
51178
51179
51180 func (c *UserRolesListCall) Pages(ctx context.Context, f func(*UserRolesListResponse) error) error {
51181 c.ctx_ = ctx
51182 defer c.PageToken(c.urlParams_.Get("pageToken"))
51183 for {
51184 x, err := c.Do()
51185 if err != nil {
51186 return err
51187 }
51188 if err := f(x); err != nil {
51189 return err
51190 }
51191 if x.NextPageToken == "" {
51192 return nil
51193 }
51194 c.PageToken(x.NextPageToken)
51195 }
51196 }
51197
51198
51199
51200 type UserRolesPatchCall struct {
51201 s *Service
51202 profileId int64
51203 userrole *UserRole
51204 urlParams_ gensupport.URLParams
51205 ctx_ context.Context
51206 header_ http.Header
51207 }
51208
51209
51210
51211 func (r *UserRolesService) Patch(profileId int64, id int64, userrole *UserRole) *UserRolesPatchCall {
51212 c := &UserRolesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
51213 c.profileId = profileId
51214 c.urlParams_.Set("id", fmt.Sprint(id))
51215 c.userrole = userrole
51216 return c
51217 }
51218
51219
51220
51221
51222 func (c *UserRolesPatchCall) Fields(s ...googleapi.Field) *UserRolesPatchCall {
51223 c.urlParams_.Set("fields", googleapi.CombineFields(s))
51224 return c
51225 }
51226
51227
51228
51229
51230 func (c *UserRolesPatchCall) Context(ctx context.Context) *UserRolesPatchCall {
51231 c.ctx_ = ctx
51232 return c
51233 }
51234
51235
51236
51237 func (c *UserRolesPatchCall) Header() http.Header {
51238 if c.header_ == nil {
51239 c.header_ = make(http.Header)
51240 }
51241 return c.header_
51242 }
51243
51244 func (c *UserRolesPatchCall) doRequest(alt string) (*http.Response, error) {
51245 reqHeaders := make(http.Header)
51246 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
51247 for k, v := range c.header_ {
51248 reqHeaders[k] = v
51249 }
51250 reqHeaders.Set("User-Agent", c.s.userAgent())
51251 var body io.Reader = nil
51252 body, err := googleapi.WithoutDataWrapper.JSONReader(c.userrole)
51253 if err != nil {
51254 return nil, err
51255 }
51256 reqHeaders.Set("Content-Type", "application/json")
51257 c.urlParams_.Set("alt", alt)
51258 c.urlParams_.Set("prettyPrint", "false")
51259 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/userRoles")
51260 urls += "?" + c.urlParams_.Encode()
51261 req, err := http.NewRequest("PATCH", urls, body)
51262 if err != nil {
51263 return nil, err
51264 }
51265 req.Header = reqHeaders
51266 googleapi.Expand(req.URL, map[string]string{
51267 "profileId": strconv.FormatInt(c.profileId, 10),
51268 })
51269 return gensupport.SendRequest(c.ctx_, c.s.client, req)
51270 }
51271
51272
51273
51274
51275
51276
51277
51278
51279 func (c *UserRolesPatchCall) Do(opts ...googleapi.CallOption) (*UserRole, error) {
51280 gensupport.SetOptions(c.urlParams_, opts...)
51281 res, err := c.doRequest("json")
51282 if res != nil && res.StatusCode == http.StatusNotModified {
51283 if res.Body != nil {
51284 res.Body.Close()
51285 }
51286 return nil, &googleapi.Error{
51287 Code: res.StatusCode,
51288 Header: res.Header,
51289 }
51290 }
51291 if err != nil {
51292 return nil, err
51293 }
51294 defer googleapi.CloseBody(res)
51295 if err := googleapi.CheckResponse(res); err != nil {
51296 return nil, err
51297 }
51298 ret := &UserRole{
51299 ServerResponse: googleapi.ServerResponse{
51300 Header: res.Header,
51301 HTTPStatusCode: res.StatusCode,
51302 },
51303 }
51304 target := &ret
51305 if err := gensupport.DecodeResponse(target, res); err != nil {
51306 return nil, err
51307 }
51308 return ret, nil
51309
51310
51311
51312
51313
51314
51315
51316
51317
51318
51319
51320
51321
51322
51323
51324
51325
51326
51327
51328
51329
51330
51331
51332
51333
51334
51335
51336
51337
51338
51339
51340
51341
51342
51343
51344
51345 }
51346
51347
51348
51349 type UserRolesUpdateCall struct {
51350 s *Service
51351 profileId int64
51352 userrole *UserRole
51353 urlParams_ gensupport.URLParams
51354 ctx_ context.Context
51355 header_ http.Header
51356 }
51357
51358
51359 func (r *UserRolesService) Update(profileId int64, userrole *UserRole) *UserRolesUpdateCall {
51360 c := &UserRolesUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
51361 c.profileId = profileId
51362 c.userrole = userrole
51363 return c
51364 }
51365
51366
51367
51368
51369 func (c *UserRolesUpdateCall) Fields(s ...googleapi.Field) *UserRolesUpdateCall {
51370 c.urlParams_.Set("fields", googleapi.CombineFields(s))
51371 return c
51372 }
51373
51374
51375
51376
51377 func (c *UserRolesUpdateCall) Context(ctx context.Context) *UserRolesUpdateCall {
51378 c.ctx_ = ctx
51379 return c
51380 }
51381
51382
51383
51384 func (c *UserRolesUpdateCall) Header() http.Header {
51385 if c.header_ == nil {
51386 c.header_ = make(http.Header)
51387 }
51388 return c.header_
51389 }
51390
51391 func (c *UserRolesUpdateCall) doRequest(alt string) (*http.Response, error) {
51392 reqHeaders := make(http.Header)
51393 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
51394 for k, v := range c.header_ {
51395 reqHeaders[k] = v
51396 }
51397 reqHeaders.Set("User-Agent", c.s.userAgent())
51398 var body io.Reader = nil
51399 body, err := googleapi.WithoutDataWrapper.JSONReader(c.userrole)
51400 if err != nil {
51401 return nil, err
51402 }
51403 reqHeaders.Set("Content-Type", "application/json")
51404 c.urlParams_.Set("alt", alt)
51405 c.urlParams_.Set("prettyPrint", "false")
51406 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/userRoles")
51407 urls += "?" + c.urlParams_.Encode()
51408 req, err := http.NewRequest("PUT", urls, body)
51409 if err != nil {
51410 return nil, err
51411 }
51412 req.Header = reqHeaders
51413 googleapi.Expand(req.URL, map[string]string{
51414 "profileId": strconv.FormatInt(c.profileId, 10),
51415 })
51416 return gensupport.SendRequest(c.ctx_, c.s.client, req)
51417 }
51418
51419
51420
51421
51422
51423
51424
51425
51426 func (c *UserRolesUpdateCall) Do(opts ...googleapi.CallOption) (*UserRole, error) {
51427 gensupport.SetOptions(c.urlParams_, opts...)
51428 res, err := c.doRequest("json")
51429 if res != nil && res.StatusCode == http.StatusNotModified {
51430 if res.Body != nil {
51431 res.Body.Close()
51432 }
51433 return nil, &googleapi.Error{
51434 Code: res.StatusCode,
51435 Header: res.Header,
51436 }
51437 }
51438 if err != nil {
51439 return nil, err
51440 }
51441 defer googleapi.CloseBody(res)
51442 if err := googleapi.CheckResponse(res); err != nil {
51443 return nil, err
51444 }
51445 ret := &UserRole{
51446 ServerResponse: googleapi.ServerResponse{
51447 Header: res.Header,
51448 HTTPStatusCode: res.StatusCode,
51449 },
51450 }
51451 target := &ret
51452 if err := gensupport.DecodeResponse(target, res); err != nil {
51453 return nil, err
51454 }
51455 return ret, nil
51456
51457
51458
51459
51460
51461
51462
51463
51464
51465
51466
51467
51468
51469
51470
51471
51472
51473
51474
51475
51476
51477
51478
51479
51480
51481
51482
51483
51484 }
51485
51486
51487
51488 type VideoFormatsGetCall struct {
51489 s *Service
51490 profileId int64
51491 id int64
51492 urlParams_ gensupport.URLParams
51493 ifNoneMatch_ string
51494 ctx_ context.Context
51495 header_ http.Header
51496 }
51497
51498
51499 func (r *VideoFormatsService) Get(profileId int64, id int64) *VideoFormatsGetCall {
51500 c := &VideoFormatsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
51501 c.profileId = profileId
51502 c.id = id
51503 return c
51504 }
51505
51506
51507
51508
51509 func (c *VideoFormatsGetCall) Fields(s ...googleapi.Field) *VideoFormatsGetCall {
51510 c.urlParams_.Set("fields", googleapi.CombineFields(s))
51511 return c
51512 }
51513
51514
51515
51516
51517
51518
51519 func (c *VideoFormatsGetCall) IfNoneMatch(entityTag string) *VideoFormatsGetCall {
51520 c.ifNoneMatch_ = entityTag
51521 return c
51522 }
51523
51524
51525
51526
51527 func (c *VideoFormatsGetCall) Context(ctx context.Context) *VideoFormatsGetCall {
51528 c.ctx_ = ctx
51529 return c
51530 }
51531
51532
51533
51534 func (c *VideoFormatsGetCall) Header() http.Header {
51535 if c.header_ == nil {
51536 c.header_ = make(http.Header)
51537 }
51538 return c.header_
51539 }
51540
51541 func (c *VideoFormatsGetCall) doRequest(alt string) (*http.Response, error) {
51542 reqHeaders := make(http.Header)
51543 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
51544 for k, v := range c.header_ {
51545 reqHeaders[k] = v
51546 }
51547 reqHeaders.Set("User-Agent", c.s.userAgent())
51548 if c.ifNoneMatch_ != "" {
51549 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
51550 }
51551 var body io.Reader = nil
51552 c.urlParams_.Set("alt", alt)
51553 c.urlParams_.Set("prettyPrint", "false")
51554 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/videoFormats/{id}")
51555 urls += "?" + c.urlParams_.Encode()
51556 req, err := http.NewRequest("GET", urls, body)
51557 if err != nil {
51558 return nil, err
51559 }
51560 req.Header = reqHeaders
51561 googleapi.Expand(req.URL, map[string]string{
51562 "profileId": strconv.FormatInt(c.profileId, 10),
51563 "id": strconv.FormatInt(c.id, 10),
51564 })
51565 return gensupport.SendRequest(c.ctx_, c.s.client, req)
51566 }
51567
51568
51569
51570
51571
51572
51573
51574
51575 func (c *VideoFormatsGetCall) Do(opts ...googleapi.CallOption) (*VideoFormat, error) {
51576 gensupport.SetOptions(c.urlParams_, opts...)
51577 res, err := c.doRequest("json")
51578 if res != nil && res.StatusCode == http.StatusNotModified {
51579 if res.Body != nil {
51580 res.Body.Close()
51581 }
51582 return nil, &googleapi.Error{
51583 Code: res.StatusCode,
51584 Header: res.Header,
51585 }
51586 }
51587 if err != nil {
51588 return nil, err
51589 }
51590 defer googleapi.CloseBody(res)
51591 if err := googleapi.CheckResponse(res); err != nil {
51592 return nil, err
51593 }
51594 ret := &VideoFormat{
51595 ServerResponse: googleapi.ServerResponse{
51596 Header: res.Header,
51597 HTTPStatusCode: res.StatusCode,
51598 },
51599 }
51600 target := &ret
51601 if err := gensupport.DecodeResponse(target, res); err != nil {
51602 return nil, err
51603 }
51604 return ret, nil
51605
51606
51607
51608
51609
51610
51611
51612
51613
51614
51615
51616
51617
51618
51619
51620
51621
51622
51623
51624
51625
51626
51627
51628
51629
51630
51631
51632
51633
51634
51635
51636
51637
51638 }
51639
51640
51641
51642 type VideoFormatsListCall struct {
51643 s *Service
51644 profileId int64
51645 urlParams_ gensupport.URLParams
51646 ifNoneMatch_ string
51647 ctx_ context.Context
51648 header_ http.Header
51649 }
51650
51651
51652 func (r *VideoFormatsService) List(profileId int64) *VideoFormatsListCall {
51653 c := &VideoFormatsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
51654 c.profileId = profileId
51655 return c
51656 }
51657
51658
51659
51660
51661 func (c *VideoFormatsListCall) Fields(s ...googleapi.Field) *VideoFormatsListCall {
51662 c.urlParams_.Set("fields", googleapi.CombineFields(s))
51663 return c
51664 }
51665
51666
51667
51668
51669
51670
51671 func (c *VideoFormatsListCall) IfNoneMatch(entityTag string) *VideoFormatsListCall {
51672 c.ifNoneMatch_ = entityTag
51673 return c
51674 }
51675
51676
51677
51678
51679 func (c *VideoFormatsListCall) Context(ctx context.Context) *VideoFormatsListCall {
51680 c.ctx_ = ctx
51681 return c
51682 }
51683
51684
51685
51686 func (c *VideoFormatsListCall) Header() http.Header {
51687 if c.header_ == nil {
51688 c.header_ = make(http.Header)
51689 }
51690 return c.header_
51691 }
51692
51693 func (c *VideoFormatsListCall) doRequest(alt string) (*http.Response, error) {
51694 reqHeaders := make(http.Header)
51695 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
51696 for k, v := range c.header_ {
51697 reqHeaders[k] = v
51698 }
51699 reqHeaders.Set("User-Agent", c.s.userAgent())
51700 if c.ifNoneMatch_ != "" {
51701 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
51702 }
51703 var body io.Reader = nil
51704 c.urlParams_.Set("alt", alt)
51705 c.urlParams_.Set("prettyPrint", "false")
51706 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/videoFormats")
51707 urls += "?" + c.urlParams_.Encode()
51708 req, err := http.NewRequest("GET", urls, body)
51709 if err != nil {
51710 return nil, err
51711 }
51712 req.Header = reqHeaders
51713 googleapi.Expand(req.URL, map[string]string{
51714 "profileId": strconv.FormatInt(c.profileId, 10),
51715 })
51716 return gensupport.SendRequest(c.ctx_, c.s.client, req)
51717 }
51718
51719
51720
51721
51722
51723
51724
51725
51726 func (c *VideoFormatsListCall) Do(opts ...googleapi.CallOption) (*VideoFormatsListResponse, error) {
51727 gensupport.SetOptions(c.urlParams_, opts...)
51728 res, err := c.doRequest("json")
51729 if res != nil && res.StatusCode == http.StatusNotModified {
51730 if res.Body != nil {
51731 res.Body.Close()
51732 }
51733 return nil, &googleapi.Error{
51734 Code: res.StatusCode,
51735 Header: res.Header,
51736 }
51737 }
51738 if err != nil {
51739 return nil, err
51740 }
51741 defer googleapi.CloseBody(res)
51742 if err := googleapi.CheckResponse(res); err != nil {
51743 return nil, err
51744 }
51745 ret := &VideoFormatsListResponse{
51746 ServerResponse: googleapi.ServerResponse{
51747 Header: res.Header,
51748 HTTPStatusCode: res.StatusCode,
51749 },
51750 }
51751 target := &ret
51752 if err := gensupport.DecodeResponse(target, res); err != nil {
51753 return nil, err
51754 }
51755 return ret, nil
51756
51757
51758
51759
51760
51761
51762
51763
51764
51765
51766
51767
51768
51769
51770
51771
51772
51773
51774
51775
51776
51777
51778
51779
51780
51781 }
51782
View as plain text