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.0"
77 const apiName = "dfareporting"
78 const apiVersion = "v3.0"
79 const basePath = "https://www.googleapis.com/dfareporting/v3.0/"
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.MobileCarriers = NewMobileCarriersService(s)
163 s.OperatingSystemVersions = NewOperatingSystemVersionsService(s)
164 s.OperatingSystems = NewOperatingSystemsService(s)
165 s.OrderDocuments = NewOrderDocumentsService(s)
166 s.Orders = NewOrdersService(s)
167 s.PlacementGroups = NewPlacementGroupsService(s)
168 s.PlacementStrategies = NewPlacementStrategiesService(s)
169 s.Placements = NewPlacementsService(s)
170 s.PlatformTypes = NewPlatformTypesService(s)
171 s.PostalCodes = NewPostalCodesService(s)
172 s.Projects = NewProjectsService(s)
173 s.Regions = NewRegionsService(s)
174 s.RemarketingListShares = NewRemarketingListSharesService(s)
175 s.RemarketingLists = NewRemarketingListsService(s)
176 s.Reports = NewReportsService(s)
177 s.Sites = NewSitesService(s)
178 s.Sizes = NewSizesService(s)
179 s.Subaccounts = NewSubaccountsService(s)
180 s.TargetableRemarketingLists = NewTargetableRemarketingListsService(s)
181 s.TargetingTemplates = NewTargetingTemplatesService(s)
182 s.UserProfiles = NewUserProfilesService(s)
183 s.UserRolePermissionGroups = NewUserRolePermissionGroupsService(s)
184 s.UserRolePermissions = NewUserRolePermissionsService(s)
185 s.UserRoles = NewUserRolesService(s)
186 s.VideoFormats = NewVideoFormatsService(s)
187 return s, nil
188 }
189
190 type Service struct {
191 client *http.Client
192 BasePath string
193 UserAgent string
194
195 AccountActiveAdSummaries *AccountActiveAdSummariesService
196
197 AccountPermissionGroups *AccountPermissionGroupsService
198
199 AccountPermissions *AccountPermissionsService
200
201 AccountUserProfiles *AccountUserProfilesService
202
203 Accounts *AccountsService
204
205 Ads *AdsService
206
207 AdvertiserGroups *AdvertiserGroupsService
208
209 AdvertiserLandingPages *AdvertiserLandingPagesService
210
211 Advertisers *AdvertisersService
212
213 Browsers *BrowsersService
214
215 CampaignCreativeAssociations *CampaignCreativeAssociationsService
216
217 Campaigns *CampaignsService
218
219 ChangeLogs *ChangeLogsService
220
221 Cities *CitiesService
222
223 ConnectionTypes *ConnectionTypesService
224
225 ContentCategories *ContentCategoriesService
226
227 Conversions *ConversionsService
228
229 Countries *CountriesService
230
231 CreativeAssets *CreativeAssetsService
232
233 CreativeFieldValues *CreativeFieldValuesService
234
235 CreativeFields *CreativeFieldsService
236
237 CreativeGroups *CreativeGroupsService
238
239 Creatives *CreativesService
240
241 DimensionValues *DimensionValuesService
242
243 DirectorySiteContacts *DirectorySiteContactsService
244
245 DirectorySites *DirectorySitesService
246
247 DynamicTargetingKeys *DynamicTargetingKeysService
248
249 EventTags *EventTagsService
250
251 Files *FilesService
252
253 FloodlightActivities *FloodlightActivitiesService
254
255 FloodlightActivityGroups *FloodlightActivityGroupsService
256
257 FloodlightConfigurations *FloodlightConfigurationsService
258
259 InventoryItems *InventoryItemsService
260
261 Languages *LanguagesService
262
263 Metros *MetrosService
264
265 MobileCarriers *MobileCarriersService
266
267 OperatingSystemVersions *OperatingSystemVersionsService
268
269 OperatingSystems *OperatingSystemsService
270
271 OrderDocuments *OrderDocumentsService
272
273 Orders *OrdersService
274
275 PlacementGroups *PlacementGroupsService
276
277 PlacementStrategies *PlacementStrategiesService
278
279 Placements *PlacementsService
280
281 PlatformTypes *PlatformTypesService
282
283 PostalCodes *PostalCodesService
284
285 Projects *ProjectsService
286
287 Regions *RegionsService
288
289 RemarketingListShares *RemarketingListSharesService
290
291 RemarketingLists *RemarketingListsService
292
293 Reports *ReportsService
294
295 Sites *SitesService
296
297 Sizes *SizesService
298
299 Subaccounts *SubaccountsService
300
301 TargetableRemarketingLists *TargetableRemarketingListsService
302
303 TargetingTemplates *TargetingTemplatesService
304
305 UserProfiles *UserProfilesService
306
307 UserRolePermissionGroups *UserRolePermissionGroupsService
308
309 UserRolePermissions *UserRolePermissionsService
310
311 UserRoles *UserRolesService
312
313 VideoFormats *VideoFormatsService
314 }
315
316 func (s *Service) userAgent() string {
317 if s.UserAgent == "" {
318 return googleapi.UserAgent
319 }
320 return googleapi.UserAgent + " " + s.UserAgent
321 }
322
323 func NewAccountActiveAdSummariesService(s *Service) *AccountActiveAdSummariesService {
324 rs := &AccountActiveAdSummariesService{s: s}
325 return rs
326 }
327
328 type AccountActiveAdSummariesService struct {
329 s *Service
330 }
331
332 func NewAccountPermissionGroupsService(s *Service) *AccountPermissionGroupsService {
333 rs := &AccountPermissionGroupsService{s: s}
334 return rs
335 }
336
337 type AccountPermissionGroupsService struct {
338 s *Service
339 }
340
341 func NewAccountPermissionsService(s *Service) *AccountPermissionsService {
342 rs := &AccountPermissionsService{s: s}
343 return rs
344 }
345
346 type AccountPermissionsService struct {
347 s *Service
348 }
349
350 func NewAccountUserProfilesService(s *Service) *AccountUserProfilesService {
351 rs := &AccountUserProfilesService{s: s}
352 return rs
353 }
354
355 type AccountUserProfilesService struct {
356 s *Service
357 }
358
359 func NewAccountsService(s *Service) *AccountsService {
360 rs := &AccountsService{s: s}
361 return rs
362 }
363
364 type AccountsService struct {
365 s *Service
366 }
367
368 func NewAdsService(s *Service) *AdsService {
369 rs := &AdsService{s: s}
370 return rs
371 }
372
373 type AdsService struct {
374 s *Service
375 }
376
377 func NewAdvertiserGroupsService(s *Service) *AdvertiserGroupsService {
378 rs := &AdvertiserGroupsService{s: s}
379 return rs
380 }
381
382 type AdvertiserGroupsService struct {
383 s *Service
384 }
385
386 func NewAdvertiserLandingPagesService(s *Service) *AdvertiserLandingPagesService {
387 rs := &AdvertiserLandingPagesService{s: s}
388 return rs
389 }
390
391 type AdvertiserLandingPagesService struct {
392 s *Service
393 }
394
395 func NewAdvertisersService(s *Service) *AdvertisersService {
396 rs := &AdvertisersService{s: s}
397 return rs
398 }
399
400 type AdvertisersService struct {
401 s *Service
402 }
403
404 func NewBrowsersService(s *Service) *BrowsersService {
405 rs := &BrowsersService{s: s}
406 return rs
407 }
408
409 type BrowsersService struct {
410 s *Service
411 }
412
413 func NewCampaignCreativeAssociationsService(s *Service) *CampaignCreativeAssociationsService {
414 rs := &CampaignCreativeAssociationsService{s: s}
415 return rs
416 }
417
418 type CampaignCreativeAssociationsService struct {
419 s *Service
420 }
421
422 func NewCampaignsService(s *Service) *CampaignsService {
423 rs := &CampaignsService{s: s}
424 return rs
425 }
426
427 type CampaignsService struct {
428 s *Service
429 }
430
431 func NewChangeLogsService(s *Service) *ChangeLogsService {
432 rs := &ChangeLogsService{s: s}
433 return rs
434 }
435
436 type ChangeLogsService struct {
437 s *Service
438 }
439
440 func NewCitiesService(s *Service) *CitiesService {
441 rs := &CitiesService{s: s}
442 return rs
443 }
444
445 type CitiesService struct {
446 s *Service
447 }
448
449 func NewConnectionTypesService(s *Service) *ConnectionTypesService {
450 rs := &ConnectionTypesService{s: s}
451 return rs
452 }
453
454 type ConnectionTypesService struct {
455 s *Service
456 }
457
458 func NewContentCategoriesService(s *Service) *ContentCategoriesService {
459 rs := &ContentCategoriesService{s: s}
460 return rs
461 }
462
463 type ContentCategoriesService struct {
464 s *Service
465 }
466
467 func NewConversionsService(s *Service) *ConversionsService {
468 rs := &ConversionsService{s: s}
469 return rs
470 }
471
472 type ConversionsService struct {
473 s *Service
474 }
475
476 func NewCountriesService(s *Service) *CountriesService {
477 rs := &CountriesService{s: s}
478 return rs
479 }
480
481 type CountriesService struct {
482 s *Service
483 }
484
485 func NewCreativeAssetsService(s *Service) *CreativeAssetsService {
486 rs := &CreativeAssetsService{s: s}
487 return rs
488 }
489
490 type CreativeAssetsService struct {
491 s *Service
492 }
493
494 func NewCreativeFieldValuesService(s *Service) *CreativeFieldValuesService {
495 rs := &CreativeFieldValuesService{s: s}
496 return rs
497 }
498
499 type CreativeFieldValuesService struct {
500 s *Service
501 }
502
503 func NewCreativeFieldsService(s *Service) *CreativeFieldsService {
504 rs := &CreativeFieldsService{s: s}
505 return rs
506 }
507
508 type CreativeFieldsService struct {
509 s *Service
510 }
511
512 func NewCreativeGroupsService(s *Service) *CreativeGroupsService {
513 rs := &CreativeGroupsService{s: s}
514 return rs
515 }
516
517 type CreativeGroupsService struct {
518 s *Service
519 }
520
521 func NewCreativesService(s *Service) *CreativesService {
522 rs := &CreativesService{s: s}
523 return rs
524 }
525
526 type CreativesService struct {
527 s *Service
528 }
529
530 func NewDimensionValuesService(s *Service) *DimensionValuesService {
531 rs := &DimensionValuesService{s: s}
532 return rs
533 }
534
535 type DimensionValuesService struct {
536 s *Service
537 }
538
539 func NewDirectorySiteContactsService(s *Service) *DirectorySiteContactsService {
540 rs := &DirectorySiteContactsService{s: s}
541 return rs
542 }
543
544 type DirectorySiteContactsService struct {
545 s *Service
546 }
547
548 func NewDirectorySitesService(s *Service) *DirectorySitesService {
549 rs := &DirectorySitesService{s: s}
550 return rs
551 }
552
553 type DirectorySitesService struct {
554 s *Service
555 }
556
557 func NewDynamicTargetingKeysService(s *Service) *DynamicTargetingKeysService {
558 rs := &DynamicTargetingKeysService{s: s}
559 return rs
560 }
561
562 type DynamicTargetingKeysService struct {
563 s *Service
564 }
565
566 func NewEventTagsService(s *Service) *EventTagsService {
567 rs := &EventTagsService{s: s}
568 return rs
569 }
570
571 type EventTagsService struct {
572 s *Service
573 }
574
575 func NewFilesService(s *Service) *FilesService {
576 rs := &FilesService{s: s}
577 return rs
578 }
579
580 type FilesService struct {
581 s *Service
582 }
583
584 func NewFloodlightActivitiesService(s *Service) *FloodlightActivitiesService {
585 rs := &FloodlightActivitiesService{s: s}
586 return rs
587 }
588
589 type FloodlightActivitiesService struct {
590 s *Service
591 }
592
593 func NewFloodlightActivityGroupsService(s *Service) *FloodlightActivityGroupsService {
594 rs := &FloodlightActivityGroupsService{s: s}
595 return rs
596 }
597
598 type FloodlightActivityGroupsService struct {
599 s *Service
600 }
601
602 func NewFloodlightConfigurationsService(s *Service) *FloodlightConfigurationsService {
603 rs := &FloodlightConfigurationsService{s: s}
604 return rs
605 }
606
607 type FloodlightConfigurationsService struct {
608 s *Service
609 }
610
611 func NewInventoryItemsService(s *Service) *InventoryItemsService {
612 rs := &InventoryItemsService{s: s}
613 return rs
614 }
615
616 type InventoryItemsService struct {
617 s *Service
618 }
619
620 func NewLanguagesService(s *Service) *LanguagesService {
621 rs := &LanguagesService{s: s}
622 return rs
623 }
624
625 type LanguagesService struct {
626 s *Service
627 }
628
629 func NewMetrosService(s *Service) *MetrosService {
630 rs := &MetrosService{s: s}
631 return rs
632 }
633
634 type MetrosService struct {
635 s *Service
636 }
637
638 func NewMobileCarriersService(s *Service) *MobileCarriersService {
639 rs := &MobileCarriersService{s: s}
640 return rs
641 }
642
643 type MobileCarriersService struct {
644 s *Service
645 }
646
647 func NewOperatingSystemVersionsService(s *Service) *OperatingSystemVersionsService {
648 rs := &OperatingSystemVersionsService{s: s}
649 return rs
650 }
651
652 type OperatingSystemVersionsService struct {
653 s *Service
654 }
655
656 func NewOperatingSystemsService(s *Service) *OperatingSystemsService {
657 rs := &OperatingSystemsService{s: s}
658 return rs
659 }
660
661 type OperatingSystemsService struct {
662 s *Service
663 }
664
665 func NewOrderDocumentsService(s *Service) *OrderDocumentsService {
666 rs := &OrderDocumentsService{s: s}
667 return rs
668 }
669
670 type OrderDocumentsService struct {
671 s *Service
672 }
673
674 func NewOrdersService(s *Service) *OrdersService {
675 rs := &OrdersService{s: s}
676 return rs
677 }
678
679 type OrdersService struct {
680 s *Service
681 }
682
683 func NewPlacementGroupsService(s *Service) *PlacementGroupsService {
684 rs := &PlacementGroupsService{s: s}
685 return rs
686 }
687
688 type PlacementGroupsService struct {
689 s *Service
690 }
691
692 func NewPlacementStrategiesService(s *Service) *PlacementStrategiesService {
693 rs := &PlacementStrategiesService{s: s}
694 return rs
695 }
696
697 type PlacementStrategiesService struct {
698 s *Service
699 }
700
701 func NewPlacementsService(s *Service) *PlacementsService {
702 rs := &PlacementsService{s: s}
703 return rs
704 }
705
706 type PlacementsService struct {
707 s *Service
708 }
709
710 func NewPlatformTypesService(s *Service) *PlatformTypesService {
711 rs := &PlatformTypesService{s: s}
712 return rs
713 }
714
715 type PlatformTypesService struct {
716 s *Service
717 }
718
719 func NewPostalCodesService(s *Service) *PostalCodesService {
720 rs := &PostalCodesService{s: s}
721 return rs
722 }
723
724 type PostalCodesService struct {
725 s *Service
726 }
727
728 func NewProjectsService(s *Service) *ProjectsService {
729 rs := &ProjectsService{s: s}
730 return rs
731 }
732
733 type ProjectsService struct {
734 s *Service
735 }
736
737 func NewRegionsService(s *Service) *RegionsService {
738 rs := &RegionsService{s: s}
739 return rs
740 }
741
742 type RegionsService struct {
743 s *Service
744 }
745
746 func NewRemarketingListSharesService(s *Service) *RemarketingListSharesService {
747 rs := &RemarketingListSharesService{s: s}
748 return rs
749 }
750
751 type RemarketingListSharesService struct {
752 s *Service
753 }
754
755 func NewRemarketingListsService(s *Service) *RemarketingListsService {
756 rs := &RemarketingListsService{s: s}
757 return rs
758 }
759
760 type RemarketingListsService struct {
761 s *Service
762 }
763
764 func NewReportsService(s *Service) *ReportsService {
765 rs := &ReportsService{s: s}
766 rs.CompatibleFields = NewReportsCompatibleFieldsService(s)
767 rs.Files = NewReportsFilesService(s)
768 return rs
769 }
770
771 type ReportsService struct {
772 s *Service
773
774 CompatibleFields *ReportsCompatibleFieldsService
775
776 Files *ReportsFilesService
777 }
778
779 func NewReportsCompatibleFieldsService(s *Service) *ReportsCompatibleFieldsService {
780 rs := &ReportsCompatibleFieldsService{s: s}
781 return rs
782 }
783
784 type ReportsCompatibleFieldsService struct {
785 s *Service
786 }
787
788 func NewReportsFilesService(s *Service) *ReportsFilesService {
789 rs := &ReportsFilesService{s: s}
790 return rs
791 }
792
793 type ReportsFilesService struct {
794 s *Service
795 }
796
797 func NewSitesService(s *Service) *SitesService {
798 rs := &SitesService{s: s}
799 return rs
800 }
801
802 type SitesService struct {
803 s *Service
804 }
805
806 func NewSizesService(s *Service) *SizesService {
807 rs := &SizesService{s: s}
808 return rs
809 }
810
811 type SizesService struct {
812 s *Service
813 }
814
815 func NewSubaccountsService(s *Service) *SubaccountsService {
816 rs := &SubaccountsService{s: s}
817 return rs
818 }
819
820 type SubaccountsService struct {
821 s *Service
822 }
823
824 func NewTargetableRemarketingListsService(s *Service) *TargetableRemarketingListsService {
825 rs := &TargetableRemarketingListsService{s: s}
826 return rs
827 }
828
829 type TargetableRemarketingListsService struct {
830 s *Service
831 }
832
833 func NewTargetingTemplatesService(s *Service) *TargetingTemplatesService {
834 rs := &TargetingTemplatesService{s: s}
835 return rs
836 }
837
838 type TargetingTemplatesService struct {
839 s *Service
840 }
841
842 func NewUserProfilesService(s *Service) *UserProfilesService {
843 rs := &UserProfilesService{s: s}
844 return rs
845 }
846
847 type UserProfilesService struct {
848 s *Service
849 }
850
851 func NewUserRolePermissionGroupsService(s *Service) *UserRolePermissionGroupsService {
852 rs := &UserRolePermissionGroupsService{s: s}
853 return rs
854 }
855
856 type UserRolePermissionGroupsService struct {
857 s *Service
858 }
859
860 func NewUserRolePermissionsService(s *Service) *UserRolePermissionsService {
861 rs := &UserRolePermissionsService{s: s}
862 return rs
863 }
864
865 type UserRolePermissionsService struct {
866 s *Service
867 }
868
869 func NewUserRolesService(s *Service) *UserRolesService {
870 rs := &UserRolesService{s: s}
871 return rs
872 }
873
874 type UserRolesService struct {
875 s *Service
876 }
877
878 func NewVideoFormatsService(s *Service) *VideoFormatsService {
879 rs := &VideoFormatsService{s: s}
880 return rs
881 }
882
883 type VideoFormatsService struct {
884 s *Service
885 }
886
887
888 type Account struct {
889
890 AccountPermissionIds googleapi.Int64s `json:"accountPermissionIds,omitempty"`
891
892
893
894
895
896
897
898 AccountProfile string `json:"accountProfile,omitempty"`
899
900
901 Active bool `json:"active,omitempty"`
902
903
904
905
906
907
908
909
910
911
912
913
914
915 ActiveAdsLimitTier string `json:"activeAdsLimitTier,omitempty"`
916
917
918
919
920 ActiveViewOptOut bool `json:"activeViewOptOut,omitempty"`
921
922
923
924 AvailablePermissionIds googleapi.Int64s `json:"availablePermissionIds,omitempty"`
925
926
927 CountryId int64 `json:"countryId,omitempty,string"`
928
929
930
931
932
933
934
935
936
937
938
939
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 CurrencyId int64 `json:"currencyId,omitempty,string"`
982
983
984 DefaultCreativeSizeId int64 `json:"defaultCreativeSizeId,omitempty,string"`
985
986
987 Description string `json:"description,omitempty"`
988
989
990 Id int64 `json:"id,omitempty,string"`
991
992
993
994 Kind string `json:"kind,omitempty"`
995
996
997
998
999
1000
1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014 Locale string `json:"locale,omitempty"`
1015
1016
1017
1018 MaximumImageSize int64 `json:"maximumImageSize,omitempty,string"`
1019
1020
1021
1022 Name string `json:"name,omitempty"`
1023
1024
1025
1026 NielsenOcrEnabled bool `json:"nielsenOcrEnabled,omitempty"`
1027
1028
1029 ReportsConfiguration *ReportsConfiguration `json:"reportsConfiguration,omitempty"`
1030
1031
1032
1033 ShareReportsWithTwitter bool `json:"shareReportsWithTwitter,omitempty"`
1034
1035
1036
1037 TeaserSizeLimit int64 `json:"teaserSizeLimit,omitempty,string"`
1038
1039
1040
1041 googleapi.ServerResponse `json:"-"`
1042
1043
1044
1045
1046
1047
1048
1049
1050 ForceSendFields []string `json:"-"`
1051
1052
1053
1054
1055
1056
1057
1058
1059 NullFields []string `json:"-"`
1060 }
1061
1062 func (s *Account) MarshalJSON() ([]byte, error) {
1063 type NoMethod Account
1064 raw := NoMethod(*s)
1065 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1066 }
1067
1068
1069 type AccountActiveAdSummary struct {
1070
1071 AccountId int64 `json:"accountId,omitempty,string"`
1072
1073
1074 ActiveAds int64 `json:"activeAds,omitempty,string"`
1075
1076
1077
1078
1079
1080
1081
1082
1083
1084
1085
1086
1087
1088 ActiveAdsLimitTier string `json:"activeAdsLimitTier,omitempty"`
1089
1090
1091 AvailableAds int64 `json:"availableAds,omitempty,string"`
1092
1093
1094
1095 Kind string `json:"kind,omitempty"`
1096
1097
1098
1099 googleapi.ServerResponse `json:"-"`
1100
1101
1102
1103
1104
1105
1106
1107 ForceSendFields []string `json:"-"`
1108
1109
1110
1111
1112
1113
1114
1115 NullFields []string `json:"-"`
1116 }
1117
1118 func (s *AccountActiveAdSummary) MarshalJSON() ([]byte, error) {
1119 type NoMethod AccountActiveAdSummary
1120 raw := NoMethod(*s)
1121 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1122 }
1123
1124
1125
1126
1127 type AccountPermission struct {
1128
1129
1130
1131
1132
1133
1134
1135
1136
1137
1138 AccountProfiles []string `json:"accountProfiles,omitempty"`
1139
1140
1141 Id int64 `json:"id,omitempty,string"`
1142
1143
1144
1145 Kind string `json:"kind,omitempty"`
1146
1147
1148
1149
1150
1151
1152
1153 Level string `json:"level,omitempty"`
1154
1155
1156 Name string `json:"name,omitempty"`
1157
1158
1159 PermissionGroupId int64 `json:"permissionGroupId,omitempty,string"`
1160
1161
1162
1163 googleapi.ServerResponse `json:"-"`
1164
1165
1166
1167
1168
1169
1170
1171 ForceSendFields []string `json:"-"`
1172
1173
1174
1175
1176
1177
1178
1179
1180 NullFields []string `json:"-"`
1181 }
1182
1183 func (s *AccountPermission) MarshalJSON() ([]byte, error) {
1184 type NoMethod AccountPermission
1185 raw := NoMethod(*s)
1186 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1187 }
1188
1189
1190
1191
1192 type AccountPermissionGroup struct {
1193
1194 Id int64 `json:"id,omitempty,string"`
1195
1196
1197
1198 Kind string `json:"kind,omitempty"`
1199
1200
1201 Name string `json:"name,omitempty"`
1202
1203
1204
1205 googleapi.ServerResponse `json:"-"`
1206
1207
1208
1209
1210
1211
1212
1213 ForceSendFields []string `json:"-"`
1214
1215
1216
1217
1218
1219
1220
1221 NullFields []string `json:"-"`
1222 }
1223
1224 func (s *AccountPermissionGroup) MarshalJSON() ([]byte, error) {
1225 type NoMethod AccountPermissionGroup
1226 raw := NoMethod(*s)
1227 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1228 }
1229
1230
1231
1232 type AccountPermissionGroupsListResponse struct {
1233
1234 AccountPermissionGroups []*AccountPermissionGroup `json:"accountPermissionGroups,omitempty"`
1235
1236
1237
1238 Kind string `json:"kind,omitempty"`
1239
1240
1241
1242 googleapi.ServerResponse `json:"-"`
1243
1244
1245
1246
1247
1248
1249
1250
1251 ForceSendFields []string `json:"-"`
1252
1253
1254
1255
1256
1257
1258
1259
1260 NullFields []string `json:"-"`
1261 }
1262
1263 func (s *AccountPermissionGroupsListResponse) MarshalJSON() ([]byte, error) {
1264 type NoMethod AccountPermissionGroupsListResponse
1265 raw := NoMethod(*s)
1266 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1267 }
1268
1269
1270 type AccountPermissionsListResponse struct {
1271
1272 AccountPermissions []*AccountPermission `json:"accountPermissions,omitempty"`
1273
1274
1275
1276 Kind string `json:"kind,omitempty"`
1277
1278
1279
1280 googleapi.ServerResponse `json:"-"`
1281
1282
1283
1284
1285
1286
1287
1288 ForceSendFields []string `json:"-"`
1289
1290
1291
1292
1293
1294
1295
1296
1297 NullFields []string `json:"-"`
1298 }
1299
1300 func (s *AccountPermissionsListResponse) MarshalJSON() ([]byte, error) {
1301 type NoMethod AccountPermissionsListResponse
1302 raw := NoMethod(*s)
1303 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1304 }
1305
1306
1307
1308
1309
1310 type AccountUserProfile struct {
1311
1312
1313 AccountId int64 `json:"accountId,omitempty,string"`
1314
1315
1316
1317 Active bool `json:"active,omitempty"`
1318
1319
1320
1321 AdvertiserFilter *ObjectFilter `json:"advertiserFilter,omitempty"`
1322
1323
1324
1325 CampaignFilter *ObjectFilter `json:"campaignFilter,omitempty"`
1326
1327
1328 Comments string `json:"comments,omitempty"`
1329
1330
1331
1332
1333 Email string `json:"email,omitempty"`
1334
1335
1336
1337 Id int64 `json:"id,omitempty,string"`
1338
1339
1340
1341 Kind string `json:"kind,omitempty"`
1342
1343
1344
1345
1346
1347
1348
1349
1350
1351
1352
1353
1354
1355
1356
1357
1358
1359
1360
1361
1362 Locale string `json:"locale,omitempty"`
1363
1364
1365
1366
1367 Name string `json:"name,omitempty"`
1368
1369
1370
1371 SiteFilter *ObjectFilter `json:"siteFilter,omitempty"`
1372
1373
1374
1375 SubaccountId int64 `json:"subaccountId,omitempty,string"`
1376
1377
1378
1379
1380
1381
1382
1383
1384 TraffickerType string `json:"traffickerType,omitempty"`
1385
1386
1387
1388
1389
1390
1391
1392
1393
1394 UserAccessType string `json:"userAccessType,omitempty"`
1395
1396
1397
1398 UserRoleFilter *ObjectFilter `json:"userRoleFilter,omitempty"`
1399
1400
1401
1402 UserRoleId int64 `json:"userRoleId,omitempty,string"`
1403
1404
1405
1406 googleapi.ServerResponse `json:"-"`
1407
1408
1409
1410
1411
1412
1413
1414 ForceSendFields []string `json:"-"`
1415
1416
1417
1418
1419
1420
1421
1422 NullFields []string `json:"-"`
1423 }
1424
1425 func (s *AccountUserProfile) MarshalJSON() ([]byte, error) {
1426 type NoMethod AccountUserProfile
1427 raw := NoMethod(*s)
1428 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1429 }
1430
1431
1432 type AccountUserProfilesListResponse struct {
1433
1434 AccountUserProfiles []*AccountUserProfile `json:"accountUserProfiles,omitempty"`
1435
1436
1437
1438 Kind string `json:"kind,omitempty"`
1439
1440
1441
1442 NextPageToken string `json:"nextPageToken,omitempty"`
1443
1444
1445
1446 googleapi.ServerResponse `json:"-"`
1447
1448
1449
1450
1451
1452
1453
1454 ForceSendFields []string `json:"-"`
1455
1456
1457
1458
1459
1460
1461
1462
1463 NullFields []string `json:"-"`
1464 }
1465
1466 func (s *AccountUserProfilesListResponse) MarshalJSON() ([]byte, error) {
1467 type NoMethod AccountUserProfilesListResponse
1468 raw := NoMethod(*s)
1469 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1470 }
1471
1472
1473 type AccountsListResponse struct {
1474
1475 Accounts []*Account `json:"accounts,omitempty"`
1476
1477
1478
1479 Kind string `json:"kind,omitempty"`
1480
1481
1482
1483 NextPageToken string `json:"nextPageToken,omitempty"`
1484
1485
1486
1487 googleapi.ServerResponse `json:"-"`
1488
1489
1490
1491
1492
1493
1494
1495 ForceSendFields []string `json:"-"`
1496
1497
1498
1499
1500
1501
1502
1503 NullFields []string `json:"-"`
1504 }
1505
1506 func (s *AccountsListResponse) MarshalJSON() ([]byte, error) {
1507 type NoMethod AccountsListResponse
1508 raw := NoMethod(*s)
1509 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1510 }
1511
1512
1513 type Activities struct {
1514
1515
1516 Filters []*DimensionValue `json:"filters,omitempty"`
1517
1518
1519
1520 Kind string `json:"kind,omitempty"`
1521
1522
1523 MetricNames []string `json:"metricNames,omitempty"`
1524
1525
1526
1527
1528
1529
1530
1531 ForceSendFields []string `json:"-"`
1532
1533
1534
1535
1536
1537
1538
1539 NullFields []string `json:"-"`
1540 }
1541
1542 func (s *Activities) MarshalJSON() ([]byte, error) {
1543 type NoMethod Activities
1544 raw := NoMethod(*s)
1545 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1546 }
1547
1548
1549 type Ad struct {
1550
1551
1552 AccountId int64 `json:"accountId,omitempty,string"`
1553
1554
1555 Active bool `json:"active,omitempty"`
1556
1557
1558
1559 AdvertiserId int64 `json:"advertiserId,omitempty,string"`
1560
1561
1562
1563 AdvertiserIdDimensionValue *DimensionValue `json:"advertiserIdDimensionValue,omitempty"`
1564
1565
1566
1567 Archived bool `json:"archived,omitempty"`
1568
1569
1570
1571 AudienceSegmentId int64 `json:"audienceSegmentId,omitempty,string"`
1572
1573
1574
1575 CampaignId int64 `json:"campaignId,omitempty,string"`
1576
1577
1578
1579 CampaignIdDimensionValue *DimensionValue `json:"campaignIdDimensionValue,omitempty"`
1580
1581
1582
1583 ClickThroughUrl *ClickThroughUrl `json:"clickThroughUrl,omitempty"`
1584
1585
1586
1587
1588 ClickThroughUrlSuffixProperties *ClickThroughUrlSuffixProperties `json:"clickThroughUrlSuffixProperties,omitempty"`
1589
1590
1591 Comments string `json:"comments,omitempty"`
1592
1593
1594
1595
1596
1597
1598
1599
1600
1601
1602
1603
1604
1605
1606
1607
1608
1609
1610 Compatibility string `json:"compatibility,omitempty"`
1611
1612
1613
1614 CreateInfo *LastModifiedInfo `json:"createInfo,omitempty"`
1615
1616
1617
1618
1619
1620 CreativeGroupAssignments []*CreativeGroupAssignment `json:"creativeGroupAssignments,omitempty"`
1621
1622
1623
1624
1625
1626 CreativeRotation *CreativeRotation `json:"creativeRotation,omitempty"`
1627
1628
1629
1630
1631 DayPartTargeting *DayPartTargeting `json:"dayPartTargeting,omitempty"`
1632
1633
1634
1635 DefaultClickThroughEventTagProperties *DefaultClickThroughEventTagProperties `json:"defaultClickThroughEventTagProperties,omitempty"`
1636
1637
1638
1639
1640
1641
1642 DeliverySchedule *DeliverySchedule `json:"deliverySchedule,omitempty"`
1643
1644
1645
1646
1647 DynamicClickTracker bool `json:"dynamicClickTracker,omitempty"`
1648
1649
1650
1651 EndTime string `json:"endTime,omitempty"`
1652
1653
1654 EventTagOverrides []*EventTagOverride `json:"eventTagOverrides,omitempty"`
1655
1656
1657
1658
1659 GeoTargeting *GeoTargeting `json:"geoTargeting,omitempty"`
1660
1661
1662 Id int64 `json:"id,omitempty,string"`
1663
1664
1665
1666 IdDimensionValue *DimensionValue `json:"idDimensionValue,omitempty"`
1667
1668
1669
1670
1671 KeyValueTargetingExpression *KeyValueTargetingExpression `json:"keyValueTargetingExpression,omitempty"`
1672
1673
1674
1675 Kind string `json:"kind,omitempty"`
1676
1677
1678
1679
1680 LanguageTargeting *LanguageTargeting `json:"languageTargeting,omitempty"`
1681
1682
1683
1684 LastModifiedInfo *LastModifiedInfo `json:"lastModifiedInfo,omitempty"`
1685
1686
1687
1688 Name string `json:"name,omitempty"`
1689
1690
1691 PlacementAssignments []*PlacementAssignment `json:"placementAssignments,omitempty"`
1692
1693
1694
1695
1696 RemarketingListExpression *ListTargetingExpression `json:"remarketingListExpression,omitempty"`
1697
1698
1699 Size *Size `json:"size,omitempty"`
1700
1701
1702
1703 SslCompliant bool `json:"sslCompliant,omitempty"`
1704
1705
1706
1707 SslRequired bool `json:"sslRequired,omitempty"`
1708
1709
1710
1711
1712 StartTime string `json:"startTime,omitempty"`
1713
1714
1715
1716 SubaccountId int64 `json:"subaccountId,omitempty,string"`
1717
1718
1719
1720
1721
1722
1723
1724 TargetingTemplateId int64 `json:"targetingTemplateId,omitempty,string"`
1725
1726
1727
1728
1729 TechnologyTargeting *TechnologyTargeting `json:"technologyTargeting,omitempty"`
1730
1731
1732
1733
1734
1735
1736
1737
1738
1739
1740 Type string `json:"type,omitempty"`
1741
1742
1743
1744 googleapi.ServerResponse `json:"-"`
1745
1746
1747
1748
1749
1750
1751
1752 ForceSendFields []string `json:"-"`
1753
1754
1755
1756
1757
1758
1759
1760 NullFields []string `json:"-"`
1761 }
1762
1763 func (s *Ad) MarshalJSON() ([]byte, error) {
1764 type NoMethod Ad
1765 raw := NoMethod(*s)
1766 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1767 }
1768
1769
1770 type AdBlockingConfiguration struct {
1771
1772
1773 ClickThroughUrl string `json:"clickThroughUrl,omitempty"`
1774
1775
1776
1777
1778 CreativeBundleId int64 `json:"creativeBundleId,omitempty,string"`
1779
1780
1781
1782
1783
1784
1785 Enabled bool `json:"enabled,omitempty"`
1786
1787
1788
1789
1790
1791 OverrideClickThroughUrl bool `json:"overrideClickThroughUrl,omitempty"`
1792
1793
1794
1795
1796
1797
1798
1799 ForceSendFields []string `json:"-"`
1800
1801
1802
1803
1804
1805
1806
1807
1808 NullFields []string `json:"-"`
1809 }
1810
1811 func (s *AdBlockingConfiguration) MarshalJSON() ([]byte, error) {
1812 type NoMethod AdBlockingConfiguration
1813 raw := NoMethod(*s)
1814 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1815 }
1816
1817
1818 type AdSlot struct {
1819
1820 Comment string `json:"comment,omitempty"`
1821
1822
1823
1824
1825
1826
1827
1828
1829
1830
1831
1832
1833
1834
1835
1836 Compatibility string `json:"compatibility,omitempty"`
1837
1838
1839 Height int64 `json:"height,omitempty,string"`
1840
1841
1842
1843 LinkedPlacementId int64 `json:"linkedPlacementId,omitempty,string"`
1844
1845
1846 Name string `json:"name,omitempty"`
1847
1848
1849
1850
1851
1852
1853 PaymentSourceType string `json:"paymentSourceType,omitempty"`
1854
1855
1856 Primary bool `json:"primary,omitempty"`
1857
1858
1859 Width int64 `json:"width,omitempty,string"`
1860
1861
1862
1863
1864
1865
1866
1867 ForceSendFields []string `json:"-"`
1868
1869
1870
1871
1872
1873
1874
1875 NullFields []string `json:"-"`
1876 }
1877
1878 func (s *AdSlot) MarshalJSON() ([]byte, error) {
1879 type NoMethod AdSlot
1880 raw := NoMethod(*s)
1881 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1882 }
1883
1884
1885 type AdsListResponse struct {
1886
1887 Ads []*Ad `json:"ads,omitempty"`
1888
1889
1890
1891 Kind string `json:"kind,omitempty"`
1892
1893
1894
1895 NextPageToken string `json:"nextPageToken,omitempty"`
1896
1897
1898
1899 googleapi.ServerResponse `json:"-"`
1900
1901
1902
1903
1904
1905
1906
1907 ForceSendFields []string `json:"-"`
1908
1909
1910
1911
1912
1913
1914
1915 NullFields []string `json:"-"`
1916 }
1917
1918 func (s *AdsListResponse) MarshalJSON() ([]byte, error) {
1919 type NoMethod AdsListResponse
1920 raw := NoMethod(*s)
1921 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1922 }
1923
1924
1925 type Advertiser struct {
1926
1927
1928 AccountId int64 `json:"accountId,omitempty,string"`
1929
1930
1931
1932
1933 AdvertiserGroupId int64 `json:"advertiserGroupId,omitempty,string"`
1934
1935
1936
1937
1938 ClickThroughUrlSuffix string `json:"clickThroughUrlSuffix,omitempty"`
1939
1940
1941
1942 DefaultClickThroughEventTagId int64 `json:"defaultClickThroughEventTagId,omitempty,string"`
1943
1944
1945
1946 DefaultEmail string `json:"defaultEmail,omitempty"`
1947
1948
1949
1950
1951
1952
1953
1954
1955
1956
1957
1958
1959 FloodlightConfigurationId int64 `json:"floodlightConfigurationId,omitempty,string"`
1960
1961
1962
1963
1964 FloodlightConfigurationIdDimensionValue *DimensionValue `json:"floodlightConfigurationIdDimensionValue,omitempty"`
1965
1966
1967 Id int64 `json:"id,omitempty,string"`
1968
1969
1970
1971 IdDimensionValue *DimensionValue `json:"idDimensionValue,omitempty"`
1972
1973
1974
1975 Kind string `json:"kind,omitempty"`
1976
1977
1978
1979
1980 Name string `json:"name,omitempty"`
1981
1982
1983
1984
1985
1986
1987
1988 OriginalFloodlightConfigurationId int64 `json:"originalFloodlightConfigurationId,omitempty,string"`
1989
1990
1991
1992
1993
1994
1995 Status string `json:"status,omitempty"`
1996
1997
1998
1999 SubaccountId int64 `json:"subaccountId,omitempty,string"`
2000
2001
2002 Suspended bool `json:"suspended,omitempty"`
2003
2004
2005
2006 googleapi.ServerResponse `json:"-"`
2007
2008
2009
2010
2011
2012
2013
2014 ForceSendFields []string `json:"-"`
2015
2016
2017
2018
2019
2020
2021
2022 NullFields []string `json:"-"`
2023 }
2024
2025 func (s *Advertiser) MarshalJSON() ([]byte, error) {
2026 type NoMethod Advertiser
2027 raw := NoMethod(*s)
2028 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2029 }
2030
2031
2032
2033 type AdvertiserGroup struct {
2034
2035
2036 AccountId int64 `json:"accountId,omitempty,string"`
2037
2038
2039
2040 Id int64 `json:"id,omitempty,string"`
2041
2042
2043
2044 Kind string `json:"kind,omitempty"`
2045
2046
2047
2048
2049 Name string `json:"name,omitempty"`
2050
2051
2052
2053 googleapi.ServerResponse `json:"-"`
2054
2055
2056
2057
2058
2059
2060
2061 ForceSendFields []string `json:"-"`
2062
2063
2064
2065
2066
2067
2068
2069 NullFields []string `json:"-"`
2070 }
2071
2072 func (s *AdvertiserGroup) MarshalJSON() ([]byte, error) {
2073 type NoMethod AdvertiserGroup
2074 raw := NoMethod(*s)
2075 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2076 }
2077
2078
2079 type AdvertiserGroupsListResponse struct {
2080
2081 AdvertiserGroups []*AdvertiserGroup `json:"advertiserGroups,omitempty"`
2082
2083
2084
2085 Kind string `json:"kind,omitempty"`
2086
2087
2088
2089 NextPageToken string `json:"nextPageToken,omitempty"`
2090
2091
2092
2093 googleapi.ServerResponse `json:"-"`
2094
2095
2096
2097
2098
2099
2100
2101 ForceSendFields []string `json:"-"`
2102
2103
2104
2105
2106
2107
2108
2109
2110 NullFields []string `json:"-"`
2111 }
2112
2113 func (s *AdvertiserGroupsListResponse) MarshalJSON() ([]byte, error) {
2114 type NoMethod AdvertiserGroupsListResponse
2115 raw := NoMethod(*s)
2116 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2117 }
2118
2119
2120 type AdvertiserLandingPagesListResponse struct {
2121
2122
2123 Kind string `json:"kind,omitempty"`
2124
2125
2126 LandingPages []*LandingPage `json:"landingPages,omitempty"`
2127
2128
2129
2130 NextPageToken string `json:"nextPageToken,omitempty"`
2131
2132
2133
2134 googleapi.ServerResponse `json:"-"`
2135
2136
2137
2138
2139
2140
2141
2142 ForceSendFields []string `json:"-"`
2143
2144
2145
2146
2147
2148
2149
2150 NullFields []string `json:"-"`
2151 }
2152
2153 func (s *AdvertiserLandingPagesListResponse) MarshalJSON() ([]byte, error) {
2154 type NoMethod AdvertiserLandingPagesListResponse
2155 raw := NoMethod(*s)
2156 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2157 }
2158
2159
2160 type AdvertisersListResponse struct {
2161
2162 Advertisers []*Advertiser `json:"advertisers,omitempty"`
2163
2164
2165
2166 Kind string `json:"kind,omitempty"`
2167
2168
2169
2170 NextPageToken string `json:"nextPageToken,omitempty"`
2171
2172
2173
2174 googleapi.ServerResponse `json:"-"`
2175
2176
2177
2178
2179
2180
2181
2182 ForceSendFields []string `json:"-"`
2183
2184
2185
2186
2187
2188
2189
2190 NullFields []string `json:"-"`
2191 }
2192
2193 func (s *AdvertisersListResponse) MarshalJSON() ([]byte, error) {
2194 type NoMethod AdvertisersListResponse
2195 raw := NoMethod(*s)
2196 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2197 }
2198
2199
2200 type AudienceSegment struct {
2201
2202
2203
2204
2205 Allocation int64 `json:"allocation,omitempty"`
2206
2207
2208
2209 Id int64 `json:"id,omitempty,string"`
2210
2211
2212
2213 Name string `json:"name,omitempty"`
2214
2215
2216
2217
2218
2219
2220
2221 ForceSendFields []string `json:"-"`
2222
2223
2224
2225
2226
2227
2228
2229 NullFields []string `json:"-"`
2230 }
2231
2232 func (s *AudienceSegment) MarshalJSON() ([]byte, error) {
2233 type NoMethod AudienceSegment
2234 raw := NoMethod(*s)
2235 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2236 }
2237
2238
2239 type AudienceSegmentGroup struct {
2240
2241
2242 AudienceSegments []*AudienceSegment `json:"audienceSegments,omitempty"`
2243
2244
2245
2246 Id int64 `json:"id,omitempty,string"`
2247
2248
2249
2250 Name string `json:"name,omitempty"`
2251
2252
2253
2254
2255
2256
2257
2258 ForceSendFields []string `json:"-"`
2259
2260
2261
2262
2263
2264
2265
2266
2267 NullFields []string `json:"-"`
2268 }
2269
2270 func (s *AudienceSegmentGroup) MarshalJSON() ([]byte, error) {
2271 type NoMethod AudienceSegmentGroup
2272 raw := NoMethod(*s)
2273 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2274 }
2275
2276
2277
2278 type Browser struct {
2279
2280
2281 BrowserVersionId int64 `json:"browserVersionId,omitempty,string"`
2282
2283
2284
2285 DartId int64 `json:"dartId,omitempty,string"`
2286
2287
2288
2289 Kind string `json:"kind,omitempty"`
2290
2291
2292
2293
2294
2295
2296
2297
2298
2299
2300 MajorVersion string `json:"majorVersion,omitempty"`
2301
2302
2303
2304
2305
2306
2307
2308
2309
2310
2311 MinorVersion string `json:"minorVersion,omitempty"`
2312
2313
2314 Name string `json:"name,omitempty"`
2315
2316
2317
2318
2319
2320
2321
2322 ForceSendFields []string `json:"-"`
2323
2324
2325
2326
2327
2328
2329
2330
2331 NullFields []string `json:"-"`
2332 }
2333
2334 func (s *Browser) MarshalJSON() ([]byte, error) {
2335 type NoMethod Browser
2336 raw := NoMethod(*s)
2337 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2338 }
2339
2340
2341 type BrowsersListResponse struct {
2342
2343 Browsers []*Browser `json:"browsers,omitempty"`
2344
2345
2346
2347 Kind string `json:"kind,omitempty"`
2348
2349
2350
2351 googleapi.ServerResponse `json:"-"`
2352
2353
2354
2355
2356
2357
2358
2359 ForceSendFields []string `json:"-"`
2360
2361
2362
2363
2364
2365
2366
2367 NullFields []string `json:"-"`
2368 }
2369
2370 func (s *BrowsersListResponse) MarshalJSON() ([]byte, error) {
2371 type NoMethod BrowsersListResponse
2372 raw := NoMethod(*s)
2373 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2374 }
2375
2376
2377 type Campaign struct {
2378
2379
2380 AccountId int64 `json:"accountId,omitempty,string"`
2381
2382
2383 AdBlockingConfiguration *AdBlockingConfiguration `json:"adBlockingConfiguration,omitempty"`
2384
2385
2386
2387 AdditionalCreativeOptimizationConfigurations []*CreativeOptimizationConfiguration `json:"additionalCreativeOptimizationConfigurations,omitempty"`
2388
2389
2390 AdvertiserGroupId int64 `json:"advertiserGroupId,omitempty,string"`
2391
2392
2393
2394 AdvertiserId int64 `json:"advertiserId,omitempty,string"`
2395
2396
2397
2398 AdvertiserIdDimensionValue *DimensionValue `json:"advertiserIdDimensionValue,omitempty"`
2399
2400
2401 Archived bool `json:"archived,omitempty"`
2402
2403
2404
2405 AudienceSegmentGroups []*AudienceSegmentGroup `json:"audienceSegmentGroups,omitempty"`
2406
2407
2408
2409 BillingInvoiceCode string `json:"billingInvoiceCode,omitempty"`
2410
2411
2412
2413 ClickThroughUrlSuffixProperties *ClickThroughUrlSuffixProperties `json:"clickThroughUrlSuffixProperties,omitempty"`
2414
2415
2416
2417 Comment string `json:"comment,omitempty"`
2418
2419
2420
2421 CreateInfo *LastModifiedInfo `json:"createInfo,omitempty"`
2422
2423
2424
2425 CreativeGroupIds googleapi.Int64s `json:"creativeGroupIds,omitempty"`
2426
2427
2428
2429 CreativeOptimizationConfiguration *CreativeOptimizationConfiguration `json:"creativeOptimizationConfiguration,omitempty"`
2430
2431
2432
2433 DefaultClickThroughEventTagProperties *DefaultClickThroughEventTagProperties `json:"defaultClickThroughEventTagProperties,omitempty"`
2434
2435
2436 DefaultLandingPageId int64 `json:"defaultLandingPageId,omitempty,string"`
2437
2438
2439
2440
2441
2442
2443
2444
2445 EndDate string `json:"endDate,omitempty"`
2446
2447
2448
2449 EventTagOverrides []*EventTagOverride `json:"eventTagOverrides,omitempty"`
2450
2451
2452 ExternalId string `json:"externalId,omitempty"`
2453
2454
2455 Id int64 `json:"id,omitempty,string"`
2456
2457
2458
2459 IdDimensionValue *DimensionValue `json:"idDimensionValue,omitempty"`
2460
2461
2462
2463 Kind string `json:"kind,omitempty"`
2464
2465
2466
2467 LastModifiedInfo *LastModifiedInfo `json:"lastModifiedInfo,omitempty"`
2468
2469
2470 LookbackConfiguration *LookbackConfiguration `json:"lookbackConfiguration,omitempty"`
2471
2472
2473
2474
2475 Name string `json:"name,omitempty"`
2476
2477
2478
2479 NielsenOcrEnabled bool `json:"nielsenOcrEnabled,omitempty"`
2480
2481
2482
2483
2484
2485 StartDate string `json:"startDate,omitempty"`
2486
2487
2488
2489 SubaccountId int64 `json:"subaccountId,omitempty,string"`
2490
2491
2492 TraffickerEmails []string `json:"traffickerEmails,omitempty"`
2493
2494
2495
2496 googleapi.ServerResponse `json:"-"`
2497
2498
2499
2500
2501
2502
2503
2504 ForceSendFields []string `json:"-"`
2505
2506
2507
2508
2509
2510
2511
2512 NullFields []string `json:"-"`
2513 }
2514
2515 func (s *Campaign) MarshalJSON() ([]byte, error) {
2516 type NoMethod Campaign
2517 raw := NoMethod(*s)
2518 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2519 }
2520
2521
2522
2523 type CampaignCreativeAssociation struct {
2524
2525
2526 CreativeId int64 `json:"creativeId,omitempty,string"`
2527
2528
2529
2530 Kind string `json:"kind,omitempty"`
2531
2532
2533
2534 googleapi.ServerResponse `json:"-"`
2535
2536
2537
2538
2539
2540
2541
2542 ForceSendFields []string `json:"-"`
2543
2544
2545
2546
2547
2548
2549
2550 NullFields []string `json:"-"`
2551 }
2552
2553 func (s *CampaignCreativeAssociation) MarshalJSON() ([]byte, error) {
2554 type NoMethod CampaignCreativeAssociation
2555 raw := NoMethod(*s)
2556 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2557 }
2558
2559
2560
2561 type CampaignCreativeAssociationsListResponse struct {
2562
2563
2564 CampaignCreativeAssociations []*CampaignCreativeAssociation `json:"campaignCreativeAssociations,omitempty"`
2565
2566
2567
2568 Kind string `json:"kind,omitempty"`
2569
2570
2571
2572 NextPageToken string `json:"nextPageToken,omitempty"`
2573
2574
2575
2576 googleapi.ServerResponse `json:"-"`
2577
2578
2579
2580
2581
2582
2583
2584
2585 ForceSendFields []string `json:"-"`
2586
2587
2588
2589
2590
2591
2592
2593
2594 NullFields []string `json:"-"`
2595 }
2596
2597 func (s *CampaignCreativeAssociationsListResponse) MarshalJSON() ([]byte, error) {
2598 type NoMethod CampaignCreativeAssociationsListResponse
2599 raw := NoMethod(*s)
2600 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2601 }
2602
2603
2604 type CampaignsListResponse struct {
2605
2606 Campaigns []*Campaign `json:"campaigns,omitempty"`
2607
2608
2609
2610 Kind string `json:"kind,omitempty"`
2611
2612
2613
2614 NextPageToken string `json:"nextPageToken,omitempty"`
2615
2616
2617
2618 googleapi.ServerResponse `json:"-"`
2619
2620
2621
2622
2623
2624
2625
2626 ForceSendFields []string `json:"-"`
2627
2628
2629
2630
2631
2632
2633
2634 NullFields []string `json:"-"`
2635 }
2636
2637 func (s *CampaignsListResponse) MarshalJSON() ([]byte, error) {
2638 type NoMethod CampaignsListResponse
2639 raw := NoMethod(*s)
2640 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2641 }
2642
2643
2644 type ChangeLog struct {
2645
2646 AccountId int64 `json:"accountId,omitempty,string"`
2647
2648
2649 Action string `json:"action,omitempty"`
2650
2651
2652 ChangeTime string `json:"changeTime,omitempty"`
2653
2654
2655 FieldName string `json:"fieldName,omitempty"`
2656
2657
2658 Id int64 `json:"id,omitempty,string"`
2659
2660
2661
2662 Kind string `json:"kind,omitempty"`
2663
2664
2665 NewValue string `json:"newValue,omitempty"`
2666
2667
2668
2669 ObjectId int64 `json:"objectId,omitempty,string"`
2670
2671
2672 ObjectType string `json:"objectType,omitempty"`
2673
2674
2675 OldValue string `json:"oldValue,omitempty"`
2676
2677
2678 SubaccountId int64 `json:"subaccountId,omitempty,string"`
2679
2680
2681
2682
2683 TransactionId int64 `json:"transactionId,omitempty,string"`
2684
2685
2686 UserProfileId int64 `json:"userProfileId,omitempty,string"`
2687
2688
2689
2690 UserProfileName string `json:"userProfileName,omitempty"`
2691
2692
2693
2694 googleapi.ServerResponse `json:"-"`
2695
2696
2697
2698
2699
2700
2701
2702 ForceSendFields []string `json:"-"`
2703
2704
2705
2706
2707
2708
2709
2710 NullFields []string `json:"-"`
2711 }
2712
2713 func (s *ChangeLog) MarshalJSON() ([]byte, error) {
2714 type NoMethod ChangeLog
2715 raw := NoMethod(*s)
2716 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2717 }
2718
2719
2720 type ChangeLogsListResponse struct {
2721
2722 ChangeLogs []*ChangeLog `json:"changeLogs,omitempty"`
2723
2724
2725
2726 Kind string `json:"kind,omitempty"`
2727
2728
2729
2730 NextPageToken string `json:"nextPageToken,omitempty"`
2731
2732
2733
2734 googleapi.ServerResponse `json:"-"`
2735
2736
2737
2738
2739
2740
2741
2742 ForceSendFields []string `json:"-"`
2743
2744
2745
2746
2747
2748
2749
2750 NullFields []string `json:"-"`
2751 }
2752
2753 func (s *ChangeLogsListResponse) MarshalJSON() ([]byte, error) {
2754 type NoMethod ChangeLogsListResponse
2755 raw := NoMethod(*s)
2756 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2757 }
2758
2759
2760 type CitiesListResponse struct {
2761
2762 Cities []*City `json:"cities,omitempty"`
2763
2764
2765
2766 Kind string `json:"kind,omitempty"`
2767
2768
2769
2770 googleapi.ServerResponse `json:"-"`
2771
2772
2773
2774
2775
2776
2777
2778 ForceSendFields []string `json:"-"`
2779
2780
2781
2782
2783
2784
2785
2786 NullFields []string `json:"-"`
2787 }
2788
2789 func (s *CitiesListResponse) MarshalJSON() ([]byte, error) {
2790 type NoMethod CitiesListResponse
2791 raw := NoMethod(*s)
2792 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2793 }
2794
2795
2796 type City struct {
2797
2798 CountryCode string `json:"countryCode,omitempty"`
2799
2800
2801 CountryDartId int64 `json:"countryDartId,omitempty,string"`
2802
2803
2804
2805 DartId int64 `json:"dartId,omitempty,string"`
2806
2807
2808
2809 Kind string `json:"kind,omitempty"`
2810
2811
2812
2813 MetroCode string `json:"metroCode,omitempty"`
2814
2815
2816 MetroDmaId int64 `json:"metroDmaId,omitempty,string"`
2817
2818
2819 Name string `json:"name,omitempty"`
2820
2821
2822 RegionCode string `json:"regionCode,omitempty"`
2823
2824
2825 RegionDartId int64 `json:"regionDartId,omitempty,string"`
2826
2827
2828
2829
2830
2831
2832
2833 ForceSendFields []string `json:"-"`
2834
2835
2836
2837
2838
2839
2840
2841 NullFields []string `json:"-"`
2842 }
2843
2844 func (s *City) MarshalJSON() ([]byte, error) {
2845 type NoMethod City
2846 raw := NoMethod(*s)
2847 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2848 }
2849
2850
2851 type ClickTag struct {
2852
2853
2854 ClickThroughUrl *CreativeClickThroughUrl `json:"clickThroughUrl,omitempty"`
2855
2856
2857
2858
2859 EventName string `json:"eventName,omitempty"`
2860
2861
2862
2863
2864 Name string `json:"name,omitempty"`
2865
2866
2867
2868
2869
2870
2871
2872 ForceSendFields []string `json:"-"`
2873
2874
2875
2876
2877
2878
2879
2880
2881 NullFields []string `json:"-"`
2882 }
2883
2884 func (s *ClickTag) MarshalJSON() ([]byte, error) {
2885 type NoMethod ClickTag
2886 raw := NoMethod(*s)
2887 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2888 }
2889
2890
2891 type ClickThroughUrl struct {
2892
2893
2894
2895
2896
2897
2898
2899
2900
2901 ComputedClickThroughUrl string `json:"computedClickThroughUrl,omitempty"`
2902
2903
2904
2905
2906 CustomClickThroughUrl string `json:"customClickThroughUrl,omitempty"`
2907
2908
2909
2910 DefaultLandingPage bool `json:"defaultLandingPage,omitempty"`
2911
2912
2913
2914 LandingPageId int64 `json:"landingPageId,omitempty,string"`
2915
2916
2917
2918
2919
2920
2921
2922
2923 ForceSendFields []string `json:"-"`
2924
2925
2926
2927
2928
2929
2930
2931
2932 NullFields []string `json:"-"`
2933 }
2934
2935 func (s *ClickThroughUrl) MarshalJSON() ([]byte, error) {
2936 type NoMethod ClickThroughUrl
2937 raw := NoMethod(*s)
2938 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2939 }
2940
2941
2942 type ClickThroughUrlSuffixProperties struct {
2943
2944
2945 ClickThroughUrlSuffix string `json:"clickThroughUrlSuffix,omitempty"`
2946
2947
2948
2949 OverrideInheritedSuffix bool `json:"overrideInheritedSuffix,omitempty"`
2950
2951
2952
2953
2954
2955
2956
2957
2958 ForceSendFields []string `json:"-"`
2959
2960
2961
2962
2963
2964
2965
2966
2967 NullFields []string `json:"-"`
2968 }
2969
2970 func (s *ClickThroughUrlSuffixProperties) MarshalJSON() ([]byte, error) {
2971 type NoMethod ClickThroughUrlSuffixProperties
2972 raw := NoMethod(*s)
2973 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2974 }
2975
2976
2977 type CompanionClickThroughOverride struct {
2978
2979
2980 ClickThroughUrl *ClickThroughUrl `json:"clickThroughUrl,omitempty"`
2981
2982
2983
2984 CreativeId int64 `json:"creativeId,omitempty,string"`
2985
2986
2987
2988
2989
2990
2991
2992 ForceSendFields []string `json:"-"`
2993
2994
2995
2996
2997
2998
2999
3000
3001 NullFields []string `json:"-"`
3002 }
3003
3004 func (s *CompanionClickThroughOverride) MarshalJSON() ([]byte, error) {
3005 type NoMethod CompanionClickThroughOverride
3006 raw := NoMethod(*s)
3007 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3008 }
3009
3010
3011 type CompanionSetting struct {
3012
3013
3014 CompanionsDisabled bool `json:"companionsDisabled,omitempty"`
3015
3016
3017
3018
3019 EnabledSizes []*Size `json:"enabledSizes,omitempty"`
3020
3021
3022 ImageOnly bool `json:"imageOnly,omitempty"`
3023
3024
3025
3026 Kind string `json:"kind,omitempty"`
3027
3028
3029
3030
3031
3032
3033
3034 ForceSendFields []string `json:"-"`
3035
3036
3037
3038
3039
3040
3041
3042
3043 NullFields []string `json:"-"`
3044 }
3045
3046 func (s *CompanionSetting) MarshalJSON() ([]byte, error) {
3047 type NoMethod CompanionSetting
3048 raw := NoMethod(*s)
3049 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3050 }
3051
3052
3053
3054 type CompatibleFields struct {
3055
3056
3057
3058 CrossDimensionReachReportCompatibleFields *CrossDimensionReachReportCompatibleFields `json:"crossDimensionReachReportCompatibleFields,omitempty"`
3059
3060
3061
3062 FloodlightReportCompatibleFields *FloodlightReportCompatibleFields `json:"floodlightReportCompatibleFields,omitempty"`
3063
3064
3065
3066 Kind string `json:"kind,omitempty"`
3067
3068
3069
3070 PathToConversionReportCompatibleFields *PathToConversionReportCompatibleFields `json:"pathToConversionReportCompatibleFields,omitempty"`
3071
3072
3073
3074 ReachReportCompatibleFields *ReachReportCompatibleFields `json:"reachReportCompatibleFields,omitempty"`
3075
3076
3077
3078 ReportCompatibleFields *ReportCompatibleFields `json:"reportCompatibleFields,omitempty"`
3079
3080
3081
3082 googleapi.ServerResponse `json:"-"`
3083
3084
3085
3086
3087
3088
3089
3090
3091 ForceSendFields []string `json:"-"`
3092
3093
3094
3095
3096
3097
3098
3099
3100 NullFields []string `json:"-"`
3101 }
3102
3103 func (s *CompatibleFields) MarshalJSON() ([]byte, error) {
3104 type NoMethod CompatibleFields
3105 raw := NoMethod(*s)
3106 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3107 }
3108
3109
3110
3111
3112 type ConnectionType struct {
3113
3114 Id int64 `json:"id,omitempty,string"`
3115
3116
3117
3118 Kind string `json:"kind,omitempty"`
3119
3120
3121 Name string `json:"name,omitempty"`
3122
3123
3124
3125 googleapi.ServerResponse `json:"-"`
3126
3127
3128
3129
3130
3131
3132
3133 ForceSendFields []string `json:"-"`
3134
3135
3136
3137
3138
3139
3140
3141 NullFields []string `json:"-"`
3142 }
3143
3144 func (s *ConnectionType) MarshalJSON() ([]byte, error) {
3145 type NoMethod ConnectionType
3146 raw := NoMethod(*s)
3147 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3148 }
3149
3150
3151 type ConnectionTypesListResponse struct {
3152
3153
3154 ConnectionTypes []*ConnectionType `json:"connectionTypes,omitempty"`
3155
3156
3157
3158 Kind string `json:"kind,omitempty"`
3159
3160
3161
3162 googleapi.ServerResponse `json:"-"`
3163
3164
3165
3166
3167
3168
3169
3170 ForceSendFields []string `json:"-"`
3171
3172
3173
3174
3175
3176
3177
3178
3179 NullFields []string `json:"-"`
3180 }
3181
3182 func (s *ConnectionTypesListResponse) MarshalJSON() ([]byte, error) {
3183 type NoMethod ConnectionTypesListResponse
3184 raw := NoMethod(*s)
3185 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3186 }
3187
3188
3189 type ContentCategoriesListResponse struct {
3190
3191 ContentCategories []*ContentCategory `json:"contentCategories,omitempty"`
3192
3193
3194
3195 Kind string `json:"kind,omitempty"`
3196
3197
3198
3199 NextPageToken string `json:"nextPageToken,omitempty"`
3200
3201
3202
3203 googleapi.ServerResponse `json:"-"`
3204
3205
3206
3207
3208
3209
3210
3211 ForceSendFields []string `json:"-"`
3212
3213
3214
3215
3216
3217
3218
3219
3220 NullFields []string `json:"-"`
3221 }
3222
3223 func (s *ContentCategoriesListResponse) MarshalJSON() ([]byte, error) {
3224 type NoMethod ContentCategoriesListResponse
3225 raw := NoMethod(*s)
3226 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3227 }
3228
3229
3230
3231 type ContentCategory struct {
3232
3233
3234 AccountId int64 `json:"accountId,omitempty,string"`
3235
3236
3237
3238 Id int64 `json:"id,omitempty,string"`
3239
3240
3241
3242 Kind string `json:"kind,omitempty"`
3243
3244
3245
3246
3247 Name string `json:"name,omitempty"`
3248
3249
3250
3251 googleapi.ServerResponse `json:"-"`
3252
3253
3254
3255
3256
3257
3258
3259 ForceSendFields []string `json:"-"`
3260
3261
3262
3263
3264
3265
3266
3267 NullFields []string `json:"-"`
3268 }
3269
3270 func (s *ContentCategory) MarshalJSON() ([]byte, error) {
3271 type NoMethod ContentCategory
3272 raw := NoMethod(*s)
3273 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3274 }
3275
3276
3277
3278 type Conversion struct {
3279
3280
3281 ChildDirectedTreatment bool `json:"childDirectedTreatment,omitempty"`
3282
3283
3284 CustomVariables []*CustomFloodlightVariable `json:"customVariables,omitempty"`
3285
3286
3287
3288
3289
3290
3291 EncryptedUserId string `json:"encryptedUserId,omitempty"`
3292
3293
3294
3295
3296
3297
3298
3299
3300
3301
3302 EncryptedUserIdCandidates []string `json:"encryptedUserIdCandidates,omitempty"`
3303
3304
3305
3306 FloodlightActivityId int64 `json:"floodlightActivityId,omitempty,string"`
3307
3308
3309
3310 FloodlightConfigurationId int64 `json:"floodlightConfigurationId,omitempty,string"`
3311
3312
3313
3314
3315
3316 Gclid string `json:"gclid,omitempty"`
3317
3318
3319
3320 Kind string `json:"kind,omitempty"`
3321
3322
3323
3324
3325 LimitAdTracking bool `json:"limitAdTracking,omitempty"`
3326
3327
3328
3329
3330
3331 MobileDeviceId string `json:"mobileDeviceId,omitempty"`
3332
3333
3334
3335
3336 Ordinal string `json:"ordinal,omitempty"`
3337
3338
3339 Quantity int64 `json:"quantity,omitempty,string"`
3340
3341
3342
3343 TimestampMicros int64 `json:"timestampMicros,omitempty,string"`
3344
3345
3346 Value float64 `json:"value,omitempty"`
3347
3348
3349
3350
3351
3352
3353
3354
3355 ForceSendFields []string `json:"-"`
3356
3357
3358
3359
3360
3361
3362
3363
3364 NullFields []string `json:"-"`
3365 }
3366
3367 func (s *Conversion) MarshalJSON() ([]byte, error) {
3368 type NoMethod Conversion
3369 raw := NoMethod(*s)
3370 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3371 }
3372
3373 func (s *Conversion) UnmarshalJSON(data []byte) error {
3374 type NoMethod Conversion
3375 var s1 struct {
3376 Value gensupport.JSONFloat64 `json:"value"`
3377 *NoMethod
3378 }
3379 s1.NoMethod = (*NoMethod)(s)
3380 if err := json.Unmarshal(data, &s1); err != nil {
3381 return err
3382 }
3383 s.Value = float64(s1.Value)
3384 return nil
3385 }
3386
3387
3388
3389 type ConversionError struct {
3390
3391
3392
3393
3394
3395
3396
3397 Code string `json:"code,omitempty"`
3398
3399
3400
3401 Kind string `json:"kind,omitempty"`
3402
3403
3404 Message string `json:"message,omitempty"`
3405
3406
3407
3408
3409
3410
3411
3412 ForceSendFields []string `json:"-"`
3413
3414
3415
3416
3417
3418
3419
3420 NullFields []string `json:"-"`
3421 }
3422
3423 func (s *ConversionError) MarshalJSON() ([]byte, error) {
3424 type NoMethod ConversionError
3425 raw := NoMethod(*s)
3426 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3427 }
3428
3429
3430
3431 type ConversionStatus struct {
3432
3433 Conversion *Conversion `json:"conversion,omitempty"`
3434
3435
3436 Errors []*ConversionError `json:"errors,omitempty"`
3437
3438
3439
3440 Kind string `json:"kind,omitempty"`
3441
3442
3443
3444
3445
3446
3447
3448 ForceSendFields []string `json:"-"`
3449
3450
3451
3452
3453
3454
3455
3456 NullFields []string `json:"-"`
3457 }
3458
3459 func (s *ConversionStatus) MarshalJSON() ([]byte, error) {
3460 type NoMethod ConversionStatus
3461 raw := NoMethod(*s)
3462 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3463 }
3464
3465
3466 type ConversionsBatchInsertRequest struct {
3467
3468 Conversions []*Conversion `json:"conversions,omitempty"`
3469
3470
3471
3472
3473 EncryptionInfo *EncryptionInfo `json:"encryptionInfo,omitempty"`
3474
3475
3476
3477 Kind string `json:"kind,omitempty"`
3478
3479
3480
3481
3482
3483
3484
3485 ForceSendFields []string `json:"-"`
3486
3487
3488
3489
3490
3491
3492
3493 NullFields []string `json:"-"`
3494 }
3495
3496 func (s *ConversionsBatchInsertRequest) MarshalJSON() ([]byte, error) {
3497 type NoMethod ConversionsBatchInsertRequest
3498 raw := NoMethod(*s)
3499 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3500 }
3501
3502
3503 type ConversionsBatchInsertResponse struct {
3504
3505 HasFailures bool `json:"hasFailures,omitempty"`
3506
3507
3508
3509 Kind string `json:"kind,omitempty"`
3510
3511
3512
3513 Status []*ConversionStatus `json:"status,omitempty"`
3514
3515
3516
3517 googleapi.ServerResponse `json:"-"`
3518
3519
3520
3521
3522
3523
3524
3525 ForceSendFields []string `json:"-"`
3526
3527
3528
3529
3530
3531
3532
3533 NullFields []string `json:"-"`
3534 }
3535
3536 func (s *ConversionsBatchInsertResponse) MarshalJSON() ([]byte, error) {
3537 type NoMethod ConversionsBatchInsertResponse
3538 raw := NoMethod(*s)
3539 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3540 }
3541
3542
3543 type ConversionsBatchUpdateRequest struct {
3544
3545 Conversions []*Conversion `json:"conversions,omitempty"`
3546
3547
3548
3549 EncryptionInfo *EncryptionInfo `json:"encryptionInfo,omitempty"`
3550
3551
3552
3553 Kind string `json:"kind,omitempty"`
3554
3555
3556
3557
3558
3559
3560
3561 ForceSendFields []string `json:"-"`
3562
3563
3564
3565
3566
3567
3568
3569 NullFields []string `json:"-"`
3570 }
3571
3572 func (s *ConversionsBatchUpdateRequest) MarshalJSON() ([]byte, error) {
3573 type NoMethod ConversionsBatchUpdateRequest
3574 raw := NoMethod(*s)
3575 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3576 }
3577
3578
3579 type ConversionsBatchUpdateResponse struct {
3580
3581 HasFailures bool `json:"hasFailures,omitempty"`
3582
3583
3584
3585 Kind string `json:"kind,omitempty"`
3586
3587
3588
3589 Status []*ConversionStatus `json:"status,omitempty"`
3590
3591
3592
3593 googleapi.ServerResponse `json:"-"`
3594
3595
3596
3597
3598
3599
3600
3601 ForceSendFields []string `json:"-"`
3602
3603
3604
3605
3606
3607
3608
3609 NullFields []string `json:"-"`
3610 }
3611
3612 func (s *ConversionsBatchUpdateResponse) MarshalJSON() ([]byte, error) {
3613 type NoMethod ConversionsBatchUpdateResponse
3614 raw := NoMethod(*s)
3615 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3616 }
3617
3618
3619 type CountriesListResponse struct {
3620
3621 Countries []*Country `json:"countries,omitempty"`
3622
3623
3624
3625 Kind string `json:"kind,omitempty"`
3626
3627
3628
3629 googleapi.ServerResponse `json:"-"`
3630
3631
3632
3633
3634
3635
3636
3637 ForceSendFields []string `json:"-"`
3638
3639
3640
3641
3642
3643
3644
3645 NullFields []string `json:"-"`
3646 }
3647
3648 func (s *CountriesListResponse) MarshalJSON() ([]byte, error) {
3649 type NoMethod CountriesListResponse
3650 raw := NoMethod(*s)
3651 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3652 }
3653
3654
3655
3656 type Country struct {
3657
3658 CountryCode string `json:"countryCode,omitempty"`
3659
3660
3661
3662 DartId int64 `json:"dartId,omitempty,string"`
3663
3664
3665
3666 Kind string `json:"kind,omitempty"`
3667
3668
3669 Name string `json:"name,omitempty"`
3670
3671
3672
3673 SslEnabled bool `json:"sslEnabled,omitempty"`
3674
3675
3676
3677 googleapi.ServerResponse `json:"-"`
3678
3679
3680
3681
3682
3683
3684
3685 ForceSendFields []string `json:"-"`
3686
3687
3688
3689
3690
3691
3692
3693 NullFields []string `json:"-"`
3694 }
3695
3696 func (s *Country) MarshalJSON() ([]byte, error) {
3697 type NoMethod Country
3698 raw := NoMethod(*s)
3699 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3700 }
3701
3702
3703 type Creative struct {
3704
3705
3706
3707 AccountId int64 `json:"accountId,omitempty,string"`
3708
3709
3710
3711 Active bool `json:"active,omitempty"`
3712
3713
3714
3715
3716 AdParameters string `json:"adParameters,omitempty"`
3717
3718
3719
3720
3721
3722
3723
3724 AdTagKeys []string `json:"adTagKeys,omitempty"`
3725
3726
3727
3728 AdvertiserId int64 `json:"advertiserId,omitempty,string"`
3729
3730
3731
3732
3733
3734 AllowScriptAccess bool `json:"allowScriptAccess,omitempty"`
3735
3736
3737
3738 Archived bool `json:"archived,omitempty"`
3739
3740
3741
3742
3743
3744
3745
3746
3747
3748
3749 ArtworkType string `json:"artworkType,omitempty"`
3750
3751
3752
3753
3754
3755
3756
3757
3758
3759 AuthoringSource string `json:"authoringSource,omitempty"`
3760
3761
3762
3763
3764
3765
3766
3767
3768 AuthoringTool string `json:"authoringTool,omitempty"`
3769
3770
3771
3772
3773 AutoAdvanceImages bool `json:"autoAdvanceImages,omitempty"`
3774
3775
3776
3777
3778
3779 BackgroundColor string `json:"backgroundColor,omitempty"`
3780
3781
3782
3783
3784 BackupImageClickThroughUrl *CreativeClickThroughUrl `json:"backupImageClickThroughUrl,omitempty"`
3785
3786
3787
3788
3789
3790
3791
3792
3793
3794
3795
3796
3797
3798
3799
3800
3801
3802
3803
3804
3805
3806
3807
3808
3809
3810
3811
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 BackupImageFeatures []string `json:"backupImageFeatures,omitempty"`
3865
3866
3867
3868
3869 BackupImageReportingLabel string `json:"backupImageReportingLabel,omitempty"`
3870
3871
3872
3873
3874 BackupImageTargetWindow *TargetWindow `json:"backupImageTargetWindow,omitempty"`
3875
3876
3877
3878
3879
3880
3881
3882
3883
3884
3885
3886
3887
3888
3889 ClickTags []*ClickTag `json:"clickTags,omitempty"`
3890
3891
3892
3893 CommercialId string `json:"commercialId,omitempty"`
3894
3895
3896
3897
3898
3899
3900 CompanionCreatives googleapi.Int64s `json:"companionCreatives,omitempty"`
3901
3902
3903
3904
3905
3906
3907
3908
3909
3910
3911
3912
3913
3914
3915
3916
3917
3918
3919
3920
3921
3922
3923
3924
3925
3926 Compatibility []string `json:"compatibility,omitempty"`
3927
3928
3929
3930
3931
3932
3933
3934 ConvertFlashToHtml5 bool `json:"convertFlashToHtml5,omitempty"`
3935
3936
3937
3938
3939
3940 CounterCustomEvents []*CreativeCustomEvent `json:"counterCustomEvents,omitempty"`
3941
3942
3943 CreativeAssetSelection *CreativeAssetSelection `json:"creativeAssetSelection,omitempty"`
3944
3945
3946
3947
3948 CreativeAssets []*CreativeAsset `json:"creativeAssets,omitempty"`
3949
3950
3951
3952 CreativeFieldAssignments []*CreativeFieldAssignment `json:"creativeFieldAssignments,omitempty"`
3953
3954
3955
3956
3957
3958
3959
3960 CustomKeyValues []string `json:"customKeyValues,omitempty"`
3961
3962
3963
3964
3965
3966
3967
3968 DynamicAssetSelection bool `json:"dynamicAssetSelection,omitempty"`
3969
3970
3971
3972
3973
3974
3975
3976
3977 ExitCustomEvents []*CreativeCustomEvent `json:"exitCustomEvents,omitempty"`
3978
3979
3980
3981
3982
3983
3984 FsCommand *FsCommand `json:"fsCommand,omitempty"`
3985
3986
3987
3988
3989
3990 HtmlCode string `json:"htmlCode,omitempty"`
3991
3992
3993
3994
3995
3996 HtmlCodeLocked bool `json:"htmlCodeLocked,omitempty"`
3997
3998
3999
4000 Id int64 `json:"id,omitempty,string"`
4001
4002
4003
4004 IdDimensionValue *DimensionValue `json:"idDimensionValue,omitempty"`
4005
4006
4007
4008 Kind string `json:"kind,omitempty"`
4009
4010
4011
4012 LastModifiedInfo *LastModifiedInfo `json:"lastModifiedInfo,omitempty"`
4013
4014
4015
4016
4017
4018 LatestTraffickedCreativeId int64 `json:"latestTraffickedCreativeId,omitempty,string"`
4019
4020
4021
4022 Name string `json:"name,omitempty"`
4023
4024
4025
4026 OverrideCss string `json:"overrideCss,omitempty"`
4027
4028
4029
4030 PoliteLoadAssetId int64 `json:"politeLoadAssetId,omitempty,string"`
4031
4032
4033
4034 ProgressOffset *VideoOffset `json:"progressOffset,omitempty"`
4035
4036
4037
4038
4039
4040
4041
4042
4043 RedirectUrl string `json:"redirectUrl,omitempty"`
4044
4045
4046
4047 RenderingId int64 `json:"renderingId,omitempty,string"`
4048
4049
4050
4051
4052 RenderingIdDimensionValue *DimensionValue `json:"renderingIdDimensionValue,omitempty"`
4053
4054
4055
4056
4057
4058 RequiredFlashPluginVersion string `json:"requiredFlashPluginVersion,omitempty"`
4059
4060
4061
4062
4063
4064 RequiredFlashVersion int64 `json:"requiredFlashVersion,omitempty"`
4065
4066
4067
4068
4069
4070
4071
4072
4073
4074
4075 Size *Size `json:"size,omitempty"`
4076
4077
4078
4079
4080 SkipOffset *VideoOffset `json:"skipOffset,omitempty"`
4081
4082
4083
4084
4085 Skippable bool `json:"skippable,omitempty"`
4086
4087
4088
4089 SslCompliant bool `json:"sslCompliant,omitempty"`
4090
4091
4092
4093 SslOverride bool `json:"sslOverride,omitempty"`
4094
4095
4096
4097
4098 StudioAdvertiserId int64 `json:"studioAdvertiserId,omitempty,string"`
4099
4100
4101
4102
4103 StudioCreativeId int64 `json:"studioCreativeId,omitempty,string"`
4104
4105
4106
4107
4108
4109 StudioTraffickedCreativeId int64 `json:"studioTraffickedCreativeId,omitempty,string"`
4110
4111
4112
4113
4114 SubaccountId int64 `json:"subaccountId,omitempty,string"`
4115
4116
4117
4118
4119 ThirdPartyBackupImageImpressionsUrl string `json:"thirdPartyBackupImageImpressionsUrl,omitempty"`
4120
4121
4122
4123
4124 ThirdPartyRichMediaImpressionsUrl string `json:"thirdPartyRichMediaImpressionsUrl,omitempty"`
4125
4126
4127
4128
4129 ThirdPartyUrls []*ThirdPartyTrackingUrl `json:"thirdPartyUrls,omitempty"`
4130
4131
4132
4133
4134
4135
4136 TimerCustomEvents []*CreativeCustomEvent `json:"timerCustomEvents,omitempty"`
4137
4138
4139
4140
4141 TotalFileSize int64 `json:"totalFileSize,omitempty,string"`
4142
4143
4144
4145
4146
4147
4148
4149
4150
4151
4152
4153
4154
4155
4156
4157
4158
4159
4160
4161
4162
4163
4164
4165
4166
4167
4168
4169
4170
4171
4172
4173
4174
4175
4176 Type string `json:"type,omitempty"`
4177
4178
4179
4180 UniversalAdId *UniversalAdId `json:"universalAdId,omitempty"`
4181
4182
4183
4184
4185
4186
4187
4188
4189
4190 Version int64 `json:"version,omitempty"`
4191
4192
4193
4194 VideoDescription string `json:"videoDescription,omitempty"`
4195
4196
4197
4198
4199 VideoDuration float64 `json:"videoDuration,omitempty"`
4200
4201
4202
4203 googleapi.ServerResponse `json:"-"`
4204
4205
4206
4207
4208
4209
4210
4211 ForceSendFields []string `json:"-"`
4212
4213
4214
4215
4216
4217
4218
4219 NullFields []string `json:"-"`
4220 }
4221
4222 func (s *Creative) MarshalJSON() ([]byte, error) {
4223 type NoMethod Creative
4224 raw := NoMethod(*s)
4225 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
4226 }
4227
4228 func (s *Creative) UnmarshalJSON(data []byte) error {
4229 type NoMethod Creative
4230 var s1 struct {
4231 VideoDuration gensupport.JSONFloat64 `json:"videoDuration"`
4232 *NoMethod
4233 }
4234 s1.NoMethod = (*NoMethod)(s)
4235 if err := json.Unmarshal(data, &s1); err != nil {
4236 return err
4237 }
4238 s.VideoDuration = float64(s1.VideoDuration)
4239 return nil
4240 }
4241
4242
4243 type CreativeAsset struct {
4244
4245
4246
4247
4248 ActionScript3 bool `json:"actionScript3,omitempty"`
4249
4250
4251
4252
4253 Active bool `json:"active,omitempty"`
4254
4255
4256
4257
4258
4259
4260
4261
4262
4263
4264 Alignment string `json:"alignment,omitempty"`
4265
4266
4267
4268
4269
4270
4271
4272
4273
4274 ArtworkType string `json:"artworkType,omitempty"`
4275
4276
4277
4278
4279
4280 AssetIdentifier *CreativeAssetId `json:"assetIdentifier,omitempty"`
4281
4282
4283
4284 BackupImageExit *CreativeCustomEvent `json:"backupImageExit,omitempty"`
4285
4286
4287
4288
4289 BitRate int64 `json:"bitRate,omitempty"`
4290
4291
4292
4293
4294
4295
4296
4297
4298
4299 ChildAssetType string `json:"childAssetType,omitempty"`
4300
4301
4302
4303
4304
4305 CollapsedSize *Size `json:"collapsedSize,omitempty"`
4306
4307
4308
4309
4310
4311 CompanionCreativeIds googleapi.Int64s `json:"companionCreativeIds,omitempty"`
4312
4313
4314
4315
4316 CustomStartTimeValue int64 `json:"customStartTimeValue,omitempty"`
4317
4318
4319
4320
4321
4322
4323
4324
4325
4326
4327
4328
4329
4330
4331
4332
4333
4334
4335
4336
4337
4338
4339
4340
4341
4342
4343
4344
4345
4346
4347
4348
4349
4350
4351
4352
4353
4354
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 DetectedFeatures []string `json:"detectedFeatures,omitempty"`
4393
4394
4395
4396
4397
4398
4399
4400
4401
4402
4403
4404
4405
4406
4407
4408 DisplayType string `json:"displayType,omitempty"`
4409
4410
4411
4412
4413 Duration int64 `json:"duration,omitempty"`
4414
4415
4416
4417
4418
4419
4420
4421
4422 DurationType string `json:"durationType,omitempty"`
4423
4424
4425
4426
4427 ExpandedDimension *Size `json:"expandedDimension,omitempty"`
4428
4429
4430
4431
4432 FileSize int64 `json:"fileSize,omitempty,string"`
4433
4434
4435
4436
4437
4438 FlashVersion int64 `json:"flashVersion,omitempty"`
4439
4440
4441
4442 HideFlashObjects bool `json:"hideFlashObjects,omitempty"`
4443
4444
4445
4446 HideSelectionBoxes bool `json:"hideSelectionBoxes,omitempty"`
4447
4448
4449
4450
4451 HorizontallyLocked bool `json:"horizontallyLocked,omitempty"`
4452
4453
4454
4455
4456 Id int64 `json:"id,omitempty,string"`
4457
4458
4459
4460 IdDimensionValue *DimensionValue `json:"idDimensionValue,omitempty"`
4461
4462
4463
4464
4465 MimeType string `json:"mimeType,omitempty"`
4466
4467
4468
4469
4470
4471
4472 Offset *OffsetPosition `json:"offset,omitempty"`
4473
4474
4475
4476
4477
4478
4479
4480
4481 Orientation string `json:"orientation,omitempty"`
4482
4483
4484
4485
4486 OriginalBackup bool `json:"originalBackup,omitempty"`
4487
4488
4489
4490 Position *OffsetPosition `json:"position,omitempty"`
4491
4492
4493
4494
4495
4496
4497
4498
4499 PositionLeftUnit string `json:"positionLeftUnit,omitempty"`
4500
4501
4502
4503
4504
4505
4506
4507
4508
4509 PositionTopUnit string `json:"positionTopUnit,omitempty"`
4510
4511
4512
4513
4514 ProgressiveServingUrl string `json:"progressiveServingUrl,omitempty"`
4515
4516
4517
4518
4519
4520
4521 Pushdown bool `json:"pushdown,omitempty"`
4522
4523
4524
4525
4526
4527
4528
4529 PushdownDuration float64 `json:"pushdownDuration,omitempty"`
4530
4531
4532
4533
4534
4535
4536
4537
4538
4539
4540
4541
4542
4543
4544
4545
4546
4547
4548
4549
4550
4551
4552
4553
4554
4555
4556
4557
4558
4559
4560
4561
4562
4563
4564
4565
4566
4567
4568
4569
4570 Role string `json:"role,omitempty"`
4571
4572
4573
4574
4575
4576
4577
4578
4579 Size *Size `json:"size,omitempty"`
4580
4581
4582
4583
4584 SslCompliant bool `json:"sslCompliant,omitempty"`
4585
4586
4587
4588
4589
4590
4591
4592 StartTimeType string `json:"startTimeType,omitempty"`
4593
4594
4595
4596
4597 StreamingServingUrl string `json:"streamingServingUrl,omitempty"`
4598
4599
4600
4601
4602 Transparency bool `json:"transparency,omitempty"`
4603
4604
4605
4606
4607 VerticallyLocked bool `json:"verticallyLocked,omitempty"`
4608
4609
4610
4611
4612 VideoDuration float64 `json:"videoDuration,omitempty"`
4613
4614
4615
4616
4617
4618
4619
4620
4621
4622
4623 WindowMode string `json:"windowMode,omitempty"`
4624
4625
4626
4627
4628
4629
4630 ZIndex int64 `json:"zIndex,omitempty"`
4631
4632
4633
4634 ZipFilename string `json:"zipFilename,omitempty"`
4635
4636
4637
4638 ZipFilesize string `json:"zipFilesize,omitempty"`
4639
4640
4641
4642
4643
4644
4645
4646 ForceSendFields []string `json:"-"`
4647
4648
4649
4650
4651
4652
4653
4654 NullFields []string `json:"-"`
4655 }
4656
4657 func (s *CreativeAsset) MarshalJSON() ([]byte, error) {
4658 type NoMethod CreativeAsset
4659 raw := NoMethod(*s)
4660 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
4661 }
4662
4663 func (s *CreativeAsset) UnmarshalJSON(data []byte) error {
4664 type NoMethod CreativeAsset
4665 var s1 struct {
4666 PushdownDuration gensupport.JSONFloat64 `json:"pushdownDuration"`
4667 VideoDuration gensupport.JSONFloat64 `json:"videoDuration"`
4668 *NoMethod
4669 }
4670 s1.NoMethod = (*NoMethod)(s)
4671 if err := json.Unmarshal(data, &s1); err != nil {
4672 return err
4673 }
4674 s.PushdownDuration = float64(s1.PushdownDuration)
4675 s.VideoDuration = float64(s1.VideoDuration)
4676 return nil
4677 }
4678
4679
4680 type CreativeAssetId struct {
4681
4682
4683
4684
4685 Name string `json:"name,omitempty"`
4686
4687
4688
4689
4690
4691
4692
4693
4694
4695
4696
4697 Type string `json:"type,omitempty"`
4698
4699
4700
4701
4702
4703
4704
4705 ForceSendFields []string `json:"-"`
4706
4707
4708
4709
4710
4711
4712
4713 NullFields []string `json:"-"`
4714 }
4715
4716 func (s *CreativeAssetId) MarshalJSON() ([]byte, error) {
4717 type NoMethod CreativeAssetId
4718 raw := NoMethod(*s)
4719 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
4720 }
4721
4722
4723
4724
4725
4726 type CreativeAssetMetadata struct {
4727
4728 AssetIdentifier *CreativeAssetId `json:"assetIdentifier,omitempty"`
4729
4730
4731
4732 ClickTags []*ClickTag `json:"clickTags,omitempty"`
4733
4734
4735
4736
4737
4738
4739
4740
4741
4742
4743
4744
4745
4746
4747
4748
4749
4750
4751
4752
4753
4754
4755
4756
4757
4758
4759
4760
4761
4762
4763
4764
4765
4766
4767
4768
4769
4770
4771
4772
4773
4774
4775
4776
4777
4778
4779
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 DetectedFeatures []string `json:"detectedFeatures,omitempty"`
4808
4809
4810
4811 Id int64 `json:"id,omitempty,string"`
4812
4813
4814
4815 IdDimensionValue *DimensionValue `json:"idDimensionValue,omitempty"`
4816
4817
4818
4819 Kind string `json:"kind,omitempty"`
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
4855
4856
4857
4858
4859
4860
4861
4862
4863
4864
4865
4866
4867
4868
4869
4870
4871
4872
4873
4874
4875
4876 WarnedValidationRules []string `json:"warnedValidationRules,omitempty"`
4877
4878
4879
4880 googleapi.ServerResponse `json:"-"`
4881
4882
4883
4884
4885
4886
4887
4888 ForceSendFields []string `json:"-"`
4889
4890
4891
4892
4893
4894
4895
4896
4897 NullFields []string `json:"-"`
4898 }
4899
4900 func (s *CreativeAssetMetadata) MarshalJSON() ([]byte, error) {
4901 type NoMethod CreativeAssetMetadata
4902 raw := NoMethod(*s)
4903 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
4904 }
4905
4906
4907
4908
4909 type CreativeAssetSelection struct {
4910
4911
4912
4913 DefaultAssetId int64 `json:"defaultAssetId,omitempty,string"`
4914
4915
4916
4917
4918
4919 Rules []*Rule `json:"rules,omitempty"`
4920
4921
4922
4923
4924
4925
4926
4927 ForceSendFields []string `json:"-"`
4928
4929
4930
4931
4932
4933
4934
4935
4936 NullFields []string `json:"-"`
4937 }
4938
4939 func (s *CreativeAssetSelection) MarshalJSON() ([]byte, error) {
4940 type NoMethod CreativeAssetSelection
4941 raw := NoMethod(*s)
4942 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
4943 }
4944
4945
4946 type CreativeAssignment struct {
4947
4948
4949 Active bool `json:"active,omitempty"`
4950
4951
4952
4953
4954
4955
4956 ApplyEventTags bool `json:"applyEventTags,omitempty"`
4957
4958
4959 ClickThroughUrl *ClickThroughUrl `json:"clickThroughUrl,omitempty"`
4960
4961
4962
4963 CompanionCreativeOverrides []*CompanionClickThroughOverride `json:"companionCreativeOverrides,omitempty"`
4964
4965
4966
4967
4968 CreativeGroupAssignments []*CreativeGroupAssignment `json:"creativeGroupAssignments,omitempty"`
4969
4970
4971
4972 CreativeId int64 `json:"creativeId,omitempty,string"`
4973
4974
4975
4976 CreativeIdDimensionValue *DimensionValue `json:"creativeIdDimensionValue,omitempty"`
4977
4978
4979
4980 EndTime string `json:"endTime,omitempty"`
4981
4982
4983
4984
4985
4986
4987
4988
4989
4990
4991
4992
4993
4994
4995
4996 RichMediaExitOverrides []*RichMediaExitOverride `json:"richMediaExitOverrides,omitempty"`
4997
4998
4999
5000
5001 Sequence int64 `json:"sequence,omitempty"`
5002
5003
5004
5005
5006 SslCompliant bool `json:"sslCompliant,omitempty"`
5007
5008
5009
5010 StartTime string `json:"startTime,omitempty"`
5011
5012
5013
5014
5015 Weight int64 `json:"weight,omitempty"`
5016
5017
5018
5019
5020
5021
5022
5023 ForceSendFields []string `json:"-"`
5024
5025
5026
5027
5028
5029
5030
5031 NullFields []string `json:"-"`
5032 }
5033
5034 func (s *CreativeAssignment) MarshalJSON() ([]byte, error) {
5035 type NoMethod CreativeAssignment
5036 raw := NoMethod(*s)
5037 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5038 }
5039
5040
5041 type CreativeClickThroughUrl struct {
5042
5043
5044
5045
5046
5047
5048 ComputedClickThroughUrl string `json:"computedClickThroughUrl,omitempty"`
5049
5050
5051
5052 CustomClickThroughUrl string `json:"customClickThroughUrl,omitempty"`
5053
5054
5055 LandingPageId int64 `json:"landingPageId,omitempty,string"`
5056
5057
5058
5059
5060
5061
5062
5063
5064 ForceSendFields []string `json:"-"`
5065
5066
5067
5068
5069
5070
5071
5072
5073 NullFields []string `json:"-"`
5074 }
5075
5076 func (s *CreativeClickThroughUrl) MarshalJSON() ([]byte, error) {
5077 type NoMethod CreativeClickThroughUrl
5078 raw := NoMethod(*s)
5079 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5080 }
5081
5082
5083 type CreativeCustomEvent struct {
5084
5085
5086 AdvertiserCustomEventId int64 `json:"advertiserCustomEventId,omitempty,string"`
5087
5088
5089 AdvertiserCustomEventName string `json:"advertiserCustomEventName,omitempty"`
5090
5091
5092
5093
5094
5095
5096
5097
5098 AdvertiserCustomEventType string `json:"advertiserCustomEventType,omitempty"`
5099
5100
5101
5102
5103 ArtworkLabel string `json:"artworkLabel,omitempty"`
5104
5105
5106
5107
5108
5109
5110
5111
5112
5113 ArtworkType string `json:"artworkType,omitempty"`
5114
5115
5116
5117 ExitClickThroughUrl *CreativeClickThroughUrl `json:"exitClickThroughUrl,omitempty"`
5118
5119
5120
5121 Id int64 `json:"id,omitempty,string"`
5122
5123
5124
5125 PopupWindowProperties *PopupWindowProperties `json:"popupWindowProperties,omitempty"`
5126
5127
5128
5129
5130
5131
5132
5133
5134
5135 TargetType string `json:"targetType,omitempty"`
5136
5137
5138
5139 VideoReportingId string `json:"videoReportingId,omitempty"`
5140
5141
5142
5143
5144
5145
5146
5147
5148 ForceSendFields []string `json:"-"`
5149
5150
5151
5152
5153
5154
5155
5156
5157 NullFields []string `json:"-"`
5158 }
5159
5160 func (s *CreativeCustomEvent) MarshalJSON() ([]byte, error) {
5161 type NoMethod CreativeCustomEvent
5162 raw := NoMethod(*s)
5163 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5164 }
5165
5166
5167 type CreativeField struct {
5168
5169
5170 AccountId int64 `json:"accountId,omitempty,string"`
5171
5172
5173
5174 AdvertiserId int64 `json:"advertiserId,omitempty,string"`
5175
5176
5177
5178 AdvertiserIdDimensionValue *DimensionValue `json:"advertiserIdDimensionValue,omitempty"`
5179
5180
5181
5182 Id int64 `json:"id,omitempty,string"`
5183
5184
5185
5186 Kind string `json:"kind,omitempty"`
5187
5188
5189
5190
5191 Name string `json:"name,omitempty"`
5192
5193
5194
5195 SubaccountId int64 `json:"subaccountId,omitempty,string"`
5196
5197
5198
5199 googleapi.ServerResponse `json:"-"`
5200
5201
5202
5203
5204
5205
5206
5207 ForceSendFields []string `json:"-"`
5208
5209
5210
5211
5212
5213
5214
5215 NullFields []string `json:"-"`
5216 }
5217
5218 func (s *CreativeField) MarshalJSON() ([]byte, error) {
5219 type NoMethod CreativeField
5220 raw := NoMethod(*s)
5221 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5222 }
5223
5224
5225 type CreativeFieldAssignment struct {
5226
5227 CreativeFieldId int64 `json:"creativeFieldId,omitempty,string"`
5228
5229
5230 CreativeFieldValueId int64 `json:"creativeFieldValueId,omitempty,string"`
5231
5232
5233
5234
5235
5236
5237
5238 ForceSendFields []string `json:"-"`
5239
5240
5241
5242
5243
5244
5245
5246
5247 NullFields []string `json:"-"`
5248 }
5249
5250 func (s *CreativeFieldAssignment) MarshalJSON() ([]byte, error) {
5251 type NoMethod CreativeFieldAssignment
5252 raw := NoMethod(*s)
5253 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5254 }
5255
5256
5257 type CreativeFieldValue struct {
5258
5259
5260 Id int64 `json:"id,omitempty,string"`
5261
5262
5263
5264 Kind string `json:"kind,omitempty"`
5265
5266
5267
5268 Value string `json:"value,omitempty"`
5269
5270
5271
5272 googleapi.ServerResponse `json:"-"`
5273
5274
5275
5276
5277
5278
5279
5280 ForceSendFields []string `json:"-"`
5281
5282
5283
5284
5285
5286
5287
5288 NullFields []string `json:"-"`
5289 }
5290
5291 func (s *CreativeFieldValue) MarshalJSON() ([]byte, error) {
5292 type NoMethod CreativeFieldValue
5293 raw := NoMethod(*s)
5294 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5295 }
5296
5297
5298 type CreativeFieldValuesListResponse struct {
5299
5300 CreativeFieldValues []*CreativeFieldValue `json:"creativeFieldValues,omitempty"`
5301
5302
5303
5304 Kind string `json:"kind,omitempty"`
5305
5306
5307
5308 NextPageToken string `json:"nextPageToken,omitempty"`
5309
5310
5311
5312 googleapi.ServerResponse `json:"-"`
5313
5314
5315
5316
5317
5318
5319
5320 ForceSendFields []string `json:"-"`
5321
5322
5323
5324
5325
5326
5327
5328
5329 NullFields []string `json:"-"`
5330 }
5331
5332 func (s *CreativeFieldValuesListResponse) MarshalJSON() ([]byte, error) {
5333 type NoMethod CreativeFieldValuesListResponse
5334 raw := NoMethod(*s)
5335 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5336 }
5337
5338
5339 type CreativeFieldsListResponse struct {
5340
5341 CreativeFields []*CreativeField `json:"creativeFields,omitempty"`
5342
5343
5344
5345 Kind string `json:"kind,omitempty"`
5346
5347
5348
5349 NextPageToken string `json:"nextPageToken,omitempty"`
5350
5351
5352
5353 googleapi.ServerResponse `json:"-"`
5354
5355
5356
5357
5358
5359
5360
5361 ForceSendFields []string `json:"-"`
5362
5363
5364
5365
5366
5367
5368
5369
5370 NullFields []string `json:"-"`
5371 }
5372
5373 func (s *CreativeFieldsListResponse) MarshalJSON() ([]byte, error) {
5374 type NoMethod CreativeFieldsListResponse
5375 raw := NoMethod(*s)
5376 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5377 }
5378
5379
5380 type CreativeGroup struct {
5381
5382
5383 AccountId int64 `json:"accountId,omitempty,string"`
5384
5385
5386
5387 AdvertiserId int64 `json:"advertiserId,omitempty,string"`
5388
5389
5390
5391 AdvertiserIdDimensionValue *DimensionValue `json:"advertiserIdDimensionValue,omitempty"`
5392
5393
5394
5395
5396
5397 GroupNumber int64 `json:"groupNumber,omitempty"`
5398
5399
5400
5401 Id int64 `json:"id,omitempty,string"`
5402
5403
5404
5405 Kind string `json:"kind,omitempty"`
5406
5407
5408
5409
5410 Name string `json:"name,omitempty"`
5411
5412
5413
5414 SubaccountId int64 `json:"subaccountId,omitempty,string"`
5415
5416
5417
5418 googleapi.ServerResponse `json:"-"`
5419
5420
5421
5422
5423
5424
5425
5426 ForceSendFields []string `json:"-"`
5427
5428
5429
5430
5431
5432
5433
5434 NullFields []string `json:"-"`
5435 }
5436
5437 func (s *CreativeGroup) MarshalJSON() ([]byte, error) {
5438 type NoMethod CreativeGroup
5439 raw := NoMethod(*s)
5440 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5441 }
5442
5443
5444 type CreativeGroupAssignment struct {
5445
5446 CreativeGroupId int64 `json:"creativeGroupId,omitempty,string"`
5447
5448
5449
5450
5451
5452
5453
5454 CreativeGroupNumber string `json:"creativeGroupNumber,omitempty"`
5455
5456
5457
5458
5459
5460
5461
5462 ForceSendFields []string `json:"-"`
5463
5464
5465
5466
5467
5468
5469
5470
5471 NullFields []string `json:"-"`
5472 }
5473
5474 func (s *CreativeGroupAssignment) MarshalJSON() ([]byte, error) {
5475 type NoMethod CreativeGroupAssignment
5476 raw := NoMethod(*s)
5477 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5478 }
5479
5480
5481 type CreativeGroupsListResponse struct {
5482
5483 CreativeGroups []*CreativeGroup `json:"creativeGroups,omitempty"`
5484
5485
5486
5487 Kind string `json:"kind,omitempty"`
5488
5489
5490
5491 NextPageToken string `json:"nextPageToken,omitempty"`
5492
5493
5494
5495 googleapi.ServerResponse `json:"-"`
5496
5497
5498
5499
5500
5501
5502
5503 ForceSendFields []string `json:"-"`
5504
5505
5506
5507
5508
5509
5510
5511
5512 NullFields []string `json:"-"`
5513 }
5514
5515 func (s *CreativeGroupsListResponse) MarshalJSON() ([]byte, error) {
5516 type NoMethod CreativeGroupsListResponse
5517 raw := NoMethod(*s)
5518 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5519 }
5520
5521
5522 type CreativeOptimizationConfiguration struct {
5523
5524
5525
5526 Id int64 `json:"id,omitempty,string"`
5527
5528
5529
5530 Name string `json:"name,omitempty"`
5531
5532
5533
5534 OptimizationActivitys []*OptimizationActivity `json:"optimizationActivitys,omitempty"`
5535
5536
5537
5538
5539
5540
5541
5542
5543
5544 OptimizationModel string `json:"optimizationModel,omitempty"`
5545
5546
5547
5548
5549
5550
5551
5552 ForceSendFields []string `json:"-"`
5553
5554
5555
5556
5557
5558
5559
5560 NullFields []string `json:"-"`
5561 }
5562
5563 func (s *CreativeOptimizationConfiguration) MarshalJSON() ([]byte, error) {
5564 type NoMethod CreativeOptimizationConfiguration
5565 raw := NoMethod(*s)
5566 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5567 }
5568
5569
5570 type CreativeRotation struct {
5571
5572 CreativeAssignments []*CreativeAssignment `json:"creativeAssignments,omitempty"`
5573
5574
5575
5576
5577
5578
5579 CreativeOptimizationConfigurationId int64 `json:"creativeOptimizationConfigurationId,omitempty,string"`
5580
5581
5582
5583
5584
5585
5586
5587 Type string `json:"type,omitempty"`
5588
5589
5590
5591
5592
5593
5594
5595
5596
5597 WeightCalculationStrategy string `json:"weightCalculationStrategy,omitempty"`
5598
5599
5600
5601
5602
5603
5604
5605 ForceSendFields []string `json:"-"`
5606
5607
5608
5609
5610
5611
5612
5613
5614 NullFields []string `json:"-"`
5615 }
5616
5617 func (s *CreativeRotation) MarshalJSON() ([]byte, error) {
5618 type NoMethod CreativeRotation
5619 raw := NoMethod(*s)
5620 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5621 }
5622
5623
5624 type CreativeSettings struct {
5625
5626
5627 IFrameFooter string `json:"iFrameFooter,omitempty"`
5628
5629
5630
5631 IFrameHeader string `json:"iFrameHeader,omitempty"`
5632
5633
5634
5635
5636
5637
5638
5639 ForceSendFields []string `json:"-"`
5640
5641
5642
5643
5644
5645
5646
5647 NullFields []string `json:"-"`
5648 }
5649
5650 func (s *CreativeSettings) MarshalJSON() ([]byte, error) {
5651 type NoMethod CreativeSettings
5652 raw := NoMethod(*s)
5653 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5654 }
5655
5656
5657 type CreativesListResponse struct {
5658
5659 Creatives []*Creative `json:"creatives,omitempty"`
5660
5661
5662
5663 Kind string `json:"kind,omitempty"`
5664
5665
5666
5667 NextPageToken string `json:"nextPageToken,omitempty"`
5668
5669
5670
5671 googleapi.ServerResponse `json:"-"`
5672
5673
5674
5675
5676
5677
5678
5679 ForceSendFields []string `json:"-"`
5680
5681
5682
5683
5684
5685
5686
5687 NullFields []string `json:"-"`
5688 }
5689
5690 func (s *CreativesListResponse) MarshalJSON() ([]byte, error) {
5691 type NoMethod CreativesListResponse
5692 raw := NoMethod(*s)
5693 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5694 }
5695
5696
5697
5698
5699 type CrossDimensionReachReportCompatibleFields struct {
5700
5701
5702 Breakdown []*Dimension `json:"breakdown,omitempty"`
5703
5704
5705
5706 DimensionFilters []*Dimension `json:"dimensionFilters,omitempty"`
5707
5708
5709
5710 Kind string `json:"kind,omitempty"`
5711
5712
5713
5714 Metrics []*Metric `json:"metrics,omitempty"`
5715
5716
5717
5718 OverlapMetrics []*Metric `json:"overlapMetrics,omitempty"`
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 *CrossDimensionReachReportCompatibleFields) MarshalJSON() ([]byte, error) {
5738 type NoMethod CrossDimensionReachReportCompatibleFields
5739 raw := NoMethod(*s)
5740 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5741 }
5742
5743
5744 type CustomFloodlightVariable struct {
5745
5746
5747 Kind string `json:"kind,omitempty"`
5748
5749
5750
5751
5752
5753
5754
5755
5756
5757
5758
5759
5760
5761
5762
5763
5764
5765
5766
5767
5768
5769
5770
5771
5772
5773
5774
5775
5776
5777
5778
5779
5780
5781
5782
5783
5784
5785
5786
5787
5788
5789
5790
5791
5792
5793
5794
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 Type string `json:"type,omitempty"`
5854
5855
5856
5857 Value string `json:"value,omitempty"`
5858
5859
5860
5861
5862
5863
5864
5865 ForceSendFields []string `json:"-"`
5866
5867
5868
5869
5870
5871
5872
5873 NullFields []string `json:"-"`
5874 }
5875
5876 func (s *CustomFloodlightVariable) MarshalJSON() ([]byte, error) {
5877 type NoMethod CustomFloodlightVariable
5878 raw := NoMethod(*s)
5879 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5880 }
5881
5882
5883 type CustomRichMediaEvents struct {
5884
5885
5886 FilteredEventIds []*DimensionValue `json:"filteredEventIds,omitempty"`
5887
5888
5889
5890 Kind string `json:"kind,omitempty"`
5891
5892
5893
5894
5895
5896
5897
5898 ForceSendFields []string `json:"-"`
5899
5900
5901
5902
5903
5904
5905
5906
5907 NullFields []string `json:"-"`
5908 }
5909
5910 func (s *CustomRichMediaEvents) MarshalJSON() ([]byte, error) {
5911 type NoMethod CustomRichMediaEvents
5912 raw := NoMethod(*s)
5913 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5914 }
5915
5916
5917 type DateRange struct {
5918
5919
5920 EndDate string `json:"endDate,omitempty"`
5921
5922
5923
5924 Kind string `json:"kind,omitempty"`
5925
5926
5927
5928
5929
5930
5931
5932
5933
5934
5935
5936
5937
5938
5939
5940
5941
5942
5943
5944
5945
5946
5947 RelativeDateRange string `json:"relativeDateRange,omitempty"`
5948
5949
5950
5951 StartDate string `json:"startDate,omitempty"`
5952
5953
5954
5955
5956
5957
5958
5959 ForceSendFields []string `json:"-"`
5960
5961
5962
5963
5964
5965
5966
5967 NullFields []string `json:"-"`
5968 }
5969
5970 func (s *DateRange) MarshalJSON() ([]byte, error) {
5971 type NoMethod DateRange
5972 raw := NoMethod(*s)
5973 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5974 }
5975
5976
5977 type DayPartTargeting struct {
5978
5979
5980
5981
5982
5983
5984
5985
5986
5987
5988
5989
5990
5991
5992
5993
5994
5995
5996
5997 DaysOfWeek []string `json:"daysOfWeek,omitempty"`
5998
5999
6000
6001
6002
6003
6004
6005
6006 HoursOfDay []int64 `json:"hoursOfDay,omitempty"`
6007
6008
6009
6010 UserLocalTime bool `json:"userLocalTime,omitempty"`
6011
6012
6013
6014
6015
6016
6017
6018 ForceSendFields []string `json:"-"`
6019
6020
6021
6022
6023
6024
6025
6026 NullFields []string `json:"-"`
6027 }
6028
6029 func (s *DayPartTargeting) MarshalJSON() ([]byte, error) {
6030 type NoMethod DayPartTargeting
6031 raw := NoMethod(*s)
6032 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6033 }
6034
6035
6036
6037
6038
6039 type DefaultClickThroughEventTagProperties struct {
6040
6041
6042 DefaultClickThroughEventTagId int64 `json:"defaultClickThroughEventTagId,omitempty,string"`
6043
6044
6045
6046 OverrideInheritedEventTag bool `json:"overrideInheritedEventTag,omitempty"`
6047
6048
6049
6050
6051
6052
6053
6054
6055 ForceSendFields []string `json:"-"`
6056
6057
6058
6059
6060
6061
6062
6063
6064 NullFields []string `json:"-"`
6065 }
6066
6067 func (s *DefaultClickThroughEventTagProperties) MarshalJSON() ([]byte, error) {
6068 type NoMethod DefaultClickThroughEventTagProperties
6069 raw := NoMethod(*s)
6070 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6071 }
6072
6073
6074 type DeliverySchedule struct {
6075
6076
6077 FrequencyCap *FrequencyCap `json:"frequencyCap,omitempty"`
6078
6079
6080
6081
6082 HardCutoff bool `json:"hardCutoff,omitempty"`
6083
6084
6085
6086
6087
6088
6089 ImpressionRatio int64 `json:"impressionRatio,omitempty,string"`
6090
6091
6092
6093
6094
6095
6096
6097
6098
6099
6100
6101
6102
6103
6104
6105
6106
6107
6108
6109
6110
6111
6112 Priority string `json:"priority,omitempty"`
6113
6114
6115
6116
6117
6118
6119
6120 ForceSendFields []string `json:"-"`
6121
6122
6123
6124
6125
6126
6127
6128 NullFields []string `json:"-"`
6129 }
6130
6131 func (s *DeliverySchedule) MarshalJSON() ([]byte, error) {
6132 type NoMethod DeliverySchedule
6133 raw := NoMethod(*s)
6134 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6135 }
6136
6137
6138 type DfpSettings struct {
6139
6140 DfpNetworkCode string `json:"dfpNetworkCode,omitempty"`
6141
6142
6143 DfpNetworkName string `json:"dfpNetworkName,omitempty"`
6144
6145
6146
6147 ProgrammaticPlacementAccepted bool `json:"programmaticPlacementAccepted,omitempty"`
6148
6149
6150
6151 PubPaidPlacementAccepted bool `json:"pubPaidPlacementAccepted,omitempty"`
6152
6153
6154
6155 PublisherPortalOnly bool `json:"publisherPortalOnly,omitempty"`
6156
6157
6158
6159
6160
6161
6162
6163 ForceSendFields []string `json:"-"`
6164
6165
6166
6167
6168
6169
6170
6171
6172 NullFields []string `json:"-"`
6173 }
6174
6175 func (s *DfpSettings) MarshalJSON() ([]byte, error) {
6176 type NoMethod DfpSettings
6177 raw := NoMethod(*s)
6178 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6179 }
6180
6181
6182 type Dimension struct {
6183
6184
6185 Kind string `json:"kind,omitempty"`
6186
6187
6188 Name string `json:"name,omitempty"`
6189
6190
6191
6192
6193
6194
6195
6196 ForceSendFields []string `json:"-"`
6197
6198
6199
6200
6201
6202
6203
6204 NullFields []string `json:"-"`
6205 }
6206
6207 func (s *Dimension) MarshalJSON() ([]byte, error) {
6208 type NoMethod Dimension
6209 raw := NoMethod(*s)
6210 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6211 }
6212
6213
6214 type DimensionFilter struct {
6215
6216 DimensionName string `json:"dimensionName,omitempty"`
6217
6218
6219
6220 Kind string `json:"kind,omitempty"`
6221
6222
6223 Value string `json:"value,omitempty"`
6224
6225
6226
6227
6228
6229
6230
6231 ForceSendFields []string `json:"-"`
6232
6233
6234
6235
6236
6237
6238
6239 NullFields []string `json:"-"`
6240 }
6241
6242 func (s *DimensionFilter) MarshalJSON() ([]byte, error) {
6243 type NoMethod DimensionFilter
6244 raw := NoMethod(*s)
6245 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6246 }
6247
6248
6249 type DimensionValue struct {
6250
6251 DimensionName string `json:"dimensionName,omitempty"`
6252
6253
6254 Etag string `json:"etag,omitempty"`
6255
6256
6257 Id string `json:"id,omitempty"`
6258
6259
6260
6261 Kind string `json:"kind,omitempty"`
6262
6263
6264
6265
6266
6267
6268
6269
6270
6271
6272
6273
6274
6275 MatchType string `json:"matchType,omitempty"`
6276
6277
6278 Value string `json:"value,omitempty"`
6279
6280
6281
6282
6283
6284
6285
6286 ForceSendFields []string `json:"-"`
6287
6288
6289
6290
6291
6292
6293
6294 NullFields []string `json:"-"`
6295 }
6296
6297 func (s *DimensionValue) MarshalJSON() ([]byte, error) {
6298 type NoMethod DimensionValue
6299 raw := NoMethod(*s)
6300 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6301 }
6302
6303
6304 type DimensionValueList struct {
6305
6306 Etag string `json:"etag,omitempty"`
6307
6308
6309 Items []*DimensionValue `json:"items,omitempty"`
6310
6311
6312
6313 Kind string `json:"kind,omitempty"`
6314
6315
6316
6317
6318
6319 NextPageToken string `json:"nextPageToken,omitempty"`
6320
6321
6322
6323 googleapi.ServerResponse `json:"-"`
6324
6325
6326
6327
6328
6329
6330
6331 ForceSendFields []string `json:"-"`
6332
6333
6334
6335
6336
6337
6338
6339 NullFields []string `json:"-"`
6340 }
6341
6342 func (s *DimensionValueList) MarshalJSON() ([]byte, error) {
6343 type NoMethod DimensionValueList
6344 raw := NoMethod(*s)
6345 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6346 }
6347
6348
6349 type DimensionValueRequest struct {
6350
6351
6352 DimensionName string `json:"dimensionName,omitempty"`
6353
6354
6355
6356 EndDate string `json:"endDate,omitempty"`
6357
6358
6359
6360 Filters []*DimensionFilter `json:"filters,omitempty"`
6361
6362
6363
6364 Kind string `json:"kind,omitempty"`
6365
6366
6367
6368 StartDate string `json:"startDate,omitempty"`
6369
6370
6371
6372
6373
6374
6375
6376 ForceSendFields []string `json:"-"`
6377
6378
6379
6380
6381
6382
6383
6384 NullFields []string `json:"-"`
6385 }
6386
6387 func (s *DimensionValueRequest) MarshalJSON() ([]byte, error) {
6388 type NoMethod DimensionValueRequest
6389 raw := NoMethod(*s)
6390 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6391 }
6392
6393
6394
6395
6396 type DirectorySite struct {
6397
6398 Active bool `json:"active,omitempty"`
6399
6400
6401 ContactAssignments []*DirectorySiteContactAssignment `json:"contactAssignments,omitempty"`
6402
6403
6404
6405 CountryId int64 `json:"countryId,omitempty,string"`
6406
6407
6408
6409
6410
6411
6412
6413
6414
6415
6416
6417
6418
6419
6420
6421
6422
6423
6424
6425
6426
6427
6428
6429
6430
6431
6432
6433
6434
6435
6436
6437
6438
6439
6440
6441
6442
6443
6444
6445
6446
6447
6448
6449
6450
6451
6452
6453
6454
6455
6456
6457
6458
6459 CurrencyId int64 `json:"currencyId,omitempty,string"`
6460
6461
6462
6463 Description string `json:"description,omitempty"`
6464
6465
6466
6467 Id int64 `json:"id,omitempty,string"`
6468
6469
6470
6471 IdDimensionValue *DimensionValue `json:"idDimensionValue,omitempty"`
6472
6473
6474
6475
6476
6477
6478
6479
6480
6481
6482
6483
6484
6485
6486 InpageTagFormats []string `json:"inpageTagFormats,omitempty"`
6487
6488
6489
6490
6491
6492
6493
6494
6495
6496
6497
6498
6499
6500 InterstitialTagFormats []string `json:"interstitialTagFormats,omitempty"`
6501
6502
6503
6504 Kind string `json:"kind,omitempty"`
6505
6506
6507 Name string `json:"name,omitempty"`
6508
6509
6510 ParentId int64 `json:"parentId,omitempty,string"`
6511
6512
6513 Settings *DirectorySiteSettings `json:"settings,omitempty"`
6514
6515
6516 Url string `json:"url,omitempty"`
6517
6518
6519
6520 googleapi.ServerResponse `json:"-"`
6521
6522
6523
6524
6525
6526
6527
6528 ForceSendFields []string `json:"-"`
6529
6530
6531
6532
6533
6534
6535
6536 NullFields []string `json:"-"`
6537 }
6538
6539 func (s *DirectorySite) MarshalJSON() ([]byte, error) {
6540 type NoMethod DirectorySite
6541 raw := NoMethod(*s)
6542 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6543 }
6544
6545
6546
6547 type DirectorySiteContact struct {
6548
6549 Address string `json:"address,omitempty"`
6550
6551
6552 Email string `json:"email,omitempty"`
6553
6554
6555 FirstName string `json:"firstName,omitempty"`
6556
6557
6558
6559 Id int64 `json:"id,omitempty,string"`
6560
6561
6562
6563 Kind string `json:"kind,omitempty"`
6564
6565
6566 LastName string `json:"lastName,omitempty"`
6567
6568
6569 Phone string `json:"phone,omitempty"`
6570
6571
6572
6573
6574
6575
6576
6577 Role string `json:"role,omitempty"`
6578
6579
6580 Title string `json:"title,omitempty"`
6581
6582
6583
6584
6585
6586
6587
6588
6589 Type string `json:"type,omitempty"`
6590
6591
6592
6593 googleapi.ServerResponse `json:"-"`
6594
6595
6596
6597
6598
6599
6600
6601 ForceSendFields []string `json:"-"`
6602
6603
6604
6605
6606
6607
6608
6609 NullFields []string `json:"-"`
6610 }
6611
6612 func (s *DirectorySiteContact) MarshalJSON() ([]byte, error) {
6613 type NoMethod DirectorySiteContact
6614 raw := NoMethod(*s)
6615 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6616 }
6617
6618
6619 type DirectorySiteContactAssignment struct {
6620
6621
6622 ContactId int64 `json:"contactId,omitempty,string"`
6623
6624
6625
6626
6627
6628
6629
6630
6631 Visibility string `json:"visibility,omitempty"`
6632
6633
6634
6635
6636
6637
6638
6639 ForceSendFields []string `json:"-"`
6640
6641
6642
6643
6644
6645
6646
6647 NullFields []string `json:"-"`
6648 }
6649
6650 func (s *DirectorySiteContactAssignment) MarshalJSON() ([]byte, error) {
6651 type NoMethod DirectorySiteContactAssignment
6652 raw := NoMethod(*s)
6653 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6654 }
6655
6656
6657
6658 type DirectorySiteContactsListResponse struct {
6659
6660 DirectorySiteContacts []*DirectorySiteContact `json:"directorySiteContacts,omitempty"`
6661
6662
6663
6664 Kind string `json:"kind,omitempty"`
6665
6666
6667
6668 NextPageToken string `json:"nextPageToken,omitempty"`
6669
6670
6671
6672 googleapi.ServerResponse `json:"-"`
6673
6674
6675
6676
6677
6678
6679
6680
6681 ForceSendFields []string `json:"-"`
6682
6683
6684
6685
6686
6687
6688
6689
6690 NullFields []string `json:"-"`
6691 }
6692
6693 func (s *DirectorySiteContactsListResponse) MarshalJSON() ([]byte, error) {
6694 type NoMethod DirectorySiteContactsListResponse
6695 raw := NoMethod(*s)
6696 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6697 }
6698
6699
6700 type DirectorySiteSettings struct {
6701
6702
6703 ActiveViewOptOut bool `json:"activeViewOptOut,omitempty"`
6704
6705
6706 DfpSettings *DfpSettings `json:"dfpSettings,omitempty"`
6707
6708
6709
6710 InstreamVideoPlacementAccepted bool `json:"instreamVideoPlacementAccepted,omitempty"`
6711
6712
6713
6714 InterstitialPlacementAccepted bool `json:"interstitialPlacementAccepted,omitempty"`
6715
6716
6717
6718 NielsenOcrOptOut bool `json:"nielsenOcrOptOut,omitempty"`
6719
6720
6721
6722 VerificationTagOptOut bool `json:"verificationTagOptOut,omitempty"`
6723
6724
6725
6726 VideoActiveViewOptOut bool `json:"videoActiveViewOptOut,omitempty"`
6727
6728
6729
6730
6731
6732
6733
6734 ForceSendFields []string `json:"-"`
6735
6736
6737
6738
6739
6740
6741
6742
6743 NullFields []string `json:"-"`
6744 }
6745
6746 func (s *DirectorySiteSettings) MarshalJSON() ([]byte, error) {
6747 type NoMethod DirectorySiteSettings
6748 raw := NoMethod(*s)
6749 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6750 }
6751
6752
6753 type DirectorySitesListResponse struct {
6754
6755 DirectorySites []*DirectorySite `json:"directorySites,omitempty"`
6756
6757
6758
6759 Kind string `json:"kind,omitempty"`
6760
6761
6762
6763 NextPageToken string `json:"nextPageToken,omitempty"`
6764
6765
6766
6767 googleapi.ServerResponse `json:"-"`
6768
6769
6770
6771
6772
6773
6774
6775 ForceSendFields []string `json:"-"`
6776
6777
6778
6779
6780
6781
6782
6783
6784 NullFields []string `json:"-"`
6785 }
6786
6787 func (s *DirectorySitesListResponse) MarshalJSON() ([]byte, error) {
6788 type NoMethod DirectorySitesListResponse
6789 raw := NoMethod(*s)
6790 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6791 }
6792
6793
6794
6795
6796
6797
6798
6799 type DynamicTargetingKey struct {
6800
6801
6802 Kind string `json:"kind,omitempty"`
6803
6804
6805
6806
6807 Name string `json:"name,omitempty"`
6808
6809
6810
6811 ObjectId int64 `json:"objectId,omitempty,string"`
6812
6813
6814
6815
6816
6817
6818
6819
6820
6821 ObjectType string `json:"objectType,omitempty"`
6822
6823
6824
6825 googleapi.ServerResponse `json:"-"`
6826
6827
6828
6829
6830
6831
6832
6833 ForceSendFields []string `json:"-"`
6834
6835
6836
6837
6838
6839
6840
6841 NullFields []string `json:"-"`
6842 }
6843
6844 func (s *DynamicTargetingKey) MarshalJSON() ([]byte, error) {
6845 type NoMethod DynamicTargetingKey
6846 raw := NoMethod(*s)
6847 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6848 }
6849
6850
6851 type DynamicTargetingKeysListResponse struct {
6852
6853 DynamicTargetingKeys []*DynamicTargetingKey `json:"dynamicTargetingKeys,omitempty"`
6854
6855
6856
6857 Kind string `json:"kind,omitempty"`
6858
6859
6860
6861 googleapi.ServerResponse `json:"-"`
6862
6863
6864
6865
6866
6867
6868
6869
6870 ForceSendFields []string `json:"-"`
6871
6872
6873
6874
6875
6876
6877
6878
6879 NullFields []string `json:"-"`
6880 }
6881
6882 func (s *DynamicTargetingKeysListResponse) MarshalJSON() ([]byte, error) {
6883 type NoMethod DynamicTargetingKeysListResponse
6884 raw := NoMethod(*s)
6885 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6886 }
6887
6888
6889 type EncryptionInfo struct {
6890
6891
6892 EncryptionEntityId int64 `json:"encryptionEntityId,omitempty,string"`
6893
6894
6895
6896
6897
6898
6899
6900
6901
6902
6903
6904
6905 EncryptionEntityType string `json:"encryptionEntityType,omitempty"`
6906
6907
6908
6909
6910
6911
6912
6913
6914 EncryptionSource string `json:"encryptionSource,omitempty"`
6915
6916
6917
6918 Kind string `json:"kind,omitempty"`
6919
6920
6921
6922
6923
6924
6925
6926 ForceSendFields []string `json:"-"`
6927
6928
6929
6930
6931
6932
6933
6934
6935 NullFields []string `json:"-"`
6936 }
6937
6938 func (s *EncryptionInfo) MarshalJSON() ([]byte, error) {
6939 type NoMethod EncryptionInfo
6940 raw := NoMethod(*s)
6941 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6942 }
6943
6944
6945 type EventTag struct {
6946
6947
6948 AccountId int64 `json:"accountId,omitempty,string"`
6949
6950
6951
6952 AdvertiserId int64 `json:"advertiserId,omitempty,string"`
6953
6954
6955
6956 AdvertiserIdDimensionValue *DimensionValue `json:"advertiserIdDimensionValue,omitempty"`
6957
6958
6959
6960 CampaignId int64 `json:"campaignId,omitempty,string"`
6961
6962
6963
6964 CampaignIdDimensionValue *DimensionValue `json:"campaignIdDimensionValue,omitempty"`
6965
6966
6967
6968 EnabledByDefault bool `json:"enabledByDefault,omitempty"`
6969
6970
6971
6972
6973
6974
6975 ExcludeFromAdxRequests bool `json:"excludeFromAdxRequests,omitempty"`
6976
6977
6978 Id int64 `json:"id,omitempty,string"`
6979
6980
6981
6982 Kind string `json:"kind,omitempty"`
6983
6984
6985
6986 Name string `json:"name,omitempty"`
6987
6988
6989
6990
6991
6992
6993
6994 SiteFilterType string `json:"siteFilterType,omitempty"`
6995
6996
6997
6998
6999 SiteIds googleapi.Int64s `json:"siteIds,omitempty"`
7000
7001
7002
7003 SslCompliant bool `json:"sslCompliant,omitempty"`
7004
7005
7006
7007
7008
7009
7010
7011 Status string `json:"status,omitempty"`
7012
7013
7014
7015 SubaccountId int64 `json:"subaccountId,omitempty,string"`
7016
7017
7018
7019
7020
7021
7022
7023
7024
7025
7026 Type string `json:"type,omitempty"`
7027
7028
7029
7030
7031 Url string `json:"url,omitempty"`
7032
7033
7034
7035
7036
7037 UrlEscapeLevels int64 `json:"urlEscapeLevels,omitempty"`
7038
7039
7040
7041 googleapi.ServerResponse `json:"-"`
7042
7043
7044
7045
7046
7047
7048
7049 ForceSendFields []string `json:"-"`
7050
7051
7052
7053
7054
7055
7056
7057 NullFields []string `json:"-"`
7058 }
7059
7060 func (s *EventTag) MarshalJSON() ([]byte, error) {
7061 type NoMethod EventTag
7062 raw := NoMethod(*s)
7063 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7064 }
7065
7066
7067 type EventTagOverride struct {
7068
7069 Enabled bool `json:"enabled,omitempty"`
7070
7071
7072
7073 Id int64 `json:"id,omitempty,string"`
7074
7075
7076
7077
7078
7079
7080
7081 ForceSendFields []string `json:"-"`
7082
7083
7084
7085
7086
7087
7088
7089 NullFields []string `json:"-"`
7090 }
7091
7092 func (s *EventTagOverride) MarshalJSON() ([]byte, error) {
7093 type NoMethod EventTagOverride
7094 raw := NoMethod(*s)
7095 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7096 }
7097
7098
7099 type EventTagsListResponse struct {
7100
7101 EventTags []*EventTag `json:"eventTags,omitempty"`
7102
7103
7104
7105 Kind string `json:"kind,omitempty"`
7106
7107
7108
7109 googleapi.ServerResponse `json:"-"`
7110
7111
7112
7113
7114
7115
7116
7117 ForceSendFields []string `json:"-"`
7118
7119
7120
7121
7122
7123
7124
7125 NullFields []string `json:"-"`
7126 }
7127
7128 func (s *EventTagsListResponse) MarshalJSON() ([]byte, error) {
7129 type NoMethod EventTagsListResponse
7130 raw := NoMethod(*s)
7131 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7132 }
7133
7134
7135
7136
7137
7138 type File struct {
7139
7140
7141
7142 DateRange *DateRange `json:"dateRange,omitempty"`
7143
7144
7145 Etag string `json:"etag,omitempty"`
7146
7147
7148 FileName string `json:"fileName,omitempty"`
7149
7150
7151
7152
7153
7154
7155
7156 Format string `json:"format,omitempty"`
7157
7158
7159 Id int64 `json:"id,omitempty,string"`
7160
7161
7162 Kind string `json:"kind,omitempty"`
7163
7164
7165
7166 LastModifiedTime int64 `json:"lastModifiedTime,omitempty,string"`
7167
7168
7169 ReportId int64 `json:"reportId,omitempty,string"`
7170
7171
7172
7173
7174
7175
7176
7177
7178 Status string `json:"status,omitempty"`
7179
7180
7181 Urls *FileUrls `json:"urls,omitempty"`
7182
7183
7184
7185 googleapi.ServerResponse `json:"-"`
7186
7187
7188
7189
7190
7191
7192
7193 ForceSendFields []string `json:"-"`
7194
7195
7196
7197
7198
7199
7200
7201 NullFields []string `json:"-"`
7202 }
7203
7204 func (s *File) MarshalJSON() ([]byte, error) {
7205 type NoMethod File
7206 raw := NoMethod(*s)
7207 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7208 }
7209
7210
7211 type FileUrls struct {
7212
7213 ApiUrl string `json:"apiUrl,omitempty"`
7214
7215
7216
7217 BrowserUrl string `json:"browserUrl,omitempty"`
7218
7219
7220
7221
7222
7223
7224
7225 ForceSendFields []string `json:"-"`
7226
7227
7228
7229
7230
7231
7232
7233 NullFields []string `json:"-"`
7234 }
7235
7236 func (s *FileUrls) MarshalJSON() ([]byte, error) {
7237 type NoMethod FileUrls
7238 raw := NoMethod(*s)
7239 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7240 }
7241
7242
7243 type FileList struct {
7244
7245 Etag string `json:"etag,omitempty"`
7246
7247
7248 Items []*File `json:"items,omitempty"`
7249
7250
7251 Kind string `json:"kind,omitempty"`
7252
7253
7254
7255
7256
7257 NextPageToken string `json:"nextPageToken,omitempty"`
7258
7259
7260
7261 googleapi.ServerResponse `json:"-"`
7262
7263
7264
7265
7266
7267
7268
7269 ForceSendFields []string `json:"-"`
7270
7271
7272
7273
7274
7275
7276
7277 NullFields []string `json:"-"`
7278 }
7279
7280 func (s *FileList) MarshalJSON() ([]byte, error) {
7281 type NoMethod FileList
7282 raw := NoMethod(*s)
7283 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7284 }
7285
7286
7287 type Flight struct {
7288
7289 EndDate string `json:"endDate,omitempty"`
7290
7291
7292 RateOrCost int64 `json:"rateOrCost,omitempty,string"`
7293
7294
7295 StartDate string `json:"startDate,omitempty"`
7296
7297
7298 Units int64 `json:"units,omitempty,string"`
7299
7300
7301
7302
7303
7304
7305
7306 ForceSendFields []string `json:"-"`
7307
7308
7309
7310
7311
7312
7313
7314 NullFields []string `json:"-"`
7315 }
7316
7317 func (s *Flight) MarshalJSON() ([]byte, error) {
7318 type NoMethod Flight
7319 raw := NoMethod(*s)
7320 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7321 }
7322
7323
7324
7325 type FloodlightActivitiesGenerateTagResponse struct {
7326
7327
7328 FloodlightActivityTag string `json:"floodlightActivityTag,omitempty"`
7329
7330
7331
7332
7333
7334 GlobalSiteTagGlobalSnippet string `json:"globalSiteTagGlobalSnippet,omitempty"`
7335
7336
7337
7338 Kind string `json:"kind,omitempty"`
7339
7340
7341
7342 googleapi.ServerResponse `json:"-"`
7343
7344
7345
7346
7347
7348
7349
7350
7351 ForceSendFields []string `json:"-"`
7352
7353
7354
7355
7356
7357
7358
7359
7360 NullFields []string `json:"-"`
7361 }
7362
7363 func (s *FloodlightActivitiesGenerateTagResponse) MarshalJSON() ([]byte, error) {
7364 type NoMethod FloodlightActivitiesGenerateTagResponse
7365 raw := NoMethod(*s)
7366 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7367 }
7368
7369
7370 type FloodlightActivitiesListResponse struct {
7371
7372 FloodlightActivities []*FloodlightActivity `json:"floodlightActivities,omitempty"`
7373
7374
7375
7376 Kind string `json:"kind,omitempty"`
7377
7378
7379
7380 NextPageToken string `json:"nextPageToken,omitempty"`
7381
7382
7383
7384 googleapi.ServerResponse `json:"-"`
7385
7386
7387
7388
7389
7390
7391
7392
7393 ForceSendFields []string `json:"-"`
7394
7395
7396
7397
7398
7399
7400
7401
7402 NullFields []string `json:"-"`
7403 }
7404
7405 func (s *FloodlightActivitiesListResponse) MarshalJSON() ([]byte, error) {
7406 type NoMethod FloodlightActivitiesListResponse
7407 raw := NoMethod(*s)
7408 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7409 }
7410
7411
7412 type FloodlightActivity struct {
7413
7414
7415 AccountId int64 `json:"accountId,omitempty,string"`
7416
7417
7418
7419
7420 AdvertiserId int64 `json:"advertiserId,omitempty,string"`
7421
7422
7423
7424 AdvertiserIdDimensionValue *DimensionValue `json:"advertiserIdDimensionValue,omitempty"`
7425
7426
7427
7428
7429
7430
7431
7432
7433
7434
7435
7436 CacheBustingType string `json:"cacheBustingType,omitempty"`
7437
7438
7439
7440
7441
7442
7443
7444
7445
7446
7447 CountingMethod string `json:"countingMethod,omitempty"`
7448
7449
7450 DefaultTags []*FloodlightActivityDynamicTag `json:"defaultTags,omitempty"`
7451
7452
7453
7454 ExpectedUrl string `json:"expectedUrl,omitempty"`
7455
7456
7457
7458 FloodlightActivityGroupId int64 `json:"floodlightActivityGroupId,omitempty,string"`
7459
7460
7461
7462 FloodlightActivityGroupName string `json:"floodlightActivityGroupName,omitempty"`
7463
7464
7465
7466 FloodlightActivityGroupTagString string `json:"floodlightActivityGroupTagString,omitempty"`
7467
7468
7469
7470
7471
7472
7473
7474 FloodlightActivityGroupType string `json:"floodlightActivityGroupType,omitempty"`
7475
7476
7477
7478
7479
7480 FloodlightConfigurationId int64 `json:"floodlightConfigurationId,omitempty,string"`
7481
7482
7483
7484
7485 FloodlightConfigurationIdDimensionValue *DimensionValue `json:"floodlightConfigurationIdDimensionValue,omitempty"`
7486
7487
7488
7489
7490
7491
7492
7493
7494 FloodlightTagType string `json:"floodlightTagType,omitempty"`
7495
7496
7497 Hidden bool `json:"hidden,omitempty"`
7498
7499
7500
7501 Id int64 `json:"id,omitempty,string"`
7502
7503
7504
7505 IdDimensionValue *DimensionValue `json:"idDimensionValue,omitempty"`
7506
7507
7508
7509 Kind string `json:"kind,omitempty"`
7510
7511
7512
7513 Name string `json:"name,omitempty"`
7514
7515
7516 Notes string `json:"notes,omitempty"`
7517
7518
7519 PublisherTags []*FloodlightActivityPublisherDynamicTag `json:"publisherTags,omitempty"`
7520
7521
7522 Secure bool `json:"secure,omitempty"`
7523
7524
7525
7526
7527 SslCompliant bool `json:"sslCompliant,omitempty"`
7528
7529
7530 SslRequired bool `json:"sslRequired,omitempty"`
7531
7532
7533
7534 SubaccountId int64 `json:"subaccountId,omitempty,string"`
7535
7536
7537
7538
7539
7540
7541
7542 TagFormat string `json:"tagFormat,omitempty"`
7543
7544
7545
7546
7547
7548
7549
7550
7551 TagString string `json:"tagString,omitempty"`
7552
7553
7554
7555
7556
7557
7558
7559
7560
7561
7562
7563
7564
7565
7566
7567
7568
7569
7570
7571
7572
7573
7574
7575
7576
7577
7578
7579
7580
7581
7582
7583
7584
7585
7586
7587
7588
7589
7590
7591
7592
7593
7594
7595
7596
7597
7598
7599
7600
7601
7602
7603
7604
7605
7606
7607
7608
7609
7610
7611
7612
7613
7614
7615
7616
7617
7618
7619
7620
7621
7622
7623
7624
7625
7626
7627
7628
7629
7630
7631
7632
7633
7634
7635
7636
7637
7638
7639
7640
7641
7642
7643
7644
7645
7646
7647
7648
7649
7650
7651
7652
7653
7654
7655
7656
7657
7658
7659 UserDefinedVariableTypes []string `json:"userDefinedVariableTypes,omitempty"`
7660
7661
7662
7663 googleapi.ServerResponse `json:"-"`
7664
7665
7666
7667
7668
7669
7670
7671 ForceSendFields []string `json:"-"`
7672
7673
7674
7675
7676
7677
7678
7679 NullFields []string `json:"-"`
7680 }
7681
7682 func (s *FloodlightActivity) MarshalJSON() ([]byte, error) {
7683 type NoMethod FloodlightActivity
7684 raw := NoMethod(*s)
7685 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7686 }
7687
7688
7689 type FloodlightActivityDynamicTag struct {
7690
7691
7692 Id int64 `json:"id,omitempty,string"`
7693
7694
7695 Name string `json:"name,omitempty"`
7696
7697
7698 Tag string `json:"tag,omitempty"`
7699
7700
7701
7702
7703
7704
7705
7706 ForceSendFields []string `json:"-"`
7707
7708
7709
7710
7711
7712
7713
7714 NullFields []string `json:"-"`
7715 }
7716
7717 func (s *FloodlightActivityDynamicTag) MarshalJSON() ([]byte, error) {
7718 type NoMethod FloodlightActivityDynamicTag
7719 raw := NoMethod(*s)
7720 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7721 }
7722
7723
7724
7725 type FloodlightActivityGroup struct {
7726
7727
7728 AccountId int64 `json:"accountId,omitempty,string"`
7729
7730
7731
7732
7733
7734 AdvertiserId int64 `json:"advertiserId,omitempty,string"`
7735
7736
7737
7738 AdvertiserIdDimensionValue *DimensionValue `json:"advertiserIdDimensionValue,omitempty"`
7739
7740
7741
7742 FloodlightConfigurationId int64 `json:"floodlightConfigurationId,omitempty,string"`
7743
7744
7745
7746
7747 FloodlightConfigurationIdDimensionValue *DimensionValue `json:"floodlightConfigurationIdDimensionValue,omitempty"`
7748
7749
7750
7751 Id int64 `json:"id,omitempty,string"`
7752
7753
7754
7755 IdDimensionValue *DimensionValue `json:"idDimensionValue,omitempty"`
7756
7757
7758
7759 Kind string `json:"kind,omitempty"`
7760
7761
7762
7763
7764 Name string `json:"name,omitempty"`
7765
7766
7767
7768 SubaccountId int64 `json:"subaccountId,omitempty,string"`
7769
7770
7771
7772
7773
7774
7775
7776
7777 TagString string `json:"tagString,omitempty"`
7778
7779
7780
7781
7782
7783
7784
7785 Type string `json:"type,omitempty"`
7786
7787
7788
7789 googleapi.ServerResponse `json:"-"`
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 *FloodlightActivityGroup) MarshalJSON() ([]byte, error) {
7809 type NoMethod FloodlightActivityGroup
7810 raw := NoMethod(*s)
7811 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7812 }
7813
7814
7815
7816 type FloodlightActivityGroupsListResponse struct {
7817
7818 FloodlightActivityGroups []*FloodlightActivityGroup `json:"floodlightActivityGroups,omitempty"`
7819
7820
7821
7822 Kind string `json:"kind,omitempty"`
7823
7824
7825
7826 NextPageToken string `json:"nextPageToken,omitempty"`
7827
7828
7829
7830 googleapi.ServerResponse `json:"-"`
7831
7832
7833
7834
7835
7836
7837
7838
7839 ForceSendFields []string `json:"-"`
7840
7841
7842
7843
7844
7845
7846
7847
7848 NullFields []string `json:"-"`
7849 }
7850
7851 func (s *FloodlightActivityGroupsListResponse) MarshalJSON() ([]byte, error) {
7852 type NoMethod FloodlightActivityGroupsListResponse
7853 raw := NoMethod(*s)
7854 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7855 }
7856
7857
7858 type FloodlightActivityPublisherDynamicTag struct {
7859
7860 ClickThrough bool `json:"clickThrough,omitempty"`
7861
7862
7863
7864
7865
7866 DirectorySiteId int64 `json:"directorySiteId,omitempty,string"`
7867
7868
7869 DynamicTag *FloodlightActivityDynamicTag `json:"dynamicTag,omitempty"`
7870
7871
7872 SiteId int64 `json:"siteId,omitempty,string"`
7873
7874
7875
7876 SiteIdDimensionValue *DimensionValue `json:"siteIdDimensionValue,omitempty"`
7877
7878
7879 ViewThrough bool `json:"viewThrough,omitempty"`
7880
7881
7882
7883
7884
7885
7886
7887 ForceSendFields []string `json:"-"`
7888
7889
7890
7891
7892
7893
7894
7895 NullFields []string `json:"-"`
7896 }
7897
7898 func (s *FloodlightActivityPublisherDynamicTag) MarshalJSON() ([]byte, error) {
7899 type NoMethod FloodlightActivityPublisherDynamicTag
7900 raw := NoMethod(*s)
7901 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7902 }
7903
7904
7905
7906 type FloodlightConfiguration struct {
7907
7908
7909 AccountId int64 `json:"accountId,omitempty,string"`
7910
7911
7912
7913 AdvertiserId int64 `json:"advertiserId,omitempty,string"`
7914
7915
7916
7917 AdvertiserIdDimensionValue *DimensionValue `json:"advertiserIdDimensionValue,omitempty"`
7918
7919
7920
7921 AnalyticsDataSharingEnabled bool `json:"analyticsDataSharingEnabled,omitempty"`
7922
7923
7924
7925
7926
7927 ExposureToConversionEnabled bool `json:"exposureToConversionEnabled,omitempty"`
7928
7929
7930
7931
7932
7933
7934
7935 FirstDayOfWeek string `json:"firstDayOfWeek,omitempty"`
7936
7937
7938
7939 Id int64 `json:"id,omitempty,string"`
7940
7941
7942
7943 IdDimensionValue *DimensionValue `json:"idDimensionValue,omitempty"`
7944
7945
7946
7947 InAppAttributionTrackingEnabled bool `json:"inAppAttributionTrackingEnabled,omitempty"`
7948
7949
7950
7951 Kind string `json:"kind,omitempty"`
7952
7953
7954
7955 LookbackConfiguration *LookbackConfiguration `json:"lookbackConfiguration,omitempty"`
7956
7957
7958
7959
7960
7961
7962
7963
7964 NaturalSearchConversionAttributionOption string `json:"naturalSearchConversionAttributionOption,omitempty"`
7965
7966
7967 OmnitureSettings *OmnitureSettings `json:"omnitureSettings,omitempty"`
7968
7969
7970
7971 SubaccountId int64 `json:"subaccountId,omitempty,string"`
7972
7973
7974
7975 TagSettings *TagSettings `json:"tagSettings,omitempty"`
7976
7977
7978
7979 ThirdPartyAuthenticationTokens []*ThirdPartyAuthenticationToken `json:"thirdPartyAuthenticationTokens,omitempty"`
7980
7981
7982
7983 UserDefinedVariableConfigurations []*UserDefinedVariableConfiguration `json:"userDefinedVariableConfigurations,omitempty"`
7984
7985
7986
7987 googleapi.ServerResponse `json:"-"`
7988
7989
7990
7991
7992
7993
7994
7995 ForceSendFields []string `json:"-"`
7996
7997
7998
7999
8000
8001
8002
8003 NullFields []string `json:"-"`
8004 }
8005
8006 func (s *FloodlightConfiguration) MarshalJSON() ([]byte, error) {
8007 type NoMethod FloodlightConfiguration
8008 raw := NoMethod(*s)
8009 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8010 }
8011
8012
8013
8014 type FloodlightConfigurationsListResponse struct {
8015
8016 FloodlightConfigurations []*FloodlightConfiguration `json:"floodlightConfigurations,omitempty"`
8017
8018
8019
8020 Kind string `json:"kind,omitempty"`
8021
8022
8023
8024 googleapi.ServerResponse `json:"-"`
8025
8026
8027
8028
8029
8030
8031
8032
8033 ForceSendFields []string `json:"-"`
8034
8035
8036
8037
8038
8039
8040
8041
8042 NullFields []string `json:"-"`
8043 }
8044
8045 func (s *FloodlightConfigurationsListResponse) MarshalJSON() ([]byte, error) {
8046 type NoMethod FloodlightConfigurationsListResponse
8047 raw := NoMethod(*s)
8048 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8049 }
8050
8051
8052
8053 type FloodlightReportCompatibleFields struct {
8054
8055
8056 DimensionFilters []*Dimension `json:"dimensionFilters,omitempty"`
8057
8058
8059
8060 Dimensions []*Dimension `json:"dimensions,omitempty"`
8061
8062
8063
8064 Kind string `json:"kind,omitempty"`
8065
8066
8067
8068 Metrics []*Metric `json:"metrics,omitempty"`
8069
8070
8071
8072
8073
8074
8075
8076 ForceSendFields []string `json:"-"`
8077
8078
8079
8080
8081
8082
8083
8084
8085 NullFields []string `json:"-"`
8086 }
8087
8088 func (s *FloodlightReportCompatibleFields) MarshalJSON() ([]byte, error) {
8089 type NoMethod FloodlightReportCompatibleFields
8090 raw := NoMethod(*s)
8091 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8092 }
8093
8094
8095 type FrequencyCap struct {
8096
8097
8098
8099 Duration int64 `json:"duration,omitempty,string"`
8100
8101
8102
8103
8104 Impressions int64 `json:"impressions,omitempty,string"`
8105
8106
8107
8108
8109
8110
8111
8112 ForceSendFields []string `json:"-"`
8113
8114
8115
8116
8117
8118
8119
8120 NullFields []string `json:"-"`
8121 }
8122
8123 func (s *FrequencyCap) MarshalJSON() ([]byte, error) {
8124 type NoMethod FrequencyCap
8125 raw := NoMethod(*s)
8126 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8127 }
8128
8129
8130 type FsCommand struct {
8131
8132
8133 Left int64 `json:"left,omitempty"`
8134
8135
8136
8137
8138
8139
8140 PositionOption string `json:"positionOption,omitempty"`
8141
8142
8143
8144 Top int64 `json:"top,omitempty"`
8145
8146
8147 WindowHeight int64 `json:"windowHeight,omitempty"`
8148
8149
8150 WindowWidth int64 `json:"windowWidth,omitempty"`
8151
8152
8153
8154
8155
8156
8157
8158 ForceSendFields []string `json:"-"`
8159
8160
8161
8162
8163
8164
8165
8166 NullFields []string `json:"-"`
8167 }
8168
8169 func (s *FsCommand) MarshalJSON() ([]byte, error) {
8170 type NoMethod FsCommand
8171 raw := NoMethod(*s)
8172 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8173 }
8174
8175
8176 type GeoTargeting struct {
8177
8178
8179
8180
8181 Cities []*City `json:"cities,omitempty"`
8182
8183
8184
8185
8186
8187
8188
8189 Countries []*Country `json:"countries,omitempty"`
8190
8191
8192
8193
8194 ExcludeCountries bool `json:"excludeCountries,omitempty"`
8195
8196
8197
8198
8199
8200 Metros []*Metro `json:"metros,omitempty"`
8201
8202
8203
8204
8205
8206 PostalCodes []*PostalCode `json:"postalCodes,omitempty"`
8207
8208
8209
8210
8211
8212 Regions []*Region `json:"regions,omitempty"`
8213
8214
8215
8216
8217
8218
8219
8220 ForceSendFields []string `json:"-"`
8221
8222
8223
8224
8225
8226
8227
8228 NullFields []string `json:"-"`
8229 }
8230
8231 func (s *GeoTargeting) MarshalJSON() ([]byte, error) {
8232 type NoMethod GeoTargeting
8233 raw := NoMethod(*s)
8234 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8235 }
8236
8237
8238 type InventoryItem struct {
8239
8240 AccountId int64 `json:"accountId,omitempty,string"`
8241
8242
8243
8244
8245
8246
8247 AdSlots []*AdSlot `json:"adSlots,omitempty"`
8248
8249
8250 AdvertiserId int64 `json:"advertiserId,omitempty,string"`
8251
8252
8253 ContentCategoryId int64 `json:"contentCategoryId,omitempty,string"`
8254
8255
8256
8257 EstimatedClickThroughRate int64 `json:"estimatedClickThroughRate,omitempty,string"`
8258
8259
8260
8261 EstimatedConversionRate int64 `json:"estimatedConversionRate,omitempty,string"`
8262
8263
8264 Id int64 `json:"id,omitempty,string"`
8265
8266
8267 InPlan bool `json:"inPlan,omitempty"`
8268
8269
8270
8271 Kind string `json:"kind,omitempty"`
8272
8273
8274
8275 LastModifiedInfo *LastModifiedInfo `json:"lastModifiedInfo,omitempty"`
8276
8277
8278
8279
8280
8281 Name string `json:"name,omitempty"`
8282
8283
8284 NegotiationChannelId int64 `json:"negotiationChannelId,omitempty,string"`
8285
8286
8287 OrderId int64 `json:"orderId,omitempty,string"`
8288
8289
8290 PlacementStrategyId int64 `json:"placementStrategyId,omitempty,string"`
8291
8292
8293 Pricing *Pricing `json:"pricing,omitempty"`
8294
8295
8296 ProjectId int64 `json:"projectId,omitempty,string"`
8297
8298
8299 RfpId int64 `json:"rfpId,omitempty,string"`
8300
8301
8302 SiteId int64 `json:"siteId,omitempty,string"`
8303
8304
8305 SubaccountId int64 `json:"subaccountId,omitempty,string"`
8306
8307
8308
8309
8310
8311
8312 Type string `json:"type,omitempty"`
8313
8314
8315
8316 googleapi.ServerResponse `json:"-"`
8317
8318
8319
8320
8321
8322
8323
8324 ForceSendFields []string `json:"-"`
8325
8326
8327
8328
8329
8330
8331
8332 NullFields []string `json:"-"`
8333 }
8334
8335 func (s *InventoryItem) MarshalJSON() ([]byte, error) {
8336 type NoMethod InventoryItem
8337 raw := NoMethod(*s)
8338 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8339 }
8340
8341
8342 type InventoryItemsListResponse struct {
8343
8344 InventoryItems []*InventoryItem `json:"inventoryItems,omitempty"`
8345
8346
8347
8348 Kind string `json:"kind,omitempty"`
8349
8350
8351
8352 NextPageToken string `json:"nextPageToken,omitempty"`
8353
8354
8355
8356 googleapi.ServerResponse `json:"-"`
8357
8358
8359
8360
8361
8362
8363
8364 ForceSendFields []string `json:"-"`
8365
8366
8367
8368
8369
8370
8371
8372
8373 NullFields []string `json:"-"`
8374 }
8375
8376 func (s *InventoryItemsListResponse) MarshalJSON() ([]byte, error) {
8377 type NoMethod InventoryItemsListResponse
8378 raw := NoMethod(*s)
8379 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8380 }
8381
8382
8383 type KeyValueTargetingExpression struct {
8384
8385 Expression string `json:"expression,omitempty"`
8386
8387
8388
8389
8390
8391
8392
8393 ForceSendFields []string `json:"-"`
8394
8395
8396
8397
8398
8399
8400
8401 NullFields []string `json:"-"`
8402 }
8403
8404 func (s *KeyValueTargetingExpression) MarshalJSON() ([]byte, error) {
8405 type NoMethod KeyValueTargetingExpression
8406 raw := NoMethod(*s)
8407 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8408 }
8409
8410
8411
8412 type LandingPage struct {
8413
8414
8415 AdvertiserId int64 `json:"advertiserId,omitempty,string"`
8416
8417
8418 Archived bool `json:"archived,omitempty"`
8419
8420
8421
8422 Id int64 `json:"id,omitempty,string"`
8423
8424
8425
8426 Kind string `json:"kind,omitempty"`
8427
8428
8429
8430 Name string `json:"name,omitempty"`
8431
8432
8433 Url string `json:"url,omitempty"`
8434
8435
8436
8437 googleapi.ServerResponse `json:"-"`
8438
8439
8440
8441
8442
8443
8444
8445 ForceSendFields []string `json:"-"`
8446
8447
8448
8449
8450
8451
8452
8453 NullFields []string `json:"-"`
8454 }
8455
8456 func (s *LandingPage) MarshalJSON() ([]byte, error) {
8457 type NoMethod LandingPage
8458 raw := NoMethod(*s)
8459 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8460 }
8461
8462
8463
8464 type Language struct {
8465
8466
8467 Id int64 `json:"id,omitempty,string"`
8468
8469
8470
8471 Kind string `json:"kind,omitempty"`
8472
8473
8474
8475
8476
8477 LanguageCode string `json:"languageCode,omitempty"`
8478
8479
8480 Name string `json:"name,omitempty"`
8481
8482
8483
8484
8485
8486
8487
8488 ForceSendFields []string `json:"-"`
8489
8490
8491
8492
8493
8494
8495
8496 NullFields []string `json:"-"`
8497 }
8498
8499 func (s *Language) MarshalJSON() ([]byte, error) {
8500 type NoMethod Language
8501 raw := NoMethod(*s)
8502 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8503 }
8504
8505
8506 type LanguageTargeting struct {
8507
8508
8509
8510 Languages []*Language `json:"languages,omitempty"`
8511
8512
8513
8514
8515
8516
8517
8518 ForceSendFields []string `json:"-"`
8519
8520
8521
8522
8523
8524
8525
8526 NullFields []string `json:"-"`
8527 }
8528
8529 func (s *LanguageTargeting) MarshalJSON() ([]byte, error) {
8530 type NoMethod LanguageTargeting
8531 raw := NoMethod(*s)
8532 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8533 }
8534
8535
8536 type LanguagesListResponse struct {
8537
8538
8539 Kind string `json:"kind,omitempty"`
8540
8541
8542 Languages []*Language `json:"languages,omitempty"`
8543
8544
8545
8546 googleapi.ServerResponse `json:"-"`
8547
8548
8549
8550
8551
8552
8553
8554 ForceSendFields []string `json:"-"`
8555
8556
8557
8558
8559
8560
8561
8562 NullFields []string `json:"-"`
8563 }
8564
8565 func (s *LanguagesListResponse) MarshalJSON() ([]byte, error) {
8566 type NoMethod LanguagesListResponse
8567 raw := NoMethod(*s)
8568 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8569 }
8570
8571
8572 type LastModifiedInfo struct {
8573
8574 Time int64 `json:"time,omitempty,string"`
8575
8576
8577
8578
8579
8580
8581
8582 ForceSendFields []string `json:"-"`
8583
8584
8585
8586
8587
8588
8589
8590 NullFields []string `json:"-"`
8591 }
8592
8593 func (s *LastModifiedInfo) MarshalJSON() ([]byte, error) {
8594 type NoMethod LastModifiedInfo
8595 raw := NoMethod(*s)
8596 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8597 }
8598
8599
8600
8601 type ListPopulationClause struct {
8602
8603
8604
8605 Terms []*ListPopulationTerm `json:"terms,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 *ListPopulationClause) MarshalJSON() ([]byte, error) {
8625 type NoMethod ListPopulationClause
8626 raw := NoMethod(*s)
8627 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8628 }
8629
8630
8631 type ListPopulationRule struct {
8632
8633
8634 FloodlightActivityId int64 `json:"floodlightActivityId,omitempty,string"`
8635
8636
8637
8638 FloodlightActivityName string `json:"floodlightActivityName,omitempty"`
8639
8640
8641
8642
8643 ListPopulationClauses []*ListPopulationClause `json:"listPopulationClauses,omitempty"`
8644
8645
8646
8647
8648
8649
8650
8651
8652 ForceSendFields []string `json:"-"`
8653
8654
8655
8656
8657
8658
8659
8660
8661 NullFields []string `json:"-"`
8662 }
8663
8664 func (s *ListPopulationRule) MarshalJSON() ([]byte, error) {
8665 type NoMethod ListPopulationRule
8666 raw := NoMethod(*s)
8667 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8668 }
8669
8670
8671 type ListPopulationTerm struct {
8672
8673
8674
8675
8676 Contains bool `json:"contains,omitempty"`
8677
8678
8679
8680
8681 Negation bool `json:"negation,omitempty"`
8682
8683
8684
8685
8686
8687
8688
8689
8690
8691
8692
8693
8694
8695 Operator string `json:"operator,omitempty"`
8696
8697
8698
8699 RemarketingListId int64 `json:"remarketingListId,omitempty,string"`
8700
8701
8702
8703
8704
8705
8706
8707
8708
8709
8710
8711
8712 Type string `json:"type,omitempty"`
8713
8714
8715
8716
8717 Value string `json:"value,omitempty"`
8718
8719
8720
8721
8722 VariableFriendlyName string `json:"variableFriendlyName,omitempty"`
8723
8724
8725
8726
8727 VariableName string `json:"variableName,omitempty"`
8728
8729
8730
8731
8732
8733
8734
8735 ForceSendFields []string `json:"-"`
8736
8737
8738
8739
8740
8741
8742
8743 NullFields []string `json:"-"`
8744 }
8745
8746 func (s *ListPopulationTerm) MarshalJSON() ([]byte, error) {
8747 type NoMethod ListPopulationTerm
8748 raw := NoMethod(*s)
8749 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8750 }
8751
8752
8753 type ListTargetingExpression struct {
8754
8755
8756 Expression string `json:"expression,omitempty"`
8757
8758
8759
8760
8761
8762
8763
8764 ForceSendFields []string `json:"-"`
8765
8766
8767
8768
8769
8770
8771
8772 NullFields []string `json:"-"`
8773 }
8774
8775 func (s *ListTargetingExpression) MarshalJSON() ([]byte, error) {
8776 type NoMethod ListTargetingExpression
8777 raw := NoMethod(*s)
8778 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8779 }
8780
8781
8782 type LookbackConfiguration struct {
8783
8784
8785
8786
8787
8788 ClickDuration int64 `json:"clickDuration,omitempty"`
8789
8790
8791
8792
8793
8794
8795
8796 PostImpressionActivitiesDuration int64 `json:"postImpressionActivitiesDuration,omitempty"`
8797
8798
8799
8800
8801
8802
8803
8804 ForceSendFields []string `json:"-"`
8805
8806
8807
8808
8809
8810
8811
8812 NullFields []string `json:"-"`
8813 }
8814
8815 func (s *LookbackConfiguration) MarshalJSON() ([]byte, error) {
8816 type NoMethod LookbackConfiguration
8817 raw := NoMethod(*s)
8818 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8819 }
8820
8821
8822 type Metric struct {
8823
8824 Kind string `json:"kind,omitempty"`
8825
8826
8827 Name string `json:"name,omitempty"`
8828
8829
8830
8831
8832
8833
8834
8835 ForceSendFields []string `json:"-"`
8836
8837
8838
8839
8840
8841
8842
8843 NullFields []string `json:"-"`
8844 }
8845
8846 func (s *Metric) MarshalJSON() ([]byte, error) {
8847 type NoMethod Metric
8848 raw := NoMethod(*s)
8849 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8850 }
8851
8852
8853
8854 type Metro struct {
8855
8856
8857 CountryCode string `json:"countryCode,omitempty"`
8858
8859
8860
8861 CountryDartId int64 `json:"countryDartId,omitempty,string"`
8862
8863
8864 DartId int64 `json:"dartId,omitempty,string"`
8865
8866
8867
8868 DmaId int64 `json:"dmaId,omitempty,string"`
8869
8870
8871
8872 Kind string `json:"kind,omitempty"`
8873
8874
8875
8876 MetroCode string `json:"metroCode,omitempty"`
8877
8878
8879 Name string `json:"name,omitempty"`
8880
8881
8882
8883
8884
8885
8886
8887 ForceSendFields []string `json:"-"`
8888
8889
8890
8891
8892
8893
8894
8895 NullFields []string `json:"-"`
8896 }
8897
8898 func (s *Metro) MarshalJSON() ([]byte, error) {
8899 type NoMethod Metro
8900 raw := NoMethod(*s)
8901 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8902 }
8903
8904
8905 type MetrosListResponse struct {
8906
8907
8908 Kind string `json:"kind,omitempty"`
8909
8910
8911 Metros []*Metro `json:"metros,omitempty"`
8912
8913
8914
8915 googleapi.ServerResponse `json:"-"`
8916
8917
8918
8919
8920
8921
8922
8923 ForceSendFields []string `json:"-"`
8924
8925
8926
8927
8928
8929
8930
8931 NullFields []string `json:"-"`
8932 }
8933
8934 func (s *MetrosListResponse) MarshalJSON() ([]byte, error) {
8935 type NoMethod MetrosListResponse
8936 raw := NoMethod(*s)
8937 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8938 }
8939
8940
8941
8942 type MobileCarrier struct {
8943
8944
8945 CountryCode string `json:"countryCode,omitempty"`
8946
8947
8948
8949 CountryDartId int64 `json:"countryDartId,omitempty,string"`
8950
8951
8952 Id int64 `json:"id,omitempty,string"`
8953
8954
8955
8956 Kind string `json:"kind,omitempty"`
8957
8958
8959 Name string `json:"name,omitempty"`
8960
8961
8962
8963 googleapi.ServerResponse `json:"-"`
8964
8965
8966
8967
8968
8969
8970
8971 ForceSendFields []string `json:"-"`
8972
8973
8974
8975
8976
8977
8978
8979 NullFields []string `json:"-"`
8980 }
8981
8982 func (s *MobileCarrier) MarshalJSON() ([]byte, error) {
8983 type NoMethod MobileCarrier
8984 raw := NoMethod(*s)
8985 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8986 }
8987
8988
8989 type MobileCarriersListResponse struct {
8990
8991
8992 Kind string `json:"kind,omitempty"`
8993
8994
8995 MobileCarriers []*MobileCarrier `json:"mobileCarriers,omitempty"`
8996
8997
8998
8999 googleapi.ServerResponse `json:"-"`
9000
9001
9002
9003
9004
9005
9006
9007 ForceSendFields []string `json:"-"`
9008
9009
9010
9011
9012
9013
9014
9015 NullFields []string `json:"-"`
9016 }
9017
9018 func (s *MobileCarriersListResponse) MarshalJSON() ([]byte, error) {
9019 type NoMethod MobileCarriersListResponse
9020 raw := NoMethod(*s)
9021 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9022 }
9023
9024
9025 type ObjectFilter struct {
9026
9027
9028 Kind string `json:"kind,omitempty"`
9029
9030
9031
9032 ObjectIds googleapi.Int64s `json:"objectIds,omitempty"`
9033
9034
9035
9036
9037
9038
9039
9040
9041
9042
9043 Status string `json:"status,omitempty"`
9044
9045
9046
9047
9048
9049
9050
9051 ForceSendFields []string `json:"-"`
9052
9053
9054
9055
9056
9057
9058
9059 NullFields []string `json:"-"`
9060 }
9061
9062 func (s *ObjectFilter) MarshalJSON() ([]byte, error) {
9063 type NoMethod ObjectFilter
9064 raw := NoMethod(*s)
9065 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9066 }
9067
9068
9069 type OffsetPosition struct {
9070
9071 Left int64 `json:"left,omitempty"`
9072
9073
9074 Top int64 `json:"top,omitempty"`
9075
9076
9077
9078
9079
9080
9081
9082 ForceSendFields []string `json:"-"`
9083
9084
9085
9086
9087
9088
9089
9090 NullFields []string `json:"-"`
9091 }
9092
9093 func (s *OffsetPosition) MarshalJSON() ([]byte, error) {
9094 type NoMethod OffsetPosition
9095 raw := NoMethod(*s)
9096 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9097 }
9098
9099
9100 type OmnitureSettings struct {
9101
9102
9103
9104 OmnitureCostDataEnabled bool `json:"omnitureCostDataEnabled,omitempty"`
9105
9106
9107
9108
9109 OmnitureIntegrationEnabled bool `json:"omnitureIntegrationEnabled,omitempty"`
9110
9111
9112
9113
9114
9115
9116
9117
9118 ForceSendFields []string `json:"-"`
9119
9120
9121
9122
9123
9124
9125
9126
9127 NullFields []string `json:"-"`
9128 }
9129
9130 func (s *OmnitureSettings) MarshalJSON() ([]byte, error) {
9131 type NoMethod OmnitureSettings
9132 raw := NoMethod(*s)
9133 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9134 }
9135
9136
9137
9138 type OperatingSystem struct {
9139
9140
9141 DartId int64 `json:"dartId,omitempty,string"`
9142
9143
9144 Desktop bool `json:"desktop,omitempty"`
9145
9146
9147
9148 Kind string `json:"kind,omitempty"`
9149
9150
9151 Mobile bool `json:"mobile,omitempty"`
9152
9153
9154 Name string `json:"name,omitempty"`
9155
9156
9157
9158 googleapi.ServerResponse `json:"-"`
9159
9160
9161
9162
9163
9164
9165
9166 ForceSendFields []string `json:"-"`
9167
9168
9169
9170
9171
9172
9173
9174 NullFields []string `json:"-"`
9175 }
9176
9177 func (s *OperatingSystem) MarshalJSON() ([]byte, error) {
9178 type NoMethod OperatingSystem
9179 raw := NoMethod(*s)
9180 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9181 }
9182
9183
9184
9185 type OperatingSystemVersion struct {
9186
9187 Id int64 `json:"id,omitempty,string"`
9188
9189
9190
9191 Kind string `json:"kind,omitempty"`
9192
9193
9194
9195 MajorVersion string `json:"majorVersion,omitempty"`
9196
9197
9198
9199 MinorVersion string `json:"minorVersion,omitempty"`
9200
9201
9202 Name string `json:"name,omitempty"`
9203
9204
9205 OperatingSystem *OperatingSystem `json:"operatingSystem,omitempty"`
9206
9207
9208
9209 googleapi.ServerResponse `json:"-"`
9210
9211
9212
9213
9214
9215
9216
9217 ForceSendFields []string `json:"-"`
9218
9219
9220
9221
9222
9223
9224
9225 NullFields []string `json:"-"`
9226 }
9227
9228 func (s *OperatingSystemVersion) MarshalJSON() ([]byte, error) {
9229 type NoMethod OperatingSystemVersion
9230 raw := NoMethod(*s)
9231 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9232 }
9233
9234
9235
9236 type OperatingSystemVersionsListResponse struct {
9237
9238
9239 Kind string `json:"kind,omitempty"`
9240
9241
9242 OperatingSystemVersions []*OperatingSystemVersion `json:"operatingSystemVersions,omitempty"`
9243
9244
9245
9246 googleapi.ServerResponse `json:"-"`
9247
9248
9249
9250
9251
9252
9253
9254 ForceSendFields []string `json:"-"`
9255
9256
9257
9258
9259
9260
9261
9262 NullFields []string `json:"-"`
9263 }
9264
9265 func (s *OperatingSystemVersionsListResponse) MarshalJSON() ([]byte, error) {
9266 type NoMethod OperatingSystemVersionsListResponse
9267 raw := NoMethod(*s)
9268 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9269 }
9270
9271
9272 type OperatingSystemsListResponse struct {
9273
9274
9275 Kind string `json:"kind,omitempty"`
9276
9277
9278 OperatingSystems []*OperatingSystem `json:"operatingSystems,omitempty"`
9279
9280
9281
9282 googleapi.ServerResponse `json:"-"`
9283
9284
9285
9286
9287
9288
9289
9290 ForceSendFields []string `json:"-"`
9291
9292
9293
9294
9295
9296
9297
9298 NullFields []string `json:"-"`
9299 }
9300
9301 func (s *OperatingSystemsListResponse) MarshalJSON() ([]byte, error) {
9302 type NoMethod OperatingSystemsListResponse
9303 raw := NoMethod(*s)
9304 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9305 }
9306
9307
9308 type OptimizationActivity struct {
9309
9310
9311 FloodlightActivityId int64 `json:"floodlightActivityId,omitempty,string"`
9312
9313
9314
9315 FloodlightActivityIdDimensionValue *DimensionValue `json:"floodlightActivityIdDimensionValue,omitempty"`
9316
9317
9318
9319
9320 Weight int64 `json:"weight,omitempty"`
9321
9322
9323
9324
9325
9326
9327
9328
9329 ForceSendFields []string `json:"-"`
9330
9331
9332
9333
9334
9335
9336
9337
9338 NullFields []string `json:"-"`
9339 }
9340
9341 func (s *OptimizationActivity) MarshalJSON() ([]byte, error) {
9342 type NoMethod OptimizationActivity
9343 raw := NoMethod(*s)
9344 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9345 }
9346
9347
9348 type Order struct {
9349
9350 AccountId int64 `json:"accountId,omitempty,string"`
9351
9352
9353 AdvertiserId int64 `json:"advertiserId,omitempty,string"`
9354
9355
9356
9357 ApproverUserProfileIds googleapi.Int64s `json:"approverUserProfileIds,omitempty"`
9358
9359
9360 BuyerInvoiceId string `json:"buyerInvoiceId,omitempty"`
9361
9362
9363 BuyerOrganizationName string `json:"buyerOrganizationName,omitempty"`
9364
9365
9366 Comments string `json:"comments,omitempty"`
9367
9368
9369 Contacts []*OrderContact `json:"contacts,omitempty"`
9370
9371
9372 Id int64 `json:"id,omitempty,string"`
9373
9374
9375
9376 Kind string `json:"kind,omitempty"`
9377
9378
9379
9380 LastModifiedInfo *LastModifiedInfo `json:"lastModifiedInfo,omitempty"`
9381
9382
9383 Name string `json:"name,omitempty"`
9384
9385
9386 Notes string `json:"notes,omitempty"`
9387
9388
9389
9390 PlanningTermId int64 `json:"planningTermId,omitempty,string"`
9391
9392
9393 ProjectId int64 `json:"projectId,omitempty,string"`
9394
9395
9396 SellerOrderId string `json:"sellerOrderId,omitempty"`
9397
9398
9399 SellerOrganizationName string `json:"sellerOrganizationName,omitempty"`
9400
9401
9402 SiteId googleapi.Int64s `json:"siteId,omitempty"`
9403
9404
9405 SiteNames []string `json:"siteNames,omitempty"`
9406
9407
9408 SubaccountId int64 `json:"subaccountId,omitempty,string"`
9409
9410
9411 TermsAndConditions string `json:"termsAndConditions,omitempty"`
9412
9413
9414
9415 googleapi.ServerResponse `json:"-"`
9416
9417
9418
9419
9420
9421
9422
9423 ForceSendFields []string `json:"-"`
9424
9425
9426
9427
9428
9429
9430
9431 NullFields []string `json:"-"`
9432 }
9433
9434 func (s *Order) MarshalJSON() ([]byte, error) {
9435 type NoMethod Order
9436 raw := NoMethod(*s)
9437 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9438 }
9439
9440
9441 type OrderContact struct {
9442
9443
9444
9445 ContactInfo string `json:"contactInfo,omitempty"`
9446
9447
9448 ContactName string `json:"contactName,omitempty"`
9449
9450
9451 ContactTitle string `json:"contactTitle,omitempty"`
9452
9453
9454
9455
9456
9457
9458
9459 ContactType string `json:"contactType,omitempty"`
9460
9461
9462
9463 SignatureUserProfileId int64 `json:"signatureUserProfileId,omitempty,string"`
9464
9465
9466
9467
9468
9469
9470
9471 ForceSendFields []string `json:"-"`
9472
9473
9474
9475
9476
9477
9478
9479 NullFields []string `json:"-"`
9480 }
9481
9482 func (s *OrderContact) MarshalJSON() ([]byte, error) {
9483 type NoMethod OrderContact
9484 raw := NoMethod(*s)
9485 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9486 }
9487
9488
9489 type OrderDocument struct {
9490
9491 AccountId int64 `json:"accountId,omitempty,string"`
9492
9493
9494 AdvertiserId int64 `json:"advertiserId,omitempty,string"`
9495
9496
9497
9498
9499 AmendedOrderDocumentId int64 `json:"amendedOrderDocumentId,omitempty,string"`
9500
9501
9502
9503 ApprovedByUserProfileIds googleapi.Int64s `json:"approvedByUserProfileIds,omitempty"`
9504
9505
9506 Cancelled bool `json:"cancelled,omitempty"`
9507
9508
9509 CreatedInfo *LastModifiedInfo `json:"createdInfo,omitempty"`
9510
9511
9512 EffectiveDate string `json:"effectiveDate,omitempty"`
9513
9514
9515 Id int64 `json:"id,omitempty,string"`
9516
9517
9518
9519 Kind string `json:"kind,omitempty"`
9520
9521
9522
9523 LastSentRecipients []string `json:"lastSentRecipients,omitempty"`
9524
9525
9526
9527 LastSentTime string `json:"lastSentTime,omitempty"`
9528
9529
9530 OrderId int64 `json:"orderId,omitempty,string"`
9531
9532
9533 ProjectId int64 `json:"projectId,omitempty,string"`
9534
9535
9536 Signed bool `json:"signed,omitempty"`
9537
9538
9539 SubaccountId int64 `json:"subaccountId,omitempty,string"`
9540
9541
9542 Title string `json:"title,omitempty"`
9543
9544
9545
9546
9547
9548
9549 Type string `json:"type,omitempty"`
9550
9551
9552
9553 googleapi.ServerResponse `json:"-"`
9554
9555
9556
9557
9558
9559
9560
9561 ForceSendFields []string `json:"-"`
9562
9563
9564
9565
9566
9567
9568
9569 NullFields []string `json:"-"`
9570 }
9571
9572 func (s *OrderDocument) MarshalJSON() ([]byte, error) {
9573 type NoMethod OrderDocument
9574 raw := NoMethod(*s)
9575 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9576 }
9577
9578
9579 type OrderDocumentsListResponse struct {
9580
9581
9582 Kind string `json:"kind,omitempty"`
9583
9584
9585
9586 NextPageToken string `json:"nextPageToken,omitempty"`
9587
9588
9589 OrderDocuments []*OrderDocument `json:"orderDocuments,omitempty"`
9590
9591
9592
9593 googleapi.ServerResponse `json:"-"`
9594
9595
9596
9597
9598
9599
9600
9601 ForceSendFields []string `json:"-"`
9602
9603
9604
9605
9606
9607
9608
9609 NullFields []string `json:"-"`
9610 }
9611
9612 func (s *OrderDocumentsListResponse) MarshalJSON() ([]byte, error) {
9613 type NoMethod OrderDocumentsListResponse
9614 raw := NoMethod(*s)
9615 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9616 }
9617
9618
9619 type OrdersListResponse struct {
9620
9621
9622 Kind string `json:"kind,omitempty"`
9623
9624
9625
9626 NextPageToken string `json:"nextPageToken,omitempty"`
9627
9628
9629 Orders []*Order `json:"orders,omitempty"`
9630
9631
9632
9633 googleapi.ServerResponse `json:"-"`
9634
9635
9636
9637
9638
9639
9640
9641 ForceSendFields []string `json:"-"`
9642
9643
9644
9645
9646
9647
9648
9649 NullFields []string `json:"-"`
9650 }
9651
9652 func (s *OrdersListResponse) MarshalJSON() ([]byte, error) {
9653 type NoMethod OrdersListResponse
9654 raw := NoMethod(*s)
9655 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9656 }
9657
9658
9659
9660 type PathToConversionReportCompatibleFields struct {
9661
9662
9663 ConversionDimensions []*Dimension `json:"conversionDimensions,omitempty"`
9664
9665
9666
9667
9668 CustomFloodlightVariables []*Dimension `json:"customFloodlightVariables,omitempty"`
9669
9670
9671
9672 Kind string `json:"kind,omitempty"`
9673
9674
9675
9676 Metrics []*Metric `json:"metrics,omitempty"`
9677
9678
9679
9680
9681 PerInteractionDimensions []*Dimension `json:"perInteractionDimensions,omitempty"`
9682
9683
9684
9685
9686
9687
9688
9689
9690 ForceSendFields []string `json:"-"`
9691
9692
9693
9694
9695
9696
9697
9698
9699 NullFields []string `json:"-"`
9700 }
9701
9702 func (s *PathToConversionReportCompatibleFields) MarshalJSON() ([]byte, error) {
9703 type NoMethod PathToConversionReportCompatibleFields
9704 raw := NoMethod(*s)
9705 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9706 }
9707
9708
9709 type Placement struct {
9710
9711
9712 AccountId int64 `json:"accountId,omitempty,string"`
9713
9714
9715
9716
9717 AdBlockingOptOut bool `json:"adBlockingOptOut,omitempty"`
9718
9719
9720
9721 AdvertiserId int64 `json:"advertiserId,omitempty,string"`
9722
9723
9724
9725 AdvertiserIdDimensionValue *DimensionValue `json:"advertiserIdDimensionValue,omitempty"`
9726
9727
9728 Archived bool `json:"archived,omitempty"`
9729
9730
9731
9732 CampaignId int64 `json:"campaignId,omitempty,string"`
9733
9734
9735
9736 CampaignIdDimensionValue *DimensionValue `json:"campaignIdDimensionValue,omitempty"`
9737
9738
9739 Comment string `json:"comment,omitempty"`
9740
9741
9742
9743
9744
9745
9746
9747
9748
9749
9750
9751
9752
9753
9754
9755
9756 Compatibility string `json:"compatibility,omitempty"`
9757
9758
9759
9760 ContentCategoryId int64 `json:"contentCategoryId,omitempty,string"`
9761
9762
9763
9764 CreateInfo *LastModifiedInfo `json:"createInfo,omitempty"`
9765
9766
9767
9768
9769
9770 DirectorySiteId int64 `json:"directorySiteId,omitempty,string"`
9771
9772
9773
9774 DirectorySiteIdDimensionValue *DimensionValue `json:"directorySiteIdDimensionValue,omitempty"`
9775
9776
9777 ExternalId string `json:"externalId,omitempty"`
9778
9779
9780 Id int64 `json:"id,omitempty,string"`
9781
9782
9783
9784 IdDimensionValue *DimensionValue `json:"idDimensionValue,omitempty"`
9785
9786
9787
9788 KeyName string `json:"keyName,omitempty"`
9789
9790
9791
9792 Kind string `json:"kind,omitempty"`
9793
9794
9795
9796 LastModifiedInfo *LastModifiedInfo `json:"lastModifiedInfo,omitempty"`
9797
9798
9799 LookbackConfiguration *LookbackConfiguration `json:"lookbackConfiguration,omitempty"`
9800
9801
9802
9803 Name string `json:"name,omitempty"`
9804
9805
9806
9807 PaymentApproved bool `json:"paymentApproved,omitempty"`
9808
9809
9810
9811
9812
9813
9814
9815 PaymentSource string `json:"paymentSource,omitempty"`
9816
9817
9818 PlacementGroupId int64 `json:"placementGroupId,omitempty,string"`
9819
9820
9821
9822 PlacementGroupIdDimensionValue *DimensionValue `json:"placementGroupIdDimensionValue,omitempty"`
9823
9824
9825
9826 PlacementStrategyId int64 `json:"placementStrategyId,omitempty,string"`
9827
9828
9829
9830
9831 PricingSchedule *PricingSchedule `json:"pricingSchedule,omitempty"`
9832
9833
9834
9835
9836
9837
9838
9839 Primary bool `json:"primary,omitempty"`
9840
9841
9842
9843 PublisherUpdateInfo *LastModifiedInfo `json:"publisherUpdateInfo,omitempty"`
9844
9845
9846
9847
9848
9849 SiteId int64 `json:"siteId,omitempty,string"`
9850
9851
9852
9853 SiteIdDimensionValue *DimensionValue `json:"siteIdDimensionValue,omitempty"`
9854
9855
9856
9857
9858 Size *Size `json:"size,omitempty"`
9859
9860
9861
9862 SslRequired bool `json:"sslRequired,omitempty"`
9863
9864
9865
9866
9867
9868
9869
9870
9871
9872
9873 Status string `json:"status,omitempty"`
9874
9875
9876
9877 SubaccountId int64 `json:"subaccountId,omitempty,string"`
9878
9879
9880
9881
9882
9883
9884
9885
9886
9887
9888
9889
9890
9891
9892
9893
9894
9895
9896
9897
9898
9899
9900
9901
9902
9903
9904
9905
9906
9907
9908
9909
9910
9911
9912
9913
9914
9915
9916
9917
9918 TagFormats []string `json:"tagFormats,omitempty"`
9919
9920
9921 TagSetting *TagSetting `json:"tagSetting,omitempty"`
9922
9923
9924
9925
9926
9927
9928
9929
9930
9931 VideoActiveViewOptOut bool `json:"videoActiveViewOptOut,omitempty"`
9932
9933
9934
9935
9936 VideoSettings *VideoSettings `json:"videoSettings,omitempty"`
9937
9938
9939
9940
9941
9942
9943
9944
9945
9946
9947
9948
9949
9950 VpaidAdapterChoice string `json:"vpaidAdapterChoice,omitempty"`
9951
9952
9953
9954 googleapi.ServerResponse `json:"-"`
9955
9956
9957
9958
9959
9960
9961
9962 ForceSendFields []string `json:"-"`
9963
9964
9965
9966
9967
9968
9969
9970 NullFields []string `json:"-"`
9971 }
9972
9973 func (s *Placement) MarshalJSON() ([]byte, error) {
9974 type NoMethod Placement
9975 raw := NoMethod(*s)
9976 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9977 }
9978
9979
9980 type PlacementAssignment struct {
9981
9982
9983 Active bool `json:"active,omitempty"`
9984
9985
9986
9987 PlacementId int64 `json:"placementId,omitempty,string"`
9988
9989
9990
9991 PlacementIdDimensionValue *DimensionValue `json:"placementIdDimensionValue,omitempty"`
9992
9993
9994
9995
9996 SslRequired bool `json:"sslRequired,omitempty"`
9997
9998
9999
10000
10001
10002
10003
10004 ForceSendFields []string `json:"-"`
10005
10006
10007
10008
10009
10010
10011
10012 NullFields []string `json:"-"`
10013 }
10014
10015 func (s *PlacementAssignment) MarshalJSON() ([]byte, error) {
10016 type NoMethod PlacementAssignment
10017 raw := NoMethod(*s)
10018 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10019 }
10020
10021
10022 type PlacementGroup struct {
10023
10024
10025 AccountId int64 `json:"accountId,omitempty,string"`
10026
10027
10028
10029 AdvertiserId int64 `json:"advertiserId,omitempty,string"`
10030
10031
10032
10033 AdvertiserIdDimensionValue *DimensionValue `json:"advertiserIdDimensionValue,omitempty"`
10034
10035
10036 Archived bool `json:"archived,omitempty"`
10037
10038
10039
10040 CampaignId int64 `json:"campaignId,omitempty,string"`
10041
10042
10043
10044 CampaignIdDimensionValue *DimensionValue `json:"campaignIdDimensionValue,omitempty"`
10045
10046
10047
10048 ChildPlacementIds googleapi.Int64s `json:"childPlacementIds,omitempty"`
10049
10050
10051 Comment string `json:"comment,omitempty"`
10052
10053
10054
10055 ContentCategoryId int64 `json:"contentCategoryId,omitempty,string"`
10056
10057
10058
10059 CreateInfo *LastModifiedInfo `json:"createInfo,omitempty"`
10060
10061
10062
10063
10064
10065 DirectorySiteId int64 `json:"directorySiteId,omitempty,string"`
10066
10067
10068
10069 DirectorySiteIdDimensionValue *DimensionValue `json:"directorySiteIdDimensionValue,omitempty"`
10070
10071
10072 ExternalId string `json:"externalId,omitempty"`
10073
10074
10075
10076 Id int64 `json:"id,omitempty,string"`
10077
10078
10079
10080 IdDimensionValue *DimensionValue `json:"idDimensionValue,omitempty"`
10081
10082
10083
10084 Kind string `json:"kind,omitempty"`
10085
10086
10087
10088 LastModifiedInfo *LastModifiedInfo `json:"lastModifiedInfo,omitempty"`
10089
10090
10091
10092 Name string `json:"name,omitempty"`
10093
10094
10095
10096
10097
10098
10099
10100
10101
10102
10103
10104
10105 PlacementGroupType string `json:"placementGroupType,omitempty"`
10106
10107
10108
10109 PlacementStrategyId int64 `json:"placementStrategyId,omitempty,string"`
10110
10111
10112
10113 PricingSchedule *PricingSchedule `json:"pricingSchedule,omitempty"`
10114
10115
10116
10117
10118
10119 PrimaryPlacementId int64 `json:"primaryPlacementId,omitempty,string"`
10120
10121
10122
10123 PrimaryPlacementIdDimensionValue *DimensionValue `json:"primaryPlacementIdDimensionValue,omitempty"`
10124
10125
10126
10127
10128
10129 SiteId int64 `json:"siteId,omitempty,string"`
10130
10131
10132
10133 SiteIdDimensionValue *DimensionValue `json:"siteIdDimensionValue,omitempty"`
10134
10135
10136
10137 SubaccountId int64 `json:"subaccountId,omitempty,string"`
10138
10139
10140
10141 googleapi.ServerResponse `json:"-"`
10142
10143
10144
10145
10146
10147
10148
10149 ForceSendFields []string `json:"-"`
10150
10151
10152
10153
10154
10155
10156
10157 NullFields []string `json:"-"`
10158 }
10159
10160 func (s *PlacementGroup) MarshalJSON() ([]byte, error) {
10161 type NoMethod PlacementGroup
10162 raw := NoMethod(*s)
10163 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10164 }
10165
10166
10167 type PlacementGroupsListResponse struct {
10168
10169
10170 Kind string `json:"kind,omitempty"`
10171
10172
10173
10174 NextPageToken string `json:"nextPageToken,omitempty"`
10175
10176
10177 PlacementGroups []*PlacementGroup `json:"placementGroups,omitempty"`
10178
10179
10180
10181 googleapi.ServerResponse `json:"-"`
10182
10183
10184
10185
10186
10187
10188
10189 ForceSendFields []string `json:"-"`
10190
10191
10192
10193
10194
10195
10196
10197 NullFields []string `json:"-"`
10198 }
10199
10200 func (s *PlacementGroupsListResponse) MarshalJSON() ([]byte, error) {
10201 type NoMethod PlacementGroupsListResponse
10202 raw := NoMethod(*s)
10203 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10204 }
10205
10206
10207 type PlacementStrategiesListResponse struct {
10208
10209
10210 Kind string `json:"kind,omitempty"`
10211
10212
10213
10214 NextPageToken string `json:"nextPageToken,omitempty"`
10215
10216
10217 PlacementStrategies []*PlacementStrategy `json:"placementStrategies,omitempty"`
10218
10219
10220
10221 googleapi.ServerResponse `json:"-"`
10222
10223
10224
10225
10226
10227
10228
10229 ForceSendFields []string `json:"-"`
10230
10231
10232
10233
10234
10235
10236
10237 NullFields []string `json:"-"`
10238 }
10239
10240 func (s *PlacementStrategiesListResponse) MarshalJSON() ([]byte, error) {
10241 type NoMethod PlacementStrategiesListResponse
10242 raw := NoMethod(*s)
10243 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10244 }
10245
10246
10247 type PlacementStrategy struct {
10248
10249
10250 AccountId int64 `json:"accountId,omitempty,string"`
10251
10252
10253
10254 Id int64 `json:"id,omitempty,string"`
10255
10256
10257
10258 Kind string `json:"kind,omitempty"`
10259
10260
10261
10262
10263 Name string `json:"name,omitempty"`
10264
10265
10266
10267 googleapi.ServerResponse `json:"-"`
10268
10269
10270
10271
10272
10273
10274
10275 ForceSendFields []string `json:"-"`
10276
10277
10278
10279
10280
10281
10282
10283 NullFields []string `json:"-"`
10284 }
10285
10286 func (s *PlacementStrategy) MarshalJSON() ([]byte, error) {
10287 type NoMethod PlacementStrategy
10288 raw := NoMethod(*s)
10289 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10290 }
10291
10292
10293 type PlacementTag struct {
10294
10295 PlacementId int64 `json:"placementId,omitempty,string"`
10296
10297
10298 TagDatas []*TagData `json:"tagDatas,omitempty"`
10299
10300
10301
10302
10303
10304
10305
10306 ForceSendFields []string `json:"-"`
10307
10308
10309
10310
10311
10312
10313
10314 NullFields []string `json:"-"`
10315 }
10316
10317 func (s *PlacementTag) MarshalJSON() ([]byte, error) {
10318 type NoMethod PlacementTag
10319 raw := NoMethod(*s)
10320 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10321 }
10322
10323
10324 type PlacementsGenerateTagsResponse struct {
10325
10326
10327 Kind string `json:"kind,omitempty"`
10328
10329
10330 PlacementTags []*PlacementTag `json:"placementTags,omitempty"`
10331
10332
10333
10334 googleapi.ServerResponse `json:"-"`
10335
10336
10337
10338
10339
10340
10341
10342 ForceSendFields []string `json:"-"`
10343
10344
10345
10346
10347
10348
10349
10350 NullFields []string `json:"-"`
10351 }
10352
10353 func (s *PlacementsGenerateTagsResponse) MarshalJSON() ([]byte, error) {
10354 type NoMethod PlacementsGenerateTagsResponse
10355 raw := NoMethod(*s)
10356 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10357 }
10358
10359
10360 type PlacementsListResponse struct {
10361
10362
10363 Kind string `json:"kind,omitempty"`
10364
10365
10366
10367 NextPageToken string `json:"nextPageToken,omitempty"`
10368
10369
10370 Placements []*Placement `json:"placements,omitempty"`
10371
10372
10373
10374 googleapi.ServerResponse `json:"-"`
10375
10376
10377
10378
10379
10380
10381
10382 ForceSendFields []string `json:"-"`
10383
10384
10385
10386
10387
10388
10389
10390 NullFields []string `json:"-"`
10391 }
10392
10393 func (s *PlacementsListResponse) MarshalJSON() ([]byte, error) {
10394 type NoMethod PlacementsListResponse
10395 raw := NoMethod(*s)
10396 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10397 }
10398
10399
10400
10401 type PlatformType struct {
10402
10403 Id int64 `json:"id,omitempty,string"`
10404
10405
10406
10407 Kind string `json:"kind,omitempty"`
10408
10409
10410 Name string `json:"name,omitempty"`
10411
10412
10413
10414 googleapi.ServerResponse `json:"-"`
10415
10416
10417
10418
10419
10420
10421
10422 ForceSendFields []string `json:"-"`
10423
10424
10425
10426
10427
10428
10429
10430 NullFields []string `json:"-"`
10431 }
10432
10433 func (s *PlatformType) MarshalJSON() ([]byte, error) {
10434 type NoMethod PlatformType
10435 raw := NoMethod(*s)
10436 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10437 }
10438
10439
10440 type PlatformTypesListResponse struct {
10441
10442
10443 Kind string `json:"kind,omitempty"`
10444
10445
10446 PlatformTypes []*PlatformType `json:"platformTypes,omitempty"`
10447
10448
10449
10450 googleapi.ServerResponse `json:"-"`
10451
10452
10453
10454
10455
10456
10457
10458 ForceSendFields []string `json:"-"`
10459
10460
10461
10462
10463
10464
10465
10466 NullFields []string `json:"-"`
10467 }
10468
10469 func (s *PlatformTypesListResponse) MarshalJSON() ([]byte, error) {
10470 type NoMethod PlatformTypesListResponse
10471 raw := NoMethod(*s)
10472 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10473 }
10474
10475
10476 type PopupWindowProperties struct {
10477
10478
10479
10480 Dimension *Size `json:"dimension,omitempty"`
10481
10482
10483
10484 Offset *OffsetPosition `json:"offset,omitempty"`
10485
10486
10487
10488
10489
10490
10491
10492 PositionType string `json:"positionType,omitempty"`
10493
10494
10495 ShowAddressBar bool `json:"showAddressBar,omitempty"`
10496
10497
10498 ShowMenuBar bool `json:"showMenuBar,omitempty"`
10499
10500
10501 ShowScrollBar bool `json:"showScrollBar,omitempty"`
10502
10503
10504 ShowStatusBar bool `json:"showStatusBar,omitempty"`
10505
10506
10507 ShowToolBar bool `json:"showToolBar,omitempty"`
10508
10509
10510 Title string `json:"title,omitempty"`
10511
10512
10513
10514
10515
10516
10517
10518 ForceSendFields []string `json:"-"`
10519
10520
10521
10522
10523
10524
10525
10526 NullFields []string `json:"-"`
10527 }
10528
10529 func (s *PopupWindowProperties) MarshalJSON() ([]byte, error) {
10530 type NoMethod PopupWindowProperties
10531 raw := NoMethod(*s)
10532 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10533 }
10534
10535
10536
10537 type PostalCode struct {
10538
10539 Code string `json:"code,omitempty"`
10540
10541
10542
10543 CountryCode string `json:"countryCode,omitempty"`
10544
10545
10546
10547 CountryDartId int64 `json:"countryDartId,omitempty,string"`
10548
10549
10550 Id string `json:"id,omitempty"`
10551
10552
10553
10554 Kind string `json:"kind,omitempty"`
10555
10556
10557
10558 googleapi.ServerResponse `json:"-"`
10559
10560
10561
10562
10563
10564
10565
10566 ForceSendFields []string `json:"-"`
10567
10568
10569
10570
10571
10572
10573
10574 NullFields []string `json:"-"`
10575 }
10576
10577 func (s *PostalCode) MarshalJSON() ([]byte, error) {
10578 type NoMethod PostalCode
10579 raw := NoMethod(*s)
10580 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10581 }
10582
10583
10584 type PostalCodesListResponse struct {
10585
10586
10587 Kind string `json:"kind,omitempty"`
10588
10589
10590 PostalCodes []*PostalCode `json:"postalCodes,omitempty"`
10591
10592
10593
10594 googleapi.ServerResponse `json:"-"`
10595
10596
10597
10598
10599
10600
10601
10602 ForceSendFields []string `json:"-"`
10603
10604
10605
10606
10607
10608
10609
10610 NullFields []string `json:"-"`
10611 }
10612
10613 func (s *PostalCodesListResponse) MarshalJSON() ([]byte, error) {
10614 type NoMethod PostalCodesListResponse
10615 raw := NoMethod(*s)
10616 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10617 }
10618
10619
10620 type Pricing struct {
10621
10622
10623
10624
10625
10626
10627 CapCostType string `json:"capCostType,omitempty"`
10628
10629
10630 EndDate string `json:"endDate,omitempty"`
10631
10632
10633
10634
10635 Flights []*Flight `json:"flights,omitempty"`
10636
10637
10638
10639
10640
10641
10642
10643
10644
10645
10646
10647
10648
10649 GroupType string `json:"groupType,omitempty"`
10650
10651
10652
10653
10654
10655
10656
10657
10658
10659
10660
10661
10662 PricingType string `json:"pricingType,omitempty"`
10663
10664
10665 StartDate string `json:"startDate,omitempty"`
10666
10667
10668
10669
10670
10671
10672
10673 ForceSendFields []string `json:"-"`
10674
10675
10676
10677
10678
10679
10680
10681 NullFields []string `json:"-"`
10682 }
10683
10684 func (s *Pricing) MarshalJSON() ([]byte, error) {
10685 type NoMethod Pricing
10686 raw := NoMethod(*s)
10687 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10688 }
10689
10690
10691 type PricingSchedule struct {
10692
10693
10694
10695
10696
10697
10698 CapCostOption string `json:"capCostOption,omitempty"`
10699
10700
10701 DisregardOverdelivery bool `json:"disregardOverdelivery,omitempty"`
10702
10703
10704
10705
10706
10707
10708
10709
10710 EndDate string `json:"endDate,omitempty"`
10711
10712
10713
10714 Flighted bool `json:"flighted,omitempty"`
10715
10716
10717
10718
10719 FloodlightActivityId int64 `json:"floodlightActivityId,omitempty,string"`
10720
10721
10722 PricingPeriods []*PricingSchedulePricingPeriod `json:"pricingPeriods,omitempty"`
10723
10724
10725
10726
10727
10728
10729
10730
10731
10732
10733
10734 PricingType string `json:"pricingType,omitempty"`
10735
10736
10737
10738
10739
10740 StartDate string `json:"startDate,omitempty"`
10741
10742
10743
10744
10745 TestingStartDate string `json:"testingStartDate,omitempty"`
10746
10747
10748
10749
10750
10751
10752
10753 ForceSendFields []string `json:"-"`
10754
10755
10756
10757
10758
10759
10760
10761 NullFields []string `json:"-"`
10762 }
10763
10764 func (s *PricingSchedule) MarshalJSON() ([]byte, error) {
10765 type NoMethod PricingSchedule
10766 raw := NoMethod(*s)
10767 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10768 }
10769
10770
10771 type PricingSchedulePricingPeriod struct {
10772
10773
10774
10775
10776
10777
10778
10779 EndDate string `json:"endDate,omitempty"`
10780
10781
10782 PricingComment string `json:"pricingComment,omitempty"`
10783
10784
10785
10786
10787 RateOrCostNanos int64 `json:"rateOrCostNanos,omitempty,string"`
10788
10789
10790
10791
10792
10793 StartDate string `json:"startDate,omitempty"`
10794
10795
10796
10797 Units int64 `json:"units,omitempty,string"`
10798
10799
10800
10801
10802
10803
10804
10805 ForceSendFields []string `json:"-"`
10806
10807
10808
10809
10810
10811
10812
10813 NullFields []string `json:"-"`
10814 }
10815
10816 func (s *PricingSchedulePricingPeriod) MarshalJSON() ([]byte, error) {
10817 type NoMethod PricingSchedulePricingPeriod
10818 raw := NoMethod(*s)
10819 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10820 }
10821
10822
10823 type Project struct {
10824
10825 AccountId int64 `json:"accountId,omitempty,string"`
10826
10827
10828 AdvertiserId int64 `json:"advertiserId,omitempty,string"`
10829
10830
10831
10832
10833
10834
10835
10836
10837
10838
10839
10840 AudienceAgeGroup string `json:"audienceAgeGroup,omitempty"`
10841
10842
10843
10844
10845
10846
10847 AudienceGender string `json:"audienceGender,omitempty"`
10848
10849
10850
10851
10852
10853 Budget int64 `json:"budget,omitempty,string"`
10854
10855
10856 ClientBillingCode string `json:"clientBillingCode,omitempty"`
10857
10858
10859 ClientName string `json:"clientName,omitempty"`
10860
10861
10862 EndDate string `json:"endDate,omitempty"`
10863
10864
10865 Id int64 `json:"id,omitempty,string"`
10866
10867
10868
10869 Kind string `json:"kind,omitempty"`
10870
10871
10872
10873 LastModifiedInfo *LastModifiedInfo `json:"lastModifiedInfo,omitempty"`
10874
10875
10876 Name string `json:"name,omitempty"`
10877
10878
10879 Overview string `json:"overview,omitempty"`
10880
10881
10882 StartDate string `json:"startDate,omitempty"`
10883
10884
10885 SubaccountId int64 `json:"subaccountId,omitempty,string"`
10886
10887
10888 TargetClicks int64 `json:"targetClicks,omitempty,string"`
10889
10890
10891
10892 TargetConversions int64 `json:"targetConversions,omitempty,string"`
10893
10894
10895 TargetCpaNanos int64 `json:"targetCpaNanos,omitempty,string"`
10896
10897
10898 TargetCpcNanos int64 `json:"targetCpcNanos,omitempty,string"`
10899
10900
10901
10902 TargetCpmActiveViewNanos int64 `json:"targetCpmActiveViewNanos,omitempty,string"`
10903
10904
10905 TargetCpmNanos int64 `json:"targetCpmNanos,omitempty,string"`
10906
10907
10908
10909 TargetImpressions int64 `json:"targetImpressions,omitempty,string"`
10910
10911
10912
10913 googleapi.ServerResponse `json:"-"`
10914
10915
10916
10917
10918
10919
10920
10921 ForceSendFields []string `json:"-"`
10922
10923
10924
10925
10926
10927
10928
10929 NullFields []string `json:"-"`
10930 }
10931
10932 func (s *Project) MarshalJSON() ([]byte, error) {
10933 type NoMethod Project
10934 raw := NoMethod(*s)
10935 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10936 }
10937
10938
10939 type ProjectsListResponse struct {
10940
10941
10942 Kind string `json:"kind,omitempty"`
10943
10944
10945
10946 NextPageToken string `json:"nextPageToken,omitempty"`
10947
10948
10949 Projects []*Project `json:"projects,omitempty"`
10950
10951
10952
10953 googleapi.ServerResponse `json:"-"`
10954
10955
10956
10957
10958
10959
10960
10961 ForceSendFields []string `json:"-"`
10962
10963
10964
10965
10966
10967
10968
10969 NullFields []string `json:"-"`
10970 }
10971
10972 func (s *ProjectsListResponse) MarshalJSON() ([]byte, error) {
10973 type NoMethod ProjectsListResponse
10974 raw := NoMethod(*s)
10975 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10976 }
10977
10978
10979
10980 type ReachReportCompatibleFields struct {
10981
10982
10983 DimensionFilters []*Dimension `json:"dimensionFilters,omitempty"`
10984
10985
10986
10987 Dimensions []*Dimension `json:"dimensions,omitempty"`
10988
10989
10990
10991 Kind string `json:"kind,omitempty"`
10992
10993
10994
10995 Metrics []*Metric `json:"metrics,omitempty"`
10996
10997
10998
10999
11000 PivotedActivityMetrics []*Metric `json:"pivotedActivityMetrics,omitempty"`
11001
11002
11003
11004 ReachByFrequencyMetrics []*Metric `json:"reachByFrequencyMetrics,omitempty"`
11005
11006
11007
11008
11009
11010
11011
11012 ForceSendFields []string `json:"-"`
11013
11014
11015
11016
11017
11018
11019
11020
11021 NullFields []string `json:"-"`
11022 }
11023
11024 func (s *ReachReportCompatibleFields) MarshalJSON() ([]byte, error) {
11025 type NoMethod ReachReportCompatibleFields
11026 raw := NoMethod(*s)
11027 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11028 }
11029
11030
11031 type Recipient struct {
11032
11033
11034
11035
11036
11037 DeliveryType string `json:"deliveryType,omitempty"`
11038
11039
11040 Email string `json:"email,omitempty"`
11041
11042
11043
11044 Kind string `json:"kind,omitempty"`
11045
11046
11047
11048
11049
11050
11051
11052 ForceSendFields []string `json:"-"`
11053
11054
11055
11056
11057
11058
11059
11060 NullFields []string `json:"-"`
11061 }
11062
11063 func (s *Recipient) MarshalJSON() ([]byte, error) {
11064 type NoMethod Recipient
11065 raw := NoMethod(*s)
11066 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11067 }
11068
11069
11070
11071 type Region struct {
11072
11073
11074 CountryCode string `json:"countryCode,omitempty"`
11075
11076
11077 CountryDartId int64 `json:"countryDartId,omitempty,string"`
11078
11079
11080 DartId int64 `json:"dartId,omitempty,string"`
11081
11082
11083
11084 Kind string `json:"kind,omitempty"`
11085
11086
11087 Name string `json:"name,omitempty"`
11088
11089
11090 RegionCode string `json:"regionCode,omitempty"`
11091
11092
11093
11094
11095
11096
11097
11098 ForceSendFields []string `json:"-"`
11099
11100
11101
11102
11103
11104
11105
11106 NullFields []string `json:"-"`
11107 }
11108
11109 func (s *Region) MarshalJSON() ([]byte, error) {
11110 type NoMethod Region
11111 raw := NoMethod(*s)
11112 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11113 }
11114
11115
11116 type RegionsListResponse struct {
11117
11118
11119 Kind string `json:"kind,omitempty"`
11120
11121
11122 Regions []*Region `json:"regions,omitempty"`
11123
11124
11125
11126 googleapi.ServerResponse `json:"-"`
11127
11128
11129
11130
11131
11132
11133
11134 ForceSendFields []string `json:"-"`
11135
11136
11137
11138
11139
11140
11141
11142 NullFields []string `json:"-"`
11143 }
11144
11145 func (s *RegionsListResponse) MarshalJSON() ([]byte, error) {
11146 type NoMethod RegionsListResponse
11147 raw := NoMethod(*s)
11148 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11149 }
11150
11151
11152
11153
11154
11155
11156
11157
11158 type RemarketingList struct {
11159
11160
11161 AccountId int64 `json:"accountId,omitempty,string"`
11162
11163
11164 Active bool `json:"active,omitempty"`
11165
11166
11167
11168 AdvertiserId int64 `json:"advertiserId,omitempty,string"`
11169
11170
11171
11172 AdvertiserIdDimensionValue *DimensionValue `json:"advertiserIdDimensionValue,omitempty"`
11173
11174
11175 Description string `json:"description,omitempty"`
11176
11177
11178 Id int64 `json:"id,omitempty,string"`
11179
11180
11181
11182 Kind string `json:"kind,omitempty"`
11183
11184
11185
11186
11187 LifeSpan int64 `json:"lifeSpan,omitempty,string"`
11188
11189
11190
11191 ListPopulationRule *ListPopulationRule `json:"listPopulationRule,omitempty"`
11192
11193
11194
11195 ListSize int64 `json:"listSize,omitempty,string"`
11196
11197
11198
11199
11200
11201
11202
11203
11204
11205
11206
11207
11208
11209
11210
11211 ListSource string `json:"listSource,omitempty"`
11212
11213
11214
11215 Name string `json:"name,omitempty"`
11216
11217
11218
11219
11220 SubaccountId int64 `json:"subaccountId,omitempty,string"`
11221
11222
11223
11224 googleapi.ServerResponse `json:"-"`
11225
11226
11227
11228
11229
11230
11231
11232 ForceSendFields []string `json:"-"`
11233
11234
11235
11236
11237
11238
11239
11240 NullFields []string `json:"-"`
11241 }
11242
11243 func (s *RemarketingList) MarshalJSON() ([]byte, error) {
11244 type NoMethod RemarketingList
11245 raw := NoMethod(*s)
11246 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11247 }
11248
11249
11250
11251
11252
11253 type RemarketingListShare struct {
11254
11255
11256 Kind string `json:"kind,omitempty"`
11257
11258
11259
11260 RemarketingListId int64 `json:"remarketingListId,omitempty,string"`
11261
11262
11263 SharedAccountIds googleapi.Int64s `json:"sharedAccountIds,omitempty"`
11264
11265
11266
11267 SharedAdvertiserIds googleapi.Int64s `json:"sharedAdvertiserIds,omitempty"`
11268
11269
11270
11271 googleapi.ServerResponse `json:"-"`
11272
11273
11274
11275
11276
11277
11278
11279 ForceSendFields []string `json:"-"`
11280
11281
11282
11283
11284
11285
11286
11287 NullFields []string `json:"-"`
11288 }
11289
11290 func (s *RemarketingListShare) MarshalJSON() ([]byte, error) {
11291 type NoMethod RemarketingListShare
11292 raw := NoMethod(*s)
11293 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11294 }
11295
11296
11297 type RemarketingListsListResponse struct {
11298
11299
11300 Kind string `json:"kind,omitempty"`
11301
11302
11303
11304 NextPageToken string `json:"nextPageToken,omitempty"`
11305
11306
11307 RemarketingLists []*RemarketingList `json:"remarketingLists,omitempty"`
11308
11309
11310
11311 googleapi.ServerResponse `json:"-"`
11312
11313
11314
11315
11316
11317
11318
11319 ForceSendFields []string `json:"-"`
11320
11321
11322
11323
11324
11325
11326
11327 NullFields []string `json:"-"`
11328 }
11329
11330 func (s *RemarketingListsListResponse) MarshalJSON() ([]byte, error) {
11331 type NoMethod RemarketingListsListResponse
11332 raw := NoMethod(*s)
11333 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11334 }
11335
11336
11337 type Report struct {
11338
11339 AccountId int64 `json:"accountId,omitempty,string"`
11340
11341
11342 Criteria *ReportCriteria `json:"criteria,omitempty"`
11343
11344
11345
11346 CrossDimensionReachCriteria *ReportCrossDimensionReachCriteria `json:"crossDimensionReachCriteria,omitempty"`
11347
11348
11349 Delivery *ReportDelivery `json:"delivery,omitempty"`
11350
11351
11352 Etag string `json:"etag,omitempty"`
11353
11354
11355
11356 FileName string `json:"fileName,omitempty"`
11357
11358
11359
11360 FloodlightCriteria *ReportFloodlightCriteria `json:"floodlightCriteria,omitempty"`
11361
11362
11363
11364
11365
11366
11367
11368
11369
11370 Format string `json:"format,omitempty"`
11371
11372
11373 Id int64 `json:"id,omitempty,string"`
11374
11375
11376 Kind string `json:"kind,omitempty"`
11377
11378
11379
11380 LastModifiedTime uint64 `json:"lastModifiedTime,omitempty,string"`
11381
11382
11383 Name string `json:"name,omitempty"`
11384
11385
11386 OwnerProfileId int64 `json:"ownerProfileId,omitempty,string"`
11387
11388
11389
11390 PathToConversionCriteria *ReportPathToConversionCriteria `json:"pathToConversionCriteria,omitempty"`
11391
11392
11393 ReachCriteria *ReportReachCriteria `json:"reachCriteria,omitempty"`
11394
11395
11396
11397
11398 Schedule *ReportSchedule `json:"schedule,omitempty"`
11399
11400
11401
11402 SubAccountId int64 `json:"subAccountId,omitempty,string"`
11403
11404
11405
11406
11407
11408
11409
11410
11411
11412 Type string `json:"type,omitempty"`
11413
11414
11415
11416 googleapi.ServerResponse `json:"-"`
11417
11418
11419
11420
11421
11422
11423
11424 ForceSendFields []string `json:"-"`
11425
11426
11427
11428
11429
11430
11431
11432 NullFields []string `json:"-"`
11433 }
11434
11435 func (s *Report) MarshalJSON() ([]byte, error) {
11436 type NoMethod Report
11437 raw := NoMethod(*s)
11438 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11439 }
11440
11441
11442 type ReportCriteria struct {
11443
11444 Activities *Activities `json:"activities,omitempty"`
11445
11446
11447 CustomRichMediaEvents *CustomRichMediaEvents `json:"customRichMediaEvents,omitempty"`
11448
11449
11450 DateRange *DateRange `json:"dateRange,omitempty"`
11451
11452
11453
11454
11455
11456 DimensionFilters []*DimensionValue `json:"dimensionFilters,omitempty"`
11457
11458
11459
11460 Dimensions []*SortedDimension `json:"dimensions,omitempty"`
11461
11462
11463 MetricNames []string `json:"metricNames,omitempty"`
11464
11465
11466
11467
11468
11469
11470
11471 ForceSendFields []string `json:"-"`
11472
11473
11474
11475
11476
11477
11478
11479 NullFields []string `json:"-"`
11480 }
11481
11482 func (s *ReportCriteria) MarshalJSON() ([]byte, error) {
11483 type NoMethod ReportCriteria
11484 raw := NoMethod(*s)
11485 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11486 }
11487
11488
11489
11490 type ReportCrossDimensionReachCriteria struct {
11491
11492 Breakdown []*SortedDimension `json:"breakdown,omitempty"`
11493
11494
11495 DateRange *DateRange `json:"dateRange,omitempty"`
11496
11497
11498
11499
11500
11501
11502
11503
11504 Dimension string `json:"dimension,omitempty"`
11505
11506
11507
11508 DimensionFilters []*DimensionValue `json:"dimensionFilters,omitempty"`
11509
11510
11511 MetricNames []string `json:"metricNames,omitempty"`
11512
11513
11514
11515 OverlapMetricNames []string `json:"overlapMetricNames,omitempty"`
11516
11517
11518 Pivoted bool `json:"pivoted,omitempty"`
11519
11520
11521
11522
11523
11524
11525
11526 ForceSendFields []string `json:"-"`
11527
11528
11529
11530
11531
11532
11533
11534 NullFields []string `json:"-"`
11535 }
11536
11537 func (s *ReportCrossDimensionReachCriteria) MarshalJSON() ([]byte, error) {
11538 type NoMethod ReportCrossDimensionReachCriteria
11539 raw := NoMethod(*s)
11540 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11541 }
11542
11543
11544 type ReportDelivery struct {
11545
11546 EmailOwner bool `json:"emailOwner,omitempty"`
11547
11548
11549
11550
11551
11552
11553
11554 EmailOwnerDeliveryType string `json:"emailOwnerDeliveryType,omitempty"`
11555
11556
11557 Message string `json:"message,omitempty"`
11558
11559
11560 Recipients []*Recipient `json:"recipients,omitempty"`
11561
11562
11563
11564
11565
11566
11567
11568 ForceSendFields []string `json:"-"`
11569
11570
11571
11572
11573
11574
11575
11576 NullFields []string `json:"-"`
11577 }
11578
11579 func (s *ReportDelivery) MarshalJSON() ([]byte, error) {
11580 type NoMethod ReportDelivery
11581 raw := NoMethod(*s)
11582 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11583 }
11584
11585
11586
11587 type ReportFloodlightCriteria struct {
11588
11589
11590 CustomRichMediaEvents []*DimensionValue `json:"customRichMediaEvents,omitempty"`
11591
11592
11593 DateRange *DateRange `json:"dateRange,omitempty"`
11594
11595
11596
11597
11598
11599 DimensionFilters []*DimensionValue `json:"dimensionFilters,omitempty"`
11600
11601
11602 Dimensions []*SortedDimension `json:"dimensions,omitempty"`
11603
11604
11605
11606
11607
11608 FloodlightConfigId *DimensionValue `json:"floodlightConfigId,omitempty"`
11609
11610
11611 MetricNames []string `json:"metricNames,omitempty"`
11612
11613
11614 ReportProperties *ReportFloodlightCriteriaReportProperties `json:"reportProperties,omitempty"`
11615
11616
11617
11618
11619
11620
11621
11622
11623 ForceSendFields []string `json:"-"`
11624
11625
11626
11627
11628
11629
11630
11631
11632 NullFields []string `json:"-"`
11633 }
11634
11635 func (s *ReportFloodlightCriteria) MarshalJSON() ([]byte, error) {
11636 type NoMethod ReportFloodlightCriteria
11637 raw := NoMethod(*s)
11638 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11639 }
11640
11641
11642
11643 type ReportFloodlightCriteriaReportProperties struct {
11644
11645
11646 IncludeAttributedIPConversions bool `json:"includeAttributedIPConversions,omitempty"`
11647
11648
11649
11650
11651
11652
11653 IncludeUnattributedCookieConversions bool `json:"includeUnattributedCookieConversions,omitempty"`
11654
11655
11656
11657
11658
11659 IncludeUnattributedIPConversions bool `json:"includeUnattributedIPConversions,omitempty"`
11660
11661
11662
11663
11664
11665
11666
11667
11668 ForceSendFields []string `json:"-"`
11669
11670
11671
11672
11673
11674
11675
11676
11677 NullFields []string `json:"-"`
11678 }
11679
11680 func (s *ReportFloodlightCriteriaReportProperties) MarshalJSON() ([]byte, error) {
11681 type NoMethod ReportFloodlightCriteriaReportProperties
11682 raw := NoMethod(*s)
11683 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11684 }
11685
11686
11687
11688 type ReportPathToConversionCriteria struct {
11689
11690 ActivityFilters []*DimensionValue `json:"activityFilters,omitempty"`
11691
11692
11693
11694 ConversionDimensions []*SortedDimension `json:"conversionDimensions,omitempty"`
11695
11696
11697
11698 CustomFloodlightVariables []*SortedDimension `json:"customFloodlightVariables,omitempty"`
11699
11700
11701
11702 CustomRichMediaEvents []*DimensionValue `json:"customRichMediaEvents,omitempty"`
11703
11704
11705 DateRange *DateRange `json:"dateRange,omitempty"`
11706
11707
11708
11709
11710
11711 FloodlightConfigId *DimensionValue `json:"floodlightConfigId,omitempty"`
11712
11713
11714 MetricNames []string `json:"metricNames,omitempty"`
11715
11716
11717
11718 PerInteractionDimensions []*SortedDimension `json:"perInteractionDimensions,omitempty"`
11719
11720
11721 ReportProperties *ReportPathToConversionCriteriaReportProperties `json:"reportProperties,omitempty"`
11722
11723
11724
11725
11726
11727
11728
11729 ForceSendFields []string `json:"-"`
11730
11731
11732
11733
11734
11735
11736
11737
11738 NullFields []string `json:"-"`
11739 }
11740
11741 func (s *ReportPathToConversionCriteria) MarshalJSON() ([]byte, error) {
11742 type NoMethod ReportPathToConversionCriteria
11743 raw := NoMethod(*s)
11744 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11745 }
11746
11747
11748
11749 type ReportPathToConversionCriteriaReportProperties struct {
11750
11751
11752
11753
11754 ClicksLookbackWindow int64 `json:"clicksLookbackWindow,omitempty"`
11755
11756
11757
11758
11759
11760 ImpressionsLookbackWindow int64 `json:"impressionsLookbackWindow,omitempty"`
11761
11762
11763 IncludeAttributedIPConversions bool `json:"includeAttributedIPConversions,omitempty"`
11764
11765
11766
11767
11768
11769
11770 IncludeUnattributedCookieConversions bool `json:"includeUnattributedCookieConversions,omitempty"`
11771
11772
11773
11774
11775
11776 IncludeUnattributedIPConversions bool `json:"includeUnattributedIPConversions,omitempty"`
11777
11778
11779
11780
11781
11782
11783 MaximumClickInteractions int64 `json:"maximumClickInteractions,omitempty"`
11784
11785
11786
11787
11788
11789
11790 MaximumImpressionInteractions int64 `json:"maximumImpressionInteractions,omitempty"`
11791
11792
11793
11794
11795 MaximumInteractionGap int64 `json:"maximumInteractionGap,omitempty"`
11796
11797
11798 PivotOnInteractionPath bool `json:"pivotOnInteractionPath,omitempty"`
11799
11800
11801
11802
11803
11804
11805
11806
11807 ForceSendFields []string `json:"-"`
11808
11809
11810
11811
11812
11813
11814
11815
11816 NullFields []string `json:"-"`
11817 }
11818
11819 func (s *ReportPathToConversionCriteriaReportProperties) MarshalJSON() ([]byte, error) {
11820 type NoMethod ReportPathToConversionCriteriaReportProperties
11821 raw := NoMethod(*s)
11822 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11823 }
11824
11825
11826
11827 type ReportReachCriteria struct {
11828
11829 Activities *Activities `json:"activities,omitempty"`
11830
11831
11832 CustomRichMediaEvents *CustomRichMediaEvents `json:"customRichMediaEvents,omitempty"`
11833
11834
11835 DateRange *DateRange `json:"dateRange,omitempty"`
11836
11837
11838
11839
11840
11841 DimensionFilters []*DimensionValue `json:"dimensionFilters,omitempty"`
11842
11843
11844 Dimensions []*SortedDimension `json:"dimensions,omitempty"`
11845
11846
11847
11848
11849 EnableAllDimensionCombinations bool `json:"enableAllDimensionCombinations,omitempty"`
11850
11851
11852 MetricNames []string `json:"metricNames,omitempty"`
11853
11854
11855
11856 ReachByFrequencyMetricNames []string `json:"reachByFrequencyMetricNames,omitempty"`
11857
11858
11859
11860
11861
11862
11863
11864 ForceSendFields []string `json:"-"`
11865
11866
11867
11868
11869
11870
11871
11872 NullFields []string `json:"-"`
11873 }
11874
11875 func (s *ReportReachCriteria) MarshalJSON() ([]byte, error) {
11876 type NoMethod ReportReachCriteria
11877 raw := NoMethod(*s)
11878 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11879 }
11880
11881
11882
11883
11884 type ReportSchedule struct {
11885
11886
11887 Active bool `json:"active,omitempty"`
11888
11889
11890
11891
11892 Every int64 `json:"every,omitempty"`
11893
11894
11895
11896 ExpirationDate string `json:"expirationDate,omitempty"`
11897
11898
11899
11900
11901
11902
11903
11904 Repeats string `json:"repeats,omitempty"`
11905
11906
11907
11908
11909
11910
11911
11912
11913
11914
11915
11916
11917 RepeatsOnWeekDays []string `json:"repeatsOnWeekDays,omitempty"`
11918
11919
11920
11921
11922
11923
11924
11925
11926
11927
11928
11929
11930 RunsOnDayOfMonth string `json:"runsOnDayOfMonth,omitempty"`
11931
11932
11933
11934 StartDate string `json:"startDate,omitempty"`
11935
11936
11937
11938
11939
11940
11941
11942 ForceSendFields []string `json:"-"`
11943
11944
11945
11946
11947
11948
11949
11950 NullFields []string `json:"-"`
11951 }
11952
11953 func (s *ReportSchedule) MarshalJSON() ([]byte, error) {
11954 type NoMethod ReportSchedule
11955 raw := NoMethod(*s)
11956 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11957 }
11958
11959
11960
11961 type ReportCompatibleFields struct {
11962
11963
11964 DimensionFilters []*Dimension `json:"dimensionFilters,omitempty"`
11965
11966
11967
11968 Dimensions []*Dimension `json:"dimensions,omitempty"`
11969
11970
11971
11972 Kind string `json:"kind,omitempty"`
11973
11974
11975
11976 Metrics []*Metric `json:"metrics,omitempty"`
11977
11978
11979
11980
11981 PivotedActivityMetrics []*Metric `json:"pivotedActivityMetrics,omitempty"`
11982
11983
11984
11985
11986
11987
11988
11989 ForceSendFields []string `json:"-"`
11990
11991
11992
11993
11994
11995
11996
11997
11998 NullFields []string `json:"-"`
11999 }
12000
12001 func (s *ReportCompatibleFields) MarshalJSON() ([]byte, error) {
12002 type NoMethod ReportCompatibleFields
12003 raw := NoMethod(*s)
12004 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12005 }
12006
12007
12008 type ReportList struct {
12009
12010 Etag string `json:"etag,omitempty"`
12011
12012
12013 Items []*Report `json:"items,omitempty"`
12014
12015
12016 Kind string `json:"kind,omitempty"`
12017
12018
12019
12020
12021
12022 NextPageToken string `json:"nextPageToken,omitempty"`
12023
12024
12025
12026 googleapi.ServerResponse `json:"-"`
12027
12028
12029
12030
12031
12032
12033
12034 ForceSendFields []string `json:"-"`
12035
12036
12037
12038
12039
12040
12041
12042 NullFields []string `json:"-"`
12043 }
12044
12045 func (s *ReportList) MarshalJSON() ([]byte, error) {
12046 type NoMethod ReportList
12047 raw := NoMethod(*s)
12048 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12049 }
12050
12051
12052 type ReportsConfiguration struct {
12053
12054
12055
12056
12057 ExposureToConversionEnabled bool `json:"exposureToConversionEnabled,omitempty"`
12058
12059
12060
12061 LookbackConfiguration *LookbackConfiguration `json:"lookbackConfiguration,omitempty"`
12062
12063
12064
12065
12066
12067
12068
12069
12070
12071
12072
12073
12074
12075
12076
12077
12078
12079
12080
12081 ReportGenerationTimeZoneId int64 `json:"reportGenerationTimeZoneId,omitempty,string"`
12082
12083
12084
12085
12086
12087
12088
12089
12090 ForceSendFields []string `json:"-"`
12091
12092
12093
12094
12095
12096
12097
12098
12099 NullFields []string `json:"-"`
12100 }
12101
12102 func (s *ReportsConfiguration) MarshalJSON() ([]byte, error) {
12103 type NoMethod ReportsConfiguration
12104 raw := NoMethod(*s)
12105 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12106 }
12107
12108
12109 type RichMediaExitOverride struct {
12110
12111
12112 ClickThroughUrl *ClickThroughUrl `json:"clickThroughUrl,omitempty"`
12113
12114
12115
12116 Enabled bool `json:"enabled,omitempty"`
12117
12118
12119
12120 ExitId int64 `json:"exitId,omitempty,string"`
12121
12122
12123
12124
12125
12126
12127
12128 ForceSendFields []string `json:"-"`
12129
12130
12131
12132
12133
12134
12135
12136
12137 NullFields []string `json:"-"`
12138 }
12139
12140 func (s *RichMediaExitOverride) MarshalJSON() ([]byte, error) {
12141 type NoMethod RichMediaExitOverride
12142 raw := NoMethod(*s)
12143 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12144 }
12145
12146
12147
12148 type Rule struct {
12149
12150
12151 AssetId int64 `json:"assetId,omitempty,string"`
12152
12153
12154 Name string `json:"name,omitempty"`
12155
12156
12157
12158
12159 TargetingTemplateId int64 `json:"targetingTemplateId,omitempty,string"`
12160
12161
12162
12163
12164
12165
12166
12167 ForceSendFields []string `json:"-"`
12168
12169
12170
12171
12172
12173
12174
12175 NullFields []string `json:"-"`
12176 }
12177
12178 func (s *Rule) MarshalJSON() ([]byte, error) {
12179 type NoMethod Rule
12180 raw := NoMethod(*s)
12181 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12182 }
12183
12184
12185 type Site struct {
12186
12187
12188 AccountId int64 `json:"accountId,omitempty,string"`
12189
12190
12191 Approved bool `json:"approved,omitempty"`
12192
12193
12194
12195 DirectorySiteId int64 `json:"directorySiteId,omitempty,string"`
12196
12197
12198
12199 DirectorySiteIdDimensionValue *DimensionValue `json:"directorySiteIdDimensionValue,omitempty"`
12200
12201
12202 Id int64 `json:"id,omitempty,string"`
12203
12204
12205
12206 IdDimensionValue *DimensionValue `json:"idDimensionValue,omitempty"`
12207
12208
12209
12210 KeyName string `json:"keyName,omitempty"`
12211
12212
12213
12214 Kind string `json:"kind,omitempty"`
12215
12216
12217
12218
12219
12220
12221 Name string `json:"name,omitempty"`
12222
12223
12224 SiteContacts []*SiteContact `json:"siteContacts,omitempty"`
12225
12226
12227 SiteSettings *SiteSettings `json:"siteSettings,omitempty"`
12228
12229
12230
12231 SubaccountId int64 `json:"subaccountId,omitempty,string"`
12232
12233
12234
12235 googleapi.ServerResponse `json:"-"`
12236
12237
12238
12239
12240
12241
12242
12243 ForceSendFields []string `json:"-"`
12244
12245
12246
12247
12248
12249
12250
12251 NullFields []string `json:"-"`
12252 }
12253
12254 func (s *Site) MarshalJSON() ([]byte, error) {
12255 type NoMethod Site
12256 raw := NoMethod(*s)
12257 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12258 }
12259
12260
12261 type SiteContact struct {
12262
12263 Address string `json:"address,omitempty"`
12264
12265
12266
12267
12268
12269
12270 ContactType string `json:"contactType,omitempty"`
12271
12272
12273 Email string `json:"email,omitempty"`
12274
12275
12276 FirstName string `json:"firstName,omitempty"`
12277
12278
12279
12280 Id int64 `json:"id,omitempty,string"`
12281
12282
12283 LastName string `json:"lastName,omitempty"`
12284
12285
12286 Phone string `json:"phone,omitempty"`
12287
12288
12289 Title string `json:"title,omitempty"`
12290
12291
12292
12293
12294
12295
12296
12297 ForceSendFields []string `json:"-"`
12298
12299
12300
12301
12302
12303
12304
12305 NullFields []string `json:"-"`
12306 }
12307
12308 func (s *SiteContact) MarshalJSON() ([]byte, error) {
12309 type NoMethod SiteContact
12310 raw := NoMethod(*s)
12311 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12312 }
12313
12314
12315 type SiteSettings struct {
12316
12317
12318 ActiveViewOptOut bool `json:"activeViewOptOut,omitempty"`
12319
12320
12321
12322
12323
12324 AdBlockingOptOut bool `json:"adBlockingOptOut,omitempty"`
12325
12326
12327 CreativeSettings *CreativeSettings `json:"creativeSettings,omitempty"`
12328
12329
12330 DisableNewCookie bool `json:"disableNewCookie,omitempty"`
12331
12332
12333 LookbackConfiguration *LookbackConfiguration `json:"lookbackConfiguration,omitempty"`
12334
12335
12336
12337 TagSetting *TagSetting `json:"tagSetting,omitempty"`
12338
12339
12340
12341
12342
12343
12344 VideoActiveViewOptOutTemplate bool `json:"videoActiveViewOptOutTemplate,omitempty"`
12345
12346
12347
12348
12349
12350
12351
12352
12353
12354
12355
12356
12357
12358
12359
12360
12361
12362
12363
12364 VpaidAdapterChoiceTemplate string `json:"vpaidAdapterChoiceTemplate,omitempty"`
12365
12366
12367
12368
12369
12370
12371
12372 ForceSendFields []string `json:"-"`
12373
12374
12375
12376
12377
12378
12379
12380
12381 NullFields []string `json:"-"`
12382 }
12383
12384 func (s *SiteSettings) MarshalJSON() ([]byte, error) {
12385 type NoMethod SiteSettings
12386 raw := NoMethod(*s)
12387 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12388 }
12389
12390
12391 type SitesListResponse struct {
12392
12393
12394 Kind string `json:"kind,omitempty"`
12395
12396
12397
12398 NextPageToken string `json:"nextPageToken,omitempty"`
12399
12400
12401 Sites []*Site `json:"sites,omitempty"`
12402
12403
12404
12405 googleapi.ServerResponse `json:"-"`
12406
12407
12408
12409
12410
12411
12412
12413 ForceSendFields []string `json:"-"`
12414
12415
12416
12417
12418
12419
12420
12421 NullFields []string `json:"-"`
12422 }
12423
12424 func (s *SitesListResponse) MarshalJSON() ([]byte, error) {
12425 type NoMethod SitesListResponse
12426 raw := NoMethod(*s)
12427 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12428 }
12429
12430
12431
12432 type Size struct {
12433
12434
12435 Height int64 `json:"height,omitempty"`
12436
12437
12438 Iab bool `json:"iab,omitempty"`
12439
12440
12441 Id int64 `json:"id,omitempty,string"`
12442
12443
12444
12445 Kind string `json:"kind,omitempty"`
12446
12447
12448
12449 Width int64 `json:"width,omitempty"`
12450
12451
12452
12453 googleapi.ServerResponse `json:"-"`
12454
12455
12456
12457
12458
12459
12460
12461 ForceSendFields []string `json:"-"`
12462
12463
12464
12465
12466
12467
12468
12469 NullFields []string `json:"-"`
12470 }
12471
12472 func (s *Size) MarshalJSON() ([]byte, error) {
12473 type NoMethod Size
12474 raw := NoMethod(*s)
12475 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12476 }
12477
12478
12479 type SizesListResponse struct {
12480
12481
12482 Kind string `json:"kind,omitempty"`
12483
12484
12485 Sizes []*Size `json:"sizes,omitempty"`
12486
12487
12488
12489 googleapi.ServerResponse `json:"-"`
12490
12491
12492
12493
12494
12495
12496
12497 ForceSendFields []string `json:"-"`
12498
12499
12500
12501
12502
12503
12504
12505 NullFields []string `json:"-"`
12506 }
12507
12508 func (s *SizesListResponse) MarshalJSON() ([]byte, error) {
12509 type NoMethod SizesListResponse
12510 raw := NoMethod(*s)
12511 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12512 }
12513
12514
12515 type SkippableSetting struct {
12516
12517
12518 Kind string `json:"kind,omitempty"`
12519
12520
12521
12522 ProgressOffset *VideoOffset `json:"progressOffset,omitempty"`
12523
12524
12525
12526
12527 SkipOffset *VideoOffset `json:"skipOffset,omitempty"`
12528
12529
12530
12531 Skippable bool `json:"skippable,omitempty"`
12532
12533
12534
12535
12536
12537
12538
12539 ForceSendFields []string `json:"-"`
12540
12541
12542
12543
12544
12545
12546
12547 NullFields []string `json:"-"`
12548 }
12549
12550 func (s *SkippableSetting) MarshalJSON() ([]byte, error) {
12551 type NoMethod SkippableSetting
12552 raw := NoMethod(*s)
12553 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12554 }
12555
12556
12557 type SortedDimension struct {
12558
12559
12560 Kind string `json:"kind,omitempty"`
12561
12562
12563 Name string `json:"name,omitempty"`
12564
12565
12566
12567
12568
12569
12570 SortOrder string `json:"sortOrder,omitempty"`
12571
12572
12573
12574
12575
12576
12577
12578 ForceSendFields []string `json:"-"`
12579
12580
12581
12582
12583
12584
12585
12586 NullFields []string `json:"-"`
12587 }
12588
12589 func (s *SortedDimension) MarshalJSON() ([]byte, error) {
12590 type NoMethod SortedDimension
12591 raw := NoMethod(*s)
12592 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12593 }
12594
12595
12596 type Subaccount struct {
12597
12598
12599 AccountId int64 `json:"accountId,omitempty,string"`
12600
12601
12602
12603 AvailablePermissionIds googleapi.Int64s `json:"availablePermissionIds,omitempty"`
12604
12605
12606 Id int64 `json:"id,omitempty,string"`
12607
12608
12609
12610 Kind string `json:"kind,omitempty"`
12611
12612
12613
12614
12615 Name string `json:"name,omitempty"`
12616
12617
12618
12619 googleapi.ServerResponse `json:"-"`
12620
12621
12622
12623
12624
12625
12626
12627 ForceSendFields []string `json:"-"`
12628
12629
12630
12631
12632
12633
12634
12635 NullFields []string `json:"-"`
12636 }
12637
12638 func (s *Subaccount) MarshalJSON() ([]byte, error) {
12639 type NoMethod Subaccount
12640 raw := NoMethod(*s)
12641 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12642 }
12643
12644
12645 type SubaccountsListResponse struct {
12646
12647
12648 Kind string `json:"kind,omitempty"`
12649
12650
12651
12652 NextPageToken string `json:"nextPageToken,omitempty"`
12653
12654
12655 Subaccounts []*Subaccount `json:"subaccounts,omitempty"`
12656
12657
12658
12659 googleapi.ServerResponse `json:"-"`
12660
12661
12662
12663
12664
12665
12666
12667 ForceSendFields []string `json:"-"`
12668
12669
12670
12671
12672
12673
12674
12675 NullFields []string `json:"-"`
12676 }
12677
12678 func (s *SubaccountsListResponse) MarshalJSON() ([]byte, error) {
12679 type NoMethod SubaccountsListResponse
12680 raw := NoMethod(*s)
12681 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12682 }
12683
12684
12685 type TagData struct {
12686
12687
12688 AdId int64 `json:"adId,omitempty,string"`
12689
12690
12691 ClickTag string `json:"clickTag,omitempty"`
12692
12693
12694
12695 CreativeId int64 `json:"creativeId,omitempty,string"`
12696
12697
12698
12699
12700
12701
12702
12703
12704
12705
12706
12707
12708
12709
12710
12711
12712
12713
12714
12715
12716
12717
12718
12719 Format string `json:"format,omitempty"`
12720
12721
12722 ImpressionTag string `json:"impressionTag,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 *TagData) MarshalJSON() ([]byte, error) {
12742 type NoMethod TagData
12743 raw := NoMethod(*s)
12744 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12745 }
12746
12747
12748 type TagSetting struct {
12749
12750
12751
12752
12753 AdditionalKeyValues string `json:"additionalKeyValues,omitempty"`
12754
12755
12756
12757 IncludeClickThroughUrls bool `json:"includeClickThroughUrls,omitempty"`
12758
12759
12760
12761 IncludeClickTracking bool `json:"includeClickTracking,omitempty"`
12762
12763
12764
12765
12766
12767
12768
12769
12770
12771
12772 KeywordOption string `json:"keywordOption,omitempty"`
12773
12774
12775
12776
12777
12778
12779
12780 ForceSendFields []string `json:"-"`
12781
12782
12783
12784
12785
12786
12787
12788
12789 NullFields []string `json:"-"`
12790 }
12791
12792 func (s *TagSetting) MarshalJSON() ([]byte, error) {
12793 type NoMethod TagSetting
12794 raw := NoMethod(*s)
12795 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12796 }
12797
12798
12799 type TagSettings struct {
12800
12801 DynamicTagEnabled bool `json:"dynamicTagEnabled,omitempty"`
12802
12803
12804 ImageTagEnabled bool `json:"imageTagEnabled,omitempty"`
12805
12806
12807
12808
12809
12810
12811
12812 ForceSendFields []string `json:"-"`
12813
12814
12815
12816
12817
12818
12819
12820
12821 NullFields []string `json:"-"`
12822 }
12823
12824 func (s *TagSettings) MarshalJSON() ([]byte, error) {
12825 type NoMethod TagSettings
12826 raw := NoMethod(*s)
12827 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12828 }
12829
12830
12831 type TargetWindow struct {
12832
12833 CustomHtml string `json:"customHtml,omitempty"`
12834
12835
12836
12837
12838
12839
12840
12841
12842 TargetWindowOption string `json:"targetWindowOption,omitempty"`
12843
12844
12845
12846
12847
12848
12849
12850 ForceSendFields []string `json:"-"`
12851
12852
12853
12854
12855
12856
12857
12858 NullFields []string `json:"-"`
12859 }
12860
12861 func (s *TargetWindow) MarshalJSON() ([]byte, error) {
12862 type NoMethod TargetWindow
12863 raw := NoMethod(*s)
12864 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12865 }
12866
12867
12868
12869
12870
12871
12872
12873
12874
12875
12876 type TargetableRemarketingList struct {
12877
12878
12879 AccountId int64 `json:"accountId,omitempty,string"`
12880
12881
12882 Active bool `json:"active,omitempty"`
12883
12884
12885
12886 AdvertiserId int64 `json:"advertiserId,omitempty,string"`
12887
12888
12889
12890 AdvertiserIdDimensionValue *DimensionValue `json:"advertiserIdDimensionValue,omitempty"`
12891
12892
12893 Description string `json:"description,omitempty"`
12894
12895
12896 Id int64 `json:"id,omitempty,string"`
12897
12898
12899
12900 Kind string `json:"kind,omitempty"`
12901
12902
12903
12904 LifeSpan int64 `json:"lifeSpan,omitempty,string"`
12905
12906
12907
12908 ListSize int64 `json:"listSize,omitempty,string"`
12909
12910
12911
12912
12913
12914
12915
12916
12917
12918
12919
12920
12921
12922
12923
12924
12925 ListSource string `json:"listSource,omitempty"`
12926
12927
12928
12929 Name string `json:"name,omitempty"`
12930
12931
12932
12933
12934 SubaccountId int64 `json:"subaccountId,omitempty,string"`
12935
12936
12937
12938 googleapi.ServerResponse `json:"-"`
12939
12940
12941
12942
12943
12944
12945
12946 ForceSendFields []string `json:"-"`
12947
12948
12949
12950
12951
12952
12953
12954 NullFields []string `json:"-"`
12955 }
12956
12957 func (s *TargetableRemarketingList) MarshalJSON() ([]byte, error) {
12958 type NoMethod TargetableRemarketingList
12959 raw := NoMethod(*s)
12960 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12961 }
12962
12963
12964
12965 type TargetableRemarketingListsListResponse struct {
12966
12967
12968 Kind string `json:"kind,omitempty"`
12969
12970
12971
12972 NextPageToken string `json:"nextPageToken,omitempty"`
12973
12974
12975 TargetableRemarketingLists []*TargetableRemarketingList `json:"targetableRemarketingLists,omitempty"`
12976
12977
12978
12979 googleapi.ServerResponse `json:"-"`
12980
12981
12982
12983
12984
12985
12986
12987 ForceSendFields []string `json:"-"`
12988
12989
12990
12991
12992
12993
12994
12995 NullFields []string `json:"-"`
12996 }
12997
12998 func (s *TargetableRemarketingListsListResponse) MarshalJSON() ([]byte, error) {
12999 type NoMethod TargetableRemarketingListsListResponse
13000 raw := NoMethod(*s)
13001 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13002 }
13003
13004
13005
13006
13007 type TargetingTemplate struct {
13008
13009
13010
13011 AccountId int64 `json:"accountId,omitempty,string"`
13012
13013
13014
13015 AdvertiserId int64 `json:"advertiserId,omitempty,string"`
13016
13017
13018
13019 AdvertiserIdDimensionValue *DimensionValue `json:"advertiserIdDimensionValue,omitempty"`
13020
13021
13022 DayPartTargeting *DayPartTargeting `json:"dayPartTargeting,omitempty"`
13023
13024
13025 GeoTargeting *GeoTargeting `json:"geoTargeting,omitempty"`
13026
13027
13028
13029 Id int64 `json:"id,omitempty,string"`
13030
13031
13032 KeyValueTargetingExpression *KeyValueTargetingExpression `json:"keyValueTargetingExpression,omitempty"`
13033
13034
13035
13036 Kind string `json:"kind,omitempty"`
13037
13038
13039 LanguageTargeting *LanguageTargeting `json:"languageTargeting,omitempty"`
13040
13041
13042 ListTargetingExpression *ListTargetingExpression `json:"listTargetingExpression,omitempty"`
13043
13044
13045
13046
13047 Name string `json:"name,omitempty"`
13048
13049
13050
13051
13052 SubaccountId int64 `json:"subaccountId,omitempty,string"`
13053
13054
13055 TechnologyTargeting *TechnologyTargeting `json:"technologyTargeting,omitempty"`
13056
13057
13058
13059 googleapi.ServerResponse `json:"-"`
13060
13061
13062
13063
13064
13065
13066
13067 ForceSendFields []string `json:"-"`
13068
13069
13070
13071
13072
13073
13074
13075 NullFields []string `json:"-"`
13076 }
13077
13078 func (s *TargetingTemplate) MarshalJSON() ([]byte, error) {
13079 type NoMethod TargetingTemplate
13080 raw := NoMethod(*s)
13081 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13082 }
13083
13084
13085 type TargetingTemplatesListResponse struct {
13086
13087
13088 Kind string `json:"kind,omitempty"`
13089
13090
13091
13092 NextPageToken string `json:"nextPageToken,omitempty"`
13093
13094
13095 TargetingTemplates []*TargetingTemplate `json:"targetingTemplates,omitempty"`
13096
13097
13098
13099 googleapi.ServerResponse `json:"-"`
13100
13101
13102
13103
13104
13105
13106
13107 ForceSendFields []string `json:"-"`
13108
13109
13110
13111
13112
13113
13114
13115 NullFields []string `json:"-"`
13116 }
13117
13118 func (s *TargetingTemplatesListResponse) MarshalJSON() ([]byte, error) {
13119 type NoMethod TargetingTemplatesListResponse
13120 raw := NoMethod(*s)
13121 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13122 }
13123
13124
13125 type TechnologyTargeting struct {
13126
13127
13128
13129
13130 Browsers []*Browser `json:"browsers,omitempty"`
13131
13132
13133
13134
13135 ConnectionTypes []*ConnectionType `json:"connectionTypes,omitempty"`
13136
13137
13138
13139
13140
13141 MobileCarriers []*MobileCarrier `json:"mobileCarriers,omitempty"`
13142
13143
13144
13145
13146
13147
13148
13149 OperatingSystemVersions []*OperatingSystemVersion `json:"operatingSystemVersions,omitempty"`
13150
13151
13152
13153
13154
13155
13156
13157 OperatingSystems []*OperatingSystem `json:"operatingSystems,omitempty"`
13158
13159
13160
13161
13162
13163 PlatformTypes []*PlatformType `json:"platformTypes,omitempty"`
13164
13165
13166
13167
13168
13169
13170
13171 ForceSendFields []string `json:"-"`
13172
13173
13174
13175
13176
13177
13178
13179 NullFields []string `json:"-"`
13180 }
13181
13182 func (s *TechnologyTargeting) MarshalJSON() ([]byte, error) {
13183 type NoMethod TechnologyTargeting
13184 raw := NoMethod(*s)
13185 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13186 }
13187
13188
13189 type ThirdPartyAuthenticationToken struct {
13190
13191 Name string `json:"name,omitempty"`
13192
13193
13194
13195 Value string `json:"value,omitempty"`
13196
13197
13198
13199
13200
13201
13202
13203 ForceSendFields []string `json:"-"`
13204
13205
13206
13207
13208
13209
13210
13211 NullFields []string `json:"-"`
13212 }
13213
13214 func (s *ThirdPartyAuthenticationToken) MarshalJSON() ([]byte, error) {
13215 type NoMethod ThirdPartyAuthenticationToken
13216 raw := NoMethod(*s)
13217 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13218 }
13219
13220
13221 type ThirdPartyTrackingUrl struct {
13222
13223
13224
13225
13226
13227
13228
13229
13230
13231
13232
13233
13234
13235
13236
13237
13238
13239
13240
13241
13242
13243
13244
13245 ThirdPartyUrlType string `json:"thirdPartyUrlType,omitempty"`
13246
13247
13248 Url string `json:"url,omitempty"`
13249
13250
13251
13252
13253
13254
13255
13256 ForceSendFields []string `json:"-"`
13257
13258
13259
13260
13261
13262
13263
13264
13265 NullFields []string `json:"-"`
13266 }
13267
13268 func (s *ThirdPartyTrackingUrl) MarshalJSON() ([]byte, error) {
13269 type NoMethod ThirdPartyTrackingUrl
13270 raw := NoMethod(*s)
13271 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13272 }
13273
13274
13275 type TranscodeSetting struct {
13276
13277
13278 EnabledVideoFormats []int64 `json:"enabledVideoFormats,omitempty"`
13279
13280
13281
13282 Kind string `json:"kind,omitempty"`
13283
13284
13285
13286
13287
13288
13289
13290 ForceSendFields []string `json:"-"`
13291
13292
13293
13294
13295
13296
13297
13298
13299 NullFields []string `json:"-"`
13300 }
13301
13302 func (s *TranscodeSetting) MarshalJSON() ([]byte, error) {
13303 type NoMethod TranscodeSetting
13304 raw := NoMethod(*s)
13305 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13306 }
13307
13308
13309
13310 type UniversalAdId struct {
13311
13312
13313
13314
13315
13316
13317
13318 Registry string `json:"registry,omitempty"`
13319
13320
13321
13322
13323 Value string `json:"value,omitempty"`
13324
13325
13326
13327
13328
13329
13330
13331 ForceSendFields []string `json:"-"`
13332
13333
13334
13335
13336
13337
13338
13339 NullFields []string `json:"-"`
13340 }
13341
13342 func (s *UniversalAdId) MarshalJSON() ([]byte, error) {
13343 type NoMethod UniversalAdId
13344 raw := NoMethod(*s)
13345 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13346 }
13347
13348
13349
13350 type UserDefinedVariableConfiguration struct {
13351
13352
13353
13354
13355
13356 DataType string `json:"dataType,omitempty"`
13357
13358
13359
13360
13361 ReportName string `json:"reportName,omitempty"`
13362
13363
13364
13365
13366
13367
13368
13369
13370
13371
13372
13373
13374
13375
13376
13377
13378
13379
13380
13381
13382
13383
13384
13385
13386
13387
13388
13389
13390
13391
13392
13393
13394
13395
13396
13397
13398
13399
13400
13401
13402
13403
13404
13405
13406
13407
13408
13409
13410
13411
13412
13413
13414
13415
13416
13417
13418
13419
13420
13421
13422
13423
13424
13425
13426
13427
13428
13429
13430
13431
13432
13433
13434
13435
13436
13437
13438
13439
13440
13441
13442
13443
13444
13445
13446
13447
13448
13449
13450
13451
13452
13453
13454
13455
13456
13457
13458
13459
13460
13461
13462
13463
13464
13465
13466 VariableType string `json:"variableType,omitempty"`
13467
13468
13469
13470
13471
13472
13473
13474 ForceSendFields []string `json:"-"`
13475
13476
13477
13478
13479
13480
13481
13482 NullFields []string `json:"-"`
13483 }
13484
13485 func (s *UserDefinedVariableConfiguration) MarshalJSON() ([]byte, error) {
13486 type NoMethod UserDefinedVariableConfiguration
13487 raw := NoMethod(*s)
13488 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13489 }
13490
13491
13492 type UserProfile struct {
13493
13494 AccountId int64 `json:"accountId,omitempty,string"`
13495
13496
13497 AccountName string `json:"accountName,omitempty"`
13498
13499
13500 Etag string `json:"etag,omitempty"`
13501
13502
13503
13504 Kind string `json:"kind,omitempty"`
13505
13506
13507 ProfileId int64 `json:"profileId,omitempty,string"`
13508
13509
13510
13511 SubAccountId int64 `json:"subAccountId,omitempty,string"`
13512
13513
13514
13515 SubAccountName string `json:"subAccountName,omitempty"`
13516
13517
13518 UserName string `json:"userName,omitempty"`
13519
13520
13521
13522 googleapi.ServerResponse `json:"-"`
13523
13524
13525
13526
13527
13528
13529
13530 ForceSendFields []string `json:"-"`
13531
13532
13533
13534
13535
13536
13537
13538 NullFields []string `json:"-"`
13539 }
13540
13541 func (s *UserProfile) MarshalJSON() ([]byte, error) {
13542 type NoMethod UserProfile
13543 raw := NoMethod(*s)
13544 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13545 }
13546
13547
13548 type UserProfileList struct {
13549
13550 Etag string `json:"etag,omitempty"`
13551
13552
13553 Items []*UserProfile `json:"items,omitempty"`
13554
13555
13556
13557 Kind string `json:"kind,omitempty"`
13558
13559
13560
13561 googleapi.ServerResponse `json:"-"`
13562
13563
13564
13565
13566
13567
13568
13569 ForceSendFields []string `json:"-"`
13570
13571
13572
13573
13574
13575
13576
13577 NullFields []string `json:"-"`
13578 }
13579
13580 func (s *UserProfileList) MarshalJSON() ([]byte, error) {
13581 type NoMethod UserProfileList
13582 raw := NoMethod(*s)
13583 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13584 }
13585
13586
13587
13588 type UserRole struct {
13589
13590
13591 AccountId int64 `json:"accountId,omitempty,string"`
13592
13593
13594
13595
13596
13597 DefaultUserRole bool `json:"defaultUserRole,omitempty"`
13598
13599
13600 Id int64 `json:"id,omitempty,string"`
13601
13602
13603
13604 Kind string `json:"kind,omitempty"`
13605
13606
13607
13608
13609
13610
13611 Name string `json:"name,omitempty"`
13612
13613
13614
13615 ParentUserRoleId int64 `json:"parentUserRoleId,omitempty,string"`
13616
13617
13618 Permissions []*UserRolePermission `json:"permissions,omitempty"`
13619
13620
13621
13622 SubaccountId int64 `json:"subaccountId,omitempty,string"`
13623
13624
13625
13626 googleapi.ServerResponse `json:"-"`
13627
13628
13629
13630
13631
13632
13633
13634 ForceSendFields []string `json:"-"`
13635
13636
13637
13638
13639
13640
13641
13642 NullFields []string `json:"-"`
13643 }
13644
13645 func (s *UserRole) MarshalJSON() ([]byte, error) {
13646 type NoMethod UserRole
13647 raw := NoMethod(*s)
13648 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13649 }
13650
13651
13652 type UserRolePermission struct {
13653
13654
13655
13656
13657
13658
13659
13660
13661 Availability string `json:"availability,omitempty"`
13662
13663
13664 Id int64 `json:"id,omitempty,string"`
13665
13666
13667
13668 Kind string `json:"kind,omitempty"`
13669
13670
13671 Name string `json:"name,omitempty"`
13672
13673
13674
13675 PermissionGroupId int64 `json:"permissionGroupId,omitempty,string"`
13676
13677
13678
13679 googleapi.ServerResponse `json:"-"`
13680
13681
13682
13683
13684
13685
13686
13687 ForceSendFields []string `json:"-"`
13688
13689
13690
13691
13692
13693
13694
13695 NullFields []string `json:"-"`
13696 }
13697
13698 func (s *UserRolePermission) MarshalJSON() ([]byte, error) {
13699 type NoMethod UserRolePermission
13700 raw := NoMethod(*s)
13701 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13702 }
13703
13704
13705
13706 type UserRolePermissionGroup struct {
13707
13708 Id int64 `json:"id,omitempty,string"`
13709
13710
13711
13712 Kind string `json:"kind,omitempty"`
13713
13714
13715 Name string `json:"name,omitempty"`
13716
13717
13718
13719 googleapi.ServerResponse `json:"-"`
13720
13721
13722
13723
13724
13725
13726
13727 ForceSendFields []string `json:"-"`
13728
13729
13730
13731
13732
13733
13734
13735 NullFields []string `json:"-"`
13736 }
13737
13738 func (s *UserRolePermissionGroup) MarshalJSON() ([]byte, error) {
13739 type NoMethod UserRolePermissionGroup
13740 raw := NoMethod(*s)
13741 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13742 }
13743
13744
13745
13746 type UserRolePermissionGroupsListResponse struct {
13747
13748
13749 Kind string `json:"kind,omitempty"`
13750
13751
13752 UserRolePermissionGroups []*UserRolePermissionGroup `json:"userRolePermissionGroups,omitempty"`
13753
13754
13755
13756 googleapi.ServerResponse `json:"-"`
13757
13758
13759
13760
13761
13762
13763
13764 ForceSendFields []string `json:"-"`
13765
13766
13767
13768
13769
13770
13771
13772 NullFields []string `json:"-"`
13773 }
13774
13775 func (s *UserRolePermissionGroupsListResponse) MarshalJSON() ([]byte, error) {
13776 type NoMethod UserRolePermissionGroupsListResponse
13777 raw := NoMethod(*s)
13778 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13779 }
13780
13781
13782 type UserRolePermissionsListResponse struct {
13783
13784
13785 Kind string `json:"kind,omitempty"`
13786
13787
13788 UserRolePermissions []*UserRolePermission `json:"userRolePermissions,omitempty"`
13789
13790
13791
13792 googleapi.ServerResponse `json:"-"`
13793
13794
13795
13796
13797
13798
13799
13800 ForceSendFields []string `json:"-"`
13801
13802
13803
13804
13805
13806
13807
13808 NullFields []string `json:"-"`
13809 }
13810
13811 func (s *UserRolePermissionsListResponse) MarshalJSON() ([]byte, error) {
13812 type NoMethod UserRolePermissionsListResponse
13813 raw := NoMethod(*s)
13814 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13815 }
13816
13817
13818 type UserRolesListResponse struct {
13819
13820
13821 Kind string `json:"kind,omitempty"`
13822
13823
13824
13825 NextPageToken string `json:"nextPageToken,omitempty"`
13826
13827
13828 UserRoles []*UserRole `json:"userRoles,omitempty"`
13829
13830
13831
13832 googleapi.ServerResponse `json:"-"`
13833
13834
13835
13836
13837
13838
13839
13840 ForceSendFields []string `json:"-"`
13841
13842
13843
13844
13845
13846
13847
13848 NullFields []string `json:"-"`
13849 }
13850
13851 func (s *UserRolesListResponse) MarshalJSON() ([]byte, error) {
13852 type NoMethod UserRolesListResponse
13853 raw := NoMethod(*s)
13854 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13855 }
13856
13857
13858 type VideoFormat struct {
13859
13860
13861
13862
13863
13864
13865
13866
13867 FileType string `json:"fileType,omitempty"`
13868
13869
13870 Id int64 `json:"id,omitempty"`
13871
13872
13873
13874 Kind string `json:"kind,omitempty"`
13875
13876
13877 Resolution *Size `json:"resolution,omitempty"`
13878
13879
13880 TargetBitRate int64 `json:"targetBitRate,omitempty"`
13881
13882
13883
13884 googleapi.ServerResponse `json:"-"`
13885
13886
13887
13888
13889
13890
13891
13892 ForceSendFields []string `json:"-"`
13893
13894
13895
13896
13897
13898
13899
13900 NullFields []string `json:"-"`
13901 }
13902
13903 func (s *VideoFormat) MarshalJSON() ([]byte, error) {
13904 type NoMethod VideoFormat
13905 raw := NoMethod(*s)
13906 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13907 }
13908
13909
13910 type VideoFormatsListResponse struct {
13911
13912
13913 Kind string `json:"kind,omitempty"`
13914
13915
13916 VideoFormats []*VideoFormat `json:"videoFormats,omitempty"`
13917
13918
13919
13920 googleapi.ServerResponse `json:"-"`
13921
13922
13923
13924
13925
13926
13927
13928 ForceSendFields []string `json:"-"`
13929
13930
13931
13932
13933
13934
13935
13936 NullFields []string `json:"-"`
13937 }
13938
13939 func (s *VideoFormatsListResponse) MarshalJSON() ([]byte, error) {
13940 type NoMethod VideoFormatsListResponse
13941 raw := NoMethod(*s)
13942 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13943 }
13944
13945
13946 type VideoOffset struct {
13947
13948
13949
13950 OffsetPercentage int64 `json:"offsetPercentage,omitempty"`
13951
13952
13953
13954 OffsetSeconds int64 `json:"offsetSeconds,omitempty"`
13955
13956
13957
13958
13959
13960
13961
13962 ForceSendFields []string `json:"-"`
13963
13964
13965
13966
13967
13968
13969
13970
13971 NullFields []string `json:"-"`
13972 }
13973
13974 func (s *VideoOffset) MarshalJSON() ([]byte, error) {
13975 type NoMethod VideoOffset
13976 raw := NoMethod(*s)
13977 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13978 }
13979
13980
13981 type VideoSettings struct {
13982
13983
13984 CompanionSettings *CompanionSetting `json:"companionSettings,omitempty"`
13985
13986
13987
13988 Kind string `json:"kind,omitempty"`
13989
13990
13991
13992
13993
13994
13995
13996
13997 Orientation string `json:"orientation,omitempty"`
13998
13999
14000
14001
14002 SkippableSettings *SkippableSetting `json:"skippableSettings,omitempty"`
14003
14004
14005
14006
14007 TranscodeSettings *TranscodeSetting `json:"transcodeSettings,omitempty"`
14008
14009
14010
14011
14012
14013
14014
14015 ForceSendFields []string `json:"-"`
14016
14017
14018
14019
14020
14021
14022
14023
14024 NullFields []string `json:"-"`
14025 }
14026
14027 func (s *VideoSettings) MarshalJSON() ([]byte, error) {
14028 type NoMethod VideoSettings
14029 raw := NoMethod(*s)
14030 return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14031 }
14032
14033
14034
14035 type AccountActiveAdSummariesGetCall struct {
14036 s *Service
14037 profileId int64
14038 summaryAccountId int64
14039 urlParams_ gensupport.URLParams
14040 ifNoneMatch_ string
14041 ctx_ context.Context
14042 header_ http.Header
14043 }
14044
14045
14046 func (r *AccountActiveAdSummariesService) Get(profileId int64, summaryAccountId int64) *AccountActiveAdSummariesGetCall {
14047 c := &AccountActiveAdSummariesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
14048 c.profileId = profileId
14049 c.summaryAccountId = summaryAccountId
14050 return c
14051 }
14052
14053
14054
14055
14056 func (c *AccountActiveAdSummariesGetCall) Fields(s ...googleapi.Field) *AccountActiveAdSummariesGetCall {
14057 c.urlParams_.Set("fields", googleapi.CombineFields(s))
14058 return c
14059 }
14060
14061
14062
14063
14064
14065
14066 func (c *AccountActiveAdSummariesGetCall) IfNoneMatch(entityTag string) *AccountActiveAdSummariesGetCall {
14067 c.ifNoneMatch_ = entityTag
14068 return c
14069 }
14070
14071
14072
14073
14074 func (c *AccountActiveAdSummariesGetCall) Context(ctx context.Context) *AccountActiveAdSummariesGetCall {
14075 c.ctx_ = ctx
14076 return c
14077 }
14078
14079
14080
14081 func (c *AccountActiveAdSummariesGetCall) Header() http.Header {
14082 if c.header_ == nil {
14083 c.header_ = make(http.Header)
14084 }
14085 return c.header_
14086 }
14087
14088 func (c *AccountActiveAdSummariesGetCall) doRequest(alt string) (*http.Response, error) {
14089 reqHeaders := make(http.Header)
14090 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
14091 for k, v := range c.header_ {
14092 reqHeaders[k] = v
14093 }
14094 reqHeaders.Set("User-Agent", c.s.userAgent())
14095 if c.ifNoneMatch_ != "" {
14096 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
14097 }
14098 var body io.Reader = nil
14099 c.urlParams_.Set("alt", alt)
14100 c.urlParams_.Set("prettyPrint", "false")
14101 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/accountActiveAdSummaries/{summaryAccountId}")
14102 urls += "?" + c.urlParams_.Encode()
14103 req, err := http.NewRequest("GET", urls, body)
14104 if err != nil {
14105 return nil, err
14106 }
14107 req.Header = reqHeaders
14108 googleapi.Expand(req.URL, map[string]string{
14109 "profileId": strconv.FormatInt(c.profileId, 10),
14110 "summaryAccountId": strconv.FormatInt(c.summaryAccountId, 10),
14111 })
14112 return gensupport.SendRequest(c.ctx_, c.s.client, req)
14113 }
14114
14115
14116
14117
14118
14119
14120
14121
14122 func (c *AccountActiveAdSummariesGetCall) Do(opts ...googleapi.CallOption) (*AccountActiveAdSummary, error) {
14123 gensupport.SetOptions(c.urlParams_, opts...)
14124 res, err := c.doRequest("json")
14125 if res != nil && res.StatusCode == http.StatusNotModified {
14126 if res.Body != nil {
14127 res.Body.Close()
14128 }
14129 return nil, &googleapi.Error{
14130 Code: res.StatusCode,
14131 Header: res.Header,
14132 }
14133 }
14134 if err != nil {
14135 return nil, err
14136 }
14137 defer googleapi.CloseBody(res)
14138 if err := googleapi.CheckResponse(res); err != nil {
14139 return nil, err
14140 }
14141 ret := &AccountActiveAdSummary{
14142 ServerResponse: googleapi.ServerResponse{
14143 Header: res.Header,
14144 HTTPStatusCode: res.StatusCode,
14145 },
14146 }
14147 target := &ret
14148 if err := gensupport.DecodeResponse(target, res); err != nil {
14149 return nil, err
14150 }
14151 return ret, nil
14152
14153
14154
14155
14156
14157
14158
14159
14160
14161
14162
14163
14164
14165
14166
14167
14168
14169
14170
14171
14172
14173
14174
14175
14176
14177
14178
14179
14180
14181
14182
14183
14184
14185 }
14186
14187
14188
14189 type AccountPermissionGroupsGetCall struct {
14190 s *Service
14191 profileId int64
14192 id int64
14193 urlParams_ gensupport.URLParams
14194 ifNoneMatch_ string
14195 ctx_ context.Context
14196 header_ http.Header
14197 }
14198
14199
14200 func (r *AccountPermissionGroupsService) Get(profileId int64, id int64) *AccountPermissionGroupsGetCall {
14201 c := &AccountPermissionGroupsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
14202 c.profileId = profileId
14203 c.id = id
14204 return c
14205 }
14206
14207
14208
14209
14210 func (c *AccountPermissionGroupsGetCall) Fields(s ...googleapi.Field) *AccountPermissionGroupsGetCall {
14211 c.urlParams_.Set("fields", googleapi.CombineFields(s))
14212 return c
14213 }
14214
14215
14216
14217
14218
14219
14220 func (c *AccountPermissionGroupsGetCall) IfNoneMatch(entityTag string) *AccountPermissionGroupsGetCall {
14221 c.ifNoneMatch_ = entityTag
14222 return c
14223 }
14224
14225
14226
14227
14228 func (c *AccountPermissionGroupsGetCall) Context(ctx context.Context) *AccountPermissionGroupsGetCall {
14229 c.ctx_ = ctx
14230 return c
14231 }
14232
14233
14234
14235 func (c *AccountPermissionGroupsGetCall) Header() http.Header {
14236 if c.header_ == nil {
14237 c.header_ = make(http.Header)
14238 }
14239 return c.header_
14240 }
14241
14242 func (c *AccountPermissionGroupsGetCall) doRequest(alt string) (*http.Response, error) {
14243 reqHeaders := make(http.Header)
14244 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
14245 for k, v := range c.header_ {
14246 reqHeaders[k] = v
14247 }
14248 reqHeaders.Set("User-Agent", c.s.userAgent())
14249 if c.ifNoneMatch_ != "" {
14250 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
14251 }
14252 var body io.Reader = nil
14253 c.urlParams_.Set("alt", alt)
14254 c.urlParams_.Set("prettyPrint", "false")
14255 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/accountPermissionGroups/{id}")
14256 urls += "?" + c.urlParams_.Encode()
14257 req, err := http.NewRequest("GET", urls, body)
14258 if err != nil {
14259 return nil, err
14260 }
14261 req.Header = reqHeaders
14262 googleapi.Expand(req.URL, map[string]string{
14263 "profileId": strconv.FormatInt(c.profileId, 10),
14264 "id": strconv.FormatInt(c.id, 10),
14265 })
14266 return gensupport.SendRequest(c.ctx_, c.s.client, req)
14267 }
14268
14269
14270
14271
14272
14273
14274
14275
14276 func (c *AccountPermissionGroupsGetCall) Do(opts ...googleapi.CallOption) (*AccountPermissionGroup, error) {
14277 gensupport.SetOptions(c.urlParams_, opts...)
14278 res, err := c.doRequest("json")
14279 if res != nil && res.StatusCode == http.StatusNotModified {
14280 if res.Body != nil {
14281 res.Body.Close()
14282 }
14283 return nil, &googleapi.Error{
14284 Code: res.StatusCode,
14285 Header: res.Header,
14286 }
14287 }
14288 if err != nil {
14289 return nil, err
14290 }
14291 defer googleapi.CloseBody(res)
14292 if err := googleapi.CheckResponse(res); err != nil {
14293 return nil, err
14294 }
14295 ret := &AccountPermissionGroup{
14296 ServerResponse: googleapi.ServerResponse{
14297 Header: res.Header,
14298 HTTPStatusCode: res.StatusCode,
14299 },
14300 }
14301 target := &ret
14302 if err := gensupport.DecodeResponse(target, res); err != nil {
14303 return nil, err
14304 }
14305 return ret, nil
14306
14307
14308
14309
14310
14311
14312
14313
14314
14315
14316
14317
14318
14319
14320
14321
14322
14323
14324
14325
14326
14327
14328
14329
14330
14331
14332
14333
14334
14335
14336
14337
14338
14339 }
14340
14341
14342
14343 type AccountPermissionGroupsListCall struct {
14344 s *Service
14345 profileId int64
14346 urlParams_ gensupport.URLParams
14347 ifNoneMatch_ string
14348 ctx_ context.Context
14349 header_ http.Header
14350 }
14351
14352
14353 func (r *AccountPermissionGroupsService) List(profileId int64) *AccountPermissionGroupsListCall {
14354 c := &AccountPermissionGroupsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
14355 c.profileId = profileId
14356 return c
14357 }
14358
14359
14360
14361
14362 func (c *AccountPermissionGroupsListCall) Fields(s ...googleapi.Field) *AccountPermissionGroupsListCall {
14363 c.urlParams_.Set("fields", googleapi.CombineFields(s))
14364 return c
14365 }
14366
14367
14368
14369
14370
14371
14372 func (c *AccountPermissionGroupsListCall) IfNoneMatch(entityTag string) *AccountPermissionGroupsListCall {
14373 c.ifNoneMatch_ = entityTag
14374 return c
14375 }
14376
14377
14378
14379
14380 func (c *AccountPermissionGroupsListCall) Context(ctx context.Context) *AccountPermissionGroupsListCall {
14381 c.ctx_ = ctx
14382 return c
14383 }
14384
14385
14386
14387 func (c *AccountPermissionGroupsListCall) Header() http.Header {
14388 if c.header_ == nil {
14389 c.header_ = make(http.Header)
14390 }
14391 return c.header_
14392 }
14393
14394 func (c *AccountPermissionGroupsListCall) doRequest(alt string) (*http.Response, error) {
14395 reqHeaders := make(http.Header)
14396 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
14397 for k, v := range c.header_ {
14398 reqHeaders[k] = v
14399 }
14400 reqHeaders.Set("User-Agent", c.s.userAgent())
14401 if c.ifNoneMatch_ != "" {
14402 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
14403 }
14404 var body io.Reader = nil
14405 c.urlParams_.Set("alt", alt)
14406 c.urlParams_.Set("prettyPrint", "false")
14407 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/accountPermissionGroups")
14408 urls += "?" + c.urlParams_.Encode()
14409 req, err := http.NewRequest("GET", urls, body)
14410 if err != nil {
14411 return nil, err
14412 }
14413 req.Header = reqHeaders
14414 googleapi.Expand(req.URL, map[string]string{
14415 "profileId": strconv.FormatInt(c.profileId, 10),
14416 })
14417 return gensupport.SendRequest(c.ctx_, c.s.client, req)
14418 }
14419
14420
14421
14422
14423
14424
14425
14426
14427
14428 func (c *AccountPermissionGroupsListCall) Do(opts ...googleapi.CallOption) (*AccountPermissionGroupsListResponse, error) {
14429 gensupport.SetOptions(c.urlParams_, opts...)
14430 res, err := c.doRequest("json")
14431 if res != nil && res.StatusCode == http.StatusNotModified {
14432 if res.Body != nil {
14433 res.Body.Close()
14434 }
14435 return nil, &googleapi.Error{
14436 Code: res.StatusCode,
14437 Header: res.Header,
14438 }
14439 }
14440 if err != nil {
14441 return nil, err
14442 }
14443 defer googleapi.CloseBody(res)
14444 if err := googleapi.CheckResponse(res); err != nil {
14445 return nil, err
14446 }
14447 ret := &AccountPermissionGroupsListResponse{
14448 ServerResponse: googleapi.ServerResponse{
14449 Header: res.Header,
14450 HTTPStatusCode: res.StatusCode,
14451 },
14452 }
14453 target := &ret
14454 if err := gensupport.DecodeResponse(target, res); err != nil {
14455 return nil, err
14456 }
14457 return ret, nil
14458
14459
14460
14461
14462
14463
14464
14465
14466
14467
14468
14469
14470
14471
14472
14473
14474
14475
14476
14477
14478
14479
14480
14481
14482
14483 }
14484
14485
14486
14487 type AccountPermissionsGetCall struct {
14488 s *Service
14489 profileId int64
14490 id int64
14491 urlParams_ gensupport.URLParams
14492 ifNoneMatch_ string
14493 ctx_ context.Context
14494 header_ http.Header
14495 }
14496
14497
14498 func (r *AccountPermissionsService) Get(profileId int64, id int64) *AccountPermissionsGetCall {
14499 c := &AccountPermissionsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
14500 c.profileId = profileId
14501 c.id = id
14502 return c
14503 }
14504
14505
14506
14507
14508 func (c *AccountPermissionsGetCall) Fields(s ...googleapi.Field) *AccountPermissionsGetCall {
14509 c.urlParams_.Set("fields", googleapi.CombineFields(s))
14510 return c
14511 }
14512
14513
14514
14515
14516
14517
14518 func (c *AccountPermissionsGetCall) IfNoneMatch(entityTag string) *AccountPermissionsGetCall {
14519 c.ifNoneMatch_ = entityTag
14520 return c
14521 }
14522
14523
14524
14525
14526 func (c *AccountPermissionsGetCall) Context(ctx context.Context) *AccountPermissionsGetCall {
14527 c.ctx_ = ctx
14528 return c
14529 }
14530
14531
14532
14533 func (c *AccountPermissionsGetCall) Header() http.Header {
14534 if c.header_ == nil {
14535 c.header_ = make(http.Header)
14536 }
14537 return c.header_
14538 }
14539
14540 func (c *AccountPermissionsGetCall) doRequest(alt string) (*http.Response, error) {
14541 reqHeaders := make(http.Header)
14542 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
14543 for k, v := range c.header_ {
14544 reqHeaders[k] = v
14545 }
14546 reqHeaders.Set("User-Agent", c.s.userAgent())
14547 if c.ifNoneMatch_ != "" {
14548 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
14549 }
14550 var body io.Reader = nil
14551 c.urlParams_.Set("alt", alt)
14552 c.urlParams_.Set("prettyPrint", "false")
14553 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/accountPermissions/{id}")
14554 urls += "?" + c.urlParams_.Encode()
14555 req, err := http.NewRequest("GET", urls, body)
14556 if err != nil {
14557 return nil, err
14558 }
14559 req.Header = reqHeaders
14560 googleapi.Expand(req.URL, map[string]string{
14561 "profileId": strconv.FormatInt(c.profileId, 10),
14562 "id": strconv.FormatInt(c.id, 10),
14563 })
14564 return gensupport.SendRequest(c.ctx_, c.s.client, req)
14565 }
14566
14567
14568
14569
14570
14571
14572
14573
14574 func (c *AccountPermissionsGetCall) Do(opts ...googleapi.CallOption) (*AccountPermission, error) {
14575 gensupport.SetOptions(c.urlParams_, opts...)
14576 res, err := c.doRequest("json")
14577 if res != nil && res.StatusCode == http.StatusNotModified {
14578 if res.Body != nil {
14579 res.Body.Close()
14580 }
14581 return nil, &googleapi.Error{
14582 Code: res.StatusCode,
14583 Header: res.Header,
14584 }
14585 }
14586 if err != nil {
14587 return nil, err
14588 }
14589 defer googleapi.CloseBody(res)
14590 if err := googleapi.CheckResponse(res); err != nil {
14591 return nil, err
14592 }
14593 ret := &AccountPermission{
14594 ServerResponse: googleapi.ServerResponse{
14595 Header: res.Header,
14596 HTTPStatusCode: res.StatusCode,
14597 },
14598 }
14599 target := &ret
14600 if err := gensupport.DecodeResponse(target, res); err != nil {
14601 return nil, err
14602 }
14603 return ret, nil
14604
14605
14606
14607
14608
14609
14610
14611
14612
14613
14614
14615
14616
14617
14618
14619
14620
14621
14622
14623
14624
14625
14626
14627
14628
14629
14630
14631
14632
14633
14634
14635
14636
14637 }
14638
14639
14640
14641 type AccountPermissionsListCall struct {
14642 s *Service
14643 profileId int64
14644 urlParams_ gensupport.URLParams
14645 ifNoneMatch_ string
14646 ctx_ context.Context
14647 header_ http.Header
14648 }
14649
14650
14651 func (r *AccountPermissionsService) List(profileId int64) *AccountPermissionsListCall {
14652 c := &AccountPermissionsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
14653 c.profileId = profileId
14654 return c
14655 }
14656
14657
14658
14659
14660 func (c *AccountPermissionsListCall) Fields(s ...googleapi.Field) *AccountPermissionsListCall {
14661 c.urlParams_.Set("fields", googleapi.CombineFields(s))
14662 return c
14663 }
14664
14665
14666
14667
14668
14669
14670 func (c *AccountPermissionsListCall) IfNoneMatch(entityTag string) *AccountPermissionsListCall {
14671 c.ifNoneMatch_ = entityTag
14672 return c
14673 }
14674
14675
14676
14677
14678 func (c *AccountPermissionsListCall) Context(ctx context.Context) *AccountPermissionsListCall {
14679 c.ctx_ = ctx
14680 return c
14681 }
14682
14683
14684
14685 func (c *AccountPermissionsListCall) Header() http.Header {
14686 if c.header_ == nil {
14687 c.header_ = make(http.Header)
14688 }
14689 return c.header_
14690 }
14691
14692 func (c *AccountPermissionsListCall) doRequest(alt string) (*http.Response, error) {
14693 reqHeaders := make(http.Header)
14694 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
14695 for k, v := range c.header_ {
14696 reqHeaders[k] = v
14697 }
14698 reqHeaders.Set("User-Agent", c.s.userAgent())
14699 if c.ifNoneMatch_ != "" {
14700 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
14701 }
14702 var body io.Reader = nil
14703 c.urlParams_.Set("alt", alt)
14704 c.urlParams_.Set("prettyPrint", "false")
14705 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/accountPermissions")
14706 urls += "?" + c.urlParams_.Encode()
14707 req, err := http.NewRequest("GET", urls, body)
14708 if err != nil {
14709 return nil, err
14710 }
14711 req.Header = reqHeaders
14712 googleapi.Expand(req.URL, map[string]string{
14713 "profileId": strconv.FormatInt(c.profileId, 10),
14714 })
14715 return gensupport.SendRequest(c.ctx_, c.s.client, req)
14716 }
14717
14718
14719
14720
14721
14722
14723
14724
14725 func (c *AccountPermissionsListCall) Do(opts ...googleapi.CallOption) (*AccountPermissionsListResponse, error) {
14726 gensupport.SetOptions(c.urlParams_, opts...)
14727 res, err := c.doRequest("json")
14728 if res != nil && res.StatusCode == http.StatusNotModified {
14729 if res.Body != nil {
14730 res.Body.Close()
14731 }
14732 return nil, &googleapi.Error{
14733 Code: res.StatusCode,
14734 Header: res.Header,
14735 }
14736 }
14737 if err != nil {
14738 return nil, err
14739 }
14740 defer googleapi.CloseBody(res)
14741 if err := googleapi.CheckResponse(res); err != nil {
14742 return nil, err
14743 }
14744 ret := &AccountPermissionsListResponse{
14745 ServerResponse: googleapi.ServerResponse{
14746 Header: res.Header,
14747 HTTPStatusCode: res.StatusCode,
14748 },
14749 }
14750 target := &ret
14751 if err := gensupport.DecodeResponse(target, res); err != nil {
14752 return nil, err
14753 }
14754 return ret, nil
14755
14756
14757
14758
14759
14760
14761
14762
14763
14764
14765
14766
14767
14768
14769
14770
14771
14772
14773
14774
14775
14776
14777
14778
14779
14780 }
14781
14782
14783
14784 type AccountUserProfilesGetCall struct {
14785 s *Service
14786 profileId int64
14787 id int64
14788 urlParams_ gensupport.URLParams
14789 ifNoneMatch_ string
14790 ctx_ context.Context
14791 header_ http.Header
14792 }
14793
14794
14795 func (r *AccountUserProfilesService) Get(profileId int64, id int64) *AccountUserProfilesGetCall {
14796 c := &AccountUserProfilesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
14797 c.profileId = profileId
14798 c.id = id
14799 return c
14800 }
14801
14802
14803
14804
14805 func (c *AccountUserProfilesGetCall) Fields(s ...googleapi.Field) *AccountUserProfilesGetCall {
14806 c.urlParams_.Set("fields", googleapi.CombineFields(s))
14807 return c
14808 }
14809
14810
14811
14812
14813
14814
14815 func (c *AccountUserProfilesGetCall) IfNoneMatch(entityTag string) *AccountUserProfilesGetCall {
14816 c.ifNoneMatch_ = entityTag
14817 return c
14818 }
14819
14820
14821
14822
14823 func (c *AccountUserProfilesGetCall) Context(ctx context.Context) *AccountUserProfilesGetCall {
14824 c.ctx_ = ctx
14825 return c
14826 }
14827
14828
14829
14830 func (c *AccountUserProfilesGetCall) Header() http.Header {
14831 if c.header_ == nil {
14832 c.header_ = make(http.Header)
14833 }
14834 return c.header_
14835 }
14836
14837 func (c *AccountUserProfilesGetCall) doRequest(alt string) (*http.Response, error) {
14838 reqHeaders := make(http.Header)
14839 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
14840 for k, v := range c.header_ {
14841 reqHeaders[k] = v
14842 }
14843 reqHeaders.Set("User-Agent", c.s.userAgent())
14844 if c.ifNoneMatch_ != "" {
14845 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
14846 }
14847 var body io.Reader = nil
14848 c.urlParams_.Set("alt", alt)
14849 c.urlParams_.Set("prettyPrint", "false")
14850 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/accountUserProfiles/{id}")
14851 urls += "?" + c.urlParams_.Encode()
14852 req, err := http.NewRequest("GET", urls, body)
14853 if err != nil {
14854 return nil, err
14855 }
14856 req.Header = reqHeaders
14857 googleapi.Expand(req.URL, map[string]string{
14858 "profileId": strconv.FormatInt(c.profileId, 10),
14859 "id": strconv.FormatInt(c.id, 10),
14860 })
14861 return gensupport.SendRequest(c.ctx_, c.s.client, req)
14862 }
14863
14864
14865
14866
14867
14868
14869
14870
14871 func (c *AccountUserProfilesGetCall) Do(opts ...googleapi.CallOption) (*AccountUserProfile, error) {
14872 gensupport.SetOptions(c.urlParams_, opts...)
14873 res, err := c.doRequest("json")
14874 if res != nil && res.StatusCode == http.StatusNotModified {
14875 if res.Body != nil {
14876 res.Body.Close()
14877 }
14878 return nil, &googleapi.Error{
14879 Code: res.StatusCode,
14880 Header: res.Header,
14881 }
14882 }
14883 if err != nil {
14884 return nil, err
14885 }
14886 defer googleapi.CloseBody(res)
14887 if err := googleapi.CheckResponse(res); err != nil {
14888 return nil, err
14889 }
14890 ret := &AccountUserProfile{
14891 ServerResponse: googleapi.ServerResponse{
14892 Header: res.Header,
14893 HTTPStatusCode: res.StatusCode,
14894 },
14895 }
14896 target := &ret
14897 if err := gensupport.DecodeResponse(target, res); err != nil {
14898 return nil, err
14899 }
14900 return ret, nil
14901
14902
14903
14904
14905
14906
14907
14908
14909
14910
14911
14912
14913
14914
14915
14916
14917
14918
14919
14920
14921
14922
14923
14924
14925
14926
14927
14928
14929
14930
14931
14932
14933
14934 }
14935
14936
14937
14938 type AccountUserProfilesInsertCall struct {
14939 s *Service
14940 profileId int64
14941 accountuserprofile *AccountUserProfile
14942 urlParams_ gensupport.URLParams
14943 ctx_ context.Context
14944 header_ http.Header
14945 }
14946
14947
14948 func (r *AccountUserProfilesService) Insert(profileId int64, accountuserprofile *AccountUserProfile) *AccountUserProfilesInsertCall {
14949 c := &AccountUserProfilesInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
14950 c.profileId = profileId
14951 c.accountuserprofile = accountuserprofile
14952 return c
14953 }
14954
14955
14956
14957
14958 func (c *AccountUserProfilesInsertCall) Fields(s ...googleapi.Field) *AccountUserProfilesInsertCall {
14959 c.urlParams_.Set("fields", googleapi.CombineFields(s))
14960 return c
14961 }
14962
14963
14964
14965
14966 func (c *AccountUserProfilesInsertCall) Context(ctx context.Context) *AccountUserProfilesInsertCall {
14967 c.ctx_ = ctx
14968 return c
14969 }
14970
14971
14972
14973 func (c *AccountUserProfilesInsertCall) Header() http.Header {
14974 if c.header_ == nil {
14975 c.header_ = make(http.Header)
14976 }
14977 return c.header_
14978 }
14979
14980 func (c *AccountUserProfilesInsertCall) doRequest(alt string) (*http.Response, error) {
14981 reqHeaders := make(http.Header)
14982 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
14983 for k, v := range c.header_ {
14984 reqHeaders[k] = v
14985 }
14986 reqHeaders.Set("User-Agent", c.s.userAgent())
14987 var body io.Reader = nil
14988 body, err := googleapi.WithoutDataWrapper.JSONReader(c.accountuserprofile)
14989 if err != nil {
14990 return nil, err
14991 }
14992 reqHeaders.Set("Content-Type", "application/json")
14993 c.urlParams_.Set("alt", alt)
14994 c.urlParams_.Set("prettyPrint", "false")
14995 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/accountUserProfiles")
14996 urls += "?" + c.urlParams_.Encode()
14997 req, err := http.NewRequest("POST", urls, body)
14998 if err != nil {
14999 return nil, err
15000 }
15001 req.Header = reqHeaders
15002 googleapi.Expand(req.URL, map[string]string{
15003 "profileId": strconv.FormatInt(c.profileId, 10),
15004 })
15005 return gensupport.SendRequest(c.ctx_, c.s.client, req)
15006 }
15007
15008
15009
15010
15011
15012
15013
15014
15015 func (c *AccountUserProfilesInsertCall) Do(opts ...googleapi.CallOption) (*AccountUserProfile, error) {
15016 gensupport.SetOptions(c.urlParams_, opts...)
15017 res, err := c.doRequest("json")
15018 if res != nil && res.StatusCode == http.StatusNotModified {
15019 if res.Body != nil {
15020 res.Body.Close()
15021 }
15022 return nil, &googleapi.Error{
15023 Code: res.StatusCode,
15024 Header: res.Header,
15025 }
15026 }
15027 if err != nil {
15028 return nil, err
15029 }
15030 defer googleapi.CloseBody(res)
15031 if err := googleapi.CheckResponse(res); err != nil {
15032 return nil, err
15033 }
15034 ret := &AccountUserProfile{
15035 ServerResponse: googleapi.ServerResponse{
15036 Header: res.Header,
15037 HTTPStatusCode: res.StatusCode,
15038 },
15039 }
15040 target := &ret
15041 if err := gensupport.DecodeResponse(target, res); err != nil {
15042 return nil, err
15043 }
15044 return ret, nil
15045
15046
15047
15048
15049
15050
15051
15052
15053
15054
15055
15056
15057
15058
15059
15060
15061
15062
15063
15064
15065
15066
15067
15068
15069
15070
15071
15072
15073 }
15074
15075
15076
15077 type AccountUserProfilesListCall struct {
15078 s *Service
15079 profileId int64
15080 urlParams_ gensupport.URLParams
15081 ifNoneMatch_ string
15082 ctx_ context.Context
15083 header_ http.Header
15084 }
15085
15086
15087
15088 func (r *AccountUserProfilesService) List(profileId int64) *AccountUserProfilesListCall {
15089 c := &AccountUserProfilesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
15090 c.profileId = profileId
15091 return c
15092 }
15093
15094
15095
15096 func (c *AccountUserProfilesListCall) Active(active bool) *AccountUserProfilesListCall {
15097 c.urlParams_.Set("active", fmt.Sprint(active))
15098 return c
15099 }
15100
15101
15102
15103 func (c *AccountUserProfilesListCall) Ids(ids ...int64) *AccountUserProfilesListCall {
15104 var ids_ []string
15105 for _, v := range ids {
15106 ids_ = append(ids_, fmt.Sprint(v))
15107 }
15108 c.urlParams_.SetMulti("ids", ids_)
15109 return c
15110 }
15111
15112
15113
15114 func (c *AccountUserProfilesListCall) MaxResults(maxResults int64) *AccountUserProfilesListCall {
15115 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
15116 return c
15117 }
15118
15119
15120
15121 func (c *AccountUserProfilesListCall) PageToken(pageToken string) *AccountUserProfilesListCall {
15122 c.urlParams_.Set("pageToken", pageToken)
15123 return c
15124 }
15125
15126
15127
15128
15129
15130
15131
15132
15133
15134
15135 func (c *AccountUserProfilesListCall) SearchString(searchString string) *AccountUserProfilesListCall {
15136 c.urlParams_.Set("searchString", searchString)
15137 return c
15138 }
15139
15140
15141
15142
15143
15144
15145
15146
15147 func (c *AccountUserProfilesListCall) SortField(sortField string) *AccountUserProfilesListCall {
15148 c.urlParams_.Set("sortField", sortField)
15149 return c
15150 }
15151
15152
15153
15154
15155
15156
15157
15158
15159 func (c *AccountUserProfilesListCall) SortOrder(sortOrder string) *AccountUserProfilesListCall {
15160 c.urlParams_.Set("sortOrder", sortOrder)
15161 return c
15162 }
15163
15164
15165
15166 func (c *AccountUserProfilesListCall) SubaccountId(subaccountId int64) *AccountUserProfilesListCall {
15167 c.urlParams_.Set("subaccountId", fmt.Sprint(subaccountId))
15168 return c
15169 }
15170
15171
15172
15173 func (c *AccountUserProfilesListCall) UserRoleId(userRoleId int64) *AccountUserProfilesListCall {
15174 c.urlParams_.Set("userRoleId", fmt.Sprint(userRoleId))
15175 return c
15176 }
15177
15178
15179
15180
15181 func (c *AccountUserProfilesListCall) Fields(s ...googleapi.Field) *AccountUserProfilesListCall {
15182 c.urlParams_.Set("fields", googleapi.CombineFields(s))
15183 return c
15184 }
15185
15186
15187
15188
15189
15190
15191 func (c *AccountUserProfilesListCall) IfNoneMatch(entityTag string) *AccountUserProfilesListCall {
15192 c.ifNoneMatch_ = entityTag
15193 return c
15194 }
15195
15196
15197
15198
15199 func (c *AccountUserProfilesListCall) Context(ctx context.Context) *AccountUserProfilesListCall {
15200 c.ctx_ = ctx
15201 return c
15202 }
15203
15204
15205
15206 func (c *AccountUserProfilesListCall) Header() http.Header {
15207 if c.header_ == nil {
15208 c.header_ = make(http.Header)
15209 }
15210 return c.header_
15211 }
15212
15213 func (c *AccountUserProfilesListCall) doRequest(alt string) (*http.Response, error) {
15214 reqHeaders := make(http.Header)
15215 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
15216 for k, v := range c.header_ {
15217 reqHeaders[k] = v
15218 }
15219 reqHeaders.Set("User-Agent", c.s.userAgent())
15220 if c.ifNoneMatch_ != "" {
15221 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
15222 }
15223 var body io.Reader = nil
15224 c.urlParams_.Set("alt", alt)
15225 c.urlParams_.Set("prettyPrint", "false")
15226 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/accountUserProfiles")
15227 urls += "?" + c.urlParams_.Encode()
15228 req, err := http.NewRequest("GET", urls, body)
15229 if err != nil {
15230 return nil, err
15231 }
15232 req.Header = reqHeaders
15233 googleapi.Expand(req.URL, map[string]string{
15234 "profileId": strconv.FormatInt(c.profileId, 10),
15235 })
15236 return gensupport.SendRequest(c.ctx_, c.s.client, req)
15237 }
15238
15239
15240
15241
15242
15243
15244
15245
15246 func (c *AccountUserProfilesListCall) Do(opts ...googleapi.CallOption) (*AccountUserProfilesListResponse, error) {
15247 gensupport.SetOptions(c.urlParams_, opts...)
15248 res, err := c.doRequest("json")
15249 if res != nil && res.StatusCode == http.StatusNotModified {
15250 if res.Body != nil {
15251 res.Body.Close()
15252 }
15253 return nil, &googleapi.Error{
15254 Code: res.StatusCode,
15255 Header: res.Header,
15256 }
15257 }
15258 if err != nil {
15259 return nil, err
15260 }
15261 defer googleapi.CloseBody(res)
15262 if err := googleapi.CheckResponse(res); err != nil {
15263 return nil, err
15264 }
15265 ret := &AccountUserProfilesListResponse{
15266 ServerResponse: googleapi.ServerResponse{
15267 Header: res.Header,
15268 HTTPStatusCode: res.StatusCode,
15269 },
15270 }
15271 target := &ret
15272 if err := gensupport.DecodeResponse(target, res); err != nil {
15273 return nil, err
15274 }
15275 return ret, nil
15276
15277
15278
15279
15280
15281
15282
15283
15284
15285
15286
15287
15288
15289
15290
15291
15292
15293
15294
15295
15296
15297
15298
15299
15300
15301
15302
15303
15304
15305
15306
15307
15308
15309
15310
15311
15312
15313
15314
15315
15316
15317
15318
15319
15320
15321
15322
15323
15324
15325
15326
15327
15328
15329
15330
15331
15332
15333
15334
15335
15336
15337
15338
15339
15340
15341
15342
15343
15344
15345
15346
15347
15348
15349
15350
15351
15352
15353
15354
15355
15356
15357
15358
15359
15360
15361
15362
15363
15364
15365
15366
15367
15368
15369
15370
15371
15372 }
15373
15374
15375
15376
15377 func (c *AccountUserProfilesListCall) Pages(ctx context.Context, f func(*AccountUserProfilesListResponse) error) error {
15378 c.ctx_ = ctx
15379 defer c.PageToken(c.urlParams_.Get("pageToken"))
15380 for {
15381 x, err := c.Do()
15382 if err != nil {
15383 return err
15384 }
15385 if err := f(x); err != nil {
15386 return err
15387 }
15388 if x.NextPageToken == "" {
15389 return nil
15390 }
15391 c.PageToken(x.NextPageToken)
15392 }
15393 }
15394
15395
15396
15397 type AccountUserProfilesPatchCall struct {
15398 s *Service
15399 profileId int64
15400 accountuserprofile *AccountUserProfile
15401 urlParams_ gensupport.URLParams
15402 ctx_ context.Context
15403 header_ http.Header
15404 }
15405
15406
15407
15408 func (r *AccountUserProfilesService) Patch(profileId int64, id int64, accountuserprofile *AccountUserProfile) *AccountUserProfilesPatchCall {
15409 c := &AccountUserProfilesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
15410 c.profileId = profileId
15411 c.urlParams_.Set("id", fmt.Sprint(id))
15412 c.accountuserprofile = accountuserprofile
15413 return c
15414 }
15415
15416
15417
15418
15419 func (c *AccountUserProfilesPatchCall) Fields(s ...googleapi.Field) *AccountUserProfilesPatchCall {
15420 c.urlParams_.Set("fields", googleapi.CombineFields(s))
15421 return c
15422 }
15423
15424
15425
15426
15427 func (c *AccountUserProfilesPatchCall) Context(ctx context.Context) *AccountUserProfilesPatchCall {
15428 c.ctx_ = ctx
15429 return c
15430 }
15431
15432
15433
15434 func (c *AccountUserProfilesPatchCall) Header() http.Header {
15435 if c.header_ == nil {
15436 c.header_ = make(http.Header)
15437 }
15438 return c.header_
15439 }
15440
15441 func (c *AccountUserProfilesPatchCall) doRequest(alt string) (*http.Response, error) {
15442 reqHeaders := make(http.Header)
15443 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
15444 for k, v := range c.header_ {
15445 reqHeaders[k] = v
15446 }
15447 reqHeaders.Set("User-Agent", c.s.userAgent())
15448 var body io.Reader = nil
15449 body, err := googleapi.WithoutDataWrapper.JSONReader(c.accountuserprofile)
15450 if err != nil {
15451 return nil, err
15452 }
15453 reqHeaders.Set("Content-Type", "application/json")
15454 c.urlParams_.Set("alt", alt)
15455 c.urlParams_.Set("prettyPrint", "false")
15456 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/accountUserProfiles")
15457 urls += "?" + c.urlParams_.Encode()
15458 req, err := http.NewRequest("PATCH", urls, body)
15459 if err != nil {
15460 return nil, err
15461 }
15462 req.Header = reqHeaders
15463 googleapi.Expand(req.URL, map[string]string{
15464 "profileId": strconv.FormatInt(c.profileId, 10),
15465 })
15466 return gensupport.SendRequest(c.ctx_, c.s.client, req)
15467 }
15468
15469
15470
15471
15472
15473
15474
15475
15476 func (c *AccountUserProfilesPatchCall) Do(opts ...googleapi.CallOption) (*AccountUserProfile, error) {
15477 gensupport.SetOptions(c.urlParams_, opts...)
15478 res, err := c.doRequest("json")
15479 if res != nil && res.StatusCode == http.StatusNotModified {
15480 if res.Body != nil {
15481 res.Body.Close()
15482 }
15483 return nil, &googleapi.Error{
15484 Code: res.StatusCode,
15485 Header: res.Header,
15486 }
15487 }
15488 if err != nil {
15489 return nil, err
15490 }
15491 defer googleapi.CloseBody(res)
15492 if err := googleapi.CheckResponse(res); err != nil {
15493 return nil, err
15494 }
15495 ret := &AccountUserProfile{
15496 ServerResponse: googleapi.ServerResponse{
15497 Header: res.Header,
15498 HTTPStatusCode: res.StatusCode,
15499 },
15500 }
15501 target := &ret
15502 if err := gensupport.DecodeResponse(target, res); err != nil {
15503 return nil, err
15504 }
15505 return ret, nil
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 type AccountUserProfilesUpdateCall struct {
15547 s *Service
15548 profileId int64
15549 accountuserprofile *AccountUserProfile
15550 urlParams_ gensupport.URLParams
15551 ctx_ context.Context
15552 header_ http.Header
15553 }
15554
15555
15556 func (r *AccountUserProfilesService) Update(profileId int64, accountuserprofile *AccountUserProfile) *AccountUserProfilesUpdateCall {
15557 c := &AccountUserProfilesUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
15558 c.profileId = profileId
15559 c.accountuserprofile = accountuserprofile
15560 return c
15561 }
15562
15563
15564
15565
15566 func (c *AccountUserProfilesUpdateCall) Fields(s ...googleapi.Field) *AccountUserProfilesUpdateCall {
15567 c.urlParams_.Set("fields", googleapi.CombineFields(s))
15568 return c
15569 }
15570
15571
15572
15573
15574 func (c *AccountUserProfilesUpdateCall) Context(ctx context.Context) *AccountUserProfilesUpdateCall {
15575 c.ctx_ = ctx
15576 return c
15577 }
15578
15579
15580
15581 func (c *AccountUserProfilesUpdateCall) Header() http.Header {
15582 if c.header_ == nil {
15583 c.header_ = make(http.Header)
15584 }
15585 return c.header_
15586 }
15587
15588 func (c *AccountUserProfilesUpdateCall) doRequest(alt string) (*http.Response, error) {
15589 reqHeaders := make(http.Header)
15590 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
15591 for k, v := range c.header_ {
15592 reqHeaders[k] = v
15593 }
15594 reqHeaders.Set("User-Agent", c.s.userAgent())
15595 var body io.Reader = nil
15596 body, err := googleapi.WithoutDataWrapper.JSONReader(c.accountuserprofile)
15597 if err != nil {
15598 return nil, err
15599 }
15600 reqHeaders.Set("Content-Type", "application/json")
15601 c.urlParams_.Set("alt", alt)
15602 c.urlParams_.Set("prettyPrint", "false")
15603 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/accountUserProfiles")
15604 urls += "?" + c.urlParams_.Encode()
15605 req, err := http.NewRequest("PUT", urls, body)
15606 if err != nil {
15607 return nil, err
15608 }
15609 req.Header = reqHeaders
15610 googleapi.Expand(req.URL, map[string]string{
15611 "profileId": strconv.FormatInt(c.profileId, 10),
15612 })
15613 return gensupport.SendRequest(c.ctx_, c.s.client, req)
15614 }
15615
15616
15617
15618
15619
15620
15621
15622
15623 func (c *AccountUserProfilesUpdateCall) Do(opts ...googleapi.CallOption) (*AccountUserProfile, error) {
15624 gensupport.SetOptions(c.urlParams_, opts...)
15625 res, err := c.doRequest("json")
15626 if res != nil && res.StatusCode == http.StatusNotModified {
15627 if res.Body != nil {
15628 res.Body.Close()
15629 }
15630 return nil, &googleapi.Error{
15631 Code: res.StatusCode,
15632 Header: res.Header,
15633 }
15634 }
15635 if err != nil {
15636 return nil, err
15637 }
15638 defer googleapi.CloseBody(res)
15639 if err := googleapi.CheckResponse(res); err != nil {
15640 return nil, err
15641 }
15642 ret := &AccountUserProfile{
15643 ServerResponse: googleapi.ServerResponse{
15644 Header: res.Header,
15645 HTTPStatusCode: res.StatusCode,
15646 },
15647 }
15648 target := &ret
15649 if err := gensupport.DecodeResponse(target, res); err != nil {
15650 return nil, err
15651 }
15652 return ret, nil
15653
15654
15655
15656
15657
15658
15659
15660
15661
15662
15663
15664
15665
15666
15667
15668
15669
15670
15671
15672
15673
15674
15675
15676
15677
15678
15679
15680
15681 }
15682
15683
15684
15685 type AccountsGetCall struct {
15686 s *Service
15687 profileId int64
15688 id int64
15689 urlParams_ gensupport.URLParams
15690 ifNoneMatch_ string
15691 ctx_ context.Context
15692 header_ http.Header
15693 }
15694
15695
15696 func (r *AccountsService) Get(profileId int64, id int64) *AccountsGetCall {
15697 c := &AccountsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
15698 c.profileId = profileId
15699 c.id = id
15700 return c
15701 }
15702
15703
15704
15705
15706 func (c *AccountsGetCall) Fields(s ...googleapi.Field) *AccountsGetCall {
15707 c.urlParams_.Set("fields", googleapi.CombineFields(s))
15708 return c
15709 }
15710
15711
15712
15713
15714
15715
15716 func (c *AccountsGetCall) IfNoneMatch(entityTag string) *AccountsGetCall {
15717 c.ifNoneMatch_ = entityTag
15718 return c
15719 }
15720
15721
15722
15723
15724 func (c *AccountsGetCall) Context(ctx context.Context) *AccountsGetCall {
15725 c.ctx_ = ctx
15726 return c
15727 }
15728
15729
15730
15731 func (c *AccountsGetCall) Header() http.Header {
15732 if c.header_ == nil {
15733 c.header_ = make(http.Header)
15734 }
15735 return c.header_
15736 }
15737
15738 func (c *AccountsGetCall) doRequest(alt string) (*http.Response, error) {
15739 reqHeaders := make(http.Header)
15740 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
15741 for k, v := range c.header_ {
15742 reqHeaders[k] = v
15743 }
15744 reqHeaders.Set("User-Agent", c.s.userAgent())
15745 if c.ifNoneMatch_ != "" {
15746 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
15747 }
15748 var body io.Reader = nil
15749 c.urlParams_.Set("alt", alt)
15750 c.urlParams_.Set("prettyPrint", "false")
15751 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/accounts/{id}")
15752 urls += "?" + c.urlParams_.Encode()
15753 req, err := http.NewRequest("GET", urls, body)
15754 if err != nil {
15755 return nil, err
15756 }
15757 req.Header = reqHeaders
15758 googleapi.Expand(req.URL, map[string]string{
15759 "profileId": strconv.FormatInt(c.profileId, 10),
15760 "id": strconv.FormatInt(c.id, 10),
15761 })
15762 return gensupport.SendRequest(c.ctx_, c.s.client, req)
15763 }
15764
15765
15766
15767
15768
15769
15770
15771
15772 func (c *AccountsGetCall) Do(opts ...googleapi.CallOption) (*Account, error) {
15773 gensupport.SetOptions(c.urlParams_, opts...)
15774 res, err := c.doRequest("json")
15775 if res != nil && res.StatusCode == http.StatusNotModified {
15776 if res.Body != nil {
15777 res.Body.Close()
15778 }
15779 return nil, &googleapi.Error{
15780 Code: res.StatusCode,
15781 Header: res.Header,
15782 }
15783 }
15784 if err != nil {
15785 return nil, err
15786 }
15787 defer googleapi.CloseBody(res)
15788 if err := googleapi.CheckResponse(res); err != nil {
15789 return nil, err
15790 }
15791 ret := &Account{
15792 ServerResponse: googleapi.ServerResponse{
15793 Header: res.Header,
15794 HTTPStatusCode: res.StatusCode,
15795 },
15796 }
15797 target := &ret
15798 if err := gensupport.DecodeResponse(target, res); err != nil {
15799 return nil, err
15800 }
15801 return ret, nil
15802
15803
15804
15805
15806
15807
15808
15809
15810
15811
15812
15813
15814
15815
15816
15817
15818
15819
15820
15821
15822
15823
15824
15825
15826
15827
15828
15829
15830
15831
15832
15833
15834
15835 }
15836
15837
15838
15839 type AccountsListCall struct {
15840 s *Service
15841 profileId int64
15842 urlParams_ gensupport.URLParams
15843 ifNoneMatch_ string
15844 ctx_ context.Context
15845 header_ http.Header
15846 }
15847
15848
15849
15850 func (r *AccountsService) List(profileId int64) *AccountsListCall {
15851 c := &AccountsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
15852 c.profileId = profileId
15853 return c
15854 }
15855
15856
15857
15858
15859 func (c *AccountsListCall) Active(active bool) *AccountsListCall {
15860 c.urlParams_.Set("active", fmt.Sprint(active))
15861 return c
15862 }
15863
15864
15865
15866 func (c *AccountsListCall) Ids(ids ...int64) *AccountsListCall {
15867 var ids_ []string
15868 for _, v := range ids {
15869 ids_ = append(ids_, fmt.Sprint(v))
15870 }
15871 c.urlParams_.SetMulti("ids", ids_)
15872 return c
15873 }
15874
15875
15876
15877 func (c *AccountsListCall) MaxResults(maxResults int64) *AccountsListCall {
15878 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
15879 return c
15880 }
15881
15882
15883
15884 func (c *AccountsListCall) PageToken(pageToken string) *AccountsListCall {
15885 c.urlParams_.Set("pageToken", pageToken)
15886 return c
15887 }
15888
15889
15890
15891
15892
15893
15894
15895
15896
15897 func (c *AccountsListCall) SearchString(searchString string) *AccountsListCall {
15898 c.urlParams_.Set("searchString", searchString)
15899 return c
15900 }
15901
15902
15903
15904
15905
15906
15907
15908
15909 func (c *AccountsListCall) SortField(sortField string) *AccountsListCall {
15910 c.urlParams_.Set("sortField", sortField)
15911 return c
15912 }
15913
15914
15915
15916
15917
15918
15919
15920
15921 func (c *AccountsListCall) SortOrder(sortOrder string) *AccountsListCall {
15922 c.urlParams_.Set("sortOrder", sortOrder)
15923 return c
15924 }
15925
15926
15927
15928
15929 func (c *AccountsListCall) Fields(s ...googleapi.Field) *AccountsListCall {
15930 c.urlParams_.Set("fields", googleapi.CombineFields(s))
15931 return c
15932 }
15933
15934
15935
15936
15937
15938
15939 func (c *AccountsListCall) IfNoneMatch(entityTag string) *AccountsListCall {
15940 c.ifNoneMatch_ = entityTag
15941 return c
15942 }
15943
15944
15945
15946
15947 func (c *AccountsListCall) Context(ctx context.Context) *AccountsListCall {
15948 c.ctx_ = ctx
15949 return c
15950 }
15951
15952
15953
15954 func (c *AccountsListCall) Header() http.Header {
15955 if c.header_ == nil {
15956 c.header_ = make(http.Header)
15957 }
15958 return c.header_
15959 }
15960
15961 func (c *AccountsListCall) doRequest(alt string) (*http.Response, error) {
15962 reqHeaders := make(http.Header)
15963 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
15964 for k, v := range c.header_ {
15965 reqHeaders[k] = v
15966 }
15967 reqHeaders.Set("User-Agent", c.s.userAgent())
15968 if c.ifNoneMatch_ != "" {
15969 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
15970 }
15971 var body io.Reader = nil
15972 c.urlParams_.Set("alt", alt)
15973 c.urlParams_.Set("prettyPrint", "false")
15974 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/accounts")
15975 urls += "?" + c.urlParams_.Encode()
15976 req, err := http.NewRequest("GET", urls, body)
15977 if err != nil {
15978 return nil, err
15979 }
15980 req.Header = reqHeaders
15981 googleapi.Expand(req.URL, map[string]string{
15982 "profileId": strconv.FormatInt(c.profileId, 10),
15983 })
15984 return gensupport.SendRequest(c.ctx_, c.s.client, req)
15985 }
15986
15987
15988
15989
15990
15991
15992
15993
15994 func (c *AccountsListCall) Do(opts ...googleapi.CallOption) (*AccountsListResponse, error) {
15995 gensupport.SetOptions(c.urlParams_, opts...)
15996 res, err := c.doRequest("json")
15997 if res != nil && res.StatusCode == http.StatusNotModified {
15998 if res.Body != nil {
15999 res.Body.Close()
16000 }
16001 return nil, &googleapi.Error{
16002 Code: res.StatusCode,
16003 Header: res.Header,
16004 }
16005 }
16006 if err != nil {
16007 return nil, err
16008 }
16009 defer googleapi.CloseBody(res)
16010 if err := googleapi.CheckResponse(res); err != nil {
16011 return nil, err
16012 }
16013 ret := &AccountsListResponse{
16014 ServerResponse: googleapi.ServerResponse{
16015 Header: res.Header,
16016 HTTPStatusCode: res.StatusCode,
16017 },
16018 }
16019 target := &ret
16020 if err := gensupport.DecodeResponse(target, res); err != nil {
16021 return nil, err
16022 }
16023 return ret, nil
16024
16025
16026
16027
16028
16029
16030
16031
16032
16033
16034
16035
16036
16037
16038
16039
16040
16041
16042
16043
16044
16045
16046
16047
16048
16049
16050
16051
16052
16053
16054
16055
16056
16057
16058
16059
16060
16061
16062
16063
16064
16065
16066
16067
16068
16069
16070
16071
16072
16073
16074
16075
16076
16077
16078
16079
16080
16081
16082
16083
16084
16085
16086
16087
16088
16089
16090
16091
16092
16093
16094
16095
16096
16097
16098
16099
16100
16101
16102
16103
16104
16105
16106
16107
16108 }
16109
16110
16111
16112
16113 func (c *AccountsListCall) Pages(ctx context.Context, f func(*AccountsListResponse) error) error {
16114 c.ctx_ = ctx
16115 defer c.PageToken(c.urlParams_.Get("pageToken"))
16116 for {
16117 x, err := c.Do()
16118 if err != nil {
16119 return err
16120 }
16121 if err := f(x); err != nil {
16122 return err
16123 }
16124 if x.NextPageToken == "" {
16125 return nil
16126 }
16127 c.PageToken(x.NextPageToken)
16128 }
16129 }
16130
16131
16132
16133 type AccountsPatchCall struct {
16134 s *Service
16135 profileId int64
16136 account *Account
16137 urlParams_ gensupport.URLParams
16138 ctx_ context.Context
16139 header_ http.Header
16140 }
16141
16142
16143
16144 func (r *AccountsService) Patch(profileId int64, id int64, account *Account) *AccountsPatchCall {
16145 c := &AccountsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
16146 c.profileId = profileId
16147 c.urlParams_.Set("id", fmt.Sprint(id))
16148 c.account = account
16149 return c
16150 }
16151
16152
16153
16154
16155 func (c *AccountsPatchCall) Fields(s ...googleapi.Field) *AccountsPatchCall {
16156 c.urlParams_.Set("fields", googleapi.CombineFields(s))
16157 return c
16158 }
16159
16160
16161
16162
16163 func (c *AccountsPatchCall) Context(ctx context.Context) *AccountsPatchCall {
16164 c.ctx_ = ctx
16165 return c
16166 }
16167
16168
16169
16170 func (c *AccountsPatchCall) Header() http.Header {
16171 if c.header_ == nil {
16172 c.header_ = make(http.Header)
16173 }
16174 return c.header_
16175 }
16176
16177 func (c *AccountsPatchCall) doRequest(alt string) (*http.Response, error) {
16178 reqHeaders := make(http.Header)
16179 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
16180 for k, v := range c.header_ {
16181 reqHeaders[k] = v
16182 }
16183 reqHeaders.Set("User-Agent", c.s.userAgent())
16184 var body io.Reader = nil
16185 body, err := googleapi.WithoutDataWrapper.JSONReader(c.account)
16186 if err != nil {
16187 return nil, err
16188 }
16189 reqHeaders.Set("Content-Type", "application/json")
16190 c.urlParams_.Set("alt", alt)
16191 c.urlParams_.Set("prettyPrint", "false")
16192 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/accounts")
16193 urls += "?" + c.urlParams_.Encode()
16194 req, err := http.NewRequest("PATCH", urls, body)
16195 if err != nil {
16196 return nil, err
16197 }
16198 req.Header = reqHeaders
16199 googleapi.Expand(req.URL, map[string]string{
16200 "profileId": strconv.FormatInt(c.profileId, 10),
16201 })
16202 return gensupport.SendRequest(c.ctx_, c.s.client, req)
16203 }
16204
16205
16206
16207
16208
16209
16210
16211
16212 func (c *AccountsPatchCall) Do(opts ...googleapi.CallOption) (*Account, error) {
16213 gensupport.SetOptions(c.urlParams_, opts...)
16214 res, err := c.doRequest("json")
16215 if res != nil && res.StatusCode == http.StatusNotModified {
16216 if res.Body != nil {
16217 res.Body.Close()
16218 }
16219 return nil, &googleapi.Error{
16220 Code: res.StatusCode,
16221 Header: res.Header,
16222 }
16223 }
16224 if err != nil {
16225 return nil, err
16226 }
16227 defer googleapi.CloseBody(res)
16228 if err := googleapi.CheckResponse(res); err != nil {
16229 return nil, err
16230 }
16231 ret := &Account{
16232 ServerResponse: googleapi.ServerResponse{
16233 Header: res.Header,
16234 HTTPStatusCode: res.StatusCode,
16235 },
16236 }
16237 target := &ret
16238 if err := gensupport.DecodeResponse(target, res); err != nil {
16239 return nil, err
16240 }
16241 return ret, nil
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 type AccountsUpdateCall struct {
16283 s *Service
16284 profileId int64
16285 account *Account
16286 urlParams_ gensupport.URLParams
16287 ctx_ context.Context
16288 header_ http.Header
16289 }
16290
16291
16292 func (r *AccountsService) Update(profileId int64, account *Account) *AccountsUpdateCall {
16293 c := &AccountsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
16294 c.profileId = profileId
16295 c.account = account
16296 return c
16297 }
16298
16299
16300
16301
16302 func (c *AccountsUpdateCall) Fields(s ...googleapi.Field) *AccountsUpdateCall {
16303 c.urlParams_.Set("fields", googleapi.CombineFields(s))
16304 return c
16305 }
16306
16307
16308
16309
16310 func (c *AccountsUpdateCall) Context(ctx context.Context) *AccountsUpdateCall {
16311 c.ctx_ = ctx
16312 return c
16313 }
16314
16315
16316
16317 func (c *AccountsUpdateCall) Header() http.Header {
16318 if c.header_ == nil {
16319 c.header_ = make(http.Header)
16320 }
16321 return c.header_
16322 }
16323
16324 func (c *AccountsUpdateCall) doRequest(alt string) (*http.Response, error) {
16325 reqHeaders := make(http.Header)
16326 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
16327 for k, v := range c.header_ {
16328 reqHeaders[k] = v
16329 }
16330 reqHeaders.Set("User-Agent", c.s.userAgent())
16331 var body io.Reader = nil
16332 body, err := googleapi.WithoutDataWrapper.JSONReader(c.account)
16333 if err != nil {
16334 return nil, err
16335 }
16336 reqHeaders.Set("Content-Type", "application/json")
16337 c.urlParams_.Set("alt", alt)
16338 c.urlParams_.Set("prettyPrint", "false")
16339 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/accounts")
16340 urls += "?" + c.urlParams_.Encode()
16341 req, err := http.NewRequest("PUT", urls, body)
16342 if err != nil {
16343 return nil, err
16344 }
16345 req.Header = reqHeaders
16346 googleapi.Expand(req.URL, map[string]string{
16347 "profileId": strconv.FormatInt(c.profileId, 10),
16348 })
16349 return gensupport.SendRequest(c.ctx_, c.s.client, req)
16350 }
16351
16352
16353
16354
16355
16356
16357
16358
16359 func (c *AccountsUpdateCall) Do(opts ...googleapi.CallOption) (*Account, error) {
16360 gensupport.SetOptions(c.urlParams_, opts...)
16361 res, err := c.doRequest("json")
16362 if res != nil && res.StatusCode == http.StatusNotModified {
16363 if res.Body != nil {
16364 res.Body.Close()
16365 }
16366 return nil, &googleapi.Error{
16367 Code: res.StatusCode,
16368 Header: res.Header,
16369 }
16370 }
16371 if err != nil {
16372 return nil, err
16373 }
16374 defer googleapi.CloseBody(res)
16375 if err := googleapi.CheckResponse(res); err != nil {
16376 return nil, err
16377 }
16378 ret := &Account{
16379 ServerResponse: googleapi.ServerResponse{
16380 Header: res.Header,
16381 HTTPStatusCode: res.StatusCode,
16382 },
16383 }
16384 target := &ret
16385 if err := gensupport.DecodeResponse(target, res); err != nil {
16386 return nil, err
16387 }
16388 return ret, nil
16389
16390
16391
16392
16393
16394
16395
16396
16397
16398
16399
16400
16401
16402
16403
16404
16405
16406
16407
16408
16409
16410
16411
16412
16413
16414
16415
16416
16417 }
16418
16419
16420
16421 type AdsGetCall struct {
16422 s *Service
16423 profileId int64
16424 id int64
16425 urlParams_ gensupport.URLParams
16426 ifNoneMatch_ string
16427 ctx_ context.Context
16428 header_ http.Header
16429 }
16430
16431
16432 func (r *AdsService) Get(profileId int64, id int64) *AdsGetCall {
16433 c := &AdsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
16434 c.profileId = profileId
16435 c.id = id
16436 return c
16437 }
16438
16439
16440
16441
16442 func (c *AdsGetCall) Fields(s ...googleapi.Field) *AdsGetCall {
16443 c.urlParams_.Set("fields", googleapi.CombineFields(s))
16444 return c
16445 }
16446
16447
16448
16449
16450
16451
16452 func (c *AdsGetCall) IfNoneMatch(entityTag string) *AdsGetCall {
16453 c.ifNoneMatch_ = entityTag
16454 return c
16455 }
16456
16457
16458
16459
16460 func (c *AdsGetCall) Context(ctx context.Context) *AdsGetCall {
16461 c.ctx_ = ctx
16462 return c
16463 }
16464
16465
16466
16467 func (c *AdsGetCall) Header() http.Header {
16468 if c.header_ == nil {
16469 c.header_ = make(http.Header)
16470 }
16471 return c.header_
16472 }
16473
16474 func (c *AdsGetCall) doRequest(alt string) (*http.Response, error) {
16475 reqHeaders := make(http.Header)
16476 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
16477 for k, v := range c.header_ {
16478 reqHeaders[k] = v
16479 }
16480 reqHeaders.Set("User-Agent", c.s.userAgent())
16481 if c.ifNoneMatch_ != "" {
16482 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
16483 }
16484 var body io.Reader = nil
16485 c.urlParams_.Set("alt", alt)
16486 c.urlParams_.Set("prettyPrint", "false")
16487 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/ads/{id}")
16488 urls += "?" + c.urlParams_.Encode()
16489 req, err := http.NewRequest("GET", urls, body)
16490 if err != nil {
16491 return nil, err
16492 }
16493 req.Header = reqHeaders
16494 googleapi.Expand(req.URL, map[string]string{
16495 "profileId": strconv.FormatInt(c.profileId, 10),
16496 "id": strconv.FormatInt(c.id, 10),
16497 })
16498 return gensupport.SendRequest(c.ctx_, c.s.client, req)
16499 }
16500
16501
16502
16503
16504
16505
16506
16507
16508 func (c *AdsGetCall) Do(opts ...googleapi.CallOption) (*Ad, error) {
16509 gensupport.SetOptions(c.urlParams_, opts...)
16510 res, err := c.doRequest("json")
16511 if res != nil && res.StatusCode == http.StatusNotModified {
16512 if res.Body != nil {
16513 res.Body.Close()
16514 }
16515 return nil, &googleapi.Error{
16516 Code: res.StatusCode,
16517 Header: res.Header,
16518 }
16519 }
16520 if err != nil {
16521 return nil, err
16522 }
16523 defer googleapi.CloseBody(res)
16524 if err := googleapi.CheckResponse(res); err != nil {
16525 return nil, err
16526 }
16527 ret := &Ad{
16528 ServerResponse: googleapi.ServerResponse{
16529 Header: res.Header,
16530 HTTPStatusCode: res.StatusCode,
16531 },
16532 }
16533 target := &ret
16534 if err := gensupport.DecodeResponse(target, res); err != nil {
16535 return nil, err
16536 }
16537 return ret, nil
16538
16539
16540
16541
16542
16543
16544
16545
16546
16547
16548
16549
16550
16551
16552
16553
16554
16555
16556
16557
16558
16559
16560
16561
16562
16563
16564
16565
16566
16567
16568
16569
16570
16571 }
16572
16573
16574
16575 type AdsInsertCall struct {
16576 s *Service
16577 profileId int64
16578 ad *Ad
16579 urlParams_ gensupport.URLParams
16580 ctx_ context.Context
16581 header_ http.Header
16582 }
16583
16584
16585 func (r *AdsService) Insert(profileId int64, ad *Ad) *AdsInsertCall {
16586 c := &AdsInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
16587 c.profileId = profileId
16588 c.ad = ad
16589 return c
16590 }
16591
16592
16593
16594
16595 func (c *AdsInsertCall) Fields(s ...googleapi.Field) *AdsInsertCall {
16596 c.urlParams_.Set("fields", googleapi.CombineFields(s))
16597 return c
16598 }
16599
16600
16601
16602
16603 func (c *AdsInsertCall) Context(ctx context.Context) *AdsInsertCall {
16604 c.ctx_ = ctx
16605 return c
16606 }
16607
16608
16609
16610 func (c *AdsInsertCall) Header() http.Header {
16611 if c.header_ == nil {
16612 c.header_ = make(http.Header)
16613 }
16614 return c.header_
16615 }
16616
16617 func (c *AdsInsertCall) doRequest(alt string) (*http.Response, error) {
16618 reqHeaders := make(http.Header)
16619 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
16620 for k, v := range c.header_ {
16621 reqHeaders[k] = v
16622 }
16623 reqHeaders.Set("User-Agent", c.s.userAgent())
16624 var body io.Reader = nil
16625 body, err := googleapi.WithoutDataWrapper.JSONReader(c.ad)
16626 if err != nil {
16627 return nil, err
16628 }
16629 reqHeaders.Set("Content-Type", "application/json")
16630 c.urlParams_.Set("alt", alt)
16631 c.urlParams_.Set("prettyPrint", "false")
16632 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/ads")
16633 urls += "?" + c.urlParams_.Encode()
16634 req, err := http.NewRequest("POST", urls, body)
16635 if err != nil {
16636 return nil, err
16637 }
16638 req.Header = reqHeaders
16639 googleapi.Expand(req.URL, map[string]string{
16640 "profileId": strconv.FormatInt(c.profileId, 10),
16641 })
16642 return gensupport.SendRequest(c.ctx_, c.s.client, req)
16643 }
16644
16645
16646
16647
16648
16649
16650
16651
16652 func (c *AdsInsertCall) Do(opts ...googleapi.CallOption) (*Ad, error) {
16653 gensupport.SetOptions(c.urlParams_, opts...)
16654 res, err := c.doRequest("json")
16655 if res != nil && res.StatusCode == http.StatusNotModified {
16656 if res.Body != nil {
16657 res.Body.Close()
16658 }
16659 return nil, &googleapi.Error{
16660 Code: res.StatusCode,
16661 Header: res.Header,
16662 }
16663 }
16664 if err != nil {
16665 return nil, err
16666 }
16667 defer googleapi.CloseBody(res)
16668 if err := googleapi.CheckResponse(res); err != nil {
16669 return nil, err
16670 }
16671 ret := &Ad{
16672 ServerResponse: googleapi.ServerResponse{
16673 Header: res.Header,
16674 HTTPStatusCode: res.StatusCode,
16675 },
16676 }
16677 target := &ret
16678 if err := gensupport.DecodeResponse(target, res); err != nil {
16679 return nil, err
16680 }
16681 return ret, nil
16682
16683
16684
16685
16686
16687
16688
16689
16690
16691
16692
16693
16694
16695
16696
16697
16698
16699
16700
16701
16702
16703
16704
16705
16706
16707
16708
16709
16710 }
16711
16712
16713
16714 type AdsListCall struct {
16715 s *Service
16716 profileId int64
16717 urlParams_ gensupport.URLParams
16718 ifNoneMatch_ string
16719 ctx_ context.Context
16720 header_ http.Header
16721 }
16722
16723
16724
16725 func (r *AdsService) List(profileId int64) *AdsListCall {
16726 c := &AdsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
16727 c.profileId = profileId
16728 return c
16729 }
16730
16731
16732 func (c *AdsListCall) Active(active bool) *AdsListCall {
16733 c.urlParams_.Set("active", fmt.Sprint(active))
16734 return c
16735 }
16736
16737
16738
16739 func (c *AdsListCall) AdvertiserId(advertiserId int64) *AdsListCall {
16740 c.urlParams_.Set("advertiserId", fmt.Sprint(advertiserId))
16741 return c
16742 }
16743
16744
16745
16746 func (c *AdsListCall) Archived(archived bool) *AdsListCall {
16747 c.urlParams_.Set("archived", fmt.Sprint(archived))
16748 return c
16749 }
16750
16751
16752
16753 func (c *AdsListCall) AudienceSegmentIds(audienceSegmentIds ...int64) *AdsListCall {
16754 var audienceSegmentIds_ []string
16755 for _, v := range audienceSegmentIds {
16756 audienceSegmentIds_ = append(audienceSegmentIds_, fmt.Sprint(v))
16757 }
16758 c.urlParams_.SetMulti("audienceSegmentIds", audienceSegmentIds_)
16759 return c
16760 }
16761
16762
16763
16764 func (c *AdsListCall) CampaignIds(campaignIds ...int64) *AdsListCall {
16765 var campaignIds_ []string
16766 for _, v := range campaignIds {
16767 campaignIds_ = append(campaignIds_, fmt.Sprint(v))
16768 }
16769 c.urlParams_.SetMulti("campaignIds", campaignIds_)
16770 return c
16771 }
16772
16773
16774
16775
16776
16777
16778
16779
16780
16781
16782
16783
16784
16785
16786
16787
16788
16789 func (c *AdsListCall) Compatibility(compatibility string) *AdsListCall {
16790 c.urlParams_.Set("compatibility", compatibility)
16791 return c
16792 }
16793
16794
16795
16796 func (c *AdsListCall) CreativeIds(creativeIds ...int64) *AdsListCall {
16797 var creativeIds_ []string
16798 for _, v := range creativeIds {
16799 creativeIds_ = append(creativeIds_, fmt.Sprint(v))
16800 }
16801 c.urlParams_.SetMulti("creativeIds", creativeIds_)
16802 return c
16803 }
16804
16805
16806
16807
16808 func (c *AdsListCall) CreativeOptimizationConfigurationIds(creativeOptimizationConfigurationIds ...int64) *AdsListCall {
16809 var creativeOptimizationConfigurationIds_ []string
16810 for _, v := range creativeOptimizationConfigurationIds {
16811 creativeOptimizationConfigurationIds_ = append(creativeOptimizationConfigurationIds_, fmt.Sprint(v))
16812 }
16813 c.urlParams_.SetMulti("creativeOptimizationConfigurationIds", creativeOptimizationConfigurationIds_)
16814 return c
16815 }
16816
16817
16818
16819
16820
16821
16822 func (c *AdsListCall) DynamicClickTracker(dynamicClickTracker bool) *AdsListCall {
16823 c.urlParams_.Set("dynamicClickTracker", fmt.Sprint(dynamicClickTracker))
16824 return c
16825 }
16826
16827
16828
16829 func (c *AdsListCall) Ids(ids ...int64) *AdsListCall {
16830 var ids_ []string
16831 for _, v := range ids {
16832 ids_ = append(ids_, fmt.Sprint(v))
16833 }
16834 c.urlParams_.SetMulti("ids", ids_)
16835 return c
16836 }
16837
16838
16839
16840 func (c *AdsListCall) LandingPageIds(landingPageIds ...int64) *AdsListCall {
16841 var landingPageIds_ []string
16842 for _, v := range landingPageIds {
16843 landingPageIds_ = append(landingPageIds_, fmt.Sprint(v))
16844 }
16845 c.urlParams_.SetMulti("landingPageIds", landingPageIds_)
16846 return c
16847 }
16848
16849
16850
16851 func (c *AdsListCall) MaxResults(maxResults int64) *AdsListCall {
16852 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
16853 return c
16854 }
16855
16856
16857
16858
16859 func (c *AdsListCall) OverriddenEventTagId(overriddenEventTagId int64) *AdsListCall {
16860 c.urlParams_.Set("overriddenEventTagId", fmt.Sprint(overriddenEventTagId))
16861 return c
16862 }
16863
16864
16865
16866 func (c *AdsListCall) PageToken(pageToken string) *AdsListCall {
16867 c.urlParams_.Set("pageToken", pageToken)
16868 return c
16869 }
16870
16871
16872
16873 func (c *AdsListCall) PlacementIds(placementIds ...int64) *AdsListCall {
16874 var placementIds_ []string
16875 for _, v := range placementIds {
16876 placementIds_ = append(placementIds_, fmt.Sprint(v))
16877 }
16878 c.urlParams_.SetMulti("placementIds", placementIds_)
16879 return c
16880 }
16881
16882
16883
16884
16885 func (c *AdsListCall) RemarketingListIds(remarketingListIds ...int64) *AdsListCall {
16886 var remarketingListIds_ []string
16887 for _, v := range remarketingListIds {
16888 remarketingListIds_ = append(remarketingListIds_, fmt.Sprint(v))
16889 }
16890 c.urlParams_.SetMulti("remarketingListIds", remarketingListIds_)
16891 return c
16892 }
16893
16894
16895
16896
16897
16898
16899
16900
16901 func (c *AdsListCall) SearchString(searchString string) *AdsListCall {
16902 c.urlParams_.Set("searchString", searchString)
16903 return c
16904 }
16905
16906
16907
16908 func (c *AdsListCall) SizeIds(sizeIds ...int64) *AdsListCall {
16909 var sizeIds_ []string
16910 for _, v := range sizeIds {
16911 sizeIds_ = append(sizeIds_, fmt.Sprint(v))
16912 }
16913 c.urlParams_.SetMulti("sizeIds", sizeIds_)
16914 return c
16915 }
16916
16917
16918
16919
16920
16921
16922
16923
16924 func (c *AdsListCall) SortField(sortField string) *AdsListCall {
16925 c.urlParams_.Set("sortField", sortField)
16926 return c
16927 }
16928
16929
16930
16931
16932
16933
16934
16935
16936 func (c *AdsListCall) SortOrder(sortOrder string) *AdsListCall {
16937 c.urlParams_.Set("sortOrder", sortOrder)
16938 return c
16939 }
16940
16941
16942
16943 func (c *AdsListCall) SslCompliant(sslCompliant bool) *AdsListCall {
16944 c.urlParams_.Set("sslCompliant", fmt.Sprint(sslCompliant))
16945 return c
16946 }
16947
16948
16949
16950 func (c *AdsListCall) SslRequired(sslRequired bool) *AdsListCall {
16951 c.urlParams_.Set("sslRequired", fmt.Sprint(sslRequired))
16952 return c
16953 }
16954
16955
16956
16957
16958
16959
16960
16961
16962
16963
16964 func (c *AdsListCall) Type(type_ ...string) *AdsListCall {
16965 c.urlParams_.SetMulti("type", append([]string{}, type_...))
16966 return c
16967 }
16968
16969
16970
16971
16972 func (c *AdsListCall) Fields(s ...googleapi.Field) *AdsListCall {
16973 c.urlParams_.Set("fields", googleapi.CombineFields(s))
16974 return c
16975 }
16976
16977
16978
16979
16980
16981
16982 func (c *AdsListCall) IfNoneMatch(entityTag string) *AdsListCall {
16983 c.ifNoneMatch_ = entityTag
16984 return c
16985 }
16986
16987
16988
16989
16990 func (c *AdsListCall) Context(ctx context.Context) *AdsListCall {
16991 c.ctx_ = ctx
16992 return c
16993 }
16994
16995
16996
16997 func (c *AdsListCall) Header() http.Header {
16998 if c.header_ == nil {
16999 c.header_ = make(http.Header)
17000 }
17001 return c.header_
17002 }
17003
17004 func (c *AdsListCall) doRequest(alt string) (*http.Response, error) {
17005 reqHeaders := make(http.Header)
17006 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
17007 for k, v := range c.header_ {
17008 reqHeaders[k] = v
17009 }
17010 reqHeaders.Set("User-Agent", c.s.userAgent())
17011 if c.ifNoneMatch_ != "" {
17012 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
17013 }
17014 var body io.Reader = nil
17015 c.urlParams_.Set("alt", alt)
17016 c.urlParams_.Set("prettyPrint", "false")
17017 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/ads")
17018 urls += "?" + c.urlParams_.Encode()
17019 req, err := http.NewRequest("GET", urls, body)
17020 if err != nil {
17021 return nil, err
17022 }
17023 req.Header = reqHeaders
17024 googleapi.Expand(req.URL, map[string]string{
17025 "profileId": strconv.FormatInt(c.profileId, 10),
17026 })
17027 return gensupport.SendRequest(c.ctx_, c.s.client, req)
17028 }
17029
17030
17031
17032
17033
17034
17035
17036
17037 func (c *AdsListCall) Do(opts ...googleapi.CallOption) (*AdsListResponse, error) {
17038 gensupport.SetOptions(c.urlParams_, opts...)
17039 res, err := c.doRequest("json")
17040 if res != nil && res.StatusCode == http.StatusNotModified {
17041 if res.Body != nil {
17042 res.Body.Close()
17043 }
17044 return nil, &googleapi.Error{
17045 Code: res.StatusCode,
17046 Header: res.Header,
17047 }
17048 }
17049 if err != nil {
17050 return nil, err
17051 }
17052 defer googleapi.CloseBody(res)
17053 if err := googleapi.CheckResponse(res); err != nil {
17054 return nil, err
17055 }
17056 ret := &AdsListResponse{
17057 ServerResponse: googleapi.ServerResponse{
17058 Header: res.Header,
17059 HTTPStatusCode: res.StatusCode,
17060 },
17061 }
17062 target := &ret
17063 if err := gensupport.DecodeResponse(target, res); err != nil {
17064 return nil, err
17065 }
17066 return ret, nil
17067
17068
17069
17070
17071
17072
17073
17074
17075
17076
17077
17078
17079
17080
17081
17082
17083
17084
17085
17086
17087
17088
17089
17090
17091
17092
17093
17094
17095
17096
17097
17098
17099
17100
17101
17102
17103
17104
17105
17106
17107
17108
17109
17110
17111
17112
17113
17114
17115
17116
17117
17118
17119
17120
17121
17122
17123
17124
17125
17126
17127
17128
17129
17130
17131
17132
17133
17134
17135
17136
17137
17138
17139
17140
17141
17142
17143
17144
17145
17146
17147
17148
17149
17150
17151
17152
17153
17154
17155
17156
17157
17158
17159
17160
17161
17162
17163
17164
17165
17166
17167
17168
17169
17170
17171
17172
17173
17174
17175
17176
17177
17178
17179
17180
17181
17182
17183
17184
17185
17186
17187
17188
17189
17190
17191
17192
17193
17194
17195
17196
17197
17198
17199
17200
17201
17202
17203
17204
17205
17206
17207
17208
17209
17210
17211
17212
17213
17214
17215
17216
17217
17218
17219
17220
17221
17222
17223
17224
17225
17226
17227
17228
17229
17230
17231
17232
17233
17234
17235
17236
17237
17238
17239
17240
17241
17242
17243
17244
17245
17246
17247
17248
17249
17250
17251
17252
17253
17254
17255
17256
17257
17258
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 func (c *AdsListCall) Pages(ctx context.Context, f func(*AdsListResponse) error) error {
17284 c.ctx_ = ctx
17285 defer c.PageToken(c.urlParams_.Get("pageToken"))
17286 for {
17287 x, err := c.Do()
17288 if err != nil {
17289 return err
17290 }
17291 if err := f(x); err != nil {
17292 return err
17293 }
17294 if x.NextPageToken == "" {
17295 return nil
17296 }
17297 c.PageToken(x.NextPageToken)
17298 }
17299 }
17300
17301
17302
17303 type AdsPatchCall struct {
17304 s *Service
17305 profileId int64
17306 ad *Ad
17307 urlParams_ gensupport.URLParams
17308 ctx_ context.Context
17309 header_ http.Header
17310 }
17311
17312
17313 func (r *AdsService) Patch(profileId int64, id int64, ad *Ad) *AdsPatchCall {
17314 c := &AdsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
17315 c.profileId = profileId
17316 c.urlParams_.Set("id", fmt.Sprint(id))
17317 c.ad = ad
17318 return c
17319 }
17320
17321
17322
17323
17324 func (c *AdsPatchCall) Fields(s ...googleapi.Field) *AdsPatchCall {
17325 c.urlParams_.Set("fields", googleapi.CombineFields(s))
17326 return c
17327 }
17328
17329
17330
17331
17332 func (c *AdsPatchCall) Context(ctx context.Context) *AdsPatchCall {
17333 c.ctx_ = ctx
17334 return c
17335 }
17336
17337
17338
17339 func (c *AdsPatchCall) Header() http.Header {
17340 if c.header_ == nil {
17341 c.header_ = make(http.Header)
17342 }
17343 return c.header_
17344 }
17345
17346 func (c *AdsPatchCall) doRequest(alt string) (*http.Response, error) {
17347 reqHeaders := make(http.Header)
17348 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
17349 for k, v := range c.header_ {
17350 reqHeaders[k] = v
17351 }
17352 reqHeaders.Set("User-Agent", c.s.userAgent())
17353 var body io.Reader = nil
17354 body, err := googleapi.WithoutDataWrapper.JSONReader(c.ad)
17355 if err != nil {
17356 return nil, err
17357 }
17358 reqHeaders.Set("Content-Type", "application/json")
17359 c.urlParams_.Set("alt", alt)
17360 c.urlParams_.Set("prettyPrint", "false")
17361 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/ads")
17362 urls += "?" + c.urlParams_.Encode()
17363 req, err := http.NewRequest("PATCH", urls, body)
17364 if err != nil {
17365 return nil, err
17366 }
17367 req.Header = reqHeaders
17368 googleapi.Expand(req.URL, map[string]string{
17369 "profileId": strconv.FormatInt(c.profileId, 10),
17370 })
17371 return gensupport.SendRequest(c.ctx_, c.s.client, req)
17372 }
17373
17374
17375
17376
17377
17378
17379
17380
17381 func (c *AdsPatchCall) Do(opts ...googleapi.CallOption) (*Ad, error) {
17382 gensupport.SetOptions(c.urlParams_, opts...)
17383 res, err := c.doRequest("json")
17384 if res != nil && res.StatusCode == http.StatusNotModified {
17385 if res.Body != nil {
17386 res.Body.Close()
17387 }
17388 return nil, &googleapi.Error{
17389 Code: res.StatusCode,
17390 Header: res.Header,
17391 }
17392 }
17393 if err != nil {
17394 return nil, err
17395 }
17396 defer googleapi.CloseBody(res)
17397 if err := googleapi.CheckResponse(res); err != nil {
17398 return nil, err
17399 }
17400 ret := &Ad{
17401 ServerResponse: googleapi.ServerResponse{
17402 Header: res.Header,
17403 HTTPStatusCode: res.StatusCode,
17404 },
17405 }
17406 target := &ret
17407 if err := gensupport.DecodeResponse(target, res); err != nil {
17408 return nil, err
17409 }
17410 return ret, nil
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 type AdsUpdateCall struct {
17452 s *Service
17453 profileId int64
17454 ad *Ad
17455 urlParams_ gensupport.URLParams
17456 ctx_ context.Context
17457 header_ http.Header
17458 }
17459
17460
17461 func (r *AdsService) Update(profileId int64, ad *Ad) *AdsUpdateCall {
17462 c := &AdsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
17463 c.profileId = profileId
17464 c.ad = ad
17465 return c
17466 }
17467
17468
17469
17470
17471 func (c *AdsUpdateCall) Fields(s ...googleapi.Field) *AdsUpdateCall {
17472 c.urlParams_.Set("fields", googleapi.CombineFields(s))
17473 return c
17474 }
17475
17476
17477
17478
17479 func (c *AdsUpdateCall) Context(ctx context.Context) *AdsUpdateCall {
17480 c.ctx_ = ctx
17481 return c
17482 }
17483
17484
17485
17486 func (c *AdsUpdateCall) Header() http.Header {
17487 if c.header_ == nil {
17488 c.header_ = make(http.Header)
17489 }
17490 return c.header_
17491 }
17492
17493 func (c *AdsUpdateCall) doRequest(alt string) (*http.Response, error) {
17494 reqHeaders := make(http.Header)
17495 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
17496 for k, v := range c.header_ {
17497 reqHeaders[k] = v
17498 }
17499 reqHeaders.Set("User-Agent", c.s.userAgent())
17500 var body io.Reader = nil
17501 body, err := googleapi.WithoutDataWrapper.JSONReader(c.ad)
17502 if err != nil {
17503 return nil, err
17504 }
17505 reqHeaders.Set("Content-Type", "application/json")
17506 c.urlParams_.Set("alt", alt)
17507 c.urlParams_.Set("prettyPrint", "false")
17508 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/ads")
17509 urls += "?" + c.urlParams_.Encode()
17510 req, err := http.NewRequest("PUT", urls, body)
17511 if err != nil {
17512 return nil, err
17513 }
17514 req.Header = reqHeaders
17515 googleapi.Expand(req.URL, map[string]string{
17516 "profileId": strconv.FormatInt(c.profileId, 10),
17517 })
17518 return gensupport.SendRequest(c.ctx_, c.s.client, req)
17519 }
17520
17521
17522
17523
17524
17525
17526
17527
17528 func (c *AdsUpdateCall) Do(opts ...googleapi.CallOption) (*Ad, error) {
17529 gensupport.SetOptions(c.urlParams_, opts...)
17530 res, err := c.doRequest("json")
17531 if res != nil && res.StatusCode == http.StatusNotModified {
17532 if res.Body != nil {
17533 res.Body.Close()
17534 }
17535 return nil, &googleapi.Error{
17536 Code: res.StatusCode,
17537 Header: res.Header,
17538 }
17539 }
17540 if err != nil {
17541 return nil, err
17542 }
17543 defer googleapi.CloseBody(res)
17544 if err := googleapi.CheckResponse(res); err != nil {
17545 return nil, err
17546 }
17547 ret := &Ad{
17548 ServerResponse: googleapi.ServerResponse{
17549 Header: res.Header,
17550 HTTPStatusCode: res.StatusCode,
17551 },
17552 }
17553 target := &ret
17554 if err := gensupport.DecodeResponse(target, res); err != nil {
17555 return nil, err
17556 }
17557 return ret, nil
17558
17559
17560
17561
17562
17563
17564
17565
17566
17567
17568
17569
17570
17571
17572
17573
17574
17575
17576
17577
17578
17579
17580
17581
17582
17583
17584
17585
17586 }
17587
17588
17589
17590 type AdvertiserGroupsDeleteCall struct {
17591 s *Service
17592 profileId int64
17593 id int64
17594 urlParams_ gensupport.URLParams
17595 ctx_ context.Context
17596 header_ http.Header
17597 }
17598
17599
17600 func (r *AdvertiserGroupsService) Delete(profileId int64, id int64) *AdvertiserGroupsDeleteCall {
17601 c := &AdvertiserGroupsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
17602 c.profileId = profileId
17603 c.id = id
17604 return c
17605 }
17606
17607
17608
17609
17610 func (c *AdvertiserGroupsDeleteCall) Fields(s ...googleapi.Field) *AdvertiserGroupsDeleteCall {
17611 c.urlParams_.Set("fields", googleapi.CombineFields(s))
17612 return c
17613 }
17614
17615
17616
17617
17618 func (c *AdvertiserGroupsDeleteCall) Context(ctx context.Context) *AdvertiserGroupsDeleteCall {
17619 c.ctx_ = ctx
17620 return c
17621 }
17622
17623
17624
17625 func (c *AdvertiserGroupsDeleteCall) Header() http.Header {
17626 if c.header_ == nil {
17627 c.header_ = make(http.Header)
17628 }
17629 return c.header_
17630 }
17631
17632 func (c *AdvertiserGroupsDeleteCall) doRequest(alt string) (*http.Response, error) {
17633 reqHeaders := make(http.Header)
17634 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
17635 for k, v := range c.header_ {
17636 reqHeaders[k] = v
17637 }
17638 reqHeaders.Set("User-Agent", c.s.userAgent())
17639 var body io.Reader = nil
17640 c.urlParams_.Set("alt", alt)
17641 c.urlParams_.Set("prettyPrint", "false")
17642 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/advertiserGroups/{id}")
17643 urls += "?" + c.urlParams_.Encode()
17644 req, err := http.NewRequest("DELETE", urls, body)
17645 if err != nil {
17646 return nil, err
17647 }
17648 req.Header = reqHeaders
17649 googleapi.Expand(req.URL, map[string]string{
17650 "profileId": strconv.FormatInt(c.profileId, 10),
17651 "id": strconv.FormatInt(c.id, 10),
17652 })
17653 return gensupport.SendRequest(c.ctx_, c.s.client, req)
17654 }
17655
17656
17657 func (c *AdvertiserGroupsDeleteCall) Do(opts ...googleapi.CallOption) error {
17658 gensupport.SetOptions(c.urlParams_, opts...)
17659 res, err := c.doRequest("json")
17660 if err != nil {
17661 return err
17662 }
17663 defer googleapi.CloseBody(res)
17664 if err := googleapi.CheckResponse(res); err != nil {
17665 return err
17666 }
17667 return nil
17668
17669
17670
17671
17672
17673
17674
17675
17676
17677
17678
17679
17680
17681
17682
17683
17684
17685
17686
17687
17688
17689
17690
17691
17692
17693
17694
17695
17696
17697
17698 }
17699
17700
17701
17702 type AdvertiserGroupsGetCall struct {
17703 s *Service
17704 profileId int64
17705 id int64
17706 urlParams_ gensupport.URLParams
17707 ifNoneMatch_ string
17708 ctx_ context.Context
17709 header_ http.Header
17710 }
17711
17712
17713 func (r *AdvertiserGroupsService) Get(profileId int64, id int64) *AdvertiserGroupsGetCall {
17714 c := &AdvertiserGroupsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
17715 c.profileId = profileId
17716 c.id = id
17717 return c
17718 }
17719
17720
17721
17722
17723 func (c *AdvertiserGroupsGetCall) Fields(s ...googleapi.Field) *AdvertiserGroupsGetCall {
17724 c.urlParams_.Set("fields", googleapi.CombineFields(s))
17725 return c
17726 }
17727
17728
17729
17730
17731
17732
17733 func (c *AdvertiserGroupsGetCall) IfNoneMatch(entityTag string) *AdvertiserGroupsGetCall {
17734 c.ifNoneMatch_ = entityTag
17735 return c
17736 }
17737
17738
17739
17740
17741 func (c *AdvertiserGroupsGetCall) Context(ctx context.Context) *AdvertiserGroupsGetCall {
17742 c.ctx_ = ctx
17743 return c
17744 }
17745
17746
17747
17748 func (c *AdvertiserGroupsGetCall) Header() http.Header {
17749 if c.header_ == nil {
17750 c.header_ = make(http.Header)
17751 }
17752 return c.header_
17753 }
17754
17755 func (c *AdvertiserGroupsGetCall) doRequest(alt string) (*http.Response, error) {
17756 reqHeaders := make(http.Header)
17757 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
17758 for k, v := range c.header_ {
17759 reqHeaders[k] = v
17760 }
17761 reqHeaders.Set("User-Agent", c.s.userAgent())
17762 if c.ifNoneMatch_ != "" {
17763 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
17764 }
17765 var body io.Reader = nil
17766 c.urlParams_.Set("alt", alt)
17767 c.urlParams_.Set("prettyPrint", "false")
17768 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/advertiserGroups/{id}")
17769 urls += "?" + c.urlParams_.Encode()
17770 req, err := http.NewRequest("GET", urls, body)
17771 if err != nil {
17772 return nil, err
17773 }
17774 req.Header = reqHeaders
17775 googleapi.Expand(req.URL, map[string]string{
17776 "profileId": strconv.FormatInt(c.profileId, 10),
17777 "id": strconv.FormatInt(c.id, 10),
17778 })
17779 return gensupport.SendRequest(c.ctx_, c.s.client, req)
17780 }
17781
17782
17783
17784
17785
17786
17787
17788
17789 func (c *AdvertiserGroupsGetCall) Do(opts ...googleapi.CallOption) (*AdvertiserGroup, error) {
17790 gensupport.SetOptions(c.urlParams_, opts...)
17791 res, err := c.doRequest("json")
17792 if res != nil && res.StatusCode == http.StatusNotModified {
17793 if res.Body != nil {
17794 res.Body.Close()
17795 }
17796 return nil, &googleapi.Error{
17797 Code: res.StatusCode,
17798 Header: res.Header,
17799 }
17800 }
17801 if err != nil {
17802 return nil, err
17803 }
17804 defer googleapi.CloseBody(res)
17805 if err := googleapi.CheckResponse(res); err != nil {
17806 return nil, err
17807 }
17808 ret := &AdvertiserGroup{
17809 ServerResponse: googleapi.ServerResponse{
17810 Header: res.Header,
17811 HTTPStatusCode: res.StatusCode,
17812 },
17813 }
17814 target := &ret
17815 if err := gensupport.DecodeResponse(target, res); err != nil {
17816 return nil, err
17817 }
17818 return ret, nil
17819
17820
17821
17822
17823
17824
17825
17826
17827
17828
17829
17830
17831
17832
17833
17834
17835
17836
17837
17838
17839
17840
17841
17842
17843
17844
17845
17846
17847
17848
17849
17850
17851
17852 }
17853
17854
17855
17856 type AdvertiserGroupsInsertCall struct {
17857 s *Service
17858 profileId int64
17859 advertisergroup *AdvertiserGroup
17860 urlParams_ gensupport.URLParams
17861 ctx_ context.Context
17862 header_ http.Header
17863 }
17864
17865
17866 func (r *AdvertiserGroupsService) Insert(profileId int64, advertisergroup *AdvertiserGroup) *AdvertiserGroupsInsertCall {
17867 c := &AdvertiserGroupsInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
17868 c.profileId = profileId
17869 c.advertisergroup = advertisergroup
17870 return c
17871 }
17872
17873
17874
17875
17876 func (c *AdvertiserGroupsInsertCall) Fields(s ...googleapi.Field) *AdvertiserGroupsInsertCall {
17877 c.urlParams_.Set("fields", googleapi.CombineFields(s))
17878 return c
17879 }
17880
17881
17882
17883
17884 func (c *AdvertiserGroupsInsertCall) Context(ctx context.Context) *AdvertiserGroupsInsertCall {
17885 c.ctx_ = ctx
17886 return c
17887 }
17888
17889
17890
17891 func (c *AdvertiserGroupsInsertCall) Header() http.Header {
17892 if c.header_ == nil {
17893 c.header_ = make(http.Header)
17894 }
17895 return c.header_
17896 }
17897
17898 func (c *AdvertiserGroupsInsertCall) doRequest(alt string) (*http.Response, error) {
17899 reqHeaders := make(http.Header)
17900 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
17901 for k, v := range c.header_ {
17902 reqHeaders[k] = v
17903 }
17904 reqHeaders.Set("User-Agent", c.s.userAgent())
17905 var body io.Reader = nil
17906 body, err := googleapi.WithoutDataWrapper.JSONReader(c.advertisergroup)
17907 if err != nil {
17908 return nil, err
17909 }
17910 reqHeaders.Set("Content-Type", "application/json")
17911 c.urlParams_.Set("alt", alt)
17912 c.urlParams_.Set("prettyPrint", "false")
17913 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/advertiserGroups")
17914 urls += "?" + c.urlParams_.Encode()
17915 req, err := http.NewRequest("POST", urls, body)
17916 if err != nil {
17917 return nil, err
17918 }
17919 req.Header = reqHeaders
17920 googleapi.Expand(req.URL, map[string]string{
17921 "profileId": strconv.FormatInt(c.profileId, 10),
17922 })
17923 return gensupport.SendRequest(c.ctx_, c.s.client, req)
17924 }
17925
17926
17927
17928
17929
17930
17931
17932
17933 func (c *AdvertiserGroupsInsertCall) Do(opts ...googleapi.CallOption) (*AdvertiserGroup, error) {
17934 gensupport.SetOptions(c.urlParams_, opts...)
17935 res, err := c.doRequest("json")
17936 if res != nil && res.StatusCode == http.StatusNotModified {
17937 if res.Body != nil {
17938 res.Body.Close()
17939 }
17940 return nil, &googleapi.Error{
17941 Code: res.StatusCode,
17942 Header: res.Header,
17943 }
17944 }
17945 if err != nil {
17946 return nil, err
17947 }
17948 defer googleapi.CloseBody(res)
17949 if err := googleapi.CheckResponse(res); err != nil {
17950 return nil, err
17951 }
17952 ret := &AdvertiserGroup{
17953 ServerResponse: googleapi.ServerResponse{
17954 Header: res.Header,
17955 HTTPStatusCode: res.StatusCode,
17956 },
17957 }
17958 target := &ret
17959 if err := gensupport.DecodeResponse(target, res); err != nil {
17960 return nil, err
17961 }
17962 return ret, nil
17963
17964
17965
17966
17967
17968
17969
17970
17971
17972
17973
17974
17975
17976
17977
17978
17979
17980
17981
17982
17983
17984
17985
17986
17987
17988
17989
17990
17991 }
17992
17993
17994
17995 type AdvertiserGroupsListCall struct {
17996 s *Service
17997 profileId int64
17998 urlParams_ gensupport.URLParams
17999 ifNoneMatch_ string
18000 ctx_ context.Context
18001 header_ http.Header
18002 }
18003
18004
18005
18006 func (r *AdvertiserGroupsService) List(profileId int64) *AdvertiserGroupsListCall {
18007 c := &AdvertiserGroupsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
18008 c.profileId = profileId
18009 return c
18010 }
18011
18012
18013
18014 func (c *AdvertiserGroupsListCall) Ids(ids ...int64) *AdvertiserGroupsListCall {
18015 var ids_ []string
18016 for _, v := range ids {
18017 ids_ = append(ids_, fmt.Sprint(v))
18018 }
18019 c.urlParams_.SetMulti("ids", ids_)
18020 return c
18021 }
18022
18023
18024
18025 func (c *AdvertiserGroupsListCall) MaxResults(maxResults int64) *AdvertiserGroupsListCall {
18026 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
18027 return c
18028 }
18029
18030
18031
18032 func (c *AdvertiserGroupsListCall) PageToken(pageToken string) *AdvertiserGroupsListCall {
18033 c.urlParams_.Set("pageToken", pageToken)
18034 return c
18035 }
18036
18037
18038
18039
18040
18041
18042
18043
18044
18045
18046 func (c *AdvertiserGroupsListCall) SearchString(searchString string) *AdvertiserGroupsListCall {
18047 c.urlParams_.Set("searchString", searchString)
18048 return c
18049 }
18050
18051
18052
18053
18054
18055
18056
18057
18058 func (c *AdvertiserGroupsListCall) SortField(sortField string) *AdvertiserGroupsListCall {
18059 c.urlParams_.Set("sortField", sortField)
18060 return c
18061 }
18062
18063
18064
18065
18066
18067
18068
18069
18070 func (c *AdvertiserGroupsListCall) SortOrder(sortOrder string) *AdvertiserGroupsListCall {
18071 c.urlParams_.Set("sortOrder", sortOrder)
18072 return c
18073 }
18074
18075
18076
18077
18078 func (c *AdvertiserGroupsListCall) Fields(s ...googleapi.Field) *AdvertiserGroupsListCall {
18079 c.urlParams_.Set("fields", googleapi.CombineFields(s))
18080 return c
18081 }
18082
18083
18084
18085
18086
18087
18088 func (c *AdvertiserGroupsListCall) IfNoneMatch(entityTag string) *AdvertiserGroupsListCall {
18089 c.ifNoneMatch_ = entityTag
18090 return c
18091 }
18092
18093
18094
18095
18096 func (c *AdvertiserGroupsListCall) Context(ctx context.Context) *AdvertiserGroupsListCall {
18097 c.ctx_ = ctx
18098 return c
18099 }
18100
18101
18102
18103 func (c *AdvertiserGroupsListCall) Header() http.Header {
18104 if c.header_ == nil {
18105 c.header_ = make(http.Header)
18106 }
18107 return c.header_
18108 }
18109
18110 func (c *AdvertiserGroupsListCall) doRequest(alt string) (*http.Response, error) {
18111 reqHeaders := make(http.Header)
18112 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
18113 for k, v := range c.header_ {
18114 reqHeaders[k] = v
18115 }
18116 reqHeaders.Set("User-Agent", c.s.userAgent())
18117 if c.ifNoneMatch_ != "" {
18118 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
18119 }
18120 var body io.Reader = nil
18121 c.urlParams_.Set("alt", alt)
18122 c.urlParams_.Set("prettyPrint", "false")
18123 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/advertiserGroups")
18124 urls += "?" + c.urlParams_.Encode()
18125 req, err := http.NewRequest("GET", urls, body)
18126 if err != nil {
18127 return nil, err
18128 }
18129 req.Header = reqHeaders
18130 googleapi.Expand(req.URL, map[string]string{
18131 "profileId": strconv.FormatInt(c.profileId, 10),
18132 })
18133 return gensupport.SendRequest(c.ctx_, c.s.client, req)
18134 }
18135
18136
18137
18138
18139
18140
18141
18142
18143 func (c *AdvertiserGroupsListCall) Do(opts ...googleapi.CallOption) (*AdvertiserGroupsListResponse, error) {
18144 gensupport.SetOptions(c.urlParams_, opts...)
18145 res, err := c.doRequest("json")
18146 if res != nil && res.StatusCode == http.StatusNotModified {
18147 if res.Body != nil {
18148 res.Body.Close()
18149 }
18150 return nil, &googleapi.Error{
18151 Code: res.StatusCode,
18152 Header: res.Header,
18153 }
18154 }
18155 if err != nil {
18156 return nil, err
18157 }
18158 defer googleapi.CloseBody(res)
18159 if err := googleapi.CheckResponse(res); err != nil {
18160 return nil, err
18161 }
18162 ret := &AdvertiserGroupsListResponse{
18163 ServerResponse: googleapi.ServerResponse{
18164 Header: res.Header,
18165 HTTPStatusCode: res.StatusCode,
18166 },
18167 }
18168 target := &ret
18169 if err := gensupport.DecodeResponse(target, res); err != nil {
18170 return nil, err
18171 }
18172 return ret, nil
18173
18174
18175
18176
18177
18178
18179
18180
18181
18182
18183
18184
18185
18186
18187
18188
18189
18190
18191
18192
18193
18194
18195
18196
18197
18198
18199
18200
18201
18202
18203
18204
18205
18206
18207
18208
18209
18210
18211
18212
18213
18214
18215
18216
18217
18218
18219
18220
18221
18222
18223
18224
18225
18226
18227
18228
18229
18230
18231
18232
18233
18234
18235
18236
18237
18238
18239
18240
18241
18242
18243
18244
18245
18246
18247
18248
18249
18250
18251
18252 }
18253
18254
18255
18256
18257 func (c *AdvertiserGroupsListCall) Pages(ctx context.Context, f func(*AdvertiserGroupsListResponse) error) error {
18258 c.ctx_ = ctx
18259 defer c.PageToken(c.urlParams_.Get("pageToken"))
18260 for {
18261 x, err := c.Do()
18262 if err != nil {
18263 return err
18264 }
18265 if err := f(x); err != nil {
18266 return err
18267 }
18268 if x.NextPageToken == "" {
18269 return nil
18270 }
18271 c.PageToken(x.NextPageToken)
18272 }
18273 }
18274
18275
18276
18277 type AdvertiserGroupsPatchCall struct {
18278 s *Service
18279 profileId int64
18280 advertisergroup *AdvertiserGroup
18281 urlParams_ gensupport.URLParams
18282 ctx_ context.Context
18283 header_ http.Header
18284 }
18285
18286
18287
18288 func (r *AdvertiserGroupsService) Patch(profileId int64, id int64, advertisergroup *AdvertiserGroup) *AdvertiserGroupsPatchCall {
18289 c := &AdvertiserGroupsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
18290 c.profileId = profileId
18291 c.urlParams_.Set("id", fmt.Sprint(id))
18292 c.advertisergroup = advertisergroup
18293 return c
18294 }
18295
18296
18297
18298
18299 func (c *AdvertiserGroupsPatchCall) Fields(s ...googleapi.Field) *AdvertiserGroupsPatchCall {
18300 c.urlParams_.Set("fields", googleapi.CombineFields(s))
18301 return c
18302 }
18303
18304
18305
18306
18307 func (c *AdvertiserGroupsPatchCall) Context(ctx context.Context) *AdvertiserGroupsPatchCall {
18308 c.ctx_ = ctx
18309 return c
18310 }
18311
18312
18313
18314 func (c *AdvertiserGroupsPatchCall) Header() http.Header {
18315 if c.header_ == nil {
18316 c.header_ = make(http.Header)
18317 }
18318 return c.header_
18319 }
18320
18321 func (c *AdvertiserGroupsPatchCall) doRequest(alt string) (*http.Response, error) {
18322 reqHeaders := make(http.Header)
18323 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
18324 for k, v := range c.header_ {
18325 reqHeaders[k] = v
18326 }
18327 reqHeaders.Set("User-Agent", c.s.userAgent())
18328 var body io.Reader = nil
18329 body, err := googleapi.WithoutDataWrapper.JSONReader(c.advertisergroup)
18330 if err != nil {
18331 return nil, err
18332 }
18333 reqHeaders.Set("Content-Type", "application/json")
18334 c.urlParams_.Set("alt", alt)
18335 c.urlParams_.Set("prettyPrint", "false")
18336 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/advertiserGroups")
18337 urls += "?" + c.urlParams_.Encode()
18338 req, err := http.NewRequest("PATCH", urls, body)
18339 if err != nil {
18340 return nil, err
18341 }
18342 req.Header = reqHeaders
18343 googleapi.Expand(req.URL, map[string]string{
18344 "profileId": strconv.FormatInt(c.profileId, 10),
18345 })
18346 return gensupport.SendRequest(c.ctx_, c.s.client, req)
18347 }
18348
18349
18350
18351
18352
18353
18354
18355
18356 func (c *AdvertiserGroupsPatchCall) Do(opts ...googleapi.CallOption) (*AdvertiserGroup, error) {
18357 gensupport.SetOptions(c.urlParams_, opts...)
18358 res, err := c.doRequest("json")
18359 if res != nil && res.StatusCode == http.StatusNotModified {
18360 if res.Body != nil {
18361 res.Body.Close()
18362 }
18363 return nil, &googleapi.Error{
18364 Code: res.StatusCode,
18365 Header: res.Header,
18366 }
18367 }
18368 if err != nil {
18369 return nil, err
18370 }
18371 defer googleapi.CloseBody(res)
18372 if err := googleapi.CheckResponse(res); err != nil {
18373 return nil, err
18374 }
18375 ret := &AdvertiserGroup{
18376 ServerResponse: googleapi.ServerResponse{
18377 Header: res.Header,
18378 HTTPStatusCode: res.StatusCode,
18379 },
18380 }
18381 target := &ret
18382 if err := gensupport.DecodeResponse(target, res); err != nil {
18383 return nil, err
18384 }
18385 return ret, nil
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 type AdvertiserGroupsUpdateCall struct {
18427 s *Service
18428 profileId int64
18429 advertisergroup *AdvertiserGroup
18430 urlParams_ gensupport.URLParams
18431 ctx_ context.Context
18432 header_ http.Header
18433 }
18434
18435
18436 func (r *AdvertiserGroupsService) Update(profileId int64, advertisergroup *AdvertiserGroup) *AdvertiserGroupsUpdateCall {
18437 c := &AdvertiserGroupsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
18438 c.profileId = profileId
18439 c.advertisergroup = advertisergroup
18440 return c
18441 }
18442
18443
18444
18445
18446 func (c *AdvertiserGroupsUpdateCall) Fields(s ...googleapi.Field) *AdvertiserGroupsUpdateCall {
18447 c.urlParams_.Set("fields", googleapi.CombineFields(s))
18448 return c
18449 }
18450
18451
18452
18453
18454 func (c *AdvertiserGroupsUpdateCall) Context(ctx context.Context) *AdvertiserGroupsUpdateCall {
18455 c.ctx_ = ctx
18456 return c
18457 }
18458
18459
18460
18461 func (c *AdvertiserGroupsUpdateCall) Header() http.Header {
18462 if c.header_ == nil {
18463 c.header_ = make(http.Header)
18464 }
18465 return c.header_
18466 }
18467
18468 func (c *AdvertiserGroupsUpdateCall) doRequest(alt string) (*http.Response, error) {
18469 reqHeaders := make(http.Header)
18470 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
18471 for k, v := range c.header_ {
18472 reqHeaders[k] = v
18473 }
18474 reqHeaders.Set("User-Agent", c.s.userAgent())
18475 var body io.Reader = nil
18476 body, err := googleapi.WithoutDataWrapper.JSONReader(c.advertisergroup)
18477 if err != nil {
18478 return nil, err
18479 }
18480 reqHeaders.Set("Content-Type", "application/json")
18481 c.urlParams_.Set("alt", alt)
18482 c.urlParams_.Set("prettyPrint", "false")
18483 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/advertiserGroups")
18484 urls += "?" + c.urlParams_.Encode()
18485 req, err := http.NewRequest("PUT", urls, body)
18486 if err != nil {
18487 return nil, err
18488 }
18489 req.Header = reqHeaders
18490 googleapi.Expand(req.URL, map[string]string{
18491 "profileId": strconv.FormatInt(c.profileId, 10),
18492 })
18493 return gensupport.SendRequest(c.ctx_, c.s.client, req)
18494 }
18495
18496
18497
18498
18499
18500
18501
18502
18503 func (c *AdvertiserGroupsUpdateCall) Do(opts ...googleapi.CallOption) (*AdvertiserGroup, error) {
18504 gensupport.SetOptions(c.urlParams_, opts...)
18505 res, err := c.doRequest("json")
18506 if res != nil && res.StatusCode == http.StatusNotModified {
18507 if res.Body != nil {
18508 res.Body.Close()
18509 }
18510 return nil, &googleapi.Error{
18511 Code: res.StatusCode,
18512 Header: res.Header,
18513 }
18514 }
18515 if err != nil {
18516 return nil, err
18517 }
18518 defer googleapi.CloseBody(res)
18519 if err := googleapi.CheckResponse(res); err != nil {
18520 return nil, err
18521 }
18522 ret := &AdvertiserGroup{
18523 ServerResponse: googleapi.ServerResponse{
18524 Header: res.Header,
18525 HTTPStatusCode: res.StatusCode,
18526 },
18527 }
18528 target := &ret
18529 if err := gensupport.DecodeResponse(target, res); err != nil {
18530 return nil, err
18531 }
18532 return ret, nil
18533
18534
18535
18536
18537
18538
18539
18540
18541
18542
18543
18544
18545
18546
18547
18548
18549
18550
18551
18552
18553
18554
18555
18556
18557
18558
18559
18560
18561 }
18562
18563
18564
18565 type AdvertiserLandingPagesGetCall struct {
18566 s *Service
18567 profileId int64
18568 id int64
18569 urlParams_ gensupport.URLParams
18570 ifNoneMatch_ string
18571 ctx_ context.Context
18572 header_ http.Header
18573 }
18574
18575
18576 func (r *AdvertiserLandingPagesService) Get(profileId int64, id int64) *AdvertiserLandingPagesGetCall {
18577 c := &AdvertiserLandingPagesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
18578 c.profileId = profileId
18579 c.id = id
18580 return c
18581 }
18582
18583
18584
18585
18586 func (c *AdvertiserLandingPagesGetCall) Fields(s ...googleapi.Field) *AdvertiserLandingPagesGetCall {
18587 c.urlParams_.Set("fields", googleapi.CombineFields(s))
18588 return c
18589 }
18590
18591
18592
18593
18594
18595
18596 func (c *AdvertiserLandingPagesGetCall) IfNoneMatch(entityTag string) *AdvertiserLandingPagesGetCall {
18597 c.ifNoneMatch_ = entityTag
18598 return c
18599 }
18600
18601
18602
18603
18604 func (c *AdvertiserLandingPagesGetCall) Context(ctx context.Context) *AdvertiserLandingPagesGetCall {
18605 c.ctx_ = ctx
18606 return c
18607 }
18608
18609
18610
18611 func (c *AdvertiserLandingPagesGetCall) Header() http.Header {
18612 if c.header_ == nil {
18613 c.header_ = make(http.Header)
18614 }
18615 return c.header_
18616 }
18617
18618 func (c *AdvertiserLandingPagesGetCall) doRequest(alt string) (*http.Response, error) {
18619 reqHeaders := make(http.Header)
18620 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
18621 for k, v := range c.header_ {
18622 reqHeaders[k] = v
18623 }
18624 reqHeaders.Set("User-Agent", c.s.userAgent())
18625 if c.ifNoneMatch_ != "" {
18626 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
18627 }
18628 var body io.Reader = nil
18629 c.urlParams_.Set("alt", alt)
18630 c.urlParams_.Set("prettyPrint", "false")
18631 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/advertiserLandingPages/{id}")
18632 urls += "?" + c.urlParams_.Encode()
18633 req, err := http.NewRequest("GET", urls, body)
18634 if err != nil {
18635 return nil, err
18636 }
18637 req.Header = reqHeaders
18638 googleapi.Expand(req.URL, map[string]string{
18639 "profileId": strconv.FormatInt(c.profileId, 10),
18640 "id": strconv.FormatInt(c.id, 10),
18641 })
18642 return gensupport.SendRequest(c.ctx_, c.s.client, req)
18643 }
18644
18645
18646
18647
18648
18649
18650
18651
18652 func (c *AdvertiserLandingPagesGetCall) Do(opts ...googleapi.CallOption) (*LandingPage, error) {
18653 gensupport.SetOptions(c.urlParams_, opts...)
18654 res, err := c.doRequest("json")
18655 if res != nil && res.StatusCode == http.StatusNotModified {
18656 if res.Body != nil {
18657 res.Body.Close()
18658 }
18659 return nil, &googleapi.Error{
18660 Code: res.StatusCode,
18661 Header: res.Header,
18662 }
18663 }
18664 if err != nil {
18665 return nil, err
18666 }
18667 defer googleapi.CloseBody(res)
18668 if err := googleapi.CheckResponse(res); err != nil {
18669 return nil, err
18670 }
18671 ret := &LandingPage{
18672 ServerResponse: googleapi.ServerResponse{
18673 Header: res.Header,
18674 HTTPStatusCode: res.StatusCode,
18675 },
18676 }
18677 target := &ret
18678 if err := gensupport.DecodeResponse(target, res); err != nil {
18679 return nil, err
18680 }
18681 return ret, nil
18682
18683
18684
18685
18686
18687
18688
18689
18690
18691
18692
18693
18694
18695
18696
18697
18698
18699
18700
18701
18702
18703
18704
18705
18706
18707
18708
18709
18710
18711
18712
18713
18714
18715 }
18716
18717
18718
18719 type AdvertiserLandingPagesInsertCall struct {
18720 s *Service
18721 profileId int64
18722 landingpage *LandingPage
18723 urlParams_ gensupport.URLParams
18724 ctx_ context.Context
18725 header_ http.Header
18726 }
18727
18728
18729 func (r *AdvertiserLandingPagesService) Insert(profileId int64, landingpage *LandingPage) *AdvertiserLandingPagesInsertCall {
18730 c := &AdvertiserLandingPagesInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
18731 c.profileId = profileId
18732 c.landingpage = landingpage
18733 return c
18734 }
18735
18736
18737
18738
18739 func (c *AdvertiserLandingPagesInsertCall) Fields(s ...googleapi.Field) *AdvertiserLandingPagesInsertCall {
18740 c.urlParams_.Set("fields", googleapi.CombineFields(s))
18741 return c
18742 }
18743
18744
18745
18746
18747 func (c *AdvertiserLandingPagesInsertCall) Context(ctx context.Context) *AdvertiserLandingPagesInsertCall {
18748 c.ctx_ = ctx
18749 return c
18750 }
18751
18752
18753
18754 func (c *AdvertiserLandingPagesInsertCall) Header() http.Header {
18755 if c.header_ == nil {
18756 c.header_ = make(http.Header)
18757 }
18758 return c.header_
18759 }
18760
18761 func (c *AdvertiserLandingPagesInsertCall) doRequest(alt string) (*http.Response, error) {
18762 reqHeaders := make(http.Header)
18763 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
18764 for k, v := range c.header_ {
18765 reqHeaders[k] = v
18766 }
18767 reqHeaders.Set("User-Agent", c.s.userAgent())
18768 var body io.Reader = nil
18769 body, err := googleapi.WithoutDataWrapper.JSONReader(c.landingpage)
18770 if err != nil {
18771 return nil, err
18772 }
18773 reqHeaders.Set("Content-Type", "application/json")
18774 c.urlParams_.Set("alt", alt)
18775 c.urlParams_.Set("prettyPrint", "false")
18776 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/advertiserLandingPages")
18777 urls += "?" + c.urlParams_.Encode()
18778 req, err := http.NewRequest("POST", urls, body)
18779 if err != nil {
18780 return nil, err
18781 }
18782 req.Header = reqHeaders
18783 googleapi.Expand(req.URL, map[string]string{
18784 "profileId": strconv.FormatInt(c.profileId, 10),
18785 })
18786 return gensupport.SendRequest(c.ctx_, c.s.client, req)
18787 }
18788
18789
18790
18791
18792
18793
18794
18795
18796 func (c *AdvertiserLandingPagesInsertCall) Do(opts ...googleapi.CallOption) (*LandingPage, error) {
18797 gensupport.SetOptions(c.urlParams_, opts...)
18798 res, err := c.doRequest("json")
18799 if res != nil && res.StatusCode == http.StatusNotModified {
18800 if res.Body != nil {
18801 res.Body.Close()
18802 }
18803 return nil, &googleapi.Error{
18804 Code: res.StatusCode,
18805 Header: res.Header,
18806 }
18807 }
18808 if err != nil {
18809 return nil, err
18810 }
18811 defer googleapi.CloseBody(res)
18812 if err := googleapi.CheckResponse(res); err != nil {
18813 return nil, err
18814 }
18815 ret := &LandingPage{
18816 ServerResponse: googleapi.ServerResponse{
18817 Header: res.Header,
18818 HTTPStatusCode: res.StatusCode,
18819 },
18820 }
18821 target := &ret
18822 if err := gensupport.DecodeResponse(target, res); err != nil {
18823 return nil, err
18824 }
18825 return ret, nil
18826
18827
18828
18829
18830
18831
18832
18833
18834
18835
18836
18837
18838
18839
18840
18841
18842
18843
18844
18845
18846
18847
18848
18849
18850
18851
18852
18853
18854 }
18855
18856
18857
18858 type AdvertiserLandingPagesListCall struct {
18859 s *Service
18860 profileId int64
18861 urlParams_ gensupport.URLParams
18862 ifNoneMatch_ string
18863 ctx_ context.Context
18864 header_ http.Header
18865 }
18866
18867
18868 func (r *AdvertiserLandingPagesService) List(profileId int64) *AdvertiserLandingPagesListCall {
18869 c := &AdvertiserLandingPagesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
18870 c.profileId = profileId
18871 return c
18872 }
18873
18874
18875
18876 func (c *AdvertiserLandingPagesListCall) AdvertiserIds(advertiserIds ...int64) *AdvertiserLandingPagesListCall {
18877 var advertiserIds_ []string
18878 for _, v := range advertiserIds {
18879 advertiserIds_ = append(advertiserIds_, fmt.Sprint(v))
18880 }
18881 c.urlParams_.SetMulti("advertiserIds", advertiserIds_)
18882 return c
18883 }
18884
18885
18886
18887
18888 func (c *AdvertiserLandingPagesListCall) Archived(archived bool) *AdvertiserLandingPagesListCall {
18889 c.urlParams_.Set("archived", fmt.Sprint(archived))
18890 return c
18891 }
18892
18893
18894
18895 func (c *AdvertiserLandingPagesListCall) Ids(ids ...int64) *AdvertiserLandingPagesListCall {
18896 var ids_ []string
18897 for _, v := range ids {
18898 ids_ = append(ids_, fmt.Sprint(v))
18899 }
18900 c.urlParams_.SetMulti("ids", ids_)
18901 return c
18902 }
18903
18904
18905
18906 func (c *AdvertiserLandingPagesListCall) MaxResults(maxResults int64) *AdvertiserLandingPagesListCall {
18907 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
18908 return c
18909 }
18910
18911
18912
18913 func (c *AdvertiserLandingPagesListCall) PageToken(pageToken string) *AdvertiserLandingPagesListCall {
18914 c.urlParams_.Set("pageToken", pageToken)
18915 return c
18916 }
18917
18918
18919
18920
18921
18922
18923
18924
18925
18926 func (c *AdvertiserLandingPagesListCall) SearchString(searchString string) *AdvertiserLandingPagesListCall {
18927 c.urlParams_.Set("searchString", searchString)
18928 return c
18929 }
18930
18931
18932
18933
18934
18935
18936
18937
18938 func (c *AdvertiserLandingPagesListCall) SortField(sortField string) *AdvertiserLandingPagesListCall {
18939 c.urlParams_.Set("sortField", sortField)
18940 return c
18941 }
18942
18943
18944
18945
18946
18947
18948
18949
18950 func (c *AdvertiserLandingPagesListCall) SortOrder(sortOrder string) *AdvertiserLandingPagesListCall {
18951 c.urlParams_.Set("sortOrder", sortOrder)
18952 return c
18953 }
18954
18955
18956
18957 func (c *AdvertiserLandingPagesListCall) SubaccountId(subaccountId int64) *AdvertiserLandingPagesListCall {
18958 c.urlParams_.Set("subaccountId", fmt.Sprint(subaccountId))
18959 return c
18960 }
18961
18962
18963
18964
18965 func (c *AdvertiserLandingPagesListCall) Fields(s ...googleapi.Field) *AdvertiserLandingPagesListCall {
18966 c.urlParams_.Set("fields", googleapi.CombineFields(s))
18967 return c
18968 }
18969
18970
18971
18972
18973
18974
18975 func (c *AdvertiserLandingPagesListCall) IfNoneMatch(entityTag string) *AdvertiserLandingPagesListCall {
18976 c.ifNoneMatch_ = entityTag
18977 return c
18978 }
18979
18980
18981
18982
18983 func (c *AdvertiserLandingPagesListCall) Context(ctx context.Context) *AdvertiserLandingPagesListCall {
18984 c.ctx_ = ctx
18985 return c
18986 }
18987
18988
18989
18990 func (c *AdvertiserLandingPagesListCall) Header() http.Header {
18991 if c.header_ == nil {
18992 c.header_ = make(http.Header)
18993 }
18994 return c.header_
18995 }
18996
18997 func (c *AdvertiserLandingPagesListCall) doRequest(alt string) (*http.Response, error) {
18998 reqHeaders := make(http.Header)
18999 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
19000 for k, v := range c.header_ {
19001 reqHeaders[k] = v
19002 }
19003 reqHeaders.Set("User-Agent", c.s.userAgent())
19004 if c.ifNoneMatch_ != "" {
19005 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
19006 }
19007 var body io.Reader = nil
19008 c.urlParams_.Set("alt", alt)
19009 c.urlParams_.Set("prettyPrint", "false")
19010 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/advertiserLandingPages")
19011 urls += "?" + c.urlParams_.Encode()
19012 req, err := http.NewRequest("GET", urls, body)
19013 if err != nil {
19014 return nil, err
19015 }
19016 req.Header = reqHeaders
19017 googleapi.Expand(req.URL, map[string]string{
19018 "profileId": strconv.FormatInt(c.profileId, 10),
19019 })
19020 return gensupport.SendRequest(c.ctx_, c.s.client, req)
19021 }
19022
19023
19024
19025
19026
19027
19028
19029
19030
19031 func (c *AdvertiserLandingPagesListCall) Do(opts ...googleapi.CallOption) (*AdvertiserLandingPagesListResponse, error) {
19032 gensupport.SetOptions(c.urlParams_, opts...)
19033 res, err := c.doRequest("json")
19034 if res != nil && res.StatusCode == http.StatusNotModified {
19035 if res.Body != nil {
19036 res.Body.Close()
19037 }
19038 return nil, &googleapi.Error{
19039 Code: res.StatusCode,
19040 Header: res.Header,
19041 }
19042 }
19043 if err != nil {
19044 return nil, err
19045 }
19046 defer googleapi.CloseBody(res)
19047 if err := googleapi.CheckResponse(res); err != nil {
19048 return nil, err
19049 }
19050 ret := &AdvertiserLandingPagesListResponse{
19051 ServerResponse: googleapi.ServerResponse{
19052 Header: res.Header,
19053 HTTPStatusCode: res.StatusCode,
19054 },
19055 }
19056 target := &ret
19057 if err := gensupport.DecodeResponse(target, res); err != nil {
19058 return nil, err
19059 }
19060 return ret, nil
19061
19062
19063
19064
19065
19066
19067
19068
19069
19070
19071
19072
19073
19074
19075
19076
19077
19078
19079
19080
19081
19082
19083
19084
19085
19086
19087
19088
19089
19090
19091
19092
19093
19094
19095
19096
19097
19098
19099
19100
19101
19102
19103
19104
19105
19106
19107
19108
19109
19110
19111
19112
19113
19114
19115
19116
19117
19118
19119
19120
19121
19122
19123
19124
19125
19126
19127
19128
19129
19130
19131
19132
19133
19134
19135
19136
19137
19138
19139
19140
19141
19142
19143
19144
19145
19146
19147
19148
19149
19150
19151
19152
19153
19154
19155
19156
19157
19158 }
19159
19160
19161
19162
19163 func (c *AdvertiserLandingPagesListCall) Pages(ctx context.Context, f func(*AdvertiserLandingPagesListResponse) error) error {
19164 c.ctx_ = ctx
19165 defer c.PageToken(c.urlParams_.Get("pageToken"))
19166 for {
19167 x, err := c.Do()
19168 if err != nil {
19169 return err
19170 }
19171 if err := f(x); err != nil {
19172 return err
19173 }
19174 if x.NextPageToken == "" {
19175 return nil
19176 }
19177 c.PageToken(x.NextPageToken)
19178 }
19179 }
19180
19181
19182
19183 type AdvertiserLandingPagesPatchCall struct {
19184 s *Service
19185 profileId int64
19186 landingpage *LandingPage
19187 urlParams_ gensupport.URLParams
19188 ctx_ context.Context
19189 header_ http.Header
19190 }
19191
19192
19193
19194 func (r *AdvertiserLandingPagesService) Patch(profileId int64, id int64, landingpage *LandingPage) *AdvertiserLandingPagesPatchCall {
19195 c := &AdvertiserLandingPagesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
19196 c.profileId = profileId
19197 c.urlParams_.Set("id", fmt.Sprint(id))
19198 c.landingpage = landingpage
19199 return c
19200 }
19201
19202
19203
19204
19205 func (c *AdvertiserLandingPagesPatchCall) Fields(s ...googleapi.Field) *AdvertiserLandingPagesPatchCall {
19206 c.urlParams_.Set("fields", googleapi.CombineFields(s))
19207 return c
19208 }
19209
19210
19211
19212
19213 func (c *AdvertiserLandingPagesPatchCall) Context(ctx context.Context) *AdvertiserLandingPagesPatchCall {
19214 c.ctx_ = ctx
19215 return c
19216 }
19217
19218
19219
19220 func (c *AdvertiserLandingPagesPatchCall) Header() http.Header {
19221 if c.header_ == nil {
19222 c.header_ = make(http.Header)
19223 }
19224 return c.header_
19225 }
19226
19227 func (c *AdvertiserLandingPagesPatchCall) doRequest(alt string) (*http.Response, error) {
19228 reqHeaders := make(http.Header)
19229 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
19230 for k, v := range c.header_ {
19231 reqHeaders[k] = v
19232 }
19233 reqHeaders.Set("User-Agent", c.s.userAgent())
19234 var body io.Reader = nil
19235 body, err := googleapi.WithoutDataWrapper.JSONReader(c.landingpage)
19236 if err != nil {
19237 return nil, err
19238 }
19239 reqHeaders.Set("Content-Type", "application/json")
19240 c.urlParams_.Set("alt", alt)
19241 c.urlParams_.Set("prettyPrint", "false")
19242 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/advertiserLandingPages")
19243 urls += "?" + c.urlParams_.Encode()
19244 req, err := http.NewRequest("PATCH", urls, body)
19245 if err != nil {
19246 return nil, err
19247 }
19248 req.Header = reqHeaders
19249 googleapi.Expand(req.URL, map[string]string{
19250 "profileId": strconv.FormatInt(c.profileId, 10),
19251 })
19252 return gensupport.SendRequest(c.ctx_, c.s.client, req)
19253 }
19254
19255
19256
19257
19258
19259
19260
19261
19262 func (c *AdvertiserLandingPagesPatchCall) Do(opts ...googleapi.CallOption) (*LandingPage, error) {
19263 gensupport.SetOptions(c.urlParams_, opts...)
19264 res, err := c.doRequest("json")
19265 if res != nil && res.StatusCode == http.StatusNotModified {
19266 if res.Body != nil {
19267 res.Body.Close()
19268 }
19269 return nil, &googleapi.Error{
19270 Code: res.StatusCode,
19271 Header: res.Header,
19272 }
19273 }
19274 if err != nil {
19275 return nil, err
19276 }
19277 defer googleapi.CloseBody(res)
19278 if err := googleapi.CheckResponse(res); err != nil {
19279 return nil, err
19280 }
19281 ret := &LandingPage{
19282 ServerResponse: googleapi.ServerResponse{
19283 Header: res.Header,
19284 HTTPStatusCode: res.StatusCode,
19285 },
19286 }
19287 target := &ret
19288 if err := gensupport.DecodeResponse(target, res); err != nil {
19289 return nil, err
19290 }
19291 return ret, nil
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 type AdvertiserLandingPagesUpdateCall struct {
19333 s *Service
19334 profileId int64
19335 landingpage *LandingPage
19336 urlParams_ gensupport.URLParams
19337 ctx_ context.Context
19338 header_ http.Header
19339 }
19340
19341
19342 func (r *AdvertiserLandingPagesService) Update(profileId int64, landingpage *LandingPage) *AdvertiserLandingPagesUpdateCall {
19343 c := &AdvertiserLandingPagesUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
19344 c.profileId = profileId
19345 c.landingpage = landingpage
19346 return c
19347 }
19348
19349
19350
19351
19352 func (c *AdvertiserLandingPagesUpdateCall) Fields(s ...googleapi.Field) *AdvertiserLandingPagesUpdateCall {
19353 c.urlParams_.Set("fields", googleapi.CombineFields(s))
19354 return c
19355 }
19356
19357
19358
19359
19360 func (c *AdvertiserLandingPagesUpdateCall) Context(ctx context.Context) *AdvertiserLandingPagesUpdateCall {
19361 c.ctx_ = ctx
19362 return c
19363 }
19364
19365
19366
19367 func (c *AdvertiserLandingPagesUpdateCall) Header() http.Header {
19368 if c.header_ == nil {
19369 c.header_ = make(http.Header)
19370 }
19371 return c.header_
19372 }
19373
19374 func (c *AdvertiserLandingPagesUpdateCall) doRequest(alt string) (*http.Response, error) {
19375 reqHeaders := make(http.Header)
19376 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
19377 for k, v := range c.header_ {
19378 reqHeaders[k] = v
19379 }
19380 reqHeaders.Set("User-Agent", c.s.userAgent())
19381 var body io.Reader = nil
19382 body, err := googleapi.WithoutDataWrapper.JSONReader(c.landingpage)
19383 if err != nil {
19384 return nil, err
19385 }
19386 reqHeaders.Set("Content-Type", "application/json")
19387 c.urlParams_.Set("alt", alt)
19388 c.urlParams_.Set("prettyPrint", "false")
19389 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/advertiserLandingPages")
19390 urls += "?" + c.urlParams_.Encode()
19391 req, err := http.NewRequest("PUT", urls, body)
19392 if err != nil {
19393 return nil, err
19394 }
19395 req.Header = reqHeaders
19396 googleapi.Expand(req.URL, map[string]string{
19397 "profileId": strconv.FormatInt(c.profileId, 10),
19398 })
19399 return gensupport.SendRequest(c.ctx_, c.s.client, req)
19400 }
19401
19402
19403
19404
19405
19406
19407
19408
19409 func (c *AdvertiserLandingPagesUpdateCall) Do(opts ...googleapi.CallOption) (*LandingPage, error) {
19410 gensupport.SetOptions(c.urlParams_, opts...)
19411 res, err := c.doRequest("json")
19412 if res != nil && res.StatusCode == http.StatusNotModified {
19413 if res.Body != nil {
19414 res.Body.Close()
19415 }
19416 return nil, &googleapi.Error{
19417 Code: res.StatusCode,
19418 Header: res.Header,
19419 }
19420 }
19421 if err != nil {
19422 return nil, err
19423 }
19424 defer googleapi.CloseBody(res)
19425 if err := googleapi.CheckResponse(res); err != nil {
19426 return nil, err
19427 }
19428 ret := &LandingPage{
19429 ServerResponse: googleapi.ServerResponse{
19430 Header: res.Header,
19431 HTTPStatusCode: res.StatusCode,
19432 },
19433 }
19434 target := &ret
19435 if err := gensupport.DecodeResponse(target, res); err != nil {
19436 return nil, err
19437 }
19438 return ret, nil
19439
19440
19441
19442
19443
19444
19445
19446
19447
19448
19449
19450
19451
19452
19453
19454
19455
19456
19457
19458
19459
19460
19461
19462
19463
19464
19465
19466
19467 }
19468
19469
19470
19471 type AdvertisersGetCall struct {
19472 s *Service
19473 profileId int64
19474 id int64
19475 urlParams_ gensupport.URLParams
19476 ifNoneMatch_ string
19477 ctx_ context.Context
19478 header_ http.Header
19479 }
19480
19481
19482 func (r *AdvertisersService) Get(profileId int64, id int64) *AdvertisersGetCall {
19483 c := &AdvertisersGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
19484 c.profileId = profileId
19485 c.id = id
19486 return c
19487 }
19488
19489
19490
19491
19492 func (c *AdvertisersGetCall) Fields(s ...googleapi.Field) *AdvertisersGetCall {
19493 c.urlParams_.Set("fields", googleapi.CombineFields(s))
19494 return c
19495 }
19496
19497
19498
19499
19500
19501
19502 func (c *AdvertisersGetCall) IfNoneMatch(entityTag string) *AdvertisersGetCall {
19503 c.ifNoneMatch_ = entityTag
19504 return c
19505 }
19506
19507
19508
19509
19510 func (c *AdvertisersGetCall) Context(ctx context.Context) *AdvertisersGetCall {
19511 c.ctx_ = ctx
19512 return c
19513 }
19514
19515
19516
19517 func (c *AdvertisersGetCall) Header() http.Header {
19518 if c.header_ == nil {
19519 c.header_ = make(http.Header)
19520 }
19521 return c.header_
19522 }
19523
19524 func (c *AdvertisersGetCall) doRequest(alt string) (*http.Response, error) {
19525 reqHeaders := make(http.Header)
19526 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
19527 for k, v := range c.header_ {
19528 reqHeaders[k] = v
19529 }
19530 reqHeaders.Set("User-Agent", c.s.userAgent())
19531 if c.ifNoneMatch_ != "" {
19532 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
19533 }
19534 var body io.Reader = nil
19535 c.urlParams_.Set("alt", alt)
19536 c.urlParams_.Set("prettyPrint", "false")
19537 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/advertisers/{id}")
19538 urls += "?" + c.urlParams_.Encode()
19539 req, err := http.NewRequest("GET", urls, body)
19540 if err != nil {
19541 return nil, err
19542 }
19543 req.Header = reqHeaders
19544 googleapi.Expand(req.URL, map[string]string{
19545 "profileId": strconv.FormatInt(c.profileId, 10),
19546 "id": strconv.FormatInt(c.id, 10),
19547 })
19548 return gensupport.SendRequest(c.ctx_, c.s.client, req)
19549 }
19550
19551
19552
19553
19554
19555
19556
19557
19558 func (c *AdvertisersGetCall) Do(opts ...googleapi.CallOption) (*Advertiser, error) {
19559 gensupport.SetOptions(c.urlParams_, opts...)
19560 res, err := c.doRequest("json")
19561 if res != nil && res.StatusCode == http.StatusNotModified {
19562 if res.Body != nil {
19563 res.Body.Close()
19564 }
19565 return nil, &googleapi.Error{
19566 Code: res.StatusCode,
19567 Header: res.Header,
19568 }
19569 }
19570 if err != nil {
19571 return nil, err
19572 }
19573 defer googleapi.CloseBody(res)
19574 if err := googleapi.CheckResponse(res); err != nil {
19575 return nil, err
19576 }
19577 ret := &Advertiser{
19578 ServerResponse: googleapi.ServerResponse{
19579 Header: res.Header,
19580 HTTPStatusCode: res.StatusCode,
19581 },
19582 }
19583 target := &ret
19584 if err := gensupport.DecodeResponse(target, res); err != nil {
19585 return nil, err
19586 }
19587 return ret, nil
19588
19589
19590
19591
19592
19593
19594
19595
19596
19597
19598
19599
19600
19601
19602
19603
19604
19605
19606
19607
19608
19609
19610
19611
19612
19613
19614
19615
19616
19617
19618
19619
19620
19621 }
19622
19623
19624
19625 type AdvertisersInsertCall struct {
19626 s *Service
19627 profileId int64
19628 advertiser *Advertiser
19629 urlParams_ gensupport.URLParams
19630 ctx_ context.Context
19631 header_ http.Header
19632 }
19633
19634
19635 func (r *AdvertisersService) Insert(profileId int64, advertiser *Advertiser) *AdvertisersInsertCall {
19636 c := &AdvertisersInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
19637 c.profileId = profileId
19638 c.advertiser = advertiser
19639 return c
19640 }
19641
19642
19643
19644
19645 func (c *AdvertisersInsertCall) Fields(s ...googleapi.Field) *AdvertisersInsertCall {
19646 c.urlParams_.Set("fields", googleapi.CombineFields(s))
19647 return c
19648 }
19649
19650
19651
19652
19653 func (c *AdvertisersInsertCall) Context(ctx context.Context) *AdvertisersInsertCall {
19654 c.ctx_ = ctx
19655 return c
19656 }
19657
19658
19659
19660 func (c *AdvertisersInsertCall) Header() http.Header {
19661 if c.header_ == nil {
19662 c.header_ = make(http.Header)
19663 }
19664 return c.header_
19665 }
19666
19667 func (c *AdvertisersInsertCall) doRequest(alt string) (*http.Response, error) {
19668 reqHeaders := make(http.Header)
19669 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
19670 for k, v := range c.header_ {
19671 reqHeaders[k] = v
19672 }
19673 reqHeaders.Set("User-Agent", c.s.userAgent())
19674 var body io.Reader = nil
19675 body, err := googleapi.WithoutDataWrapper.JSONReader(c.advertiser)
19676 if err != nil {
19677 return nil, err
19678 }
19679 reqHeaders.Set("Content-Type", "application/json")
19680 c.urlParams_.Set("alt", alt)
19681 c.urlParams_.Set("prettyPrint", "false")
19682 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/advertisers")
19683 urls += "?" + c.urlParams_.Encode()
19684 req, err := http.NewRequest("POST", urls, body)
19685 if err != nil {
19686 return nil, err
19687 }
19688 req.Header = reqHeaders
19689 googleapi.Expand(req.URL, map[string]string{
19690 "profileId": strconv.FormatInt(c.profileId, 10),
19691 })
19692 return gensupport.SendRequest(c.ctx_, c.s.client, req)
19693 }
19694
19695
19696
19697
19698
19699
19700
19701
19702 func (c *AdvertisersInsertCall) Do(opts ...googleapi.CallOption) (*Advertiser, error) {
19703 gensupport.SetOptions(c.urlParams_, opts...)
19704 res, err := c.doRequest("json")
19705 if res != nil && res.StatusCode == http.StatusNotModified {
19706 if res.Body != nil {
19707 res.Body.Close()
19708 }
19709 return nil, &googleapi.Error{
19710 Code: res.StatusCode,
19711 Header: res.Header,
19712 }
19713 }
19714 if err != nil {
19715 return nil, err
19716 }
19717 defer googleapi.CloseBody(res)
19718 if err := googleapi.CheckResponse(res); err != nil {
19719 return nil, err
19720 }
19721 ret := &Advertiser{
19722 ServerResponse: googleapi.ServerResponse{
19723 Header: res.Header,
19724 HTTPStatusCode: res.StatusCode,
19725 },
19726 }
19727 target := &ret
19728 if err := gensupport.DecodeResponse(target, res); err != nil {
19729 return nil, err
19730 }
19731 return ret, nil
19732
19733
19734
19735
19736
19737
19738
19739
19740
19741
19742
19743
19744
19745
19746
19747
19748
19749
19750
19751
19752
19753
19754
19755
19756
19757
19758
19759
19760 }
19761
19762
19763
19764 type AdvertisersListCall struct {
19765 s *Service
19766 profileId int64
19767 urlParams_ gensupport.URLParams
19768 ifNoneMatch_ string
19769 ctx_ context.Context
19770 header_ http.Header
19771 }
19772
19773
19774
19775 func (r *AdvertisersService) List(profileId int64) *AdvertisersListCall {
19776 c := &AdvertisersListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
19777 c.profileId = profileId
19778 return c
19779 }
19780
19781
19782
19783 func (c *AdvertisersListCall) AdvertiserGroupIds(advertiserGroupIds ...int64) *AdvertisersListCall {
19784 var advertiserGroupIds_ []string
19785 for _, v := range advertiserGroupIds {
19786 advertiserGroupIds_ = append(advertiserGroupIds_, fmt.Sprint(v))
19787 }
19788 c.urlParams_.SetMulti("advertiserGroupIds", advertiserGroupIds_)
19789 return c
19790 }
19791
19792
19793
19794
19795 func (c *AdvertisersListCall) FloodlightConfigurationIds(floodlightConfigurationIds ...int64) *AdvertisersListCall {
19796 var floodlightConfigurationIds_ []string
19797 for _, v := range floodlightConfigurationIds {
19798 floodlightConfigurationIds_ = append(floodlightConfigurationIds_, fmt.Sprint(v))
19799 }
19800 c.urlParams_.SetMulti("floodlightConfigurationIds", floodlightConfigurationIds_)
19801 return c
19802 }
19803
19804
19805
19806 func (c *AdvertisersListCall) Ids(ids ...int64) *AdvertisersListCall {
19807 var ids_ []string
19808 for _, v := range ids {
19809 ids_ = append(ids_, fmt.Sprint(v))
19810 }
19811 c.urlParams_.SetMulti("ids", ids_)
19812 return c
19813 }
19814
19815
19816
19817
19818 func (c *AdvertisersListCall) IncludeAdvertisersWithoutGroupsOnly(includeAdvertisersWithoutGroupsOnly bool) *AdvertisersListCall {
19819 c.urlParams_.Set("includeAdvertisersWithoutGroupsOnly", fmt.Sprint(includeAdvertisersWithoutGroupsOnly))
19820 return c
19821 }
19822
19823
19824
19825 func (c *AdvertisersListCall) MaxResults(maxResults int64) *AdvertisersListCall {
19826 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
19827 return c
19828 }
19829
19830
19831
19832 func (c *AdvertisersListCall) OnlyParent(onlyParent bool) *AdvertisersListCall {
19833 c.urlParams_.Set("onlyParent", fmt.Sprint(onlyParent))
19834 return c
19835 }
19836
19837
19838
19839 func (c *AdvertisersListCall) PageToken(pageToken string) *AdvertisersListCall {
19840 c.urlParams_.Set("pageToken", pageToken)
19841 return c
19842 }
19843
19844
19845
19846
19847
19848
19849
19850
19851
19852 func (c *AdvertisersListCall) SearchString(searchString string) *AdvertisersListCall {
19853 c.urlParams_.Set("searchString", searchString)
19854 return c
19855 }
19856
19857
19858
19859
19860
19861
19862
19863
19864 func (c *AdvertisersListCall) SortField(sortField string) *AdvertisersListCall {
19865 c.urlParams_.Set("sortField", sortField)
19866 return c
19867 }
19868
19869
19870
19871
19872
19873
19874
19875
19876 func (c *AdvertisersListCall) SortOrder(sortOrder string) *AdvertisersListCall {
19877 c.urlParams_.Set("sortOrder", sortOrder)
19878 return c
19879 }
19880
19881
19882
19883
19884
19885
19886
19887
19888 func (c *AdvertisersListCall) Status(status string) *AdvertisersListCall {
19889 c.urlParams_.Set("status", status)
19890 return c
19891 }
19892
19893
19894
19895 func (c *AdvertisersListCall) SubaccountId(subaccountId int64) *AdvertisersListCall {
19896 c.urlParams_.Set("subaccountId", fmt.Sprint(subaccountId))
19897 return c
19898 }
19899
19900
19901
19902
19903 func (c *AdvertisersListCall) Fields(s ...googleapi.Field) *AdvertisersListCall {
19904 c.urlParams_.Set("fields", googleapi.CombineFields(s))
19905 return c
19906 }
19907
19908
19909
19910
19911
19912
19913 func (c *AdvertisersListCall) IfNoneMatch(entityTag string) *AdvertisersListCall {
19914 c.ifNoneMatch_ = entityTag
19915 return c
19916 }
19917
19918
19919
19920
19921 func (c *AdvertisersListCall) Context(ctx context.Context) *AdvertisersListCall {
19922 c.ctx_ = ctx
19923 return c
19924 }
19925
19926
19927
19928 func (c *AdvertisersListCall) Header() http.Header {
19929 if c.header_ == nil {
19930 c.header_ = make(http.Header)
19931 }
19932 return c.header_
19933 }
19934
19935 func (c *AdvertisersListCall) doRequest(alt string) (*http.Response, error) {
19936 reqHeaders := make(http.Header)
19937 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
19938 for k, v := range c.header_ {
19939 reqHeaders[k] = v
19940 }
19941 reqHeaders.Set("User-Agent", c.s.userAgent())
19942 if c.ifNoneMatch_ != "" {
19943 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
19944 }
19945 var body io.Reader = nil
19946 c.urlParams_.Set("alt", alt)
19947 c.urlParams_.Set("prettyPrint", "false")
19948 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/advertisers")
19949 urls += "?" + c.urlParams_.Encode()
19950 req, err := http.NewRequest("GET", urls, body)
19951 if err != nil {
19952 return nil, err
19953 }
19954 req.Header = reqHeaders
19955 googleapi.Expand(req.URL, map[string]string{
19956 "profileId": strconv.FormatInt(c.profileId, 10),
19957 })
19958 return gensupport.SendRequest(c.ctx_, c.s.client, req)
19959 }
19960
19961
19962
19963
19964
19965
19966
19967
19968 func (c *AdvertisersListCall) Do(opts ...googleapi.CallOption) (*AdvertisersListResponse, error) {
19969 gensupport.SetOptions(c.urlParams_, opts...)
19970 res, err := c.doRequest("json")
19971 if res != nil && res.StatusCode == http.StatusNotModified {
19972 if res.Body != nil {
19973 res.Body.Close()
19974 }
19975 return nil, &googleapi.Error{
19976 Code: res.StatusCode,
19977 Header: res.Header,
19978 }
19979 }
19980 if err != nil {
19981 return nil, err
19982 }
19983 defer googleapi.CloseBody(res)
19984 if err := googleapi.CheckResponse(res); err != nil {
19985 return nil, err
19986 }
19987 ret := &AdvertisersListResponse{
19988 ServerResponse: googleapi.ServerResponse{
19989 Header: res.Header,
19990 HTTPStatusCode: res.StatusCode,
19991 },
19992 }
19993 target := &ret
19994 if err := gensupport.DecodeResponse(target, res); err != nil {
19995 return nil, err
19996 }
19997 return ret, nil
19998
19999
20000
20001
20002
20003
20004
20005
20006
20007
20008
20009
20010
20011
20012
20013
20014
20015
20016
20017
20018
20019
20020
20021
20022
20023
20024
20025
20026
20027
20028
20029
20030
20031
20032
20033
20034
20035
20036
20037
20038
20039
20040
20041
20042
20043
20044
20045
20046
20047
20048
20049
20050
20051
20052
20053
20054
20055
20056
20057
20058
20059
20060
20061
20062
20063
20064
20065
20066
20067
20068
20069
20070
20071
20072
20073
20074
20075
20076
20077
20078
20079
20080
20081
20082
20083
20084
20085
20086
20087
20088
20089
20090
20091
20092
20093
20094
20095
20096
20097
20098
20099
20100
20101
20102
20103
20104
20105
20106
20107
20108
20109
20110
20111
20112
20113
20114
20115
20116
20117
20118
20119
20120 }
20121
20122
20123
20124
20125 func (c *AdvertisersListCall) Pages(ctx context.Context, f func(*AdvertisersListResponse) error) error {
20126 c.ctx_ = ctx
20127 defer c.PageToken(c.urlParams_.Get("pageToken"))
20128 for {
20129 x, err := c.Do()
20130 if err != nil {
20131 return err
20132 }
20133 if err := f(x); err != nil {
20134 return err
20135 }
20136 if x.NextPageToken == "" {
20137 return nil
20138 }
20139 c.PageToken(x.NextPageToken)
20140 }
20141 }
20142
20143
20144
20145 type AdvertisersPatchCall struct {
20146 s *Service
20147 profileId int64
20148 advertiser *Advertiser
20149 urlParams_ gensupport.URLParams
20150 ctx_ context.Context
20151 header_ http.Header
20152 }
20153
20154
20155
20156 func (r *AdvertisersService) Patch(profileId int64, id int64, advertiser *Advertiser) *AdvertisersPatchCall {
20157 c := &AdvertisersPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
20158 c.profileId = profileId
20159 c.urlParams_.Set("id", fmt.Sprint(id))
20160 c.advertiser = advertiser
20161 return c
20162 }
20163
20164
20165
20166
20167 func (c *AdvertisersPatchCall) Fields(s ...googleapi.Field) *AdvertisersPatchCall {
20168 c.urlParams_.Set("fields", googleapi.CombineFields(s))
20169 return c
20170 }
20171
20172
20173
20174
20175 func (c *AdvertisersPatchCall) Context(ctx context.Context) *AdvertisersPatchCall {
20176 c.ctx_ = ctx
20177 return c
20178 }
20179
20180
20181
20182 func (c *AdvertisersPatchCall) Header() http.Header {
20183 if c.header_ == nil {
20184 c.header_ = make(http.Header)
20185 }
20186 return c.header_
20187 }
20188
20189 func (c *AdvertisersPatchCall) doRequest(alt string) (*http.Response, error) {
20190 reqHeaders := make(http.Header)
20191 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
20192 for k, v := range c.header_ {
20193 reqHeaders[k] = v
20194 }
20195 reqHeaders.Set("User-Agent", c.s.userAgent())
20196 var body io.Reader = nil
20197 body, err := googleapi.WithoutDataWrapper.JSONReader(c.advertiser)
20198 if err != nil {
20199 return nil, err
20200 }
20201 reqHeaders.Set("Content-Type", "application/json")
20202 c.urlParams_.Set("alt", alt)
20203 c.urlParams_.Set("prettyPrint", "false")
20204 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/advertisers")
20205 urls += "?" + c.urlParams_.Encode()
20206 req, err := http.NewRequest("PATCH", urls, body)
20207 if err != nil {
20208 return nil, err
20209 }
20210 req.Header = reqHeaders
20211 googleapi.Expand(req.URL, map[string]string{
20212 "profileId": strconv.FormatInt(c.profileId, 10),
20213 })
20214 return gensupport.SendRequest(c.ctx_, c.s.client, req)
20215 }
20216
20217
20218
20219
20220
20221
20222
20223
20224 func (c *AdvertisersPatchCall) Do(opts ...googleapi.CallOption) (*Advertiser, error) {
20225 gensupport.SetOptions(c.urlParams_, opts...)
20226 res, err := c.doRequest("json")
20227 if res != nil && res.StatusCode == http.StatusNotModified {
20228 if res.Body != nil {
20229 res.Body.Close()
20230 }
20231 return nil, &googleapi.Error{
20232 Code: res.StatusCode,
20233 Header: res.Header,
20234 }
20235 }
20236 if err != nil {
20237 return nil, err
20238 }
20239 defer googleapi.CloseBody(res)
20240 if err := googleapi.CheckResponse(res); err != nil {
20241 return nil, err
20242 }
20243 ret := &Advertiser{
20244 ServerResponse: googleapi.ServerResponse{
20245 Header: res.Header,
20246 HTTPStatusCode: res.StatusCode,
20247 },
20248 }
20249 target := &ret
20250 if err := gensupport.DecodeResponse(target, res); err != nil {
20251 return nil, err
20252 }
20253 return ret, nil
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 type AdvertisersUpdateCall struct {
20295 s *Service
20296 profileId int64
20297 advertiser *Advertiser
20298 urlParams_ gensupport.URLParams
20299 ctx_ context.Context
20300 header_ http.Header
20301 }
20302
20303
20304 func (r *AdvertisersService) Update(profileId int64, advertiser *Advertiser) *AdvertisersUpdateCall {
20305 c := &AdvertisersUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
20306 c.profileId = profileId
20307 c.advertiser = advertiser
20308 return c
20309 }
20310
20311
20312
20313
20314 func (c *AdvertisersUpdateCall) Fields(s ...googleapi.Field) *AdvertisersUpdateCall {
20315 c.urlParams_.Set("fields", googleapi.CombineFields(s))
20316 return c
20317 }
20318
20319
20320
20321
20322 func (c *AdvertisersUpdateCall) Context(ctx context.Context) *AdvertisersUpdateCall {
20323 c.ctx_ = ctx
20324 return c
20325 }
20326
20327
20328
20329 func (c *AdvertisersUpdateCall) Header() http.Header {
20330 if c.header_ == nil {
20331 c.header_ = make(http.Header)
20332 }
20333 return c.header_
20334 }
20335
20336 func (c *AdvertisersUpdateCall) doRequest(alt string) (*http.Response, error) {
20337 reqHeaders := make(http.Header)
20338 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
20339 for k, v := range c.header_ {
20340 reqHeaders[k] = v
20341 }
20342 reqHeaders.Set("User-Agent", c.s.userAgent())
20343 var body io.Reader = nil
20344 body, err := googleapi.WithoutDataWrapper.JSONReader(c.advertiser)
20345 if err != nil {
20346 return nil, err
20347 }
20348 reqHeaders.Set("Content-Type", "application/json")
20349 c.urlParams_.Set("alt", alt)
20350 c.urlParams_.Set("prettyPrint", "false")
20351 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/advertisers")
20352 urls += "?" + c.urlParams_.Encode()
20353 req, err := http.NewRequest("PUT", urls, body)
20354 if err != nil {
20355 return nil, err
20356 }
20357 req.Header = reqHeaders
20358 googleapi.Expand(req.URL, map[string]string{
20359 "profileId": strconv.FormatInt(c.profileId, 10),
20360 })
20361 return gensupport.SendRequest(c.ctx_, c.s.client, req)
20362 }
20363
20364
20365
20366
20367
20368
20369
20370
20371 func (c *AdvertisersUpdateCall) Do(opts ...googleapi.CallOption) (*Advertiser, error) {
20372 gensupport.SetOptions(c.urlParams_, opts...)
20373 res, err := c.doRequest("json")
20374 if res != nil && res.StatusCode == http.StatusNotModified {
20375 if res.Body != nil {
20376 res.Body.Close()
20377 }
20378 return nil, &googleapi.Error{
20379 Code: res.StatusCode,
20380 Header: res.Header,
20381 }
20382 }
20383 if err != nil {
20384 return nil, err
20385 }
20386 defer googleapi.CloseBody(res)
20387 if err := googleapi.CheckResponse(res); err != nil {
20388 return nil, err
20389 }
20390 ret := &Advertiser{
20391 ServerResponse: googleapi.ServerResponse{
20392 Header: res.Header,
20393 HTTPStatusCode: res.StatusCode,
20394 },
20395 }
20396 target := &ret
20397 if err := gensupport.DecodeResponse(target, res); err != nil {
20398 return nil, err
20399 }
20400 return ret, nil
20401
20402
20403
20404
20405
20406
20407
20408
20409
20410
20411
20412
20413
20414
20415
20416
20417
20418
20419
20420
20421
20422
20423
20424
20425
20426
20427
20428
20429 }
20430
20431
20432
20433 type BrowsersListCall struct {
20434 s *Service
20435 profileId int64
20436 urlParams_ gensupport.URLParams
20437 ifNoneMatch_ string
20438 ctx_ context.Context
20439 header_ http.Header
20440 }
20441
20442
20443 func (r *BrowsersService) List(profileId int64) *BrowsersListCall {
20444 c := &BrowsersListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
20445 c.profileId = profileId
20446 return c
20447 }
20448
20449
20450
20451
20452 func (c *BrowsersListCall) Fields(s ...googleapi.Field) *BrowsersListCall {
20453 c.urlParams_.Set("fields", googleapi.CombineFields(s))
20454 return c
20455 }
20456
20457
20458
20459
20460
20461
20462 func (c *BrowsersListCall) IfNoneMatch(entityTag string) *BrowsersListCall {
20463 c.ifNoneMatch_ = entityTag
20464 return c
20465 }
20466
20467
20468
20469
20470 func (c *BrowsersListCall) Context(ctx context.Context) *BrowsersListCall {
20471 c.ctx_ = ctx
20472 return c
20473 }
20474
20475
20476
20477 func (c *BrowsersListCall) Header() http.Header {
20478 if c.header_ == nil {
20479 c.header_ = make(http.Header)
20480 }
20481 return c.header_
20482 }
20483
20484 func (c *BrowsersListCall) doRequest(alt string) (*http.Response, error) {
20485 reqHeaders := make(http.Header)
20486 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
20487 for k, v := range c.header_ {
20488 reqHeaders[k] = v
20489 }
20490 reqHeaders.Set("User-Agent", c.s.userAgent())
20491 if c.ifNoneMatch_ != "" {
20492 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
20493 }
20494 var body io.Reader = nil
20495 c.urlParams_.Set("alt", alt)
20496 c.urlParams_.Set("prettyPrint", "false")
20497 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/browsers")
20498 urls += "?" + c.urlParams_.Encode()
20499 req, err := http.NewRequest("GET", urls, body)
20500 if err != nil {
20501 return nil, err
20502 }
20503 req.Header = reqHeaders
20504 googleapi.Expand(req.URL, map[string]string{
20505 "profileId": strconv.FormatInt(c.profileId, 10),
20506 })
20507 return gensupport.SendRequest(c.ctx_, c.s.client, req)
20508 }
20509
20510
20511
20512
20513
20514
20515
20516
20517 func (c *BrowsersListCall) Do(opts ...googleapi.CallOption) (*BrowsersListResponse, error) {
20518 gensupport.SetOptions(c.urlParams_, opts...)
20519 res, err := c.doRequest("json")
20520 if res != nil && res.StatusCode == http.StatusNotModified {
20521 if res.Body != nil {
20522 res.Body.Close()
20523 }
20524 return nil, &googleapi.Error{
20525 Code: res.StatusCode,
20526 Header: res.Header,
20527 }
20528 }
20529 if err != nil {
20530 return nil, err
20531 }
20532 defer googleapi.CloseBody(res)
20533 if err := googleapi.CheckResponse(res); err != nil {
20534 return nil, err
20535 }
20536 ret := &BrowsersListResponse{
20537 ServerResponse: googleapi.ServerResponse{
20538 Header: res.Header,
20539 HTTPStatusCode: res.StatusCode,
20540 },
20541 }
20542 target := &ret
20543 if err := gensupport.DecodeResponse(target, res); err != nil {
20544 return nil, err
20545 }
20546 return ret, nil
20547
20548
20549
20550
20551
20552
20553
20554
20555
20556
20557
20558
20559
20560
20561
20562
20563
20564
20565
20566
20567
20568
20569
20570
20571
20572 }
20573
20574
20575
20576 type CampaignCreativeAssociationsInsertCall struct {
20577 s *Service
20578 profileId int64
20579 campaignId int64
20580 campaigncreativeassociation *CampaignCreativeAssociation
20581 urlParams_ gensupport.URLParams
20582 ctx_ context.Context
20583 header_ http.Header
20584 }
20585
20586
20587
20588
20589 func (r *CampaignCreativeAssociationsService) Insert(profileId int64, campaignId int64, campaigncreativeassociation *CampaignCreativeAssociation) *CampaignCreativeAssociationsInsertCall {
20590 c := &CampaignCreativeAssociationsInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
20591 c.profileId = profileId
20592 c.campaignId = campaignId
20593 c.campaigncreativeassociation = campaigncreativeassociation
20594 return c
20595 }
20596
20597
20598
20599
20600 func (c *CampaignCreativeAssociationsInsertCall) Fields(s ...googleapi.Field) *CampaignCreativeAssociationsInsertCall {
20601 c.urlParams_.Set("fields", googleapi.CombineFields(s))
20602 return c
20603 }
20604
20605
20606
20607
20608 func (c *CampaignCreativeAssociationsInsertCall) Context(ctx context.Context) *CampaignCreativeAssociationsInsertCall {
20609 c.ctx_ = ctx
20610 return c
20611 }
20612
20613
20614
20615 func (c *CampaignCreativeAssociationsInsertCall) Header() http.Header {
20616 if c.header_ == nil {
20617 c.header_ = make(http.Header)
20618 }
20619 return c.header_
20620 }
20621
20622 func (c *CampaignCreativeAssociationsInsertCall) doRequest(alt string) (*http.Response, error) {
20623 reqHeaders := make(http.Header)
20624 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
20625 for k, v := range c.header_ {
20626 reqHeaders[k] = v
20627 }
20628 reqHeaders.Set("User-Agent", c.s.userAgent())
20629 var body io.Reader = nil
20630 body, err := googleapi.WithoutDataWrapper.JSONReader(c.campaigncreativeassociation)
20631 if err != nil {
20632 return nil, err
20633 }
20634 reqHeaders.Set("Content-Type", "application/json")
20635 c.urlParams_.Set("alt", alt)
20636 c.urlParams_.Set("prettyPrint", "false")
20637 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/campaigns/{campaignId}/campaignCreativeAssociations")
20638 urls += "?" + c.urlParams_.Encode()
20639 req, err := http.NewRequest("POST", urls, body)
20640 if err != nil {
20641 return nil, err
20642 }
20643 req.Header = reqHeaders
20644 googleapi.Expand(req.URL, map[string]string{
20645 "profileId": strconv.FormatInt(c.profileId, 10),
20646 "campaignId": strconv.FormatInt(c.campaignId, 10),
20647 })
20648 return gensupport.SendRequest(c.ctx_, c.s.client, req)
20649 }
20650
20651
20652
20653
20654
20655
20656
20657
20658 func (c *CampaignCreativeAssociationsInsertCall) Do(opts ...googleapi.CallOption) (*CampaignCreativeAssociation, error) {
20659 gensupport.SetOptions(c.urlParams_, opts...)
20660 res, err := c.doRequest("json")
20661 if res != nil && res.StatusCode == http.StatusNotModified {
20662 if res.Body != nil {
20663 res.Body.Close()
20664 }
20665 return nil, &googleapi.Error{
20666 Code: res.StatusCode,
20667 Header: res.Header,
20668 }
20669 }
20670 if err != nil {
20671 return nil, err
20672 }
20673 defer googleapi.CloseBody(res)
20674 if err := googleapi.CheckResponse(res); err != nil {
20675 return nil, err
20676 }
20677 ret := &CampaignCreativeAssociation{
20678 ServerResponse: googleapi.ServerResponse{
20679 Header: res.Header,
20680 HTTPStatusCode: res.StatusCode,
20681 },
20682 }
20683 target := &ret
20684 if err := gensupport.DecodeResponse(target, res); err != nil {
20685 return nil, err
20686 }
20687 return ret, nil
20688
20689
20690
20691
20692
20693
20694
20695
20696
20697
20698
20699
20700
20701
20702
20703
20704
20705
20706
20707
20708
20709
20710
20711
20712
20713
20714
20715
20716
20717
20718
20719
20720
20721
20722
20723
20724 }
20725
20726
20727
20728 type CampaignCreativeAssociationsListCall struct {
20729 s *Service
20730 profileId int64
20731 campaignId int64
20732 urlParams_ gensupport.URLParams
20733 ifNoneMatch_ string
20734 ctx_ context.Context
20735 header_ http.Header
20736 }
20737
20738
20739
20740 func (r *CampaignCreativeAssociationsService) List(profileId int64, campaignId int64) *CampaignCreativeAssociationsListCall {
20741 c := &CampaignCreativeAssociationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
20742 c.profileId = profileId
20743 c.campaignId = campaignId
20744 return c
20745 }
20746
20747
20748
20749 func (c *CampaignCreativeAssociationsListCall) MaxResults(maxResults int64) *CampaignCreativeAssociationsListCall {
20750 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
20751 return c
20752 }
20753
20754
20755
20756 func (c *CampaignCreativeAssociationsListCall) PageToken(pageToken string) *CampaignCreativeAssociationsListCall {
20757 c.urlParams_.Set("pageToken", pageToken)
20758 return c
20759 }
20760
20761
20762
20763
20764
20765
20766
20767
20768 func (c *CampaignCreativeAssociationsListCall) SortOrder(sortOrder string) *CampaignCreativeAssociationsListCall {
20769 c.urlParams_.Set("sortOrder", sortOrder)
20770 return c
20771 }
20772
20773
20774
20775
20776 func (c *CampaignCreativeAssociationsListCall) Fields(s ...googleapi.Field) *CampaignCreativeAssociationsListCall {
20777 c.urlParams_.Set("fields", googleapi.CombineFields(s))
20778 return c
20779 }
20780
20781
20782
20783
20784
20785
20786 func (c *CampaignCreativeAssociationsListCall) IfNoneMatch(entityTag string) *CampaignCreativeAssociationsListCall {
20787 c.ifNoneMatch_ = entityTag
20788 return c
20789 }
20790
20791
20792
20793
20794 func (c *CampaignCreativeAssociationsListCall) Context(ctx context.Context) *CampaignCreativeAssociationsListCall {
20795 c.ctx_ = ctx
20796 return c
20797 }
20798
20799
20800
20801 func (c *CampaignCreativeAssociationsListCall) Header() http.Header {
20802 if c.header_ == nil {
20803 c.header_ = make(http.Header)
20804 }
20805 return c.header_
20806 }
20807
20808 func (c *CampaignCreativeAssociationsListCall) doRequest(alt string) (*http.Response, error) {
20809 reqHeaders := make(http.Header)
20810 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
20811 for k, v := range c.header_ {
20812 reqHeaders[k] = v
20813 }
20814 reqHeaders.Set("User-Agent", c.s.userAgent())
20815 if c.ifNoneMatch_ != "" {
20816 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
20817 }
20818 var body io.Reader = nil
20819 c.urlParams_.Set("alt", alt)
20820 c.urlParams_.Set("prettyPrint", "false")
20821 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/campaigns/{campaignId}/campaignCreativeAssociations")
20822 urls += "?" + c.urlParams_.Encode()
20823 req, err := http.NewRequest("GET", urls, body)
20824 if err != nil {
20825 return nil, err
20826 }
20827 req.Header = reqHeaders
20828 googleapi.Expand(req.URL, map[string]string{
20829 "profileId": strconv.FormatInt(c.profileId, 10),
20830 "campaignId": strconv.FormatInt(c.campaignId, 10),
20831 })
20832 return gensupport.SendRequest(c.ctx_, c.s.client, req)
20833 }
20834
20835
20836
20837
20838
20839
20840
20841
20842
20843
20844 func (c *CampaignCreativeAssociationsListCall) Do(opts ...googleapi.CallOption) (*CampaignCreativeAssociationsListResponse, error) {
20845 gensupport.SetOptions(c.urlParams_, opts...)
20846 res, err := c.doRequest("json")
20847 if res != nil && res.StatusCode == http.StatusNotModified {
20848 if res.Body != nil {
20849 res.Body.Close()
20850 }
20851 return nil, &googleapi.Error{
20852 Code: res.StatusCode,
20853 Header: res.Header,
20854 }
20855 }
20856 if err != nil {
20857 return nil, err
20858 }
20859 defer googleapi.CloseBody(res)
20860 if err := googleapi.CheckResponse(res); err != nil {
20861 return nil, err
20862 }
20863 ret := &CampaignCreativeAssociationsListResponse{
20864 ServerResponse: googleapi.ServerResponse{
20865 Header: res.Header,
20866 HTTPStatusCode: res.StatusCode,
20867 },
20868 }
20869 target := &ret
20870 if err := gensupport.DecodeResponse(target, res); err != nil {
20871 return nil, err
20872 }
20873 return ret, nil
20874
20875
20876
20877
20878
20879
20880
20881
20882
20883
20884
20885
20886
20887
20888
20889
20890
20891
20892
20893
20894
20895
20896
20897
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
20939
20940 func (c *CampaignCreativeAssociationsListCall) Pages(ctx context.Context, f func(*CampaignCreativeAssociationsListResponse) error) error {
20941 c.ctx_ = ctx
20942 defer c.PageToken(c.urlParams_.Get("pageToken"))
20943 for {
20944 x, err := c.Do()
20945 if err != nil {
20946 return err
20947 }
20948 if err := f(x); err != nil {
20949 return err
20950 }
20951 if x.NextPageToken == "" {
20952 return nil
20953 }
20954 c.PageToken(x.NextPageToken)
20955 }
20956 }
20957
20958
20959
20960 type CampaignsGetCall struct {
20961 s *Service
20962 profileId int64
20963 id int64
20964 urlParams_ gensupport.URLParams
20965 ifNoneMatch_ string
20966 ctx_ context.Context
20967 header_ http.Header
20968 }
20969
20970
20971 func (r *CampaignsService) Get(profileId int64, id int64) *CampaignsGetCall {
20972 c := &CampaignsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
20973 c.profileId = profileId
20974 c.id = id
20975 return c
20976 }
20977
20978
20979
20980
20981 func (c *CampaignsGetCall) Fields(s ...googleapi.Field) *CampaignsGetCall {
20982 c.urlParams_.Set("fields", googleapi.CombineFields(s))
20983 return c
20984 }
20985
20986
20987
20988
20989
20990
20991 func (c *CampaignsGetCall) IfNoneMatch(entityTag string) *CampaignsGetCall {
20992 c.ifNoneMatch_ = entityTag
20993 return c
20994 }
20995
20996
20997
20998
20999 func (c *CampaignsGetCall) Context(ctx context.Context) *CampaignsGetCall {
21000 c.ctx_ = ctx
21001 return c
21002 }
21003
21004
21005
21006 func (c *CampaignsGetCall) Header() http.Header {
21007 if c.header_ == nil {
21008 c.header_ = make(http.Header)
21009 }
21010 return c.header_
21011 }
21012
21013 func (c *CampaignsGetCall) doRequest(alt string) (*http.Response, error) {
21014 reqHeaders := make(http.Header)
21015 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
21016 for k, v := range c.header_ {
21017 reqHeaders[k] = v
21018 }
21019 reqHeaders.Set("User-Agent", c.s.userAgent())
21020 if c.ifNoneMatch_ != "" {
21021 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
21022 }
21023 var body io.Reader = nil
21024 c.urlParams_.Set("alt", alt)
21025 c.urlParams_.Set("prettyPrint", "false")
21026 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/campaigns/{id}")
21027 urls += "?" + c.urlParams_.Encode()
21028 req, err := http.NewRequest("GET", urls, body)
21029 if err != nil {
21030 return nil, err
21031 }
21032 req.Header = reqHeaders
21033 googleapi.Expand(req.URL, map[string]string{
21034 "profileId": strconv.FormatInt(c.profileId, 10),
21035 "id": strconv.FormatInt(c.id, 10),
21036 })
21037 return gensupport.SendRequest(c.ctx_, c.s.client, req)
21038 }
21039
21040
21041
21042
21043
21044
21045
21046
21047 func (c *CampaignsGetCall) Do(opts ...googleapi.CallOption) (*Campaign, error) {
21048 gensupport.SetOptions(c.urlParams_, opts...)
21049 res, err := c.doRequest("json")
21050 if res != nil && res.StatusCode == http.StatusNotModified {
21051 if res.Body != nil {
21052 res.Body.Close()
21053 }
21054 return nil, &googleapi.Error{
21055 Code: res.StatusCode,
21056 Header: res.Header,
21057 }
21058 }
21059 if err != nil {
21060 return nil, err
21061 }
21062 defer googleapi.CloseBody(res)
21063 if err := googleapi.CheckResponse(res); err != nil {
21064 return nil, err
21065 }
21066 ret := &Campaign{
21067 ServerResponse: googleapi.ServerResponse{
21068 Header: res.Header,
21069 HTTPStatusCode: res.StatusCode,
21070 },
21071 }
21072 target := &ret
21073 if err := gensupport.DecodeResponse(target, res); err != nil {
21074 return nil, err
21075 }
21076 return ret, nil
21077
21078
21079
21080
21081
21082
21083
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 type CampaignsInsertCall struct {
21115 s *Service
21116 profileId int64
21117 campaign *Campaign
21118 urlParams_ gensupport.URLParams
21119 ctx_ context.Context
21120 header_ http.Header
21121 }
21122
21123
21124 func (r *CampaignsService) Insert(profileId int64, campaign *Campaign) *CampaignsInsertCall {
21125 c := &CampaignsInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
21126 c.profileId = profileId
21127 c.campaign = campaign
21128 return c
21129 }
21130
21131
21132
21133
21134 func (c *CampaignsInsertCall) Fields(s ...googleapi.Field) *CampaignsInsertCall {
21135 c.urlParams_.Set("fields", googleapi.CombineFields(s))
21136 return c
21137 }
21138
21139
21140
21141
21142 func (c *CampaignsInsertCall) Context(ctx context.Context) *CampaignsInsertCall {
21143 c.ctx_ = ctx
21144 return c
21145 }
21146
21147
21148
21149 func (c *CampaignsInsertCall) Header() http.Header {
21150 if c.header_ == nil {
21151 c.header_ = make(http.Header)
21152 }
21153 return c.header_
21154 }
21155
21156 func (c *CampaignsInsertCall) doRequest(alt string) (*http.Response, error) {
21157 reqHeaders := make(http.Header)
21158 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
21159 for k, v := range c.header_ {
21160 reqHeaders[k] = v
21161 }
21162 reqHeaders.Set("User-Agent", c.s.userAgent())
21163 var body io.Reader = nil
21164 body, err := googleapi.WithoutDataWrapper.JSONReader(c.campaign)
21165 if err != nil {
21166 return nil, err
21167 }
21168 reqHeaders.Set("Content-Type", "application/json")
21169 c.urlParams_.Set("alt", alt)
21170 c.urlParams_.Set("prettyPrint", "false")
21171 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/campaigns")
21172 urls += "?" + c.urlParams_.Encode()
21173 req, err := http.NewRequest("POST", urls, body)
21174 if err != nil {
21175 return nil, err
21176 }
21177 req.Header = reqHeaders
21178 googleapi.Expand(req.URL, map[string]string{
21179 "profileId": strconv.FormatInt(c.profileId, 10),
21180 })
21181 return gensupport.SendRequest(c.ctx_, c.s.client, req)
21182 }
21183
21184
21185
21186
21187
21188
21189
21190
21191 func (c *CampaignsInsertCall) Do(opts ...googleapi.CallOption) (*Campaign, error) {
21192 gensupport.SetOptions(c.urlParams_, opts...)
21193 res, err := c.doRequest("json")
21194 if res != nil && res.StatusCode == http.StatusNotModified {
21195 if res.Body != nil {
21196 res.Body.Close()
21197 }
21198 return nil, &googleapi.Error{
21199 Code: res.StatusCode,
21200 Header: res.Header,
21201 }
21202 }
21203 if err != nil {
21204 return nil, err
21205 }
21206 defer googleapi.CloseBody(res)
21207 if err := googleapi.CheckResponse(res); err != nil {
21208 return nil, err
21209 }
21210 ret := &Campaign{
21211 ServerResponse: googleapi.ServerResponse{
21212 Header: res.Header,
21213 HTTPStatusCode: res.StatusCode,
21214 },
21215 }
21216 target := &ret
21217 if err := gensupport.DecodeResponse(target, res); err != nil {
21218 return nil, err
21219 }
21220 return ret, nil
21221
21222
21223
21224
21225
21226
21227
21228
21229
21230
21231
21232
21233
21234
21235
21236
21237
21238
21239
21240
21241
21242
21243
21244
21245
21246
21247
21248
21249 }
21250
21251
21252
21253 type CampaignsListCall struct {
21254 s *Service
21255 profileId int64
21256 urlParams_ gensupport.URLParams
21257 ifNoneMatch_ string
21258 ctx_ context.Context
21259 header_ http.Header
21260 }
21261
21262
21263
21264 func (r *CampaignsService) List(profileId int64) *CampaignsListCall {
21265 c := &CampaignsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
21266 c.profileId = profileId
21267 return c
21268 }
21269
21270
21271
21272
21273 func (c *CampaignsListCall) AdvertiserGroupIds(advertiserGroupIds ...int64) *CampaignsListCall {
21274 var advertiserGroupIds_ []string
21275 for _, v := range advertiserGroupIds {
21276 advertiserGroupIds_ = append(advertiserGroupIds_, fmt.Sprint(v))
21277 }
21278 c.urlParams_.SetMulti("advertiserGroupIds", advertiserGroupIds_)
21279 return c
21280 }
21281
21282
21283
21284 func (c *CampaignsListCall) AdvertiserIds(advertiserIds ...int64) *CampaignsListCall {
21285 var advertiserIds_ []string
21286 for _, v := range advertiserIds {
21287 advertiserIds_ = append(advertiserIds_, fmt.Sprint(v))
21288 }
21289 c.urlParams_.SetMulti("advertiserIds", advertiserIds_)
21290 return c
21291 }
21292
21293
21294
21295
21296 func (c *CampaignsListCall) Archived(archived bool) *CampaignsListCall {
21297 c.urlParams_.Set("archived", fmt.Sprint(archived))
21298 return c
21299 }
21300
21301
21302
21303
21304 func (c *CampaignsListCall) AtLeastOneOptimizationActivity(atLeastOneOptimizationActivity bool) *CampaignsListCall {
21305 c.urlParams_.Set("atLeastOneOptimizationActivity", fmt.Sprint(atLeastOneOptimizationActivity))
21306 return c
21307 }
21308
21309
21310
21311 func (c *CampaignsListCall) ExcludedIds(excludedIds ...int64) *CampaignsListCall {
21312 var excludedIds_ []string
21313 for _, v := range excludedIds {
21314 excludedIds_ = append(excludedIds_, fmt.Sprint(v))
21315 }
21316 c.urlParams_.SetMulti("excludedIds", excludedIds_)
21317 return c
21318 }
21319
21320
21321
21322 func (c *CampaignsListCall) Ids(ids ...int64) *CampaignsListCall {
21323 var ids_ []string
21324 for _, v := range ids {
21325 ids_ = append(ids_, fmt.Sprint(v))
21326 }
21327 c.urlParams_.SetMulti("ids", ids_)
21328 return c
21329 }
21330
21331
21332
21333 func (c *CampaignsListCall) MaxResults(maxResults int64) *CampaignsListCall {
21334 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
21335 return c
21336 }
21337
21338
21339
21340
21341 func (c *CampaignsListCall) OverriddenEventTagId(overriddenEventTagId int64) *CampaignsListCall {
21342 c.urlParams_.Set("overriddenEventTagId", fmt.Sprint(overriddenEventTagId))
21343 return c
21344 }
21345
21346
21347
21348 func (c *CampaignsListCall) PageToken(pageToken string) *CampaignsListCall {
21349 c.urlParams_.Set("pageToken", pageToken)
21350 return c
21351 }
21352
21353
21354
21355
21356
21357
21358
21359
21360
21361 func (c *CampaignsListCall) SearchString(searchString string) *CampaignsListCall {
21362 c.urlParams_.Set("searchString", searchString)
21363 return c
21364 }
21365
21366
21367
21368
21369
21370
21371
21372
21373 func (c *CampaignsListCall) SortField(sortField string) *CampaignsListCall {
21374 c.urlParams_.Set("sortField", sortField)
21375 return c
21376 }
21377
21378
21379
21380
21381
21382
21383
21384
21385 func (c *CampaignsListCall) SortOrder(sortOrder string) *CampaignsListCall {
21386 c.urlParams_.Set("sortOrder", sortOrder)
21387 return c
21388 }
21389
21390
21391
21392 func (c *CampaignsListCall) SubaccountId(subaccountId int64) *CampaignsListCall {
21393 c.urlParams_.Set("subaccountId", fmt.Sprint(subaccountId))
21394 return c
21395 }
21396
21397
21398
21399
21400 func (c *CampaignsListCall) Fields(s ...googleapi.Field) *CampaignsListCall {
21401 c.urlParams_.Set("fields", googleapi.CombineFields(s))
21402 return c
21403 }
21404
21405
21406
21407
21408
21409
21410 func (c *CampaignsListCall) IfNoneMatch(entityTag string) *CampaignsListCall {
21411 c.ifNoneMatch_ = entityTag
21412 return c
21413 }
21414
21415
21416
21417
21418 func (c *CampaignsListCall) Context(ctx context.Context) *CampaignsListCall {
21419 c.ctx_ = ctx
21420 return c
21421 }
21422
21423
21424
21425 func (c *CampaignsListCall) Header() http.Header {
21426 if c.header_ == nil {
21427 c.header_ = make(http.Header)
21428 }
21429 return c.header_
21430 }
21431
21432 func (c *CampaignsListCall) doRequest(alt string) (*http.Response, error) {
21433 reqHeaders := make(http.Header)
21434 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
21435 for k, v := range c.header_ {
21436 reqHeaders[k] = v
21437 }
21438 reqHeaders.Set("User-Agent", c.s.userAgent())
21439 if c.ifNoneMatch_ != "" {
21440 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
21441 }
21442 var body io.Reader = nil
21443 c.urlParams_.Set("alt", alt)
21444 c.urlParams_.Set("prettyPrint", "false")
21445 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/campaigns")
21446 urls += "?" + c.urlParams_.Encode()
21447 req, err := http.NewRequest("GET", urls, body)
21448 if err != nil {
21449 return nil, err
21450 }
21451 req.Header = reqHeaders
21452 googleapi.Expand(req.URL, map[string]string{
21453 "profileId": strconv.FormatInt(c.profileId, 10),
21454 })
21455 return gensupport.SendRequest(c.ctx_, c.s.client, req)
21456 }
21457
21458
21459
21460
21461
21462
21463
21464
21465 func (c *CampaignsListCall) Do(opts ...googleapi.CallOption) (*CampaignsListResponse, error) {
21466 gensupport.SetOptions(c.urlParams_, opts...)
21467 res, err := c.doRequest("json")
21468 if res != nil && res.StatusCode == http.StatusNotModified {
21469 if res.Body != nil {
21470 res.Body.Close()
21471 }
21472 return nil, &googleapi.Error{
21473 Code: res.StatusCode,
21474 Header: res.Header,
21475 }
21476 }
21477 if err != nil {
21478 return nil, err
21479 }
21480 defer googleapi.CloseBody(res)
21481 if err := googleapi.CheckResponse(res); err != nil {
21482 return nil, err
21483 }
21484 ret := &CampaignsListResponse{
21485 ServerResponse: googleapi.ServerResponse{
21486 Header: res.Header,
21487 HTTPStatusCode: res.StatusCode,
21488 },
21489 }
21490 target := &ret
21491 if err := gensupport.DecodeResponse(target, res); err != nil {
21492 return nil, err
21493 }
21494 return ret, nil
21495
21496
21497
21498
21499
21500
21501
21502
21503
21504
21505
21506
21507
21508
21509
21510
21511
21512
21513
21514
21515
21516
21517
21518
21519
21520
21521
21522
21523
21524
21525
21526
21527
21528
21529
21530
21531
21532
21533
21534
21535
21536
21537
21538
21539
21540
21541
21542
21543
21544
21545
21546
21547
21548
21549
21550
21551
21552
21553
21554
21555
21556
21557
21558
21559
21560
21561
21562
21563
21564
21565
21566
21567
21568
21569
21570
21571
21572
21573
21574
21575
21576
21577
21578
21579
21580
21581
21582
21583
21584
21585
21586
21587
21588
21589
21590
21591
21592
21593
21594
21595
21596
21597
21598
21599
21600
21601
21602
21603
21604
21605
21606
21607
21608
21609
21610
21611
21612
21613
21614
21615
21616
21617 }
21618
21619
21620
21621
21622 func (c *CampaignsListCall) Pages(ctx context.Context, f func(*CampaignsListResponse) error) error {
21623 c.ctx_ = ctx
21624 defer c.PageToken(c.urlParams_.Get("pageToken"))
21625 for {
21626 x, err := c.Do()
21627 if err != nil {
21628 return err
21629 }
21630 if err := f(x); err != nil {
21631 return err
21632 }
21633 if x.NextPageToken == "" {
21634 return nil
21635 }
21636 c.PageToken(x.NextPageToken)
21637 }
21638 }
21639
21640
21641
21642 type CampaignsPatchCall struct {
21643 s *Service
21644 profileId int64
21645 campaign *Campaign
21646 urlParams_ gensupport.URLParams
21647 ctx_ context.Context
21648 header_ http.Header
21649 }
21650
21651
21652
21653 func (r *CampaignsService) Patch(profileId int64, id int64, campaign *Campaign) *CampaignsPatchCall {
21654 c := &CampaignsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
21655 c.profileId = profileId
21656 c.urlParams_.Set("id", fmt.Sprint(id))
21657 c.campaign = campaign
21658 return c
21659 }
21660
21661
21662
21663
21664 func (c *CampaignsPatchCall) Fields(s ...googleapi.Field) *CampaignsPatchCall {
21665 c.urlParams_.Set("fields", googleapi.CombineFields(s))
21666 return c
21667 }
21668
21669
21670
21671
21672 func (c *CampaignsPatchCall) Context(ctx context.Context) *CampaignsPatchCall {
21673 c.ctx_ = ctx
21674 return c
21675 }
21676
21677
21678
21679 func (c *CampaignsPatchCall) Header() http.Header {
21680 if c.header_ == nil {
21681 c.header_ = make(http.Header)
21682 }
21683 return c.header_
21684 }
21685
21686 func (c *CampaignsPatchCall) doRequest(alt string) (*http.Response, error) {
21687 reqHeaders := make(http.Header)
21688 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
21689 for k, v := range c.header_ {
21690 reqHeaders[k] = v
21691 }
21692 reqHeaders.Set("User-Agent", c.s.userAgent())
21693 var body io.Reader = nil
21694 body, err := googleapi.WithoutDataWrapper.JSONReader(c.campaign)
21695 if err != nil {
21696 return nil, err
21697 }
21698 reqHeaders.Set("Content-Type", "application/json")
21699 c.urlParams_.Set("alt", alt)
21700 c.urlParams_.Set("prettyPrint", "false")
21701 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/campaigns")
21702 urls += "?" + c.urlParams_.Encode()
21703 req, err := http.NewRequest("PATCH", urls, body)
21704 if err != nil {
21705 return nil, err
21706 }
21707 req.Header = reqHeaders
21708 googleapi.Expand(req.URL, map[string]string{
21709 "profileId": strconv.FormatInt(c.profileId, 10),
21710 })
21711 return gensupport.SendRequest(c.ctx_, c.s.client, req)
21712 }
21713
21714
21715
21716
21717
21718
21719
21720
21721 func (c *CampaignsPatchCall) Do(opts ...googleapi.CallOption) (*Campaign, error) {
21722 gensupport.SetOptions(c.urlParams_, opts...)
21723 res, err := c.doRequest("json")
21724 if res != nil && res.StatusCode == http.StatusNotModified {
21725 if res.Body != nil {
21726 res.Body.Close()
21727 }
21728 return nil, &googleapi.Error{
21729 Code: res.StatusCode,
21730 Header: res.Header,
21731 }
21732 }
21733 if err != nil {
21734 return nil, err
21735 }
21736 defer googleapi.CloseBody(res)
21737 if err := googleapi.CheckResponse(res); err != nil {
21738 return nil, err
21739 }
21740 ret := &Campaign{
21741 ServerResponse: googleapi.ServerResponse{
21742 Header: res.Header,
21743 HTTPStatusCode: res.StatusCode,
21744 },
21745 }
21746 target := &ret
21747 if err := gensupport.DecodeResponse(target, res); err != nil {
21748 return nil, err
21749 }
21750 return ret, nil
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 type CampaignsUpdateCall struct {
21792 s *Service
21793 profileId int64
21794 campaign *Campaign
21795 urlParams_ gensupport.URLParams
21796 ctx_ context.Context
21797 header_ http.Header
21798 }
21799
21800
21801 func (r *CampaignsService) Update(profileId int64, campaign *Campaign) *CampaignsUpdateCall {
21802 c := &CampaignsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
21803 c.profileId = profileId
21804 c.campaign = campaign
21805 return c
21806 }
21807
21808
21809
21810
21811 func (c *CampaignsUpdateCall) Fields(s ...googleapi.Field) *CampaignsUpdateCall {
21812 c.urlParams_.Set("fields", googleapi.CombineFields(s))
21813 return c
21814 }
21815
21816
21817
21818
21819 func (c *CampaignsUpdateCall) Context(ctx context.Context) *CampaignsUpdateCall {
21820 c.ctx_ = ctx
21821 return c
21822 }
21823
21824
21825
21826 func (c *CampaignsUpdateCall) Header() http.Header {
21827 if c.header_ == nil {
21828 c.header_ = make(http.Header)
21829 }
21830 return c.header_
21831 }
21832
21833 func (c *CampaignsUpdateCall) doRequest(alt string) (*http.Response, error) {
21834 reqHeaders := make(http.Header)
21835 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
21836 for k, v := range c.header_ {
21837 reqHeaders[k] = v
21838 }
21839 reqHeaders.Set("User-Agent", c.s.userAgent())
21840 var body io.Reader = nil
21841 body, err := googleapi.WithoutDataWrapper.JSONReader(c.campaign)
21842 if err != nil {
21843 return nil, err
21844 }
21845 reqHeaders.Set("Content-Type", "application/json")
21846 c.urlParams_.Set("alt", alt)
21847 c.urlParams_.Set("prettyPrint", "false")
21848 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/campaigns")
21849 urls += "?" + c.urlParams_.Encode()
21850 req, err := http.NewRequest("PUT", urls, body)
21851 if err != nil {
21852 return nil, err
21853 }
21854 req.Header = reqHeaders
21855 googleapi.Expand(req.URL, map[string]string{
21856 "profileId": strconv.FormatInt(c.profileId, 10),
21857 })
21858 return gensupport.SendRequest(c.ctx_, c.s.client, req)
21859 }
21860
21861
21862
21863
21864
21865
21866
21867
21868 func (c *CampaignsUpdateCall) Do(opts ...googleapi.CallOption) (*Campaign, error) {
21869 gensupport.SetOptions(c.urlParams_, opts...)
21870 res, err := c.doRequest("json")
21871 if res != nil && res.StatusCode == http.StatusNotModified {
21872 if res.Body != nil {
21873 res.Body.Close()
21874 }
21875 return nil, &googleapi.Error{
21876 Code: res.StatusCode,
21877 Header: res.Header,
21878 }
21879 }
21880 if err != nil {
21881 return nil, err
21882 }
21883 defer googleapi.CloseBody(res)
21884 if err := googleapi.CheckResponse(res); err != nil {
21885 return nil, err
21886 }
21887 ret := &Campaign{
21888 ServerResponse: googleapi.ServerResponse{
21889 Header: res.Header,
21890 HTTPStatusCode: res.StatusCode,
21891 },
21892 }
21893 target := &ret
21894 if err := gensupport.DecodeResponse(target, res); err != nil {
21895 return nil, err
21896 }
21897 return ret, nil
21898
21899
21900
21901
21902
21903
21904
21905
21906
21907
21908
21909
21910
21911
21912
21913
21914
21915
21916
21917
21918
21919
21920
21921
21922
21923
21924
21925
21926 }
21927
21928
21929
21930 type ChangeLogsGetCall struct {
21931 s *Service
21932 profileId int64
21933 id int64
21934 urlParams_ gensupport.URLParams
21935 ifNoneMatch_ string
21936 ctx_ context.Context
21937 header_ http.Header
21938 }
21939
21940
21941 func (r *ChangeLogsService) Get(profileId int64, id int64) *ChangeLogsGetCall {
21942 c := &ChangeLogsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
21943 c.profileId = profileId
21944 c.id = id
21945 return c
21946 }
21947
21948
21949
21950
21951 func (c *ChangeLogsGetCall) Fields(s ...googleapi.Field) *ChangeLogsGetCall {
21952 c.urlParams_.Set("fields", googleapi.CombineFields(s))
21953 return c
21954 }
21955
21956
21957
21958
21959
21960
21961 func (c *ChangeLogsGetCall) IfNoneMatch(entityTag string) *ChangeLogsGetCall {
21962 c.ifNoneMatch_ = entityTag
21963 return c
21964 }
21965
21966
21967
21968
21969 func (c *ChangeLogsGetCall) Context(ctx context.Context) *ChangeLogsGetCall {
21970 c.ctx_ = ctx
21971 return c
21972 }
21973
21974
21975
21976 func (c *ChangeLogsGetCall) Header() http.Header {
21977 if c.header_ == nil {
21978 c.header_ = make(http.Header)
21979 }
21980 return c.header_
21981 }
21982
21983 func (c *ChangeLogsGetCall) doRequest(alt string) (*http.Response, error) {
21984 reqHeaders := make(http.Header)
21985 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
21986 for k, v := range c.header_ {
21987 reqHeaders[k] = v
21988 }
21989 reqHeaders.Set("User-Agent", c.s.userAgent())
21990 if c.ifNoneMatch_ != "" {
21991 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
21992 }
21993 var body io.Reader = nil
21994 c.urlParams_.Set("alt", alt)
21995 c.urlParams_.Set("prettyPrint", "false")
21996 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/changeLogs/{id}")
21997 urls += "?" + c.urlParams_.Encode()
21998 req, err := http.NewRequest("GET", urls, body)
21999 if err != nil {
22000 return nil, err
22001 }
22002 req.Header = reqHeaders
22003 googleapi.Expand(req.URL, map[string]string{
22004 "profileId": strconv.FormatInt(c.profileId, 10),
22005 "id": strconv.FormatInt(c.id, 10),
22006 })
22007 return gensupport.SendRequest(c.ctx_, c.s.client, req)
22008 }
22009
22010
22011
22012
22013
22014
22015
22016
22017 func (c *ChangeLogsGetCall) Do(opts ...googleapi.CallOption) (*ChangeLog, error) {
22018 gensupport.SetOptions(c.urlParams_, opts...)
22019 res, err := c.doRequest("json")
22020 if res != nil && res.StatusCode == http.StatusNotModified {
22021 if res.Body != nil {
22022 res.Body.Close()
22023 }
22024 return nil, &googleapi.Error{
22025 Code: res.StatusCode,
22026 Header: res.Header,
22027 }
22028 }
22029 if err != nil {
22030 return nil, err
22031 }
22032 defer googleapi.CloseBody(res)
22033 if err := googleapi.CheckResponse(res); err != nil {
22034 return nil, err
22035 }
22036 ret := &ChangeLog{
22037 ServerResponse: googleapi.ServerResponse{
22038 Header: res.Header,
22039 HTTPStatusCode: res.StatusCode,
22040 },
22041 }
22042 target := &ret
22043 if err := gensupport.DecodeResponse(target, res); err != nil {
22044 return nil, err
22045 }
22046 return ret, nil
22047
22048
22049
22050
22051
22052
22053
22054
22055
22056
22057
22058
22059
22060
22061
22062
22063
22064
22065
22066
22067
22068
22069
22070
22071
22072
22073
22074
22075
22076
22077
22078
22079
22080 }
22081
22082
22083
22084 type ChangeLogsListCall struct {
22085 s *Service
22086 profileId int64
22087 urlParams_ gensupport.URLParams
22088 ifNoneMatch_ string
22089 ctx_ context.Context
22090 header_ http.Header
22091 }
22092
22093
22094 func (r *ChangeLogsService) List(profileId int64) *ChangeLogsListCall {
22095 c := &ChangeLogsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
22096 c.profileId = profileId
22097 return c
22098 }
22099
22100
22101
22102
22103
22104
22105
22106
22107
22108
22109
22110
22111
22112
22113
22114
22115
22116
22117
22118
22119
22120
22121
22122 func (c *ChangeLogsListCall) Action(action string) *ChangeLogsListCall {
22123 c.urlParams_.Set("action", action)
22124 return c
22125 }
22126
22127
22128
22129 func (c *ChangeLogsListCall) Ids(ids ...int64) *ChangeLogsListCall {
22130 var ids_ []string
22131 for _, v := range ids {
22132 ids_ = append(ids_, fmt.Sprint(v))
22133 }
22134 c.urlParams_.SetMulti("ids", ids_)
22135 return c
22136 }
22137
22138
22139
22140
22141
22142
22143
22144
22145
22146 func (c *ChangeLogsListCall) MaxChangeTime(maxChangeTime string) *ChangeLogsListCall {
22147 c.urlParams_.Set("maxChangeTime", maxChangeTime)
22148 return c
22149 }
22150
22151
22152
22153 func (c *ChangeLogsListCall) MaxResults(maxResults int64) *ChangeLogsListCall {
22154 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
22155 return c
22156 }
22157
22158
22159
22160
22161
22162
22163
22164
22165
22166 func (c *ChangeLogsListCall) MinChangeTime(minChangeTime string) *ChangeLogsListCall {
22167 c.urlParams_.Set("minChangeTime", minChangeTime)
22168 return c
22169 }
22170
22171
22172
22173 func (c *ChangeLogsListCall) ObjectIds(objectIds ...int64) *ChangeLogsListCall {
22174 var objectIds_ []string
22175 for _, v := range objectIds {
22176 objectIds_ = append(objectIds_, fmt.Sprint(v))
22177 }
22178 c.urlParams_.SetMulti("objectIds", objectIds_)
22179 return c
22180 }
22181
22182
22183
22184
22185
22186
22187
22188
22189
22190
22191
22192
22193
22194
22195
22196
22197
22198
22199
22200
22201
22202
22203
22204
22205
22206
22207
22208
22209
22210
22211
22212
22213
22214
22215
22216
22217
22218
22219
22220
22221
22222
22223
22224
22225
22226 func (c *ChangeLogsListCall) ObjectType(objectType string) *ChangeLogsListCall {
22227 c.urlParams_.Set("objectType", objectType)
22228 return c
22229 }
22230
22231
22232
22233 func (c *ChangeLogsListCall) PageToken(pageToken string) *ChangeLogsListCall {
22234 c.urlParams_.Set("pageToken", pageToken)
22235 return c
22236 }
22237
22238
22239
22240
22241 func (c *ChangeLogsListCall) SearchString(searchString string) *ChangeLogsListCall {
22242 c.urlParams_.Set("searchString", searchString)
22243 return c
22244 }
22245
22246
22247
22248 func (c *ChangeLogsListCall) UserProfileIds(userProfileIds ...int64) *ChangeLogsListCall {
22249 var userProfileIds_ []string
22250 for _, v := range userProfileIds {
22251 userProfileIds_ = append(userProfileIds_, fmt.Sprint(v))
22252 }
22253 c.urlParams_.SetMulti("userProfileIds", userProfileIds_)
22254 return c
22255 }
22256
22257
22258
22259
22260 func (c *ChangeLogsListCall) Fields(s ...googleapi.Field) *ChangeLogsListCall {
22261 c.urlParams_.Set("fields", googleapi.CombineFields(s))
22262 return c
22263 }
22264
22265
22266
22267
22268
22269
22270 func (c *ChangeLogsListCall) IfNoneMatch(entityTag string) *ChangeLogsListCall {
22271 c.ifNoneMatch_ = entityTag
22272 return c
22273 }
22274
22275
22276
22277
22278 func (c *ChangeLogsListCall) Context(ctx context.Context) *ChangeLogsListCall {
22279 c.ctx_ = ctx
22280 return c
22281 }
22282
22283
22284
22285 func (c *ChangeLogsListCall) Header() http.Header {
22286 if c.header_ == nil {
22287 c.header_ = make(http.Header)
22288 }
22289 return c.header_
22290 }
22291
22292 func (c *ChangeLogsListCall) doRequest(alt string) (*http.Response, error) {
22293 reqHeaders := make(http.Header)
22294 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
22295 for k, v := range c.header_ {
22296 reqHeaders[k] = v
22297 }
22298 reqHeaders.Set("User-Agent", c.s.userAgent())
22299 if c.ifNoneMatch_ != "" {
22300 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
22301 }
22302 var body io.Reader = nil
22303 c.urlParams_.Set("alt", alt)
22304 c.urlParams_.Set("prettyPrint", "false")
22305 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/changeLogs")
22306 urls += "?" + c.urlParams_.Encode()
22307 req, err := http.NewRequest("GET", urls, body)
22308 if err != nil {
22309 return nil, err
22310 }
22311 req.Header = reqHeaders
22312 googleapi.Expand(req.URL, map[string]string{
22313 "profileId": strconv.FormatInt(c.profileId, 10),
22314 })
22315 return gensupport.SendRequest(c.ctx_, c.s.client, req)
22316 }
22317
22318
22319
22320
22321
22322
22323
22324
22325 func (c *ChangeLogsListCall) Do(opts ...googleapi.CallOption) (*ChangeLogsListResponse, error) {
22326 gensupport.SetOptions(c.urlParams_, opts...)
22327 res, err := c.doRequest("json")
22328 if res != nil && res.StatusCode == http.StatusNotModified {
22329 if res.Body != nil {
22330 res.Body.Close()
22331 }
22332 return nil, &googleapi.Error{
22333 Code: res.StatusCode,
22334 Header: res.Header,
22335 }
22336 }
22337 if err != nil {
22338 return nil, err
22339 }
22340 defer googleapi.CloseBody(res)
22341 if err := googleapi.CheckResponse(res); err != nil {
22342 return nil, err
22343 }
22344 ret := &ChangeLogsListResponse{
22345 ServerResponse: googleapi.ServerResponse{
22346 Header: res.Header,
22347 HTTPStatusCode: res.StatusCode,
22348 },
22349 }
22350 target := &ret
22351 if err := gensupport.DecodeResponse(target, res); err != nil {
22352 return nil, err
22353 }
22354 return ret, nil
22355
22356
22357
22358
22359
22360
22361
22362
22363
22364
22365
22366
22367
22368
22369
22370
22371
22372
22373
22374
22375
22376
22377
22378
22379
22380
22381
22382
22383
22384
22385
22386
22387
22388
22389
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
22438
22439
22440
22441
22442
22443
22444
22445
22446
22447
22448
22449
22450
22451
22452
22453
22454
22455
22456
22457
22458
22459
22460
22461
22462
22463
22464
22465
22466
22467
22468
22469
22470
22471
22472
22473
22474
22475
22476
22477
22478
22479
22480
22481
22482
22483
22484
22485
22486
22487
22488
22489
22490
22491
22492
22493
22494
22495
22496
22497
22498
22499
22500
22501
22502
22503
22504
22505
22506
22507
22508
22509
22510
22511
22512
22513
22514
22515
22516
22517
22518
22519
22520
22521
22522
22523
22524
22525
22526
22527
22528
22529
22530
22531
22532
22533
22534
22535
22536
22537
22538
22539
22540
22541
22542
22543
22544
22545
22546
22547
22548
22549
22550
22551
22552
22553
22554
22555
22556
22557
22558
22559
22560 }
22561
22562
22563
22564
22565 func (c *ChangeLogsListCall) Pages(ctx context.Context, f func(*ChangeLogsListResponse) error) error {
22566 c.ctx_ = ctx
22567 defer c.PageToken(c.urlParams_.Get("pageToken"))
22568 for {
22569 x, err := c.Do()
22570 if err != nil {
22571 return err
22572 }
22573 if err := f(x); err != nil {
22574 return err
22575 }
22576 if x.NextPageToken == "" {
22577 return nil
22578 }
22579 c.PageToken(x.NextPageToken)
22580 }
22581 }
22582
22583
22584
22585 type CitiesListCall struct {
22586 s *Service
22587 profileId int64
22588 urlParams_ gensupport.URLParams
22589 ifNoneMatch_ string
22590 ctx_ context.Context
22591 header_ http.Header
22592 }
22593
22594
22595 func (r *CitiesService) List(profileId int64) *CitiesListCall {
22596 c := &CitiesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
22597 c.profileId = profileId
22598 return c
22599 }
22600
22601
22602
22603 func (c *CitiesListCall) CountryDartIds(countryDartIds ...int64) *CitiesListCall {
22604 var countryDartIds_ []string
22605 for _, v := range countryDartIds {
22606 countryDartIds_ = append(countryDartIds_, fmt.Sprint(v))
22607 }
22608 c.urlParams_.SetMulti("countryDartIds", countryDartIds_)
22609 return c
22610 }
22611
22612
22613
22614 func (c *CitiesListCall) DartIds(dartIds ...int64) *CitiesListCall {
22615 var dartIds_ []string
22616 for _, v := range dartIds {
22617 dartIds_ = append(dartIds_, fmt.Sprint(v))
22618 }
22619 c.urlParams_.SetMulti("dartIds", dartIds_)
22620 return c
22621 }
22622
22623
22624
22625 func (c *CitiesListCall) NamePrefix(namePrefix string) *CitiesListCall {
22626 c.urlParams_.Set("namePrefix", namePrefix)
22627 return c
22628 }
22629
22630
22631
22632 func (c *CitiesListCall) RegionDartIds(regionDartIds ...int64) *CitiesListCall {
22633 var regionDartIds_ []string
22634 for _, v := range regionDartIds {
22635 regionDartIds_ = append(regionDartIds_, fmt.Sprint(v))
22636 }
22637 c.urlParams_.SetMulti("regionDartIds", regionDartIds_)
22638 return c
22639 }
22640
22641
22642
22643
22644 func (c *CitiesListCall) Fields(s ...googleapi.Field) *CitiesListCall {
22645 c.urlParams_.Set("fields", googleapi.CombineFields(s))
22646 return c
22647 }
22648
22649
22650
22651
22652
22653
22654 func (c *CitiesListCall) IfNoneMatch(entityTag string) *CitiesListCall {
22655 c.ifNoneMatch_ = entityTag
22656 return c
22657 }
22658
22659
22660
22661
22662 func (c *CitiesListCall) Context(ctx context.Context) *CitiesListCall {
22663 c.ctx_ = ctx
22664 return c
22665 }
22666
22667
22668
22669 func (c *CitiesListCall) Header() http.Header {
22670 if c.header_ == nil {
22671 c.header_ = make(http.Header)
22672 }
22673 return c.header_
22674 }
22675
22676 func (c *CitiesListCall) doRequest(alt string) (*http.Response, error) {
22677 reqHeaders := make(http.Header)
22678 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
22679 for k, v := range c.header_ {
22680 reqHeaders[k] = v
22681 }
22682 reqHeaders.Set("User-Agent", c.s.userAgent())
22683 if c.ifNoneMatch_ != "" {
22684 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
22685 }
22686 var body io.Reader = nil
22687 c.urlParams_.Set("alt", alt)
22688 c.urlParams_.Set("prettyPrint", "false")
22689 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/cities")
22690 urls += "?" + c.urlParams_.Encode()
22691 req, err := http.NewRequest("GET", urls, body)
22692 if err != nil {
22693 return nil, err
22694 }
22695 req.Header = reqHeaders
22696 googleapi.Expand(req.URL, map[string]string{
22697 "profileId": strconv.FormatInt(c.profileId, 10),
22698 })
22699 return gensupport.SendRequest(c.ctx_, c.s.client, req)
22700 }
22701
22702
22703
22704
22705
22706
22707
22708
22709 func (c *CitiesListCall) Do(opts ...googleapi.CallOption) (*CitiesListResponse, error) {
22710 gensupport.SetOptions(c.urlParams_, opts...)
22711 res, err := c.doRequest("json")
22712 if res != nil && res.StatusCode == http.StatusNotModified {
22713 if res.Body != nil {
22714 res.Body.Close()
22715 }
22716 return nil, &googleapi.Error{
22717 Code: res.StatusCode,
22718 Header: res.Header,
22719 }
22720 }
22721 if err != nil {
22722 return nil, err
22723 }
22724 defer googleapi.CloseBody(res)
22725 if err := googleapi.CheckResponse(res); err != nil {
22726 return nil, err
22727 }
22728 ret := &CitiesListResponse{
22729 ServerResponse: googleapi.ServerResponse{
22730 Header: res.Header,
22731 HTTPStatusCode: res.StatusCode,
22732 },
22733 }
22734 target := &ret
22735 if err := gensupport.DecodeResponse(target, res); err != nil {
22736 return nil, err
22737 }
22738 return ret, nil
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
22779
22780
22781
22782
22783
22784
22785
22786
22787
22788
22789
22790 }
22791
22792
22793
22794 type ConnectionTypesGetCall struct {
22795 s *Service
22796 profileId int64
22797 id int64
22798 urlParams_ gensupport.URLParams
22799 ifNoneMatch_ string
22800 ctx_ context.Context
22801 header_ http.Header
22802 }
22803
22804
22805 func (r *ConnectionTypesService) Get(profileId int64, id int64) *ConnectionTypesGetCall {
22806 c := &ConnectionTypesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
22807 c.profileId = profileId
22808 c.id = id
22809 return c
22810 }
22811
22812
22813
22814
22815 func (c *ConnectionTypesGetCall) Fields(s ...googleapi.Field) *ConnectionTypesGetCall {
22816 c.urlParams_.Set("fields", googleapi.CombineFields(s))
22817 return c
22818 }
22819
22820
22821
22822
22823
22824
22825 func (c *ConnectionTypesGetCall) IfNoneMatch(entityTag string) *ConnectionTypesGetCall {
22826 c.ifNoneMatch_ = entityTag
22827 return c
22828 }
22829
22830
22831
22832
22833 func (c *ConnectionTypesGetCall) Context(ctx context.Context) *ConnectionTypesGetCall {
22834 c.ctx_ = ctx
22835 return c
22836 }
22837
22838
22839
22840 func (c *ConnectionTypesGetCall) Header() http.Header {
22841 if c.header_ == nil {
22842 c.header_ = make(http.Header)
22843 }
22844 return c.header_
22845 }
22846
22847 func (c *ConnectionTypesGetCall) doRequest(alt string) (*http.Response, error) {
22848 reqHeaders := make(http.Header)
22849 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
22850 for k, v := range c.header_ {
22851 reqHeaders[k] = v
22852 }
22853 reqHeaders.Set("User-Agent", c.s.userAgent())
22854 if c.ifNoneMatch_ != "" {
22855 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
22856 }
22857 var body io.Reader = nil
22858 c.urlParams_.Set("alt", alt)
22859 c.urlParams_.Set("prettyPrint", "false")
22860 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/connectionTypes/{id}")
22861 urls += "?" + c.urlParams_.Encode()
22862 req, err := http.NewRequest("GET", urls, body)
22863 if err != nil {
22864 return nil, err
22865 }
22866 req.Header = reqHeaders
22867 googleapi.Expand(req.URL, map[string]string{
22868 "profileId": strconv.FormatInt(c.profileId, 10),
22869 "id": strconv.FormatInt(c.id, 10),
22870 })
22871 return gensupport.SendRequest(c.ctx_, c.s.client, req)
22872 }
22873
22874
22875
22876
22877
22878
22879
22880
22881 func (c *ConnectionTypesGetCall) Do(opts ...googleapi.CallOption) (*ConnectionType, error) {
22882 gensupport.SetOptions(c.urlParams_, opts...)
22883 res, err := c.doRequest("json")
22884 if res != nil && res.StatusCode == http.StatusNotModified {
22885 if res.Body != nil {
22886 res.Body.Close()
22887 }
22888 return nil, &googleapi.Error{
22889 Code: res.StatusCode,
22890 Header: res.Header,
22891 }
22892 }
22893 if err != nil {
22894 return nil, err
22895 }
22896 defer googleapi.CloseBody(res)
22897 if err := googleapi.CheckResponse(res); err != nil {
22898 return nil, err
22899 }
22900 ret := &ConnectionType{
22901 ServerResponse: googleapi.ServerResponse{
22902 Header: res.Header,
22903 HTTPStatusCode: res.StatusCode,
22904 },
22905 }
22906 target := &ret
22907 if err := gensupport.DecodeResponse(target, res); err != nil {
22908 return nil, err
22909 }
22910 return ret, nil
22911
22912
22913
22914
22915
22916
22917
22918
22919
22920
22921
22922
22923
22924
22925
22926
22927
22928
22929
22930
22931
22932
22933
22934
22935
22936
22937
22938
22939
22940
22941
22942
22943
22944 }
22945
22946
22947
22948 type ConnectionTypesListCall struct {
22949 s *Service
22950 profileId int64
22951 urlParams_ gensupport.URLParams
22952 ifNoneMatch_ string
22953 ctx_ context.Context
22954 header_ http.Header
22955 }
22956
22957
22958 func (r *ConnectionTypesService) List(profileId int64) *ConnectionTypesListCall {
22959 c := &ConnectionTypesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
22960 c.profileId = profileId
22961 return c
22962 }
22963
22964
22965
22966
22967 func (c *ConnectionTypesListCall) Fields(s ...googleapi.Field) *ConnectionTypesListCall {
22968 c.urlParams_.Set("fields", googleapi.CombineFields(s))
22969 return c
22970 }
22971
22972
22973
22974
22975
22976
22977 func (c *ConnectionTypesListCall) IfNoneMatch(entityTag string) *ConnectionTypesListCall {
22978 c.ifNoneMatch_ = entityTag
22979 return c
22980 }
22981
22982
22983
22984
22985 func (c *ConnectionTypesListCall) Context(ctx context.Context) *ConnectionTypesListCall {
22986 c.ctx_ = ctx
22987 return c
22988 }
22989
22990
22991
22992 func (c *ConnectionTypesListCall) Header() http.Header {
22993 if c.header_ == nil {
22994 c.header_ = make(http.Header)
22995 }
22996 return c.header_
22997 }
22998
22999 func (c *ConnectionTypesListCall) doRequest(alt string) (*http.Response, error) {
23000 reqHeaders := make(http.Header)
23001 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
23002 for k, v := range c.header_ {
23003 reqHeaders[k] = v
23004 }
23005 reqHeaders.Set("User-Agent", c.s.userAgent())
23006 if c.ifNoneMatch_ != "" {
23007 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
23008 }
23009 var body io.Reader = nil
23010 c.urlParams_.Set("alt", alt)
23011 c.urlParams_.Set("prettyPrint", "false")
23012 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/connectionTypes")
23013 urls += "?" + c.urlParams_.Encode()
23014 req, err := http.NewRequest("GET", urls, body)
23015 if err != nil {
23016 return nil, err
23017 }
23018 req.Header = reqHeaders
23019 googleapi.Expand(req.URL, map[string]string{
23020 "profileId": strconv.FormatInt(c.profileId, 10),
23021 })
23022 return gensupport.SendRequest(c.ctx_, c.s.client, req)
23023 }
23024
23025
23026
23027
23028
23029
23030
23031
23032 func (c *ConnectionTypesListCall) Do(opts ...googleapi.CallOption) (*ConnectionTypesListResponse, error) {
23033 gensupport.SetOptions(c.urlParams_, opts...)
23034 res, err := c.doRequest("json")
23035 if res != nil && res.StatusCode == http.StatusNotModified {
23036 if res.Body != nil {
23037 res.Body.Close()
23038 }
23039 return nil, &googleapi.Error{
23040 Code: res.StatusCode,
23041 Header: res.Header,
23042 }
23043 }
23044 if err != nil {
23045 return nil, err
23046 }
23047 defer googleapi.CloseBody(res)
23048 if err := googleapi.CheckResponse(res); err != nil {
23049 return nil, err
23050 }
23051 ret := &ConnectionTypesListResponse{
23052 ServerResponse: googleapi.ServerResponse{
23053 Header: res.Header,
23054 HTTPStatusCode: res.StatusCode,
23055 },
23056 }
23057 target := &ret
23058 if err := gensupport.DecodeResponse(target, res); err != nil {
23059 return nil, err
23060 }
23061 return ret, nil
23062
23063
23064
23065
23066
23067
23068
23069
23070
23071
23072
23073
23074
23075
23076
23077
23078
23079
23080
23081
23082
23083
23084
23085
23086
23087 }
23088
23089
23090
23091 type ContentCategoriesDeleteCall struct {
23092 s *Service
23093 profileId int64
23094 id int64
23095 urlParams_ gensupport.URLParams
23096 ctx_ context.Context
23097 header_ http.Header
23098 }
23099
23100
23101 func (r *ContentCategoriesService) Delete(profileId int64, id int64) *ContentCategoriesDeleteCall {
23102 c := &ContentCategoriesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
23103 c.profileId = profileId
23104 c.id = id
23105 return c
23106 }
23107
23108
23109
23110
23111 func (c *ContentCategoriesDeleteCall) Fields(s ...googleapi.Field) *ContentCategoriesDeleteCall {
23112 c.urlParams_.Set("fields", googleapi.CombineFields(s))
23113 return c
23114 }
23115
23116
23117
23118
23119 func (c *ContentCategoriesDeleteCall) Context(ctx context.Context) *ContentCategoriesDeleteCall {
23120 c.ctx_ = ctx
23121 return c
23122 }
23123
23124
23125
23126 func (c *ContentCategoriesDeleteCall) Header() http.Header {
23127 if c.header_ == nil {
23128 c.header_ = make(http.Header)
23129 }
23130 return c.header_
23131 }
23132
23133 func (c *ContentCategoriesDeleteCall) doRequest(alt string) (*http.Response, error) {
23134 reqHeaders := make(http.Header)
23135 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
23136 for k, v := range c.header_ {
23137 reqHeaders[k] = v
23138 }
23139 reqHeaders.Set("User-Agent", c.s.userAgent())
23140 var body io.Reader = nil
23141 c.urlParams_.Set("alt", alt)
23142 c.urlParams_.Set("prettyPrint", "false")
23143 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/contentCategories/{id}")
23144 urls += "?" + c.urlParams_.Encode()
23145 req, err := http.NewRequest("DELETE", urls, body)
23146 if err != nil {
23147 return nil, err
23148 }
23149 req.Header = reqHeaders
23150 googleapi.Expand(req.URL, map[string]string{
23151 "profileId": strconv.FormatInt(c.profileId, 10),
23152 "id": strconv.FormatInt(c.id, 10),
23153 })
23154 return gensupport.SendRequest(c.ctx_, c.s.client, req)
23155 }
23156
23157
23158 func (c *ContentCategoriesDeleteCall) Do(opts ...googleapi.CallOption) error {
23159 gensupport.SetOptions(c.urlParams_, opts...)
23160 res, err := c.doRequest("json")
23161 if err != nil {
23162 return err
23163 }
23164 defer googleapi.CloseBody(res)
23165 if err := googleapi.CheckResponse(res); err != nil {
23166 return err
23167 }
23168 return nil
23169
23170
23171
23172
23173
23174
23175
23176
23177
23178
23179
23180
23181
23182
23183
23184
23185
23186
23187
23188
23189
23190
23191
23192
23193
23194
23195
23196
23197
23198
23199 }
23200
23201
23202
23203 type ContentCategoriesGetCall struct {
23204 s *Service
23205 profileId int64
23206 id int64
23207 urlParams_ gensupport.URLParams
23208 ifNoneMatch_ string
23209 ctx_ context.Context
23210 header_ http.Header
23211 }
23212
23213
23214 func (r *ContentCategoriesService) Get(profileId int64, id int64) *ContentCategoriesGetCall {
23215 c := &ContentCategoriesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
23216 c.profileId = profileId
23217 c.id = id
23218 return c
23219 }
23220
23221
23222
23223
23224 func (c *ContentCategoriesGetCall) Fields(s ...googleapi.Field) *ContentCategoriesGetCall {
23225 c.urlParams_.Set("fields", googleapi.CombineFields(s))
23226 return c
23227 }
23228
23229
23230
23231
23232
23233
23234 func (c *ContentCategoriesGetCall) IfNoneMatch(entityTag string) *ContentCategoriesGetCall {
23235 c.ifNoneMatch_ = entityTag
23236 return c
23237 }
23238
23239
23240
23241
23242 func (c *ContentCategoriesGetCall) Context(ctx context.Context) *ContentCategoriesGetCall {
23243 c.ctx_ = ctx
23244 return c
23245 }
23246
23247
23248
23249 func (c *ContentCategoriesGetCall) Header() http.Header {
23250 if c.header_ == nil {
23251 c.header_ = make(http.Header)
23252 }
23253 return c.header_
23254 }
23255
23256 func (c *ContentCategoriesGetCall) doRequest(alt string) (*http.Response, error) {
23257 reqHeaders := make(http.Header)
23258 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
23259 for k, v := range c.header_ {
23260 reqHeaders[k] = v
23261 }
23262 reqHeaders.Set("User-Agent", c.s.userAgent())
23263 if c.ifNoneMatch_ != "" {
23264 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
23265 }
23266 var body io.Reader = nil
23267 c.urlParams_.Set("alt", alt)
23268 c.urlParams_.Set("prettyPrint", "false")
23269 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/contentCategories/{id}")
23270 urls += "?" + c.urlParams_.Encode()
23271 req, err := http.NewRequest("GET", urls, body)
23272 if err != nil {
23273 return nil, err
23274 }
23275 req.Header = reqHeaders
23276 googleapi.Expand(req.URL, map[string]string{
23277 "profileId": strconv.FormatInt(c.profileId, 10),
23278 "id": strconv.FormatInt(c.id, 10),
23279 })
23280 return gensupport.SendRequest(c.ctx_, c.s.client, req)
23281 }
23282
23283
23284
23285
23286
23287
23288
23289
23290 func (c *ContentCategoriesGetCall) Do(opts ...googleapi.CallOption) (*ContentCategory, error) {
23291 gensupport.SetOptions(c.urlParams_, opts...)
23292 res, err := c.doRequest("json")
23293 if res != nil && res.StatusCode == http.StatusNotModified {
23294 if res.Body != nil {
23295 res.Body.Close()
23296 }
23297 return nil, &googleapi.Error{
23298 Code: res.StatusCode,
23299 Header: res.Header,
23300 }
23301 }
23302 if err != nil {
23303 return nil, err
23304 }
23305 defer googleapi.CloseBody(res)
23306 if err := googleapi.CheckResponse(res); err != nil {
23307 return nil, err
23308 }
23309 ret := &ContentCategory{
23310 ServerResponse: googleapi.ServerResponse{
23311 Header: res.Header,
23312 HTTPStatusCode: res.StatusCode,
23313 },
23314 }
23315 target := &ret
23316 if err := gensupport.DecodeResponse(target, res); err != nil {
23317 return nil, err
23318 }
23319 return ret, nil
23320
23321
23322
23323
23324
23325
23326
23327
23328
23329
23330
23331
23332
23333
23334
23335
23336
23337
23338
23339
23340
23341
23342
23343
23344
23345
23346
23347
23348
23349
23350
23351
23352
23353 }
23354
23355
23356
23357 type ContentCategoriesInsertCall struct {
23358 s *Service
23359 profileId int64
23360 contentcategory *ContentCategory
23361 urlParams_ gensupport.URLParams
23362 ctx_ context.Context
23363 header_ http.Header
23364 }
23365
23366
23367 func (r *ContentCategoriesService) Insert(profileId int64, contentcategory *ContentCategory) *ContentCategoriesInsertCall {
23368 c := &ContentCategoriesInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
23369 c.profileId = profileId
23370 c.contentcategory = contentcategory
23371 return c
23372 }
23373
23374
23375
23376
23377 func (c *ContentCategoriesInsertCall) Fields(s ...googleapi.Field) *ContentCategoriesInsertCall {
23378 c.urlParams_.Set("fields", googleapi.CombineFields(s))
23379 return c
23380 }
23381
23382
23383
23384
23385 func (c *ContentCategoriesInsertCall) Context(ctx context.Context) *ContentCategoriesInsertCall {
23386 c.ctx_ = ctx
23387 return c
23388 }
23389
23390
23391
23392 func (c *ContentCategoriesInsertCall) Header() http.Header {
23393 if c.header_ == nil {
23394 c.header_ = make(http.Header)
23395 }
23396 return c.header_
23397 }
23398
23399 func (c *ContentCategoriesInsertCall) doRequest(alt string) (*http.Response, error) {
23400 reqHeaders := make(http.Header)
23401 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
23402 for k, v := range c.header_ {
23403 reqHeaders[k] = v
23404 }
23405 reqHeaders.Set("User-Agent", c.s.userAgent())
23406 var body io.Reader = nil
23407 body, err := googleapi.WithoutDataWrapper.JSONReader(c.contentcategory)
23408 if err != nil {
23409 return nil, err
23410 }
23411 reqHeaders.Set("Content-Type", "application/json")
23412 c.urlParams_.Set("alt", alt)
23413 c.urlParams_.Set("prettyPrint", "false")
23414 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/contentCategories")
23415 urls += "?" + c.urlParams_.Encode()
23416 req, err := http.NewRequest("POST", urls, body)
23417 if err != nil {
23418 return nil, err
23419 }
23420 req.Header = reqHeaders
23421 googleapi.Expand(req.URL, map[string]string{
23422 "profileId": strconv.FormatInt(c.profileId, 10),
23423 })
23424 return gensupport.SendRequest(c.ctx_, c.s.client, req)
23425 }
23426
23427
23428
23429
23430
23431
23432
23433
23434 func (c *ContentCategoriesInsertCall) Do(opts ...googleapi.CallOption) (*ContentCategory, error) {
23435 gensupport.SetOptions(c.urlParams_, opts...)
23436 res, err := c.doRequest("json")
23437 if res != nil && res.StatusCode == http.StatusNotModified {
23438 if res.Body != nil {
23439 res.Body.Close()
23440 }
23441 return nil, &googleapi.Error{
23442 Code: res.StatusCode,
23443 Header: res.Header,
23444 }
23445 }
23446 if err != nil {
23447 return nil, err
23448 }
23449 defer googleapi.CloseBody(res)
23450 if err := googleapi.CheckResponse(res); err != nil {
23451 return nil, err
23452 }
23453 ret := &ContentCategory{
23454 ServerResponse: googleapi.ServerResponse{
23455 Header: res.Header,
23456 HTTPStatusCode: res.StatusCode,
23457 },
23458 }
23459 target := &ret
23460 if err := gensupport.DecodeResponse(target, res); err != nil {
23461 return nil, err
23462 }
23463 return ret, nil
23464
23465
23466
23467
23468
23469
23470
23471
23472
23473
23474
23475
23476
23477
23478
23479
23480
23481
23482
23483
23484
23485
23486
23487
23488
23489
23490
23491
23492 }
23493
23494
23495
23496 type ContentCategoriesListCall struct {
23497 s *Service
23498 profileId int64
23499 urlParams_ gensupport.URLParams
23500 ifNoneMatch_ string
23501 ctx_ context.Context
23502 header_ http.Header
23503 }
23504
23505
23506
23507 func (r *ContentCategoriesService) List(profileId int64) *ContentCategoriesListCall {
23508 c := &ContentCategoriesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
23509 c.profileId = profileId
23510 return c
23511 }
23512
23513
23514
23515 func (c *ContentCategoriesListCall) Ids(ids ...int64) *ContentCategoriesListCall {
23516 var ids_ []string
23517 for _, v := range ids {
23518 ids_ = append(ids_, fmt.Sprint(v))
23519 }
23520 c.urlParams_.SetMulti("ids", ids_)
23521 return c
23522 }
23523
23524
23525
23526 func (c *ContentCategoriesListCall) MaxResults(maxResults int64) *ContentCategoriesListCall {
23527 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
23528 return c
23529 }
23530
23531
23532
23533 func (c *ContentCategoriesListCall) PageToken(pageToken string) *ContentCategoriesListCall {
23534 c.urlParams_.Set("pageToken", pageToken)
23535 return c
23536 }
23537
23538
23539
23540
23541
23542
23543
23544
23545
23546
23547 func (c *ContentCategoriesListCall) SearchString(searchString string) *ContentCategoriesListCall {
23548 c.urlParams_.Set("searchString", searchString)
23549 return c
23550 }
23551
23552
23553
23554
23555
23556
23557
23558
23559 func (c *ContentCategoriesListCall) SortField(sortField string) *ContentCategoriesListCall {
23560 c.urlParams_.Set("sortField", sortField)
23561 return c
23562 }
23563
23564
23565
23566
23567
23568
23569
23570
23571 func (c *ContentCategoriesListCall) SortOrder(sortOrder string) *ContentCategoriesListCall {
23572 c.urlParams_.Set("sortOrder", sortOrder)
23573 return c
23574 }
23575
23576
23577
23578
23579 func (c *ContentCategoriesListCall) Fields(s ...googleapi.Field) *ContentCategoriesListCall {
23580 c.urlParams_.Set("fields", googleapi.CombineFields(s))
23581 return c
23582 }
23583
23584
23585
23586
23587
23588
23589 func (c *ContentCategoriesListCall) IfNoneMatch(entityTag string) *ContentCategoriesListCall {
23590 c.ifNoneMatch_ = entityTag
23591 return c
23592 }
23593
23594
23595
23596
23597 func (c *ContentCategoriesListCall) Context(ctx context.Context) *ContentCategoriesListCall {
23598 c.ctx_ = ctx
23599 return c
23600 }
23601
23602
23603
23604 func (c *ContentCategoriesListCall) Header() http.Header {
23605 if c.header_ == nil {
23606 c.header_ = make(http.Header)
23607 }
23608 return c.header_
23609 }
23610
23611 func (c *ContentCategoriesListCall) doRequest(alt string) (*http.Response, error) {
23612 reqHeaders := make(http.Header)
23613 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
23614 for k, v := range c.header_ {
23615 reqHeaders[k] = v
23616 }
23617 reqHeaders.Set("User-Agent", c.s.userAgent())
23618 if c.ifNoneMatch_ != "" {
23619 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
23620 }
23621 var body io.Reader = nil
23622 c.urlParams_.Set("alt", alt)
23623 c.urlParams_.Set("prettyPrint", "false")
23624 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/contentCategories")
23625 urls += "?" + c.urlParams_.Encode()
23626 req, err := http.NewRequest("GET", urls, body)
23627 if err != nil {
23628 return nil, err
23629 }
23630 req.Header = reqHeaders
23631 googleapi.Expand(req.URL, map[string]string{
23632 "profileId": strconv.FormatInt(c.profileId, 10),
23633 })
23634 return gensupport.SendRequest(c.ctx_, c.s.client, req)
23635 }
23636
23637
23638
23639
23640
23641
23642
23643
23644 func (c *ContentCategoriesListCall) Do(opts ...googleapi.CallOption) (*ContentCategoriesListResponse, error) {
23645 gensupport.SetOptions(c.urlParams_, opts...)
23646 res, err := c.doRequest("json")
23647 if res != nil && res.StatusCode == http.StatusNotModified {
23648 if res.Body != nil {
23649 res.Body.Close()
23650 }
23651 return nil, &googleapi.Error{
23652 Code: res.StatusCode,
23653 Header: res.Header,
23654 }
23655 }
23656 if err != nil {
23657 return nil, err
23658 }
23659 defer googleapi.CloseBody(res)
23660 if err := googleapi.CheckResponse(res); err != nil {
23661 return nil, err
23662 }
23663 ret := &ContentCategoriesListResponse{
23664 ServerResponse: googleapi.ServerResponse{
23665 Header: res.Header,
23666 HTTPStatusCode: res.StatusCode,
23667 },
23668 }
23669 target := &ret
23670 if err := gensupport.DecodeResponse(target, res); err != nil {
23671 return nil, err
23672 }
23673 return ret, nil
23674
23675
23676
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
23710
23711
23712
23713
23714
23715
23716
23717
23718
23719
23720
23721
23722
23723
23724
23725
23726
23727
23728
23729
23730
23731
23732
23733
23734
23735
23736
23737
23738
23739
23740
23741
23742
23743
23744
23745
23746
23747
23748
23749
23750
23751
23752
23753 }
23754
23755
23756
23757
23758 func (c *ContentCategoriesListCall) Pages(ctx context.Context, f func(*ContentCategoriesListResponse) error) error {
23759 c.ctx_ = ctx
23760 defer c.PageToken(c.urlParams_.Get("pageToken"))
23761 for {
23762 x, err := c.Do()
23763 if err != nil {
23764 return err
23765 }
23766 if err := f(x); err != nil {
23767 return err
23768 }
23769 if x.NextPageToken == "" {
23770 return nil
23771 }
23772 c.PageToken(x.NextPageToken)
23773 }
23774 }
23775
23776
23777
23778 type ContentCategoriesPatchCall struct {
23779 s *Service
23780 profileId int64
23781 contentcategory *ContentCategory
23782 urlParams_ gensupport.URLParams
23783 ctx_ context.Context
23784 header_ http.Header
23785 }
23786
23787
23788
23789 func (r *ContentCategoriesService) Patch(profileId int64, id int64, contentcategory *ContentCategory) *ContentCategoriesPatchCall {
23790 c := &ContentCategoriesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
23791 c.profileId = profileId
23792 c.urlParams_.Set("id", fmt.Sprint(id))
23793 c.contentcategory = contentcategory
23794 return c
23795 }
23796
23797
23798
23799
23800 func (c *ContentCategoriesPatchCall) Fields(s ...googleapi.Field) *ContentCategoriesPatchCall {
23801 c.urlParams_.Set("fields", googleapi.CombineFields(s))
23802 return c
23803 }
23804
23805
23806
23807
23808 func (c *ContentCategoriesPatchCall) Context(ctx context.Context) *ContentCategoriesPatchCall {
23809 c.ctx_ = ctx
23810 return c
23811 }
23812
23813
23814
23815 func (c *ContentCategoriesPatchCall) Header() http.Header {
23816 if c.header_ == nil {
23817 c.header_ = make(http.Header)
23818 }
23819 return c.header_
23820 }
23821
23822 func (c *ContentCategoriesPatchCall) doRequest(alt string) (*http.Response, error) {
23823 reqHeaders := make(http.Header)
23824 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
23825 for k, v := range c.header_ {
23826 reqHeaders[k] = v
23827 }
23828 reqHeaders.Set("User-Agent", c.s.userAgent())
23829 var body io.Reader = nil
23830 body, err := googleapi.WithoutDataWrapper.JSONReader(c.contentcategory)
23831 if err != nil {
23832 return nil, err
23833 }
23834 reqHeaders.Set("Content-Type", "application/json")
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("PATCH", 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 *ContentCategoriesPatchCall) Do(opts ...googleapi.CallOption) (*ContentCategory, 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 := &ContentCategory{
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 type ContentCategoriesUpdateCall struct {
23928 s *Service
23929 profileId int64
23930 contentcategory *ContentCategory
23931 urlParams_ gensupport.URLParams
23932 ctx_ context.Context
23933 header_ http.Header
23934 }
23935
23936
23937 func (r *ContentCategoriesService) Update(profileId int64, contentcategory *ContentCategory) *ContentCategoriesUpdateCall {
23938 c := &ContentCategoriesUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
23939 c.profileId = profileId
23940 c.contentcategory = contentcategory
23941 return c
23942 }
23943
23944
23945
23946
23947 func (c *ContentCategoriesUpdateCall) Fields(s ...googleapi.Field) *ContentCategoriesUpdateCall {
23948 c.urlParams_.Set("fields", googleapi.CombineFields(s))
23949 return c
23950 }
23951
23952
23953
23954
23955 func (c *ContentCategoriesUpdateCall) Context(ctx context.Context) *ContentCategoriesUpdateCall {
23956 c.ctx_ = ctx
23957 return c
23958 }
23959
23960
23961
23962 func (c *ContentCategoriesUpdateCall) Header() http.Header {
23963 if c.header_ == nil {
23964 c.header_ = make(http.Header)
23965 }
23966 return c.header_
23967 }
23968
23969 func (c *ContentCategoriesUpdateCall) doRequest(alt string) (*http.Response, error) {
23970 reqHeaders := make(http.Header)
23971 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
23972 for k, v := range c.header_ {
23973 reqHeaders[k] = v
23974 }
23975 reqHeaders.Set("User-Agent", c.s.userAgent())
23976 var body io.Reader = nil
23977 body, err := googleapi.WithoutDataWrapper.JSONReader(c.contentcategory)
23978 if err != nil {
23979 return nil, err
23980 }
23981 reqHeaders.Set("Content-Type", "application/json")
23982 c.urlParams_.Set("alt", alt)
23983 c.urlParams_.Set("prettyPrint", "false")
23984 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/contentCategories")
23985 urls += "?" + c.urlParams_.Encode()
23986 req, err := http.NewRequest("PUT", urls, body)
23987 if err != nil {
23988 return nil, err
23989 }
23990 req.Header = reqHeaders
23991 googleapi.Expand(req.URL, map[string]string{
23992 "profileId": strconv.FormatInt(c.profileId, 10),
23993 })
23994 return gensupport.SendRequest(c.ctx_, c.s.client, req)
23995 }
23996
23997
23998
23999
24000
24001
24002
24003
24004 func (c *ContentCategoriesUpdateCall) Do(opts ...googleapi.CallOption) (*ContentCategory, error) {
24005 gensupport.SetOptions(c.urlParams_, opts...)
24006 res, err := c.doRequest("json")
24007 if res != nil && res.StatusCode == http.StatusNotModified {
24008 if res.Body != nil {
24009 res.Body.Close()
24010 }
24011 return nil, &googleapi.Error{
24012 Code: res.StatusCode,
24013 Header: res.Header,
24014 }
24015 }
24016 if err != nil {
24017 return nil, err
24018 }
24019 defer googleapi.CloseBody(res)
24020 if err := googleapi.CheckResponse(res); err != nil {
24021 return nil, err
24022 }
24023 ret := &ContentCategory{
24024 ServerResponse: googleapi.ServerResponse{
24025 Header: res.Header,
24026 HTTPStatusCode: res.StatusCode,
24027 },
24028 }
24029 target := &ret
24030 if err := gensupport.DecodeResponse(target, res); err != nil {
24031 return nil, err
24032 }
24033 return ret, nil
24034
24035
24036
24037
24038
24039
24040
24041
24042
24043
24044
24045
24046
24047
24048
24049
24050
24051
24052
24053
24054
24055
24056
24057
24058
24059
24060
24061
24062 }
24063
24064
24065
24066 type ConversionsBatchinsertCall struct {
24067 s *Service
24068 profileId int64
24069 conversionsbatchinsertrequest *ConversionsBatchInsertRequest
24070 urlParams_ gensupport.URLParams
24071 ctx_ context.Context
24072 header_ http.Header
24073 }
24074
24075
24076 func (r *ConversionsService) Batchinsert(profileId int64, conversionsbatchinsertrequest *ConversionsBatchInsertRequest) *ConversionsBatchinsertCall {
24077 c := &ConversionsBatchinsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
24078 c.profileId = profileId
24079 c.conversionsbatchinsertrequest = conversionsbatchinsertrequest
24080 return c
24081 }
24082
24083
24084
24085
24086 func (c *ConversionsBatchinsertCall) Fields(s ...googleapi.Field) *ConversionsBatchinsertCall {
24087 c.urlParams_.Set("fields", googleapi.CombineFields(s))
24088 return c
24089 }
24090
24091
24092
24093
24094 func (c *ConversionsBatchinsertCall) Context(ctx context.Context) *ConversionsBatchinsertCall {
24095 c.ctx_ = ctx
24096 return c
24097 }
24098
24099
24100
24101 func (c *ConversionsBatchinsertCall) Header() http.Header {
24102 if c.header_ == nil {
24103 c.header_ = make(http.Header)
24104 }
24105 return c.header_
24106 }
24107
24108 func (c *ConversionsBatchinsertCall) doRequest(alt string) (*http.Response, error) {
24109 reqHeaders := make(http.Header)
24110 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
24111 for k, v := range c.header_ {
24112 reqHeaders[k] = v
24113 }
24114 reqHeaders.Set("User-Agent", c.s.userAgent())
24115 var body io.Reader = nil
24116 body, err := googleapi.WithoutDataWrapper.JSONReader(c.conversionsbatchinsertrequest)
24117 if err != nil {
24118 return nil, err
24119 }
24120 reqHeaders.Set("Content-Type", "application/json")
24121 c.urlParams_.Set("alt", alt)
24122 c.urlParams_.Set("prettyPrint", "false")
24123 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/conversions/batchinsert")
24124 urls += "?" + c.urlParams_.Encode()
24125 req, err := http.NewRequest("POST", urls, body)
24126 if err != nil {
24127 return nil, err
24128 }
24129 req.Header = reqHeaders
24130 googleapi.Expand(req.URL, map[string]string{
24131 "profileId": strconv.FormatInt(c.profileId, 10),
24132 })
24133 return gensupport.SendRequest(c.ctx_, c.s.client, req)
24134 }
24135
24136
24137
24138
24139
24140
24141
24142
24143 func (c *ConversionsBatchinsertCall) Do(opts ...googleapi.CallOption) (*ConversionsBatchInsertResponse, error) {
24144 gensupport.SetOptions(c.urlParams_, opts...)
24145 res, err := c.doRequest("json")
24146 if res != nil && res.StatusCode == http.StatusNotModified {
24147 if res.Body != nil {
24148 res.Body.Close()
24149 }
24150 return nil, &googleapi.Error{
24151 Code: res.StatusCode,
24152 Header: res.Header,
24153 }
24154 }
24155 if err != nil {
24156 return nil, err
24157 }
24158 defer googleapi.CloseBody(res)
24159 if err := googleapi.CheckResponse(res); err != nil {
24160 return nil, err
24161 }
24162 ret := &ConversionsBatchInsertResponse{
24163 ServerResponse: googleapi.ServerResponse{
24164 Header: res.Header,
24165 HTTPStatusCode: res.StatusCode,
24166 },
24167 }
24168 target := &ret
24169 if err := gensupport.DecodeResponse(target, res); err != nil {
24170 return nil, err
24171 }
24172 return ret, nil
24173
24174
24175
24176
24177
24178
24179
24180
24181
24182
24183
24184
24185
24186
24187
24188
24189
24190
24191
24192
24193
24194
24195
24196
24197
24198
24199
24200
24201 }
24202
24203
24204
24205 type ConversionsBatchupdateCall struct {
24206 s *Service
24207 profileId int64
24208 conversionsbatchupdaterequest *ConversionsBatchUpdateRequest
24209 urlParams_ gensupport.URLParams
24210 ctx_ context.Context
24211 header_ http.Header
24212 }
24213
24214
24215 func (r *ConversionsService) Batchupdate(profileId int64, conversionsbatchupdaterequest *ConversionsBatchUpdateRequest) *ConversionsBatchupdateCall {
24216 c := &ConversionsBatchupdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
24217 c.profileId = profileId
24218 c.conversionsbatchupdaterequest = conversionsbatchupdaterequest
24219 return c
24220 }
24221
24222
24223
24224
24225 func (c *ConversionsBatchupdateCall) Fields(s ...googleapi.Field) *ConversionsBatchupdateCall {
24226 c.urlParams_.Set("fields", googleapi.CombineFields(s))
24227 return c
24228 }
24229
24230
24231
24232
24233 func (c *ConversionsBatchupdateCall) Context(ctx context.Context) *ConversionsBatchupdateCall {
24234 c.ctx_ = ctx
24235 return c
24236 }
24237
24238
24239
24240 func (c *ConversionsBatchupdateCall) Header() http.Header {
24241 if c.header_ == nil {
24242 c.header_ = make(http.Header)
24243 }
24244 return c.header_
24245 }
24246
24247 func (c *ConversionsBatchupdateCall) doRequest(alt string) (*http.Response, error) {
24248 reqHeaders := make(http.Header)
24249 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
24250 for k, v := range c.header_ {
24251 reqHeaders[k] = v
24252 }
24253 reqHeaders.Set("User-Agent", c.s.userAgent())
24254 var body io.Reader = nil
24255 body, err := googleapi.WithoutDataWrapper.JSONReader(c.conversionsbatchupdaterequest)
24256 if err != nil {
24257 return nil, err
24258 }
24259 reqHeaders.Set("Content-Type", "application/json")
24260 c.urlParams_.Set("alt", alt)
24261 c.urlParams_.Set("prettyPrint", "false")
24262 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/conversions/batchupdate")
24263 urls += "?" + c.urlParams_.Encode()
24264 req, err := http.NewRequest("POST", urls, body)
24265 if err != nil {
24266 return nil, err
24267 }
24268 req.Header = reqHeaders
24269 googleapi.Expand(req.URL, map[string]string{
24270 "profileId": strconv.FormatInt(c.profileId, 10),
24271 })
24272 return gensupport.SendRequest(c.ctx_, c.s.client, req)
24273 }
24274
24275
24276
24277
24278
24279
24280
24281
24282 func (c *ConversionsBatchupdateCall) Do(opts ...googleapi.CallOption) (*ConversionsBatchUpdateResponse, error) {
24283 gensupport.SetOptions(c.urlParams_, opts...)
24284 res, err := c.doRequest("json")
24285 if res != nil && res.StatusCode == http.StatusNotModified {
24286 if res.Body != nil {
24287 res.Body.Close()
24288 }
24289 return nil, &googleapi.Error{
24290 Code: res.StatusCode,
24291 Header: res.Header,
24292 }
24293 }
24294 if err != nil {
24295 return nil, err
24296 }
24297 defer googleapi.CloseBody(res)
24298 if err := googleapi.CheckResponse(res); err != nil {
24299 return nil, err
24300 }
24301 ret := &ConversionsBatchUpdateResponse{
24302 ServerResponse: googleapi.ServerResponse{
24303 Header: res.Header,
24304 HTTPStatusCode: res.StatusCode,
24305 },
24306 }
24307 target := &ret
24308 if err := gensupport.DecodeResponse(target, res); err != nil {
24309 return nil, err
24310 }
24311 return ret, nil
24312
24313
24314
24315
24316
24317
24318
24319
24320
24321
24322
24323
24324
24325
24326
24327
24328
24329
24330
24331
24332
24333
24334
24335
24336
24337
24338
24339
24340 }
24341
24342
24343
24344 type CountriesGetCall struct {
24345 s *Service
24346 profileId int64
24347 dartId int64
24348 urlParams_ gensupport.URLParams
24349 ifNoneMatch_ string
24350 ctx_ context.Context
24351 header_ http.Header
24352 }
24353
24354
24355 func (r *CountriesService) Get(profileId int64, dartId int64) *CountriesGetCall {
24356 c := &CountriesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
24357 c.profileId = profileId
24358 c.dartId = dartId
24359 return c
24360 }
24361
24362
24363
24364
24365 func (c *CountriesGetCall) Fields(s ...googleapi.Field) *CountriesGetCall {
24366 c.urlParams_.Set("fields", googleapi.CombineFields(s))
24367 return c
24368 }
24369
24370
24371
24372
24373
24374
24375 func (c *CountriesGetCall) IfNoneMatch(entityTag string) *CountriesGetCall {
24376 c.ifNoneMatch_ = entityTag
24377 return c
24378 }
24379
24380
24381
24382
24383 func (c *CountriesGetCall) Context(ctx context.Context) *CountriesGetCall {
24384 c.ctx_ = ctx
24385 return c
24386 }
24387
24388
24389
24390 func (c *CountriesGetCall) Header() http.Header {
24391 if c.header_ == nil {
24392 c.header_ = make(http.Header)
24393 }
24394 return c.header_
24395 }
24396
24397 func (c *CountriesGetCall) doRequest(alt string) (*http.Response, error) {
24398 reqHeaders := make(http.Header)
24399 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
24400 for k, v := range c.header_ {
24401 reqHeaders[k] = v
24402 }
24403 reqHeaders.Set("User-Agent", c.s.userAgent())
24404 if c.ifNoneMatch_ != "" {
24405 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
24406 }
24407 var body io.Reader = nil
24408 c.urlParams_.Set("alt", alt)
24409 c.urlParams_.Set("prettyPrint", "false")
24410 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/countries/{dartId}")
24411 urls += "?" + c.urlParams_.Encode()
24412 req, err := http.NewRequest("GET", urls, body)
24413 if err != nil {
24414 return nil, err
24415 }
24416 req.Header = reqHeaders
24417 googleapi.Expand(req.URL, map[string]string{
24418 "profileId": strconv.FormatInt(c.profileId, 10),
24419 "dartId": strconv.FormatInt(c.dartId, 10),
24420 })
24421 return gensupport.SendRequest(c.ctx_, c.s.client, req)
24422 }
24423
24424
24425
24426
24427
24428
24429
24430
24431 func (c *CountriesGetCall) Do(opts ...googleapi.CallOption) (*Country, error) {
24432 gensupport.SetOptions(c.urlParams_, opts...)
24433 res, err := c.doRequest("json")
24434 if res != nil && res.StatusCode == http.StatusNotModified {
24435 if res.Body != nil {
24436 res.Body.Close()
24437 }
24438 return nil, &googleapi.Error{
24439 Code: res.StatusCode,
24440 Header: res.Header,
24441 }
24442 }
24443 if err != nil {
24444 return nil, err
24445 }
24446 defer googleapi.CloseBody(res)
24447 if err := googleapi.CheckResponse(res); err != nil {
24448 return nil, err
24449 }
24450 ret := &Country{
24451 ServerResponse: googleapi.ServerResponse{
24452 Header: res.Header,
24453 HTTPStatusCode: res.StatusCode,
24454 },
24455 }
24456 target := &ret
24457 if err := gensupport.DecodeResponse(target, res); err != nil {
24458 return nil, err
24459 }
24460 return ret, nil
24461
24462
24463
24464
24465
24466
24467
24468
24469
24470
24471
24472
24473
24474
24475
24476
24477
24478
24479
24480
24481
24482
24483
24484
24485
24486
24487
24488
24489
24490
24491
24492
24493
24494 }
24495
24496
24497
24498 type CountriesListCall struct {
24499 s *Service
24500 profileId int64
24501 urlParams_ gensupport.URLParams
24502 ifNoneMatch_ string
24503 ctx_ context.Context
24504 header_ http.Header
24505 }
24506
24507
24508 func (r *CountriesService) List(profileId int64) *CountriesListCall {
24509 c := &CountriesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
24510 c.profileId = profileId
24511 return c
24512 }
24513
24514
24515
24516
24517 func (c *CountriesListCall) Fields(s ...googleapi.Field) *CountriesListCall {
24518 c.urlParams_.Set("fields", googleapi.CombineFields(s))
24519 return c
24520 }
24521
24522
24523
24524
24525
24526
24527 func (c *CountriesListCall) IfNoneMatch(entityTag string) *CountriesListCall {
24528 c.ifNoneMatch_ = entityTag
24529 return c
24530 }
24531
24532
24533
24534
24535 func (c *CountriesListCall) Context(ctx context.Context) *CountriesListCall {
24536 c.ctx_ = ctx
24537 return c
24538 }
24539
24540
24541
24542 func (c *CountriesListCall) Header() http.Header {
24543 if c.header_ == nil {
24544 c.header_ = make(http.Header)
24545 }
24546 return c.header_
24547 }
24548
24549 func (c *CountriesListCall) doRequest(alt string) (*http.Response, error) {
24550 reqHeaders := make(http.Header)
24551 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
24552 for k, v := range c.header_ {
24553 reqHeaders[k] = v
24554 }
24555 reqHeaders.Set("User-Agent", c.s.userAgent())
24556 if c.ifNoneMatch_ != "" {
24557 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
24558 }
24559 var body io.Reader = nil
24560 c.urlParams_.Set("alt", alt)
24561 c.urlParams_.Set("prettyPrint", "false")
24562 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/countries")
24563 urls += "?" + c.urlParams_.Encode()
24564 req, err := http.NewRequest("GET", urls, body)
24565 if err != nil {
24566 return nil, err
24567 }
24568 req.Header = reqHeaders
24569 googleapi.Expand(req.URL, map[string]string{
24570 "profileId": strconv.FormatInt(c.profileId, 10),
24571 })
24572 return gensupport.SendRequest(c.ctx_, c.s.client, req)
24573 }
24574
24575
24576
24577
24578
24579
24580
24581
24582 func (c *CountriesListCall) Do(opts ...googleapi.CallOption) (*CountriesListResponse, error) {
24583 gensupport.SetOptions(c.urlParams_, opts...)
24584 res, err := c.doRequest("json")
24585 if res != nil && res.StatusCode == http.StatusNotModified {
24586 if res.Body != nil {
24587 res.Body.Close()
24588 }
24589 return nil, &googleapi.Error{
24590 Code: res.StatusCode,
24591 Header: res.Header,
24592 }
24593 }
24594 if err != nil {
24595 return nil, err
24596 }
24597 defer googleapi.CloseBody(res)
24598 if err := googleapi.CheckResponse(res); err != nil {
24599 return nil, err
24600 }
24601 ret := &CountriesListResponse{
24602 ServerResponse: googleapi.ServerResponse{
24603 Header: res.Header,
24604 HTTPStatusCode: res.StatusCode,
24605 },
24606 }
24607 target := &ret
24608 if err := gensupport.DecodeResponse(target, res); err != nil {
24609 return nil, err
24610 }
24611 return ret, nil
24612
24613
24614
24615
24616
24617
24618
24619
24620
24621
24622
24623
24624
24625
24626
24627
24628
24629
24630
24631
24632
24633
24634
24635
24636
24637 }
24638
24639
24640
24641 type CreativeAssetsInsertCall struct {
24642 s *Service
24643 profileId int64
24644 advertiserId int64
24645 creativeassetmetadata *CreativeAssetMetadata
24646 urlParams_ gensupport.URLParams
24647 mediaInfo_ *gensupport.MediaInfo
24648 ctx_ context.Context
24649 header_ http.Header
24650 }
24651
24652
24653 func (r *CreativeAssetsService) Insert(profileId int64, advertiserId int64, creativeassetmetadata *CreativeAssetMetadata) *CreativeAssetsInsertCall {
24654 c := &CreativeAssetsInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
24655 c.profileId = profileId
24656 c.advertiserId = advertiserId
24657 c.creativeassetmetadata = creativeassetmetadata
24658 return c
24659 }
24660
24661
24662
24663
24664
24665
24666
24667
24668
24669 func (c *CreativeAssetsInsertCall) Media(r io.Reader, options ...googleapi.MediaOption) *CreativeAssetsInsertCall {
24670 c.mediaInfo_ = gensupport.NewInfoFromMedia(r, options)
24671 return c
24672 }
24673
24674
24675
24676
24677
24678
24679
24680
24681
24682
24683 func (c *CreativeAssetsInsertCall) ResumableMedia(ctx context.Context, r io.ReaderAt, size int64, mediaType string) *CreativeAssetsInsertCall {
24684 c.ctx_ = ctx
24685 c.mediaInfo_ = gensupport.NewInfoFromResumableMedia(r, size, mediaType)
24686 return c
24687 }
24688
24689
24690
24691
24692
24693 func (c *CreativeAssetsInsertCall) ProgressUpdater(pu googleapi.ProgressUpdater) *CreativeAssetsInsertCall {
24694 c.mediaInfo_.SetProgressUpdater(pu)
24695 return c
24696 }
24697
24698
24699
24700
24701 func (c *CreativeAssetsInsertCall) Fields(s ...googleapi.Field) *CreativeAssetsInsertCall {
24702 c.urlParams_.Set("fields", googleapi.CombineFields(s))
24703 return c
24704 }
24705
24706
24707
24708
24709
24710
24711 func (c *CreativeAssetsInsertCall) Context(ctx context.Context) *CreativeAssetsInsertCall {
24712 c.ctx_ = ctx
24713 return c
24714 }
24715
24716
24717
24718 func (c *CreativeAssetsInsertCall) Header() http.Header {
24719 if c.header_ == nil {
24720 c.header_ = make(http.Header)
24721 }
24722 return c.header_
24723 }
24724
24725 func (c *CreativeAssetsInsertCall) doRequest(alt string) (*http.Response, error) {
24726 reqHeaders := make(http.Header)
24727 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
24728 for k, v := range c.header_ {
24729 reqHeaders[k] = v
24730 }
24731 reqHeaders.Set("User-Agent", c.s.userAgent())
24732 var body io.Reader = nil
24733 body, err := googleapi.WithoutDataWrapper.JSONReader(c.creativeassetmetadata)
24734 if err != nil {
24735 return nil, err
24736 }
24737 reqHeaders.Set("Content-Type", "application/json")
24738 c.urlParams_.Set("alt", alt)
24739 c.urlParams_.Set("prettyPrint", "false")
24740 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeAssets/{advertiserId}/creativeAssets")
24741 if c.mediaInfo_ != nil {
24742 urls = googleapi.ResolveRelative(c.s.BasePath, "/upload/dfareporting/v3.0/userprofiles/{profileId}/creativeAssets/{advertiserId}/creativeAssets")
24743 c.urlParams_.Set("uploadType", c.mediaInfo_.UploadType())
24744 }
24745 if body == nil {
24746 body = new(bytes.Buffer)
24747 reqHeaders.Set("Content-Type", "application/json")
24748 }
24749 body, getBody, cleanup := c.mediaInfo_.UploadRequest(reqHeaders, body)
24750 defer cleanup()
24751 urls += "?" + c.urlParams_.Encode()
24752 req, err := http.NewRequest("POST", urls, body)
24753 if err != nil {
24754 return nil, err
24755 }
24756 req.Header = reqHeaders
24757 req.GetBody = getBody
24758 googleapi.Expand(req.URL, map[string]string{
24759 "profileId": strconv.FormatInt(c.profileId, 10),
24760 "advertiserId": strconv.FormatInt(c.advertiserId, 10),
24761 })
24762 return gensupport.SendRequest(c.ctx_, c.s.client, req)
24763 }
24764
24765
24766
24767
24768
24769
24770
24771
24772 func (c *CreativeAssetsInsertCall) Do(opts ...googleapi.CallOption) (*CreativeAssetMetadata, error) {
24773 gensupport.SetOptions(c.urlParams_, opts...)
24774 res, err := c.doRequest("json")
24775 if res != nil && res.StatusCode == http.StatusNotModified {
24776 if res.Body != nil {
24777 res.Body.Close()
24778 }
24779 return nil, &googleapi.Error{
24780 Code: res.StatusCode,
24781 Header: res.Header,
24782 }
24783 }
24784 if err != nil {
24785 return nil, err
24786 }
24787 defer googleapi.CloseBody(res)
24788 if err := googleapi.CheckResponse(res); err != nil {
24789 return nil, err
24790 }
24791 rx := c.mediaInfo_.ResumableUpload(res.Header.Get("Location"))
24792 if rx != nil {
24793 rx.Client = c.s.client
24794 rx.UserAgent = c.s.userAgent()
24795 ctx := c.ctx_
24796 if ctx == nil {
24797 ctx = context.TODO()
24798 }
24799 res, err = rx.Upload(ctx)
24800 if err != nil {
24801 return nil, err
24802 }
24803 defer res.Body.Close()
24804 if err := googleapi.CheckResponse(res); err != nil {
24805 return nil, err
24806 }
24807 }
24808 ret := &CreativeAssetMetadata{
24809 ServerResponse: googleapi.ServerResponse{
24810 Header: res.Header,
24811 HTTPStatusCode: res.StatusCode,
24812 },
24813 }
24814 target := &ret
24815 if err := gensupport.DecodeResponse(target, res); err != nil {
24816 return nil, err
24817 }
24818 return ret, nil
24819
24820
24821
24822
24823
24824
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
24855
24856
24857
24858
24859
24860
24861
24862
24863
24864
24865
24866
24867
24868
24869
24870
24871
24872 }
24873
24874
24875
24876 type CreativeFieldValuesDeleteCall struct {
24877 s *Service
24878 profileId int64
24879 creativeFieldId int64
24880 id int64
24881 urlParams_ gensupport.URLParams
24882 ctx_ context.Context
24883 header_ http.Header
24884 }
24885
24886
24887 func (r *CreativeFieldValuesService) Delete(profileId int64, creativeFieldId int64, id int64) *CreativeFieldValuesDeleteCall {
24888 c := &CreativeFieldValuesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
24889 c.profileId = profileId
24890 c.creativeFieldId = creativeFieldId
24891 c.id = id
24892 return c
24893 }
24894
24895
24896
24897
24898 func (c *CreativeFieldValuesDeleteCall) Fields(s ...googleapi.Field) *CreativeFieldValuesDeleteCall {
24899 c.urlParams_.Set("fields", googleapi.CombineFields(s))
24900 return c
24901 }
24902
24903
24904
24905
24906 func (c *CreativeFieldValuesDeleteCall) Context(ctx context.Context) *CreativeFieldValuesDeleteCall {
24907 c.ctx_ = ctx
24908 return c
24909 }
24910
24911
24912
24913 func (c *CreativeFieldValuesDeleteCall) Header() http.Header {
24914 if c.header_ == nil {
24915 c.header_ = make(http.Header)
24916 }
24917 return c.header_
24918 }
24919
24920 func (c *CreativeFieldValuesDeleteCall) doRequest(alt string) (*http.Response, error) {
24921 reqHeaders := make(http.Header)
24922 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
24923 for k, v := range c.header_ {
24924 reqHeaders[k] = v
24925 }
24926 reqHeaders.Set("User-Agent", c.s.userAgent())
24927 var body io.Reader = nil
24928 c.urlParams_.Set("alt", alt)
24929 c.urlParams_.Set("prettyPrint", "false")
24930 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeFields/{creativeFieldId}/creativeFieldValues/{id}")
24931 urls += "?" + c.urlParams_.Encode()
24932 req, err := http.NewRequest("DELETE", urls, body)
24933 if err != nil {
24934 return nil, err
24935 }
24936 req.Header = reqHeaders
24937 googleapi.Expand(req.URL, map[string]string{
24938 "profileId": strconv.FormatInt(c.profileId, 10),
24939 "creativeFieldId": strconv.FormatInt(c.creativeFieldId, 10),
24940 "id": strconv.FormatInt(c.id, 10),
24941 })
24942 return gensupport.SendRequest(c.ctx_, c.s.client, req)
24943 }
24944
24945
24946 func (c *CreativeFieldValuesDeleteCall) Do(opts ...googleapi.CallOption) error {
24947 gensupport.SetOptions(c.urlParams_, opts...)
24948 res, err := c.doRequest("json")
24949 if err != nil {
24950 return err
24951 }
24952 defer googleapi.CloseBody(res)
24953 if err := googleapi.CheckResponse(res); err != nil {
24954 return err
24955 }
24956 return nil
24957
24958
24959
24960
24961
24962
24963
24964
24965
24966
24967
24968
24969
24970
24971
24972
24973
24974
24975
24976
24977
24978
24979
24980
24981
24982
24983
24984
24985
24986
24987
24988
24989
24990
24991
24992
24993
24994
24995 }
24996
24997
24998
24999 type CreativeFieldValuesGetCall struct {
25000 s *Service
25001 profileId int64
25002 creativeFieldId int64
25003 id int64
25004 urlParams_ gensupport.URLParams
25005 ifNoneMatch_ string
25006 ctx_ context.Context
25007 header_ http.Header
25008 }
25009
25010
25011 func (r *CreativeFieldValuesService) Get(profileId int64, creativeFieldId int64, id int64) *CreativeFieldValuesGetCall {
25012 c := &CreativeFieldValuesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
25013 c.profileId = profileId
25014 c.creativeFieldId = creativeFieldId
25015 c.id = id
25016 return c
25017 }
25018
25019
25020
25021
25022 func (c *CreativeFieldValuesGetCall) Fields(s ...googleapi.Field) *CreativeFieldValuesGetCall {
25023 c.urlParams_.Set("fields", googleapi.CombineFields(s))
25024 return c
25025 }
25026
25027
25028
25029
25030
25031
25032 func (c *CreativeFieldValuesGetCall) IfNoneMatch(entityTag string) *CreativeFieldValuesGetCall {
25033 c.ifNoneMatch_ = entityTag
25034 return c
25035 }
25036
25037
25038
25039
25040 func (c *CreativeFieldValuesGetCall) Context(ctx context.Context) *CreativeFieldValuesGetCall {
25041 c.ctx_ = ctx
25042 return c
25043 }
25044
25045
25046
25047 func (c *CreativeFieldValuesGetCall) Header() http.Header {
25048 if c.header_ == nil {
25049 c.header_ = make(http.Header)
25050 }
25051 return c.header_
25052 }
25053
25054 func (c *CreativeFieldValuesGetCall) doRequest(alt string) (*http.Response, error) {
25055 reqHeaders := make(http.Header)
25056 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
25057 for k, v := range c.header_ {
25058 reqHeaders[k] = v
25059 }
25060 reqHeaders.Set("User-Agent", c.s.userAgent())
25061 if c.ifNoneMatch_ != "" {
25062 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
25063 }
25064 var body io.Reader = nil
25065 c.urlParams_.Set("alt", alt)
25066 c.urlParams_.Set("prettyPrint", "false")
25067 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeFields/{creativeFieldId}/creativeFieldValues/{id}")
25068 urls += "?" + c.urlParams_.Encode()
25069 req, err := http.NewRequest("GET", urls, body)
25070 if err != nil {
25071 return nil, err
25072 }
25073 req.Header = reqHeaders
25074 googleapi.Expand(req.URL, map[string]string{
25075 "profileId": strconv.FormatInt(c.profileId, 10),
25076 "creativeFieldId": strconv.FormatInt(c.creativeFieldId, 10),
25077 "id": strconv.FormatInt(c.id, 10),
25078 })
25079 return gensupport.SendRequest(c.ctx_, c.s.client, req)
25080 }
25081
25082
25083
25084
25085
25086
25087
25088
25089 func (c *CreativeFieldValuesGetCall) Do(opts ...googleapi.CallOption) (*CreativeFieldValue, error) {
25090 gensupport.SetOptions(c.urlParams_, opts...)
25091 res, err := c.doRequest("json")
25092 if res != nil && res.StatusCode == http.StatusNotModified {
25093 if res.Body != nil {
25094 res.Body.Close()
25095 }
25096 return nil, &googleapi.Error{
25097 Code: res.StatusCode,
25098 Header: res.Header,
25099 }
25100 }
25101 if err != nil {
25102 return nil, err
25103 }
25104 defer googleapi.CloseBody(res)
25105 if err := googleapi.CheckResponse(res); err != nil {
25106 return nil, err
25107 }
25108 ret := &CreativeFieldValue{
25109 ServerResponse: googleapi.ServerResponse{
25110 Header: res.Header,
25111 HTTPStatusCode: res.StatusCode,
25112 },
25113 }
25114 target := &ret
25115 if err := gensupport.DecodeResponse(target, res); err != nil {
25116 return nil, err
25117 }
25118 return ret, nil
25119
25120
25121
25122
25123
25124
25125
25126
25127
25128
25129
25130
25131
25132
25133
25134
25135
25136
25137
25138
25139
25140
25141
25142
25143
25144
25145
25146
25147
25148
25149
25150
25151
25152
25153
25154
25155
25156
25157
25158
25159
25160 }
25161
25162
25163
25164 type CreativeFieldValuesInsertCall struct {
25165 s *Service
25166 profileId int64
25167 creativeFieldId int64
25168 creativefieldvalue *CreativeFieldValue
25169 urlParams_ gensupport.URLParams
25170 ctx_ context.Context
25171 header_ http.Header
25172 }
25173
25174
25175 func (r *CreativeFieldValuesService) Insert(profileId int64, creativeFieldId int64, creativefieldvalue *CreativeFieldValue) *CreativeFieldValuesInsertCall {
25176 c := &CreativeFieldValuesInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
25177 c.profileId = profileId
25178 c.creativeFieldId = creativeFieldId
25179 c.creativefieldvalue = creativefieldvalue
25180 return c
25181 }
25182
25183
25184
25185
25186 func (c *CreativeFieldValuesInsertCall) Fields(s ...googleapi.Field) *CreativeFieldValuesInsertCall {
25187 c.urlParams_.Set("fields", googleapi.CombineFields(s))
25188 return c
25189 }
25190
25191
25192
25193
25194 func (c *CreativeFieldValuesInsertCall) Context(ctx context.Context) *CreativeFieldValuesInsertCall {
25195 c.ctx_ = ctx
25196 return c
25197 }
25198
25199
25200
25201 func (c *CreativeFieldValuesInsertCall) Header() http.Header {
25202 if c.header_ == nil {
25203 c.header_ = make(http.Header)
25204 }
25205 return c.header_
25206 }
25207
25208 func (c *CreativeFieldValuesInsertCall) doRequest(alt string) (*http.Response, error) {
25209 reqHeaders := make(http.Header)
25210 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
25211 for k, v := range c.header_ {
25212 reqHeaders[k] = v
25213 }
25214 reqHeaders.Set("User-Agent", c.s.userAgent())
25215 var body io.Reader = nil
25216 body, err := googleapi.WithoutDataWrapper.JSONReader(c.creativefieldvalue)
25217 if err != nil {
25218 return nil, err
25219 }
25220 reqHeaders.Set("Content-Type", "application/json")
25221 c.urlParams_.Set("alt", alt)
25222 c.urlParams_.Set("prettyPrint", "false")
25223 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeFields/{creativeFieldId}/creativeFieldValues")
25224 urls += "?" + c.urlParams_.Encode()
25225 req, err := http.NewRequest("POST", urls, body)
25226 if err != nil {
25227 return nil, err
25228 }
25229 req.Header = reqHeaders
25230 googleapi.Expand(req.URL, map[string]string{
25231 "profileId": strconv.FormatInt(c.profileId, 10),
25232 "creativeFieldId": strconv.FormatInt(c.creativeFieldId, 10),
25233 })
25234 return gensupport.SendRequest(c.ctx_, c.s.client, req)
25235 }
25236
25237
25238
25239
25240
25241
25242
25243
25244 func (c *CreativeFieldValuesInsertCall) Do(opts ...googleapi.CallOption) (*CreativeFieldValue, error) {
25245 gensupport.SetOptions(c.urlParams_, opts...)
25246 res, err := c.doRequest("json")
25247 if res != nil && res.StatusCode == http.StatusNotModified {
25248 if res.Body != nil {
25249 res.Body.Close()
25250 }
25251 return nil, &googleapi.Error{
25252 Code: res.StatusCode,
25253 Header: res.Header,
25254 }
25255 }
25256 if err != nil {
25257 return nil, err
25258 }
25259 defer googleapi.CloseBody(res)
25260 if err := googleapi.CheckResponse(res); err != nil {
25261 return nil, err
25262 }
25263 ret := &CreativeFieldValue{
25264 ServerResponse: googleapi.ServerResponse{
25265 Header: res.Header,
25266 HTTPStatusCode: res.StatusCode,
25267 },
25268 }
25269 target := &ret
25270 if err := gensupport.DecodeResponse(target, res); err != nil {
25271 return nil, err
25272 }
25273 return ret, nil
25274
25275
25276
25277
25278
25279
25280
25281
25282
25283
25284
25285
25286
25287
25288
25289
25290
25291
25292
25293
25294
25295
25296
25297
25298
25299
25300
25301
25302
25303
25304
25305
25306
25307
25308
25309
25310 }
25311
25312
25313
25314 type CreativeFieldValuesListCall struct {
25315 s *Service
25316 profileId int64
25317 creativeFieldId int64
25318 urlParams_ gensupport.URLParams
25319 ifNoneMatch_ string
25320 ctx_ context.Context
25321 header_ http.Header
25322 }
25323
25324
25325
25326 func (r *CreativeFieldValuesService) List(profileId int64, creativeFieldId int64) *CreativeFieldValuesListCall {
25327 c := &CreativeFieldValuesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
25328 c.profileId = profileId
25329 c.creativeFieldId = creativeFieldId
25330 return c
25331 }
25332
25333
25334
25335 func (c *CreativeFieldValuesListCall) Ids(ids ...int64) *CreativeFieldValuesListCall {
25336 var ids_ []string
25337 for _, v := range ids {
25338 ids_ = append(ids_, fmt.Sprint(v))
25339 }
25340 c.urlParams_.SetMulti("ids", ids_)
25341 return c
25342 }
25343
25344
25345
25346 func (c *CreativeFieldValuesListCall) MaxResults(maxResults int64) *CreativeFieldValuesListCall {
25347 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
25348 return c
25349 }
25350
25351
25352
25353 func (c *CreativeFieldValuesListCall) PageToken(pageToken string) *CreativeFieldValuesListCall {
25354 c.urlParams_.Set("pageToken", pageToken)
25355 return c
25356 }
25357
25358
25359
25360
25361 func (c *CreativeFieldValuesListCall) SearchString(searchString string) *CreativeFieldValuesListCall {
25362 c.urlParams_.Set("searchString", searchString)
25363 return c
25364 }
25365
25366
25367
25368
25369
25370
25371
25372
25373 func (c *CreativeFieldValuesListCall) SortField(sortField string) *CreativeFieldValuesListCall {
25374 c.urlParams_.Set("sortField", sortField)
25375 return c
25376 }
25377
25378
25379
25380
25381
25382
25383
25384
25385 func (c *CreativeFieldValuesListCall) SortOrder(sortOrder string) *CreativeFieldValuesListCall {
25386 c.urlParams_.Set("sortOrder", sortOrder)
25387 return c
25388 }
25389
25390
25391
25392
25393 func (c *CreativeFieldValuesListCall) Fields(s ...googleapi.Field) *CreativeFieldValuesListCall {
25394 c.urlParams_.Set("fields", googleapi.CombineFields(s))
25395 return c
25396 }
25397
25398
25399
25400
25401
25402
25403 func (c *CreativeFieldValuesListCall) IfNoneMatch(entityTag string) *CreativeFieldValuesListCall {
25404 c.ifNoneMatch_ = entityTag
25405 return c
25406 }
25407
25408
25409
25410
25411 func (c *CreativeFieldValuesListCall) Context(ctx context.Context) *CreativeFieldValuesListCall {
25412 c.ctx_ = ctx
25413 return c
25414 }
25415
25416
25417
25418 func (c *CreativeFieldValuesListCall) Header() http.Header {
25419 if c.header_ == nil {
25420 c.header_ = make(http.Header)
25421 }
25422 return c.header_
25423 }
25424
25425 func (c *CreativeFieldValuesListCall) doRequest(alt string) (*http.Response, error) {
25426 reqHeaders := make(http.Header)
25427 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
25428 for k, v := range c.header_ {
25429 reqHeaders[k] = v
25430 }
25431 reqHeaders.Set("User-Agent", c.s.userAgent())
25432 if c.ifNoneMatch_ != "" {
25433 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
25434 }
25435 var body io.Reader = nil
25436 c.urlParams_.Set("alt", alt)
25437 c.urlParams_.Set("prettyPrint", "false")
25438 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeFields/{creativeFieldId}/creativeFieldValues")
25439 urls += "?" + c.urlParams_.Encode()
25440 req, err := http.NewRequest("GET", urls, body)
25441 if err != nil {
25442 return nil, err
25443 }
25444 req.Header = reqHeaders
25445 googleapi.Expand(req.URL, map[string]string{
25446 "profileId": strconv.FormatInt(c.profileId, 10),
25447 "creativeFieldId": strconv.FormatInt(c.creativeFieldId, 10),
25448 })
25449 return gensupport.SendRequest(c.ctx_, c.s.client, req)
25450 }
25451
25452
25453
25454
25455
25456
25457
25458
25459 func (c *CreativeFieldValuesListCall) Do(opts ...googleapi.CallOption) (*CreativeFieldValuesListResponse, error) {
25460 gensupport.SetOptions(c.urlParams_, opts...)
25461 res, err := c.doRequest("json")
25462 if res != nil && res.StatusCode == http.StatusNotModified {
25463 if res.Body != nil {
25464 res.Body.Close()
25465 }
25466 return nil, &googleapi.Error{
25467 Code: res.StatusCode,
25468 Header: res.Header,
25469 }
25470 }
25471 if err != nil {
25472 return nil, err
25473 }
25474 defer googleapi.CloseBody(res)
25475 if err := googleapi.CheckResponse(res); err != nil {
25476 return nil, err
25477 }
25478 ret := &CreativeFieldValuesListResponse{
25479 ServerResponse: googleapi.ServerResponse{
25480 Header: res.Header,
25481 HTTPStatusCode: res.StatusCode,
25482 },
25483 }
25484 target := &ret
25485 if err := gensupport.DecodeResponse(target, res); err != nil {
25486 return nil, err
25487 }
25488 return ret, nil
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
25528
25529
25530
25531
25532
25533
25534
25535
25536
25537
25538
25539
25540
25541
25542
25543
25544
25545
25546
25547
25548
25549
25550
25551
25552
25553
25554
25555
25556
25557
25558
25559
25560
25561
25562
25563
25564
25565
25566
25567
25568
25569
25570
25571
25572
25573
25574
25575
25576 }
25577
25578
25579
25580
25581 func (c *CreativeFieldValuesListCall) Pages(ctx context.Context, f func(*CreativeFieldValuesListResponse) error) error {
25582 c.ctx_ = ctx
25583 defer c.PageToken(c.urlParams_.Get("pageToken"))
25584 for {
25585 x, err := c.Do()
25586 if err != nil {
25587 return err
25588 }
25589 if err := f(x); err != nil {
25590 return err
25591 }
25592 if x.NextPageToken == "" {
25593 return nil
25594 }
25595 c.PageToken(x.NextPageToken)
25596 }
25597 }
25598
25599
25600
25601 type CreativeFieldValuesPatchCall struct {
25602 s *Service
25603 profileId int64
25604 creativeFieldId int64
25605 creativefieldvalue *CreativeFieldValue
25606 urlParams_ gensupport.URLParams
25607 ctx_ context.Context
25608 header_ http.Header
25609 }
25610
25611
25612
25613 func (r *CreativeFieldValuesService) Patch(profileId int64, creativeFieldId int64, id int64, creativefieldvalue *CreativeFieldValue) *CreativeFieldValuesPatchCall {
25614 c := &CreativeFieldValuesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
25615 c.profileId = profileId
25616 c.creativeFieldId = creativeFieldId
25617 c.urlParams_.Set("id", fmt.Sprint(id))
25618 c.creativefieldvalue = creativefieldvalue
25619 return c
25620 }
25621
25622
25623
25624
25625 func (c *CreativeFieldValuesPatchCall) Fields(s ...googleapi.Field) *CreativeFieldValuesPatchCall {
25626 c.urlParams_.Set("fields", googleapi.CombineFields(s))
25627 return c
25628 }
25629
25630
25631
25632
25633 func (c *CreativeFieldValuesPatchCall) Context(ctx context.Context) *CreativeFieldValuesPatchCall {
25634 c.ctx_ = ctx
25635 return c
25636 }
25637
25638
25639
25640 func (c *CreativeFieldValuesPatchCall) Header() http.Header {
25641 if c.header_ == nil {
25642 c.header_ = make(http.Header)
25643 }
25644 return c.header_
25645 }
25646
25647 func (c *CreativeFieldValuesPatchCall) doRequest(alt string) (*http.Response, error) {
25648 reqHeaders := make(http.Header)
25649 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
25650 for k, v := range c.header_ {
25651 reqHeaders[k] = v
25652 }
25653 reqHeaders.Set("User-Agent", c.s.userAgent())
25654 var body io.Reader = nil
25655 body, err := googleapi.WithoutDataWrapper.JSONReader(c.creativefieldvalue)
25656 if err != nil {
25657 return nil, err
25658 }
25659 reqHeaders.Set("Content-Type", "application/json")
25660 c.urlParams_.Set("alt", alt)
25661 c.urlParams_.Set("prettyPrint", "false")
25662 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeFields/{creativeFieldId}/creativeFieldValues")
25663 urls += "?" + c.urlParams_.Encode()
25664 req, err := http.NewRequest("PATCH", urls, body)
25665 if err != nil {
25666 return nil, err
25667 }
25668 req.Header = reqHeaders
25669 googleapi.Expand(req.URL, map[string]string{
25670 "profileId": strconv.FormatInt(c.profileId, 10),
25671 "creativeFieldId": strconv.FormatInt(c.creativeFieldId, 10),
25672 })
25673 return gensupport.SendRequest(c.ctx_, c.s.client, req)
25674 }
25675
25676
25677
25678
25679
25680
25681
25682
25683 func (c *CreativeFieldValuesPatchCall) Do(opts ...googleapi.CallOption) (*CreativeFieldValue, error) {
25684 gensupport.SetOptions(c.urlParams_, opts...)
25685 res, err := c.doRequest("json")
25686 if res != nil && res.StatusCode == http.StatusNotModified {
25687 if res.Body != nil {
25688 res.Body.Close()
25689 }
25690 return nil, &googleapi.Error{
25691 Code: res.StatusCode,
25692 Header: res.Header,
25693 }
25694 }
25695 if err != nil {
25696 return nil, err
25697 }
25698 defer googleapi.CloseBody(res)
25699 if err := googleapi.CheckResponse(res); err != nil {
25700 return nil, err
25701 }
25702 ret := &CreativeFieldValue{
25703 ServerResponse: googleapi.ServerResponse{
25704 Header: res.Header,
25705 HTTPStatusCode: res.StatusCode,
25706 },
25707 }
25708 target := &ret
25709 if err := gensupport.DecodeResponse(target, res); err != nil {
25710 return nil, err
25711 }
25712 return ret, nil
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 type CreativeFieldValuesUpdateCall struct {
25762 s *Service
25763 profileId int64
25764 creativeFieldId int64
25765 creativefieldvalue *CreativeFieldValue
25766 urlParams_ gensupport.URLParams
25767 ctx_ context.Context
25768 header_ http.Header
25769 }
25770
25771
25772 func (r *CreativeFieldValuesService) Update(profileId int64, creativeFieldId int64, creativefieldvalue *CreativeFieldValue) *CreativeFieldValuesUpdateCall {
25773 c := &CreativeFieldValuesUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
25774 c.profileId = profileId
25775 c.creativeFieldId = creativeFieldId
25776 c.creativefieldvalue = creativefieldvalue
25777 return c
25778 }
25779
25780
25781
25782
25783 func (c *CreativeFieldValuesUpdateCall) Fields(s ...googleapi.Field) *CreativeFieldValuesUpdateCall {
25784 c.urlParams_.Set("fields", googleapi.CombineFields(s))
25785 return c
25786 }
25787
25788
25789
25790
25791 func (c *CreativeFieldValuesUpdateCall) Context(ctx context.Context) *CreativeFieldValuesUpdateCall {
25792 c.ctx_ = ctx
25793 return c
25794 }
25795
25796
25797
25798 func (c *CreativeFieldValuesUpdateCall) Header() http.Header {
25799 if c.header_ == nil {
25800 c.header_ = make(http.Header)
25801 }
25802 return c.header_
25803 }
25804
25805 func (c *CreativeFieldValuesUpdateCall) doRequest(alt string) (*http.Response, error) {
25806 reqHeaders := make(http.Header)
25807 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
25808 for k, v := range c.header_ {
25809 reqHeaders[k] = v
25810 }
25811 reqHeaders.Set("User-Agent", c.s.userAgent())
25812 var body io.Reader = nil
25813 body, err := googleapi.WithoutDataWrapper.JSONReader(c.creativefieldvalue)
25814 if err != nil {
25815 return nil, err
25816 }
25817 reqHeaders.Set("Content-Type", "application/json")
25818 c.urlParams_.Set("alt", alt)
25819 c.urlParams_.Set("prettyPrint", "false")
25820 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeFields/{creativeFieldId}/creativeFieldValues")
25821 urls += "?" + c.urlParams_.Encode()
25822 req, err := http.NewRequest("PUT", urls, body)
25823 if err != nil {
25824 return nil, err
25825 }
25826 req.Header = reqHeaders
25827 googleapi.Expand(req.URL, map[string]string{
25828 "profileId": strconv.FormatInt(c.profileId, 10),
25829 "creativeFieldId": strconv.FormatInt(c.creativeFieldId, 10),
25830 })
25831 return gensupport.SendRequest(c.ctx_, c.s.client, req)
25832 }
25833
25834
25835
25836
25837
25838
25839
25840
25841 func (c *CreativeFieldValuesUpdateCall) Do(opts ...googleapi.CallOption) (*CreativeFieldValue, error) {
25842 gensupport.SetOptions(c.urlParams_, opts...)
25843 res, err := c.doRequest("json")
25844 if res != nil && res.StatusCode == http.StatusNotModified {
25845 if res.Body != nil {
25846 res.Body.Close()
25847 }
25848 return nil, &googleapi.Error{
25849 Code: res.StatusCode,
25850 Header: res.Header,
25851 }
25852 }
25853 if err != nil {
25854 return nil, err
25855 }
25856 defer googleapi.CloseBody(res)
25857 if err := googleapi.CheckResponse(res); err != nil {
25858 return nil, err
25859 }
25860 ret := &CreativeFieldValue{
25861 ServerResponse: googleapi.ServerResponse{
25862 Header: res.Header,
25863 HTTPStatusCode: res.StatusCode,
25864 },
25865 }
25866 target := &ret
25867 if err := gensupport.DecodeResponse(target, res); err != nil {
25868 return nil, err
25869 }
25870 return ret, nil
25871
25872
25873
25874
25875
25876
25877
25878
25879
25880
25881
25882
25883
25884
25885
25886
25887
25888
25889
25890
25891
25892
25893
25894
25895
25896
25897
25898
25899
25900
25901
25902
25903
25904
25905
25906
25907 }
25908
25909
25910
25911 type CreativeFieldsDeleteCall struct {
25912 s *Service
25913 profileId int64
25914 id int64
25915 urlParams_ gensupport.URLParams
25916 ctx_ context.Context
25917 header_ http.Header
25918 }
25919
25920
25921 func (r *CreativeFieldsService) Delete(profileId int64, id int64) *CreativeFieldsDeleteCall {
25922 c := &CreativeFieldsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
25923 c.profileId = profileId
25924 c.id = id
25925 return c
25926 }
25927
25928
25929
25930
25931 func (c *CreativeFieldsDeleteCall) Fields(s ...googleapi.Field) *CreativeFieldsDeleteCall {
25932 c.urlParams_.Set("fields", googleapi.CombineFields(s))
25933 return c
25934 }
25935
25936
25937
25938
25939 func (c *CreativeFieldsDeleteCall) Context(ctx context.Context) *CreativeFieldsDeleteCall {
25940 c.ctx_ = ctx
25941 return c
25942 }
25943
25944
25945
25946 func (c *CreativeFieldsDeleteCall) Header() http.Header {
25947 if c.header_ == nil {
25948 c.header_ = make(http.Header)
25949 }
25950 return c.header_
25951 }
25952
25953 func (c *CreativeFieldsDeleteCall) doRequest(alt string) (*http.Response, error) {
25954 reqHeaders := make(http.Header)
25955 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
25956 for k, v := range c.header_ {
25957 reqHeaders[k] = v
25958 }
25959 reqHeaders.Set("User-Agent", c.s.userAgent())
25960 var body io.Reader = nil
25961 c.urlParams_.Set("alt", alt)
25962 c.urlParams_.Set("prettyPrint", "false")
25963 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeFields/{id}")
25964 urls += "?" + c.urlParams_.Encode()
25965 req, err := http.NewRequest("DELETE", urls, body)
25966 if err != nil {
25967 return nil, err
25968 }
25969 req.Header = reqHeaders
25970 googleapi.Expand(req.URL, map[string]string{
25971 "profileId": strconv.FormatInt(c.profileId, 10),
25972 "id": strconv.FormatInt(c.id, 10),
25973 })
25974 return gensupport.SendRequest(c.ctx_, c.s.client, req)
25975 }
25976
25977
25978 func (c *CreativeFieldsDeleteCall) Do(opts ...googleapi.CallOption) error {
25979 gensupport.SetOptions(c.urlParams_, opts...)
25980 res, err := c.doRequest("json")
25981 if err != nil {
25982 return err
25983 }
25984 defer googleapi.CloseBody(res)
25985 if err := googleapi.CheckResponse(res); err != nil {
25986 return err
25987 }
25988 return nil
25989
25990
25991
25992
25993
25994
25995
25996
25997
25998
25999
26000
26001
26002
26003
26004
26005
26006
26007
26008
26009
26010
26011
26012
26013
26014
26015
26016
26017
26018
26019 }
26020
26021
26022
26023 type CreativeFieldsGetCall struct {
26024 s *Service
26025 profileId int64
26026 id int64
26027 urlParams_ gensupport.URLParams
26028 ifNoneMatch_ string
26029 ctx_ context.Context
26030 header_ http.Header
26031 }
26032
26033
26034 func (r *CreativeFieldsService) Get(profileId int64, id int64) *CreativeFieldsGetCall {
26035 c := &CreativeFieldsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
26036 c.profileId = profileId
26037 c.id = id
26038 return c
26039 }
26040
26041
26042
26043
26044 func (c *CreativeFieldsGetCall) Fields(s ...googleapi.Field) *CreativeFieldsGetCall {
26045 c.urlParams_.Set("fields", googleapi.CombineFields(s))
26046 return c
26047 }
26048
26049
26050
26051
26052
26053
26054 func (c *CreativeFieldsGetCall) IfNoneMatch(entityTag string) *CreativeFieldsGetCall {
26055 c.ifNoneMatch_ = entityTag
26056 return c
26057 }
26058
26059
26060
26061
26062 func (c *CreativeFieldsGetCall) Context(ctx context.Context) *CreativeFieldsGetCall {
26063 c.ctx_ = ctx
26064 return c
26065 }
26066
26067
26068
26069 func (c *CreativeFieldsGetCall) Header() http.Header {
26070 if c.header_ == nil {
26071 c.header_ = make(http.Header)
26072 }
26073 return c.header_
26074 }
26075
26076 func (c *CreativeFieldsGetCall) doRequest(alt string) (*http.Response, error) {
26077 reqHeaders := make(http.Header)
26078 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
26079 for k, v := range c.header_ {
26080 reqHeaders[k] = v
26081 }
26082 reqHeaders.Set("User-Agent", c.s.userAgent())
26083 if c.ifNoneMatch_ != "" {
26084 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
26085 }
26086 var body io.Reader = nil
26087 c.urlParams_.Set("alt", alt)
26088 c.urlParams_.Set("prettyPrint", "false")
26089 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeFields/{id}")
26090 urls += "?" + c.urlParams_.Encode()
26091 req, err := http.NewRequest("GET", urls, body)
26092 if err != nil {
26093 return nil, err
26094 }
26095 req.Header = reqHeaders
26096 googleapi.Expand(req.URL, map[string]string{
26097 "profileId": strconv.FormatInt(c.profileId, 10),
26098 "id": strconv.FormatInt(c.id, 10),
26099 })
26100 return gensupport.SendRequest(c.ctx_, c.s.client, req)
26101 }
26102
26103
26104
26105
26106
26107
26108
26109
26110 func (c *CreativeFieldsGetCall) Do(opts ...googleapi.CallOption) (*CreativeField, error) {
26111 gensupport.SetOptions(c.urlParams_, opts...)
26112 res, err := c.doRequest("json")
26113 if res != nil && res.StatusCode == http.StatusNotModified {
26114 if res.Body != nil {
26115 res.Body.Close()
26116 }
26117 return nil, &googleapi.Error{
26118 Code: res.StatusCode,
26119 Header: res.Header,
26120 }
26121 }
26122 if err != nil {
26123 return nil, err
26124 }
26125 defer googleapi.CloseBody(res)
26126 if err := googleapi.CheckResponse(res); err != nil {
26127 return nil, err
26128 }
26129 ret := &CreativeField{
26130 ServerResponse: googleapi.ServerResponse{
26131 Header: res.Header,
26132 HTTPStatusCode: res.StatusCode,
26133 },
26134 }
26135 target := &ret
26136 if err := gensupport.DecodeResponse(target, res); err != nil {
26137 return nil, err
26138 }
26139 return ret, nil
26140
26141
26142
26143
26144
26145
26146
26147
26148
26149
26150
26151
26152
26153
26154
26155
26156
26157
26158
26159
26160
26161
26162
26163
26164
26165
26166
26167
26168
26169
26170
26171
26172
26173 }
26174
26175
26176
26177 type CreativeFieldsInsertCall struct {
26178 s *Service
26179 profileId int64
26180 creativefield *CreativeField
26181 urlParams_ gensupport.URLParams
26182 ctx_ context.Context
26183 header_ http.Header
26184 }
26185
26186
26187 func (r *CreativeFieldsService) Insert(profileId int64, creativefield *CreativeField) *CreativeFieldsInsertCall {
26188 c := &CreativeFieldsInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
26189 c.profileId = profileId
26190 c.creativefield = creativefield
26191 return c
26192 }
26193
26194
26195
26196
26197 func (c *CreativeFieldsInsertCall) Fields(s ...googleapi.Field) *CreativeFieldsInsertCall {
26198 c.urlParams_.Set("fields", googleapi.CombineFields(s))
26199 return c
26200 }
26201
26202
26203
26204
26205 func (c *CreativeFieldsInsertCall) Context(ctx context.Context) *CreativeFieldsInsertCall {
26206 c.ctx_ = ctx
26207 return c
26208 }
26209
26210
26211
26212 func (c *CreativeFieldsInsertCall) Header() http.Header {
26213 if c.header_ == nil {
26214 c.header_ = make(http.Header)
26215 }
26216 return c.header_
26217 }
26218
26219 func (c *CreativeFieldsInsertCall) doRequest(alt string) (*http.Response, error) {
26220 reqHeaders := make(http.Header)
26221 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
26222 for k, v := range c.header_ {
26223 reqHeaders[k] = v
26224 }
26225 reqHeaders.Set("User-Agent", c.s.userAgent())
26226 var body io.Reader = nil
26227 body, err := googleapi.WithoutDataWrapper.JSONReader(c.creativefield)
26228 if err != nil {
26229 return nil, err
26230 }
26231 reqHeaders.Set("Content-Type", "application/json")
26232 c.urlParams_.Set("alt", alt)
26233 c.urlParams_.Set("prettyPrint", "false")
26234 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeFields")
26235 urls += "?" + c.urlParams_.Encode()
26236 req, err := http.NewRequest("POST", urls, body)
26237 if err != nil {
26238 return nil, err
26239 }
26240 req.Header = reqHeaders
26241 googleapi.Expand(req.URL, map[string]string{
26242 "profileId": strconv.FormatInt(c.profileId, 10),
26243 })
26244 return gensupport.SendRequest(c.ctx_, c.s.client, req)
26245 }
26246
26247
26248
26249
26250
26251
26252
26253
26254 func (c *CreativeFieldsInsertCall) Do(opts ...googleapi.CallOption) (*CreativeField, error) {
26255 gensupport.SetOptions(c.urlParams_, opts...)
26256 res, err := c.doRequest("json")
26257 if res != nil && res.StatusCode == http.StatusNotModified {
26258 if res.Body != nil {
26259 res.Body.Close()
26260 }
26261 return nil, &googleapi.Error{
26262 Code: res.StatusCode,
26263 Header: res.Header,
26264 }
26265 }
26266 if err != nil {
26267 return nil, err
26268 }
26269 defer googleapi.CloseBody(res)
26270 if err := googleapi.CheckResponse(res); err != nil {
26271 return nil, err
26272 }
26273 ret := &CreativeField{
26274 ServerResponse: googleapi.ServerResponse{
26275 Header: res.Header,
26276 HTTPStatusCode: res.StatusCode,
26277 },
26278 }
26279 target := &ret
26280 if err := gensupport.DecodeResponse(target, res); err != nil {
26281 return nil, err
26282 }
26283 return ret, nil
26284
26285
26286
26287
26288
26289
26290
26291
26292
26293
26294
26295
26296
26297
26298
26299
26300
26301
26302
26303
26304
26305
26306
26307
26308
26309
26310
26311
26312 }
26313
26314
26315
26316 type CreativeFieldsListCall struct {
26317 s *Service
26318 profileId int64
26319 urlParams_ gensupport.URLParams
26320 ifNoneMatch_ string
26321 ctx_ context.Context
26322 header_ http.Header
26323 }
26324
26325
26326
26327 func (r *CreativeFieldsService) List(profileId int64) *CreativeFieldsListCall {
26328 c := &CreativeFieldsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
26329 c.profileId = profileId
26330 return c
26331 }
26332
26333
26334
26335 func (c *CreativeFieldsListCall) AdvertiserIds(advertiserIds ...int64) *CreativeFieldsListCall {
26336 var advertiserIds_ []string
26337 for _, v := range advertiserIds {
26338 advertiserIds_ = append(advertiserIds_, fmt.Sprint(v))
26339 }
26340 c.urlParams_.SetMulti("advertiserIds", advertiserIds_)
26341 return c
26342 }
26343
26344
26345
26346 func (c *CreativeFieldsListCall) Ids(ids ...int64) *CreativeFieldsListCall {
26347 var ids_ []string
26348 for _, v := range ids {
26349 ids_ = append(ids_, fmt.Sprint(v))
26350 }
26351 c.urlParams_.SetMulti("ids", ids_)
26352 return c
26353 }
26354
26355
26356
26357 func (c *CreativeFieldsListCall) MaxResults(maxResults int64) *CreativeFieldsListCall {
26358 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
26359 return c
26360 }
26361
26362
26363
26364 func (c *CreativeFieldsListCall) PageToken(pageToken string) *CreativeFieldsListCall {
26365 c.urlParams_.Set("pageToken", pageToken)
26366 return c
26367 }
26368
26369
26370
26371
26372
26373
26374
26375
26376
26377
26378 func (c *CreativeFieldsListCall) SearchString(searchString string) *CreativeFieldsListCall {
26379 c.urlParams_.Set("searchString", searchString)
26380 return c
26381 }
26382
26383
26384
26385
26386
26387
26388
26389
26390 func (c *CreativeFieldsListCall) SortField(sortField string) *CreativeFieldsListCall {
26391 c.urlParams_.Set("sortField", sortField)
26392 return c
26393 }
26394
26395
26396
26397
26398
26399
26400
26401
26402 func (c *CreativeFieldsListCall) SortOrder(sortOrder string) *CreativeFieldsListCall {
26403 c.urlParams_.Set("sortOrder", sortOrder)
26404 return c
26405 }
26406
26407
26408
26409
26410 func (c *CreativeFieldsListCall) Fields(s ...googleapi.Field) *CreativeFieldsListCall {
26411 c.urlParams_.Set("fields", googleapi.CombineFields(s))
26412 return c
26413 }
26414
26415
26416
26417
26418
26419
26420 func (c *CreativeFieldsListCall) IfNoneMatch(entityTag string) *CreativeFieldsListCall {
26421 c.ifNoneMatch_ = entityTag
26422 return c
26423 }
26424
26425
26426
26427
26428 func (c *CreativeFieldsListCall) Context(ctx context.Context) *CreativeFieldsListCall {
26429 c.ctx_ = ctx
26430 return c
26431 }
26432
26433
26434
26435 func (c *CreativeFieldsListCall) Header() http.Header {
26436 if c.header_ == nil {
26437 c.header_ = make(http.Header)
26438 }
26439 return c.header_
26440 }
26441
26442 func (c *CreativeFieldsListCall) doRequest(alt string) (*http.Response, error) {
26443 reqHeaders := make(http.Header)
26444 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
26445 for k, v := range c.header_ {
26446 reqHeaders[k] = v
26447 }
26448 reqHeaders.Set("User-Agent", c.s.userAgent())
26449 if c.ifNoneMatch_ != "" {
26450 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
26451 }
26452 var body io.Reader = nil
26453 c.urlParams_.Set("alt", alt)
26454 c.urlParams_.Set("prettyPrint", "false")
26455 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeFields")
26456 urls += "?" + c.urlParams_.Encode()
26457 req, err := http.NewRequest("GET", urls, body)
26458 if err != nil {
26459 return nil, err
26460 }
26461 req.Header = reqHeaders
26462 googleapi.Expand(req.URL, map[string]string{
26463 "profileId": strconv.FormatInt(c.profileId, 10),
26464 })
26465 return gensupport.SendRequest(c.ctx_, c.s.client, req)
26466 }
26467
26468
26469
26470
26471
26472
26473
26474
26475 func (c *CreativeFieldsListCall) Do(opts ...googleapi.CallOption) (*CreativeFieldsListResponse, error) {
26476 gensupport.SetOptions(c.urlParams_, opts...)
26477 res, err := c.doRequest("json")
26478 if res != nil && res.StatusCode == http.StatusNotModified {
26479 if res.Body != nil {
26480 res.Body.Close()
26481 }
26482 return nil, &googleapi.Error{
26483 Code: res.StatusCode,
26484 Header: res.Header,
26485 }
26486 }
26487 if err != nil {
26488 return nil, err
26489 }
26490 defer googleapi.CloseBody(res)
26491 if err := googleapi.CheckResponse(res); err != nil {
26492 return nil, err
26493 }
26494 ret := &CreativeFieldsListResponse{
26495 ServerResponse: googleapi.ServerResponse{
26496 Header: res.Header,
26497 HTTPStatusCode: res.StatusCode,
26498 },
26499 }
26500 target := &ret
26501 if err := gensupport.DecodeResponse(target, res); err != nil {
26502 return nil, err
26503 }
26504 return ret, nil
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
26530
26531
26532
26533
26534
26535
26536
26537
26538
26539
26540
26541
26542
26543
26544
26545
26546
26547
26548
26549
26550
26551
26552
26553
26554
26555
26556
26557
26558
26559
26560
26561
26562
26563
26564
26565
26566
26567
26568
26569
26570
26571
26572
26573
26574
26575
26576
26577
26578
26579
26580
26581
26582
26583
26584
26585
26586
26587
26588
26589
26590
26591 }
26592
26593
26594
26595
26596 func (c *CreativeFieldsListCall) Pages(ctx context.Context, f func(*CreativeFieldsListResponse) error) error {
26597 c.ctx_ = ctx
26598 defer c.PageToken(c.urlParams_.Get("pageToken"))
26599 for {
26600 x, err := c.Do()
26601 if err != nil {
26602 return err
26603 }
26604 if err := f(x); err != nil {
26605 return err
26606 }
26607 if x.NextPageToken == "" {
26608 return nil
26609 }
26610 c.PageToken(x.NextPageToken)
26611 }
26612 }
26613
26614
26615
26616 type CreativeFieldsPatchCall struct {
26617 s *Service
26618 profileId int64
26619 creativefield *CreativeField
26620 urlParams_ gensupport.URLParams
26621 ctx_ context.Context
26622 header_ http.Header
26623 }
26624
26625
26626
26627 func (r *CreativeFieldsService) Patch(profileId int64, id int64, creativefield *CreativeField) *CreativeFieldsPatchCall {
26628 c := &CreativeFieldsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
26629 c.profileId = profileId
26630 c.urlParams_.Set("id", fmt.Sprint(id))
26631 c.creativefield = creativefield
26632 return c
26633 }
26634
26635
26636
26637
26638 func (c *CreativeFieldsPatchCall) Fields(s ...googleapi.Field) *CreativeFieldsPatchCall {
26639 c.urlParams_.Set("fields", googleapi.CombineFields(s))
26640 return c
26641 }
26642
26643
26644
26645
26646 func (c *CreativeFieldsPatchCall) Context(ctx context.Context) *CreativeFieldsPatchCall {
26647 c.ctx_ = ctx
26648 return c
26649 }
26650
26651
26652
26653 func (c *CreativeFieldsPatchCall) Header() http.Header {
26654 if c.header_ == nil {
26655 c.header_ = make(http.Header)
26656 }
26657 return c.header_
26658 }
26659
26660 func (c *CreativeFieldsPatchCall) doRequest(alt string) (*http.Response, error) {
26661 reqHeaders := make(http.Header)
26662 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
26663 for k, v := range c.header_ {
26664 reqHeaders[k] = v
26665 }
26666 reqHeaders.Set("User-Agent", c.s.userAgent())
26667 var body io.Reader = nil
26668 body, err := googleapi.WithoutDataWrapper.JSONReader(c.creativefield)
26669 if err != nil {
26670 return nil, err
26671 }
26672 reqHeaders.Set("Content-Type", "application/json")
26673 c.urlParams_.Set("alt", alt)
26674 c.urlParams_.Set("prettyPrint", "false")
26675 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeFields")
26676 urls += "?" + c.urlParams_.Encode()
26677 req, err := http.NewRequest("PATCH", urls, body)
26678 if err != nil {
26679 return nil, err
26680 }
26681 req.Header = reqHeaders
26682 googleapi.Expand(req.URL, map[string]string{
26683 "profileId": strconv.FormatInt(c.profileId, 10),
26684 })
26685 return gensupport.SendRequest(c.ctx_, c.s.client, req)
26686 }
26687
26688
26689
26690
26691
26692
26693
26694
26695 func (c *CreativeFieldsPatchCall) Do(opts ...googleapi.CallOption) (*CreativeField, error) {
26696 gensupport.SetOptions(c.urlParams_, opts...)
26697 res, err := c.doRequest("json")
26698 if res != nil && res.StatusCode == http.StatusNotModified {
26699 if res.Body != nil {
26700 res.Body.Close()
26701 }
26702 return nil, &googleapi.Error{
26703 Code: res.StatusCode,
26704 Header: res.Header,
26705 }
26706 }
26707 if err != nil {
26708 return nil, err
26709 }
26710 defer googleapi.CloseBody(res)
26711 if err := googleapi.CheckResponse(res); err != nil {
26712 return nil, err
26713 }
26714 ret := &CreativeField{
26715 ServerResponse: googleapi.ServerResponse{
26716 Header: res.Header,
26717 HTTPStatusCode: res.StatusCode,
26718 },
26719 }
26720 target := &ret
26721 if err := gensupport.DecodeResponse(target, res); err != nil {
26722 return nil, err
26723 }
26724 return ret, nil
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 type CreativeFieldsUpdateCall struct {
26766 s *Service
26767 profileId int64
26768 creativefield *CreativeField
26769 urlParams_ gensupport.URLParams
26770 ctx_ context.Context
26771 header_ http.Header
26772 }
26773
26774
26775 func (r *CreativeFieldsService) Update(profileId int64, creativefield *CreativeField) *CreativeFieldsUpdateCall {
26776 c := &CreativeFieldsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
26777 c.profileId = profileId
26778 c.creativefield = creativefield
26779 return c
26780 }
26781
26782
26783
26784
26785 func (c *CreativeFieldsUpdateCall) Fields(s ...googleapi.Field) *CreativeFieldsUpdateCall {
26786 c.urlParams_.Set("fields", googleapi.CombineFields(s))
26787 return c
26788 }
26789
26790
26791
26792
26793 func (c *CreativeFieldsUpdateCall) Context(ctx context.Context) *CreativeFieldsUpdateCall {
26794 c.ctx_ = ctx
26795 return c
26796 }
26797
26798
26799
26800 func (c *CreativeFieldsUpdateCall) Header() http.Header {
26801 if c.header_ == nil {
26802 c.header_ = make(http.Header)
26803 }
26804 return c.header_
26805 }
26806
26807 func (c *CreativeFieldsUpdateCall) doRequest(alt string) (*http.Response, error) {
26808 reqHeaders := make(http.Header)
26809 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
26810 for k, v := range c.header_ {
26811 reqHeaders[k] = v
26812 }
26813 reqHeaders.Set("User-Agent", c.s.userAgent())
26814 var body io.Reader = nil
26815 body, err := googleapi.WithoutDataWrapper.JSONReader(c.creativefield)
26816 if err != nil {
26817 return nil, err
26818 }
26819 reqHeaders.Set("Content-Type", "application/json")
26820 c.urlParams_.Set("alt", alt)
26821 c.urlParams_.Set("prettyPrint", "false")
26822 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeFields")
26823 urls += "?" + c.urlParams_.Encode()
26824 req, err := http.NewRequest("PUT", urls, body)
26825 if err != nil {
26826 return nil, err
26827 }
26828 req.Header = reqHeaders
26829 googleapi.Expand(req.URL, map[string]string{
26830 "profileId": strconv.FormatInt(c.profileId, 10),
26831 })
26832 return gensupport.SendRequest(c.ctx_, c.s.client, req)
26833 }
26834
26835
26836
26837
26838
26839
26840
26841
26842 func (c *CreativeFieldsUpdateCall) Do(opts ...googleapi.CallOption) (*CreativeField, error) {
26843 gensupport.SetOptions(c.urlParams_, opts...)
26844 res, err := c.doRequest("json")
26845 if res != nil && res.StatusCode == http.StatusNotModified {
26846 if res.Body != nil {
26847 res.Body.Close()
26848 }
26849 return nil, &googleapi.Error{
26850 Code: res.StatusCode,
26851 Header: res.Header,
26852 }
26853 }
26854 if err != nil {
26855 return nil, err
26856 }
26857 defer googleapi.CloseBody(res)
26858 if err := googleapi.CheckResponse(res); err != nil {
26859 return nil, err
26860 }
26861 ret := &CreativeField{
26862 ServerResponse: googleapi.ServerResponse{
26863 Header: res.Header,
26864 HTTPStatusCode: res.StatusCode,
26865 },
26866 }
26867 target := &ret
26868 if err := gensupport.DecodeResponse(target, res); err != nil {
26869 return nil, err
26870 }
26871 return ret, nil
26872
26873
26874
26875
26876
26877
26878
26879
26880
26881
26882
26883
26884
26885
26886
26887
26888
26889
26890
26891
26892
26893
26894
26895
26896
26897
26898
26899
26900 }
26901
26902
26903
26904 type CreativeGroupsGetCall struct {
26905 s *Service
26906 profileId int64
26907 id int64
26908 urlParams_ gensupport.URLParams
26909 ifNoneMatch_ string
26910 ctx_ context.Context
26911 header_ http.Header
26912 }
26913
26914
26915 func (r *CreativeGroupsService) Get(profileId int64, id int64) *CreativeGroupsGetCall {
26916 c := &CreativeGroupsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
26917 c.profileId = profileId
26918 c.id = id
26919 return c
26920 }
26921
26922
26923
26924
26925 func (c *CreativeGroupsGetCall) Fields(s ...googleapi.Field) *CreativeGroupsGetCall {
26926 c.urlParams_.Set("fields", googleapi.CombineFields(s))
26927 return c
26928 }
26929
26930
26931
26932
26933
26934
26935 func (c *CreativeGroupsGetCall) IfNoneMatch(entityTag string) *CreativeGroupsGetCall {
26936 c.ifNoneMatch_ = entityTag
26937 return c
26938 }
26939
26940
26941
26942
26943 func (c *CreativeGroupsGetCall) Context(ctx context.Context) *CreativeGroupsGetCall {
26944 c.ctx_ = ctx
26945 return c
26946 }
26947
26948
26949
26950 func (c *CreativeGroupsGetCall) Header() http.Header {
26951 if c.header_ == nil {
26952 c.header_ = make(http.Header)
26953 }
26954 return c.header_
26955 }
26956
26957 func (c *CreativeGroupsGetCall) doRequest(alt string) (*http.Response, error) {
26958 reqHeaders := make(http.Header)
26959 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
26960 for k, v := range c.header_ {
26961 reqHeaders[k] = v
26962 }
26963 reqHeaders.Set("User-Agent", c.s.userAgent())
26964 if c.ifNoneMatch_ != "" {
26965 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
26966 }
26967 var body io.Reader = nil
26968 c.urlParams_.Set("alt", alt)
26969 c.urlParams_.Set("prettyPrint", "false")
26970 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeGroups/{id}")
26971 urls += "?" + c.urlParams_.Encode()
26972 req, err := http.NewRequest("GET", urls, body)
26973 if err != nil {
26974 return nil, err
26975 }
26976 req.Header = reqHeaders
26977 googleapi.Expand(req.URL, map[string]string{
26978 "profileId": strconv.FormatInt(c.profileId, 10),
26979 "id": strconv.FormatInt(c.id, 10),
26980 })
26981 return gensupport.SendRequest(c.ctx_, c.s.client, req)
26982 }
26983
26984
26985
26986
26987
26988
26989
26990
26991 func (c *CreativeGroupsGetCall) Do(opts ...googleapi.CallOption) (*CreativeGroup, error) {
26992 gensupport.SetOptions(c.urlParams_, opts...)
26993 res, err := c.doRequest("json")
26994 if res != nil && res.StatusCode == http.StatusNotModified {
26995 if res.Body != nil {
26996 res.Body.Close()
26997 }
26998 return nil, &googleapi.Error{
26999 Code: res.StatusCode,
27000 Header: res.Header,
27001 }
27002 }
27003 if err != nil {
27004 return nil, err
27005 }
27006 defer googleapi.CloseBody(res)
27007 if err := googleapi.CheckResponse(res); err != nil {
27008 return nil, err
27009 }
27010 ret := &CreativeGroup{
27011 ServerResponse: googleapi.ServerResponse{
27012 Header: res.Header,
27013 HTTPStatusCode: res.StatusCode,
27014 },
27015 }
27016 target := &ret
27017 if err := gensupport.DecodeResponse(target, res); err != nil {
27018 return nil, err
27019 }
27020 return ret, nil
27021
27022
27023
27024
27025
27026
27027
27028
27029
27030
27031
27032
27033
27034
27035
27036
27037
27038
27039
27040
27041
27042
27043
27044
27045
27046
27047
27048
27049
27050
27051
27052
27053
27054 }
27055
27056
27057
27058 type CreativeGroupsInsertCall struct {
27059 s *Service
27060 profileId int64
27061 creativegroup *CreativeGroup
27062 urlParams_ gensupport.URLParams
27063 ctx_ context.Context
27064 header_ http.Header
27065 }
27066
27067
27068 func (r *CreativeGroupsService) Insert(profileId int64, creativegroup *CreativeGroup) *CreativeGroupsInsertCall {
27069 c := &CreativeGroupsInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
27070 c.profileId = profileId
27071 c.creativegroup = creativegroup
27072 return c
27073 }
27074
27075
27076
27077
27078 func (c *CreativeGroupsInsertCall) Fields(s ...googleapi.Field) *CreativeGroupsInsertCall {
27079 c.urlParams_.Set("fields", googleapi.CombineFields(s))
27080 return c
27081 }
27082
27083
27084
27085
27086 func (c *CreativeGroupsInsertCall) Context(ctx context.Context) *CreativeGroupsInsertCall {
27087 c.ctx_ = ctx
27088 return c
27089 }
27090
27091
27092
27093 func (c *CreativeGroupsInsertCall) Header() http.Header {
27094 if c.header_ == nil {
27095 c.header_ = make(http.Header)
27096 }
27097 return c.header_
27098 }
27099
27100 func (c *CreativeGroupsInsertCall) doRequest(alt string) (*http.Response, error) {
27101 reqHeaders := make(http.Header)
27102 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
27103 for k, v := range c.header_ {
27104 reqHeaders[k] = v
27105 }
27106 reqHeaders.Set("User-Agent", c.s.userAgent())
27107 var body io.Reader = nil
27108 body, err := googleapi.WithoutDataWrapper.JSONReader(c.creativegroup)
27109 if err != nil {
27110 return nil, err
27111 }
27112 reqHeaders.Set("Content-Type", "application/json")
27113 c.urlParams_.Set("alt", alt)
27114 c.urlParams_.Set("prettyPrint", "false")
27115 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeGroups")
27116 urls += "?" + c.urlParams_.Encode()
27117 req, err := http.NewRequest("POST", urls, body)
27118 if err != nil {
27119 return nil, err
27120 }
27121 req.Header = reqHeaders
27122 googleapi.Expand(req.URL, map[string]string{
27123 "profileId": strconv.FormatInt(c.profileId, 10),
27124 })
27125 return gensupport.SendRequest(c.ctx_, c.s.client, req)
27126 }
27127
27128
27129
27130
27131
27132
27133
27134
27135 func (c *CreativeGroupsInsertCall) Do(opts ...googleapi.CallOption) (*CreativeGroup, error) {
27136 gensupport.SetOptions(c.urlParams_, opts...)
27137 res, err := c.doRequest("json")
27138 if res != nil && res.StatusCode == http.StatusNotModified {
27139 if res.Body != nil {
27140 res.Body.Close()
27141 }
27142 return nil, &googleapi.Error{
27143 Code: res.StatusCode,
27144 Header: res.Header,
27145 }
27146 }
27147 if err != nil {
27148 return nil, err
27149 }
27150 defer googleapi.CloseBody(res)
27151 if err := googleapi.CheckResponse(res); err != nil {
27152 return nil, err
27153 }
27154 ret := &CreativeGroup{
27155 ServerResponse: googleapi.ServerResponse{
27156 Header: res.Header,
27157 HTTPStatusCode: res.StatusCode,
27158 },
27159 }
27160 target := &ret
27161 if err := gensupport.DecodeResponse(target, res); err != nil {
27162 return nil, err
27163 }
27164 return ret, nil
27165
27166
27167
27168
27169
27170
27171
27172
27173
27174
27175
27176
27177
27178
27179
27180
27181
27182
27183
27184
27185
27186
27187
27188
27189
27190
27191
27192
27193 }
27194
27195
27196
27197 type CreativeGroupsListCall struct {
27198 s *Service
27199 profileId int64
27200 urlParams_ gensupport.URLParams
27201 ifNoneMatch_ string
27202 ctx_ context.Context
27203 header_ http.Header
27204 }
27205
27206
27207
27208 func (r *CreativeGroupsService) List(profileId int64) *CreativeGroupsListCall {
27209 c := &CreativeGroupsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
27210 c.profileId = profileId
27211 return c
27212 }
27213
27214
27215
27216 func (c *CreativeGroupsListCall) AdvertiserIds(advertiserIds ...int64) *CreativeGroupsListCall {
27217 var advertiserIds_ []string
27218 for _, v := range advertiserIds {
27219 advertiserIds_ = append(advertiserIds_, fmt.Sprint(v))
27220 }
27221 c.urlParams_.SetMulti("advertiserIds", advertiserIds_)
27222 return c
27223 }
27224
27225
27226
27227 func (c *CreativeGroupsListCall) GroupNumber(groupNumber int64) *CreativeGroupsListCall {
27228 c.urlParams_.Set("groupNumber", fmt.Sprint(groupNumber))
27229 return c
27230 }
27231
27232
27233
27234 func (c *CreativeGroupsListCall) Ids(ids ...int64) *CreativeGroupsListCall {
27235 var ids_ []string
27236 for _, v := range ids {
27237 ids_ = append(ids_, fmt.Sprint(v))
27238 }
27239 c.urlParams_.SetMulti("ids", ids_)
27240 return c
27241 }
27242
27243
27244
27245 func (c *CreativeGroupsListCall) MaxResults(maxResults int64) *CreativeGroupsListCall {
27246 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
27247 return c
27248 }
27249
27250
27251
27252 func (c *CreativeGroupsListCall) PageToken(pageToken string) *CreativeGroupsListCall {
27253 c.urlParams_.Set("pageToken", pageToken)
27254 return c
27255 }
27256
27257
27258
27259
27260
27261
27262
27263
27264
27265
27266 func (c *CreativeGroupsListCall) SearchString(searchString string) *CreativeGroupsListCall {
27267 c.urlParams_.Set("searchString", searchString)
27268 return c
27269 }
27270
27271
27272
27273
27274
27275
27276
27277
27278 func (c *CreativeGroupsListCall) SortField(sortField string) *CreativeGroupsListCall {
27279 c.urlParams_.Set("sortField", sortField)
27280 return c
27281 }
27282
27283
27284
27285
27286
27287
27288
27289
27290 func (c *CreativeGroupsListCall) SortOrder(sortOrder string) *CreativeGroupsListCall {
27291 c.urlParams_.Set("sortOrder", sortOrder)
27292 return c
27293 }
27294
27295
27296
27297
27298 func (c *CreativeGroupsListCall) Fields(s ...googleapi.Field) *CreativeGroupsListCall {
27299 c.urlParams_.Set("fields", googleapi.CombineFields(s))
27300 return c
27301 }
27302
27303
27304
27305
27306
27307
27308 func (c *CreativeGroupsListCall) IfNoneMatch(entityTag string) *CreativeGroupsListCall {
27309 c.ifNoneMatch_ = entityTag
27310 return c
27311 }
27312
27313
27314
27315
27316 func (c *CreativeGroupsListCall) Context(ctx context.Context) *CreativeGroupsListCall {
27317 c.ctx_ = ctx
27318 return c
27319 }
27320
27321
27322
27323 func (c *CreativeGroupsListCall) Header() http.Header {
27324 if c.header_ == nil {
27325 c.header_ = make(http.Header)
27326 }
27327 return c.header_
27328 }
27329
27330 func (c *CreativeGroupsListCall) doRequest(alt string) (*http.Response, error) {
27331 reqHeaders := make(http.Header)
27332 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
27333 for k, v := range c.header_ {
27334 reqHeaders[k] = v
27335 }
27336 reqHeaders.Set("User-Agent", c.s.userAgent())
27337 if c.ifNoneMatch_ != "" {
27338 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
27339 }
27340 var body io.Reader = nil
27341 c.urlParams_.Set("alt", alt)
27342 c.urlParams_.Set("prettyPrint", "false")
27343 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeGroups")
27344 urls += "?" + c.urlParams_.Encode()
27345 req, err := http.NewRequest("GET", urls, body)
27346 if err != nil {
27347 return nil, err
27348 }
27349 req.Header = reqHeaders
27350 googleapi.Expand(req.URL, map[string]string{
27351 "profileId": strconv.FormatInt(c.profileId, 10),
27352 })
27353 return gensupport.SendRequest(c.ctx_, c.s.client, req)
27354 }
27355
27356
27357
27358
27359
27360
27361
27362
27363 func (c *CreativeGroupsListCall) Do(opts ...googleapi.CallOption) (*CreativeGroupsListResponse, error) {
27364 gensupport.SetOptions(c.urlParams_, opts...)
27365 res, err := c.doRequest("json")
27366 if res != nil && res.StatusCode == http.StatusNotModified {
27367 if res.Body != nil {
27368 res.Body.Close()
27369 }
27370 return nil, &googleapi.Error{
27371 Code: res.StatusCode,
27372 Header: res.Header,
27373 }
27374 }
27375 if err != nil {
27376 return nil, err
27377 }
27378 defer googleapi.CloseBody(res)
27379 if err := googleapi.CheckResponse(res); err != nil {
27380 return nil, err
27381 }
27382 ret := &CreativeGroupsListResponse{
27383 ServerResponse: googleapi.ServerResponse{
27384 Header: res.Header,
27385 HTTPStatusCode: res.StatusCode,
27386 },
27387 }
27388 target := &ret
27389 if err := gensupport.DecodeResponse(target, res); err != nil {
27390 return nil, err
27391 }
27392 return ret, nil
27393
27394
27395
27396
27397
27398
27399
27400
27401
27402
27403
27404
27405
27406
27407
27408
27409
27410
27411
27412
27413
27414
27415
27416
27417
27418
27419
27420
27421
27422
27423
27424
27425
27426
27427
27428
27429
27430
27431
27432
27433
27434
27435
27436
27437
27438
27439
27440
27441
27442
27443
27444
27445
27446
27447
27448
27449
27450
27451
27452
27453
27454
27455
27456
27457
27458
27459
27460
27461
27462
27463
27464
27465
27466
27467
27468
27469
27470
27471
27472
27473
27474
27475
27476
27477
27478
27479
27480
27481
27482
27483
27484
27485
27486
27487 }
27488
27489
27490
27491
27492 func (c *CreativeGroupsListCall) Pages(ctx context.Context, f func(*CreativeGroupsListResponse) error) error {
27493 c.ctx_ = ctx
27494 defer c.PageToken(c.urlParams_.Get("pageToken"))
27495 for {
27496 x, err := c.Do()
27497 if err != nil {
27498 return err
27499 }
27500 if err := f(x); err != nil {
27501 return err
27502 }
27503 if x.NextPageToken == "" {
27504 return nil
27505 }
27506 c.PageToken(x.NextPageToken)
27507 }
27508 }
27509
27510
27511
27512 type CreativeGroupsPatchCall struct {
27513 s *Service
27514 profileId int64
27515 creativegroup *CreativeGroup
27516 urlParams_ gensupport.URLParams
27517 ctx_ context.Context
27518 header_ http.Header
27519 }
27520
27521
27522
27523 func (r *CreativeGroupsService) Patch(profileId int64, id int64, creativegroup *CreativeGroup) *CreativeGroupsPatchCall {
27524 c := &CreativeGroupsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
27525 c.profileId = profileId
27526 c.urlParams_.Set("id", fmt.Sprint(id))
27527 c.creativegroup = creativegroup
27528 return c
27529 }
27530
27531
27532
27533
27534 func (c *CreativeGroupsPatchCall) Fields(s ...googleapi.Field) *CreativeGroupsPatchCall {
27535 c.urlParams_.Set("fields", googleapi.CombineFields(s))
27536 return c
27537 }
27538
27539
27540
27541
27542 func (c *CreativeGroupsPatchCall) Context(ctx context.Context) *CreativeGroupsPatchCall {
27543 c.ctx_ = ctx
27544 return c
27545 }
27546
27547
27548
27549 func (c *CreativeGroupsPatchCall) Header() http.Header {
27550 if c.header_ == nil {
27551 c.header_ = make(http.Header)
27552 }
27553 return c.header_
27554 }
27555
27556 func (c *CreativeGroupsPatchCall) doRequest(alt string) (*http.Response, error) {
27557 reqHeaders := make(http.Header)
27558 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
27559 for k, v := range c.header_ {
27560 reqHeaders[k] = v
27561 }
27562 reqHeaders.Set("User-Agent", c.s.userAgent())
27563 var body io.Reader = nil
27564 body, err := googleapi.WithoutDataWrapper.JSONReader(c.creativegroup)
27565 if err != nil {
27566 return nil, err
27567 }
27568 reqHeaders.Set("Content-Type", "application/json")
27569 c.urlParams_.Set("alt", alt)
27570 c.urlParams_.Set("prettyPrint", "false")
27571 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeGroups")
27572 urls += "?" + c.urlParams_.Encode()
27573 req, err := http.NewRequest("PATCH", urls, body)
27574 if err != nil {
27575 return nil, err
27576 }
27577 req.Header = reqHeaders
27578 googleapi.Expand(req.URL, map[string]string{
27579 "profileId": strconv.FormatInt(c.profileId, 10),
27580 })
27581 return gensupport.SendRequest(c.ctx_, c.s.client, req)
27582 }
27583
27584
27585
27586
27587
27588
27589
27590
27591 func (c *CreativeGroupsPatchCall) Do(opts ...googleapi.CallOption) (*CreativeGroup, error) {
27592 gensupport.SetOptions(c.urlParams_, opts...)
27593 res, err := c.doRequest("json")
27594 if res != nil && res.StatusCode == http.StatusNotModified {
27595 if res.Body != nil {
27596 res.Body.Close()
27597 }
27598 return nil, &googleapi.Error{
27599 Code: res.StatusCode,
27600 Header: res.Header,
27601 }
27602 }
27603 if err != nil {
27604 return nil, err
27605 }
27606 defer googleapi.CloseBody(res)
27607 if err := googleapi.CheckResponse(res); err != nil {
27608 return nil, err
27609 }
27610 ret := &CreativeGroup{
27611 ServerResponse: googleapi.ServerResponse{
27612 Header: res.Header,
27613 HTTPStatusCode: res.StatusCode,
27614 },
27615 }
27616 target := &ret
27617 if err := gensupport.DecodeResponse(target, res); err != nil {
27618 return nil, err
27619 }
27620 return ret, nil
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 type CreativeGroupsUpdateCall struct {
27662 s *Service
27663 profileId int64
27664 creativegroup *CreativeGroup
27665 urlParams_ gensupport.URLParams
27666 ctx_ context.Context
27667 header_ http.Header
27668 }
27669
27670
27671 func (r *CreativeGroupsService) Update(profileId int64, creativegroup *CreativeGroup) *CreativeGroupsUpdateCall {
27672 c := &CreativeGroupsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
27673 c.profileId = profileId
27674 c.creativegroup = creativegroup
27675 return c
27676 }
27677
27678
27679
27680
27681 func (c *CreativeGroupsUpdateCall) Fields(s ...googleapi.Field) *CreativeGroupsUpdateCall {
27682 c.urlParams_.Set("fields", googleapi.CombineFields(s))
27683 return c
27684 }
27685
27686
27687
27688
27689 func (c *CreativeGroupsUpdateCall) Context(ctx context.Context) *CreativeGroupsUpdateCall {
27690 c.ctx_ = ctx
27691 return c
27692 }
27693
27694
27695
27696 func (c *CreativeGroupsUpdateCall) Header() http.Header {
27697 if c.header_ == nil {
27698 c.header_ = make(http.Header)
27699 }
27700 return c.header_
27701 }
27702
27703 func (c *CreativeGroupsUpdateCall) doRequest(alt string) (*http.Response, error) {
27704 reqHeaders := make(http.Header)
27705 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
27706 for k, v := range c.header_ {
27707 reqHeaders[k] = v
27708 }
27709 reqHeaders.Set("User-Agent", c.s.userAgent())
27710 var body io.Reader = nil
27711 body, err := googleapi.WithoutDataWrapper.JSONReader(c.creativegroup)
27712 if err != nil {
27713 return nil, err
27714 }
27715 reqHeaders.Set("Content-Type", "application/json")
27716 c.urlParams_.Set("alt", alt)
27717 c.urlParams_.Set("prettyPrint", "false")
27718 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeGroups")
27719 urls += "?" + c.urlParams_.Encode()
27720 req, err := http.NewRequest("PUT", urls, body)
27721 if err != nil {
27722 return nil, err
27723 }
27724 req.Header = reqHeaders
27725 googleapi.Expand(req.URL, map[string]string{
27726 "profileId": strconv.FormatInt(c.profileId, 10),
27727 })
27728 return gensupport.SendRequest(c.ctx_, c.s.client, req)
27729 }
27730
27731
27732
27733
27734
27735
27736
27737
27738 func (c *CreativeGroupsUpdateCall) Do(opts ...googleapi.CallOption) (*CreativeGroup, error) {
27739 gensupport.SetOptions(c.urlParams_, opts...)
27740 res, err := c.doRequest("json")
27741 if res != nil && res.StatusCode == http.StatusNotModified {
27742 if res.Body != nil {
27743 res.Body.Close()
27744 }
27745 return nil, &googleapi.Error{
27746 Code: res.StatusCode,
27747 Header: res.Header,
27748 }
27749 }
27750 if err != nil {
27751 return nil, err
27752 }
27753 defer googleapi.CloseBody(res)
27754 if err := googleapi.CheckResponse(res); err != nil {
27755 return nil, err
27756 }
27757 ret := &CreativeGroup{
27758 ServerResponse: googleapi.ServerResponse{
27759 Header: res.Header,
27760 HTTPStatusCode: res.StatusCode,
27761 },
27762 }
27763 target := &ret
27764 if err := gensupport.DecodeResponse(target, res); err != nil {
27765 return nil, err
27766 }
27767 return ret, nil
27768
27769
27770
27771
27772
27773
27774
27775
27776
27777
27778
27779
27780
27781
27782
27783
27784
27785
27786
27787
27788
27789
27790
27791
27792
27793
27794
27795
27796 }
27797
27798
27799
27800 type CreativesGetCall struct {
27801 s *Service
27802 profileId int64
27803 id int64
27804 urlParams_ gensupport.URLParams
27805 ifNoneMatch_ string
27806 ctx_ context.Context
27807 header_ http.Header
27808 }
27809
27810
27811 func (r *CreativesService) Get(profileId int64, id int64) *CreativesGetCall {
27812 c := &CreativesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
27813 c.profileId = profileId
27814 c.id = id
27815 return c
27816 }
27817
27818
27819
27820
27821 func (c *CreativesGetCall) Fields(s ...googleapi.Field) *CreativesGetCall {
27822 c.urlParams_.Set("fields", googleapi.CombineFields(s))
27823 return c
27824 }
27825
27826
27827
27828
27829
27830
27831 func (c *CreativesGetCall) IfNoneMatch(entityTag string) *CreativesGetCall {
27832 c.ifNoneMatch_ = entityTag
27833 return c
27834 }
27835
27836
27837
27838
27839 func (c *CreativesGetCall) Context(ctx context.Context) *CreativesGetCall {
27840 c.ctx_ = ctx
27841 return c
27842 }
27843
27844
27845
27846 func (c *CreativesGetCall) Header() http.Header {
27847 if c.header_ == nil {
27848 c.header_ = make(http.Header)
27849 }
27850 return c.header_
27851 }
27852
27853 func (c *CreativesGetCall) doRequest(alt string) (*http.Response, error) {
27854 reqHeaders := make(http.Header)
27855 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
27856 for k, v := range c.header_ {
27857 reqHeaders[k] = v
27858 }
27859 reqHeaders.Set("User-Agent", c.s.userAgent())
27860 if c.ifNoneMatch_ != "" {
27861 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
27862 }
27863 var body io.Reader = nil
27864 c.urlParams_.Set("alt", alt)
27865 c.urlParams_.Set("prettyPrint", "false")
27866 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creatives/{id}")
27867 urls += "?" + c.urlParams_.Encode()
27868 req, err := http.NewRequest("GET", urls, body)
27869 if err != nil {
27870 return nil, err
27871 }
27872 req.Header = reqHeaders
27873 googleapi.Expand(req.URL, map[string]string{
27874 "profileId": strconv.FormatInt(c.profileId, 10),
27875 "id": strconv.FormatInt(c.id, 10),
27876 })
27877 return gensupport.SendRequest(c.ctx_, c.s.client, req)
27878 }
27879
27880
27881
27882
27883
27884
27885
27886
27887 func (c *CreativesGetCall) Do(opts ...googleapi.CallOption) (*Creative, error) {
27888 gensupport.SetOptions(c.urlParams_, opts...)
27889 res, err := c.doRequest("json")
27890 if res != nil && res.StatusCode == http.StatusNotModified {
27891 if res.Body != nil {
27892 res.Body.Close()
27893 }
27894 return nil, &googleapi.Error{
27895 Code: res.StatusCode,
27896 Header: res.Header,
27897 }
27898 }
27899 if err != nil {
27900 return nil, err
27901 }
27902 defer googleapi.CloseBody(res)
27903 if err := googleapi.CheckResponse(res); err != nil {
27904 return nil, err
27905 }
27906 ret := &Creative{
27907 ServerResponse: googleapi.ServerResponse{
27908 Header: res.Header,
27909 HTTPStatusCode: res.StatusCode,
27910 },
27911 }
27912 target := &ret
27913 if err := gensupport.DecodeResponse(target, res); err != nil {
27914 return nil, err
27915 }
27916 return ret, nil
27917
27918
27919
27920
27921
27922
27923
27924
27925
27926
27927
27928
27929
27930
27931
27932
27933
27934
27935
27936
27937
27938
27939
27940
27941
27942
27943
27944
27945
27946
27947
27948
27949
27950 }
27951
27952
27953
27954 type CreativesInsertCall struct {
27955 s *Service
27956 profileId int64
27957 creative *Creative
27958 urlParams_ gensupport.URLParams
27959 ctx_ context.Context
27960 header_ http.Header
27961 }
27962
27963
27964 func (r *CreativesService) Insert(profileId int64, creative *Creative) *CreativesInsertCall {
27965 c := &CreativesInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
27966 c.profileId = profileId
27967 c.creative = creative
27968 return c
27969 }
27970
27971
27972
27973
27974 func (c *CreativesInsertCall) Fields(s ...googleapi.Field) *CreativesInsertCall {
27975 c.urlParams_.Set("fields", googleapi.CombineFields(s))
27976 return c
27977 }
27978
27979
27980
27981
27982 func (c *CreativesInsertCall) Context(ctx context.Context) *CreativesInsertCall {
27983 c.ctx_ = ctx
27984 return c
27985 }
27986
27987
27988
27989 func (c *CreativesInsertCall) Header() http.Header {
27990 if c.header_ == nil {
27991 c.header_ = make(http.Header)
27992 }
27993 return c.header_
27994 }
27995
27996 func (c *CreativesInsertCall) doRequest(alt string) (*http.Response, error) {
27997 reqHeaders := make(http.Header)
27998 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
27999 for k, v := range c.header_ {
28000 reqHeaders[k] = v
28001 }
28002 reqHeaders.Set("User-Agent", c.s.userAgent())
28003 var body io.Reader = nil
28004 body, err := googleapi.WithoutDataWrapper.JSONReader(c.creative)
28005 if err != nil {
28006 return nil, err
28007 }
28008 reqHeaders.Set("Content-Type", "application/json")
28009 c.urlParams_.Set("alt", alt)
28010 c.urlParams_.Set("prettyPrint", "false")
28011 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creatives")
28012 urls += "?" + c.urlParams_.Encode()
28013 req, err := http.NewRequest("POST", urls, body)
28014 if err != nil {
28015 return nil, err
28016 }
28017 req.Header = reqHeaders
28018 googleapi.Expand(req.URL, map[string]string{
28019 "profileId": strconv.FormatInt(c.profileId, 10),
28020 })
28021 return gensupport.SendRequest(c.ctx_, c.s.client, req)
28022 }
28023
28024
28025
28026
28027
28028
28029
28030
28031 func (c *CreativesInsertCall) Do(opts ...googleapi.CallOption) (*Creative, error) {
28032 gensupport.SetOptions(c.urlParams_, opts...)
28033 res, err := c.doRequest("json")
28034 if res != nil && res.StatusCode == http.StatusNotModified {
28035 if res.Body != nil {
28036 res.Body.Close()
28037 }
28038 return nil, &googleapi.Error{
28039 Code: res.StatusCode,
28040 Header: res.Header,
28041 }
28042 }
28043 if err != nil {
28044 return nil, err
28045 }
28046 defer googleapi.CloseBody(res)
28047 if err := googleapi.CheckResponse(res); err != nil {
28048 return nil, err
28049 }
28050 ret := &Creative{
28051 ServerResponse: googleapi.ServerResponse{
28052 Header: res.Header,
28053 HTTPStatusCode: res.StatusCode,
28054 },
28055 }
28056 target := &ret
28057 if err := gensupport.DecodeResponse(target, res); err != nil {
28058 return nil, err
28059 }
28060 return ret, nil
28061
28062
28063
28064
28065
28066
28067
28068
28069
28070
28071
28072
28073
28074
28075
28076
28077
28078
28079
28080
28081
28082
28083
28084
28085
28086
28087
28088
28089 }
28090
28091
28092
28093 type CreativesListCall struct {
28094 s *Service
28095 profileId int64
28096 urlParams_ gensupport.URLParams
28097 ifNoneMatch_ string
28098 ctx_ context.Context
28099 header_ http.Header
28100 }
28101
28102
28103
28104 func (r *CreativesService) List(profileId int64) *CreativesListCall {
28105 c := &CreativesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
28106 c.profileId = profileId
28107 return c
28108 }
28109
28110
28111
28112 func (c *CreativesListCall) Active(active bool) *CreativesListCall {
28113 c.urlParams_.Set("active", fmt.Sprint(active))
28114 return c
28115 }
28116
28117
28118
28119 func (c *CreativesListCall) AdvertiserId(advertiserId int64) *CreativesListCall {
28120 c.urlParams_.Set("advertiserId", fmt.Sprint(advertiserId))
28121 return c
28122 }
28123
28124
28125
28126 func (c *CreativesListCall) Archived(archived bool) *CreativesListCall {
28127 c.urlParams_.Set("archived", fmt.Sprint(archived))
28128 return c
28129 }
28130
28131
28132
28133 func (c *CreativesListCall) CampaignId(campaignId int64) *CreativesListCall {
28134 c.urlParams_.Set("campaignId", fmt.Sprint(campaignId))
28135 return c
28136 }
28137
28138
28139
28140
28141 func (c *CreativesListCall) CompanionCreativeIds(companionCreativeIds ...int64) *CreativesListCall {
28142 var companionCreativeIds_ []string
28143 for _, v := range companionCreativeIds {
28144 companionCreativeIds_ = append(companionCreativeIds_, fmt.Sprint(v))
28145 }
28146 c.urlParams_.SetMulti("companionCreativeIds", companionCreativeIds_)
28147 return c
28148 }
28149
28150
28151
28152 func (c *CreativesListCall) CreativeFieldIds(creativeFieldIds ...int64) *CreativesListCall {
28153 var creativeFieldIds_ []string
28154 for _, v := range creativeFieldIds {
28155 creativeFieldIds_ = append(creativeFieldIds_, fmt.Sprint(v))
28156 }
28157 c.urlParams_.SetMulti("creativeFieldIds", creativeFieldIds_)
28158 return c
28159 }
28160
28161
28162
28163 func (c *CreativesListCall) Ids(ids ...int64) *CreativesListCall {
28164 var ids_ []string
28165 for _, v := range ids {
28166 ids_ = append(ids_, fmt.Sprint(v))
28167 }
28168 c.urlParams_.SetMulti("ids", ids_)
28169 return c
28170 }
28171
28172
28173
28174 func (c *CreativesListCall) MaxResults(maxResults int64) *CreativesListCall {
28175 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
28176 return c
28177 }
28178
28179
28180
28181 func (c *CreativesListCall) PageToken(pageToken string) *CreativesListCall {
28182 c.urlParams_.Set("pageToken", pageToken)
28183 return c
28184 }
28185
28186
28187
28188 func (c *CreativesListCall) RenderingIds(renderingIds ...int64) *CreativesListCall {
28189 var renderingIds_ []string
28190 for _, v := range renderingIds {
28191 renderingIds_ = append(renderingIds_, fmt.Sprint(v))
28192 }
28193 c.urlParams_.SetMulti("renderingIds", renderingIds_)
28194 return c
28195 }
28196
28197
28198
28199
28200
28201
28202
28203
28204
28205 func (c *CreativesListCall) SearchString(searchString string) *CreativesListCall {
28206 c.urlParams_.Set("searchString", searchString)
28207 return c
28208 }
28209
28210
28211
28212 func (c *CreativesListCall) SizeIds(sizeIds ...int64) *CreativesListCall {
28213 var sizeIds_ []string
28214 for _, v := range sizeIds {
28215 sizeIds_ = append(sizeIds_, fmt.Sprint(v))
28216 }
28217 c.urlParams_.SetMulti("sizeIds", sizeIds_)
28218 return c
28219 }
28220
28221
28222
28223
28224
28225
28226
28227
28228 func (c *CreativesListCall) SortField(sortField string) *CreativesListCall {
28229 c.urlParams_.Set("sortField", sortField)
28230 return c
28231 }
28232
28233
28234
28235
28236
28237
28238
28239
28240 func (c *CreativesListCall) SortOrder(sortOrder string) *CreativesListCall {
28241 c.urlParams_.Set("sortOrder", sortOrder)
28242 return c
28243 }
28244
28245
28246
28247 func (c *CreativesListCall) StudioCreativeId(studioCreativeId int64) *CreativesListCall {
28248 c.urlParams_.Set("studioCreativeId", fmt.Sprint(studioCreativeId))
28249 return c
28250 }
28251
28252
28253
28254
28255
28256
28257
28258
28259
28260
28261
28262
28263
28264
28265
28266
28267
28268
28269
28270
28271
28272
28273
28274
28275
28276
28277
28278
28279
28280
28281
28282 func (c *CreativesListCall) Types(types ...string) *CreativesListCall {
28283 c.urlParams_.SetMulti("types", append([]string{}, types...))
28284 return c
28285 }
28286
28287
28288
28289
28290 func (c *CreativesListCall) Fields(s ...googleapi.Field) *CreativesListCall {
28291 c.urlParams_.Set("fields", googleapi.CombineFields(s))
28292 return c
28293 }
28294
28295
28296
28297
28298
28299
28300 func (c *CreativesListCall) IfNoneMatch(entityTag string) *CreativesListCall {
28301 c.ifNoneMatch_ = entityTag
28302 return c
28303 }
28304
28305
28306
28307
28308 func (c *CreativesListCall) Context(ctx context.Context) *CreativesListCall {
28309 c.ctx_ = ctx
28310 return c
28311 }
28312
28313
28314
28315 func (c *CreativesListCall) Header() http.Header {
28316 if c.header_ == nil {
28317 c.header_ = make(http.Header)
28318 }
28319 return c.header_
28320 }
28321
28322 func (c *CreativesListCall) doRequest(alt string) (*http.Response, error) {
28323 reqHeaders := make(http.Header)
28324 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
28325 for k, v := range c.header_ {
28326 reqHeaders[k] = v
28327 }
28328 reqHeaders.Set("User-Agent", c.s.userAgent())
28329 if c.ifNoneMatch_ != "" {
28330 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
28331 }
28332 var body io.Reader = nil
28333 c.urlParams_.Set("alt", alt)
28334 c.urlParams_.Set("prettyPrint", "false")
28335 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creatives")
28336 urls += "?" + c.urlParams_.Encode()
28337 req, err := http.NewRequest("GET", urls, body)
28338 if err != nil {
28339 return nil, err
28340 }
28341 req.Header = reqHeaders
28342 googleapi.Expand(req.URL, map[string]string{
28343 "profileId": strconv.FormatInt(c.profileId, 10),
28344 })
28345 return gensupport.SendRequest(c.ctx_, c.s.client, req)
28346 }
28347
28348
28349
28350
28351
28352
28353
28354
28355 func (c *CreativesListCall) Do(opts ...googleapi.CallOption) (*CreativesListResponse, error) {
28356 gensupport.SetOptions(c.urlParams_, opts...)
28357 res, err := c.doRequest("json")
28358 if res != nil && res.StatusCode == http.StatusNotModified {
28359 if res.Body != nil {
28360 res.Body.Close()
28361 }
28362 return nil, &googleapi.Error{
28363 Code: res.StatusCode,
28364 Header: res.Header,
28365 }
28366 }
28367 if err != nil {
28368 return nil, err
28369 }
28370 defer googleapi.CloseBody(res)
28371 if err := googleapi.CheckResponse(res); err != nil {
28372 return nil, err
28373 }
28374 ret := &CreativesListResponse{
28375 ServerResponse: googleapi.ServerResponse{
28376 Header: res.Header,
28377 HTTPStatusCode: res.StatusCode,
28378 },
28379 }
28380 target := &ret
28381 if err := gensupport.DecodeResponse(target, res); err != nil {
28382 return nil, err
28383 }
28384 return ret, nil
28385
28386
28387
28388
28389
28390
28391
28392
28393
28394
28395
28396
28397
28398
28399
28400
28401
28402
28403
28404
28405
28406
28407
28408
28409
28410
28411
28412
28413
28414
28415
28416
28417
28418
28419
28420
28421
28422
28423
28424
28425
28426
28427
28428
28429
28430
28431
28432
28433
28434
28435
28436
28437
28438
28439
28440
28441
28442
28443
28444
28445
28446
28447
28448
28449
28450
28451
28452
28453
28454
28455
28456
28457
28458
28459
28460
28461
28462
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
28496
28497
28498
28499
28500
28501
28502
28503
28504
28505
28506
28507
28508
28509
28510
28511
28512
28513
28514
28515
28516
28517
28518
28519
28520
28521
28522
28523
28524
28525
28526
28527
28528
28529
28530
28531
28532
28533
28534
28535
28536
28537
28538
28539
28540
28541
28542
28543
28544
28545
28546
28547
28548
28549
28550
28551
28552
28553
28554
28555
28556
28557
28558
28559
28560
28561
28562
28563
28564
28565
28566
28567
28568
28569
28570
28571
28572
28573
28574
28575
28576
28577
28578
28579
28580 }
28581
28582
28583
28584
28585 func (c *CreativesListCall) Pages(ctx context.Context, f func(*CreativesListResponse) error) error {
28586 c.ctx_ = ctx
28587 defer c.PageToken(c.urlParams_.Get("pageToken"))
28588 for {
28589 x, err := c.Do()
28590 if err != nil {
28591 return err
28592 }
28593 if err := f(x); err != nil {
28594 return err
28595 }
28596 if x.NextPageToken == "" {
28597 return nil
28598 }
28599 c.PageToken(x.NextPageToken)
28600 }
28601 }
28602
28603
28604
28605 type CreativesPatchCall struct {
28606 s *Service
28607 profileId int64
28608 creative *Creative
28609 urlParams_ gensupport.URLParams
28610 ctx_ context.Context
28611 header_ http.Header
28612 }
28613
28614
28615
28616 func (r *CreativesService) Patch(profileId int64, id int64, creative *Creative) *CreativesPatchCall {
28617 c := &CreativesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
28618 c.profileId = profileId
28619 c.urlParams_.Set("id", fmt.Sprint(id))
28620 c.creative = creative
28621 return c
28622 }
28623
28624
28625
28626
28627 func (c *CreativesPatchCall) Fields(s ...googleapi.Field) *CreativesPatchCall {
28628 c.urlParams_.Set("fields", googleapi.CombineFields(s))
28629 return c
28630 }
28631
28632
28633
28634
28635 func (c *CreativesPatchCall) Context(ctx context.Context) *CreativesPatchCall {
28636 c.ctx_ = ctx
28637 return c
28638 }
28639
28640
28641
28642 func (c *CreativesPatchCall) Header() http.Header {
28643 if c.header_ == nil {
28644 c.header_ = make(http.Header)
28645 }
28646 return c.header_
28647 }
28648
28649 func (c *CreativesPatchCall) doRequest(alt string) (*http.Response, error) {
28650 reqHeaders := make(http.Header)
28651 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
28652 for k, v := range c.header_ {
28653 reqHeaders[k] = v
28654 }
28655 reqHeaders.Set("User-Agent", c.s.userAgent())
28656 var body io.Reader = nil
28657 body, err := googleapi.WithoutDataWrapper.JSONReader(c.creative)
28658 if err != nil {
28659 return nil, err
28660 }
28661 reqHeaders.Set("Content-Type", "application/json")
28662 c.urlParams_.Set("alt", alt)
28663 c.urlParams_.Set("prettyPrint", "false")
28664 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creatives")
28665 urls += "?" + c.urlParams_.Encode()
28666 req, err := http.NewRequest("PATCH", urls, body)
28667 if err != nil {
28668 return nil, err
28669 }
28670 req.Header = reqHeaders
28671 googleapi.Expand(req.URL, map[string]string{
28672 "profileId": strconv.FormatInt(c.profileId, 10),
28673 })
28674 return gensupport.SendRequest(c.ctx_, c.s.client, req)
28675 }
28676
28677
28678
28679
28680
28681
28682
28683
28684 func (c *CreativesPatchCall) Do(opts ...googleapi.CallOption) (*Creative, error) {
28685 gensupport.SetOptions(c.urlParams_, opts...)
28686 res, err := c.doRequest("json")
28687 if res != nil && res.StatusCode == http.StatusNotModified {
28688 if res.Body != nil {
28689 res.Body.Close()
28690 }
28691 return nil, &googleapi.Error{
28692 Code: res.StatusCode,
28693 Header: res.Header,
28694 }
28695 }
28696 if err != nil {
28697 return nil, err
28698 }
28699 defer googleapi.CloseBody(res)
28700 if err := googleapi.CheckResponse(res); err != nil {
28701 return nil, err
28702 }
28703 ret := &Creative{
28704 ServerResponse: googleapi.ServerResponse{
28705 Header: res.Header,
28706 HTTPStatusCode: res.StatusCode,
28707 },
28708 }
28709 target := &ret
28710 if err := gensupport.DecodeResponse(target, res); err != nil {
28711 return nil, err
28712 }
28713 return ret, nil
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 type CreativesUpdateCall struct {
28755 s *Service
28756 profileId int64
28757 creative *Creative
28758 urlParams_ gensupport.URLParams
28759 ctx_ context.Context
28760 header_ http.Header
28761 }
28762
28763
28764 func (r *CreativesService) Update(profileId int64, creative *Creative) *CreativesUpdateCall {
28765 c := &CreativesUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
28766 c.profileId = profileId
28767 c.creative = creative
28768 return c
28769 }
28770
28771
28772
28773
28774 func (c *CreativesUpdateCall) Fields(s ...googleapi.Field) *CreativesUpdateCall {
28775 c.urlParams_.Set("fields", googleapi.CombineFields(s))
28776 return c
28777 }
28778
28779
28780
28781
28782 func (c *CreativesUpdateCall) Context(ctx context.Context) *CreativesUpdateCall {
28783 c.ctx_ = ctx
28784 return c
28785 }
28786
28787
28788
28789 func (c *CreativesUpdateCall) Header() http.Header {
28790 if c.header_ == nil {
28791 c.header_ = make(http.Header)
28792 }
28793 return c.header_
28794 }
28795
28796 func (c *CreativesUpdateCall) doRequest(alt string) (*http.Response, error) {
28797 reqHeaders := make(http.Header)
28798 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
28799 for k, v := range c.header_ {
28800 reqHeaders[k] = v
28801 }
28802 reqHeaders.Set("User-Agent", c.s.userAgent())
28803 var body io.Reader = nil
28804 body, err := googleapi.WithoutDataWrapper.JSONReader(c.creative)
28805 if err != nil {
28806 return nil, err
28807 }
28808 reqHeaders.Set("Content-Type", "application/json")
28809 c.urlParams_.Set("alt", alt)
28810 c.urlParams_.Set("prettyPrint", "false")
28811 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creatives")
28812 urls += "?" + c.urlParams_.Encode()
28813 req, err := http.NewRequest("PUT", urls, body)
28814 if err != nil {
28815 return nil, err
28816 }
28817 req.Header = reqHeaders
28818 googleapi.Expand(req.URL, map[string]string{
28819 "profileId": strconv.FormatInt(c.profileId, 10),
28820 })
28821 return gensupport.SendRequest(c.ctx_, c.s.client, req)
28822 }
28823
28824
28825
28826
28827
28828
28829
28830
28831 func (c *CreativesUpdateCall) Do(opts ...googleapi.CallOption) (*Creative, error) {
28832 gensupport.SetOptions(c.urlParams_, opts...)
28833 res, err := c.doRequest("json")
28834 if res != nil && res.StatusCode == http.StatusNotModified {
28835 if res.Body != nil {
28836 res.Body.Close()
28837 }
28838 return nil, &googleapi.Error{
28839 Code: res.StatusCode,
28840 Header: res.Header,
28841 }
28842 }
28843 if err != nil {
28844 return nil, err
28845 }
28846 defer googleapi.CloseBody(res)
28847 if err := googleapi.CheckResponse(res); err != nil {
28848 return nil, err
28849 }
28850 ret := &Creative{
28851 ServerResponse: googleapi.ServerResponse{
28852 Header: res.Header,
28853 HTTPStatusCode: res.StatusCode,
28854 },
28855 }
28856 target := &ret
28857 if err := gensupport.DecodeResponse(target, res); err != nil {
28858 return nil, err
28859 }
28860 return ret, nil
28861
28862
28863
28864
28865
28866
28867
28868
28869
28870
28871
28872
28873
28874
28875
28876
28877
28878
28879
28880
28881
28882
28883
28884
28885
28886
28887
28888
28889 }
28890
28891
28892
28893 type DimensionValuesQueryCall struct {
28894 s *Service
28895 profileId int64
28896 dimensionvaluerequest *DimensionValueRequest
28897 urlParams_ gensupport.URLParams
28898 ctx_ context.Context
28899 header_ http.Header
28900 }
28901
28902
28903
28904 func (r *DimensionValuesService) Query(profileId int64, dimensionvaluerequest *DimensionValueRequest) *DimensionValuesQueryCall {
28905 c := &DimensionValuesQueryCall{s: r.s, urlParams_: make(gensupport.URLParams)}
28906 c.profileId = profileId
28907 c.dimensionvaluerequest = dimensionvaluerequest
28908 return c
28909 }
28910
28911
28912
28913 func (c *DimensionValuesQueryCall) MaxResults(maxResults int64) *DimensionValuesQueryCall {
28914 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
28915 return c
28916 }
28917
28918
28919
28920 func (c *DimensionValuesQueryCall) PageToken(pageToken string) *DimensionValuesQueryCall {
28921 c.urlParams_.Set("pageToken", pageToken)
28922 return c
28923 }
28924
28925
28926
28927
28928 func (c *DimensionValuesQueryCall) Fields(s ...googleapi.Field) *DimensionValuesQueryCall {
28929 c.urlParams_.Set("fields", googleapi.CombineFields(s))
28930 return c
28931 }
28932
28933
28934
28935
28936 func (c *DimensionValuesQueryCall) Context(ctx context.Context) *DimensionValuesQueryCall {
28937 c.ctx_ = ctx
28938 return c
28939 }
28940
28941
28942
28943 func (c *DimensionValuesQueryCall) Header() http.Header {
28944 if c.header_ == nil {
28945 c.header_ = make(http.Header)
28946 }
28947 return c.header_
28948 }
28949
28950 func (c *DimensionValuesQueryCall) doRequest(alt string) (*http.Response, error) {
28951 reqHeaders := make(http.Header)
28952 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
28953 for k, v := range c.header_ {
28954 reqHeaders[k] = v
28955 }
28956 reqHeaders.Set("User-Agent", c.s.userAgent())
28957 var body io.Reader = nil
28958 body, err := googleapi.WithoutDataWrapper.JSONReader(c.dimensionvaluerequest)
28959 if err != nil {
28960 return nil, err
28961 }
28962 reqHeaders.Set("Content-Type", "application/json")
28963 c.urlParams_.Set("alt", alt)
28964 c.urlParams_.Set("prettyPrint", "false")
28965 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/dimensionvalues/query")
28966 urls += "?" + c.urlParams_.Encode()
28967 req, err := http.NewRequest("POST", urls, body)
28968 if err != nil {
28969 return nil, err
28970 }
28971 req.Header = reqHeaders
28972 googleapi.Expand(req.URL, map[string]string{
28973 "profileId": strconv.FormatInt(c.profileId, 10),
28974 })
28975 return gensupport.SendRequest(c.ctx_, c.s.client, req)
28976 }
28977
28978
28979
28980
28981
28982
28983
28984
28985 func (c *DimensionValuesQueryCall) Do(opts ...googleapi.CallOption) (*DimensionValueList, error) {
28986 gensupport.SetOptions(c.urlParams_, opts...)
28987 res, err := c.doRequest("json")
28988 if res != nil && res.StatusCode == http.StatusNotModified {
28989 if res.Body != nil {
28990 res.Body.Close()
28991 }
28992 return nil, &googleapi.Error{
28993 Code: res.StatusCode,
28994 Header: res.Header,
28995 }
28996 }
28997 if err != nil {
28998 return nil, err
28999 }
29000 defer googleapi.CloseBody(res)
29001 if err := googleapi.CheckResponse(res); err != nil {
29002 return nil, err
29003 }
29004 ret := &DimensionValueList{
29005 ServerResponse: googleapi.ServerResponse{
29006 Header: res.Header,
29007 HTTPStatusCode: res.StatusCode,
29008 },
29009 }
29010 target := &ret
29011 if err := gensupport.DecodeResponse(target, res); err != nil {
29012 return nil, err
29013 }
29014 return ret, nil
29015
29016
29017
29018
29019
29020
29021
29022
29023
29024
29025
29026
29027
29028
29029
29030
29031
29032
29033
29034
29035
29036
29037
29038
29039
29040
29041
29042
29043
29044
29045
29046
29047
29048
29049
29050
29051
29052
29053
29054
29055
29056
29057 }
29058
29059
29060
29061
29062 func (c *DimensionValuesQueryCall) Pages(ctx context.Context, f func(*DimensionValueList) error) error {
29063 c.ctx_ = ctx
29064 defer c.PageToken(c.urlParams_.Get("pageToken"))
29065 for {
29066 x, err := c.Do()
29067 if err != nil {
29068 return err
29069 }
29070 if err := f(x); err != nil {
29071 return err
29072 }
29073 if x.NextPageToken == "" {
29074 return nil
29075 }
29076 c.PageToken(x.NextPageToken)
29077 }
29078 }
29079
29080
29081
29082 type DirectorySiteContactsGetCall struct {
29083 s *Service
29084 profileId int64
29085 id int64
29086 urlParams_ gensupport.URLParams
29087 ifNoneMatch_ string
29088 ctx_ context.Context
29089 header_ http.Header
29090 }
29091
29092
29093 func (r *DirectorySiteContactsService) Get(profileId int64, id int64) *DirectorySiteContactsGetCall {
29094 c := &DirectorySiteContactsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
29095 c.profileId = profileId
29096 c.id = id
29097 return c
29098 }
29099
29100
29101
29102
29103 func (c *DirectorySiteContactsGetCall) Fields(s ...googleapi.Field) *DirectorySiteContactsGetCall {
29104 c.urlParams_.Set("fields", googleapi.CombineFields(s))
29105 return c
29106 }
29107
29108
29109
29110
29111
29112
29113 func (c *DirectorySiteContactsGetCall) IfNoneMatch(entityTag string) *DirectorySiteContactsGetCall {
29114 c.ifNoneMatch_ = entityTag
29115 return c
29116 }
29117
29118
29119
29120
29121 func (c *DirectorySiteContactsGetCall) Context(ctx context.Context) *DirectorySiteContactsGetCall {
29122 c.ctx_ = ctx
29123 return c
29124 }
29125
29126
29127
29128 func (c *DirectorySiteContactsGetCall) Header() http.Header {
29129 if c.header_ == nil {
29130 c.header_ = make(http.Header)
29131 }
29132 return c.header_
29133 }
29134
29135 func (c *DirectorySiteContactsGetCall) doRequest(alt string) (*http.Response, error) {
29136 reqHeaders := make(http.Header)
29137 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
29138 for k, v := range c.header_ {
29139 reqHeaders[k] = v
29140 }
29141 reqHeaders.Set("User-Agent", c.s.userAgent())
29142 if c.ifNoneMatch_ != "" {
29143 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
29144 }
29145 var body io.Reader = nil
29146 c.urlParams_.Set("alt", alt)
29147 c.urlParams_.Set("prettyPrint", "false")
29148 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/directorySiteContacts/{id}")
29149 urls += "?" + c.urlParams_.Encode()
29150 req, err := http.NewRequest("GET", urls, body)
29151 if err != nil {
29152 return nil, err
29153 }
29154 req.Header = reqHeaders
29155 googleapi.Expand(req.URL, map[string]string{
29156 "profileId": strconv.FormatInt(c.profileId, 10),
29157 "id": strconv.FormatInt(c.id, 10),
29158 })
29159 return gensupport.SendRequest(c.ctx_, c.s.client, req)
29160 }
29161
29162
29163
29164
29165
29166
29167
29168
29169 func (c *DirectorySiteContactsGetCall) Do(opts ...googleapi.CallOption) (*DirectorySiteContact, error) {
29170 gensupport.SetOptions(c.urlParams_, opts...)
29171 res, err := c.doRequest("json")
29172 if res != nil && res.StatusCode == http.StatusNotModified {
29173 if res.Body != nil {
29174 res.Body.Close()
29175 }
29176 return nil, &googleapi.Error{
29177 Code: res.StatusCode,
29178 Header: res.Header,
29179 }
29180 }
29181 if err != nil {
29182 return nil, err
29183 }
29184 defer googleapi.CloseBody(res)
29185 if err := googleapi.CheckResponse(res); err != nil {
29186 return nil, err
29187 }
29188 ret := &DirectorySiteContact{
29189 ServerResponse: googleapi.ServerResponse{
29190 Header: res.Header,
29191 HTTPStatusCode: res.StatusCode,
29192 },
29193 }
29194 target := &ret
29195 if err := gensupport.DecodeResponse(target, res); err != nil {
29196 return nil, err
29197 }
29198 return ret, nil
29199
29200
29201
29202
29203
29204
29205
29206
29207
29208
29209
29210
29211
29212
29213
29214
29215
29216
29217
29218
29219
29220
29221
29222
29223
29224
29225
29226
29227
29228
29229
29230
29231
29232 }
29233
29234
29235
29236 type DirectorySiteContactsListCall struct {
29237 s *Service
29238 profileId int64
29239 urlParams_ gensupport.URLParams
29240 ifNoneMatch_ string
29241 ctx_ context.Context
29242 header_ http.Header
29243 }
29244
29245
29246
29247 func (r *DirectorySiteContactsService) List(profileId int64) *DirectorySiteContactsListCall {
29248 c := &DirectorySiteContactsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
29249 c.profileId = profileId
29250 return c
29251 }
29252
29253
29254
29255
29256 func (c *DirectorySiteContactsListCall) DirectorySiteIds(directorySiteIds ...int64) *DirectorySiteContactsListCall {
29257 var directorySiteIds_ []string
29258 for _, v := range directorySiteIds {
29259 directorySiteIds_ = append(directorySiteIds_, fmt.Sprint(v))
29260 }
29261 c.urlParams_.SetMulti("directorySiteIds", directorySiteIds_)
29262 return c
29263 }
29264
29265
29266
29267 func (c *DirectorySiteContactsListCall) Ids(ids ...int64) *DirectorySiteContactsListCall {
29268 var ids_ []string
29269 for _, v := range ids {
29270 ids_ = append(ids_, fmt.Sprint(v))
29271 }
29272 c.urlParams_.SetMulti("ids", ids_)
29273 return c
29274 }
29275
29276
29277
29278 func (c *DirectorySiteContactsListCall) MaxResults(maxResults int64) *DirectorySiteContactsListCall {
29279 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
29280 return c
29281 }
29282
29283
29284
29285 func (c *DirectorySiteContactsListCall) PageToken(pageToken string) *DirectorySiteContactsListCall {
29286 c.urlParams_.Set("pageToken", pageToken)
29287 return c
29288 }
29289
29290
29291
29292
29293
29294
29295
29296
29297
29298
29299
29300 func (c *DirectorySiteContactsListCall) SearchString(searchString string) *DirectorySiteContactsListCall {
29301 c.urlParams_.Set("searchString", searchString)
29302 return c
29303 }
29304
29305
29306
29307
29308
29309
29310
29311
29312 func (c *DirectorySiteContactsListCall) SortField(sortField string) *DirectorySiteContactsListCall {
29313 c.urlParams_.Set("sortField", sortField)
29314 return c
29315 }
29316
29317
29318
29319
29320
29321
29322
29323
29324 func (c *DirectorySiteContactsListCall) SortOrder(sortOrder string) *DirectorySiteContactsListCall {
29325 c.urlParams_.Set("sortOrder", sortOrder)
29326 return c
29327 }
29328
29329
29330
29331
29332 func (c *DirectorySiteContactsListCall) Fields(s ...googleapi.Field) *DirectorySiteContactsListCall {
29333 c.urlParams_.Set("fields", googleapi.CombineFields(s))
29334 return c
29335 }
29336
29337
29338
29339
29340
29341
29342 func (c *DirectorySiteContactsListCall) IfNoneMatch(entityTag string) *DirectorySiteContactsListCall {
29343 c.ifNoneMatch_ = entityTag
29344 return c
29345 }
29346
29347
29348
29349
29350 func (c *DirectorySiteContactsListCall) Context(ctx context.Context) *DirectorySiteContactsListCall {
29351 c.ctx_ = ctx
29352 return c
29353 }
29354
29355
29356
29357 func (c *DirectorySiteContactsListCall) Header() http.Header {
29358 if c.header_ == nil {
29359 c.header_ = make(http.Header)
29360 }
29361 return c.header_
29362 }
29363
29364 func (c *DirectorySiteContactsListCall) doRequest(alt string) (*http.Response, error) {
29365 reqHeaders := make(http.Header)
29366 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
29367 for k, v := range c.header_ {
29368 reqHeaders[k] = v
29369 }
29370 reqHeaders.Set("User-Agent", c.s.userAgent())
29371 if c.ifNoneMatch_ != "" {
29372 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
29373 }
29374 var body io.Reader = nil
29375 c.urlParams_.Set("alt", alt)
29376 c.urlParams_.Set("prettyPrint", "false")
29377 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/directorySiteContacts")
29378 urls += "?" + c.urlParams_.Encode()
29379 req, err := http.NewRequest("GET", urls, body)
29380 if err != nil {
29381 return nil, err
29382 }
29383 req.Header = reqHeaders
29384 googleapi.Expand(req.URL, map[string]string{
29385 "profileId": strconv.FormatInt(c.profileId, 10),
29386 })
29387 return gensupport.SendRequest(c.ctx_, c.s.client, req)
29388 }
29389
29390
29391
29392
29393
29394
29395
29396
29397
29398 func (c *DirectorySiteContactsListCall) Do(opts ...googleapi.CallOption) (*DirectorySiteContactsListResponse, error) {
29399 gensupport.SetOptions(c.urlParams_, opts...)
29400 res, err := c.doRequest("json")
29401 if res != nil && res.StatusCode == http.StatusNotModified {
29402 if res.Body != nil {
29403 res.Body.Close()
29404 }
29405 return nil, &googleapi.Error{
29406 Code: res.StatusCode,
29407 Header: res.Header,
29408 }
29409 }
29410 if err != nil {
29411 return nil, err
29412 }
29413 defer googleapi.CloseBody(res)
29414 if err := googleapi.CheckResponse(res); err != nil {
29415 return nil, err
29416 }
29417 ret := &DirectorySiteContactsListResponse{
29418 ServerResponse: googleapi.ServerResponse{
29419 Header: res.Header,
29420 HTTPStatusCode: res.StatusCode,
29421 },
29422 }
29423 target := &ret
29424 if err := gensupport.DecodeResponse(target, res); err != nil {
29425 return nil, err
29426 }
29427 return ret, nil
29428
29429
29430
29431
29432
29433
29434
29435
29436
29437
29438
29439
29440
29441
29442
29443
29444
29445
29446
29447
29448
29449
29450
29451
29452
29453
29454
29455
29456
29457
29458
29459
29460
29461
29462
29463
29464
29465
29466
29467
29468
29469
29470
29471
29472
29473
29474
29475
29476
29477
29478
29479
29480
29481
29482
29483
29484
29485
29486
29487
29488
29489
29490
29491
29492
29493
29494
29495
29496
29497
29498
29499
29500
29501
29502
29503
29504
29505
29506
29507
29508
29509
29510
29511
29512
29513
29514 }
29515
29516
29517
29518
29519 func (c *DirectorySiteContactsListCall) Pages(ctx context.Context, f func(*DirectorySiteContactsListResponse) error) error {
29520 c.ctx_ = ctx
29521 defer c.PageToken(c.urlParams_.Get("pageToken"))
29522 for {
29523 x, err := c.Do()
29524 if err != nil {
29525 return err
29526 }
29527 if err := f(x); err != nil {
29528 return err
29529 }
29530 if x.NextPageToken == "" {
29531 return nil
29532 }
29533 c.PageToken(x.NextPageToken)
29534 }
29535 }
29536
29537
29538
29539 type DirectorySitesGetCall struct {
29540 s *Service
29541 profileId int64
29542 id int64
29543 urlParams_ gensupport.URLParams
29544 ifNoneMatch_ string
29545 ctx_ context.Context
29546 header_ http.Header
29547 }
29548
29549
29550 func (r *DirectorySitesService) Get(profileId int64, id int64) *DirectorySitesGetCall {
29551 c := &DirectorySitesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
29552 c.profileId = profileId
29553 c.id = id
29554 return c
29555 }
29556
29557
29558
29559
29560 func (c *DirectorySitesGetCall) Fields(s ...googleapi.Field) *DirectorySitesGetCall {
29561 c.urlParams_.Set("fields", googleapi.CombineFields(s))
29562 return c
29563 }
29564
29565
29566
29567
29568
29569
29570 func (c *DirectorySitesGetCall) IfNoneMatch(entityTag string) *DirectorySitesGetCall {
29571 c.ifNoneMatch_ = entityTag
29572 return c
29573 }
29574
29575
29576
29577
29578 func (c *DirectorySitesGetCall) Context(ctx context.Context) *DirectorySitesGetCall {
29579 c.ctx_ = ctx
29580 return c
29581 }
29582
29583
29584
29585 func (c *DirectorySitesGetCall) Header() http.Header {
29586 if c.header_ == nil {
29587 c.header_ = make(http.Header)
29588 }
29589 return c.header_
29590 }
29591
29592 func (c *DirectorySitesGetCall) doRequest(alt string) (*http.Response, error) {
29593 reqHeaders := make(http.Header)
29594 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
29595 for k, v := range c.header_ {
29596 reqHeaders[k] = v
29597 }
29598 reqHeaders.Set("User-Agent", c.s.userAgent())
29599 if c.ifNoneMatch_ != "" {
29600 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
29601 }
29602 var body io.Reader = nil
29603 c.urlParams_.Set("alt", alt)
29604 c.urlParams_.Set("prettyPrint", "false")
29605 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/directorySites/{id}")
29606 urls += "?" + c.urlParams_.Encode()
29607 req, err := http.NewRequest("GET", urls, body)
29608 if err != nil {
29609 return nil, err
29610 }
29611 req.Header = reqHeaders
29612 googleapi.Expand(req.URL, map[string]string{
29613 "profileId": strconv.FormatInt(c.profileId, 10),
29614 "id": strconv.FormatInt(c.id, 10),
29615 })
29616 return gensupport.SendRequest(c.ctx_, c.s.client, req)
29617 }
29618
29619
29620
29621
29622
29623
29624
29625
29626 func (c *DirectorySitesGetCall) Do(opts ...googleapi.CallOption) (*DirectorySite, error) {
29627 gensupport.SetOptions(c.urlParams_, opts...)
29628 res, err := c.doRequest("json")
29629 if res != nil && res.StatusCode == http.StatusNotModified {
29630 if res.Body != nil {
29631 res.Body.Close()
29632 }
29633 return nil, &googleapi.Error{
29634 Code: res.StatusCode,
29635 Header: res.Header,
29636 }
29637 }
29638 if err != nil {
29639 return nil, err
29640 }
29641 defer googleapi.CloseBody(res)
29642 if err := googleapi.CheckResponse(res); err != nil {
29643 return nil, err
29644 }
29645 ret := &DirectorySite{
29646 ServerResponse: googleapi.ServerResponse{
29647 Header: res.Header,
29648 HTTPStatusCode: res.StatusCode,
29649 },
29650 }
29651 target := &ret
29652 if err := gensupport.DecodeResponse(target, res); err != nil {
29653 return nil, err
29654 }
29655 return ret, nil
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 type DirectorySitesInsertCall struct {
29694 s *Service
29695 profileId int64
29696 directorysite *DirectorySite
29697 urlParams_ gensupport.URLParams
29698 ctx_ context.Context
29699 header_ http.Header
29700 }
29701
29702
29703 func (r *DirectorySitesService) Insert(profileId int64, directorysite *DirectorySite) *DirectorySitesInsertCall {
29704 c := &DirectorySitesInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
29705 c.profileId = profileId
29706 c.directorysite = directorysite
29707 return c
29708 }
29709
29710
29711
29712
29713 func (c *DirectorySitesInsertCall) Fields(s ...googleapi.Field) *DirectorySitesInsertCall {
29714 c.urlParams_.Set("fields", googleapi.CombineFields(s))
29715 return c
29716 }
29717
29718
29719
29720
29721 func (c *DirectorySitesInsertCall) Context(ctx context.Context) *DirectorySitesInsertCall {
29722 c.ctx_ = ctx
29723 return c
29724 }
29725
29726
29727
29728 func (c *DirectorySitesInsertCall) Header() http.Header {
29729 if c.header_ == nil {
29730 c.header_ = make(http.Header)
29731 }
29732 return c.header_
29733 }
29734
29735 func (c *DirectorySitesInsertCall) doRequest(alt string) (*http.Response, error) {
29736 reqHeaders := make(http.Header)
29737 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
29738 for k, v := range c.header_ {
29739 reqHeaders[k] = v
29740 }
29741 reqHeaders.Set("User-Agent", c.s.userAgent())
29742 var body io.Reader = nil
29743 body, err := googleapi.WithoutDataWrapper.JSONReader(c.directorysite)
29744 if err != nil {
29745 return nil, err
29746 }
29747 reqHeaders.Set("Content-Type", "application/json")
29748 c.urlParams_.Set("alt", alt)
29749 c.urlParams_.Set("prettyPrint", "false")
29750 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/directorySites")
29751 urls += "?" + c.urlParams_.Encode()
29752 req, err := http.NewRequest("POST", urls, body)
29753 if err != nil {
29754 return nil, err
29755 }
29756 req.Header = reqHeaders
29757 googleapi.Expand(req.URL, map[string]string{
29758 "profileId": strconv.FormatInt(c.profileId, 10),
29759 })
29760 return gensupport.SendRequest(c.ctx_, c.s.client, req)
29761 }
29762
29763
29764
29765
29766
29767
29768
29769
29770 func (c *DirectorySitesInsertCall) Do(opts ...googleapi.CallOption) (*DirectorySite, error) {
29771 gensupport.SetOptions(c.urlParams_, opts...)
29772 res, err := c.doRequest("json")
29773 if res != nil && res.StatusCode == http.StatusNotModified {
29774 if res.Body != nil {
29775 res.Body.Close()
29776 }
29777 return nil, &googleapi.Error{
29778 Code: res.StatusCode,
29779 Header: res.Header,
29780 }
29781 }
29782 if err != nil {
29783 return nil, err
29784 }
29785 defer googleapi.CloseBody(res)
29786 if err := googleapi.CheckResponse(res); err != nil {
29787 return nil, err
29788 }
29789 ret := &DirectorySite{
29790 ServerResponse: googleapi.ServerResponse{
29791 Header: res.Header,
29792 HTTPStatusCode: res.StatusCode,
29793 },
29794 }
29795 target := &ret
29796 if err := gensupport.DecodeResponse(target, res); err != nil {
29797 return nil, err
29798 }
29799 return ret, nil
29800
29801
29802
29803
29804
29805
29806
29807
29808
29809
29810
29811
29812
29813
29814
29815
29816
29817
29818
29819
29820
29821
29822
29823
29824
29825
29826
29827
29828 }
29829
29830
29831
29832 type DirectorySitesListCall struct {
29833 s *Service
29834 profileId int64
29835 urlParams_ gensupport.URLParams
29836 ifNoneMatch_ string
29837 ctx_ context.Context
29838 header_ http.Header
29839 }
29840
29841
29842
29843 func (r *DirectorySitesService) List(profileId int64) *DirectorySitesListCall {
29844 c := &DirectorySitesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
29845 c.profileId = profileId
29846 return c
29847 }
29848
29849
29850
29851
29852 func (c *DirectorySitesListCall) AcceptsInStreamVideoPlacements(acceptsInStreamVideoPlacements bool) *DirectorySitesListCall {
29853 c.urlParams_.Set("acceptsInStreamVideoPlacements", fmt.Sprint(acceptsInStreamVideoPlacements))
29854 return c
29855 }
29856
29857
29858
29859
29860 func (c *DirectorySitesListCall) AcceptsInterstitialPlacements(acceptsInterstitialPlacements bool) *DirectorySitesListCall {
29861 c.urlParams_.Set("acceptsInterstitialPlacements", fmt.Sprint(acceptsInterstitialPlacements))
29862 return c
29863 }
29864
29865
29866
29867
29868 func (c *DirectorySitesListCall) AcceptsPublisherPaidPlacements(acceptsPublisherPaidPlacements bool) *DirectorySitesListCall {
29869 c.urlParams_.Set("acceptsPublisherPaidPlacements", fmt.Sprint(acceptsPublisherPaidPlacements))
29870 return c
29871 }
29872
29873
29874
29875
29876 func (c *DirectorySitesListCall) Active(active bool) *DirectorySitesListCall {
29877 c.urlParams_.Set("active", fmt.Sprint(active))
29878 return c
29879 }
29880
29881
29882
29883 func (c *DirectorySitesListCall) CountryId(countryId int64) *DirectorySitesListCall {
29884 c.urlParams_.Set("countryId", fmt.Sprint(countryId))
29885 return c
29886 }
29887
29888
29889
29890 func (c *DirectorySitesListCall) DfpNetworkCode(dfpNetworkCode string) *DirectorySitesListCall {
29891 c.urlParams_.Set("dfpNetworkCode", dfpNetworkCode)
29892 return c
29893 }
29894
29895
29896
29897 func (c *DirectorySitesListCall) Ids(ids ...int64) *DirectorySitesListCall {
29898 var ids_ []string
29899 for _, v := range ids {
29900 ids_ = append(ids_, fmt.Sprint(v))
29901 }
29902 c.urlParams_.SetMulti("ids", ids_)
29903 return c
29904 }
29905
29906
29907
29908 func (c *DirectorySitesListCall) MaxResults(maxResults int64) *DirectorySitesListCall {
29909 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
29910 return c
29911 }
29912
29913
29914
29915 func (c *DirectorySitesListCall) PageToken(pageToken string) *DirectorySitesListCall {
29916 c.urlParams_.Set("pageToken", pageToken)
29917 return c
29918 }
29919
29920
29921
29922 func (c *DirectorySitesListCall) ParentId(parentId int64) *DirectorySitesListCall {
29923 c.urlParams_.Set("parentId", fmt.Sprint(parentId))
29924 return c
29925 }
29926
29927
29928
29929
29930
29931
29932
29933
29934
29935
29936 func (c *DirectorySitesListCall) SearchString(searchString string) *DirectorySitesListCall {
29937 c.urlParams_.Set("searchString", searchString)
29938 return c
29939 }
29940
29941
29942
29943
29944
29945
29946
29947
29948 func (c *DirectorySitesListCall) SortField(sortField string) *DirectorySitesListCall {
29949 c.urlParams_.Set("sortField", sortField)
29950 return c
29951 }
29952
29953
29954
29955
29956
29957
29958
29959
29960 func (c *DirectorySitesListCall) SortOrder(sortOrder string) *DirectorySitesListCall {
29961 c.urlParams_.Set("sortOrder", sortOrder)
29962 return c
29963 }
29964
29965
29966
29967
29968 func (c *DirectorySitesListCall) Fields(s ...googleapi.Field) *DirectorySitesListCall {
29969 c.urlParams_.Set("fields", googleapi.CombineFields(s))
29970 return c
29971 }
29972
29973
29974
29975
29976
29977
29978 func (c *DirectorySitesListCall) IfNoneMatch(entityTag string) *DirectorySitesListCall {
29979 c.ifNoneMatch_ = entityTag
29980 return c
29981 }
29982
29983
29984
29985
29986 func (c *DirectorySitesListCall) Context(ctx context.Context) *DirectorySitesListCall {
29987 c.ctx_ = ctx
29988 return c
29989 }
29990
29991
29992
29993 func (c *DirectorySitesListCall) Header() http.Header {
29994 if c.header_ == nil {
29995 c.header_ = make(http.Header)
29996 }
29997 return c.header_
29998 }
29999
30000 func (c *DirectorySitesListCall) doRequest(alt string) (*http.Response, error) {
30001 reqHeaders := make(http.Header)
30002 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
30003 for k, v := range c.header_ {
30004 reqHeaders[k] = v
30005 }
30006 reqHeaders.Set("User-Agent", c.s.userAgent())
30007 if c.ifNoneMatch_ != "" {
30008 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
30009 }
30010 var body io.Reader = nil
30011 c.urlParams_.Set("alt", alt)
30012 c.urlParams_.Set("prettyPrint", "false")
30013 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/directorySites")
30014 urls += "?" + c.urlParams_.Encode()
30015 req, err := http.NewRequest("GET", urls, body)
30016 if err != nil {
30017 return nil, err
30018 }
30019 req.Header = reqHeaders
30020 googleapi.Expand(req.URL, map[string]string{
30021 "profileId": strconv.FormatInt(c.profileId, 10),
30022 })
30023 return gensupport.SendRequest(c.ctx_, c.s.client, req)
30024 }
30025
30026
30027
30028
30029
30030
30031
30032
30033 func (c *DirectorySitesListCall) Do(opts ...googleapi.CallOption) (*DirectorySitesListResponse, error) {
30034 gensupport.SetOptions(c.urlParams_, opts...)
30035 res, err := c.doRequest("json")
30036 if res != nil && res.StatusCode == http.StatusNotModified {
30037 if res.Body != nil {
30038 res.Body.Close()
30039 }
30040 return nil, &googleapi.Error{
30041 Code: res.StatusCode,
30042 Header: res.Header,
30043 }
30044 }
30045 if err != nil {
30046 return nil, err
30047 }
30048 defer googleapi.CloseBody(res)
30049 if err := googleapi.CheckResponse(res); err != nil {
30050 return nil, err
30051 }
30052 ret := &DirectorySitesListResponse{
30053 ServerResponse: googleapi.ServerResponse{
30054 Header: res.Header,
30055 HTTPStatusCode: res.StatusCode,
30056 },
30057 }
30058 target := &ret
30059 if err := gensupport.DecodeResponse(target, res); err != nil {
30060 return nil, err
30061 }
30062 return ret, nil
30063
30064
30065
30066
30067
30068
30069
30070
30071
30072
30073
30074
30075
30076
30077
30078
30079
30080
30081
30082
30083
30084
30085
30086
30087
30088
30089
30090
30091
30092
30093
30094
30095
30096
30097
30098
30099
30100
30101
30102
30103
30104
30105
30106
30107
30108
30109
30110
30111
30112
30113
30114
30115
30116
30117
30118
30119
30120
30121
30122
30123
30124
30125
30126
30127
30128
30129
30130
30131
30132
30133
30134
30135
30136
30137
30138
30139
30140
30141
30142
30143
30144
30145
30146
30147
30148
30149
30150
30151
30152
30153
30154
30155
30156
30157
30158
30159
30160
30161
30162
30163
30164
30165
30166
30167
30168
30169
30170
30171
30172
30173
30174
30175
30176
30177
30178
30179 }
30180
30181
30182
30183
30184 func (c *DirectorySitesListCall) Pages(ctx context.Context, f func(*DirectorySitesListResponse) error) error {
30185 c.ctx_ = ctx
30186 defer c.PageToken(c.urlParams_.Get("pageToken"))
30187 for {
30188 x, err := c.Do()
30189 if err != nil {
30190 return err
30191 }
30192 if err := f(x); err != nil {
30193 return err
30194 }
30195 if x.NextPageToken == "" {
30196 return nil
30197 }
30198 c.PageToken(x.NextPageToken)
30199 }
30200 }
30201
30202
30203
30204 type DynamicTargetingKeysDeleteCall struct {
30205 s *Service
30206 profileId int64
30207 objectId int64
30208 urlParams_ gensupport.URLParams
30209 ctx_ context.Context
30210 header_ http.Header
30211 }
30212
30213
30214 func (r *DynamicTargetingKeysService) Delete(profileId int64, objectId int64, name string, objectType string) *DynamicTargetingKeysDeleteCall {
30215 c := &DynamicTargetingKeysDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
30216 c.profileId = profileId
30217 c.objectId = objectId
30218 c.urlParams_.Set("name", name)
30219 c.urlParams_.Set("objectType", objectType)
30220 return c
30221 }
30222
30223
30224
30225
30226 func (c *DynamicTargetingKeysDeleteCall) Fields(s ...googleapi.Field) *DynamicTargetingKeysDeleteCall {
30227 c.urlParams_.Set("fields", googleapi.CombineFields(s))
30228 return c
30229 }
30230
30231
30232
30233
30234 func (c *DynamicTargetingKeysDeleteCall) Context(ctx context.Context) *DynamicTargetingKeysDeleteCall {
30235 c.ctx_ = ctx
30236 return c
30237 }
30238
30239
30240
30241 func (c *DynamicTargetingKeysDeleteCall) Header() http.Header {
30242 if c.header_ == nil {
30243 c.header_ = make(http.Header)
30244 }
30245 return c.header_
30246 }
30247
30248 func (c *DynamicTargetingKeysDeleteCall) doRequest(alt string) (*http.Response, error) {
30249 reqHeaders := make(http.Header)
30250 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
30251 for k, v := range c.header_ {
30252 reqHeaders[k] = v
30253 }
30254 reqHeaders.Set("User-Agent", c.s.userAgent())
30255 var body io.Reader = nil
30256 c.urlParams_.Set("alt", alt)
30257 c.urlParams_.Set("prettyPrint", "false")
30258 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/dynamicTargetingKeys/{objectId}")
30259 urls += "?" + c.urlParams_.Encode()
30260 req, err := http.NewRequest("DELETE", urls, body)
30261 if err != nil {
30262 return nil, err
30263 }
30264 req.Header = reqHeaders
30265 googleapi.Expand(req.URL, map[string]string{
30266 "profileId": strconv.FormatInt(c.profileId, 10),
30267 "objectId": strconv.FormatInt(c.objectId, 10),
30268 })
30269 return gensupport.SendRequest(c.ctx_, c.s.client, req)
30270 }
30271
30272
30273 func (c *DynamicTargetingKeysDeleteCall) Do(opts ...googleapi.CallOption) error {
30274 gensupport.SetOptions(c.urlParams_, opts...)
30275 res, err := c.doRequest("json")
30276 if err != nil {
30277 return err
30278 }
30279 defer googleapi.CloseBody(res)
30280 if err := googleapi.CheckResponse(res); err != nil {
30281 return err
30282 }
30283 return nil
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 type DynamicTargetingKeysInsertCall struct {
30345 s *Service
30346 profileId int64
30347 dynamictargetingkey *DynamicTargetingKey
30348 urlParams_ gensupport.URLParams
30349 ctx_ context.Context
30350 header_ http.Header
30351 }
30352
30353
30354
30355
30356
30357
30358 func (r *DynamicTargetingKeysService) Insert(profileId int64, dynamictargetingkey *DynamicTargetingKey) *DynamicTargetingKeysInsertCall {
30359 c := &DynamicTargetingKeysInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
30360 c.profileId = profileId
30361 c.dynamictargetingkey = dynamictargetingkey
30362 return c
30363 }
30364
30365
30366
30367
30368 func (c *DynamicTargetingKeysInsertCall) Fields(s ...googleapi.Field) *DynamicTargetingKeysInsertCall {
30369 c.urlParams_.Set("fields", googleapi.CombineFields(s))
30370 return c
30371 }
30372
30373
30374
30375
30376 func (c *DynamicTargetingKeysInsertCall) Context(ctx context.Context) *DynamicTargetingKeysInsertCall {
30377 c.ctx_ = ctx
30378 return c
30379 }
30380
30381
30382
30383 func (c *DynamicTargetingKeysInsertCall) Header() http.Header {
30384 if c.header_ == nil {
30385 c.header_ = make(http.Header)
30386 }
30387 return c.header_
30388 }
30389
30390 func (c *DynamicTargetingKeysInsertCall) doRequest(alt string) (*http.Response, error) {
30391 reqHeaders := make(http.Header)
30392 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
30393 for k, v := range c.header_ {
30394 reqHeaders[k] = v
30395 }
30396 reqHeaders.Set("User-Agent", c.s.userAgent())
30397 var body io.Reader = nil
30398 body, err := googleapi.WithoutDataWrapper.JSONReader(c.dynamictargetingkey)
30399 if err != nil {
30400 return nil, err
30401 }
30402 reqHeaders.Set("Content-Type", "application/json")
30403 c.urlParams_.Set("alt", alt)
30404 c.urlParams_.Set("prettyPrint", "false")
30405 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/dynamicTargetingKeys")
30406 urls += "?" + c.urlParams_.Encode()
30407 req, err := http.NewRequest("POST", urls, body)
30408 if err != nil {
30409 return nil, err
30410 }
30411 req.Header = reqHeaders
30412 googleapi.Expand(req.URL, map[string]string{
30413 "profileId": strconv.FormatInt(c.profileId, 10),
30414 })
30415 return gensupport.SendRequest(c.ctx_, c.s.client, req)
30416 }
30417
30418
30419
30420
30421
30422
30423
30424
30425 func (c *DynamicTargetingKeysInsertCall) Do(opts ...googleapi.CallOption) (*DynamicTargetingKey, error) {
30426 gensupport.SetOptions(c.urlParams_, opts...)
30427 res, err := c.doRequest("json")
30428 if res != nil && res.StatusCode == http.StatusNotModified {
30429 if res.Body != nil {
30430 res.Body.Close()
30431 }
30432 return nil, &googleapi.Error{
30433 Code: res.StatusCode,
30434 Header: res.Header,
30435 }
30436 }
30437 if err != nil {
30438 return nil, err
30439 }
30440 defer googleapi.CloseBody(res)
30441 if err := googleapi.CheckResponse(res); err != nil {
30442 return nil, err
30443 }
30444 ret := &DynamicTargetingKey{
30445 ServerResponse: googleapi.ServerResponse{
30446 Header: res.Header,
30447 HTTPStatusCode: res.StatusCode,
30448 },
30449 }
30450 target := &ret
30451 if err := gensupport.DecodeResponse(target, res); err != nil {
30452 return nil, err
30453 }
30454 return ret, nil
30455
30456
30457
30458
30459
30460
30461
30462
30463
30464
30465
30466
30467
30468
30469
30470
30471
30472
30473
30474
30475
30476
30477
30478
30479
30480
30481
30482
30483 }
30484
30485
30486
30487 type DynamicTargetingKeysListCall struct {
30488 s *Service
30489 profileId int64
30490 urlParams_ gensupport.URLParams
30491 ifNoneMatch_ string
30492 ctx_ context.Context
30493 header_ http.Header
30494 }
30495
30496
30497 func (r *DynamicTargetingKeysService) List(profileId int64) *DynamicTargetingKeysListCall {
30498 c := &DynamicTargetingKeysListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
30499 c.profileId = profileId
30500 return c
30501 }
30502
30503
30504
30505 func (c *DynamicTargetingKeysListCall) AdvertiserId(advertiserId int64) *DynamicTargetingKeysListCall {
30506 c.urlParams_.Set("advertiserId", fmt.Sprint(advertiserId))
30507 return c
30508 }
30509
30510
30511
30512 func (c *DynamicTargetingKeysListCall) Names(names ...string) *DynamicTargetingKeysListCall {
30513 c.urlParams_.SetMulti("names", append([]string{}, names...))
30514 return c
30515 }
30516
30517
30518
30519 func (c *DynamicTargetingKeysListCall) ObjectId(objectId int64) *DynamicTargetingKeysListCall {
30520 c.urlParams_.Set("objectId", fmt.Sprint(objectId))
30521 return c
30522 }
30523
30524
30525
30526
30527
30528
30529
30530
30531
30532
30533 func (c *DynamicTargetingKeysListCall) ObjectType(objectType string) *DynamicTargetingKeysListCall {
30534 c.urlParams_.Set("objectType", objectType)
30535 return c
30536 }
30537
30538
30539
30540
30541 func (c *DynamicTargetingKeysListCall) Fields(s ...googleapi.Field) *DynamicTargetingKeysListCall {
30542 c.urlParams_.Set("fields", googleapi.CombineFields(s))
30543 return c
30544 }
30545
30546
30547
30548
30549
30550
30551 func (c *DynamicTargetingKeysListCall) IfNoneMatch(entityTag string) *DynamicTargetingKeysListCall {
30552 c.ifNoneMatch_ = entityTag
30553 return c
30554 }
30555
30556
30557
30558
30559 func (c *DynamicTargetingKeysListCall) Context(ctx context.Context) *DynamicTargetingKeysListCall {
30560 c.ctx_ = ctx
30561 return c
30562 }
30563
30564
30565
30566 func (c *DynamicTargetingKeysListCall) Header() http.Header {
30567 if c.header_ == nil {
30568 c.header_ = make(http.Header)
30569 }
30570 return c.header_
30571 }
30572
30573 func (c *DynamicTargetingKeysListCall) doRequest(alt string) (*http.Response, error) {
30574 reqHeaders := make(http.Header)
30575 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
30576 for k, v := range c.header_ {
30577 reqHeaders[k] = v
30578 }
30579 reqHeaders.Set("User-Agent", c.s.userAgent())
30580 if c.ifNoneMatch_ != "" {
30581 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
30582 }
30583 var body io.Reader = nil
30584 c.urlParams_.Set("alt", alt)
30585 c.urlParams_.Set("prettyPrint", "false")
30586 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/dynamicTargetingKeys")
30587 urls += "?" + c.urlParams_.Encode()
30588 req, err := http.NewRequest("GET", urls, body)
30589 if err != nil {
30590 return nil, err
30591 }
30592 req.Header = reqHeaders
30593 googleapi.Expand(req.URL, map[string]string{
30594 "profileId": strconv.FormatInt(c.profileId, 10),
30595 })
30596 return gensupport.SendRequest(c.ctx_, c.s.client, req)
30597 }
30598
30599
30600
30601
30602
30603
30604
30605
30606 func (c *DynamicTargetingKeysListCall) Do(opts ...googleapi.CallOption) (*DynamicTargetingKeysListResponse, error) {
30607 gensupport.SetOptions(c.urlParams_, opts...)
30608 res, err := c.doRequest("json")
30609 if res != nil && res.StatusCode == http.StatusNotModified {
30610 if res.Body != nil {
30611 res.Body.Close()
30612 }
30613 return nil, &googleapi.Error{
30614 Code: res.StatusCode,
30615 Header: res.Header,
30616 }
30617 }
30618 if err != nil {
30619 return nil, err
30620 }
30621 defer googleapi.CloseBody(res)
30622 if err := googleapi.CheckResponse(res); err != nil {
30623 return nil, err
30624 }
30625 ret := &DynamicTargetingKeysListResponse{
30626 ServerResponse: googleapi.ServerResponse{
30627 Header: res.Header,
30628 HTTPStatusCode: res.StatusCode,
30629 },
30630 }
30631 target := &ret
30632 if err := gensupport.DecodeResponse(target, res); err != nil {
30633 return nil, err
30634 }
30635 return ret, nil
30636
30637
30638
30639
30640
30641
30642
30643
30644
30645
30646
30647
30648
30649
30650
30651
30652
30653
30654
30655
30656
30657
30658
30659
30660
30661
30662
30663
30664
30665
30666
30667
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 EventTagsDeleteCall struct {
30701 s *Service
30702 profileId int64
30703 id int64
30704 urlParams_ gensupport.URLParams
30705 ctx_ context.Context
30706 header_ http.Header
30707 }
30708
30709
30710 func (r *EventTagsService) Delete(profileId int64, id int64) *EventTagsDeleteCall {
30711 c := &EventTagsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
30712 c.profileId = profileId
30713 c.id = id
30714 return c
30715 }
30716
30717
30718
30719
30720 func (c *EventTagsDeleteCall) Fields(s ...googleapi.Field) *EventTagsDeleteCall {
30721 c.urlParams_.Set("fields", googleapi.CombineFields(s))
30722 return c
30723 }
30724
30725
30726
30727
30728 func (c *EventTagsDeleteCall) Context(ctx context.Context) *EventTagsDeleteCall {
30729 c.ctx_ = ctx
30730 return c
30731 }
30732
30733
30734
30735 func (c *EventTagsDeleteCall) Header() http.Header {
30736 if c.header_ == nil {
30737 c.header_ = make(http.Header)
30738 }
30739 return c.header_
30740 }
30741
30742 func (c *EventTagsDeleteCall) doRequest(alt string) (*http.Response, error) {
30743 reqHeaders := make(http.Header)
30744 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
30745 for k, v := range c.header_ {
30746 reqHeaders[k] = v
30747 }
30748 reqHeaders.Set("User-Agent", c.s.userAgent())
30749 var body io.Reader = nil
30750 c.urlParams_.Set("alt", alt)
30751 c.urlParams_.Set("prettyPrint", "false")
30752 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/eventTags/{id}")
30753 urls += "?" + c.urlParams_.Encode()
30754 req, err := http.NewRequest("DELETE", urls, body)
30755 if err != nil {
30756 return nil, err
30757 }
30758 req.Header = reqHeaders
30759 googleapi.Expand(req.URL, map[string]string{
30760 "profileId": strconv.FormatInt(c.profileId, 10),
30761 "id": strconv.FormatInt(c.id, 10),
30762 })
30763 return gensupport.SendRequest(c.ctx_, c.s.client, req)
30764 }
30765
30766
30767 func (c *EventTagsDeleteCall) Do(opts ...googleapi.CallOption) error {
30768 gensupport.SetOptions(c.urlParams_, opts...)
30769 res, err := c.doRequest("json")
30770 if err != nil {
30771 return err
30772 }
30773 defer googleapi.CloseBody(res)
30774 if err := googleapi.CheckResponse(res); err != nil {
30775 return err
30776 }
30777 return nil
30778
30779
30780
30781
30782
30783
30784
30785
30786
30787
30788
30789
30790
30791
30792
30793
30794
30795
30796
30797
30798
30799
30800
30801
30802
30803
30804
30805
30806
30807
30808 }
30809
30810
30811
30812 type EventTagsGetCall struct {
30813 s *Service
30814 profileId int64
30815 id int64
30816 urlParams_ gensupport.URLParams
30817 ifNoneMatch_ string
30818 ctx_ context.Context
30819 header_ http.Header
30820 }
30821
30822
30823 func (r *EventTagsService) Get(profileId int64, id int64) *EventTagsGetCall {
30824 c := &EventTagsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
30825 c.profileId = profileId
30826 c.id = id
30827 return c
30828 }
30829
30830
30831
30832
30833 func (c *EventTagsGetCall) Fields(s ...googleapi.Field) *EventTagsGetCall {
30834 c.urlParams_.Set("fields", googleapi.CombineFields(s))
30835 return c
30836 }
30837
30838
30839
30840
30841
30842
30843 func (c *EventTagsGetCall) IfNoneMatch(entityTag string) *EventTagsGetCall {
30844 c.ifNoneMatch_ = entityTag
30845 return c
30846 }
30847
30848
30849
30850
30851 func (c *EventTagsGetCall) Context(ctx context.Context) *EventTagsGetCall {
30852 c.ctx_ = ctx
30853 return c
30854 }
30855
30856
30857
30858 func (c *EventTagsGetCall) Header() http.Header {
30859 if c.header_ == nil {
30860 c.header_ = make(http.Header)
30861 }
30862 return c.header_
30863 }
30864
30865 func (c *EventTagsGetCall) doRequest(alt string) (*http.Response, error) {
30866 reqHeaders := make(http.Header)
30867 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
30868 for k, v := range c.header_ {
30869 reqHeaders[k] = v
30870 }
30871 reqHeaders.Set("User-Agent", c.s.userAgent())
30872 if c.ifNoneMatch_ != "" {
30873 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
30874 }
30875 var body io.Reader = nil
30876 c.urlParams_.Set("alt", alt)
30877 c.urlParams_.Set("prettyPrint", "false")
30878 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/eventTags/{id}")
30879 urls += "?" + c.urlParams_.Encode()
30880 req, err := http.NewRequest("GET", urls, body)
30881 if err != nil {
30882 return nil, err
30883 }
30884 req.Header = reqHeaders
30885 googleapi.Expand(req.URL, map[string]string{
30886 "profileId": strconv.FormatInt(c.profileId, 10),
30887 "id": strconv.FormatInt(c.id, 10),
30888 })
30889 return gensupport.SendRequest(c.ctx_, c.s.client, req)
30890 }
30891
30892
30893
30894
30895
30896
30897
30898
30899 func (c *EventTagsGetCall) Do(opts ...googleapi.CallOption) (*EventTag, error) {
30900 gensupport.SetOptions(c.urlParams_, opts...)
30901 res, err := c.doRequest("json")
30902 if res != nil && res.StatusCode == http.StatusNotModified {
30903 if res.Body != nil {
30904 res.Body.Close()
30905 }
30906 return nil, &googleapi.Error{
30907 Code: res.StatusCode,
30908 Header: res.Header,
30909 }
30910 }
30911 if err != nil {
30912 return nil, err
30913 }
30914 defer googleapi.CloseBody(res)
30915 if err := googleapi.CheckResponse(res); err != nil {
30916 return nil, err
30917 }
30918 ret := &EventTag{
30919 ServerResponse: googleapi.ServerResponse{
30920 Header: res.Header,
30921 HTTPStatusCode: res.StatusCode,
30922 },
30923 }
30924 target := &ret
30925 if err := gensupport.DecodeResponse(target, res); err != nil {
30926 return nil, err
30927 }
30928 return ret, nil
30929
30930
30931
30932
30933
30934
30935
30936
30937
30938
30939
30940
30941
30942
30943
30944
30945
30946
30947
30948
30949
30950
30951
30952
30953
30954
30955
30956
30957
30958
30959
30960
30961
30962 }
30963
30964
30965
30966 type EventTagsInsertCall struct {
30967 s *Service
30968 profileId int64
30969 eventtag *EventTag
30970 urlParams_ gensupport.URLParams
30971 ctx_ context.Context
30972 header_ http.Header
30973 }
30974
30975
30976 func (r *EventTagsService) Insert(profileId int64, eventtag *EventTag) *EventTagsInsertCall {
30977 c := &EventTagsInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
30978 c.profileId = profileId
30979 c.eventtag = eventtag
30980 return c
30981 }
30982
30983
30984
30985
30986 func (c *EventTagsInsertCall) Fields(s ...googleapi.Field) *EventTagsInsertCall {
30987 c.urlParams_.Set("fields", googleapi.CombineFields(s))
30988 return c
30989 }
30990
30991
30992
30993
30994 func (c *EventTagsInsertCall) Context(ctx context.Context) *EventTagsInsertCall {
30995 c.ctx_ = ctx
30996 return c
30997 }
30998
30999
31000
31001 func (c *EventTagsInsertCall) Header() http.Header {
31002 if c.header_ == nil {
31003 c.header_ = make(http.Header)
31004 }
31005 return c.header_
31006 }
31007
31008 func (c *EventTagsInsertCall) doRequest(alt string) (*http.Response, error) {
31009 reqHeaders := make(http.Header)
31010 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
31011 for k, v := range c.header_ {
31012 reqHeaders[k] = v
31013 }
31014 reqHeaders.Set("User-Agent", c.s.userAgent())
31015 var body io.Reader = nil
31016 body, err := googleapi.WithoutDataWrapper.JSONReader(c.eventtag)
31017 if err != nil {
31018 return nil, err
31019 }
31020 reqHeaders.Set("Content-Type", "application/json")
31021 c.urlParams_.Set("alt", alt)
31022 c.urlParams_.Set("prettyPrint", "false")
31023 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/eventTags")
31024 urls += "?" + c.urlParams_.Encode()
31025 req, err := http.NewRequest("POST", urls, body)
31026 if err != nil {
31027 return nil, err
31028 }
31029 req.Header = reqHeaders
31030 googleapi.Expand(req.URL, map[string]string{
31031 "profileId": strconv.FormatInt(c.profileId, 10),
31032 })
31033 return gensupport.SendRequest(c.ctx_, c.s.client, req)
31034 }
31035
31036
31037
31038
31039
31040
31041
31042
31043 func (c *EventTagsInsertCall) Do(opts ...googleapi.CallOption) (*EventTag, error) {
31044 gensupport.SetOptions(c.urlParams_, opts...)
31045 res, err := c.doRequest("json")
31046 if res != nil && res.StatusCode == http.StatusNotModified {
31047 if res.Body != nil {
31048 res.Body.Close()
31049 }
31050 return nil, &googleapi.Error{
31051 Code: res.StatusCode,
31052 Header: res.Header,
31053 }
31054 }
31055 if err != nil {
31056 return nil, err
31057 }
31058 defer googleapi.CloseBody(res)
31059 if err := googleapi.CheckResponse(res); err != nil {
31060 return nil, err
31061 }
31062 ret := &EventTag{
31063 ServerResponse: googleapi.ServerResponse{
31064 Header: res.Header,
31065 HTTPStatusCode: res.StatusCode,
31066 },
31067 }
31068 target := &ret
31069 if err := gensupport.DecodeResponse(target, res); err != nil {
31070 return nil, err
31071 }
31072 return ret, nil
31073
31074
31075
31076
31077
31078
31079
31080
31081
31082
31083
31084
31085
31086
31087
31088
31089
31090
31091
31092
31093
31094
31095
31096
31097
31098
31099
31100
31101 }
31102
31103
31104
31105 type EventTagsListCall struct {
31106 s *Service
31107 profileId int64
31108 urlParams_ gensupport.URLParams
31109 ifNoneMatch_ string
31110 ctx_ context.Context
31111 header_ http.Header
31112 }
31113
31114
31115 func (r *EventTagsService) List(profileId int64) *EventTagsListCall {
31116 c := &EventTagsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
31117 c.profileId = profileId
31118 return c
31119 }
31120
31121
31122
31123 func (c *EventTagsListCall) AdId(adId int64) *EventTagsListCall {
31124 c.urlParams_.Set("adId", fmt.Sprint(adId))
31125 return c
31126 }
31127
31128
31129
31130 func (c *EventTagsListCall) AdvertiserId(advertiserId int64) *EventTagsListCall {
31131 c.urlParams_.Set("advertiserId", fmt.Sprint(advertiserId))
31132 return c
31133 }
31134
31135
31136
31137 func (c *EventTagsListCall) CampaignId(campaignId int64) *EventTagsListCall {
31138 c.urlParams_.Set("campaignId", fmt.Sprint(campaignId))
31139 return c
31140 }
31141
31142
31143
31144
31145
31146
31147
31148
31149
31150 func (c *EventTagsListCall) DefinitionsOnly(definitionsOnly bool) *EventTagsListCall {
31151 c.urlParams_.Set("definitionsOnly", fmt.Sprint(definitionsOnly))
31152 return c
31153 }
31154
31155
31156
31157
31158
31159
31160
31161
31162
31163 func (c *EventTagsListCall) Enabled(enabled bool) *EventTagsListCall {
31164 c.urlParams_.Set("enabled", fmt.Sprint(enabled))
31165 return c
31166 }
31167
31168
31169
31170
31171
31172
31173
31174
31175
31176
31177
31178
31179 func (c *EventTagsListCall) EventTagTypes(eventTagTypes ...string) *EventTagsListCall {
31180 c.urlParams_.SetMulti("eventTagTypes", append([]string{}, eventTagTypes...))
31181 return c
31182 }
31183
31184
31185
31186 func (c *EventTagsListCall) Ids(ids ...int64) *EventTagsListCall {
31187 var ids_ []string
31188 for _, v := range ids {
31189 ids_ = append(ids_, fmt.Sprint(v))
31190 }
31191 c.urlParams_.SetMulti("ids", ids_)
31192 return c
31193 }
31194
31195
31196
31197
31198
31199
31200
31201
31202
31203 func (c *EventTagsListCall) SearchString(searchString string) *EventTagsListCall {
31204 c.urlParams_.Set("searchString", searchString)
31205 return c
31206 }
31207
31208
31209
31210
31211
31212
31213
31214
31215 func (c *EventTagsListCall) SortField(sortField string) *EventTagsListCall {
31216 c.urlParams_.Set("sortField", sortField)
31217 return c
31218 }
31219
31220
31221
31222
31223
31224
31225
31226
31227 func (c *EventTagsListCall) SortOrder(sortOrder string) *EventTagsListCall {
31228 c.urlParams_.Set("sortOrder", sortOrder)
31229 return c
31230 }
31231
31232
31233
31234
31235 func (c *EventTagsListCall) Fields(s ...googleapi.Field) *EventTagsListCall {
31236 c.urlParams_.Set("fields", googleapi.CombineFields(s))
31237 return c
31238 }
31239
31240
31241
31242
31243
31244
31245 func (c *EventTagsListCall) IfNoneMatch(entityTag string) *EventTagsListCall {
31246 c.ifNoneMatch_ = entityTag
31247 return c
31248 }
31249
31250
31251
31252
31253 func (c *EventTagsListCall) Context(ctx context.Context) *EventTagsListCall {
31254 c.ctx_ = ctx
31255 return c
31256 }
31257
31258
31259
31260 func (c *EventTagsListCall) Header() http.Header {
31261 if c.header_ == nil {
31262 c.header_ = make(http.Header)
31263 }
31264 return c.header_
31265 }
31266
31267 func (c *EventTagsListCall) doRequest(alt string) (*http.Response, error) {
31268 reqHeaders := make(http.Header)
31269 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
31270 for k, v := range c.header_ {
31271 reqHeaders[k] = v
31272 }
31273 reqHeaders.Set("User-Agent", c.s.userAgent())
31274 if c.ifNoneMatch_ != "" {
31275 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
31276 }
31277 var body io.Reader = nil
31278 c.urlParams_.Set("alt", alt)
31279 c.urlParams_.Set("prettyPrint", "false")
31280 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/eventTags")
31281 urls += "?" + c.urlParams_.Encode()
31282 req, err := http.NewRequest("GET", urls, body)
31283 if err != nil {
31284 return nil, err
31285 }
31286 req.Header = reqHeaders
31287 googleapi.Expand(req.URL, map[string]string{
31288 "profileId": strconv.FormatInt(c.profileId, 10),
31289 })
31290 return gensupport.SendRequest(c.ctx_, c.s.client, req)
31291 }
31292
31293
31294
31295
31296
31297
31298
31299
31300 func (c *EventTagsListCall) Do(opts ...googleapi.CallOption) (*EventTagsListResponse, error) {
31301 gensupport.SetOptions(c.urlParams_, opts...)
31302 res, err := c.doRequest("json")
31303 if res != nil && res.StatusCode == http.StatusNotModified {
31304 if res.Body != nil {
31305 res.Body.Close()
31306 }
31307 return nil, &googleapi.Error{
31308 Code: res.StatusCode,
31309 Header: res.Header,
31310 }
31311 }
31312 if err != nil {
31313 return nil, err
31314 }
31315 defer googleapi.CloseBody(res)
31316 if err := googleapi.CheckResponse(res); err != nil {
31317 return nil, err
31318 }
31319 ret := &EventTagsListResponse{
31320 ServerResponse: googleapi.ServerResponse{
31321 Header: res.Header,
31322 HTTPStatusCode: res.StatusCode,
31323 },
31324 }
31325 target := &ret
31326 if err := gensupport.DecodeResponse(target, res); err != nil {
31327 return nil, err
31328 }
31329 return ret, nil
31330
31331
31332
31333
31334
31335
31336
31337
31338
31339
31340
31341
31342
31343
31344
31345
31346
31347
31348
31349
31350
31351
31352
31353
31354
31355
31356
31357
31358
31359
31360
31361
31362
31363
31364
31365
31366
31367
31368
31369
31370
31371
31372
31373
31374
31375
31376
31377
31378
31379
31380
31381
31382
31383
31384
31385
31386
31387
31388
31389
31390
31391
31392
31393
31394
31395
31396
31397
31398
31399
31400
31401
31402
31403
31404
31405
31406
31407
31408
31409
31410
31411
31412
31413
31414
31415
31416
31417
31418
31419
31420
31421
31422
31423
31424
31425
31426
31427
31428
31429
31430
31431
31432
31433
31434
31435
31436
31437
31438
31439 }
31440
31441
31442
31443 type EventTagsPatchCall struct {
31444 s *Service
31445 profileId int64
31446 eventtag *EventTag
31447 urlParams_ gensupport.URLParams
31448 ctx_ context.Context
31449 header_ http.Header
31450 }
31451
31452
31453
31454 func (r *EventTagsService) Patch(profileId int64, id int64, eventtag *EventTag) *EventTagsPatchCall {
31455 c := &EventTagsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
31456 c.profileId = profileId
31457 c.urlParams_.Set("id", fmt.Sprint(id))
31458 c.eventtag = eventtag
31459 return c
31460 }
31461
31462
31463
31464
31465 func (c *EventTagsPatchCall) Fields(s ...googleapi.Field) *EventTagsPatchCall {
31466 c.urlParams_.Set("fields", googleapi.CombineFields(s))
31467 return c
31468 }
31469
31470
31471
31472
31473 func (c *EventTagsPatchCall) Context(ctx context.Context) *EventTagsPatchCall {
31474 c.ctx_ = ctx
31475 return c
31476 }
31477
31478
31479
31480 func (c *EventTagsPatchCall) Header() http.Header {
31481 if c.header_ == nil {
31482 c.header_ = make(http.Header)
31483 }
31484 return c.header_
31485 }
31486
31487 func (c *EventTagsPatchCall) doRequest(alt string) (*http.Response, error) {
31488 reqHeaders := make(http.Header)
31489 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
31490 for k, v := range c.header_ {
31491 reqHeaders[k] = v
31492 }
31493 reqHeaders.Set("User-Agent", c.s.userAgent())
31494 var body io.Reader = nil
31495 body, err := googleapi.WithoutDataWrapper.JSONReader(c.eventtag)
31496 if err != nil {
31497 return nil, err
31498 }
31499 reqHeaders.Set("Content-Type", "application/json")
31500 c.urlParams_.Set("alt", alt)
31501 c.urlParams_.Set("prettyPrint", "false")
31502 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/eventTags")
31503 urls += "?" + c.urlParams_.Encode()
31504 req, err := http.NewRequest("PATCH", urls, body)
31505 if err != nil {
31506 return nil, err
31507 }
31508 req.Header = reqHeaders
31509 googleapi.Expand(req.URL, map[string]string{
31510 "profileId": strconv.FormatInt(c.profileId, 10),
31511 })
31512 return gensupport.SendRequest(c.ctx_, c.s.client, req)
31513 }
31514
31515
31516
31517
31518
31519
31520
31521
31522 func (c *EventTagsPatchCall) Do(opts ...googleapi.CallOption) (*EventTag, error) {
31523 gensupport.SetOptions(c.urlParams_, opts...)
31524 res, err := c.doRequest("json")
31525 if res != nil && res.StatusCode == http.StatusNotModified {
31526 if res.Body != nil {
31527 res.Body.Close()
31528 }
31529 return nil, &googleapi.Error{
31530 Code: res.StatusCode,
31531 Header: res.Header,
31532 }
31533 }
31534 if err != nil {
31535 return nil, err
31536 }
31537 defer googleapi.CloseBody(res)
31538 if err := googleapi.CheckResponse(res); err != nil {
31539 return nil, err
31540 }
31541 ret := &EventTag{
31542 ServerResponse: googleapi.ServerResponse{
31543 Header: res.Header,
31544 HTTPStatusCode: res.StatusCode,
31545 },
31546 }
31547 target := &ret
31548 if err := gensupport.DecodeResponse(target, res); err != nil {
31549 return nil, err
31550 }
31551 return ret, nil
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 type EventTagsUpdateCall struct {
31593 s *Service
31594 profileId int64
31595 eventtag *EventTag
31596 urlParams_ gensupport.URLParams
31597 ctx_ context.Context
31598 header_ http.Header
31599 }
31600
31601
31602 func (r *EventTagsService) Update(profileId int64, eventtag *EventTag) *EventTagsUpdateCall {
31603 c := &EventTagsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
31604 c.profileId = profileId
31605 c.eventtag = eventtag
31606 return c
31607 }
31608
31609
31610
31611
31612 func (c *EventTagsUpdateCall) Fields(s ...googleapi.Field) *EventTagsUpdateCall {
31613 c.urlParams_.Set("fields", googleapi.CombineFields(s))
31614 return c
31615 }
31616
31617
31618
31619
31620 func (c *EventTagsUpdateCall) Context(ctx context.Context) *EventTagsUpdateCall {
31621 c.ctx_ = ctx
31622 return c
31623 }
31624
31625
31626
31627 func (c *EventTagsUpdateCall) Header() http.Header {
31628 if c.header_ == nil {
31629 c.header_ = make(http.Header)
31630 }
31631 return c.header_
31632 }
31633
31634 func (c *EventTagsUpdateCall) doRequest(alt string) (*http.Response, error) {
31635 reqHeaders := make(http.Header)
31636 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
31637 for k, v := range c.header_ {
31638 reqHeaders[k] = v
31639 }
31640 reqHeaders.Set("User-Agent", c.s.userAgent())
31641 var body io.Reader = nil
31642 body, err := googleapi.WithoutDataWrapper.JSONReader(c.eventtag)
31643 if err != nil {
31644 return nil, err
31645 }
31646 reqHeaders.Set("Content-Type", "application/json")
31647 c.urlParams_.Set("alt", alt)
31648 c.urlParams_.Set("prettyPrint", "false")
31649 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/eventTags")
31650 urls += "?" + c.urlParams_.Encode()
31651 req, err := http.NewRequest("PUT", urls, body)
31652 if err != nil {
31653 return nil, err
31654 }
31655 req.Header = reqHeaders
31656 googleapi.Expand(req.URL, map[string]string{
31657 "profileId": strconv.FormatInt(c.profileId, 10),
31658 })
31659 return gensupport.SendRequest(c.ctx_, c.s.client, req)
31660 }
31661
31662
31663
31664
31665
31666
31667
31668
31669 func (c *EventTagsUpdateCall) Do(opts ...googleapi.CallOption) (*EventTag, error) {
31670 gensupport.SetOptions(c.urlParams_, opts...)
31671 res, err := c.doRequest("json")
31672 if res != nil && res.StatusCode == http.StatusNotModified {
31673 if res.Body != nil {
31674 res.Body.Close()
31675 }
31676 return nil, &googleapi.Error{
31677 Code: res.StatusCode,
31678 Header: res.Header,
31679 }
31680 }
31681 if err != nil {
31682 return nil, err
31683 }
31684 defer googleapi.CloseBody(res)
31685 if err := googleapi.CheckResponse(res); err != nil {
31686 return nil, err
31687 }
31688 ret := &EventTag{
31689 ServerResponse: googleapi.ServerResponse{
31690 Header: res.Header,
31691 HTTPStatusCode: res.StatusCode,
31692 },
31693 }
31694 target := &ret
31695 if err := gensupport.DecodeResponse(target, res); err != nil {
31696 return nil, err
31697 }
31698 return ret, nil
31699
31700
31701
31702
31703
31704
31705
31706
31707
31708
31709
31710
31711
31712
31713
31714
31715
31716
31717
31718
31719
31720
31721
31722
31723
31724
31725
31726
31727 }
31728
31729
31730
31731 type FilesGetCall struct {
31732 s *Service
31733 reportId int64
31734 fileId int64
31735 urlParams_ gensupport.URLParams
31736 ifNoneMatch_ string
31737 ctx_ context.Context
31738 header_ http.Header
31739 }
31740
31741
31742
31743 func (r *FilesService) Get(reportId int64, fileId int64) *FilesGetCall {
31744 c := &FilesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
31745 c.reportId = reportId
31746 c.fileId = fileId
31747 return c
31748 }
31749
31750
31751
31752
31753 func (c *FilesGetCall) Fields(s ...googleapi.Field) *FilesGetCall {
31754 c.urlParams_.Set("fields", googleapi.CombineFields(s))
31755 return c
31756 }
31757
31758
31759
31760
31761
31762
31763 func (c *FilesGetCall) IfNoneMatch(entityTag string) *FilesGetCall {
31764 c.ifNoneMatch_ = entityTag
31765 return c
31766 }
31767
31768
31769
31770
31771 func (c *FilesGetCall) Context(ctx context.Context) *FilesGetCall {
31772 c.ctx_ = ctx
31773 return c
31774 }
31775
31776
31777
31778 func (c *FilesGetCall) Header() http.Header {
31779 if c.header_ == nil {
31780 c.header_ = make(http.Header)
31781 }
31782 return c.header_
31783 }
31784
31785 func (c *FilesGetCall) doRequest(alt string) (*http.Response, error) {
31786 reqHeaders := make(http.Header)
31787 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
31788 for k, v := range c.header_ {
31789 reqHeaders[k] = v
31790 }
31791 reqHeaders.Set("User-Agent", c.s.userAgent())
31792 if c.ifNoneMatch_ != "" {
31793 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
31794 }
31795 var body io.Reader = nil
31796 c.urlParams_.Set("alt", alt)
31797 c.urlParams_.Set("prettyPrint", "false")
31798 urls := googleapi.ResolveRelative(c.s.BasePath, "reports/{reportId}/files/{fileId}")
31799 urls += "?" + c.urlParams_.Encode()
31800 req, err := http.NewRequest("GET", urls, body)
31801 if err != nil {
31802 return nil, err
31803 }
31804 req.Header = reqHeaders
31805 googleapi.Expand(req.URL, map[string]string{
31806 "reportId": strconv.FormatInt(c.reportId, 10),
31807 "fileId": strconv.FormatInt(c.fileId, 10),
31808 })
31809 return gensupport.SendRequest(c.ctx_, c.s.client, req)
31810 }
31811
31812
31813
31814
31815 func (c *FilesGetCall) Download(opts ...googleapi.CallOption) (*http.Response, error) {
31816 gensupport.SetOptions(c.urlParams_, opts...)
31817 res, err := c.doRequest("media")
31818 if err != nil {
31819 return nil, err
31820 }
31821 if err := googleapi.CheckMediaResponse(res); err != nil {
31822 res.Body.Close()
31823 return nil, err
31824 }
31825 return res, nil
31826 }
31827
31828
31829
31830
31831
31832
31833
31834
31835 func (c *FilesGetCall) Do(opts ...googleapi.CallOption) (*File, error) {
31836 gensupport.SetOptions(c.urlParams_, opts...)
31837 res, err := c.doRequest("json")
31838 if res != nil && res.StatusCode == http.StatusNotModified {
31839 if res.Body != nil {
31840 res.Body.Close()
31841 }
31842 return nil, &googleapi.Error{
31843 Code: res.StatusCode,
31844 Header: res.Header,
31845 }
31846 }
31847 if err != nil {
31848 return nil, err
31849 }
31850 defer googleapi.CloseBody(res)
31851 if err := googleapi.CheckResponse(res); err != nil {
31852 return nil, err
31853 }
31854 ret := &File{
31855 ServerResponse: googleapi.ServerResponse{
31856 Header: res.Header,
31857 HTTPStatusCode: res.StatusCode,
31858 },
31859 }
31860 target := &ret
31861 if err := gensupport.DecodeResponse(target, res); err != nil {
31862 return nil, err
31863 }
31864 return ret, nil
31865
31866
31867
31868
31869
31870
31871
31872
31873
31874
31875
31876
31877
31878
31879
31880
31881
31882
31883
31884
31885
31886
31887
31888
31889
31890
31891
31892
31893
31894
31895
31896
31897
31898
31899 }
31900
31901
31902
31903 type FilesListCall struct {
31904 s *Service
31905 profileId int64
31906 urlParams_ gensupport.URLParams
31907 ifNoneMatch_ string
31908 ctx_ context.Context
31909 header_ http.Header
31910 }
31911
31912
31913 func (r *FilesService) List(profileId int64) *FilesListCall {
31914 c := &FilesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
31915 c.profileId = profileId
31916 return c
31917 }
31918
31919
31920
31921 func (c *FilesListCall) MaxResults(maxResults int64) *FilesListCall {
31922 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
31923 return c
31924 }
31925
31926
31927
31928 func (c *FilesListCall) PageToken(pageToken string) *FilesListCall {
31929 c.urlParams_.Set("pageToken", pageToken)
31930 return c
31931 }
31932
31933
31934
31935
31936
31937
31938
31939
31940
31941 func (c *FilesListCall) Scope(scope string) *FilesListCall {
31942 c.urlParams_.Set("scope", scope)
31943 return c
31944 }
31945
31946
31947
31948
31949
31950
31951
31952
31953 func (c *FilesListCall) SortField(sortField string) *FilesListCall {
31954 c.urlParams_.Set("sortField", sortField)
31955 return c
31956 }
31957
31958
31959
31960
31961
31962
31963
31964
31965 func (c *FilesListCall) SortOrder(sortOrder string) *FilesListCall {
31966 c.urlParams_.Set("sortOrder", sortOrder)
31967 return c
31968 }
31969
31970
31971
31972
31973 func (c *FilesListCall) Fields(s ...googleapi.Field) *FilesListCall {
31974 c.urlParams_.Set("fields", googleapi.CombineFields(s))
31975 return c
31976 }
31977
31978
31979
31980
31981
31982
31983 func (c *FilesListCall) IfNoneMatch(entityTag string) *FilesListCall {
31984 c.ifNoneMatch_ = entityTag
31985 return c
31986 }
31987
31988
31989
31990
31991 func (c *FilesListCall) Context(ctx context.Context) *FilesListCall {
31992 c.ctx_ = ctx
31993 return c
31994 }
31995
31996
31997
31998 func (c *FilesListCall) Header() http.Header {
31999 if c.header_ == nil {
32000 c.header_ = make(http.Header)
32001 }
32002 return c.header_
32003 }
32004
32005 func (c *FilesListCall) doRequest(alt string) (*http.Response, error) {
32006 reqHeaders := make(http.Header)
32007 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
32008 for k, v := range c.header_ {
32009 reqHeaders[k] = v
32010 }
32011 reqHeaders.Set("User-Agent", c.s.userAgent())
32012 if c.ifNoneMatch_ != "" {
32013 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
32014 }
32015 var body io.Reader = nil
32016 c.urlParams_.Set("alt", alt)
32017 c.urlParams_.Set("prettyPrint", "false")
32018 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/files")
32019 urls += "?" + c.urlParams_.Encode()
32020 req, err := http.NewRequest("GET", urls, body)
32021 if err != nil {
32022 return nil, err
32023 }
32024 req.Header = reqHeaders
32025 googleapi.Expand(req.URL, map[string]string{
32026 "profileId": strconv.FormatInt(c.profileId, 10),
32027 })
32028 return gensupport.SendRequest(c.ctx_, c.s.client, req)
32029 }
32030
32031
32032
32033
32034
32035
32036
32037
32038 func (c *FilesListCall) Do(opts ...googleapi.CallOption) (*FileList, error) {
32039 gensupport.SetOptions(c.urlParams_, opts...)
32040 res, err := c.doRequest("json")
32041 if res != nil && res.StatusCode == http.StatusNotModified {
32042 if res.Body != nil {
32043 res.Body.Close()
32044 }
32045 return nil, &googleapi.Error{
32046 Code: res.StatusCode,
32047 Header: res.Header,
32048 }
32049 }
32050 if err != nil {
32051 return nil, err
32052 }
32053 defer googleapi.CloseBody(res)
32054 if err := googleapi.CheckResponse(res); err != nil {
32055 return nil, err
32056 }
32057 ret := &FileList{
32058 ServerResponse: googleapi.ServerResponse{
32059 Header: res.Header,
32060 HTTPStatusCode: res.StatusCode,
32061 },
32062 }
32063 target := &ret
32064 if err := gensupport.DecodeResponse(target, res); err != nil {
32065 return nil, err
32066 }
32067 return ret, nil
32068
32069
32070
32071
32072
32073
32074
32075
32076
32077
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
32117
32118
32119
32120
32121
32122
32123
32124
32125
32126
32127
32128
32129
32130
32131
32132
32133
32134
32135
32136
32137
32138
32139
32140
32141
32142
32143
32144
32145
32146
32147
32148
32149
32150
32151 }
32152
32153
32154
32155
32156 func (c *FilesListCall) Pages(ctx context.Context, f func(*FileList) error) error {
32157 c.ctx_ = ctx
32158 defer c.PageToken(c.urlParams_.Get("pageToken"))
32159 for {
32160 x, err := c.Do()
32161 if err != nil {
32162 return err
32163 }
32164 if err := f(x); err != nil {
32165 return err
32166 }
32167 if x.NextPageToken == "" {
32168 return nil
32169 }
32170 c.PageToken(x.NextPageToken)
32171 }
32172 }
32173
32174
32175
32176 type FloodlightActivitiesDeleteCall struct {
32177 s *Service
32178 profileId int64
32179 id int64
32180 urlParams_ gensupport.URLParams
32181 ctx_ context.Context
32182 header_ http.Header
32183 }
32184
32185
32186 func (r *FloodlightActivitiesService) Delete(profileId int64, id int64) *FloodlightActivitiesDeleteCall {
32187 c := &FloodlightActivitiesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
32188 c.profileId = profileId
32189 c.id = id
32190 return c
32191 }
32192
32193
32194
32195
32196 func (c *FloodlightActivitiesDeleteCall) Fields(s ...googleapi.Field) *FloodlightActivitiesDeleteCall {
32197 c.urlParams_.Set("fields", googleapi.CombineFields(s))
32198 return c
32199 }
32200
32201
32202
32203
32204 func (c *FloodlightActivitiesDeleteCall) Context(ctx context.Context) *FloodlightActivitiesDeleteCall {
32205 c.ctx_ = ctx
32206 return c
32207 }
32208
32209
32210
32211 func (c *FloodlightActivitiesDeleteCall) Header() http.Header {
32212 if c.header_ == nil {
32213 c.header_ = make(http.Header)
32214 }
32215 return c.header_
32216 }
32217
32218 func (c *FloodlightActivitiesDeleteCall) 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 var body io.Reader = nil
32226 c.urlParams_.Set("alt", alt)
32227 c.urlParams_.Set("prettyPrint", "false")
32228 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/floodlightActivities/{id}")
32229 urls += "?" + c.urlParams_.Encode()
32230 req, err := http.NewRequest("DELETE", urls, body)
32231 if err != nil {
32232 return nil, err
32233 }
32234 req.Header = reqHeaders
32235 googleapi.Expand(req.URL, map[string]string{
32236 "profileId": strconv.FormatInt(c.profileId, 10),
32237 "id": strconv.FormatInt(c.id, 10),
32238 })
32239 return gensupport.SendRequest(c.ctx_, c.s.client, req)
32240 }
32241
32242
32243 func (c *FloodlightActivitiesDeleteCall) Do(opts ...googleapi.CallOption) error {
32244 gensupport.SetOptions(c.urlParams_, opts...)
32245 res, err := c.doRequest("json")
32246 if err != nil {
32247 return err
32248 }
32249 defer googleapi.CloseBody(res)
32250 if err := googleapi.CheckResponse(res); err != nil {
32251 return err
32252 }
32253 return nil
32254
32255
32256
32257
32258
32259
32260
32261
32262
32263
32264
32265
32266
32267
32268
32269
32270
32271
32272
32273
32274
32275
32276
32277
32278
32279
32280
32281
32282
32283
32284 }
32285
32286
32287
32288 type FloodlightActivitiesGeneratetagCall struct {
32289 s *Service
32290 profileId int64
32291 urlParams_ gensupport.URLParams
32292 ctx_ context.Context
32293 header_ http.Header
32294 }
32295
32296
32297 func (r *FloodlightActivitiesService) Generatetag(profileId int64) *FloodlightActivitiesGeneratetagCall {
32298 c := &FloodlightActivitiesGeneratetagCall{s: r.s, urlParams_: make(gensupport.URLParams)}
32299 c.profileId = profileId
32300 return c
32301 }
32302
32303
32304
32305
32306 func (c *FloodlightActivitiesGeneratetagCall) FloodlightActivityId(floodlightActivityId int64) *FloodlightActivitiesGeneratetagCall {
32307 c.urlParams_.Set("floodlightActivityId", fmt.Sprint(floodlightActivityId))
32308 return c
32309 }
32310
32311
32312
32313
32314 func (c *FloodlightActivitiesGeneratetagCall) Fields(s ...googleapi.Field) *FloodlightActivitiesGeneratetagCall {
32315 c.urlParams_.Set("fields", googleapi.CombineFields(s))
32316 return c
32317 }
32318
32319
32320
32321
32322 func (c *FloodlightActivitiesGeneratetagCall) Context(ctx context.Context) *FloodlightActivitiesGeneratetagCall {
32323 c.ctx_ = ctx
32324 return c
32325 }
32326
32327
32328
32329 func (c *FloodlightActivitiesGeneratetagCall) Header() http.Header {
32330 if c.header_ == nil {
32331 c.header_ = make(http.Header)
32332 }
32333 return c.header_
32334 }
32335
32336 func (c *FloodlightActivitiesGeneratetagCall) doRequest(alt string) (*http.Response, error) {
32337 reqHeaders := make(http.Header)
32338 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
32339 for k, v := range c.header_ {
32340 reqHeaders[k] = v
32341 }
32342 reqHeaders.Set("User-Agent", c.s.userAgent())
32343 var body io.Reader = nil
32344 c.urlParams_.Set("alt", alt)
32345 c.urlParams_.Set("prettyPrint", "false")
32346 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/floodlightActivities/generatetag")
32347 urls += "?" + c.urlParams_.Encode()
32348 req, err := http.NewRequest("POST", urls, body)
32349 if err != nil {
32350 return nil, err
32351 }
32352 req.Header = reqHeaders
32353 googleapi.Expand(req.URL, map[string]string{
32354 "profileId": strconv.FormatInt(c.profileId, 10),
32355 })
32356 return gensupport.SendRequest(c.ctx_, c.s.client, req)
32357 }
32358
32359
32360
32361
32362
32363
32364
32365
32366
32367 func (c *FloodlightActivitiesGeneratetagCall) Do(opts ...googleapi.CallOption) (*FloodlightActivitiesGenerateTagResponse, error) {
32368 gensupport.SetOptions(c.urlParams_, opts...)
32369 res, err := c.doRequest("json")
32370 if res != nil && res.StatusCode == http.StatusNotModified {
32371 if res.Body != nil {
32372 res.Body.Close()
32373 }
32374 return nil, &googleapi.Error{
32375 Code: res.StatusCode,
32376 Header: res.Header,
32377 }
32378 }
32379 if err != nil {
32380 return nil, err
32381 }
32382 defer googleapi.CloseBody(res)
32383 if err := googleapi.CheckResponse(res); err != nil {
32384 return nil, err
32385 }
32386 ret := &FloodlightActivitiesGenerateTagResponse{
32387 ServerResponse: googleapi.ServerResponse{
32388 Header: res.Header,
32389 HTTPStatusCode: res.StatusCode,
32390 },
32391 }
32392 target := &ret
32393 if err := gensupport.DecodeResponse(target, res); err != nil {
32394 return nil, err
32395 }
32396 return ret, nil
32397
32398
32399
32400
32401
32402
32403
32404
32405
32406
32407
32408
32409
32410
32411
32412
32413
32414
32415
32416
32417
32418
32419
32420
32421
32422
32423
32424
32425
32426
32427
32428 }
32429
32430
32431
32432 type FloodlightActivitiesGetCall struct {
32433 s *Service
32434 profileId int64
32435 id int64
32436 urlParams_ gensupport.URLParams
32437 ifNoneMatch_ string
32438 ctx_ context.Context
32439 header_ http.Header
32440 }
32441
32442
32443 func (r *FloodlightActivitiesService) Get(profileId int64, id int64) *FloodlightActivitiesGetCall {
32444 c := &FloodlightActivitiesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
32445 c.profileId = profileId
32446 c.id = id
32447 return c
32448 }
32449
32450
32451
32452
32453 func (c *FloodlightActivitiesGetCall) Fields(s ...googleapi.Field) *FloodlightActivitiesGetCall {
32454 c.urlParams_.Set("fields", googleapi.CombineFields(s))
32455 return c
32456 }
32457
32458
32459
32460
32461
32462
32463 func (c *FloodlightActivitiesGetCall) IfNoneMatch(entityTag string) *FloodlightActivitiesGetCall {
32464 c.ifNoneMatch_ = entityTag
32465 return c
32466 }
32467
32468
32469
32470
32471 func (c *FloodlightActivitiesGetCall) Context(ctx context.Context) *FloodlightActivitiesGetCall {
32472 c.ctx_ = ctx
32473 return c
32474 }
32475
32476
32477
32478 func (c *FloodlightActivitiesGetCall) Header() http.Header {
32479 if c.header_ == nil {
32480 c.header_ = make(http.Header)
32481 }
32482 return c.header_
32483 }
32484
32485 func (c *FloodlightActivitiesGetCall) doRequest(alt string) (*http.Response, error) {
32486 reqHeaders := make(http.Header)
32487 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
32488 for k, v := range c.header_ {
32489 reqHeaders[k] = v
32490 }
32491 reqHeaders.Set("User-Agent", c.s.userAgent())
32492 if c.ifNoneMatch_ != "" {
32493 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
32494 }
32495 var body io.Reader = nil
32496 c.urlParams_.Set("alt", alt)
32497 c.urlParams_.Set("prettyPrint", "false")
32498 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/floodlightActivities/{id}")
32499 urls += "?" + c.urlParams_.Encode()
32500 req, err := http.NewRequest("GET", urls, body)
32501 if err != nil {
32502 return nil, err
32503 }
32504 req.Header = reqHeaders
32505 googleapi.Expand(req.URL, map[string]string{
32506 "profileId": strconv.FormatInt(c.profileId, 10),
32507 "id": strconv.FormatInt(c.id, 10),
32508 })
32509 return gensupport.SendRequest(c.ctx_, c.s.client, req)
32510 }
32511
32512
32513
32514
32515
32516
32517
32518
32519 func (c *FloodlightActivitiesGetCall) Do(opts ...googleapi.CallOption) (*FloodlightActivity, error) {
32520 gensupport.SetOptions(c.urlParams_, opts...)
32521 res, err := c.doRequest("json")
32522 if res != nil && res.StatusCode == http.StatusNotModified {
32523 if res.Body != nil {
32524 res.Body.Close()
32525 }
32526 return nil, &googleapi.Error{
32527 Code: res.StatusCode,
32528 Header: res.Header,
32529 }
32530 }
32531 if err != nil {
32532 return nil, err
32533 }
32534 defer googleapi.CloseBody(res)
32535 if err := googleapi.CheckResponse(res); err != nil {
32536 return nil, err
32537 }
32538 ret := &FloodlightActivity{
32539 ServerResponse: googleapi.ServerResponse{
32540 Header: res.Header,
32541 HTTPStatusCode: res.StatusCode,
32542 },
32543 }
32544 target := &ret
32545 if err := gensupport.DecodeResponse(target, res); err != nil {
32546 return nil, err
32547 }
32548 return ret, nil
32549
32550
32551
32552
32553
32554
32555
32556
32557
32558
32559
32560
32561
32562
32563
32564
32565
32566
32567
32568
32569
32570
32571
32572
32573
32574
32575
32576
32577
32578
32579
32580
32581
32582 }
32583
32584
32585
32586 type FloodlightActivitiesInsertCall struct {
32587 s *Service
32588 profileId int64
32589 floodlightactivity *FloodlightActivity
32590 urlParams_ gensupport.URLParams
32591 ctx_ context.Context
32592 header_ http.Header
32593 }
32594
32595
32596 func (r *FloodlightActivitiesService) Insert(profileId int64, floodlightactivity *FloodlightActivity) *FloodlightActivitiesInsertCall {
32597 c := &FloodlightActivitiesInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
32598 c.profileId = profileId
32599 c.floodlightactivity = floodlightactivity
32600 return c
32601 }
32602
32603
32604
32605
32606 func (c *FloodlightActivitiesInsertCall) Fields(s ...googleapi.Field) *FloodlightActivitiesInsertCall {
32607 c.urlParams_.Set("fields", googleapi.CombineFields(s))
32608 return c
32609 }
32610
32611
32612
32613
32614 func (c *FloodlightActivitiesInsertCall) Context(ctx context.Context) *FloodlightActivitiesInsertCall {
32615 c.ctx_ = ctx
32616 return c
32617 }
32618
32619
32620
32621 func (c *FloodlightActivitiesInsertCall) Header() http.Header {
32622 if c.header_ == nil {
32623 c.header_ = make(http.Header)
32624 }
32625 return c.header_
32626 }
32627
32628 func (c *FloodlightActivitiesInsertCall) doRequest(alt string) (*http.Response, error) {
32629 reqHeaders := make(http.Header)
32630 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
32631 for k, v := range c.header_ {
32632 reqHeaders[k] = v
32633 }
32634 reqHeaders.Set("User-Agent", c.s.userAgent())
32635 var body io.Reader = nil
32636 body, err := googleapi.WithoutDataWrapper.JSONReader(c.floodlightactivity)
32637 if err != nil {
32638 return nil, err
32639 }
32640 reqHeaders.Set("Content-Type", "application/json")
32641 c.urlParams_.Set("alt", alt)
32642 c.urlParams_.Set("prettyPrint", "false")
32643 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/floodlightActivities")
32644 urls += "?" + c.urlParams_.Encode()
32645 req, err := http.NewRequest("POST", urls, body)
32646 if err != nil {
32647 return nil, err
32648 }
32649 req.Header = reqHeaders
32650 googleapi.Expand(req.URL, map[string]string{
32651 "profileId": strconv.FormatInt(c.profileId, 10),
32652 })
32653 return gensupport.SendRequest(c.ctx_, c.s.client, req)
32654 }
32655
32656
32657
32658
32659
32660
32661
32662
32663 func (c *FloodlightActivitiesInsertCall) Do(opts ...googleapi.CallOption) (*FloodlightActivity, error) {
32664 gensupport.SetOptions(c.urlParams_, opts...)
32665 res, err := c.doRequest("json")
32666 if res != nil && res.StatusCode == http.StatusNotModified {
32667 if res.Body != nil {
32668 res.Body.Close()
32669 }
32670 return nil, &googleapi.Error{
32671 Code: res.StatusCode,
32672 Header: res.Header,
32673 }
32674 }
32675 if err != nil {
32676 return nil, err
32677 }
32678 defer googleapi.CloseBody(res)
32679 if err := googleapi.CheckResponse(res); err != nil {
32680 return nil, err
32681 }
32682 ret := &FloodlightActivity{
32683 ServerResponse: googleapi.ServerResponse{
32684 Header: res.Header,
32685 HTTPStatusCode: res.StatusCode,
32686 },
32687 }
32688 target := &ret
32689 if err := gensupport.DecodeResponse(target, res); err != nil {
32690 return nil, err
32691 }
32692 return ret, nil
32693
32694
32695
32696
32697
32698
32699
32700
32701
32702
32703
32704
32705
32706
32707
32708
32709
32710
32711
32712
32713
32714
32715
32716
32717
32718
32719
32720
32721 }
32722
32723
32724
32725 type FloodlightActivitiesListCall struct {
32726 s *Service
32727 profileId int64
32728 urlParams_ gensupport.URLParams
32729 ifNoneMatch_ string
32730 ctx_ context.Context
32731 header_ http.Header
32732 }
32733
32734
32735
32736 func (r *FloodlightActivitiesService) List(profileId int64) *FloodlightActivitiesListCall {
32737 c := &FloodlightActivitiesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
32738 c.profileId = profileId
32739 return c
32740 }
32741
32742
32743
32744
32745
32746 func (c *FloodlightActivitiesListCall) AdvertiserId(advertiserId int64) *FloodlightActivitiesListCall {
32747 c.urlParams_.Set("advertiserId", fmt.Sprint(advertiserId))
32748 return c
32749 }
32750
32751
32752
32753
32754 func (c *FloodlightActivitiesListCall) FloodlightActivityGroupIds(floodlightActivityGroupIds ...int64) *FloodlightActivitiesListCall {
32755 var floodlightActivityGroupIds_ []string
32756 for _, v := range floodlightActivityGroupIds {
32757 floodlightActivityGroupIds_ = append(floodlightActivityGroupIds_, fmt.Sprint(v))
32758 }
32759 c.urlParams_.SetMulti("floodlightActivityGroupIds", floodlightActivityGroupIds_)
32760 return c
32761 }
32762
32763
32764
32765
32766 func (c *FloodlightActivitiesListCall) FloodlightActivityGroupName(floodlightActivityGroupName string) *FloodlightActivitiesListCall {
32767 c.urlParams_.Set("floodlightActivityGroupName", floodlightActivityGroupName)
32768 return c
32769 }
32770
32771
32772
32773
32774 func (c *FloodlightActivitiesListCall) FloodlightActivityGroupTagString(floodlightActivityGroupTagString string) *FloodlightActivitiesListCall {
32775 c.urlParams_.Set("floodlightActivityGroupTagString", floodlightActivityGroupTagString)
32776 return c
32777 }
32778
32779
32780
32781
32782
32783
32784
32785
32786
32787 func (c *FloodlightActivitiesListCall) FloodlightActivityGroupType(floodlightActivityGroupType string) *FloodlightActivitiesListCall {
32788 c.urlParams_.Set("floodlightActivityGroupType", floodlightActivityGroupType)
32789 return c
32790 }
32791
32792
32793
32794
32795
32796 func (c *FloodlightActivitiesListCall) FloodlightConfigurationId(floodlightConfigurationId int64) *FloodlightActivitiesListCall {
32797 c.urlParams_.Set("floodlightConfigurationId", fmt.Sprint(floodlightConfigurationId))
32798 return c
32799 }
32800
32801
32802
32803
32804 func (c *FloodlightActivitiesListCall) Ids(ids ...int64) *FloodlightActivitiesListCall {
32805 var ids_ []string
32806 for _, v := range ids {
32807 ids_ = append(ids_, fmt.Sprint(v))
32808 }
32809 c.urlParams_.SetMulti("ids", ids_)
32810 return c
32811 }
32812
32813
32814
32815 func (c *FloodlightActivitiesListCall) MaxResults(maxResults int64) *FloodlightActivitiesListCall {
32816 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
32817 return c
32818 }
32819
32820
32821
32822 func (c *FloodlightActivitiesListCall) PageToken(pageToken string) *FloodlightActivitiesListCall {
32823 c.urlParams_.Set("pageToken", pageToken)
32824 return c
32825 }
32826
32827
32828
32829
32830
32831
32832
32833
32834
32835
32836 func (c *FloodlightActivitiesListCall) SearchString(searchString string) *FloodlightActivitiesListCall {
32837 c.urlParams_.Set("searchString", searchString)
32838 return c
32839 }
32840
32841
32842
32843
32844
32845
32846
32847
32848 func (c *FloodlightActivitiesListCall) SortField(sortField string) *FloodlightActivitiesListCall {
32849 c.urlParams_.Set("sortField", sortField)
32850 return c
32851 }
32852
32853
32854
32855
32856
32857
32858
32859
32860 func (c *FloodlightActivitiesListCall) SortOrder(sortOrder string) *FloodlightActivitiesListCall {
32861 c.urlParams_.Set("sortOrder", sortOrder)
32862 return c
32863 }
32864
32865
32866
32867 func (c *FloodlightActivitiesListCall) TagString(tagString string) *FloodlightActivitiesListCall {
32868 c.urlParams_.Set("tagString", tagString)
32869 return c
32870 }
32871
32872
32873
32874
32875 func (c *FloodlightActivitiesListCall) Fields(s ...googleapi.Field) *FloodlightActivitiesListCall {
32876 c.urlParams_.Set("fields", googleapi.CombineFields(s))
32877 return c
32878 }
32879
32880
32881
32882
32883
32884
32885 func (c *FloodlightActivitiesListCall) IfNoneMatch(entityTag string) *FloodlightActivitiesListCall {
32886 c.ifNoneMatch_ = entityTag
32887 return c
32888 }
32889
32890
32891
32892
32893 func (c *FloodlightActivitiesListCall) Context(ctx context.Context) *FloodlightActivitiesListCall {
32894 c.ctx_ = ctx
32895 return c
32896 }
32897
32898
32899
32900 func (c *FloodlightActivitiesListCall) Header() http.Header {
32901 if c.header_ == nil {
32902 c.header_ = make(http.Header)
32903 }
32904 return c.header_
32905 }
32906
32907 func (c *FloodlightActivitiesListCall) doRequest(alt string) (*http.Response, error) {
32908 reqHeaders := make(http.Header)
32909 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
32910 for k, v := range c.header_ {
32911 reqHeaders[k] = v
32912 }
32913 reqHeaders.Set("User-Agent", c.s.userAgent())
32914 if c.ifNoneMatch_ != "" {
32915 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
32916 }
32917 var body io.Reader = nil
32918 c.urlParams_.Set("alt", alt)
32919 c.urlParams_.Set("prettyPrint", "false")
32920 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/floodlightActivities")
32921 urls += "?" + c.urlParams_.Encode()
32922 req, err := http.NewRequest("GET", urls, body)
32923 if err != nil {
32924 return nil, err
32925 }
32926 req.Header = reqHeaders
32927 googleapi.Expand(req.URL, map[string]string{
32928 "profileId": strconv.FormatInt(c.profileId, 10),
32929 })
32930 return gensupport.SendRequest(c.ctx_, c.s.client, req)
32931 }
32932
32933
32934
32935
32936
32937
32938
32939
32940 func (c *FloodlightActivitiesListCall) Do(opts ...googleapi.CallOption) (*FloodlightActivitiesListResponse, error) {
32941 gensupport.SetOptions(c.urlParams_, opts...)
32942 res, err := c.doRequest("json")
32943 if res != nil && res.StatusCode == http.StatusNotModified {
32944 if res.Body != nil {
32945 res.Body.Close()
32946 }
32947 return nil, &googleapi.Error{
32948 Code: res.StatusCode,
32949 Header: res.Header,
32950 }
32951 }
32952 if err != nil {
32953 return nil, err
32954 }
32955 defer googleapi.CloseBody(res)
32956 if err := googleapi.CheckResponse(res); err != nil {
32957 return nil, err
32958 }
32959 ret := &FloodlightActivitiesListResponse{
32960 ServerResponse: googleapi.ServerResponse{
32961 Header: res.Header,
32962 HTTPStatusCode: res.StatusCode,
32963 },
32964 }
32965 target := &ret
32966 if err := gensupport.DecodeResponse(target, res); err != nil {
32967 return nil, err
32968 }
32969 return ret, nil
32970
32971
32972
32973
32974
32975
32976
32977
32978
32979
32980
32981
32982
32983
32984
32985
32986
32987
32988
32989
32990
32991
32992
32993
32994
32995
32996
32997
32998
32999
33000
33001
33002
33003
33004
33005
33006
33007
33008
33009
33010
33011
33012
33013
33014
33015
33016
33017
33018
33019
33020
33021
33022
33023
33024
33025
33026
33027
33028
33029
33030
33031
33032
33033
33034
33035
33036
33037
33038
33039
33040
33041
33042
33043
33044
33045
33046
33047
33048
33049
33050
33051
33052
33053
33054
33055
33056
33057
33058
33059
33060
33061
33062
33063
33064
33065
33066
33067
33068
33069
33070
33071
33072
33073
33074
33075
33076
33077
33078
33079
33080
33081
33082
33083
33084
33085
33086
33087
33088
33089
33090
33091
33092
33093
33094
33095
33096 }
33097
33098
33099
33100
33101 func (c *FloodlightActivitiesListCall) Pages(ctx context.Context, f func(*FloodlightActivitiesListResponse) error) error {
33102 c.ctx_ = ctx
33103 defer c.PageToken(c.urlParams_.Get("pageToken"))
33104 for {
33105 x, err := c.Do()
33106 if err != nil {
33107 return err
33108 }
33109 if err := f(x); err != nil {
33110 return err
33111 }
33112 if x.NextPageToken == "" {
33113 return nil
33114 }
33115 c.PageToken(x.NextPageToken)
33116 }
33117 }
33118
33119
33120
33121 type FloodlightActivitiesPatchCall struct {
33122 s *Service
33123 profileId int64
33124 floodlightactivity *FloodlightActivity
33125 urlParams_ gensupport.URLParams
33126 ctx_ context.Context
33127 header_ http.Header
33128 }
33129
33130
33131
33132 func (r *FloodlightActivitiesService) Patch(profileId int64, id int64, floodlightactivity *FloodlightActivity) *FloodlightActivitiesPatchCall {
33133 c := &FloodlightActivitiesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
33134 c.profileId = profileId
33135 c.urlParams_.Set("id", fmt.Sprint(id))
33136 c.floodlightactivity = floodlightactivity
33137 return c
33138 }
33139
33140
33141
33142
33143 func (c *FloodlightActivitiesPatchCall) Fields(s ...googleapi.Field) *FloodlightActivitiesPatchCall {
33144 c.urlParams_.Set("fields", googleapi.CombineFields(s))
33145 return c
33146 }
33147
33148
33149
33150
33151 func (c *FloodlightActivitiesPatchCall) Context(ctx context.Context) *FloodlightActivitiesPatchCall {
33152 c.ctx_ = ctx
33153 return c
33154 }
33155
33156
33157
33158 func (c *FloodlightActivitiesPatchCall) Header() http.Header {
33159 if c.header_ == nil {
33160 c.header_ = make(http.Header)
33161 }
33162 return c.header_
33163 }
33164
33165 func (c *FloodlightActivitiesPatchCall) doRequest(alt string) (*http.Response, error) {
33166 reqHeaders := make(http.Header)
33167 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
33168 for k, v := range c.header_ {
33169 reqHeaders[k] = v
33170 }
33171 reqHeaders.Set("User-Agent", c.s.userAgent())
33172 var body io.Reader = nil
33173 body, err := googleapi.WithoutDataWrapper.JSONReader(c.floodlightactivity)
33174 if err != nil {
33175 return nil, err
33176 }
33177 reqHeaders.Set("Content-Type", "application/json")
33178 c.urlParams_.Set("alt", alt)
33179 c.urlParams_.Set("prettyPrint", "false")
33180 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/floodlightActivities")
33181 urls += "?" + c.urlParams_.Encode()
33182 req, err := http.NewRequest("PATCH", urls, body)
33183 if err != nil {
33184 return nil, err
33185 }
33186 req.Header = reqHeaders
33187 googleapi.Expand(req.URL, map[string]string{
33188 "profileId": strconv.FormatInt(c.profileId, 10),
33189 })
33190 return gensupport.SendRequest(c.ctx_, c.s.client, req)
33191 }
33192
33193
33194
33195
33196
33197
33198
33199
33200 func (c *FloodlightActivitiesPatchCall) Do(opts ...googleapi.CallOption) (*FloodlightActivity, error) {
33201 gensupport.SetOptions(c.urlParams_, opts...)
33202 res, err := c.doRequest("json")
33203 if res != nil && res.StatusCode == http.StatusNotModified {
33204 if res.Body != nil {
33205 res.Body.Close()
33206 }
33207 return nil, &googleapi.Error{
33208 Code: res.StatusCode,
33209 Header: res.Header,
33210 }
33211 }
33212 if err != nil {
33213 return nil, err
33214 }
33215 defer googleapi.CloseBody(res)
33216 if err := googleapi.CheckResponse(res); err != nil {
33217 return nil, err
33218 }
33219 ret := &FloodlightActivity{
33220 ServerResponse: googleapi.ServerResponse{
33221 Header: res.Header,
33222 HTTPStatusCode: res.StatusCode,
33223 },
33224 }
33225 target := &ret
33226 if err := gensupport.DecodeResponse(target, res); err != nil {
33227 return nil, err
33228 }
33229 return ret, nil
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 type FloodlightActivitiesUpdateCall struct {
33271 s *Service
33272 profileId int64
33273 floodlightactivity *FloodlightActivity
33274 urlParams_ gensupport.URLParams
33275 ctx_ context.Context
33276 header_ http.Header
33277 }
33278
33279
33280 func (r *FloodlightActivitiesService) Update(profileId int64, floodlightactivity *FloodlightActivity) *FloodlightActivitiesUpdateCall {
33281 c := &FloodlightActivitiesUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
33282 c.profileId = profileId
33283 c.floodlightactivity = floodlightactivity
33284 return c
33285 }
33286
33287
33288
33289
33290 func (c *FloodlightActivitiesUpdateCall) Fields(s ...googleapi.Field) *FloodlightActivitiesUpdateCall {
33291 c.urlParams_.Set("fields", googleapi.CombineFields(s))
33292 return c
33293 }
33294
33295
33296
33297
33298 func (c *FloodlightActivitiesUpdateCall) Context(ctx context.Context) *FloodlightActivitiesUpdateCall {
33299 c.ctx_ = ctx
33300 return c
33301 }
33302
33303
33304
33305 func (c *FloodlightActivitiesUpdateCall) Header() http.Header {
33306 if c.header_ == nil {
33307 c.header_ = make(http.Header)
33308 }
33309 return c.header_
33310 }
33311
33312 func (c *FloodlightActivitiesUpdateCall) doRequest(alt string) (*http.Response, error) {
33313 reqHeaders := make(http.Header)
33314 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
33315 for k, v := range c.header_ {
33316 reqHeaders[k] = v
33317 }
33318 reqHeaders.Set("User-Agent", c.s.userAgent())
33319 var body io.Reader = nil
33320 body, err := googleapi.WithoutDataWrapper.JSONReader(c.floodlightactivity)
33321 if err != nil {
33322 return nil, err
33323 }
33324 reqHeaders.Set("Content-Type", "application/json")
33325 c.urlParams_.Set("alt", alt)
33326 c.urlParams_.Set("prettyPrint", "false")
33327 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/floodlightActivities")
33328 urls += "?" + c.urlParams_.Encode()
33329 req, err := http.NewRequest("PUT", urls, body)
33330 if err != nil {
33331 return nil, err
33332 }
33333 req.Header = reqHeaders
33334 googleapi.Expand(req.URL, map[string]string{
33335 "profileId": strconv.FormatInt(c.profileId, 10),
33336 })
33337 return gensupport.SendRequest(c.ctx_, c.s.client, req)
33338 }
33339
33340
33341
33342
33343
33344
33345
33346
33347 func (c *FloodlightActivitiesUpdateCall) Do(opts ...googleapi.CallOption) (*FloodlightActivity, error) {
33348 gensupport.SetOptions(c.urlParams_, opts...)
33349 res, err := c.doRequest("json")
33350 if res != nil && res.StatusCode == http.StatusNotModified {
33351 if res.Body != nil {
33352 res.Body.Close()
33353 }
33354 return nil, &googleapi.Error{
33355 Code: res.StatusCode,
33356 Header: res.Header,
33357 }
33358 }
33359 if err != nil {
33360 return nil, err
33361 }
33362 defer googleapi.CloseBody(res)
33363 if err := googleapi.CheckResponse(res); err != nil {
33364 return nil, err
33365 }
33366 ret := &FloodlightActivity{
33367 ServerResponse: googleapi.ServerResponse{
33368 Header: res.Header,
33369 HTTPStatusCode: res.StatusCode,
33370 },
33371 }
33372 target := &ret
33373 if err := gensupport.DecodeResponse(target, res); err != nil {
33374 return nil, err
33375 }
33376 return ret, nil
33377
33378
33379
33380
33381
33382
33383
33384
33385
33386
33387
33388
33389
33390
33391
33392
33393
33394
33395
33396
33397
33398
33399
33400
33401
33402
33403
33404
33405 }
33406
33407
33408
33409 type FloodlightActivityGroupsGetCall struct {
33410 s *Service
33411 profileId int64
33412 id int64
33413 urlParams_ gensupport.URLParams
33414 ifNoneMatch_ string
33415 ctx_ context.Context
33416 header_ http.Header
33417 }
33418
33419
33420 func (r *FloodlightActivityGroupsService) Get(profileId int64, id int64) *FloodlightActivityGroupsGetCall {
33421 c := &FloodlightActivityGroupsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
33422 c.profileId = profileId
33423 c.id = id
33424 return c
33425 }
33426
33427
33428
33429
33430 func (c *FloodlightActivityGroupsGetCall) Fields(s ...googleapi.Field) *FloodlightActivityGroupsGetCall {
33431 c.urlParams_.Set("fields", googleapi.CombineFields(s))
33432 return c
33433 }
33434
33435
33436
33437
33438
33439
33440 func (c *FloodlightActivityGroupsGetCall) IfNoneMatch(entityTag string) *FloodlightActivityGroupsGetCall {
33441 c.ifNoneMatch_ = entityTag
33442 return c
33443 }
33444
33445
33446
33447
33448 func (c *FloodlightActivityGroupsGetCall) Context(ctx context.Context) *FloodlightActivityGroupsGetCall {
33449 c.ctx_ = ctx
33450 return c
33451 }
33452
33453
33454
33455 func (c *FloodlightActivityGroupsGetCall) Header() http.Header {
33456 if c.header_ == nil {
33457 c.header_ = make(http.Header)
33458 }
33459 return c.header_
33460 }
33461
33462 func (c *FloodlightActivityGroupsGetCall) doRequest(alt string) (*http.Response, error) {
33463 reqHeaders := make(http.Header)
33464 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
33465 for k, v := range c.header_ {
33466 reqHeaders[k] = v
33467 }
33468 reqHeaders.Set("User-Agent", c.s.userAgent())
33469 if c.ifNoneMatch_ != "" {
33470 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
33471 }
33472 var body io.Reader = nil
33473 c.urlParams_.Set("alt", alt)
33474 c.urlParams_.Set("prettyPrint", "false")
33475 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/floodlightActivityGroups/{id}")
33476 urls += "?" + c.urlParams_.Encode()
33477 req, err := http.NewRequest("GET", urls, body)
33478 if err != nil {
33479 return nil, err
33480 }
33481 req.Header = reqHeaders
33482 googleapi.Expand(req.URL, map[string]string{
33483 "profileId": strconv.FormatInt(c.profileId, 10),
33484 "id": strconv.FormatInt(c.id, 10),
33485 })
33486 return gensupport.SendRequest(c.ctx_, c.s.client, req)
33487 }
33488
33489
33490
33491
33492
33493
33494
33495
33496 func (c *FloodlightActivityGroupsGetCall) Do(opts ...googleapi.CallOption) (*FloodlightActivityGroup, error) {
33497 gensupport.SetOptions(c.urlParams_, opts...)
33498 res, err := c.doRequest("json")
33499 if res != nil && res.StatusCode == http.StatusNotModified {
33500 if res.Body != nil {
33501 res.Body.Close()
33502 }
33503 return nil, &googleapi.Error{
33504 Code: res.StatusCode,
33505 Header: res.Header,
33506 }
33507 }
33508 if err != nil {
33509 return nil, err
33510 }
33511 defer googleapi.CloseBody(res)
33512 if err := googleapi.CheckResponse(res); err != nil {
33513 return nil, err
33514 }
33515 ret := &FloodlightActivityGroup{
33516 ServerResponse: googleapi.ServerResponse{
33517 Header: res.Header,
33518 HTTPStatusCode: res.StatusCode,
33519 },
33520 }
33521 target := &ret
33522 if err := gensupport.DecodeResponse(target, res); err != nil {
33523 return nil, err
33524 }
33525 return ret, nil
33526
33527
33528
33529
33530
33531
33532
33533
33534
33535
33536
33537
33538
33539
33540
33541
33542
33543
33544
33545
33546
33547
33548
33549
33550
33551
33552
33553
33554
33555
33556
33557
33558
33559 }
33560
33561
33562
33563 type FloodlightActivityGroupsInsertCall struct {
33564 s *Service
33565 profileId int64
33566 floodlightactivitygroup *FloodlightActivityGroup
33567 urlParams_ gensupport.URLParams
33568 ctx_ context.Context
33569 header_ http.Header
33570 }
33571
33572
33573 func (r *FloodlightActivityGroupsService) Insert(profileId int64, floodlightactivitygroup *FloodlightActivityGroup) *FloodlightActivityGroupsInsertCall {
33574 c := &FloodlightActivityGroupsInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
33575 c.profileId = profileId
33576 c.floodlightactivitygroup = floodlightactivitygroup
33577 return c
33578 }
33579
33580
33581
33582
33583 func (c *FloodlightActivityGroupsInsertCall) Fields(s ...googleapi.Field) *FloodlightActivityGroupsInsertCall {
33584 c.urlParams_.Set("fields", googleapi.CombineFields(s))
33585 return c
33586 }
33587
33588
33589
33590
33591 func (c *FloodlightActivityGroupsInsertCall) Context(ctx context.Context) *FloodlightActivityGroupsInsertCall {
33592 c.ctx_ = ctx
33593 return c
33594 }
33595
33596
33597
33598 func (c *FloodlightActivityGroupsInsertCall) Header() http.Header {
33599 if c.header_ == nil {
33600 c.header_ = make(http.Header)
33601 }
33602 return c.header_
33603 }
33604
33605 func (c *FloodlightActivityGroupsInsertCall) doRequest(alt string) (*http.Response, error) {
33606 reqHeaders := make(http.Header)
33607 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
33608 for k, v := range c.header_ {
33609 reqHeaders[k] = v
33610 }
33611 reqHeaders.Set("User-Agent", c.s.userAgent())
33612 var body io.Reader = nil
33613 body, err := googleapi.WithoutDataWrapper.JSONReader(c.floodlightactivitygroup)
33614 if err != nil {
33615 return nil, err
33616 }
33617 reqHeaders.Set("Content-Type", "application/json")
33618 c.urlParams_.Set("alt", alt)
33619 c.urlParams_.Set("prettyPrint", "false")
33620 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/floodlightActivityGroups")
33621 urls += "?" + c.urlParams_.Encode()
33622 req, err := http.NewRequest("POST", urls, body)
33623 if err != nil {
33624 return nil, err
33625 }
33626 req.Header = reqHeaders
33627 googleapi.Expand(req.URL, map[string]string{
33628 "profileId": strconv.FormatInt(c.profileId, 10),
33629 })
33630 return gensupport.SendRequest(c.ctx_, c.s.client, req)
33631 }
33632
33633
33634
33635
33636
33637
33638
33639
33640 func (c *FloodlightActivityGroupsInsertCall) Do(opts ...googleapi.CallOption) (*FloodlightActivityGroup, error) {
33641 gensupport.SetOptions(c.urlParams_, opts...)
33642 res, err := c.doRequest("json")
33643 if res != nil && res.StatusCode == http.StatusNotModified {
33644 if res.Body != nil {
33645 res.Body.Close()
33646 }
33647 return nil, &googleapi.Error{
33648 Code: res.StatusCode,
33649 Header: res.Header,
33650 }
33651 }
33652 if err != nil {
33653 return nil, err
33654 }
33655 defer googleapi.CloseBody(res)
33656 if err := googleapi.CheckResponse(res); err != nil {
33657 return nil, err
33658 }
33659 ret := &FloodlightActivityGroup{
33660 ServerResponse: googleapi.ServerResponse{
33661 Header: res.Header,
33662 HTTPStatusCode: res.StatusCode,
33663 },
33664 }
33665 target := &ret
33666 if err := gensupport.DecodeResponse(target, res); err != nil {
33667 return nil, err
33668 }
33669 return ret, nil
33670
33671
33672
33673
33674
33675
33676
33677
33678
33679
33680
33681
33682
33683
33684
33685
33686
33687
33688
33689
33690
33691
33692
33693
33694
33695
33696
33697
33698 }
33699
33700
33701
33702 type FloodlightActivityGroupsListCall struct {
33703 s *Service
33704 profileId int64
33705 urlParams_ gensupport.URLParams
33706 ifNoneMatch_ string
33707 ctx_ context.Context
33708 header_ http.Header
33709 }
33710
33711
33712
33713 func (r *FloodlightActivityGroupsService) List(profileId int64) *FloodlightActivityGroupsListCall {
33714 c := &FloodlightActivityGroupsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
33715 c.profileId = profileId
33716 return c
33717 }
33718
33719
33720
33721
33722
33723 func (c *FloodlightActivityGroupsListCall) AdvertiserId(advertiserId int64) *FloodlightActivityGroupsListCall {
33724 c.urlParams_.Set("advertiserId", fmt.Sprint(advertiserId))
33725 return c
33726 }
33727
33728
33729
33730
33731
33732 func (c *FloodlightActivityGroupsListCall) FloodlightConfigurationId(floodlightConfigurationId int64) *FloodlightActivityGroupsListCall {
33733 c.urlParams_.Set("floodlightConfigurationId", fmt.Sprint(floodlightConfigurationId))
33734 return c
33735 }
33736
33737
33738
33739
33740 func (c *FloodlightActivityGroupsListCall) Ids(ids ...int64) *FloodlightActivityGroupsListCall {
33741 var ids_ []string
33742 for _, v := range ids {
33743 ids_ = append(ids_, fmt.Sprint(v))
33744 }
33745 c.urlParams_.SetMulti("ids", ids_)
33746 return c
33747 }
33748
33749
33750
33751 func (c *FloodlightActivityGroupsListCall) MaxResults(maxResults int64) *FloodlightActivityGroupsListCall {
33752 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
33753 return c
33754 }
33755
33756
33757
33758 func (c *FloodlightActivityGroupsListCall) PageToken(pageToken string) *FloodlightActivityGroupsListCall {
33759 c.urlParams_.Set("pageToken", pageToken)
33760 return c
33761 }
33762
33763
33764
33765
33766
33767
33768
33769
33770
33771
33772
33773 func (c *FloodlightActivityGroupsListCall) SearchString(searchString string) *FloodlightActivityGroupsListCall {
33774 c.urlParams_.Set("searchString", searchString)
33775 return c
33776 }
33777
33778
33779
33780
33781
33782
33783
33784
33785 func (c *FloodlightActivityGroupsListCall) SortField(sortField string) *FloodlightActivityGroupsListCall {
33786 c.urlParams_.Set("sortField", sortField)
33787 return c
33788 }
33789
33790
33791
33792
33793
33794
33795
33796
33797 func (c *FloodlightActivityGroupsListCall) SortOrder(sortOrder string) *FloodlightActivityGroupsListCall {
33798 c.urlParams_.Set("sortOrder", sortOrder)
33799 return c
33800 }
33801
33802
33803
33804
33805
33806
33807
33808
33809 func (c *FloodlightActivityGroupsListCall) Type(type_ string) *FloodlightActivityGroupsListCall {
33810 c.urlParams_.Set("type", type_)
33811 return c
33812 }
33813
33814
33815
33816
33817 func (c *FloodlightActivityGroupsListCall) Fields(s ...googleapi.Field) *FloodlightActivityGroupsListCall {
33818 c.urlParams_.Set("fields", googleapi.CombineFields(s))
33819 return c
33820 }
33821
33822
33823
33824
33825
33826
33827 func (c *FloodlightActivityGroupsListCall) IfNoneMatch(entityTag string) *FloodlightActivityGroupsListCall {
33828 c.ifNoneMatch_ = entityTag
33829 return c
33830 }
33831
33832
33833
33834
33835 func (c *FloodlightActivityGroupsListCall) Context(ctx context.Context) *FloodlightActivityGroupsListCall {
33836 c.ctx_ = ctx
33837 return c
33838 }
33839
33840
33841
33842 func (c *FloodlightActivityGroupsListCall) Header() http.Header {
33843 if c.header_ == nil {
33844 c.header_ = make(http.Header)
33845 }
33846 return c.header_
33847 }
33848
33849 func (c *FloodlightActivityGroupsListCall) doRequest(alt string) (*http.Response, error) {
33850 reqHeaders := make(http.Header)
33851 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
33852 for k, v := range c.header_ {
33853 reqHeaders[k] = v
33854 }
33855 reqHeaders.Set("User-Agent", c.s.userAgent())
33856 if c.ifNoneMatch_ != "" {
33857 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
33858 }
33859 var body io.Reader = nil
33860 c.urlParams_.Set("alt", alt)
33861 c.urlParams_.Set("prettyPrint", "false")
33862 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/floodlightActivityGroups")
33863 urls += "?" + c.urlParams_.Encode()
33864 req, err := http.NewRequest("GET", urls, body)
33865 if err != nil {
33866 return nil, err
33867 }
33868 req.Header = reqHeaders
33869 googleapi.Expand(req.URL, map[string]string{
33870 "profileId": strconv.FormatInt(c.profileId, 10),
33871 })
33872 return gensupport.SendRequest(c.ctx_, c.s.client, req)
33873 }
33874
33875
33876
33877
33878
33879
33880
33881
33882
33883 func (c *FloodlightActivityGroupsListCall) Do(opts ...googleapi.CallOption) (*FloodlightActivityGroupsListResponse, error) {
33884 gensupport.SetOptions(c.urlParams_, opts...)
33885 res, err := c.doRequest("json")
33886 if res != nil && res.StatusCode == http.StatusNotModified {
33887 if res.Body != nil {
33888 res.Body.Close()
33889 }
33890 return nil, &googleapi.Error{
33891 Code: res.StatusCode,
33892 Header: res.Header,
33893 }
33894 }
33895 if err != nil {
33896 return nil, err
33897 }
33898 defer googleapi.CloseBody(res)
33899 if err := googleapi.CheckResponse(res); err != nil {
33900 return nil, err
33901 }
33902 ret := &FloodlightActivityGroupsListResponse{
33903 ServerResponse: googleapi.ServerResponse{
33904 Header: res.Header,
33905 HTTPStatusCode: res.StatusCode,
33906 },
33907 }
33908 target := &ret
33909 if err := gensupport.DecodeResponse(target, res); err != nil {
33910 return nil, err
33911 }
33912 return ret, nil
33913
33914
33915
33916
33917
33918
33919
33920
33921
33922
33923
33924
33925
33926
33927
33928
33929
33930
33931
33932
33933
33934
33935
33936
33937
33938
33939
33940
33941
33942
33943
33944
33945
33946
33947
33948
33949
33950
33951
33952
33953
33954
33955
33956
33957
33958
33959
33960
33961
33962
33963
33964
33965
33966
33967
33968
33969
33970
33971
33972
33973
33974
33975
33976
33977
33978
33979
33980
33981
33982
33983
33984
33985
33986
33987
33988
33989
33990
33991
33992
33993
33994
33995
33996
33997
33998
33999
34000
34001
34002
34003
34004
34005
34006
34007
34008
34009
34010
34011
34012
34013
34014
34015
34016
34017 }
34018
34019
34020
34021
34022 func (c *FloodlightActivityGroupsListCall) Pages(ctx context.Context, f func(*FloodlightActivityGroupsListResponse) error) error {
34023 c.ctx_ = ctx
34024 defer c.PageToken(c.urlParams_.Get("pageToken"))
34025 for {
34026 x, err := c.Do()
34027 if err != nil {
34028 return err
34029 }
34030 if err := f(x); err != nil {
34031 return err
34032 }
34033 if x.NextPageToken == "" {
34034 return nil
34035 }
34036 c.PageToken(x.NextPageToken)
34037 }
34038 }
34039
34040
34041
34042 type FloodlightActivityGroupsPatchCall struct {
34043 s *Service
34044 profileId int64
34045 floodlightactivitygroup *FloodlightActivityGroup
34046 urlParams_ gensupport.URLParams
34047 ctx_ context.Context
34048 header_ http.Header
34049 }
34050
34051
34052
34053 func (r *FloodlightActivityGroupsService) Patch(profileId int64, id int64, floodlightactivitygroup *FloodlightActivityGroup) *FloodlightActivityGroupsPatchCall {
34054 c := &FloodlightActivityGroupsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
34055 c.profileId = profileId
34056 c.urlParams_.Set("id", fmt.Sprint(id))
34057 c.floodlightactivitygroup = floodlightactivitygroup
34058 return c
34059 }
34060
34061
34062
34063
34064 func (c *FloodlightActivityGroupsPatchCall) Fields(s ...googleapi.Field) *FloodlightActivityGroupsPatchCall {
34065 c.urlParams_.Set("fields", googleapi.CombineFields(s))
34066 return c
34067 }
34068
34069
34070
34071
34072 func (c *FloodlightActivityGroupsPatchCall) Context(ctx context.Context) *FloodlightActivityGroupsPatchCall {
34073 c.ctx_ = ctx
34074 return c
34075 }
34076
34077
34078
34079 func (c *FloodlightActivityGroupsPatchCall) Header() http.Header {
34080 if c.header_ == nil {
34081 c.header_ = make(http.Header)
34082 }
34083 return c.header_
34084 }
34085
34086 func (c *FloodlightActivityGroupsPatchCall) doRequest(alt string) (*http.Response, error) {
34087 reqHeaders := make(http.Header)
34088 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
34089 for k, v := range c.header_ {
34090 reqHeaders[k] = v
34091 }
34092 reqHeaders.Set("User-Agent", c.s.userAgent())
34093 var body io.Reader = nil
34094 body, err := googleapi.WithoutDataWrapper.JSONReader(c.floodlightactivitygroup)
34095 if err != nil {
34096 return nil, err
34097 }
34098 reqHeaders.Set("Content-Type", "application/json")
34099 c.urlParams_.Set("alt", alt)
34100 c.urlParams_.Set("prettyPrint", "false")
34101 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/floodlightActivityGroups")
34102 urls += "?" + c.urlParams_.Encode()
34103 req, err := http.NewRequest("PATCH", urls, body)
34104 if err != nil {
34105 return nil, err
34106 }
34107 req.Header = reqHeaders
34108 googleapi.Expand(req.URL, map[string]string{
34109 "profileId": strconv.FormatInt(c.profileId, 10),
34110 })
34111 return gensupport.SendRequest(c.ctx_, c.s.client, req)
34112 }
34113
34114
34115
34116
34117
34118
34119
34120
34121 func (c *FloodlightActivityGroupsPatchCall) Do(opts ...googleapi.CallOption) (*FloodlightActivityGroup, error) {
34122 gensupport.SetOptions(c.urlParams_, opts...)
34123 res, err := c.doRequest("json")
34124 if res != nil && res.StatusCode == http.StatusNotModified {
34125 if res.Body != nil {
34126 res.Body.Close()
34127 }
34128 return nil, &googleapi.Error{
34129 Code: res.StatusCode,
34130 Header: res.Header,
34131 }
34132 }
34133 if err != nil {
34134 return nil, err
34135 }
34136 defer googleapi.CloseBody(res)
34137 if err := googleapi.CheckResponse(res); err != nil {
34138 return nil, err
34139 }
34140 ret := &FloodlightActivityGroup{
34141 ServerResponse: googleapi.ServerResponse{
34142 Header: res.Header,
34143 HTTPStatusCode: res.StatusCode,
34144 },
34145 }
34146 target := &ret
34147 if err := gensupport.DecodeResponse(target, res); err != nil {
34148 return nil, err
34149 }
34150 return ret, nil
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 type FloodlightActivityGroupsUpdateCall struct {
34192 s *Service
34193 profileId int64
34194 floodlightactivitygroup *FloodlightActivityGroup
34195 urlParams_ gensupport.URLParams
34196 ctx_ context.Context
34197 header_ http.Header
34198 }
34199
34200
34201 func (r *FloodlightActivityGroupsService) Update(profileId int64, floodlightactivitygroup *FloodlightActivityGroup) *FloodlightActivityGroupsUpdateCall {
34202 c := &FloodlightActivityGroupsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
34203 c.profileId = profileId
34204 c.floodlightactivitygroup = floodlightactivitygroup
34205 return c
34206 }
34207
34208
34209
34210
34211 func (c *FloodlightActivityGroupsUpdateCall) Fields(s ...googleapi.Field) *FloodlightActivityGroupsUpdateCall {
34212 c.urlParams_.Set("fields", googleapi.CombineFields(s))
34213 return c
34214 }
34215
34216
34217
34218
34219 func (c *FloodlightActivityGroupsUpdateCall) Context(ctx context.Context) *FloodlightActivityGroupsUpdateCall {
34220 c.ctx_ = ctx
34221 return c
34222 }
34223
34224
34225
34226 func (c *FloodlightActivityGroupsUpdateCall) Header() http.Header {
34227 if c.header_ == nil {
34228 c.header_ = make(http.Header)
34229 }
34230 return c.header_
34231 }
34232
34233 func (c *FloodlightActivityGroupsUpdateCall) doRequest(alt string) (*http.Response, error) {
34234 reqHeaders := make(http.Header)
34235 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
34236 for k, v := range c.header_ {
34237 reqHeaders[k] = v
34238 }
34239 reqHeaders.Set("User-Agent", c.s.userAgent())
34240 var body io.Reader = nil
34241 body, err := googleapi.WithoutDataWrapper.JSONReader(c.floodlightactivitygroup)
34242 if err != nil {
34243 return nil, err
34244 }
34245 reqHeaders.Set("Content-Type", "application/json")
34246 c.urlParams_.Set("alt", alt)
34247 c.urlParams_.Set("prettyPrint", "false")
34248 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/floodlightActivityGroups")
34249 urls += "?" + c.urlParams_.Encode()
34250 req, err := http.NewRequest("PUT", urls, body)
34251 if err != nil {
34252 return nil, err
34253 }
34254 req.Header = reqHeaders
34255 googleapi.Expand(req.URL, map[string]string{
34256 "profileId": strconv.FormatInt(c.profileId, 10),
34257 })
34258 return gensupport.SendRequest(c.ctx_, c.s.client, req)
34259 }
34260
34261
34262
34263
34264
34265
34266
34267
34268 func (c *FloodlightActivityGroupsUpdateCall) Do(opts ...googleapi.CallOption) (*FloodlightActivityGroup, error) {
34269 gensupport.SetOptions(c.urlParams_, opts...)
34270 res, err := c.doRequest("json")
34271 if res != nil && res.StatusCode == http.StatusNotModified {
34272 if res.Body != nil {
34273 res.Body.Close()
34274 }
34275 return nil, &googleapi.Error{
34276 Code: res.StatusCode,
34277 Header: res.Header,
34278 }
34279 }
34280 if err != nil {
34281 return nil, err
34282 }
34283 defer googleapi.CloseBody(res)
34284 if err := googleapi.CheckResponse(res); err != nil {
34285 return nil, err
34286 }
34287 ret := &FloodlightActivityGroup{
34288 ServerResponse: googleapi.ServerResponse{
34289 Header: res.Header,
34290 HTTPStatusCode: res.StatusCode,
34291 },
34292 }
34293 target := &ret
34294 if err := gensupport.DecodeResponse(target, res); err != nil {
34295 return nil, err
34296 }
34297 return ret, nil
34298
34299
34300
34301
34302
34303
34304
34305
34306
34307
34308
34309
34310
34311
34312
34313
34314
34315
34316
34317
34318
34319
34320
34321
34322
34323
34324
34325
34326 }
34327
34328
34329
34330 type FloodlightConfigurationsGetCall struct {
34331 s *Service
34332 profileId int64
34333 id int64
34334 urlParams_ gensupport.URLParams
34335 ifNoneMatch_ string
34336 ctx_ context.Context
34337 header_ http.Header
34338 }
34339
34340
34341 func (r *FloodlightConfigurationsService) Get(profileId int64, id int64) *FloodlightConfigurationsGetCall {
34342 c := &FloodlightConfigurationsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
34343 c.profileId = profileId
34344 c.id = id
34345 return c
34346 }
34347
34348
34349
34350
34351 func (c *FloodlightConfigurationsGetCall) Fields(s ...googleapi.Field) *FloodlightConfigurationsGetCall {
34352 c.urlParams_.Set("fields", googleapi.CombineFields(s))
34353 return c
34354 }
34355
34356
34357
34358
34359
34360
34361 func (c *FloodlightConfigurationsGetCall) IfNoneMatch(entityTag string) *FloodlightConfigurationsGetCall {
34362 c.ifNoneMatch_ = entityTag
34363 return c
34364 }
34365
34366
34367
34368
34369 func (c *FloodlightConfigurationsGetCall) Context(ctx context.Context) *FloodlightConfigurationsGetCall {
34370 c.ctx_ = ctx
34371 return c
34372 }
34373
34374
34375
34376 func (c *FloodlightConfigurationsGetCall) Header() http.Header {
34377 if c.header_ == nil {
34378 c.header_ = make(http.Header)
34379 }
34380 return c.header_
34381 }
34382
34383 func (c *FloodlightConfigurationsGetCall) doRequest(alt string) (*http.Response, error) {
34384 reqHeaders := make(http.Header)
34385 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
34386 for k, v := range c.header_ {
34387 reqHeaders[k] = v
34388 }
34389 reqHeaders.Set("User-Agent", c.s.userAgent())
34390 if c.ifNoneMatch_ != "" {
34391 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
34392 }
34393 var body io.Reader = nil
34394 c.urlParams_.Set("alt", alt)
34395 c.urlParams_.Set("prettyPrint", "false")
34396 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/floodlightConfigurations/{id}")
34397 urls += "?" + c.urlParams_.Encode()
34398 req, err := http.NewRequest("GET", urls, body)
34399 if err != nil {
34400 return nil, err
34401 }
34402 req.Header = reqHeaders
34403 googleapi.Expand(req.URL, map[string]string{
34404 "profileId": strconv.FormatInt(c.profileId, 10),
34405 "id": strconv.FormatInt(c.id, 10),
34406 })
34407 return gensupport.SendRequest(c.ctx_, c.s.client, req)
34408 }
34409
34410
34411
34412
34413
34414
34415
34416
34417 func (c *FloodlightConfigurationsGetCall) Do(opts ...googleapi.CallOption) (*FloodlightConfiguration, error) {
34418 gensupport.SetOptions(c.urlParams_, opts...)
34419 res, err := c.doRequest("json")
34420 if res != nil && res.StatusCode == http.StatusNotModified {
34421 if res.Body != nil {
34422 res.Body.Close()
34423 }
34424 return nil, &googleapi.Error{
34425 Code: res.StatusCode,
34426 Header: res.Header,
34427 }
34428 }
34429 if err != nil {
34430 return nil, err
34431 }
34432 defer googleapi.CloseBody(res)
34433 if err := googleapi.CheckResponse(res); err != nil {
34434 return nil, err
34435 }
34436 ret := &FloodlightConfiguration{
34437 ServerResponse: googleapi.ServerResponse{
34438 Header: res.Header,
34439 HTTPStatusCode: res.StatusCode,
34440 },
34441 }
34442 target := &ret
34443 if err := gensupport.DecodeResponse(target, res); err != nil {
34444 return nil, err
34445 }
34446 return ret, nil
34447
34448
34449
34450
34451
34452
34453
34454
34455
34456
34457
34458
34459
34460
34461
34462
34463
34464
34465
34466
34467
34468
34469
34470
34471
34472
34473
34474
34475
34476
34477
34478
34479
34480 }
34481
34482
34483
34484 type FloodlightConfigurationsListCall struct {
34485 s *Service
34486 profileId int64
34487 urlParams_ gensupport.URLParams
34488 ifNoneMatch_ string
34489 ctx_ context.Context
34490 header_ http.Header
34491 }
34492
34493
34494
34495 func (r *FloodlightConfigurationsService) List(profileId int64) *FloodlightConfigurationsListCall {
34496 c := &FloodlightConfigurationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
34497 c.profileId = profileId
34498 return c
34499 }
34500
34501
34502
34503
34504 func (c *FloodlightConfigurationsListCall) Ids(ids ...int64) *FloodlightConfigurationsListCall {
34505 var ids_ []string
34506 for _, v := range ids {
34507 ids_ = append(ids_, fmt.Sprint(v))
34508 }
34509 c.urlParams_.SetMulti("ids", ids_)
34510 return c
34511 }
34512
34513
34514
34515
34516 func (c *FloodlightConfigurationsListCall) Fields(s ...googleapi.Field) *FloodlightConfigurationsListCall {
34517 c.urlParams_.Set("fields", googleapi.CombineFields(s))
34518 return c
34519 }
34520
34521
34522
34523
34524
34525
34526 func (c *FloodlightConfigurationsListCall) IfNoneMatch(entityTag string) *FloodlightConfigurationsListCall {
34527 c.ifNoneMatch_ = entityTag
34528 return c
34529 }
34530
34531
34532
34533
34534 func (c *FloodlightConfigurationsListCall) Context(ctx context.Context) *FloodlightConfigurationsListCall {
34535 c.ctx_ = ctx
34536 return c
34537 }
34538
34539
34540
34541 func (c *FloodlightConfigurationsListCall) Header() http.Header {
34542 if c.header_ == nil {
34543 c.header_ = make(http.Header)
34544 }
34545 return c.header_
34546 }
34547
34548 func (c *FloodlightConfigurationsListCall) doRequest(alt string) (*http.Response, error) {
34549 reqHeaders := make(http.Header)
34550 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
34551 for k, v := range c.header_ {
34552 reqHeaders[k] = v
34553 }
34554 reqHeaders.Set("User-Agent", c.s.userAgent())
34555 if c.ifNoneMatch_ != "" {
34556 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
34557 }
34558 var body io.Reader = nil
34559 c.urlParams_.Set("alt", alt)
34560 c.urlParams_.Set("prettyPrint", "false")
34561 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/floodlightConfigurations")
34562 urls += "?" + c.urlParams_.Encode()
34563 req, err := http.NewRequest("GET", urls, body)
34564 if err != nil {
34565 return nil, err
34566 }
34567 req.Header = reqHeaders
34568 googleapi.Expand(req.URL, map[string]string{
34569 "profileId": strconv.FormatInt(c.profileId, 10),
34570 })
34571 return gensupport.SendRequest(c.ctx_, c.s.client, req)
34572 }
34573
34574
34575
34576
34577
34578
34579
34580
34581
34582 func (c *FloodlightConfigurationsListCall) Do(opts ...googleapi.CallOption) (*FloodlightConfigurationsListResponse, error) {
34583 gensupport.SetOptions(c.urlParams_, opts...)
34584 res, err := c.doRequest("json")
34585 if res != nil && res.StatusCode == http.StatusNotModified {
34586 if res.Body != nil {
34587 res.Body.Close()
34588 }
34589 return nil, &googleapi.Error{
34590 Code: res.StatusCode,
34591 Header: res.Header,
34592 }
34593 }
34594 if err != nil {
34595 return nil, err
34596 }
34597 defer googleapi.CloseBody(res)
34598 if err := googleapi.CheckResponse(res); err != nil {
34599 return nil, err
34600 }
34601 ret := &FloodlightConfigurationsListResponse{
34602 ServerResponse: googleapi.ServerResponse{
34603 Header: res.Header,
34604 HTTPStatusCode: res.StatusCode,
34605 },
34606 }
34607 target := &ret
34608 if err := gensupport.DecodeResponse(target, res); err != nil {
34609 return nil, err
34610 }
34611 return ret, nil
34612
34613
34614
34615
34616
34617
34618
34619
34620
34621
34622
34623
34624
34625
34626
34627
34628
34629
34630
34631
34632
34633
34634
34635
34636
34637
34638
34639
34640
34641
34642
34643
34644 }
34645
34646
34647
34648 type FloodlightConfigurationsPatchCall struct {
34649 s *Service
34650 profileId int64
34651 floodlightconfiguration *FloodlightConfiguration
34652 urlParams_ gensupport.URLParams
34653 ctx_ context.Context
34654 header_ http.Header
34655 }
34656
34657
34658
34659 func (r *FloodlightConfigurationsService) Patch(profileId int64, id int64, floodlightconfiguration *FloodlightConfiguration) *FloodlightConfigurationsPatchCall {
34660 c := &FloodlightConfigurationsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
34661 c.profileId = profileId
34662 c.urlParams_.Set("id", fmt.Sprint(id))
34663 c.floodlightconfiguration = floodlightconfiguration
34664 return c
34665 }
34666
34667
34668
34669
34670 func (c *FloodlightConfigurationsPatchCall) Fields(s ...googleapi.Field) *FloodlightConfigurationsPatchCall {
34671 c.urlParams_.Set("fields", googleapi.CombineFields(s))
34672 return c
34673 }
34674
34675
34676
34677
34678 func (c *FloodlightConfigurationsPatchCall) Context(ctx context.Context) *FloodlightConfigurationsPatchCall {
34679 c.ctx_ = ctx
34680 return c
34681 }
34682
34683
34684
34685 func (c *FloodlightConfigurationsPatchCall) Header() http.Header {
34686 if c.header_ == nil {
34687 c.header_ = make(http.Header)
34688 }
34689 return c.header_
34690 }
34691
34692 func (c *FloodlightConfigurationsPatchCall) doRequest(alt string) (*http.Response, error) {
34693 reqHeaders := make(http.Header)
34694 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
34695 for k, v := range c.header_ {
34696 reqHeaders[k] = v
34697 }
34698 reqHeaders.Set("User-Agent", c.s.userAgent())
34699 var body io.Reader = nil
34700 body, err := googleapi.WithoutDataWrapper.JSONReader(c.floodlightconfiguration)
34701 if err != nil {
34702 return nil, err
34703 }
34704 reqHeaders.Set("Content-Type", "application/json")
34705 c.urlParams_.Set("alt", alt)
34706 c.urlParams_.Set("prettyPrint", "false")
34707 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/floodlightConfigurations")
34708 urls += "?" + c.urlParams_.Encode()
34709 req, err := http.NewRequest("PATCH", urls, body)
34710 if err != nil {
34711 return nil, err
34712 }
34713 req.Header = reqHeaders
34714 googleapi.Expand(req.URL, map[string]string{
34715 "profileId": strconv.FormatInt(c.profileId, 10),
34716 })
34717 return gensupport.SendRequest(c.ctx_, c.s.client, req)
34718 }
34719
34720
34721
34722
34723
34724
34725
34726
34727 func (c *FloodlightConfigurationsPatchCall) Do(opts ...googleapi.CallOption) (*FloodlightConfiguration, error) {
34728 gensupport.SetOptions(c.urlParams_, opts...)
34729 res, err := c.doRequest("json")
34730 if res != nil && res.StatusCode == http.StatusNotModified {
34731 if res.Body != nil {
34732 res.Body.Close()
34733 }
34734 return nil, &googleapi.Error{
34735 Code: res.StatusCode,
34736 Header: res.Header,
34737 }
34738 }
34739 if err != nil {
34740 return nil, err
34741 }
34742 defer googleapi.CloseBody(res)
34743 if err := googleapi.CheckResponse(res); err != nil {
34744 return nil, err
34745 }
34746 ret := &FloodlightConfiguration{
34747 ServerResponse: googleapi.ServerResponse{
34748 Header: res.Header,
34749 HTTPStatusCode: res.StatusCode,
34750 },
34751 }
34752 target := &ret
34753 if err := gensupport.DecodeResponse(target, res); err != nil {
34754 return nil, err
34755 }
34756 return ret, nil
34757
34758
34759
34760
34761
34762
34763
34764
34765
34766
34767
34768
34769
34770
34771
34772
34773
34774
34775
34776
34777
34778
34779
34780
34781
34782
34783
34784
34785
34786
34787
34788
34789
34790
34791
34792
34793 }
34794
34795
34796
34797 type FloodlightConfigurationsUpdateCall struct {
34798 s *Service
34799 profileId int64
34800 floodlightconfiguration *FloodlightConfiguration
34801 urlParams_ gensupport.URLParams
34802 ctx_ context.Context
34803 header_ http.Header
34804 }
34805
34806
34807 func (r *FloodlightConfigurationsService) Update(profileId int64, floodlightconfiguration *FloodlightConfiguration) *FloodlightConfigurationsUpdateCall {
34808 c := &FloodlightConfigurationsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
34809 c.profileId = profileId
34810 c.floodlightconfiguration = floodlightconfiguration
34811 return c
34812 }
34813
34814
34815
34816
34817 func (c *FloodlightConfigurationsUpdateCall) Fields(s ...googleapi.Field) *FloodlightConfigurationsUpdateCall {
34818 c.urlParams_.Set("fields", googleapi.CombineFields(s))
34819 return c
34820 }
34821
34822
34823
34824
34825 func (c *FloodlightConfigurationsUpdateCall) Context(ctx context.Context) *FloodlightConfigurationsUpdateCall {
34826 c.ctx_ = ctx
34827 return c
34828 }
34829
34830
34831
34832 func (c *FloodlightConfigurationsUpdateCall) Header() http.Header {
34833 if c.header_ == nil {
34834 c.header_ = make(http.Header)
34835 }
34836 return c.header_
34837 }
34838
34839 func (c *FloodlightConfigurationsUpdateCall) doRequest(alt string) (*http.Response, error) {
34840 reqHeaders := make(http.Header)
34841 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
34842 for k, v := range c.header_ {
34843 reqHeaders[k] = v
34844 }
34845 reqHeaders.Set("User-Agent", c.s.userAgent())
34846 var body io.Reader = nil
34847 body, err := googleapi.WithoutDataWrapper.JSONReader(c.floodlightconfiguration)
34848 if err != nil {
34849 return nil, err
34850 }
34851 reqHeaders.Set("Content-Type", "application/json")
34852 c.urlParams_.Set("alt", alt)
34853 c.urlParams_.Set("prettyPrint", "false")
34854 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/floodlightConfigurations")
34855 urls += "?" + c.urlParams_.Encode()
34856 req, err := http.NewRequest("PUT", urls, body)
34857 if err != nil {
34858 return nil, err
34859 }
34860 req.Header = reqHeaders
34861 googleapi.Expand(req.URL, map[string]string{
34862 "profileId": strconv.FormatInt(c.profileId, 10),
34863 })
34864 return gensupport.SendRequest(c.ctx_, c.s.client, req)
34865 }
34866
34867
34868
34869
34870
34871
34872
34873
34874 func (c *FloodlightConfigurationsUpdateCall) Do(opts ...googleapi.CallOption) (*FloodlightConfiguration, error) {
34875 gensupport.SetOptions(c.urlParams_, opts...)
34876 res, err := c.doRequest("json")
34877 if res != nil && res.StatusCode == http.StatusNotModified {
34878 if res.Body != nil {
34879 res.Body.Close()
34880 }
34881 return nil, &googleapi.Error{
34882 Code: res.StatusCode,
34883 Header: res.Header,
34884 }
34885 }
34886 if err != nil {
34887 return nil, err
34888 }
34889 defer googleapi.CloseBody(res)
34890 if err := googleapi.CheckResponse(res); err != nil {
34891 return nil, err
34892 }
34893 ret := &FloodlightConfiguration{
34894 ServerResponse: googleapi.ServerResponse{
34895 Header: res.Header,
34896 HTTPStatusCode: res.StatusCode,
34897 },
34898 }
34899 target := &ret
34900 if err := gensupport.DecodeResponse(target, res); err != nil {
34901 return nil, err
34902 }
34903 return ret, nil
34904
34905
34906
34907
34908
34909
34910
34911
34912
34913
34914
34915
34916
34917
34918
34919
34920
34921
34922
34923
34924
34925
34926
34927
34928
34929
34930
34931
34932 }
34933
34934
34935
34936 type InventoryItemsGetCall struct {
34937 s *Service
34938 profileId int64
34939 projectId int64
34940 id int64
34941 urlParams_ gensupport.URLParams
34942 ifNoneMatch_ string
34943 ctx_ context.Context
34944 header_ http.Header
34945 }
34946
34947
34948 func (r *InventoryItemsService) Get(profileId int64, projectId int64, id int64) *InventoryItemsGetCall {
34949 c := &InventoryItemsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
34950 c.profileId = profileId
34951 c.projectId = projectId
34952 c.id = id
34953 return c
34954 }
34955
34956
34957
34958
34959 func (c *InventoryItemsGetCall) Fields(s ...googleapi.Field) *InventoryItemsGetCall {
34960 c.urlParams_.Set("fields", googleapi.CombineFields(s))
34961 return c
34962 }
34963
34964
34965
34966
34967
34968
34969 func (c *InventoryItemsGetCall) IfNoneMatch(entityTag string) *InventoryItemsGetCall {
34970 c.ifNoneMatch_ = entityTag
34971 return c
34972 }
34973
34974
34975
34976
34977 func (c *InventoryItemsGetCall) Context(ctx context.Context) *InventoryItemsGetCall {
34978 c.ctx_ = ctx
34979 return c
34980 }
34981
34982
34983
34984 func (c *InventoryItemsGetCall) Header() http.Header {
34985 if c.header_ == nil {
34986 c.header_ = make(http.Header)
34987 }
34988 return c.header_
34989 }
34990
34991 func (c *InventoryItemsGetCall) doRequest(alt string) (*http.Response, error) {
34992 reqHeaders := make(http.Header)
34993 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
34994 for k, v := range c.header_ {
34995 reqHeaders[k] = v
34996 }
34997 reqHeaders.Set("User-Agent", c.s.userAgent())
34998 if c.ifNoneMatch_ != "" {
34999 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
35000 }
35001 var body io.Reader = nil
35002 c.urlParams_.Set("alt", alt)
35003 c.urlParams_.Set("prettyPrint", "false")
35004 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/projects/{projectId}/inventoryItems/{id}")
35005 urls += "?" + c.urlParams_.Encode()
35006 req, err := http.NewRequest("GET", urls, body)
35007 if err != nil {
35008 return nil, err
35009 }
35010 req.Header = reqHeaders
35011 googleapi.Expand(req.URL, map[string]string{
35012 "profileId": strconv.FormatInt(c.profileId, 10),
35013 "projectId": strconv.FormatInt(c.projectId, 10),
35014 "id": strconv.FormatInt(c.id, 10),
35015 })
35016 return gensupport.SendRequest(c.ctx_, c.s.client, req)
35017 }
35018
35019
35020
35021
35022
35023
35024
35025
35026 func (c *InventoryItemsGetCall) Do(opts ...googleapi.CallOption) (*InventoryItem, error) {
35027 gensupport.SetOptions(c.urlParams_, opts...)
35028 res, err := c.doRequest("json")
35029 if res != nil && res.StatusCode == http.StatusNotModified {
35030 if res.Body != nil {
35031 res.Body.Close()
35032 }
35033 return nil, &googleapi.Error{
35034 Code: res.StatusCode,
35035 Header: res.Header,
35036 }
35037 }
35038 if err != nil {
35039 return nil, err
35040 }
35041 defer googleapi.CloseBody(res)
35042 if err := googleapi.CheckResponse(res); err != nil {
35043 return nil, err
35044 }
35045 ret := &InventoryItem{
35046 ServerResponse: googleapi.ServerResponse{
35047 Header: res.Header,
35048 HTTPStatusCode: res.StatusCode,
35049 },
35050 }
35051 target := &ret
35052 if err := gensupport.DecodeResponse(target, res); err != nil {
35053 return nil, err
35054 }
35055 return ret, nil
35056
35057
35058
35059
35060
35061
35062
35063
35064
35065
35066
35067
35068
35069
35070
35071
35072
35073
35074
35075
35076
35077
35078
35079
35080
35081
35082
35083
35084
35085
35086
35087
35088
35089
35090
35091
35092
35093
35094
35095
35096
35097 }
35098
35099
35100
35101 type InventoryItemsListCall struct {
35102 s *Service
35103 profileId int64
35104 projectId int64
35105 urlParams_ gensupport.URLParams
35106 ifNoneMatch_ string
35107 ctx_ context.Context
35108 header_ http.Header
35109 }
35110
35111
35112
35113 func (r *InventoryItemsService) List(profileId int64, projectId int64) *InventoryItemsListCall {
35114 c := &InventoryItemsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
35115 c.profileId = profileId
35116 c.projectId = projectId
35117 return c
35118 }
35119
35120
35121
35122 func (c *InventoryItemsListCall) Ids(ids ...int64) *InventoryItemsListCall {
35123 var ids_ []string
35124 for _, v := range ids {
35125 ids_ = append(ids_, fmt.Sprint(v))
35126 }
35127 c.urlParams_.SetMulti("ids", ids_)
35128 return c
35129 }
35130
35131
35132
35133 func (c *InventoryItemsListCall) InPlan(inPlan bool) *InventoryItemsListCall {
35134 c.urlParams_.Set("inPlan", fmt.Sprint(inPlan))
35135 return c
35136 }
35137
35138
35139
35140 func (c *InventoryItemsListCall) MaxResults(maxResults int64) *InventoryItemsListCall {
35141 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
35142 return c
35143 }
35144
35145
35146
35147 func (c *InventoryItemsListCall) OrderId(orderId ...int64) *InventoryItemsListCall {
35148 var orderId_ []string
35149 for _, v := range orderId {
35150 orderId_ = append(orderId_, fmt.Sprint(v))
35151 }
35152 c.urlParams_.SetMulti("orderId", orderId_)
35153 return c
35154 }
35155
35156
35157
35158 func (c *InventoryItemsListCall) PageToken(pageToken string) *InventoryItemsListCall {
35159 c.urlParams_.Set("pageToken", pageToken)
35160 return c
35161 }
35162
35163
35164
35165 func (c *InventoryItemsListCall) SiteId(siteId ...int64) *InventoryItemsListCall {
35166 var siteId_ []string
35167 for _, v := range siteId {
35168 siteId_ = append(siteId_, fmt.Sprint(v))
35169 }
35170 c.urlParams_.SetMulti("siteId", siteId_)
35171 return c
35172 }
35173
35174
35175
35176
35177
35178
35179
35180
35181 func (c *InventoryItemsListCall) SortField(sortField string) *InventoryItemsListCall {
35182 c.urlParams_.Set("sortField", sortField)
35183 return c
35184 }
35185
35186
35187
35188
35189
35190
35191
35192
35193 func (c *InventoryItemsListCall) SortOrder(sortOrder string) *InventoryItemsListCall {
35194 c.urlParams_.Set("sortOrder", sortOrder)
35195 return c
35196 }
35197
35198
35199
35200
35201
35202
35203
35204
35205 func (c *InventoryItemsListCall) Type(type_ string) *InventoryItemsListCall {
35206 c.urlParams_.Set("type", type_)
35207 return c
35208 }
35209
35210
35211
35212
35213 func (c *InventoryItemsListCall) Fields(s ...googleapi.Field) *InventoryItemsListCall {
35214 c.urlParams_.Set("fields", googleapi.CombineFields(s))
35215 return c
35216 }
35217
35218
35219
35220
35221
35222
35223 func (c *InventoryItemsListCall) IfNoneMatch(entityTag string) *InventoryItemsListCall {
35224 c.ifNoneMatch_ = entityTag
35225 return c
35226 }
35227
35228
35229
35230
35231 func (c *InventoryItemsListCall) Context(ctx context.Context) *InventoryItemsListCall {
35232 c.ctx_ = ctx
35233 return c
35234 }
35235
35236
35237
35238 func (c *InventoryItemsListCall) Header() http.Header {
35239 if c.header_ == nil {
35240 c.header_ = make(http.Header)
35241 }
35242 return c.header_
35243 }
35244
35245 func (c *InventoryItemsListCall) doRequest(alt string) (*http.Response, error) {
35246 reqHeaders := make(http.Header)
35247 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
35248 for k, v := range c.header_ {
35249 reqHeaders[k] = v
35250 }
35251 reqHeaders.Set("User-Agent", c.s.userAgent())
35252 if c.ifNoneMatch_ != "" {
35253 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
35254 }
35255 var body io.Reader = nil
35256 c.urlParams_.Set("alt", alt)
35257 c.urlParams_.Set("prettyPrint", "false")
35258 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/projects/{projectId}/inventoryItems")
35259 urls += "?" + c.urlParams_.Encode()
35260 req, err := http.NewRequest("GET", urls, body)
35261 if err != nil {
35262 return nil, err
35263 }
35264 req.Header = reqHeaders
35265 googleapi.Expand(req.URL, map[string]string{
35266 "profileId": strconv.FormatInt(c.profileId, 10),
35267 "projectId": strconv.FormatInt(c.projectId, 10),
35268 })
35269 return gensupport.SendRequest(c.ctx_, c.s.client, req)
35270 }
35271
35272
35273
35274
35275
35276
35277
35278
35279 func (c *InventoryItemsListCall) Do(opts ...googleapi.CallOption) (*InventoryItemsListResponse, error) {
35280 gensupport.SetOptions(c.urlParams_, opts...)
35281 res, err := c.doRequest("json")
35282 if res != nil && res.StatusCode == http.StatusNotModified {
35283 if res.Body != nil {
35284 res.Body.Close()
35285 }
35286 return nil, &googleapi.Error{
35287 Code: res.StatusCode,
35288 Header: res.Header,
35289 }
35290 }
35291 if err != nil {
35292 return nil, err
35293 }
35294 defer googleapi.CloseBody(res)
35295 if err := googleapi.CheckResponse(res); err != nil {
35296 return nil, err
35297 }
35298 ret := &InventoryItemsListResponse{
35299 ServerResponse: googleapi.ServerResponse{
35300 Header: res.Header,
35301 HTTPStatusCode: res.StatusCode,
35302 },
35303 }
35304 target := &ret
35305 if err := gensupport.DecodeResponse(target, res); err != nil {
35306 return nil, err
35307 }
35308 return ret, nil
35309
35310
35311
35312
35313
35314
35315
35316
35317
35318
35319
35320
35321
35322
35323
35324
35325
35326
35327
35328
35329
35330
35331
35332
35333
35334
35335
35336
35337
35338
35339
35340
35341
35342
35343
35344
35345
35346
35347
35348
35349
35350
35351
35352
35353
35354
35355
35356
35357
35358
35359
35360
35361
35362
35363
35364
35365
35366
35367
35368
35369
35370
35371
35372
35373
35374
35375
35376
35377
35378
35379
35380
35381
35382
35383
35384
35385
35386
35387
35388
35389
35390
35391
35392
35393
35394
35395
35396
35397
35398
35399
35400
35401
35402
35403
35404
35405
35406
35407
35408
35409
35410
35411
35412
35413
35414
35415
35416
35417
35418
35419
35420
35421
35422
35423 }
35424
35425
35426
35427
35428 func (c *InventoryItemsListCall) Pages(ctx context.Context, f func(*InventoryItemsListResponse) error) error {
35429 c.ctx_ = ctx
35430 defer c.PageToken(c.urlParams_.Get("pageToken"))
35431 for {
35432 x, err := c.Do()
35433 if err != nil {
35434 return err
35435 }
35436 if err := f(x); err != nil {
35437 return err
35438 }
35439 if x.NextPageToken == "" {
35440 return nil
35441 }
35442 c.PageToken(x.NextPageToken)
35443 }
35444 }
35445
35446
35447
35448 type LanguagesListCall struct {
35449 s *Service
35450 profileId int64
35451 urlParams_ gensupport.URLParams
35452 ifNoneMatch_ string
35453 ctx_ context.Context
35454 header_ http.Header
35455 }
35456
35457
35458 func (r *LanguagesService) List(profileId int64) *LanguagesListCall {
35459 c := &LanguagesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
35460 c.profileId = profileId
35461 return c
35462 }
35463
35464
35465
35466
35467 func (c *LanguagesListCall) Fields(s ...googleapi.Field) *LanguagesListCall {
35468 c.urlParams_.Set("fields", googleapi.CombineFields(s))
35469 return c
35470 }
35471
35472
35473
35474
35475
35476
35477 func (c *LanguagesListCall) IfNoneMatch(entityTag string) *LanguagesListCall {
35478 c.ifNoneMatch_ = entityTag
35479 return c
35480 }
35481
35482
35483
35484
35485 func (c *LanguagesListCall) Context(ctx context.Context) *LanguagesListCall {
35486 c.ctx_ = ctx
35487 return c
35488 }
35489
35490
35491
35492 func (c *LanguagesListCall) Header() http.Header {
35493 if c.header_ == nil {
35494 c.header_ = make(http.Header)
35495 }
35496 return c.header_
35497 }
35498
35499 func (c *LanguagesListCall) doRequest(alt string) (*http.Response, error) {
35500 reqHeaders := make(http.Header)
35501 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
35502 for k, v := range c.header_ {
35503 reqHeaders[k] = v
35504 }
35505 reqHeaders.Set("User-Agent", c.s.userAgent())
35506 if c.ifNoneMatch_ != "" {
35507 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
35508 }
35509 var body io.Reader = nil
35510 c.urlParams_.Set("alt", alt)
35511 c.urlParams_.Set("prettyPrint", "false")
35512 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/languages")
35513 urls += "?" + c.urlParams_.Encode()
35514 req, err := http.NewRequest("GET", urls, body)
35515 if err != nil {
35516 return nil, err
35517 }
35518 req.Header = reqHeaders
35519 googleapi.Expand(req.URL, map[string]string{
35520 "profileId": strconv.FormatInt(c.profileId, 10),
35521 })
35522 return gensupport.SendRequest(c.ctx_, c.s.client, req)
35523 }
35524
35525
35526
35527
35528
35529
35530
35531
35532 func (c *LanguagesListCall) Do(opts ...googleapi.CallOption) (*LanguagesListResponse, error) {
35533 gensupport.SetOptions(c.urlParams_, opts...)
35534 res, err := c.doRequest("json")
35535 if res != nil && res.StatusCode == http.StatusNotModified {
35536 if res.Body != nil {
35537 res.Body.Close()
35538 }
35539 return nil, &googleapi.Error{
35540 Code: res.StatusCode,
35541 Header: res.Header,
35542 }
35543 }
35544 if err != nil {
35545 return nil, err
35546 }
35547 defer googleapi.CloseBody(res)
35548 if err := googleapi.CheckResponse(res); err != nil {
35549 return nil, err
35550 }
35551 ret := &LanguagesListResponse{
35552 ServerResponse: googleapi.ServerResponse{
35553 Header: res.Header,
35554 HTTPStatusCode: res.StatusCode,
35555 },
35556 }
35557 target := &ret
35558 if err := gensupport.DecodeResponse(target, res); err != nil {
35559 return nil, err
35560 }
35561 return ret, nil
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 type MetrosListCall struct {
35592 s *Service
35593 profileId int64
35594 urlParams_ gensupport.URLParams
35595 ifNoneMatch_ string
35596 ctx_ context.Context
35597 header_ http.Header
35598 }
35599
35600
35601 func (r *MetrosService) List(profileId int64) *MetrosListCall {
35602 c := &MetrosListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
35603 c.profileId = profileId
35604 return c
35605 }
35606
35607
35608
35609
35610 func (c *MetrosListCall) Fields(s ...googleapi.Field) *MetrosListCall {
35611 c.urlParams_.Set("fields", googleapi.CombineFields(s))
35612 return c
35613 }
35614
35615
35616
35617
35618
35619
35620 func (c *MetrosListCall) IfNoneMatch(entityTag string) *MetrosListCall {
35621 c.ifNoneMatch_ = entityTag
35622 return c
35623 }
35624
35625
35626
35627
35628 func (c *MetrosListCall) Context(ctx context.Context) *MetrosListCall {
35629 c.ctx_ = ctx
35630 return c
35631 }
35632
35633
35634
35635 func (c *MetrosListCall) Header() http.Header {
35636 if c.header_ == nil {
35637 c.header_ = make(http.Header)
35638 }
35639 return c.header_
35640 }
35641
35642 func (c *MetrosListCall) doRequest(alt string) (*http.Response, error) {
35643 reqHeaders := make(http.Header)
35644 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
35645 for k, v := range c.header_ {
35646 reqHeaders[k] = v
35647 }
35648 reqHeaders.Set("User-Agent", c.s.userAgent())
35649 if c.ifNoneMatch_ != "" {
35650 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
35651 }
35652 var body io.Reader = nil
35653 c.urlParams_.Set("alt", alt)
35654 c.urlParams_.Set("prettyPrint", "false")
35655 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/metros")
35656 urls += "?" + c.urlParams_.Encode()
35657 req, err := http.NewRequest("GET", urls, body)
35658 if err != nil {
35659 return nil, err
35660 }
35661 req.Header = reqHeaders
35662 googleapi.Expand(req.URL, map[string]string{
35663 "profileId": strconv.FormatInt(c.profileId, 10),
35664 })
35665 return gensupport.SendRequest(c.ctx_, c.s.client, req)
35666 }
35667
35668
35669
35670
35671
35672
35673
35674
35675 func (c *MetrosListCall) Do(opts ...googleapi.CallOption) (*MetrosListResponse, error) {
35676 gensupport.SetOptions(c.urlParams_, opts...)
35677 res, err := c.doRequest("json")
35678 if res != nil && res.StatusCode == http.StatusNotModified {
35679 if res.Body != nil {
35680 res.Body.Close()
35681 }
35682 return nil, &googleapi.Error{
35683 Code: res.StatusCode,
35684 Header: res.Header,
35685 }
35686 }
35687 if err != nil {
35688 return nil, err
35689 }
35690 defer googleapi.CloseBody(res)
35691 if err := googleapi.CheckResponse(res); err != nil {
35692 return nil, err
35693 }
35694 ret := &MetrosListResponse{
35695 ServerResponse: googleapi.ServerResponse{
35696 Header: res.Header,
35697 HTTPStatusCode: res.StatusCode,
35698 },
35699 }
35700 target := &ret
35701 if err := gensupport.DecodeResponse(target, res); err != nil {
35702 return nil, err
35703 }
35704 return ret, nil
35705
35706
35707
35708
35709
35710
35711
35712
35713
35714
35715
35716
35717
35718
35719
35720
35721
35722
35723
35724
35725
35726
35727
35728
35729
35730 }
35731
35732
35733
35734 type MobileCarriersGetCall struct {
35735 s *Service
35736 profileId int64
35737 id int64
35738 urlParams_ gensupport.URLParams
35739 ifNoneMatch_ string
35740 ctx_ context.Context
35741 header_ http.Header
35742 }
35743
35744
35745 func (r *MobileCarriersService) Get(profileId int64, id int64) *MobileCarriersGetCall {
35746 c := &MobileCarriersGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
35747 c.profileId = profileId
35748 c.id = id
35749 return c
35750 }
35751
35752
35753
35754
35755 func (c *MobileCarriersGetCall) Fields(s ...googleapi.Field) *MobileCarriersGetCall {
35756 c.urlParams_.Set("fields", googleapi.CombineFields(s))
35757 return c
35758 }
35759
35760
35761
35762
35763
35764
35765 func (c *MobileCarriersGetCall) IfNoneMatch(entityTag string) *MobileCarriersGetCall {
35766 c.ifNoneMatch_ = entityTag
35767 return c
35768 }
35769
35770
35771
35772
35773 func (c *MobileCarriersGetCall) Context(ctx context.Context) *MobileCarriersGetCall {
35774 c.ctx_ = ctx
35775 return c
35776 }
35777
35778
35779
35780 func (c *MobileCarriersGetCall) Header() http.Header {
35781 if c.header_ == nil {
35782 c.header_ = make(http.Header)
35783 }
35784 return c.header_
35785 }
35786
35787 func (c *MobileCarriersGetCall) doRequest(alt string) (*http.Response, error) {
35788 reqHeaders := make(http.Header)
35789 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
35790 for k, v := range c.header_ {
35791 reqHeaders[k] = v
35792 }
35793 reqHeaders.Set("User-Agent", c.s.userAgent())
35794 if c.ifNoneMatch_ != "" {
35795 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
35796 }
35797 var body io.Reader = nil
35798 c.urlParams_.Set("alt", alt)
35799 c.urlParams_.Set("prettyPrint", "false")
35800 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/mobileCarriers/{id}")
35801 urls += "?" + c.urlParams_.Encode()
35802 req, err := http.NewRequest("GET", urls, body)
35803 if err != nil {
35804 return nil, err
35805 }
35806 req.Header = reqHeaders
35807 googleapi.Expand(req.URL, map[string]string{
35808 "profileId": strconv.FormatInt(c.profileId, 10),
35809 "id": strconv.FormatInt(c.id, 10),
35810 })
35811 return gensupport.SendRequest(c.ctx_, c.s.client, req)
35812 }
35813
35814
35815
35816
35817
35818
35819
35820
35821 func (c *MobileCarriersGetCall) Do(opts ...googleapi.CallOption) (*MobileCarrier, error) {
35822 gensupport.SetOptions(c.urlParams_, opts...)
35823 res, err := c.doRequest("json")
35824 if res != nil && res.StatusCode == http.StatusNotModified {
35825 if res.Body != nil {
35826 res.Body.Close()
35827 }
35828 return nil, &googleapi.Error{
35829 Code: res.StatusCode,
35830 Header: res.Header,
35831 }
35832 }
35833 if err != nil {
35834 return nil, err
35835 }
35836 defer googleapi.CloseBody(res)
35837 if err := googleapi.CheckResponse(res); err != nil {
35838 return nil, err
35839 }
35840 ret := &MobileCarrier{
35841 ServerResponse: googleapi.ServerResponse{
35842 Header: res.Header,
35843 HTTPStatusCode: res.StatusCode,
35844 },
35845 }
35846 target := &ret
35847 if err := gensupport.DecodeResponse(target, res); err != nil {
35848 return nil, err
35849 }
35850 return ret, nil
35851
35852
35853
35854
35855
35856
35857
35858
35859
35860
35861
35862
35863
35864
35865
35866
35867
35868
35869
35870
35871
35872
35873
35874
35875
35876
35877
35878
35879
35880
35881
35882
35883
35884 }
35885
35886
35887
35888 type MobileCarriersListCall struct {
35889 s *Service
35890 profileId int64
35891 urlParams_ gensupport.URLParams
35892 ifNoneMatch_ string
35893 ctx_ context.Context
35894 header_ http.Header
35895 }
35896
35897
35898 func (r *MobileCarriersService) List(profileId int64) *MobileCarriersListCall {
35899 c := &MobileCarriersListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
35900 c.profileId = profileId
35901 return c
35902 }
35903
35904
35905
35906
35907 func (c *MobileCarriersListCall) Fields(s ...googleapi.Field) *MobileCarriersListCall {
35908 c.urlParams_.Set("fields", googleapi.CombineFields(s))
35909 return c
35910 }
35911
35912
35913
35914
35915
35916
35917 func (c *MobileCarriersListCall) IfNoneMatch(entityTag string) *MobileCarriersListCall {
35918 c.ifNoneMatch_ = entityTag
35919 return c
35920 }
35921
35922
35923
35924
35925 func (c *MobileCarriersListCall) Context(ctx context.Context) *MobileCarriersListCall {
35926 c.ctx_ = ctx
35927 return c
35928 }
35929
35930
35931
35932 func (c *MobileCarriersListCall) Header() http.Header {
35933 if c.header_ == nil {
35934 c.header_ = make(http.Header)
35935 }
35936 return c.header_
35937 }
35938
35939 func (c *MobileCarriersListCall) doRequest(alt string) (*http.Response, error) {
35940 reqHeaders := make(http.Header)
35941 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
35942 for k, v := range c.header_ {
35943 reqHeaders[k] = v
35944 }
35945 reqHeaders.Set("User-Agent", c.s.userAgent())
35946 if c.ifNoneMatch_ != "" {
35947 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
35948 }
35949 var body io.Reader = nil
35950 c.urlParams_.Set("alt", alt)
35951 c.urlParams_.Set("prettyPrint", "false")
35952 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/mobileCarriers")
35953 urls += "?" + c.urlParams_.Encode()
35954 req, err := http.NewRequest("GET", urls, body)
35955 if err != nil {
35956 return nil, err
35957 }
35958 req.Header = reqHeaders
35959 googleapi.Expand(req.URL, map[string]string{
35960 "profileId": strconv.FormatInt(c.profileId, 10),
35961 })
35962 return gensupport.SendRequest(c.ctx_, c.s.client, req)
35963 }
35964
35965
35966
35967
35968
35969
35970
35971
35972 func (c *MobileCarriersListCall) Do(opts ...googleapi.CallOption) (*MobileCarriersListResponse, error) {
35973 gensupport.SetOptions(c.urlParams_, opts...)
35974 res, err := c.doRequest("json")
35975 if res != nil && res.StatusCode == http.StatusNotModified {
35976 if res.Body != nil {
35977 res.Body.Close()
35978 }
35979 return nil, &googleapi.Error{
35980 Code: res.StatusCode,
35981 Header: res.Header,
35982 }
35983 }
35984 if err != nil {
35985 return nil, err
35986 }
35987 defer googleapi.CloseBody(res)
35988 if err := googleapi.CheckResponse(res); err != nil {
35989 return nil, err
35990 }
35991 ret := &MobileCarriersListResponse{
35992 ServerResponse: googleapi.ServerResponse{
35993 Header: res.Header,
35994 HTTPStatusCode: res.StatusCode,
35995 },
35996 }
35997 target := &ret
35998 if err := gensupport.DecodeResponse(target, res); err != nil {
35999 return nil, err
36000 }
36001 return ret, nil
36002
36003
36004
36005
36006
36007
36008
36009
36010
36011
36012
36013
36014
36015
36016
36017
36018
36019
36020
36021
36022
36023
36024
36025
36026
36027 }
36028
36029
36030
36031 type OperatingSystemVersionsGetCall struct {
36032 s *Service
36033 profileId int64
36034 id int64
36035 urlParams_ gensupport.URLParams
36036 ifNoneMatch_ string
36037 ctx_ context.Context
36038 header_ http.Header
36039 }
36040
36041
36042 func (r *OperatingSystemVersionsService) Get(profileId int64, id int64) *OperatingSystemVersionsGetCall {
36043 c := &OperatingSystemVersionsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
36044 c.profileId = profileId
36045 c.id = id
36046 return c
36047 }
36048
36049
36050
36051
36052 func (c *OperatingSystemVersionsGetCall) Fields(s ...googleapi.Field) *OperatingSystemVersionsGetCall {
36053 c.urlParams_.Set("fields", googleapi.CombineFields(s))
36054 return c
36055 }
36056
36057
36058
36059
36060
36061
36062 func (c *OperatingSystemVersionsGetCall) IfNoneMatch(entityTag string) *OperatingSystemVersionsGetCall {
36063 c.ifNoneMatch_ = entityTag
36064 return c
36065 }
36066
36067
36068
36069
36070 func (c *OperatingSystemVersionsGetCall) Context(ctx context.Context) *OperatingSystemVersionsGetCall {
36071 c.ctx_ = ctx
36072 return c
36073 }
36074
36075
36076
36077 func (c *OperatingSystemVersionsGetCall) Header() http.Header {
36078 if c.header_ == nil {
36079 c.header_ = make(http.Header)
36080 }
36081 return c.header_
36082 }
36083
36084 func (c *OperatingSystemVersionsGetCall) doRequest(alt string) (*http.Response, error) {
36085 reqHeaders := make(http.Header)
36086 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
36087 for k, v := range c.header_ {
36088 reqHeaders[k] = v
36089 }
36090 reqHeaders.Set("User-Agent", c.s.userAgent())
36091 if c.ifNoneMatch_ != "" {
36092 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
36093 }
36094 var body io.Reader = nil
36095 c.urlParams_.Set("alt", alt)
36096 c.urlParams_.Set("prettyPrint", "false")
36097 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/operatingSystemVersions/{id}")
36098 urls += "?" + c.urlParams_.Encode()
36099 req, err := http.NewRequest("GET", urls, body)
36100 if err != nil {
36101 return nil, err
36102 }
36103 req.Header = reqHeaders
36104 googleapi.Expand(req.URL, map[string]string{
36105 "profileId": strconv.FormatInt(c.profileId, 10),
36106 "id": strconv.FormatInt(c.id, 10),
36107 })
36108 return gensupport.SendRequest(c.ctx_, c.s.client, req)
36109 }
36110
36111
36112
36113
36114
36115
36116
36117
36118 func (c *OperatingSystemVersionsGetCall) Do(opts ...googleapi.CallOption) (*OperatingSystemVersion, error) {
36119 gensupport.SetOptions(c.urlParams_, opts...)
36120 res, err := c.doRequest("json")
36121 if res != nil && res.StatusCode == http.StatusNotModified {
36122 if res.Body != nil {
36123 res.Body.Close()
36124 }
36125 return nil, &googleapi.Error{
36126 Code: res.StatusCode,
36127 Header: res.Header,
36128 }
36129 }
36130 if err != nil {
36131 return nil, err
36132 }
36133 defer googleapi.CloseBody(res)
36134 if err := googleapi.CheckResponse(res); err != nil {
36135 return nil, err
36136 }
36137 ret := &OperatingSystemVersion{
36138 ServerResponse: googleapi.ServerResponse{
36139 Header: res.Header,
36140 HTTPStatusCode: res.StatusCode,
36141 },
36142 }
36143 target := &ret
36144 if err := gensupport.DecodeResponse(target, res); err != nil {
36145 return nil, err
36146 }
36147 return ret, nil
36148
36149
36150
36151
36152
36153
36154
36155
36156
36157
36158
36159
36160
36161
36162
36163
36164
36165
36166
36167
36168
36169
36170
36171
36172
36173
36174
36175
36176
36177
36178
36179
36180
36181 }
36182
36183
36184
36185 type OperatingSystemVersionsListCall struct {
36186 s *Service
36187 profileId int64
36188 urlParams_ gensupport.URLParams
36189 ifNoneMatch_ string
36190 ctx_ context.Context
36191 header_ http.Header
36192 }
36193
36194
36195 func (r *OperatingSystemVersionsService) List(profileId int64) *OperatingSystemVersionsListCall {
36196 c := &OperatingSystemVersionsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
36197 c.profileId = profileId
36198 return c
36199 }
36200
36201
36202
36203
36204 func (c *OperatingSystemVersionsListCall) Fields(s ...googleapi.Field) *OperatingSystemVersionsListCall {
36205 c.urlParams_.Set("fields", googleapi.CombineFields(s))
36206 return c
36207 }
36208
36209
36210
36211
36212
36213
36214 func (c *OperatingSystemVersionsListCall) IfNoneMatch(entityTag string) *OperatingSystemVersionsListCall {
36215 c.ifNoneMatch_ = entityTag
36216 return c
36217 }
36218
36219
36220
36221
36222 func (c *OperatingSystemVersionsListCall) Context(ctx context.Context) *OperatingSystemVersionsListCall {
36223 c.ctx_ = ctx
36224 return c
36225 }
36226
36227
36228
36229 func (c *OperatingSystemVersionsListCall) Header() http.Header {
36230 if c.header_ == nil {
36231 c.header_ = make(http.Header)
36232 }
36233 return c.header_
36234 }
36235
36236 func (c *OperatingSystemVersionsListCall) doRequest(alt string) (*http.Response, error) {
36237 reqHeaders := make(http.Header)
36238 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
36239 for k, v := range c.header_ {
36240 reqHeaders[k] = v
36241 }
36242 reqHeaders.Set("User-Agent", c.s.userAgent())
36243 if c.ifNoneMatch_ != "" {
36244 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
36245 }
36246 var body io.Reader = nil
36247 c.urlParams_.Set("alt", alt)
36248 c.urlParams_.Set("prettyPrint", "false")
36249 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/operatingSystemVersions")
36250 urls += "?" + c.urlParams_.Encode()
36251 req, err := http.NewRequest("GET", urls, body)
36252 if err != nil {
36253 return nil, err
36254 }
36255 req.Header = reqHeaders
36256 googleapi.Expand(req.URL, map[string]string{
36257 "profileId": strconv.FormatInt(c.profileId, 10),
36258 })
36259 return gensupport.SendRequest(c.ctx_, c.s.client, req)
36260 }
36261
36262
36263
36264
36265
36266
36267
36268
36269
36270 func (c *OperatingSystemVersionsListCall) Do(opts ...googleapi.CallOption) (*OperatingSystemVersionsListResponse, error) {
36271 gensupport.SetOptions(c.urlParams_, opts...)
36272 res, err := c.doRequest("json")
36273 if res != nil && res.StatusCode == http.StatusNotModified {
36274 if res.Body != nil {
36275 res.Body.Close()
36276 }
36277 return nil, &googleapi.Error{
36278 Code: res.StatusCode,
36279 Header: res.Header,
36280 }
36281 }
36282 if err != nil {
36283 return nil, err
36284 }
36285 defer googleapi.CloseBody(res)
36286 if err := googleapi.CheckResponse(res); err != nil {
36287 return nil, err
36288 }
36289 ret := &OperatingSystemVersionsListResponse{
36290 ServerResponse: googleapi.ServerResponse{
36291 Header: res.Header,
36292 HTTPStatusCode: res.StatusCode,
36293 },
36294 }
36295 target := &ret
36296 if err := gensupport.DecodeResponse(target, res); err != nil {
36297 return nil, err
36298 }
36299 return ret, nil
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 type OperatingSystemsGetCall struct {
36330 s *Service
36331 profileId int64
36332 dartId int64
36333 urlParams_ gensupport.URLParams
36334 ifNoneMatch_ string
36335 ctx_ context.Context
36336 header_ http.Header
36337 }
36338
36339
36340 func (r *OperatingSystemsService) Get(profileId int64, dartId int64) *OperatingSystemsGetCall {
36341 c := &OperatingSystemsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
36342 c.profileId = profileId
36343 c.dartId = dartId
36344 return c
36345 }
36346
36347
36348
36349
36350 func (c *OperatingSystemsGetCall) Fields(s ...googleapi.Field) *OperatingSystemsGetCall {
36351 c.urlParams_.Set("fields", googleapi.CombineFields(s))
36352 return c
36353 }
36354
36355
36356
36357
36358
36359
36360 func (c *OperatingSystemsGetCall) IfNoneMatch(entityTag string) *OperatingSystemsGetCall {
36361 c.ifNoneMatch_ = entityTag
36362 return c
36363 }
36364
36365
36366
36367
36368 func (c *OperatingSystemsGetCall) Context(ctx context.Context) *OperatingSystemsGetCall {
36369 c.ctx_ = ctx
36370 return c
36371 }
36372
36373
36374
36375 func (c *OperatingSystemsGetCall) Header() http.Header {
36376 if c.header_ == nil {
36377 c.header_ = make(http.Header)
36378 }
36379 return c.header_
36380 }
36381
36382 func (c *OperatingSystemsGetCall) doRequest(alt string) (*http.Response, error) {
36383 reqHeaders := make(http.Header)
36384 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
36385 for k, v := range c.header_ {
36386 reqHeaders[k] = v
36387 }
36388 reqHeaders.Set("User-Agent", c.s.userAgent())
36389 if c.ifNoneMatch_ != "" {
36390 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
36391 }
36392 var body io.Reader = nil
36393 c.urlParams_.Set("alt", alt)
36394 c.urlParams_.Set("prettyPrint", "false")
36395 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/operatingSystems/{dartId}")
36396 urls += "?" + c.urlParams_.Encode()
36397 req, err := http.NewRequest("GET", urls, body)
36398 if err != nil {
36399 return nil, err
36400 }
36401 req.Header = reqHeaders
36402 googleapi.Expand(req.URL, map[string]string{
36403 "profileId": strconv.FormatInt(c.profileId, 10),
36404 "dartId": strconv.FormatInt(c.dartId, 10),
36405 })
36406 return gensupport.SendRequest(c.ctx_, c.s.client, req)
36407 }
36408
36409
36410
36411
36412
36413
36414
36415
36416 func (c *OperatingSystemsGetCall) Do(opts ...googleapi.CallOption) (*OperatingSystem, error) {
36417 gensupport.SetOptions(c.urlParams_, opts...)
36418 res, err := c.doRequest("json")
36419 if res != nil && res.StatusCode == http.StatusNotModified {
36420 if res.Body != nil {
36421 res.Body.Close()
36422 }
36423 return nil, &googleapi.Error{
36424 Code: res.StatusCode,
36425 Header: res.Header,
36426 }
36427 }
36428 if err != nil {
36429 return nil, err
36430 }
36431 defer googleapi.CloseBody(res)
36432 if err := googleapi.CheckResponse(res); err != nil {
36433 return nil, err
36434 }
36435 ret := &OperatingSystem{
36436 ServerResponse: googleapi.ServerResponse{
36437 Header: res.Header,
36438 HTTPStatusCode: res.StatusCode,
36439 },
36440 }
36441 target := &ret
36442 if err := gensupport.DecodeResponse(target, res); err != nil {
36443 return nil, err
36444 }
36445 return ret, nil
36446
36447
36448
36449
36450
36451
36452
36453
36454
36455
36456
36457
36458
36459
36460
36461
36462
36463
36464
36465
36466
36467
36468
36469
36470
36471
36472
36473
36474
36475
36476
36477
36478
36479 }
36480
36481
36482
36483 type OperatingSystemsListCall struct {
36484 s *Service
36485 profileId int64
36486 urlParams_ gensupport.URLParams
36487 ifNoneMatch_ string
36488 ctx_ context.Context
36489 header_ http.Header
36490 }
36491
36492
36493 func (r *OperatingSystemsService) List(profileId int64) *OperatingSystemsListCall {
36494 c := &OperatingSystemsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
36495 c.profileId = profileId
36496 return c
36497 }
36498
36499
36500
36501
36502 func (c *OperatingSystemsListCall) Fields(s ...googleapi.Field) *OperatingSystemsListCall {
36503 c.urlParams_.Set("fields", googleapi.CombineFields(s))
36504 return c
36505 }
36506
36507
36508
36509
36510
36511
36512 func (c *OperatingSystemsListCall) IfNoneMatch(entityTag string) *OperatingSystemsListCall {
36513 c.ifNoneMatch_ = entityTag
36514 return c
36515 }
36516
36517
36518
36519
36520 func (c *OperatingSystemsListCall) Context(ctx context.Context) *OperatingSystemsListCall {
36521 c.ctx_ = ctx
36522 return c
36523 }
36524
36525
36526
36527 func (c *OperatingSystemsListCall) Header() http.Header {
36528 if c.header_ == nil {
36529 c.header_ = make(http.Header)
36530 }
36531 return c.header_
36532 }
36533
36534 func (c *OperatingSystemsListCall) doRequest(alt string) (*http.Response, error) {
36535 reqHeaders := make(http.Header)
36536 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
36537 for k, v := range c.header_ {
36538 reqHeaders[k] = v
36539 }
36540 reqHeaders.Set("User-Agent", c.s.userAgent())
36541 if c.ifNoneMatch_ != "" {
36542 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
36543 }
36544 var body io.Reader = nil
36545 c.urlParams_.Set("alt", alt)
36546 c.urlParams_.Set("prettyPrint", "false")
36547 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/operatingSystems")
36548 urls += "?" + c.urlParams_.Encode()
36549 req, err := http.NewRequest("GET", urls, body)
36550 if err != nil {
36551 return nil, err
36552 }
36553 req.Header = reqHeaders
36554 googleapi.Expand(req.URL, map[string]string{
36555 "profileId": strconv.FormatInt(c.profileId, 10),
36556 })
36557 return gensupport.SendRequest(c.ctx_, c.s.client, req)
36558 }
36559
36560
36561
36562
36563
36564
36565
36566
36567 func (c *OperatingSystemsListCall) Do(opts ...googleapi.CallOption) (*OperatingSystemsListResponse, error) {
36568 gensupport.SetOptions(c.urlParams_, opts...)
36569 res, err := c.doRequest("json")
36570 if res != nil && res.StatusCode == http.StatusNotModified {
36571 if res.Body != nil {
36572 res.Body.Close()
36573 }
36574 return nil, &googleapi.Error{
36575 Code: res.StatusCode,
36576 Header: res.Header,
36577 }
36578 }
36579 if err != nil {
36580 return nil, err
36581 }
36582 defer googleapi.CloseBody(res)
36583 if err := googleapi.CheckResponse(res); err != nil {
36584 return nil, err
36585 }
36586 ret := &OperatingSystemsListResponse{
36587 ServerResponse: googleapi.ServerResponse{
36588 Header: res.Header,
36589 HTTPStatusCode: res.StatusCode,
36590 },
36591 }
36592 target := &ret
36593 if err := gensupport.DecodeResponse(target, res); err != nil {
36594 return nil, err
36595 }
36596 return ret, nil
36597
36598
36599
36600
36601
36602
36603
36604
36605
36606
36607
36608
36609
36610
36611
36612
36613
36614
36615
36616
36617
36618
36619
36620
36621
36622 }
36623
36624
36625
36626 type OrderDocumentsGetCall struct {
36627 s *Service
36628 profileId int64
36629 projectId int64
36630 id int64
36631 urlParams_ gensupport.URLParams
36632 ifNoneMatch_ string
36633 ctx_ context.Context
36634 header_ http.Header
36635 }
36636
36637
36638 func (r *OrderDocumentsService) Get(profileId int64, projectId int64, id int64) *OrderDocumentsGetCall {
36639 c := &OrderDocumentsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
36640 c.profileId = profileId
36641 c.projectId = projectId
36642 c.id = id
36643 return c
36644 }
36645
36646
36647
36648
36649 func (c *OrderDocumentsGetCall) Fields(s ...googleapi.Field) *OrderDocumentsGetCall {
36650 c.urlParams_.Set("fields", googleapi.CombineFields(s))
36651 return c
36652 }
36653
36654
36655
36656
36657
36658
36659 func (c *OrderDocumentsGetCall) IfNoneMatch(entityTag string) *OrderDocumentsGetCall {
36660 c.ifNoneMatch_ = entityTag
36661 return c
36662 }
36663
36664
36665
36666
36667 func (c *OrderDocumentsGetCall) Context(ctx context.Context) *OrderDocumentsGetCall {
36668 c.ctx_ = ctx
36669 return c
36670 }
36671
36672
36673
36674 func (c *OrderDocumentsGetCall) Header() http.Header {
36675 if c.header_ == nil {
36676 c.header_ = make(http.Header)
36677 }
36678 return c.header_
36679 }
36680
36681 func (c *OrderDocumentsGetCall) doRequest(alt string) (*http.Response, error) {
36682 reqHeaders := make(http.Header)
36683 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
36684 for k, v := range c.header_ {
36685 reqHeaders[k] = v
36686 }
36687 reqHeaders.Set("User-Agent", c.s.userAgent())
36688 if c.ifNoneMatch_ != "" {
36689 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
36690 }
36691 var body io.Reader = nil
36692 c.urlParams_.Set("alt", alt)
36693 c.urlParams_.Set("prettyPrint", "false")
36694 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/projects/{projectId}/orderDocuments/{id}")
36695 urls += "?" + c.urlParams_.Encode()
36696 req, err := http.NewRequest("GET", urls, body)
36697 if err != nil {
36698 return nil, err
36699 }
36700 req.Header = reqHeaders
36701 googleapi.Expand(req.URL, map[string]string{
36702 "profileId": strconv.FormatInt(c.profileId, 10),
36703 "projectId": strconv.FormatInt(c.projectId, 10),
36704 "id": strconv.FormatInt(c.id, 10),
36705 })
36706 return gensupport.SendRequest(c.ctx_, c.s.client, req)
36707 }
36708
36709
36710
36711
36712
36713
36714
36715
36716 func (c *OrderDocumentsGetCall) Do(opts ...googleapi.CallOption) (*OrderDocument, error) {
36717 gensupport.SetOptions(c.urlParams_, opts...)
36718 res, err := c.doRequest("json")
36719 if res != nil && res.StatusCode == http.StatusNotModified {
36720 if res.Body != nil {
36721 res.Body.Close()
36722 }
36723 return nil, &googleapi.Error{
36724 Code: res.StatusCode,
36725 Header: res.Header,
36726 }
36727 }
36728 if err != nil {
36729 return nil, err
36730 }
36731 defer googleapi.CloseBody(res)
36732 if err := googleapi.CheckResponse(res); err != nil {
36733 return nil, err
36734 }
36735 ret := &OrderDocument{
36736 ServerResponse: googleapi.ServerResponse{
36737 Header: res.Header,
36738 HTTPStatusCode: res.StatusCode,
36739 },
36740 }
36741 target := &ret
36742 if err := gensupport.DecodeResponse(target, res); err != nil {
36743 return nil, err
36744 }
36745 return ret, nil
36746
36747
36748
36749
36750
36751
36752
36753
36754
36755
36756
36757
36758
36759
36760
36761
36762
36763
36764
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 type OrderDocumentsListCall struct {
36792 s *Service
36793 profileId int64
36794 projectId int64
36795 urlParams_ gensupport.URLParams
36796 ifNoneMatch_ string
36797 ctx_ context.Context
36798 header_ http.Header
36799 }
36800
36801
36802
36803 func (r *OrderDocumentsService) List(profileId int64, projectId int64) *OrderDocumentsListCall {
36804 c := &OrderDocumentsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
36805 c.profileId = profileId
36806 c.projectId = projectId
36807 return c
36808 }
36809
36810
36811
36812 func (c *OrderDocumentsListCall) Approved(approved bool) *OrderDocumentsListCall {
36813 c.urlParams_.Set("approved", fmt.Sprint(approved))
36814 return c
36815 }
36816
36817
36818
36819 func (c *OrderDocumentsListCall) Ids(ids ...int64) *OrderDocumentsListCall {
36820 var ids_ []string
36821 for _, v := range ids {
36822 ids_ = append(ids_, fmt.Sprint(v))
36823 }
36824 c.urlParams_.SetMulti("ids", ids_)
36825 return c
36826 }
36827
36828
36829
36830 func (c *OrderDocumentsListCall) MaxResults(maxResults int64) *OrderDocumentsListCall {
36831 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
36832 return c
36833 }
36834
36835
36836
36837 func (c *OrderDocumentsListCall) OrderId(orderId ...int64) *OrderDocumentsListCall {
36838 var orderId_ []string
36839 for _, v := range orderId {
36840 orderId_ = append(orderId_, fmt.Sprint(v))
36841 }
36842 c.urlParams_.SetMulti("orderId", orderId_)
36843 return c
36844 }
36845
36846
36847
36848 func (c *OrderDocumentsListCall) PageToken(pageToken string) *OrderDocumentsListCall {
36849 c.urlParams_.Set("pageToken", pageToken)
36850 return c
36851 }
36852
36853
36854
36855
36856
36857
36858
36859
36860
36861
36862 func (c *OrderDocumentsListCall) SearchString(searchString string) *OrderDocumentsListCall {
36863 c.urlParams_.Set("searchString", searchString)
36864 return c
36865 }
36866
36867
36868
36869 func (c *OrderDocumentsListCall) SiteId(siteId ...int64) *OrderDocumentsListCall {
36870 var siteId_ []string
36871 for _, v := range siteId {
36872 siteId_ = append(siteId_, fmt.Sprint(v))
36873 }
36874 c.urlParams_.SetMulti("siteId", siteId_)
36875 return c
36876 }
36877
36878
36879
36880
36881
36882
36883
36884
36885 func (c *OrderDocumentsListCall) SortField(sortField string) *OrderDocumentsListCall {
36886 c.urlParams_.Set("sortField", sortField)
36887 return c
36888 }
36889
36890
36891
36892
36893
36894
36895
36896
36897 func (c *OrderDocumentsListCall) SortOrder(sortOrder string) *OrderDocumentsListCall {
36898 c.urlParams_.Set("sortOrder", sortOrder)
36899 return c
36900 }
36901
36902
36903
36904
36905 func (c *OrderDocumentsListCall) Fields(s ...googleapi.Field) *OrderDocumentsListCall {
36906 c.urlParams_.Set("fields", googleapi.CombineFields(s))
36907 return c
36908 }
36909
36910
36911
36912
36913
36914
36915 func (c *OrderDocumentsListCall) IfNoneMatch(entityTag string) *OrderDocumentsListCall {
36916 c.ifNoneMatch_ = entityTag
36917 return c
36918 }
36919
36920
36921
36922
36923 func (c *OrderDocumentsListCall) Context(ctx context.Context) *OrderDocumentsListCall {
36924 c.ctx_ = ctx
36925 return c
36926 }
36927
36928
36929
36930 func (c *OrderDocumentsListCall) Header() http.Header {
36931 if c.header_ == nil {
36932 c.header_ = make(http.Header)
36933 }
36934 return c.header_
36935 }
36936
36937 func (c *OrderDocumentsListCall) doRequest(alt string) (*http.Response, error) {
36938 reqHeaders := make(http.Header)
36939 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
36940 for k, v := range c.header_ {
36941 reqHeaders[k] = v
36942 }
36943 reqHeaders.Set("User-Agent", c.s.userAgent())
36944 if c.ifNoneMatch_ != "" {
36945 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
36946 }
36947 var body io.Reader = nil
36948 c.urlParams_.Set("alt", alt)
36949 c.urlParams_.Set("prettyPrint", "false")
36950 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/projects/{projectId}/orderDocuments")
36951 urls += "?" + c.urlParams_.Encode()
36952 req, err := http.NewRequest("GET", urls, body)
36953 if err != nil {
36954 return nil, err
36955 }
36956 req.Header = reqHeaders
36957 googleapi.Expand(req.URL, map[string]string{
36958 "profileId": strconv.FormatInt(c.profileId, 10),
36959 "projectId": strconv.FormatInt(c.projectId, 10),
36960 })
36961 return gensupport.SendRequest(c.ctx_, c.s.client, req)
36962 }
36963
36964
36965
36966
36967
36968
36969
36970
36971 func (c *OrderDocumentsListCall) Do(opts ...googleapi.CallOption) (*OrderDocumentsListResponse, error) {
36972 gensupport.SetOptions(c.urlParams_, opts...)
36973 res, err := c.doRequest("json")
36974 if res != nil && res.StatusCode == http.StatusNotModified {
36975 if res.Body != nil {
36976 res.Body.Close()
36977 }
36978 return nil, &googleapi.Error{
36979 Code: res.StatusCode,
36980 Header: res.Header,
36981 }
36982 }
36983 if err != nil {
36984 return nil, err
36985 }
36986 defer googleapi.CloseBody(res)
36987 if err := googleapi.CheckResponse(res); err != nil {
36988 return nil, err
36989 }
36990 ret := &OrderDocumentsListResponse{
36991 ServerResponse: googleapi.ServerResponse{
36992 Header: res.Header,
36993 HTTPStatusCode: res.StatusCode,
36994 },
36995 }
36996 target := &ret
36997 if err := gensupport.DecodeResponse(target, res); err != nil {
36998 return nil, err
36999 }
37000 return ret, nil
37001
37002
37003
37004
37005
37006
37007
37008
37009
37010
37011
37012
37013
37014
37015
37016
37017
37018
37019
37020
37021
37022
37023
37024
37025
37026
37027
37028
37029
37030
37031
37032
37033
37034
37035
37036
37037
37038
37039
37040
37041
37042
37043
37044
37045
37046
37047
37048
37049
37050
37051
37052
37053
37054
37055
37056
37057
37058
37059
37060
37061
37062
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
37101
37102
37103
37104
37105
37106
37107 }
37108
37109
37110
37111
37112 func (c *OrderDocumentsListCall) Pages(ctx context.Context, f func(*OrderDocumentsListResponse) error) error {
37113 c.ctx_ = ctx
37114 defer c.PageToken(c.urlParams_.Get("pageToken"))
37115 for {
37116 x, err := c.Do()
37117 if err != nil {
37118 return err
37119 }
37120 if err := f(x); err != nil {
37121 return err
37122 }
37123 if x.NextPageToken == "" {
37124 return nil
37125 }
37126 c.PageToken(x.NextPageToken)
37127 }
37128 }
37129
37130
37131
37132 type OrdersGetCall struct {
37133 s *Service
37134 profileId int64
37135 projectId int64
37136 id int64
37137 urlParams_ gensupport.URLParams
37138 ifNoneMatch_ string
37139 ctx_ context.Context
37140 header_ http.Header
37141 }
37142
37143
37144 func (r *OrdersService) Get(profileId int64, projectId int64, id int64) *OrdersGetCall {
37145 c := &OrdersGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
37146 c.profileId = profileId
37147 c.projectId = projectId
37148 c.id = id
37149 return c
37150 }
37151
37152
37153
37154
37155 func (c *OrdersGetCall) Fields(s ...googleapi.Field) *OrdersGetCall {
37156 c.urlParams_.Set("fields", googleapi.CombineFields(s))
37157 return c
37158 }
37159
37160
37161
37162
37163
37164
37165 func (c *OrdersGetCall) IfNoneMatch(entityTag string) *OrdersGetCall {
37166 c.ifNoneMatch_ = entityTag
37167 return c
37168 }
37169
37170
37171
37172
37173 func (c *OrdersGetCall) Context(ctx context.Context) *OrdersGetCall {
37174 c.ctx_ = ctx
37175 return c
37176 }
37177
37178
37179
37180 func (c *OrdersGetCall) Header() http.Header {
37181 if c.header_ == nil {
37182 c.header_ = make(http.Header)
37183 }
37184 return c.header_
37185 }
37186
37187 func (c *OrdersGetCall) doRequest(alt string) (*http.Response, error) {
37188 reqHeaders := make(http.Header)
37189 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
37190 for k, v := range c.header_ {
37191 reqHeaders[k] = v
37192 }
37193 reqHeaders.Set("User-Agent", c.s.userAgent())
37194 if c.ifNoneMatch_ != "" {
37195 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
37196 }
37197 var body io.Reader = nil
37198 c.urlParams_.Set("alt", alt)
37199 c.urlParams_.Set("prettyPrint", "false")
37200 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/projects/{projectId}/orders/{id}")
37201 urls += "?" + c.urlParams_.Encode()
37202 req, err := http.NewRequest("GET", urls, body)
37203 if err != nil {
37204 return nil, err
37205 }
37206 req.Header = reqHeaders
37207 googleapi.Expand(req.URL, map[string]string{
37208 "profileId": strconv.FormatInt(c.profileId, 10),
37209 "projectId": strconv.FormatInt(c.projectId, 10),
37210 "id": strconv.FormatInt(c.id, 10),
37211 })
37212 return gensupport.SendRequest(c.ctx_, c.s.client, req)
37213 }
37214
37215
37216
37217
37218
37219
37220
37221
37222 func (c *OrdersGetCall) Do(opts ...googleapi.CallOption) (*Order, error) {
37223 gensupport.SetOptions(c.urlParams_, opts...)
37224 res, err := c.doRequest("json")
37225 if res != nil && res.StatusCode == http.StatusNotModified {
37226 if res.Body != nil {
37227 res.Body.Close()
37228 }
37229 return nil, &googleapi.Error{
37230 Code: res.StatusCode,
37231 Header: res.Header,
37232 }
37233 }
37234 if err != nil {
37235 return nil, err
37236 }
37237 defer googleapi.CloseBody(res)
37238 if err := googleapi.CheckResponse(res); err != nil {
37239 return nil, err
37240 }
37241 ret := &Order{
37242 ServerResponse: googleapi.ServerResponse{
37243 Header: res.Header,
37244 HTTPStatusCode: res.StatusCode,
37245 },
37246 }
37247 target := &ret
37248 if err := gensupport.DecodeResponse(target, res); err != nil {
37249 return nil, err
37250 }
37251 return ret, nil
37252
37253
37254
37255
37256
37257
37258
37259
37260
37261
37262
37263
37264
37265
37266
37267
37268
37269
37270
37271
37272
37273
37274
37275
37276
37277
37278
37279
37280
37281
37282
37283
37284
37285
37286
37287
37288
37289
37290
37291
37292
37293 }
37294
37295
37296
37297 type OrdersListCall struct {
37298 s *Service
37299 profileId int64
37300 projectId int64
37301 urlParams_ gensupport.URLParams
37302 ifNoneMatch_ string
37303 ctx_ context.Context
37304 header_ http.Header
37305 }
37306
37307
37308
37309 func (r *OrdersService) List(profileId int64, projectId int64) *OrdersListCall {
37310 c := &OrdersListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
37311 c.profileId = profileId
37312 c.projectId = projectId
37313 return c
37314 }
37315
37316
37317
37318 func (c *OrdersListCall) Ids(ids ...int64) *OrdersListCall {
37319 var ids_ []string
37320 for _, v := range ids {
37321 ids_ = append(ids_, fmt.Sprint(v))
37322 }
37323 c.urlParams_.SetMulti("ids", ids_)
37324 return c
37325 }
37326
37327
37328
37329 func (c *OrdersListCall) MaxResults(maxResults int64) *OrdersListCall {
37330 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
37331 return c
37332 }
37333
37334
37335
37336 func (c *OrdersListCall) PageToken(pageToken string) *OrdersListCall {
37337 c.urlParams_.Set("pageToken", pageToken)
37338 return c
37339 }
37340
37341
37342
37343
37344
37345
37346
37347
37348 func (c *OrdersListCall) SearchString(searchString string) *OrdersListCall {
37349 c.urlParams_.Set("searchString", searchString)
37350 return c
37351 }
37352
37353
37354
37355 func (c *OrdersListCall) SiteId(siteId ...int64) *OrdersListCall {
37356 var siteId_ []string
37357 for _, v := range siteId {
37358 siteId_ = append(siteId_, fmt.Sprint(v))
37359 }
37360 c.urlParams_.SetMulti("siteId", siteId_)
37361 return c
37362 }
37363
37364
37365
37366
37367
37368
37369
37370
37371 func (c *OrdersListCall) SortField(sortField string) *OrdersListCall {
37372 c.urlParams_.Set("sortField", sortField)
37373 return c
37374 }
37375
37376
37377
37378
37379
37380
37381
37382
37383 func (c *OrdersListCall) SortOrder(sortOrder string) *OrdersListCall {
37384 c.urlParams_.Set("sortOrder", sortOrder)
37385 return c
37386 }
37387
37388
37389
37390
37391 func (c *OrdersListCall) Fields(s ...googleapi.Field) *OrdersListCall {
37392 c.urlParams_.Set("fields", googleapi.CombineFields(s))
37393 return c
37394 }
37395
37396
37397
37398
37399
37400
37401 func (c *OrdersListCall) IfNoneMatch(entityTag string) *OrdersListCall {
37402 c.ifNoneMatch_ = entityTag
37403 return c
37404 }
37405
37406
37407
37408
37409 func (c *OrdersListCall) Context(ctx context.Context) *OrdersListCall {
37410 c.ctx_ = ctx
37411 return c
37412 }
37413
37414
37415
37416 func (c *OrdersListCall) Header() http.Header {
37417 if c.header_ == nil {
37418 c.header_ = make(http.Header)
37419 }
37420 return c.header_
37421 }
37422
37423 func (c *OrdersListCall) doRequest(alt string) (*http.Response, error) {
37424 reqHeaders := make(http.Header)
37425 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
37426 for k, v := range c.header_ {
37427 reqHeaders[k] = v
37428 }
37429 reqHeaders.Set("User-Agent", c.s.userAgent())
37430 if c.ifNoneMatch_ != "" {
37431 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
37432 }
37433 var body io.Reader = nil
37434 c.urlParams_.Set("alt", alt)
37435 c.urlParams_.Set("prettyPrint", "false")
37436 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/projects/{projectId}/orders")
37437 urls += "?" + c.urlParams_.Encode()
37438 req, err := http.NewRequest("GET", urls, body)
37439 if err != nil {
37440 return nil, err
37441 }
37442 req.Header = reqHeaders
37443 googleapi.Expand(req.URL, map[string]string{
37444 "profileId": strconv.FormatInt(c.profileId, 10),
37445 "projectId": strconv.FormatInt(c.projectId, 10),
37446 })
37447 return gensupport.SendRequest(c.ctx_, c.s.client, req)
37448 }
37449
37450
37451
37452
37453
37454
37455
37456
37457 func (c *OrdersListCall) Do(opts ...googleapi.CallOption) (*OrdersListResponse, error) {
37458 gensupport.SetOptions(c.urlParams_, opts...)
37459 res, err := c.doRequest("json")
37460 if res != nil && res.StatusCode == http.StatusNotModified {
37461 if res.Body != nil {
37462 res.Body.Close()
37463 }
37464 return nil, &googleapi.Error{
37465 Code: res.StatusCode,
37466 Header: res.Header,
37467 }
37468 }
37469 if err != nil {
37470 return nil, err
37471 }
37472 defer googleapi.CloseBody(res)
37473 if err := googleapi.CheckResponse(res); err != nil {
37474 return nil, err
37475 }
37476 ret := &OrdersListResponse{
37477 ServerResponse: googleapi.ServerResponse{
37478 Header: res.Header,
37479 HTTPStatusCode: res.StatusCode,
37480 },
37481 }
37482 target := &ret
37483 if err := gensupport.DecodeResponse(target, res); err != nil {
37484 return nil, err
37485 }
37486 return ret, nil
37487
37488
37489
37490
37491
37492
37493
37494
37495
37496
37497
37498
37499
37500
37501
37502
37503
37504
37505
37506
37507
37508
37509
37510
37511
37512
37513
37514
37515
37516
37517
37518
37519
37520
37521
37522
37523
37524
37525
37526
37527
37528
37529
37530
37531
37532
37533
37534
37535
37536
37537
37538
37539
37540
37541
37542
37543
37544
37545
37546
37547
37548
37549
37550
37551
37552
37553
37554
37555
37556
37557
37558
37559
37560
37561
37562
37563
37564
37565
37566
37567
37568
37569
37570
37571
37572
37573
37574
37575
37576
37577
37578
37579
37580
37581 }
37582
37583
37584
37585
37586 func (c *OrdersListCall) Pages(ctx context.Context, f func(*OrdersListResponse) error) error {
37587 c.ctx_ = ctx
37588 defer c.PageToken(c.urlParams_.Get("pageToken"))
37589 for {
37590 x, err := c.Do()
37591 if err != nil {
37592 return err
37593 }
37594 if err := f(x); err != nil {
37595 return err
37596 }
37597 if x.NextPageToken == "" {
37598 return nil
37599 }
37600 c.PageToken(x.NextPageToken)
37601 }
37602 }
37603
37604
37605
37606 type PlacementGroupsGetCall struct {
37607 s *Service
37608 profileId int64
37609 id int64
37610 urlParams_ gensupport.URLParams
37611 ifNoneMatch_ string
37612 ctx_ context.Context
37613 header_ http.Header
37614 }
37615
37616
37617 func (r *PlacementGroupsService) Get(profileId int64, id int64) *PlacementGroupsGetCall {
37618 c := &PlacementGroupsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
37619 c.profileId = profileId
37620 c.id = id
37621 return c
37622 }
37623
37624
37625
37626
37627 func (c *PlacementGroupsGetCall) Fields(s ...googleapi.Field) *PlacementGroupsGetCall {
37628 c.urlParams_.Set("fields", googleapi.CombineFields(s))
37629 return c
37630 }
37631
37632
37633
37634
37635
37636
37637 func (c *PlacementGroupsGetCall) IfNoneMatch(entityTag string) *PlacementGroupsGetCall {
37638 c.ifNoneMatch_ = entityTag
37639 return c
37640 }
37641
37642
37643
37644
37645 func (c *PlacementGroupsGetCall) Context(ctx context.Context) *PlacementGroupsGetCall {
37646 c.ctx_ = ctx
37647 return c
37648 }
37649
37650
37651
37652 func (c *PlacementGroupsGetCall) Header() http.Header {
37653 if c.header_ == nil {
37654 c.header_ = make(http.Header)
37655 }
37656 return c.header_
37657 }
37658
37659 func (c *PlacementGroupsGetCall) doRequest(alt string) (*http.Response, error) {
37660 reqHeaders := make(http.Header)
37661 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
37662 for k, v := range c.header_ {
37663 reqHeaders[k] = v
37664 }
37665 reqHeaders.Set("User-Agent", c.s.userAgent())
37666 if c.ifNoneMatch_ != "" {
37667 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
37668 }
37669 var body io.Reader = nil
37670 c.urlParams_.Set("alt", alt)
37671 c.urlParams_.Set("prettyPrint", "false")
37672 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/placementGroups/{id}")
37673 urls += "?" + c.urlParams_.Encode()
37674 req, err := http.NewRequest("GET", urls, body)
37675 if err != nil {
37676 return nil, err
37677 }
37678 req.Header = reqHeaders
37679 googleapi.Expand(req.URL, map[string]string{
37680 "profileId": strconv.FormatInt(c.profileId, 10),
37681 "id": strconv.FormatInt(c.id, 10),
37682 })
37683 return gensupport.SendRequest(c.ctx_, c.s.client, req)
37684 }
37685
37686
37687
37688
37689
37690
37691
37692
37693 func (c *PlacementGroupsGetCall) Do(opts ...googleapi.CallOption) (*PlacementGroup, error) {
37694 gensupport.SetOptions(c.urlParams_, opts...)
37695 res, err := c.doRequest("json")
37696 if res != nil && res.StatusCode == http.StatusNotModified {
37697 if res.Body != nil {
37698 res.Body.Close()
37699 }
37700 return nil, &googleapi.Error{
37701 Code: res.StatusCode,
37702 Header: res.Header,
37703 }
37704 }
37705 if err != nil {
37706 return nil, err
37707 }
37708 defer googleapi.CloseBody(res)
37709 if err := googleapi.CheckResponse(res); err != nil {
37710 return nil, err
37711 }
37712 ret := &PlacementGroup{
37713 ServerResponse: googleapi.ServerResponse{
37714 Header: res.Header,
37715 HTTPStatusCode: res.StatusCode,
37716 },
37717 }
37718 target := &ret
37719 if err := gensupport.DecodeResponse(target, res); err != nil {
37720 return nil, err
37721 }
37722 return ret, nil
37723
37724
37725
37726
37727
37728
37729
37730
37731
37732
37733
37734
37735
37736
37737
37738
37739
37740
37741
37742
37743
37744
37745
37746
37747
37748
37749
37750
37751
37752
37753
37754
37755
37756 }
37757
37758
37759
37760 type PlacementGroupsInsertCall struct {
37761 s *Service
37762 profileId int64
37763 placementgroup *PlacementGroup
37764 urlParams_ gensupport.URLParams
37765 ctx_ context.Context
37766 header_ http.Header
37767 }
37768
37769
37770 func (r *PlacementGroupsService) Insert(profileId int64, placementgroup *PlacementGroup) *PlacementGroupsInsertCall {
37771 c := &PlacementGroupsInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
37772 c.profileId = profileId
37773 c.placementgroup = placementgroup
37774 return c
37775 }
37776
37777
37778
37779
37780 func (c *PlacementGroupsInsertCall) Fields(s ...googleapi.Field) *PlacementGroupsInsertCall {
37781 c.urlParams_.Set("fields", googleapi.CombineFields(s))
37782 return c
37783 }
37784
37785
37786
37787
37788 func (c *PlacementGroupsInsertCall) Context(ctx context.Context) *PlacementGroupsInsertCall {
37789 c.ctx_ = ctx
37790 return c
37791 }
37792
37793
37794
37795 func (c *PlacementGroupsInsertCall) Header() http.Header {
37796 if c.header_ == nil {
37797 c.header_ = make(http.Header)
37798 }
37799 return c.header_
37800 }
37801
37802 func (c *PlacementGroupsInsertCall) doRequest(alt string) (*http.Response, error) {
37803 reqHeaders := make(http.Header)
37804 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
37805 for k, v := range c.header_ {
37806 reqHeaders[k] = v
37807 }
37808 reqHeaders.Set("User-Agent", c.s.userAgent())
37809 var body io.Reader = nil
37810 body, err := googleapi.WithoutDataWrapper.JSONReader(c.placementgroup)
37811 if err != nil {
37812 return nil, err
37813 }
37814 reqHeaders.Set("Content-Type", "application/json")
37815 c.urlParams_.Set("alt", alt)
37816 c.urlParams_.Set("prettyPrint", "false")
37817 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/placementGroups")
37818 urls += "?" + c.urlParams_.Encode()
37819 req, err := http.NewRequest("POST", 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 })
37827 return gensupport.SendRequest(c.ctx_, c.s.client, req)
37828 }
37829
37830
37831
37832
37833
37834
37835
37836
37837 func (c *PlacementGroupsInsertCall) Do(opts ...googleapi.CallOption) (*PlacementGroup, error) {
37838 gensupport.SetOptions(c.urlParams_, opts...)
37839 res, err := c.doRequest("json")
37840 if res != nil && res.StatusCode == http.StatusNotModified {
37841 if res.Body != nil {
37842 res.Body.Close()
37843 }
37844 return nil, &googleapi.Error{
37845 Code: res.StatusCode,
37846 Header: res.Header,
37847 }
37848 }
37849 if err != nil {
37850 return nil, err
37851 }
37852 defer googleapi.CloseBody(res)
37853 if err := googleapi.CheckResponse(res); err != nil {
37854 return nil, err
37855 }
37856 ret := &PlacementGroup{
37857 ServerResponse: googleapi.ServerResponse{
37858 Header: res.Header,
37859 HTTPStatusCode: res.StatusCode,
37860 },
37861 }
37862 target := &ret
37863 if err := gensupport.DecodeResponse(target, res); err != nil {
37864 return nil, err
37865 }
37866 return ret, nil
37867
37868
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 type PlacementGroupsListCall struct {
37900 s *Service
37901 profileId int64
37902 urlParams_ gensupport.URLParams
37903 ifNoneMatch_ string
37904 ctx_ context.Context
37905 header_ http.Header
37906 }
37907
37908
37909
37910 func (r *PlacementGroupsService) List(profileId int64) *PlacementGroupsListCall {
37911 c := &PlacementGroupsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
37912 c.profileId = profileId
37913 return c
37914 }
37915
37916
37917
37918 func (c *PlacementGroupsListCall) AdvertiserIds(advertiserIds ...int64) *PlacementGroupsListCall {
37919 var advertiserIds_ []string
37920 for _, v := range advertiserIds {
37921 advertiserIds_ = append(advertiserIds_, fmt.Sprint(v))
37922 }
37923 c.urlParams_.SetMulti("advertiserIds", advertiserIds_)
37924 return c
37925 }
37926
37927
37928
37929
37930 func (c *PlacementGroupsListCall) Archived(archived bool) *PlacementGroupsListCall {
37931 c.urlParams_.Set("archived", fmt.Sprint(archived))
37932 return c
37933 }
37934
37935
37936
37937 func (c *PlacementGroupsListCall) CampaignIds(campaignIds ...int64) *PlacementGroupsListCall {
37938 var campaignIds_ []string
37939 for _, v := range campaignIds {
37940 campaignIds_ = append(campaignIds_, fmt.Sprint(v))
37941 }
37942 c.urlParams_.SetMulti("campaignIds", campaignIds_)
37943 return c
37944 }
37945
37946
37947
37948
37949 func (c *PlacementGroupsListCall) ContentCategoryIds(contentCategoryIds ...int64) *PlacementGroupsListCall {
37950 var contentCategoryIds_ []string
37951 for _, v := range contentCategoryIds {
37952 contentCategoryIds_ = append(contentCategoryIds_, fmt.Sprint(v))
37953 }
37954 c.urlParams_.SetMulti("contentCategoryIds", contentCategoryIds_)
37955 return c
37956 }
37957
37958
37959
37960
37961 func (c *PlacementGroupsListCall) DirectorySiteIds(directorySiteIds ...int64) *PlacementGroupsListCall {
37962 var directorySiteIds_ []string
37963 for _, v := range directorySiteIds {
37964 directorySiteIds_ = append(directorySiteIds_, fmt.Sprint(v))
37965 }
37966 c.urlParams_.SetMulti("directorySiteIds", directorySiteIds_)
37967 return c
37968 }
37969
37970
37971
37972 func (c *PlacementGroupsListCall) Ids(ids ...int64) *PlacementGroupsListCall {
37973 var ids_ []string
37974 for _, v := range ids {
37975 ids_ = append(ids_, fmt.Sprint(v))
37976 }
37977 c.urlParams_.SetMulti("ids", ids_)
37978 return c
37979 }
37980
37981
37982
37983
37984 func (c *PlacementGroupsListCall) MaxEndDate(maxEndDate string) *PlacementGroupsListCall {
37985 c.urlParams_.Set("maxEndDate", maxEndDate)
37986 return c
37987 }
37988
37989
37990
37991 func (c *PlacementGroupsListCall) MaxResults(maxResults int64) *PlacementGroupsListCall {
37992 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
37993 return c
37994 }
37995
37996
37997
37998
37999 func (c *PlacementGroupsListCall) MaxStartDate(maxStartDate string) *PlacementGroupsListCall {
38000 c.urlParams_.Set("maxStartDate", maxStartDate)
38001 return c
38002 }
38003
38004
38005
38006
38007 func (c *PlacementGroupsListCall) MinEndDate(minEndDate string) *PlacementGroupsListCall {
38008 c.urlParams_.Set("minEndDate", minEndDate)
38009 return c
38010 }
38011
38012
38013
38014
38015 func (c *PlacementGroupsListCall) MinStartDate(minStartDate string) *PlacementGroupsListCall {
38016 c.urlParams_.Set("minStartDate", minStartDate)
38017 return c
38018 }
38019
38020
38021
38022 func (c *PlacementGroupsListCall) PageToken(pageToken string) *PlacementGroupsListCall {
38023 c.urlParams_.Set("pageToken", pageToken)
38024 return c
38025 }
38026
38027
38028
38029
38030
38031
38032
38033
38034
38035
38036
38037
38038
38039 func (c *PlacementGroupsListCall) PlacementGroupType(placementGroupType string) *PlacementGroupsListCall {
38040 c.urlParams_.Set("placementGroupType", placementGroupType)
38041 return c
38042 }
38043
38044
38045
38046
38047 func (c *PlacementGroupsListCall) PlacementStrategyIds(placementStrategyIds ...int64) *PlacementGroupsListCall {
38048 var placementStrategyIds_ []string
38049 for _, v := range placementStrategyIds {
38050 placementStrategyIds_ = append(placementStrategyIds_, fmt.Sprint(v))
38051 }
38052 c.urlParams_.SetMulti("placementStrategyIds", placementStrategyIds_)
38053 return c
38054 }
38055
38056
38057
38058
38059
38060
38061
38062
38063
38064
38065
38066
38067 func (c *PlacementGroupsListCall) PricingTypes(pricingTypes ...string) *PlacementGroupsListCall {
38068 c.urlParams_.SetMulti("pricingTypes", append([]string{}, pricingTypes...))
38069 return c
38070 }
38071
38072
38073
38074
38075
38076
38077
38078
38079
38080
38081 func (c *PlacementGroupsListCall) SearchString(searchString string) *PlacementGroupsListCall {
38082 c.urlParams_.Set("searchString", searchString)
38083 return c
38084 }
38085
38086
38087
38088 func (c *PlacementGroupsListCall) SiteIds(siteIds ...int64) *PlacementGroupsListCall {
38089 var siteIds_ []string
38090 for _, v := range siteIds {
38091 siteIds_ = append(siteIds_, fmt.Sprint(v))
38092 }
38093 c.urlParams_.SetMulti("siteIds", siteIds_)
38094 return c
38095 }
38096
38097
38098
38099
38100
38101
38102
38103
38104 func (c *PlacementGroupsListCall) SortField(sortField string) *PlacementGroupsListCall {
38105 c.urlParams_.Set("sortField", sortField)
38106 return c
38107 }
38108
38109
38110
38111
38112
38113
38114
38115
38116 func (c *PlacementGroupsListCall) SortOrder(sortOrder string) *PlacementGroupsListCall {
38117 c.urlParams_.Set("sortOrder", sortOrder)
38118 return c
38119 }
38120
38121
38122
38123
38124 func (c *PlacementGroupsListCall) Fields(s ...googleapi.Field) *PlacementGroupsListCall {
38125 c.urlParams_.Set("fields", googleapi.CombineFields(s))
38126 return c
38127 }
38128
38129
38130
38131
38132
38133
38134 func (c *PlacementGroupsListCall) IfNoneMatch(entityTag string) *PlacementGroupsListCall {
38135 c.ifNoneMatch_ = entityTag
38136 return c
38137 }
38138
38139
38140
38141
38142 func (c *PlacementGroupsListCall) Context(ctx context.Context) *PlacementGroupsListCall {
38143 c.ctx_ = ctx
38144 return c
38145 }
38146
38147
38148
38149 func (c *PlacementGroupsListCall) Header() http.Header {
38150 if c.header_ == nil {
38151 c.header_ = make(http.Header)
38152 }
38153 return c.header_
38154 }
38155
38156 func (c *PlacementGroupsListCall) doRequest(alt string) (*http.Response, error) {
38157 reqHeaders := make(http.Header)
38158 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
38159 for k, v := range c.header_ {
38160 reqHeaders[k] = v
38161 }
38162 reqHeaders.Set("User-Agent", c.s.userAgent())
38163 if c.ifNoneMatch_ != "" {
38164 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
38165 }
38166 var body io.Reader = nil
38167 c.urlParams_.Set("alt", alt)
38168 c.urlParams_.Set("prettyPrint", "false")
38169 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/placementGroups")
38170 urls += "?" + c.urlParams_.Encode()
38171 req, err := http.NewRequest("GET", urls, body)
38172 if err != nil {
38173 return nil, err
38174 }
38175 req.Header = reqHeaders
38176 googleapi.Expand(req.URL, map[string]string{
38177 "profileId": strconv.FormatInt(c.profileId, 10),
38178 })
38179 return gensupport.SendRequest(c.ctx_, c.s.client, req)
38180 }
38181
38182
38183
38184
38185
38186
38187
38188
38189 func (c *PlacementGroupsListCall) Do(opts ...googleapi.CallOption) (*PlacementGroupsListResponse, error) {
38190 gensupport.SetOptions(c.urlParams_, opts...)
38191 res, err := c.doRequest("json")
38192 if res != nil && res.StatusCode == http.StatusNotModified {
38193 if res.Body != nil {
38194 res.Body.Close()
38195 }
38196 return nil, &googleapi.Error{
38197 Code: res.StatusCode,
38198 Header: res.Header,
38199 }
38200 }
38201 if err != nil {
38202 return nil, err
38203 }
38204 defer googleapi.CloseBody(res)
38205 if err := googleapi.CheckResponse(res); err != nil {
38206 return nil, err
38207 }
38208 ret := &PlacementGroupsListResponse{
38209 ServerResponse: googleapi.ServerResponse{
38210 Header: res.Header,
38211 HTTPStatusCode: res.StatusCode,
38212 },
38213 }
38214 target := &ret
38215 if err := gensupport.DecodeResponse(target, res); err != nil {
38216 return nil, err
38217 }
38218 return ret, nil
38219
38220
38221
38222
38223
38224
38225
38226
38227
38228
38229
38230
38231
38232
38233
38234
38235
38236
38237
38238
38239
38240
38241
38242
38243
38244
38245
38246
38247
38248
38249
38250
38251
38252
38253
38254
38255
38256
38257
38258
38259
38260
38261
38262
38263
38264
38265
38266
38267
38268
38269
38270
38271
38272
38273
38274
38275
38276
38277
38278
38279
38280
38281
38282
38283
38284
38285
38286
38287
38288
38289
38290
38291
38292
38293
38294
38295
38296
38297
38298
38299
38300
38301
38302
38303
38304
38305
38306
38307
38308
38309
38310
38311
38312
38313
38314
38315
38316
38317
38318
38319
38320
38321
38322
38323
38324
38325
38326
38327
38328
38329
38330
38331
38332
38333
38334
38335
38336
38337
38338
38339
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
38378
38379
38380
38381
38382
38383
38384
38385
38386
38387
38388
38389
38390
38391
38392
38393
38394
38395
38396
38397
38398
38399
38400 }
38401
38402
38403
38404
38405 func (c *PlacementGroupsListCall) Pages(ctx context.Context, f func(*PlacementGroupsListResponse) error) error {
38406 c.ctx_ = ctx
38407 defer c.PageToken(c.urlParams_.Get("pageToken"))
38408 for {
38409 x, err := c.Do()
38410 if err != nil {
38411 return err
38412 }
38413 if err := f(x); err != nil {
38414 return err
38415 }
38416 if x.NextPageToken == "" {
38417 return nil
38418 }
38419 c.PageToken(x.NextPageToken)
38420 }
38421 }
38422
38423
38424
38425 type PlacementGroupsPatchCall struct {
38426 s *Service
38427 profileId int64
38428 placementgroup *PlacementGroup
38429 urlParams_ gensupport.URLParams
38430 ctx_ context.Context
38431 header_ http.Header
38432 }
38433
38434
38435
38436 func (r *PlacementGroupsService) Patch(profileId int64, id int64, placementgroup *PlacementGroup) *PlacementGroupsPatchCall {
38437 c := &PlacementGroupsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
38438 c.profileId = profileId
38439 c.urlParams_.Set("id", fmt.Sprint(id))
38440 c.placementgroup = placementgroup
38441 return c
38442 }
38443
38444
38445
38446
38447 func (c *PlacementGroupsPatchCall) Fields(s ...googleapi.Field) *PlacementGroupsPatchCall {
38448 c.urlParams_.Set("fields", googleapi.CombineFields(s))
38449 return c
38450 }
38451
38452
38453
38454
38455 func (c *PlacementGroupsPatchCall) Context(ctx context.Context) *PlacementGroupsPatchCall {
38456 c.ctx_ = ctx
38457 return c
38458 }
38459
38460
38461
38462 func (c *PlacementGroupsPatchCall) Header() http.Header {
38463 if c.header_ == nil {
38464 c.header_ = make(http.Header)
38465 }
38466 return c.header_
38467 }
38468
38469 func (c *PlacementGroupsPatchCall) doRequest(alt string) (*http.Response, error) {
38470 reqHeaders := make(http.Header)
38471 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
38472 for k, v := range c.header_ {
38473 reqHeaders[k] = v
38474 }
38475 reqHeaders.Set("User-Agent", c.s.userAgent())
38476 var body io.Reader = nil
38477 body, err := googleapi.WithoutDataWrapper.JSONReader(c.placementgroup)
38478 if err != nil {
38479 return nil, err
38480 }
38481 reqHeaders.Set("Content-Type", "application/json")
38482 c.urlParams_.Set("alt", alt)
38483 c.urlParams_.Set("prettyPrint", "false")
38484 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/placementGroups")
38485 urls += "?" + c.urlParams_.Encode()
38486 req, err := http.NewRequest("PATCH", urls, body)
38487 if err != nil {
38488 return nil, err
38489 }
38490 req.Header = reqHeaders
38491 googleapi.Expand(req.URL, map[string]string{
38492 "profileId": strconv.FormatInt(c.profileId, 10),
38493 })
38494 return gensupport.SendRequest(c.ctx_, c.s.client, req)
38495 }
38496
38497
38498
38499
38500
38501
38502
38503
38504 func (c *PlacementGroupsPatchCall) Do(opts ...googleapi.CallOption) (*PlacementGroup, error) {
38505 gensupport.SetOptions(c.urlParams_, opts...)
38506 res, err := c.doRequest("json")
38507 if res != nil && res.StatusCode == http.StatusNotModified {
38508 if res.Body != nil {
38509 res.Body.Close()
38510 }
38511 return nil, &googleapi.Error{
38512 Code: res.StatusCode,
38513 Header: res.Header,
38514 }
38515 }
38516 if err != nil {
38517 return nil, err
38518 }
38519 defer googleapi.CloseBody(res)
38520 if err := googleapi.CheckResponse(res); err != nil {
38521 return nil, err
38522 }
38523 ret := &PlacementGroup{
38524 ServerResponse: googleapi.ServerResponse{
38525 Header: res.Header,
38526 HTTPStatusCode: res.StatusCode,
38527 },
38528 }
38529 target := &ret
38530 if err := gensupport.DecodeResponse(target, res); err != nil {
38531 return nil, err
38532 }
38533 return ret, nil
38534
38535
38536
38537
38538
38539
38540
38541
38542
38543
38544
38545
38546
38547
38548
38549
38550
38551
38552
38553
38554
38555
38556
38557
38558
38559
38560
38561
38562
38563
38564
38565
38566
38567
38568
38569
38570 }
38571
38572
38573
38574 type PlacementGroupsUpdateCall struct {
38575 s *Service
38576 profileId int64
38577 placementgroup *PlacementGroup
38578 urlParams_ gensupport.URLParams
38579 ctx_ context.Context
38580 header_ http.Header
38581 }
38582
38583
38584 func (r *PlacementGroupsService) Update(profileId int64, placementgroup *PlacementGroup) *PlacementGroupsUpdateCall {
38585 c := &PlacementGroupsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
38586 c.profileId = profileId
38587 c.placementgroup = placementgroup
38588 return c
38589 }
38590
38591
38592
38593
38594 func (c *PlacementGroupsUpdateCall) Fields(s ...googleapi.Field) *PlacementGroupsUpdateCall {
38595 c.urlParams_.Set("fields", googleapi.CombineFields(s))
38596 return c
38597 }
38598
38599
38600
38601
38602 func (c *PlacementGroupsUpdateCall) Context(ctx context.Context) *PlacementGroupsUpdateCall {
38603 c.ctx_ = ctx
38604 return c
38605 }
38606
38607
38608
38609 func (c *PlacementGroupsUpdateCall) Header() http.Header {
38610 if c.header_ == nil {
38611 c.header_ = make(http.Header)
38612 }
38613 return c.header_
38614 }
38615
38616 func (c *PlacementGroupsUpdateCall) doRequest(alt string) (*http.Response, error) {
38617 reqHeaders := make(http.Header)
38618 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
38619 for k, v := range c.header_ {
38620 reqHeaders[k] = v
38621 }
38622 reqHeaders.Set("User-Agent", c.s.userAgent())
38623 var body io.Reader = nil
38624 body, err := googleapi.WithoutDataWrapper.JSONReader(c.placementgroup)
38625 if err != nil {
38626 return nil, err
38627 }
38628 reqHeaders.Set("Content-Type", "application/json")
38629 c.urlParams_.Set("alt", alt)
38630 c.urlParams_.Set("prettyPrint", "false")
38631 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/placementGroups")
38632 urls += "?" + c.urlParams_.Encode()
38633 req, err := http.NewRequest("PUT", urls, body)
38634 if err != nil {
38635 return nil, err
38636 }
38637 req.Header = reqHeaders
38638 googleapi.Expand(req.URL, map[string]string{
38639 "profileId": strconv.FormatInt(c.profileId, 10),
38640 })
38641 return gensupport.SendRequest(c.ctx_, c.s.client, req)
38642 }
38643
38644
38645
38646
38647
38648
38649
38650
38651 func (c *PlacementGroupsUpdateCall) Do(opts ...googleapi.CallOption) (*PlacementGroup, error) {
38652 gensupport.SetOptions(c.urlParams_, opts...)
38653 res, err := c.doRequest("json")
38654 if res != nil && res.StatusCode == http.StatusNotModified {
38655 if res.Body != nil {
38656 res.Body.Close()
38657 }
38658 return nil, &googleapi.Error{
38659 Code: res.StatusCode,
38660 Header: res.Header,
38661 }
38662 }
38663 if err != nil {
38664 return nil, err
38665 }
38666 defer googleapi.CloseBody(res)
38667 if err := googleapi.CheckResponse(res); err != nil {
38668 return nil, err
38669 }
38670 ret := &PlacementGroup{
38671 ServerResponse: googleapi.ServerResponse{
38672 Header: res.Header,
38673 HTTPStatusCode: res.StatusCode,
38674 },
38675 }
38676 target := &ret
38677 if err := gensupport.DecodeResponse(target, res); err != nil {
38678 return nil, err
38679 }
38680 return ret, nil
38681
38682
38683
38684
38685
38686
38687
38688
38689
38690
38691
38692
38693
38694
38695
38696
38697
38698
38699
38700
38701
38702
38703
38704
38705
38706
38707
38708
38709 }
38710
38711
38712
38713 type PlacementStrategiesDeleteCall struct {
38714 s *Service
38715 profileId int64
38716 id int64
38717 urlParams_ gensupport.URLParams
38718 ctx_ context.Context
38719 header_ http.Header
38720 }
38721
38722
38723 func (r *PlacementStrategiesService) Delete(profileId int64, id int64) *PlacementStrategiesDeleteCall {
38724 c := &PlacementStrategiesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
38725 c.profileId = profileId
38726 c.id = id
38727 return c
38728 }
38729
38730
38731
38732
38733 func (c *PlacementStrategiesDeleteCall) Fields(s ...googleapi.Field) *PlacementStrategiesDeleteCall {
38734 c.urlParams_.Set("fields", googleapi.CombineFields(s))
38735 return c
38736 }
38737
38738
38739
38740
38741 func (c *PlacementStrategiesDeleteCall) Context(ctx context.Context) *PlacementStrategiesDeleteCall {
38742 c.ctx_ = ctx
38743 return c
38744 }
38745
38746
38747
38748 func (c *PlacementStrategiesDeleteCall) Header() http.Header {
38749 if c.header_ == nil {
38750 c.header_ = make(http.Header)
38751 }
38752 return c.header_
38753 }
38754
38755 func (c *PlacementStrategiesDeleteCall) doRequest(alt string) (*http.Response, error) {
38756 reqHeaders := make(http.Header)
38757 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
38758 for k, v := range c.header_ {
38759 reqHeaders[k] = v
38760 }
38761 reqHeaders.Set("User-Agent", c.s.userAgent())
38762 var body io.Reader = nil
38763 c.urlParams_.Set("alt", alt)
38764 c.urlParams_.Set("prettyPrint", "false")
38765 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/placementStrategies/{id}")
38766 urls += "?" + c.urlParams_.Encode()
38767 req, err := http.NewRequest("DELETE", urls, body)
38768 if err != nil {
38769 return nil, err
38770 }
38771 req.Header = reqHeaders
38772 googleapi.Expand(req.URL, map[string]string{
38773 "profileId": strconv.FormatInt(c.profileId, 10),
38774 "id": strconv.FormatInt(c.id, 10),
38775 })
38776 return gensupport.SendRequest(c.ctx_, c.s.client, req)
38777 }
38778
38779
38780 func (c *PlacementStrategiesDeleteCall) Do(opts ...googleapi.CallOption) error {
38781 gensupport.SetOptions(c.urlParams_, opts...)
38782 res, err := c.doRequest("json")
38783 if err != nil {
38784 return err
38785 }
38786 defer googleapi.CloseBody(res)
38787 if err := googleapi.CheckResponse(res); err != nil {
38788 return err
38789 }
38790 return nil
38791
38792
38793
38794
38795
38796
38797
38798
38799
38800
38801
38802
38803
38804
38805
38806
38807
38808
38809
38810
38811
38812
38813
38814
38815
38816
38817
38818
38819
38820
38821 }
38822
38823
38824
38825 type PlacementStrategiesGetCall struct {
38826 s *Service
38827 profileId int64
38828 id int64
38829 urlParams_ gensupport.URLParams
38830 ifNoneMatch_ string
38831 ctx_ context.Context
38832 header_ http.Header
38833 }
38834
38835
38836 func (r *PlacementStrategiesService) Get(profileId int64, id int64) *PlacementStrategiesGetCall {
38837 c := &PlacementStrategiesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
38838 c.profileId = profileId
38839 c.id = id
38840 return c
38841 }
38842
38843
38844
38845
38846 func (c *PlacementStrategiesGetCall) Fields(s ...googleapi.Field) *PlacementStrategiesGetCall {
38847 c.urlParams_.Set("fields", googleapi.CombineFields(s))
38848 return c
38849 }
38850
38851
38852
38853
38854
38855
38856 func (c *PlacementStrategiesGetCall) IfNoneMatch(entityTag string) *PlacementStrategiesGetCall {
38857 c.ifNoneMatch_ = entityTag
38858 return c
38859 }
38860
38861
38862
38863
38864 func (c *PlacementStrategiesGetCall) Context(ctx context.Context) *PlacementStrategiesGetCall {
38865 c.ctx_ = ctx
38866 return c
38867 }
38868
38869
38870
38871 func (c *PlacementStrategiesGetCall) Header() http.Header {
38872 if c.header_ == nil {
38873 c.header_ = make(http.Header)
38874 }
38875 return c.header_
38876 }
38877
38878 func (c *PlacementStrategiesGetCall) doRequest(alt string) (*http.Response, error) {
38879 reqHeaders := make(http.Header)
38880 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
38881 for k, v := range c.header_ {
38882 reqHeaders[k] = v
38883 }
38884 reqHeaders.Set("User-Agent", c.s.userAgent())
38885 if c.ifNoneMatch_ != "" {
38886 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
38887 }
38888 var body io.Reader = nil
38889 c.urlParams_.Set("alt", alt)
38890 c.urlParams_.Set("prettyPrint", "false")
38891 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/placementStrategies/{id}")
38892 urls += "?" + c.urlParams_.Encode()
38893 req, err := http.NewRequest("GET", urls, body)
38894 if err != nil {
38895 return nil, err
38896 }
38897 req.Header = reqHeaders
38898 googleapi.Expand(req.URL, map[string]string{
38899 "profileId": strconv.FormatInt(c.profileId, 10),
38900 "id": strconv.FormatInt(c.id, 10),
38901 })
38902 return gensupport.SendRequest(c.ctx_, c.s.client, req)
38903 }
38904
38905
38906
38907
38908
38909
38910
38911
38912 func (c *PlacementStrategiesGetCall) Do(opts ...googleapi.CallOption) (*PlacementStrategy, error) {
38913 gensupport.SetOptions(c.urlParams_, opts...)
38914 res, err := c.doRequest("json")
38915 if res != nil && res.StatusCode == http.StatusNotModified {
38916 if res.Body != nil {
38917 res.Body.Close()
38918 }
38919 return nil, &googleapi.Error{
38920 Code: res.StatusCode,
38921 Header: res.Header,
38922 }
38923 }
38924 if err != nil {
38925 return nil, err
38926 }
38927 defer googleapi.CloseBody(res)
38928 if err := googleapi.CheckResponse(res); err != nil {
38929 return nil, err
38930 }
38931 ret := &PlacementStrategy{
38932 ServerResponse: googleapi.ServerResponse{
38933 Header: res.Header,
38934 HTTPStatusCode: res.StatusCode,
38935 },
38936 }
38937 target := &ret
38938 if err := gensupport.DecodeResponse(target, res); err != nil {
38939 return nil, err
38940 }
38941 return ret, nil
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 type PlacementStrategiesInsertCall struct {
38980 s *Service
38981 profileId int64
38982 placementstrategy *PlacementStrategy
38983 urlParams_ gensupport.URLParams
38984 ctx_ context.Context
38985 header_ http.Header
38986 }
38987
38988
38989 func (r *PlacementStrategiesService) Insert(profileId int64, placementstrategy *PlacementStrategy) *PlacementStrategiesInsertCall {
38990 c := &PlacementStrategiesInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
38991 c.profileId = profileId
38992 c.placementstrategy = placementstrategy
38993 return c
38994 }
38995
38996
38997
38998
38999 func (c *PlacementStrategiesInsertCall) Fields(s ...googleapi.Field) *PlacementStrategiesInsertCall {
39000 c.urlParams_.Set("fields", googleapi.CombineFields(s))
39001 return c
39002 }
39003
39004
39005
39006
39007 func (c *PlacementStrategiesInsertCall) Context(ctx context.Context) *PlacementStrategiesInsertCall {
39008 c.ctx_ = ctx
39009 return c
39010 }
39011
39012
39013
39014 func (c *PlacementStrategiesInsertCall) Header() http.Header {
39015 if c.header_ == nil {
39016 c.header_ = make(http.Header)
39017 }
39018 return c.header_
39019 }
39020
39021 func (c *PlacementStrategiesInsertCall) doRequest(alt string) (*http.Response, error) {
39022 reqHeaders := make(http.Header)
39023 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
39024 for k, v := range c.header_ {
39025 reqHeaders[k] = v
39026 }
39027 reqHeaders.Set("User-Agent", c.s.userAgent())
39028 var body io.Reader = nil
39029 body, err := googleapi.WithoutDataWrapper.JSONReader(c.placementstrategy)
39030 if err != nil {
39031 return nil, err
39032 }
39033 reqHeaders.Set("Content-Type", "application/json")
39034 c.urlParams_.Set("alt", alt)
39035 c.urlParams_.Set("prettyPrint", "false")
39036 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/placementStrategies")
39037 urls += "?" + c.urlParams_.Encode()
39038 req, err := http.NewRequest("POST", urls, body)
39039 if err != nil {
39040 return nil, err
39041 }
39042 req.Header = reqHeaders
39043 googleapi.Expand(req.URL, map[string]string{
39044 "profileId": strconv.FormatInt(c.profileId, 10),
39045 })
39046 return gensupport.SendRequest(c.ctx_, c.s.client, req)
39047 }
39048
39049
39050
39051
39052
39053
39054
39055
39056 func (c *PlacementStrategiesInsertCall) Do(opts ...googleapi.CallOption) (*PlacementStrategy, error) {
39057 gensupport.SetOptions(c.urlParams_, opts...)
39058 res, err := c.doRequest("json")
39059 if res != nil && res.StatusCode == http.StatusNotModified {
39060 if res.Body != nil {
39061 res.Body.Close()
39062 }
39063 return nil, &googleapi.Error{
39064 Code: res.StatusCode,
39065 Header: res.Header,
39066 }
39067 }
39068 if err != nil {
39069 return nil, err
39070 }
39071 defer googleapi.CloseBody(res)
39072 if err := googleapi.CheckResponse(res); err != nil {
39073 return nil, err
39074 }
39075 ret := &PlacementStrategy{
39076 ServerResponse: googleapi.ServerResponse{
39077 Header: res.Header,
39078 HTTPStatusCode: res.StatusCode,
39079 },
39080 }
39081 target := &ret
39082 if err := gensupport.DecodeResponse(target, res); err != nil {
39083 return nil, err
39084 }
39085 return ret, nil
39086
39087
39088
39089
39090
39091
39092
39093
39094
39095
39096
39097
39098
39099
39100
39101
39102
39103
39104
39105
39106
39107
39108
39109
39110
39111
39112
39113
39114 }
39115
39116
39117
39118 type PlacementStrategiesListCall struct {
39119 s *Service
39120 profileId int64
39121 urlParams_ gensupport.URLParams
39122 ifNoneMatch_ string
39123 ctx_ context.Context
39124 header_ http.Header
39125 }
39126
39127
39128
39129 func (r *PlacementStrategiesService) List(profileId int64) *PlacementStrategiesListCall {
39130 c := &PlacementStrategiesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
39131 c.profileId = profileId
39132 return c
39133 }
39134
39135
39136
39137 func (c *PlacementStrategiesListCall) Ids(ids ...int64) *PlacementStrategiesListCall {
39138 var ids_ []string
39139 for _, v := range ids {
39140 ids_ = append(ids_, fmt.Sprint(v))
39141 }
39142 c.urlParams_.SetMulti("ids", ids_)
39143 return c
39144 }
39145
39146
39147
39148 func (c *PlacementStrategiesListCall) MaxResults(maxResults int64) *PlacementStrategiesListCall {
39149 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
39150 return c
39151 }
39152
39153
39154
39155 func (c *PlacementStrategiesListCall) PageToken(pageToken string) *PlacementStrategiesListCall {
39156 c.urlParams_.Set("pageToken", pageToken)
39157 return c
39158 }
39159
39160
39161
39162
39163
39164
39165
39166
39167
39168
39169 func (c *PlacementStrategiesListCall) SearchString(searchString string) *PlacementStrategiesListCall {
39170 c.urlParams_.Set("searchString", searchString)
39171 return c
39172 }
39173
39174
39175
39176
39177
39178
39179
39180
39181 func (c *PlacementStrategiesListCall) SortField(sortField string) *PlacementStrategiesListCall {
39182 c.urlParams_.Set("sortField", sortField)
39183 return c
39184 }
39185
39186
39187
39188
39189
39190
39191
39192
39193 func (c *PlacementStrategiesListCall) SortOrder(sortOrder string) *PlacementStrategiesListCall {
39194 c.urlParams_.Set("sortOrder", sortOrder)
39195 return c
39196 }
39197
39198
39199
39200
39201 func (c *PlacementStrategiesListCall) Fields(s ...googleapi.Field) *PlacementStrategiesListCall {
39202 c.urlParams_.Set("fields", googleapi.CombineFields(s))
39203 return c
39204 }
39205
39206
39207
39208
39209
39210
39211 func (c *PlacementStrategiesListCall) IfNoneMatch(entityTag string) *PlacementStrategiesListCall {
39212 c.ifNoneMatch_ = entityTag
39213 return c
39214 }
39215
39216
39217
39218
39219 func (c *PlacementStrategiesListCall) Context(ctx context.Context) *PlacementStrategiesListCall {
39220 c.ctx_ = ctx
39221 return c
39222 }
39223
39224
39225
39226 func (c *PlacementStrategiesListCall) Header() http.Header {
39227 if c.header_ == nil {
39228 c.header_ = make(http.Header)
39229 }
39230 return c.header_
39231 }
39232
39233 func (c *PlacementStrategiesListCall) 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 if c.ifNoneMatch_ != "" {
39241 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
39242 }
39243 var body io.Reader = nil
39244 c.urlParams_.Set("alt", alt)
39245 c.urlParams_.Set("prettyPrint", "false")
39246 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/placementStrategies")
39247 urls += "?" + c.urlParams_.Encode()
39248 req, err := http.NewRequest("GET", urls, body)
39249 if err != nil {
39250 return nil, err
39251 }
39252 req.Header = reqHeaders
39253 googleapi.Expand(req.URL, map[string]string{
39254 "profileId": strconv.FormatInt(c.profileId, 10),
39255 })
39256 return gensupport.SendRequest(c.ctx_, c.s.client, req)
39257 }
39258
39259
39260
39261
39262
39263
39264
39265
39266 func (c *PlacementStrategiesListCall) Do(opts ...googleapi.CallOption) (*PlacementStrategiesListResponse, error) {
39267 gensupport.SetOptions(c.urlParams_, opts...)
39268 res, err := c.doRequest("json")
39269 if res != nil && res.StatusCode == http.StatusNotModified {
39270 if res.Body != nil {
39271 res.Body.Close()
39272 }
39273 return nil, &googleapi.Error{
39274 Code: res.StatusCode,
39275 Header: res.Header,
39276 }
39277 }
39278 if err != nil {
39279 return nil, err
39280 }
39281 defer googleapi.CloseBody(res)
39282 if err := googleapi.CheckResponse(res); err != nil {
39283 return nil, err
39284 }
39285 ret := &PlacementStrategiesListResponse{
39286 ServerResponse: googleapi.ServerResponse{
39287 Header: res.Header,
39288 HTTPStatusCode: res.StatusCode,
39289 },
39290 }
39291 target := &ret
39292 if err := gensupport.DecodeResponse(target, res); err != nil {
39293 return nil, err
39294 }
39295 return ret, nil
39296
39297
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
39331
39332
39333
39334
39335
39336
39337
39338
39339
39340
39341
39342
39343
39344
39345
39346
39347
39348
39349
39350
39351
39352
39353
39354
39355
39356
39357
39358
39359
39360
39361
39362
39363
39364
39365
39366
39367
39368
39369
39370
39371
39372
39373
39374
39375 }
39376
39377
39378
39379
39380 func (c *PlacementStrategiesListCall) Pages(ctx context.Context, f func(*PlacementStrategiesListResponse) error) error {
39381 c.ctx_ = ctx
39382 defer c.PageToken(c.urlParams_.Get("pageToken"))
39383 for {
39384 x, err := c.Do()
39385 if err != nil {
39386 return err
39387 }
39388 if err := f(x); err != nil {
39389 return err
39390 }
39391 if x.NextPageToken == "" {
39392 return nil
39393 }
39394 c.PageToken(x.NextPageToken)
39395 }
39396 }
39397
39398
39399
39400 type PlacementStrategiesPatchCall struct {
39401 s *Service
39402 profileId int64
39403 placementstrategy *PlacementStrategy
39404 urlParams_ gensupport.URLParams
39405 ctx_ context.Context
39406 header_ http.Header
39407 }
39408
39409
39410
39411 func (r *PlacementStrategiesService) Patch(profileId int64, id int64, placementstrategy *PlacementStrategy) *PlacementStrategiesPatchCall {
39412 c := &PlacementStrategiesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
39413 c.profileId = profileId
39414 c.urlParams_.Set("id", fmt.Sprint(id))
39415 c.placementstrategy = placementstrategy
39416 return c
39417 }
39418
39419
39420
39421
39422 func (c *PlacementStrategiesPatchCall) Fields(s ...googleapi.Field) *PlacementStrategiesPatchCall {
39423 c.urlParams_.Set("fields", googleapi.CombineFields(s))
39424 return c
39425 }
39426
39427
39428
39429
39430 func (c *PlacementStrategiesPatchCall) Context(ctx context.Context) *PlacementStrategiesPatchCall {
39431 c.ctx_ = ctx
39432 return c
39433 }
39434
39435
39436
39437 func (c *PlacementStrategiesPatchCall) Header() http.Header {
39438 if c.header_ == nil {
39439 c.header_ = make(http.Header)
39440 }
39441 return c.header_
39442 }
39443
39444 func (c *PlacementStrategiesPatchCall) doRequest(alt string) (*http.Response, error) {
39445 reqHeaders := make(http.Header)
39446 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
39447 for k, v := range c.header_ {
39448 reqHeaders[k] = v
39449 }
39450 reqHeaders.Set("User-Agent", c.s.userAgent())
39451 var body io.Reader = nil
39452 body, err := googleapi.WithoutDataWrapper.JSONReader(c.placementstrategy)
39453 if err != nil {
39454 return nil, err
39455 }
39456 reqHeaders.Set("Content-Type", "application/json")
39457 c.urlParams_.Set("alt", alt)
39458 c.urlParams_.Set("prettyPrint", "false")
39459 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/placementStrategies")
39460 urls += "?" + c.urlParams_.Encode()
39461 req, err := http.NewRequest("PATCH", urls, body)
39462 if err != nil {
39463 return nil, err
39464 }
39465 req.Header = reqHeaders
39466 googleapi.Expand(req.URL, map[string]string{
39467 "profileId": strconv.FormatInt(c.profileId, 10),
39468 })
39469 return gensupport.SendRequest(c.ctx_, c.s.client, req)
39470 }
39471
39472
39473
39474
39475
39476
39477
39478
39479 func (c *PlacementStrategiesPatchCall) Do(opts ...googleapi.CallOption) (*PlacementStrategy, error) {
39480 gensupport.SetOptions(c.urlParams_, opts...)
39481 res, err := c.doRequest("json")
39482 if res != nil && res.StatusCode == http.StatusNotModified {
39483 if res.Body != nil {
39484 res.Body.Close()
39485 }
39486 return nil, &googleapi.Error{
39487 Code: res.StatusCode,
39488 Header: res.Header,
39489 }
39490 }
39491 if err != nil {
39492 return nil, err
39493 }
39494 defer googleapi.CloseBody(res)
39495 if err := googleapi.CheckResponse(res); err != nil {
39496 return nil, err
39497 }
39498 ret := &PlacementStrategy{
39499 ServerResponse: googleapi.ServerResponse{
39500 Header: res.Header,
39501 HTTPStatusCode: res.StatusCode,
39502 },
39503 }
39504 target := &ret
39505 if err := gensupport.DecodeResponse(target, res); err != nil {
39506 return nil, err
39507 }
39508 return ret, nil
39509
39510
39511
39512
39513
39514
39515
39516
39517
39518
39519
39520
39521
39522
39523
39524
39525
39526
39527
39528
39529
39530
39531
39532
39533
39534
39535
39536
39537
39538
39539
39540
39541
39542
39543
39544
39545 }
39546
39547
39548
39549 type PlacementStrategiesUpdateCall struct {
39550 s *Service
39551 profileId int64
39552 placementstrategy *PlacementStrategy
39553 urlParams_ gensupport.URLParams
39554 ctx_ context.Context
39555 header_ http.Header
39556 }
39557
39558
39559 func (r *PlacementStrategiesService) Update(profileId int64, placementstrategy *PlacementStrategy) *PlacementStrategiesUpdateCall {
39560 c := &PlacementStrategiesUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
39561 c.profileId = profileId
39562 c.placementstrategy = placementstrategy
39563 return c
39564 }
39565
39566
39567
39568
39569 func (c *PlacementStrategiesUpdateCall) Fields(s ...googleapi.Field) *PlacementStrategiesUpdateCall {
39570 c.urlParams_.Set("fields", googleapi.CombineFields(s))
39571 return c
39572 }
39573
39574
39575
39576
39577 func (c *PlacementStrategiesUpdateCall) Context(ctx context.Context) *PlacementStrategiesUpdateCall {
39578 c.ctx_ = ctx
39579 return c
39580 }
39581
39582
39583
39584 func (c *PlacementStrategiesUpdateCall) Header() http.Header {
39585 if c.header_ == nil {
39586 c.header_ = make(http.Header)
39587 }
39588 return c.header_
39589 }
39590
39591 func (c *PlacementStrategiesUpdateCall) doRequest(alt string) (*http.Response, error) {
39592 reqHeaders := make(http.Header)
39593 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
39594 for k, v := range c.header_ {
39595 reqHeaders[k] = v
39596 }
39597 reqHeaders.Set("User-Agent", c.s.userAgent())
39598 var body io.Reader = nil
39599 body, err := googleapi.WithoutDataWrapper.JSONReader(c.placementstrategy)
39600 if err != nil {
39601 return nil, err
39602 }
39603 reqHeaders.Set("Content-Type", "application/json")
39604 c.urlParams_.Set("alt", alt)
39605 c.urlParams_.Set("prettyPrint", "false")
39606 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/placementStrategies")
39607 urls += "?" + c.urlParams_.Encode()
39608 req, err := http.NewRequest("PUT", urls, body)
39609 if err != nil {
39610 return nil, err
39611 }
39612 req.Header = reqHeaders
39613 googleapi.Expand(req.URL, map[string]string{
39614 "profileId": strconv.FormatInt(c.profileId, 10),
39615 })
39616 return gensupport.SendRequest(c.ctx_, c.s.client, req)
39617 }
39618
39619
39620
39621
39622
39623
39624
39625
39626 func (c *PlacementStrategiesUpdateCall) Do(opts ...googleapi.CallOption) (*PlacementStrategy, error) {
39627 gensupport.SetOptions(c.urlParams_, opts...)
39628 res, err := c.doRequest("json")
39629 if res != nil && res.StatusCode == http.StatusNotModified {
39630 if res.Body != nil {
39631 res.Body.Close()
39632 }
39633 return nil, &googleapi.Error{
39634 Code: res.StatusCode,
39635 Header: res.Header,
39636 }
39637 }
39638 if err != nil {
39639 return nil, err
39640 }
39641 defer googleapi.CloseBody(res)
39642 if err := googleapi.CheckResponse(res); err != nil {
39643 return nil, err
39644 }
39645 ret := &PlacementStrategy{
39646 ServerResponse: googleapi.ServerResponse{
39647 Header: res.Header,
39648 HTTPStatusCode: res.StatusCode,
39649 },
39650 }
39651 target := &ret
39652 if err := gensupport.DecodeResponse(target, res); err != nil {
39653 return nil, err
39654 }
39655 return ret, nil
39656
39657
39658
39659
39660
39661
39662
39663
39664
39665
39666
39667
39668
39669
39670
39671
39672
39673
39674
39675
39676
39677
39678
39679
39680
39681
39682
39683
39684 }
39685
39686
39687
39688 type PlacementsGeneratetagsCall struct {
39689 s *Service
39690 profileId int64
39691 urlParams_ gensupport.URLParams
39692 ctx_ context.Context
39693 header_ http.Header
39694 }
39695
39696
39697 func (r *PlacementsService) Generatetags(profileId int64) *PlacementsGeneratetagsCall {
39698 c := &PlacementsGeneratetagsCall{s: r.s, urlParams_: make(gensupport.URLParams)}
39699 c.profileId = profileId
39700 return c
39701 }
39702
39703
39704
39705 func (c *PlacementsGeneratetagsCall) CampaignId(campaignId int64) *PlacementsGeneratetagsCall {
39706 c.urlParams_.Set("campaignId", fmt.Sprint(campaignId))
39707 return c
39708 }
39709
39710
39711
39712 func (c *PlacementsGeneratetagsCall) PlacementIds(placementIds ...int64) *PlacementsGeneratetagsCall {
39713 var placementIds_ []string
39714 for _, v := range placementIds {
39715 placementIds_ = append(placementIds_, fmt.Sprint(v))
39716 }
39717 c.urlParams_.SetMulti("placementIds", placementIds_)
39718 return c
39719 }
39720
39721
39722
39723
39724
39725
39726
39727
39728
39729
39730
39731
39732
39733
39734
39735
39736
39737
39738
39739
39740
39741
39742
39743
39744
39745
39746
39747
39748 func (c *PlacementsGeneratetagsCall) TagFormats(tagFormats ...string) *PlacementsGeneratetagsCall {
39749 c.urlParams_.SetMulti("tagFormats", append([]string{}, tagFormats...))
39750 return c
39751 }
39752
39753
39754
39755
39756 func (c *PlacementsGeneratetagsCall) Fields(s ...googleapi.Field) *PlacementsGeneratetagsCall {
39757 c.urlParams_.Set("fields", googleapi.CombineFields(s))
39758 return c
39759 }
39760
39761
39762
39763
39764 func (c *PlacementsGeneratetagsCall) Context(ctx context.Context) *PlacementsGeneratetagsCall {
39765 c.ctx_ = ctx
39766 return c
39767 }
39768
39769
39770
39771 func (c *PlacementsGeneratetagsCall) Header() http.Header {
39772 if c.header_ == nil {
39773 c.header_ = make(http.Header)
39774 }
39775 return c.header_
39776 }
39777
39778 func (c *PlacementsGeneratetagsCall) doRequest(alt string) (*http.Response, error) {
39779 reqHeaders := make(http.Header)
39780 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
39781 for k, v := range c.header_ {
39782 reqHeaders[k] = v
39783 }
39784 reqHeaders.Set("User-Agent", c.s.userAgent())
39785 var body io.Reader = nil
39786 c.urlParams_.Set("alt", alt)
39787 c.urlParams_.Set("prettyPrint", "false")
39788 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/placements/generatetags")
39789 urls += "?" + c.urlParams_.Encode()
39790 req, err := http.NewRequest("POST", urls, body)
39791 if err != nil {
39792 return nil, err
39793 }
39794 req.Header = reqHeaders
39795 googleapi.Expand(req.URL, map[string]string{
39796 "profileId": strconv.FormatInt(c.profileId, 10),
39797 })
39798 return gensupport.SendRequest(c.ctx_, c.s.client, req)
39799 }
39800
39801
39802
39803
39804
39805
39806
39807
39808 func (c *PlacementsGeneratetagsCall) Do(opts ...googleapi.CallOption) (*PlacementsGenerateTagsResponse, error) {
39809 gensupport.SetOptions(c.urlParams_, opts...)
39810 res, err := c.doRequest("json")
39811 if res != nil && res.StatusCode == http.StatusNotModified {
39812 if res.Body != nil {
39813 res.Body.Close()
39814 }
39815 return nil, &googleapi.Error{
39816 Code: res.StatusCode,
39817 Header: res.Header,
39818 }
39819 }
39820 if err != nil {
39821 return nil, err
39822 }
39823 defer googleapi.CloseBody(res)
39824 if err := googleapi.CheckResponse(res); err != nil {
39825 return nil, err
39826 }
39827 ret := &PlacementsGenerateTagsResponse{
39828 ServerResponse: googleapi.ServerResponse{
39829 Header: res.Header,
39830 HTTPStatusCode: res.StatusCode,
39831 },
39832 }
39833 target := &ret
39834 if err := gensupport.DecodeResponse(target, res); err != nil {
39835 return nil, err
39836 }
39837 return ret, nil
39838
39839
39840
39841
39842
39843
39844
39845
39846
39847
39848
39849
39850
39851
39852
39853
39854
39855
39856
39857
39858
39859
39860
39861
39862
39863
39864
39865
39866
39867
39868
39869
39870
39871
39872
39873
39874
39875
39876
39877
39878
39879
39880
39881
39882
39883
39884
39885
39886
39887
39888
39889
39890
39891
39892
39893
39894
39895
39896
39897
39898
39899
39900
39901
39902
39903
39904
39905
39906
39907
39908
39909
39910
39911
39912
39913
39914
39915
39916
39917
39918
39919
39920
39921
39922
39923
39924 }
39925
39926
39927
39928 type PlacementsGetCall struct {
39929 s *Service
39930 profileId int64
39931 id int64
39932 urlParams_ gensupport.URLParams
39933 ifNoneMatch_ string
39934 ctx_ context.Context
39935 header_ http.Header
39936 }
39937
39938
39939 func (r *PlacementsService) Get(profileId int64, id int64) *PlacementsGetCall {
39940 c := &PlacementsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
39941 c.profileId = profileId
39942 c.id = id
39943 return c
39944 }
39945
39946
39947
39948
39949 func (c *PlacementsGetCall) Fields(s ...googleapi.Field) *PlacementsGetCall {
39950 c.urlParams_.Set("fields", googleapi.CombineFields(s))
39951 return c
39952 }
39953
39954
39955
39956
39957
39958
39959 func (c *PlacementsGetCall) IfNoneMatch(entityTag string) *PlacementsGetCall {
39960 c.ifNoneMatch_ = entityTag
39961 return c
39962 }
39963
39964
39965
39966
39967 func (c *PlacementsGetCall) Context(ctx context.Context) *PlacementsGetCall {
39968 c.ctx_ = ctx
39969 return c
39970 }
39971
39972
39973
39974 func (c *PlacementsGetCall) Header() http.Header {
39975 if c.header_ == nil {
39976 c.header_ = make(http.Header)
39977 }
39978 return c.header_
39979 }
39980
39981 func (c *PlacementsGetCall) doRequest(alt string) (*http.Response, error) {
39982 reqHeaders := make(http.Header)
39983 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
39984 for k, v := range c.header_ {
39985 reqHeaders[k] = v
39986 }
39987 reqHeaders.Set("User-Agent", c.s.userAgent())
39988 if c.ifNoneMatch_ != "" {
39989 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
39990 }
39991 var body io.Reader = nil
39992 c.urlParams_.Set("alt", alt)
39993 c.urlParams_.Set("prettyPrint", "false")
39994 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/placements/{id}")
39995 urls += "?" + c.urlParams_.Encode()
39996 req, err := http.NewRequest("GET", urls, body)
39997 if err != nil {
39998 return nil, err
39999 }
40000 req.Header = reqHeaders
40001 googleapi.Expand(req.URL, map[string]string{
40002 "profileId": strconv.FormatInt(c.profileId, 10),
40003 "id": strconv.FormatInt(c.id, 10),
40004 })
40005 return gensupport.SendRequest(c.ctx_, c.s.client, req)
40006 }
40007
40008
40009
40010
40011
40012
40013
40014
40015 func (c *PlacementsGetCall) Do(opts ...googleapi.CallOption) (*Placement, error) {
40016 gensupport.SetOptions(c.urlParams_, opts...)
40017 res, err := c.doRequest("json")
40018 if res != nil && res.StatusCode == http.StatusNotModified {
40019 if res.Body != nil {
40020 res.Body.Close()
40021 }
40022 return nil, &googleapi.Error{
40023 Code: res.StatusCode,
40024 Header: res.Header,
40025 }
40026 }
40027 if err != nil {
40028 return nil, err
40029 }
40030 defer googleapi.CloseBody(res)
40031 if err := googleapi.CheckResponse(res); err != nil {
40032 return nil, err
40033 }
40034 ret := &Placement{
40035 ServerResponse: googleapi.ServerResponse{
40036 Header: res.Header,
40037 HTTPStatusCode: res.StatusCode,
40038 },
40039 }
40040 target := &ret
40041 if err := gensupport.DecodeResponse(target, res); err != nil {
40042 return nil, err
40043 }
40044 return ret, nil
40045
40046
40047
40048
40049
40050
40051
40052
40053
40054
40055
40056
40057
40058
40059
40060
40061
40062
40063
40064
40065
40066
40067
40068
40069
40070
40071
40072
40073
40074
40075
40076
40077
40078 }
40079
40080
40081
40082 type PlacementsInsertCall struct {
40083 s *Service
40084 profileId int64
40085 placement *Placement
40086 urlParams_ gensupport.URLParams
40087 ctx_ context.Context
40088 header_ http.Header
40089 }
40090
40091
40092 func (r *PlacementsService) Insert(profileId int64, placement *Placement) *PlacementsInsertCall {
40093 c := &PlacementsInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
40094 c.profileId = profileId
40095 c.placement = placement
40096 return c
40097 }
40098
40099
40100
40101
40102 func (c *PlacementsInsertCall) Fields(s ...googleapi.Field) *PlacementsInsertCall {
40103 c.urlParams_.Set("fields", googleapi.CombineFields(s))
40104 return c
40105 }
40106
40107
40108
40109
40110 func (c *PlacementsInsertCall) Context(ctx context.Context) *PlacementsInsertCall {
40111 c.ctx_ = ctx
40112 return c
40113 }
40114
40115
40116
40117 func (c *PlacementsInsertCall) Header() http.Header {
40118 if c.header_ == nil {
40119 c.header_ = make(http.Header)
40120 }
40121 return c.header_
40122 }
40123
40124 func (c *PlacementsInsertCall) doRequest(alt string) (*http.Response, error) {
40125 reqHeaders := make(http.Header)
40126 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
40127 for k, v := range c.header_ {
40128 reqHeaders[k] = v
40129 }
40130 reqHeaders.Set("User-Agent", c.s.userAgent())
40131 var body io.Reader = nil
40132 body, err := googleapi.WithoutDataWrapper.JSONReader(c.placement)
40133 if err != nil {
40134 return nil, err
40135 }
40136 reqHeaders.Set("Content-Type", "application/json")
40137 c.urlParams_.Set("alt", alt)
40138 c.urlParams_.Set("prettyPrint", "false")
40139 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/placements")
40140 urls += "?" + c.urlParams_.Encode()
40141 req, err := http.NewRequest("POST", urls, body)
40142 if err != nil {
40143 return nil, err
40144 }
40145 req.Header = reqHeaders
40146 googleapi.Expand(req.URL, map[string]string{
40147 "profileId": strconv.FormatInt(c.profileId, 10),
40148 })
40149 return gensupport.SendRequest(c.ctx_, c.s.client, req)
40150 }
40151
40152
40153
40154
40155
40156
40157
40158
40159 func (c *PlacementsInsertCall) Do(opts ...googleapi.CallOption) (*Placement, error) {
40160 gensupport.SetOptions(c.urlParams_, opts...)
40161 res, err := c.doRequest("json")
40162 if res != nil && res.StatusCode == http.StatusNotModified {
40163 if res.Body != nil {
40164 res.Body.Close()
40165 }
40166 return nil, &googleapi.Error{
40167 Code: res.StatusCode,
40168 Header: res.Header,
40169 }
40170 }
40171 if err != nil {
40172 return nil, err
40173 }
40174 defer googleapi.CloseBody(res)
40175 if err := googleapi.CheckResponse(res); err != nil {
40176 return nil, err
40177 }
40178 ret := &Placement{
40179 ServerResponse: googleapi.ServerResponse{
40180 Header: res.Header,
40181 HTTPStatusCode: res.StatusCode,
40182 },
40183 }
40184 target := &ret
40185 if err := gensupport.DecodeResponse(target, res); err != nil {
40186 return nil, err
40187 }
40188 return ret, nil
40189
40190
40191
40192
40193
40194
40195
40196
40197
40198
40199
40200
40201
40202
40203
40204
40205
40206
40207
40208
40209
40210
40211
40212
40213
40214
40215
40216
40217 }
40218
40219
40220
40221 type PlacementsListCall struct {
40222 s *Service
40223 profileId int64
40224 urlParams_ gensupport.URLParams
40225 ifNoneMatch_ string
40226 ctx_ context.Context
40227 header_ http.Header
40228 }
40229
40230
40231
40232 func (r *PlacementsService) List(profileId int64) *PlacementsListCall {
40233 c := &PlacementsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
40234 c.profileId = profileId
40235 return c
40236 }
40237
40238
40239
40240 func (c *PlacementsListCall) AdvertiserIds(advertiserIds ...int64) *PlacementsListCall {
40241 var advertiserIds_ []string
40242 for _, v := range advertiserIds {
40243 advertiserIds_ = append(advertiserIds_, fmt.Sprint(v))
40244 }
40245 c.urlParams_.SetMulti("advertiserIds", advertiserIds_)
40246 return c
40247 }
40248
40249
40250
40251
40252 func (c *PlacementsListCall) Archived(archived bool) *PlacementsListCall {
40253 c.urlParams_.Set("archived", fmt.Sprint(archived))
40254 return c
40255 }
40256
40257
40258
40259 func (c *PlacementsListCall) CampaignIds(campaignIds ...int64) *PlacementsListCall {
40260 var campaignIds_ []string
40261 for _, v := range campaignIds {
40262 campaignIds_ = append(campaignIds_, fmt.Sprint(v))
40263 }
40264 c.urlParams_.SetMulti("campaignIds", campaignIds_)
40265 return c
40266 }
40267
40268
40269
40270
40271
40272
40273
40274
40275
40276
40277
40278
40279
40280
40281
40282
40283
40284 func (c *PlacementsListCall) Compatibilities(compatibilities ...string) *PlacementsListCall {
40285 c.urlParams_.SetMulti("compatibilities", append([]string{}, compatibilities...))
40286 return c
40287 }
40288
40289
40290
40291
40292 func (c *PlacementsListCall) ContentCategoryIds(contentCategoryIds ...int64) *PlacementsListCall {
40293 var contentCategoryIds_ []string
40294 for _, v := range contentCategoryIds {
40295 contentCategoryIds_ = append(contentCategoryIds_, fmt.Sprint(v))
40296 }
40297 c.urlParams_.SetMulti("contentCategoryIds", contentCategoryIds_)
40298 return c
40299 }
40300
40301
40302
40303
40304 func (c *PlacementsListCall) DirectorySiteIds(directorySiteIds ...int64) *PlacementsListCall {
40305 var directorySiteIds_ []string
40306 for _, v := range directorySiteIds {
40307 directorySiteIds_ = append(directorySiteIds_, fmt.Sprint(v))
40308 }
40309 c.urlParams_.SetMulti("directorySiteIds", directorySiteIds_)
40310 return c
40311 }
40312
40313
40314
40315 func (c *PlacementsListCall) GroupIds(groupIds ...int64) *PlacementsListCall {
40316 var groupIds_ []string
40317 for _, v := range groupIds {
40318 groupIds_ = append(groupIds_, fmt.Sprint(v))
40319 }
40320 c.urlParams_.SetMulti("groupIds", groupIds_)
40321 return c
40322 }
40323
40324
40325
40326 func (c *PlacementsListCall) Ids(ids ...int64) *PlacementsListCall {
40327 var ids_ []string
40328 for _, v := range ids {
40329 ids_ = append(ids_, fmt.Sprint(v))
40330 }
40331 c.urlParams_.SetMulti("ids", ids_)
40332 return c
40333 }
40334
40335
40336
40337
40338 func (c *PlacementsListCall) MaxEndDate(maxEndDate string) *PlacementsListCall {
40339 c.urlParams_.Set("maxEndDate", maxEndDate)
40340 return c
40341 }
40342
40343
40344
40345 func (c *PlacementsListCall) MaxResults(maxResults int64) *PlacementsListCall {
40346 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
40347 return c
40348 }
40349
40350
40351
40352
40353 func (c *PlacementsListCall) MaxStartDate(maxStartDate string) *PlacementsListCall {
40354 c.urlParams_.Set("maxStartDate", maxStartDate)
40355 return c
40356 }
40357
40358
40359
40360
40361 func (c *PlacementsListCall) MinEndDate(minEndDate string) *PlacementsListCall {
40362 c.urlParams_.Set("minEndDate", minEndDate)
40363 return c
40364 }
40365
40366
40367
40368
40369 func (c *PlacementsListCall) MinStartDate(minStartDate string) *PlacementsListCall {
40370 c.urlParams_.Set("minStartDate", minStartDate)
40371 return c
40372 }
40373
40374
40375
40376 func (c *PlacementsListCall) PageToken(pageToken string) *PlacementsListCall {
40377 c.urlParams_.Set("pageToken", pageToken)
40378 return c
40379 }
40380
40381
40382
40383
40384
40385
40386
40387
40388 func (c *PlacementsListCall) PaymentSource(paymentSource string) *PlacementsListCall {
40389 c.urlParams_.Set("paymentSource", paymentSource)
40390 return c
40391 }
40392
40393
40394
40395
40396 func (c *PlacementsListCall) PlacementStrategyIds(placementStrategyIds ...int64) *PlacementsListCall {
40397 var placementStrategyIds_ []string
40398 for _, v := range placementStrategyIds {
40399 placementStrategyIds_ = append(placementStrategyIds_, fmt.Sprint(v))
40400 }
40401 c.urlParams_.SetMulti("placementStrategyIds", placementStrategyIds_)
40402 return c
40403 }
40404
40405
40406
40407
40408
40409
40410
40411
40412
40413
40414
40415
40416 func (c *PlacementsListCall) PricingTypes(pricingTypes ...string) *PlacementsListCall {
40417 c.urlParams_.SetMulti("pricingTypes", append([]string{}, pricingTypes...))
40418 return c
40419 }
40420
40421
40422
40423
40424
40425
40426
40427
40428
40429 func (c *PlacementsListCall) SearchString(searchString string) *PlacementsListCall {
40430 c.urlParams_.Set("searchString", searchString)
40431 return c
40432 }
40433
40434
40435
40436 func (c *PlacementsListCall) SiteIds(siteIds ...int64) *PlacementsListCall {
40437 var siteIds_ []string
40438 for _, v := range siteIds {
40439 siteIds_ = append(siteIds_, fmt.Sprint(v))
40440 }
40441 c.urlParams_.SetMulti("siteIds", siteIds_)
40442 return c
40443 }
40444
40445
40446
40447 func (c *PlacementsListCall) SizeIds(sizeIds ...int64) *PlacementsListCall {
40448 var sizeIds_ []string
40449 for _, v := range sizeIds {
40450 sizeIds_ = append(sizeIds_, fmt.Sprint(v))
40451 }
40452 c.urlParams_.SetMulti("sizeIds", sizeIds_)
40453 return c
40454 }
40455
40456
40457
40458
40459
40460
40461
40462
40463 func (c *PlacementsListCall) SortField(sortField string) *PlacementsListCall {
40464 c.urlParams_.Set("sortField", sortField)
40465 return c
40466 }
40467
40468
40469
40470
40471
40472
40473
40474
40475 func (c *PlacementsListCall) SortOrder(sortOrder string) *PlacementsListCall {
40476 c.urlParams_.Set("sortOrder", sortOrder)
40477 return c
40478 }
40479
40480
40481
40482
40483 func (c *PlacementsListCall) Fields(s ...googleapi.Field) *PlacementsListCall {
40484 c.urlParams_.Set("fields", googleapi.CombineFields(s))
40485 return c
40486 }
40487
40488
40489
40490
40491
40492
40493 func (c *PlacementsListCall) IfNoneMatch(entityTag string) *PlacementsListCall {
40494 c.ifNoneMatch_ = entityTag
40495 return c
40496 }
40497
40498
40499
40500
40501 func (c *PlacementsListCall) Context(ctx context.Context) *PlacementsListCall {
40502 c.ctx_ = ctx
40503 return c
40504 }
40505
40506
40507
40508 func (c *PlacementsListCall) Header() http.Header {
40509 if c.header_ == nil {
40510 c.header_ = make(http.Header)
40511 }
40512 return c.header_
40513 }
40514
40515 func (c *PlacementsListCall) doRequest(alt string) (*http.Response, error) {
40516 reqHeaders := make(http.Header)
40517 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
40518 for k, v := range c.header_ {
40519 reqHeaders[k] = v
40520 }
40521 reqHeaders.Set("User-Agent", c.s.userAgent())
40522 if c.ifNoneMatch_ != "" {
40523 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
40524 }
40525 var body io.Reader = nil
40526 c.urlParams_.Set("alt", alt)
40527 c.urlParams_.Set("prettyPrint", "false")
40528 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/placements")
40529 urls += "?" + c.urlParams_.Encode()
40530 req, err := http.NewRequest("GET", urls, body)
40531 if err != nil {
40532 return nil, err
40533 }
40534 req.Header = reqHeaders
40535 googleapi.Expand(req.URL, map[string]string{
40536 "profileId": strconv.FormatInt(c.profileId, 10),
40537 })
40538 return gensupport.SendRequest(c.ctx_, c.s.client, req)
40539 }
40540
40541
40542
40543
40544
40545
40546
40547
40548 func (c *PlacementsListCall) Do(opts ...googleapi.CallOption) (*PlacementsListResponse, error) {
40549 gensupport.SetOptions(c.urlParams_, opts...)
40550 res, err := c.doRequest("json")
40551 if res != nil && res.StatusCode == http.StatusNotModified {
40552 if res.Body != nil {
40553 res.Body.Close()
40554 }
40555 return nil, &googleapi.Error{
40556 Code: res.StatusCode,
40557 Header: res.Header,
40558 }
40559 }
40560 if err != nil {
40561 return nil, err
40562 }
40563 defer googleapi.CloseBody(res)
40564 if err := googleapi.CheckResponse(res); err != nil {
40565 return nil, err
40566 }
40567 ret := &PlacementsListResponse{
40568 ServerResponse: googleapi.ServerResponse{
40569 Header: res.Header,
40570 HTTPStatusCode: res.StatusCode,
40571 },
40572 }
40573 target := &ret
40574 if err := gensupport.DecodeResponse(target, res); err != nil {
40575 return nil, err
40576 }
40577 return ret, nil
40578
40579
40580
40581
40582
40583
40584
40585
40586
40587
40588
40589
40590
40591
40592
40593
40594
40595
40596
40597
40598
40599
40600
40601
40602
40603
40604
40605
40606
40607
40608
40609
40610
40611
40612
40613
40614
40615
40616
40617
40618
40619
40620
40621
40622
40623
40624
40625
40626
40627
40628
40629
40630
40631
40632
40633
40634
40635
40636
40637
40638
40639
40640
40641
40642
40643
40644
40645
40646
40647
40648
40649
40650
40651
40652
40653
40654
40655
40656
40657
40658
40659
40660
40661
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
40700
40701
40702
40703
40704
40705
40706
40707
40708
40709
40710
40711
40712
40713
40714
40715
40716
40717
40718
40719
40720
40721
40722
40723
40724
40725
40726
40727
40728
40729
40730
40731
40732
40733
40734
40735
40736
40737
40738
40739
40740
40741
40742
40743
40744
40745
40746
40747
40748
40749
40750
40751
40752
40753
40754
40755
40756
40757
40758
40759
40760
40761
40762
40763
40764
40765
40766
40767
40768
40769
40770
40771
40772
40773
40774
40775
40776
40777
40778
40779
40780
40781
40782
40783
40784
40785
40786
40787
40788
40789
40790
40791
40792
40793
40794
40795 }
40796
40797
40798
40799
40800 func (c *PlacementsListCall) Pages(ctx context.Context, f func(*PlacementsListResponse) error) error {
40801 c.ctx_ = ctx
40802 defer c.PageToken(c.urlParams_.Get("pageToken"))
40803 for {
40804 x, err := c.Do()
40805 if err != nil {
40806 return err
40807 }
40808 if err := f(x); err != nil {
40809 return err
40810 }
40811 if x.NextPageToken == "" {
40812 return nil
40813 }
40814 c.PageToken(x.NextPageToken)
40815 }
40816 }
40817
40818
40819
40820 type PlacementsPatchCall struct {
40821 s *Service
40822 profileId int64
40823 placement *Placement
40824 urlParams_ gensupport.URLParams
40825 ctx_ context.Context
40826 header_ http.Header
40827 }
40828
40829
40830
40831 func (r *PlacementsService) Patch(profileId int64, id int64, placement *Placement) *PlacementsPatchCall {
40832 c := &PlacementsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
40833 c.profileId = profileId
40834 c.urlParams_.Set("id", fmt.Sprint(id))
40835 c.placement = placement
40836 return c
40837 }
40838
40839
40840
40841
40842 func (c *PlacementsPatchCall) Fields(s ...googleapi.Field) *PlacementsPatchCall {
40843 c.urlParams_.Set("fields", googleapi.CombineFields(s))
40844 return c
40845 }
40846
40847
40848
40849
40850 func (c *PlacementsPatchCall) Context(ctx context.Context) *PlacementsPatchCall {
40851 c.ctx_ = ctx
40852 return c
40853 }
40854
40855
40856
40857 func (c *PlacementsPatchCall) Header() http.Header {
40858 if c.header_ == nil {
40859 c.header_ = make(http.Header)
40860 }
40861 return c.header_
40862 }
40863
40864 func (c *PlacementsPatchCall) doRequest(alt string) (*http.Response, error) {
40865 reqHeaders := make(http.Header)
40866 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
40867 for k, v := range c.header_ {
40868 reqHeaders[k] = v
40869 }
40870 reqHeaders.Set("User-Agent", c.s.userAgent())
40871 var body io.Reader = nil
40872 body, err := googleapi.WithoutDataWrapper.JSONReader(c.placement)
40873 if err != nil {
40874 return nil, err
40875 }
40876 reqHeaders.Set("Content-Type", "application/json")
40877 c.urlParams_.Set("alt", alt)
40878 c.urlParams_.Set("prettyPrint", "false")
40879 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/placements")
40880 urls += "?" + c.urlParams_.Encode()
40881 req, err := http.NewRequest("PATCH", urls, body)
40882 if err != nil {
40883 return nil, err
40884 }
40885 req.Header = reqHeaders
40886 googleapi.Expand(req.URL, map[string]string{
40887 "profileId": strconv.FormatInt(c.profileId, 10),
40888 })
40889 return gensupport.SendRequest(c.ctx_, c.s.client, req)
40890 }
40891
40892
40893
40894
40895
40896
40897
40898
40899 func (c *PlacementsPatchCall) Do(opts ...googleapi.CallOption) (*Placement, error) {
40900 gensupport.SetOptions(c.urlParams_, opts...)
40901 res, err := c.doRequest("json")
40902 if res != nil && res.StatusCode == http.StatusNotModified {
40903 if res.Body != nil {
40904 res.Body.Close()
40905 }
40906 return nil, &googleapi.Error{
40907 Code: res.StatusCode,
40908 Header: res.Header,
40909 }
40910 }
40911 if err != nil {
40912 return nil, err
40913 }
40914 defer googleapi.CloseBody(res)
40915 if err := googleapi.CheckResponse(res); err != nil {
40916 return nil, err
40917 }
40918 ret := &Placement{
40919 ServerResponse: googleapi.ServerResponse{
40920 Header: res.Header,
40921 HTTPStatusCode: res.StatusCode,
40922 },
40923 }
40924 target := &ret
40925 if err := gensupport.DecodeResponse(target, res); err != nil {
40926 return nil, err
40927 }
40928 return ret, nil
40929
40930
40931
40932
40933
40934
40935
40936
40937
40938
40939
40940
40941
40942
40943
40944
40945
40946
40947
40948
40949
40950
40951
40952
40953
40954
40955
40956
40957
40958
40959
40960
40961
40962
40963
40964
40965 }
40966
40967
40968
40969 type PlacementsUpdateCall struct {
40970 s *Service
40971 profileId int64
40972 placement *Placement
40973 urlParams_ gensupport.URLParams
40974 ctx_ context.Context
40975 header_ http.Header
40976 }
40977
40978
40979 func (r *PlacementsService) Update(profileId int64, placement *Placement) *PlacementsUpdateCall {
40980 c := &PlacementsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
40981 c.profileId = profileId
40982 c.placement = placement
40983 return c
40984 }
40985
40986
40987
40988
40989 func (c *PlacementsUpdateCall) Fields(s ...googleapi.Field) *PlacementsUpdateCall {
40990 c.urlParams_.Set("fields", googleapi.CombineFields(s))
40991 return c
40992 }
40993
40994
40995
40996
40997 func (c *PlacementsUpdateCall) Context(ctx context.Context) *PlacementsUpdateCall {
40998 c.ctx_ = ctx
40999 return c
41000 }
41001
41002
41003
41004 func (c *PlacementsUpdateCall) Header() http.Header {
41005 if c.header_ == nil {
41006 c.header_ = make(http.Header)
41007 }
41008 return c.header_
41009 }
41010
41011 func (c *PlacementsUpdateCall) doRequest(alt string) (*http.Response, error) {
41012 reqHeaders := make(http.Header)
41013 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
41014 for k, v := range c.header_ {
41015 reqHeaders[k] = v
41016 }
41017 reqHeaders.Set("User-Agent", c.s.userAgent())
41018 var body io.Reader = nil
41019 body, err := googleapi.WithoutDataWrapper.JSONReader(c.placement)
41020 if err != nil {
41021 return nil, err
41022 }
41023 reqHeaders.Set("Content-Type", "application/json")
41024 c.urlParams_.Set("alt", alt)
41025 c.urlParams_.Set("prettyPrint", "false")
41026 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/placements")
41027 urls += "?" + c.urlParams_.Encode()
41028 req, err := http.NewRequest("PUT", urls, body)
41029 if err != nil {
41030 return nil, err
41031 }
41032 req.Header = reqHeaders
41033 googleapi.Expand(req.URL, map[string]string{
41034 "profileId": strconv.FormatInt(c.profileId, 10),
41035 })
41036 return gensupport.SendRequest(c.ctx_, c.s.client, req)
41037 }
41038
41039
41040
41041
41042
41043
41044
41045
41046 func (c *PlacementsUpdateCall) Do(opts ...googleapi.CallOption) (*Placement, error) {
41047 gensupport.SetOptions(c.urlParams_, opts...)
41048 res, err := c.doRequest("json")
41049 if res != nil && res.StatusCode == http.StatusNotModified {
41050 if res.Body != nil {
41051 res.Body.Close()
41052 }
41053 return nil, &googleapi.Error{
41054 Code: res.StatusCode,
41055 Header: res.Header,
41056 }
41057 }
41058 if err != nil {
41059 return nil, err
41060 }
41061 defer googleapi.CloseBody(res)
41062 if err := googleapi.CheckResponse(res); err != nil {
41063 return nil, err
41064 }
41065 ret := &Placement{
41066 ServerResponse: googleapi.ServerResponse{
41067 Header: res.Header,
41068 HTTPStatusCode: res.StatusCode,
41069 },
41070 }
41071 target := &ret
41072 if err := gensupport.DecodeResponse(target, res); err != nil {
41073 return nil, err
41074 }
41075 return ret, nil
41076
41077
41078
41079
41080
41081
41082
41083
41084
41085
41086
41087
41088
41089
41090
41091
41092
41093
41094
41095
41096
41097
41098
41099
41100
41101
41102
41103
41104 }
41105
41106
41107
41108 type PlatformTypesGetCall struct {
41109 s *Service
41110 profileId int64
41111 id int64
41112 urlParams_ gensupport.URLParams
41113 ifNoneMatch_ string
41114 ctx_ context.Context
41115 header_ http.Header
41116 }
41117
41118
41119 func (r *PlatformTypesService) Get(profileId int64, id int64) *PlatformTypesGetCall {
41120 c := &PlatformTypesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
41121 c.profileId = profileId
41122 c.id = id
41123 return c
41124 }
41125
41126
41127
41128
41129 func (c *PlatformTypesGetCall) Fields(s ...googleapi.Field) *PlatformTypesGetCall {
41130 c.urlParams_.Set("fields", googleapi.CombineFields(s))
41131 return c
41132 }
41133
41134
41135
41136
41137
41138
41139 func (c *PlatformTypesGetCall) IfNoneMatch(entityTag string) *PlatformTypesGetCall {
41140 c.ifNoneMatch_ = entityTag
41141 return c
41142 }
41143
41144
41145
41146
41147 func (c *PlatformTypesGetCall) Context(ctx context.Context) *PlatformTypesGetCall {
41148 c.ctx_ = ctx
41149 return c
41150 }
41151
41152
41153
41154 func (c *PlatformTypesGetCall) Header() http.Header {
41155 if c.header_ == nil {
41156 c.header_ = make(http.Header)
41157 }
41158 return c.header_
41159 }
41160
41161 func (c *PlatformTypesGetCall) doRequest(alt string) (*http.Response, error) {
41162 reqHeaders := make(http.Header)
41163 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
41164 for k, v := range c.header_ {
41165 reqHeaders[k] = v
41166 }
41167 reqHeaders.Set("User-Agent", c.s.userAgent())
41168 if c.ifNoneMatch_ != "" {
41169 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
41170 }
41171 var body io.Reader = nil
41172 c.urlParams_.Set("alt", alt)
41173 c.urlParams_.Set("prettyPrint", "false")
41174 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/platformTypes/{id}")
41175 urls += "?" + c.urlParams_.Encode()
41176 req, err := http.NewRequest("GET", urls, body)
41177 if err != nil {
41178 return nil, err
41179 }
41180 req.Header = reqHeaders
41181 googleapi.Expand(req.URL, map[string]string{
41182 "profileId": strconv.FormatInt(c.profileId, 10),
41183 "id": strconv.FormatInt(c.id, 10),
41184 })
41185 return gensupport.SendRequest(c.ctx_, c.s.client, req)
41186 }
41187
41188
41189
41190
41191
41192
41193
41194
41195 func (c *PlatformTypesGetCall) Do(opts ...googleapi.CallOption) (*PlatformType, error) {
41196 gensupport.SetOptions(c.urlParams_, opts...)
41197 res, err := c.doRequest("json")
41198 if res != nil && res.StatusCode == http.StatusNotModified {
41199 if res.Body != nil {
41200 res.Body.Close()
41201 }
41202 return nil, &googleapi.Error{
41203 Code: res.StatusCode,
41204 Header: res.Header,
41205 }
41206 }
41207 if err != nil {
41208 return nil, err
41209 }
41210 defer googleapi.CloseBody(res)
41211 if err := googleapi.CheckResponse(res); err != nil {
41212 return nil, err
41213 }
41214 ret := &PlatformType{
41215 ServerResponse: googleapi.ServerResponse{
41216 Header: res.Header,
41217 HTTPStatusCode: res.StatusCode,
41218 },
41219 }
41220 target := &ret
41221 if err := gensupport.DecodeResponse(target, res); err != nil {
41222 return nil, err
41223 }
41224 return ret, nil
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 type PlatformTypesListCall struct {
41263 s *Service
41264 profileId int64
41265 urlParams_ gensupport.URLParams
41266 ifNoneMatch_ string
41267 ctx_ context.Context
41268 header_ http.Header
41269 }
41270
41271
41272 func (r *PlatformTypesService) List(profileId int64) *PlatformTypesListCall {
41273 c := &PlatformTypesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
41274 c.profileId = profileId
41275 return c
41276 }
41277
41278
41279
41280
41281 func (c *PlatformTypesListCall) Fields(s ...googleapi.Field) *PlatformTypesListCall {
41282 c.urlParams_.Set("fields", googleapi.CombineFields(s))
41283 return c
41284 }
41285
41286
41287
41288
41289
41290
41291 func (c *PlatformTypesListCall) IfNoneMatch(entityTag string) *PlatformTypesListCall {
41292 c.ifNoneMatch_ = entityTag
41293 return c
41294 }
41295
41296
41297
41298
41299 func (c *PlatformTypesListCall) Context(ctx context.Context) *PlatformTypesListCall {
41300 c.ctx_ = ctx
41301 return c
41302 }
41303
41304
41305
41306 func (c *PlatformTypesListCall) Header() http.Header {
41307 if c.header_ == nil {
41308 c.header_ = make(http.Header)
41309 }
41310 return c.header_
41311 }
41312
41313 func (c *PlatformTypesListCall) doRequest(alt string) (*http.Response, error) {
41314 reqHeaders := make(http.Header)
41315 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
41316 for k, v := range c.header_ {
41317 reqHeaders[k] = v
41318 }
41319 reqHeaders.Set("User-Agent", c.s.userAgent())
41320 if c.ifNoneMatch_ != "" {
41321 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
41322 }
41323 var body io.Reader = nil
41324 c.urlParams_.Set("alt", alt)
41325 c.urlParams_.Set("prettyPrint", "false")
41326 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/platformTypes")
41327 urls += "?" + c.urlParams_.Encode()
41328 req, err := http.NewRequest("GET", urls, body)
41329 if err != nil {
41330 return nil, err
41331 }
41332 req.Header = reqHeaders
41333 googleapi.Expand(req.URL, map[string]string{
41334 "profileId": strconv.FormatInt(c.profileId, 10),
41335 })
41336 return gensupport.SendRequest(c.ctx_, c.s.client, req)
41337 }
41338
41339
41340
41341
41342
41343
41344
41345
41346 func (c *PlatformTypesListCall) Do(opts ...googleapi.CallOption) (*PlatformTypesListResponse, error) {
41347 gensupport.SetOptions(c.urlParams_, opts...)
41348 res, err := c.doRequest("json")
41349 if res != nil && res.StatusCode == http.StatusNotModified {
41350 if res.Body != nil {
41351 res.Body.Close()
41352 }
41353 return nil, &googleapi.Error{
41354 Code: res.StatusCode,
41355 Header: res.Header,
41356 }
41357 }
41358 if err != nil {
41359 return nil, err
41360 }
41361 defer googleapi.CloseBody(res)
41362 if err := googleapi.CheckResponse(res); err != nil {
41363 return nil, err
41364 }
41365 ret := &PlatformTypesListResponse{
41366 ServerResponse: googleapi.ServerResponse{
41367 Header: res.Header,
41368 HTTPStatusCode: res.StatusCode,
41369 },
41370 }
41371 target := &ret
41372 if err := gensupport.DecodeResponse(target, res); err != nil {
41373 return nil, err
41374 }
41375 return ret, nil
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 type PostalCodesGetCall struct {
41406 s *Service
41407 profileId int64
41408 code string
41409 urlParams_ gensupport.URLParams
41410 ifNoneMatch_ string
41411 ctx_ context.Context
41412 header_ http.Header
41413 }
41414
41415
41416 func (r *PostalCodesService) Get(profileId int64, code string) *PostalCodesGetCall {
41417 c := &PostalCodesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
41418 c.profileId = profileId
41419 c.code = code
41420 return c
41421 }
41422
41423
41424
41425
41426 func (c *PostalCodesGetCall) Fields(s ...googleapi.Field) *PostalCodesGetCall {
41427 c.urlParams_.Set("fields", googleapi.CombineFields(s))
41428 return c
41429 }
41430
41431
41432
41433
41434
41435
41436 func (c *PostalCodesGetCall) IfNoneMatch(entityTag string) *PostalCodesGetCall {
41437 c.ifNoneMatch_ = entityTag
41438 return c
41439 }
41440
41441
41442
41443
41444 func (c *PostalCodesGetCall) Context(ctx context.Context) *PostalCodesGetCall {
41445 c.ctx_ = ctx
41446 return c
41447 }
41448
41449
41450
41451 func (c *PostalCodesGetCall) Header() http.Header {
41452 if c.header_ == nil {
41453 c.header_ = make(http.Header)
41454 }
41455 return c.header_
41456 }
41457
41458 func (c *PostalCodesGetCall) doRequest(alt string) (*http.Response, error) {
41459 reqHeaders := make(http.Header)
41460 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
41461 for k, v := range c.header_ {
41462 reqHeaders[k] = v
41463 }
41464 reqHeaders.Set("User-Agent", c.s.userAgent())
41465 if c.ifNoneMatch_ != "" {
41466 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
41467 }
41468 var body io.Reader = nil
41469 c.urlParams_.Set("alt", alt)
41470 c.urlParams_.Set("prettyPrint", "false")
41471 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/postalCodes/{code}")
41472 urls += "?" + c.urlParams_.Encode()
41473 req, err := http.NewRequest("GET", urls, body)
41474 if err != nil {
41475 return nil, err
41476 }
41477 req.Header = reqHeaders
41478 googleapi.Expand(req.URL, map[string]string{
41479 "profileId": strconv.FormatInt(c.profileId, 10),
41480 "code": c.code,
41481 })
41482 return gensupport.SendRequest(c.ctx_, c.s.client, req)
41483 }
41484
41485
41486
41487
41488
41489
41490
41491
41492 func (c *PostalCodesGetCall) Do(opts ...googleapi.CallOption) (*PostalCode, error) {
41493 gensupport.SetOptions(c.urlParams_, opts...)
41494 res, err := c.doRequest("json")
41495 if res != nil && res.StatusCode == http.StatusNotModified {
41496 if res.Body != nil {
41497 res.Body.Close()
41498 }
41499 return nil, &googleapi.Error{
41500 Code: res.StatusCode,
41501 Header: res.Header,
41502 }
41503 }
41504 if err != nil {
41505 return nil, err
41506 }
41507 defer googleapi.CloseBody(res)
41508 if err := googleapi.CheckResponse(res); err != nil {
41509 return nil, err
41510 }
41511 ret := &PostalCode{
41512 ServerResponse: googleapi.ServerResponse{
41513 Header: res.Header,
41514 HTTPStatusCode: res.StatusCode,
41515 },
41516 }
41517 target := &ret
41518 if err := gensupport.DecodeResponse(target, res); err != nil {
41519 return nil, err
41520 }
41521 return ret, nil
41522
41523
41524
41525
41526
41527
41528
41529
41530
41531
41532
41533
41534
41535
41536
41537
41538
41539
41540
41541
41542
41543
41544
41545
41546
41547
41548
41549
41550
41551
41552
41553
41554 }
41555
41556
41557
41558 type PostalCodesListCall struct {
41559 s *Service
41560 profileId int64
41561 urlParams_ gensupport.URLParams
41562 ifNoneMatch_ string
41563 ctx_ context.Context
41564 header_ http.Header
41565 }
41566
41567
41568 func (r *PostalCodesService) List(profileId int64) *PostalCodesListCall {
41569 c := &PostalCodesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
41570 c.profileId = profileId
41571 return c
41572 }
41573
41574
41575
41576
41577 func (c *PostalCodesListCall) Fields(s ...googleapi.Field) *PostalCodesListCall {
41578 c.urlParams_.Set("fields", googleapi.CombineFields(s))
41579 return c
41580 }
41581
41582
41583
41584
41585
41586
41587 func (c *PostalCodesListCall) IfNoneMatch(entityTag string) *PostalCodesListCall {
41588 c.ifNoneMatch_ = entityTag
41589 return c
41590 }
41591
41592
41593
41594
41595 func (c *PostalCodesListCall) Context(ctx context.Context) *PostalCodesListCall {
41596 c.ctx_ = ctx
41597 return c
41598 }
41599
41600
41601
41602 func (c *PostalCodesListCall) Header() http.Header {
41603 if c.header_ == nil {
41604 c.header_ = make(http.Header)
41605 }
41606 return c.header_
41607 }
41608
41609 func (c *PostalCodesListCall) doRequest(alt string) (*http.Response, error) {
41610 reqHeaders := make(http.Header)
41611 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
41612 for k, v := range c.header_ {
41613 reqHeaders[k] = v
41614 }
41615 reqHeaders.Set("User-Agent", c.s.userAgent())
41616 if c.ifNoneMatch_ != "" {
41617 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
41618 }
41619 var body io.Reader = nil
41620 c.urlParams_.Set("alt", alt)
41621 c.urlParams_.Set("prettyPrint", "false")
41622 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/postalCodes")
41623 urls += "?" + c.urlParams_.Encode()
41624 req, err := http.NewRequest("GET", urls, body)
41625 if err != nil {
41626 return nil, err
41627 }
41628 req.Header = reqHeaders
41629 googleapi.Expand(req.URL, map[string]string{
41630 "profileId": strconv.FormatInt(c.profileId, 10),
41631 })
41632 return gensupport.SendRequest(c.ctx_, c.s.client, req)
41633 }
41634
41635
41636
41637
41638
41639
41640
41641
41642 func (c *PostalCodesListCall) Do(opts ...googleapi.CallOption) (*PostalCodesListResponse, error) {
41643 gensupport.SetOptions(c.urlParams_, opts...)
41644 res, err := c.doRequest("json")
41645 if res != nil && res.StatusCode == http.StatusNotModified {
41646 if res.Body != nil {
41647 res.Body.Close()
41648 }
41649 return nil, &googleapi.Error{
41650 Code: res.StatusCode,
41651 Header: res.Header,
41652 }
41653 }
41654 if err != nil {
41655 return nil, err
41656 }
41657 defer googleapi.CloseBody(res)
41658 if err := googleapi.CheckResponse(res); err != nil {
41659 return nil, err
41660 }
41661 ret := &PostalCodesListResponse{
41662 ServerResponse: googleapi.ServerResponse{
41663 Header: res.Header,
41664 HTTPStatusCode: res.StatusCode,
41665 },
41666 }
41667 target := &ret
41668 if err := gensupport.DecodeResponse(target, res); err != nil {
41669 return nil, err
41670 }
41671 return ret, nil
41672
41673
41674
41675
41676
41677
41678
41679
41680
41681
41682
41683
41684
41685
41686
41687
41688
41689
41690
41691
41692
41693
41694
41695
41696
41697 }
41698
41699
41700
41701 type ProjectsGetCall struct {
41702 s *Service
41703 profileId int64
41704 id int64
41705 urlParams_ gensupport.URLParams
41706 ifNoneMatch_ string
41707 ctx_ context.Context
41708 header_ http.Header
41709 }
41710
41711
41712 func (r *ProjectsService) Get(profileId int64, id int64) *ProjectsGetCall {
41713 c := &ProjectsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
41714 c.profileId = profileId
41715 c.id = id
41716 return c
41717 }
41718
41719
41720
41721
41722 func (c *ProjectsGetCall) Fields(s ...googleapi.Field) *ProjectsGetCall {
41723 c.urlParams_.Set("fields", googleapi.CombineFields(s))
41724 return c
41725 }
41726
41727
41728
41729
41730
41731
41732 func (c *ProjectsGetCall) IfNoneMatch(entityTag string) *ProjectsGetCall {
41733 c.ifNoneMatch_ = entityTag
41734 return c
41735 }
41736
41737
41738
41739
41740 func (c *ProjectsGetCall) Context(ctx context.Context) *ProjectsGetCall {
41741 c.ctx_ = ctx
41742 return c
41743 }
41744
41745
41746
41747 func (c *ProjectsGetCall) Header() http.Header {
41748 if c.header_ == nil {
41749 c.header_ = make(http.Header)
41750 }
41751 return c.header_
41752 }
41753
41754 func (c *ProjectsGetCall) doRequest(alt string) (*http.Response, error) {
41755 reqHeaders := make(http.Header)
41756 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
41757 for k, v := range c.header_ {
41758 reqHeaders[k] = v
41759 }
41760 reqHeaders.Set("User-Agent", c.s.userAgent())
41761 if c.ifNoneMatch_ != "" {
41762 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
41763 }
41764 var body io.Reader = nil
41765 c.urlParams_.Set("alt", alt)
41766 c.urlParams_.Set("prettyPrint", "false")
41767 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/projects/{id}")
41768 urls += "?" + c.urlParams_.Encode()
41769 req, err := http.NewRequest("GET", urls, body)
41770 if err != nil {
41771 return nil, err
41772 }
41773 req.Header = reqHeaders
41774 googleapi.Expand(req.URL, map[string]string{
41775 "profileId": strconv.FormatInt(c.profileId, 10),
41776 "id": strconv.FormatInt(c.id, 10),
41777 })
41778 return gensupport.SendRequest(c.ctx_, c.s.client, req)
41779 }
41780
41781
41782
41783
41784
41785
41786
41787
41788 func (c *ProjectsGetCall) Do(opts ...googleapi.CallOption) (*Project, error) {
41789 gensupport.SetOptions(c.urlParams_, opts...)
41790 res, err := c.doRequest("json")
41791 if res != nil && res.StatusCode == http.StatusNotModified {
41792 if res.Body != nil {
41793 res.Body.Close()
41794 }
41795 return nil, &googleapi.Error{
41796 Code: res.StatusCode,
41797 Header: res.Header,
41798 }
41799 }
41800 if err != nil {
41801 return nil, err
41802 }
41803 defer googleapi.CloseBody(res)
41804 if err := googleapi.CheckResponse(res); err != nil {
41805 return nil, err
41806 }
41807 ret := &Project{
41808 ServerResponse: googleapi.ServerResponse{
41809 Header: res.Header,
41810 HTTPStatusCode: res.StatusCode,
41811 },
41812 }
41813 target := &ret
41814 if err := gensupport.DecodeResponse(target, res); err != nil {
41815 return nil, err
41816 }
41817 return ret, nil
41818
41819
41820
41821
41822
41823
41824
41825
41826
41827
41828
41829
41830
41831
41832
41833
41834
41835
41836
41837
41838
41839
41840
41841
41842
41843
41844
41845
41846
41847
41848
41849
41850
41851 }
41852
41853
41854
41855 type ProjectsListCall struct {
41856 s *Service
41857 profileId int64
41858 urlParams_ gensupport.URLParams
41859 ifNoneMatch_ string
41860 ctx_ context.Context
41861 header_ http.Header
41862 }
41863
41864
41865
41866 func (r *ProjectsService) List(profileId int64) *ProjectsListCall {
41867 c := &ProjectsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
41868 c.profileId = profileId
41869 return c
41870 }
41871
41872
41873
41874 func (c *ProjectsListCall) AdvertiserIds(advertiserIds ...int64) *ProjectsListCall {
41875 var advertiserIds_ []string
41876 for _, v := range advertiserIds {
41877 advertiserIds_ = append(advertiserIds_, fmt.Sprint(v))
41878 }
41879 c.urlParams_.SetMulti("advertiserIds", advertiserIds_)
41880 return c
41881 }
41882
41883
41884
41885 func (c *ProjectsListCall) Ids(ids ...int64) *ProjectsListCall {
41886 var ids_ []string
41887 for _, v := range ids {
41888 ids_ = append(ids_, fmt.Sprint(v))
41889 }
41890 c.urlParams_.SetMulti("ids", ids_)
41891 return c
41892 }
41893
41894
41895
41896 func (c *ProjectsListCall) MaxResults(maxResults int64) *ProjectsListCall {
41897 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
41898 return c
41899 }
41900
41901
41902
41903 func (c *ProjectsListCall) PageToken(pageToken string) *ProjectsListCall {
41904 c.urlParams_.Set("pageToken", pageToken)
41905 return c
41906 }
41907
41908
41909
41910
41911
41912
41913
41914
41915
41916 func (c *ProjectsListCall) SearchString(searchString string) *ProjectsListCall {
41917 c.urlParams_.Set("searchString", searchString)
41918 return c
41919 }
41920
41921
41922
41923
41924
41925
41926
41927
41928 func (c *ProjectsListCall) SortField(sortField string) *ProjectsListCall {
41929 c.urlParams_.Set("sortField", sortField)
41930 return c
41931 }
41932
41933
41934
41935
41936
41937
41938
41939
41940 func (c *ProjectsListCall) SortOrder(sortOrder string) *ProjectsListCall {
41941 c.urlParams_.Set("sortOrder", sortOrder)
41942 return c
41943 }
41944
41945
41946
41947
41948 func (c *ProjectsListCall) Fields(s ...googleapi.Field) *ProjectsListCall {
41949 c.urlParams_.Set("fields", googleapi.CombineFields(s))
41950 return c
41951 }
41952
41953
41954
41955
41956
41957
41958 func (c *ProjectsListCall) IfNoneMatch(entityTag string) *ProjectsListCall {
41959 c.ifNoneMatch_ = entityTag
41960 return c
41961 }
41962
41963
41964
41965
41966 func (c *ProjectsListCall) Context(ctx context.Context) *ProjectsListCall {
41967 c.ctx_ = ctx
41968 return c
41969 }
41970
41971
41972
41973 func (c *ProjectsListCall) Header() http.Header {
41974 if c.header_ == nil {
41975 c.header_ = make(http.Header)
41976 }
41977 return c.header_
41978 }
41979
41980 func (c *ProjectsListCall) doRequest(alt string) (*http.Response, error) {
41981 reqHeaders := make(http.Header)
41982 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
41983 for k, v := range c.header_ {
41984 reqHeaders[k] = v
41985 }
41986 reqHeaders.Set("User-Agent", c.s.userAgent())
41987 if c.ifNoneMatch_ != "" {
41988 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
41989 }
41990 var body io.Reader = nil
41991 c.urlParams_.Set("alt", alt)
41992 c.urlParams_.Set("prettyPrint", "false")
41993 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/projects")
41994 urls += "?" + c.urlParams_.Encode()
41995 req, err := http.NewRequest("GET", urls, body)
41996 if err != nil {
41997 return nil, err
41998 }
41999 req.Header = reqHeaders
42000 googleapi.Expand(req.URL, map[string]string{
42001 "profileId": strconv.FormatInt(c.profileId, 10),
42002 })
42003 return gensupport.SendRequest(c.ctx_, c.s.client, req)
42004 }
42005
42006
42007
42008
42009
42010
42011
42012
42013 func (c *ProjectsListCall) Do(opts ...googleapi.CallOption) (*ProjectsListResponse, error) {
42014 gensupport.SetOptions(c.urlParams_, opts...)
42015 res, err := c.doRequest("json")
42016 if res != nil && res.StatusCode == http.StatusNotModified {
42017 if res.Body != nil {
42018 res.Body.Close()
42019 }
42020 return nil, &googleapi.Error{
42021 Code: res.StatusCode,
42022 Header: res.Header,
42023 }
42024 }
42025 if err != nil {
42026 return nil, err
42027 }
42028 defer googleapi.CloseBody(res)
42029 if err := googleapi.CheckResponse(res); err != nil {
42030 return nil, err
42031 }
42032 ret := &ProjectsListResponse{
42033 ServerResponse: googleapi.ServerResponse{
42034 Header: res.Header,
42035 HTTPStatusCode: res.StatusCode,
42036 },
42037 }
42038 target := &ret
42039 if err := gensupport.DecodeResponse(target, res); err != nil {
42040 return nil, err
42041 }
42042 return ret, nil
42043
42044
42045
42046
42047
42048
42049
42050
42051
42052
42053
42054
42055
42056
42057
42058
42059
42060
42061
42062
42063
42064
42065
42066
42067
42068
42069
42070
42071
42072
42073
42074
42075
42076
42077
42078
42079
42080
42081
42082
42083
42084
42085
42086
42087
42088
42089
42090
42091
42092
42093
42094
42095
42096
42097
42098
42099
42100
42101
42102
42103
42104
42105
42106
42107
42108
42109
42110
42111
42112
42113
42114
42115
42116
42117
42118
42119
42120
42121
42122
42123
42124
42125
42126
42127
42128
42129 }
42130
42131
42132
42133
42134 func (c *ProjectsListCall) Pages(ctx context.Context, f func(*ProjectsListResponse) error) error {
42135 c.ctx_ = ctx
42136 defer c.PageToken(c.urlParams_.Get("pageToken"))
42137 for {
42138 x, err := c.Do()
42139 if err != nil {
42140 return err
42141 }
42142 if err := f(x); err != nil {
42143 return err
42144 }
42145 if x.NextPageToken == "" {
42146 return nil
42147 }
42148 c.PageToken(x.NextPageToken)
42149 }
42150 }
42151
42152
42153
42154 type RegionsListCall struct {
42155 s *Service
42156 profileId int64
42157 urlParams_ gensupport.URLParams
42158 ifNoneMatch_ string
42159 ctx_ context.Context
42160 header_ http.Header
42161 }
42162
42163
42164 func (r *RegionsService) List(profileId int64) *RegionsListCall {
42165 c := &RegionsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
42166 c.profileId = profileId
42167 return c
42168 }
42169
42170
42171
42172
42173 func (c *RegionsListCall) Fields(s ...googleapi.Field) *RegionsListCall {
42174 c.urlParams_.Set("fields", googleapi.CombineFields(s))
42175 return c
42176 }
42177
42178
42179
42180
42181
42182
42183 func (c *RegionsListCall) IfNoneMatch(entityTag string) *RegionsListCall {
42184 c.ifNoneMatch_ = entityTag
42185 return c
42186 }
42187
42188
42189
42190
42191 func (c *RegionsListCall) Context(ctx context.Context) *RegionsListCall {
42192 c.ctx_ = ctx
42193 return c
42194 }
42195
42196
42197
42198 func (c *RegionsListCall) Header() http.Header {
42199 if c.header_ == nil {
42200 c.header_ = make(http.Header)
42201 }
42202 return c.header_
42203 }
42204
42205 func (c *RegionsListCall) doRequest(alt string) (*http.Response, error) {
42206 reqHeaders := make(http.Header)
42207 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
42208 for k, v := range c.header_ {
42209 reqHeaders[k] = v
42210 }
42211 reqHeaders.Set("User-Agent", c.s.userAgent())
42212 if c.ifNoneMatch_ != "" {
42213 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
42214 }
42215 var body io.Reader = nil
42216 c.urlParams_.Set("alt", alt)
42217 c.urlParams_.Set("prettyPrint", "false")
42218 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/regions")
42219 urls += "?" + c.urlParams_.Encode()
42220 req, err := http.NewRequest("GET", urls, body)
42221 if err != nil {
42222 return nil, err
42223 }
42224 req.Header = reqHeaders
42225 googleapi.Expand(req.URL, map[string]string{
42226 "profileId": strconv.FormatInt(c.profileId, 10),
42227 })
42228 return gensupport.SendRequest(c.ctx_, c.s.client, req)
42229 }
42230
42231
42232
42233
42234
42235
42236
42237
42238 func (c *RegionsListCall) Do(opts ...googleapi.CallOption) (*RegionsListResponse, error) {
42239 gensupport.SetOptions(c.urlParams_, opts...)
42240 res, err := c.doRequest("json")
42241 if res != nil && res.StatusCode == http.StatusNotModified {
42242 if res.Body != nil {
42243 res.Body.Close()
42244 }
42245 return nil, &googleapi.Error{
42246 Code: res.StatusCode,
42247 Header: res.Header,
42248 }
42249 }
42250 if err != nil {
42251 return nil, err
42252 }
42253 defer googleapi.CloseBody(res)
42254 if err := googleapi.CheckResponse(res); err != nil {
42255 return nil, err
42256 }
42257 ret := &RegionsListResponse{
42258 ServerResponse: googleapi.ServerResponse{
42259 Header: res.Header,
42260 HTTPStatusCode: res.StatusCode,
42261 },
42262 }
42263 target := &ret
42264 if err := gensupport.DecodeResponse(target, res); err != nil {
42265 return nil, err
42266 }
42267 return ret, nil
42268
42269
42270
42271
42272
42273
42274
42275
42276
42277
42278
42279
42280
42281
42282
42283
42284
42285
42286
42287
42288
42289
42290
42291
42292
42293 }
42294
42295
42296
42297 type RemarketingListSharesGetCall struct {
42298 s *Service
42299 profileId int64
42300 remarketingListId int64
42301 urlParams_ gensupport.URLParams
42302 ifNoneMatch_ string
42303 ctx_ context.Context
42304 header_ http.Header
42305 }
42306
42307
42308 func (r *RemarketingListSharesService) Get(profileId int64, remarketingListId int64) *RemarketingListSharesGetCall {
42309 c := &RemarketingListSharesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
42310 c.profileId = profileId
42311 c.remarketingListId = remarketingListId
42312 return c
42313 }
42314
42315
42316
42317
42318 func (c *RemarketingListSharesGetCall) Fields(s ...googleapi.Field) *RemarketingListSharesGetCall {
42319 c.urlParams_.Set("fields", googleapi.CombineFields(s))
42320 return c
42321 }
42322
42323
42324
42325
42326
42327
42328 func (c *RemarketingListSharesGetCall) IfNoneMatch(entityTag string) *RemarketingListSharesGetCall {
42329 c.ifNoneMatch_ = entityTag
42330 return c
42331 }
42332
42333
42334
42335
42336 func (c *RemarketingListSharesGetCall) Context(ctx context.Context) *RemarketingListSharesGetCall {
42337 c.ctx_ = ctx
42338 return c
42339 }
42340
42341
42342
42343 func (c *RemarketingListSharesGetCall) Header() http.Header {
42344 if c.header_ == nil {
42345 c.header_ = make(http.Header)
42346 }
42347 return c.header_
42348 }
42349
42350 func (c *RemarketingListSharesGetCall) doRequest(alt string) (*http.Response, error) {
42351 reqHeaders := make(http.Header)
42352 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
42353 for k, v := range c.header_ {
42354 reqHeaders[k] = v
42355 }
42356 reqHeaders.Set("User-Agent", c.s.userAgent())
42357 if c.ifNoneMatch_ != "" {
42358 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
42359 }
42360 var body io.Reader = nil
42361 c.urlParams_.Set("alt", alt)
42362 c.urlParams_.Set("prettyPrint", "false")
42363 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/remarketingListShares/{remarketingListId}")
42364 urls += "?" + c.urlParams_.Encode()
42365 req, err := http.NewRequest("GET", urls, body)
42366 if err != nil {
42367 return nil, err
42368 }
42369 req.Header = reqHeaders
42370 googleapi.Expand(req.URL, map[string]string{
42371 "profileId": strconv.FormatInt(c.profileId, 10),
42372 "remarketingListId": strconv.FormatInt(c.remarketingListId, 10),
42373 })
42374 return gensupport.SendRequest(c.ctx_, c.s.client, req)
42375 }
42376
42377
42378
42379
42380
42381
42382
42383
42384 func (c *RemarketingListSharesGetCall) Do(opts ...googleapi.CallOption) (*RemarketingListShare, error) {
42385 gensupport.SetOptions(c.urlParams_, opts...)
42386 res, err := c.doRequest("json")
42387 if res != nil && res.StatusCode == http.StatusNotModified {
42388 if res.Body != nil {
42389 res.Body.Close()
42390 }
42391 return nil, &googleapi.Error{
42392 Code: res.StatusCode,
42393 Header: res.Header,
42394 }
42395 }
42396 if err != nil {
42397 return nil, err
42398 }
42399 defer googleapi.CloseBody(res)
42400 if err := googleapi.CheckResponse(res); err != nil {
42401 return nil, err
42402 }
42403 ret := &RemarketingListShare{
42404 ServerResponse: googleapi.ServerResponse{
42405 Header: res.Header,
42406 HTTPStatusCode: res.StatusCode,
42407 },
42408 }
42409 target := &ret
42410 if err := gensupport.DecodeResponse(target, res); err != nil {
42411 return nil, err
42412 }
42413 return ret, nil
42414
42415
42416
42417
42418
42419
42420
42421
42422
42423
42424
42425
42426
42427
42428
42429
42430
42431
42432
42433
42434
42435
42436
42437
42438
42439
42440
42441
42442
42443
42444
42445
42446
42447 }
42448
42449
42450
42451 type RemarketingListSharesPatchCall struct {
42452 s *Service
42453 profileId int64
42454 remarketinglistshare *RemarketingListShare
42455 urlParams_ gensupport.URLParams
42456 ctx_ context.Context
42457 header_ http.Header
42458 }
42459
42460
42461
42462 func (r *RemarketingListSharesService) Patch(profileId int64, remarketingListId int64, remarketinglistshare *RemarketingListShare) *RemarketingListSharesPatchCall {
42463 c := &RemarketingListSharesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
42464 c.profileId = profileId
42465 c.urlParams_.Set("remarketingListId", fmt.Sprint(remarketingListId))
42466 c.remarketinglistshare = remarketinglistshare
42467 return c
42468 }
42469
42470
42471
42472
42473 func (c *RemarketingListSharesPatchCall) Fields(s ...googleapi.Field) *RemarketingListSharesPatchCall {
42474 c.urlParams_.Set("fields", googleapi.CombineFields(s))
42475 return c
42476 }
42477
42478
42479
42480
42481 func (c *RemarketingListSharesPatchCall) Context(ctx context.Context) *RemarketingListSharesPatchCall {
42482 c.ctx_ = ctx
42483 return c
42484 }
42485
42486
42487
42488 func (c *RemarketingListSharesPatchCall) Header() http.Header {
42489 if c.header_ == nil {
42490 c.header_ = make(http.Header)
42491 }
42492 return c.header_
42493 }
42494
42495 func (c *RemarketingListSharesPatchCall) doRequest(alt string) (*http.Response, error) {
42496 reqHeaders := make(http.Header)
42497 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
42498 for k, v := range c.header_ {
42499 reqHeaders[k] = v
42500 }
42501 reqHeaders.Set("User-Agent", c.s.userAgent())
42502 var body io.Reader = nil
42503 body, err := googleapi.WithoutDataWrapper.JSONReader(c.remarketinglistshare)
42504 if err != nil {
42505 return nil, err
42506 }
42507 reqHeaders.Set("Content-Type", "application/json")
42508 c.urlParams_.Set("alt", alt)
42509 c.urlParams_.Set("prettyPrint", "false")
42510 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/remarketingListShares")
42511 urls += "?" + c.urlParams_.Encode()
42512 req, err := http.NewRequest("PATCH", urls, body)
42513 if err != nil {
42514 return nil, err
42515 }
42516 req.Header = reqHeaders
42517 googleapi.Expand(req.URL, map[string]string{
42518 "profileId": strconv.FormatInt(c.profileId, 10),
42519 })
42520 return gensupport.SendRequest(c.ctx_, c.s.client, req)
42521 }
42522
42523
42524
42525
42526
42527
42528
42529
42530 func (c *RemarketingListSharesPatchCall) Do(opts ...googleapi.CallOption) (*RemarketingListShare, error) {
42531 gensupport.SetOptions(c.urlParams_, opts...)
42532 res, err := c.doRequest("json")
42533 if res != nil && res.StatusCode == http.StatusNotModified {
42534 if res.Body != nil {
42535 res.Body.Close()
42536 }
42537 return nil, &googleapi.Error{
42538 Code: res.StatusCode,
42539 Header: res.Header,
42540 }
42541 }
42542 if err != nil {
42543 return nil, err
42544 }
42545 defer googleapi.CloseBody(res)
42546 if err := googleapi.CheckResponse(res); err != nil {
42547 return nil, err
42548 }
42549 ret := &RemarketingListShare{
42550 ServerResponse: googleapi.ServerResponse{
42551 Header: res.Header,
42552 HTTPStatusCode: res.StatusCode,
42553 },
42554 }
42555 target := &ret
42556 if err := gensupport.DecodeResponse(target, res); err != nil {
42557 return nil, err
42558 }
42559 return ret, nil
42560
42561
42562
42563
42564
42565
42566
42567
42568
42569
42570
42571
42572
42573
42574
42575
42576
42577
42578
42579
42580
42581
42582
42583
42584
42585
42586
42587
42588
42589
42590
42591
42592
42593
42594
42595
42596 }
42597
42598
42599
42600 type RemarketingListSharesUpdateCall struct {
42601 s *Service
42602 profileId int64
42603 remarketinglistshare *RemarketingListShare
42604 urlParams_ gensupport.URLParams
42605 ctx_ context.Context
42606 header_ http.Header
42607 }
42608
42609
42610 func (r *RemarketingListSharesService) Update(profileId int64, remarketinglistshare *RemarketingListShare) *RemarketingListSharesUpdateCall {
42611 c := &RemarketingListSharesUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
42612 c.profileId = profileId
42613 c.remarketinglistshare = remarketinglistshare
42614 return c
42615 }
42616
42617
42618
42619
42620 func (c *RemarketingListSharesUpdateCall) Fields(s ...googleapi.Field) *RemarketingListSharesUpdateCall {
42621 c.urlParams_.Set("fields", googleapi.CombineFields(s))
42622 return c
42623 }
42624
42625
42626
42627
42628 func (c *RemarketingListSharesUpdateCall) Context(ctx context.Context) *RemarketingListSharesUpdateCall {
42629 c.ctx_ = ctx
42630 return c
42631 }
42632
42633
42634
42635 func (c *RemarketingListSharesUpdateCall) Header() http.Header {
42636 if c.header_ == nil {
42637 c.header_ = make(http.Header)
42638 }
42639 return c.header_
42640 }
42641
42642 func (c *RemarketingListSharesUpdateCall) doRequest(alt string) (*http.Response, error) {
42643 reqHeaders := make(http.Header)
42644 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
42645 for k, v := range c.header_ {
42646 reqHeaders[k] = v
42647 }
42648 reqHeaders.Set("User-Agent", c.s.userAgent())
42649 var body io.Reader = nil
42650 body, err := googleapi.WithoutDataWrapper.JSONReader(c.remarketinglistshare)
42651 if err != nil {
42652 return nil, err
42653 }
42654 reqHeaders.Set("Content-Type", "application/json")
42655 c.urlParams_.Set("alt", alt)
42656 c.urlParams_.Set("prettyPrint", "false")
42657 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/remarketingListShares")
42658 urls += "?" + c.urlParams_.Encode()
42659 req, err := http.NewRequest("PUT", urls, body)
42660 if err != nil {
42661 return nil, err
42662 }
42663 req.Header = reqHeaders
42664 googleapi.Expand(req.URL, map[string]string{
42665 "profileId": strconv.FormatInt(c.profileId, 10),
42666 })
42667 return gensupport.SendRequest(c.ctx_, c.s.client, req)
42668 }
42669
42670
42671
42672
42673
42674
42675
42676
42677 func (c *RemarketingListSharesUpdateCall) Do(opts ...googleapi.CallOption) (*RemarketingListShare, error) {
42678 gensupport.SetOptions(c.urlParams_, opts...)
42679 res, err := c.doRequest("json")
42680 if res != nil && res.StatusCode == http.StatusNotModified {
42681 if res.Body != nil {
42682 res.Body.Close()
42683 }
42684 return nil, &googleapi.Error{
42685 Code: res.StatusCode,
42686 Header: res.Header,
42687 }
42688 }
42689 if err != nil {
42690 return nil, err
42691 }
42692 defer googleapi.CloseBody(res)
42693 if err := googleapi.CheckResponse(res); err != nil {
42694 return nil, err
42695 }
42696 ret := &RemarketingListShare{
42697 ServerResponse: googleapi.ServerResponse{
42698 Header: res.Header,
42699 HTTPStatusCode: res.StatusCode,
42700 },
42701 }
42702 target := &ret
42703 if err := gensupport.DecodeResponse(target, res); err != nil {
42704 return nil, err
42705 }
42706 return ret, nil
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 type RemarketingListsGetCall struct {
42740 s *Service
42741 profileId int64
42742 id int64
42743 urlParams_ gensupport.URLParams
42744 ifNoneMatch_ string
42745 ctx_ context.Context
42746 header_ http.Header
42747 }
42748
42749
42750 func (r *RemarketingListsService) Get(profileId int64, id int64) *RemarketingListsGetCall {
42751 c := &RemarketingListsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
42752 c.profileId = profileId
42753 c.id = id
42754 return c
42755 }
42756
42757
42758
42759
42760 func (c *RemarketingListsGetCall) Fields(s ...googleapi.Field) *RemarketingListsGetCall {
42761 c.urlParams_.Set("fields", googleapi.CombineFields(s))
42762 return c
42763 }
42764
42765
42766
42767
42768
42769
42770 func (c *RemarketingListsGetCall) IfNoneMatch(entityTag string) *RemarketingListsGetCall {
42771 c.ifNoneMatch_ = entityTag
42772 return c
42773 }
42774
42775
42776
42777
42778 func (c *RemarketingListsGetCall) Context(ctx context.Context) *RemarketingListsGetCall {
42779 c.ctx_ = ctx
42780 return c
42781 }
42782
42783
42784
42785 func (c *RemarketingListsGetCall) Header() http.Header {
42786 if c.header_ == nil {
42787 c.header_ = make(http.Header)
42788 }
42789 return c.header_
42790 }
42791
42792 func (c *RemarketingListsGetCall) doRequest(alt string) (*http.Response, error) {
42793 reqHeaders := make(http.Header)
42794 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
42795 for k, v := range c.header_ {
42796 reqHeaders[k] = v
42797 }
42798 reqHeaders.Set("User-Agent", c.s.userAgent())
42799 if c.ifNoneMatch_ != "" {
42800 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
42801 }
42802 var body io.Reader = nil
42803 c.urlParams_.Set("alt", alt)
42804 c.urlParams_.Set("prettyPrint", "false")
42805 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/remarketingLists/{id}")
42806 urls += "?" + c.urlParams_.Encode()
42807 req, err := http.NewRequest("GET", urls, body)
42808 if err != nil {
42809 return nil, err
42810 }
42811 req.Header = reqHeaders
42812 googleapi.Expand(req.URL, map[string]string{
42813 "profileId": strconv.FormatInt(c.profileId, 10),
42814 "id": strconv.FormatInt(c.id, 10),
42815 })
42816 return gensupport.SendRequest(c.ctx_, c.s.client, req)
42817 }
42818
42819
42820
42821
42822
42823
42824
42825
42826 func (c *RemarketingListsGetCall) Do(opts ...googleapi.CallOption) (*RemarketingList, error) {
42827 gensupport.SetOptions(c.urlParams_, opts...)
42828 res, err := c.doRequest("json")
42829 if res != nil && res.StatusCode == http.StatusNotModified {
42830 if res.Body != nil {
42831 res.Body.Close()
42832 }
42833 return nil, &googleapi.Error{
42834 Code: res.StatusCode,
42835 Header: res.Header,
42836 }
42837 }
42838 if err != nil {
42839 return nil, err
42840 }
42841 defer googleapi.CloseBody(res)
42842 if err := googleapi.CheckResponse(res); err != nil {
42843 return nil, err
42844 }
42845 ret := &RemarketingList{
42846 ServerResponse: googleapi.ServerResponse{
42847 Header: res.Header,
42848 HTTPStatusCode: res.StatusCode,
42849 },
42850 }
42851 target := &ret
42852 if err := gensupport.DecodeResponse(target, res); err != nil {
42853 return nil, err
42854 }
42855 return ret, nil
42856
42857
42858
42859
42860
42861
42862
42863
42864
42865
42866
42867
42868
42869
42870
42871
42872
42873
42874
42875
42876
42877
42878
42879
42880
42881
42882
42883
42884
42885
42886
42887
42888
42889 }
42890
42891
42892
42893 type RemarketingListsInsertCall struct {
42894 s *Service
42895 profileId int64
42896 remarketinglist *RemarketingList
42897 urlParams_ gensupport.URLParams
42898 ctx_ context.Context
42899 header_ http.Header
42900 }
42901
42902
42903 func (r *RemarketingListsService) Insert(profileId int64, remarketinglist *RemarketingList) *RemarketingListsInsertCall {
42904 c := &RemarketingListsInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
42905 c.profileId = profileId
42906 c.remarketinglist = remarketinglist
42907 return c
42908 }
42909
42910
42911
42912
42913 func (c *RemarketingListsInsertCall) Fields(s ...googleapi.Field) *RemarketingListsInsertCall {
42914 c.urlParams_.Set("fields", googleapi.CombineFields(s))
42915 return c
42916 }
42917
42918
42919
42920
42921 func (c *RemarketingListsInsertCall) Context(ctx context.Context) *RemarketingListsInsertCall {
42922 c.ctx_ = ctx
42923 return c
42924 }
42925
42926
42927
42928 func (c *RemarketingListsInsertCall) Header() http.Header {
42929 if c.header_ == nil {
42930 c.header_ = make(http.Header)
42931 }
42932 return c.header_
42933 }
42934
42935 func (c *RemarketingListsInsertCall) doRequest(alt string) (*http.Response, error) {
42936 reqHeaders := make(http.Header)
42937 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
42938 for k, v := range c.header_ {
42939 reqHeaders[k] = v
42940 }
42941 reqHeaders.Set("User-Agent", c.s.userAgent())
42942 var body io.Reader = nil
42943 body, err := googleapi.WithoutDataWrapper.JSONReader(c.remarketinglist)
42944 if err != nil {
42945 return nil, err
42946 }
42947 reqHeaders.Set("Content-Type", "application/json")
42948 c.urlParams_.Set("alt", alt)
42949 c.urlParams_.Set("prettyPrint", "false")
42950 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/remarketingLists")
42951 urls += "?" + c.urlParams_.Encode()
42952 req, err := http.NewRequest("POST", urls, body)
42953 if err != nil {
42954 return nil, err
42955 }
42956 req.Header = reqHeaders
42957 googleapi.Expand(req.URL, map[string]string{
42958 "profileId": strconv.FormatInt(c.profileId, 10),
42959 })
42960 return gensupport.SendRequest(c.ctx_, c.s.client, req)
42961 }
42962
42963
42964
42965
42966
42967
42968
42969
42970 func (c *RemarketingListsInsertCall) Do(opts ...googleapi.CallOption) (*RemarketingList, error) {
42971 gensupport.SetOptions(c.urlParams_, opts...)
42972 res, err := c.doRequest("json")
42973 if res != nil && res.StatusCode == http.StatusNotModified {
42974 if res.Body != nil {
42975 res.Body.Close()
42976 }
42977 return nil, &googleapi.Error{
42978 Code: res.StatusCode,
42979 Header: res.Header,
42980 }
42981 }
42982 if err != nil {
42983 return nil, err
42984 }
42985 defer googleapi.CloseBody(res)
42986 if err := googleapi.CheckResponse(res); err != nil {
42987 return nil, err
42988 }
42989 ret := &RemarketingList{
42990 ServerResponse: googleapi.ServerResponse{
42991 Header: res.Header,
42992 HTTPStatusCode: res.StatusCode,
42993 },
42994 }
42995 target := &ret
42996 if err := gensupport.DecodeResponse(target, res); err != nil {
42997 return nil, err
42998 }
42999 return ret, nil
43000
43001
43002
43003
43004
43005
43006
43007
43008
43009
43010
43011
43012
43013
43014
43015
43016
43017
43018
43019
43020
43021
43022
43023
43024
43025
43026
43027
43028 }
43029
43030
43031
43032 type RemarketingListsListCall struct {
43033 s *Service
43034 profileId int64
43035 urlParams_ gensupport.URLParams
43036 ifNoneMatch_ string
43037 ctx_ context.Context
43038 header_ http.Header
43039 }
43040
43041
43042
43043 func (r *RemarketingListsService) List(profileId int64, advertiserId int64) *RemarketingListsListCall {
43044 c := &RemarketingListsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
43045 c.profileId = profileId
43046 c.urlParams_.Set("advertiserId", fmt.Sprint(advertiserId))
43047 return c
43048 }
43049
43050
43051
43052 func (c *RemarketingListsListCall) Active(active bool) *RemarketingListsListCall {
43053 c.urlParams_.Set("active", fmt.Sprint(active))
43054 return c
43055 }
43056
43057
43058
43059
43060 func (c *RemarketingListsListCall) FloodlightActivityId(floodlightActivityId int64) *RemarketingListsListCall {
43061 c.urlParams_.Set("floodlightActivityId", fmt.Sprint(floodlightActivityId))
43062 return c
43063 }
43064
43065
43066
43067 func (c *RemarketingListsListCall) MaxResults(maxResults int64) *RemarketingListsListCall {
43068 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
43069 return c
43070 }
43071
43072
43073
43074
43075
43076
43077
43078
43079
43080 func (c *RemarketingListsListCall) Name(name string) *RemarketingListsListCall {
43081 c.urlParams_.Set("name", name)
43082 return c
43083 }
43084
43085
43086
43087 func (c *RemarketingListsListCall) PageToken(pageToken string) *RemarketingListsListCall {
43088 c.urlParams_.Set("pageToken", pageToken)
43089 return c
43090 }
43091
43092
43093
43094
43095
43096
43097
43098
43099 func (c *RemarketingListsListCall) SortField(sortField string) *RemarketingListsListCall {
43100 c.urlParams_.Set("sortField", sortField)
43101 return c
43102 }
43103
43104
43105
43106
43107
43108
43109
43110
43111 func (c *RemarketingListsListCall) SortOrder(sortOrder string) *RemarketingListsListCall {
43112 c.urlParams_.Set("sortOrder", sortOrder)
43113 return c
43114 }
43115
43116
43117
43118
43119 func (c *RemarketingListsListCall) Fields(s ...googleapi.Field) *RemarketingListsListCall {
43120 c.urlParams_.Set("fields", googleapi.CombineFields(s))
43121 return c
43122 }
43123
43124
43125
43126
43127
43128
43129 func (c *RemarketingListsListCall) IfNoneMatch(entityTag string) *RemarketingListsListCall {
43130 c.ifNoneMatch_ = entityTag
43131 return c
43132 }
43133
43134
43135
43136
43137 func (c *RemarketingListsListCall) Context(ctx context.Context) *RemarketingListsListCall {
43138 c.ctx_ = ctx
43139 return c
43140 }
43141
43142
43143
43144 func (c *RemarketingListsListCall) Header() http.Header {
43145 if c.header_ == nil {
43146 c.header_ = make(http.Header)
43147 }
43148 return c.header_
43149 }
43150
43151 func (c *RemarketingListsListCall) doRequest(alt string) (*http.Response, error) {
43152 reqHeaders := make(http.Header)
43153 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
43154 for k, v := range c.header_ {
43155 reqHeaders[k] = v
43156 }
43157 reqHeaders.Set("User-Agent", c.s.userAgent())
43158 if c.ifNoneMatch_ != "" {
43159 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
43160 }
43161 var body io.Reader = nil
43162 c.urlParams_.Set("alt", alt)
43163 c.urlParams_.Set("prettyPrint", "false")
43164 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/remarketingLists")
43165 urls += "?" + c.urlParams_.Encode()
43166 req, err := http.NewRequest("GET", urls, body)
43167 if err != nil {
43168 return nil, err
43169 }
43170 req.Header = reqHeaders
43171 googleapi.Expand(req.URL, map[string]string{
43172 "profileId": strconv.FormatInt(c.profileId, 10),
43173 })
43174 return gensupport.SendRequest(c.ctx_, c.s.client, req)
43175 }
43176
43177
43178
43179
43180
43181
43182
43183
43184 func (c *RemarketingListsListCall) Do(opts ...googleapi.CallOption) (*RemarketingListsListResponse, error) {
43185 gensupport.SetOptions(c.urlParams_, opts...)
43186 res, err := c.doRequest("json")
43187 if res != nil && res.StatusCode == http.StatusNotModified {
43188 if res.Body != nil {
43189 res.Body.Close()
43190 }
43191 return nil, &googleapi.Error{
43192 Code: res.StatusCode,
43193 Header: res.Header,
43194 }
43195 }
43196 if err != nil {
43197 return nil, err
43198 }
43199 defer googleapi.CloseBody(res)
43200 if err := googleapi.CheckResponse(res); err != nil {
43201 return nil, err
43202 }
43203 ret := &RemarketingListsListResponse{
43204 ServerResponse: googleapi.ServerResponse{
43205 Header: res.Header,
43206 HTTPStatusCode: res.StatusCode,
43207 },
43208 }
43209 target := &ret
43210 if err := gensupport.DecodeResponse(target, res); err != nil {
43211 return nil, err
43212 }
43213 return ret, nil
43214
43215
43216
43217
43218
43219
43220
43221
43222
43223
43224
43225
43226
43227
43228
43229
43230
43231
43232
43233
43234
43235
43236
43237
43238
43239
43240
43241
43242
43243
43244
43245
43246
43247
43248
43249
43250
43251
43252
43253
43254
43255
43256
43257
43258
43259
43260
43261
43262
43263
43264
43265
43266
43267
43268
43269
43270
43271
43272
43273
43274
43275
43276
43277
43278
43279
43280
43281
43282
43283
43284
43285
43286
43287
43288
43289
43290
43291
43292
43293
43294
43295
43296
43297
43298
43299
43300
43301
43302
43303
43304
43305 }
43306
43307
43308
43309
43310 func (c *RemarketingListsListCall) Pages(ctx context.Context, f func(*RemarketingListsListResponse) error) error {
43311 c.ctx_ = ctx
43312 defer c.PageToken(c.urlParams_.Get("pageToken"))
43313 for {
43314 x, err := c.Do()
43315 if err != nil {
43316 return err
43317 }
43318 if err := f(x); err != nil {
43319 return err
43320 }
43321 if x.NextPageToken == "" {
43322 return nil
43323 }
43324 c.PageToken(x.NextPageToken)
43325 }
43326 }
43327
43328
43329
43330 type RemarketingListsPatchCall struct {
43331 s *Service
43332 profileId int64
43333 remarketinglist *RemarketingList
43334 urlParams_ gensupport.URLParams
43335 ctx_ context.Context
43336 header_ http.Header
43337 }
43338
43339
43340
43341 func (r *RemarketingListsService) Patch(profileId int64, id int64, remarketinglist *RemarketingList) *RemarketingListsPatchCall {
43342 c := &RemarketingListsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
43343 c.profileId = profileId
43344 c.urlParams_.Set("id", fmt.Sprint(id))
43345 c.remarketinglist = remarketinglist
43346 return c
43347 }
43348
43349
43350
43351
43352 func (c *RemarketingListsPatchCall) Fields(s ...googleapi.Field) *RemarketingListsPatchCall {
43353 c.urlParams_.Set("fields", googleapi.CombineFields(s))
43354 return c
43355 }
43356
43357
43358
43359
43360 func (c *RemarketingListsPatchCall) Context(ctx context.Context) *RemarketingListsPatchCall {
43361 c.ctx_ = ctx
43362 return c
43363 }
43364
43365
43366
43367 func (c *RemarketingListsPatchCall) Header() http.Header {
43368 if c.header_ == nil {
43369 c.header_ = make(http.Header)
43370 }
43371 return c.header_
43372 }
43373
43374 func (c *RemarketingListsPatchCall) doRequest(alt string) (*http.Response, error) {
43375 reqHeaders := make(http.Header)
43376 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
43377 for k, v := range c.header_ {
43378 reqHeaders[k] = v
43379 }
43380 reqHeaders.Set("User-Agent", c.s.userAgent())
43381 var body io.Reader = nil
43382 body, err := googleapi.WithoutDataWrapper.JSONReader(c.remarketinglist)
43383 if err != nil {
43384 return nil, err
43385 }
43386 reqHeaders.Set("Content-Type", "application/json")
43387 c.urlParams_.Set("alt", alt)
43388 c.urlParams_.Set("prettyPrint", "false")
43389 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/remarketingLists")
43390 urls += "?" + c.urlParams_.Encode()
43391 req, err := http.NewRequest("PATCH", urls, body)
43392 if err != nil {
43393 return nil, err
43394 }
43395 req.Header = reqHeaders
43396 googleapi.Expand(req.URL, map[string]string{
43397 "profileId": strconv.FormatInt(c.profileId, 10),
43398 })
43399 return gensupport.SendRequest(c.ctx_, c.s.client, req)
43400 }
43401
43402
43403
43404
43405
43406
43407
43408
43409 func (c *RemarketingListsPatchCall) Do(opts ...googleapi.CallOption) (*RemarketingList, error) {
43410 gensupport.SetOptions(c.urlParams_, opts...)
43411 res, err := c.doRequest("json")
43412 if res != nil && res.StatusCode == http.StatusNotModified {
43413 if res.Body != nil {
43414 res.Body.Close()
43415 }
43416 return nil, &googleapi.Error{
43417 Code: res.StatusCode,
43418 Header: res.Header,
43419 }
43420 }
43421 if err != nil {
43422 return nil, err
43423 }
43424 defer googleapi.CloseBody(res)
43425 if err := googleapi.CheckResponse(res); err != nil {
43426 return nil, err
43427 }
43428 ret := &RemarketingList{
43429 ServerResponse: googleapi.ServerResponse{
43430 Header: res.Header,
43431 HTTPStatusCode: res.StatusCode,
43432 },
43433 }
43434 target := &ret
43435 if err := gensupport.DecodeResponse(target, res); err != nil {
43436 return nil, err
43437 }
43438 return ret, nil
43439
43440
43441
43442
43443
43444
43445
43446
43447
43448
43449
43450
43451
43452
43453
43454
43455
43456
43457
43458
43459
43460
43461
43462
43463
43464
43465
43466
43467
43468
43469
43470
43471
43472
43473
43474
43475 }
43476
43477
43478
43479 type RemarketingListsUpdateCall struct {
43480 s *Service
43481 profileId int64
43482 remarketinglist *RemarketingList
43483 urlParams_ gensupport.URLParams
43484 ctx_ context.Context
43485 header_ http.Header
43486 }
43487
43488
43489 func (r *RemarketingListsService) Update(profileId int64, remarketinglist *RemarketingList) *RemarketingListsUpdateCall {
43490 c := &RemarketingListsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
43491 c.profileId = profileId
43492 c.remarketinglist = remarketinglist
43493 return c
43494 }
43495
43496
43497
43498
43499 func (c *RemarketingListsUpdateCall) Fields(s ...googleapi.Field) *RemarketingListsUpdateCall {
43500 c.urlParams_.Set("fields", googleapi.CombineFields(s))
43501 return c
43502 }
43503
43504
43505
43506
43507 func (c *RemarketingListsUpdateCall) Context(ctx context.Context) *RemarketingListsUpdateCall {
43508 c.ctx_ = ctx
43509 return c
43510 }
43511
43512
43513
43514 func (c *RemarketingListsUpdateCall) Header() http.Header {
43515 if c.header_ == nil {
43516 c.header_ = make(http.Header)
43517 }
43518 return c.header_
43519 }
43520
43521 func (c *RemarketingListsUpdateCall) doRequest(alt string) (*http.Response, error) {
43522 reqHeaders := make(http.Header)
43523 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
43524 for k, v := range c.header_ {
43525 reqHeaders[k] = v
43526 }
43527 reqHeaders.Set("User-Agent", c.s.userAgent())
43528 var body io.Reader = nil
43529 body, err := googleapi.WithoutDataWrapper.JSONReader(c.remarketinglist)
43530 if err != nil {
43531 return nil, err
43532 }
43533 reqHeaders.Set("Content-Type", "application/json")
43534 c.urlParams_.Set("alt", alt)
43535 c.urlParams_.Set("prettyPrint", "false")
43536 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/remarketingLists")
43537 urls += "?" + c.urlParams_.Encode()
43538 req, err := http.NewRequest("PUT", urls, body)
43539 if err != nil {
43540 return nil, err
43541 }
43542 req.Header = reqHeaders
43543 googleapi.Expand(req.URL, map[string]string{
43544 "profileId": strconv.FormatInt(c.profileId, 10),
43545 })
43546 return gensupport.SendRequest(c.ctx_, c.s.client, req)
43547 }
43548
43549
43550
43551
43552
43553
43554
43555
43556 func (c *RemarketingListsUpdateCall) Do(opts ...googleapi.CallOption) (*RemarketingList, error) {
43557 gensupport.SetOptions(c.urlParams_, opts...)
43558 res, err := c.doRequest("json")
43559 if res != nil && res.StatusCode == http.StatusNotModified {
43560 if res.Body != nil {
43561 res.Body.Close()
43562 }
43563 return nil, &googleapi.Error{
43564 Code: res.StatusCode,
43565 Header: res.Header,
43566 }
43567 }
43568 if err != nil {
43569 return nil, err
43570 }
43571 defer googleapi.CloseBody(res)
43572 if err := googleapi.CheckResponse(res); err != nil {
43573 return nil, err
43574 }
43575 ret := &RemarketingList{
43576 ServerResponse: googleapi.ServerResponse{
43577 Header: res.Header,
43578 HTTPStatusCode: res.StatusCode,
43579 },
43580 }
43581 target := &ret
43582 if err := gensupport.DecodeResponse(target, res); err != nil {
43583 return nil, err
43584 }
43585 return ret, nil
43586
43587
43588
43589
43590
43591
43592
43593
43594
43595
43596
43597
43598
43599
43600
43601
43602
43603
43604
43605
43606
43607
43608
43609
43610
43611
43612
43613
43614 }
43615
43616
43617
43618 type ReportsDeleteCall struct {
43619 s *Service
43620 profileId int64
43621 reportId int64
43622 urlParams_ gensupport.URLParams
43623 ctx_ context.Context
43624 header_ http.Header
43625 }
43626
43627
43628 func (r *ReportsService) Delete(profileId int64, reportId int64) *ReportsDeleteCall {
43629 c := &ReportsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
43630 c.profileId = profileId
43631 c.reportId = reportId
43632 return c
43633 }
43634
43635
43636
43637
43638 func (c *ReportsDeleteCall) Fields(s ...googleapi.Field) *ReportsDeleteCall {
43639 c.urlParams_.Set("fields", googleapi.CombineFields(s))
43640 return c
43641 }
43642
43643
43644
43645
43646 func (c *ReportsDeleteCall) Context(ctx context.Context) *ReportsDeleteCall {
43647 c.ctx_ = ctx
43648 return c
43649 }
43650
43651
43652
43653 func (c *ReportsDeleteCall) Header() http.Header {
43654 if c.header_ == nil {
43655 c.header_ = make(http.Header)
43656 }
43657 return c.header_
43658 }
43659
43660 func (c *ReportsDeleteCall) doRequest(alt string) (*http.Response, error) {
43661 reqHeaders := make(http.Header)
43662 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
43663 for k, v := range c.header_ {
43664 reqHeaders[k] = v
43665 }
43666 reqHeaders.Set("User-Agent", c.s.userAgent())
43667 var body io.Reader = nil
43668 c.urlParams_.Set("alt", alt)
43669 c.urlParams_.Set("prettyPrint", "false")
43670 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/reports/{reportId}")
43671 urls += "?" + c.urlParams_.Encode()
43672 req, err := http.NewRequest("DELETE", urls, body)
43673 if err != nil {
43674 return nil, err
43675 }
43676 req.Header = reqHeaders
43677 googleapi.Expand(req.URL, map[string]string{
43678 "profileId": strconv.FormatInt(c.profileId, 10),
43679 "reportId": strconv.FormatInt(c.reportId, 10),
43680 })
43681 return gensupport.SendRequest(c.ctx_, c.s.client, req)
43682 }
43683
43684
43685 func (c *ReportsDeleteCall) Do(opts ...googleapi.CallOption) error {
43686 gensupport.SetOptions(c.urlParams_, opts...)
43687 res, err := c.doRequest("json")
43688 if err != nil {
43689 return err
43690 }
43691 defer googleapi.CloseBody(res)
43692 if err := googleapi.CheckResponse(res); err != nil {
43693 return err
43694 }
43695 return nil
43696
43697
43698
43699
43700
43701
43702
43703
43704
43705
43706
43707
43708
43709
43710
43711
43712
43713
43714
43715
43716
43717
43718
43719
43720
43721
43722
43723
43724
43725
43726 }
43727
43728
43729
43730 type ReportsGetCall struct {
43731 s *Service
43732 profileId int64
43733 reportId int64
43734 urlParams_ gensupport.URLParams
43735 ifNoneMatch_ string
43736 ctx_ context.Context
43737 header_ http.Header
43738 }
43739
43740
43741 func (r *ReportsService) Get(profileId int64, reportId int64) *ReportsGetCall {
43742 c := &ReportsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
43743 c.profileId = profileId
43744 c.reportId = reportId
43745 return c
43746 }
43747
43748
43749
43750
43751 func (c *ReportsGetCall) Fields(s ...googleapi.Field) *ReportsGetCall {
43752 c.urlParams_.Set("fields", googleapi.CombineFields(s))
43753 return c
43754 }
43755
43756
43757
43758
43759
43760
43761 func (c *ReportsGetCall) IfNoneMatch(entityTag string) *ReportsGetCall {
43762 c.ifNoneMatch_ = entityTag
43763 return c
43764 }
43765
43766
43767
43768
43769 func (c *ReportsGetCall) Context(ctx context.Context) *ReportsGetCall {
43770 c.ctx_ = ctx
43771 return c
43772 }
43773
43774
43775
43776 func (c *ReportsGetCall) Header() http.Header {
43777 if c.header_ == nil {
43778 c.header_ = make(http.Header)
43779 }
43780 return c.header_
43781 }
43782
43783 func (c *ReportsGetCall) doRequest(alt string) (*http.Response, error) {
43784 reqHeaders := make(http.Header)
43785 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
43786 for k, v := range c.header_ {
43787 reqHeaders[k] = v
43788 }
43789 reqHeaders.Set("User-Agent", c.s.userAgent())
43790 if c.ifNoneMatch_ != "" {
43791 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
43792 }
43793 var body io.Reader = nil
43794 c.urlParams_.Set("alt", alt)
43795 c.urlParams_.Set("prettyPrint", "false")
43796 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/reports/{reportId}")
43797 urls += "?" + c.urlParams_.Encode()
43798 req, err := http.NewRequest("GET", urls, body)
43799 if err != nil {
43800 return nil, err
43801 }
43802 req.Header = reqHeaders
43803 googleapi.Expand(req.URL, map[string]string{
43804 "profileId": strconv.FormatInt(c.profileId, 10),
43805 "reportId": strconv.FormatInt(c.reportId, 10),
43806 })
43807 return gensupport.SendRequest(c.ctx_, c.s.client, req)
43808 }
43809
43810
43811
43812
43813
43814
43815
43816
43817 func (c *ReportsGetCall) Do(opts ...googleapi.CallOption) (*Report, error) {
43818 gensupport.SetOptions(c.urlParams_, opts...)
43819 res, err := c.doRequest("json")
43820 if res != nil && res.StatusCode == http.StatusNotModified {
43821 if res.Body != nil {
43822 res.Body.Close()
43823 }
43824 return nil, &googleapi.Error{
43825 Code: res.StatusCode,
43826 Header: res.Header,
43827 }
43828 }
43829 if err != nil {
43830 return nil, err
43831 }
43832 defer googleapi.CloseBody(res)
43833 if err := googleapi.CheckResponse(res); err != nil {
43834 return nil, err
43835 }
43836 ret := &Report{
43837 ServerResponse: googleapi.ServerResponse{
43838 Header: res.Header,
43839 HTTPStatusCode: res.StatusCode,
43840 },
43841 }
43842 target := &ret
43843 if err := gensupport.DecodeResponse(target, res); err != nil {
43844 return nil, err
43845 }
43846 return ret, nil
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 type ReportsInsertCall struct {
43885 s *Service
43886 profileId int64
43887 report *Report
43888 urlParams_ gensupport.URLParams
43889 ctx_ context.Context
43890 header_ http.Header
43891 }
43892
43893
43894 func (r *ReportsService) Insert(profileId int64, report *Report) *ReportsInsertCall {
43895 c := &ReportsInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
43896 c.profileId = profileId
43897 c.report = report
43898 return c
43899 }
43900
43901
43902
43903
43904 func (c *ReportsInsertCall) Fields(s ...googleapi.Field) *ReportsInsertCall {
43905 c.urlParams_.Set("fields", googleapi.CombineFields(s))
43906 return c
43907 }
43908
43909
43910
43911
43912 func (c *ReportsInsertCall) Context(ctx context.Context) *ReportsInsertCall {
43913 c.ctx_ = ctx
43914 return c
43915 }
43916
43917
43918
43919 func (c *ReportsInsertCall) Header() http.Header {
43920 if c.header_ == nil {
43921 c.header_ = make(http.Header)
43922 }
43923 return c.header_
43924 }
43925
43926 func (c *ReportsInsertCall) doRequest(alt string) (*http.Response, error) {
43927 reqHeaders := make(http.Header)
43928 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
43929 for k, v := range c.header_ {
43930 reqHeaders[k] = v
43931 }
43932 reqHeaders.Set("User-Agent", c.s.userAgent())
43933 var body io.Reader = nil
43934 body, err := googleapi.WithoutDataWrapper.JSONReader(c.report)
43935 if err != nil {
43936 return nil, err
43937 }
43938 reqHeaders.Set("Content-Type", "application/json")
43939 c.urlParams_.Set("alt", alt)
43940 c.urlParams_.Set("prettyPrint", "false")
43941 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/reports")
43942 urls += "?" + c.urlParams_.Encode()
43943 req, err := http.NewRequest("POST", urls, body)
43944 if err != nil {
43945 return nil, err
43946 }
43947 req.Header = reqHeaders
43948 googleapi.Expand(req.URL, map[string]string{
43949 "profileId": strconv.FormatInt(c.profileId, 10),
43950 })
43951 return gensupport.SendRequest(c.ctx_, c.s.client, req)
43952 }
43953
43954
43955
43956
43957
43958
43959
43960
43961 func (c *ReportsInsertCall) Do(opts ...googleapi.CallOption) (*Report, error) {
43962 gensupport.SetOptions(c.urlParams_, opts...)
43963 res, err := c.doRequest("json")
43964 if res != nil && res.StatusCode == http.StatusNotModified {
43965 if res.Body != nil {
43966 res.Body.Close()
43967 }
43968 return nil, &googleapi.Error{
43969 Code: res.StatusCode,
43970 Header: res.Header,
43971 }
43972 }
43973 if err != nil {
43974 return nil, err
43975 }
43976 defer googleapi.CloseBody(res)
43977 if err := googleapi.CheckResponse(res); err != nil {
43978 return nil, err
43979 }
43980 ret := &Report{
43981 ServerResponse: googleapi.ServerResponse{
43982 Header: res.Header,
43983 HTTPStatusCode: res.StatusCode,
43984 },
43985 }
43986 target := &ret
43987 if err := gensupport.DecodeResponse(target, res); err != nil {
43988 return nil, err
43989 }
43990 return ret, nil
43991
43992
43993
43994
43995
43996
43997
43998
43999
44000
44001
44002
44003
44004
44005
44006
44007
44008
44009
44010
44011
44012
44013
44014
44015
44016
44017
44018
44019 }
44020
44021
44022
44023 type ReportsListCall struct {
44024 s *Service
44025 profileId int64
44026 urlParams_ gensupport.URLParams
44027 ifNoneMatch_ string
44028 ctx_ context.Context
44029 header_ http.Header
44030 }
44031
44032
44033 func (r *ReportsService) List(profileId int64) *ReportsListCall {
44034 c := &ReportsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
44035 c.profileId = profileId
44036 return c
44037 }
44038
44039
44040
44041 func (c *ReportsListCall) MaxResults(maxResults int64) *ReportsListCall {
44042 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
44043 return c
44044 }
44045
44046
44047
44048 func (c *ReportsListCall) PageToken(pageToken string) *ReportsListCall {
44049 c.urlParams_.Set("pageToken", pageToken)
44050 return c
44051 }
44052
44053
44054
44055
44056
44057
44058
44059
44060 func (c *ReportsListCall) Scope(scope string) *ReportsListCall {
44061 c.urlParams_.Set("scope", scope)
44062 return c
44063 }
44064
44065
44066
44067
44068
44069
44070
44071
44072
44073 func (c *ReportsListCall) SortField(sortField string) *ReportsListCall {
44074 c.urlParams_.Set("sortField", sortField)
44075 return c
44076 }
44077
44078
44079
44080
44081
44082
44083
44084
44085 func (c *ReportsListCall) SortOrder(sortOrder string) *ReportsListCall {
44086 c.urlParams_.Set("sortOrder", sortOrder)
44087 return c
44088 }
44089
44090
44091
44092
44093 func (c *ReportsListCall) Fields(s ...googleapi.Field) *ReportsListCall {
44094 c.urlParams_.Set("fields", googleapi.CombineFields(s))
44095 return c
44096 }
44097
44098
44099
44100
44101
44102
44103 func (c *ReportsListCall) IfNoneMatch(entityTag string) *ReportsListCall {
44104 c.ifNoneMatch_ = entityTag
44105 return c
44106 }
44107
44108
44109
44110
44111 func (c *ReportsListCall) Context(ctx context.Context) *ReportsListCall {
44112 c.ctx_ = ctx
44113 return c
44114 }
44115
44116
44117
44118 func (c *ReportsListCall) Header() http.Header {
44119 if c.header_ == nil {
44120 c.header_ = make(http.Header)
44121 }
44122 return c.header_
44123 }
44124
44125 func (c *ReportsListCall) doRequest(alt string) (*http.Response, error) {
44126 reqHeaders := make(http.Header)
44127 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
44128 for k, v := range c.header_ {
44129 reqHeaders[k] = v
44130 }
44131 reqHeaders.Set("User-Agent", c.s.userAgent())
44132 if c.ifNoneMatch_ != "" {
44133 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
44134 }
44135 var body io.Reader = nil
44136 c.urlParams_.Set("alt", alt)
44137 c.urlParams_.Set("prettyPrint", "false")
44138 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/reports")
44139 urls += "?" + c.urlParams_.Encode()
44140 req, err := http.NewRequest("GET", urls, body)
44141 if err != nil {
44142 return nil, err
44143 }
44144 req.Header = reqHeaders
44145 googleapi.Expand(req.URL, map[string]string{
44146 "profileId": strconv.FormatInt(c.profileId, 10),
44147 })
44148 return gensupport.SendRequest(c.ctx_, c.s.client, req)
44149 }
44150
44151
44152
44153
44154
44155
44156
44157
44158 func (c *ReportsListCall) Do(opts ...googleapi.CallOption) (*ReportList, error) {
44159 gensupport.SetOptions(c.urlParams_, opts...)
44160 res, err := c.doRequest("json")
44161 if res != nil && res.StatusCode == http.StatusNotModified {
44162 if res.Body != nil {
44163 res.Body.Close()
44164 }
44165 return nil, &googleapi.Error{
44166 Code: res.StatusCode,
44167 Header: res.Header,
44168 }
44169 }
44170 if err != nil {
44171 return nil, err
44172 }
44173 defer googleapi.CloseBody(res)
44174 if err := googleapi.CheckResponse(res); err != nil {
44175 return nil, err
44176 }
44177 ret := &ReportList{
44178 ServerResponse: googleapi.ServerResponse{
44179 Header: res.Header,
44180 HTTPStatusCode: res.StatusCode,
44181 },
44182 }
44183 target := &ret
44184 if err := gensupport.DecodeResponse(target, res); err != nil {
44185 return nil, err
44186 }
44187 return ret, nil
44188
44189
44190
44191
44192
44193
44194
44195
44196
44197
44198
44199
44200
44201
44202
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
44236
44237
44238
44239
44240
44241
44242
44243
44244
44245
44246
44247
44248
44249
44250
44251
44252
44253
44254
44255
44256
44257
44258
44259
44260
44261
44262
44263
44264
44265
44266
44267
44268
44269
44270
44271 }
44272
44273
44274
44275
44276 func (c *ReportsListCall) Pages(ctx context.Context, f func(*ReportList) error) error {
44277 c.ctx_ = ctx
44278 defer c.PageToken(c.urlParams_.Get("pageToken"))
44279 for {
44280 x, err := c.Do()
44281 if err != nil {
44282 return err
44283 }
44284 if err := f(x); err != nil {
44285 return err
44286 }
44287 if x.NextPageToken == "" {
44288 return nil
44289 }
44290 c.PageToken(x.NextPageToken)
44291 }
44292 }
44293
44294
44295
44296 type ReportsPatchCall struct {
44297 s *Service
44298 profileId int64
44299 reportId int64
44300 report *Report
44301 urlParams_ gensupport.URLParams
44302 ctx_ context.Context
44303 header_ http.Header
44304 }
44305
44306
44307 func (r *ReportsService) Patch(profileId int64, reportId int64, report *Report) *ReportsPatchCall {
44308 c := &ReportsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
44309 c.profileId = profileId
44310 c.reportId = reportId
44311 c.report = report
44312 return c
44313 }
44314
44315
44316
44317
44318 func (c *ReportsPatchCall) Fields(s ...googleapi.Field) *ReportsPatchCall {
44319 c.urlParams_.Set("fields", googleapi.CombineFields(s))
44320 return c
44321 }
44322
44323
44324
44325
44326 func (c *ReportsPatchCall) Context(ctx context.Context) *ReportsPatchCall {
44327 c.ctx_ = ctx
44328 return c
44329 }
44330
44331
44332
44333 func (c *ReportsPatchCall) Header() http.Header {
44334 if c.header_ == nil {
44335 c.header_ = make(http.Header)
44336 }
44337 return c.header_
44338 }
44339
44340 func (c *ReportsPatchCall) doRequest(alt string) (*http.Response, error) {
44341 reqHeaders := make(http.Header)
44342 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
44343 for k, v := range c.header_ {
44344 reqHeaders[k] = v
44345 }
44346 reqHeaders.Set("User-Agent", c.s.userAgent())
44347 var body io.Reader = nil
44348 body, err := googleapi.WithoutDataWrapper.JSONReader(c.report)
44349 if err != nil {
44350 return nil, err
44351 }
44352 reqHeaders.Set("Content-Type", "application/json")
44353 c.urlParams_.Set("alt", alt)
44354 c.urlParams_.Set("prettyPrint", "false")
44355 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/reports/{reportId}")
44356 urls += "?" + c.urlParams_.Encode()
44357 req, err := http.NewRequest("PATCH", urls, body)
44358 if err != nil {
44359 return nil, err
44360 }
44361 req.Header = reqHeaders
44362 googleapi.Expand(req.URL, map[string]string{
44363 "profileId": strconv.FormatInt(c.profileId, 10),
44364 "reportId": strconv.FormatInt(c.reportId, 10),
44365 })
44366 return gensupport.SendRequest(c.ctx_, c.s.client, req)
44367 }
44368
44369
44370
44371
44372
44373
44374
44375
44376 func (c *ReportsPatchCall) Do(opts ...googleapi.CallOption) (*Report, error) {
44377 gensupport.SetOptions(c.urlParams_, opts...)
44378 res, err := c.doRequest("json")
44379 if res != nil && res.StatusCode == http.StatusNotModified {
44380 if res.Body != nil {
44381 res.Body.Close()
44382 }
44383 return nil, &googleapi.Error{
44384 Code: res.StatusCode,
44385 Header: res.Header,
44386 }
44387 }
44388 if err != nil {
44389 return nil, err
44390 }
44391 defer googleapi.CloseBody(res)
44392 if err := googleapi.CheckResponse(res); err != nil {
44393 return nil, err
44394 }
44395 ret := &Report{
44396 ServerResponse: googleapi.ServerResponse{
44397 Header: res.Header,
44398 HTTPStatusCode: res.StatusCode,
44399 },
44400 }
44401 target := &ret
44402 if err := gensupport.DecodeResponse(target, res); err != nil {
44403 return nil, err
44404 }
44405 return ret, nil
44406
44407
44408
44409
44410
44411
44412
44413
44414
44415
44416
44417
44418
44419
44420
44421
44422
44423
44424
44425
44426
44427
44428
44429
44430
44431
44432
44433
44434
44435
44436
44437
44438
44439
44440
44441
44442 }
44443
44444
44445
44446 type ReportsRunCall struct {
44447 s *Service
44448 profileId int64
44449 reportId int64
44450 urlParams_ gensupport.URLParams
44451 ctx_ context.Context
44452 header_ http.Header
44453 }
44454
44455
44456 func (r *ReportsService) Run(profileId int64, reportId int64) *ReportsRunCall {
44457 c := &ReportsRunCall{s: r.s, urlParams_: make(gensupport.URLParams)}
44458 c.profileId = profileId
44459 c.reportId = reportId
44460 return c
44461 }
44462
44463
44464
44465 func (c *ReportsRunCall) Synchronous(synchronous bool) *ReportsRunCall {
44466 c.urlParams_.Set("synchronous", fmt.Sprint(synchronous))
44467 return c
44468 }
44469
44470
44471
44472
44473 func (c *ReportsRunCall) Fields(s ...googleapi.Field) *ReportsRunCall {
44474 c.urlParams_.Set("fields", googleapi.CombineFields(s))
44475 return c
44476 }
44477
44478
44479
44480
44481 func (c *ReportsRunCall) Context(ctx context.Context) *ReportsRunCall {
44482 c.ctx_ = ctx
44483 return c
44484 }
44485
44486
44487
44488 func (c *ReportsRunCall) Header() http.Header {
44489 if c.header_ == nil {
44490 c.header_ = make(http.Header)
44491 }
44492 return c.header_
44493 }
44494
44495 func (c *ReportsRunCall) doRequest(alt string) (*http.Response, error) {
44496 reqHeaders := make(http.Header)
44497 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
44498 for k, v := range c.header_ {
44499 reqHeaders[k] = v
44500 }
44501 reqHeaders.Set("User-Agent", c.s.userAgent())
44502 var body io.Reader = nil
44503 c.urlParams_.Set("alt", alt)
44504 c.urlParams_.Set("prettyPrint", "false")
44505 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/reports/{reportId}/run")
44506 urls += "?" + c.urlParams_.Encode()
44507 req, err := http.NewRequest("POST", urls, body)
44508 if err != nil {
44509 return nil, err
44510 }
44511 req.Header = reqHeaders
44512 googleapi.Expand(req.URL, map[string]string{
44513 "profileId": strconv.FormatInt(c.profileId, 10),
44514 "reportId": strconv.FormatInt(c.reportId, 10),
44515 })
44516 return gensupport.SendRequest(c.ctx_, c.s.client, req)
44517 }
44518
44519
44520
44521
44522
44523
44524
44525
44526 func (c *ReportsRunCall) Do(opts ...googleapi.CallOption) (*File, error) {
44527 gensupport.SetOptions(c.urlParams_, opts...)
44528 res, err := c.doRequest("json")
44529 if res != nil && res.StatusCode == http.StatusNotModified {
44530 if res.Body != nil {
44531 res.Body.Close()
44532 }
44533 return nil, &googleapi.Error{
44534 Code: res.StatusCode,
44535 Header: res.Header,
44536 }
44537 }
44538 if err != nil {
44539 return nil, err
44540 }
44541 defer googleapi.CloseBody(res)
44542 if err := googleapi.CheckResponse(res); err != nil {
44543 return nil, err
44544 }
44545 ret := &File{
44546 ServerResponse: googleapi.ServerResponse{
44547 Header: res.Header,
44548 HTTPStatusCode: res.StatusCode,
44549 },
44550 }
44551 target := &ret
44552 if err := gensupport.DecodeResponse(target, res); err != nil {
44553 return nil, err
44554 }
44555 return ret, nil
44556
44557
44558
44559
44560
44561
44562
44563
44564
44565
44566
44567
44568
44569
44570
44571
44572
44573
44574
44575
44576
44577
44578
44579
44580
44581
44582
44583
44584
44585
44586
44587
44588
44589
44590
44591
44592
44593
44594
44595 }
44596
44597
44598
44599 type ReportsUpdateCall struct {
44600 s *Service
44601 profileId int64
44602 reportId int64
44603 report *Report
44604 urlParams_ gensupport.URLParams
44605 ctx_ context.Context
44606 header_ http.Header
44607 }
44608
44609
44610 func (r *ReportsService) Update(profileId int64, reportId int64, report *Report) *ReportsUpdateCall {
44611 c := &ReportsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
44612 c.profileId = profileId
44613 c.reportId = reportId
44614 c.report = report
44615 return c
44616 }
44617
44618
44619
44620
44621 func (c *ReportsUpdateCall) Fields(s ...googleapi.Field) *ReportsUpdateCall {
44622 c.urlParams_.Set("fields", googleapi.CombineFields(s))
44623 return c
44624 }
44625
44626
44627
44628
44629 func (c *ReportsUpdateCall) Context(ctx context.Context) *ReportsUpdateCall {
44630 c.ctx_ = ctx
44631 return c
44632 }
44633
44634
44635
44636 func (c *ReportsUpdateCall) Header() http.Header {
44637 if c.header_ == nil {
44638 c.header_ = make(http.Header)
44639 }
44640 return c.header_
44641 }
44642
44643 func (c *ReportsUpdateCall) doRequest(alt string) (*http.Response, error) {
44644 reqHeaders := make(http.Header)
44645 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
44646 for k, v := range c.header_ {
44647 reqHeaders[k] = v
44648 }
44649 reqHeaders.Set("User-Agent", c.s.userAgent())
44650 var body io.Reader = nil
44651 body, err := googleapi.WithoutDataWrapper.JSONReader(c.report)
44652 if err != nil {
44653 return nil, err
44654 }
44655 reqHeaders.Set("Content-Type", "application/json")
44656 c.urlParams_.Set("alt", alt)
44657 c.urlParams_.Set("prettyPrint", "false")
44658 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/reports/{reportId}")
44659 urls += "?" + c.urlParams_.Encode()
44660 req, err := http.NewRequest("PUT", urls, body)
44661 if err != nil {
44662 return nil, err
44663 }
44664 req.Header = reqHeaders
44665 googleapi.Expand(req.URL, map[string]string{
44666 "profileId": strconv.FormatInt(c.profileId, 10),
44667 "reportId": strconv.FormatInt(c.reportId, 10),
44668 })
44669 return gensupport.SendRequest(c.ctx_, c.s.client, req)
44670 }
44671
44672
44673
44674
44675
44676
44677
44678
44679 func (c *ReportsUpdateCall) Do(opts ...googleapi.CallOption) (*Report, error) {
44680 gensupport.SetOptions(c.urlParams_, opts...)
44681 res, err := c.doRequest("json")
44682 if res != nil && res.StatusCode == http.StatusNotModified {
44683 if res.Body != nil {
44684 res.Body.Close()
44685 }
44686 return nil, &googleapi.Error{
44687 Code: res.StatusCode,
44688 Header: res.Header,
44689 }
44690 }
44691 if err != nil {
44692 return nil, err
44693 }
44694 defer googleapi.CloseBody(res)
44695 if err := googleapi.CheckResponse(res); err != nil {
44696 return nil, err
44697 }
44698 ret := &Report{
44699 ServerResponse: googleapi.ServerResponse{
44700 Header: res.Header,
44701 HTTPStatusCode: res.StatusCode,
44702 },
44703 }
44704 target := &ret
44705 if err := gensupport.DecodeResponse(target, res); err != nil {
44706 return nil, err
44707 }
44708 return ret, nil
44709
44710
44711
44712
44713
44714
44715
44716
44717
44718
44719
44720
44721
44722
44723
44724
44725
44726
44727
44728
44729
44730
44731
44732
44733
44734
44735
44736
44737
44738
44739
44740
44741
44742
44743
44744
44745 }
44746
44747
44748
44749 type ReportsCompatibleFieldsQueryCall struct {
44750 s *Service
44751 profileId int64
44752 report *Report
44753 urlParams_ gensupport.URLParams
44754 ctx_ context.Context
44755 header_ http.Header
44756 }
44757
44758
44759
44760
44761 func (r *ReportsCompatibleFieldsService) Query(profileId int64, report *Report) *ReportsCompatibleFieldsQueryCall {
44762 c := &ReportsCompatibleFieldsQueryCall{s: r.s, urlParams_: make(gensupport.URLParams)}
44763 c.profileId = profileId
44764 c.report = report
44765 return c
44766 }
44767
44768
44769
44770
44771 func (c *ReportsCompatibleFieldsQueryCall) Fields(s ...googleapi.Field) *ReportsCompatibleFieldsQueryCall {
44772 c.urlParams_.Set("fields", googleapi.CombineFields(s))
44773 return c
44774 }
44775
44776
44777
44778
44779 func (c *ReportsCompatibleFieldsQueryCall) Context(ctx context.Context) *ReportsCompatibleFieldsQueryCall {
44780 c.ctx_ = ctx
44781 return c
44782 }
44783
44784
44785
44786 func (c *ReportsCompatibleFieldsQueryCall) Header() http.Header {
44787 if c.header_ == nil {
44788 c.header_ = make(http.Header)
44789 }
44790 return c.header_
44791 }
44792
44793 func (c *ReportsCompatibleFieldsQueryCall) doRequest(alt string) (*http.Response, error) {
44794 reqHeaders := make(http.Header)
44795 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
44796 for k, v := range c.header_ {
44797 reqHeaders[k] = v
44798 }
44799 reqHeaders.Set("User-Agent", c.s.userAgent())
44800 var body io.Reader = nil
44801 body, err := googleapi.WithoutDataWrapper.JSONReader(c.report)
44802 if err != nil {
44803 return nil, err
44804 }
44805 reqHeaders.Set("Content-Type", "application/json")
44806 c.urlParams_.Set("alt", alt)
44807 c.urlParams_.Set("prettyPrint", "false")
44808 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/reports/compatiblefields/query")
44809 urls += "?" + c.urlParams_.Encode()
44810 req, err := http.NewRequest("POST", urls, body)
44811 if err != nil {
44812 return nil, err
44813 }
44814 req.Header = reqHeaders
44815 googleapi.Expand(req.URL, map[string]string{
44816 "profileId": strconv.FormatInt(c.profileId, 10),
44817 })
44818 return gensupport.SendRequest(c.ctx_, c.s.client, req)
44819 }
44820
44821
44822
44823
44824
44825
44826
44827
44828 func (c *ReportsCompatibleFieldsQueryCall) Do(opts ...googleapi.CallOption) (*CompatibleFields, error) {
44829 gensupport.SetOptions(c.urlParams_, opts...)
44830 res, err := c.doRequest("json")
44831 if res != nil && res.StatusCode == http.StatusNotModified {
44832 if res.Body != nil {
44833 res.Body.Close()
44834 }
44835 return nil, &googleapi.Error{
44836 Code: res.StatusCode,
44837 Header: res.Header,
44838 }
44839 }
44840 if err != nil {
44841 return nil, err
44842 }
44843 defer googleapi.CloseBody(res)
44844 if err := googleapi.CheckResponse(res); err != nil {
44845 return nil, err
44846 }
44847 ret := &CompatibleFields{
44848 ServerResponse: googleapi.ServerResponse{
44849 Header: res.Header,
44850 HTTPStatusCode: res.StatusCode,
44851 },
44852 }
44853 target := &ret
44854 if err := gensupport.DecodeResponse(target, res); err != nil {
44855 return nil, err
44856 }
44857 return ret, nil
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 type ReportsFilesGetCall struct {
44891 s *Service
44892 profileId int64
44893 reportId int64
44894 fileId int64
44895 urlParams_ gensupport.URLParams
44896 ifNoneMatch_ string
44897 ctx_ context.Context
44898 header_ http.Header
44899 }
44900
44901
44902 func (r *ReportsFilesService) Get(profileId int64, reportId int64, fileId int64) *ReportsFilesGetCall {
44903 c := &ReportsFilesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
44904 c.profileId = profileId
44905 c.reportId = reportId
44906 c.fileId = fileId
44907 return c
44908 }
44909
44910
44911
44912
44913 func (c *ReportsFilesGetCall) Fields(s ...googleapi.Field) *ReportsFilesGetCall {
44914 c.urlParams_.Set("fields", googleapi.CombineFields(s))
44915 return c
44916 }
44917
44918
44919
44920
44921
44922
44923 func (c *ReportsFilesGetCall) IfNoneMatch(entityTag string) *ReportsFilesGetCall {
44924 c.ifNoneMatch_ = entityTag
44925 return c
44926 }
44927
44928
44929
44930
44931 func (c *ReportsFilesGetCall) Context(ctx context.Context) *ReportsFilesGetCall {
44932 c.ctx_ = ctx
44933 return c
44934 }
44935
44936
44937
44938 func (c *ReportsFilesGetCall) Header() http.Header {
44939 if c.header_ == nil {
44940 c.header_ = make(http.Header)
44941 }
44942 return c.header_
44943 }
44944
44945 func (c *ReportsFilesGetCall) doRequest(alt string) (*http.Response, error) {
44946 reqHeaders := make(http.Header)
44947 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
44948 for k, v := range c.header_ {
44949 reqHeaders[k] = v
44950 }
44951 reqHeaders.Set("User-Agent", c.s.userAgent())
44952 if c.ifNoneMatch_ != "" {
44953 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
44954 }
44955 var body io.Reader = nil
44956 c.urlParams_.Set("alt", alt)
44957 c.urlParams_.Set("prettyPrint", "false")
44958 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/reports/{reportId}/files/{fileId}")
44959 urls += "?" + c.urlParams_.Encode()
44960 req, err := http.NewRequest("GET", urls, body)
44961 if err != nil {
44962 return nil, err
44963 }
44964 req.Header = reqHeaders
44965 googleapi.Expand(req.URL, map[string]string{
44966 "profileId": strconv.FormatInt(c.profileId, 10),
44967 "reportId": strconv.FormatInt(c.reportId, 10),
44968 "fileId": strconv.FormatInt(c.fileId, 10),
44969 })
44970 return gensupport.SendRequest(c.ctx_, c.s.client, req)
44971 }
44972
44973
44974
44975
44976 func (c *ReportsFilesGetCall) Download(opts ...googleapi.CallOption) (*http.Response, error) {
44977 gensupport.SetOptions(c.urlParams_, opts...)
44978 res, err := c.doRequest("media")
44979 if err != nil {
44980 return nil, err
44981 }
44982 if err := googleapi.CheckMediaResponse(res); err != nil {
44983 res.Body.Close()
44984 return nil, err
44985 }
44986 return res, nil
44987 }
44988
44989
44990
44991
44992
44993
44994
44995
44996 func (c *ReportsFilesGetCall) Do(opts ...googleapi.CallOption) (*File, error) {
44997 gensupport.SetOptions(c.urlParams_, opts...)
44998 res, err := c.doRequest("json")
44999 if res != nil && res.StatusCode == http.StatusNotModified {
45000 if res.Body != nil {
45001 res.Body.Close()
45002 }
45003 return nil, &googleapi.Error{
45004 Code: res.StatusCode,
45005 Header: res.Header,
45006 }
45007 }
45008 if err != nil {
45009 return nil, err
45010 }
45011 defer googleapi.CloseBody(res)
45012 if err := googleapi.CheckResponse(res); err != nil {
45013 return nil, err
45014 }
45015 ret := &File{
45016 ServerResponse: googleapi.ServerResponse{
45017 Header: res.Header,
45018 HTTPStatusCode: res.StatusCode,
45019 },
45020 }
45021 target := &ret
45022 if err := gensupport.DecodeResponse(target, res); err != nil {
45023 return nil, err
45024 }
45025 return ret, nil
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
45064
45065
45066
45067
45068 }
45069
45070
45071
45072 type ReportsFilesListCall struct {
45073 s *Service
45074 profileId int64
45075 reportId int64
45076 urlParams_ gensupport.URLParams
45077 ifNoneMatch_ string
45078 ctx_ context.Context
45079 header_ http.Header
45080 }
45081
45082
45083 func (r *ReportsFilesService) List(profileId int64, reportId int64) *ReportsFilesListCall {
45084 c := &ReportsFilesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
45085 c.profileId = profileId
45086 c.reportId = reportId
45087 return c
45088 }
45089
45090
45091
45092 func (c *ReportsFilesListCall) MaxResults(maxResults int64) *ReportsFilesListCall {
45093 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
45094 return c
45095 }
45096
45097
45098
45099 func (c *ReportsFilesListCall) PageToken(pageToken string) *ReportsFilesListCall {
45100 c.urlParams_.Set("pageToken", pageToken)
45101 return c
45102 }
45103
45104
45105
45106
45107
45108
45109
45110
45111 func (c *ReportsFilesListCall) SortField(sortField string) *ReportsFilesListCall {
45112 c.urlParams_.Set("sortField", sortField)
45113 return c
45114 }
45115
45116
45117
45118
45119
45120
45121
45122
45123 func (c *ReportsFilesListCall) SortOrder(sortOrder string) *ReportsFilesListCall {
45124 c.urlParams_.Set("sortOrder", sortOrder)
45125 return c
45126 }
45127
45128
45129
45130
45131 func (c *ReportsFilesListCall) Fields(s ...googleapi.Field) *ReportsFilesListCall {
45132 c.urlParams_.Set("fields", googleapi.CombineFields(s))
45133 return c
45134 }
45135
45136
45137
45138
45139
45140
45141 func (c *ReportsFilesListCall) IfNoneMatch(entityTag string) *ReportsFilesListCall {
45142 c.ifNoneMatch_ = entityTag
45143 return c
45144 }
45145
45146
45147
45148
45149 func (c *ReportsFilesListCall) Context(ctx context.Context) *ReportsFilesListCall {
45150 c.ctx_ = ctx
45151 return c
45152 }
45153
45154
45155
45156 func (c *ReportsFilesListCall) Header() http.Header {
45157 if c.header_ == nil {
45158 c.header_ = make(http.Header)
45159 }
45160 return c.header_
45161 }
45162
45163 func (c *ReportsFilesListCall) doRequest(alt string) (*http.Response, error) {
45164 reqHeaders := make(http.Header)
45165 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
45166 for k, v := range c.header_ {
45167 reqHeaders[k] = v
45168 }
45169 reqHeaders.Set("User-Agent", c.s.userAgent())
45170 if c.ifNoneMatch_ != "" {
45171 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
45172 }
45173 var body io.Reader = nil
45174 c.urlParams_.Set("alt", alt)
45175 c.urlParams_.Set("prettyPrint", "false")
45176 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/reports/{reportId}/files")
45177 urls += "?" + c.urlParams_.Encode()
45178 req, err := http.NewRequest("GET", urls, body)
45179 if err != nil {
45180 return nil, err
45181 }
45182 req.Header = reqHeaders
45183 googleapi.Expand(req.URL, map[string]string{
45184 "profileId": strconv.FormatInt(c.profileId, 10),
45185 "reportId": strconv.FormatInt(c.reportId, 10),
45186 })
45187 return gensupport.SendRequest(c.ctx_, c.s.client, req)
45188 }
45189
45190
45191
45192
45193
45194
45195
45196
45197 func (c *ReportsFilesListCall) Do(opts ...googleapi.CallOption) (*FileList, error) {
45198 gensupport.SetOptions(c.urlParams_, opts...)
45199 res, err := c.doRequest("json")
45200 if res != nil && res.StatusCode == http.StatusNotModified {
45201 if res.Body != nil {
45202 res.Body.Close()
45203 }
45204 return nil, &googleapi.Error{
45205 Code: res.StatusCode,
45206 Header: res.Header,
45207 }
45208 }
45209 if err != nil {
45210 return nil, err
45211 }
45212 defer googleapi.CloseBody(res)
45213 if err := googleapi.CheckResponse(res); err != nil {
45214 return nil, err
45215 }
45216 ret := &FileList{
45217 ServerResponse: googleapi.ServerResponse{
45218 Header: res.Header,
45219 HTTPStatusCode: res.StatusCode,
45220 },
45221 }
45222 target := &ret
45223 if err := gensupport.DecodeResponse(target, res); err != nil {
45224 return nil, err
45225 }
45226 return ret, nil
45227
45228
45229
45230
45231
45232
45233
45234
45235
45236
45237
45238
45239
45240
45241
45242
45243
45244
45245
45246
45247
45248
45249
45250
45251
45252
45253
45254
45255
45256
45257
45258
45259
45260
45261
45262
45263
45264
45265
45266
45267
45268
45269
45270
45271
45272
45273
45274
45275
45276
45277
45278
45279
45280
45281
45282
45283
45284
45285
45286
45287
45288
45289
45290
45291
45292
45293
45294
45295
45296
45297
45298
45299
45300
45301
45302 }
45303
45304
45305
45306
45307 func (c *ReportsFilesListCall) Pages(ctx context.Context, f func(*FileList) error) error {
45308 c.ctx_ = ctx
45309 defer c.PageToken(c.urlParams_.Get("pageToken"))
45310 for {
45311 x, err := c.Do()
45312 if err != nil {
45313 return err
45314 }
45315 if err := f(x); err != nil {
45316 return err
45317 }
45318 if x.NextPageToken == "" {
45319 return nil
45320 }
45321 c.PageToken(x.NextPageToken)
45322 }
45323 }
45324
45325
45326
45327 type SitesGetCall struct {
45328 s *Service
45329 profileId int64
45330 id int64
45331 urlParams_ gensupport.URLParams
45332 ifNoneMatch_ string
45333 ctx_ context.Context
45334 header_ http.Header
45335 }
45336
45337
45338 func (r *SitesService) Get(profileId int64, id int64) *SitesGetCall {
45339 c := &SitesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
45340 c.profileId = profileId
45341 c.id = id
45342 return c
45343 }
45344
45345
45346
45347
45348 func (c *SitesGetCall) Fields(s ...googleapi.Field) *SitesGetCall {
45349 c.urlParams_.Set("fields", googleapi.CombineFields(s))
45350 return c
45351 }
45352
45353
45354
45355
45356
45357
45358 func (c *SitesGetCall) IfNoneMatch(entityTag string) *SitesGetCall {
45359 c.ifNoneMatch_ = entityTag
45360 return c
45361 }
45362
45363
45364
45365
45366 func (c *SitesGetCall) Context(ctx context.Context) *SitesGetCall {
45367 c.ctx_ = ctx
45368 return c
45369 }
45370
45371
45372
45373 func (c *SitesGetCall) Header() http.Header {
45374 if c.header_ == nil {
45375 c.header_ = make(http.Header)
45376 }
45377 return c.header_
45378 }
45379
45380 func (c *SitesGetCall) doRequest(alt string) (*http.Response, error) {
45381 reqHeaders := make(http.Header)
45382 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
45383 for k, v := range c.header_ {
45384 reqHeaders[k] = v
45385 }
45386 reqHeaders.Set("User-Agent", c.s.userAgent())
45387 if c.ifNoneMatch_ != "" {
45388 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
45389 }
45390 var body io.Reader = nil
45391 c.urlParams_.Set("alt", alt)
45392 c.urlParams_.Set("prettyPrint", "false")
45393 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/sites/{id}")
45394 urls += "?" + c.urlParams_.Encode()
45395 req, err := http.NewRequest("GET", urls, body)
45396 if err != nil {
45397 return nil, err
45398 }
45399 req.Header = reqHeaders
45400 googleapi.Expand(req.URL, map[string]string{
45401 "profileId": strconv.FormatInt(c.profileId, 10),
45402 "id": strconv.FormatInt(c.id, 10),
45403 })
45404 return gensupport.SendRequest(c.ctx_, c.s.client, req)
45405 }
45406
45407
45408
45409
45410
45411
45412
45413
45414 func (c *SitesGetCall) Do(opts ...googleapi.CallOption) (*Site, error) {
45415 gensupport.SetOptions(c.urlParams_, opts...)
45416 res, err := c.doRequest("json")
45417 if res != nil && res.StatusCode == http.StatusNotModified {
45418 if res.Body != nil {
45419 res.Body.Close()
45420 }
45421 return nil, &googleapi.Error{
45422 Code: res.StatusCode,
45423 Header: res.Header,
45424 }
45425 }
45426 if err != nil {
45427 return nil, err
45428 }
45429 defer googleapi.CloseBody(res)
45430 if err := googleapi.CheckResponse(res); err != nil {
45431 return nil, err
45432 }
45433 ret := &Site{
45434 ServerResponse: googleapi.ServerResponse{
45435 Header: res.Header,
45436 HTTPStatusCode: res.StatusCode,
45437 },
45438 }
45439 target := &ret
45440 if err := gensupport.DecodeResponse(target, res); err != nil {
45441 return nil, err
45442 }
45443 return ret, nil
45444
45445
45446
45447
45448
45449
45450
45451
45452
45453
45454
45455
45456
45457
45458
45459
45460
45461
45462
45463
45464
45465
45466
45467
45468
45469
45470
45471
45472
45473
45474
45475
45476
45477 }
45478
45479
45480
45481 type SitesInsertCall struct {
45482 s *Service
45483 profileId int64
45484 site *Site
45485 urlParams_ gensupport.URLParams
45486 ctx_ context.Context
45487 header_ http.Header
45488 }
45489
45490
45491 func (r *SitesService) Insert(profileId int64, site *Site) *SitesInsertCall {
45492 c := &SitesInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
45493 c.profileId = profileId
45494 c.site = site
45495 return c
45496 }
45497
45498
45499
45500
45501 func (c *SitesInsertCall) Fields(s ...googleapi.Field) *SitesInsertCall {
45502 c.urlParams_.Set("fields", googleapi.CombineFields(s))
45503 return c
45504 }
45505
45506
45507
45508
45509 func (c *SitesInsertCall) Context(ctx context.Context) *SitesInsertCall {
45510 c.ctx_ = ctx
45511 return c
45512 }
45513
45514
45515
45516 func (c *SitesInsertCall) Header() http.Header {
45517 if c.header_ == nil {
45518 c.header_ = make(http.Header)
45519 }
45520 return c.header_
45521 }
45522
45523 func (c *SitesInsertCall) doRequest(alt string) (*http.Response, error) {
45524 reqHeaders := make(http.Header)
45525 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
45526 for k, v := range c.header_ {
45527 reqHeaders[k] = v
45528 }
45529 reqHeaders.Set("User-Agent", c.s.userAgent())
45530 var body io.Reader = nil
45531 body, err := googleapi.WithoutDataWrapper.JSONReader(c.site)
45532 if err != nil {
45533 return nil, err
45534 }
45535 reqHeaders.Set("Content-Type", "application/json")
45536 c.urlParams_.Set("alt", alt)
45537 c.urlParams_.Set("prettyPrint", "false")
45538 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/sites")
45539 urls += "?" + c.urlParams_.Encode()
45540 req, err := http.NewRequest("POST", urls, body)
45541 if err != nil {
45542 return nil, err
45543 }
45544 req.Header = reqHeaders
45545 googleapi.Expand(req.URL, map[string]string{
45546 "profileId": strconv.FormatInt(c.profileId, 10),
45547 })
45548 return gensupport.SendRequest(c.ctx_, c.s.client, req)
45549 }
45550
45551
45552
45553
45554
45555
45556
45557
45558 func (c *SitesInsertCall) Do(opts ...googleapi.CallOption) (*Site, error) {
45559 gensupport.SetOptions(c.urlParams_, opts...)
45560 res, err := c.doRequest("json")
45561 if res != nil && res.StatusCode == http.StatusNotModified {
45562 if res.Body != nil {
45563 res.Body.Close()
45564 }
45565 return nil, &googleapi.Error{
45566 Code: res.StatusCode,
45567 Header: res.Header,
45568 }
45569 }
45570 if err != nil {
45571 return nil, err
45572 }
45573 defer googleapi.CloseBody(res)
45574 if err := googleapi.CheckResponse(res); err != nil {
45575 return nil, err
45576 }
45577 ret := &Site{
45578 ServerResponse: googleapi.ServerResponse{
45579 Header: res.Header,
45580 HTTPStatusCode: res.StatusCode,
45581 },
45582 }
45583 target := &ret
45584 if err := gensupport.DecodeResponse(target, res); err != nil {
45585 return nil, err
45586 }
45587 return ret, nil
45588
45589
45590
45591
45592
45593
45594
45595
45596
45597
45598
45599
45600
45601
45602
45603
45604
45605
45606
45607
45608
45609
45610
45611
45612
45613
45614
45615
45616 }
45617
45618
45619
45620 type SitesListCall struct {
45621 s *Service
45622 profileId int64
45623 urlParams_ gensupport.URLParams
45624 ifNoneMatch_ string
45625 ctx_ context.Context
45626 header_ http.Header
45627 }
45628
45629
45630
45631 func (r *SitesService) List(profileId int64) *SitesListCall {
45632 c := &SitesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
45633 c.profileId = profileId
45634 return c
45635 }
45636
45637
45638
45639
45640 func (c *SitesListCall) AcceptsInStreamVideoPlacements(acceptsInStreamVideoPlacements bool) *SitesListCall {
45641 c.urlParams_.Set("acceptsInStreamVideoPlacements", fmt.Sprint(acceptsInStreamVideoPlacements))
45642 return c
45643 }
45644
45645
45646
45647
45648 func (c *SitesListCall) AcceptsInterstitialPlacements(acceptsInterstitialPlacements bool) *SitesListCall {
45649 c.urlParams_.Set("acceptsInterstitialPlacements", fmt.Sprint(acceptsInterstitialPlacements))
45650 return c
45651 }
45652
45653
45654
45655
45656 func (c *SitesListCall) AcceptsPublisherPaidPlacements(acceptsPublisherPaidPlacements bool) *SitesListCall {
45657 c.urlParams_.Set("acceptsPublisherPaidPlacements", fmt.Sprint(acceptsPublisherPaidPlacements))
45658 return c
45659 }
45660
45661
45662
45663 func (c *SitesListCall) AdWordsSite(adWordsSite bool) *SitesListCall {
45664 c.urlParams_.Set("adWordsSite", fmt.Sprint(adWordsSite))
45665 return c
45666 }
45667
45668
45669
45670 func (c *SitesListCall) Approved(approved bool) *SitesListCall {
45671 c.urlParams_.Set("approved", fmt.Sprint(approved))
45672 return c
45673 }
45674
45675
45676
45677 func (c *SitesListCall) CampaignIds(campaignIds ...int64) *SitesListCall {
45678 var campaignIds_ []string
45679 for _, v := range campaignIds {
45680 campaignIds_ = append(campaignIds_, fmt.Sprint(v))
45681 }
45682 c.urlParams_.SetMulti("campaignIds", campaignIds_)
45683 return c
45684 }
45685
45686
45687
45688 func (c *SitesListCall) DirectorySiteIds(directorySiteIds ...int64) *SitesListCall {
45689 var directorySiteIds_ []string
45690 for _, v := range directorySiteIds {
45691 directorySiteIds_ = append(directorySiteIds_, fmt.Sprint(v))
45692 }
45693 c.urlParams_.SetMulti("directorySiteIds", directorySiteIds_)
45694 return c
45695 }
45696
45697
45698
45699 func (c *SitesListCall) Ids(ids ...int64) *SitesListCall {
45700 var ids_ []string
45701 for _, v := range ids {
45702 ids_ = append(ids_, fmt.Sprint(v))
45703 }
45704 c.urlParams_.SetMulti("ids", ids_)
45705 return c
45706 }
45707
45708
45709
45710 func (c *SitesListCall) MaxResults(maxResults int64) *SitesListCall {
45711 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
45712 return c
45713 }
45714
45715
45716
45717 func (c *SitesListCall) PageToken(pageToken string) *SitesListCall {
45718 c.urlParams_.Set("pageToken", pageToken)
45719 return c
45720 }
45721
45722
45723
45724
45725
45726
45727
45728
45729 func (c *SitesListCall) SearchString(searchString string) *SitesListCall {
45730 c.urlParams_.Set("searchString", searchString)
45731 return c
45732 }
45733
45734
45735
45736
45737
45738
45739
45740
45741 func (c *SitesListCall) SortField(sortField string) *SitesListCall {
45742 c.urlParams_.Set("sortField", sortField)
45743 return c
45744 }
45745
45746
45747
45748
45749
45750
45751
45752
45753 func (c *SitesListCall) SortOrder(sortOrder string) *SitesListCall {
45754 c.urlParams_.Set("sortOrder", sortOrder)
45755 return c
45756 }
45757
45758
45759
45760 func (c *SitesListCall) SubaccountId(subaccountId int64) *SitesListCall {
45761 c.urlParams_.Set("subaccountId", fmt.Sprint(subaccountId))
45762 return c
45763 }
45764
45765
45766
45767 func (c *SitesListCall) UnmappedSite(unmappedSite bool) *SitesListCall {
45768 c.urlParams_.Set("unmappedSite", fmt.Sprint(unmappedSite))
45769 return c
45770 }
45771
45772
45773
45774
45775 func (c *SitesListCall) Fields(s ...googleapi.Field) *SitesListCall {
45776 c.urlParams_.Set("fields", googleapi.CombineFields(s))
45777 return c
45778 }
45779
45780
45781
45782
45783
45784
45785 func (c *SitesListCall) IfNoneMatch(entityTag string) *SitesListCall {
45786 c.ifNoneMatch_ = entityTag
45787 return c
45788 }
45789
45790
45791
45792
45793 func (c *SitesListCall) Context(ctx context.Context) *SitesListCall {
45794 c.ctx_ = ctx
45795 return c
45796 }
45797
45798
45799
45800 func (c *SitesListCall) Header() http.Header {
45801 if c.header_ == nil {
45802 c.header_ = make(http.Header)
45803 }
45804 return c.header_
45805 }
45806
45807 func (c *SitesListCall) doRequest(alt string) (*http.Response, error) {
45808 reqHeaders := make(http.Header)
45809 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
45810 for k, v := range c.header_ {
45811 reqHeaders[k] = v
45812 }
45813 reqHeaders.Set("User-Agent", c.s.userAgent())
45814 if c.ifNoneMatch_ != "" {
45815 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
45816 }
45817 var body io.Reader = nil
45818 c.urlParams_.Set("alt", alt)
45819 c.urlParams_.Set("prettyPrint", "false")
45820 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/sites")
45821 urls += "?" + c.urlParams_.Encode()
45822 req, err := http.NewRequest("GET", urls, body)
45823 if err != nil {
45824 return nil, err
45825 }
45826 req.Header = reqHeaders
45827 googleapi.Expand(req.URL, map[string]string{
45828 "profileId": strconv.FormatInt(c.profileId, 10),
45829 })
45830 return gensupport.SendRequest(c.ctx_, c.s.client, req)
45831 }
45832
45833
45834
45835
45836
45837
45838
45839
45840 func (c *SitesListCall) Do(opts ...googleapi.CallOption) (*SitesListResponse, error) {
45841 gensupport.SetOptions(c.urlParams_, opts...)
45842 res, err := c.doRequest("json")
45843 if res != nil && res.StatusCode == http.StatusNotModified {
45844 if res.Body != nil {
45845 res.Body.Close()
45846 }
45847 return nil, &googleapi.Error{
45848 Code: res.StatusCode,
45849 Header: res.Header,
45850 }
45851 }
45852 if err != nil {
45853 return nil, err
45854 }
45855 defer googleapi.CloseBody(res)
45856 if err := googleapi.CheckResponse(res); err != nil {
45857 return nil, err
45858 }
45859 ret := &SitesListResponse{
45860 ServerResponse: googleapi.ServerResponse{
45861 Header: res.Header,
45862 HTTPStatusCode: res.StatusCode,
45863 },
45864 }
45865 target := &ret
45866 if err := gensupport.DecodeResponse(target, res); err != nil {
45867 return nil, err
45868 }
45869 return ret, nil
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
45925
45926
45927
45928
45929
45930
45931
45932
45933
45934
45935
45936
45937
45938
45939
45940
45941
45942
45943
45944
45945
45946
45947
45948
45949
45950
45951
45952
45953
45954
45955
45956
45957
45958
45959
45960
45961
45962
45963
45964
45965
45966
45967
45968
45969
45970
45971
45972
45973
45974
45975
45976
45977
45978
45979
45980
45981
45982
45983
45984
45985
45986
45987
45988
45989
45990
45991
45992
45993
45994
45995
45996
45997
45998
45999 }
46000
46001
46002
46003
46004 func (c *SitesListCall) Pages(ctx context.Context, f func(*SitesListResponse) error) error {
46005 c.ctx_ = ctx
46006 defer c.PageToken(c.urlParams_.Get("pageToken"))
46007 for {
46008 x, err := c.Do()
46009 if err != nil {
46010 return err
46011 }
46012 if err := f(x); err != nil {
46013 return err
46014 }
46015 if x.NextPageToken == "" {
46016 return nil
46017 }
46018 c.PageToken(x.NextPageToken)
46019 }
46020 }
46021
46022
46023
46024 type SitesPatchCall struct {
46025 s *Service
46026 profileId int64
46027 site *Site
46028 urlParams_ gensupport.URLParams
46029 ctx_ context.Context
46030 header_ http.Header
46031 }
46032
46033
46034
46035 func (r *SitesService) Patch(profileId int64, id int64, site *Site) *SitesPatchCall {
46036 c := &SitesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
46037 c.profileId = profileId
46038 c.urlParams_.Set("id", fmt.Sprint(id))
46039 c.site = site
46040 return c
46041 }
46042
46043
46044
46045
46046 func (c *SitesPatchCall) Fields(s ...googleapi.Field) *SitesPatchCall {
46047 c.urlParams_.Set("fields", googleapi.CombineFields(s))
46048 return c
46049 }
46050
46051
46052
46053
46054 func (c *SitesPatchCall) Context(ctx context.Context) *SitesPatchCall {
46055 c.ctx_ = ctx
46056 return c
46057 }
46058
46059
46060
46061 func (c *SitesPatchCall) Header() http.Header {
46062 if c.header_ == nil {
46063 c.header_ = make(http.Header)
46064 }
46065 return c.header_
46066 }
46067
46068 func (c *SitesPatchCall) doRequest(alt string) (*http.Response, error) {
46069 reqHeaders := make(http.Header)
46070 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
46071 for k, v := range c.header_ {
46072 reqHeaders[k] = v
46073 }
46074 reqHeaders.Set("User-Agent", c.s.userAgent())
46075 var body io.Reader = nil
46076 body, err := googleapi.WithoutDataWrapper.JSONReader(c.site)
46077 if err != nil {
46078 return nil, err
46079 }
46080 reqHeaders.Set("Content-Type", "application/json")
46081 c.urlParams_.Set("alt", alt)
46082 c.urlParams_.Set("prettyPrint", "false")
46083 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/sites")
46084 urls += "?" + c.urlParams_.Encode()
46085 req, err := http.NewRequest("PATCH", urls, body)
46086 if err != nil {
46087 return nil, err
46088 }
46089 req.Header = reqHeaders
46090 googleapi.Expand(req.URL, map[string]string{
46091 "profileId": strconv.FormatInt(c.profileId, 10),
46092 })
46093 return gensupport.SendRequest(c.ctx_, c.s.client, req)
46094 }
46095
46096
46097
46098
46099
46100
46101
46102
46103 func (c *SitesPatchCall) Do(opts ...googleapi.CallOption) (*Site, error) {
46104 gensupport.SetOptions(c.urlParams_, opts...)
46105 res, err := c.doRequest("json")
46106 if res != nil && res.StatusCode == http.StatusNotModified {
46107 if res.Body != nil {
46108 res.Body.Close()
46109 }
46110 return nil, &googleapi.Error{
46111 Code: res.StatusCode,
46112 Header: res.Header,
46113 }
46114 }
46115 if err != nil {
46116 return nil, err
46117 }
46118 defer googleapi.CloseBody(res)
46119 if err := googleapi.CheckResponse(res); err != nil {
46120 return nil, err
46121 }
46122 ret := &Site{
46123 ServerResponse: googleapi.ServerResponse{
46124 Header: res.Header,
46125 HTTPStatusCode: res.StatusCode,
46126 },
46127 }
46128 target := &ret
46129 if err := gensupport.DecodeResponse(target, res); err != nil {
46130 return nil, err
46131 }
46132 return ret, nil
46133
46134
46135
46136
46137
46138
46139
46140
46141
46142
46143
46144
46145
46146
46147
46148
46149
46150
46151
46152
46153
46154
46155
46156
46157
46158
46159
46160
46161
46162
46163
46164
46165
46166
46167
46168
46169 }
46170
46171
46172
46173 type SitesUpdateCall struct {
46174 s *Service
46175 profileId int64
46176 site *Site
46177 urlParams_ gensupport.URLParams
46178 ctx_ context.Context
46179 header_ http.Header
46180 }
46181
46182
46183 func (r *SitesService) Update(profileId int64, site *Site) *SitesUpdateCall {
46184 c := &SitesUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
46185 c.profileId = profileId
46186 c.site = site
46187 return c
46188 }
46189
46190
46191
46192
46193 func (c *SitesUpdateCall) Fields(s ...googleapi.Field) *SitesUpdateCall {
46194 c.urlParams_.Set("fields", googleapi.CombineFields(s))
46195 return c
46196 }
46197
46198
46199
46200
46201 func (c *SitesUpdateCall) Context(ctx context.Context) *SitesUpdateCall {
46202 c.ctx_ = ctx
46203 return c
46204 }
46205
46206
46207
46208 func (c *SitesUpdateCall) Header() http.Header {
46209 if c.header_ == nil {
46210 c.header_ = make(http.Header)
46211 }
46212 return c.header_
46213 }
46214
46215 func (c *SitesUpdateCall) doRequest(alt string) (*http.Response, error) {
46216 reqHeaders := make(http.Header)
46217 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
46218 for k, v := range c.header_ {
46219 reqHeaders[k] = v
46220 }
46221 reqHeaders.Set("User-Agent", c.s.userAgent())
46222 var body io.Reader = nil
46223 body, err := googleapi.WithoutDataWrapper.JSONReader(c.site)
46224 if err != nil {
46225 return nil, err
46226 }
46227 reqHeaders.Set("Content-Type", "application/json")
46228 c.urlParams_.Set("alt", alt)
46229 c.urlParams_.Set("prettyPrint", "false")
46230 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/sites")
46231 urls += "?" + c.urlParams_.Encode()
46232 req, err := http.NewRequest("PUT", urls, body)
46233 if err != nil {
46234 return nil, err
46235 }
46236 req.Header = reqHeaders
46237 googleapi.Expand(req.URL, map[string]string{
46238 "profileId": strconv.FormatInt(c.profileId, 10),
46239 })
46240 return gensupport.SendRequest(c.ctx_, c.s.client, req)
46241 }
46242
46243
46244
46245
46246
46247
46248
46249
46250 func (c *SitesUpdateCall) Do(opts ...googleapi.CallOption) (*Site, error) {
46251 gensupport.SetOptions(c.urlParams_, opts...)
46252 res, err := c.doRequest("json")
46253 if res != nil && res.StatusCode == http.StatusNotModified {
46254 if res.Body != nil {
46255 res.Body.Close()
46256 }
46257 return nil, &googleapi.Error{
46258 Code: res.StatusCode,
46259 Header: res.Header,
46260 }
46261 }
46262 if err != nil {
46263 return nil, err
46264 }
46265 defer googleapi.CloseBody(res)
46266 if err := googleapi.CheckResponse(res); err != nil {
46267 return nil, err
46268 }
46269 ret := &Site{
46270 ServerResponse: googleapi.ServerResponse{
46271 Header: res.Header,
46272 HTTPStatusCode: res.StatusCode,
46273 },
46274 }
46275 target := &ret
46276 if err := gensupport.DecodeResponse(target, res); err != nil {
46277 return nil, err
46278 }
46279 return ret, nil
46280
46281
46282
46283
46284
46285
46286
46287
46288
46289
46290
46291
46292
46293
46294
46295
46296
46297
46298
46299
46300
46301
46302
46303
46304
46305
46306
46307
46308 }
46309
46310
46311
46312 type SizesGetCall struct {
46313 s *Service
46314 profileId int64
46315 id int64
46316 urlParams_ gensupport.URLParams
46317 ifNoneMatch_ string
46318 ctx_ context.Context
46319 header_ http.Header
46320 }
46321
46322
46323 func (r *SizesService) Get(profileId int64, id int64) *SizesGetCall {
46324 c := &SizesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
46325 c.profileId = profileId
46326 c.id = id
46327 return c
46328 }
46329
46330
46331
46332
46333 func (c *SizesGetCall) Fields(s ...googleapi.Field) *SizesGetCall {
46334 c.urlParams_.Set("fields", googleapi.CombineFields(s))
46335 return c
46336 }
46337
46338
46339
46340
46341
46342
46343 func (c *SizesGetCall) IfNoneMatch(entityTag string) *SizesGetCall {
46344 c.ifNoneMatch_ = entityTag
46345 return c
46346 }
46347
46348
46349
46350
46351 func (c *SizesGetCall) Context(ctx context.Context) *SizesGetCall {
46352 c.ctx_ = ctx
46353 return c
46354 }
46355
46356
46357
46358 func (c *SizesGetCall) Header() http.Header {
46359 if c.header_ == nil {
46360 c.header_ = make(http.Header)
46361 }
46362 return c.header_
46363 }
46364
46365 func (c *SizesGetCall) doRequest(alt string) (*http.Response, error) {
46366 reqHeaders := make(http.Header)
46367 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
46368 for k, v := range c.header_ {
46369 reqHeaders[k] = v
46370 }
46371 reqHeaders.Set("User-Agent", c.s.userAgent())
46372 if c.ifNoneMatch_ != "" {
46373 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
46374 }
46375 var body io.Reader = nil
46376 c.urlParams_.Set("alt", alt)
46377 c.urlParams_.Set("prettyPrint", "false")
46378 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/sizes/{id}")
46379 urls += "?" + c.urlParams_.Encode()
46380 req, err := http.NewRequest("GET", urls, body)
46381 if err != nil {
46382 return nil, err
46383 }
46384 req.Header = reqHeaders
46385 googleapi.Expand(req.URL, map[string]string{
46386 "profileId": strconv.FormatInt(c.profileId, 10),
46387 "id": strconv.FormatInt(c.id, 10),
46388 })
46389 return gensupport.SendRequest(c.ctx_, c.s.client, req)
46390 }
46391
46392
46393
46394
46395
46396
46397
46398
46399 func (c *SizesGetCall) Do(opts ...googleapi.CallOption) (*Size, error) {
46400 gensupport.SetOptions(c.urlParams_, opts...)
46401 res, err := c.doRequest("json")
46402 if res != nil && res.StatusCode == http.StatusNotModified {
46403 if res.Body != nil {
46404 res.Body.Close()
46405 }
46406 return nil, &googleapi.Error{
46407 Code: res.StatusCode,
46408 Header: res.Header,
46409 }
46410 }
46411 if err != nil {
46412 return nil, err
46413 }
46414 defer googleapi.CloseBody(res)
46415 if err := googleapi.CheckResponse(res); err != nil {
46416 return nil, err
46417 }
46418 ret := &Size{
46419 ServerResponse: googleapi.ServerResponse{
46420 Header: res.Header,
46421 HTTPStatusCode: res.StatusCode,
46422 },
46423 }
46424 target := &ret
46425 if err := gensupport.DecodeResponse(target, res); err != nil {
46426 return nil, err
46427 }
46428 return ret, nil
46429
46430
46431
46432
46433
46434
46435
46436
46437
46438
46439
46440
46441
46442
46443
46444
46445
46446
46447
46448
46449
46450
46451
46452
46453
46454
46455
46456
46457
46458
46459
46460
46461
46462 }
46463
46464
46465
46466 type SizesInsertCall struct {
46467 s *Service
46468 profileId int64
46469 size *Size
46470 urlParams_ gensupport.URLParams
46471 ctx_ context.Context
46472 header_ http.Header
46473 }
46474
46475
46476 func (r *SizesService) Insert(profileId int64, size *Size) *SizesInsertCall {
46477 c := &SizesInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
46478 c.profileId = profileId
46479 c.size = size
46480 return c
46481 }
46482
46483
46484
46485
46486 func (c *SizesInsertCall) Fields(s ...googleapi.Field) *SizesInsertCall {
46487 c.urlParams_.Set("fields", googleapi.CombineFields(s))
46488 return c
46489 }
46490
46491
46492
46493
46494 func (c *SizesInsertCall) Context(ctx context.Context) *SizesInsertCall {
46495 c.ctx_ = ctx
46496 return c
46497 }
46498
46499
46500
46501 func (c *SizesInsertCall) Header() http.Header {
46502 if c.header_ == nil {
46503 c.header_ = make(http.Header)
46504 }
46505 return c.header_
46506 }
46507
46508 func (c *SizesInsertCall) doRequest(alt string) (*http.Response, error) {
46509 reqHeaders := make(http.Header)
46510 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
46511 for k, v := range c.header_ {
46512 reqHeaders[k] = v
46513 }
46514 reqHeaders.Set("User-Agent", c.s.userAgent())
46515 var body io.Reader = nil
46516 body, err := googleapi.WithoutDataWrapper.JSONReader(c.size)
46517 if err != nil {
46518 return nil, err
46519 }
46520 reqHeaders.Set("Content-Type", "application/json")
46521 c.urlParams_.Set("alt", alt)
46522 c.urlParams_.Set("prettyPrint", "false")
46523 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/sizes")
46524 urls += "?" + c.urlParams_.Encode()
46525 req, err := http.NewRequest("POST", urls, body)
46526 if err != nil {
46527 return nil, err
46528 }
46529 req.Header = reqHeaders
46530 googleapi.Expand(req.URL, map[string]string{
46531 "profileId": strconv.FormatInt(c.profileId, 10),
46532 })
46533 return gensupport.SendRequest(c.ctx_, c.s.client, req)
46534 }
46535
46536
46537
46538
46539
46540
46541
46542
46543 func (c *SizesInsertCall) Do(opts ...googleapi.CallOption) (*Size, error) {
46544 gensupport.SetOptions(c.urlParams_, opts...)
46545 res, err := c.doRequest("json")
46546 if res != nil && res.StatusCode == http.StatusNotModified {
46547 if res.Body != nil {
46548 res.Body.Close()
46549 }
46550 return nil, &googleapi.Error{
46551 Code: res.StatusCode,
46552 Header: res.Header,
46553 }
46554 }
46555 if err != nil {
46556 return nil, err
46557 }
46558 defer googleapi.CloseBody(res)
46559 if err := googleapi.CheckResponse(res); err != nil {
46560 return nil, err
46561 }
46562 ret := &Size{
46563 ServerResponse: googleapi.ServerResponse{
46564 Header: res.Header,
46565 HTTPStatusCode: res.StatusCode,
46566 },
46567 }
46568 target := &ret
46569 if err := gensupport.DecodeResponse(target, res); err != nil {
46570 return nil, err
46571 }
46572 return ret, nil
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 type SizesListCall struct {
46606 s *Service
46607 profileId int64
46608 urlParams_ gensupport.URLParams
46609 ifNoneMatch_ string
46610 ctx_ context.Context
46611 header_ http.Header
46612 }
46613
46614
46615
46616
46617
46618 func (r *SizesService) List(profileId int64) *SizesListCall {
46619 c := &SizesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
46620 c.profileId = profileId
46621 return c
46622 }
46623
46624
46625
46626 func (c *SizesListCall) Height(height int64) *SizesListCall {
46627 c.urlParams_.Set("height", fmt.Sprint(height))
46628 return c
46629 }
46630
46631
46632
46633 func (c *SizesListCall) IabStandard(iabStandard bool) *SizesListCall {
46634 c.urlParams_.Set("iabStandard", fmt.Sprint(iabStandard))
46635 return c
46636 }
46637
46638
46639
46640 func (c *SizesListCall) Ids(ids ...int64) *SizesListCall {
46641 var ids_ []string
46642 for _, v := range ids {
46643 ids_ = append(ids_, fmt.Sprint(v))
46644 }
46645 c.urlParams_.SetMulti("ids", ids_)
46646 return c
46647 }
46648
46649
46650
46651 func (c *SizesListCall) Width(width int64) *SizesListCall {
46652 c.urlParams_.Set("width", fmt.Sprint(width))
46653 return c
46654 }
46655
46656
46657
46658
46659 func (c *SizesListCall) Fields(s ...googleapi.Field) *SizesListCall {
46660 c.urlParams_.Set("fields", googleapi.CombineFields(s))
46661 return c
46662 }
46663
46664
46665
46666
46667
46668
46669 func (c *SizesListCall) IfNoneMatch(entityTag string) *SizesListCall {
46670 c.ifNoneMatch_ = entityTag
46671 return c
46672 }
46673
46674
46675
46676
46677 func (c *SizesListCall) Context(ctx context.Context) *SizesListCall {
46678 c.ctx_ = ctx
46679 return c
46680 }
46681
46682
46683
46684 func (c *SizesListCall) Header() http.Header {
46685 if c.header_ == nil {
46686 c.header_ = make(http.Header)
46687 }
46688 return c.header_
46689 }
46690
46691 func (c *SizesListCall) doRequest(alt string) (*http.Response, error) {
46692 reqHeaders := make(http.Header)
46693 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
46694 for k, v := range c.header_ {
46695 reqHeaders[k] = v
46696 }
46697 reqHeaders.Set("User-Agent", c.s.userAgent())
46698 if c.ifNoneMatch_ != "" {
46699 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
46700 }
46701 var body io.Reader = nil
46702 c.urlParams_.Set("alt", alt)
46703 c.urlParams_.Set("prettyPrint", "false")
46704 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/sizes")
46705 urls += "?" + c.urlParams_.Encode()
46706 req, err := http.NewRequest("GET", urls, body)
46707 if err != nil {
46708 return nil, err
46709 }
46710 req.Header = reqHeaders
46711 googleapi.Expand(req.URL, map[string]string{
46712 "profileId": strconv.FormatInt(c.profileId, 10),
46713 })
46714 return gensupport.SendRequest(c.ctx_, c.s.client, req)
46715 }
46716
46717
46718
46719
46720
46721
46722
46723
46724 func (c *SizesListCall) Do(opts ...googleapi.CallOption) (*SizesListResponse, error) {
46725 gensupport.SetOptions(c.urlParams_, opts...)
46726 res, err := c.doRequest("json")
46727 if res != nil && res.StatusCode == http.StatusNotModified {
46728 if res.Body != nil {
46729 res.Body.Close()
46730 }
46731 return nil, &googleapi.Error{
46732 Code: res.StatusCode,
46733 Header: res.Header,
46734 }
46735 }
46736 if err != nil {
46737 return nil, err
46738 }
46739 defer googleapi.CloseBody(res)
46740 if err := googleapi.CheckResponse(res); err != nil {
46741 return nil, err
46742 }
46743 ret := &SizesListResponse{
46744 ServerResponse: googleapi.ServerResponse{
46745 Header: res.Header,
46746 HTTPStatusCode: res.StatusCode,
46747 },
46748 }
46749 target := &ret
46750 if err := gensupport.DecodeResponse(target, res); err != nil {
46751 return nil, err
46752 }
46753 return ret, nil
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
46791
46792
46793
46794
46795
46796
46797
46798
46799
46800
46801
46802
46803
46804
46805
46806
46807 }
46808
46809
46810
46811 type SubaccountsGetCall struct {
46812 s *Service
46813 profileId int64
46814 id int64
46815 urlParams_ gensupport.URLParams
46816 ifNoneMatch_ string
46817 ctx_ context.Context
46818 header_ http.Header
46819 }
46820
46821
46822 func (r *SubaccountsService) Get(profileId int64, id int64) *SubaccountsGetCall {
46823 c := &SubaccountsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
46824 c.profileId = profileId
46825 c.id = id
46826 return c
46827 }
46828
46829
46830
46831
46832 func (c *SubaccountsGetCall) Fields(s ...googleapi.Field) *SubaccountsGetCall {
46833 c.urlParams_.Set("fields", googleapi.CombineFields(s))
46834 return c
46835 }
46836
46837
46838
46839
46840
46841
46842 func (c *SubaccountsGetCall) IfNoneMatch(entityTag string) *SubaccountsGetCall {
46843 c.ifNoneMatch_ = entityTag
46844 return c
46845 }
46846
46847
46848
46849
46850 func (c *SubaccountsGetCall) Context(ctx context.Context) *SubaccountsGetCall {
46851 c.ctx_ = ctx
46852 return c
46853 }
46854
46855
46856
46857 func (c *SubaccountsGetCall) Header() http.Header {
46858 if c.header_ == nil {
46859 c.header_ = make(http.Header)
46860 }
46861 return c.header_
46862 }
46863
46864 func (c *SubaccountsGetCall) doRequest(alt string) (*http.Response, error) {
46865 reqHeaders := make(http.Header)
46866 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
46867 for k, v := range c.header_ {
46868 reqHeaders[k] = v
46869 }
46870 reqHeaders.Set("User-Agent", c.s.userAgent())
46871 if c.ifNoneMatch_ != "" {
46872 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
46873 }
46874 var body io.Reader = nil
46875 c.urlParams_.Set("alt", alt)
46876 c.urlParams_.Set("prettyPrint", "false")
46877 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/subaccounts/{id}")
46878 urls += "?" + c.urlParams_.Encode()
46879 req, err := http.NewRequest("GET", urls, body)
46880 if err != nil {
46881 return nil, err
46882 }
46883 req.Header = reqHeaders
46884 googleapi.Expand(req.URL, map[string]string{
46885 "profileId": strconv.FormatInt(c.profileId, 10),
46886 "id": strconv.FormatInt(c.id, 10),
46887 })
46888 return gensupport.SendRequest(c.ctx_, c.s.client, req)
46889 }
46890
46891
46892
46893
46894
46895
46896
46897
46898 func (c *SubaccountsGetCall) Do(opts ...googleapi.CallOption) (*Subaccount, error) {
46899 gensupport.SetOptions(c.urlParams_, opts...)
46900 res, err := c.doRequest("json")
46901 if res != nil && res.StatusCode == http.StatusNotModified {
46902 if res.Body != nil {
46903 res.Body.Close()
46904 }
46905 return nil, &googleapi.Error{
46906 Code: res.StatusCode,
46907 Header: res.Header,
46908 }
46909 }
46910 if err != nil {
46911 return nil, err
46912 }
46913 defer googleapi.CloseBody(res)
46914 if err := googleapi.CheckResponse(res); err != nil {
46915 return nil, err
46916 }
46917 ret := &Subaccount{
46918 ServerResponse: googleapi.ServerResponse{
46919 Header: res.Header,
46920 HTTPStatusCode: res.StatusCode,
46921 },
46922 }
46923 target := &ret
46924 if err := gensupport.DecodeResponse(target, res); err != nil {
46925 return nil, err
46926 }
46927 return ret, nil
46928
46929
46930
46931
46932
46933
46934
46935
46936
46937
46938
46939
46940
46941
46942
46943
46944
46945
46946
46947
46948
46949
46950
46951
46952
46953
46954
46955
46956
46957
46958
46959
46960
46961 }
46962
46963
46964
46965 type SubaccountsInsertCall struct {
46966 s *Service
46967 profileId int64
46968 subaccount *Subaccount
46969 urlParams_ gensupport.URLParams
46970 ctx_ context.Context
46971 header_ http.Header
46972 }
46973
46974
46975 func (r *SubaccountsService) Insert(profileId int64, subaccount *Subaccount) *SubaccountsInsertCall {
46976 c := &SubaccountsInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
46977 c.profileId = profileId
46978 c.subaccount = subaccount
46979 return c
46980 }
46981
46982
46983
46984
46985 func (c *SubaccountsInsertCall) Fields(s ...googleapi.Field) *SubaccountsInsertCall {
46986 c.urlParams_.Set("fields", googleapi.CombineFields(s))
46987 return c
46988 }
46989
46990
46991
46992
46993 func (c *SubaccountsInsertCall) Context(ctx context.Context) *SubaccountsInsertCall {
46994 c.ctx_ = ctx
46995 return c
46996 }
46997
46998
46999
47000 func (c *SubaccountsInsertCall) Header() http.Header {
47001 if c.header_ == nil {
47002 c.header_ = make(http.Header)
47003 }
47004 return c.header_
47005 }
47006
47007 func (c *SubaccountsInsertCall) doRequest(alt string) (*http.Response, error) {
47008 reqHeaders := make(http.Header)
47009 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
47010 for k, v := range c.header_ {
47011 reqHeaders[k] = v
47012 }
47013 reqHeaders.Set("User-Agent", c.s.userAgent())
47014 var body io.Reader = nil
47015 body, err := googleapi.WithoutDataWrapper.JSONReader(c.subaccount)
47016 if err != nil {
47017 return nil, err
47018 }
47019 reqHeaders.Set("Content-Type", "application/json")
47020 c.urlParams_.Set("alt", alt)
47021 c.urlParams_.Set("prettyPrint", "false")
47022 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/subaccounts")
47023 urls += "?" + c.urlParams_.Encode()
47024 req, err := http.NewRequest("POST", urls, body)
47025 if err != nil {
47026 return nil, err
47027 }
47028 req.Header = reqHeaders
47029 googleapi.Expand(req.URL, map[string]string{
47030 "profileId": strconv.FormatInt(c.profileId, 10),
47031 })
47032 return gensupport.SendRequest(c.ctx_, c.s.client, req)
47033 }
47034
47035
47036
47037
47038
47039
47040
47041
47042 func (c *SubaccountsInsertCall) Do(opts ...googleapi.CallOption) (*Subaccount, error) {
47043 gensupport.SetOptions(c.urlParams_, opts...)
47044 res, err := c.doRequest("json")
47045 if res != nil && res.StatusCode == http.StatusNotModified {
47046 if res.Body != nil {
47047 res.Body.Close()
47048 }
47049 return nil, &googleapi.Error{
47050 Code: res.StatusCode,
47051 Header: res.Header,
47052 }
47053 }
47054 if err != nil {
47055 return nil, err
47056 }
47057 defer googleapi.CloseBody(res)
47058 if err := googleapi.CheckResponse(res); err != nil {
47059 return nil, err
47060 }
47061 ret := &Subaccount{
47062 ServerResponse: googleapi.ServerResponse{
47063 Header: res.Header,
47064 HTTPStatusCode: res.StatusCode,
47065 },
47066 }
47067 target := &ret
47068 if err := gensupport.DecodeResponse(target, res); err != nil {
47069 return nil, err
47070 }
47071 return ret, nil
47072
47073
47074
47075
47076
47077
47078
47079
47080
47081
47082
47083
47084
47085
47086
47087
47088
47089
47090
47091
47092
47093
47094
47095
47096
47097
47098
47099
47100 }
47101
47102
47103
47104 type SubaccountsListCall struct {
47105 s *Service
47106 profileId int64
47107 urlParams_ gensupport.URLParams
47108 ifNoneMatch_ string
47109 ctx_ context.Context
47110 header_ http.Header
47111 }
47112
47113
47114
47115 func (r *SubaccountsService) List(profileId int64) *SubaccountsListCall {
47116 c := &SubaccountsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
47117 c.profileId = profileId
47118 return c
47119 }
47120
47121
47122
47123 func (c *SubaccountsListCall) Ids(ids ...int64) *SubaccountsListCall {
47124 var ids_ []string
47125 for _, v := range ids {
47126 ids_ = append(ids_, fmt.Sprint(v))
47127 }
47128 c.urlParams_.SetMulti("ids", ids_)
47129 return c
47130 }
47131
47132
47133
47134 func (c *SubaccountsListCall) MaxResults(maxResults int64) *SubaccountsListCall {
47135 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
47136 return c
47137 }
47138
47139
47140
47141 func (c *SubaccountsListCall) PageToken(pageToken string) *SubaccountsListCall {
47142 c.urlParams_.Set("pageToken", pageToken)
47143 return c
47144 }
47145
47146
47147
47148
47149
47150
47151
47152
47153
47154 func (c *SubaccountsListCall) SearchString(searchString string) *SubaccountsListCall {
47155 c.urlParams_.Set("searchString", searchString)
47156 return c
47157 }
47158
47159
47160
47161
47162
47163
47164
47165
47166 func (c *SubaccountsListCall) SortField(sortField string) *SubaccountsListCall {
47167 c.urlParams_.Set("sortField", sortField)
47168 return c
47169 }
47170
47171
47172
47173
47174
47175
47176
47177
47178 func (c *SubaccountsListCall) SortOrder(sortOrder string) *SubaccountsListCall {
47179 c.urlParams_.Set("sortOrder", sortOrder)
47180 return c
47181 }
47182
47183
47184
47185
47186 func (c *SubaccountsListCall) Fields(s ...googleapi.Field) *SubaccountsListCall {
47187 c.urlParams_.Set("fields", googleapi.CombineFields(s))
47188 return c
47189 }
47190
47191
47192
47193
47194
47195
47196 func (c *SubaccountsListCall) IfNoneMatch(entityTag string) *SubaccountsListCall {
47197 c.ifNoneMatch_ = entityTag
47198 return c
47199 }
47200
47201
47202
47203
47204 func (c *SubaccountsListCall) Context(ctx context.Context) *SubaccountsListCall {
47205 c.ctx_ = ctx
47206 return c
47207 }
47208
47209
47210
47211 func (c *SubaccountsListCall) Header() http.Header {
47212 if c.header_ == nil {
47213 c.header_ = make(http.Header)
47214 }
47215 return c.header_
47216 }
47217
47218 func (c *SubaccountsListCall) doRequest(alt string) (*http.Response, error) {
47219 reqHeaders := make(http.Header)
47220 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
47221 for k, v := range c.header_ {
47222 reqHeaders[k] = v
47223 }
47224 reqHeaders.Set("User-Agent", c.s.userAgent())
47225 if c.ifNoneMatch_ != "" {
47226 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
47227 }
47228 var body io.Reader = nil
47229 c.urlParams_.Set("alt", alt)
47230 c.urlParams_.Set("prettyPrint", "false")
47231 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/subaccounts")
47232 urls += "?" + c.urlParams_.Encode()
47233 req, err := http.NewRequest("GET", urls, body)
47234 if err != nil {
47235 return nil, err
47236 }
47237 req.Header = reqHeaders
47238 googleapi.Expand(req.URL, map[string]string{
47239 "profileId": strconv.FormatInt(c.profileId, 10),
47240 })
47241 return gensupport.SendRequest(c.ctx_, c.s.client, req)
47242 }
47243
47244
47245
47246
47247
47248
47249
47250
47251 func (c *SubaccountsListCall) Do(opts ...googleapi.CallOption) (*SubaccountsListResponse, error) {
47252 gensupport.SetOptions(c.urlParams_, opts...)
47253 res, err := c.doRequest("json")
47254 if res != nil && res.StatusCode == http.StatusNotModified {
47255 if res.Body != nil {
47256 res.Body.Close()
47257 }
47258 return nil, &googleapi.Error{
47259 Code: res.StatusCode,
47260 Header: res.Header,
47261 }
47262 }
47263 if err != nil {
47264 return nil, err
47265 }
47266 defer googleapi.CloseBody(res)
47267 if err := googleapi.CheckResponse(res); err != nil {
47268 return nil, err
47269 }
47270 ret := &SubaccountsListResponse{
47271 ServerResponse: googleapi.ServerResponse{
47272 Header: res.Header,
47273 HTTPStatusCode: res.StatusCode,
47274 },
47275 }
47276 target := &ret
47277 if err := gensupport.DecodeResponse(target, res); err != nil {
47278 return nil, err
47279 }
47280 return ret, nil
47281
47282
47283
47284
47285
47286
47287
47288
47289
47290
47291
47292
47293
47294
47295
47296
47297
47298
47299
47300
47301
47302
47303
47304
47305
47306
47307
47308
47309
47310
47311
47312
47313
47314
47315
47316
47317
47318
47319
47320
47321
47322
47323
47324
47325
47326
47327
47328
47329
47330
47331
47332
47333
47334
47335
47336
47337
47338
47339
47340
47341
47342
47343
47344
47345
47346
47347
47348
47349
47350
47351
47352
47353
47354
47355
47356
47357
47358
47359
47360 }
47361
47362
47363
47364
47365 func (c *SubaccountsListCall) Pages(ctx context.Context, f func(*SubaccountsListResponse) error) error {
47366 c.ctx_ = ctx
47367 defer c.PageToken(c.urlParams_.Get("pageToken"))
47368 for {
47369 x, err := c.Do()
47370 if err != nil {
47371 return err
47372 }
47373 if err := f(x); err != nil {
47374 return err
47375 }
47376 if x.NextPageToken == "" {
47377 return nil
47378 }
47379 c.PageToken(x.NextPageToken)
47380 }
47381 }
47382
47383
47384
47385 type SubaccountsPatchCall struct {
47386 s *Service
47387 profileId int64
47388 subaccount *Subaccount
47389 urlParams_ gensupport.URLParams
47390 ctx_ context.Context
47391 header_ http.Header
47392 }
47393
47394
47395
47396 func (r *SubaccountsService) Patch(profileId int64, id int64, subaccount *Subaccount) *SubaccountsPatchCall {
47397 c := &SubaccountsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
47398 c.profileId = profileId
47399 c.urlParams_.Set("id", fmt.Sprint(id))
47400 c.subaccount = subaccount
47401 return c
47402 }
47403
47404
47405
47406
47407 func (c *SubaccountsPatchCall) Fields(s ...googleapi.Field) *SubaccountsPatchCall {
47408 c.urlParams_.Set("fields", googleapi.CombineFields(s))
47409 return c
47410 }
47411
47412
47413
47414
47415 func (c *SubaccountsPatchCall) Context(ctx context.Context) *SubaccountsPatchCall {
47416 c.ctx_ = ctx
47417 return c
47418 }
47419
47420
47421
47422 func (c *SubaccountsPatchCall) Header() http.Header {
47423 if c.header_ == nil {
47424 c.header_ = make(http.Header)
47425 }
47426 return c.header_
47427 }
47428
47429 func (c *SubaccountsPatchCall) doRequest(alt string) (*http.Response, error) {
47430 reqHeaders := make(http.Header)
47431 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
47432 for k, v := range c.header_ {
47433 reqHeaders[k] = v
47434 }
47435 reqHeaders.Set("User-Agent", c.s.userAgent())
47436 var body io.Reader = nil
47437 body, err := googleapi.WithoutDataWrapper.JSONReader(c.subaccount)
47438 if err != nil {
47439 return nil, err
47440 }
47441 reqHeaders.Set("Content-Type", "application/json")
47442 c.urlParams_.Set("alt", alt)
47443 c.urlParams_.Set("prettyPrint", "false")
47444 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/subaccounts")
47445 urls += "?" + c.urlParams_.Encode()
47446 req, err := http.NewRequest("PATCH", urls, body)
47447 if err != nil {
47448 return nil, err
47449 }
47450 req.Header = reqHeaders
47451 googleapi.Expand(req.URL, map[string]string{
47452 "profileId": strconv.FormatInt(c.profileId, 10),
47453 })
47454 return gensupport.SendRequest(c.ctx_, c.s.client, req)
47455 }
47456
47457
47458
47459
47460
47461
47462
47463
47464 func (c *SubaccountsPatchCall) Do(opts ...googleapi.CallOption) (*Subaccount, error) {
47465 gensupport.SetOptions(c.urlParams_, opts...)
47466 res, err := c.doRequest("json")
47467 if res != nil && res.StatusCode == http.StatusNotModified {
47468 if res.Body != nil {
47469 res.Body.Close()
47470 }
47471 return nil, &googleapi.Error{
47472 Code: res.StatusCode,
47473 Header: res.Header,
47474 }
47475 }
47476 if err != nil {
47477 return nil, err
47478 }
47479 defer googleapi.CloseBody(res)
47480 if err := googleapi.CheckResponse(res); err != nil {
47481 return nil, err
47482 }
47483 ret := &Subaccount{
47484 ServerResponse: googleapi.ServerResponse{
47485 Header: res.Header,
47486 HTTPStatusCode: res.StatusCode,
47487 },
47488 }
47489 target := &ret
47490 if err := gensupport.DecodeResponse(target, res); err != nil {
47491 return nil, err
47492 }
47493 return ret, nil
47494
47495
47496
47497
47498
47499
47500
47501
47502
47503
47504
47505
47506
47507
47508
47509
47510
47511
47512
47513
47514
47515
47516
47517
47518
47519
47520
47521
47522
47523
47524
47525
47526
47527
47528
47529
47530 }
47531
47532
47533
47534 type SubaccountsUpdateCall struct {
47535 s *Service
47536 profileId int64
47537 subaccount *Subaccount
47538 urlParams_ gensupport.URLParams
47539 ctx_ context.Context
47540 header_ http.Header
47541 }
47542
47543
47544 func (r *SubaccountsService) Update(profileId int64, subaccount *Subaccount) *SubaccountsUpdateCall {
47545 c := &SubaccountsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
47546 c.profileId = profileId
47547 c.subaccount = subaccount
47548 return c
47549 }
47550
47551
47552
47553
47554 func (c *SubaccountsUpdateCall) Fields(s ...googleapi.Field) *SubaccountsUpdateCall {
47555 c.urlParams_.Set("fields", googleapi.CombineFields(s))
47556 return c
47557 }
47558
47559
47560
47561
47562 func (c *SubaccountsUpdateCall) Context(ctx context.Context) *SubaccountsUpdateCall {
47563 c.ctx_ = ctx
47564 return c
47565 }
47566
47567
47568
47569 func (c *SubaccountsUpdateCall) Header() http.Header {
47570 if c.header_ == nil {
47571 c.header_ = make(http.Header)
47572 }
47573 return c.header_
47574 }
47575
47576 func (c *SubaccountsUpdateCall) doRequest(alt string) (*http.Response, error) {
47577 reqHeaders := make(http.Header)
47578 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
47579 for k, v := range c.header_ {
47580 reqHeaders[k] = v
47581 }
47582 reqHeaders.Set("User-Agent", c.s.userAgent())
47583 var body io.Reader = nil
47584 body, err := googleapi.WithoutDataWrapper.JSONReader(c.subaccount)
47585 if err != nil {
47586 return nil, err
47587 }
47588 reqHeaders.Set("Content-Type", "application/json")
47589 c.urlParams_.Set("alt", alt)
47590 c.urlParams_.Set("prettyPrint", "false")
47591 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/subaccounts")
47592 urls += "?" + c.urlParams_.Encode()
47593 req, err := http.NewRequest("PUT", urls, body)
47594 if err != nil {
47595 return nil, err
47596 }
47597 req.Header = reqHeaders
47598 googleapi.Expand(req.URL, map[string]string{
47599 "profileId": strconv.FormatInt(c.profileId, 10),
47600 })
47601 return gensupport.SendRequest(c.ctx_, c.s.client, req)
47602 }
47603
47604
47605
47606
47607
47608
47609
47610
47611 func (c *SubaccountsUpdateCall) Do(opts ...googleapi.CallOption) (*Subaccount, error) {
47612 gensupport.SetOptions(c.urlParams_, opts...)
47613 res, err := c.doRequest("json")
47614 if res != nil && res.StatusCode == http.StatusNotModified {
47615 if res.Body != nil {
47616 res.Body.Close()
47617 }
47618 return nil, &googleapi.Error{
47619 Code: res.StatusCode,
47620 Header: res.Header,
47621 }
47622 }
47623 if err != nil {
47624 return nil, err
47625 }
47626 defer googleapi.CloseBody(res)
47627 if err := googleapi.CheckResponse(res); err != nil {
47628 return nil, err
47629 }
47630 ret := &Subaccount{
47631 ServerResponse: googleapi.ServerResponse{
47632 Header: res.Header,
47633 HTTPStatusCode: res.StatusCode,
47634 },
47635 }
47636 target := &ret
47637 if err := gensupport.DecodeResponse(target, res); err != nil {
47638 return nil, err
47639 }
47640 return ret, nil
47641
47642
47643
47644
47645
47646
47647
47648
47649
47650
47651
47652
47653
47654
47655
47656
47657
47658
47659
47660
47661
47662
47663
47664
47665
47666
47667
47668
47669 }
47670
47671
47672
47673 type TargetableRemarketingListsGetCall struct {
47674 s *Service
47675 profileId int64
47676 id int64
47677 urlParams_ gensupport.URLParams
47678 ifNoneMatch_ string
47679 ctx_ context.Context
47680 header_ http.Header
47681 }
47682
47683
47684 func (r *TargetableRemarketingListsService) Get(profileId int64, id int64) *TargetableRemarketingListsGetCall {
47685 c := &TargetableRemarketingListsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
47686 c.profileId = profileId
47687 c.id = id
47688 return c
47689 }
47690
47691
47692
47693
47694 func (c *TargetableRemarketingListsGetCall) Fields(s ...googleapi.Field) *TargetableRemarketingListsGetCall {
47695 c.urlParams_.Set("fields", googleapi.CombineFields(s))
47696 return c
47697 }
47698
47699
47700
47701
47702
47703
47704 func (c *TargetableRemarketingListsGetCall) IfNoneMatch(entityTag string) *TargetableRemarketingListsGetCall {
47705 c.ifNoneMatch_ = entityTag
47706 return c
47707 }
47708
47709
47710
47711
47712 func (c *TargetableRemarketingListsGetCall) Context(ctx context.Context) *TargetableRemarketingListsGetCall {
47713 c.ctx_ = ctx
47714 return c
47715 }
47716
47717
47718
47719 func (c *TargetableRemarketingListsGetCall) Header() http.Header {
47720 if c.header_ == nil {
47721 c.header_ = make(http.Header)
47722 }
47723 return c.header_
47724 }
47725
47726 func (c *TargetableRemarketingListsGetCall) doRequest(alt string) (*http.Response, error) {
47727 reqHeaders := make(http.Header)
47728 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
47729 for k, v := range c.header_ {
47730 reqHeaders[k] = v
47731 }
47732 reqHeaders.Set("User-Agent", c.s.userAgent())
47733 if c.ifNoneMatch_ != "" {
47734 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
47735 }
47736 var body io.Reader = nil
47737 c.urlParams_.Set("alt", alt)
47738 c.urlParams_.Set("prettyPrint", "false")
47739 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/targetableRemarketingLists/{id}")
47740 urls += "?" + c.urlParams_.Encode()
47741 req, err := http.NewRequest("GET", urls, body)
47742 if err != nil {
47743 return nil, err
47744 }
47745 req.Header = reqHeaders
47746 googleapi.Expand(req.URL, map[string]string{
47747 "profileId": strconv.FormatInt(c.profileId, 10),
47748 "id": strconv.FormatInt(c.id, 10),
47749 })
47750 return gensupport.SendRequest(c.ctx_, c.s.client, req)
47751 }
47752
47753
47754
47755
47756
47757
47758
47759
47760 func (c *TargetableRemarketingListsGetCall) Do(opts ...googleapi.CallOption) (*TargetableRemarketingList, error) {
47761 gensupport.SetOptions(c.urlParams_, opts...)
47762 res, err := c.doRequest("json")
47763 if res != nil && res.StatusCode == http.StatusNotModified {
47764 if res.Body != nil {
47765 res.Body.Close()
47766 }
47767 return nil, &googleapi.Error{
47768 Code: res.StatusCode,
47769 Header: res.Header,
47770 }
47771 }
47772 if err != nil {
47773 return nil, err
47774 }
47775 defer googleapi.CloseBody(res)
47776 if err := googleapi.CheckResponse(res); err != nil {
47777 return nil, err
47778 }
47779 ret := &TargetableRemarketingList{
47780 ServerResponse: googleapi.ServerResponse{
47781 Header: res.Header,
47782 HTTPStatusCode: res.StatusCode,
47783 },
47784 }
47785 target := &ret
47786 if err := gensupport.DecodeResponse(target, res); err != nil {
47787 return nil, err
47788 }
47789 return ret, nil
47790
47791
47792
47793
47794
47795
47796
47797
47798
47799
47800
47801
47802
47803
47804
47805
47806
47807
47808
47809
47810
47811
47812
47813
47814
47815
47816
47817
47818
47819
47820
47821
47822
47823 }
47824
47825
47826
47827 type TargetableRemarketingListsListCall struct {
47828 s *Service
47829 profileId int64
47830 urlParams_ gensupport.URLParams
47831 ifNoneMatch_ string
47832 ctx_ context.Context
47833 header_ http.Header
47834 }
47835
47836
47837
47838 func (r *TargetableRemarketingListsService) List(profileId int64, advertiserId int64) *TargetableRemarketingListsListCall {
47839 c := &TargetableRemarketingListsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
47840 c.profileId = profileId
47841 c.urlParams_.Set("advertiserId", fmt.Sprint(advertiserId))
47842 return c
47843 }
47844
47845
47846
47847 func (c *TargetableRemarketingListsListCall) Active(active bool) *TargetableRemarketingListsListCall {
47848 c.urlParams_.Set("active", fmt.Sprint(active))
47849 return c
47850 }
47851
47852
47853
47854 func (c *TargetableRemarketingListsListCall) MaxResults(maxResults int64) *TargetableRemarketingListsListCall {
47855 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
47856 return c
47857 }
47858
47859
47860
47861
47862
47863
47864
47865
47866
47867 func (c *TargetableRemarketingListsListCall) Name(name string) *TargetableRemarketingListsListCall {
47868 c.urlParams_.Set("name", name)
47869 return c
47870 }
47871
47872
47873
47874 func (c *TargetableRemarketingListsListCall) PageToken(pageToken string) *TargetableRemarketingListsListCall {
47875 c.urlParams_.Set("pageToken", pageToken)
47876 return c
47877 }
47878
47879
47880
47881
47882
47883
47884
47885
47886 func (c *TargetableRemarketingListsListCall) SortField(sortField string) *TargetableRemarketingListsListCall {
47887 c.urlParams_.Set("sortField", sortField)
47888 return c
47889 }
47890
47891
47892
47893
47894
47895
47896
47897
47898 func (c *TargetableRemarketingListsListCall) SortOrder(sortOrder string) *TargetableRemarketingListsListCall {
47899 c.urlParams_.Set("sortOrder", sortOrder)
47900 return c
47901 }
47902
47903
47904
47905
47906 func (c *TargetableRemarketingListsListCall) Fields(s ...googleapi.Field) *TargetableRemarketingListsListCall {
47907 c.urlParams_.Set("fields", googleapi.CombineFields(s))
47908 return c
47909 }
47910
47911
47912
47913
47914
47915
47916 func (c *TargetableRemarketingListsListCall) IfNoneMatch(entityTag string) *TargetableRemarketingListsListCall {
47917 c.ifNoneMatch_ = entityTag
47918 return c
47919 }
47920
47921
47922
47923
47924 func (c *TargetableRemarketingListsListCall) Context(ctx context.Context) *TargetableRemarketingListsListCall {
47925 c.ctx_ = ctx
47926 return c
47927 }
47928
47929
47930
47931 func (c *TargetableRemarketingListsListCall) Header() http.Header {
47932 if c.header_ == nil {
47933 c.header_ = make(http.Header)
47934 }
47935 return c.header_
47936 }
47937
47938 func (c *TargetableRemarketingListsListCall) doRequest(alt string) (*http.Response, error) {
47939 reqHeaders := make(http.Header)
47940 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
47941 for k, v := range c.header_ {
47942 reqHeaders[k] = v
47943 }
47944 reqHeaders.Set("User-Agent", c.s.userAgent())
47945 if c.ifNoneMatch_ != "" {
47946 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
47947 }
47948 var body io.Reader = nil
47949 c.urlParams_.Set("alt", alt)
47950 c.urlParams_.Set("prettyPrint", "false")
47951 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/targetableRemarketingLists")
47952 urls += "?" + c.urlParams_.Encode()
47953 req, err := http.NewRequest("GET", urls, body)
47954 if err != nil {
47955 return nil, err
47956 }
47957 req.Header = reqHeaders
47958 googleapi.Expand(req.URL, map[string]string{
47959 "profileId": strconv.FormatInt(c.profileId, 10),
47960 })
47961 return gensupport.SendRequest(c.ctx_, c.s.client, req)
47962 }
47963
47964
47965
47966
47967
47968
47969
47970
47971
47972 func (c *TargetableRemarketingListsListCall) Do(opts ...googleapi.CallOption) (*TargetableRemarketingListsListResponse, error) {
47973 gensupport.SetOptions(c.urlParams_, opts...)
47974 res, err := c.doRequest("json")
47975 if res != nil && res.StatusCode == http.StatusNotModified {
47976 if res.Body != nil {
47977 res.Body.Close()
47978 }
47979 return nil, &googleapi.Error{
47980 Code: res.StatusCode,
47981 Header: res.Header,
47982 }
47983 }
47984 if err != nil {
47985 return nil, err
47986 }
47987 defer googleapi.CloseBody(res)
47988 if err := googleapi.CheckResponse(res); err != nil {
47989 return nil, err
47990 }
47991 ret := &TargetableRemarketingListsListResponse{
47992 ServerResponse: googleapi.ServerResponse{
47993 Header: res.Header,
47994 HTTPStatusCode: res.StatusCode,
47995 },
47996 }
47997 target := &ret
47998 if err := gensupport.DecodeResponse(target, res); err != nil {
47999 return nil, err
48000 }
48001 return ret, nil
48002
48003
48004
48005
48006
48007
48008
48009
48010
48011
48012
48013
48014
48015
48016
48017
48018
48019
48020
48021
48022
48023
48024
48025
48026
48027
48028
48029
48030
48031
48032
48033
48034
48035
48036
48037
48038
48039
48040
48041
48042
48043
48044
48045
48046
48047
48048
48049
48050
48051
48052
48053
48054
48055
48056
48057
48058
48059
48060
48061
48062
48063
48064
48065
48066
48067
48068
48069
48070
48071
48072
48073
48074
48075
48076
48077
48078
48079
48080
48081
48082
48083
48084
48085
48086
48087 }
48088
48089
48090
48091
48092 func (c *TargetableRemarketingListsListCall) Pages(ctx context.Context, f func(*TargetableRemarketingListsListResponse) error) error {
48093 c.ctx_ = ctx
48094 defer c.PageToken(c.urlParams_.Get("pageToken"))
48095 for {
48096 x, err := c.Do()
48097 if err != nil {
48098 return err
48099 }
48100 if err := f(x); err != nil {
48101 return err
48102 }
48103 if x.NextPageToken == "" {
48104 return nil
48105 }
48106 c.PageToken(x.NextPageToken)
48107 }
48108 }
48109
48110
48111
48112 type TargetingTemplatesGetCall struct {
48113 s *Service
48114 profileId int64
48115 id int64
48116 urlParams_ gensupport.URLParams
48117 ifNoneMatch_ string
48118 ctx_ context.Context
48119 header_ http.Header
48120 }
48121
48122
48123 func (r *TargetingTemplatesService) Get(profileId int64, id int64) *TargetingTemplatesGetCall {
48124 c := &TargetingTemplatesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
48125 c.profileId = profileId
48126 c.id = id
48127 return c
48128 }
48129
48130
48131
48132
48133 func (c *TargetingTemplatesGetCall) Fields(s ...googleapi.Field) *TargetingTemplatesGetCall {
48134 c.urlParams_.Set("fields", googleapi.CombineFields(s))
48135 return c
48136 }
48137
48138
48139
48140
48141
48142
48143 func (c *TargetingTemplatesGetCall) IfNoneMatch(entityTag string) *TargetingTemplatesGetCall {
48144 c.ifNoneMatch_ = entityTag
48145 return c
48146 }
48147
48148
48149
48150
48151 func (c *TargetingTemplatesGetCall) Context(ctx context.Context) *TargetingTemplatesGetCall {
48152 c.ctx_ = ctx
48153 return c
48154 }
48155
48156
48157
48158 func (c *TargetingTemplatesGetCall) Header() http.Header {
48159 if c.header_ == nil {
48160 c.header_ = make(http.Header)
48161 }
48162 return c.header_
48163 }
48164
48165 func (c *TargetingTemplatesGetCall) doRequest(alt string) (*http.Response, error) {
48166 reqHeaders := make(http.Header)
48167 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
48168 for k, v := range c.header_ {
48169 reqHeaders[k] = v
48170 }
48171 reqHeaders.Set("User-Agent", c.s.userAgent())
48172 if c.ifNoneMatch_ != "" {
48173 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
48174 }
48175 var body io.Reader = nil
48176 c.urlParams_.Set("alt", alt)
48177 c.urlParams_.Set("prettyPrint", "false")
48178 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/targetingTemplates/{id}")
48179 urls += "?" + c.urlParams_.Encode()
48180 req, err := http.NewRequest("GET", urls, body)
48181 if err != nil {
48182 return nil, err
48183 }
48184 req.Header = reqHeaders
48185 googleapi.Expand(req.URL, map[string]string{
48186 "profileId": strconv.FormatInt(c.profileId, 10),
48187 "id": strconv.FormatInt(c.id, 10),
48188 })
48189 return gensupport.SendRequest(c.ctx_, c.s.client, req)
48190 }
48191
48192
48193
48194
48195
48196
48197
48198
48199 func (c *TargetingTemplatesGetCall) Do(opts ...googleapi.CallOption) (*TargetingTemplate, error) {
48200 gensupport.SetOptions(c.urlParams_, opts...)
48201 res, err := c.doRequest("json")
48202 if res != nil && res.StatusCode == http.StatusNotModified {
48203 if res.Body != nil {
48204 res.Body.Close()
48205 }
48206 return nil, &googleapi.Error{
48207 Code: res.StatusCode,
48208 Header: res.Header,
48209 }
48210 }
48211 if err != nil {
48212 return nil, err
48213 }
48214 defer googleapi.CloseBody(res)
48215 if err := googleapi.CheckResponse(res); err != nil {
48216 return nil, err
48217 }
48218 ret := &TargetingTemplate{
48219 ServerResponse: googleapi.ServerResponse{
48220 Header: res.Header,
48221 HTTPStatusCode: res.StatusCode,
48222 },
48223 }
48224 target := &ret
48225 if err := gensupport.DecodeResponse(target, res); err != nil {
48226 return nil, err
48227 }
48228 return ret, nil
48229
48230
48231
48232
48233
48234
48235
48236
48237
48238
48239
48240
48241
48242
48243
48244
48245
48246
48247
48248
48249
48250
48251
48252
48253
48254
48255
48256
48257
48258
48259
48260
48261
48262 }
48263
48264
48265
48266 type TargetingTemplatesInsertCall struct {
48267 s *Service
48268 profileId int64
48269 targetingtemplate *TargetingTemplate
48270 urlParams_ gensupport.URLParams
48271 ctx_ context.Context
48272 header_ http.Header
48273 }
48274
48275
48276 func (r *TargetingTemplatesService) Insert(profileId int64, targetingtemplate *TargetingTemplate) *TargetingTemplatesInsertCall {
48277 c := &TargetingTemplatesInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
48278 c.profileId = profileId
48279 c.targetingtemplate = targetingtemplate
48280 return c
48281 }
48282
48283
48284
48285
48286 func (c *TargetingTemplatesInsertCall) Fields(s ...googleapi.Field) *TargetingTemplatesInsertCall {
48287 c.urlParams_.Set("fields", googleapi.CombineFields(s))
48288 return c
48289 }
48290
48291
48292
48293
48294 func (c *TargetingTemplatesInsertCall) Context(ctx context.Context) *TargetingTemplatesInsertCall {
48295 c.ctx_ = ctx
48296 return c
48297 }
48298
48299
48300
48301 func (c *TargetingTemplatesInsertCall) Header() http.Header {
48302 if c.header_ == nil {
48303 c.header_ = make(http.Header)
48304 }
48305 return c.header_
48306 }
48307
48308 func (c *TargetingTemplatesInsertCall) doRequest(alt string) (*http.Response, error) {
48309 reqHeaders := make(http.Header)
48310 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
48311 for k, v := range c.header_ {
48312 reqHeaders[k] = v
48313 }
48314 reqHeaders.Set("User-Agent", c.s.userAgent())
48315 var body io.Reader = nil
48316 body, err := googleapi.WithoutDataWrapper.JSONReader(c.targetingtemplate)
48317 if err != nil {
48318 return nil, err
48319 }
48320 reqHeaders.Set("Content-Type", "application/json")
48321 c.urlParams_.Set("alt", alt)
48322 c.urlParams_.Set("prettyPrint", "false")
48323 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/targetingTemplates")
48324 urls += "?" + c.urlParams_.Encode()
48325 req, err := http.NewRequest("POST", urls, body)
48326 if err != nil {
48327 return nil, err
48328 }
48329 req.Header = reqHeaders
48330 googleapi.Expand(req.URL, map[string]string{
48331 "profileId": strconv.FormatInt(c.profileId, 10),
48332 })
48333 return gensupport.SendRequest(c.ctx_, c.s.client, req)
48334 }
48335
48336
48337
48338
48339
48340
48341
48342
48343 func (c *TargetingTemplatesInsertCall) Do(opts ...googleapi.CallOption) (*TargetingTemplate, error) {
48344 gensupport.SetOptions(c.urlParams_, opts...)
48345 res, err := c.doRequest("json")
48346 if res != nil && res.StatusCode == http.StatusNotModified {
48347 if res.Body != nil {
48348 res.Body.Close()
48349 }
48350 return nil, &googleapi.Error{
48351 Code: res.StatusCode,
48352 Header: res.Header,
48353 }
48354 }
48355 if err != nil {
48356 return nil, err
48357 }
48358 defer googleapi.CloseBody(res)
48359 if err := googleapi.CheckResponse(res); err != nil {
48360 return nil, err
48361 }
48362 ret := &TargetingTemplate{
48363 ServerResponse: googleapi.ServerResponse{
48364 Header: res.Header,
48365 HTTPStatusCode: res.StatusCode,
48366 },
48367 }
48368 target := &ret
48369 if err := gensupport.DecodeResponse(target, res); err != nil {
48370 return nil, err
48371 }
48372 return ret, nil
48373
48374
48375
48376
48377
48378
48379
48380
48381
48382
48383
48384
48385
48386
48387
48388
48389
48390
48391
48392
48393
48394
48395
48396
48397
48398
48399
48400
48401 }
48402
48403
48404
48405 type TargetingTemplatesListCall struct {
48406 s *Service
48407 profileId int64
48408 urlParams_ gensupport.URLParams
48409 ifNoneMatch_ string
48410 ctx_ context.Context
48411 header_ http.Header
48412 }
48413
48414
48415
48416 func (r *TargetingTemplatesService) List(profileId int64) *TargetingTemplatesListCall {
48417 c := &TargetingTemplatesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
48418 c.profileId = profileId
48419 return c
48420 }
48421
48422
48423
48424 func (c *TargetingTemplatesListCall) AdvertiserId(advertiserId int64) *TargetingTemplatesListCall {
48425 c.urlParams_.Set("advertiserId", fmt.Sprint(advertiserId))
48426 return c
48427 }
48428
48429
48430
48431 func (c *TargetingTemplatesListCall) Ids(ids ...int64) *TargetingTemplatesListCall {
48432 var ids_ []string
48433 for _, v := range ids {
48434 ids_ = append(ids_, fmt.Sprint(v))
48435 }
48436 c.urlParams_.SetMulti("ids", ids_)
48437 return c
48438 }
48439
48440
48441
48442 func (c *TargetingTemplatesListCall) MaxResults(maxResults int64) *TargetingTemplatesListCall {
48443 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
48444 return c
48445 }
48446
48447
48448
48449 func (c *TargetingTemplatesListCall) PageToken(pageToken string) *TargetingTemplatesListCall {
48450 c.urlParams_.Set("pageToken", pageToken)
48451 return c
48452 }
48453
48454
48455
48456
48457
48458
48459
48460
48461
48462 func (c *TargetingTemplatesListCall) SearchString(searchString string) *TargetingTemplatesListCall {
48463 c.urlParams_.Set("searchString", searchString)
48464 return c
48465 }
48466
48467
48468
48469
48470
48471
48472
48473
48474 func (c *TargetingTemplatesListCall) SortField(sortField string) *TargetingTemplatesListCall {
48475 c.urlParams_.Set("sortField", sortField)
48476 return c
48477 }
48478
48479
48480
48481
48482
48483
48484
48485
48486 func (c *TargetingTemplatesListCall) SortOrder(sortOrder string) *TargetingTemplatesListCall {
48487 c.urlParams_.Set("sortOrder", sortOrder)
48488 return c
48489 }
48490
48491
48492
48493
48494 func (c *TargetingTemplatesListCall) Fields(s ...googleapi.Field) *TargetingTemplatesListCall {
48495 c.urlParams_.Set("fields", googleapi.CombineFields(s))
48496 return c
48497 }
48498
48499
48500
48501
48502
48503
48504 func (c *TargetingTemplatesListCall) IfNoneMatch(entityTag string) *TargetingTemplatesListCall {
48505 c.ifNoneMatch_ = entityTag
48506 return c
48507 }
48508
48509
48510
48511
48512 func (c *TargetingTemplatesListCall) Context(ctx context.Context) *TargetingTemplatesListCall {
48513 c.ctx_ = ctx
48514 return c
48515 }
48516
48517
48518
48519 func (c *TargetingTemplatesListCall) Header() http.Header {
48520 if c.header_ == nil {
48521 c.header_ = make(http.Header)
48522 }
48523 return c.header_
48524 }
48525
48526 func (c *TargetingTemplatesListCall) doRequest(alt string) (*http.Response, error) {
48527 reqHeaders := make(http.Header)
48528 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
48529 for k, v := range c.header_ {
48530 reqHeaders[k] = v
48531 }
48532 reqHeaders.Set("User-Agent", c.s.userAgent())
48533 if c.ifNoneMatch_ != "" {
48534 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
48535 }
48536 var body io.Reader = nil
48537 c.urlParams_.Set("alt", alt)
48538 c.urlParams_.Set("prettyPrint", "false")
48539 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/targetingTemplates")
48540 urls += "?" + c.urlParams_.Encode()
48541 req, err := http.NewRequest("GET", urls, body)
48542 if err != nil {
48543 return nil, err
48544 }
48545 req.Header = reqHeaders
48546 googleapi.Expand(req.URL, map[string]string{
48547 "profileId": strconv.FormatInt(c.profileId, 10),
48548 })
48549 return gensupport.SendRequest(c.ctx_, c.s.client, req)
48550 }
48551
48552
48553
48554
48555
48556
48557
48558
48559 func (c *TargetingTemplatesListCall) Do(opts ...googleapi.CallOption) (*TargetingTemplatesListResponse, error) {
48560 gensupport.SetOptions(c.urlParams_, opts...)
48561 res, err := c.doRequest("json")
48562 if res != nil && res.StatusCode == http.StatusNotModified {
48563 if res.Body != nil {
48564 res.Body.Close()
48565 }
48566 return nil, &googleapi.Error{
48567 Code: res.StatusCode,
48568 Header: res.Header,
48569 }
48570 }
48571 if err != nil {
48572 return nil, err
48573 }
48574 defer googleapi.CloseBody(res)
48575 if err := googleapi.CheckResponse(res); err != nil {
48576 return nil, err
48577 }
48578 ret := &TargetingTemplatesListResponse{
48579 ServerResponse: googleapi.ServerResponse{
48580 Header: res.Header,
48581 HTTPStatusCode: res.StatusCode,
48582 },
48583 }
48584 target := &ret
48585 if err := gensupport.DecodeResponse(target, res); err != nil {
48586 return nil, err
48587 }
48588 return ret, nil
48589
48590
48591
48592
48593
48594
48595
48596
48597
48598
48599
48600
48601
48602
48603
48604
48605
48606
48607
48608
48609
48610
48611
48612
48613
48614
48615
48616
48617
48618
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 func (c *TargetingTemplatesListCall) Pages(ctx context.Context, f func(*TargetingTemplatesListResponse) error) error {
48680 c.ctx_ = ctx
48681 defer c.PageToken(c.urlParams_.Get("pageToken"))
48682 for {
48683 x, err := c.Do()
48684 if err != nil {
48685 return err
48686 }
48687 if err := f(x); err != nil {
48688 return err
48689 }
48690 if x.NextPageToken == "" {
48691 return nil
48692 }
48693 c.PageToken(x.NextPageToken)
48694 }
48695 }
48696
48697
48698
48699 type TargetingTemplatesPatchCall struct {
48700 s *Service
48701 profileId int64
48702 targetingtemplate *TargetingTemplate
48703 urlParams_ gensupport.URLParams
48704 ctx_ context.Context
48705 header_ http.Header
48706 }
48707
48708
48709
48710 func (r *TargetingTemplatesService) Patch(profileId int64, id int64, targetingtemplate *TargetingTemplate) *TargetingTemplatesPatchCall {
48711 c := &TargetingTemplatesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
48712 c.profileId = profileId
48713 c.urlParams_.Set("id", fmt.Sprint(id))
48714 c.targetingtemplate = targetingtemplate
48715 return c
48716 }
48717
48718
48719
48720
48721 func (c *TargetingTemplatesPatchCall) Fields(s ...googleapi.Field) *TargetingTemplatesPatchCall {
48722 c.urlParams_.Set("fields", googleapi.CombineFields(s))
48723 return c
48724 }
48725
48726
48727
48728
48729 func (c *TargetingTemplatesPatchCall) Context(ctx context.Context) *TargetingTemplatesPatchCall {
48730 c.ctx_ = ctx
48731 return c
48732 }
48733
48734
48735
48736 func (c *TargetingTemplatesPatchCall) Header() http.Header {
48737 if c.header_ == nil {
48738 c.header_ = make(http.Header)
48739 }
48740 return c.header_
48741 }
48742
48743 func (c *TargetingTemplatesPatchCall) doRequest(alt string) (*http.Response, error) {
48744 reqHeaders := make(http.Header)
48745 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
48746 for k, v := range c.header_ {
48747 reqHeaders[k] = v
48748 }
48749 reqHeaders.Set("User-Agent", c.s.userAgent())
48750 var body io.Reader = nil
48751 body, err := googleapi.WithoutDataWrapper.JSONReader(c.targetingtemplate)
48752 if err != nil {
48753 return nil, err
48754 }
48755 reqHeaders.Set("Content-Type", "application/json")
48756 c.urlParams_.Set("alt", alt)
48757 c.urlParams_.Set("prettyPrint", "false")
48758 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/targetingTemplates")
48759 urls += "?" + c.urlParams_.Encode()
48760 req, err := http.NewRequest("PATCH", urls, body)
48761 if err != nil {
48762 return nil, err
48763 }
48764 req.Header = reqHeaders
48765 googleapi.Expand(req.URL, map[string]string{
48766 "profileId": strconv.FormatInt(c.profileId, 10),
48767 })
48768 return gensupport.SendRequest(c.ctx_, c.s.client, req)
48769 }
48770
48771
48772
48773
48774
48775
48776
48777
48778 func (c *TargetingTemplatesPatchCall) Do(opts ...googleapi.CallOption) (*TargetingTemplate, error) {
48779 gensupport.SetOptions(c.urlParams_, opts...)
48780 res, err := c.doRequest("json")
48781 if res != nil && res.StatusCode == http.StatusNotModified {
48782 if res.Body != nil {
48783 res.Body.Close()
48784 }
48785 return nil, &googleapi.Error{
48786 Code: res.StatusCode,
48787 Header: res.Header,
48788 }
48789 }
48790 if err != nil {
48791 return nil, err
48792 }
48793 defer googleapi.CloseBody(res)
48794 if err := googleapi.CheckResponse(res); err != nil {
48795 return nil, err
48796 }
48797 ret := &TargetingTemplate{
48798 ServerResponse: googleapi.ServerResponse{
48799 Header: res.Header,
48800 HTTPStatusCode: res.StatusCode,
48801 },
48802 }
48803 target := &ret
48804 if err := gensupport.DecodeResponse(target, res); err != nil {
48805 return nil, err
48806 }
48807 return ret, nil
48808
48809
48810
48811
48812
48813
48814
48815
48816
48817
48818
48819
48820
48821
48822
48823
48824
48825
48826
48827
48828
48829
48830
48831
48832
48833
48834
48835
48836
48837
48838
48839
48840
48841
48842
48843
48844 }
48845
48846
48847
48848 type TargetingTemplatesUpdateCall struct {
48849 s *Service
48850 profileId int64
48851 targetingtemplate *TargetingTemplate
48852 urlParams_ gensupport.URLParams
48853 ctx_ context.Context
48854 header_ http.Header
48855 }
48856
48857
48858 func (r *TargetingTemplatesService) Update(profileId int64, targetingtemplate *TargetingTemplate) *TargetingTemplatesUpdateCall {
48859 c := &TargetingTemplatesUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
48860 c.profileId = profileId
48861 c.targetingtemplate = targetingtemplate
48862 return c
48863 }
48864
48865
48866
48867
48868 func (c *TargetingTemplatesUpdateCall) Fields(s ...googleapi.Field) *TargetingTemplatesUpdateCall {
48869 c.urlParams_.Set("fields", googleapi.CombineFields(s))
48870 return c
48871 }
48872
48873
48874
48875
48876 func (c *TargetingTemplatesUpdateCall) Context(ctx context.Context) *TargetingTemplatesUpdateCall {
48877 c.ctx_ = ctx
48878 return c
48879 }
48880
48881
48882
48883 func (c *TargetingTemplatesUpdateCall) Header() http.Header {
48884 if c.header_ == nil {
48885 c.header_ = make(http.Header)
48886 }
48887 return c.header_
48888 }
48889
48890 func (c *TargetingTemplatesUpdateCall) doRequest(alt string) (*http.Response, error) {
48891 reqHeaders := make(http.Header)
48892 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
48893 for k, v := range c.header_ {
48894 reqHeaders[k] = v
48895 }
48896 reqHeaders.Set("User-Agent", c.s.userAgent())
48897 var body io.Reader = nil
48898 body, err := googleapi.WithoutDataWrapper.JSONReader(c.targetingtemplate)
48899 if err != nil {
48900 return nil, err
48901 }
48902 reqHeaders.Set("Content-Type", "application/json")
48903 c.urlParams_.Set("alt", alt)
48904 c.urlParams_.Set("prettyPrint", "false")
48905 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/targetingTemplates")
48906 urls += "?" + c.urlParams_.Encode()
48907 req, err := http.NewRequest("PUT", urls, body)
48908 if err != nil {
48909 return nil, err
48910 }
48911 req.Header = reqHeaders
48912 googleapi.Expand(req.URL, map[string]string{
48913 "profileId": strconv.FormatInt(c.profileId, 10),
48914 })
48915 return gensupport.SendRequest(c.ctx_, c.s.client, req)
48916 }
48917
48918
48919
48920
48921
48922
48923
48924
48925 func (c *TargetingTemplatesUpdateCall) Do(opts ...googleapi.CallOption) (*TargetingTemplate, error) {
48926 gensupport.SetOptions(c.urlParams_, opts...)
48927 res, err := c.doRequest("json")
48928 if res != nil && res.StatusCode == http.StatusNotModified {
48929 if res.Body != nil {
48930 res.Body.Close()
48931 }
48932 return nil, &googleapi.Error{
48933 Code: res.StatusCode,
48934 Header: res.Header,
48935 }
48936 }
48937 if err != nil {
48938 return nil, err
48939 }
48940 defer googleapi.CloseBody(res)
48941 if err := googleapi.CheckResponse(res); err != nil {
48942 return nil, err
48943 }
48944 ret := &TargetingTemplate{
48945 ServerResponse: googleapi.ServerResponse{
48946 Header: res.Header,
48947 HTTPStatusCode: res.StatusCode,
48948 },
48949 }
48950 target := &ret
48951 if err := gensupport.DecodeResponse(target, res); err != nil {
48952 return nil, err
48953 }
48954 return ret, nil
48955
48956
48957
48958
48959
48960
48961
48962
48963
48964
48965
48966
48967
48968
48969
48970
48971
48972
48973
48974
48975
48976
48977
48978
48979
48980
48981
48982
48983 }
48984
48985
48986
48987 type UserProfilesGetCall struct {
48988 s *Service
48989 profileId int64
48990 urlParams_ gensupport.URLParams
48991 ifNoneMatch_ string
48992 ctx_ context.Context
48993 header_ http.Header
48994 }
48995
48996
48997 func (r *UserProfilesService) Get(profileId int64) *UserProfilesGetCall {
48998 c := &UserProfilesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
48999 c.profileId = profileId
49000 return c
49001 }
49002
49003
49004
49005
49006 func (c *UserProfilesGetCall) Fields(s ...googleapi.Field) *UserProfilesGetCall {
49007 c.urlParams_.Set("fields", googleapi.CombineFields(s))
49008 return c
49009 }
49010
49011
49012
49013
49014
49015
49016 func (c *UserProfilesGetCall) IfNoneMatch(entityTag string) *UserProfilesGetCall {
49017 c.ifNoneMatch_ = entityTag
49018 return c
49019 }
49020
49021
49022
49023
49024 func (c *UserProfilesGetCall) Context(ctx context.Context) *UserProfilesGetCall {
49025 c.ctx_ = ctx
49026 return c
49027 }
49028
49029
49030
49031 func (c *UserProfilesGetCall) Header() http.Header {
49032 if c.header_ == nil {
49033 c.header_ = make(http.Header)
49034 }
49035 return c.header_
49036 }
49037
49038 func (c *UserProfilesGetCall) doRequest(alt string) (*http.Response, error) {
49039 reqHeaders := make(http.Header)
49040 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
49041 for k, v := range c.header_ {
49042 reqHeaders[k] = v
49043 }
49044 reqHeaders.Set("User-Agent", c.s.userAgent())
49045 if c.ifNoneMatch_ != "" {
49046 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
49047 }
49048 var body io.Reader = nil
49049 c.urlParams_.Set("alt", alt)
49050 c.urlParams_.Set("prettyPrint", "false")
49051 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}")
49052 urls += "?" + c.urlParams_.Encode()
49053 req, err := http.NewRequest("GET", urls, body)
49054 if err != nil {
49055 return nil, err
49056 }
49057 req.Header = reqHeaders
49058 googleapi.Expand(req.URL, map[string]string{
49059 "profileId": strconv.FormatInt(c.profileId, 10),
49060 })
49061 return gensupport.SendRequest(c.ctx_, c.s.client, req)
49062 }
49063
49064
49065
49066
49067
49068
49069
49070
49071 func (c *UserProfilesGetCall) Do(opts ...googleapi.CallOption) (*UserProfile, error) {
49072 gensupport.SetOptions(c.urlParams_, opts...)
49073 res, err := c.doRequest("json")
49074 if res != nil && res.StatusCode == http.StatusNotModified {
49075 if res.Body != nil {
49076 res.Body.Close()
49077 }
49078 return nil, &googleapi.Error{
49079 Code: res.StatusCode,
49080 Header: res.Header,
49081 }
49082 }
49083 if err != nil {
49084 return nil, err
49085 }
49086 defer googleapi.CloseBody(res)
49087 if err := googleapi.CheckResponse(res); err != nil {
49088 return nil, err
49089 }
49090 ret := &UserProfile{
49091 ServerResponse: googleapi.ServerResponse{
49092 Header: res.Header,
49093 HTTPStatusCode: res.StatusCode,
49094 },
49095 }
49096 target := &ret
49097 if err := gensupport.DecodeResponse(target, res); err != nil {
49098 return nil, err
49099 }
49100 return ret, nil
49101
49102
49103
49104
49105
49106
49107
49108
49109
49110
49111
49112
49113
49114
49115
49116
49117
49118
49119
49120
49121
49122
49123
49124
49125
49126
49127 }
49128
49129
49130
49131 type UserProfilesListCall struct {
49132 s *Service
49133 urlParams_ gensupport.URLParams
49134 ifNoneMatch_ string
49135 ctx_ context.Context
49136 header_ http.Header
49137 }
49138
49139
49140 func (r *UserProfilesService) List() *UserProfilesListCall {
49141 c := &UserProfilesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
49142 return c
49143 }
49144
49145
49146
49147
49148 func (c *UserProfilesListCall) Fields(s ...googleapi.Field) *UserProfilesListCall {
49149 c.urlParams_.Set("fields", googleapi.CombineFields(s))
49150 return c
49151 }
49152
49153
49154
49155
49156
49157
49158 func (c *UserProfilesListCall) IfNoneMatch(entityTag string) *UserProfilesListCall {
49159 c.ifNoneMatch_ = entityTag
49160 return c
49161 }
49162
49163
49164
49165
49166 func (c *UserProfilesListCall) Context(ctx context.Context) *UserProfilesListCall {
49167 c.ctx_ = ctx
49168 return c
49169 }
49170
49171
49172
49173 func (c *UserProfilesListCall) Header() http.Header {
49174 if c.header_ == nil {
49175 c.header_ = make(http.Header)
49176 }
49177 return c.header_
49178 }
49179
49180 func (c *UserProfilesListCall) doRequest(alt string) (*http.Response, error) {
49181 reqHeaders := make(http.Header)
49182 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
49183 for k, v := range c.header_ {
49184 reqHeaders[k] = v
49185 }
49186 reqHeaders.Set("User-Agent", c.s.userAgent())
49187 if c.ifNoneMatch_ != "" {
49188 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
49189 }
49190 var body io.Reader = nil
49191 c.urlParams_.Set("alt", alt)
49192 c.urlParams_.Set("prettyPrint", "false")
49193 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles")
49194 urls += "?" + c.urlParams_.Encode()
49195 req, err := http.NewRequest("GET", urls, body)
49196 if err != nil {
49197 return nil, err
49198 }
49199 req.Header = reqHeaders
49200 return gensupport.SendRequest(c.ctx_, c.s.client, req)
49201 }
49202
49203
49204
49205
49206
49207
49208
49209
49210 func (c *UserProfilesListCall) Do(opts ...googleapi.CallOption) (*UserProfileList, error) {
49211 gensupport.SetOptions(c.urlParams_, opts...)
49212 res, err := c.doRequest("json")
49213 if res != nil && res.StatusCode == http.StatusNotModified {
49214 if res.Body != nil {
49215 res.Body.Close()
49216 }
49217 return nil, &googleapi.Error{
49218 Code: res.StatusCode,
49219 Header: res.Header,
49220 }
49221 }
49222 if err != nil {
49223 return nil, err
49224 }
49225 defer googleapi.CloseBody(res)
49226 if err := googleapi.CheckResponse(res); err != nil {
49227 return nil, err
49228 }
49229 ret := &UserProfileList{
49230 ServerResponse: googleapi.ServerResponse{
49231 Header: res.Header,
49232 HTTPStatusCode: res.StatusCode,
49233 },
49234 }
49235 target := &ret
49236 if err := gensupport.DecodeResponse(target, res); err != nil {
49237 return nil, err
49238 }
49239 return ret, nil
49240
49241
49242
49243
49244
49245
49246
49247
49248
49249
49250
49251
49252
49253
49254 }
49255
49256
49257
49258 type UserRolePermissionGroupsGetCall struct {
49259 s *Service
49260 profileId int64
49261 id int64
49262 urlParams_ gensupport.URLParams
49263 ifNoneMatch_ string
49264 ctx_ context.Context
49265 header_ http.Header
49266 }
49267
49268
49269 func (r *UserRolePermissionGroupsService) Get(profileId int64, id int64) *UserRolePermissionGroupsGetCall {
49270 c := &UserRolePermissionGroupsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
49271 c.profileId = profileId
49272 c.id = id
49273 return c
49274 }
49275
49276
49277
49278
49279 func (c *UserRolePermissionGroupsGetCall) Fields(s ...googleapi.Field) *UserRolePermissionGroupsGetCall {
49280 c.urlParams_.Set("fields", googleapi.CombineFields(s))
49281 return c
49282 }
49283
49284
49285
49286
49287
49288
49289 func (c *UserRolePermissionGroupsGetCall) IfNoneMatch(entityTag string) *UserRolePermissionGroupsGetCall {
49290 c.ifNoneMatch_ = entityTag
49291 return c
49292 }
49293
49294
49295
49296
49297 func (c *UserRolePermissionGroupsGetCall) Context(ctx context.Context) *UserRolePermissionGroupsGetCall {
49298 c.ctx_ = ctx
49299 return c
49300 }
49301
49302
49303
49304 func (c *UserRolePermissionGroupsGetCall) Header() http.Header {
49305 if c.header_ == nil {
49306 c.header_ = make(http.Header)
49307 }
49308 return c.header_
49309 }
49310
49311 func (c *UserRolePermissionGroupsGetCall) doRequest(alt string) (*http.Response, error) {
49312 reqHeaders := make(http.Header)
49313 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
49314 for k, v := range c.header_ {
49315 reqHeaders[k] = v
49316 }
49317 reqHeaders.Set("User-Agent", c.s.userAgent())
49318 if c.ifNoneMatch_ != "" {
49319 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
49320 }
49321 var body io.Reader = nil
49322 c.urlParams_.Set("alt", alt)
49323 c.urlParams_.Set("prettyPrint", "false")
49324 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/userRolePermissionGroups/{id}")
49325 urls += "?" + c.urlParams_.Encode()
49326 req, err := http.NewRequest("GET", urls, body)
49327 if err != nil {
49328 return nil, err
49329 }
49330 req.Header = reqHeaders
49331 googleapi.Expand(req.URL, map[string]string{
49332 "profileId": strconv.FormatInt(c.profileId, 10),
49333 "id": strconv.FormatInt(c.id, 10),
49334 })
49335 return gensupport.SendRequest(c.ctx_, c.s.client, req)
49336 }
49337
49338
49339
49340
49341
49342
49343
49344
49345 func (c *UserRolePermissionGroupsGetCall) Do(opts ...googleapi.CallOption) (*UserRolePermissionGroup, error) {
49346 gensupport.SetOptions(c.urlParams_, opts...)
49347 res, err := c.doRequest("json")
49348 if res != nil && res.StatusCode == http.StatusNotModified {
49349 if res.Body != nil {
49350 res.Body.Close()
49351 }
49352 return nil, &googleapi.Error{
49353 Code: res.StatusCode,
49354 Header: res.Header,
49355 }
49356 }
49357 if err != nil {
49358 return nil, err
49359 }
49360 defer googleapi.CloseBody(res)
49361 if err := googleapi.CheckResponse(res); err != nil {
49362 return nil, err
49363 }
49364 ret := &UserRolePermissionGroup{
49365 ServerResponse: googleapi.ServerResponse{
49366 Header: res.Header,
49367 HTTPStatusCode: res.StatusCode,
49368 },
49369 }
49370 target := &ret
49371 if err := gensupport.DecodeResponse(target, res); err != nil {
49372 return nil, err
49373 }
49374 return ret, nil
49375
49376
49377
49378
49379
49380
49381
49382
49383
49384
49385
49386
49387
49388
49389
49390
49391
49392
49393
49394
49395
49396
49397
49398
49399
49400
49401
49402
49403
49404
49405
49406
49407
49408 }
49409
49410
49411
49412 type UserRolePermissionGroupsListCall struct {
49413 s *Service
49414 profileId int64
49415 urlParams_ gensupport.URLParams
49416 ifNoneMatch_ string
49417 ctx_ context.Context
49418 header_ http.Header
49419 }
49420
49421
49422 func (r *UserRolePermissionGroupsService) List(profileId int64) *UserRolePermissionGroupsListCall {
49423 c := &UserRolePermissionGroupsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
49424 c.profileId = profileId
49425 return c
49426 }
49427
49428
49429
49430
49431 func (c *UserRolePermissionGroupsListCall) Fields(s ...googleapi.Field) *UserRolePermissionGroupsListCall {
49432 c.urlParams_.Set("fields", googleapi.CombineFields(s))
49433 return c
49434 }
49435
49436
49437
49438
49439
49440
49441 func (c *UserRolePermissionGroupsListCall) IfNoneMatch(entityTag string) *UserRolePermissionGroupsListCall {
49442 c.ifNoneMatch_ = entityTag
49443 return c
49444 }
49445
49446
49447
49448
49449 func (c *UserRolePermissionGroupsListCall) Context(ctx context.Context) *UserRolePermissionGroupsListCall {
49450 c.ctx_ = ctx
49451 return c
49452 }
49453
49454
49455
49456 func (c *UserRolePermissionGroupsListCall) Header() http.Header {
49457 if c.header_ == nil {
49458 c.header_ = make(http.Header)
49459 }
49460 return c.header_
49461 }
49462
49463 func (c *UserRolePermissionGroupsListCall) doRequest(alt string) (*http.Response, error) {
49464 reqHeaders := make(http.Header)
49465 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
49466 for k, v := range c.header_ {
49467 reqHeaders[k] = v
49468 }
49469 reqHeaders.Set("User-Agent", c.s.userAgent())
49470 if c.ifNoneMatch_ != "" {
49471 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
49472 }
49473 var body io.Reader = nil
49474 c.urlParams_.Set("alt", alt)
49475 c.urlParams_.Set("prettyPrint", "false")
49476 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/userRolePermissionGroups")
49477 urls += "?" + c.urlParams_.Encode()
49478 req, err := http.NewRequest("GET", urls, body)
49479 if err != nil {
49480 return nil, err
49481 }
49482 req.Header = reqHeaders
49483 googleapi.Expand(req.URL, map[string]string{
49484 "profileId": strconv.FormatInt(c.profileId, 10),
49485 })
49486 return gensupport.SendRequest(c.ctx_, c.s.client, req)
49487 }
49488
49489
49490
49491
49492
49493
49494
49495
49496
49497 func (c *UserRolePermissionGroupsListCall) Do(opts ...googleapi.CallOption) (*UserRolePermissionGroupsListResponse, error) {
49498 gensupport.SetOptions(c.urlParams_, opts...)
49499 res, err := c.doRequest("json")
49500 if res != nil && res.StatusCode == http.StatusNotModified {
49501 if res.Body != nil {
49502 res.Body.Close()
49503 }
49504 return nil, &googleapi.Error{
49505 Code: res.StatusCode,
49506 Header: res.Header,
49507 }
49508 }
49509 if err != nil {
49510 return nil, err
49511 }
49512 defer googleapi.CloseBody(res)
49513 if err := googleapi.CheckResponse(res); err != nil {
49514 return nil, err
49515 }
49516 ret := &UserRolePermissionGroupsListResponse{
49517 ServerResponse: googleapi.ServerResponse{
49518 Header: res.Header,
49519 HTTPStatusCode: res.StatusCode,
49520 },
49521 }
49522 target := &ret
49523 if err := gensupport.DecodeResponse(target, res); err != nil {
49524 return nil, err
49525 }
49526 return ret, nil
49527
49528
49529
49530
49531
49532
49533
49534
49535
49536
49537
49538
49539
49540
49541
49542
49543
49544
49545
49546
49547
49548
49549
49550
49551
49552 }
49553
49554
49555
49556 type UserRolePermissionsGetCall struct {
49557 s *Service
49558 profileId int64
49559 id int64
49560 urlParams_ gensupport.URLParams
49561 ifNoneMatch_ string
49562 ctx_ context.Context
49563 header_ http.Header
49564 }
49565
49566
49567 func (r *UserRolePermissionsService) Get(profileId int64, id int64) *UserRolePermissionsGetCall {
49568 c := &UserRolePermissionsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
49569 c.profileId = profileId
49570 c.id = id
49571 return c
49572 }
49573
49574
49575
49576
49577 func (c *UserRolePermissionsGetCall) Fields(s ...googleapi.Field) *UserRolePermissionsGetCall {
49578 c.urlParams_.Set("fields", googleapi.CombineFields(s))
49579 return c
49580 }
49581
49582
49583
49584
49585
49586
49587 func (c *UserRolePermissionsGetCall) IfNoneMatch(entityTag string) *UserRolePermissionsGetCall {
49588 c.ifNoneMatch_ = entityTag
49589 return c
49590 }
49591
49592
49593
49594
49595 func (c *UserRolePermissionsGetCall) Context(ctx context.Context) *UserRolePermissionsGetCall {
49596 c.ctx_ = ctx
49597 return c
49598 }
49599
49600
49601
49602 func (c *UserRolePermissionsGetCall) Header() http.Header {
49603 if c.header_ == nil {
49604 c.header_ = make(http.Header)
49605 }
49606 return c.header_
49607 }
49608
49609 func (c *UserRolePermissionsGetCall) doRequest(alt string) (*http.Response, error) {
49610 reqHeaders := make(http.Header)
49611 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
49612 for k, v := range c.header_ {
49613 reqHeaders[k] = v
49614 }
49615 reqHeaders.Set("User-Agent", c.s.userAgent())
49616 if c.ifNoneMatch_ != "" {
49617 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
49618 }
49619 var body io.Reader = nil
49620 c.urlParams_.Set("alt", alt)
49621 c.urlParams_.Set("prettyPrint", "false")
49622 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/userRolePermissions/{id}")
49623 urls += "?" + c.urlParams_.Encode()
49624 req, err := http.NewRequest("GET", urls, body)
49625 if err != nil {
49626 return nil, err
49627 }
49628 req.Header = reqHeaders
49629 googleapi.Expand(req.URL, map[string]string{
49630 "profileId": strconv.FormatInt(c.profileId, 10),
49631 "id": strconv.FormatInt(c.id, 10),
49632 })
49633 return gensupport.SendRequest(c.ctx_, c.s.client, req)
49634 }
49635
49636
49637
49638
49639
49640
49641
49642
49643 func (c *UserRolePermissionsGetCall) Do(opts ...googleapi.CallOption) (*UserRolePermission, error) {
49644 gensupport.SetOptions(c.urlParams_, opts...)
49645 res, err := c.doRequest("json")
49646 if res != nil && res.StatusCode == http.StatusNotModified {
49647 if res.Body != nil {
49648 res.Body.Close()
49649 }
49650 return nil, &googleapi.Error{
49651 Code: res.StatusCode,
49652 Header: res.Header,
49653 }
49654 }
49655 if err != nil {
49656 return nil, err
49657 }
49658 defer googleapi.CloseBody(res)
49659 if err := googleapi.CheckResponse(res); err != nil {
49660 return nil, err
49661 }
49662 ret := &UserRolePermission{
49663 ServerResponse: googleapi.ServerResponse{
49664 Header: res.Header,
49665 HTTPStatusCode: res.StatusCode,
49666 },
49667 }
49668 target := &ret
49669 if err := gensupport.DecodeResponse(target, res); err != nil {
49670 return nil, err
49671 }
49672 return ret, nil
49673
49674
49675
49676
49677
49678
49679
49680
49681
49682
49683
49684
49685
49686
49687
49688
49689
49690
49691
49692
49693
49694
49695
49696
49697
49698
49699
49700
49701
49702
49703
49704
49705
49706 }
49707
49708
49709
49710 type UserRolePermissionsListCall struct {
49711 s *Service
49712 profileId int64
49713 urlParams_ gensupport.URLParams
49714 ifNoneMatch_ string
49715 ctx_ context.Context
49716 header_ http.Header
49717 }
49718
49719
49720 func (r *UserRolePermissionsService) List(profileId int64) *UserRolePermissionsListCall {
49721 c := &UserRolePermissionsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
49722 c.profileId = profileId
49723 return c
49724 }
49725
49726
49727
49728 func (c *UserRolePermissionsListCall) Ids(ids ...int64) *UserRolePermissionsListCall {
49729 var ids_ []string
49730 for _, v := range ids {
49731 ids_ = append(ids_, fmt.Sprint(v))
49732 }
49733 c.urlParams_.SetMulti("ids", ids_)
49734 return c
49735 }
49736
49737
49738
49739
49740 func (c *UserRolePermissionsListCall) Fields(s ...googleapi.Field) *UserRolePermissionsListCall {
49741 c.urlParams_.Set("fields", googleapi.CombineFields(s))
49742 return c
49743 }
49744
49745
49746
49747
49748
49749
49750 func (c *UserRolePermissionsListCall) IfNoneMatch(entityTag string) *UserRolePermissionsListCall {
49751 c.ifNoneMatch_ = entityTag
49752 return c
49753 }
49754
49755
49756
49757
49758 func (c *UserRolePermissionsListCall) Context(ctx context.Context) *UserRolePermissionsListCall {
49759 c.ctx_ = ctx
49760 return c
49761 }
49762
49763
49764
49765 func (c *UserRolePermissionsListCall) Header() http.Header {
49766 if c.header_ == nil {
49767 c.header_ = make(http.Header)
49768 }
49769 return c.header_
49770 }
49771
49772 func (c *UserRolePermissionsListCall) doRequest(alt string) (*http.Response, error) {
49773 reqHeaders := make(http.Header)
49774 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
49775 for k, v := range c.header_ {
49776 reqHeaders[k] = v
49777 }
49778 reqHeaders.Set("User-Agent", c.s.userAgent())
49779 if c.ifNoneMatch_ != "" {
49780 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
49781 }
49782 var body io.Reader = nil
49783 c.urlParams_.Set("alt", alt)
49784 c.urlParams_.Set("prettyPrint", "false")
49785 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/userRolePermissions")
49786 urls += "?" + c.urlParams_.Encode()
49787 req, err := http.NewRequest("GET", urls, body)
49788 if err != nil {
49789 return nil, err
49790 }
49791 req.Header = reqHeaders
49792 googleapi.Expand(req.URL, map[string]string{
49793 "profileId": strconv.FormatInt(c.profileId, 10),
49794 })
49795 return gensupport.SendRequest(c.ctx_, c.s.client, req)
49796 }
49797
49798
49799
49800
49801
49802
49803
49804
49805 func (c *UserRolePermissionsListCall) Do(opts ...googleapi.CallOption) (*UserRolePermissionsListResponse, error) {
49806 gensupport.SetOptions(c.urlParams_, opts...)
49807 res, err := c.doRequest("json")
49808 if res != nil && res.StatusCode == http.StatusNotModified {
49809 if res.Body != nil {
49810 res.Body.Close()
49811 }
49812 return nil, &googleapi.Error{
49813 Code: res.StatusCode,
49814 Header: res.Header,
49815 }
49816 }
49817 if err != nil {
49818 return nil, err
49819 }
49820 defer googleapi.CloseBody(res)
49821 if err := googleapi.CheckResponse(res); err != nil {
49822 return nil, err
49823 }
49824 ret := &UserRolePermissionsListResponse{
49825 ServerResponse: googleapi.ServerResponse{
49826 Header: res.Header,
49827 HTTPStatusCode: res.StatusCode,
49828 },
49829 }
49830 target := &ret
49831 if err := gensupport.DecodeResponse(target, res); err != nil {
49832 return nil, err
49833 }
49834 return ret, nil
49835
49836
49837
49838
49839
49840
49841
49842
49843
49844
49845
49846
49847
49848
49849
49850
49851
49852
49853
49854
49855
49856
49857
49858
49859
49860
49861
49862
49863
49864
49865
49866
49867 }
49868
49869
49870
49871 type UserRolesDeleteCall struct {
49872 s *Service
49873 profileId int64
49874 id int64
49875 urlParams_ gensupport.URLParams
49876 ctx_ context.Context
49877 header_ http.Header
49878 }
49879
49880
49881 func (r *UserRolesService) Delete(profileId int64, id int64) *UserRolesDeleteCall {
49882 c := &UserRolesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
49883 c.profileId = profileId
49884 c.id = id
49885 return c
49886 }
49887
49888
49889
49890
49891 func (c *UserRolesDeleteCall) Fields(s ...googleapi.Field) *UserRolesDeleteCall {
49892 c.urlParams_.Set("fields", googleapi.CombineFields(s))
49893 return c
49894 }
49895
49896
49897
49898
49899 func (c *UserRolesDeleteCall) Context(ctx context.Context) *UserRolesDeleteCall {
49900 c.ctx_ = ctx
49901 return c
49902 }
49903
49904
49905
49906 func (c *UserRolesDeleteCall) Header() http.Header {
49907 if c.header_ == nil {
49908 c.header_ = make(http.Header)
49909 }
49910 return c.header_
49911 }
49912
49913 func (c *UserRolesDeleteCall) doRequest(alt string) (*http.Response, error) {
49914 reqHeaders := make(http.Header)
49915 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
49916 for k, v := range c.header_ {
49917 reqHeaders[k] = v
49918 }
49919 reqHeaders.Set("User-Agent", c.s.userAgent())
49920 var body io.Reader = nil
49921 c.urlParams_.Set("alt", alt)
49922 c.urlParams_.Set("prettyPrint", "false")
49923 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/userRoles/{id}")
49924 urls += "?" + c.urlParams_.Encode()
49925 req, err := http.NewRequest("DELETE", urls, body)
49926 if err != nil {
49927 return nil, err
49928 }
49929 req.Header = reqHeaders
49930 googleapi.Expand(req.URL, map[string]string{
49931 "profileId": strconv.FormatInt(c.profileId, 10),
49932 "id": strconv.FormatInt(c.id, 10),
49933 })
49934 return gensupport.SendRequest(c.ctx_, c.s.client, req)
49935 }
49936
49937
49938 func (c *UserRolesDeleteCall) Do(opts ...googleapi.CallOption) error {
49939 gensupport.SetOptions(c.urlParams_, opts...)
49940 res, err := c.doRequest("json")
49941 if err != nil {
49942 return err
49943 }
49944 defer googleapi.CloseBody(res)
49945 if err := googleapi.CheckResponse(res); err != nil {
49946 return err
49947 }
49948 return nil
49949
49950
49951
49952
49953
49954
49955
49956
49957
49958
49959
49960
49961
49962
49963
49964
49965
49966
49967
49968
49969
49970
49971
49972
49973
49974
49975
49976
49977
49978
49979 }
49980
49981
49982
49983 type UserRolesGetCall struct {
49984 s *Service
49985 profileId int64
49986 id int64
49987 urlParams_ gensupport.URLParams
49988 ifNoneMatch_ string
49989 ctx_ context.Context
49990 header_ http.Header
49991 }
49992
49993
49994 func (r *UserRolesService) Get(profileId int64, id int64) *UserRolesGetCall {
49995 c := &UserRolesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
49996 c.profileId = profileId
49997 c.id = id
49998 return c
49999 }
50000
50001
50002
50003
50004 func (c *UserRolesGetCall) Fields(s ...googleapi.Field) *UserRolesGetCall {
50005 c.urlParams_.Set("fields", googleapi.CombineFields(s))
50006 return c
50007 }
50008
50009
50010
50011
50012
50013
50014 func (c *UserRolesGetCall) IfNoneMatch(entityTag string) *UserRolesGetCall {
50015 c.ifNoneMatch_ = entityTag
50016 return c
50017 }
50018
50019
50020
50021
50022 func (c *UserRolesGetCall) Context(ctx context.Context) *UserRolesGetCall {
50023 c.ctx_ = ctx
50024 return c
50025 }
50026
50027
50028
50029 func (c *UserRolesGetCall) Header() http.Header {
50030 if c.header_ == nil {
50031 c.header_ = make(http.Header)
50032 }
50033 return c.header_
50034 }
50035
50036 func (c *UserRolesGetCall) doRequest(alt string) (*http.Response, error) {
50037 reqHeaders := make(http.Header)
50038 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
50039 for k, v := range c.header_ {
50040 reqHeaders[k] = v
50041 }
50042 reqHeaders.Set("User-Agent", c.s.userAgent())
50043 if c.ifNoneMatch_ != "" {
50044 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
50045 }
50046 var body io.Reader = nil
50047 c.urlParams_.Set("alt", alt)
50048 c.urlParams_.Set("prettyPrint", "false")
50049 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/userRoles/{id}")
50050 urls += "?" + c.urlParams_.Encode()
50051 req, err := http.NewRequest("GET", urls, body)
50052 if err != nil {
50053 return nil, err
50054 }
50055 req.Header = reqHeaders
50056 googleapi.Expand(req.URL, map[string]string{
50057 "profileId": strconv.FormatInt(c.profileId, 10),
50058 "id": strconv.FormatInt(c.id, 10),
50059 })
50060 return gensupport.SendRequest(c.ctx_, c.s.client, req)
50061 }
50062
50063
50064
50065
50066
50067
50068
50069
50070 func (c *UserRolesGetCall) Do(opts ...googleapi.CallOption) (*UserRole, error) {
50071 gensupport.SetOptions(c.urlParams_, opts...)
50072 res, err := c.doRequest("json")
50073 if res != nil && res.StatusCode == http.StatusNotModified {
50074 if res.Body != nil {
50075 res.Body.Close()
50076 }
50077 return nil, &googleapi.Error{
50078 Code: res.StatusCode,
50079 Header: res.Header,
50080 }
50081 }
50082 if err != nil {
50083 return nil, err
50084 }
50085 defer googleapi.CloseBody(res)
50086 if err := googleapi.CheckResponse(res); err != nil {
50087 return nil, err
50088 }
50089 ret := &UserRole{
50090 ServerResponse: googleapi.ServerResponse{
50091 Header: res.Header,
50092 HTTPStatusCode: res.StatusCode,
50093 },
50094 }
50095 target := &ret
50096 if err := gensupport.DecodeResponse(target, res); err != nil {
50097 return nil, err
50098 }
50099 return ret, nil
50100
50101
50102
50103
50104
50105
50106
50107
50108
50109
50110
50111
50112
50113
50114
50115
50116
50117
50118
50119
50120
50121
50122
50123
50124
50125
50126
50127
50128
50129
50130
50131
50132
50133 }
50134
50135
50136
50137 type UserRolesInsertCall struct {
50138 s *Service
50139 profileId int64
50140 userrole *UserRole
50141 urlParams_ gensupport.URLParams
50142 ctx_ context.Context
50143 header_ http.Header
50144 }
50145
50146
50147 func (r *UserRolesService) Insert(profileId int64, userrole *UserRole) *UserRolesInsertCall {
50148 c := &UserRolesInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
50149 c.profileId = profileId
50150 c.userrole = userrole
50151 return c
50152 }
50153
50154
50155
50156
50157 func (c *UserRolesInsertCall) Fields(s ...googleapi.Field) *UserRolesInsertCall {
50158 c.urlParams_.Set("fields", googleapi.CombineFields(s))
50159 return c
50160 }
50161
50162
50163
50164
50165 func (c *UserRolesInsertCall) Context(ctx context.Context) *UserRolesInsertCall {
50166 c.ctx_ = ctx
50167 return c
50168 }
50169
50170
50171
50172 func (c *UserRolesInsertCall) Header() http.Header {
50173 if c.header_ == nil {
50174 c.header_ = make(http.Header)
50175 }
50176 return c.header_
50177 }
50178
50179 func (c *UserRolesInsertCall) doRequest(alt string) (*http.Response, error) {
50180 reqHeaders := make(http.Header)
50181 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
50182 for k, v := range c.header_ {
50183 reqHeaders[k] = v
50184 }
50185 reqHeaders.Set("User-Agent", c.s.userAgent())
50186 var body io.Reader = nil
50187 body, err := googleapi.WithoutDataWrapper.JSONReader(c.userrole)
50188 if err != nil {
50189 return nil, err
50190 }
50191 reqHeaders.Set("Content-Type", "application/json")
50192 c.urlParams_.Set("alt", alt)
50193 c.urlParams_.Set("prettyPrint", "false")
50194 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/userRoles")
50195 urls += "?" + c.urlParams_.Encode()
50196 req, err := http.NewRequest("POST", urls, body)
50197 if err != nil {
50198 return nil, err
50199 }
50200 req.Header = reqHeaders
50201 googleapi.Expand(req.URL, map[string]string{
50202 "profileId": strconv.FormatInt(c.profileId, 10),
50203 })
50204 return gensupport.SendRequest(c.ctx_, c.s.client, req)
50205 }
50206
50207
50208
50209
50210
50211
50212
50213
50214 func (c *UserRolesInsertCall) Do(opts ...googleapi.CallOption) (*UserRole, error) {
50215 gensupport.SetOptions(c.urlParams_, opts...)
50216 res, err := c.doRequest("json")
50217 if res != nil && res.StatusCode == http.StatusNotModified {
50218 if res.Body != nil {
50219 res.Body.Close()
50220 }
50221 return nil, &googleapi.Error{
50222 Code: res.StatusCode,
50223 Header: res.Header,
50224 }
50225 }
50226 if err != nil {
50227 return nil, err
50228 }
50229 defer googleapi.CloseBody(res)
50230 if err := googleapi.CheckResponse(res); err != nil {
50231 return nil, err
50232 }
50233 ret := &UserRole{
50234 ServerResponse: googleapi.ServerResponse{
50235 Header: res.Header,
50236 HTTPStatusCode: res.StatusCode,
50237 },
50238 }
50239 target := &ret
50240 if err := gensupport.DecodeResponse(target, res); err != nil {
50241 return nil, err
50242 }
50243 return ret, nil
50244
50245
50246
50247
50248
50249
50250
50251
50252
50253
50254
50255
50256
50257
50258
50259
50260
50261
50262
50263
50264
50265
50266
50267
50268
50269
50270
50271
50272 }
50273
50274
50275
50276 type UserRolesListCall struct {
50277 s *Service
50278 profileId int64
50279 urlParams_ gensupport.URLParams
50280 ifNoneMatch_ string
50281 ctx_ context.Context
50282 header_ http.Header
50283 }
50284
50285
50286
50287 func (r *UserRolesService) List(profileId int64) *UserRolesListCall {
50288 c := &UserRolesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
50289 c.profileId = profileId
50290 return c
50291 }
50292
50293
50294
50295
50296 func (c *UserRolesListCall) AccountUserRoleOnly(accountUserRoleOnly bool) *UserRolesListCall {
50297 c.urlParams_.Set("accountUserRoleOnly", fmt.Sprint(accountUserRoleOnly))
50298 return c
50299 }
50300
50301
50302
50303 func (c *UserRolesListCall) Ids(ids ...int64) *UserRolesListCall {
50304 var ids_ []string
50305 for _, v := range ids {
50306 ids_ = append(ids_, fmt.Sprint(v))
50307 }
50308 c.urlParams_.SetMulti("ids", ids_)
50309 return c
50310 }
50311
50312
50313
50314 func (c *UserRolesListCall) MaxResults(maxResults int64) *UserRolesListCall {
50315 c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
50316 return c
50317 }
50318
50319
50320
50321 func (c *UserRolesListCall) PageToken(pageToken string) *UserRolesListCall {
50322 c.urlParams_.Set("pageToken", pageToken)
50323 return c
50324 }
50325
50326
50327
50328
50329
50330
50331
50332
50333
50334 func (c *UserRolesListCall) SearchString(searchString string) *UserRolesListCall {
50335 c.urlParams_.Set("searchString", searchString)
50336 return c
50337 }
50338
50339
50340
50341
50342
50343
50344
50345
50346 func (c *UserRolesListCall) SortField(sortField string) *UserRolesListCall {
50347 c.urlParams_.Set("sortField", sortField)
50348 return c
50349 }
50350
50351
50352
50353
50354
50355
50356
50357
50358 func (c *UserRolesListCall) SortOrder(sortOrder string) *UserRolesListCall {
50359 c.urlParams_.Set("sortOrder", sortOrder)
50360 return c
50361 }
50362
50363
50364
50365 func (c *UserRolesListCall) SubaccountId(subaccountId int64) *UserRolesListCall {
50366 c.urlParams_.Set("subaccountId", fmt.Sprint(subaccountId))
50367 return c
50368 }
50369
50370
50371
50372
50373 func (c *UserRolesListCall) Fields(s ...googleapi.Field) *UserRolesListCall {
50374 c.urlParams_.Set("fields", googleapi.CombineFields(s))
50375 return c
50376 }
50377
50378
50379
50380
50381
50382
50383 func (c *UserRolesListCall) IfNoneMatch(entityTag string) *UserRolesListCall {
50384 c.ifNoneMatch_ = entityTag
50385 return c
50386 }
50387
50388
50389
50390
50391 func (c *UserRolesListCall) Context(ctx context.Context) *UserRolesListCall {
50392 c.ctx_ = ctx
50393 return c
50394 }
50395
50396
50397
50398 func (c *UserRolesListCall) Header() http.Header {
50399 if c.header_ == nil {
50400 c.header_ = make(http.Header)
50401 }
50402 return c.header_
50403 }
50404
50405 func (c *UserRolesListCall) doRequest(alt string) (*http.Response, error) {
50406 reqHeaders := make(http.Header)
50407 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
50408 for k, v := range c.header_ {
50409 reqHeaders[k] = v
50410 }
50411 reqHeaders.Set("User-Agent", c.s.userAgent())
50412 if c.ifNoneMatch_ != "" {
50413 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
50414 }
50415 var body io.Reader = nil
50416 c.urlParams_.Set("alt", alt)
50417 c.urlParams_.Set("prettyPrint", "false")
50418 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/userRoles")
50419 urls += "?" + c.urlParams_.Encode()
50420 req, err := http.NewRequest("GET", urls, body)
50421 if err != nil {
50422 return nil, err
50423 }
50424 req.Header = reqHeaders
50425 googleapi.Expand(req.URL, map[string]string{
50426 "profileId": strconv.FormatInt(c.profileId, 10),
50427 })
50428 return gensupport.SendRequest(c.ctx_, c.s.client, req)
50429 }
50430
50431
50432
50433
50434
50435
50436
50437
50438 func (c *UserRolesListCall) Do(opts ...googleapi.CallOption) (*UserRolesListResponse, error) {
50439 gensupport.SetOptions(c.urlParams_, opts...)
50440 res, err := c.doRequest("json")
50441 if res != nil && res.StatusCode == http.StatusNotModified {
50442 if res.Body != nil {
50443 res.Body.Close()
50444 }
50445 return nil, &googleapi.Error{
50446 Code: res.StatusCode,
50447 Header: res.Header,
50448 }
50449 }
50450 if err != nil {
50451 return nil, err
50452 }
50453 defer googleapi.CloseBody(res)
50454 if err := googleapi.CheckResponse(res); err != nil {
50455 return nil, err
50456 }
50457 ret := &UserRolesListResponse{
50458 ServerResponse: googleapi.ServerResponse{
50459 Header: res.Header,
50460 HTTPStatusCode: res.StatusCode,
50461 },
50462 }
50463 target := &ret
50464 if err := gensupport.DecodeResponse(target, res); err != nil {
50465 return nil, err
50466 }
50467 return ret, nil
50468
50469
50470
50471
50472
50473
50474
50475
50476
50477
50478
50479
50480
50481
50482
50483
50484
50485
50486
50487
50488
50489
50490
50491
50492
50493
50494
50495
50496
50497
50498
50499
50500
50501
50502
50503
50504
50505
50506
50507
50508
50509
50510
50511
50512
50513
50514
50515
50516
50517
50518
50519
50520
50521
50522
50523
50524
50525
50526
50527
50528
50529
50530
50531
50532
50533
50534
50535
50536
50537
50538
50539
50540
50541
50542
50543
50544
50545
50546
50547
50548
50549
50550
50551
50552
50553
50554
50555
50556
50557
50558 }
50559
50560
50561
50562
50563 func (c *UserRolesListCall) Pages(ctx context.Context, f func(*UserRolesListResponse) error) error {
50564 c.ctx_ = ctx
50565 defer c.PageToken(c.urlParams_.Get("pageToken"))
50566 for {
50567 x, err := c.Do()
50568 if err != nil {
50569 return err
50570 }
50571 if err := f(x); err != nil {
50572 return err
50573 }
50574 if x.NextPageToken == "" {
50575 return nil
50576 }
50577 c.PageToken(x.NextPageToken)
50578 }
50579 }
50580
50581
50582
50583 type UserRolesPatchCall struct {
50584 s *Service
50585 profileId int64
50586 userrole *UserRole
50587 urlParams_ gensupport.URLParams
50588 ctx_ context.Context
50589 header_ http.Header
50590 }
50591
50592
50593
50594 func (r *UserRolesService) Patch(profileId int64, id int64, userrole *UserRole) *UserRolesPatchCall {
50595 c := &UserRolesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
50596 c.profileId = profileId
50597 c.urlParams_.Set("id", fmt.Sprint(id))
50598 c.userrole = userrole
50599 return c
50600 }
50601
50602
50603
50604
50605 func (c *UserRolesPatchCall) Fields(s ...googleapi.Field) *UserRolesPatchCall {
50606 c.urlParams_.Set("fields", googleapi.CombineFields(s))
50607 return c
50608 }
50609
50610
50611
50612
50613 func (c *UserRolesPatchCall) Context(ctx context.Context) *UserRolesPatchCall {
50614 c.ctx_ = ctx
50615 return c
50616 }
50617
50618
50619
50620 func (c *UserRolesPatchCall) Header() http.Header {
50621 if c.header_ == nil {
50622 c.header_ = make(http.Header)
50623 }
50624 return c.header_
50625 }
50626
50627 func (c *UserRolesPatchCall) doRequest(alt string) (*http.Response, error) {
50628 reqHeaders := make(http.Header)
50629 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
50630 for k, v := range c.header_ {
50631 reqHeaders[k] = v
50632 }
50633 reqHeaders.Set("User-Agent", c.s.userAgent())
50634 var body io.Reader = nil
50635 body, err := googleapi.WithoutDataWrapper.JSONReader(c.userrole)
50636 if err != nil {
50637 return nil, err
50638 }
50639 reqHeaders.Set("Content-Type", "application/json")
50640 c.urlParams_.Set("alt", alt)
50641 c.urlParams_.Set("prettyPrint", "false")
50642 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/userRoles")
50643 urls += "?" + c.urlParams_.Encode()
50644 req, err := http.NewRequest("PATCH", urls, body)
50645 if err != nil {
50646 return nil, err
50647 }
50648 req.Header = reqHeaders
50649 googleapi.Expand(req.URL, map[string]string{
50650 "profileId": strconv.FormatInt(c.profileId, 10),
50651 })
50652 return gensupport.SendRequest(c.ctx_, c.s.client, req)
50653 }
50654
50655
50656
50657
50658
50659
50660
50661
50662 func (c *UserRolesPatchCall) Do(opts ...googleapi.CallOption) (*UserRole, error) {
50663 gensupport.SetOptions(c.urlParams_, opts...)
50664 res, err := c.doRequest("json")
50665 if res != nil && res.StatusCode == http.StatusNotModified {
50666 if res.Body != nil {
50667 res.Body.Close()
50668 }
50669 return nil, &googleapi.Error{
50670 Code: res.StatusCode,
50671 Header: res.Header,
50672 }
50673 }
50674 if err != nil {
50675 return nil, err
50676 }
50677 defer googleapi.CloseBody(res)
50678 if err := googleapi.CheckResponse(res); err != nil {
50679 return nil, err
50680 }
50681 ret := &UserRole{
50682 ServerResponse: googleapi.ServerResponse{
50683 Header: res.Header,
50684 HTTPStatusCode: res.StatusCode,
50685 },
50686 }
50687 target := &ret
50688 if err := gensupport.DecodeResponse(target, res); err != nil {
50689 return nil, err
50690 }
50691 return ret, nil
50692
50693
50694
50695
50696
50697
50698
50699
50700
50701
50702
50703
50704
50705
50706
50707
50708
50709
50710
50711
50712
50713
50714
50715
50716
50717
50718
50719
50720
50721
50722
50723
50724
50725
50726
50727
50728 }
50729
50730
50731
50732 type UserRolesUpdateCall struct {
50733 s *Service
50734 profileId int64
50735 userrole *UserRole
50736 urlParams_ gensupport.URLParams
50737 ctx_ context.Context
50738 header_ http.Header
50739 }
50740
50741
50742 func (r *UserRolesService) Update(profileId int64, userrole *UserRole) *UserRolesUpdateCall {
50743 c := &UserRolesUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
50744 c.profileId = profileId
50745 c.userrole = userrole
50746 return c
50747 }
50748
50749
50750
50751
50752 func (c *UserRolesUpdateCall) Fields(s ...googleapi.Field) *UserRolesUpdateCall {
50753 c.urlParams_.Set("fields", googleapi.CombineFields(s))
50754 return c
50755 }
50756
50757
50758
50759
50760 func (c *UserRolesUpdateCall) Context(ctx context.Context) *UserRolesUpdateCall {
50761 c.ctx_ = ctx
50762 return c
50763 }
50764
50765
50766
50767 func (c *UserRolesUpdateCall) Header() http.Header {
50768 if c.header_ == nil {
50769 c.header_ = make(http.Header)
50770 }
50771 return c.header_
50772 }
50773
50774 func (c *UserRolesUpdateCall) doRequest(alt string) (*http.Response, error) {
50775 reqHeaders := make(http.Header)
50776 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
50777 for k, v := range c.header_ {
50778 reqHeaders[k] = v
50779 }
50780 reqHeaders.Set("User-Agent", c.s.userAgent())
50781 var body io.Reader = nil
50782 body, err := googleapi.WithoutDataWrapper.JSONReader(c.userrole)
50783 if err != nil {
50784 return nil, err
50785 }
50786 reqHeaders.Set("Content-Type", "application/json")
50787 c.urlParams_.Set("alt", alt)
50788 c.urlParams_.Set("prettyPrint", "false")
50789 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/userRoles")
50790 urls += "?" + c.urlParams_.Encode()
50791 req, err := http.NewRequest("PUT", urls, body)
50792 if err != nil {
50793 return nil, err
50794 }
50795 req.Header = reqHeaders
50796 googleapi.Expand(req.URL, map[string]string{
50797 "profileId": strconv.FormatInt(c.profileId, 10),
50798 })
50799 return gensupport.SendRequest(c.ctx_, c.s.client, req)
50800 }
50801
50802
50803
50804
50805
50806
50807
50808
50809 func (c *UserRolesUpdateCall) Do(opts ...googleapi.CallOption) (*UserRole, error) {
50810 gensupport.SetOptions(c.urlParams_, opts...)
50811 res, err := c.doRequest("json")
50812 if res != nil && res.StatusCode == http.StatusNotModified {
50813 if res.Body != nil {
50814 res.Body.Close()
50815 }
50816 return nil, &googleapi.Error{
50817 Code: res.StatusCode,
50818 Header: res.Header,
50819 }
50820 }
50821 if err != nil {
50822 return nil, err
50823 }
50824 defer googleapi.CloseBody(res)
50825 if err := googleapi.CheckResponse(res); err != nil {
50826 return nil, err
50827 }
50828 ret := &UserRole{
50829 ServerResponse: googleapi.ServerResponse{
50830 Header: res.Header,
50831 HTTPStatusCode: res.StatusCode,
50832 },
50833 }
50834 target := &ret
50835 if err := gensupport.DecodeResponse(target, res); err != nil {
50836 return nil, err
50837 }
50838 return ret, nil
50839
50840
50841
50842
50843
50844
50845
50846
50847
50848
50849
50850
50851
50852
50853
50854
50855
50856
50857
50858
50859
50860
50861
50862
50863
50864
50865
50866
50867 }
50868
50869
50870
50871 type VideoFormatsGetCall struct {
50872 s *Service
50873 profileId int64
50874 id int64
50875 urlParams_ gensupport.URLParams
50876 ifNoneMatch_ string
50877 ctx_ context.Context
50878 header_ http.Header
50879 }
50880
50881
50882 func (r *VideoFormatsService) Get(profileId int64, id int64) *VideoFormatsGetCall {
50883 c := &VideoFormatsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
50884 c.profileId = profileId
50885 c.id = id
50886 return c
50887 }
50888
50889
50890
50891
50892 func (c *VideoFormatsGetCall) Fields(s ...googleapi.Field) *VideoFormatsGetCall {
50893 c.urlParams_.Set("fields", googleapi.CombineFields(s))
50894 return c
50895 }
50896
50897
50898
50899
50900
50901
50902 func (c *VideoFormatsGetCall) IfNoneMatch(entityTag string) *VideoFormatsGetCall {
50903 c.ifNoneMatch_ = entityTag
50904 return c
50905 }
50906
50907
50908
50909
50910 func (c *VideoFormatsGetCall) Context(ctx context.Context) *VideoFormatsGetCall {
50911 c.ctx_ = ctx
50912 return c
50913 }
50914
50915
50916
50917 func (c *VideoFormatsGetCall) Header() http.Header {
50918 if c.header_ == nil {
50919 c.header_ = make(http.Header)
50920 }
50921 return c.header_
50922 }
50923
50924 func (c *VideoFormatsGetCall) doRequest(alt string) (*http.Response, error) {
50925 reqHeaders := make(http.Header)
50926 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
50927 for k, v := range c.header_ {
50928 reqHeaders[k] = v
50929 }
50930 reqHeaders.Set("User-Agent", c.s.userAgent())
50931 if c.ifNoneMatch_ != "" {
50932 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
50933 }
50934 var body io.Reader = nil
50935 c.urlParams_.Set("alt", alt)
50936 c.urlParams_.Set("prettyPrint", "false")
50937 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/videoFormats/{id}")
50938 urls += "?" + c.urlParams_.Encode()
50939 req, err := http.NewRequest("GET", urls, body)
50940 if err != nil {
50941 return nil, err
50942 }
50943 req.Header = reqHeaders
50944 googleapi.Expand(req.URL, map[string]string{
50945 "profileId": strconv.FormatInt(c.profileId, 10),
50946 "id": strconv.FormatInt(c.id, 10),
50947 })
50948 return gensupport.SendRequest(c.ctx_, c.s.client, req)
50949 }
50950
50951
50952
50953
50954
50955
50956
50957
50958 func (c *VideoFormatsGetCall) Do(opts ...googleapi.CallOption) (*VideoFormat, error) {
50959 gensupport.SetOptions(c.urlParams_, opts...)
50960 res, err := c.doRequest("json")
50961 if res != nil && res.StatusCode == http.StatusNotModified {
50962 if res.Body != nil {
50963 res.Body.Close()
50964 }
50965 return nil, &googleapi.Error{
50966 Code: res.StatusCode,
50967 Header: res.Header,
50968 }
50969 }
50970 if err != nil {
50971 return nil, err
50972 }
50973 defer googleapi.CloseBody(res)
50974 if err := googleapi.CheckResponse(res); err != nil {
50975 return nil, err
50976 }
50977 ret := &VideoFormat{
50978 ServerResponse: googleapi.ServerResponse{
50979 Header: res.Header,
50980 HTTPStatusCode: res.StatusCode,
50981 },
50982 }
50983 target := &ret
50984 if err := gensupport.DecodeResponse(target, res); err != nil {
50985 return nil, err
50986 }
50987 return ret, nil
50988
50989
50990
50991
50992
50993
50994
50995
50996
50997
50998
50999
51000
51001
51002
51003
51004
51005
51006
51007
51008
51009
51010
51011
51012
51013
51014
51015
51016
51017
51018
51019
51020
51021 }
51022
51023
51024
51025 type VideoFormatsListCall struct {
51026 s *Service
51027 profileId int64
51028 urlParams_ gensupport.URLParams
51029 ifNoneMatch_ string
51030 ctx_ context.Context
51031 header_ http.Header
51032 }
51033
51034
51035 func (r *VideoFormatsService) List(profileId int64) *VideoFormatsListCall {
51036 c := &VideoFormatsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
51037 c.profileId = profileId
51038 return c
51039 }
51040
51041
51042
51043
51044 func (c *VideoFormatsListCall) Fields(s ...googleapi.Field) *VideoFormatsListCall {
51045 c.urlParams_.Set("fields", googleapi.CombineFields(s))
51046 return c
51047 }
51048
51049
51050
51051
51052
51053
51054 func (c *VideoFormatsListCall) IfNoneMatch(entityTag string) *VideoFormatsListCall {
51055 c.ifNoneMatch_ = entityTag
51056 return c
51057 }
51058
51059
51060
51061
51062 func (c *VideoFormatsListCall) Context(ctx context.Context) *VideoFormatsListCall {
51063 c.ctx_ = ctx
51064 return c
51065 }
51066
51067
51068
51069 func (c *VideoFormatsListCall) Header() http.Header {
51070 if c.header_ == nil {
51071 c.header_ = make(http.Header)
51072 }
51073 return c.header_
51074 }
51075
51076 func (c *VideoFormatsListCall) doRequest(alt string) (*http.Response, error) {
51077 reqHeaders := make(http.Header)
51078 reqHeaders.Set("x-goog-api-client", "gl-go/1.13.7 gdcl/20200203")
51079 for k, v := range c.header_ {
51080 reqHeaders[k] = v
51081 }
51082 reqHeaders.Set("User-Agent", c.s.userAgent())
51083 if c.ifNoneMatch_ != "" {
51084 reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
51085 }
51086 var body io.Reader = nil
51087 c.urlParams_.Set("alt", alt)
51088 c.urlParams_.Set("prettyPrint", "false")
51089 urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/videoFormats")
51090 urls += "?" + c.urlParams_.Encode()
51091 req, err := http.NewRequest("GET", urls, body)
51092 if err != nil {
51093 return nil, err
51094 }
51095 req.Header = reqHeaders
51096 googleapi.Expand(req.URL, map[string]string{
51097 "profileId": strconv.FormatInt(c.profileId, 10),
51098 })
51099 return gensupport.SendRequest(c.ctx_, c.s.client, req)
51100 }
51101
51102
51103
51104
51105
51106
51107
51108
51109 func (c *VideoFormatsListCall) Do(opts ...googleapi.CallOption) (*VideoFormatsListResponse, error) {
51110 gensupport.SetOptions(c.urlParams_, opts...)
51111 res, err := c.doRequest("json")
51112 if res != nil && res.StatusCode == http.StatusNotModified {
51113 if res.Body != nil {
51114 res.Body.Close()
51115 }
51116 return nil, &googleapi.Error{
51117 Code: res.StatusCode,
51118 Header: res.Header,
51119 }
51120 }
51121 if err != nil {
51122 return nil, err
51123 }
51124 defer googleapi.CloseBody(res)
51125 if err := googleapi.CheckResponse(res); err != nil {
51126 return nil, err
51127 }
51128 ret := &VideoFormatsListResponse{
51129 ServerResponse: googleapi.ServerResponse{
51130 Header: res.Header,
51131 HTTPStatusCode: res.StatusCode,
51132 },
51133 }
51134 target := &ret
51135 if err := gensupport.DecodeResponse(target, res); err != nil {
51136 return nil, err
51137 }
51138 return ret, nil
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
View as plain text