1// Copyright 2021 Google LLC.
2// Use of this source code is governed by a BSD-style
3// license that can be found in the LICENSE file.
4
5// Code generated file. DO NOT EDIT.
6
7// Package dfareporting provides access to the Campaign Manager 360 API.
8//
9// For product documentation, see: https://developers.google.com/doubleclick-advertisers/
10//
11// Creating a client
12//
13// Usage example:
14//
15//   import "google.golang.org/api/dfareporting/v3.4"
16//   ...
17//   ctx := context.Background()
18//   dfareportingService, err := dfareporting.NewService(ctx)
19//
20// In this example, Google Application Default Credentials are used for authentication.
21//
22// For information on how to create and obtain Application Default Credentials, see https://developers.google.com/identity/protocols/application-default-credentials.
23//
24// Other authentication options
25//
26// By default, all available scopes (see "Constants") are used to authenticate. To restrict scopes, use option.WithScopes:
27//
28//   dfareportingService, err := dfareporting.NewService(ctx, option.WithScopes(dfareporting.DfatraffickingScope))
29//
30// To use an API key for authentication (note: some APIs do not support API keys), use option.WithAPIKey:
31//
32//   dfareportingService, err := dfareporting.NewService(ctx, option.WithAPIKey("AIza..."))
33//
34// To use an OAuth token (e.g., a user token obtained via a three-legged OAuth flow), use option.WithTokenSource:
35//
36//   config := &oauth2.Config{...}
37//   // ...
38//   token, err := config.Exchange(ctx, ...)
39//   dfareportingService, err := dfareporting.NewService(ctx, option.WithTokenSource(config.TokenSource(ctx, token)))
40//
41// See https://godoc.org/google.golang.org/api/option/ for details on options.
42package dfareporting // import "google.golang.org/api/dfareporting/v3.4"
43
44import (
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	internaloption "google.golang.org/api/option/internaloption"
60	htransport "google.golang.org/api/transport/http"
61)
62
63// Always reference these packages, just in case the auto-generated code
64// below doesn't.
65var _ = bytes.NewBuffer
66var _ = strconv.Itoa
67var _ = fmt.Sprintf
68var _ = json.NewDecoder
69var _ = io.Copy
70var _ = url.Parse
71var _ = gensupport.MarshalJSON
72var _ = googleapi.Version
73var _ = errors.New
74var _ = strings.Replace
75var _ = context.Canceled
76var _ = internaloption.WithDefaultEndpoint
77
78const apiId = "dfareporting:v3.4"
79const apiName = "dfareporting"
80const apiVersion = "v3.4"
81const basePath = "https://dfareporting.googleapis.com/dfareporting/v3.4/"
82const mtlsBasePath = "https://dfareporting.mtls.googleapis.com/dfareporting/v3.4/"
83
84// OAuth2 scopes used by this API.
85const (
86	// Manage DoubleClick Digital Marketing conversions
87	DdmconversionsScope = "https://www.googleapis.com/auth/ddmconversions"
88
89	// View and manage DoubleClick for Advertisers reports
90	DfareportingScope = "https://www.googleapis.com/auth/dfareporting"
91
92	// View and manage your DoubleClick Campaign Manager's (DCM) display ad
93	// campaigns
94	DfatraffickingScope = "https://www.googleapis.com/auth/dfatrafficking"
95)
96
97// NewService creates a new Service.
98func NewService(ctx context.Context, opts ...option.ClientOption) (*Service, error) {
99	scopesOption := option.WithScopes(
100		"https://www.googleapis.com/auth/ddmconversions",
101		"https://www.googleapis.com/auth/dfareporting",
102		"https://www.googleapis.com/auth/dfatrafficking",
103	)
104	// NOTE: prepend, so we don't override user-specified scopes.
105	opts = append([]option.ClientOption{scopesOption}, opts...)
106	opts = append(opts, internaloption.WithDefaultEndpoint(basePath))
107	opts = append(opts, internaloption.WithDefaultMTLSEndpoint(mtlsBasePath))
108	client, endpoint, err := htransport.NewClient(ctx, opts...)
109	if err != nil {
110		return nil, err
111	}
112	s, err := New(client)
113	if err != nil {
114		return nil, err
115	}
116	if endpoint != "" {
117		s.BasePath = endpoint
118	}
119	return s, nil
120}
121
122// New creates a new Service. It uses the provided http.Client for requests.
123//
124// Deprecated: please use NewService instead.
125// To provide a custom HTTP client, use option.WithHTTPClient.
126// If you are using google.golang.org/api/googleapis/transport.APIKey, use option.WithAPIKey with NewService instead.
127func New(client *http.Client) (*Service, error) {
128	if client == nil {
129		return nil, errors.New("client is nil")
130	}
131	s := &Service{client: client, BasePath: basePath}
132	s.AccountActiveAdSummaries = NewAccountActiveAdSummariesService(s)
133	s.AccountPermissionGroups = NewAccountPermissionGroupsService(s)
134	s.AccountPermissions = NewAccountPermissionsService(s)
135	s.AccountUserProfiles = NewAccountUserProfilesService(s)
136	s.Accounts = NewAccountsService(s)
137	s.Ads = NewAdsService(s)
138	s.AdvertiserGroups = NewAdvertiserGroupsService(s)
139	s.AdvertiserLandingPages = NewAdvertiserLandingPagesService(s)
140	s.Advertisers = NewAdvertisersService(s)
141	s.Browsers = NewBrowsersService(s)
142	s.CampaignCreativeAssociations = NewCampaignCreativeAssociationsService(s)
143	s.Campaigns = NewCampaignsService(s)
144	s.ChangeLogs = NewChangeLogsService(s)
145	s.Cities = NewCitiesService(s)
146	s.ConnectionTypes = NewConnectionTypesService(s)
147	s.ContentCategories = NewContentCategoriesService(s)
148	s.Conversions = NewConversionsService(s)
149	s.Countries = NewCountriesService(s)
150	s.CreativeAssets = NewCreativeAssetsService(s)
151	s.CreativeFieldValues = NewCreativeFieldValuesService(s)
152	s.CreativeFields = NewCreativeFieldsService(s)
153	s.CreativeGroups = NewCreativeGroupsService(s)
154	s.Creatives = NewCreativesService(s)
155	s.CustomEvents = NewCustomEventsService(s)
156	s.DimensionValues = NewDimensionValuesService(s)
157	s.DirectorySites = NewDirectorySitesService(s)
158	s.DynamicTargetingKeys = NewDynamicTargetingKeysService(s)
159	s.EventTags = NewEventTagsService(s)
160	s.Files = NewFilesService(s)
161	s.FloodlightActivities = NewFloodlightActivitiesService(s)
162	s.FloodlightActivityGroups = NewFloodlightActivityGroupsService(s)
163	s.FloodlightConfigurations = NewFloodlightConfigurationsService(s)
164	s.InventoryItems = NewInventoryItemsService(s)
165	s.Languages = NewLanguagesService(s)
166	s.Metros = NewMetrosService(s)
167	s.MobileApps = NewMobileAppsService(s)
168	s.MobileCarriers = NewMobileCarriersService(s)
169	s.OperatingSystemVersions = NewOperatingSystemVersionsService(s)
170	s.OperatingSystems = NewOperatingSystemsService(s)
171	s.OrderDocuments = NewOrderDocumentsService(s)
172	s.Orders = NewOrdersService(s)
173	s.PlacementGroups = NewPlacementGroupsService(s)
174	s.PlacementStrategies = NewPlacementStrategiesService(s)
175	s.Placements = NewPlacementsService(s)
176	s.PlatformTypes = NewPlatformTypesService(s)
177	s.PostalCodes = NewPostalCodesService(s)
178	s.Projects = NewProjectsService(s)
179	s.Regions = NewRegionsService(s)
180	s.RemarketingListShares = NewRemarketingListSharesService(s)
181	s.RemarketingLists = NewRemarketingListsService(s)
182	s.Reports = NewReportsService(s)
183	s.Sites = NewSitesService(s)
184	s.Sizes = NewSizesService(s)
185	s.Subaccounts = NewSubaccountsService(s)
186	s.TargetableRemarketingLists = NewTargetableRemarketingListsService(s)
187	s.TargetingTemplates = NewTargetingTemplatesService(s)
188	s.UserProfiles = NewUserProfilesService(s)
189	s.UserRolePermissionGroups = NewUserRolePermissionGroupsService(s)
190	s.UserRolePermissions = NewUserRolePermissionsService(s)
191	s.UserRoles = NewUserRolesService(s)
192	s.VideoFormats = NewVideoFormatsService(s)
193	return s, nil
194}
195
196type Service struct {
197	client    *http.Client
198	BasePath  string // API endpoint base URL
199	UserAgent string // optional additional User-Agent fragment
200
201	AccountActiveAdSummaries *AccountActiveAdSummariesService
202
203	AccountPermissionGroups *AccountPermissionGroupsService
204
205	AccountPermissions *AccountPermissionsService
206
207	AccountUserProfiles *AccountUserProfilesService
208
209	Accounts *AccountsService
210
211	Ads *AdsService
212
213	AdvertiserGroups *AdvertiserGroupsService
214
215	AdvertiserLandingPages *AdvertiserLandingPagesService
216
217	Advertisers *AdvertisersService
218
219	Browsers *BrowsersService
220
221	CampaignCreativeAssociations *CampaignCreativeAssociationsService
222
223	Campaigns *CampaignsService
224
225	ChangeLogs *ChangeLogsService
226
227	Cities *CitiesService
228
229	ConnectionTypes *ConnectionTypesService
230
231	ContentCategories *ContentCategoriesService
232
233	Conversions *ConversionsService
234
235	Countries *CountriesService
236
237	CreativeAssets *CreativeAssetsService
238
239	CreativeFieldValues *CreativeFieldValuesService
240
241	CreativeFields *CreativeFieldsService
242
243	CreativeGroups *CreativeGroupsService
244
245	Creatives *CreativesService
246
247	CustomEvents *CustomEventsService
248
249	DimensionValues *DimensionValuesService
250
251	DirectorySites *DirectorySitesService
252
253	DynamicTargetingKeys *DynamicTargetingKeysService
254
255	EventTags *EventTagsService
256
257	Files *FilesService
258
259	FloodlightActivities *FloodlightActivitiesService
260
261	FloodlightActivityGroups *FloodlightActivityGroupsService
262
263	FloodlightConfigurations *FloodlightConfigurationsService
264
265	InventoryItems *InventoryItemsService
266
267	Languages *LanguagesService
268
269	Metros *MetrosService
270
271	MobileApps *MobileAppsService
272
273	MobileCarriers *MobileCarriersService
274
275	OperatingSystemVersions *OperatingSystemVersionsService
276
277	OperatingSystems *OperatingSystemsService
278
279	OrderDocuments *OrderDocumentsService
280
281	Orders *OrdersService
282
283	PlacementGroups *PlacementGroupsService
284
285	PlacementStrategies *PlacementStrategiesService
286
287	Placements *PlacementsService
288
289	PlatformTypes *PlatformTypesService
290
291	PostalCodes *PostalCodesService
292
293	Projects *ProjectsService
294
295	Regions *RegionsService
296
297	RemarketingListShares *RemarketingListSharesService
298
299	RemarketingLists *RemarketingListsService
300
301	Reports *ReportsService
302
303	Sites *SitesService
304
305	Sizes *SizesService
306
307	Subaccounts *SubaccountsService
308
309	TargetableRemarketingLists *TargetableRemarketingListsService
310
311	TargetingTemplates *TargetingTemplatesService
312
313	UserProfiles *UserProfilesService
314
315	UserRolePermissionGroups *UserRolePermissionGroupsService
316
317	UserRolePermissions *UserRolePermissionsService
318
319	UserRoles *UserRolesService
320
321	VideoFormats *VideoFormatsService
322}
323
324func (s *Service) userAgent() string {
325	if s.UserAgent == "" {
326		return googleapi.UserAgent
327	}
328	return googleapi.UserAgent + " " + s.UserAgent
329}
330
331func NewAccountActiveAdSummariesService(s *Service) *AccountActiveAdSummariesService {
332	rs := &AccountActiveAdSummariesService{s: s}
333	return rs
334}
335
336type AccountActiveAdSummariesService struct {
337	s *Service
338}
339
340func NewAccountPermissionGroupsService(s *Service) *AccountPermissionGroupsService {
341	rs := &AccountPermissionGroupsService{s: s}
342	return rs
343}
344
345type AccountPermissionGroupsService struct {
346	s *Service
347}
348
349func NewAccountPermissionsService(s *Service) *AccountPermissionsService {
350	rs := &AccountPermissionsService{s: s}
351	return rs
352}
353
354type AccountPermissionsService struct {
355	s *Service
356}
357
358func NewAccountUserProfilesService(s *Service) *AccountUserProfilesService {
359	rs := &AccountUserProfilesService{s: s}
360	return rs
361}
362
363type AccountUserProfilesService struct {
364	s *Service
365}
366
367func NewAccountsService(s *Service) *AccountsService {
368	rs := &AccountsService{s: s}
369	return rs
370}
371
372type AccountsService struct {
373	s *Service
374}
375
376func NewAdsService(s *Service) *AdsService {
377	rs := &AdsService{s: s}
378	return rs
379}
380
381type AdsService struct {
382	s *Service
383}
384
385func NewAdvertiserGroupsService(s *Service) *AdvertiserGroupsService {
386	rs := &AdvertiserGroupsService{s: s}
387	return rs
388}
389
390type AdvertiserGroupsService struct {
391	s *Service
392}
393
394func NewAdvertiserLandingPagesService(s *Service) *AdvertiserLandingPagesService {
395	rs := &AdvertiserLandingPagesService{s: s}
396	return rs
397}
398
399type AdvertiserLandingPagesService struct {
400	s *Service
401}
402
403func NewAdvertisersService(s *Service) *AdvertisersService {
404	rs := &AdvertisersService{s: s}
405	return rs
406}
407
408type AdvertisersService struct {
409	s *Service
410}
411
412func NewBrowsersService(s *Service) *BrowsersService {
413	rs := &BrowsersService{s: s}
414	return rs
415}
416
417type BrowsersService struct {
418	s *Service
419}
420
421func NewCampaignCreativeAssociationsService(s *Service) *CampaignCreativeAssociationsService {
422	rs := &CampaignCreativeAssociationsService{s: s}
423	return rs
424}
425
426type CampaignCreativeAssociationsService struct {
427	s *Service
428}
429
430func NewCampaignsService(s *Service) *CampaignsService {
431	rs := &CampaignsService{s: s}
432	return rs
433}
434
435type CampaignsService struct {
436	s *Service
437}
438
439func NewChangeLogsService(s *Service) *ChangeLogsService {
440	rs := &ChangeLogsService{s: s}
441	return rs
442}
443
444type ChangeLogsService struct {
445	s *Service
446}
447
448func NewCitiesService(s *Service) *CitiesService {
449	rs := &CitiesService{s: s}
450	return rs
451}
452
453type CitiesService struct {
454	s *Service
455}
456
457func NewConnectionTypesService(s *Service) *ConnectionTypesService {
458	rs := &ConnectionTypesService{s: s}
459	return rs
460}
461
462type ConnectionTypesService struct {
463	s *Service
464}
465
466func NewContentCategoriesService(s *Service) *ContentCategoriesService {
467	rs := &ContentCategoriesService{s: s}
468	return rs
469}
470
471type ContentCategoriesService struct {
472	s *Service
473}
474
475func NewConversionsService(s *Service) *ConversionsService {
476	rs := &ConversionsService{s: s}
477	return rs
478}
479
480type ConversionsService struct {
481	s *Service
482}
483
484func NewCountriesService(s *Service) *CountriesService {
485	rs := &CountriesService{s: s}
486	return rs
487}
488
489type CountriesService struct {
490	s *Service
491}
492
493func NewCreativeAssetsService(s *Service) *CreativeAssetsService {
494	rs := &CreativeAssetsService{s: s}
495	return rs
496}
497
498type CreativeAssetsService struct {
499	s *Service
500}
501
502func NewCreativeFieldValuesService(s *Service) *CreativeFieldValuesService {
503	rs := &CreativeFieldValuesService{s: s}
504	return rs
505}
506
507type CreativeFieldValuesService struct {
508	s *Service
509}
510
511func NewCreativeFieldsService(s *Service) *CreativeFieldsService {
512	rs := &CreativeFieldsService{s: s}
513	return rs
514}
515
516type CreativeFieldsService struct {
517	s *Service
518}
519
520func NewCreativeGroupsService(s *Service) *CreativeGroupsService {
521	rs := &CreativeGroupsService{s: s}
522	return rs
523}
524
525type CreativeGroupsService struct {
526	s *Service
527}
528
529func NewCreativesService(s *Service) *CreativesService {
530	rs := &CreativesService{s: s}
531	return rs
532}
533
534type CreativesService struct {
535	s *Service
536}
537
538func NewCustomEventsService(s *Service) *CustomEventsService {
539	rs := &CustomEventsService{s: s}
540	return rs
541}
542
543type CustomEventsService struct {
544	s *Service
545}
546
547func NewDimensionValuesService(s *Service) *DimensionValuesService {
548	rs := &DimensionValuesService{s: s}
549	return rs
550}
551
552type DimensionValuesService struct {
553	s *Service
554}
555
556func NewDirectorySitesService(s *Service) *DirectorySitesService {
557	rs := &DirectorySitesService{s: s}
558	return rs
559}
560
561type DirectorySitesService struct {
562	s *Service
563}
564
565func NewDynamicTargetingKeysService(s *Service) *DynamicTargetingKeysService {
566	rs := &DynamicTargetingKeysService{s: s}
567	return rs
568}
569
570type DynamicTargetingKeysService struct {
571	s *Service
572}
573
574func NewEventTagsService(s *Service) *EventTagsService {
575	rs := &EventTagsService{s: s}
576	return rs
577}
578
579type EventTagsService struct {
580	s *Service
581}
582
583func NewFilesService(s *Service) *FilesService {
584	rs := &FilesService{s: s}
585	return rs
586}
587
588type FilesService struct {
589	s *Service
590}
591
592func NewFloodlightActivitiesService(s *Service) *FloodlightActivitiesService {
593	rs := &FloodlightActivitiesService{s: s}
594	return rs
595}
596
597type FloodlightActivitiesService struct {
598	s *Service
599}
600
601func NewFloodlightActivityGroupsService(s *Service) *FloodlightActivityGroupsService {
602	rs := &FloodlightActivityGroupsService{s: s}
603	return rs
604}
605
606type FloodlightActivityGroupsService struct {
607	s *Service
608}
609
610func NewFloodlightConfigurationsService(s *Service) *FloodlightConfigurationsService {
611	rs := &FloodlightConfigurationsService{s: s}
612	return rs
613}
614
615type FloodlightConfigurationsService struct {
616	s *Service
617}
618
619func NewInventoryItemsService(s *Service) *InventoryItemsService {
620	rs := &InventoryItemsService{s: s}
621	return rs
622}
623
624type InventoryItemsService struct {
625	s *Service
626}
627
628func NewLanguagesService(s *Service) *LanguagesService {
629	rs := &LanguagesService{s: s}
630	return rs
631}
632
633type LanguagesService struct {
634	s *Service
635}
636
637func NewMetrosService(s *Service) *MetrosService {
638	rs := &MetrosService{s: s}
639	return rs
640}
641
642type MetrosService struct {
643	s *Service
644}
645
646func NewMobileAppsService(s *Service) *MobileAppsService {
647	rs := &MobileAppsService{s: s}
648	return rs
649}
650
651type MobileAppsService struct {
652	s *Service
653}
654
655func NewMobileCarriersService(s *Service) *MobileCarriersService {
656	rs := &MobileCarriersService{s: s}
657	return rs
658}
659
660type MobileCarriersService struct {
661	s *Service
662}
663
664func NewOperatingSystemVersionsService(s *Service) *OperatingSystemVersionsService {
665	rs := &OperatingSystemVersionsService{s: s}
666	return rs
667}
668
669type OperatingSystemVersionsService struct {
670	s *Service
671}
672
673func NewOperatingSystemsService(s *Service) *OperatingSystemsService {
674	rs := &OperatingSystemsService{s: s}
675	return rs
676}
677
678type OperatingSystemsService struct {
679	s *Service
680}
681
682func NewOrderDocumentsService(s *Service) *OrderDocumentsService {
683	rs := &OrderDocumentsService{s: s}
684	return rs
685}
686
687type OrderDocumentsService struct {
688	s *Service
689}
690
691func NewOrdersService(s *Service) *OrdersService {
692	rs := &OrdersService{s: s}
693	return rs
694}
695
696type OrdersService struct {
697	s *Service
698}
699
700func NewPlacementGroupsService(s *Service) *PlacementGroupsService {
701	rs := &PlacementGroupsService{s: s}
702	return rs
703}
704
705type PlacementGroupsService struct {
706	s *Service
707}
708
709func NewPlacementStrategiesService(s *Service) *PlacementStrategiesService {
710	rs := &PlacementStrategiesService{s: s}
711	return rs
712}
713
714type PlacementStrategiesService struct {
715	s *Service
716}
717
718func NewPlacementsService(s *Service) *PlacementsService {
719	rs := &PlacementsService{s: s}
720	return rs
721}
722
723type PlacementsService struct {
724	s *Service
725}
726
727func NewPlatformTypesService(s *Service) *PlatformTypesService {
728	rs := &PlatformTypesService{s: s}
729	return rs
730}
731
732type PlatformTypesService struct {
733	s *Service
734}
735
736func NewPostalCodesService(s *Service) *PostalCodesService {
737	rs := &PostalCodesService{s: s}
738	return rs
739}
740
741type PostalCodesService struct {
742	s *Service
743}
744
745func NewProjectsService(s *Service) *ProjectsService {
746	rs := &ProjectsService{s: s}
747	return rs
748}
749
750type ProjectsService struct {
751	s *Service
752}
753
754func NewRegionsService(s *Service) *RegionsService {
755	rs := &RegionsService{s: s}
756	return rs
757}
758
759type RegionsService struct {
760	s *Service
761}
762
763func NewRemarketingListSharesService(s *Service) *RemarketingListSharesService {
764	rs := &RemarketingListSharesService{s: s}
765	return rs
766}
767
768type RemarketingListSharesService struct {
769	s *Service
770}
771
772func NewRemarketingListsService(s *Service) *RemarketingListsService {
773	rs := &RemarketingListsService{s: s}
774	return rs
775}
776
777type RemarketingListsService struct {
778	s *Service
779}
780
781func NewReportsService(s *Service) *ReportsService {
782	rs := &ReportsService{s: s}
783	rs.CompatibleFields = NewReportsCompatibleFieldsService(s)
784	rs.Files = NewReportsFilesService(s)
785	return rs
786}
787
788type ReportsService struct {
789	s *Service
790
791	CompatibleFields *ReportsCompatibleFieldsService
792
793	Files *ReportsFilesService
794}
795
796func NewReportsCompatibleFieldsService(s *Service) *ReportsCompatibleFieldsService {
797	rs := &ReportsCompatibleFieldsService{s: s}
798	return rs
799}
800
801type ReportsCompatibleFieldsService struct {
802	s *Service
803}
804
805func NewReportsFilesService(s *Service) *ReportsFilesService {
806	rs := &ReportsFilesService{s: s}
807	return rs
808}
809
810type ReportsFilesService struct {
811	s *Service
812}
813
814func NewSitesService(s *Service) *SitesService {
815	rs := &SitesService{s: s}
816	return rs
817}
818
819type SitesService struct {
820	s *Service
821}
822
823func NewSizesService(s *Service) *SizesService {
824	rs := &SizesService{s: s}
825	return rs
826}
827
828type SizesService struct {
829	s *Service
830}
831
832func NewSubaccountsService(s *Service) *SubaccountsService {
833	rs := &SubaccountsService{s: s}
834	return rs
835}
836
837type SubaccountsService struct {
838	s *Service
839}
840
841func NewTargetableRemarketingListsService(s *Service) *TargetableRemarketingListsService {
842	rs := &TargetableRemarketingListsService{s: s}
843	return rs
844}
845
846type TargetableRemarketingListsService struct {
847	s *Service
848}
849
850func NewTargetingTemplatesService(s *Service) *TargetingTemplatesService {
851	rs := &TargetingTemplatesService{s: s}
852	return rs
853}
854
855type TargetingTemplatesService struct {
856	s *Service
857}
858
859func NewUserProfilesService(s *Service) *UserProfilesService {
860	rs := &UserProfilesService{s: s}
861	return rs
862}
863
864type UserProfilesService struct {
865	s *Service
866}
867
868func NewUserRolePermissionGroupsService(s *Service) *UserRolePermissionGroupsService {
869	rs := &UserRolePermissionGroupsService{s: s}
870	return rs
871}
872
873type UserRolePermissionGroupsService struct {
874	s *Service
875}
876
877func NewUserRolePermissionsService(s *Service) *UserRolePermissionsService {
878	rs := &UserRolePermissionsService{s: s}
879	return rs
880}
881
882type UserRolePermissionsService struct {
883	s *Service
884}
885
886func NewUserRolesService(s *Service) *UserRolesService {
887	rs := &UserRolesService{s: s}
888	return rs
889}
890
891type UserRolesService struct {
892	s *Service
893}
894
895func NewVideoFormatsService(s *Service) *VideoFormatsService {
896	rs := &VideoFormatsService{s: s}
897	return rs
898}
899
900type VideoFormatsService struct {
901	s *Service
902}
903
904// Account: Contains properties of a Campaign Manager account.
905type Account struct {
906	// AccountPermissionIds: Account permissions assigned to this account.
907	AccountPermissionIds googleapi.Int64s `json:"accountPermissionIds,omitempty"`
908
909	// AccountProfile: Profile for this account. This is a read-only field
910	// that can be left blank.
911	//
912	// Possible values:
913	//   "ACCOUNT_PROFILE_BASIC"
914	//   "ACCOUNT_PROFILE_STANDARD"
915	AccountProfile string `json:"accountProfile,omitempty"`
916
917	// Active: Whether this account is active.
918	Active bool `json:"active,omitempty"`
919
920	// ActiveAdsLimitTier: Maximum number of active ads allowed for this
921	// account.
922	//
923	// Possible values:
924	//   "ACTIVE_ADS_TIER_40K"
925	//   "ACTIVE_ADS_TIER_75K"
926	//   "ACTIVE_ADS_TIER_100K"
927	//   "ACTIVE_ADS_TIER_200K"
928	//   "ACTIVE_ADS_TIER_300K"
929	//   "ACTIVE_ADS_TIER_500K"
930	//   "ACTIVE_ADS_TIER_750K"
931	//   "ACTIVE_ADS_TIER_1M"
932	ActiveAdsLimitTier string `json:"activeAdsLimitTier,omitempty"`
933
934	// ActiveViewOptOut: Whether to serve creatives with Active View tags.
935	// If disabled, viewability data will not be available for any
936	// impressions.
937	ActiveViewOptOut bool `json:"activeViewOptOut,omitempty"`
938
939	// AvailablePermissionIds: User role permissions available to the user
940	// roles of this account.
941	AvailablePermissionIds googleapi.Int64s `json:"availablePermissionIds,omitempty"`
942
943	// CountryId: ID of the country associated with this account.
944	CountryId int64 `json:"countryId,omitempty,string"`
945
946	// CurrencyId: ID of currency associated with this account. This is a
947	// required field. Acceptable values are: - "1" for USD - "2" for GBP -
948	// "3" for ESP - "4" for SEK - "5" for CAD - "6" for JPY - "7" for DEM -
949	// "8" for AUD - "9" for FRF - "10" for ITL - "11" for DKK - "12" for
950	// NOK - "13" for FIM - "14" for ZAR - "15" for IEP - "16" for NLG -
951	// "17" for EUR - "18" for KRW - "19" for TWD - "20" for SGD - "21" for
952	// CNY - "22" for HKD - "23" for NZD - "24" for MYR - "25" for BRL -
953	// "26" for PTE - "28" for CLP - "29" for TRY - "30" for ARS - "31" for
954	// PEN - "32" for ILS - "33" for CHF - "34" for VEF - "35" for COP -
955	// "36" for GTQ - "37" for PLN - "39" for INR - "40" for THB - "41" for
956	// IDR - "42" for CZK - "43" for RON - "44" for HUF - "45" for RUB -
957	// "46" for AED - "47" for BGN - "48" for HRK - "49" for MXN - "50" for
958	// NGN - "51" for EGP
959	CurrencyId int64 `json:"currencyId,omitempty,string"`
960
961	// DefaultCreativeSizeId: Default placement dimensions for this account.
962	DefaultCreativeSizeId int64 `json:"defaultCreativeSizeId,omitempty,string"`
963
964	// Description: Description of this account.
965	Description string `json:"description,omitempty"`
966
967	// Id: ID of this account. This is a read-only, auto-generated field.
968	Id int64 `json:"id,omitempty,string"`
969
970	// Kind: Identifies what kind of resource this is. Value: the fixed
971	// string "dfareporting#account".
972	Kind string `json:"kind,omitempty"`
973
974	// Locale: Locale of this account. Acceptable values are: - "cs" (Czech)
975	// - "de" (German) - "en" (English) - "en-GB" (English United Kingdom) -
976	// "es" (Spanish) - "fr" (French) - "it" (Italian) - "ja" (Japanese) -
977	// "ko" (Korean) - "pl" (Polish) - "pt-BR" (Portuguese Brazil) - "ru"
978	// (Russian) - "sv" (Swedish) - "tr" (Turkish) - "zh-CN" (Chinese
979	// Simplified) - "zh-TW" (Chinese Traditional)
980	Locale string `json:"locale,omitempty"`
981
982	// MaximumImageSize: Maximum image size allowed for this account, in
983	// kilobytes. Value must be greater than or equal to 1.
984	MaximumImageSize int64 `json:"maximumImageSize,omitempty,string"`
985
986	// Name: Name of this account. This is a required field, and must be
987	// less than 128 characters long and be globally unique.
988	Name string `json:"name,omitempty"`
989
990	// NielsenOcrEnabled: Whether campaigns created in this account will be
991	// enabled for Nielsen OCR reach ratings by default.
992	NielsenOcrEnabled bool `json:"nielsenOcrEnabled,omitempty"`
993
994	// ReportsConfiguration: Reporting configuration of this account.
995	ReportsConfiguration *ReportsConfiguration `json:"reportsConfiguration,omitempty"`
996
997	// ShareReportsWithTwitter: Share Path to Conversion reports with
998	// Twitter.
999	ShareReportsWithTwitter bool `json:"shareReportsWithTwitter,omitempty"`
1000
1001	// TeaserSizeLimit: File size limit in kilobytes of Rich Media teaser
1002	// creatives. Acceptable values are 1 to 10240, inclusive.
1003	TeaserSizeLimit int64 `json:"teaserSizeLimit,omitempty,string"`
1004
1005	// ServerResponse contains the HTTP response code and headers from the
1006	// server.
1007	googleapi.ServerResponse `json:"-"`
1008
1009	// ForceSendFields is a list of field names (e.g.
1010	// "AccountPermissionIds") to unconditionally include in API requests.
1011	// By default, fields with empty or default values are omitted from API
1012	// requests. However, any non-pointer, non-interface field appearing in
1013	// ForceSendFields will be sent to the server regardless of whether the
1014	// field is empty or not. This may be used to include empty fields in
1015	// Patch requests.
1016	ForceSendFields []string `json:"-"`
1017
1018	// NullFields is a list of field names (e.g. "AccountPermissionIds") to
1019	// include in API requests with the JSON null value. By default, fields
1020	// with empty values are omitted from API requests. However, any field
1021	// with an empty value appearing in NullFields will be sent to the
1022	// server as null. It is an error if a field in this list has a
1023	// non-empty value. This may be used to include null fields in Patch
1024	// requests.
1025	NullFields []string `json:"-"`
1026}
1027
1028func (s *Account) MarshalJSON() ([]byte, error) {
1029	type NoMethod Account
1030	raw := NoMethod(*s)
1031	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1032}
1033
1034// AccountActiveAdSummary: Gets a summary of active ads in an account.
1035type AccountActiveAdSummary struct {
1036	// AccountId: ID of the account.
1037	AccountId int64 `json:"accountId,omitempty,string"`
1038
1039	// ActiveAds: Ads that have been activated for the account
1040	ActiveAds int64 `json:"activeAds,omitempty,string"`
1041
1042	// ActiveAdsLimitTier: Maximum number of active ads allowed for the
1043	// account.
1044	//
1045	// Possible values:
1046	//   "ACTIVE_ADS_TIER_40K"
1047	//   "ACTIVE_ADS_TIER_75K"
1048	//   "ACTIVE_ADS_TIER_100K"
1049	//   "ACTIVE_ADS_TIER_200K"
1050	//   "ACTIVE_ADS_TIER_300K"
1051	//   "ACTIVE_ADS_TIER_500K"
1052	//   "ACTIVE_ADS_TIER_750K"
1053	//   "ACTIVE_ADS_TIER_1M"
1054	ActiveAdsLimitTier string `json:"activeAdsLimitTier,omitempty"`
1055
1056	// AvailableAds: Ads that can be activated for the account.
1057	AvailableAds int64 `json:"availableAds,omitempty,string"`
1058
1059	// Kind: Identifies what kind of resource this is. Value: the fixed
1060	// string "dfareporting#accountActiveAdSummary".
1061	Kind string `json:"kind,omitempty"`
1062
1063	// ServerResponse contains the HTTP response code and headers from the
1064	// server.
1065	googleapi.ServerResponse `json:"-"`
1066
1067	// ForceSendFields is a list of field names (e.g. "AccountId") to
1068	// unconditionally include in API requests. By default, fields with
1069	// empty or default values are omitted from API requests. However, any
1070	// non-pointer, non-interface field appearing in ForceSendFields will be
1071	// sent to the server regardless of whether the field is empty or not.
1072	// This may be used to include empty fields in Patch requests.
1073	ForceSendFields []string `json:"-"`
1074
1075	// NullFields is a list of field names (e.g. "AccountId") to include in
1076	// API requests with the JSON null value. By default, fields with empty
1077	// values are omitted from API requests. However, any field with an
1078	// empty value appearing in NullFields will be sent to the server as
1079	// null. It is an error if a field in this list has a non-empty value.
1080	// This may be used to include null fields in Patch requests.
1081	NullFields []string `json:"-"`
1082}
1083
1084func (s *AccountActiveAdSummary) MarshalJSON() ([]byte, error) {
1085	type NoMethod AccountActiveAdSummary
1086	raw := NoMethod(*s)
1087	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1088}
1089
1090// AccountPermission: AccountPermissions contains information about a
1091// particular account permission. Some features of Campaign Manager
1092// require an account permission to be present in the account.
1093type AccountPermission struct {
1094	// AccountProfiles: Account profiles associated with this account
1095	// permission. Possible values are: - "ACCOUNT_PROFILE_BASIC" -
1096	// "ACCOUNT_PROFILE_STANDARD"
1097	//
1098	// Possible values:
1099	//   "ACCOUNT_PROFILE_BASIC"
1100	//   "ACCOUNT_PROFILE_STANDARD"
1101	AccountProfiles []string `json:"accountProfiles,omitempty"`
1102
1103	// Id: ID of this account permission.
1104	Id int64 `json:"id,omitempty,string"`
1105
1106	// Kind: Identifies what kind of resource this is. Value: the fixed
1107	// string "dfareporting#accountPermission".
1108	Kind string `json:"kind,omitempty"`
1109
1110	// Level: Administrative level required to enable this account
1111	// permission.
1112	//
1113	// Possible values:
1114	//   "USER"
1115	//   "ADMINISTRATOR"
1116	Level string `json:"level,omitempty"`
1117
1118	// Name: Name of this account permission.
1119	Name string `json:"name,omitempty"`
1120
1121	// PermissionGroupId: Permission group of this account permission.
1122	PermissionGroupId int64 `json:"permissionGroupId,omitempty,string"`
1123
1124	// ServerResponse contains the HTTP response code and headers from the
1125	// server.
1126	googleapi.ServerResponse `json:"-"`
1127
1128	// ForceSendFields is a list of field names (e.g. "AccountProfiles") to
1129	// unconditionally include in API requests. By default, fields with
1130	// empty or default values are omitted from API requests. However, any
1131	// non-pointer, non-interface field appearing in ForceSendFields will be
1132	// sent to the server regardless of whether the field is empty or not.
1133	// This may be used to include empty fields in Patch requests.
1134	ForceSendFields []string `json:"-"`
1135
1136	// NullFields is a list of field names (e.g. "AccountProfiles") to
1137	// include in API requests with the JSON null value. By default, fields
1138	// with empty values are omitted from API requests. However, any field
1139	// with an empty value appearing in NullFields will be sent to the
1140	// server as null. It is an error if a field in this list has a
1141	// non-empty value. This may be used to include null fields in Patch
1142	// requests.
1143	NullFields []string `json:"-"`
1144}
1145
1146func (s *AccountPermission) MarshalJSON() ([]byte, error) {
1147	type NoMethod AccountPermission
1148	raw := NoMethod(*s)
1149	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1150}
1151
1152// AccountPermissionGroup: AccountPermissionGroups contains a mapping of
1153// permission group IDs to names. A permission group is a grouping of
1154// account permissions.
1155type AccountPermissionGroup struct {
1156	// Id: ID of this account permission group.
1157	Id int64 `json:"id,omitempty,string"`
1158
1159	// Kind: Identifies what kind of resource this is. Value: the fixed
1160	// string "dfareporting#accountPermissionGroup".
1161	Kind string `json:"kind,omitempty"`
1162
1163	// Name: Name of this account permission group.
1164	Name string `json:"name,omitempty"`
1165
1166	// ServerResponse contains the HTTP response code and headers from the
1167	// server.
1168	googleapi.ServerResponse `json:"-"`
1169
1170	// ForceSendFields is a list of field names (e.g. "Id") to
1171	// unconditionally include in API requests. By default, fields with
1172	// empty or default values are omitted from API requests. However, any
1173	// non-pointer, non-interface field appearing in ForceSendFields will be
1174	// sent to the server regardless of whether the field is empty or not.
1175	// This may be used to include empty fields in Patch requests.
1176	ForceSendFields []string `json:"-"`
1177
1178	// NullFields is a list of field names (e.g. "Id") to include in API
1179	// requests with the JSON null value. By default, fields with empty
1180	// values are omitted from API requests. However, any field with an
1181	// empty value appearing in NullFields will be sent to the server as
1182	// null. It is an error if a field in this list has a non-empty value.
1183	// This may be used to include null fields in Patch requests.
1184	NullFields []string `json:"-"`
1185}
1186
1187func (s *AccountPermissionGroup) MarshalJSON() ([]byte, error) {
1188	type NoMethod AccountPermissionGroup
1189	raw := NoMethod(*s)
1190	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1191}
1192
1193// AccountPermissionGroupsListResponse: Account Permission Group List
1194// Response
1195type AccountPermissionGroupsListResponse struct {
1196	// AccountPermissionGroups: Account permission group collection.
1197	AccountPermissionGroups []*AccountPermissionGroup `json:"accountPermissionGroups,omitempty"`
1198
1199	// Kind: Identifies what kind of resource this is. Value: the fixed
1200	// string "dfareporting#accountPermissionGroupsListResponse".
1201	Kind string `json:"kind,omitempty"`
1202
1203	// ServerResponse contains the HTTP response code and headers from the
1204	// server.
1205	googleapi.ServerResponse `json:"-"`
1206
1207	// ForceSendFields is a list of field names (e.g.
1208	// "AccountPermissionGroups") to unconditionally include in API
1209	// requests. By default, fields with empty or default values are omitted
1210	// from API requests. However, any non-pointer, non-interface field
1211	// appearing in ForceSendFields will be sent to the server regardless of
1212	// whether the field is empty or not. This may be used to include empty
1213	// fields in Patch requests.
1214	ForceSendFields []string `json:"-"`
1215
1216	// NullFields is a list of field names (e.g. "AccountPermissionGroups")
1217	// to include in API requests with the JSON null value. By default,
1218	// fields with empty values are omitted from API requests. However, any
1219	// field with an empty value appearing in NullFields will be sent to the
1220	// server as null. It is an error if a field in this list has a
1221	// non-empty value. This may be used to include null fields in Patch
1222	// requests.
1223	NullFields []string `json:"-"`
1224}
1225
1226func (s *AccountPermissionGroupsListResponse) MarshalJSON() ([]byte, error) {
1227	type NoMethod AccountPermissionGroupsListResponse
1228	raw := NoMethod(*s)
1229	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1230}
1231
1232// AccountPermissionsListResponse: Account Permission List Response
1233type AccountPermissionsListResponse struct {
1234	// AccountPermissions: Account permission collection.
1235	AccountPermissions []*AccountPermission `json:"accountPermissions,omitempty"`
1236
1237	// Kind: Identifies what kind of resource this is. Value: the fixed
1238	// string "dfareporting#accountPermissionsListResponse".
1239	Kind string `json:"kind,omitempty"`
1240
1241	// ServerResponse contains the HTTP response code and headers from the
1242	// server.
1243	googleapi.ServerResponse `json:"-"`
1244
1245	// ForceSendFields is a list of field names (e.g. "AccountPermissions")
1246	// to unconditionally include in API requests. By default, fields with
1247	// empty or default values are omitted from API requests. However, any
1248	// non-pointer, non-interface field appearing in ForceSendFields will be
1249	// sent to the server regardless of whether the field is empty or not.
1250	// This may be used to include empty fields in Patch requests.
1251	ForceSendFields []string `json:"-"`
1252
1253	// NullFields is a list of field names (e.g. "AccountPermissions") to
1254	// include in API requests with the JSON null value. By default, fields
1255	// with empty values are omitted from API requests. However, any field
1256	// with an empty value appearing in NullFields will be sent to the
1257	// server as null. It is an error if a field in this list has a
1258	// non-empty value. This may be used to include null fields in Patch
1259	// requests.
1260	NullFields []string `json:"-"`
1261}
1262
1263func (s *AccountPermissionsListResponse) MarshalJSON() ([]byte, error) {
1264	type NoMethod AccountPermissionsListResponse
1265	raw := NoMethod(*s)
1266	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1267}
1268
1269// AccountUserProfile: AccountUserProfiles contains properties of a
1270// Campaign Manager user profile. This resource is specifically for
1271// managing user profiles, whereas UserProfiles is for accessing the
1272// API.
1273type AccountUserProfile struct {
1274	// AccountId: Account ID of the user profile. This is a read-only field
1275	// that can be left blank.
1276	AccountId int64 `json:"accountId,omitempty,string"`
1277
1278	// Active: Whether this user profile is active. This defaults to false,
1279	// and must be set true on insert for the user profile to be usable.
1280	Active bool `json:"active,omitempty"`
1281
1282	// AdvertiserFilter: Filter that describes which advertisers are visible
1283	// to the user profile.
1284	AdvertiserFilter *ObjectFilter `json:"advertiserFilter,omitempty"`
1285
1286	// CampaignFilter: Filter that describes which campaigns are visible to
1287	// the user profile.
1288	CampaignFilter *ObjectFilter `json:"campaignFilter,omitempty"`
1289
1290	// Comments: Comments for this user profile.
1291	Comments string `json:"comments,omitempty"`
1292
1293	// Email: Email of the user profile. The email addresss must be linked
1294	// to a Google Account. This field is required on insertion and is
1295	// read-only after insertion.
1296	Email string `json:"email,omitempty"`
1297
1298	// Id: ID of the user profile. This is a read-only, auto-generated
1299	// field.
1300	Id int64 `json:"id,omitempty,string"`
1301
1302	// Kind: Identifies what kind of resource this is. Value: the fixed
1303	// string "dfareporting#accountUserProfile".
1304	Kind string `json:"kind,omitempty"`
1305
1306	// Locale: Locale of the user profile. This is a required field.
1307	// Acceptable values are: - "cs" (Czech) - "de" (German) - "en"
1308	// (English) - "en-GB" (English United Kingdom) - "es" (Spanish) - "fr"
1309	// (French) - "it" (Italian) - "ja" (Japanese) - "ko" (Korean) - "pl"
1310	// (Polish) - "pt-BR" (Portuguese Brazil) - "ru" (Russian) - "sv"
1311	// (Swedish) - "tr" (Turkish) - "zh-CN" (Chinese Simplified) - "zh-TW"
1312	// (Chinese Traditional)
1313	Locale string `json:"locale,omitempty"`
1314
1315	// Name: Name of the user profile. This is a required field. Must be
1316	// less than 64 characters long, must be globally unique, and cannot
1317	// contain whitespace or any of the following characters: "&;<>"#%,".
1318	Name string `json:"name,omitempty"`
1319
1320	// SiteFilter: Filter that describes which sites are visible to the user
1321	// profile.
1322	SiteFilter *ObjectFilter `json:"siteFilter,omitempty"`
1323
1324	// SubaccountId: Subaccount ID of the user profile. This is a read-only
1325	// field that can be left blank.
1326	SubaccountId int64 `json:"subaccountId,omitempty,string"`
1327
1328	// TraffickerType: Trafficker type of this user profile. This is a
1329	// read-only field.
1330	//
1331	// Possible values:
1332	//   "INTERNAL_NON_TRAFFICKER"
1333	//   "INTERNAL_TRAFFICKER"
1334	//   "EXTERNAL_TRAFFICKER"
1335	TraffickerType string `json:"traffickerType,omitempty"`
1336
1337	// UserAccessType: User type of the user profile. This is a read-only
1338	// field that can be left blank.
1339	//
1340	// Possible values:
1341	//   "NORMAL_USER"
1342	//   "SUPER_USER"
1343	//   "INTERNAL_ADMINISTRATOR"
1344	//   "READ_ONLY_SUPER_USER"
1345	UserAccessType string `json:"userAccessType,omitempty"`
1346
1347	// UserRoleFilter: Filter that describes which user roles are visible to
1348	// the user profile.
1349	UserRoleFilter *ObjectFilter `json:"userRoleFilter,omitempty"`
1350
1351	// UserRoleId: User role ID of the user profile. This is a required
1352	// field.
1353	UserRoleId int64 `json:"userRoleId,omitempty,string"`
1354
1355	// ServerResponse contains the HTTP response code and headers from the
1356	// server.
1357	googleapi.ServerResponse `json:"-"`
1358
1359	// ForceSendFields is a list of field names (e.g. "AccountId") to
1360	// unconditionally include in API requests. By default, fields with
1361	// empty or default values are omitted from API requests. However, any
1362	// non-pointer, non-interface field appearing in ForceSendFields will be
1363	// sent to the server regardless of whether the field is empty or not.
1364	// This may be used to include empty fields in Patch requests.
1365	ForceSendFields []string `json:"-"`
1366
1367	// NullFields is a list of field names (e.g. "AccountId") to include in
1368	// API requests with the JSON null value. By default, fields with empty
1369	// values are omitted from API requests. However, any field with an
1370	// empty value appearing in NullFields will be sent to the server as
1371	// null. It is an error if a field in this list has a non-empty value.
1372	// This may be used to include null fields in Patch requests.
1373	NullFields []string `json:"-"`
1374}
1375
1376func (s *AccountUserProfile) MarshalJSON() ([]byte, error) {
1377	type NoMethod AccountUserProfile
1378	raw := NoMethod(*s)
1379	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1380}
1381
1382// AccountUserProfilesListResponse: Account User Profile List Response
1383type AccountUserProfilesListResponse struct {
1384	// AccountUserProfiles: Account user profile collection.
1385	AccountUserProfiles []*AccountUserProfile `json:"accountUserProfiles,omitempty"`
1386
1387	// Kind: Identifies what kind of resource this is. Value: the fixed
1388	// string "dfareporting#accountUserProfilesListResponse".
1389	Kind string `json:"kind,omitempty"`
1390
1391	// NextPageToken: Pagination token to be used for the next list
1392	// operation.
1393	NextPageToken string `json:"nextPageToken,omitempty"`
1394
1395	// ServerResponse contains the HTTP response code and headers from the
1396	// server.
1397	googleapi.ServerResponse `json:"-"`
1398
1399	// ForceSendFields is a list of field names (e.g. "AccountUserProfiles")
1400	// to unconditionally include in API requests. By default, fields with
1401	// empty or default values are omitted from API requests. However, any
1402	// non-pointer, non-interface field appearing in ForceSendFields will be
1403	// sent to the server regardless of whether the field is empty or not.
1404	// This may be used to include empty fields in Patch requests.
1405	ForceSendFields []string `json:"-"`
1406
1407	// NullFields is a list of field names (e.g. "AccountUserProfiles") to
1408	// include in API requests with the JSON null value. By default, fields
1409	// with empty values are omitted from API requests. However, any field
1410	// with an empty value appearing in NullFields will be sent to the
1411	// server as null. It is an error if a field in this list has a
1412	// non-empty value. This may be used to include null fields in Patch
1413	// requests.
1414	NullFields []string `json:"-"`
1415}
1416
1417func (s *AccountUserProfilesListResponse) MarshalJSON() ([]byte, error) {
1418	type NoMethod AccountUserProfilesListResponse
1419	raw := NoMethod(*s)
1420	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1421}
1422
1423// AccountsListResponse: Account List Response
1424type AccountsListResponse struct {
1425	// Accounts: Account collection.
1426	Accounts []*Account `json:"accounts,omitempty"`
1427
1428	// Kind: Identifies what kind of resource this is. Value: the fixed
1429	// string "dfareporting#accountsListResponse".
1430	Kind string `json:"kind,omitempty"`
1431
1432	// NextPageToken: Pagination token to be used for the next list
1433	// operation.
1434	NextPageToken string `json:"nextPageToken,omitempty"`
1435
1436	// ServerResponse contains the HTTP response code and headers from the
1437	// server.
1438	googleapi.ServerResponse `json:"-"`
1439
1440	// ForceSendFields is a list of field names (e.g. "Accounts") to
1441	// unconditionally include in API requests. By default, fields with
1442	// empty or default values are omitted from API requests. However, any
1443	// non-pointer, non-interface field appearing in ForceSendFields will be
1444	// sent to the server regardless of whether the field is empty or not.
1445	// This may be used to include empty fields in Patch requests.
1446	ForceSendFields []string `json:"-"`
1447
1448	// NullFields is a list of field names (e.g. "Accounts") to include in
1449	// API requests with the JSON null value. By default, fields with empty
1450	// values are omitted from API requests. However, any field with an
1451	// empty value appearing in NullFields will be sent to the server as
1452	// null. It is an error if a field in this list has a non-empty value.
1453	// This may be used to include null fields in Patch requests.
1454	NullFields []string `json:"-"`
1455}
1456
1457func (s *AccountsListResponse) MarshalJSON() ([]byte, error) {
1458	type NoMethod AccountsListResponse
1459	raw := NoMethod(*s)
1460	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1461}
1462
1463// Activities: Represents an activity group.
1464type Activities struct {
1465	// Filters: List of activity filters. The dimension values need to be
1466	// all either of type "dfa:activity" or "dfa:activityGroup".
1467	Filters []*DimensionValue `json:"filters,omitempty"`
1468
1469	// Kind: The kind of resource this is, in this case
1470	// dfareporting#activities.
1471	Kind string `json:"kind,omitempty"`
1472
1473	// MetricNames: List of names of floodlight activity metrics.
1474	MetricNames []string `json:"metricNames,omitempty"`
1475
1476	// ForceSendFields is a list of field names (e.g. "Filters") to
1477	// unconditionally include in API requests. By default, fields with
1478	// empty or default values are omitted from API requests. However, any
1479	// non-pointer, non-interface field appearing in ForceSendFields will be
1480	// sent to the server regardless of whether the field is empty or not.
1481	// This may be used to include empty fields in Patch requests.
1482	ForceSendFields []string `json:"-"`
1483
1484	// NullFields is a list of field names (e.g. "Filters") to include in
1485	// API requests with the JSON null value. By default, fields with empty
1486	// values are omitted from API requests. However, any field with an
1487	// empty value appearing in NullFields will be sent to the server as
1488	// null. It is an error if a field in this list has a non-empty value.
1489	// This may be used to include null fields in Patch requests.
1490	NullFields []string `json:"-"`
1491}
1492
1493func (s *Activities) MarshalJSON() ([]byte, error) {
1494	type NoMethod Activities
1495	raw := NoMethod(*s)
1496	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1497}
1498
1499// Ad: Contains properties of a Campaign Manager ad.
1500type Ad struct {
1501	// AccountId: Account ID of this ad. This is a read-only field that can
1502	// be left blank.
1503	AccountId int64 `json:"accountId,omitempty,string"`
1504
1505	// Active: Whether this ad is active. When true, archived must be false.
1506	Active bool `json:"active,omitempty"`
1507
1508	// AdvertiserId: Advertiser ID of this ad. This is a required field on
1509	// insertion.
1510	AdvertiserId int64 `json:"advertiserId,omitempty,string"`
1511
1512	// AdvertiserIdDimensionValue: Dimension value for the ID of the
1513	// advertiser. This is a read-only, auto-generated field.
1514	AdvertiserIdDimensionValue *DimensionValue `json:"advertiserIdDimensionValue,omitempty"`
1515
1516	// Archived: Whether this ad is archived. When true, active must be
1517	// false.
1518	Archived bool `json:"archived,omitempty"`
1519
1520	// AudienceSegmentId: Audience segment ID that is being targeted for
1521	// this ad. Applicable when type is AD_SERVING_STANDARD_AD.
1522	AudienceSegmentId int64 `json:"audienceSegmentId,omitempty,string"`
1523
1524	// CampaignId: Campaign ID of this ad. This is a required field on
1525	// insertion.
1526	CampaignId int64 `json:"campaignId,omitempty,string"`
1527
1528	// CampaignIdDimensionValue: Dimension value for the ID of the campaign.
1529	// This is a read-only, auto-generated field.
1530	CampaignIdDimensionValue *DimensionValue `json:"campaignIdDimensionValue,omitempty"`
1531
1532	// ClickThroughUrl: Click-through URL for this ad. This is a required
1533	// field on insertion. Applicable when type is AD_SERVING_CLICK_TRACKER.
1534	ClickThroughUrl *ClickThroughUrl `json:"clickThroughUrl,omitempty"`
1535
1536	// ClickThroughUrlSuffixProperties: Click-through URL suffix properties
1537	// for this ad. Applies to the URL in the ad or (if overriding ad
1538	// properties) the URL in the creative.
1539	ClickThroughUrlSuffixProperties *ClickThroughUrlSuffixProperties `json:"clickThroughUrlSuffixProperties,omitempty"`
1540
1541	// Comments: Comments for this ad.
1542	Comments string `json:"comments,omitempty"`
1543
1544	// Compatibility: Compatibility of this ad. Applicable when type is
1545	// AD_SERVING_DEFAULT_AD. DISPLAY and DISPLAY_INTERSTITIAL refer to
1546	// either rendering on desktop or on mobile devices or in mobile apps
1547	// for regular or interstitial ads, respectively. APP and
1548	// APP_INTERSTITIAL are only used for existing default ads. New mobile
1549	// placements must be assigned DISPLAY or DISPLAY_INTERSTITIAL and
1550	// default ads created for those placements will be limited to those
1551	// compatibility types. IN_STREAM_VIDEO refers to rendering in-stream
1552	// video ads developed with the VAST standard.
1553	//
1554	// Possible values:
1555	//   "DISPLAY"
1556	//   "DISPLAY_INTERSTITIAL"
1557	//   "APP"
1558	//   "APP_INTERSTITIAL"
1559	//   "IN_STREAM_VIDEO"
1560	//   "IN_STREAM_AUDIO"
1561	Compatibility string `json:"compatibility,omitempty"`
1562
1563	// CreateInfo: Information about the creation of this ad. This is a
1564	// read-only field.
1565	CreateInfo *LastModifiedInfo `json:"createInfo,omitempty"`
1566
1567	// CreativeGroupAssignments: Creative group assignments for this ad.
1568	// Applicable when type is AD_SERVING_CLICK_TRACKER. Only one assignment
1569	// per creative group number is allowed for a maximum of two
1570	// assignments.
1571	CreativeGroupAssignments []*CreativeGroupAssignment `json:"creativeGroupAssignments,omitempty"`
1572
1573	// CreativeRotation: Creative rotation for this ad. Applicable when type
1574	// is AD_SERVING_DEFAULT_AD, AD_SERVING_STANDARD_AD, or
1575	// AD_SERVING_TRACKING. When type is AD_SERVING_DEFAULT_AD, this field
1576	// should have exactly one creativeAssignment .
1577	CreativeRotation *CreativeRotation `json:"creativeRotation,omitempty"`
1578
1579	// DayPartTargeting: Time and day targeting information for this ad.
1580	// This field must be left blank if the ad is using a targeting
1581	// template. Applicable when type is AD_SERVING_STANDARD_AD.
1582	DayPartTargeting *DayPartTargeting `json:"dayPartTargeting,omitempty"`
1583
1584	// DefaultClickThroughEventTagProperties: Default click-through event
1585	// tag properties for this ad.
1586	DefaultClickThroughEventTagProperties *DefaultClickThroughEventTagProperties `json:"defaultClickThroughEventTagProperties,omitempty"`
1587
1588	// DeliverySchedule: Delivery schedule information for this ad.
1589	// Applicable when type is AD_SERVING_STANDARD_AD or
1590	// AD_SERVING_TRACKING. This field along with subfields priority and
1591	// impressionRatio are required on insertion when type is
1592	// AD_SERVING_STANDARD_AD.
1593	DeliverySchedule *DeliverySchedule `json:"deliverySchedule,omitempty"`
1594
1595	// DynamicClickTracker: Whether this ad is a dynamic click tracker.
1596	// Applicable when type is AD_SERVING_CLICK_TRACKER. This is a required
1597	// field on insert, and is read-only after insert.
1598	DynamicClickTracker bool `json:"dynamicClickTracker,omitempty"`
1599
1600	EndTime string `json:"endTime,omitempty"`
1601
1602	// EventTagOverrides: Event tag overrides for this ad.
1603	EventTagOverrides []*EventTagOverride `json:"eventTagOverrides,omitempty"`
1604
1605	// GeoTargeting: Geographical targeting information for this ad. This
1606	// field must be left blank if the ad is using a targeting template.
1607	// Applicable when type is AD_SERVING_STANDARD_AD.
1608	GeoTargeting *GeoTargeting `json:"geoTargeting,omitempty"`
1609
1610	// Id: ID of this ad. This is a read-only, auto-generated field.
1611	Id int64 `json:"id,omitempty,string"`
1612
1613	// IdDimensionValue: Dimension value for the ID of this ad. This is a
1614	// read-only, auto-generated field.
1615	IdDimensionValue *DimensionValue `json:"idDimensionValue,omitempty"`
1616
1617	// KeyValueTargetingExpression: Key-value targeting information for this
1618	// ad. This field must be left blank if the ad is using a targeting
1619	// template. Applicable when type is AD_SERVING_STANDARD_AD.
1620	KeyValueTargetingExpression *KeyValueTargetingExpression `json:"keyValueTargetingExpression,omitempty"`
1621
1622	// Kind: Identifies what kind of resource this is. Value: the fixed
1623	// string "dfareporting#ad".
1624	Kind string `json:"kind,omitempty"`
1625
1626	// LanguageTargeting: Language targeting information for this ad. This
1627	// field must be left blank if the ad is using a targeting template.
1628	// Applicable when type is AD_SERVING_STANDARD_AD.
1629	LanguageTargeting *LanguageTargeting `json:"languageTargeting,omitempty"`
1630
1631	// LastModifiedInfo: Information about the most recent modification of
1632	// this ad. This is a read-only field.
1633	LastModifiedInfo *LastModifiedInfo `json:"lastModifiedInfo,omitempty"`
1634
1635	// Name: Name of this ad. This is a required field and must be less than
1636	// 256 characters long.
1637	Name string `json:"name,omitempty"`
1638
1639	// PlacementAssignments: Placement assignments for this ad.
1640	PlacementAssignments []*PlacementAssignment `json:"placementAssignments,omitempty"`
1641
1642	// RemarketingListExpression: Remarketing list targeting expression for
1643	// this ad. This field must be left blank if the ad is using a targeting
1644	// template. Applicable when type is AD_SERVING_STANDARD_AD.
1645	RemarketingListExpression *ListTargetingExpression `json:"remarketingListExpression,omitempty"`
1646
1647	// Size: Size of this ad. Applicable when type is AD_SERVING_DEFAULT_AD.
1648	Size *Size `json:"size,omitempty"`
1649
1650	// SslCompliant: Whether this ad is ssl compliant. This is a read-only
1651	// field that is auto-generated when the ad is inserted or updated.
1652	SslCompliant bool `json:"sslCompliant,omitempty"`
1653
1654	// SslRequired: Whether this ad requires ssl. This is a read-only field
1655	// that is auto-generated when the ad is inserted or updated.
1656	SslRequired bool `json:"sslRequired,omitempty"`
1657
1658	StartTime string `json:"startTime,omitempty"`
1659
1660	// SubaccountId: Subaccount ID of this ad. This is a read-only field
1661	// that can be left blank.
1662	SubaccountId int64 `json:"subaccountId,omitempty,string"`
1663
1664	// TargetingTemplateId: Targeting template ID, used to apply
1665	// preconfigured targeting information to this ad. This cannot be set
1666	// while any of dayPartTargeting, geoTargeting,
1667	// keyValueTargetingExpression, languageTargeting,
1668	// remarketingListExpression, or technologyTargeting are set. Applicable
1669	// when type is AD_SERVING_STANDARD_AD.
1670	TargetingTemplateId int64 `json:"targetingTemplateId,omitempty,string"`
1671
1672	// TechnologyTargeting: Technology platform targeting information for
1673	// this ad. This field must be left blank if the ad is using a targeting
1674	// template. Applicable when type is AD_SERVING_STANDARD_AD.
1675	TechnologyTargeting *TechnologyTargeting `json:"technologyTargeting,omitempty"`
1676
1677	// Type: Type of ad. This is a required field on insertion. Note that
1678	// default ads ( AD_SERVING_DEFAULT_AD) cannot be created directly (see
1679	// Creative resource).
1680	//
1681	// Possible values:
1682	//   "AD_SERVING_STANDARD_AD"
1683	//   "AD_SERVING_DEFAULT_AD"
1684	//   "AD_SERVING_CLICK_TRACKER"
1685	//   "AD_SERVING_TRACKING"
1686	//   "AD_SERVING_BRAND_SAFE_AD"
1687	Type string `json:"type,omitempty"`
1688
1689	// ServerResponse contains the HTTP response code and headers from the
1690	// server.
1691	googleapi.ServerResponse `json:"-"`
1692
1693	// ForceSendFields is a list of field names (e.g. "AccountId") to
1694	// unconditionally include in API requests. By default, fields with
1695	// empty or default values are omitted from API requests. However, any
1696	// non-pointer, non-interface field appearing in ForceSendFields will be
1697	// sent to the server regardless of whether the field is empty or not.
1698	// This may be used to include empty fields in Patch requests.
1699	ForceSendFields []string `json:"-"`
1700
1701	// NullFields is a list of field names (e.g. "AccountId") to include in
1702	// API requests with the JSON null value. By default, fields with empty
1703	// values are omitted from API requests. However, any field with an
1704	// empty value appearing in NullFields will be sent to the server as
1705	// null. It is an error if a field in this list has a non-empty value.
1706	// This may be used to include null fields in Patch requests.
1707	NullFields []string `json:"-"`
1708}
1709
1710func (s *Ad) MarshalJSON() ([]byte, error) {
1711	type NoMethod Ad
1712	raw := NoMethod(*s)
1713	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1714}
1715
1716// AdBlockingConfiguration: Campaign ad blocking settings.
1717type AdBlockingConfiguration struct {
1718	// ClickThroughUrl: Click-through URL used by brand-neutral ads. This is
1719	// a required field when overrideClickThroughUrl is set to true.
1720	ClickThroughUrl string `json:"clickThroughUrl,omitempty"`
1721
1722	// CreativeBundleId: ID of a creative bundle to use for this campaign.
1723	// If set, brand-neutral ads will select creatives from this bundle.
1724	// Otherwise, a default transparent pixel will be used.
1725	CreativeBundleId int64 `json:"creativeBundleId,omitempty,string"`
1726
1727	// Enabled: Whether this campaign has enabled ad blocking. When true, ad
1728	// blocking is enabled for placements in the campaign, but this may be
1729	// overridden by site and placement settings. When false, ad blocking is
1730	// disabled for all placements under the campaign, regardless of site
1731	// and placement settings.
1732	Enabled bool `json:"enabled,omitempty"`
1733
1734	// OverrideClickThroughUrl: Whether the brand-neutral ad's click-through
1735	// URL comes from the campaign's creative bundle or the override URL.
1736	// Must be set to true if ad blocking is enabled and no creative bundle
1737	// is configured.
1738	OverrideClickThroughUrl bool `json:"overrideClickThroughUrl,omitempty"`
1739
1740	// ForceSendFields is a list of field names (e.g. "ClickThroughUrl") to
1741	// unconditionally include in API requests. By default, fields with
1742	// empty or default values are omitted from API requests. However, any
1743	// non-pointer, non-interface field appearing in ForceSendFields will be
1744	// sent to the server regardless of whether the field is empty or not.
1745	// This may be used to include empty fields in Patch requests.
1746	ForceSendFields []string `json:"-"`
1747
1748	// NullFields is a list of field names (e.g. "ClickThroughUrl") to
1749	// include in API requests with the JSON null value. By default, fields
1750	// with empty values are omitted from API requests. However, any field
1751	// with an empty value appearing in NullFields will be sent to the
1752	// server as null. It is an error if a field in this list has a
1753	// non-empty value. This may be used to include null fields in Patch
1754	// requests.
1755	NullFields []string `json:"-"`
1756}
1757
1758func (s *AdBlockingConfiguration) MarshalJSON() ([]byte, error) {
1759	type NoMethod AdBlockingConfiguration
1760	raw := NoMethod(*s)
1761	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1762}
1763
1764// AdSlot: Ad Slot
1765type AdSlot struct {
1766	// Comment: Comment for this ad slot.
1767	Comment string `json:"comment,omitempty"`
1768
1769	// Compatibility: Ad slot compatibility. DISPLAY and
1770	// DISPLAY_INTERSTITIAL refer to rendering either on desktop, mobile
1771	// devices or in mobile apps for regular or interstitial ads
1772	// respectively. APP and APP_INTERSTITIAL are for rendering in mobile
1773	// apps. IN_STREAM_VIDEO refers to rendering in in-stream video ads
1774	// developed with the VAST standard.
1775	//
1776	// Possible values:
1777	//   "DISPLAY"
1778	//   "DISPLAY_INTERSTITIAL"
1779	//   "APP"
1780	//   "APP_INTERSTITIAL"
1781	//   "IN_STREAM_VIDEO"
1782	//   "IN_STREAM_AUDIO"
1783	Compatibility string `json:"compatibility,omitempty"`
1784
1785	// Height: Height of this ad slot.
1786	Height int64 `json:"height,omitempty,string"`
1787
1788	// LinkedPlacementId: ID of the placement from an external platform that
1789	// is linked to this ad slot.
1790	LinkedPlacementId int64 `json:"linkedPlacementId,omitempty,string"`
1791
1792	// Name: Name of this ad slot.
1793	Name string `json:"name,omitempty"`
1794
1795	// PaymentSourceType: Payment source type of this ad slot.
1796	//
1797	// Possible values:
1798	//   "PLANNING_PAYMENT_SOURCE_TYPE_AGENCY_PAID"
1799	//   "PLANNING_PAYMENT_SOURCE_TYPE_PUBLISHER_PAID"
1800	PaymentSourceType string `json:"paymentSourceType,omitempty"`
1801
1802	// Primary: Primary ad slot of a roadblock inventory item.
1803	Primary bool `json:"primary,omitempty"`
1804
1805	// Width: Width of this ad slot.
1806	Width int64 `json:"width,omitempty,string"`
1807
1808	// ForceSendFields is a list of field names (e.g. "Comment") to
1809	// unconditionally include in API requests. By default, fields with
1810	// empty or default values are omitted from API requests. However, any
1811	// non-pointer, non-interface field appearing in ForceSendFields will be
1812	// sent to the server regardless of whether the field is empty or not.
1813	// This may be used to include empty fields in Patch requests.
1814	ForceSendFields []string `json:"-"`
1815
1816	// NullFields is a list of field names (e.g. "Comment") to include in
1817	// API requests with the JSON null value. By default, fields with empty
1818	// values are omitted from API requests. However, any field with an
1819	// empty value appearing in NullFields will be sent to the server as
1820	// null. It is an error if a field in this list has a non-empty value.
1821	// This may be used to include null fields in Patch requests.
1822	NullFields []string `json:"-"`
1823}
1824
1825func (s *AdSlot) MarshalJSON() ([]byte, error) {
1826	type NoMethod AdSlot
1827	raw := NoMethod(*s)
1828	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1829}
1830
1831// AdsListResponse: Ad List Response
1832type AdsListResponse struct {
1833	// Ads: Ad collection.
1834	Ads []*Ad `json:"ads,omitempty"`
1835
1836	// Kind: Identifies what kind of resource this is. Value: the fixed
1837	// string "dfareporting#adsListResponse".
1838	Kind string `json:"kind,omitempty"`
1839
1840	// NextPageToken: Pagination token to be used for the next list
1841	// operation.
1842	NextPageToken string `json:"nextPageToken,omitempty"`
1843
1844	// ServerResponse contains the HTTP response code and headers from the
1845	// server.
1846	googleapi.ServerResponse `json:"-"`
1847
1848	// ForceSendFields is a list of field names (e.g. "Ads") to
1849	// unconditionally include in API requests. By default, fields with
1850	// empty or default values are omitted from API requests. However, any
1851	// non-pointer, non-interface field appearing in ForceSendFields will be
1852	// sent to the server regardless of whether the field is empty or not.
1853	// This may be used to include empty fields in Patch requests.
1854	ForceSendFields []string `json:"-"`
1855
1856	// NullFields is a list of field names (e.g. "Ads") to include in API
1857	// requests with the JSON null value. By default, fields with empty
1858	// values are omitted from API requests. However, any field with an
1859	// empty value appearing in NullFields will be sent to the server as
1860	// null. It is an error if a field in this list has a non-empty value.
1861	// This may be used to include null fields in Patch requests.
1862	NullFields []string `json:"-"`
1863}
1864
1865func (s *AdsListResponse) MarshalJSON() ([]byte, error) {
1866	type NoMethod AdsListResponse
1867	raw := NoMethod(*s)
1868	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1869}
1870
1871// Advertiser: Contains properties of a Campaign Manager advertiser.
1872type Advertiser struct {
1873	// AccountId: Account ID of this advertiser.This is a read-only field
1874	// that can be left blank.
1875	AccountId int64 `json:"accountId,omitempty,string"`
1876
1877	// AdvertiserGroupId: ID of the advertiser group this advertiser belongs
1878	// to. You can group advertisers for reporting purposes, allowing you to
1879	// see aggregated information for all advertisers in each group.
1880	AdvertiserGroupId int64 `json:"advertiserGroupId,omitempty,string"`
1881
1882	// ClickThroughUrlSuffix: Suffix added to click-through URL of ad
1883	// creative associations under this advertiser. Must be less than 129
1884	// characters long.
1885	ClickThroughUrlSuffix string `json:"clickThroughUrlSuffix,omitempty"`
1886
1887	// DefaultClickThroughEventTagId: ID of the click-through event tag to
1888	// apply by default to the landing pages of this advertiser's campaigns.
1889	DefaultClickThroughEventTagId int64 `json:"defaultClickThroughEventTagId,omitempty,string"`
1890
1891	// DefaultEmail: Default email address used in sender field for tag
1892	// emails.
1893	DefaultEmail string `json:"defaultEmail,omitempty"`
1894
1895	// FloodlightConfigurationId: Floodlight configuration ID of this
1896	// advertiser. The floodlight configuration ID will be created
1897	// automatically, so on insert this field should be left blank. This
1898	// field can be set to another advertiser's floodlight configuration ID
1899	// in order to share that advertiser's floodlight configuration with
1900	// this advertiser, so long as: - This advertiser's original floodlight
1901	// configuration is not already associated with floodlight activities or
1902	// floodlight activity groups. - This advertiser's original floodlight
1903	// configuration is not already shared with another advertiser.
1904	FloodlightConfigurationId int64 `json:"floodlightConfigurationId,omitempty,string"`
1905
1906	// FloodlightConfigurationIdDimensionValue: Dimension value for the ID
1907	// of the floodlight configuration. This is a read-only, auto-generated
1908	// field.
1909	FloodlightConfigurationIdDimensionValue *DimensionValue `json:"floodlightConfigurationIdDimensionValue,omitempty"`
1910
1911	// Id: ID of this advertiser. This is a read-only, auto-generated field.
1912	Id int64 `json:"id,omitempty,string"`
1913
1914	// IdDimensionValue: Dimension value for the ID of this advertiser. This
1915	// is a read-only, auto-generated field.
1916	IdDimensionValue *DimensionValue `json:"idDimensionValue,omitempty"`
1917
1918	// Kind: Identifies what kind of resource this is. Value: the fixed
1919	// string "dfareporting#advertiser".
1920	Kind string `json:"kind,omitempty"`
1921
1922	// Name: Name of this advertiser. This is a required field and must be
1923	// less than 256 characters long and unique among advertisers of the
1924	// same account.
1925	Name string `json:"name,omitempty"`
1926
1927	// OriginalFloodlightConfigurationId: Original floodlight configuration
1928	// before any sharing occurred. Set the floodlightConfigurationId of
1929	// this advertiser to originalFloodlightConfigurationId to unshare the
1930	// advertiser's current floodlight configuration. You cannot unshare an
1931	// advertiser's floodlight configuration if the shared configuration has
1932	// activities associated with any campaign or placement.
1933	OriginalFloodlightConfigurationId int64 `json:"originalFloodlightConfigurationId,omitempty,string"`
1934
1935	// Status: Status of this advertiser.
1936	//
1937	// Possible values:
1938	//   "APPROVED"
1939	//   "ON_HOLD"
1940	Status string `json:"status,omitempty"`
1941
1942	// SubaccountId: Subaccount ID of this advertiser.This is a read-only
1943	// field that can be left blank.
1944	SubaccountId int64 `json:"subaccountId,omitempty,string"`
1945
1946	// Suspended: Suspension status of this advertiser.
1947	Suspended bool `json:"suspended,omitempty"`
1948
1949	// ServerResponse contains the HTTP response code and headers from the
1950	// server.
1951	googleapi.ServerResponse `json:"-"`
1952
1953	// ForceSendFields is a list of field names (e.g. "AccountId") to
1954	// unconditionally include in API requests. By default, fields with
1955	// empty or default values are omitted from API requests. However, any
1956	// non-pointer, non-interface field appearing in ForceSendFields will be
1957	// sent to the server regardless of whether the field is empty or not.
1958	// This may be used to include empty fields in Patch requests.
1959	ForceSendFields []string `json:"-"`
1960
1961	// NullFields is a list of field names (e.g. "AccountId") to include in
1962	// API requests with the JSON null value. By default, fields with empty
1963	// values are omitted from API requests. However, any field with an
1964	// empty value appearing in NullFields will be sent to the server as
1965	// null. It is an error if a field in this list has a non-empty value.
1966	// This may be used to include null fields in Patch requests.
1967	NullFields []string `json:"-"`
1968}
1969
1970func (s *Advertiser) MarshalJSON() ([]byte, error) {
1971	type NoMethod Advertiser
1972	raw := NoMethod(*s)
1973	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1974}
1975
1976// AdvertiserGroup: Groups advertisers together so that reports can be
1977// generated for the entire group at once.
1978type AdvertiserGroup struct {
1979	// AccountId: Account ID of this advertiser group. This is a read-only
1980	// field that can be left blank.
1981	AccountId int64 `json:"accountId,omitempty,string"`
1982
1983	// Id: ID of this advertiser group. This is a read-only, auto-generated
1984	// field.
1985	Id int64 `json:"id,omitempty,string"`
1986
1987	// Kind: Identifies what kind of resource this is. Value: the fixed
1988	// string "dfareporting#advertiserGroup".
1989	Kind string `json:"kind,omitempty"`
1990
1991	// Name: Name of this advertiser group. This is a required field and
1992	// must be less than 256 characters long and unique among advertiser
1993	// groups of the same account.
1994	Name string `json:"name,omitempty"`
1995
1996	// ServerResponse contains the HTTP response code and headers from the
1997	// server.
1998	googleapi.ServerResponse `json:"-"`
1999
2000	// ForceSendFields is a list of field names (e.g. "AccountId") to
2001	// unconditionally include in API requests. By default, fields with
2002	// empty or default values are omitted from API requests. However, any
2003	// non-pointer, non-interface field appearing in ForceSendFields will be
2004	// sent to the server regardless of whether the field is empty or not.
2005	// This may be used to include empty fields in Patch requests.
2006	ForceSendFields []string `json:"-"`
2007
2008	// NullFields is a list of field names (e.g. "AccountId") to include in
2009	// API requests with the JSON null value. By default, fields with empty
2010	// values are omitted from API requests. However, any field with an
2011	// empty value appearing in NullFields will be sent to the server as
2012	// null. It is an error if a field in this list has a non-empty value.
2013	// This may be used to include null fields in Patch requests.
2014	NullFields []string `json:"-"`
2015}
2016
2017func (s *AdvertiserGroup) MarshalJSON() ([]byte, error) {
2018	type NoMethod AdvertiserGroup
2019	raw := NoMethod(*s)
2020	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2021}
2022
2023// AdvertiserGroupsListResponse: Advertiser Group List Response
2024type AdvertiserGroupsListResponse struct {
2025	// AdvertiserGroups: Advertiser group collection.
2026	AdvertiserGroups []*AdvertiserGroup `json:"advertiserGroups,omitempty"`
2027
2028	// Kind: Identifies what kind of resource this is. Value: the fixed
2029	// string "dfareporting#advertiserGroupsListResponse".
2030	Kind string `json:"kind,omitempty"`
2031
2032	// NextPageToken: Pagination token to be used for the next list
2033	// operation.
2034	NextPageToken string `json:"nextPageToken,omitempty"`
2035
2036	// ServerResponse contains the HTTP response code and headers from the
2037	// server.
2038	googleapi.ServerResponse `json:"-"`
2039
2040	// ForceSendFields is a list of field names (e.g. "AdvertiserGroups") to
2041	// unconditionally include in API requests. By default, fields with
2042	// empty or default values are omitted from API requests. However, any
2043	// non-pointer, non-interface field appearing in ForceSendFields will be
2044	// sent to the server regardless of whether the field is empty or not.
2045	// This may be used to include empty fields in Patch requests.
2046	ForceSendFields []string `json:"-"`
2047
2048	// NullFields is a list of field names (e.g. "AdvertiserGroups") to
2049	// include in API requests with the JSON null value. By default, fields
2050	// with empty values are omitted from API requests. However, any field
2051	// with an empty value appearing in NullFields will be sent to the
2052	// server as null. It is an error if a field in this list has a
2053	// non-empty value. This may be used to include null fields in Patch
2054	// requests.
2055	NullFields []string `json:"-"`
2056}
2057
2058func (s *AdvertiserGroupsListResponse) MarshalJSON() ([]byte, error) {
2059	type NoMethod AdvertiserGroupsListResponse
2060	raw := NoMethod(*s)
2061	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2062}
2063
2064// AdvertiserLandingPagesListResponse: Landing Page List Response
2065type AdvertiserLandingPagesListResponse struct {
2066	// Kind: Identifies what kind of resource this is. Value: the fixed
2067	// string "dfareporting#advertiserLandingPagesListResponse".
2068	Kind string `json:"kind,omitempty"`
2069
2070	// LandingPages: Landing page collection
2071	LandingPages []*LandingPage `json:"landingPages,omitempty"`
2072
2073	// NextPageToken: Pagination token to be used for the next list
2074	// operation.
2075	NextPageToken string `json:"nextPageToken,omitempty"`
2076
2077	// ServerResponse contains the HTTP response code and headers from the
2078	// server.
2079	googleapi.ServerResponse `json:"-"`
2080
2081	// ForceSendFields is a list of field names (e.g. "Kind") to
2082	// unconditionally include in API requests. By default, fields with
2083	// empty or default values are omitted from API requests. However, any
2084	// non-pointer, non-interface field appearing in ForceSendFields will be
2085	// sent to the server regardless of whether the field is empty or not.
2086	// This may be used to include empty fields in Patch requests.
2087	ForceSendFields []string `json:"-"`
2088
2089	// NullFields is a list of field names (e.g. "Kind") to include in API
2090	// requests with the JSON null value. By default, fields with empty
2091	// values are omitted from API requests. However, any field with an
2092	// empty value appearing in NullFields will be sent to the server as
2093	// null. It is an error if a field in this list has a non-empty value.
2094	// This may be used to include null fields in Patch requests.
2095	NullFields []string `json:"-"`
2096}
2097
2098func (s *AdvertiserLandingPagesListResponse) MarshalJSON() ([]byte, error) {
2099	type NoMethod AdvertiserLandingPagesListResponse
2100	raw := NoMethod(*s)
2101	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2102}
2103
2104// AdvertisersListResponse: Advertiser List Response
2105type AdvertisersListResponse struct {
2106	// Advertisers: Advertiser collection.
2107	Advertisers []*Advertiser `json:"advertisers,omitempty"`
2108
2109	// Kind: Identifies what kind of resource this is. Value: the fixed
2110	// string "dfareporting#advertisersListResponse".
2111	Kind string `json:"kind,omitempty"`
2112
2113	// NextPageToken: Pagination token to be used for the next list
2114	// operation.
2115	NextPageToken string `json:"nextPageToken,omitempty"`
2116
2117	// ServerResponse contains the HTTP response code and headers from the
2118	// server.
2119	googleapi.ServerResponse `json:"-"`
2120
2121	// ForceSendFields is a list of field names (e.g. "Advertisers") to
2122	// unconditionally include in API requests. By default, fields with
2123	// empty or default values are omitted from API requests. However, any
2124	// non-pointer, non-interface field appearing in ForceSendFields will be
2125	// sent to the server regardless of whether the field is empty or not.
2126	// This may be used to include empty fields in Patch requests.
2127	ForceSendFields []string `json:"-"`
2128
2129	// NullFields is a list of field names (e.g. "Advertisers") to include
2130	// in API requests with the JSON null value. By default, fields with
2131	// empty values are omitted from API requests. However, any field with
2132	// an empty value appearing in NullFields will be sent to the server as
2133	// null. It is an error if a field in this list has a non-empty value.
2134	// This may be used to include null fields in Patch requests.
2135	NullFields []string `json:"-"`
2136}
2137
2138func (s *AdvertisersListResponse) MarshalJSON() ([]byte, error) {
2139	type NoMethod AdvertisersListResponse
2140	raw := NoMethod(*s)
2141	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2142}
2143
2144// AudienceSegment: Audience Segment.
2145type AudienceSegment struct {
2146	// Allocation: Weight allocated to this segment. The weight assigned
2147	// will be understood in proportion to the weights assigned to other
2148	// segments in the same segment group. Acceptable values are 1 to 1000,
2149	// inclusive.
2150	Allocation int64 `json:"allocation,omitempty"`
2151
2152	// Id: ID of this audience segment. This is a read-only, auto-generated
2153	// field.
2154	Id int64 `json:"id,omitempty,string"`
2155
2156	// Name: Name of this audience segment. This is a required field and
2157	// must be less than 65 characters long.
2158	Name string `json:"name,omitempty"`
2159
2160	// ForceSendFields is a list of field names (e.g. "Allocation") to
2161	// unconditionally include in API requests. By default, fields with
2162	// empty or default values are omitted from API requests. However, any
2163	// non-pointer, non-interface field appearing in ForceSendFields will be
2164	// sent to the server regardless of whether the field is empty or not.
2165	// This may be used to include empty fields in Patch requests.
2166	ForceSendFields []string `json:"-"`
2167
2168	// NullFields is a list of field names (e.g. "Allocation") to include in
2169	// API requests with the JSON null value. By default, fields with empty
2170	// values are omitted from API requests. However, any field with an
2171	// empty value appearing in NullFields will be sent to the server as
2172	// null. It is an error if a field in this list has a non-empty value.
2173	// This may be used to include null fields in Patch requests.
2174	NullFields []string `json:"-"`
2175}
2176
2177func (s *AudienceSegment) MarshalJSON() ([]byte, error) {
2178	type NoMethod AudienceSegment
2179	raw := NoMethod(*s)
2180	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2181}
2182
2183// AudienceSegmentGroup: Audience Segment Group.
2184type AudienceSegmentGroup struct {
2185	// AudienceSegments: Audience segments assigned to this group. The
2186	// number of segments must be between 2 and 100.
2187	AudienceSegments []*AudienceSegment `json:"audienceSegments,omitempty"`
2188
2189	// Id: ID of this audience segment group. This is a read-only,
2190	// auto-generated field.
2191	Id int64 `json:"id,omitempty,string"`
2192
2193	// Name: Name of this audience segment group. This is a required field
2194	// and must be less than 65 characters long.
2195	Name string `json:"name,omitempty"`
2196
2197	// ForceSendFields is a list of field names (e.g. "AudienceSegments") to
2198	// unconditionally include in API requests. By default, fields with
2199	// empty or default values are omitted from API requests. However, any
2200	// non-pointer, non-interface field appearing in ForceSendFields will be
2201	// sent to the server regardless of whether the field is empty or not.
2202	// This may be used to include empty fields in Patch requests.
2203	ForceSendFields []string `json:"-"`
2204
2205	// NullFields is a list of field names (e.g. "AudienceSegments") to
2206	// include in API requests with the JSON null value. By default, fields
2207	// with empty values are omitted from API requests. However, any field
2208	// with an empty value appearing in NullFields will be sent to the
2209	// server as null. It is an error if a field in this list has a
2210	// non-empty value. This may be used to include null fields in Patch
2211	// requests.
2212	NullFields []string `json:"-"`
2213}
2214
2215func (s *AudienceSegmentGroup) MarshalJSON() ([]byte, error) {
2216	type NoMethod AudienceSegmentGroup
2217	raw := NoMethod(*s)
2218	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2219}
2220
2221// Browser: Contains information about a browser that can be targeted by
2222// ads.
2223type Browser struct {
2224	// BrowserVersionId: ID referring to this grouping of browser and
2225	// version numbers. This is the ID used for targeting.
2226	BrowserVersionId int64 `json:"browserVersionId,omitempty,string"`
2227
2228	// DartId: DART ID of this browser. This is the ID used when generating
2229	// reports.
2230	DartId int64 `json:"dartId,omitempty,string"`
2231
2232	// Kind: Identifies what kind of resource this is. Value: the fixed
2233	// string "dfareporting#browser".
2234	Kind string `json:"kind,omitempty"`
2235
2236	// MajorVersion: Major version number (leftmost number) of this browser.
2237	// For example, for Chrome 5.0.376.86 beta, this field should be set to
2238	// 5. An asterisk (*) may be used to target any version number, and a
2239	// question mark (?) may be used to target cases where the version
2240	// number cannot be identified. For example, Chrome *.* targets any
2241	// version of Chrome: 1.2, 2.5, 3.5, and so on. Chrome 3.* targets
2242	// Chrome 3.1, 3.5, but not 4.0. Firefox ?.? targets cases where the ad
2243	// server knows the browser is Firefox but can't tell which version it
2244	// is.
2245	MajorVersion string `json:"majorVersion,omitempty"`
2246
2247	// MinorVersion: Minor version number (number after first dot on left)
2248	// of this browser. For example, for Chrome 5.0.375.86 beta, this field
2249	// should be set to 0. An asterisk (*) may be used to target any version
2250	// number, and a question mark (?) may be used to target cases where the
2251	// version number cannot be identified. For example, Chrome *.* targets
2252	// any version of Chrome: 1.2, 2.5, 3.5, and so on. Chrome 3.* targets
2253	// Chrome 3.1, 3.5, but not 4.0. Firefox ?.? targets cases where the ad
2254	// server knows the browser is Firefox but can't tell which version it
2255	// is.
2256	MinorVersion string `json:"minorVersion,omitempty"`
2257
2258	// Name: Name of this browser.
2259	Name string `json:"name,omitempty"`
2260
2261	// ForceSendFields is a list of field names (e.g. "BrowserVersionId") to
2262	// unconditionally include in API requests. By default, fields with
2263	// empty or default values are omitted from API requests. However, any
2264	// non-pointer, non-interface field appearing in ForceSendFields will be
2265	// sent to the server regardless of whether the field is empty or not.
2266	// This may be used to include empty fields in Patch requests.
2267	ForceSendFields []string `json:"-"`
2268
2269	// NullFields is a list of field names (e.g. "BrowserVersionId") to
2270	// include in API requests with the JSON null value. By default, fields
2271	// with empty values are omitted from API requests. However, any field
2272	// with an empty value appearing in NullFields will be sent to the
2273	// server as null. It is an error if a field in this list has a
2274	// non-empty value. This may be used to include null fields in Patch
2275	// requests.
2276	NullFields []string `json:"-"`
2277}
2278
2279func (s *Browser) MarshalJSON() ([]byte, error) {
2280	type NoMethod Browser
2281	raw := NoMethod(*s)
2282	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2283}
2284
2285// BrowsersListResponse: Browser List Response
2286type BrowsersListResponse struct {
2287	// Browsers: Browser collection.
2288	Browsers []*Browser `json:"browsers,omitempty"`
2289
2290	// Kind: Identifies what kind of resource this is. Value: the fixed
2291	// string "dfareporting#browsersListResponse".
2292	Kind string `json:"kind,omitempty"`
2293
2294	// ServerResponse contains the HTTP response code and headers from the
2295	// server.
2296	googleapi.ServerResponse `json:"-"`
2297
2298	// ForceSendFields is a list of field names (e.g. "Browsers") to
2299	// unconditionally include in API requests. By default, fields with
2300	// empty or default values are omitted from API requests. However, any
2301	// non-pointer, non-interface field appearing in ForceSendFields will be
2302	// sent to the server regardless of whether the field is empty or not.
2303	// This may be used to include empty fields in Patch requests.
2304	ForceSendFields []string `json:"-"`
2305
2306	// NullFields is a list of field names (e.g. "Browsers") to include in
2307	// API requests with the JSON null value. By default, fields with empty
2308	// values are omitted from API requests. However, any field with an
2309	// empty value appearing in NullFields will be sent to the server as
2310	// null. It is an error if a field in this list has a non-empty value.
2311	// This may be used to include null fields in Patch requests.
2312	NullFields []string `json:"-"`
2313}
2314
2315func (s *BrowsersListResponse) MarshalJSON() ([]byte, error) {
2316	type NoMethod BrowsersListResponse
2317	raw := NoMethod(*s)
2318	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2319}
2320
2321// Campaign: Contains properties of a Campaign Manager campaign.
2322type Campaign struct {
2323	// AccountId: Account ID of this campaign. This is a read-only field
2324	// that can be left blank.
2325	AccountId int64 `json:"accountId,omitempty,string"`
2326
2327	// AdBlockingConfiguration: Ad blocking settings for this campaign.
2328	AdBlockingConfiguration *AdBlockingConfiguration `json:"adBlockingConfiguration,omitempty"`
2329
2330	// AdditionalCreativeOptimizationConfigurations: Additional creative
2331	// optimization configurations for the campaign.
2332	AdditionalCreativeOptimizationConfigurations []*CreativeOptimizationConfiguration `json:"additionalCreativeOptimizationConfigurations,omitempty"`
2333
2334	// AdvertiserGroupId: Advertiser group ID of the associated advertiser.
2335	AdvertiserGroupId int64 `json:"advertiserGroupId,omitempty,string"`
2336
2337	// AdvertiserId: Advertiser ID of this campaign. This is a required
2338	// field.
2339	AdvertiserId int64 `json:"advertiserId,omitempty,string"`
2340
2341	// AdvertiserIdDimensionValue: Dimension value for the advertiser ID of
2342	// this campaign. This is a read-only, auto-generated field.
2343	AdvertiserIdDimensionValue *DimensionValue `json:"advertiserIdDimensionValue,omitempty"`
2344
2345	// Archived: Whether this campaign has been archived.
2346	Archived bool `json:"archived,omitempty"`
2347
2348	// AudienceSegmentGroups: Audience segment groups assigned to this
2349	// campaign. Cannot have more than 300 segment groups.
2350	AudienceSegmentGroups []*AudienceSegmentGroup `json:"audienceSegmentGroups,omitempty"`
2351
2352	// BillingInvoiceCode: Billing invoice code included in the Campaign
2353	// Manager client billing invoices associated with the campaign.
2354	BillingInvoiceCode string `json:"billingInvoiceCode,omitempty"`
2355
2356	// ClickThroughUrlSuffixProperties: Click-through URL suffix override
2357	// properties for this campaign.
2358	ClickThroughUrlSuffixProperties *ClickThroughUrlSuffixProperties `json:"clickThroughUrlSuffixProperties,omitempty"`
2359
2360	// Comment: Arbitrary comments about this campaign. Must be less than
2361	// 256 characters long.
2362	Comment string `json:"comment,omitempty"`
2363
2364	// CreateInfo: Information about the creation of this campaign. This is
2365	// a read-only field.
2366	CreateInfo *LastModifiedInfo `json:"createInfo,omitempty"`
2367
2368	// CreativeGroupIds: List of creative group IDs that are assigned to the
2369	// campaign.
2370	CreativeGroupIds googleapi.Int64s `json:"creativeGroupIds,omitempty"`
2371
2372	// CreativeOptimizationConfiguration: Creative optimization
2373	// configuration for the campaign.
2374	CreativeOptimizationConfiguration *CreativeOptimizationConfiguration `json:"creativeOptimizationConfiguration,omitempty"`
2375
2376	// DefaultClickThroughEventTagProperties: Click-through event tag ID
2377	// override properties for this campaign.
2378	DefaultClickThroughEventTagProperties *DefaultClickThroughEventTagProperties `json:"defaultClickThroughEventTagProperties,omitempty"`
2379
2380	// DefaultLandingPageId: The default landing page ID for this campaign.
2381	DefaultLandingPageId int64 `json:"defaultLandingPageId,omitempty,string"`
2382
2383	EndDate string `json:"endDate,omitempty"`
2384
2385	// EventTagOverrides: Overrides that can be used to activate or
2386	// deactivate advertiser event tags.
2387	EventTagOverrides []*EventTagOverride `json:"eventTagOverrides,omitempty"`
2388
2389	// ExternalId: External ID for this campaign.
2390	ExternalId string `json:"externalId,omitempty"`
2391
2392	// Id: ID of this campaign. This is a read-only auto-generated field.
2393	Id int64 `json:"id,omitempty,string"`
2394
2395	// IdDimensionValue: Dimension value for the ID of this campaign. This
2396	// is a read-only, auto-generated field.
2397	IdDimensionValue *DimensionValue `json:"idDimensionValue,omitempty"`
2398
2399	// Kind: Identifies what kind of resource this is. Value: the fixed
2400	// string "dfareporting#campaign".
2401	Kind string `json:"kind,omitempty"`
2402
2403	// LastModifiedInfo: Information about the most recent modification of
2404	// this campaign. This is a read-only field.
2405	LastModifiedInfo *LastModifiedInfo `json:"lastModifiedInfo,omitempty"`
2406
2407	// Name: Name of this campaign. This is a required field and must be
2408	// less than 256 characters long and unique among campaigns of the same
2409	// advertiser.
2410	Name string `json:"name,omitempty"`
2411
2412	// NielsenOcrEnabled: Whether Nielsen reports are enabled for this
2413	// campaign.
2414	NielsenOcrEnabled bool `json:"nielsenOcrEnabled,omitempty"`
2415
2416	StartDate string `json:"startDate,omitempty"`
2417
2418	// SubaccountId: Subaccount ID of this campaign. This is a read-only
2419	// field that can be left blank.
2420	SubaccountId int64 `json:"subaccountId,omitempty,string"`
2421
2422	// TraffickerEmails: Campaign trafficker contact emails.
2423	TraffickerEmails []string `json:"traffickerEmails,omitempty"`
2424
2425	// ServerResponse contains the HTTP response code and headers from the
2426	// server.
2427	googleapi.ServerResponse `json:"-"`
2428
2429	// ForceSendFields is a list of field names (e.g. "AccountId") to
2430	// unconditionally include in API requests. By default, fields with
2431	// empty or default values are omitted from API requests. However, any
2432	// non-pointer, non-interface field appearing in ForceSendFields will be
2433	// sent to the server regardless of whether the field is empty or not.
2434	// This may be used to include empty fields in Patch requests.
2435	ForceSendFields []string `json:"-"`
2436
2437	// NullFields is a list of field names (e.g. "AccountId") to include in
2438	// API requests with the JSON null value. By default, fields with empty
2439	// values are omitted from API requests. However, any field with an
2440	// empty value appearing in NullFields will be sent to the server as
2441	// null. It is an error if a field in this list has a non-empty value.
2442	// This may be used to include null fields in Patch requests.
2443	NullFields []string `json:"-"`
2444}
2445
2446func (s *Campaign) MarshalJSON() ([]byte, error) {
2447	type NoMethod Campaign
2448	raw := NoMethod(*s)
2449	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2450}
2451
2452// CampaignCreativeAssociation: Identifies a creative which has been
2453// associated with a given campaign.
2454type CampaignCreativeAssociation struct {
2455	// CreativeId: ID of the creative associated with the campaign. This is
2456	// a required field.
2457	CreativeId int64 `json:"creativeId,omitempty,string"`
2458
2459	// Kind: Identifies what kind of resource this is. Value: the fixed
2460	// string "dfareporting#campaignCreativeAssociation".
2461	Kind string `json:"kind,omitempty"`
2462
2463	// ServerResponse contains the HTTP response code and headers from the
2464	// server.
2465	googleapi.ServerResponse `json:"-"`
2466
2467	// ForceSendFields is a list of field names (e.g. "CreativeId") to
2468	// unconditionally include in API requests. By default, fields with
2469	// empty or default values are omitted from API requests. However, any
2470	// non-pointer, non-interface field appearing in ForceSendFields will be
2471	// sent to the server regardless of whether the field is empty or not.
2472	// This may be used to include empty fields in Patch requests.
2473	ForceSendFields []string `json:"-"`
2474
2475	// NullFields is a list of field names (e.g. "CreativeId") to include in
2476	// API requests with the JSON null value. By default, fields with empty
2477	// values are omitted from API requests. However, any field with an
2478	// empty value appearing in NullFields will be sent to the server as
2479	// null. It is an error if a field in this list has a non-empty value.
2480	// This may be used to include null fields in Patch requests.
2481	NullFields []string `json:"-"`
2482}
2483
2484func (s *CampaignCreativeAssociation) MarshalJSON() ([]byte, error) {
2485	type NoMethod CampaignCreativeAssociation
2486	raw := NoMethod(*s)
2487	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2488}
2489
2490// CampaignCreativeAssociationsListResponse: Campaign Creative
2491// Association List Response
2492type CampaignCreativeAssociationsListResponse struct {
2493	// CampaignCreativeAssociations: Campaign creative association
2494	// collection
2495	CampaignCreativeAssociations []*CampaignCreativeAssociation `json:"campaignCreativeAssociations,omitempty"`
2496
2497	// Kind: Identifies what kind of resource this is. Value: the fixed
2498	// string "dfareporting#campaignCreativeAssociationsListResponse".
2499	Kind string `json:"kind,omitempty"`
2500
2501	// NextPageToken: Pagination token to be used for the next list
2502	// operation.
2503	NextPageToken string `json:"nextPageToken,omitempty"`
2504
2505	// ServerResponse contains the HTTP response code and headers from the
2506	// server.
2507	googleapi.ServerResponse `json:"-"`
2508
2509	// ForceSendFields is a list of field names (e.g.
2510	// "CampaignCreativeAssociations") to unconditionally include in API
2511	// requests. By default, fields with empty or default values are omitted
2512	// from API requests. However, any non-pointer, non-interface field
2513	// appearing in ForceSendFields will be sent to the server regardless of
2514	// whether the field is empty or not. This may be used to include empty
2515	// fields in Patch requests.
2516	ForceSendFields []string `json:"-"`
2517
2518	// NullFields is a list of field names (e.g.
2519	// "CampaignCreativeAssociations") to include in API requests with the
2520	// JSON null value. By default, fields with empty values are omitted
2521	// from API requests. However, any field with an empty value appearing
2522	// in NullFields will be sent to the server as null. It is an error if a
2523	// field in this list has a non-empty value. This may be used to include
2524	// null fields in Patch requests.
2525	NullFields []string `json:"-"`
2526}
2527
2528func (s *CampaignCreativeAssociationsListResponse) MarshalJSON() ([]byte, error) {
2529	type NoMethod CampaignCreativeAssociationsListResponse
2530	raw := NoMethod(*s)
2531	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2532}
2533
2534// CampaignManagerIds: Campaign Manager IDs related to the custom event.
2535type CampaignManagerIds struct {
2536	// AdId: Ad ID for Campaign Manager.
2537	AdId int64 `json:"adId,omitempty,string"`
2538
2539	// CampaignId: Campaign ID for Campaign Manager.
2540	CampaignId int64 `json:"campaignId,omitempty,string"`
2541
2542	// CreativeId: Creative ID for Campaign Manager.
2543	CreativeId int64 `json:"creativeId,omitempty,string"`
2544
2545	// Kind: Identifies what kind of resource this is. Value: the fixed
2546	// string "dfareporting#campaignManagerIds".
2547	Kind string `json:"kind,omitempty"`
2548
2549	// PlacementId: Placement ID for Campaign Manager.
2550	PlacementId int64 `json:"placementId,omitempty,string"`
2551
2552	// SiteId: Site ID for Campaign Manager.
2553	SiteId int64 `json:"siteId,omitempty,string"`
2554
2555	// ForceSendFields is a list of field names (e.g. "AdId") to
2556	// unconditionally include in API requests. By default, fields with
2557	// empty or default values are omitted from API requests. However, any
2558	// non-pointer, non-interface field appearing in ForceSendFields will be
2559	// sent to the server regardless of whether the field is empty or not.
2560	// This may be used to include empty fields in Patch requests.
2561	ForceSendFields []string `json:"-"`
2562
2563	// NullFields is a list of field names (e.g. "AdId") to include in API
2564	// requests with the JSON null value. By default, fields with empty
2565	// values are omitted from API requests. However, any field with an
2566	// empty value appearing in NullFields will be sent to the server as
2567	// null. It is an error if a field in this list has a non-empty value.
2568	// This may be used to include null fields in Patch requests.
2569	NullFields []string `json:"-"`
2570}
2571
2572func (s *CampaignManagerIds) MarshalJSON() ([]byte, error) {
2573	type NoMethod CampaignManagerIds
2574	raw := NoMethod(*s)
2575	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2576}
2577
2578// CampaignsListResponse: Campaign List Response
2579type CampaignsListResponse struct {
2580	// Campaigns: Campaign collection.
2581	Campaigns []*Campaign `json:"campaigns,omitempty"`
2582
2583	// Kind: Identifies what kind of resource this is. Value: the fixed
2584	// string "dfareporting#campaignsListResponse".
2585	Kind string `json:"kind,omitempty"`
2586
2587	// NextPageToken: Pagination token to be used for the next list
2588	// operation.
2589	NextPageToken string `json:"nextPageToken,omitempty"`
2590
2591	// ServerResponse contains the HTTP response code and headers from the
2592	// server.
2593	googleapi.ServerResponse `json:"-"`
2594
2595	// ForceSendFields is a list of field names (e.g. "Campaigns") to
2596	// unconditionally include in API requests. By default, fields with
2597	// empty or default values are omitted from API requests. However, any
2598	// non-pointer, non-interface field appearing in ForceSendFields will be
2599	// sent to the server regardless of whether the field is empty or not.
2600	// This may be used to include empty fields in Patch requests.
2601	ForceSendFields []string `json:"-"`
2602
2603	// NullFields is a list of field names (e.g. "Campaigns") to include in
2604	// API requests with the JSON null value. By default, fields with empty
2605	// values are omitted from API requests. However, any field with an
2606	// empty value appearing in NullFields will be sent to the server as
2607	// null. It is an error if a field in this list has a non-empty value.
2608	// This may be used to include null fields in Patch requests.
2609	NullFields []string `json:"-"`
2610}
2611
2612func (s *CampaignsListResponse) MarshalJSON() ([]byte, error) {
2613	type NoMethod CampaignsListResponse
2614	raw := NoMethod(*s)
2615	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2616}
2617
2618// ChangeLog: Describes a change that a user has made to a resource.
2619type ChangeLog struct {
2620	// AccountId: Account ID of the modified object.
2621	AccountId int64 `json:"accountId,omitempty,string"`
2622
2623	// Action: Action which caused the change.
2624	Action string `json:"action,omitempty"`
2625
2626	ChangeTime string `json:"changeTime,omitempty"`
2627
2628	// FieldName: Field name of the object which changed.
2629	FieldName string `json:"fieldName,omitempty"`
2630
2631	// Id: ID of this change log.
2632	Id int64 `json:"id,omitempty,string"`
2633
2634	// Kind: Identifies what kind of resource this is. Value: the fixed
2635	// string "dfareporting#changeLog".
2636	Kind string `json:"kind,omitempty"`
2637
2638	// NewValue: New value of the object field.
2639	NewValue string `json:"newValue,omitempty"`
2640
2641	// ObjectId: ID of the object of this change log. The object could be a
2642	// campaign, placement, ad, or other type.
2643	ObjectId int64 `json:"objectId,omitempty,string"`
2644
2645	// ObjectType: Object type of the change log.
2646	ObjectType string `json:"objectType,omitempty"`
2647
2648	// OldValue: Old value of the object field.
2649	OldValue string `json:"oldValue,omitempty"`
2650
2651	// SubaccountId: Subaccount ID of the modified object.
2652	SubaccountId int64 `json:"subaccountId,omitempty,string"`
2653
2654	// TransactionId: Transaction ID of this change log. When a single API
2655	// call results in many changes, each change will have a separate ID in
2656	// the change log but will share the same transactionId.
2657	TransactionId int64 `json:"transactionId,omitempty,string"`
2658
2659	// UserProfileId: ID of the user who modified the object.
2660	UserProfileId int64 `json:"userProfileId,omitempty,string"`
2661
2662	// UserProfileName: User profile name of the user who modified the
2663	// object.
2664	UserProfileName string `json:"userProfileName,omitempty"`
2665
2666	// ServerResponse contains the HTTP response code and headers from the
2667	// server.
2668	googleapi.ServerResponse `json:"-"`
2669
2670	// ForceSendFields is a list of field names (e.g. "AccountId") to
2671	// unconditionally include in API requests. By default, fields with
2672	// empty or default values are omitted from API requests. However, any
2673	// non-pointer, non-interface field appearing in ForceSendFields will be
2674	// sent to the server regardless of whether the field is empty or not.
2675	// This may be used to include empty fields in Patch requests.
2676	ForceSendFields []string `json:"-"`
2677
2678	// NullFields is a list of field names (e.g. "AccountId") to include in
2679	// API requests with the JSON null value. By default, fields with empty
2680	// values are omitted from API requests. However, any field with an
2681	// empty value appearing in NullFields will be sent to the server as
2682	// null. It is an error if a field in this list has a non-empty value.
2683	// This may be used to include null fields in Patch requests.
2684	NullFields []string `json:"-"`
2685}
2686
2687func (s *ChangeLog) MarshalJSON() ([]byte, error) {
2688	type NoMethod ChangeLog
2689	raw := NoMethod(*s)
2690	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2691}
2692
2693// ChangeLogsListResponse: Change Log List Response
2694type ChangeLogsListResponse struct {
2695	// ChangeLogs: Change log collection.
2696	ChangeLogs []*ChangeLog `json:"changeLogs,omitempty"`
2697
2698	// Kind: Identifies what kind of resource this is. Value: the fixed
2699	// string "dfareporting#changeLogsListResponse".
2700	Kind string `json:"kind,omitempty"`
2701
2702	// NextPageToken: Pagination token to be used for the next list
2703	// operation.
2704	NextPageToken string `json:"nextPageToken,omitempty"`
2705
2706	// ServerResponse contains the HTTP response code and headers from the
2707	// server.
2708	googleapi.ServerResponse `json:"-"`
2709
2710	// ForceSendFields is a list of field names (e.g. "ChangeLogs") to
2711	// unconditionally include in API requests. By default, fields with
2712	// empty or default values are omitted from API requests. However, any
2713	// non-pointer, non-interface field appearing in ForceSendFields will be
2714	// sent to the server regardless of whether the field is empty or not.
2715	// This may be used to include empty fields in Patch requests.
2716	ForceSendFields []string `json:"-"`
2717
2718	// NullFields is a list of field names (e.g. "ChangeLogs") to include in
2719	// API requests with the JSON null value. By default, fields with empty
2720	// values are omitted from API requests. However, any field with an
2721	// empty value appearing in NullFields will be sent to the server as
2722	// null. It is an error if a field in this list has a non-empty value.
2723	// This may be used to include null fields in Patch requests.
2724	NullFields []string `json:"-"`
2725}
2726
2727func (s *ChangeLogsListResponse) MarshalJSON() ([]byte, error) {
2728	type NoMethod ChangeLogsListResponse
2729	raw := NoMethod(*s)
2730	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2731}
2732
2733// ChannelGrouping: Represents a DfaReporting channel grouping.
2734type ChannelGrouping struct {
2735	// FallbackName: ChannelGrouping fallback name.
2736	FallbackName string `json:"fallbackName,omitempty"`
2737
2738	// Kind: The kind of resource this is, in this case
2739	// dfareporting#channelGrouping.
2740	Kind string `json:"kind,omitempty"`
2741
2742	// Name: ChannelGrouping name.
2743	Name string `json:"name,omitempty"`
2744
2745	// Rules: The rules contained within this channel grouping.
2746	Rules []*ChannelGroupingRule `json:"rules,omitempty"`
2747
2748	// ForceSendFields is a list of field names (e.g. "FallbackName") to
2749	// unconditionally include in API requests. By default, fields with
2750	// empty or default values are omitted from API requests. However, any
2751	// non-pointer, non-interface field appearing in ForceSendFields will be
2752	// sent to the server regardless of whether the field is empty or not.
2753	// This may be used to include empty fields in Patch requests.
2754	ForceSendFields []string `json:"-"`
2755
2756	// NullFields is a list of field names (e.g. "FallbackName") to include
2757	// in API requests with the JSON null value. By default, fields with
2758	// empty values are omitted from API requests. However, any field with
2759	// an empty value appearing in NullFields will be sent to the server as
2760	// null. It is an error if a field in this list has a non-empty value.
2761	// This may be used to include null fields in Patch requests.
2762	NullFields []string `json:"-"`
2763}
2764
2765func (s *ChannelGrouping) MarshalJSON() ([]byte, error) {
2766	type NoMethod ChannelGrouping
2767	raw := NoMethod(*s)
2768	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2769}
2770
2771// ChannelGroupingRule: Represents a DfaReporting channel grouping rule.
2772type ChannelGroupingRule struct {
2773	// DisjunctiveMatchStatements: The disjunctive match statements
2774	// contained within this rule.
2775	DisjunctiveMatchStatements []*DisjunctiveMatchStatement `json:"disjunctiveMatchStatements,omitempty"`
2776
2777	// Kind: The kind of resource this is, in this case
2778	// dfareporting#channelGroupingRule.
2779	Kind string `json:"kind,omitempty"`
2780
2781	// Name: Rule name.
2782	Name string `json:"name,omitempty"`
2783
2784	// ForceSendFields is a list of field names (e.g.
2785	// "DisjunctiveMatchStatements") to unconditionally include in API
2786	// requests. By default, fields with empty or default values are omitted
2787	// from API requests. However, any non-pointer, non-interface field
2788	// appearing in ForceSendFields will be sent to the server regardless of
2789	// whether the field is empty or not. This may be used to include empty
2790	// fields in Patch requests.
2791	ForceSendFields []string `json:"-"`
2792
2793	// NullFields is a list of field names (e.g.
2794	// "DisjunctiveMatchStatements") to include in API requests with the
2795	// JSON null value. By default, fields with empty values are omitted
2796	// from API requests. However, any field with an empty value appearing
2797	// in NullFields will be sent to the server as null. It is an error if a
2798	// field in this list has a non-empty value. This may be used to include
2799	// null fields in Patch requests.
2800	NullFields []string `json:"-"`
2801}
2802
2803func (s *ChannelGroupingRule) MarshalJSON() ([]byte, error) {
2804	type NoMethod ChannelGroupingRule
2805	raw := NoMethod(*s)
2806	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2807}
2808
2809// CitiesListResponse: City List Response
2810type CitiesListResponse struct {
2811	// Cities: City collection.
2812	Cities []*City `json:"cities,omitempty"`
2813
2814	// Kind: Identifies what kind of resource this is. Value: the fixed
2815	// string "dfareporting#citiesListResponse".
2816	Kind string `json:"kind,omitempty"`
2817
2818	// ServerResponse contains the HTTP response code and headers from the
2819	// server.
2820	googleapi.ServerResponse `json:"-"`
2821
2822	// ForceSendFields is a list of field names (e.g. "Cities") to
2823	// unconditionally include in API requests. By default, fields with
2824	// empty or default values are omitted from API requests. However, any
2825	// non-pointer, non-interface field appearing in ForceSendFields will be
2826	// sent to the server regardless of whether the field is empty or not.
2827	// This may be used to include empty fields in Patch requests.
2828	ForceSendFields []string `json:"-"`
2829
2830	// NullFields is a list of field names (e.g. "Cities") to include in API
2831	// requests with the JSON null value. By default, fields with empty
2832	// values are omitted from API requests. However, any field with an
2833	// empty value appearing in NullFields will be sent to the server as
2834	// null. It is an error if a field in this list has a non-empty value.
2835	// This may be used to include null fields in Patch requests.
2836	NullFields []string `json:"-"`
2837}
2838
2839func (s *CitiesListResponse) MarshalJSON() ([]byte, error) {
2840	type NoMethod CitiesListResponse
2841	raw := NoMethod(*s)
2842	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2843}
2844
2845// City: Contains information about a city that can be targeted by ads.
2846type City struct {
2847	// CountryCode: Country code of the country to which this city belongs.
2848	CountryCode string `json:"countryCode,omitempty"`
2849
2850	// CountryDartId: DART ID of the country to which this city belongs.
2851	CountryDartId int64 `json:"countryDartId,omitempty,string"`
2852
2853	// DartId: DART ID of this city. This is the ID used for targeting and
2854	// generating reports.
2855	DartId int64 `json:"dartId,omitempty,string"`
2856
2857	// Kind: Identifies what kind of resource this is. Value: the fixed
2858	// string "dfareporting#city".
2859	Kind string `json:"kind,omitempty"`
2860
2861	// MetroCode: Metro region code of the metro region (DMA) to which this
2862	// city belongs.
2863	MetroCode string `json:"metroCode,omitempty"`
2864
2865	// MetroDmaId: ID of the metro region (DMA) to which this city belongs.
2866	MetroDmaId int64 `json:"metroDmaId,omitempty,string"`
2867
2868	// Name: Name of this city.
2869	Name string `json:"name,omitempty"`
2870
2871	// RegionCode: Region code of the region to which this city belongs.
2872	RegionCode string `json:"regionCode,omitempty"`
2873
2874	// RegionDartId: DART ID of the region to which this city belongs.
2875	RegionDartId int64 `json:"regionDartId,omitempty,string"`
2876
2877	// ForceSendFields is a list of field names (e.g. "CountryCode") to
2878	// unconditionally include in API requests. By default, fields with
2879	// empty or default values are omitted from API requests. However, any
2880	// non-pointer, non-interface field appearing in ForceSendFields will be
2881	// sent to the server regardless of whether the field is empty or not.
2882	// This may be used to include empty fields in Patch requests.
2883	ForceSendFields []string `json:"-"`
2884
2885	// NullFields is a list of field names (e.g. "CountryCode") to include
2886	// in API requests with the JSON null value. By default, fields with
2887	// empty values are omitted from API requests. However, any field with
2888	// an empty value appearing in NullFields will be sent to the server as
2889	// null. It is an error if a field in this list has a non-empty value.
2890	// This may be used to include null fields in Patch requests.
2891	NullFields []string `json:"-"`
2892}
2893
2894func (s *City) MarshalJSON() ([]byte, error) {
2895	type NoMethod City
2896	raw := NoMethod(*s)
2897	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2898}
2899
2900// ClickTag: Creative Click Tag.
2901type ClickTag struct {
2902	// ClickThroughUrl: Parameter value for the specified click tag. This
2903	// field contains a click-through url.
2904	ClickThroughUrl *CreativeClickThroughUrl `json:"clickThroughUrl,omitempty"`
2905
2906	// EventName: Advertiser event name associated with the click tag. This
2907	// field is used by DISPLAY_IMAGE_GALLERY and HTML5_BANNER creatives.
2908	// Applicable to DISPLAY when the primary asset type is not HTML_IMAGE.
2909	EventName string `json:"eventName,omitempty"`
2910
2911	// Name: Parameter name for the specified click tag. For
2912	// DISPLAY_IMAGE_GALLERY creative assets, this field must match the
2913	// value of the creative asset's creativeAssetId.name field.
2914	Name string `json:"name,omitempty"`
2915
2916	// ForceSendFields is a list of field names (e.g. "ClickThroughUrl") to
2917	// unconditionally include in API requests. By default, fields with
2918	// empty or default values are omitted from API requests. However, any
2919	// non-pointer, non-interface field appearing in ForceSendFields will be
2920	// sent to the server regardless of whether the field is empty or not.
2921	// This may be used to include empty fields in Patch requests.
2922	ForceSendFields []string `json:"-"`
2923
2924	// NullFields is a list of field names (e.g. "ClickThroughUrl") to
2925	// include in API requests with the JSON null value. By default, fields
2926	// with empty values are omitted from API requests. However, any field
2927	// with an empty value appearing in NullFields will be sent to the
2928	// server as null. It is an error if a field in this list has a
2929	// non-empty value. This may be used to include null fields in Patch
2930	// requests.
2931	NullFields []string `json:"-"`
2932}
2933
2934func (s *ClickTag) MarshalJSON() ([]byte, error) {
2935	type NoMethod ClickTag
2936	raw := NoMethod(*s)
2937	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2938}
2939
2940// ClickThroughUrl: Click-through URL
2941type ClickThroughUrl struct {
2942	// ComputedClickThroughUrl: Read-only convenience field representing the
2943	// actual URL that will be used for this click-through. The URL is
2944	// computed as follows: - If defaultLandingPage is enabled then the
2945	// campaign's default landing page URL is assigned to this field. - If
2946	// defaultLandingPage is not enabled and a landingPageId is specified
2947	// then that landing page's URL is assigned to this field. - If neither
2948	// of the above cases apply, then the customClickThroughUrl is assigned
2949	// to this field.
2950	ComputedClickThroughUrl string `json:"computedClickThroughUrl,omitempty"`
2951
2952	// CustomClickThroughUrl: Custom click-through URL. Applicable if the
2953	// defaultLandingPage field is set to false and the landingPageId field
2954	// is left unset.
2955	CustomClickThroughUrl string `json:"customClickThroughUrl,omitempty"`
2956
2957	// DefaultLandingPage: Whether the campaign default landing page is
2958	// used.
2959	DefaultLandingPage bool `json:"defaultLandingPage,omitempty"`
2960
2961	// LandingPageId: ID of the landing page for the click-through URL.
2962	// Applicable if the defaultLandingPage field is set to false.
2963	LandingPageId int64 `json:"landingPageId,omitempty,string"`
2964
2965	// ForceSendFields is a list of field names (e.g.
2966	// "ComputedClickThroughUrl") to unconditionally include in API
2967	// requests. By default, fields with empty or default values are omitted
2968	// from API requests. However, any non-pointer, non-interface field
2969	// appearing in ForceSendFields will be sent to the server regardless of
2970	// whether the field is empty or not. This may be used to include empty
2971	// fields in Patch requests.
2972	ForceSendFields []string `json:"-"`
2973
2974	// NullFields is a list of field names (e.g. "ComputedClickThroughUrl")
2975	// to include in API requests with the JSON null value. By default,
2976	// fields with empty values are omitted from API requests. However, any
2977	// field with an empty value appearing in NullFields will be sent to the
2978	// server as null. It is an error if a field in this list has a
2979	// non-empty value. This may be used to include null fields in Patch
2980	// requests.
2981	NullFields []string `json:"-"`
2982}
2983
2984func (s *ClickThroughUrl) MarshalJSON() ([]byte, error) {
2985	type NoMethod ClickThroughUrl
2986	raw := NoMethod(*s)
2987	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2988}
2989
2990// ClickThroughUrlSuffixProperties: Click Through URL Suffix settings.
2991type ClickThroughUrlSuffixProperties struct {
2992	// ClickThroughUrlSuffix: Click-through URL suffix to apply to all ads
2993	// in this entity's scope. Must be less than 128 characters long.
2994	ClickThroughUrlSuffix string `json:"clickThroughUrlSuffix,omitempty"`
2995
2996	// OverrideInheritedSuffix: Whether this entity should override the
2997	// inherited click-through URL suffix with its own defined value.
2998	OverrideInheritedSuffix bool `json:"overrideInheritedSuffix,omitempty"`
2999
3000	// ForceSendFields is a list of field names (e.g.
3001	// "ClickThroughUrlSuffix") to unconditionally include in API requests.
3002	// By default, fields with empty or default values are omitted from API
3003	// requests. However, any non-pointer, non-interface field appearing in
3004	// ForceSendFields will be sent to the server regardless of whether the
3005	// field is empty or not. This may be used to include empty fields in
3006	// Patch requests.
3007	ForceSendFields []string `json:"-"`
3008
3009	// NullFields is a list of field names (e.g. "ClickThroughUrlSuffix") to
3010	// include in API requests with the JSON null value. By default, fields
3011	// with empty values are omitted from API requests. However, any field
3012	// with an empty value appearing in NullFields will be sent to the
3013	// server as null. It is an error if a field in this list has a
3014	// non-empty value. This may be used to include null fields in Patch
3015	// requests.
3016	NullFields []string `json:"-"`
3017}
3018
3019func (s *ClickThroughUrlSuffixProperties) MarshalJSON() ([]byte, error) {
3020	type NoMethod ClickThroughUrlSuffixProperties
3021	raw := NoMethod(*s)
3022	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3023}
3024
3025// CompanionClickThroughOverride: Companion Click-through override.
3026type CompanionClickThroughOverride struct {
3027	// ClickThroughUrl: Click-through URL of this companion click-through
3028	// override.
3029	ClickThroughUrl *ClickThroughUrl `json:"clickThroughUrl,omitempty"`
3030
3031	// CreativeId: ID of the creative for this companion click-through
3032	// override.
3033	CreativeId int64 `json:"creativeId,omitempty,string"`
3034
3035	// ForceSendFields is a list of field names (e.g. "ClickThroughUrl") to
3036	// unconditionally include in API requests. By default, fields with
3037	// empty or default values are omitted from API requests. However, any
3038	// non-pointer, non-interface field appearing in ForceSendFields will be
3039	// sent to the server regardless of whether the field is empty or not.
3040	// This may be used to include empty fields in Patch requests.
3041	ForceSendFields []string `json:"-"`
3042
3043	// NullFields is a list of field names (e.g. "ClickThroughUrl") to
3044	// include in API requests with the JSON null value. By default, fields
3045	// with empty values are omitted from API requests. However, any field
3046	// with an empty value appearing in NullFields will be sent to the
3047	// server as null. It is an error if a field in this list has a
3048	// non-empty value. This may be used to include null fields in Patch
3049	// requests.
3050	NullFields []string `json:"-"`
3051}
3052
3053func (s *CompanionClickThroughOverride) MarshalJSON() ([]byte, error) {
3054	type NoMethod CompanionClickThroughOverride
3055	raw := NoMethod(*s)
3056	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3057}
3058
3059// CompanionSetting: Companion Settings
3060type CompanionSetting struct {
3061	// CompanionsDisabled: Whether companions are disabled for this
3062	// placement.
3063	CompanionsDisabled bool `json:"companionsDisabled,omitempty"`
3064
3065	// EnabledSizes: Allowlist of companion sizes to be served to this
3066	// placement. Set this list to null or empty to serve all companion
3067	// sizes.
3068	EnabledSizes []*Size `json:"enabledSizes,omitempty"`
3069
3070	// ImageOnly: Whether to serve only static images as companions.
3071	ImageOnly bool `json:"imageOnly,omitempty"`
3072
3073	// Kind: Identifies what kind of resource this is. Value: the fixed
3074	// string "dfareporting#companionSetting".
3075	Kind string `json:"kind,omitempty"`
3076
3077	// ForceSendFields is a list of field names (e.g. "CompanionsDisabled")
3078	// to unconditionally include in API requests. By default, fields with
3079	// empty or default values are omitted from API requests. However, any
3080	// non-pointer, non-interface field appearing in ForceSendFields will be
3081	// sent to the server regardless of whether the field is empty or not.
3082	// This may be used to include empty fields in Patch requests.
3083	ForceSendFields []string `json:"-"`
3084
3085	// NullFields is a list of field names (e.g. "CompanionsDisabled") to
3086	// include in API requests with the JSON null value. By default, fields
3087	// with empty values are omitted from API requests. However, any field
3088	// with an empty value appearing in NullFields will be sent to the
3089	// server as null. It is an error if a field in this list has a
3090	// non-empty value. This may be used to include null fields in Patch
3091	// requests.
3092	NullFields []string `json:"-"`
3093}
3094
3095func (s *CompanionSetting) MarshalJSON() ([]byte, error) {
3096	type NoMethod CompanionSetting
3097	raw := NoMethod(*s)
3098	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3099}
3100
3101// CompatibleFields: Represents a response to the queryCompatibleFields
3102// method.
3103type CompatibleFields struct {
3104	// CrossDimensionReachReportCompatibleFields: Contains items that are
3105	// compatible to be selected for a report of type
3106	// "CROSS_DIMENSION_REACH".
3107	CrossDimensionReachReportCompatibleFields *CrossDimensionReachReportCompatibleFields `json:"crossDimensionReachReportCompatibleFields,omitempty"`
3108
3109	// FloodlightReportCompatibleFields: Contains items that are compatible
3110	// to be selected for a report of type "FLOODLIGHT".
3111	FloodlightReportCompatibleFields *FloodlightReportCompatibleFields `json:"floodlightReportCompatibleFields,omitempty"`
3112
3113	// Kind: The kind of resource this is, in this case
3114	// dfareporting#compatibleFields.
3115	Kind string `json:"kind,omitempty"`
3116
3117	// PathAttributionReportCompatibleFields: Contains items that are
3118	// compatible to be selected for a report of type "PATH_ATTRIBUTION".
3119	PathAttributionReportCompatibleFields *PathReportCompatibleFields `json:"pathAttributionReportCompatibleFields,omitempty"`
3120
3121	// PathReportCompatibleFields: Contains items that are compatible to be
3122	// selected for a report of type "PATH".
3123	PathReportCompatibleFields *PathReportCompatibleFields `json:"pathReportCompatibleFields,omitempty"`
3124
3125	// PathToConversionReportCompatibleFields: Contains items that are
3126	// compatible to be selected for a report of type "PATH_TO_CONVERSION".
3127	PathToConversionReportCompatibleFields *PathToConversionReportCompatibleFields `json:"pathToConversionReportCompatibleFields,omitempty"`
3128
3129	// ReachReportCompatibleFields: Contains items that are compatible to be
3130	// selected for a report of type "REACH".
3131	ReachReportCompatibleFields *ReachReportCompatibleFields `json:"reachReportCompatibleFields,omitempty"`
3132
3133	// ReportCompatibleFields: Contains items that are compatible to be
3134	// selected for a report of type "STANDARD".
3135	ReportCompatibleFields *ReportCompatibleFields `json:"reportCompatibleFields,omitempty"`
3136
3137	// ServerResponse contains the HTTP response code and headers from the
3138	// server.
3139	googleapi.ServerResponse `json:"-"`
3140
3141	// ForceSendFields is a list of field names (e.g.
3142	// "CrossDimensionReachReportCompatibleFields") to unconditionally
3143	// include in API requests. By default, fields with empty or default
3144	// values are omitted from API requests. However, any non-pointer,
3145	// non-interface field appearing in ForceSendFields will be sent to the
3146	// server regardless of whether the field is empty or not. This may be
3147	// used to include empty fields in Patch requests.
3148	ForceSendFields []string `json:"-"`
3149
3150	// NullFields is a list of field names (e.g.
3151	// "CrossDimensionReachReportCompatibleFields") to include in API
3152	// requests with the JSON null value. By default, fields with empty
3153	// values are omitted from API requests. However, any field with an
3154	// empty value appearing in NullFields will be sent to the server as
3155	// null. It is an error if a field in this list has a non-empty value.
3156	// This may be used to include null fields in Patch requests.
3157	NullFields []string `json:"-"`
3158}
3159
3160func (s *CompatibleFields) MarshalJSON() ([]byte, error) {
3161	type NoMethod CompatibleFields
3162	raw := NoMethod(*s)
3163	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3164}
3165
3166// ConnectionType: Contains information about an internet connection
3167// type that can be targeted by ads. Clients can use the connection type
3168// to target mobile vs. broadband users.
3169type ConnectionType struct {
3170	// Id: ID of this connection type.
3171	Id int64 `json:"id,omitempty,string"`
3172
3173	// Kind: Identifies what kind of resource this is. Value: the fixed
3174	// string "dfareporting#connectionType".
3175	Kind string `json:"kind,omitempty"`
3176
3177	// Name: Name of this connection type.
3178	Name string `json:"name,omitempty"`
3179
3180	// ServerResponse contains the HTTP response code and headers from the
3181	// server.
3182	googleapi.ServerResponse `json:"-"`
3183
3184	// ForceSendFields is a list of field names (e.g. "Id") to
3185	// unconditionally include in API requests. By default, fields with
3186	// empty or default values are omitted from API requests. However, any
3187	// non-pointer, non-interface field appearing in ForceSendFields will be
3188	// sent to the server regardless of whether the field is empty or not.
3189	// This may be used to include empty fields in Patch requests.
3190	ForceSendFields []string `json:"-"`
3191
3192	// NullFields is a list of field names (e.g. "Id") to include in API
3193	// requests with the JSON null value. By default, fields with empty
3194	// values are omitted from API requests. However, any field with an
3195	// empty value appearing in NullFields will be sent to the server as
3196	// null. It is an error if a field in this list has a non-empty value.
3197	// This may be used to include null fields in Patch requests.
3198	NullFields []string `json:"-"`
3199}
3200
3201func (s *ConnectionType) MarshalJSON() ([]byte, error) {
3202	type NoMethod ConnectionType
3203	raw := NoMethod(*s)
3204	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3205}
3206
3207// ConnectionTypesListResponse: Connection Type List Response
3208type ConnectionTypesListResponse struct {
3209	// ConnectionTypes: Collection of connection types such as broadband and
3210	// mobile.
3211	ConnectionTypes []*ConnectionType `json:"connectionTypes,omitempty"`
3212
3213	// Kind: Identifies what kind of resource this is. Value: the fixed
3214	// string "dfareporting#connectionTypesListResponse".
3215	Kind string `json:"kind,omitempty"`
3216
3217	// ServerResponse contains the HTTP response code and headers from the
3218	// server.
3219	googleapi.ServerResponse `json:"-"`
3220
3221	// ForceSendFields is a list of field names (e.g. "ConnectionTypes") to
3222	// unconditionally include in API requests. By default, fields with
3223	// empty or default values are omitted from API requests. However, any
3224	// non-pointer, non-interface field appearing in ForceSendFields will be
3225	// sent to the server regardless of whether the field is empty or not.
3226	// This may be used to include empty fields in Patch requests.
3227	ForceSendFields []string `json:"-"`
3228
3229	// NullFields is a list of field names (e.g. "ConnectionTypes") to
3230	// include in API requests with the JSON null value. By default, fields
3231	// with empty values are omitted from API requests. However, any field
3232	// with an empty value appearing in NullFields will be sent to the
3233	// server as null. It is an error if a field in this list has a
3234	// non-empty value. This may be used to include null fields in Patch
3235	// requests.
3236	NullFields []string `json:"-"`
3237}
3238
3239func (s *ConnectionTypesListResponse) MarshalJSON() ([]byte, error) {
3240	type NoMethod ConnectionTypesListResponse
3241	raw := NoMethod(*s)
3242	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3243}
3244
3245// ContentCategoriesListResponse: Content Category List Response
3246type ContentCategoriesListResponse struct {
3247	// ContentCategories: Content category collection.
3248	ContentCategories []*ContentCategory `json:"contentCategories,omitempty"`
3249
3250	// Kind: Identifies what kind of resource this is. Value: the fixed
3251	// string "dfareporting#contentCategoriesListResponse".
3252	Kind string `json:"kind,omitempty"`
3253
3254	// NextPageToken: Pagination token to be used for the next list
3255	// operation.
3256	NextPageToken string `json:"nextPageToken,omitempty"`
3257
3258	// ServerResponse contains the HTTP response code and headers from the
3259	// server.
3260	googleapi.ServerResponse `json:"-"`
3261
3262	// ForceSendFields is a list of field names (e.g. "ContentCategories")
3263	// to unconditionally include in API requests. By default, fields with
3264	// empty or default values are omitted from API requests. However, any
3265	// non-pointer, non-interface field appearing in ForceSendFields will be
3266	// sent to the server regardless of whether the field is empty or not.
3267	// This may be used to include empty fields in Patch requests.
3268	ForceSendFields []string `json:"-"`
3269
3270	// NullFields is a list of field names (e.g. "ContentCategories") to
3271	// include in API requests with the JSON null value. By default, fields
3272	// with empty values are omitted from API requests. However, any field
3273	// with an empty value appearing in NullFields will be sent to the
3274	// server as null. It is an error if a field in this list has a
3275	// non-empty value. This may be used to include null fields in Patch
3276	// requests.
3277	NullFields []string `json:"-"`
3278}
3279
3280func (s *ContentCategoriesListResponse) MarshalJSON() ([]byte, error) {
3281	type NoMethod ContentCategoriesListResponse
3282	raw := NoMethod(*s)
3283	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3284}
3285
3286// ContentCategory: Organizes placements according to the contents of
3287// their associated webpages.
3288type ContentCategory struct {
3289	// AccountId: Account ID of this content category. This is a read-only
3290	// field that can be left blank.
3291	AccountId int64 `json:"accountId,omitempty,string"`
3292
3293	// Id: ID of this content category. This is a read-only, auto-generated
3294	// field.
3295	Id int64 `json:"id,omitempty,string"`
3296
3297	// Kind: Identifies what kind of resource this is. Value: the fixed
3298	// string "dfareporting#contentCategory".
3299	Kind string `json:"kind,omitempty"`
3300
3301	// Name: Name of this content category. This is a required field and
3302	// must be less than 256 characters long and unique among content
3303	// categories of the same account.
3304	Name string `json:"name,omitempty"`
3305
3306	// ServerResponse contains the HTTP response code and headers from the
3307	// server.
3308	googleapi.ServerResponse `json:"-"`
3309
3310	// ForceSendFields is a list of field names (e.g. "AccountId") to
3311	// unconditionally include in API requests. By default, fields with
3312	// empty or default values are omitted from API requests. However, any
3313	// non-pointer, non-interface field appearing in ForceSendFields will be
3314	// sent to the server regardless of whether the field is empty or not.
3315	// This may be used to include empty fields in Patch requests.
3316	ForceSendFields []string `json:"-"`
3317
3318	// NullFields is a list of field names (e.g. "AccountId") to include in
3319	// API requests with the JSON null value. By default, fields with empty
3320	// values are omitted from API requests. However, any field with an
3321	// empty value appearing in NullFields will be sent to the server as
3322	// null. It is an error if a field in this list has a non-empty value.
3323	// This may be used to include null fields in Patch requests.
3324	NullFields []string `json:"-"`
3325}
3326
3327func (s *ContentCategory) MarshalJSON() ([]byte, error) {
3328	type NoMethod ContentCategory
3329	raw := NoMethod(*s)
3330	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3331}
3332
3333// Conversion: A Conversion represents when a user successfully performs
3334// a desired action after seeing an ad.
3335type Conversion struct {
3336	// ChildDirectedTreatment: Whether this particular request may come from
3337	// a user under the age of 13, under COPPA compliance.
3338	ChildDirectedTreatment bool `json:"childDirectedTreatment,omitempty"`
3339
3340	// CustomVariables: Custom floodlight variables.
3341	CustomVariables []*CustomFloodlightVariable `json:"customVariables,omitempty"`
3342
3343	// Dclid: The display click ID. This field is mutually exclusive with
3344	// encryptedUserId, encryptedUserIdCandidates[], matchId, mobileDeviceId
3345	// and gclid. This or encryptedUserId or encryptedUserIdCandidates[] or
3346	// matchId or mobileDeviceId or gclid is a required field.
3347	Dclid string `json:"dclid,omitempty"`
3348
3349	// EncryptedUserId: The alphanumeric encrypted user ID. When set,
3350	// encryptionInfo should also be specified. This field is mutually
3351	// exclusive with encryptedUserIdCandidates[], matchId, mobileDeviceId,
3352	// gclid and dclid. This or encryptedUserIdCandidates[] or matchId or
3353	// mobileDeviceId or gclid or dclid is a required field.
3354	EncryptedUserId string `json:"encryptedUserId,omitempty"`
3355
3356	// EncryptedUserIdCandidates: A list of the alphanumeric encrypted user
3357	// IDs. Any user ID with exposure prior to the conversion timestamp will
3358	// be used in the inserted conversion. If no such user ID is found then
3359	// the conversion will be rejected with INVALID_ARGUMENT error. When
3360	// set, encryptionInfo should also be specified. This field may only be
3361	// used when calling batchinsert; it is not supported by batchupdate.
3362	// This field is mutually exclusive with encryptedUserId, matchId,
3363	// mobileDeviceId, gclid and dclid. This or encryptedUserId or matchId
3364	// or mobileDeviceId or gclid or dclid is a required field.
3365	EncryptedUserIdCandidates []string `json:"encryptedUserIdCandidates,omitempty"`
3366
3367	// FloodlightActivityId: Floodlight Activity ID of this conversion. This
3368	// is a required field.
3369	FloodlightActivityId int64 `json:"floodlightActivityId,omitempty,string"`
3370
3371	// FloodlightConfigurationId: Floodlight Configuration ID of this
3372	// conversion. This is a required field.
3373	FloodlightConfigurationId int64 `json:"floodlightConfigurationId,omitempty,string"`
3374
3375	// Gclid: The Google click ID. This field is mutually exclusive with
3376	// encryptedUserId, encryptedUserIdCandidates[], matchId, mobileDeviceId
3377	// and dclid. This or encryptedUserId or encryptedUserIdCandidates[] or
3378	// matchId or mobileDeviceId or dclid is a required field.
3379	Gclid string `json:"gclid,omitempty"`
3380
3381	// Kind: Identifies what kind of resource this is. Value: the fixed
3382	// string "dfareporting#conversion".
3383	Kind string `json:"kind,omitempty"`
3384
3385	// LimitAdTracking: Whether Limit Ad Tracking is enabled. When set to
3386	// true, the conversion will be used for reporting but not targeting.
3387	// This will prevent remarketing.
3388	LimitAdTracking bool `json:"limitAdTracking,omitempty"`
3389
3390	// MatchId: The match ID field. A match ID is your own first-party
3391	// identifier that has been synced with Google using the match ID
3392	// feature in Floodlight. This field is mutually exclusive with
3393	// encryptedUserId, encryptedUserIdCandidates[],mobileDeviceId, gclid
3394	// and dclid. This or encryptedUserId or encryptedUserIdCandidates[] or
3395	// mobileDeviceId or gclid or dclid is a required field.
3396	MatchId string `json:"matchId,omitempty"`
3397
3398	// MobileDeviceId: The mobile device ID. This field is mutually
3399	// exclusive with encryptedUserId, encryptedUserIdCandidates[], matchId,
3400	// gclid and dclid. This or encryptedUserId or
3401	// encryptedUserIdCandidates[] or matchId or gclid or dclid is a
3402	// required field.
3403	MobileDeviceId string `json:"mobileDeviceId,omitempty"`
3404
3405	// NonPersonalizedAd: Whether the conversion was for a non personalized
3406	// ad.
3407	NonPersonalizedAd bool `json:"nonPersonalizedAd,omitempty"`
3408
3409	// Ordinal: The ordinal of the conversion. Use this field to control how
3410	// conversions of the same user and day are de-duplicated. This is a
3411	// required field.
3412	Ordinal string `json:"ordinal,omitempty"`
3413
3414	// Quantity: The quantity of the conversion.
3415	Quantity int64 `json:"quantity,omitempty,string"`
3416
3417	// TimestampMicros: The timestamp of conversion, in Unix epoch micros.
3418	// This is a required field.
3419	TimestampMicros int64 `json:"timestampMicros,omitempty,string"`
3420
3421	// TreatmentForUnderage: Whether this particular request may come from a
3422	// user under the age of 16 (may differ by country), under compliance
3423	// with the European Union's General Data Protection Regulation (GDPR).
3424	TreatmentForUnderage bool `json:"treatmentForUnderage,omitempty"`
3425
3426	// Value: The value of the conversion.
3427	Value float64 `json:"value,omitempty"`
3428
3429	// ForceSendFields is a list of field names (e.g.
3430	// "ChildDirectedTreatment") to unconditionally include in API requests.
3431	// By default, fields with empty or default values are omitted from API
3432	// requests. However, any non-pointer, non-interface field appearing in
3433	// ForceSendFields will be sent to the server regardless of whether the
3434	// field is empty or not. This may be used to include empty fields in
3435	// Patch requests.
3436	ForceSendFields []string `json:"-"`
3437
3438	// NullFields is a list of field names (e.g. "ChildDirectedTreatment")
3439	// to include in API requests with the JSON null value. By default,
3440	// fields with empty values are omitted from API requests. However, any
3441	// field with an empty value appearing in NullFields will be sent to the
3442	// server as null. It is an error if a field in this list has a
3443	// non-empty value. This may be used to include null fields in Patch
3444	// requests.
3445	NullFields []string `json:"-"`
3446}
3447
3448func (s *Conversion) MarshalJSON() ([]byte, error) {
3449	type NoMethod Conversion
3450	raw := NoMethod(*s)
3451	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3452}
3453
3454func (s *Conversion) UnmarshalJSON(data []byte) error {
3455	type NoMethod Conversion
3456	var s1 struct {
3457		Value gensupport.JSONFloat64 `json:"value"`
3458		*NoMethod
3459	}
3460	s1.NoMethod = (*NoMethod)(s)
3461	if err := json.Unmarshal(data, &s1); err != nil {
3462		return err
3463	}
3464	s.Value = float64(s1.Value)
3465	return nil
3466}
3467
3468// ConversionError: The error code and description for a conversion that
3469// failed to insert or update.
3470type ConversionError struct {
3471	// Code: The error code.
3472	//
3473	// Possible values:
3474	//   "INVALID_ARGUMENT"
3475	//   "INTERNAL"
3476	//   "PERMISSION_DENIED"
3477	//   "NOT_FOUND"
3478	Code string `json:"code,omitempty"`
3479
3480	// Kind: Identifies what kind of resource this is. Value: the fixed
3481	// string "dfareporting#conversionError".
3482	Kind string `json:"kind,omitempty"`
3483
3484	// Message: A description of the error.
3485	Message string `json:"message,omitempty"`
3486
3487	// ForceSendFields is a list of field names (e.g. "Code") to
3488	// unconditionally include in API requests. By default, fields with
3489	// empty or default values are omitted from API requests. However, any
3490	// non-pointer, non-interface field appearing in ForceSendFields will be
3491	// sent to the server regardless of whether the field is empty or not.
3492	// This may be used to include empty fields in Patch requests.
3493	ForceSendFields []string `json:"-"`
3494
3495	// NullFields is a list of field names (e.g. "Code") to include in API
3496	// requests with the JSON null value. By default, fields with empty
3497	// values are omitted from API requests. However, any field with an
3498	// empty value appearing in NullFields will be sent to the server as
3499	// null. It is an error if a field in this list has a non-empty value.
3500	// This may be used to include null fields in Patch requests.
3501	NullFields []string `json:"-"`
3502}
3503
3504func (s *ConversionError) MarshalJSON() ([]byte, error) {
3505	type NoMethod ConversionError
3506	raw := NoMethod(*s)
3507	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3508}
3509
3510// ConversionStatus: The original conversion that was inserted or
3511// updated and whether there were any errors.
3512type ConversionStatus struct {
3513	// Conversion: The original conversion that was inserted or updated.
3514	Conversion *Conversion `json:"conversion,omitempty"`
3515
3516	// Errors: A list of errors related to this conversion.
3517	Errors []*ConversionError `json:"errors,omitempty"`
3518
3519	// Kind: Identifies what kind of resource this is. Value: the fixed
3520	// string "dfareporting#conversionStatus".
3521	Kind string `json:"kind,omitempty"`
3522
3523	// ForceSendFields is a list of field names (e.g. "Conversion") to
3524	// unconditionally include in API requests. By default, fields with
3525	// empty or default values are omitted from API requests. However, any
3526	// non-pointer, non-interface field appearing in ForceSendFields will be
3527	// sent to the server regardless of whether the field is empty or not.
3528	// This may be used to include empty fields in Patch requests.
3529	ForceSendFields []string `json:"-"`
3530
3531	// NullFields is a list of field names (e.g. "Conversion") to include in
3532	// API requests with the JSON null value. By default, fields with empty
3533	// values are omitted from API requests. However, any field with an
3534	// empty value appearing in NullFields will be sent to the server as
3535	// null. It is an error if a field in this list has a non-empty value.
3536	// This may be used to include null fields in Patch requests.
3537	NullFields []string `json:"-"`
3538}
3539
3540func (s *ConversionStatus) MarshalJSON() ([]byte, error) {
3541	type NoMethod ConversionStatus
3542	raw := NoMethod(*s)
3543	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3544}
3545
3546// ConversionsBatchInsertRequest: Insert Conversions Request.
3547type ConversionsBatchInsertRequest struct {
3548	// Conversions: The set of conversions to insert.
3549	Conversions []*Conversion `json:"conversions,omitempty"`
3550
3551	// EncryptionInfo: Describes how encryptedUserId or
3552	// encryptedUserIdCandidates[] is encrypted. This is a required field if
3553	// encryptedUserId or encryptedUserIdCandidates[] is used.
3554	EncryptionInfo *EncryptionInfo `json:"encryptionInfo,omitempty"`
3555
3556	// Kind: Identifies what kind of resource this is. Value: the fixed
3557	// string "dfareporting#conversionsBatchInsertRequest".
3558	Kind string `json:"kind,omitempty"`
3559
3560	// ForceSendFields is a list of field names (e.g. "Conversions") to
3561	// unconditionally include in API requests. By default, fields with
3562	// empty or default values are omitted from API requests. However, any
3563	// non-pointer, non-interface field appearing in ForceSendFields will be
3564	// sent to the server regardless of whether the field is empty or not.
3565	// This may be used to include empty fields in Patch requests.
3566	ForceSendFields []string `json:"-"`
3567
3568	// NullFields is a list of field names (e.g. "Conversions") to include
3569	// in API requests with the JSON null value. By default, fields with
3570	// empty values are omitted from API requests. However, any field with
3571	// an empty value appearing in NullFields will be sent to the server as
3572	// null. It is an error if a field in this list has a non-empty value.
3573	// This may be used to include null fields in Patch requests.
3574	NullFields []string `json:"-"`
3575}
3576
3577func (s *ConversionsBatchInsertRequest) MarshalJSON() ([]byte, error) {
3578	type NoMethod ConversionsBatchInsertRequest
3579	raw := NoMethod(*s)
3580	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3581}
3582
3583// ConversionsBatchInsertResponse: Insert Conversions Response.
3584type ConversionsBatchInsertResponse struct {
3585	// HasFailures: Indicates that some or all conversions failed to insert.
3586	HasFailures bool `json:"hasFailures,omitempty"`
3587
3588	// Kind: Identifies what kind of resource this is. Value: the fixed
3589	// string "dfareporting#conversionsBatchInsertResponse".
3590	Kind string `json:"kind,omitempty"`
3591
3592	// Status: The insert status of each conversion. Statuses are returned
3593	// in the same order that conversions are inserted.
3594	Status []*ConversionStatus `json:"status,omitempty"`
3595
3596	// ServerResponse contains the HTTP response code and headers from the
3597	// server.
3598	googleapi.ServerResponse `json:"-"`
3599
3600	// ForceSendFields is a list of field names (e.g. "HasFailures") to
3601	// unconditionally include in API requests. By default, fields with
3602	// empty or default values are omitted from API requests. However, any
3603	// non-pointer, non-interface field appearing in ForceSendFields will be
3604	// sent to the server regardless of whether the field is empty or not.
3605	// This may be used to include empty fields in Patch requests.
3606	ForceSendFields []string `json:"-"`
3607
3608	// NullFields is a list of field names (e.g. "HasFailures") to include
3609	// in API requests with the JSON null value. By default, fields with
3610	// empty values are omitted from API requests. However, any field with
3611	// an empty value appearing in NullFields will be sent to the server as
3612	// null. It is an error if a field in this list has a non-empty value.
3613	// This may be used to include null fields in Patch requests.
3614	NullFields []string `json:"-"`
3615}
3616
3617func (s *ConversionsBatchInsertResponse) MarshalJSON() ([]byte, error) {
3618	type NoMethod ConversionsBatchInsertResponse
3619	raw := NoMethod(*s)
3620	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3621}
3622
3623// ConversionsBatchUpdateRequest: Update Conversions Request.
3624type ConversionsBatchUpdateRequest struct {
3625	// Conversions: The set of conversions to update.
3626	Conversions []*Conversion `json:"conversions,omitempty"`
3627
3628	// EncryptionInfo: Describes how encryptedUserId is encrypted. This is a
3629	// required field if encryptedUserId is used.
3630	EncryptionInfo *EncryptionInfo `json:"encryptionInfo,omitempty"`
3631
3632	// Kind: Identifies what kind of resource this is. Value: the fixed
3633	// string "dfareporting#conversionsBatchUpdateRequest".
3634	Kind string `json:"kind,omitempty"`
3635
3636	// ForceSendFields is a list of field names (e.g. "Conversions") to
3637	// unconditionally include in API requests. By default, fields with
3638	// empty or default values are omitted from API requests. However, any
3639	// non-pointer, non-interface field appearing in ForceSendFields will be
3640	// sent to the server regardless of whether the field is empty or not.
3641	// This may be used to include empty fields in Patch requests.
3642	ForceSendFields []string `json:"-"`
3643
3644	// NullFields is a list of field names (e.g. "Conversions") to include
3645	// in API requests with the JSON null value. By default, fields with
3646	// empty values are omitted from API requests. However, any field with
3647	// an empty value appearing in NullFields will be sent to the server as
3648	// null. It is an error if a field in this list has a non-empty value.
3649	// This may be used to include null fields in Patch requests.
3650	NullFields []string `json:"-"`
3651}
3652
3653func (s *ConversionsBatchUpdateRequest) MarshalJSON() ([]byte, error) {
3654	type NoMethod ConversionsBatchUpdateRequest
3655	raw := NoMethod(*s)
3656	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3657}
3658
3659// ConversionsBatchUpdateResponse: Update Conversions Response.
3660type ConversionsBatchUpdateResponse struct {
3661	// HasFailures: Indicates that some or all conversions failed to update.
3662	HasFailures bool `json:"hasFailures,omitempty"`
3663
3664	// Kind: Identifies what kind of resource this is. Value: the fixed
3665	// string "dfareporting#conversionsBatchUpdateResponse".
3666	Kind string `json:"kind,omitempty"`
3667
3668	// Status: The update status of each conversion. Statuses are returned
3669	// in the same order that conversions are updated.
3670	Status []*ConversionStatus `json:"status,omitempty"`
3671
3672	// ServerResponse contains the HTTP response code and headers from the
3673	// server.
3674	googleapi.ServerResponse `json:"-"`
3675
3676	// ForceSendFields is a list of field names (e.g. "HasFailures") to
3677	// unconditionally include in API requests. By default, fields with
3678	// empty or default values are omitted from API requests. However, any
3679	// non-pointer, non-interface field appearing in ForceSendFields will be
3680	// sent to the server regardless of whether the field is empty or not.
3681	// This may be used to include empty fields in Patch requests.
3682	ForceSendFields []string `json:"-"`
3683
3684	// NullFields is a list of field names (e.g. "HasFailures") to include
3685	// in API requests with the JSON null value. By default, fields with
3686	// empty values are omitted from API requests. However, any field with
3687	// an empty value appearing in NullFields will be sent to the server as
3688	// null. It is an error if a field in this list has a non-empty value.
3689	// This may be used to include null fields in Patch requests.
3690	NullFields []string `json:"-"`
3691}
3692
3693func (s *ConversionsBatchUpdateResponse) MarshalJSON() ([]byte, error) {
3694	type NoMethod ConversionsBatchUpdateResponse
3695	raw := NoMethod(*s)
3696	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3697}
3698
3699// CountriesListResponse: Country List Response
3700type CountriesListResponse struct {
3701	// Countries: Country collection.
3702	Countries []*Country `json:"countries,omitempty"`
3703
3704	// Kind: Identifies what kind of resource this is. Value: the fixed
3705	// string "dfareporting#countriesListResponse".
3706	Kind string `json:"kind,omitempty"`
3707
3708	// ServerResponse contains the HTTP response code and headers from the
3709	// server.
3710	googleapi.ServerResponse `json:"-"`
3711
3712	// ForceSendFields is a list of field names (e.g. "Countries") to
3713	// unconditionally include in API requests. By default, fields with
3714	// empty or default values are omitted from API requests. However, any
3715	// non-pointer, non-interface field appearing in ForceSendFields will be
3716	// sent to the server regardless of whether the field is empty or not.
3717	// This may be used to include empty fields in Patch requests.
3718	ForceSendFields []string `json:"-"`
3719
3720	// NullFields is a list of field names (e.g. "Countries") to include in
3721	// API requests with the JSON null value. By default, fields with empty
3722	// values are omitted from API requests. However, any field with an
3723	// empty value appearing in NullFields will be sent to the server as
3724	// null. It is an error if a field in this list has a non-empty value.
3725	// This may be used to include null fields in Patch requests.
3726	NullFields []string `json:"-"`
3727}
3728
3729func (s *CountriesListResponse) MarshalJSON() ([]byte, error) {
3730	type NoMethod CountriesListResponse
3731	raw := NoMethod(*s)
3732	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3733}
3734
3735// Country: Contains information about a country that can be targeted by
3736// ads.
3737type Country struct {
3738	// CountryCode: Country code.
3739	CountryCode string `json:"countryCode,omitempty"`
3740
3741	// DartId: DART ID of this country. This is the ID used for targeting
3742	// and generating reports.
3743	DartId int64 `json:"dartId,omitempty,string"`
3744
3745	// Kind: Identifies what kind of resource this is. Value: the fixed
3746	// string "dfareporting#country".
3747	Kind string `json:"kind,omitempty"`
3748
3749	// Name: Name of this country.
3750	Name string `json:"name,omitempty"`
3751
3752	// SslEnabled: Whether ad serving supports secure servers in this
3753	// country.
3754	SslEnabled bool `json:"sslEnabled,omitempty"`
3755
3756	// ServerResponse contains the HTTP response code and headers from the
3757	// server.
3758	googleapi.ServerResponse `json:"-"`
3759
3760	// ForceSendFields is a list of field names (e.g. "CountryCode") to
3761	// unconditionally include in API requests. By default, fields with
3762	// empty or default values are omitted from API requests. However, any
3763	// non-pointer, non-interface field appearing in ForceSendFields will be
3764	// sent to the server regardless of whether the field is empty or not.
3765	// This may be used to include empty fields in Patch requests.
3766	ForceSendFields []string `json:"-"`
3767
3768	// NullFields is a list of field names (e.g. "CountryCode") to include
3769	// in API requests with the JSON null value. By default, fields with
3770	// empty values are omitted from API requests. However, any field with
3771	// an empty value appearing in NullFields will be sent to the server as
3772	// null. It is an error if a field in this list has a non-empty value.
3773	// This may be used to include null fields in Patch requests.
3774	NullFields []string `json:"-"`
3775}
3776
3777func (s *Country) MarshalJSON() ([]byte, error) {
3778	type NoMethod Country
3779	raw := NoMethod(*s)
3780	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3781}
3782
3783// Creative: Contains properties of a Creative.
3784type Creative struct {
3785	// AccountId: Account ID of this creative. This field, if left unset,
3786	// will be auto-generated for both insert and update operations.
3787	// Applicable to all creative types.
3788	AccountId int64 `json:"accountId,omitempty,string"`
3789
3790	// Active: Whether the creative is active. Applicable to all creative
3791	// types.
3792	Active bool `json:"active,omitempty"`
3793
3794	// AdParameters: Ad parameters user for VPAID creative. This is a
3795	// read-only field. Applicable to the following creative types: all
3796	// VPAID.
3797	AdParameters string `json:"adParameters,omitempty"`
3798
3799	// AdTagKeys: Keywords for a Rich Media creative. Keywords let you
3800	// customize the creative settings of a Rich Media ad running on your
3801	// site without having to contact the advertiser. You can use keywords
3802	// to dynamically change the look or functionality of a creative.
3803	// Applicable to the following creative types: all RICH_MEDIA, and all
3804	// VPAID.
3805	AdTagKeys []string `json:"adTagKeys,omitempty"`
3806
3807	// AdditionalSizes: Additional sizes associated with a responsive
3808	// creative. When inserting or updating a creative either the size ID
3809	// field or size width and height fields can be used. Applicable to
3810	// DISPLAY creatives when the primary asset type is HTML_IMAGE.
3811	AdditionalSizes []*Size `json:"additionalSizes,omitempty"`
3812
3813	// AdvertiserId: Advertiser ID of this creative. This is a required
3814	// field. Applicable to all creative types.
3815	AdvertiserId int64 `json:"advertiserId,omitempty,string"`
3816
3817	// AllowScriptAccess: Whether script access is allowed for this
3818	// creative. This is a read-only and deprecated field which will
3819	// automatically be set to true on update. Applicable to the following
3820	// creative types: FLASH_INPAGE.
3821	AllowScriptAccess bool `json:"allowScriptAccess,omitempty"`
3822
3823	// Archived: Whether the creative is archived. Applicable to all
3824	// creative types.
3825	Archived bool `json:"archived,omitempty"`
3826
3827	// ArtworkType: Type of artwork used for the creative. This is a
3828	// read-only field. Applicable to the following creative types: all
3829	// RICH_MEDIA, and all VPAID.
3830	//
3831	// Possible values:
3832	//   "ARTWORK_TYPE_FLASH"
3833	//   "ARTWORK_TYPE_HTML5"
3834	//   "ARTWORK_TYPE_MIXED"
3835	//   "ARTWORK_TYPE_IMAGE"
3836	ArtworkType string `json:"artworkType,omitempty"`
3837
3838	// AuthoringSource: Source application where creative was authored.
3839	// Presently, only DBM authored creatives will have this field set.
3840	// Applicable to all creative types.
3841	//
3842	// Possible values:
3843	//   "CREATIVE_AUTHORING_SOURCE_DCM"
3844	//   "CREATIVE_AUTHORING_SOURCE_DBM"
3845	//   "CREATIVE_AUTHORING_SOURCE_STUDIO"
3846	//   "CREATIVE_AUTHORING_SOURCE_GWD"
3847	AuthoringSource string `json:"authoringSource,omitempty"`
3848
3849	// AuthoringTool: Authoring tool for HTML5 banner creatives. This is a
3850	// read-only field. Applicable to the following creative types:
3851	// HTML5_BANNER.
3852	//
3853	// Possible values:
3854	//   "NINJA"
3855	//   "SWIFFY"
3856	AuthoringTool string `json:"authoringTool,omitempty"`
3857
3858	// AutoAdvanceImages: Whether images are automatically advanced for
3859	// image gallery creatives. Applicable to the following creative types:
3860	// DISPLAY_IMAGE_GALLERY.
3861	AutoAdvanceImages bool `json:"autoAdvanceImages,omitempty"`
3862
3863	// BackgroundColor: The 6-character HTML color code, beginning with #,
3864	// for the background of the window area where the Flash file is
3865	// displayed. Default is white. Applicable to the following creative
3866	// types: FLASH_INPAGE.
3867	BackgroundColor string `json:"backgroundColor,omitempty"`
3868
3869	// BackupImageClickThroughUrl: Click-through URL for backup image.
3870	// Applicable to ENHANCED_BANNER when the primary asset type is not
3871	// HTML_IMAGE.
3872	BackupImageClickThroughUrl *CreativeClickThroughUrl `json:"backupImageClickThroughUrl,omitempty"`
3873
3874	// BackupImageFeatures: List of feature dependencies that will cause a
3875	// backup image to be served if the browser that serves the ad does not
3876	// support them. Feature dependencies are features that a browser must
3877	// be able to support in order to render your HTML5 creative asset
3878	// correctly. This field is initially auto-generated to contain all
3879	// features detected by Campaign Manager for all the assets of this
3880	// creative and can then be modified by the client. To reset this field,
3881	// copy over all the creativeAssets' detected features. Applicable to
3882	// the following creative types: HTML5_BANNER. Applicable to DISPLAY
3883	// when the primary asset type is not HTML_IMAGE.
3884	//
3885	// Possible values:
3886	//   "CSS_FONT_FACE"
3887	//   "CSS_BACKGROUND_SIZE"
3888	//   "CSS_BORDER_IMAGE"
3889	//   "CSS_BORDER_RADIUS"
3890	//   "CSS_BOX_SHADOW"
3891	//   "CSS_FLEX_BOX"
3892	//   "CSS_HSLA"
3893	//   "CSS_MULTIPLE_BGS"
3894	//   "CSS_OPACITY"
3895	//   "CSS_RGBA"
3896	//   "CSS_TEXT_SHADOW"
3897	//   "CSS_ANIMATIONS"
3898	//   "CSS_COLUMNS"
3899	//   "CSS_GENERATED_CONTENT"
3900	//   "CSS_GRADIENTS"
3901	//   "CSS_REFLECTIONS"
3902	//   "CSS_TRANSFORMS"
3903	//   "CSS_TRANSFORMS3D"
3904	//   "CSS_TRANSITIONS"
3905	//   "APPLICATION_CACHE"
3906	//   "CANVAS"
3907	//   "CANVAS_TEXT"
3908	//   "DRAG_AND_DROP"
3909	//   "HASH_CHANGE"
3910	//   "HISTORY"
3911	//   "AUDIO"
3912	//   "VIDEO"
3913	//   "INDEXED_DB"
3914	//   "INPUT_ATTR_AUTOCOMPLETE"
3915	//   "INPUT_ATTR_AUTOFOCUS"
3916	//   "INPUT_ATTR_LIST"
3917	//   "INPUT_ATTR_PLACEHOLDER"
3918	//   "INPUT_ATTR_MAX"
3919	//   "INPUT_ATTR_MIN"
3920	//   "INPUT_ATTR_MULTIPLE"
3921	//   "INPUT_ATTR_PATTERN"
3922	//   "INPUT_ATTR_REQUIRED"
3923	//   "INPUT_ATTR_STEP"
3924	//   "INPUT_TYPE_SEARCH"
3925	//   "INPUT_TYPE_TEL"
3926	//   "INPUT_TYPE_URL"
3927	//   "INPUT_TYPE_EMAIL"
3928	//   "INPUT_TYPE_DATETIME"
3929	//   "INPUT_TYPE_DATE"
3930	//   "INPUT_TYPE_MONTH"
3931	//   "INPUT_TYPE_WEEK"
3932	//   "INPUT_TYPE_TIME"
3933	//   "INPUT_TYPE_DATETIME_LOCAL"
3934	//   "INPUT_TYPE_NUMBER"
3935	//   "INPUT_TYPE_RANGE"
3936	//   "INPUT_TYPE_COLOR"
3937	//   "LOCAL_STORAGE"
3938	//   "POST_MESSAGE"
3939	//   "SESSION_STORAGE"
3940	//   "WEB_SOCKETS"
3941	//   "WEB_SQL_DATABASE"
3942	//   "WEB_WORKERS"
3943	//   "GEO_LOCATION"
3944	//   "INLINE_SVG"
3945	//   "SMIL"
3946	//   "SVG_HREF"
3947	//   "SVG_CLIP_PATHS"
3948	//   "TOUCH"
3949	//   "WEBGL"
3950	//   "SVG_FILTERS"
3951	//   "SVG_FE_IMAGE"
3952	BackupImageFeatures []string `json:"backupImageFeatures,omitempty"`
3953
3954	// BackupImageReportingLabel: Reporting label used for HTML5 banner
3955	// backup image. Applicable to the following creative types: DISPLAY
3956	// when the primary asset type is not HTML_IMAGE.
3957	BackupImageReportingLabel string `json:"backupImageReportingLabel,omitempty"`
3958
3959	// BackupImageTargetWindow: Target window for backup image. Applicable
3960	// to the following creative types: FLASH_INPAGE and HTML5_BANNER.
3961	// Applicable to DISPLAY when the primary asset type is not HTML_IMAGE.
3962	BackupImageTargetWindow *TargetWindow `json:"backupImageTargetWindow,omitempty"`
3963
3964	// ClickTags: Click tags of the creative. For DISPLAY, FLASH_INPAGE, and
3965	// HTML5_BANNER creatives, this is a subset of detected click tags for
3966	// the assets associated with this creative. After creating a flash
3967	// asset, detected click tags will be returned in the
3968	// creativeAssetMetadata. When inserting the creative, populate the
3969	// creative clickTags field using the creativeAssetMetadata.clickTags
3970	// field. For DISPLAY_IMAGE_GALLERY creatives, there should be exactly
3971	// one entry in this list for each image creative asset. A click tag is
3972	// matched with a corresponding creative asset by matching the
3973	// clickTag.name field with the creativeAsset.assetIdentifier.name
3974	// field. Applicable to the following creative types:
3975	// DISPLAY_IMAGE_GALLERY, FLASH_INPAGE, HTML5_BANNER. Applicable to
3976	// DISPLAY when the primary asset type is not HTML_IMAGE.
3977	ClickTags []*ClickTag `json:"clickTags,omitempty"`
3978
3979	// CommercialId: Industry standard ID assigned to creative for reach and
3980	// frequency. Applicable to INSTREAM_VIDEO_REDIRECT creatives.
3981	CommercialId string `json:"commercialId,omitempty"`
3982
3983	// CompanionCreatives: List of companion creatives assigned to an
3984	// in-Stream video creative. Acceptable values include IDs of existing
3985	// flash and image creatives. Applicable to the following creative
3986	// types: all VPAID, all INSTREAM_AUDIO and all INSTREAM_VIDEO with
3987	// dynamicAssetSelection set to false.
3988	CompanionCreatives googleapi.Int64s `json:"companionCreatives,omitempty"`
3989
3990	// Compatibility: Compatibilities associated with this creative. This is
3991	// a read-only field. DISPLAY and DISPLAY_INTERSTITIAL refer to
3992	// rendering either on desktop or on mobile devices or in mobile apps
3993	// for regular or interstitial ads, respectively. APP and
3994	// APP_INTERSTITIAL are for rendering in mobile apps. Only pre-existing
3995	// creatives may have these compatibilities since new creatives will
3996	// either be assigned DISPLAY or DISPLAY_INTERSTITIAL instead.
3997	// IN_STREAM_VIDEO refers to rendering in in-stream video ads developed
3998	// with the VAST standard. IN_STREAM_AUDIO refers to rendering in
3999	// in-stream audio ads developed with the VAST standard. Applicable to
4000	// all creative types. Acceptable values are: - "APP" -
4001	// "APP_INTERSTITIAL" - "IN_STREAM_VIDEO" - "IN_STREAM_AUDIO" -
4002	// "DISPLAY" - "DISPLAY_INTERSTITIAL"
4003	//
4004	// Possible values:
4005	//   "DISPLAY"
4006	//   "DISPLAY_INTERSTITIAL"
4007	//   "APP"
4008	//   "APP_INTERSTITIAL"
4009	//   "IN_STREAM_VIDEO"
4010	//   "IN_STREAM_AUDIO"
4011	Compatibility []string `json:"compatibility,omitempty"`
4012
4013	// ConvertFlashToHtml5: Whether Flash assets associated with the
4014	// creative need to be automatically converted to HTML5. This flag is
4015	// enabled by default and users can choose to disable it if they don't
4016	// want the system to generate and use HTML5 asset for this creative.
4017	// Applicable to the following creative type: FLASH_INPAGE. Applicable
4018	// to DISPLAY when the primary asset type is not HTML_IMAGE.
4019	ConvertFlashToHtml5 bool `json:"convertFlashToHtml5,omitempty"`
4020
4021	// CounterCustomEvents: List of counter events configured for the
4022	// creative. For DISPLAY_IMAGE_GALLERY creatives, these are read-only
4023	// and auto-generated from clickTags. Applicable to the following
4024	// creative types: DISPLAY_IMAGE_GALLERY, all RICH_MEDIA, and all VPAID.
4025	CounterCustomEvents []*CreativeCustomEvent `json:"counterCustomEvents,omitempty"`
4026
4027	// CreativeAssetSelection: Required if dynamicAssetSelection is true.
4028	CreativeAssetSelection *CreativeAssetSelection `json:"creativeAssetSelection,omitempty"`
4029
4030	// CreativeAssets: Assets associated with a creative. Applicable to all
4031	// but the following creative types: INTERNAL_REDIRECT,
4032	// INTERSTITIAL_INTERNAL_REDIRECT, and REDIRECT
4033	CreativeAssets []*CreativeAsset `json:"creativeAssets,omitempty"`
4034
4035	// CreativeFieldAssignments: Creative field assignments for this
4036	// creative. Applicable to all creative types.
4037	CreativeFieldAssignments []*CreativeFieldAssignment `json:"creativeFieldAssignments,omitempty"`
4038
4039	// CustomKeyValues: Custom key-values for a Rich Media creative.
4040	// Key-values let you customize the creative settings of a Rich Media ad
4041	// running on your site without having to contact the advertiser. You
4042	// can use key-values to dynamically change the look or functionality of
4043	// a creative. Applicable to the following creative types: all
4044	// RICH_MEDIA, and all VPAID.
4045	CustomKeyValues []string `json:"customKeyValues,omitempty"`
4046
4047	// DynamicAssetSelection: Set this to true to enable the use of rules to
4048	// target individual assets in this creative. When set to true
4049	// creativeAssetSelection must be set. This also controls asset-level
4050	// companions. When this is true, companion creatives should be assigned
4051	// to creative assets. Learn more. Applicable to INSTREAM_VIDEO
4052	// creatives.
4053	DynamicAssetSelection bool `json:"dynamicAssetSelection,omitempty"`
4054
4055	// ExitCustomEvents: List of exit events configured for the creative.
4056	// For DISPLAY and DISPLAY_IMAGE_GALLERY creatives, these are read-only
4057	// and auto-generated from clickTags, For DISPLAY, an event is also
4058	// created from the backupImageReportingLabel. Applicable to the
4059	// following creative types: DISPLAY_IMAGE_GALLERY, all RICH_MEDIA, and
4060	// all VPAID. Applicable to DISPLAY when the primary asset type is not
4061	// HTML_IMAGE.
4062	ExitCustomEvents []*CreativeCustomEvent `json:"exitCustomEvents,omitempty"`
4063
4064	// FsCommand: OpenWindow FSCommand of this creative. This lets the SWF
4065	// file communicate with either Flash Player or the program hosting
4066	// Flash Player, such as a web browser. This is only triggered if
4067	// allowScriptAccess field is true. Applicable to the following creative
4068	// types: FLASH_INPAGE.
4069	FsCommand *FsCommand `json:"fsCommand,omitempty"`
4070
4071	// HtmlCode: HTML code for the creative. This is a required field when
4072	// applicable. This field is ignored if htmlCodeLocked is true.
4073	// Applicable to the following creative types: all CUSTOM, FLASH_INPAGE,
4074	// and HTML5_BANNER, and all RICH_MEDIA.
4075	HtmlCode string `json:"htmlCode,omitempty"`
4076
4077	// HtmlCodeLocked: Whether HTML code is generated by Campaign Manager or
4078	// manually entered. Set to true to ignore changes to htmlCode.
4079	// Applicable to the following creative types: FLASH_INPAGE and
4080	// HTML5_BANNER.
4081	HtmlCodeLocked bool `json:"htmlCodeLocked,omitempty"`
4082
4083	// Id: ID of this creative. This is a read-only, auto-generated field.
4084	// Applicable to all creative types.
4085	Id int64 `json:"id,omitempty,string"`
4086
4087	// IdDimensionValue: Dimension value for the ID of this creative. This
4088	// is a read-only field. Applicable to all creative types.
4089	IdDimensionValue *DimensionValue `json:"idDimensionValue,omitempty"`
4090
4091	// Kind: Identifies what kind of resource this is. Value: the fixed
4092	// string "dfareporting#creative".
4093	Kind string `json:"kind,omitempty"`
4094
4095	// LastModifiedInfo: Creative last modification information. This is a
4096	// read-only field. Applicable to all creative types.
4097	LastModifiedInfo *LastModifiedInfo `json:"lastModifiedInfo,omitempty"`
4098
4099	// LatestTraffickedCreativeId: Latest Studio trafficked creative ID
4100	// associated with rich media and VPAID creatives. This is a read-only
4101	// field. Applicable to the following creative types: all RICH_MEDIA,
4102	// and all VPAID.
4103	LatestTraffickedCreativeId int64 `json:"latestTraffickedCreativeId,omitempty,string"`
4104
4105	// MediaDescription: Description of the audio or video ad. Applicable to
4106	// the following creative types: all INSTREAM_VIDEO, INSTREAM_AUDIO, and
4107	// all VPAID.
4108	MediaDescription string `json:"mediaDescription,omitempty"`
4109
4110	// MediaDuration: Creative audio or video duration in seconds. This is a
4111	// read-only field. Applicable to the following creative types:
4112	// INSTREAM_VIDEO, INSTREAM_AUDIO, all RICH_MEDIA, and all VPAID.
4113	MediaDuration float64 `json:"mediaDuration,omitempty"`
4114
4115	// Name: Name of the creative. This is a required field and must be less
4116	// than 256 characters long. Applicable to all creative types.
4117	Name string `json:"name,omitempty"`
4118
4119	// ObaIcon: Online behavioral advertising icon to be added to the
4120	// creative. Applicable to the following creative types: all
4121	// INSTREAM_VIDEO.
4122	ObaIcon *ObaIcon `json:"obaIcon,omitempty"`
4123
4124	// OverrideCss: Override CSS value for rich media creatives. Applicable
4125	// to the following creative types: all RICH_MEDIA.
4126	OverrideCss string `json:"overrideCss,omitempty"`
4127
4128	// ProgressOffset: Amount of time to play the video before counting a
4129	// view. Applicable to the following creative types: all INSTREAM_VIDEO.
4130	ProgressOffset *VideoOffset `json:"progressOffset,omitempty"`
4131
4132	// RedirectUrl: URL of hosted image or hosted video or another ad tag.
4133	// For INSTREAM_VIDEO_REDIRECT creatives this is the in-stream video
4134	// redirect URL. The standard for a VAST (Video Ad Serving Template) ad
4135	// response allows for a redirect link to another VAST 2.0 or 3.0 call.
4136	// This is a required field when applicable. Applicable to the following
4137	// creative types: DISPLAY_REDIRECT, INTERNAL_REDIRECT,
4138	// INTERSTITIAL_INTERNAL_REDIRECT, and INSTREAM_VIDEO_REDIRECT
4139	RedirectUrl string `json:"redirectUrl,omitempty"`
4140
4141	// RenderingId: ID of current rendering version. This is a read-only
4142	// field. Applicable to all creative types.
4143	RenderingId int64 `json:"renderingId,omitempty,string"`
4144
4145	// RenderingIdDimensionValue: Dimension value for the rendering ID of
4146	// this creative. This is a read-only field. Applicable to all creative
4147	// types.
4148	RenderingIdDimensionValue *DimensionValue `json:"renderingIdDimensionValue,omitempty"`
4149
4150	// RequiredFlashPluginVersion: The minimum required Flash plugin version
4151	// for this creative. For example, 11.2.202.235. This is a read-only
4152	// field. Applicable to the following creative types: all RICH_MEDIA,
4153	// and all VPAID.
4154	RequiredFlashPluginVersion string `json:"requiredFlashPluginVersion,omitempty"`
4155
4156	// RequiredFlashVersion: The internal Flash version for this creative as
4157	// calculated by Studio. This is a read-only field. Applicable to the
4158	// following creative types: FLASH_INPAGE all RICH_MEDIA, and all VPAID.
4159	// Applicable to DISPLAY when the primary asset type is not HTML_IMAGE.
4160	RequiredFlashVersion int64 `json:"requiredFlashVersion,omitempty"`
4161
4162	// Size: Size associated with this creative. When inserting or updating
4163	// a creative either the size ID field or size width and height fields
4164	// can be used. This is a required field when applicable; however for
4165	// IMAGE, FLASH_INPAGE creatives, and for DISPLAY creatives with a
4166	// primary asset of type HTML_IMAGE, if left blank, this field will be
4167	// automatically set using the actual size of the associated image
4168	// assets. Applicable to the following creative types: DISPLAY,
4169	// DISPLAY_IMAGE_GALLERY, FLASH_INPAGE, HTML5_BANNER, IMAGE, and all
4170	// RICH_MEDIA.
4171	Size *Size `json:"size,omitempty"`
4172
4173	// SkipOffset: Amount of time to play the video before the skip button
4174	// appears. Applicable to the following creative types: all
4175	// INSTREAM_VIDEO.
4176	SkipOffset *VideoOffset `json:"skipOffset,omitempty"`
4177
4178	// Skippable: Whether the user can choose to skip the creative.
4179	// Applicable to the following creative types: all INSTREAM_VIDEO and
4180	// all VPAID.
4181	Skippable bool `json:"skippable,omitempty"`
4182
4183	// SslCompliant: Whether the creative is SSL-compliant. This is a
4184	// read-only field. Applicable to all creative types.
4185	SslCompliant bool `json:"sslCompliant,omitempty"`
4186
4187	// SslOverride: Whether creative should be treated as SSL compliant even
4188	// if the system scan shows it's not. Applicable to all creative types.
4189	SslOverride bool `json:"sslOverride,omitempty"`
4190
4191	// StudioAdvertiserId: Studio advertiser ID associated with rich media
4192	// and VPAID creatives. This is a read-only field. Applicable to the
4193	// following creative types: all RICH_MEDIA, and all VPAID.
4194	StudioAdvertiserId int64 `json:"studioAdvertiserId,omitempty,string"`
4195
4196	// StudioCreativeId: Studio creative ID associated with rich media and
4197	// VPAID creatives. This is a read-only field. Applicable to the
4198	// following creative types: all RICH_MEDIA, and all VPAID.
4199	StudioCreativeId int64 `json:"studioCreativeId,omitempty,string"`
4200
4201	// StudioTraffickedCreativeId: Studio trafficked creative ID associated
4202	// with rich media and VPAID creatives. This is a read-only field.
4203	// Applicable to the following creative types: all RICH_MEDIA, and all
4204	// VPAID.
4205	StudioTraffickedCreativeId int64 `json:"studioTraffickedCreativeId,omitempty,string"`
4206
4207	// SubaccountId: Subaccount ID of this creative. This field, if left
4208	// unset, will be auto-generated for both insert and update operations.
4209	// Applicable to all creative types.
4210	SubaccountId int64 `json:"subaccountId,omitempty,string"`
4211
4212	// ThirdPartyBackupImageImpressionsUrl: Third-party URL used to record
4213	// backup image impressions. Applicable to the following creative types:
4214	// all RICH_MEDIA.
4215	ThirdPartyBackupImageImpressionsUrl string `json:"thirdPartyBackupImageImpressionsUrl,omitempty"`
4216
4217	// ThirdPartyRichMediaImpressionsUrl: Third-party URL used to record
4218	// rich media impressions. Applicable to the following creative types:
4219	// all RICH_MEDIA.
4220	ThirdPartyRichMediaImpressionsUrl string `json:"thirdPartyRichMediaImpressionsUrl,omitempty"`
4221
4222	// ThirdPartyUrls: Third-party URLs for tracking in-stream creative
4223	// events. Applicable to the following creative types: all
4224	// INSTREAM_VIDEO, all INSTREAM_AUDIO, and all VPAID.
4225	ThirdPartyUrls []*ThirdPartyTrackingUrl `json:"thirdPartyUrls,omitempty"`
4226
4227	// TimerCustomEvents: List of timer events configured for the creative.
4228	// For DISPLAY_IMAGE_GALLERY creatives, these are read-only and
4229	// auto-generated from clickTags. Applicable to the following creative
4230	// types: DISPLAY_IMAGE_GALLERY, all RICH_MEDIA, and all VPAID.
4231	// Applicable to DISPLAY when the primary asset is not HTML_IMAGE.
4232	TimerCustomEvents []*CreativeCustomEvent `json:"timerCustomEvents,omitempty"`
4233
4234	// TotalFileSize: Combined size of all creative assets. This is a
4235	// read-only field. Applicable to the following creative types: all
4236	// RICH_MEDIA, and all VPAID.
4237	TotalFileSize int64 `json:"totalFileSize,omitempty,string"`
4238
4239	// Type: Type of this creative. This is a required field. Applicable to
4240	// all creative types. *Note:* FLASH_INPAGE, HTML5_BANNER, and IMAGE are
4241	// only used for existing creatives. New creatives should use DISPLAY as
4242	// a replacement for these types.
4243	//
4244	// Possible values:
4245	//   "IMAGE"
4246	//   "DISPLAY_REDIRECT"
4247	//   "CUSTOM_DISPLAY"
4248	//   "INTERNAL_REDIRECT"
4249	//   "CUSTOM_DISPLAY_INTERSTITIAL"
4250	//   "INTERSTITIAL_INTERNAL_REDIRECT"
4251	//   "TRACKING_TEXT"
4252	//   "RICH_MEDIA_DISPLAY_BANNER"
4253	//   "RICH_MEDIA_INPAGE_FLOATING"
4254	//   "RICH_MEDIA_IM_EXPAND"
4255	//   "RICH_MEDIA_DISPLAY_EXPANDING"
4256	//   "RICH_MEDIA_DISPLAY_INTERSTITIAL"
4257	//   "RICH_MEDIA_DISPLAY_MULTI_FLOATING_INTERSTITIAL"
4258	//   "RICH_MEDIA_MOBILE_IN_APP"
4259	//   "FLASH_INPAGE"
4260	//   "INSTREAM_VIDEO"
4261	//   "VPAID_LINEAR_VIDEO"
4262	//   "VPAID_NON_LINEAR_VIDEO"
4263	//   "INSTREAM_VIDEO_REDIRECT"
4264	//   "RICH_MEDIA_PEEL_DOWN"
4265	//   "HTML5_BANNER"
4266	//   "DISPLAY"
4267	//   "DISPLAY_IMAGE_GALLERY"
4268	//   "BRAND_SAFE_DEFAULT_INSTREAM_VIDEO"
4269	//   "INSTREAM_AUDIO"
4270	Type string `json:"type,omitempty"`
4271
4272	// UniversalAdId: A Universal Ad ID as per the VAST 4.0 spec. Applicable
4273	// to the following creative types: INSTREAM_AUDIO and INSTREAM_VIDEO
4274	// and VPAID.
4275	UniversalAdId *UniversalAdId `json:"universalAdId,omitempty"`
4276
4277	// Version: The version number helps you keep track of multiple versions
4278	// of your creative in your reports. The version number will always be
4279	// auto-generated during insert operations to start at 1. For tracking
4280	// creatives the version cannot be incremented and will always remain at
4281	// 1. For all other creative types the version can be incremented only
4282	// by 1 during update operations. In addition, the version will be
4283	// automatically incremented by 1 when undergoing Rich Media creative
4284	// merging. Applicable to all creative types.
4285	Version int64 `json:"version,omitempty"`
4286
4287	// ServerResponse contains the HTTP response code and headers from the
4288	// server.
4289	googleapi.ServerResponse `json:"-"`
4290
4291	// ForceSendFields is a list of field names (e.g. "AccountId") to
4292	// unconditionally include in API requests. By default, fields with
4293	// empty or default values are omitted from API requests. However, any
4294	// non-pointer, non-interface field appearing in ForceSendFields will be
4295	// sent to the server regardless of whether the field is empty or not.
4296	// This may be used to include empty fields in Patch requests.
4297	ForceSendFields []string `json:"-"`
4298
4299	// NullFields is a list of field names (e.g. "AccountId") to include in
4300	// API requests with the JSON null value. By default, fields with empty
4301	// values are omitted from API requests. However, any field with an
4302	// empty value appearing in NullFields will be sent to the server as
4303	// null. It is an error if a field in this list has a non-empty value.
4304	// This may be used to include null fields in Patch requests.
4305	NullFields []string `json:"-"`
4306}
4307
4308func (s *Creative) MarshalJSON() ([]byte, error) {
4309	type NoMethod Creative
4310	raw := NoMethod(*s)
4311	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
4312}
4313
4314func (s *Creative) UnmarshalJSON(data []byte) error {
4315	type NoMethod Creative
4316	var s1 struct {
4317		MediaDuration gensupport.JSONFloat64 `json:"mediaDuration"`
4318		*NoMethod
4319	}
4320	s1.NoMethod = (*NoMethod)(s)
4321	if err := json.Unmarshal(data, &s1); err != nil {
4322		return err
4323	}
4324	s.MediaDuration = float64(s1.MediaDuration)
4325	return nil
4326}
4327
4328// CreativeAsset: Creative Asset.
4329type CreativeAsset struct {
4330	// ActionScript3: Whether ActionScript3 is enabled for the flash asset.
4331	// This is a read-only field. Applicable to the following creative type:
4332	// FLASH_INPAGE. Applicable to DISPLAY when the primary asset type is
4333	// not HTML_IMAGE.
4334	ActionScript3 bool `json:"actionScript3,omitempty"`
4335
4336	// Active: Whether the video or audio asset is active. This is a
4337	// read-only field for VPAID_NON_LINEAR_VIDEO assets. Applicable to the
4338	// following creative types: INSTREAM_AUDIO, INSTREAM_VIDEO and all
4339	// VPAID.
4340	Active bool `json:"active,omitempty"`
4341
4342	// AdditionalSizes: Additional sizes associated with this creative
4343	// asset. HTML5 asset generated by compatible software such as GWD will
4344	// be able to support more sizes this creative asset can render.
4345	AdditionalSizes []*Size `json:"additionalSizes,omitempty"`
4346
4347	// Alignment: Possible alignments for an asset. This is a read-only
4348	// field. Applicable to the following creative types:
4349	// RICH_MEDIA_DISPLAY_MULTI_FLOATING_INTERSTITIAL .
4350	//
4351	// Possible values:
4352	//   "ALIGNMENT_TOP"
4353	//   "ALIGNMENT_RIGHT"
4354	//   "ALIGNMENT_BOTTOM"
4355	//   "ALIGNMENT_LEFT"
4356	Alignment string `json:"alignment,omitempty"`
4357
4358	// ArtworkType: Artwork type of rich media creative. This is a read-only
4359	// field. Applicable to the following creative types: all RICH_MEDIA.
4360	//
4361	// Possible values:
4362	//   "ARTWORK_TYPE_FLASH"
4363	//   "ARTWORK_TYPE_HTML5"
4364	//   "ARTWORK_TYPE_MIXED"
4365	//   "ARTWORK_TYPE_IMAGE"
4366	ArtworkType string `json:"artworkType,omitempty"`
4367
4368	// AssetIdentifier: Identifier of this asset. This is the same
4369	// identifier returned during creative asset insert operation. This is a
4370	// required field. Applicable to all but the following creative types:
4371	// all REDIRECT and TRACKING_TEXT.
4372	AssetIdentifier *CreativeAssetId `json:"assetIdentifier,omitempty"`
4373
4374	// AudioBitRate: Audio stream bit rate in kbps. This is a read-only
4375	// field. Applicable to the following creative types: INSTREAM_AUDIO,
4376	// INSTREAM_VIDEO and all VPAID.
4377	AudioBitRate int64 `json:"audioBitRate,omitempty"`
4378
4379	// AudioSampleRate: Audio sample bit rate in hertz. This is a read-only
4380	// field. Applicable to the following creative types: INSTREAM_AUDIO,
4381	// INSTREAM_VIDEO and all VPAID.
4382	AudioSampleRate int64 `json:"audioSampleRate,omitempty"`
4383
4384	// BackupImageExit: Exit event configured for the backup image.
4385	// Applicable to the following creative types: all RICH_MEDIA.
4386	BackupImageExit *CreativeCustomEvent `json:"backupImageExit,omitempty"`
4387
4388	// BitRate: Detected bit-rate for audio or video asset. This is a
4389	// read-only field. Applicable to the following creative types:
4390	// INSTREAM_AUDIO, INSTREAM_VIDEO and all VPAID.
4391	BitRate int64 `json:"bitRate,omitempty"`
4392
4393	// ChildAssetType: Rich media child asset type. This is a read-only
4394	// field. Applicable to the following creative types: all VPAID.
4395	//
4396	// Possible values:
4397	//   "CHILD_ASSET_TYPE_FLASH"
4398	//   "CHILD_ASSET_TYPE_VIDEO"
4399	//   "CHILD_ASSET_TYPE_IMAGE"
4400	//   "CHILD_ASSET_TYPE_DATA"
4401	ChildAssetType string `json:"childAssetType,omitempty"`
4402
4403	// CollapsedSize: Size of an asset when collapsed. This is a read-only
4404	// field. Applicable to the following creative types: all RICH_MEDIA and
4405	// all VPAID. Additionally, applicable to assets whose displayType is
4406	// ASSET_DISPLAY_TYPE_EXPANDING or ASSET_DISPLAY_TYPE_PEEL_DOWN.
4407	CollapsedSize *Size `json:"collapsedSize,omitempty"`
4408
4409	// CompanionCreativeIds: List of companion creatives assigned to an
4410	// in-stream video creative asset. Acceptable values include IDs of
4411	// existing flash and image creatives. Applicable to INSTREAM_VIDEO
4412	// creative type with dynamicAssetSelection set to true.
4413	CompanionCreativeIds googleapi.Int64s `json:"companionCreativeIds,omitempty"`
4414
4415	// CustomStartTimeValue: Custom start time in seconds for making the
4416	// asset visible. Applicable to the following creative types: all
4417	// RICH_MEDIA. Value must be greater than or equal to 0.
4418	CustomStartTimeValue int64 `json:"customStartTimeValue,omitempty"`
4419
4420	// DetectedFeatures: List of feature dependencies for the creative asset
4421	// that are detected by Campaign Manager. Feature dependencies are
4422	// features that a browser must be able to support in order to render
4423	// your HTML5 creative correctly. This is a read-only, auto-generated
4424	// field. Applicable to the following creative types: HTML5_BANNER.
4425	// Applicable to DISPLAY when the primary asset type is not HTML_IMAGE.
4426	//
4427	// Possible values:
4428	//   "CSS_FONT_FACE"
4429	//   "CSS_BACKGROUND_SIZE"
4430	//   "CSS_BORDER_IMAGE"
4431	//   "CSS_BORDER_RADIUS"
4432	//   "CSS_BOX_SHADOW"
4433	//   "CSS_FLEX_BOX"
4434	//   "CSS_HSLA"
4435	//   "CSS_MULTIPLE_BGS"
4436	//   "CSS_OPACITY"
4437	//   "CSS_RGBA"
4438	//   "CSS_TEXT_SHADOW"
4439	//   "CSS_ANIMATIONS"
4440	//   "CSS_COLUMNS"
4441	//   "CSS_GENERATED_CONTENT"
4442	//   "CSS_GRADIENTS"
4443	//   "CSS_REFLECTIONS"
4444	//   "CSS_TRANSFORMS"
4445	//   "CSS_TRANSFORMS3D"
4446	//   "CSS_TRANSITIONS"
4447	//   "APPLICATION_CACHE"
4448	//   "CANVAS"
4449	//   "CANVAS_TEXT"
4450	//   "DRAG_AND_DROP"
4451	//   "HASH_CHANGE"
4452	//   "HISTORY"
4453	//   "AUDIO"
4454	//   "VIDEO"
4455	//   "INDEXED_DB"
4456	//   "INPUT_ATTR_AUTOCOMPLETE"
4457	//   "INPUT_ATTR_AUTOFOCUS"
4458	//   "INPUT_ATTR_LIST"
4459	//   "INPUT_ATTR_PLACEHOLDER"
4460	//   "INPUT_ATTR_MAX"
4461	//   "INPUT_ATTR_MIN"
4462	//   "INPUT_ATTR_MULTIPLE"
4463	//   "INPUT_ATTR_PATTERN"
4464	//   "INPUT_ATTR_REQUIRED"
4465	//   "INPUT_ATTR_STEP"
4466	//   "INPUT_TYPE_SEARCH"
4467	//   "INPUT_TYPE_TEL"
4468	//   "INPUT_TYPE_URL"
4469	//   "INPUT_TYPE_EMAIL"
4470	//   "INPUT_TYPE_DATETIME"
4471	//   "INPUT_TYPE_DATE"
4472	//   "INPUT_TYPE_MONTH"
4473	//   "INPUT_TYPE_WEEK"
4474	//   "INPUT_TYPE_TIME"
4475	//   "INPUT_TYPE_DATETIME_LOCAL"
4476	//   "INPUT_TYPE_NUMBER"
4477	//   "INPUT_TYPE_RANGE"
4478	//   "INPUT_TYPE_COLOR"
4479	//   "LOCAL_STORAGE"
4480	//   "POST_MESSAGE"
4481	//   "SESSION_STORAGE"
4482	//   "WEB_SOCKETS"
4483	//   "WEB_SQL_DATABASE"
4484	//   "WEB_WORKERS"
4485	//   "GEO_LOCATION"
4486	//   "INLINE_SVG"
4487	//   "SMIL"
4488	//   "SVG_HREF"
4489	//   "SVG_CLIP_PATHS"
4490	//   "TOUCH"
4491	//   "WEBGL"
4492	//   "SVG_FILTERS"
4493	//   "SVG_FE_IMAGE"
4494	DetectedFeatures []string `json:"detectedFeatures,omitempty"`
4495
4496	// DisplayType: Type of rich media asset. This is a read-only field.
4497	// Applicable to the following creative types: all RICH_MEDIA.
4498	//
4499	// Possible values:
4500	//   "ASSET_DISPLAY_TYPE_INPAGE"
4501	//   "ASSET_DISPLAY_TYPE_FLOATING"
4502	//   "ASSET_DISPLAY_TYPE_OVERLAY"
4503	//   "ASSET_DISPLAY_TYPE_EXPANDING"
4504	//   "ASSET_DISPLAY_TYPE_FLASH_IN_FLASH"
4505	//   "ASSET_DISPLAY_TYPE_FLASH_IN_FLASH_EXPANDING"
4506	//   "ASSET_DISPLAY_TYPE_PEEL_DOWN"
4507	//   "ASSET_DISPLAY_TYPE_VPAID_LINEAR"
4508	//   "ASSET_DISPLAY_TYPE_VPAID_NON_LINEAR"
4509	//   "ASSET_DISPLAY_TYPE_BACKDROP"
4510	DisplayType string `json:"displayType,omitempty"`
4511
4512	// Duration: Duration in seconds for which an asset will be displayed.
4513	// Applicable to the following creative types: INSTREAM_AUDIO,
4514	// INSTREAM_VIDEO and VPAID_LINEAR_VIDEO. Value must be greater than or
4515	// equal to 1.
4516	Duration int64 `json:"duration,omitempty"`
4517
4518	// DurationType: Duration type for which an asset will be displayed.
4519	// Applicable to the following creative types: all RICH_MEDIA.
4520	//
4521	// Possible values:
4522	//   "ASSET_DURATION_TYPE_AUTO"
4523	//   "ASSET_DURATION_TYPE_NONE"
4524	//   "ASSET_DURATION_TYPE_CUSTOM"
4525	DurationType string `json:"durationType,omitempty"`
4526
4527	// ExpandedDimension: Detected expanded dimension for video asset. This
4528	// is a read-only field. Applicable to the following creative types:
4529	// INSTREAM_VIDEO and all VPAID.
4530	ExpandedDimension *Size `json:"expandedDimension,omitempty"`
4531
4532	// FileSize: File size associated with this creative asset. This is a
4533	// read-only field. Applicable to all but the following creative types:
4534	// all REDIRECT and TRACKING_TEXT.
4535	FileSize int64 `json:"fileSize,omitempty,string"`
4536
4537	// FlashVersion: Flash version of the asset. This is a read-only field.
4538	// Applicable to the following creative types: FLASH_INPAGE, all
4539	// RICH_MEDIA, and all VPAID. Applicable to DISPLAY when the primary
4540	// asset type is not HTML_IMAGE.
4541	FlashVersion int64 `json:"flashVersion,omitempty"`
4542
4543	// FrameRate: Video frame rate for video asset in frames per second.
4544	// This is a read-only field. Applicable to the following creative
4545	// types: INSTREAM_VIDEO and all VPAID.
4546	FrameRate float64 `json:"frameRate,omitempty"`
4547
4548	// HideFlashObjects: Whether to hide Flash objects flag for an asset.
4549	// Applicable to the following creative types: all RICH_MEDIA.
4550	HideFlashObjects bool `json:"hideFlashObjects,omitempty"`
4551
4552	// HideSelectionBoxes: Whether to hide selection boxes flag for an
4553	// asset. Applicable to the following creative types: all RICH_MEDIA.
4554	HideSelectionBoxes bool `json:"hideSelectionBoxes,omitempty"`
4555
4556	// HorizontallyLocked: Whether the asset is horizontally locked. This is
4557	// a read-only field. Applicable to the following creative types: all
4558	// RICH_MEDIA.
4559	HorizontallyLocked bool `json:"horizontallyLocked,omitempty"`
4560
4561	// Id: Numeric ID of this creative asset. This is a required field and
4562	// should not be modified. Applicable to all but the following creative
4563	// types: all REDIRECT and TRACKING_TEXT.
4564	Id int64 `json:"id,omitempty,string"`
4565
4566	// IdDimensionValue: Dimension value for the ID of the asset. This is a
4567	// read-only, auto-generated field.
4568	IdDimensionValue *DimensionValue `json:"idDimensionValue,omitempty"`
4569
4570	// MediaDuration: Detected duration for audio or video asset. This is a
4571	// read-only field. Applicable to the following creative types:
4572	// INSTREAM_AUDIO, INSTREAM_VIDEO and all VPAID.
4573	MediaDuration float64 `json:"mediaDuration,omitempty"`
4574
4575	// MimeType: Detected MIME type for audio or video asset. This is a
4576	// read-only field. Applicable to the following creative types:
4577	// INSTREAM_AUDIO, INSTREAM_VIDEO and all VPAID.
4578	MimeType string `json:"mimeType,omitempty"`
4579
4580	// Offset: Offset position for an asset in collapsed mode. This is a
4581	// read-only field. Applicable to the following creative types: all
4582	// RICH_MEDIA and all VPAID. Additionally, only applicable to assets
4583	// whose displayType is ASSET_DISPLAY_TYPE_EXPANDING or
4584	// ASSET_DISPLAY_TYPE_PEEL_DOWN.
4585	Offset *OffsetPosition `json:"offset,omitempty"`
4586
4587	// Orientation: Orientation of video asset. This is a read-only,
4588	// auto-generated field.
4589	//
4590	// Possible values:
4591	//   "LANDSCAPE"
4592	//   "PORTRAIT"
4593	//   "SQUARE"
4594	Orientation string `json:"orientation,omitempty"`
4595
4596	// OriginalBackup: Whether the backup asset is original or changed by
4597	// the user in Campaign Manager. Applicable to the following creative
4598	// types: all RICH_MEDIA.
4599	OriginalBackup bool `json:"originalBackup,omitempty"`
4600
4601	// PoliteLoad: Whether this asset is used as a polite load asset.
4602	PoliteLoad bool `json:"politeLoad,omitempty"`
4603
4604	// Position: Offset position for an asset. Applicable to the following
4605	// creative types: all RICH_MEDIA.
4606	Position *OffsetPosition `json:"position,omitempty"`
4607
4608	// PositionLeftUnit: Offset left unit for an asset. This is a read-only
4609	// field. Applicable to the following creative types: all RICH_MEDIA.
4610	//
4611	// Possible values:
4612	//   "OFFSET_UNIT_PIXEL"
4613	//   "OFFSET_UNIT_PERCENT"
4614	//   "OFFSET_UNIT_PIXEL_FROM_CENTER"
4615	PositionLeftUnit string `json:"positionLeftUnit,omitempty"`
4616
4617	// PositionTopUnit: Offset top unit for an asset. This is a read-only
4618	// field if the asset displayType is ASSET_DISPLAY_TYPE_OVERLAY.
4619	// Applicable to the following creative types: all RICH_MEDIA.
4620	//
4621	// Possible values:
4622	//   "OFFSET_UNIT_PIXEL"
4623	//   "OFFSET_UNIT_PERCENT"
4624	//   "OFFSET_UNIT_PIXEL_FROM_CENTER"
4625	PositionTopUnit string `json:"positionTopUnit,omitempty"`
4626
4627	// ProgressiveServingUrl: Progressive URL for video asset. This is a
4628	// read-only field. Applicable to the following creative types:
4629	// INSTREAM_VIDEO and all VPAID.
4630	ProgressiveServingUrl string `json:"progressiveServingUrl,omitempty"`
4631
4632	// Pushdown: Whether the asset pushes down other content. Applicable to
4633	// the following creative types: all RICH_MEDIA. Additionally, only
4634	// applicable when the asset offsets are 0, the collapsedSize.width
4635	// matches size.width, and the collapsedSize.height is less than
4636	// size.height.
4637	Pushdown bool `json:"pushdown,omitempty"`
4638
4639	// PushdownDuration: Pushdown duration in seconds for an asset.
4640	// Applicable to the following creative types: all
4641	// RICH_MEDIA.Additionally, only applicable when the asset pushdown
4642	// field is true, the offsets are 0, the collapsedSize.width matches
4643	// size.width, and the collapsedSize.height is less than size.height.
4644	// Acceptable values are 0 to 9.99, inclusive.
4645	PushdownDuration float64 `json:"pushdownDuration,omitempty"`
4646
4647	// Role: Role of the asset in relation to creative. Applicable to all
4648	// but the following creative types: all REDIRECT and TRACKING_TEXT.
4649	// This is a required field. PRIMARY applies to DISPLAY, FLASH_INPAGE,
4650	// HTML5_BANNER, IMAGE, DISPLAY_IMAGE_GALLERY, all RICH_MEDIA (which may
4651	// contain multiple primary assets), and all VPAID creatives.
4652	// BACKUP_IMAGE applies to FLASH_INPAGE, HTML5_BANNER, all RICH_MEDIA,
4653	// and all VPAID creatives. Applicable to DISPLAY when the primary asset
4654	// type is not HTML_IMAGE. ADDITIONAL_IMAGE and ADDITIONAL_FLASH apply
4655	// to FLASH_INPAGE creatives. OTHER refers to assets from sources other
4656	// than Campaign Manager, such as Studio uploaded assets, applicable to
4657	// all RICH_MEDIA and all VPAID creatives. PARENT_VIDEO refers to videos
4658	// uploaded by the user in Campaign Manager and is applicable to
4659	// INSTREAM_VIDEO and VPAID_LINEAR_VIDEO creatives. TRANSCODED_VIDEO
4660	// refers to videos transcoded by Campaign Manager from PARENT_VIDEO
4661	// assets and is applicable to INSTREAM_VIDEO and VPAID_LINEAR_VIDEO
4662	// creatives. ALTERNATE_VIDEO refers to the Campaign Manager
4663	// representation of child asset videos from Studio, and is applicable
4664	// to VPAID_LINEAR_VIDEO creatives. These cannot be added or removed
4665	// within Campaign Manager. For VPAID_LINEAR_VIDEO creatives,
4666	// PARENT_VIDEO, TRANSCODED_VIDEO and ALTERNATE_VIDEO assets that are
4667	// marked active serve as backup in case the VPAID creative cannot be
4668	// served. Only PARENT_VIDEO assets can be added or removed for an
4669	// INSTREAM_VIDEO or VPAID_LINEAR_VIDEO creative. PARENT_AUDIO refers to
4670	// audios uploaded by the user in Campaign Manager and is applicable to
4671	// INSTREAM_AUDIO creatives. TRANSCODED_AUDIO refers to audios
4672	// transcoded by Campaign Manager from PARENT_AUDIO assets and is
4673	// applicable to INSTREAM_AUDIO creatives.
4674	//
4675	// Possible values:
4676	//   "PRIMARY"
4677	//   "BACKUP_IMAGE"
4678	//   "ADDITIONAL_IMAGE"
4679	//   "ADDITIONAL_FLASH"
4680	//   "PARENT_VIDEO"
4681	//   "TRANSCODED_VIDEO"
4682	//   "OTHER"
4683	//   "ALTERNATE_VIDEO"
4684	//   "PARENT_AUDIO"
4685	//   "TRANSCODED_AUDIO"
4686	Role string `json:"role,omitempty"`
4687
4688	// Size: Size associated with this creative asset. This is a required
4689	// field when applicable; however for IMAGE and FLASH_INPAGE, creatives
4690	// if left blank, this field will be automatically set using the actual
4691	// size of the associated image asset. Applicable to the following
4692	// creative types: DISPLAY_IMAGE_GALLERY, FLASH_INPAGE, HTML5_BANNER,
4693	// IMAGE, and all RICH_MEDIA. Applicable to DISPLAY when the primary
4694	// asset type is not HTML_IMAGE.
4695	Size *Size `json:"size,omitempty"`
4696
4697	// SslCompliant: Whether the asset is SSL-compliant. This is a read-only
4698	// field. Applicable to all but the following creative types: all
4699	// REDIRECT and TRACKING_TEXT.
4700	SslCompliant bool `json:"sslCompliant,omitempty"`
4701
4702	// StartTimeType: Initial wait time type before making the asset
4703	// visible. Applicable to the following creative types: all RICH_MEDIA.
4704	//
4705	// Possible values:
4706	//   "ASSET_START_TIME_TYPE_NONE"
4707	//   "ASSET_START_TIME_TYPE_CUSTOM"
4708	StartTimeType string `json:"startTimeType,omitempty"`
4709
4710	// StreamingServingUrl: Streaming URL for video asset. This is a
4711	// read-only field. Applicable to the following creative types:
4712	// INSTREAM_VIDEO and all VPAID.
4713	StreamingServingUrl string `json:"streamingServingUrl,omitempty"`
4714
4715	// Transparency: Whether the asset is transparent. Applicable to the
4716	// following creative types: all RICH_MEDIA. Additionally, only
4717	// applicable to HTML5 assets.
4718	Transparency bool `json:"transparency,omitempty"`
4719
4720	// VerticallyLocked: Whether the asset is vertically locked. This is a
4721	// read-only field. Applicable to the following creative types: all
4722	// RICH_MEDIA.
4723	VerticallyLocked bool `json:"verticallyLocked,omitempty"`
4724
4725	// WindowMode: Window mode options for flash assets. Applicable to the
4726	// following creative types: FLASH_INPAGE, RICH_MEDIA_DISPLAY_EXPANDING,
4727	// RICH_MEDIA_IM_EXPAND, RICH_MEDIA_DISPLAY_BANNER, and
4728	// RICH_MEDIA_INPAGE_FLOATING.
4729	//
4730	// Possible values:
4731	//   "OPAQUE"
4732	//   "WINDOW"
4733	//   "TRANSPARENT"
4734	WindowMode string `json:"windowMode,omitempty"`
4735
4736	// ZIndex: zIndex value of an asset. Applicable to the following
4737	// creative types: all RICH_MEDIA.Additionally, only applicable to
4738	// assets whose displayType is NOT one of the following types:
4739	// ASSET_DISPLAY_TYPE_INPAGE or ASSET_DISPLAY_TYPE_OVERLAY. Acceptable
4740	// values are -999999999 to 999999999, inclusive.
4741	ZIndex int64 `json:"zIndex,omitempty"`
4742
4743	// ZipFilename: File name of zip file. This is a read-only field.
4744	// Applicable to the following creative types: HTML5_BANNER.
4745	ZipFilename string `json:"zipFilename,omitempty"`
4746
4747	// ZipFilesize: Size of zip file. This is a read-only field. Applicable
4748	// to the following creative types: HTML5_BANNER.
4749	ZipFilesize string `json:"zipFilesize,omitempty"`
4750
4751	// ForceSendFields is a list of field names (e.g. "ActionScript3") to
4752	// unconditionally include in API requests. By default, fields with
4753	// empty or default values are omitted from API requests. However, any
4754	// non-pointer, non-interface field appearing in ForceSendFields will be
4755	// sent to the server regardless of whether the field is empty or not.
4756	// This may be used to include empty fields in Patch requests.
4757	ForceSendFields []string `json:"-"`
4758
4759	// NullFields is a list of field names (e.g. "ActionScript3") to include
4760	// in API requests with the JSON null value. By default, fields with
4761	// empty values are omitted from API requests. However, any field with
4762	// an empty value appearing in NullFields will be sent to the server as
4763	// null. It is an error if a field in this list has a non-empty value.
4764	// This may be used to include null fields in Patch requests.
4765	NullFields []string `json:"-"`
4766}
4767
4768func (s *CreativeAsset) MarshalJSON() ([]byte, error) {
4769	type NoMethod CreativeAsset
4770	raw := NoMethod(*s)
4771	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
4772}
4773
4774func (s *CreativeAsset) UnmarshalJSON(data []byte) error {
4775	type NoMethod CreativeAsset
4776	var s1 struct {
4777		FrameRate        gensupport.JSONFloat64 `json:"frameRate"`
4778		MediaDuration    gensupport.JSONFloat64 `json:"mediaDuration"`
4779		PushdownDuration gensupport.JSONFloat64 `json:"pushdownDuration"`
4780		*NoMethod
4781	}
4782	s1.NoMethod = (*NoMethod)(s)
4783	if err := json.Unmarshal(data, &s1); err != nil {
4784		return err
4785	}
4786	s.FrameRate = float64(s1.FrameRate)
4787	s.MediaDuration = float64(s1.MediaDuration)
4788	s.PushdownDuration = float64(s1.PushdownDuration)
4789	return nil
4790}
4791
4792// CreativeAssetId: Creative Asset ID.
4793type CreativeAssetId struct {
4794	// Name: Name of the creative asset. This is a required field while
4795	// inserting an asset. After insertion, this assetIdentifier is used to
4796	// identify the uploaded asset. Characters in the name must be
4797	// alphanumeric or one of the following: ".-_ ". Spaces are allowed.
4798	Name string `json:"name,omitempty"`
4799
4800	// Type: Type of asset to upload. This is a required field. FLASH and
4801	// IMAGE are no longer supported for new uploads. All image assets
4802	// should use HTML_IMAGE.
4803	//
4804	// Possible values:
4805	//   "IMAGE"
4806	//   "FLASH"
4807	//   "VIDEO"
4808	//   "HTML"
4809	//   "HTML_IMAGE"
4810	//   "AUDIO"
4811	Type string `json:"type,omitempty"`
4812
4813	// ForceSendFields is a list of field names (e.g. "Name") to
4814	// unconditionally include in API requests. By default, fields with
4815	// empty or default values are omitted from API requests. However, any
4816	// non-pointer, non-interface field appearing in ForceSendFields will be
4817	// sent to the server regardless of whether the field is empty or not.
4818	// This may be used to include empty fields in Patch requests.
4819	ForceSendFields []string `json:"-"`
4820
4821	// NullFields is a list of field names (e.g. "Name") to include in API
4822	// requests with the JSON null value. By default, fields with empty
4823	// values are omitted from API requests. However, any field with an
4824	// empty value appearing in NullFields will be sent to the server as
4825	// null. It is an error if a field in this list has a non-empty value.
4826	// This may be used to include null fields in Patch requests.
4827	NullFields []string `json:"-"`
4828}
4829
4830func (s *CreativeAssetId) MarshalJSON() ([]byte, error) {
4831	type NoMethod CreativeAssetId
4832	raw := NoMethod(*s)
4833	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
4834}
4835
4836// CreativeAssetMetadata: CreativeAssets contains properties of a
4837// creative asset file which will be uploaded or has already been
4838// uploaded. Refer to the creative sample code for how to upload assets
4839// and insert a creative.
4840type CreativeAssetMetadata struct {
4841	// AssetIdentifier: ID of the creative asset. This is a required field.
4842	AssetIdentifier *CreativeAssetId `json:"assetIdentifier,omitempty"`
4843
4844	// ClickTags: List of detected click tags for assets. This is a
4845	// read-only, auto-generated field. This field is empty for a rich media
4846	// asset.
4847	ClickTags []*ClickTag `json:"clickTags,omitempty"`
4848
4849	// CounterCustomEvents: List of counter events configured for the asset.
4850	// This is a read-only, auto-generated field and only applicable to a
4851	// rich media asset.
4852	CounterCustomEvents []*CreativeCustomEvent `json:"counterCustomEvents,omitempty"`
4853
4854	// DetectedFeatures: List of feature dependencies for the creative asset
4855	// that are detected by Campaign Manager. Feature dependencies are
4856	// features that a browser must be able to support in order to render
4857	// your HTML5 creative correctly. This is a read-only, auto-generated
4858	// field.
4859	//
4860	// Possible values:
4861	//   "CSS_FONT_FACE"
4862	//   "CSS_BACKGROUND_SIZE"
4863	//   "CSS_BORDER_IMAGE"
4864	//   "CSS_BORDER_RADIUS"
4865	//   "CSS_BOX_SHADOW"
4866	//   "CSS_FLEX_BOX"
4867	//   "CSS_HSLA"
4868	//   "CSS_MULTIPLE_BGS"
4869	//   "CSS_OPACITY"
4870	//   "CSS_RGBA"
4871	//   "CSS_TEXT_SHADOW"
4872	//   "CSS_ANIMATIONS"
4873	//   "CSS_COLUMNS"
4874	//   "CSS_GENERATED_CONTENT"
4875	//   "CSS_GRADIENTS"
4876	//   "CSS_REFLECTIONS"
4877	//   "CSS_TRANSFORMS"
4878	//   "CSS_TRANSFORMS3D"
4879	//   "CSS_TRANSITIONS"
4880	//   "APPLICATION_CACHE"
4881	//   "CANVAS"
4882	//   "CANVAS_TEXT"
4883	//   "DRAG_AND_DROP"
4884	//   "HASH_CHANGE"
4885	//   "HISTORY"
4886	//   "AUDIO"
4887	//   "VIDEO"
4888	//   "INDEXED_DB"
4889	//   "INPUT_ATTR_AUTOCOMPLETE"
4890	//   "INPUT_ATTR_AUTOFOCUS"
4891	//   "INPUT_ATTR_LIST"
4892	//   "INPUT_ATTR_PLACEHOLDER"
4893	//   "INPUT_ATTR_MAX"
4894	//   "INPUT_ATTR_MIN"
4895	//   "INPUT_ATTR_MULTIPLE"
4896	//   "INPUT_ATTR_PATTERN"
4897	//   "INPUT_ATTR_REQUIRED"
4898	//   "INPUT_ATTR_STEP"
4899	//   "INPUT_TYPE_SEARCH"
4900	//   "INPUT_TYPE_TEL"
4901	//   "INPUT_TYPE_URL"
4902	//   "INPUT_TYPE_EMAIL"
4903	//   "INPUT_TYPE_DATETIME"
4904	//   "INPUT_TYPE_DATE"
4905	//   "INPUT_TYPE_MONTH"
4906	//   "INPUT_TYPE_WEEK"
4907	//   "INPUT_TYPE_TIME"
4908	//   "INPUT_TYPE_DATETIME_LOCAL"
4909	//   "INPUT_TYPE_NUMBER"
4910	//   "INPUT_TYPE_RANGE"
4911	//   "INPUT_TYPE_COLOR"
4912	//   "LOCAL_STORAGE"
4913	//   "POST_MESSAGE"
4914	//   "SESSION_STORAGE"
4915	//   "WEB_SOCKETS"
4916	//   "WEB_SQL_DATABASE"
4917	//   "WEB_WORKERS"
4918	//   "GEO_LOCATION"
4919	//   "INLINE_SVG"
4920	//   "SMIL"
4921	//   "SVG_HREF"
4922	//   "SVG_CLIP_PATHS"
4923	//   "TOUCH"
4924	//   "WEBGL"
4925	//   "SVG_FILTERS"
4926	//   "SVG_FE_IMAGE"
4927	DetectedFeatures []string `json:"detectedFeatures,omitempty"`
4928
4929	// ExitCustomEvents: List of exit events configured for the asset. This
4930	// is a read-only, auto-generated field and only applicable to a rich
4931	// media asset.
4932	ExitCustomEvents []*CreativeCustomEvent `json:"exitCustomEvents,omitempty"`
4933
4934	// Id: Numeric ID of the asset. This is a read-only, auto-generated
4935	// field.
4936	Id int64 `json:"id,omitempty,string"`
4937
4938	// IdDimensionValue: Dimension value for the numeric ID of the asset.
4939	// This is a read-only, auto-generated field.
4940	IdDimensionValue *DimensionValue `json:"idDimensionValue,omitempty"`
4941
4942	// Kind: Identifies what kind of resource this is. Value: the fixed
4943	// string "dfareporting#creativeAssetMetadata".
4944	Kind string `json:"kind,omitempty"`
4945
4946	// RichMedia: True if the uploaded asset is a rich media asset. This is
4947	// a read-only, auto-generated field.
4948	RichMedia bool `json:"richMedia,omitempty"`
4949
4950	// TimerCustomEvents: List of timer events configured for the asset.
4951	// This is a read-only, auto-generated field and only applicable to a
4952	// rich media asset.
4953	TimerCustomEvents []*CreativeCustomEvent `json:"timerCustomEvents,omitempty"`
4954
4955	// WarnedValidationRules: Rules validated during code generation that
4956	// generated a warning. This is a read-only, auto-generated field.
4957	// Possible values are: - "ADMOB_REFERENCED" -
4958	// "ASSET_FORMAT_UNSUPPORTED_DCM" - "ASSET_INVALID" -
4959	// "CLICK_TAG_HARD_CODED" - "CLICK_TAG_INVALID" - "CLICK_TAG_IN_GWD" -
4960	// "CLICK_TAG_MISSING" - "CLICK_TAG_MORE_THAN_ONE" -
4961	// "CLICK_TAG_NON_TOP_LEVEL" - "COMPONENT_UNSUPPORTED_DCM" -
4962	// "ENABLER_UNSUPPORTED_METHOD_DCM" - "EXTERNAL_FILE_REFERENCED" -
4963	// "FILE_DETAIL_EMPTY" - "FILE_TYPE_INVALID" - "GWD_PROPERTIES_INVALID"
4964	// - "HTML5_FEATURE_UNSUPPORTED" - "LINKED_FILE_NOT_FOUND" -
4965	// "MAX_FLASH_VERSION_11" - "MRAID_REFERENCED" - "NOT_SSL_COMPLIANT" -
4966	// "ORPHANED_ASSET" - "PRIMARY_HTML_MISSING" - "SVG_INVALID" -
4967	// "ZIP_INVALID"
4968	//
4969	// Possible values:
4970	//   "CLICK_TAG_NON_TOP_LEVEL"
4971	//   "CLICK_TAG_MISSING"
4972	//   "CLICK_TAG_MORE_THAN_ONE"
4973	//   "CLICK_TAG_INVALID"
4974	//   "ORPHANED_ASSET"
4975	//   "PRIMARY_HTML_MISSING"
4976	//   "EXTERNAL_FILE_REFERENCED"
4977	//   "MRAID_REFERENCED"
4978	//   "ADMOB_REFERENCED"
4979	//   "FILE_TYPE_INVALID"
4980	//   "ZIP_INVALID"
4981	//   "LINKED_FILE_NOT_FOUND"
4982	//   "MAX_FLASH_VERSION_11"
4983	//   "NOT_SSL_COMPLIANT"
4984	//   "FILE_DETAIL_EMPTY"
4985	//   "ASSET_INVALID"
4986	//   "GWD_PROPERTIES_INVALID"
4987	//   "ENABLER_UNSUPPORTED_METHOD_DCM"
4988	//   "ASSET_FORMAT_UNSUPPORTED_DCM"
4989	//   "COMPONENT_UNSUPPORTED_DCM"
4990	//   "HTML5_FEATURE_UNSUPPORTED"
4991	//   "CLICK_TAG_IN_GWD"
4992	//   "CLICK_TAG_HARD_CODED"
4993	//   "SVG_INVALID"
4994	//   "CLICK_TAG_IN_RICH_MEDIA"
4995	WarnedValidationRules []string `json:"warnedValidationRules,omitempty"`
4996
4997	// ServerResponse contains the HTTP response code and headers from the
4998	// server.
4999	googleapi.ServerResponse `json:"-"`
5000
5001	// ForceSendFields is a list of field names (e.g. "AssetIdentifier") to
5002	// unconditionally include in API requests. By default, fields with
5003	// empty or default values are omitted from API requests. However, any
5004	// non-pointer, non-interface field appearing in ForceSendFields will be
5005	// sent to the server regardless of whether the field is empty or not.
5006	// This may be used to include empty fields in Patch requests.
5007	ForceSendFields []string `json:"-"`
5008
5009	// NullFields is a list of field names (e.g. "AssetIdentifier") to
5010	// include in API requests with the JSON null value. By default, fields
5011	// with empty values are omitted from API requests. However, any field
5012	// with an empty value appearing in NullFields will be sent to the
5013	// server as null. It is an error if a field in this list has a
5014	// non-empty value. This may be used to include null fields in Patch
5015	// requests.
5016	NullFields []string `json:"-"`
5017}
5018
5019func (s *CreativeAssetMetadata) MarshalJSON() ([]byte, error) {
5020	type NoMethod CreativeAssetMetadata
5021	raw := NoMethod(*s)
5022	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5023}
5024
5025// CreativeAssetSelection: Encapsulates the list of rules for asset
5026// selection and a default asset in case none of the rules match.
5027// Applicable to INSTREAM_VIDEO creatives.
5028type CreativeAssetSelection struct {
5029	// DefaultAssetId: A creativeAssets[].id. This should refer to one of
5030	// the parent assets in this creative, and will be served if none of the
5031	// rules match. This is a required field.
5032	DefaultAssetId int64 `json:"defaultAssetId,omitempty,string"`
5033
5034	// Rules: Rules determine which asset will be served to a viewer. Rules
5035	// will be evaluated in the order in which they are stored in this list.
5036	// This list must contain at least one rule. Applicable to
5037	// INSTREAM_VIDEO creatives.
5038	Rules []*Rule `json:"rules,omitempty"`
5039
5040	// ForceSendFields is a list of field names (e.g. "DefaultAssetId") to
5041	// unconditionally include in API requests. By default, fields with
5042	// empty or default values are omitted from API requests. However, any
5043	// non-pointer, non-interface field appearing in ForceSendFields will be
5044	// sent to the server regardless of whether the field is empty or not.
5045	// This may be used to include empty fields in Patch requests.
5046	ForceSendFields []string `json:"-"`
5047
5048	// NullFields is a list of field names (e.g. "DefaultAssetId") to
5049	// include in API requests with the JSON null value. By default, fields
5050	// with empty values are omitted from API requests. However, any field
5051	// with an empty value appearing in NullFields will be sent to the
5052	// server as null. It is an error if a field in this list has a
5053	// non-empty value. This may be used to include null fields in Patch
5054	// requests.
5055	NullFields []string `json:"-"`
5056}
5057
5058func (s *CreativeAssetSelection) MarshalJSON() ([]byte, error) {
5059	type NoMethod CreativeAssetSelection
5060	raw := NoMethod(*s)
5061	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5062}
5063
5064// CreativeAssignment: Creative Assignment.
5065type CreativeAssignment struct {
5066	// Active: Whether this creative assignment is active. When true, the
5067	// creative will be included in the ad's rotation.
5068	Active bool `json:"active,omitempty"`
5069
5070	// ApplyEventTags: Whether applicable event tags should fire when this
5071	// creative assignment is rendered. If this value is unset when the ad
5072	// is inserted or updated, it will default to true for all creative
5073	// types EXCEPT for INTERNAL_REDIRECT, INTERSTITIAL_INTERNAL_REDIRECT,
5074	// and INSTREAM_VIDEO.
5075	ApplyEventTags bool `json:"applyEventTags,omitempty"`
5076
5077	// ClickThroughUrl: Click-through URL of the creative assignment.
5078	ClickThroughUrl *ClickThroughUrl `json:"clickThroughUrl,omitempty"`
5079
5080	// CompanionCreativeOverrides: Companion creative overrides for this
5081	// creative assignment. Applicable to video ads.
5082	CompanionCreativeOverrides []*CompanionClickThroughOverride `json:"companionCreativeOverrides,omitempty"`
5083
5084	// CreativeGroupAssignments: Creative group assignments for this
5085	// creative assignment. Only one assignment per creative group number is
5086	// allowed for a maximum of two assignments.
5087	CreativeGroupAssignments []*CreativeGroupAssignment `json:"creativeGroupAssignments,omitempty"`
5088
5089	// CreativeId: ID of the creative to be assigned. This is a required
5090	// field.
5091	CreativeId int64 `json:"creativeId,omitempty,string"`
5092
5093	// CreativeIdDimensionValue: Dimension value for the ID of the creative.
5094	// This is a read-only, auto-generated field.
5095	CreativeIdDimensionValue *DimensionValue `json:"creativeIdDimensionValue,omitempty"`
5096
5097	EndTime string `json:"endTime,omitempty"`
5098
5099	// RichMediaExitOverrides: Rich media exit overrides for this creative
5100	// assignment. Applicable when the creative type is any of the
5101	// following: - DISPLAY - RICH_MEDIA_INPAGE - RICH_MEDIA_INPAGE_FLOATING
5102	// - RICH_MEDIA_IM_EXPAND - RICH_MEDIA_EXPANDING -
5103	// RICH_MEDIA_INTERSTITIAL_FLOAT - RICH_MEDIA_MOBILE_IN_APP -
5104	// RICH_MEDIA_MULTI_FLOATING - RICH_MEDIA_PEEL_DOWN - VPAID_LINEAR -
5105	// VPAID_NON_LINEAR
5106	RichMediaExitOverrides []*RichMediaExitOverride `json:"richMediaExitOverrides,omitempty"`
5107
5108	// Sequence: Sequence number of the creative assignment, applicable when
5109	// the rotation type is CREATIVE_ROTATION_TYPE_SEQUENTIAL. Acceptable
5110	// values are 1 to 65535, inclusive.
5111	Sequence int64 `json:"sequence,omitempty"`
5112
5113	// SslCompliant: Whether the creative to be assigned is SSL-compliant.
5114	// This is a read-only field that is auto-generated when the ad is
5115	// inserted or updated.
5116	SslCompliant bool `json:"sslCompliant,omitempty"`
5117
5118	StartTime string `json:"startTime,omitempty"`
5119
5120	// Weight: Weight of the creative assignment, applicable when the
5121	// rotation type is CREATIVE_ROTATION_TYPE_RANDOM. Value must be greater
5122	// than or equal to 1.
5123	Weight int64 `json:"weight,omitempty"`
5124
5125	// ForceSendFields is a list of field names (e.g. "Active") to
5126	// unconditionally include in API requests. By default, fields with
5127	// empty or default values are omitted from API requests. However, any
5128	// non-pointer, non-interface field appearing in ForceSendFields will be
5129	// sent to the server regardless of whether the field is empty or not.
5130	// This may be used to include empty fields in Patch requests.
5131	ForceSendFields []string `json:"-"`
5132
5133	// NullFields is a list of field names (e.g. "Active") to include in API
5134	// requests with the JSON null value. By default, fields with empty
5135	// values are omitted from API requests. However, any field with an
5136	// empty value appearing in NullFields will be sent to the server as
5137	// null. It is an error if a field in this list has a non-empty value.
5138	// This may be used to include null fields in Patch requests.
5139	NullFields []string `json:"-"`
5140}
5141
5142func (s *CreativeAssignment) MarshalJSON() ([]byte, error) {
5143	type NoMethod CreativeAssignment
5144	raw := NoMethod(*s)
5145	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5146}
5147
5148// CreativeClickThroughUrl: Click-through URL
5149type CreativeClickThroughUrl struct {
5150	// ComputedClickThroughUrl: Read-only convenience field representing the
5151	// actual URL that will be used for this click-through. The URL is
5152	// computed as follows: - If landingPageId is specified then that
5153	// landing page's URL is assigned to this field. - Otherwise, the
5154	// customClickThroughUrl is assigned to this field.
5155	ComputedClickThroughUrl string `json:"computedClickThroughUrl,omitempty"`
5156
5157	// CustomClickThroughUrl: Custom click-through URL. Applicable if the
5158	// landingPageId field is left unset.
5159	CustomClickThroughUrl string `json:"customClickThroughUrl,omitempty"`
5160
5161	// LandingPageId: ID of the landing page for the click-through URL.
5162	LandingPageId int64 `json:"landingPageId,omitempty,string"`
5163
5164	// ForceSendFields is a list of field names (e.g.
5165	// "ComputedClickThroughUrl") to unconditionally include in API
5166	// requests. By default, fields with empty or default values are omitted
5167	// from API requests. However, any non-pointer, non-interface field
5168	// appearing in ForceSendFields will be sent to the server regardless of
5169	// whether the field is empty or not. This may be used to include empty
5170	// fields in Patch requests.
5171	ForceSendFields []string `json:"-"`
5172
5173	// NullFields is a list of field names (e.g. "ComputedClickThroughUrl")
5174	// to include in API requests with the JSON null value. By default,
5175	// fields with empty values are omitted from API requests. However, any
5176	// field with an empty value appearing in NullFields will be sent to the
5177	// server as null. It is an error if a field in this list has a
5178	// non-empty value. This may be used to include null fields in Patch
5179	// requests.
5180	NullFields []string `json:"-"`
5181}
5182
5183func (s *CreativeClickThroughUrl) MarshalJSON() ([]byte, error) {
5184	type NoMethod CreativeClickThroughUrl
5185	raw := NoMethod(*s)
5186	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5187}
5188
5189// CreativeCustomEvent: Creative Custom Event.
5190type CreativeCustomEvent struct {
5191	// AdvertiserCustomEventId: Unique ID of this event used by Reporting
5192	// and Data Transfer. This is a read-only field.
5193	AdvertiserCustomEventId int64 `json:"advertiserCustomEventId,omitempty,string"`
5194
5195	// AdvertiserCustomEventName: User-entered name for the event.
5196	AdvertiserCustomEventName string `json:"advertiserCustomEventName,omitempty"`
5197
5198	// AdvertiserCustomEventType: Type of the event. This is a read-only
5199	// field.
5200	//
5201	// Possible values:
5202	//   "ADVERTISER_EVENT_TIMER"
5203	//   "ADVERTISER_EVENT_EXIT"
5204	//   "ADVERTISER_EVENT_COUNTER"
5205	AdvertiserCustomEventType string `json:"advertiserCustomEventType,omitempty"`
5206
5207	// ArtworkLabel: Artwork label column, used to link events in Campaign
5208	// Manager back to events in Studio. This is a required field and should
5209	// not be modified after insertion.
5210	ArtworkLabel string `json:"artworkLabel,omitempty"`
5211
5212	// ArtworkType: Artwork type used by the creative.This is a read-only
5213	// field.
5214	//
5215	// Possible values:
5216	//   "ARTWORK_TYPE_FLASH"
5217	//   "ARTWORK_TYPE_HTML5"
5218	//   "ARTWORK_TYPE_MIXED"
5219	//   "ARTWORK_TYPE_IMAGE"
5220	ArtworkType string `json:"artworkType,omitempty"`
5221
5222	// ExitClickThroughUrl: Exit click-through URL for the event. This field
5223	// is used only for exit events.
5224	ExitClickThroughUrl *CreativeClickThroughUrl `json:"exitClickThroughUrl,omitempty"`
5225
5226	// Id: ID of this event. This is a required field and should not be
5227	// modified after insertion.
5228	Id int64 `json:"id,omitempty,string"`
5229
5230	// PopupWindowProperties: Properties for rich media popup windows. This
5231	// field is used only for exit events.
5232	PopupWindowProperties *PopupWindowProperties `json:"popupWindowProperties,omitempty"`
5233
5234	// TargetType: Target type used by the event.
5235	//
5236	// Possible values:
5237	//   "TARGET_BLANK"
5238	//   "TARGET_TOP"
5239	//   "TARGET_SELF"
5240	//   "TARGET_PARENT"
5241	//   "TARGET_POPUP"
5242	TargetType string `json:"targetType,omitempty"`
5243
5244	// VideoReportingId: Video reporting ID, used to differentiate multiple
5245	// videos in a single creative. This is a read-only field.
5246	VideoReportingId string `json:"videoReportingId,omitempty"`
5247
5248	// ForceSendFields is a list of field names (e.g.
5249	// "AdvertiserCustomEventId") to unconditionally include in API
5250	// requests. By default, fields with empty or default values are omitted
5251	// from API requests. However, any non-pointer, non-interface field
5252	// appearing in ForceSendFields will be sent to the server regardless of
5253	// whether the field is empty or not. This may be used to include empty
5254	// fields in Patch requests.
5255	ForceSendFields []string `json:"-"`
5256
5257	// NullFields is a list of field names (e.g. "AdvertiserCustomEventId")
5258	// to include in API requests with the JSON null value. By default,
5259	// fields with empty values are omitted from API requests. However, any
5260	// field with an empty value appearing in NullFields will be sent to the
5261	// server as null. It is an error if a field in this list has a
5262	// non-empty value. This may be used to include null fields in Patch
5263	// requests.
5264	NullFields []string `json:"-"`
5265}
5266
5267func (s *CreativeCustomEvent) MarshalJSON() ([]byte, error) {
5268	type NoMethod CreativeCustomEvent
5269	raw := NoMethod(*s)
5270	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5271}
5272
5273// CreativeField: Contains properties of a creative field.
5274type CreativeField struct {
5275	// AccountId: Account ID of this creative field. This is a read-only
5276	// field that can be left blank.
5277	AccountId int64 `json:"accountId,omitempty,string"`
5278
5279	// AdvertiserId: Advertiser ID of this creative field. This is a
5280	// required field on insertion.
5281	AdvertiserId int64 `json:"advertiserId,omitempty,string"`
5282
5283	// AdvertiserIdDimensionValue: Dimension value for the ID of the
5284	// advertiser. This is a read-only, auto-generated field.
5285	AdvertiserIdDimensionValue *DimensionValue `json:"advertiserIdDimensionValue,omitempty"`
5286
5287	// Id: ID of this creative field. This is a read-only, auto-generated
5288	// field.
5289	Id int64 `json:"id,omitempty,string"`
5290
5291	// Kind: Identifies what kind of resource this is. Value: the fixed
5292	// string "dfareporting#creativeField".
5293	Kind string `json:"kind,omitempty"`
5294
5295	// Name: Name of this creative field. This is a required field and must
5296	// be less than 256 characters long and unique among creative fields of
5297	// the same advertiser.
5298	Name string `json:"name,omitempty"`
5299
5300	// SubaccountId: Subaccount ID of this creative field. This is a
5301	// read-only field that can be left blank.
5302	SubaccountId int64 `json:"subaccountId,omitempty,string"`
5303
5304	// ServerResponse contains the HTTP response code and headers from the
5305	// server.
5306	googleapi.ServerResponse `json:"-"`
5307
5308	// ForceSendFields is a list of field names (e.g. "AccountId") to
5309	// unconditionally include in API requests. By default, fields with
5310	// empty or default values are omitted from API requests. However, any
5311	// non-pointer, non-interface field appearing in ForceSendFields will be
5312	// sent to the server regardless of whether the field is empty or not.
5313	// This may be used to include empty fields in Patch requests.
5314	ForceSendFields []string `json:"-"`
5315
5316	// NullFields is a list of field names (e.g. "AccountId") to include in
5317	// API requests with the JSON null value. By default, fields with empty
5318	// values are omitted from API requests. However, any field with an
5319	// empty value appearing in NullFields will be sent to the server as
5320	// null. It is an error if a field in this list has a non-empty value.
5321	// This may be used to include null fields in Patch requests.
5322	NullFields []string `json:"-"`
5323}
5324
5325func (s *CreativeField) MarshalJSON() ([]byte, error) {
5326	type NoMethod CreativeField
5327	raw := NoMethod(*s)
5328	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5329}
5330
5331// CreativeFieldAssignment: Creative Field Assignment.
5332type CreativeFieldAssignment struct {
5333	// CreativeFieldId: ID of the creative field.
5334	CreativeFieldId int64 `json:"creativeFieldId,omitempty,string"`
5335
5336	// CreativeFieldValueId: ID of the creative field value.
5337	CreativeFieldValueId int64 `json:"creativeFieldValueId,omitempty,string"`
5338
5339	// ForceSendFields is a list of field names (e.g. "CreativeFieldId") to
5340	// unconditionally include in API requests. By default, fields with
5341	// empty or default values are omitted from API requests. However, any
5342	// non-pointer, non-interface field appearing in ForceSendFields will be
5343	// sent to the server regardless of whether the field is empty or not.
5344	// This may be used to include empty fields in Patch requests.
5345	ForceSendFields []string `json:"-"`
5346
5347	// NullFields is a list of field names (e.g. "CreativeFieldId") to
5348	// include in API requests with the JSON null value. By default, fields
5349	// with empty values are omitted from API requests. However, any field
5350	// with an empty value appearing in NullFields will be sent to the
5351	// server as null. It is an error if a field in this list has a
5352	// non-empty value. This may be used to include null fields in Patch
5353	// requests.
5354	NullFields []string `json:"-"`
5355}
5356
5357func (s *CreativeFieldAssignment) MarshalJSON() ([]byte, error) {
5358	type NoMethod CreativeFieldAssignment
5359	raw := NoMethod(*s)
5360	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5361}
5362
5363// CreativeFieldValue: Contains properties of a creative field value.
5364type CreativeFieldValue struct {
5365	// Id: ID of this creative field value. This is a read-only,
5366	// auto-generated field.
5367	Id int64 `json:"id,omitempty,string"`
5368
5369	// Kind: Identifies what kind of resource this is. Value: the fixed
5370	// string "dfareporting#creativeFieldValue".
5371	Kind string `json:"kind,omitempty"`
5372
5373	// Value: Value of this creative field value. It needs to be less than
5374	// 256 characters in length and unique per creative field.
5375	Value string `json:"value,omitempty"`
5376
5377	// ServerResponse contains the HTTP response code and headers from the
5378	// server.
5379	googleapi.ServerResponse `json:"-"`
5380
5381	// ForceSendFields is a list of field names (e.g. "Id") to
5382	// unconditionally include in API requests. By default, fields with
5383	// empty or default values are omitted from API requests. However, any
5384	// non-pointer, non-interface field appearing in ForceSendFields will be
5385	// sent to the server regardless of whether the field is empty or not.
5386	// This may be used to include empty fields in Patch requests.
5387	ForceSendFields []string `json:"-"`
5388
5389	// NullFields is a list of field names (e.g. "Id") to include in API
5390	// requests with the JSON null value. By default, fields with empty
5391	// values are omitted from API requests. However, any field with an
5392	// empty value appearing in NullFields will be sent to the server as
5393	// null. It is an error if a field in this list has a non-empty value.
5394	// This may be used to include null fields in Patch requests.
5395	NullFields []string `json:"-"`
5396}
5397
5398func (s *CreativeFieldValue) MarshalJSON() ([]byte, error) {
5399	type NoMethod CreativeFieldValue
5400	raw := NoMethod(*s)
5401	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5402}
5403
5404// CreativeFieldValuesListResponse: Creative Field Value List Response
5405type CreativeFieldValuesListResponse struct {
5406	// CreativeFieldValues: Creative field value collection.
5407	CreativeFieldValues []*CreativeFieldValue `json:"creativeFieldValues,omitempty"`
5408
5409	// Kind: Identifies what kind of resource this is. Value: the fixed
5410	// string "dfareporting#creativeFieldValuesListResponse".
5411	Kind string `json:"kind,omitempty"`
5412
5413	// NextPageToken: Pagination token to be used for the next list
5414	// operation.
5415	NextPageToken string `json:"nextPageToken,omitempty"`
5416
5417	// ServerResponse contains the HTTP response code and headers from the
5418	// server.
5419	googleapi.ServerResponse `json:"-"`
5420
5421	// ForceSendFields is a list of field names (e.g. "CreativeFieldValues")
5422	// to unconditionally include in API requests. By default, fields with
5423	// empty or default values are omitted from API requests. However, any
5424	// non-pointer, non-interface field appearing in ForceSendFields will be
5425	// sent to the server regardless of whether the field is empty or not.
5426	// This may be used to include empty fields in Patch requests.
5427	ForceSendFields []string `json:"-"`
5428
5429	// NullFields is a list of field names (e.g. "CreativeFieldValues") to
5430	// include in API requests with the JSON null value. By default, fields
5431	// with empty values are omitted from API requests. However, any field
5432	// with an empty value appearing in NullFields will be sent to the
5433	// server as null. It is an error if a field in this list has a
5434	// non-empty value. This may be used to include null fields in Patch
5435	// requests.
5436	NullFields []string `json:"-"`
5437}
5438
5439func (s *CreativeFieldValuesListResponse) MarshalJSON() ([]byte, error) {
5440	type NoMethod CreativeFieldValuesListResponse
5441	raw := NoMethod(*s)
5442	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5443}
5444
5445// CreativeFieldsListResponse: Creative Field List Response
5446type CreativeFieldsListResponse struct {
5447	// CreativeFields: Creative field collection.
5448	CreativeFields []*CreativeField `json:"creativeFields,omitempty"`
5449
5450	// Kind: Identifies what kind of resource this is. Value: the fixed
5451	// string "dfareporting#creativeFieldsListResponse".
5452	Kind string `json:"kind,omitempty"`
5453
5454	// NextPageToken: Pagination token to be used for the next list
5455	// operation.
5456	NextPageToken string `json:"nextPageToken,omitempty"`
5457
5458	// ServerResponse contains the HTTP response code and headers from the
5459	// server.
5460	googleapi.ServerResponse `json:"-"`
5461
5462	// ForceSendFields is a list of field names (e.g. "CreativeFields") to
5463	// unconditionally include in API requests. By default, fields with
5464	// empty or default values are omitted from API requests. However, any
5465	// non-pointer, non-interface field appearing in ForceSendFields will be
5466	// sent to the server regardless of whether the field is empty or not.
5467	// This may be used to include empty fields in Patch requests.
5468	ForceSendFields []string `json:"-"`
5469
5470	// NullFields is a list of field names (e.g. "CreativeFields") to
5471	// include in API requests with the JSON null value. By default, fields
5472	// with empty values are omitted from API requests. However, any field
5473	// with an empty value appearing in NullFields will be sent to the
5474	// server as null. It is an error if a field in this list has a
5475	// non-empty value. This may be used to include null fields in Patch
5476	// requests.
5477	NullFields []string `json:"-"`
5478}
5479
5480func (s *CreativeFieldsListResponse) MarshalJSON() ([]byte, error) {
5481	type NoMethod CreativeFieldsListResponse
5482	raw := NoMethod(*s)
5483	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5484}
5485
5486// CreativeGroup: Contains properties of a creative group.
5487type CreativeGroup struct {
5488	// AccountId: Account ID of this creative group. This is a read-only
5489	// field that can be left blank.
5490	AccountId int64 `json:"accountId,omitempty,string"`
5491
5492	// AdvertiserId: Advertiser ID of this creative group. This is a
5493	// required field on insertion.
5494	AdvertiserId int64 `json:"advertiserId,omitempty,string"`
5495
5496	// AdvertiserIdDimensionValue: Dimension value for the ID of the
5497	// advertiser. This is a read-only, auto-generated field.
5498	AdvertiserIdDimensionValue *DimensionValue `json:"advertiserIdDimensionValue,omitempty"`
5499
5500	// GroupNumber: Subgroup of the creative group. Assign your creative
5501	// groups to a subgroup in order to filter or manage them more easily.
5502	// This field is required on insertion and is read-only after insertion.
5503	// Acceptable values are 1 to 2, inclusive.
5504	GroupNumber int64 `json:"groupNumber,omitempty"`
5505
5506	// Id: ID of this creative group. This is a read-only, auto-generated
5507	// field.
5508	Id int64 `json:"id,omitempty,string"`
5509
5510	// Kind: Identifies what kind of resource this is. Value: the fixed
5511	// string "dfareporting#creativeGroup".
5512	Kind string `json:"kind,omitempty"`
5513
5514	// Name: Name of this creative group. This is a required field and must
5515	// be less than 256 characters long and unique among creative groups of
5516	// the same advertiser.
5517	Name string `json:"name,omitempty"`
5518
5519	// SubaccountId: Subaccount ID of this creative group. This is a
5520	// read-only field that can be left blank.
5521	SubaccountId int64 `json:"subaccountId,omitempty,string"`
5522
5523	// ServerResponse contains the HTTP response code and headers from the
5524	// server.
5525	googleapi.ServerResponse `json:"-"`
5526
5527	// ForceSendFields is a list of field names (e.g. "AccountId") to
5528	// unconditionally include in API requests. By default, fields with
5529	// empty or default values are omitted from API requests. However, any
5530	// non-pointer, non-interface field appearing in ForceSendFields will be
5531	// sent to the server regardless of whether the field is empty or not.
5532	// This may be used to include empty fields in Patch requests.
5533	ForceSendFields []string `json:"-"`
5534
5535	// NullFields is a list of field names (e.g. "AccountId") to include in
5536	// API requests with the JSON null value. By default, fields with empty
5537	// values are omitted from API requests. However, any field with an
5538	// empty value appearing in NullFields will be sent to the server as
5539	// null. It is an error if a field in this list has a non-empty value.
5540	// This may be used to include null fields in Patch requests.
5541	NullFields []string `json:"-"`
5542}
5543
5544func (s *CreativeGroup) MarshalJSON() ([]byte, error) {
5545	type NoMethod CreativeGroup
5546	raw := NoMethod(*s)
5547	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5548}
5549
5550// CreativeGroupAssignment: Creative Group Assignment.
5551type CreativeGroupAssignment struct {
5552	// CreativeGroupId: ID of the creative group to be assigned.
5553	CreativeGroupId int64 `json:"creativeGroupId,omitempty,string"`
5554
5555	// CreativeGroupNumber: Creative group number of the creative group
5556	// assignment.
5557	//
5558	// Possible values:
5559	//   "CREATIVE_GROUP_ONE"
5560	//   "CREATIVE_GROUP_TWO"
5561	CreativeGroupNumber string `json:"creativeGroupNumber,omitempty"`
5562
5563	// ForceSendFields is a list of field names (e.g. "CreativeGroupId") to
5564	// unconditionally include in API requests. By default, fields with
5565	// empty or default values are omitted from API requests. However, any
5566	// non-pointer, non-interface field appearing in ForceSendFields will be
5567	// sent to the server regardless of whether the field is empty or not.
5568	// This may be used to include empty fields in Patch requests.
5569	ForceSendFields []string `json:"-"`
5570
5571	// NullFields is a list of field names (e.g. "CreativeGroupId") to
5572	// include in API requests with the JSON null value. By default, fields
5573	// with empty values are omitted from API requests. However, any field
5574	// with an empty value appearing in NullFields will be sent to the
5575	// server as null. It is an error if a field in this list has a
5576	// non-empty value. This may be used to include null fields in Patch
5577	// requests.
5578	NullFields []string `json:"-"`
5579}
5580
5581func (s *CreativeGroupAssignment) MarshalJSON() ([]byte, error) {
5582	type NoMethod CreativeGroupAssignment
5583	raw := NoMethod(*s)
5584	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5585}
5586
5587// CreativeGroupsListResponse: Creative Group List Response
5588type CreativeGroupsListResponse struct {
5589	// CreativeGroups: Creative group collection.
5590	CreativeGroups []*CreativeGroup `json:"creativeGroups,omitempty"`
5591
5592	// Kind: Identifies what kind of resource this is. Value: the fixed
5593	// string "dfareporting#creativeGroupsListResponse".
5594	Kind string `json:"kind,omitempty"`
5595
5596	// NextPageToken: Pagination token to be used for the next list
5597	// operation.
5598	NextPageToken string `json:"nextPageToken,omitempty"`
5599
5600	// ServerResponse contains the HTTP response code and headers from the
5601	// server.
5602	googleapi.ServerResponse `json:"-"`
5603
5604	// ForceSendFields is a list of field names (e.g. "CreativeGroups") to
5605	// unconditionally include in API requests. By default, fields with
5606	// empty or default values are omitted from API requests. However, any
5607	// non-pointer, non-interface field appearing in ForceSendFields will be
5608	// sent to the server regardless of whether the field is empty or not.
5609	// This may be used to include empty fields in Patch requests.
5610	ForceSendFields []string `json:"-"`
5611
5612	// NullFields is a list of field names (e.g. "CreativeGroups") to
5613	// include in API requests with the JSON null value. By default, fields
5614	// with empty values are omitted from API requests. However, any field
5615	// with an empty value appearing in NullFields will be sent to the
5616	// server as null. It is an error if a field in this list has a
5617	// non-empty value. This may be used to include null fields in Patch
5618	// requests.
5619	NullFields []string `json:"-"`
5620}
5621
5622func (s *CreativeGroupsListResponse) MarshalJSON() ([]byte, error) {
5623	type NoMethod CreativeGroupsListResponse
5624	raw := NoMethod(*s)
5625	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5626}
5627
5628// CreativeOptimizationConfiguration: Creative optimization settings.
5629type CreativeOptimizationConfiguration struct {
5630	// Id: ID of this creative optimization config. This field is
5631	// auto-generated when the campaign is inserted or updated. It can be
5632	// null for existing campaigns.
5633	Id int64 `json:"id,omitempty,string"`
5634
5635	// Name: Name of this creative optimization config. This is a required
5636	// field and must be less than 129 characters long.
5637	Name string `json:"name,omitempty"`
5638
5639	// OptimizationActivitys: List of optimization activities associated
5640	// with this configuration.
5641	OptimizationActivitys []*OptimizationActivity `json:"optimizationActivitys,omitempty"`
5642
5643	// OptimizationModel: Optimization model for this configuration.
5644	//
5645	// Possible values:
5646	//   "CLICK"
5647	//   "POST_CLICK"
5648	//   "POST_IMPRESSION"
5649	//   "POST_CLICK_AND_IMPRESSION"
5650	//   "VIDEO_COMPLETION"
5651	OptimizationModel string `json:"optimizationModel,omitempty"`
5652
5653	// ForceSendFields is a list of field names (e.g. "Id") to
5654	// unconditionally include in API requests. By default, fields with
5655	// empty or default values are omitted from API requests. However, any
5656	// non-pointer, non-interface field appearing in ForceSendFields will be
5657	// sent to the server regardless of whether the field is empty or not.
5658	// This may be used to include empty fields in Patch requests.
5659	ForceSendFields []string `json:"-"`
5660
5661	// NullFields is a list of field names (e.g. "Id") to include in API
5662	// requests with the JSON null value. By default, fields with empty
5663	// values are omitted from API requests. However, any field with an
5664	// empty value appearing in NullFields will be sent to the server as
5665	// null. It is an error if a field in this list has a non-empty value.
5666	// This may be used to include null fields in Patch requests.
5667	NullFields []string `json:"-"`
5668}
5669
5670func (s *CreativeOptimizationConfiguration) MarshalJSON() ([]byte, error) {
5671	type NoMethod CreativeOptimizationConfiguration
5672	raw := NoMethod(*s)
5673	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5674}
5675
5676// CreativeRotation: Creative Rotation.
5677type CreativeRotation struct {
5678	// CreativeAssignments: Creative assignments in this creative rotation.
5679	CreativeAssignments []*CreativeAssignment `json:"creativeAssignments,omitempty"`
5680
5681	// CreativeOptimizationConfigurationId: Creative optimization
5682	// configuration that is used by this ad. It should refer to one of the
5683	// existing optimization configurations in the ad's campaign. If it is
5684	// unset or set to 0, then the campaign's default optimization
5685	// configuration will be used for this ad.
5686	CreativeOptimizationConfigurationId int64 `json:"creativeOptimizationConfigurationId,omitempty,string"`
5687
5688	// Type: Type of creative rotation. Can be used to specify whether to
5689	// use sequential or random rotation.
5690	//
5691	// Possible values:
5692	//   "CREATIVE_ROTATION_TYPE_SEQUENTIAL"
5693	//   "CREATIVE_ROTATION_TYPE_RANDOM"
5694	Type string `json:"type,omitempty"`
5695
5696	// WeightCalculationStrategy: Strategy for calculating weights. Used
5697	// with CREATIVE_ROTATION_TYPE_RANDOM.
5698	//
5699	// Possible values:
5700	//   "WEIGHT_STRATEGY_EQUAL"
5701	//   "WEIGHT_STRATEGY_CUSTOM"
5702	//   "WEIGHT_STRATEGY_HIGHEST_CTR"
5703	//   "WEIGHT_STRATEGY_OPTIMIZED"
5704	WeightCalculationStrategy string `json:"weightCalculationStrategy,omitempty"`
5705
5706	// ForceSendFields is a list of field names (e.g. "CreativeAssignments")
5707	// to unconditionally include in API requests. By default, fields with
5708	// empty or default values are omitted from API requests. However, any
5709	// non-pointer, non-interface field appearing in ForceSendFields will be
5710	// sent to the server regardless of whether the field is empty or not.
5711	// This may be used to include empty fields in Patch requests.
5712	ForceSendFields []string `json:"-"`
5713
5714	// NullFields is a list of field names (e.g. "CreativeAssignments") to
5715	// include in API requests with the JSON null value. By default, fields
5716	// with empty values are omitted from API requests. However, any field
5717	// with an empty value appearing in NullFields will be sent to the
5718	// server as null. It is an error if a field in this list has a
5719	// non-empty value. This may be used to include null fields in Patch
5720	// requests.
5721	NullFields []string `json:"-"`
5722}
5723
5724func (s *CreativeRotation) MarshalJSON() ([]byte, error) {
5725	type NoMethod CreativeRotation
5726	raw := NoMethod(*s)
5727	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5728}
5729
5730// CreativesListResponse: Creative List Response
5731type CreativesListResponse struct {
5732	// Creatives: Creative collection.
5733	Creatives []*Creative `json:"creatives,omitempty"`
5734
5735	// Kind: Identifies what kind of resource this is. Value: the fixed
5736	// string "dfareporting#creativesListResponse".
5737	Kind string `json:"kind,omitempty"`
5738
5739	// NextPageToken: Pagination token to be used for the next list
5740	// operation.
5741	NextPageToken string `json:"nextPageToken,omitempty"`
5742
5743	// ServerResponse contains the HTTP response code and headers from the
5744	// server.
5745	googleapi.ServerResponse `json:"-"`
5746
5747	// ForceSendFields is a list of field names (e.g. "Creatives") to
5748	// unconditionally include in API requests. By default, fields with
5749	// empty or default values are omitted from API requests. However, any
5750	// non-pointer, non-interface field appearing in ForceSendFields will be
5751	// sent to the server regardless of whether the field is empty or not.
5752	// This may be used to include empty fields in Patch requests.
5753	ForceSendFields []string `json:"-"`
5754
5755	// NullFields is a list of field names (e.g. "Creatives") to include in
5756	// API requests with the JSON null value. By default, fields with empty
5757	// values are omitted from API requests. However, any field with an
5758	// empty value appearing in NullFields will be sent to the server as
5759	// null. It is an error if a field in this list has a non-empty value.
5760	// This may be used to include null fields in Patch requests.
5761	NullFields []string `json:"-"`
5762}
5763
5764func (s *CreativesListResponse) MarshalJSON() ([]byte, error) {
5765	type NoMethod CreativesListResponse
5766	raw := NoMethod(*s)
5767	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5768}
5769
5770// CrossDimensionReachReportCompatibleFields: Represents fields that are
5771// compatible to be selected for a report of type
5772// "CROSS_DIMENSION_REACH".
5773type CrossDimensionReachReportCompatibleFields struct {
5774	// Breakdown: Dimensions which are compatible to be selected in the
5775	// "breakdown" section of the report.
5776	Breakdown []*Dimension `json:"breakdown,omitempty"`
5777
5778	// DimensionFilters: Dimensions which are compatible to be selected in
5779	// the "dimensionFilters" section of the report.
5780	DimensionFilters []*Dimension `json:"dimensionFilters,omitempty"`
5781
5782	// Kind: The kind of resource this is, in this case
5783	// dfareporting#crossDimensionReachReportCompatibleFields.
5784	Kind string `json:"kind,omitempty"`
5785
5786	// Metrics: Metrics which are compatible to be selected in the
5787	// "metricNames" section of the report.
5788	Metrics []*Metric `json:"metrics,omitempty"`
5789
5790	// OverlapMetrics: Metrics which are compatible to be selected in the
5791	// "overlapMetricNames" section of the report.
5792	OverlapMetrics []*Metric `json:"overlapMetrics,omitempty"`
5793
5794	// ForceSendFields is a list of field names (e.g. "Breakdown") to
5795	// unconditionally include in API requests. By default, fields with
5796	// empty or default values are omitted from API requests. However, any
5797	// non-pointer, non-interface field appearing in ForceSendFields will be
5798	// sent to the server regardless of whether the field is empty or not.
5799	// This may be used to include empty fields in Patch requests.
5800	ForceSendFields []string `json:"-"`
5801
5802	// NullFields is a list of field names (e.g. "Breakdown") to include in
5803	// API requests with the JSON null value. By default, fields with empty
5804	// values are omitted from API requests. However, any field with an
5805	// empty value appearing in NullFields will be sent to the server as
5806	// null. It is an error if a field in this list has a non-empty value.
5807	// This may be used to include null fields in Patch requests.
5808	NullFields []string `json:"-"`
5809}
5810
5811func (s *CrossDimensionReachReportCompatibleFields) MarshalJSON() ([]byte, error) {
5812	type NoMethod CrossDimensionReachReportCompatibleFields
5813	raw := NoMethod(*s)
5814	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5815}
5816
5817// CustomEvent: Experimental feature (no support provided) A custom
5818// event represents a third party impression, a third party click, an
5819// annotation on a first party impression, or an annotation on a first
5820// party click.
5821type CustomEvent struct {
5822	// AnnotateClickEvent: Annotate a click event. This field is mutually
5823	// exclusive with insertEvent and annotateImpressionEvent. This or
5824	// insertEvent and annotateImpressionEvent is a required field.
5825	AnnotateClickEvent *CustomEventClickAnnotation `json:"annotateClickEvent,omitempty"`
5826
5827	// AnnotateImpressionEvent: Annotate an impression. This field is
5828	// mutually exclusive with insertEvent and annotateClickEvent. This or
5829	// insertEvent and annotateClickEvent is a required field.
5830	AnnotateImpressionEvent *CustomEventImpressionAnnotation `json:"annotateImpressionEvent,omitempty"`
5831
5832	// CustomVariables: Custom variables associated with the event.
5833	CustomVariables []*CustomVariable `json:"customVariables,omitempty"`
5834
5835	// EventType: The type of event. If INSERT, the fields in insertEvent
5836	// need to be populated. If ANNOTATE, the fields in either
5837	// annotateClickEvent or annotateImpressionEvent need to be populated.
5838	//
5839	// Possible values:
5840	//   "UNKNOWN"
5841	//   "INSERT"
5842	//   "ANNOTATE"
5843	EventType string `json:"eventType,omitempty"`
5844
5845	// FloodlightConfigurationId: Floodlight configuration ID of the
5846	// advertiser the event is linked to. This is a required field.
5847	FloodlightConfigurationId int64 `json:"floodlightConfigurationId,omitempty,string"`
5848
5849	// InsertEvent: Insert custom event. This field is mutually exclusive
5850	// with annotateClickEvent and annotateImpressionEvent. This or
5851	// annotateClickEvent and annotateImpressionEvent is a required field.
5852	InsertEvent *CustomEventInsert `json:"insertEvent,omitempty"`
5853
5854	// Kind: Identifies what kind of resource this is. Value: the fixed
5855	// string "dfareporting#customEvent".
5856	Kind string `json:"kind,omitempty"`
5857
5858	// Ordinal: The ordinal of this custom event. This is a required field.
5859	Ordinal string `json:"ordinal,omitempty"`
5860
5861	// TimestampMicros: The timestamp of this custom event, in Unix epoch
5862	// micros. This is a required field.
5863	TimestampMicros int64 `json:"timestampMicros,omitempty,string"`
5864
5865	// ForceSendFields is a list of field names (e.g. "AnnotateClickEvent")
5866	// to unconditionally include in API requests. By default, fields with
5867	// empty or default values are omitted from API requests. However, any
5868	// non-pointer, non-interface field appearing in ForceSendFields will be
5869	// sent to the server regardless of whether the field is empty or not.
5870	// This may be used to include empty fields in Patch requests.
5871	ForceSendFields []string `json:"-"`
5872
5873	// NullFields is a list of field names (e.g. "AnnotateClickEvent") to
5874	// include in API requests with the JSON null value. By default, fields
5875	// with empty values are omitted from API requests. However, any field
5876	// with an empty value appearing in NullFields will be sent to the
5877	// server as null. It is an error if a field in this list has a
5878	// non-empty value. This may be used to include null fields in Patch
5879	// requests.
5880	NullFields []string `json:"-"`
5881}
5882
5883func (s *CustomEvent) MarshalJSON() ([]byte, error) {
5884	type NoMethod CustomEvent
5885	raw := NoMethod(*s)
5886	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5887}
5888
5889// CustomEventClickAnnotation: Annotate a click event.
5890type CustomEventClickAnnotation struct {
5891	// Gclid: The Google click ID. Use this field to annotate the click
5892	// associated with the gclid.
5893	Gclid string `json:"gclid,omitempty"`
5894
5895	// Kind: Identifies what kind of resource this is. Value: the fixed
5896	// string "dfareporting#customEventClickAnnotation".
5897	Kind string `json:"kind,omitempty"`
5898
5899	// ForceSendFields is a list of field names (e.g. "Gclid") to
5900	// unconditionally include in API requests. By default, fields with
5901	// empty or default values are omitted from API requests. However, any
5902	// non-pointer, non-interface field appearing in ForceSendFields will be
5903	// sent to the server regardless of whether the field is empty or not.
5904	// This may be used to include empty fields in Patch requests.
5905	ForceSendFields []string `json:"-"`
5906
5907	// NullFields is a list of field names (e.g. "Gclid") to include in API
5908	// requests with the JSON null value. By default, fields with empty
5909	// values are omitted from API requests. However, any field with an
5910	// empty value appearing in NullFields will be sent to the server as
5911	// null. It is an error if a field in this list has a non-empty value.
5912	// This may be used to include null fields in Patch requests.
5913	NullFields []string `json:"-"`
5914}
5915
5916func (s *CustomEventClickAnnotation) MarshalJSON() ([]byte, error) {
5917	type NoMethod CustomEventClickAnnotation
5918	raw := NoMethod(*s)
5919	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5920}
5921
5922// CustomEventError: The error code and description for a custom event
5923// that failed to insert.
5924type CustomEventError struct {
5925	// Code: The error code.
5926	//
5927	// Possible values:
5928	//   "UNKNOWN"
5929	//   "INVALID_ARGUMENT"
5930	//   "INTERNAL"
5931	//   "PERMISSION_DENIED"
5932	//   "NOT_FOUND"
5933	Code string `json:"code,omitempty"`
5934
5935	// Kind: Identifies what kind of resource this is. Value: the fixed
5936	// string "dfareporting#customEventError".
5937	Kind string `json:"kind,omitempty"`
5938
5939	// Message: A description of the error.
5940	Message string `json:"message,omitempty"`
5941
5942	// ForceSendFields is a list of field names (e.g. "Code") to
5943	// unconditionally include in API requests. By default, fields with
5944	// empty or default values are omitted from API requests. However, any
5945	// non-pointer, non-interface field appearing in ForceSendFields will be
5946	// sent to the server regardless of whether the field is empty or not.
5947	// This may be used to include empty fields in Patch requests.
5948	ForceSendFields []string `json:"-"`
5949
5950	// NullFields is a list of field names (e.g. "Code") to include in API
5951	// requests with the JSON null value. By default, fields with empty
5952	// values are omitted from API requests. However, any field with an
5953	// empty value appearing in NullFields will be sent to the server as
5954	// null. It is an error if a field in this list has a non-empty value.
5955	// This may be used to include null fields in Patch requests.
5956	NullFields []string `json:"-"`
5957}
5958
5959func (s *CustomEventError) MarshalJSON() ([]byte, error) {
5960	type NoMethod CustomEventError
5961	raw := NoMethod(*s)
5962	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5963}
5964
5965// CustomEventImpressionAnnotation: Annotate an impression.
5966type CustomEventImpressionAnnotation struct {
5967	// Kind: Identifies what kind of resource this is. Value: the fixed
5968	// string "dfareporting#customEventImpressionAnnotation".
5969	Kind string `json:"kind,omitempty"`
5970
5971	// PathImpressionId: The path impression ID. Use this field to annotate
5972	// the impression associated with the pathImpressionId.
5973	PathImpressionId string `json:"pathImpressionId,omitempty"`
5974
5975	// ForceSendFields is a list of field names (e.g. "Kind") to
5976	// unconditionally include in API requests. By default, fields with
5977	// empty or default values are omitted from API requests. However, any
5978	// non-pointer, non-interface field appearing in ForceSendFields will be
5979	// sent to the server regardless of whether the field is empty or not.
5980	// This may be used to include empty fields in Patch requests.
5981	ForceSendFields []string `json:"-"`
5982
5983	// NullFields is a list of field names (e.g. "Kind") to include in API
5984	// requests with the JSON null value. By default, fields with empty
5985	// values are omitted from API requests. However, any field with an
5986	// empty value appearing in NullFields will be sent to the server as
5987	// null. It is an error if a field in this list has a non-empty value.
5988	// This may be used to include null fields in Patch requests.
5989	NullFields []string `json:"-"`
5990}
5991
5992func (s *CustomEventImpressionAnnotation) MarshalJSON() ([]byte, error) {
5993	type NoMethod CustomEventImpressionAnnotation
5994	raw := NoMethod(*s)
5995	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5996}
5997
5998// CustomEventInsert: Custom event to be inserted.
5999type CustomEventInsert struct {
6000	// CmDimensions: Campaign Manager dimensions associated with the event.
6001	CmDimensions *CampaignManagerIds `json:"cmDimensions,omitempty"`
6002
6003	// Dv3Dimensions: DV360 dimensions associated with the event.
6004	Dv3Dimensions *DV3Ids `json:"dv3Dimensions,omitempty"`
6005
6006	// InsertEventType: The type of event to insert.
6007	//
6008	// Possible values:
6009	//   "UNKNOWN"
6010	//   "IMPRESSION"
6011	//   "CLICK"
6012	InsertEventType string `json:"insertEventType,omitempty"`
6013
6014	// Kind: Identifies what kind of resource this is. Value: the fixed
6015	// string "dfareporting#customEventInsert".
6016	Kind string `json:"kind,omitempty"`
6017
6018	// MatchId: The match ID field. A match ID is your own first-party
6019	// identifier that has been synced with Google using the match ID
6020	// feature in Floodlight. This field is mutually exclusive with
6021	// mobileDeviceId, and at least one of the two fields is required.
6022	MatchId string `json:"matchId,omitempty"`
6023
6024	// MobileDeviceId: The mobile device ID. This field is mutually
6025	// exclusive with matchId, and at least one of the two fields is
6026	// required.
6027	MobileDeviceId string `json:"mobileDeviceId,omitempty"`
6028
6029	// ForceSendFields is a list of field names (e.g. "CmDimensions") to
6030	// unconditionally include in API requests. By default, fields with
6031	// empty or default values are omitted from API requests. However, any
6032	// non-pointer, non-interface field appearing in ForceSendFields will be
6033	// sent to the server regardless of whether the field is empty or not.
6034	// This may be used to include empty fields in Patch requests.
6035	ForceSendFields []string `json:"-"`
6036
6037	// NullFields is a list of field names (e.g. "CmDimensions") to include
6038	// in API requests with the JSON null value. By default, fields with
6039	// empty values are omitted from API requests. However, any field with
6040	// an empty value appearing in NullFields will be sent to the server as
6041	// null. It is an error if a field in this list has a non-empty value.
6042	// This may be used to include null fields in Patch requests.
6043	NullFields []string `json:"-"`
6044}
6045
6046func (s *CustomEventInsert) MarshalJSON() ([]byte, error) {
6047	type NoMethod CustomEventInsert
6048	raw := NoMethod(*s)
6049	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6050}
6051
6052// CustomEventStatus: The original custom event that was inserted and
6053// whether there were any errors.
6054type CustomEventStatus struct {
6055	// CustomEvent: The original custom event that was inserted.
6056	CustomEvent *CustomEvent `json:"customEvent,omitempty"`
6057
6058	// Errors: A list of errors related to this custom event.
6059	Errors []*CustomEventError `json:"errors,omitempty"`
6060
6061	// Kind: Identifies what kind of resource this is. Value: the fixed
6062	// string "dfareporting#customEventStatus".
6063	Kind string `json:"kind,omitempty"`
6064
6065	// ForceSendFields is a list of field names (e.g. "CustomEvent") to
6066	// unconditionally include in API requests. By default, fields with
6067	// empty or default values are omitted from API requests. However, any
6068	// non-pointer, non-interface field appearing in ForceSendFields will be
6069	// sent to the server regardless of whether the field is empty or not.
6070	// This may be used to include empty fields in Patch requests.
6071	ForceSendFields []string `json:"-"`
6072
6073	// NullFields is a list of field names (e.g. "CustomEvent") to include
6074	// in API requests with the JSON null value. By default, fields with
6075	// empty values are omitted from API requests. However, any field with
6076	// an empty value appearing in NullFields will be sent to the server as
6077	// null. It is an error if a field in this list has a non-empty value.
6078	// This may be used to include null fields in Patch requests.
6079	NullFields []string `json:"-"`
6080}
6081
6082func (s *CustomEventStatus) MarshalJSON() ([]byte, error) {
6083	type NoMethod CustomEventStatus
6084	raw := NoMethod(*s)
6085	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6086}
6087
6088// CustomEventsBatchInsertRequest: Insert Custom Events Request.
6089type CustomEventsBatchInsertRequest struct {
6090	// CustomEvents: The set of custom events to insert.
6091	CustomEvents []*CustomEvent `json:"customEvents,omitempty"`
6092
6093	// Kind: Identifies what kind of resource this is. Value: the fixed
6094	// string "dfareporting#customEventsBatchInsertRequest".
6095	Kind string `json:"kind,omitempty"`
6096
6097	// ForceSendFields is a list of field names (e.g. "CustomEvents") to
6098	// unconditionally include in API requests. By default, fields with
6099	// empty or default values are omitted from API requests. However, any
6100	// non-pointer, non-interface field appearing in ForceSendFields will be
6101	// sent to the server regardless of whether the field is empty or not.
6102	// This may be used to include empty fields in Patch requests.
6103	ForceSendFields []string `json:"-"`
6104
6105	// NullFields is a list of field names (e.g. "CustomEvents") to include
6106	// in API requests with the JSON null value. By default, fields with
6107	// empty values are omitted from API requests. However, any field with
6108	// an empty value appearing in NullFields will be sent to the server as
6109	// null. It is an error if a field in this list has a non-empty value.
6110	// This may be used to include null fields in Patch requests.
6111	NullFields []string `json:"-"`
6112}
6113
6114func (s *CustomEventsBatchInsertRequest) MarshalJSON() ([]byte, error) {
6115	type NoMethod CustomEventsBatchInsertRequest
6116	raw := NoMethod(*s)
6117	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6118}
6119
6120// CustomEventsBatchInsertResponse: Insert Custom Events Response.
6121type CustomEventsBatchInsertResponse struct {
6122	// HasFailures: Indicates that some or all custom events failed to
6123	// insert.
6124	HasFailures bool `json:"hasFailures,omitempty"`
6125
6126	// Kind: Identifies what kind of resource this is. Value: the fixed
6127	// string "dfareporting#customEventsBatchInsertResponse".
6128	Kind string `json:"kind,omitempty"`
6129
6130	// Status: The insert status of each custom event. Statuses are returned
6131	// in the same order that conversions are inserted.
6132	Status []*CustomEventStatus `json:"status,omitempty"`
6133
6134	// ServerResponse contains the HTTP response code and headers from the
6135	// server.
6136	googleapi.ServerResponse `json:"-"`
6137
6138	// ForceSendFields is a list of field names (e.g. "HasFailures") to
6139	// unconditionally include in API requests. By default, fields with
6140	// empty or default values are omitted from API requests. However, any
6141	// non-pointer, non-interface field appearing in ForceSendFields will be
6142	// sent to the server regardless of whether the field is empty or not.
6143	// This may be used to include empty fields in Patch requests.
6144	ForceSendFields []string `json:"-"`
6145
6146	// NullFields is a list of field names (e.g. "HasFailures") to include
6147	// in API requests with the JSON null value. By default, fields with
6148	// empty values are omitted from API requests. However, any field with
6149	// an empty value appearing in NullFields will be sent to the server as
6150	// null. It is an error if a field in this list has a non-empty value.
6151	// This may be used to include null fields in Patch requests.
6152	NullFields []string `json:"-"`
6153}
6154
6155func (s *CustomEventsBatchInsertResponse) MarshalJSON() ([]byte, error) {
6156	type NoMethod CustomEventsBatchInsertResponse
6157	raw := NoMethod(*s)
6158	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6159}
6160
6161// CustomFloodlightVariable: A custom floodlight variable.
6162type CustomFloodlightVariable struct {
6163	// Kind: Identifies what kind of resource this is. Value: the fixed
6164	// string "dfareporting#customFloodlightVariable".
6165	Kind string `json:"kind,omitempty"`
6166
6167	// Type: The type of custom floodlight variable to supply a value for.
6168	// These map to the "u[1-20]=" in the tags.
6169	//
6170	// Possible values:
6171	//   "U1"
6172	//   "U2"
6173	//   "U3"
6174	//   "U4"
6175	//   "U5"
6176	//   "U6"
6177	//   "U7"
6178	//   "U8"
6179	//   "U9"
6180	//   "U10"
6181	//   "U11"
6182	//   "U12"
6183	//   "U13"
6184	//   "U14"
6185	//   "U15"
6186	//   "U16"
6187	//   "U17"
6188	//   "U18"
6189	//   "U19"
6190	//   "U20"
6191	//   "U21"
6192	//   "U22"
6193	//   "U23"
6194	//   "U24"
6195	//   "U25"
6196	//   "U26"
6197	//   "U27"
6198	//   "U28"
6199	//   "U29"
6200	//   "U30"
6201	//   "U31"
6202	//   "U32"
6203	//   "U33"
6204	//   "U34"
6205	//   "U35"
6206	//   "U36"
6207	//   "U37"
6208	//   "U38"
6209	//   "U39"
6210	//   "U40"
6211	//   "U41"
6212	//   "U42"
6213	//   "U43"
6214	//   "U44"
6215	//   "U45"
6216	//   "U46"
6217	//   "U47"
6218	//   "U48"
6219	//   "U49"
6220	//   "U50"
6221	//   "U51"
6222	//   "U52"
6223	//   "U53"
6224	//   "U54"
6225	//   "U55"
6226	//   "U56"
6227	//   "U57"
6228	//   "U58"
6229	//   "U59"
6230	//   "U60"
6231	//   "U61"
6232	//   "U62"
6233	//   "U63"
6234	//   "U64"
6235	//   "U65"
6236	//   "U66"
6237	//   "U67"
6238	//   "U68"
6239	//   "U69"
6240	//   "U70"
6241	//   "U71"
6242	//   "U72"
6243	//   "U73"
6244	//   "U74"
6245	//   "U75"
6246	//   "U76"
6247	//   "U77"
6248	//   "U78"
6249	//   "U79"
6250	//   "U80"
6251	//   "U81"
6252	//   "U82"
6253	//   "U83"
6254	//   "U84"
6255	//   "U85"
6256	//   "U86"
6257	//   "U87"
6258	//   "U88"
6259	//   "U89"
6260	//   "U90"
6261	//   "U91"
6262	//   "U92"
6263	//   "U93"
6264	//   "U94"
6265	//   "U95"
6266	//   "U96"
6267	//   "U97"
6268	//   "U98"
6269	//   "U99"
6270	//   "U100"
6271	Type string `json:"type,omitempty"`
6272
6273	// Value: The value of the custom floodlight variable. The length of
6274	// string must not exceed 100 characters.
6275	Value string `json:"value,omitempty"`
6276
6277	// ForceSendFields is a list of field names (e.g. "Kind") to
6278	// unconditionally include in API requests. By default, fields with
6279	// empty or default values are omitted from API requests. However, any
6280	// non-pointer, non-interface field appearing in ForceSendFields will be
6281	// sent to the server regardless of whether the field is empty or not.
6282	// This may be used to include empty fields in Patch requests.
6283	ForceSendFields []string `json:"-"`
6284
6285	// NullFields is a list of field names (e.g. "Kind") to include in API
6286	// requests with the JSON null value. By default, fields with empty
6287	// values are omitted from API requests. However, any field with an
6288	// empty value appearing in NullFields will be sent to the server as
6289	// null. It is an error if a field in this list has a non-empty value.
6290	// This may be used to include null fields in Patch requests.
6291	NullFields []string `json:"-"`
6292}
6293
6294func (s *CustomFloodlightVariable) MarshalJSON() ([]byte, error) {
6295	type NoMethod CustomFloodlightVariable
6296	raw := NoMethod(*s)
6297	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6298}
6299
6300// CustomRichMediaEvents: Represents a Custom Rich Media Events group.
6301type CustomRichMediaEvents struct {
6302	// FilteredEventIds: List of custom rich media event IDs. Dimension
6303	// values must be all of type dfa:richMediaEventTypeIdAndName.
6304	FilteredEventIds []*DimensionValue `json:"filteredEventIds,omitempty"`
6305
6306	// Kind: The kind of resource this is, in this case
6307	// dfareporting#customRichMediaEvents.
6308	Kind string `json:"kind,omitempty"`
6309
6310	// ForceSendFields is a list of field names (e.g. "FilteredEventIds") to
6311	// unconditionally include in API requests. By default, fields with
6312	// empty or default values are omitted from API requests. However, any
6313	// non-pointer, non-interface field appearing in ForceSendFields will be
6314	// sent to the server regardless of whether the field is empty or not.
6315	// This may be used to include empty fields in Patch requests.
6316	ForceSendFields []string `json:"-"`
6317
6318	// NullFields is a list of field names (e.g. "FilteredEventIds") to
6319	// include in API requests with the JSON null value. By default, fields
6320	// with empty values are omitted from API requests. However, any field
6321	// with an empty value appearing in NullFields will be sent to the
6322	// server as null. It is an error if a field in this list has a
6323	// non-empty value. This may be used to include null fields in Patch
6324	// requests.
6325	NullFields []string `json:"-"`
6326}
6327
6328func (s *CustomRichMediaEvents) MarshalJSON() ([]byte, error) {
6329	type NoMethod CustomRichMediaEvents
6330	raw := NoMethod(*s)
6331	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6332}
6333
6334// CustomVariable: Custom variable.
6335type CustomVariable struct {
6336	// Index: The index of the custom variable.
6337	Index int64 `json:"index,omitempty,string"`
6338
6339	// Kind: Identifies what kind of resource this is. Value: the fixed
6340	// string "dfareporting#customVariable".
6341	Kind string `json:"kind,omitempty"`
6342
6343	// Value: The value of the custom variable. The length of string must
6344	// not exceed 50 characters.
6345	Value string `json:"value,omitempty"`
6346
6347	// ForceSendFields is a list of field names (e.g. "Index") to
6348	// unconditionally include in API requests. By default, fields with
6349	// empty or default values are omitted from API requests. However, any
6350	// non-pointer, non-interface field appearing in ForceSendFields will be
6351	// sent to the server regardless of whether the field is empty or not.
6352	// This may be used to include empty fields in Patch requests.
6353	ForceSendFields []string `json:"-"`
6354
6355	// NullFields is a list of field names (e.g. "Index") to include in API
6356	// requests with the JSON null value. By default, fields with empty
6357	// values are omitted from API requests. However, any field with an
6358	// empty value appearing in NullFields will be sent to the server as
6359	// null. It is an error if a field in this list has a non-empty value.
6360	// This may be used to include null fields in Patch requests.
6361	NullFields []string `json:"-"`
6362}
6363
6364func (s *CustomVariable) MarshalJSON() ([]byte, error) {
6365	type NoMethod CustomVariable
6366	raw := NoMethod(*s)
6367	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6368}
6369
6370// CustomViewabilityMetric: Custom Viewability Metric
6371type CustomViewabilityMetric struct {
6372	// Configuration: Configuration of the custom viewability metric.
6373	Configuration *CustomViewabilityMetricConfiguration `json:"configuration,omitempty"`
6374
6375	// Id: ID of the custom viewability metric.
6376	Id int64 `json:"id,omitempty,string"`
6377
6378	// Name: Name of the custom viewability metric.
6379	Name string `json:"name,omitempty"`
6380
6381	// ForceSendFields is a list of field names (e.g. "Configuration") to
6382	// unconditionally include in API requests. By default, fields with
6383	// empty or default values are omitted from API requests. However, any
6384	// non-pointer, non-interface field appearing in ForceSendFields will be
6385	// sent to the server regardless of whether the field is empty or not.
6386	// This may be used to include empty fields in Patch requests.
6387	ForceSendFields []string `json:"-"`
6388
6389	// NullFields is a list of field names (e.g. "Configuration") to include
6390	// in API requests with the JSON null value. By default, fields with
6391	// empty values are omitted from API requests. However, any field with
6392	// an empty value appearing in NullFields will be sent to the server as
6393	// null. It is an error if a field in this list has a non-empty value.
6394	// This may be used to include null fields in Patch requests.
6395	NullFields []string `json:"-"`
6396}
6397
6398func (s *CustomViewabilityMetric) MarshalJSON() ([]byte, error) {
6399	type NoMethod CustomViewabilityMetric
6400	raw := NoMethod(*s)
6401	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6402}
6403
6404// CustomViewabilityMetricConfiguration: The attributes, like playtime
6405// and percent onscreen, that define the Custom Viewability Metric.
6406type CustomViewabilityMetricConfiguration struct {
6407	// Audible: Whether the video must be audible to count an impression.
6408	Audible bool `json:"audible,omitempty"`
6409
6410	// TimeMillis: The time in milliseconds the video must play for the
6411	// Custom Viewability Metric to count an impression. If both this and
6412	// timePercent are specified, the earlier of the two will be used.
6413	TimeMillis int64 `json:"timeMillis,omitempty"`
6414
6415	// TimePercent: The percentage of video that must play for the Custom
6416	// Viewability Metric to count an impression. If both this and
6417	// timeMillis are specified, the earlier of the two will be used.
6418	TimePercent int64 `json:"timePercent,omitempty"`
6419
6420	// ViewabilityPercent: The percentage of video that must be on screen
6421	// for the Custom Viewability Metric to count an impression.
6422	ViewabilityPercent int64 `json:"viewabilityPercent,omitempty"`
6423
6424	// ForceSendFields is a list of field names (e.g. "Audible") to
6425	// unconditionally include in API requests. By default, fields with
6426	// empty or default values are omitted from API requests. However, any
6427	// non-pointer, non-interface field appearing in ForceSendFields will be
6428	// sent to the server regardless of whether the field is empty or not.
6429	// This may be used to include empty fields in Patch requests.
6430	ForceSendFields []string `json:"-"`
6431
6432	// NullFields is a list of field names (e.g. "Audible") to include in
6433	// API requests with the JSON null value. By default, fields with empty
6434	// values are omitted from API requests. However, any field with an
6435	// empty value appearing in NullFields will be sent to the server as
6436	// null. It is an error if a field in this list has a non-empty value.
6437	// This may be used to include null fields in Patch requests.
6438	NullFields []string `json:"-"`
6439}
6440
6441func (s *CustomViewabilityMetricConfiguration) MarshalJSON() ([]byte, error) {
6442	type NoMethod CustomViewabilityMetricConfiguration
6443	raw := NoMethod(*s)
6444	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6445}
6446
6447// DV3Ids: DV360 IDs related to the custom event.
6448type DV3Ids struct {
6449	// DvCampaignId: Campaign ID for DV360.
6450	DvCampaignId int64 `json:"dvCampaignId,omitempty,string"`
6451
6452	// DvCreativeId: Creative ID for DV360.
6453	DvCreativeId int64 `json:"dvCreativeId,omitempty,string"`
6454
6455	// DvInsertionOrderId: Insertion Order ID for DV360.
6456	DvInsertionOrderId int64 `json:"dvInsertionOrderId,omitempty,string"`
6457
6458	// DvLineItemId: Line Item ID for DV360.
6459	DvLineItemId int64 `json:"dvLineItemId,omitempty,string"`
6460
6461	// DvSiteId: Site ID for DV360.
6462	DvSiteId int64 `json:"dvSiteId,omitempty,string"`
6463
6464	// Kind: Identifies what kind of resource this is. Value: the fixed
6465	// string "dfareporting#dV3Ids".
6466	Kind string `json:"kind,omitempty"`
6467
6468	// ForceSendFields is a list of field names (e.g. "DvCampaignId") to
6469	// unconditionally include in API requests. By default, fields with
6470	// empty or default values are omitted from API requests. However, any
6471	// non-pointer, non-interface field appearing in ForceSendFields will be
6472	// sent to the server regardless of whether the field is empty or not.
6473	// This may be used to include empty fields in Patch requests.
6474	ForceSendFields []string `json:"-"`
6475
6476	// NullFields is a list of field names (e.g. "DvCampaignId") to include
6477	// in API requests with the JSON null value. By default, fields with
6478	// empty values are omitted from API requests. However, any field with
6479	// an empty value appearing in NullFields will be sent to the server as
6480	// null. It is an error if a field in this list has a non-empty value.
6481	// This may be used to include null fields in Patch requests.
6482	NullFields []string `json:"-"`
6483}
6484
6485func (s *DV3Ids) MarshalJSON() ([]byte, error) {
6486	type NoMethod DV3Ids
6487	raw := NoMethod(*s)
6488	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6489}
6490
6491// DateRange: Represents a date range.
6492type DateRange struct {
6493	EndDate string `json:"endDate,omitempty"`
6494
6495	// Kind: The kind of resource this is, in this case
6496	// dfareporting#dateRange.
6497	Kind string `json:"kind,omitempty"`
6498
6499	// RelativeDateRange: The date range relative to the date of when the
6500	// report is run.
6501	//
6502	// Possible values:
6503	//   "TODAY"
6504	//   "YESTERDAY"
6505	//   "WEEK_TO_DATE"
6506	//   "MONTH_TO_DATE"
6507	//   "QUARTER_TO_DATE"
6508	//   "YEAR_TO_DATE"
6509	//   "PREVIOUS_WEEK"
6510	//   "PREVIOUS_MONTH"
6511	//   "PREVIOUS_QUARTER"
6512	//   "PREVIOUS_YEAR"
6513	//   "LAST_7_DAYS"
6514	//   "LAST_30_DAYS"
6515	//   "LAST_90_DAYS"
6516	//   "LAST_365_DAYS"
6517	//   "LAST_24_MONTHS"
6518	//   "LAST_14_DAYS"
6519	//   "LAST_60_DAYS"
6520	RelativeDateRange string `json:"relativeDateRange,omitempty"`
6521
6522	StartDate string `json:"startDate,omitempty"`
6523
6524	// ForceSendFields is a list of field names (e.g. "EndDate") to
6525	// unconditionally include in API requests. By default, fields with
6526	// empty or default values are omitted from API requests. However, any
6527	// non-pointer, non-interface field appearing in ForceSendFields will be
6528	// sent to the server regardless of whether the field is empty or not.
6529	// This may be used to include empty fields in Patch requests.
6530	ForceSendFields []string `json:"-"`
6531
6532	// NullFields is a list of field names (e.g. "EndDate") to include in
6533	// API requests with the JSON null value. By default, fields with empty
6534	// values are omitted from API requests. However, any field with an
6535	// empty value appearing in NullFields will be sent to the server as
6536	// null. It is an error if a field in this list has a non-empty value.
6537	// This may be used to include null fields in Patch requests.
6538	NullFields []string `json:"-"`
6539}
6540
6541func (s *DateRange) MarshalJSON() ([]byte, error) {
6542	type NoMethod DateRange
6543	raw := NoMethod(*s)
6544	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6545}
6546
6547// DayPartTargeting: Day Part Targeting.
6548type DayPartTargeting struct {
6549	// DaysOfWeek: Days of the week when the ad will serve. Acceptable
6550	// values are: - "SUNDAY" - "MONDAY" - "TUESDAY" - "WEDNESDAY" -
6551	// "THURSDAY" - "FRIDAY" - "SATURDAY"
6552	//
6553	// Possible values:
6554	//   "MONDAY"
6555	//   "TUESDAY"
6556	//   "WEDNESDAY"
6557	//   "THURSDAY"
6558	//   "FRIDAY"
6559	//   "SATURDAY"
6560	//   "SUNDAY"
6561	DaysOfWeek []string `json:"daysOfWeek,omitempty"`
6562
6563	// HoursOfDay: Hours of the day when the ad will serve, where 0 is
6564	// midnight to 1 AM and 23 is 11 PM to midnight. Can be specified with
6565	// days of week, in which case the ad would serve during these hours on
6566	// the specified days. For example if Monday, Wednesday, Friday are the
6567	// days of week specified and 9-10am, 3-5pm (hours 9, 15, and 16) is
6568	// specified, the ad would serve Monday, Wednesdays, and Fridays at
6569	// 9-10am and 3-5pm. Acceptable values are 0 to 23, inclusive.
6570	HoursOfDay []int64 `json:"hoursOfDay,omitempty"`
6571
6572	// UserLocalTime: Whether or not to use the user's local time. If false,
6573	// the America/New York time zone applies.
6574	UserLocalTime bool `json:"userLocalTime,omitempty"`
6575
6576	// ForceSendFields is a list of field names (e.g. "DaysOfWeek") to
6577	// unconditionally include in API requests. By default, fields with
6578	// empty or default values are omitted from API requests. However, any
6579	// non-pointer, non-interface field appearing in ForceSendFields will be
6580	// sent to the server regardless of whether the field is empty or not.
6581	// This may be used to include empty fields in Patch requests.
6582	ForceSendFields []string `json:"-"`
6583
6584	// NullFields is a list of field names (e.g. "DaysOfWeek") to include in
6585	// API requests with the JSON null value. By default, fields with empty
6586	// values are omitted from API requests. However, any field with an
6587	// empty value appearing in NullFields will be sent to the server as
6588	// null. It is an error if a field in this list has a non-empty value.
6589	// This may be used to include null fields in Patch requests.
6590	NullFields []string `json:"-"`
6591}
6592
6593func (s *DayPartTargeting) MarshalJSON() ([]byte, error) {
6594	type NoMethod DayPartTargeting
6595	raw := NoMethod(*s)
6596	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6597}
6598
6599// DeepLink: Contains information about a landing page deep link.
6600type DeepLink struct {
6601	// AppUrl: The URL of the mobile app being linked to.
6602	AppUrl string `json:"appUrl,omitempty"`
6603
6604	// FallbackUrl: The fallback URL. This URL will be served to users who
6605	// do not have the mobile app installed.
6606	FallbackUrl string `json:"fallbackUrl,omitempty"`
6607
6608	// Kind: Identifies what kind of resource this is. Value: the fixed
6609	// string "dfareporting#deepLink".
6610	Kind string `json:"kind,omitempty"`
6611
6612	// MobileApp: The mobile app targeted by this deep link.
6613	MobileApp *MobileApp `json:"mobileApp,omitempty"`
6614
6615	// RemarketingListIds: Ads served to users on these remarketing lists
6616	// will use this deep link. Applicable when mobileApp.directory is
6617	// APPLE_APP_STORE.
6618	RemarketingListIds googleapi.Int64s `json:"remarketingListIds,omitempty"`
6619
6620	// ForceSendFields is a list of field names (e.g. "AppUrl") to
6621	// unconditionally include in API requests. By default, fields with
6622	// empty or default values are omitted from API requests. However, any
6623	// non-pointer, non-interface field appearing in ForceSendFields will be
6624	// sent to the server regardless of whether the field is empty or not.
6625	// This may be used to include empty fields in Patch requests.
6626	ForceSendFields []string `json:"-"`
6627
6628	// NullFields is a list of field names (e.g. "AppUrl") to include in API
6629	// requests with the JSON null value. By default, fields with empty
6630	// values are omitted from API requests. However, any field with an
6631	// empty value appearing in NullFields will be sent to the server as
6632	// null. It is an error if a field in this list has a non-empty value.
6633	// This may be used to include null fields in Patch requests.
6634	NullFields []string `json:"-"`
6635}
6636
6637func (s *DeepLink) MarshalJSON() ([]byte, error) {
6638	type NoMethod DeepLink
6639	raw := NoMethod(*s)
6640	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6641}
6642
6643// DefaultClickThroughEventTagProperties: Properties of inheriting and
6644// overriding the default click-through event tag. A campaign may
6645// override the event tag defined at the advertiser level, and an ad may
6646// also override the campaign's setting further.
6647type DefaultClickThroughEventTagProperties struct {
6648	// DefaultClickThroughEventTagId: ID of the click-through event tag to
6649	// apply to all ads in this entity's scope.
6650	DefaultClickThroughEventTagId int64 `json:"defaultClickThroughEventTagId,omitempty,string"`
6651
6652	// OverrideInheritedEventTag: Whether this entity should override the
6653	// inherited default click-through event tag with its own defined value.
6654	OverrideInheritedEventTag bool `json:"overrideInheritedEventTag,omitempty"`
6655
6656	// ForceSendFields is a list of field names (e.g.
6657	// "DefaultClickThroughEventTagId") to unconditionally include in API
6658	// requests. By default, fields with empty or default values are omitted
6659	// from API requests. However, any non-pointer, non-interface field
6660	// appearing in ForceSendFields will be sent to the server regardless of
6661	// whether the field is empty or not. This may be used to include empty
6662	// fields in Patch requests.
6663	ForceSendFields []string `json:"-"`
6664
6665	// NullFields is a list of field names (e.g.
6666	// "DefaultClickThroughEventTagId") to include in API requests with the
6667	// JSON null value. By default, fields with empty values are omitted
6668	// from API requests. However, any field with an empty value appearing
6669	// in NullFields will be sent to the server as null. It is an error if a
6670	// field in this list has a non-empty value. This may be used to include
6671	// null fields in Patch requests.
6672	NullFields []string `json:"-"`
6673}
6674
6675func (s *DefaultClickThroughEventTagProperties) MarshalJSON() ([]byte, error) {
6676	type NoMethod DefaultClickThroughEventTagProperties
6677	raw := NoMethod(*s)
6678	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6679}
6680
6681// DeliverySchedule: Delivery Schedule.
6682type DeliverySchedule struct {
6683	// FrequencyCap: Limit on the number of times an individual user can be
6684	// served the ad within a specified period of time.
6685	FrequencyCap *FrequencyCap `json:"frequencyCap,omitempty"`
6686
6687	// HardCutoff: Whether or not hard cutoff is enabled. If true, the ad
6688	// will not serve after the end date and time. Otherwise the ad will
6689	// continue to be served until it has reached its delivery goals.
6690	HardCutoff bool `json:"hardCutoff,omitempty"`
6691
6692	// ImpressionRatio: Impression ratio for this ad. This ratio determines
6693	// how often each ad is served relative to the others. For example, if
6694	// ad A has an impression ratio of 1 and ad B has an impression ratio of
6695	// 3, then Campaign Manager will serve ad B three times as often as ad
6696	// A. Acceptable values are 1 to 10, inclusive.
6697	ImpressionRatio int64 `json:"impressionRatio,omitempty,string"`
6698
6699	// Priority: Serving priority of an ad, with respect to other ads. The
6700	// lower the priority number, the greater the priority with which it is
6701	// served.
6702	//
6703	// Possible values:
6704	//   "AD_PRIORITY_01"
6705	//   "AD_PRIORITY_02"
6706	//   "AD_PRIORITY_03"
6707	//   "AD_PRIORITY_04"
6708	//   "AD_PRIORITY_05"
6709	//   "AD_PRIORITY_06"
6710	//   "AD_PRIORITY_07"
6711	//   "AD_PRIORITY_08"
6712	//   "AD_PRIORITY_09"
6713	//   "AD_PRIORITY_10"
6714	//   "AD_PRIORITY_11"
6715	//   "AD_PRIORITY_12"
6716	//   "AD_PRIORITY_13"
6717	//   "AD_PRIORITY_14"
6718	//   "AD_PRIORITY_15"
6719	//   "AD_PRIORITY_16"
6720	Priority string `json:"priority,omitempty"`
6721
6722	// ForceSendFields is a list of field names (e.g. "FrequencyCap") to
6723	// unconditionally include in API requests. By default, fields with
6724	// empty or default values are omitted from API requests. However, any
6725	// non-pointer, non-interface field appearing in ForceSendFields will be
6726	// sent to the server regardless of whether the field is empty or not.
6727	// This may be used to include empty fields in Patch requests.
6728	ForceSendFields []string `json:"-"`
6729
6730	// NullFields is a list of field names (e.g. "FrequencyCap") to include
6731	// in API requests with the JSON null value. By default, fields with
6732	// empty values are omitted from API requests. However, any field with
6733	// an empty value appearing in NullFields will be sent to the server as
6734	// null. It is an error if a field in this list has a non-empty value.
6735	// This may be used to include null fields in Patch requests.
6736	NullFields []string `json:"-"`
6737}
6738
6739func (s *DeliverySchedule) MarshalJSON() ([]byte, error) {
6740	type NoMethod DeliverySchedule
6741	raw := NoMethod(*s)
6742	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6743}
6744
6745// DfpSettings: Google Ad Manager Settings
6746type DfpSettings struct {
6747	// DfpNetworkCode: Ad Manager network code for this directory site.
6748	DfpNetworkCode string `json:"dfpNetworkCode,omitempty"`
6749
6750	// DfpNetworkName: Ad Manager network name for this directory site.
6751	DfpNetworkName string `json:"dfpNetworkName,omitempty"`
6752
6753	// ProgrammaticPlacementAccepted: Whether this directory site accepts
6754	// programmatic placements.
6755	ProgrammaticPlacementAccepted bool `json:"programmaticPlacementAccepted,omitempty"`
6756
6757	// PubPaidPlacementAccepted: Whether this directory site accepts
6758	// publisher-paid tags.
6759	PubPaidPlacementAccepted bool `json:"pubPaidPlacementAccepted,omitempty"`
6760
6761	// PublisherPortalOnly: Whether this directory site is available only
6762	// via Publisher Portal.
6763	PublisherPortalOnly bool `json:"publisherPortalOnly,omitempty"`
6764
6765	// ForceSendFields is a list of field names (e.g. "DfpNetworkCode") to
6766	// unconditionally include in API requests. By default, fields with
6767	// empty or default values are omitted from API requests. However, any
6768	// non-pointer, non-interface field appearing in ForceSendFields will be
6769	// sent to the server regardless of whether the field is empty or not.
6770	// This may be used to include empty fields in Patch requests.
6771	ForceSendFields []string `json:"-"`
6772
6773	// NullFields is a list of field names (e.g. "DfpNetworkCode") to
6774	// include in API requests with the JSON null value. By default, fields
6775	// with empty values are omitted from API requests. However, any field
6776	// with an empty value appearing in NullFields will be sent to the
6777	// server as null. It is an error if a field in this list has a
6778	// non-empty value. This may be used to include null fields in Patch
6779	// requests.
6780	NullFields []string `json:"-"`
6781}
6782
6783func (s *DfpSettings) MarshalJSON() ([]byte, error) {
6784	type NoMethod DfpSettings
6785	raw := NoMethod(*s)
6786	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6787}
6788
6789// Dimension: Represents a dimension.
6790type Dimension struct {
6791	// Kind: The kind of resource this is, in this case
6792	// dfareporting#dimension.
6793	Kind string `json:"kind,omitempty"`
6794
6795	// Name: The dimension name, e.g. dfa:advertiser
6796	Name string `json:"name,omitempty"`
6797
6798	// ForceSendFields is a list of field names (e.g. "Kind") to
6799	// unconditionally include in API requests. By default, fields with
6800	// empty or default values are omitted from API requests. However, any
6801	// non-pointer, non-interface field appearing in ForceSendFields will be
6802	// sent to the server regardless of whether the field is empty or not.
6803	// This may be used to include empty fields in Patch requests.
6804	ForceSendFields []string `json:"-"`
6805
6806	// NullFields is a list of field names (e.g. "Kind") to include in API
6807	// requests with the JSON null value. By default, fields with empty
6808	// values are omitted from API requests. However, any field with an
6809	// empty value appearing in NullFields will be sent to the server as
6810	// null. It is an error if a field in this list has a non-empty value.
6811	// This may be used to include null fields in Patch requests.
6812	NullFields []string `json:"-"`
6813}
6814
6815func (s *Dimension) MarshalJSON() ([]byte, error) {
6816	type NoMethod Dimension
6817	raw := NoMethod(*s)
6818	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6819}
6820
6821// DimensionFilter: Represents a dimension filter.
6822type DimensionFilter struct {
6823	// DimensionName: The name of the dimension to filter.
6824	DimensionName string `json:"dimensionName,omitempty"`
6825
6826	// Kind: The kind of resource this is, in this case
6827	// dfareporting#dimensionFilter.
6828	Kind string `json:"kind,omitempty"`
6829
6830	// Value: The value of the dimension to filter.
6831	Value string `json:"value,omitempty"`
6832
6833	// ForceSendFields is a list of field names (e.g. "DimensionName") to
6834	// unconditionally include in API requests. By default, fields with
6835	// empty or default values are omitted from API requests. However, any
6836	// non-pointer, non-interface field appearing in ForceSendFields will be
6837	// sent to the server regardless of whether the field is empty or not.
6838	// This may be used to include empty fields in Patch requests.
6839	ForceSendFields []string `json:"-"`
6840
6841	// NullFields is a list of field names (e.g. "DimensionName") to include
6842	// in API requests with the JSON null value. By default, fields with
6843	// empty values are omitted from API requests. However, any field with
6844	// an empty value appearing in NullFields will be sent to the server as
6845	// null. It is an error if a field in this list has a non-empty value.
6846	// This may be used to include null fields in Patch requests.
6847	NullFields []string `json:"-"`
6848}
6849
6850func (s *DimensionFilter) MarshalJSON() ([]byte, error) {
6851	type NoMethod DimensionFilter
6852	raw := NoMethod(*s)
6853	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6854}
6855
6856// DimensionValue: Represents a DimensionValue resource.
6857type DimensionValue struct {
6858	// DimensionName: The name of the dimension.
6859	DimensionName string `json:"dimensionName,omitempty"`
6860
6861	// Etag: The eTag of this response for caching purposes.
6862	Etag string `json:"etag,omitempty"`
6863
6864	// Id: The ID associated with the value if available.
6865	Id string `json:"id,omitempty"`
6866
6867	// Kind: The kind of resource this is, in this case
6868	// dfareporting#dimensionValue.
6869	Kind string `json:"kind,omitempty"`
6870
6871	// MatchType: Determines how the 'value' field is matched when
6872	// filtering. If not specified, defaults to EXACT. If set to
6873	// WILDCARD_EXPRESSION, '*' is allowed as a placeholder for variable
6874	// length character sequences, and it can be escaped with a backslash.
6875	// Note, only paid search dimensions ('dfa:paidSearch*') allow a
6876	// matchType other than EXACT.
6877	//
6878	// Possible values:
6879	//   "EXACT"
6880	//   "BEGINS_WITH"
6881	//   "CONTAINS"
6882	//   "WILDCARD_EXPRESSION"
6883	MatchType string `json:"matchType,omitempty"`
6884
6885	// Value: The value of the dimension.
6886	Value string `json:"value,omitempty"`
6887
6888	// ForceSendFields is a list of field names (e.g. "DimensionName") to
6889	// unconditionally include in API requests. By default, fields with
6890	// empty or default values are omitted from API requests. However, any
6891	// non-pointer, non-interface field appearing in ForceSendFields will be
6892	// sent to the server regardless of whether the field is empty or not.
6893	// This may be used to include empty fields in Patch requests.
6894	ForceSendFields []string `json:"-"`
6895
6896	// NullFields is a list of field names (e.g. "DimensionName") to include
6897	// in API requests with the JSON null value. By default, fields with
6898	// empty values are omitted from API requests. However, any field with
6899	// an empty value appearing in NullFields will be sent to the server as
6900	// null. It is an error if a field in this list has a non-empty value.
6901	// This may be used to include null fields in Patch requests.
6902	NullFields []string `json:"-"`
6903}
6904
6905func (s *DimensionValue) MarshalJSON() ([]byte, error) {
6906	type NoMethod DimensionValue
6907	raw := NoMethod(*s)
6908	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6909}
6910
6911// DimensionValueList: Represents the list of DimensionValue resources.
6912type DimensionValueList struct {
6913	// Etag: The eTag of this response for caching purposes.
6914	Etag string `json:"etag,omitempty"`
6915
6916	// Items: The dimension values returned in this response.
6917	Items []*DimensionValue `json:"items,omitempty"`
6918
6919	// Kind: The kind of list this is, in this case
6920	// dfareporting#dimensionValueList.
6921	Kind string `json:"kind,omitempty"`
6922
6923	// NextPageToken: Continuation token used to page through dimension
6924	// values. To retrieve the next page of results, set the next request's
6925	// "pageToken" to the value of this field. The page token is only valid
6926	// for a limited amount of time and should not be persisted.
6927	NextPageToken string `json:"nextPageToken,omitempty"`
6928
6929	// ServerResponse contains the HTTP response code and headers from the
6930	// server.
6931	googleapi.ServerResponse `json:"-"`
6932
6933	// ForceSendFields is a list of field names (e.g. "Etag") to
6934	// unconditionally include in API requests. By default, fields with
6935	// empty or default values are omitted from API requests. However, any
6936	// non-pointer, non-interface field appearing in ForceSendFields will be
6937	// sent to the server regardless of whether the field is empty or not.
6938	// This may be used to include empty fields in Patch requests.
6939	ForceSendFields []string `json:"-"`
6940
6941	// NullFields is a list of field names (e.g. "Etag") to include in API
6942	// requests with the JSON null value. By default, fields with empty
6943	// values are omitted from API requests. However, any field with an
6944	// empty value appearing in NullFields will be sent to the server as
6945	// null. It is an error if a field in this list has a non-empty value.
6946	// This may be used to include null fields in Patch requests.
6947	NullFields []string `json:"-"`
6948}
6949
6950func (s *DimensionValueList) MarshalJSON() ([]byte, error) {
6951	type NoMethod DimensionValueList
6952	raw := NoMethod(*s)
6953	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6954}
6955
6956// DimensionValueRequest: Represents a DimensionValuesRequest.
6957type DimensionValueRequest struct {
6958	// DimensionName: The name of the dimension for which values should be
6959	// requested.
6960	DimensionName string `json:"dimensionName,omitempty"`
6961
6962	EndDate string `json:"endDate,omitempty"`
6963
6964	// Filters: The list of filters by which to filter values. The filters
6965	// are ANDed.
6966	Filters []*DimensionFilter `json:"filters,omitempty"`
6967
6968	// Kind: The kind of request this is, in this case
6969	// dfareporting#dimensionValueRequest .
6970	Kind string `json:"kind,omitempty"`
6971
6972	StartDate string `json:"startDate,omitempty"`
6973
6974	// ForceSendFields is a list of field names (e.g. "DimensionName") to
6975	// unconditionally include in API requests. By default, fields with
6976	// empty or default values are omitted from API requests. However, any
6977	// non-pointer, non-interface field appearing in ForceSendFields will be
6978	// sent to the server regardless of whether the field is empty or not.
6979	// This may be used to include empty fields in Patch requests.
6980	ForceSendFields []string `json:"-"`
6981
6982	// NullFields is a list of field names (e.g. "DimensionName") to include
6983	// in API requests with the JSON null value. By default, fields with
6984	// empty values are omitted from API requests. However, any field with
6985	// an empty value appearing in NullFields will be sent to the server as
6986	// null. It is an error if a field in this list has a non-empty value.
6987	// This may be used to include null fields in Patch requests.
6988	NullFields []string `json:"-"`
6989}
6990
6991func (s *DimensionValueRequest) MarshalJSON() ([]byte, error) {
6992	type NoMethod DimensionValueRequest
6993	raw := NoMethod(*s)
6994	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6995}
6996
6997// DirectorySite: DirectorySites contains properties of a website from
6998// the Site Directory. Sites need to be added to an account via the
6999// Sites resource before they can be assigned to a placement.
7000type DirectorySite struct {
7001	// Id: ID of this directory site. This is a read-only, auto-generated
7002	// field.
7003	Id int64 `json:"id,omitempty,string"`
7004
7005	// IdDimensionValue: Dimension value for the ID of this directory site.
7006	// This is a read-only, auto-generated field.
7007	IdDimensionValue *DimensionValue `json:"idDimensionValue,omitempty"`
7008
7009	// InpageTagFormats: Tag types for regular placements. Acceptable values
7010	// are: - "STANDARD" - "IFRAME_JAVASCRIPT_INPAGE" -
7011	// "INTERNAL_REDIRECT_INPAGE" - "JAVASCRIPT_INPAGE"
7012	//
7013	// Possible values:
7014	//   "STANDARD"
7015	//   "IFRAME_JAVASCRIPT_INPAGE"
7016	//   "INTERNAL_REDIRECT_INPAGE"
7017	//   "JAVASCRIPT_INPAGE"
7018	InpageTagFormats []string `json:"inpageTagFormats,omitempty"`
7019
7020	// InterstitialTagFormats: Tag types for interstitial placements.
7021	// Acceptable values are: - "IFRAME_JAVASCRIPT_INTERSTITIAL" -
7022	// "INTERNAL_REDIRECT_INTERSTITIAL" - "JAVASCRIPT_INTERSTITIAL"
7023	//
7024	// Possible values:
7025	//   "IFRAME_JAVASCRIPT_INTERSTITIAL"
7026	//   "INTERNAL_REDIRECT_INTERSTITIAL"
7027	//   "JAVASCRIPT_INTERSTITIAL"
7028	InterstitialTagFormats []string `json:"interstitialTagFormats,omitempty"`
7029
7030	// Kind: Identifies what kind of resource this is. Value: the fixed
7031	// string "dfareporting#directorySite".
7032	Kind string `json:"kind,omitempty"`
7033
7034	// Name: Name of this directory site.
7035	Name string `json:"name,omitempty"`
7036
7037	// Settings: Directory site settings.
7038	Settings *DirectorySiteSettings `json:"settings,omitempty"`
7039
7040	// Url: URL of this directory site.
7041	Url string `json:"url,omitempty"`
7042
7043	// ServerResponse contains the HTTP response code and headers from the
7044	// server.
7045	googleapi.ServerResponse `json:"-"`
7046
7047	// ForceSendFields is a list of field names (e.g. "Id") to
7048	// unconditionally include in API requests. By default, fields with
7049	// empty or default values are omitted from API requests. However, any
7050	// non-pointer, non-interface field appearing in ForceSendFields will be
7051	// sent to the server regardless of whether the field is empty or not.
7052	// This may be used to include empty fields in Patch requests.
7053	ForceSendFields []string `json:"-"`
7054
7055	// NullFields is a list of field names (e.g. "Id") to include in API
7056	// requests with the JSON null value. By default, fields with empty
7057	// values are omitted from API requests. However, any field with an
7058	// empty value appearing in NullFields will be sent to the server as
7059	// null. It is an error if a field in this list has a non-empty value.
7060	// This may be used to include null fields in Patch requests.
7061	NullFields []string `json:"-"`
7062}
7063
7064func (s *DirectorySite) MarshalJSON() ([]byte, error) {
7065	type NoMethod DirectorySite
7066	raw := NoMethod(*s)
7067	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7068}
7069
7070// DirectorySiteSettings: Directory Site Settings
7071type DirectorySiteSettings struct {
7072	// ActiveViewOptOut: Whether this directory site has disabled active
7073	// view creatives.
7074	ActiveViewOptOut bool `json:"activeViewOptOut,omitempty"`
7075
7076	// DfpSettings: Directory site Ad Manager settings.
7077	DfpSettings *DfpSettings `json:"dfpSettings,omitempty"`
7078
7079	// InstreamVideoPlacementAccepted: Whether this site accepts in-stream
7080	// video ads.
7081	InstreamVideoPlacementAccepted bool `json:"instreamVideoPlacementAccepted,omitempty"`
7082
7083	// InterstitialPlacementAccepted: Whether this site accepts interstitial
7084	// ads.
7085	InterstitialPlacementAccepted bool `json:"interstitialPlacementAccepted,omitempty"`
7086
7087	// ForceSendFields is a list of field names (e.g. "ActiveViewOptOut") to
7088	// unconditionally include in API requests. By default, fields with
7089	// empty or default values are omitted from API requests. However, any
7090	// non-pointer, non-interface field appearing in ForceSendFields will be
7091	// sent to the server regardless of whether the field is empty or not.
7092	// This may be used to include empty fields in Patch requests.
7093	ForceSendFields []string `json:"-"`
7094
7095	// NullFields is a list of field names (e.g. "ActiveViewOptOut") to
7096	// include in API requests with the JSON null value. By default, fields
7097	// with empty values are omitted from API requests. However, any field
7098	// with an empty value appearing in NullFields will be sent to the
7099	// server as null. It is an error if a field in this list has a
7100	// non-empty value. This may be used to include null fields in Patch
7101	// requests.
7102	NullFields []string `json:"-"`
7103}
7104
7105func (s *DirectorySiteSettings) MarshalJSON() ([]byte, error) {
7106	type NoMethod DirectorySiteSettings
7107	raw := NoMethod(*s)
7108	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7109}
7110
7111// DirectorySitesListResponse: Directory Site List Response
7112type DirectorySitesListResponse struct {
7113	// DirectorySites: Directory site collection.
7114	DirectorySites []*DirectorySite `json:"directorySites,omitempty"`
7115
7116	// Kind: Identifies what kind of resource this is. Value: the fixed
7117	// string "dfareporting#directorySitesListResponse".
7118	Kind string `json:"kind,omitempty"`
7119
7120	// NextPageToken: Pagination token to be used for the next list
7121	// operation.
7122	NextPageToken string `json:"nextPageToken,omitempty"`
7123
7124	// ServerResponse contains the HTTP response code and headers from the
7125	// server.
7126	googleapi.ServerResponse `json:"-"`
7127
7128	// ForceSendFields is a list of field names (e.g. "DirectorySites") to
7129	// unconditionally include in API requests. By default, fields with
7130	// empty or default values are omitted from API requests. However, any
7131	// non-pointer, non-interface field appearing in ForceSendFields will be
7132	// sent to the server regardless of whether the field is empty or not.
7133	// This may be used to include empty fields in Patch requests.
7134	ForceSendFields []string `json:"-"`
7135
7136	// NullFields is a list of field names (e.g. "DirectorySites") to
7137	// include in API requests with the JSON null value. By default, fields
7138	// with empty values are omitted from API requests. However, any field
7139	// with an empty value appearing in NullFields will be sent to the
7140	// server as null. It is an error if a field in this list has a
7141	// non-empty value. This may be used to include null fields in Patch
7142	// requests.
7143	NullFields []string `json:"-"`
7144}
7145
7146func (s *DirectorySitesListResponse) MarshalJSON() ([]byte, error) {
7147	type NoMethod DirectorySitesListResponse
7148	raw := NoMethod(*s)
7149	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7150}
7151
7152// DisjunctiveMatchStatement: Represents a Disjunctive Match Statement
7153// resource, which is a conjunction (and) of disjunctive (or) boolean
7154// statements.
7155type DisjunctiveMatchStatement struct {
7156	// EventFilters: The event filters contained within this disjunctive
7157	// match statement.
7158	EventFilters []*EventFilter `json:"eventFilters,omitempty"`
7159
7160	// Kind: The kind of resource this is, in this case
7161	// dfareporting#disjunctiveMatchStatement.
7162	Kind string `json:"kind,omitempty"`
7163
7164	// ForceSendFields is a list of field names (e.g. "EventFilters") to
7165	// unconditionally include in API requests. By default, fields with
7166	// empty or default values are omitted from API requests. However, any
7167	// non-pointer, non-interface field appearing in ForceSendFields will be
7168	// sent to the server regardless of whether the field is empty or not.
7169	// This may be used to include empty fields in Patch requests.
7170	ForceSendFields []string `json:"-"`
7171
7172	// NullFields is a list of field names (e.g. "EventFilters") to include
7173	// in API requests with the JSON null value. By default, fields with
7174	// empty values are omitted from API requests. However, any field with
7175	// an empty value appearing in NullFields will be sent to the server as
7176	// null. It is an error if a field in this list has a non-empty value.
7177	// This may be used to include null fields in Patch requests.
7178	NullFields []string `json:"-"`
7179}
7180
7181func (s *DisjunctiveMatchStatement) MarshalJSON() ([]byte, error) {
7182	type NoMethod DisjunctiveMatchStatement
7183	raw := NoMethod(*s)
7184	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7185}
7186
7187// DynamicTargetingKey: Contains properties of a dynamic targeting key.
7188// Dynamic targeting keys are unique, user-friendly labels, created at
7189// the advertiser level in DCM, that can be assigned to ads, creatives,
7190// and placements and used for targeting with Studio dynamic creatives.
7191// Use these labels instead of numeric Campaign Manager IDs (such as
7192// placement IDs) to save time and avoid errors in your dynamic feeds.
7193type DynamicTargetingKey struct {
7194	// Kind: Identifies what kind of resource this is. Value: the fixed
7195	// string "dfareporting#dynamicTargetingKey".
7196	Kind string `json:"kind,omitempty"`
7197
7198	// Name: Name of this dynamic targeting key. This is a required field.
7199	// Must be less than 256 characters long and cannot contain commas. All
7200	// characters are converted to lowercase.
7201	Name string `json:"name,omitempty"`
7202
7203	// ObjectId: ID of the object of this dynamic targeting key. This is a
7204	// required field.
7205	ObjectId int64 `json:"objectId,omitempty,string"`
7206
7207	// ObjectType: Type of the object of this dynamic targeting key. This is
7208	// a required field.
7209	//
7210	// Possible values:
7211	//   "OBJECT_ADVERTISER"
7212	//   "OBJECT_AD"
7213	//   "OBJECT_CREATIVE"
7214	//   "OBJECT_PLACEMENT"
7215	ObjectType string `json:"objectType,omitempty"`
7216
7217	// ServerResponse contains the HTTP response code and headers from the
7218	// server.
7219	googleapi.ServerResponse `json:"-"`
7220
7221	// ForceSendFields is a list of field names (e.g. "Kind") to
7222	// unconditionally include in API requests. By default, fields with
7223	// empty or default values are omitted from API requests. However, any
7224	// non-pointer, non-interface field appearing in ForceSendFields will be
7225	// sent to the server regardless of whether the field is empty or not.
7226	// This may be used to include empty fields in Patch requests.
7227	ForceSendFields []string `json:"-"`
7228
7229	// NullFields is a list of field names (e.g. "Kind") to include in API
7230	// requests with the JSON null value. By default, fields with empty
7231	// values are omitted from API requests. However, any field with an
7232	// empty value appearing in NullFields will be sent to the server as
7233	// null. It is an error if a field in this list has a non-empty value.
7234	// This may be used to include null fields in Patch requests.
7235	NullFields []string `json:"-"`
7236}
7237
7238func (s *DynamicTargetingKey) MarshalJSON() ([]byte, error) {
7239	type NoMethod DynamicTargetingKey
7240	raw := NoMethod(*s)
7241	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7242}
7243
7244// DynamicTargetingKeysListResponse: Dynamic Targeting Key List Response
7245type DynamicTargetingKeysListResponse struct {
7246	// DynamicTargetingKeys: Dynamic targeting key collection.
7247	DynamicTargetingKeys []*DynamicTargetingKey `json:"dynamicTargetingKeys,omitempty"`
7248
7249	// Kind: Identifies what kind of resource this is. Value: the fixed
7250	// string "dfareporting#dynamicTargetingKeysListResponse".
7251	Kind string `json:"kind,omitempty"`
7252
7253	// ServerResponse contains the HTTP response code and headers from the
7254	// server.
7255	googleapi.ServerResponse `json:"-"`
7256
7257	// ForceSendFields is a list of field names (e.g.
7258	// "DynamicTargetingKeys") to unconditionally include in API requests.
7259	// By default, fields with empty or default values are omitted from API
7260	// requests. However, any non-pointer, non-interface field appearing in
7261	// ForceSendFields will be sent to the server regardless of whether the
7262	// field is empty or not. This may be used to include empty fields in
7263	// Patch requests.
7264	ForceSendFields []string `json:"-"`
7265
7266	// NullFields is a list of field names (e.g. "DynamicTargetingKeys") to
7267	// include in API requests with the JSON null value. By default, fields
7268	// with empty values are omitted from API requests. However, any field
7269	// with an empty value appearing in NullFields will be sent to the
7270	// server as null. It is an error if a field in this list has a
7271	// non-empty value. This may be used to include null fields in Patch
7272	// requests.
7273	NullFields []string `json:"-"`
7274}
7275
7276func (s *DynamicTargetingKeysListResponse) MarshalJSON() ([]byte, error) {
7277	type NoMethod DynamicTargetingKeysListResponse
7278	raw := NoMethod(*s)
7279	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7280}
7281
7282// EncryptionInfo: A description of how user IDs are encrypted.
7283type EncryptionInfo struct {
7284	// EncryptionEntityId: The encryption entity ID. This should match the
7285	// encryption configuration for ad serving or Data Transfer.
7286	EncryptionEntityId int64 `json:"encryptionEntityId,omitempty,string"`
7287
7288	// EncryptionEntityType: The encryption entity type. This should match
7289	// the encryption configuration for ad serving or Data Transfer.
7290	//
7291	// Possible values:
7292	//   "ENCRYPTION_ENTITY_TYPE_UNKNOWN"
7293	//   "DCM_ACCOUNT"
7294	//   "DCM_ADVERTISER"
7295	//   "DBM_PARTNER"
7296	//   "DBM_ADVERTISER"
7297	//   "ADWORDS_CUSTOMER"
7298	//   "DFP_NETWORK_CODE"
7299	EncryptionEntityType string `json:"encryptionEntityType,omitempty"`
7300
7301	// EncryptionSource: Describes whether the encrypted cookie was received
7302	// from ad serving (the %m macro) or from Data Transfer.
7303	//
7304	// Possible values:
7305	//   "ENCRYPTION_SCOPE_UNKNOWN"
7306	//   "AD_SERVING"
7307	//   "DATA_TRANSFER"
7308	EncryptionSource string `json:"encryptionSource,omitempty"`
7309
7310	// Kind: Identifies what kind of resource this is. Value: the fixed
7311	// string "dfareporting#encryptionInfo".
7312	Kind string `json:"kind,omitempty"`
7313
7314	// ForceSendFields is a list of field names (e.g. "EncryptionEntityId")
7315	// to unconditionally include in API requests. By default, fields with
7316	// empty or default values are omitted from API requests. However, any
7317	// non-pointer, non-interface field appearing in ForceSendFields will be
7318	// sent to the server regardless of whether the field is empty or not.
7319	// This may be used to include empty fields in Patch requests.
7320	ForceSendFields []string `json:"-"`
7321
7322	// NullFields is a list of field names (e.g. "EncryptionEntityId") to
7323	// include in API requests with the JSON null value. By default, fields
7324	// with empty values are omitted from API requests. However, any field
7325	// with an empty value appearing in NullFields will be sent to the
7326	// server as null. It is an error if a field in this list has a
7327	// non-empty value. This may be used to include null fields in Patch
7328	// requests.
7329	NullFields []string `json:"-"`
7330}
7331
7332func (s *EncryptionInfo) MarshalJSON() ([]byte, error) {
7333	type NoMethod EncryptionInfo
7334	raw := NoMethod(*s)
7335	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7336}
7337
7338// EventFilter: Represents a DfaReporting event filter.
7339type EventFilter struct {
7340	// DimensionFilter: The dimension filter contained within this
7341	// EventFilter.
7342	DimensionFilter *PathReportDimensionValue `json:"dimensionFilter,omitempty"`
7343
7344	// Kind: The kind of resource this is, in this case
7345	// dfareporting#eventFilter.
7346	Kind string `json:"kind,omitempty"`
7347
7348	// ForceSendFields is a list of field names (e.g. "DimensionFilter") to
7349	// unconditionally include in API requests. By default, fields with
7350	// empty or default values are omitted from API requests. However, any
7351	// non-pointer, non-interface field appearing in ForceSendFields will be
7352	// sent to the server regardless of whether the field is empty or not.
7353	// This may be used to include empty fields in Patch requests.
7354	ForceSendFields []string `json:"-"`
7355
7356	// NullFields is a list of field names (e.g. "DimensionFilter") to
7357	// include in API requests with the JSON null value. By default, fields
7358	// with empty values are omitted from API requests. However, any field
7359	// with an empty value appearing in NullFields will be sent to the
7360	// server as null. It is an error if a field in this list has a
7361	// non-empty value. This may be used to include null fields in Patch
7362	// requests.
7363	NullFields []string `json:"-"`
7364}
7365
7366func (s *EventFilter) MarshalJSON() ([]byte, error) {
7367	type NoMethod EventFilter
7368	raw := NoMethod(*s)
7369	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7370}
7371
7372// EventTag: Contains properties of an event tag.
7373type EventTag struct {
7374	// AccountId: Account ID of this event tag. This is a read-only field
7375	// that can be left blank.
7376	AccountId int64 `json:"accountId,omitempty,string"`
7377
7378	// AdvertiserId: Advertiser ID of this event tag. This field or the
7379	// campaignId field is required on insertion.
7380	AdvertiserId int64 `json:"advertiserId,omitempty,string"`
7381
7382	// AdvertiserIdDimensionValue: Dimension value for the ID of the
7383	// advertiser. This is a read-only, auto-generated field.
7384	AdvertiserIdDimensionValue *DimensionValue `json:"advertiserIdDimensionValue,omitempty"`
7385
7386	// CampaignId: Campaign ID of this event tag. This field or the
7387	// advertiserId field is required on insertion.
7388	CampaignId int64 `json:"campaignId,omitempty,string"`
7389
7390	// CampaignIdDimensionValue: Dimension value for the ID of the campaign.
7391	// This is a read-only, auto-generated field.
7392	CampaignIdDimensionValue *DimensionValue `json:"campaignIdDimensionValue,omitempty"`
7393
7394	// EnabledByDefault: Whether this event tag should be automatically
7395	// enabled for all of the advertiser's campaigns and ads.
7396	EnabledByDefault bool `json:"enabledByDefault,omitempty"`
7397
7398	// ExcludeFromAdxRequests: Whether to remove this event tag from ads
7399	// that are trafficked through Display & Video 360 to Ad Exchange. This
7400	// may be useful if the event tag uses a pixel that is unapproved for Ad
7401	// Exchange bids on one or more networks, such as the Google Display
7402	// Network.
7403	ExcludeFromAdxRequests bool `json:"excludeFromAdxRequests,omitempty"`
7404
7405	// Id: ID of this event tag. This is a read-only, auto-generated field.
7406	Id int64 `json:"id,omitempty,string"`
7407
7408	// Kind: Identifies what kind of resource this is. Value: the fixed
7409	// string "dfareporting#eventTag".
7410	Kind string `json:"kind,omitempty"`
7411
7412	// Name: Name of this event tag. This is a required field and must be
7413	// less than 256 characters long.
7414	Name string `json:"name,omitempty"`
7415
7416	// SiteFilterType: Site filter type for this event tag. If no type is
7417	// specified then the event tag will be applied to all sites.
7418	//
7419	// Possible values:
7420	//   "WHITELIST"
7421	//   "BLACKLIST"
7422	SiteFilterType string `json:"siteFilterType,omitempty"`
7423
7424	// SiteIds: Filter list of site IDs associated with this event tag. The
7425	// siteFilterType determines whether this is a allowlist or blocklist
7426	// filter.
7427	SiteIds googleapi.Int64s `json:"siteIds,omitempty"`
7428
7429	// SslCompliant: Whether this tag is SSL-compliant or not. This is a
7430	// read-only field.
7431	SslCompliant bool `json:"sslCompliant,omitempty"`
7432
7433	// Status: Status of this event tag. Must be ENABLED for this event tag
7434	// to fire. This is a required field.
7435	//
7436	// Possible values:
7437	//   "ENABLED"
7438	//   "DISABLED"
7439	Status string `json:"status,omitempty"`
7440
7441	// SubaccountId: Subaccount ID of this event tag. This is a read-only
7442	// field that can be left blank.
7443	SubaccountId int64 `json:"subaccountId,omitempty,string"`
7444
7445	// Type: Event tag type. Can be used to specify whether to use a
7446	// third-party pixel, a third-party JavaScript URL, or a third-party
7447	// click-through URL for either impression or click tracking. This is a
7448	// required field.
7449	//
7450	// Possible values:
7451	//   "IMPRESSION_IMAGE_EVENT_TAG"
7452	//   "IMPRESSION_JAVASCRIPT_EVENT_TAG"
7453	//   "CLICK_THROUGH_EVENT_TAG"
7454	Type string `json:"type,omitempty"`
7455
7456	// Url: Payload URL for this event tag. The URL on a click-through event
7457	// tag should have a landing page URL appended to the end of it. This
7458	// field is required on insertion.
7459	Url string `json:"url,omitempty"`
7460
7461	// UrlEscapeLevels: Number of times the landing page URL should be
7462	// URL-escaped before being appended to the click-through event tag URL.
7463	// Only applies to click-through event tags as specified by the event
7464	// tag type.
7465	UrlEscapeLevels int64 `json:"urlEscapeLevels,omitempty"`
7466
7467	// ServerResponse contains the HTTP response code and headers from the
7468	// server.
7469	googleapi.ServerResponse `json:"-"`
7470
7471	// ForceSendFields is a list of field names (e.g. "AccountId") to
7472	// unconditionally include in API requests. By default, fields with
7473	// empty or default values are omitted from API requests. However, any
7474	// non-pointer, non-interface field appearing in ForceSendFields will be
7475	// sent to the server regardless of whether the field is empty or not.
7476	// This may be used to include empty fields in Patch requests.
7477	ForceSendFields []string `json:"-"`
7478
7479	// NullFields is a list of field names (e.g. "AccountId") to include in
7480	// API requests with the JSON null value. By default, fields with empty
7481	// values are omitted from API requests. However, any field with an
7482	// empty value appearing in NullFields will be sent to the server as
7483	// null. It is an error if a field in this list has a non-empty value.
7484	// This may be used to include null fields in Patch requests.
7485	NullFields []string `json:"-"`
7486}
7487
7488func (s *EventTag) MarshalJSON() ([]byte, error) {
7489	type NoMethod EventTag
7490	raw := NoMethod(*s)
7491	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7492}
7493
7494// EventTagOverride: Event tag override information.
7495type EventTagOverride struct {
7496	// Enabled: Whether this override is enabled.
7497	Enabled bool `json:"enabled,omitempty"`
7498
7499	// Id: ID of this event tag override. This is a read-only,
7500	// auto-generated field.
7501	Id int64 `json:"id,omitempty,string"`
7502
7503	// ForceSendFields is a list of field names (e.g. "Enabled") to
7504	// unconditionally include in API requests. By default, fields with
7505	// empty or default values are omitted from API requests. However, any
7506	// non-pointer, non-interface field appearing in ForceSendFields will be
7507	// sent to the server regardless of whether the field is empty or not.
7508	// This may be used to include empty fields in Patch requests.
7509	ForceSendFields []string `json:"-"`
7510
7511	// NullFields is a list of field names (e.g. "Enabled") to include in
7512	// API requests with the JSON null value. By default, fields with empty
7513	// values are omitted from API requests. However, any field with an
7514	// empty value appearing in NullFields will be sent to the server as
7515	// null. It is an error if a field in this list has a non-empty value.
7516	// This may be used to include null fields in Patch requests.
7517	NullFields []string `json:"-"`
7518}
7519
7520func (s *EventTagOverride) MarshalJSON() ([]byte, error) {
7521	type NoMethod EventTagOverride
7522	raw := NoMethod(*s)
7523	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7524}
7525
7526// EventTagsListResponse: Event Tag List Response
7527type EventTagsListResponse struct {
7528	// EventTags: Event tag collection.
7529	EventTags []*EventTag `json:"eventTags,omitempty"`
7530
7531	// Kind: Identifies what kind of resource this is. Value: the fixed
7532	// string "dfareporting#eventTagsListResponse".
7533	Kind string `json:"kind,omitempty"`
7534
7535	// ServerResponse contains the HTTP response code and headers from the
7536	// server.
7537	googleapi.ServerResponse `json:"-"`
7538
7539	// ForceSendFields is a list of field names (e.g. "EventTags") to
7540	// unconditionally include in API requests. By default, fields with
7541	// empty or default values are omitted from API requests. However, any
7542	// non-pointer, non-interface field appearing in ForceSendFields will be
7543	// sent to the server regardless of whether the field is empty or not.
7544	// This may be used to include empty fields in Patch requests.
7545	ForceSendFields []string `json:"-"`
7546
7547	// NullFields is a list of field names (e.g. "EventTags") to include in
7548	// API requests with the JSON null value. By default, fields with empty
7549	// values are omitted from API requests. However, any field with an
7550	// empty value appearing in NullFields will be sent to the server as
7551	// null. It is an error if a field in this list has a non-empty value.
7552	// This may be used to include null fields in Patch requests.
7553	NullFields []string `json:"-"`
7554}
7555
7556func (s *EventTagsListResponse) MarshalJSON() ([]byte, error) {
7557	type NoMethod EventTagsListResponse
7558	raw := NoMethod(*s)
7559	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7560}
7561
7562// File: Represents a File resource. A file contains the metadata for a
7563// report run. It shows the status of the run and holds the URLs to the
7564// generated report data if the run is finished and the status is
7565// "REPORT_AVAILABLE".
7566type File struct {
7567	// DateRange: The date range for which the file has report data. The
7568	// date range will always be the absolute date range for which the
7569	// report is run.
7570	DateRange *DateRange `json:"dateRange,omitempty"`
7571
7572	// Etag: Etag of this resource.
7573	Etag string `json:"etag,omitempty"`
7574
7575	// FileName: The filename of the file.
7576	FileName string `json:"fileName,omitempty"`
7577
7578	// Format: The output format of the report. Only available once the file
7579	// is available.
7580	//
7581	// Possible values:
7582	//   "CSV"
7583	//   "EXCEL"
7584	Format string `json:"format,omitempty"`
7585
7586	// Id: The unique ID of this report file.
7587	Id int64 `json:"id,omitempty,string"`
7588
7589	// Kind: Identifies what kind of resource this is. Value: the fixed
7590	// string "dfareporting#file".
7591	Kind string `json:"kind,omitempty"`
7592
7593	// LastModifiedTime: The timestamp in milliseconds since epoch when this
7594	// file was last modified.
7595	LastModifiedTime int64 `json:"lastModifiedTime,omitempty,string"`
7596
7597	// ReportId: The ID of the report this file was generated from.
7598	ReportId int64 `json:"reportId,omitempty,string"`
7599
7600	// Status: The status of the report file.
7601	//
7602	// Possible values:
7603	//   "PROCESSING"
7604	//   "REPORT_AVAILABLE"
7605	//   "FAILED"
7606	//   "CANCELLED"
7607	Status string `json:"status,omitempty"`
7608
7609	// Urls: The URLs where the completed report file can be downloaded.
7610	Urls *FileUrls `json:"urls,omitempty"`
7611
7612	// ServerResponse contains the HTTP response code and headers from the
7613	// server.
7614	googleapi.ServerResponse `json:"-"`
7615
7616	// ForceSendFields is a list of field names (e.g. "DateRange") to
7617	// unconditionally include in API requests. By default, fields with
7618	// empty or default values are omitted from API requests. However, any
7619	// non-pointer, non-interface field appearing in ForceSendFields will be
7620	// sent to the server regardless of whether the field is empty or not.
7621	// This may be used to include empty fields in Patch requests.
7622	ForceSendFields []string `json:"-"`
7623
7624	// NullFields is a list of field names (e.g. "DateRange") to include in
7625	// API requests with the JSON null value. By default, fields with empty
7626	// values are omitted from API requests. However, any field with an
7627	// empty value appearing in NullFields will be sent to the server as
7628	// null. It is an error if a field in this list has a non-empty value.
7629	// This may be used to include null fields in Patch requests.
7630	NullFields []string `json:"-"`
7631}
7632
7633func (s *File) MarshalJSON() ([]byte, error) {
7634	type NoMethod File
7635	raw := NoMethod(*s)
7636	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7637}
7638
7639// FileUrls: The URLs where the completed report file can be downloaded.
7640type FileUrls struct {
7641	// ApiUrl: The URL for downloading the report data through the API.
7642	ApiUrl string `json:"apiUrl,omitempty"`
7643
7644	// BrowserUrl: The URL for downloading the report data through a
7645	// browser.
7646	BrowserUrl string `json:"browserUrl,omitempty"`
7647
7648	// ForceSendFields is a list of field names (e.g. "ApiUrl") to
7649	// unconditionally include in API requests. By default, fields with
7650	// empty or default values are omitted from API requests. However, any
7651	// non-pointer, non-interface field appearing in ForceSendFields will be
7652	// sent to the server regardless of whether the field is empty or not.
7653	// This may be used to include empty fields in Patch requests.
7654	ForceSendFields []string `json:"-"`
7655
7656	// NullFields is a list of field names (e.g. "ApiUrl") to include in API
7657	// requests with the JSON null value. By default, fields with empty
7658	// values are omitted from API requests. However, any field with an
7659	// empty value appearing in NullFields will be sent to the server as
7660	// null. It is an error if a field in this list has a non-empty value.
7661	// This may be used to include null fields in Patch requests.
7662	NullFields []string `json:"-"`
7663}
7664
7665func (s *FileUrls) MarshalJSON() ([]byte, error) {
7666	type NoMethod FileUrls
7667	raw := NoMethod(*s)
7668	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7669}
7670
7671// FileList: List of files for a report.
7672type FileList struct {
7673	// Etag: Etag of this resource.
7674	Etag string `json:"etag,omitempty"`
7675
7676	// Items: The files returned in this response.
7677	Items []*File `json:"items,omitempty"`
7678
7679	// Kind: Identifies what kind of resource this is. Value: the fixed
7680	// string "dfareporting#fileList".
7681	Kind string `json:"kind,omitempty"`
7682
7683	// NextPageToken: Continuation token used to page through files. To
7684	// retrieve the next page of results, set the next request's "pageToken"
7685	// to the value of this field. The page token is only valid for a
7686	// limited amount of time and should not be persisted.
7687	NextPageToken string `json:"nextPageToken,omitempty"`
7688
7689	// ServerResponse contains the HTTP response code and headers from the
7690	// server.
7691	googleapi.ServerResponse `json:"-"`
7692
7693	// ForceSendFields is a list of field names (e.g. "Etag") to
7694	// unconditionally include in API requests. By default, fields with
7695	// empty or default values are omitted from API requests. However, any
7696	// non-pointer, non-interface field appearing in ForceSendFields will be
7697	// sent to the server regardless of whether the field is empty or not.
7698	// This may be used to include empty fields in Patch requests.
7699	ForceSendFields []string `json:"-"`
7700
7701	// NullFields is a list of field names (e.g. "Etag") to include in API
7702	// requests with the JSON null value. By default, fields with empty
7703	// values are omitted from API requests. However, any field with an
7704	// empty value appearing in NullFields will be sent to the server as
7705	// null. It is an error if a field in this list has a non-empty value.
7706	// This may be used to include null fields in Patch requests.
7707	NullFields []string `json:"-"`
7708}
7709
7710func (s *FileList) MarshalJSON() ([]byte, error) {
7711	type NoMethod FileList
7712	raw := NoMethod(*s)
7713	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7714}
7715
7716// Flight: Flight
7717type Flight struct {
7718	EndDate string `json:"endDate,omitempty"`
7719
7720	// RateOrCost: Rate or cost of this flight.
7721	RateOrCost int64 `json:"rateOrCost,omitempty,string"`
7722
7723	StartDate string `json:"startDate,omitempty"`
7724
7725	// Units: Units of this flight.
7726	Units int64 `json:"units,omitempty,string"`
7727
7728	// ForceSendFields is a list of field names (e.g. "EndDate") to
7729	// unconditionally include in API requests. By default, fields with
7730	// empty or default values are omitted from API requests. However, any
7731	// non-pointer, non-interface field appearing in ForceSendFields will be
7732	// sent to the server regardless of whether the field is empty or not.
7733	// This may be used to include empty fields in Patch requests.
7734	ForceSendFields []string `json:"-"`
7735
7736	// NullFields is a list of field names (e.g. "EndDate") to include in
7737	// API requests with the JSON null value. By default, fields with empty
7738	// values are omitted from API requests. However, any field with an
7739	// empty value appearing in NullFields will be sent to the server as
7740	// null. It is an error if a field in this list has a non-empty value.
7741	// This may be used to include null fields in Patch requests.
7742	NullFields []string `json:"-"`
7743}
7744
7745func (s *Flight) MarshalJSON() ([]byte, error) {
7746	type NoMethod Flight
7747	raw := NoMethod(*s)
7748	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7749}
7750
7751// FloodlightActivitiesGenerateTagResponse: Floodlight Activity
7752// GenerateTag Response
7753type FloodlightActivitiesGenerateTagResponse struct {
7754	// FloodlightActivityTag: Generated tag for this Floodlight activity.
7755	// For global site tags, this is the event snippet.
7756	FloodlightActivityTag string `json:"floodlightActivityTag,omitempty"`
7757
7758	// GlobalSiteTagGlobalSnippet: The global snippet section of a global
7759	// site tag. The global site tag sets new cookies on your domain, which
7760	// will store a unique identifier for a user or the ad click that
7761	// brought the user to your site. Learn more.
7762	GlobalSiteTagGlobalSnippet string `json:"globalSiteTagGlobalSnippet,omitempty"`
7763
7764	// Kind: Identifies what kind of resource this is. Value: the fixed
7765	// string "dfareporting#floodlightActivitiesGenerateTagResponse".
7766	Kind string `json:"kind,omitempty"`
7767
7768	// ServerResponse contains the HTTP response code and headers from the
7769	// server.
7770	googleapi.ServerResponse `json:"-"`
7771
7772	// ForceSendFields is a list of field names (e.g.
7773	// "FloodlightActivityTag") to unconditionally include in API requests.
7774	// By default, fields with empty or default values are omitted from API
7775	// requests. However, any non-pointer, non-interface field appearing in
7776	// ForceSendFields will be sent to the server regardless of whether the
7777	// field is empty or not. This may be used to include empty fields in
7778	// Patch requests.
7779	ForceSendFields []string `json:"-"`
7780
7781	// NullFields is a list of field names (e.g. "FloodlightActivityTag") to
7782	// include in API requests with the JSON null value. By default, fields
7783	// with empty values are omitted from API requests. However, any field
7784	// with an empty value appearing in NullFields will be sent to the
7785	// server as null. It is an error if a field in this list has a
7786	// non-empty value. This may be used to include null fields in Patch
7787	// requests.
7788	NullFields []string `json:"-"`
7789}
7790
7791func (s *FloodlightActivitiesGenerateTagResponse) MarshalJSON() ([]byte, error) {
7792	type NoMethod FloodlightActivitiesGenerateTagResponse
7793	raw := NoMethod(*s)
7794	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7795}
7796
7797// FloodlightActivitiesListResponse: Floodlight Activity List Response
7798type FloodlightActivitiesListResponse struct {
7799	// FloodlightActivities: Floodlight activity collection.
7800	FloodlightActivities []*FloodlightActivity `json:"floodlightActivities,omitempty"`
7801
7802	// Kind: Identifies what kind of resource this is. Value: the fixed
7803	// string "dfareporting#floodlightActivitiesListResponse".
7804	Kind string `json:"kind,omitempty"`
7805
7806	// NextPageToken: Pagination token to be used for the next list
7807	// operation.
7808	NextPageToken string `json:"nextPageToken,omitempty"`
7809
7810	// ServerResponse contains the HTTP response code and headers from the
7811	// server.
7812	googleapi.ServerResponse `json:"-"`
7813
7814	// ForceSendFields is a list of field names (e.g.
7815	// "FloodlightActivities") to unconditionally include in API requests.
7816	// By default, fields with empty or default values are omitted from API
7817	// requests. However, any non-pointer, non-interface field appearing in
7818	// ForceSendFields will be sent to the server regardless of whether the
7819	// field is empty or not. This may be used to include empty fields in
7820	// Patch requests.
7821	ForceSendFields []string `json:"-"`
7822
7823	// NullFields is a list of field names (e.g. "FloodlightActivities") to
7824	// include in API requests with the JSON null value. By default, fields
7825	// with empty values are omitted from API requests. However, any field
7826	// with an empty value appearing in NullFields will be sent to the
7827	// server as null. It is an error if a field in this list has a
7828	// non-empty value. This may be used to include null fields in Patch
7829	// requests.
7830	NullFields []string `json:"-"`
7831}
7832
7833func (s *FloodlightActivitiesListResponse) MarshalJSON() ([]byte, error) {
7834	type NoMethod FloodlightActivitiesListResponse
7835	raw := NoMethod(*s)
7836	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7837}
7838
7839// FloodlightActivity: Contains properties of a Floodlight activity.
7840type FloodlightActivity struct {
7841	// AccountId: Account ID of this floodlight activity. This is a
7842	// read-only field that can be left blank.
7843	AccountId int64 `json:"accountId,omitempty,string"`
7844
7845	// AdvertiserId: Advertiser ID of this floodlight activity. If this
7846	// field is left blank, the value will be copied over either from the
7847	// activity group's advertiser or the existing activity's advertiser.
7848	AdvertiserId int64 `json:"advertiserId,omitempty,string"`
7849
7850	// AdvertiserIdDimensionValue: Dimension value for the ID of the
7851	// advertiser. This is a read-only, auto-generated field.
7852	AdvertiserIdDimensionValue *DimensionValue `json:"advertiserIdDimensionValue,omitempty"`
7853
7854	// AttributionEnabled: Whether the activity is enabled for attribution.
7855	AttributionEnabled bool `json:"attributionEnabled,omitempty"`
7856
7857	// CacheBustingType: Code type used for cache busting in the generated
7858	// tag. Applicable only when floodlightActivityGroupType is COUNTER and
7859	// countingMethod is STANDARD_COUNTING or UNIQUE_COUNTING.
7860	//
7861	// Possible values:
7862	//   "JAVASCRIPT"
7863	//   "ACTIVE_SERVER_PAGE"
7864	//   "JSP"
7865	//   "PHP"
7866	//   "COLD_FUSION"
7867	CacheBustingType string `json:"cacheBustingType,omitempty"`
7868
7869	// CountingMethod: Counting method for conversions for this floodlight
7870	// activity. This is a required field.
7871	//
7872	// Possible values:
7873	//   "STANDARD_COUNTING"
7874	//   "UNIQUE_COUNTING"
7875	//   "SESSION_COUNTING"
7876	//   "TRANSACTIONS_COUNTING"
7877	//   "ITEMS_SOLD_COUNTING"
7878	CountingMethod string `json:"countingMethod,omitempty"`
7879
7880	// DefaultTags: Dynamic floodlight tags.
7881	DefaultTags []*FloodlightActivityDynamicTag `json:"defaultTags,omitempty"`
7882
7883	// ExpectedUrl: URL where this tag will be deployed. If specified, must
7884	// be less than 256 characters long.
7885	ExpectedUrl string `json:"expectedUrl,omitempty"`
7886
7887	// FloodlightActivityGroupId: Floodlight activity group ID of this
7888	// floodlight activity. This is a required field.
7889	FloodlightActivityGroupId int64 `json:"floodlightActivityGroupId,omitempty,string"`
7890
7891	// FloodlightActivityGroupName: Name of the associated floodlight
7892	// activity group. This is a read-only field.
7893	FloodlightActivityGroupName string `json:"floodlightActivityGroupName,omitempty"`
7894
7895	// FloodlightActivityGroupTagString: Tag string of the associated
7896	// floodlight activity group. This is a read-only field.
7897	FloodlightActivityGroupTagString string `json:"floodlightActivityGroupTagString,omitempty"`
7898
7899	// FloodlightActivityGroupType: Type of the associated floodlight
7900	// activity group. This is a read-only field.
7901	//
7902	// Possible values:
7903	//   "COUNTER"
7904	//   "SALE"
7905	FloodlightActivityGroupType string `json:"floodlightActivityGroupType,omitempty"`
7906
7907	// FloodlightConfigurationId: Floodlight configuration ID of this
7908	// floodlight activity. If this field is left blank, the value will be
7909	// copied over either from the activity group's floodlight configuration
7910	// or from the existing activity's floodlight configuration.
7911	FloodlightConfigurationId int64 `json:"floodlightConfigurationId,omitempty,string"`
7912
7913	// FloodlightConfigurationIdDimensionValue: Dimension value for the ID
7914	// of the floodlight configuration. This is a read-only, auto-generated
7915	// field.
7916	FloodlightConfigurationIdDimensionValue *DimensionValue `json:"floodlightConfigurationIdDimensionValue,omitempty"`
7917
7918	// FloodlightTagType: The type of Floodlight tag this activity will
7919	// generate. This is a required field.
7920	//
7921	// Possible values:
7922	//   "IFRAME"
7923	//   "IMAGE"
7924	//   "GLOBAL_SITE_TAG"
7925	FloodlightTagType string `json:"floodlightTagType,omitempty"`
7926
7927	// Id: ID of this floodlight activity. This is a read-only,
7928	// auto-generated field.
7929	Id int64 `json:"id,omitempty,string"`
7930
7931	// IdDimensionValue: Dimension value for the ID of this floodlight
7932	// activity. This is a read-only, auto-generated field.
7933	IdDimensionValue *DimensionValue `json:"idDimensionValue,omitempty"`
7934
7935	// Kind: Identifies what kind of resource this is. Value: the fixed
7936	// string "dfareporting#floodlightActivity".
7937	Kind string `json:"kind,omitempty"`
7938
7939	// Name: Name of this floodlight activity. This is a required field.
7940	// Must be less than 129 characters long and cannot contain quotes.
7941	Name string `json:"name,omitempty"`
7942
7943	// Notes: General notes or implementation instructions for the tag.
7944	Notes string `json:"notes,omitempty"`
7945
7946	// PublisherTags: Publisher dynamic floodlight tags.
7947	PublisherTags []*FloodlightActivityPublisherDynamicTag `json:"publisherTags,omitempty"`
7948
7949	// Secure: Whether this tag should use SSL.
7950	Secure bool `json:"secure,omitempty"`
7951
7952	// SslCompliant: Whether the floodlight activity is SSL-compliant. This
7953	// is a read-only field, its value detected by the system from the
7954	// floodlight tags.
7955	SslCompliant bool `json:"sslCompliant,omitempty"`
7956
7957	// SslRequired: Whether this floodlight activity must be SSL-compliant.
7958	SslRequired bool `json:"sslRequired,omitempty"`
7959
7960	// Status: The status of the activity. This can only be set to ACTIVE or
7961	// ARCHIVED_AND_DISABLED. The ARCHIVED status is no longer supported and
7962	// cannot be set for Floodlight activities. The DISABLED_POLICY status
7963	// indicates that a Floodlight activity is violating Google policy.
7964	// Contact your account manager for more information.
7965	//
7966	// Possible values:
7967	//   "ACTIVE"
7968	//   "ARCHIVED_AND_DISABLED"
7969	//   "ARCHIVED"
7970	//   "DISABLED_POLICY"
7971	Status string `json:"status,omitempty"`
7972
7973	// SubaccountId: Subaccount ID of this floodlight activity. This is a
7974	// read-only field that can be left blank.
7975	SubaccountId int64 `json:"subaccountId,omitempty,string"`
7976
7977	// TagFormat: Tag format type for the floodlight activity. If left
7978	// blank, the tag format will default to HTML.
7979	//
7980	// Possible values:
7981	//   "HTML"
7982	//   "XHTML"
7983	TagFormat string `json:"tagFormat,omitempty"`
7984
7985	// TagString: Value of the cat= parameter in the floodlight tag, which
7986	// the ad servers use to identify the activity. This is optional: if
7987	// empty, a new tag string will be generated for you. This string must
7988	// be 1 to 8 characters long, with valid characters being a-z0-9[ _ ].
7989	// This tag string must also be unique among activities of the same
7990	// activity group. This field is read-only after insertion.
7991	TagString string `json:"tagString,omitempty"`
7992
7993	// UserDefinedVariableTypes: List of the user-defined variables used by
7994	// this conversion tag. These map to the "u[1-100]=" in the tags. Each
7995	// of these can have a user defined type. Acceptable values are U1 to
7996	// U100, inclusive.
7997	//
7998	// Possible values:
7999	//   "U1"
8000	//   "U2"
8001	//   "U3"
8002	//   "U4"
8003	//   "U5"
8004	//   "U6"
8005	//   "U7"
8006	//   "U8"
8007	//   "U9"
8008	//   "U10"
8009	//   "U11"
8010	//   "U12"
8011	//   "U13"
8012	//   "U14"
8013	//   "U15"
8014	//   "U16"
8015	//   "U17"
8016	//   "U18"
8017	//   "U19"
8018	//   "U20"
8019	//   "U21"
8020	//   "U22"
8021	//   "U23"
8022	//   "U24"
8023	//   "U25"
8024	//   "U26"
8025	//   "U27"
8026	//   "U28"
8027	//   "U29"
8028	//   "U30"
8029	//   "U31"
8030	//   "U32"
8031	//   "U33"
8032	//   "U34"
8033	//   "U35"
8034	//   "U36"
8035	//   "U37"
8036	//   "U38"
8037	//   "U39"
8038	//   "U40"
8039	//   "U41"
8040	//   "U42"
8041	//   "U43"
8042	//   "U44"
8043	//   "U45"
8044	//   "U46"
8045	//   "U47"
8046	//   "U48"
8047	//   "U49"
8048	//   "U50"
8049	//   "U51"
8050	//   "U52"
8051	//   "U53"
8052	//   "U54"
8053	//   "U55"
8054	//   "U56"
8055	//   "U57"
8056	//   "U58"
8057	//   "U59"
8058	//   "U60"
8059	//   "U61"
8060	//   "U62"
8061	//   "U63"
8062	//   "U64"
8063	//   "U65"
8064	//   "U66"
8065	//   "U67"
8066	//   "U68"
8067	//   "U69"
8068	//   "U70"
8069	//   "U71"
8070	//   "U72"
8071	//   "U73"
8072	//   "U74"
8073	//   "U75"
8074	//   "U76"
8075	//   "U77"
8076	//   "U78"
8077	//   "U79"
8078	//   "U80"
8079	//   "U81"
8080	//   "U82"
8081	//   "U83"
8082	//   "U84"
8083	//   "U85"
8084	//   "U86"
8085	//   "U87"
8086	//   "U88"
8087	//   "U89"
8088	//   "U90"
8089	//   "U91"
8090	//   "U92"
8091	//   "U93"
8092	//   "U94"
8093	//   "U95"
8094	//   "U96"
8095	//   "U97"
8096	//   "U98"
8097	//   "U99"
8098	//   "U100"
8099	UserDefinedVariableTypes []string `json:"userDefinedVariableTypes,omitempty"`
8100
8101	// ServerResponse contains the HTTP response code and headers from the
8102	// server.
8103	googleapi.ServerResponse `json:"-"`
8104
8105	// ForceSendFields is a list of field names (e.g. "AccountId") to
8106	// unconditionally include in API requests. By default, fields with
8107	// empty or default values are omitted from API requests. However, any
8108	// non-pointer, non-interface field appearing in ForceSendFields will be
8109	// sent to the server regardless of whether the field is empty or not.
8110	// This may be used to include empty fields in Patch requests.
8111	ForceSendFields []string `json:"-"`
8112
8113	// NullFields is a list of field names (e.g. "AccountId") to include in
8114	// API requests with the JSON null value. By default, fields with empty
8115	// values are omitted from API requests. However, any field with an
8116	// empty value appearing in NullFields will be sent to the server as
8117	// null. It is an error if a field in this list has a non-empty value.
8118	// This may be used to include null fields in Patch requests.
8119	NullFields []string `json:"-"`
8120}
8121
8122func (s *FloodlightActivity) MarshalJSON() ([]byte, error) {
8123	type NoMethod FloodlightActivity
8124	raw := NoMethod(*s)
8125	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8126}
8127
8128// FloodlightActivityDynamicTag: Dynamic Tag
8129type FloodlightActivityDynamicTag struct {
8130	// Id: ID of this dynamic tag. This is a read-only, auto-generated
8131	// field.
8132	Id int64 `json:"id,omitempty,string"`
8133
8134	// Name: Name of this tag.
8135	Name string `json:"name,omitempty"`
8136
8137	// Tag: Tag code.
8138	Tag string `json:"tag,omitempty"`
8139
8140	// ForceSendFields is a list of field names (e.g. "Id") to
8141	// unconditionally include in API requests. By default, fields with
8142	// empty or default values are omitted from API requests. However, any
8143	// non-pointer, non-interface field appearing in ForceSendFields will be
8144	// sent to the server regardless of whether the field is empty or not.
8145	// This may be used to include empty fields in Patch requests.
8146	ForceSendFields []string `json:"-"`
8147
8148	// NullFields is a list of field names (e.g. "Id") to include in API
8149	// requests with the JSON null value. By default, fields with empty
8150	// values are omitted from API requests. However, any field with an
8151	// empty value appearing in NullFields will be sent to the server as
8152	// null. It is an error if a field in this list has a non-empty value.
8153	// This may be used to include null fields in Patch requests.
8154	NullFields []string `json:"-"`
8155}
8156
8157func (s *FloodlightActivityDynamicTag) MarshalJSON() ([]byte, error) {
8158	type NoMethod FloodlightActivityDynamicTag
8159	raw := NoMethod(*s)
8160	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8161}
8162
8163// FloodlightActivityGroup: Contains properties of a Floodlight activity
8164// group.
8165type FloodlightActivityGroup struct {
8166	// AccountId: Account ID of this floodlight activity group. This is a
8167	// read-only field that can be left blank.
8168	AccountId int64 `json:"accountId,omitempty,string"`
8169
8170	// AdvertiserId: Advertiser ID of this floodlight activity group. If
8171	// this field is left blank, the value will be copied over either from
8172	// the floodlight configuration's advertiser or from the existing
8173	// activity group's advertiser.
8174	AdvertiserId int64 `json:"advertiserId,omitempty,string"`
8175
8176	// AdvertiserIdDimensionValue: Dimension value for the ID of the
8177	// advertiser. This is a read-only, auto-generated field.
8178	AdvertiserIdDimensionValue *DimensionValue `json:"advertiserIdDimensionValue,omitempty"`
8179
8180	// FloodlightConfigurationId: Floodlight configuration ID of this
8181	// floodlight activity group. This is a required field.
8182	FloodlightConfigurationId int64 `json:"floodlightConfigurationId,omitempty,string"`
8183
8184	// FloodlightConfigurationIdDimensionValue: Dimension value for the ID
8185	// of the floodlight configuration. This is a read-only, auto-generated
8186	// field.
8187	FloodlightConfigurationIdDimensionValue *DimensionValue `json:"floodlightConfigurationIdDimensionValue,omitempty"`
8188
8189	// Id: ID of this floodlight activity group. This is a read-only,
8190	// auto-generated field.
8191	Id int64 `json:"id,omitempty,string"`
8192
8193	// IdDimensionValue: Dimension value for the ID of this floodlight
8194	// activity group. This is a read-only, auto-generated field.
8195	IdDimensionValue *DimensionValue `json:"idDimensionValue,omitempty"`
8196
8197	// Kind: Identifies what kind of resource this is. Value: the fixed
8198	// string "dfareporting#floodlightActivityGroup".
8199	Kind string `json:"kind,omitempty"`
8200
8201	// Name: Name of this floodlight activity group. This is a required
8202	// field. Must be less than 65 characters long and cannot contain
8203	// quotes.
8204	Name string `json:"name,omitempty"`
8205
8206	// SubaccountId: Subaccount ID of this floodlight activity group. This
8207	// is a read-only field that can be left blank.
8208	SubaccountId int64 `json:"subaccountId,omitempty,string"`
8209
8210	// TagString: Value of the type= parameter in the floodlight tag, which
8211	// the ad servers use to identify the activity group that the activity
8212	// belongs to. This is optional: if empty, a new tag string will be
8213	// generated for you. This string must be 1 to 8 characters long, with
8214	// valid characters being a-z0-9[ _ ]. This tag string must also be
8215	// unique among activity groups of the same floodlight configuration.
8216	// This field is read-only after insertion.
8217	TagString string `json:"tagString,omitempty"`
8218
8219	// Type: Type of the floodlight activity group. This is a required field
8220	// that is read-only after insertion.
8221	//
8222	// Possible values:
8223	//   "COUNTER"
8224	//   "SALE"
8225	Type string `json:"type,omitempty"`
8226
8227	// ServerResponse contains the HTTP response code and headers from the
8228	// server.
8229	googleapi.ServerResponse `json:"-"`
8230
8231	// ForceSendFields is a list of field names (e.g. "AccountId") to
8232	// unconditionally include in API requests. By default, fields with
8233	// empty or default values are omitted from API requests. However, any
8234	// non-pointer, non-interface field appearing in ForceSendFields will be
8235	// sent to the server regardless of whether the field is empty or not.
8236	// This may be used to include empty fields in Patch requests.
8237	ForceSendFields []string `json:"-"`
8238
8239	// NullFields is a list of field names (e.g. "AccountId") to include in
8240	// API requests with the JSON null value. By default, fields with empty
8241	// values are omitted from API requests. However, any field with an
8242	// empty value appearing in NullFields will be sent to the server as
8243	// null. It is an error if a field in this list has a non-empty value.
8244	// This may be used to include null fields in Patch requests.
8245	NullFields []string `json:"-"`
8246}
8247
8248func (s *FloodlightActivityGroup) MarshalJSON() ([]byte, error) {
8249	type NoMethod FloodlightActivityGroup
8250	raw := NoMethod(*s)
8251	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8252}
8253
8254// FloodlightActivityGroupsListResponse: Floodlight Activity Group List
8255// Response
8256type FloodlightActivityGroupsListResponse struct {
8257	// FloodlightActivityGroups: Floodlight activity group collection.
8258	FloodlightActivityGroups []*FloodlightActivityGroup `json:"floodlightActivityGroups,omitempty"`
8259
8260	// Kind: Identifies what kind of resource this is. Value: the fixed
8261	// string "dfareporting#floodlightActivityGroupsListResponse".
8262	Kind string `json:"kind,omitempty"`
8263
8264	// NextPageToken: Pagination token to be used for the next list
8265	// operation.
8266	NextPageToken string `json:"nextPageToken,omitempty"`
8267
8268	// ServerResponse contains the HTTP response code and headers from the
8269	// server.
8270	googleapi.ServerResponse `json:"-"`
8271
8272	// ForceSendFields is a list of field names (e.g.
8273	// "FloodlightActivityGroups") to unconditionally include in API
8274	// requests. By default, fields with empty or default values are omitted
8275	// from API requests. However, any non-pointer, non-interface field
8276	// appearing in ForceSendFields will be sent to the server regardless of
8277	// whether the field is empty or not. This may be used to include empty
8278	// fields in Patch requests.
8279	ForceSendFields []string `json:"-"`
8280
8281	// NullFields is a list of field names (e.g. "FloodlightActivityGroups")
8282	// to include in API requests with the JSON null value. By default,
8283	// fields with empty values are omitted from API requests. However, any
8284	// field with an empty value appearing in NullFields will be sent to the
8285	// server as null. It is an error if a field in this list has a
8286	// non-empty value. This may be used to include null fields in Patch
8287	// requests.
8288	NullFields []string `json:"-"`
8289}
8290
8291func (s *FloodlightActivityGroupsListResponse) MarshalJSON() ([]byte, error) {
8292	type NoMethod FloodlightActivityGroupsListResponse
8293	raw := NoMethod(*s)
8294	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8295}
8296
8297// FloodlightActivityPublisherDynamicTag: Publisher Dynamic Tag
8298type FloodlightActivityPublisherDynamicTag struct {
8299	// ClickThrough: Whether this tag is applicable only for click-throughs.
8300	ClickThrough bool `json:"clickThrough,omitempty"`
8301
8302	// DirectorySiteId: Directory site ID of this dynamic tag. This is a
8303	// write-only field that can be used as an alternative to the siteId
8304	// field. When this resource is retrieved, only the siteId field will be
8305	// populated.
8306	DirectorySiteId int64 `json:"directorySiteId,omitempty,string"`
8307
8308	// DynamicTag: Dynamic floodlight tag.
8309	DynamicTag *FloodlightActivityDynamicTag `json:"dynamicTag,omitempty"`
8310
8311	// SiteId: Site ID of this dynamic tag.
8312	SiteId int64 `json:"siteId,omitempty,string"`
8313
8314	// SiteIdDimensionValue: Dimension value for the ID of the site. This is
8315	// a read-only, auto-generated field.
8316	SiteIdDimensionValue *DimensionValue `json:"siteIdDimensionValue,omitempty"`
8317
8318	// ViewThrough: Whether this tag is applicable only for view-throughs.
8319	ViewThrough bool `json:"viewThrough,omitempty"`
8320
8321	// ForceSendFields is a list of field names (e.g. "ClickThrough") to
8322	// unconditionally include in API requests. By default, fields with
8323	// empty or default values are omitted from API requests. However, any
8324	// non-pointer, non-interface field appearing in ForceSendFields will be
8325	// sent to the server regardless of whether the field is empty or not.
8326	// This may be used to include empty fields in Patch requests.
8327	ForceSendFields []string `json:"-"`
8328
8329	// NullFields is a list of field names (e.g. "ClickThrough") to include
8330	// in API requests with the JSON null value. By default, fields with
8331	// empty values are omitted from API requests. However, any field with
8332	// an empty value appearing in NullFields will be sent to the server as
8333	// null. It is an error if a field in this list has a non-empty value.
8334	// This may be used to include null fields in Patch requests.
8335	NullFields []string `json:"-"`
8336}
8337
8338func (s *FloodlightActivityPublisherDynamicTag) MarshalJSON() ([]byte, error) {
8339	type NoMethod FloodlightActivityPublisherDynamicTag
8340	raw := NoMethod(*s)
8341	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8342}
8343
8344// FloodlightConfiguration: Contains properties of a Floodlight
8345// configuration.
8346type FloodlightConfiguration struct {
8347	// AccountId: Account ID of this floodlight configuration. This is a
8348	// read-only field that can be left blank.
8349	AccountId int64 `json:"accountId,omitempty,string"`
8350
8351	// AdvertiserId: Advertiser ID of the parent advertiser of this
8352	// floodlight configuration.
8353	AdvertiserId int64 `json:"advertiserId,omitempty,string"`
8354
8355	// AdvertiserIdDimensionValue: Dimension value for the ID of the
8356	// advertiser. This is a read-only, auto-generated field.
8357	AdvertiserIdDimensionValue *DimensionValue `json:"advertiserIdDimensionValue,omitempty"`
8358
8359	// AnalyticsDataSharingEnabled: Whether advertiser data is shared with
8360	// Google Analytics.
8361	AnalyticsDataSharingEnabled bool `json:"analyticsDataSharingEnabled,omitempty"`
8362
8363	// CustomViewabilityMetric: Custom Viewability metric for the floodlight
8364	// configuration.
8365	CustomViewabilityMetric *CustomViewabilityMetric `json:"customViewabilityMetric,omitempty"`
8366
8367	// ExposureToConversionEnabled: Whether the exposure-to-conversion
8368	// report is enabled. This report shows detailed pathway information on
8369	// up to 10 of the most recent ad exposures seen by a user before
8370	// converting.
8371	ExposureToConversionEnabled bool `json:"exposureToConversionEnabled,omitempty"`
8372
8373	// FirstDayOfWeek: Day that will be counted as the first day of the week
8374	// in reports. This is a required field.
8375	//
8376	// Possible values:
8377	//   "MONDAY"
8378	//   "SUNDAY"
8379	FirstDayOfWeek string `json:"firstDayOfWeek,omitempty"`
8380
8381	// Id: ID of this floodlight configuration. This is a read-only,
8382	// auto-generated field.
8383	Id int64 `json:"id,omitempty,string"`
8384
8385	// IdDimensionValue: Dimension value for the ID of this floodlight
8386	// configuration. This is a read-only, auto-generated field.
8387	IdDimensionValue *DimensionValue `json:"idDimensionValue,omitempty"`
8388
8389	// InAppAttributionTrackingEnabled: Whether in-app attribution tracking
8390	// is enabled.
8391	InAppAttributionTrackingEnabled bool `json:"inAppAttributionTrackingEnabled,omitempty"`
8392
8393	// Kind: Identifies what kind of resource this is. Value: the fixed
8394	// string "dfareporting#floodlightConfiguration".
8395	Kind string `json:"kind,omitempty"`
8396
8397	// LookbackConfiguration: Lookback window settings for this floodlight
8398	// configuration.
8399	LookbackConfiguration *LookbackConfiguration `json:"lookbackConfiguration,omitempty"`
8400
8401	// NaturalSearchConversionAttributionOption: Types of attribution
8402	// options for natural search conversions.
8403	//
8404	// Possible values:
8405	//   "EXCLUDE_NATURAL_SEARCH_CONVERSION_ATTRIBUTION"
8406	//   "INCLUDE_NATURAL_SEARCH_CONVERSION_ATTRIBUTION"
8407	//   "INCLUDE_NATURAL_SEARCH_TIERED_CONVERSION_ATTRIBUTION"
8408	NaturalSearchConversionAttributionOption string `json:"naturalSearchConversionAttributionOption,omitempty"`
8409
8410	// OmnitureSettings: Settings for Campaign Manager Omniture integration.
8411	OmnitureSettings *OmnitureSettings `json:"omnitureSettings,omitempty"`
8412
8413	// SubaccountId: Subaccount ID of this floodlight configuration. This is
8414	// a read-only field that can be left blank.
8415	SubaccountId int64 `json:"subaccountId,omitempty,string"`
8416
8417	// TagSettings: Configuration settings for dynamic and image floodlight
8418	// tags.
8419	TagSettings *TagSettings `json:"tagSettings,omitempty"`
8420
8421	// ThirdPartyAuthenticationTokens: List of third-party authentication
8422	// tokens enabled for this configuration.
8423	ThirdPartyAuthenticationTokens []*ThirdPartyAuthenticationToken `json:"thirdPartyAuthenticationTokens,omitempty"`
8424
8425	// UserDefinedVariableConfigurations: List of user defined variables
8426	// enabled for this configuration.
8427	UserDefinedVariableConfigurations []*UserDefinedVariableConfiguration `json:"userDefinedVariableConfigurations,omitempty"`
8428
8429	// ServerResponse contains the HTTP response code and headers from the
8430	// server.
8431	googleapi.ServerResponse `json:"-"`
8432
8433	// ForceSendFields is a list of field names (e.g. "AccountId") to
8434	// unconditionally include in API requests. By default, fields with
8435	// empty or default values are omitted from API requests. However, any
8436	// non-pointer, non-interface field appearing in ForceSendFields will be
8437	// sent to the server regardless of whether the field is empty or not.
8438	// This may be used to include empty fields in Patch requests.
8439	ForceSendFields []string `json:"-"`
8440
8441	// NullFields is a list of field names (e.g. "AccountId") to include in
8442	// API requests with the JSON null value. By default, fields with empty
8443	// values are omitted from API requests. However, any field with an
8444	// empty value appearing in NullFields will be sent to the server as
8445	// null. It is an error if a field in this list has a non-empty value.
8446	// This may be used to include null fields in Patch requests.
8447	NullFields []string `json:"-"`
8448}
8449
8450func (s *FloodlightConfiguration) MarshalJSON() ([]byte, error) {
8451	type NoMethod FloodlightConfiguration
8452	raw := NoMethod(*s)
8453	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8454}
8455
8456// FloodlightConfigurationsListResponse: Floodlight Configuration List
8457// Response
8458type FloodlightConfigurationsListResponse struct {
8459	// FloodlightConfigurations: Floodlight configuration collection.
8460	FloodlightConfigurations []*FloodlightConfiguration `json:"floodlightConfigurations,omitempty"`
8461
8462	// Kind: Identifies what kind of resource this is. Value: the fixed
8463	// string "dfareporting#floodlightConfigurationsListResponse".
8464	Kind string `json:"kind,omitempty"`
8465
8466	// ServerResponse contains the HTTP response code and headers from the
8467	// server.
8468	googleapi.ServerResponse `json:"-"`
8469
8470	// ForceSendFields is a list of field names (e.g.
8471	// "FloodlightConfigurations") to unconditionally include in API
8472	// requests. By default, fields with empty or default values are omitted
8473	// from API requests. However, any non-pointer, non-interface field
8474	// appearing in ForceSendFields will be sent to the server regardless of
8475	// whether the field is empty or not. This may be used to include empty
8476	// fields in Patch requests.
8477	ForceSendFields []string `json:"-"`
8478
8479	// NullFields is a list of field names (e.g. "FloodlightConfigurations")
8480	// to include in API requests with the JSON null value. By default,
8481	// fields with empty values are omitted from API requests. However, any
8482	// field with an empty value appearing in NullFields will be sent to the
8483	// server as null. It is an error if a field in this list has a
8484	// non-empty value. This may be used to include null fields in Patch
8485	// requests.
8486	NullFields []string `json:"-"`
8487}
8488
8489func (s *FloodlightConfigurationsListResponse) MarshalJSON() ([]byte, error) {
8490	type NoMethod FloodlightConfigurationsListResponse
8491	raw := NoMethod(*s)
8492	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8493}
8494
8495// FloodlightReportCompatibleFields: Represents fields that are
8496// compatible to be selected for a report of type "FlOODLIGHT".
8497type FloodlightReportCompatibleFields struct {
8498	// DimensionFilters: Dimensions which are compatible to be selected in
8499	// the "dimensionFilters" section of the report.
8500	DimensionFilters []*Dimension `json:"dimensionFilters,omitempty"`
8501
8502	// Dimensions: Dimensions which are compatible to be selected in the
8503	// "dimensions" section of the report.
8504	Dimensions []*Dimension `json:"dimensions,omitempty"`
8505
8506	// Kind: The kind of resource this is, in this case
8507	// dfareporting#floodlightReportCompatibleFields.
8508	Kind string `json:"kind,omitempty"`
8509
8510	// Metrics: Metrics which are compatible to be selected in the
8511	// "metricNames" section of the report.
8512	Metrics []*Metric `json:"metrics,omitempty"`
8513
8514	// ForceSendFields is a list of field names (e.g. "DimensionFilters") to
8515	// unconditionally include in API requests. By default, fields with
8516	// empty or default values are omitted from API requests. However, any
8517	// non-pointer, non-interface field appearing in ForceSendFields will be
8518	// sent to the server regardless of whether the field is empty or not.
8519	// This may be used to include empty fields in Patch requests.
8520	ForceSendFields []string `json:"-"`
8521
8522	// NullFields is a list of field names (e.g. "DimensionFilters") to
8523	// include in API requests with the JSON null value. By default, fields
8524	// with empty values are omitted from API requests. However, any field
8525	// with an empty value appearing in NullFields will be sent to the
8526	// server as null. It is an error if a field in this list has a
8527	// non-empty value. This may be used to include null fields in Patch
8528	// requests.
8529	NullFields []string `json:"-"`
8530}
8531
8532func (s *FloodlightReportCompatibleFields) MarshalJSON() ([]byte, error) {
8533	type NoMethod FloodlightReportCompatibleFields
8534	raw := NoMethod(*s)
8535	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8536}
8537
8538// FrequencyCap: Frequency Cap.
8539type FrequencyCap struct {
8540	// Duration: Duration of time, in seconds, for this frequency cap. The
8541	// maximum duration is 90 days. Acceptable values are 1 to 7776000,
8542	// inclusive.
8543	Duration int64 `json:"duration,omitempty,string"`
8544
8545	// Impressions: Number of times an individual user can be served the ad
8546	// within the specified duration. Acceptable values are 1 to 15,
8547	// inclusive.
8548	Impressions int64 `json:"impressions,omitempty,string"`
8549
8550	// ForceSendFields is a list of field names (e.g. "Duration") to
8551	// unconditionally include in API requests. By default, fields with
8552	// empty or default values are omitted from API requests. However, any
8553	// non-pointer, non-interface field appearing in ForceSendFields will be
8554	// sent to the server regardless of whether the field is empty or not.
8555	// This may be used to include empty fields in Patch requests.
8556	ForceSendFields []string `json:"-"`
8557
8558	// NullFields is a list of field names (e.g. "Duration") to include in
8559	// API requests with the JSON null value. By default, fields with empty
8560	// values are omitted from API requests. However, any field with an
8561	// empty value appearing in NullFields will be sent to the server as
8562	// null. It is an error if a field in this list has a non-empty value.
8563	// This may be used to include null fields in Patch requests.
8564	NullFields []string `json:"-"`
8565}
8566
8567func (s *FrequencyCap) MarshalJSON() ([]byte, error) {
8568	type NoMethod FrequencyCap
8569	raw := NoMethod(*s)
8570	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8571}
8572
8573// FsCommand: FsCommand.
8574type FsCommand struct {
8575	// Left: Distance from the left of the browser.Applicable when
8576	// positionOption is DISTANCE_FROM_TOP_LEFT_CORNER.
8577	Left int64 `json:"left,omitempty"`
8578
8579	// PositionOption: Position in the browser where the window will open.
8580	//
8581	// Possible values:
8582	//   "CENTERED"
8583	//   "DISTANCE_FROM_TOP_LEFT_CORNER"
8584	PositionOption string `json:"positionOption,omitempty"`
8585
8586	// Top: Distance from the top of the browser. Applicable when
8587	// positionOption is DISTANCE_FROM_TOP_LEFT_CORNER.
8588	Top int64 `json:"top,omitempty"`
8589
8590	// WindowHeight: Height of the window.
8591	WindowHeight int64 `json:"windowHeight,omitempty"`
8592
8593	// WindowWidth: Width of the window.
8594	WindowWidth int64 `json:"windowWidth,omitempty"`
8595
8596	// ForceSendFields is a list of field names (e.g. "Left") to
8597	// unconditionally include in API requests. By default, fields with
8598	// empty or default values are omitted from API requests. However, any
8599	// non-pointer, non-interface field appearing in ForceSendFields will be
8600	// sent to the server regardless of whether the field is empty or not.
8601	// This may be used to include empty fields in Patch requests.
8602	ForceSendFields []string `json:"-"`
8603
8604	// NullFields is a list of field names (e.g. "Left") to include in API
8605	// requests with the JSON null value. By default, fields with empty
8606	// values are omitted from API requests. However, any field with an
8607	// empty value appearing in NullFields will be sent to the server as
8608	// null. It is an error if a field in this list has a non-empty value.
8609	// This may be used to include null fields in Patch requests.
8610	NullFields []string `json:"-"`
8611}
8612
8613func (s *FsCommand) MarshalJSON() ([]byte, error) {
8614	type NoMethod FsCommand
8615	raw := NoMethod(*s)
8616	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8617}
8618
8619// GeoTargeting: Geographical Targeting.
8620type GeoTargeting struct {
8621	// Cities: Cities to be targeted. For each city only dartId is required.
8622	// The other fields are populated automatically when the ad is inserted
8623	// or updated. If targeting a city, do not target or exclude the country
8624	// of the city, and do not target the metro or region of the city.
8625	Cities []*City `json:"cities,omitempty"`
8626
8627	// Countries: Countries to be targeted or excluded from targeting,
8628	// depending on the setting of the excludeCountries field. For each
8629	// country only dartId is required. The other fields are populated
8630	// automatically when the ad is inserted or updated. If targeting or
8631	// excluding a country, do not target regions, cities, metros, or postal
8632	// codes in the same country.
8633	Countries []*Country `json:"countries,omitempty"`
8634
8635	// ExcludeCountries: Whether or not to exclude the countries in the
8636	// countries field from targeting. If false, the countries field refers
8637	// to countries which will be targeted by the ad.
8638	ExcludeCountries bool `json:"excludeCountries,omitempty"`
8639
8640	// Metros: Metros to be targeted. For each metro only dmaId is required.
8641	// The other fields are populated automatically when the ad is inserted
8642	// or updated. If targeting a metro, do not target or exclude the
8643	// country of the metro.
8644	Metros []*Metro `json:"metros,omitempty"`
8645
8646	// PostalCodes: Postal codes to be targeted. For each postal code only
8647	// id is required. The other fields are populated automatically when the
8648	// ad is inserted or updated. If targeting a postal code, do not target
8649	// or exclude the country of the postal code.
8650	PostalCodes []*PostalCode `json:"postalCodes,omitempty"`
8651
8652	// Regions: Regions to be targeted. For each region only dartId is
8653	// required. The other fields are populated automatically when the ad is
8654	// inserted or updated. If targeting a region, do not target or exclude
8655	// the country of the region.
8656	Regions []*Region `json:"regions,omitempty"`
8657
8658	// ForceSendFields is a list of field names (e.g. "Cities") to
8659	// unconditionally include in API requests. By default, fields with
8660	// empty or default values are omitted from API requests. However, any
8661	// non-pointer, non-interface field appearing in ForceSendFields will be
8662	// sent to the server regardless of whether the field is empty or not.
8663	// This may be used to include empty fields in Patch requests.
8664	ForceSendFields []string `json:"-"`
8665
8666	// NullFields is a list of field names (e.g. "Cities") to include in API
8667	// requests with the JSON null value. By default, fields with empty
8668	// values are omitted from API requests. However, any field with an
8669	// empty value appearing in NullFields will be sent to the server as
8670	// null. It is an error if a field in this list has a non-empty value.
8671	// This may be used to include null fields in Patch requests.
8672	NullFields []string `json:"-"`
8673}
8674
8675func (s *GeoTargeting) MarshalJSON() ([]byte, error) {
8676	type NoMethod GeoTargeting
8677	raw := NoMethod(*s)
8678	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8679}
8680
8681// InventoryItem: Represents a buy from the Planning inventory store.
8682type InventoryItem struct {
8683	// AccountId: Account ID of this inventory item.
8684	AccountId int64 `json:"accountId,omitempty,string"`
8685
8686	// AdSlots: Ad slots of this inventory item. If this inventory item
8687	// represents a standalone placement, there will be exactly one ad slot.
8688	// If this inventory item represents a placement group, there will be
8689	// more than one ad slot, each representing one child placement in that
8690	// placement group.
8691	AdSlots []*AdSlot `json:"adSlots,omitempty"`
8692
8693	// AdvertiserId: Advertiser ID of this inventory item.
8694	AdvertiserId int64 `json:"advertiserId,omitempty,string"`
8695
8696	// ContentCategoryId: Content category ID of this inventory item.
8697	ContentCategoryId int64 `json:"contentCategoryId,omitempty,string"`
8698
8699	// EstimatedClickThroughRate: Estimated click-through rate of this
8700	// inventory item.
8701	EstimatedClickThroughRate int64 `json:"estimatedClickThroughRate,omitempty,string"`
8702
8703	// EstimatedConversionRate: Estimated conversion rate of this inventory
8704	// item.
8705	EstimatedConversionRate int64 `json:"estimatedConversionRate,omitempty,string"`
8706
8707	// Id: ID of this inventory item.
8708	Id int64 `json:"id,omitempty,string"`
8709
8710	// InPlan: Whether this inventory item is in plan.
8711	InPlan bool `json:"inPlan,omitempty"`
8712
8713	// Kind: Identifies what kind of resource this is. Value: the fixed
8714	// string "dfareporting#inventoryItem".
8715	Kind string `json:"kind,omitempty"`
8716
8717	// LastModifiedInfo: Information about the most recent modification of
8718	// this inventory item.
8719	LastModifiedInfo *LastModifiedInfo `json:"lastModifiedInfo,omitempty"`
8720
8721	// Name: Name of this inventory item. For standalone inventory items,
8722	// this is the same name as that of its only ad slot. For group
8723	// inventory items, this can differ from the name of any of its ad
8724	// slots.
8725	Name string `json:"name,omitempty"`
8726
8727	// NegotiationChannelId: Negotiation channel ID of this inventory item.
8728	NegotiationChannelId int64 `json:"negotiationChannelId,omitempty,string"`
8729
8730	// OrderId: Order ID of this inventory item.
8731	OrderId int64 `json:"orderId,omitempty,string"`
8732
8733	// PlacementStrategyId: Placement strategy ID of this inventory item.
8734	PlacementStrategyId int64 `json:"placementStrategyId,omitempty,string"`
8735
8736	// Pricing: Pricing of this inventory item.
8737	Pricing *Pricing `json:"pricing,omitempty"`
8738
8739	// ProjectId: Project ID of this inventory item.
8740	ProjectId int64 `json:"projectId,omitempty,string"`
8741
8742	// RfpId: RFP ID of this inventory item.
8743	RfpId int64 `json:"rfpId,omitempty,string"`
8744
8745	// SiteId: ID of the site this inventory item is associated with.
8746	SiteId int64 `json:"siteId,omitempty,string"`
8747
8748	// SubaccountId: Subaccount ID of this inventory item.
8749	SubaccountId int64 `json:"subaccountId,omitempty,string"`
8750
8751	// Type: Type of inventory item.
8752	//
8753	// Possible values:
8754	//   "PLANNING_PLACEMENT_TYPE_REGULAR"
8755	//   "PLANNING_PLACEMENT_TYPE_CREDIT"
8756	Type string `json:"type,omitempty"`
8757
8758	// ServerResponse contains the HTTP response code and headers from the
8759	// server.
8760	googleapi.ServerResponse `json:"-"`
8761
8762	// ForceSendFields is a list of field names (e.g. "AccountId") to
8763	// unconditionally include in API requests. By default, fields with
8764	// empty or default values are omitted from API requests. However, any
8765	// non-pointer, non-interface field appearing in ForceSendFields will be
8766	// sent to the server regardless of whether the field is empty or not.
8767	// This may be used to include empty fields in Patch requests.
8768	ForceSendFields []string `json:"-"`
8769
8770	// NullFields is a list of field names (e.g. "AccountId") to include in
8771	// API requests with the JSON null value. By default, fields with empty
8772	// values are omitted from API requests. However, any field with an
8773	// empty value appearing in NullFields will be sent to the server as
8774	// null. It is an error if a field in this list has a non-empty value.
8775	// This may be used to include null fields in Patch requests.
8776	NullFields []string `json:"-"`
8777}
8778
8779func (s *InventoryItem) MarshalJSON() ([]byte, error) {
8780	type NoMethod InventoryItem
8781	raw := NoMethod(*s)
8782	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8783}
8784
8785// InventoryItemsListResponse: Inventory item List Response
8786type InventoryItemsListResponse struct {
8787	// InventoryItems: Inventory item collection
8788	InventoryItems []*InventoryItem `json:"inventoryItems,omitempty"`
8789
8790	// Kind: Identifies what kind of resource this is. Value: the fixed
8791	// string "dfareporting#inventoryItemsListResponse".
8792	Kind string `json:"kind,omitempty"`
8793
8794	// NextPageToken: Pagination token to be used for the next list
8795	// operation.
8796	NextPageToken string `json:"nextPageToken,omitempty"`
8797
8798	// ServerResponse contains the HTTP response code and headers from the
8799	// server.
8800	googleapi.ServerResponse `json:"-"`
8801
8802	// ForceSendFields is a list of field names (e.g. "InventoryItems") to
8803	// unconditionally include in API requests. By default, fields with
8804	// empty or default values are omitted from API requests. However, any
8805	// non-pointer, non-interface field appearing in ForceSendFields will be
8806	// sent to the server regardless of whether the field is empty or not.
8807	// This may be used to include empty fields in Patch requests.
8808	ForceSendFields []string `json:"-"`
8809
8810	// NullFields is a list of field names (e.g. "InventoryItems") to
8811	// include in API requests with the JSON null value. By default, fields
8812	// with empty values are omitted from API requests. However, any field
8813	// with an empty value appearing in NullFields will be sent to the
8814	// server as null. It is an error if a field in this list has a
8815	// non-empty value. This may be used to include null fields in Patch
8816	// requests.
8817	NullFields []string `json:"-"`
8818}
8819
8820func (s *InventoryItemsListResponse) MarshalJSON() ([]byte, error) {
8821	type NoMethod InventoryItemsListResponse
8822	raw := NoMethod(*s)
8823	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8824}
8825
8826// KeyValueTargetingExpression: Key Value Targeting Expression.
8827type KeyValueTargetingExpression struct {
8828	// Expression: Keyword expression being targeted by the ad.
8829	Expression string `json:"expression,omitempty"`
8830
8831	// ForceSendFields is a list of field names (e.g. "Expression") to
8832	// unconditionally include in API requests. By default, fields with
8833	// empty or default values are omitted from API requests. However, any
8834	// non-pointer, non-interface field appearing in ForceSendFields will be
8835	// sent to the server regardless of whether the field is empty or not.
8836	// This may be used to include empty fields in Patch requests.
8837	ForceSendFields []string `json:"-"`
8838
8839	// NullFields is a list of field names (e.g. "Expression") to include in
8840	// API requests with the JSON null value. By default, fields with empty
8841	// values are omitted from API requests. However, any field with an
8842	// empty value appearing in NullFields will be sent to the server as
8843	// null. It is an error if a field in this list has a non-empty value.
8844	// This may be used to include null fields in Patch requests.
8845	NullFields []string `json:"-"`
8846}
8847
8848func (s *KeyValueTargetingExpression) MarshalJSON() ([]byte, error) {
8849	type NoMethod KeyValueTargetingExpression
8850	raw := NoMethod(*s)
8851	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8852}
8853
8854// LandingPage: Contains information about where a user's browser is
8855// taken after the user clicks an ad.
8856type LandingPage struct {
8857	// AdvertiserId: Advertiser ID of this landing page. This is a required
8858	// field.
8859	AdvertiserId int64 `json:"advertiserId,omitempty,string"`
8860
8861	// Archived: Whether this landing page has been archived.
8862	Archived bool `json:"archived,omitempty"`
8863
8864	// DeepLinks: Links that will direct the user to a mobile app, if
8865	// installed.
8866	DeepLinks []*DeepLink `json:"deepLinks,omitempty"`
8867
8868	// Id: ID of this landing page. This is a read-only, auto-generated
8869	// field.
8870	Id int64 `json:"id,omitempty,string"`
8871
8872	// Kind: Identifies what kind of resource this is. Value: the fixed
8873	// string "dfareporting#landingPage".
8874	Kind string `json:"kind,omitempty"`
8875
8876	// Name: Name of this landing page. This is a required field. It must be
8877	// less than 256 characters long.
8878	Name string `json:"name,omitempty"`
8879
8880	// Url: URL of this landing page. This is a required field.
8881	Url string `json:"url,omitempty"`
8882
8883	// ServerResponse contains the HTTP response code and headers from the
8884	// server.
8885	googleapi.ServerResponse `json:"-"`
8886
8887	// ForceSendFields is a list of field names (e.g. "AdvertiserId") to
8888	// unconditionally include in API requests. By default, fields with
8889	// empty or default values are omitted from API requests. However, any
8890	// non-pointer, non-interface field appearing in ForceSendFields will be
8891	// sent to the server regardless of whether the field is empty or not.
8892	// This may be used to include empty fields in Patch requests.
8893	ForceSendFields []string `json:"-"`
8894
8895	// NullFields is a list of field names (e.g. "AdvertiserId") to include
8896	// in API requests with the JSON null value. By default, fields with
8897	// empty values are omitted from API requests. However, any field with
8898	// an empty value appearing in NullFields will be sent to the server as
8899	// null. It is an error if a field in this list has a non-empty value.
8900	// This may be used to include null fields in Patch requests.
8901	NullFields []string `json:"-"`
8902}
8903
8904func (s *LandingPage) MarshalJSON() ([]byte, error) {
8905	type NoMethod LandingPage
8906	raw := NoMethod(*s)
8907	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8908}
8909
8910// Language: Contains information about a language that can be targeted
8911// by ads.
8912type Language struct {
8913	// Id: Language ID of this language. This is the ID used for targeting
8914	// and generating reports.
8915	Id int64 `json:"id,omitempty,string"`
8916
8917	// Kind: Identifies what kind of resource this is. Value: the fixed
8918	// string "dfareporting#language".
8919	Kind string `json:"kind,omitempty"`
8920
8921	// LanguageCode: Format of language code is an ISO 639 two-letter
8922	// language code optionally followed by an underscore followed by an ISO
8923	// 3166 code. Examples are "en" for English or "zh_CN" for Simplified
8924	// Chinese.
8925	LanguageCode string `json:"languageCode,omitempty"`
8926
8927	// Name: Name of this language.
8928	Name string `json:"name,omitempty"`
8929
8930	// ForceSendFields is a list of field names (e.g. "Id") to
8931	// unconditionally include in API requests. By default, fields with
8932	// empty or default values are omitted from API requests. However, any
8933	// non-pointer, non-interface field appearing in ForceSendFields will be
8934	// sent to the server regardless of whether the field is empty or not.
8935	// This may be used to include empty fields in Patch requests.
8936	ForceSendFields []string `json:"-"`
8937
8938	// NullFields is a list of field names (e.g. "Id") to include in API
8939	// requests with the JSON null value. By default, fields with empty
8940	// values are omitted from API requests. However, any field with an
8941	// empty value appearing in NullFields will be sent to the server as
8942	// null. It is an error if a field in this list has a non-empty value.
8943	// This may be used to include null fields in Patch requests.
8944	NullFields []string `json:"-"`
8945}
8946
8947func (s *Language) MarshalJSON() ([]byte, error) {
8948	type NoMethod Language
8949	raw := NoMethod(*s)
8950	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8951}
8952
8953// LanguageTargeting: Language Targeting.
8954type LanguageTargeting struct {
8955	// Languages: Languages that this ad targets. For each language only
8956	// languageId is required. The other fields are populated automatically
8957	// when the ad is inserted or updated.
8958	Languages []*Language `json:"languages,omitempty"`
8959
8960	// ForceSendFields is a list of field names (e.g. "Languages") to
8961	// unconditionally include in API requests. By default, fields with
8962	// empty or default values are omitted from API requests. However, any
8963	// non-pointer, non-interface field appearing in ForceSendFields will be
8964	// sent to the server regardless of whether the field is empty or not.
8965	// This may be used to include empty fields in Patch requests.
8966	ForceSendFields []string `json:"-"`
8967
8968	// NullFields is a list of field names (e.g. "Languages") to include in
8969	// API requests with the JSON null value. By default, fields with empty
8970	// values are omitted from API requests. However, any field with an
8971	// empty value appearing in NullFields will be sent to the server as
8972	// null. It is an error if a field in this list has a non-empty value.
8973	// This may be used to include null fields in Patch requests.
8974	NullFields []string `json:"-"`
8975}
8976
8977func (s *LanguageTargeting) MarshalJSON() ([]byte, error) {
8978	type NoMethod LanguageTargeting
8979	raw := NoMethod(*s)
8980	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8981}
8982
8983// LanguagesListResponse: Language List Response
8984type LanguagesListResponse struct {
8985	// Kind: Identifies what kind of resource this is. Value: the fixed
8986	// string "dfareporting#languagesListResponse".
8987	Kind string `json:"kind,omitempty"`
8988
8989	// Languages: Language collection.
8990	Languages []*Language `json:"languages,omitempty"`
8991
8992	// ServerResponse contains the HTTP response code and headers from the
8993	// server.
8994	googleapi.ServerResponse `json:"-"`
8995
8996	// ForceSendFields is a list of field names (e.g. "Kind") to
8997	// unconditionally include in API requests. By default, fields with
8998	// empty or default values are omitted from API requests. However, any
8999	// non-pointer, non-interface field appearing in ForceSendFields will be
9000	// sent to the server regardless of whether the field is empty or not.
9001	// This may be used to include empty fields in Patch requests.
9002	ForceSendFields []string `json:"-"`
9003
9004	// NullFields is a list of field names (e.g. "Kind") to include in API
9005	// requests with the JSON null value. By default, fields with empty
9006	// values are omitted from API requests. However, any field with an
9007	// empty value appearing in NullFields will be sent to the server as
9008	// null. It is an error if a field in this list has a non-empty value.
9009	// This may be used to include null fields in Patch requests.
9010	NullFields []string `json:"-"`
9011}
9012
9013func (s *LanguagesListResponse) MarshalJSON() ([]byte, error) {
9014	type NoMethod LanguagesListResponse
9015	raw := NoMethod(*s)
9016	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9017}
9018
9019// LastModifiedInfo: Modification timestamp.
9020type LastModifiedInfo struct {
9021	// Time: Timestamp of the last change in milliseconds since epoch.
9022	Time int64 `json:"time,omitempty,string"`
9023
9024	// ForceSendFields is a list of field names (e.g. "Time") to
9025	// unconditionally include in API requests. By default, fields with
9026	// empty or default values are omitted from API requests. However, any
9027	// non-pointer, non-interface field appearing in ForceSendFields will be
9028	// sent to the server regardless of whether the field is empty or not.
9029	// This may be used to include empty fields in Patch requests.
9030	ForceSendFields []string `json:"-"`
9031
9032	// NullFields is a list of field names (e.g. "Time") to include in API
9033	// requests with the JSON null value. By default, fields with empty
9034	// values are omitted from API requests. However, any field with an
9035	// empty value appearing in NullFields will be sent to the server as
9036	// null. It is an error if a field in this list has a non-empty value.
9037	// This may be used to include null fields in Patch requests.
9038	NullFields []string `json:"-"`
9039}
9040
9041func (s *LastModifiedInfo) MarshalJSON() ([]byte, error) {
9042	type NoMethod LastModifiedInfo
9043	raw := NoMethod(*s)
9044	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9045}
9046
9047// ListPopulationClause: A group clause made up of list population terms
9048// representing constraints joined by ORs.
9049type ListPopulationClause struct {
9050	// Terms: Terms of this list population clause. Each clause is made up
9051	// of list population terms representing constraints and are joined by
9052	// ORs.
9053	Terms []*ListPopulationTerm `json:"terms,omitempty"`
9054
9055	// ForceSendFields is a list of field names (e.g. "Terms") to
9056	// unconditionally include in API requests. By default, fields with
9057	// empty or default values are omitted from API requests. However, any
9058	// non-pointer, non-interface field appearing in ForceSendFields will be
9059	// sent to the server regardless of whether the field is empty or not.
9060	// This may be used to include empty fields in Patch requests.
9061	ForceSendFields []string `json:"-"`
9062
9063	// NullFields is a list of field names (e.g. "Terms") to include in API
9064	// requests with the JSON null value. By default, fields with empty
9065	// values are omitted from API requests. However, any field with an
9066	// empty value appearing in NullFields will be sent to the server as
9067	// null. It is an error if a field in this list has a non-empty value.
9068	// This may be used to include null fields in Patch requests.
9069	NullFields []string `json:"-"`
9070}
9071
9072func (s *ListPopulationClause) MarshalJSON() ([]byte, error) {
9073	type NoMethod ListPopulationClause
9074	raw := NoMethod(*s)
9075	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9076}
9077
9078// ListPopulationRule: Remarketing List Population Rule.
9079type ListPopulationRule struct {
9080	// FloodlightActivityId: Floodlight activity ID associated with this
9081	// rule. This field can be left blank.
9082	FloodlightActivityId int64 `json:"floodlightActivityId,omitempty,string"`
9083
9084	// FloodlightActivityName: Name of floodlight activity associated with
9085	// this rule. This is a read-only, auto-generated field.
9086	FloodlightActivityName string `json:"floodlightActivityName,omitempty"`
9087
9088	// ListPopulationClauses: Clauses that make up this list population
9089	// rule. Clauses are joined by ANDs, and the clauses themselves are made
9090	// up of list population terms which are joined by ORs.
9091	ListPopulationClauses []*ListPopulationClause `json:"listPopulationClauses,omitempty"`
9092
9093	// ForceSendFields is a list of field names (e.g.
9094	// "FloodlightActivityId") to unconditionally include in API requests.
9095	// By default, fields with empty or default values are omitted from API
9096	// requests. However, any non-pointer, non-interface field appearing in
9097	// ForceSendFields will be sent to the server regardless of whether the
9098	// field is empty or not. This may be used to include empty fields in
9099	// Patch requests.
9100	ForceSendFields []string `json:"-"`
9101
9102	// NullFields is a list of field names (e.g. "FloodlightActivityId") to
9103	// include in API requests with the JSON null value. By default, fields
9104	// with empty values are omitted from API requests. However, any field
9105	// with an empty value appearing in NullFields will be sent to the
9106	// server as null. It is an error if a field in this list has a
9107	// non-empty value. This may be used to include null fields in Patch
9108	// requests.
9109	NullFields []string `json:"-"`
9110}
9111
9112func (s *ListPopulationRule) MarshalJSON() ([]byte, error) {
9113	type NoMethod ListPopulationRule
9114	raw := NoMethod(*s)
9115	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9116}
9117
9118// ListPopulationTerm: Remarketing List Population Rule Term.
9119type ListPopulationTerm struct {
9120	// Contains: Will be true if the term should check if the user is in the
9121	// list and false if the term should check if the user is not in the
9122	// list. This field is only relevant when type is set to
9123	// LIST_MEMBERSHIP_TERM. False by default.
9124	Contains bool `json:"contains,omitempty"`
9125
9126	// Negation: Whether to negate the comparison result of this term during
9127	// rule evaluation. This field is only relevant when type is left unset
9128	// or set to CUSTOM_VARIABLE_TERM or REFERRER_TERM.
9129	Negation bool `json:"negation,omitempty"`
9130
9131	// Operator: Comparison operator of this term. This field is only
9132	// relevant when type is left unset or set to CUSTOM_VARIABLE_TERM or
9133	// REFERRER_TERM.
9134	//
9135	// Possible values:
9136	//   "NUM_EQUALS"
9137	//   "NUM_LESS_THAN"
9138	//   "NUM_LESS_THAN_EQUAL"
9139	//   "NUM_GREATER_THAN"
9140	//   "NUM_GREATER_THAN_EQUAL"
9141	//   "STRING_EQUALS"
9142	//   "STRING_CONTAINS"
9143	Operator string `json:"operator,omitempty"`
9144
9145	// RemarketingListId: ID of the list in question. This field is only
9146	// relevant when type is set to LIST_MEMBERSHIP_TERM.
9147	RemarketingListId int64 `json:"remarketingListId,omitempty,string"`
9148
9149	// Type: List population term type determines the applicable fields in
9150	// this object. If left unset or set to CUSTOM_VARIABLE_TERM, then
9151	// variableName, variableFriendlyName, operator, value, and negation are
9152	// applicable. If set to LIST_MEMBERSHIP_TERM then remarketingListId and
9153	// contains are applicable. If set to REFERRER_TERM then operator,
9154	// value, and negation are applicable.
9155	//
9156	// Possible values:
9157	//   "CUSTOM_VARIABLE_TERM"
9158	//   "LIST_MEMBERSHIP_TERM"
9159	//   "REFERRER_TERM"
9160	Type string `json:"type,omitempty"`
9161
9162	// Value: Literal to compare the variable to. This field is only
9163	// relevant when type is left unset or set to CUSTOM_VARIABLE_TERM or
9164	// REFERRER_TERM.
9165	Value string `json:"value,omitempty"`
9166
9167	// VariableFriendlyName: Friendly name of this term's variable. This is
9168	// a read-only, auto-generated field. This field is only relevant when
9169	// type is left unset or set to CUSTOM_VARIABLE_TERM.
9170	VariableFriendlyName string `json:"variableFriendlyName,omitempty"`
9171
9172	// VariableName: Name of the variable (U1, U2, etc.) being compared in
9173	// this term. This field is only relevant when type is set to null,
9174	// CUSTOM_VARIABLE_TERM or REFERRER_TERM.
9175	VariableName string `json:"variableName,omitempty"`
9176
9177	// ForceSendFields is a list of field names (e.g. "Contains") to
9178	// unconditionally include in API requests. By default, fields with
9179	// empty or default values are omitted from API requests. However, any
9180	// non-pointer, non-interface field appearing in ForceSendFields will be
9181	// sent to the server regardless of whether the field is empty or not.
9182	// This may be used to include empty fields in Patch requests.
9183	ForceSendFields []string `json:"-"`
9184
9185	// NullFields is a list of field names (e.g. "Contains") to include in
9186	// API requests with the JSON null value. By default, fields with empty
9187	// values are omitted from API requests. However, any field with an
9188	// empty value appearing in NullFields will be sent to the server as
9189	// null. It is an error if a field in this list has a non-empty value.
9190	// This may be used to include null fields in Patch requests.
9191	NullFields []string `json:"-"`
9192}
9193
9194func (s *ListPopulationTerm) MarshalJSON() ([]byte, error) {
9195	type NoMethod ListPopulationTerm
9196	raw := NoMethod(*s)
9197	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9198}
9199
9200// ListTargetingExpression: Remarketing List Targeting Expression.
9201type ListTargetingExpression struct {
9202	// Expression: Expression describing which lists are being targeted by
9203	// the ad.
9204	Expression string `json:"expression,omitempty"`
9205
9206	// ForceSendFields is a list of field names (e.g. "Expression") to
9207	// unconditionally include in API requests. By default, fields with
9208	// empty or default values are omitted from API requests. However, any
9209	// non-pointer, non-interface field appearing in ForceSendFields will be
9210	// sent to the server regardless of whether the field is empty or not.
9211	// This may be used to include empty fields in Patch requests.
9212	ForceSendFields []string `json:"-"`
9213
9214	// NullFields is a list of field names (e.g. "Expression") to include in
9215	// API requests with the JSON null value. By default, fields with empty
9216	// values are omitted from API requests. However, any field with an
9217	// empty value appearing in NullFields will be sent to the server as
9218	// null. It is an error if a field in this list has a non-empty value.
9219	// This may be used to include null fields in Patch requests.
9220	NullFields []string `json:"-"`
9221}
9222
9223func (s *ListTargetingExpression) MarshalJSON() ([]byte, error) {
9224	type NoMethod ListTargetingExpression
9225	raw := NoMethod(*s)
9226	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9227}
9228
9229// LookbackConfiguration: Lookback configuration settings.
9230type LookbackConfiguration struct {
9231	// ClickDuration: Lookback window, in days, from the last time a given
9232	// user clicked on one of your ads. If you enter 0, clicks will not be
9233	// considered as triggering events for floodlight tracking. If you leave
9234	// this field blank, the default value for your account will be used.
9235	// Acceptable values are 0 to 90, inclusive.
9236	ClickDuration int64 `json:"clickDuration,omitempty"`
9237
9238	// PostImpressionActivitiesDuration: Lookback window, in days, from the
9239	// last time a given user viewed one of your ads. If you enter 0,
9240	// impressions will not be considered as triggering events for
9241	// floodlight tracking. If you leave this field blank, the default value
9242	// for your account will be used. Acceptable values are 0 to 90,
9243	// inclusive.
9244	PostImpressionActivitiesDuration int64 `json:"postImpressionActivitiesDuration,omitempty"`
9245
9246	// ForceSendFields is a list of field names (e.g. "ClickDuration") to
9247	// unconditionally include in API requests. By default, fields with
9248	// empty or default values are omitted from API requests. However, any
9249	// non-pointer, non-interface field appearing in ForceSendFields will be
9250	// sent to the server regardless of whether the field is empty or not.
9251	// This may be used to include empty fields in Patch requests.
9252	ForceSendFields []string `json:"-"`
9253
9254	// NullFields is a list of field names (e.g. "ClickDuration") to include
9255	// in API requests with the JSON null value. By default, fields with
9256	// empty values are omitted from API requests. However, any field with
9257	// an empty value appearing in NullFields will be sent to the server as
9258	// null. It is an error if a field in this list has a non-empty value.
9259	// This may be used to include null fields in Patch requests.
9260	NullFields []string `json:"-"`
9261}
9262
9263func (s *LookbackConfiguration) MarshalJSON() ([]byte, error) {
9264	type NoMethod LookbackConfiguration
9265	raw := NoMethod(*s)
9266	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9267}
9268
9269// Metric: Represents a metric.
9270type Metric struct {
9271	// Kind: The kind of resource this is, in this case dfareporting#metric.
9272	Kind string `json:"kind,omitempty"`
9273
9274	// Name: The metric name, e.g. dfa:impressions
9275	Name string `json:"name,omitempty"`
9276
9277	// ForceSendFields is a list of field names (e.g. "Kind") to
9278	// unconditionally include in API requests. By default, fields with
9279	// empty or default values are omitted from API requests. However, any
9280	// non-pointer, non-interface field appearing in ForceSendFields will be
9281	// sent to the server regardless of whether the field is empty or not.
9282	// This may be used to include empty fields in Patch requests.
9283	ForceSendFields []string `json:"-"`
9284
9285	// NullFields is a list of field names (e.g. "Kind") to include in API
9286	// requests with the JSON null value. By default, fields with empty
9287	// values are omitted from API requests. However, any field with an
9288	// empty value appearing in NullFields will be sent to the server as
9289	// null. It is an error if a field in this list has a non-empty value.
9290	// This may be used to include null fields in Patch requests.
9291	NullFields []string `json:"-"`
9292}
9293
9294func (s *Metric) MarshalJSON() ([]byte, error) {
9295	type NoMethod Metric
9296	raw := NoMethod(*s)
9297	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9298}
9299
9300// Metro: Contains information about a metro region that can be targeted
9301// by ads.
9302type Metro struct {
9303	// CountryCode: Country code of the country to which this metro region
9304	// belongs.
9305	CountryCode string `json:"countryCode,omitempty"`
9306
9307	// CountryDartId: DART ID of the country to which this metro region
9308	// belongs.
9309	CountryDartId int64 `json:"countryDartId,omitempty,string"`
9310
9311	// DartId: DART ID of this metro region.
9312	DartId int64 `json:"dartId,omitempty,string"`
9313
9314	// DmaId: DMA ID of this metro region. This is the ID used for targeting
9315	// and generating reports, and is equivalent to metro_code.
9316	DmaId int64 `json:"dmaId,omitempty,string"`
9317
9318	// Kind: Identifies what kind of resource this is. Value: the fixed
9319	// string "dfareporting#metro".
9320	Kind string `json:"kind,omitempty"`
9321
9322	// MetroCode: Metro code of this metro region. This is equivalent to
9323	// dma_id.
9324	MetroCode string `json:"metroCode,omitempty"`
9325
9326	// Name: Name of this metro region.
9327	Name string `json:"name,omitempty"`
9328
9329	// ForceSendFields is a list of field names (e.g. "CountryCode") to
9330	// unconditionally include in API requests. By default, fields with
9331	// empty or default values are omitted from API requests. However, any
9332	// non-pointer, non-interface field appearing in ForceSendFields will be
9333	// sent to the server regardless of whether the field is empty or not.
9334	// This may be used to include empty fields in Patch requests.
9335	ForceSendFields []string `json:"-"`
9336
9337	// NullFields is a list of field names (e.g. "CountryCode") to include
9338	// in API requests with the JSON null value. By default, fields with
9339	// empty values are omitted from API requests. However, any field with
9340	// an empty value appearing in NullFields will be sent to the server as
9341	// null. It is an error if a field in this list has a non-empty value.
9342	// This may be used to include null fields in Patch requests.
9343	NullFields []string `json:"-"`
9344}
9345
9346func (s *Metro) MarshalJSON() ([]byte, error) {
9347	type NoMethod Metro
9348	raw := NoMethod(*s)
9349	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9350}
9351
9352// MetrosListResponse: Metro List Response
9353type MetrosListResponse struct {
9354	// Kind: Identifies what kind of resource this is. Value: the fixed
9355	// string "dfareporting#metrosListResponse".
9356	Kind string `json:"kind,omitempty"`
9357
9358	// Metros: Metro collection.
9359	Metros []*Metro `json:"metros,omitempty"`
9360
9361	// ServerResponse contains the HTTP response code and headers from the
9362	// server.
9363	googleapi.ServerResponse `json:"-"`
9364
9365	// ForceSendFields is a list of field names (e.g. "Kind") to
9366	// unconditionally include in API requests. By default, fields with
9367	// empty or default values are omitted from API requests. However, any
9368	// non-pointer, non-interface field appearing in ForceSendFields will be
9369	// sent to the server regardless of whether the field is empty or not.
9370	// This may be used to include empty fields in Patch requests.
9371	ForceSendFields []string `json:"-"`
9372
9373	// NullFields is a list of field names (e.g. "Kind") to include in API
9374	// requests with the JSON null value. By default, fields with empty
9375	// values are omitted from API requests. However, any field with an
9376	// empty value appearing in NullFields will be sent to the server as
9377	// null. It is an error if a field in this list has a non-empty value.
9378	// This may be used to include null fields in Patch requests.
9379	NullFields []string `json:"-"`
9380}
9381
9382func (s *MetrosListResponse) MarshalJSON() ([]byte, error) {
9383	type NoMethod MetrosListResponse
9384	raw := NoMethod(*s)
9385	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9386}
9387
9388// MobileApp: Contains information about a mobile app. Used as a landing
9389// page deep link.
9390type MobileApp struct {
9391	// Directory: Mobile app directory.
9392	//
9393	// Possible values:
9394	//   "UNKNOWN"
9395	//   "APPLE_APP_STORE"
9396	//   "GOOGLE_PLAY_STORE"
9397	Directory string `json:"directory,omitempty"`
9398
9399	// Id: ID of this mobile app.
9400	Id string `json:"id,omitempty"`
9401
9402	// Kind: Identifies what kind of resource this is. Value: the fixed
9403	// string "dfareporting#mobileApp".
9404	Kind string `json:"kind,omitempty"`
9405
9406	// PublisherName: Publisher name.
9407	PublisherName string `json:"publisherName,omitempty"`
9408
9409	// Title: Title of this mobile app.
9410	Title string `json:"title,omitempty"`
9411
9412	// ServerResponse contains the HTTP response code and headers from the
9413	// server.
9414	googleapi.ServerResponse `json:"-"`
9415
9416	// ForceSendFields is a list of field names (e.g. "Directory") to
9417	// unconditionally include in API requests. By default, fields with
9418	// empty or default values are omitted from API requests. However, any
9419	// non-pointer, non-interface field appearing in ForceSendFields will be
9420	// sent to the server regardless of whether the field is empty or not.
9421	// This may be used to include empty fields in Patch requests.
9422	ForceSendFields []string `json:"-"`
9423
9424	// NullFields is a list of field names (e.g. "Directory") to include in
9425	// API requests with the JSON null value. By default, fields with empty
9426	// values are omitted from API requests. However, any field with an
9427	// empty value appearing in NullFields will be sent to the server as
9428	// null. It is an error if a field in this list has a non-empty value.
9429	// This may be used to include null fields in Patch requests.
9430	NullFields []string `json:"-"`
9431}
9432
9433func (s *MobileApp) MarshalJSON() ([]byte, error) {
9434	type NoMethod MobileApp
9435	raw := NoMethod(*s)
9436	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9437}
9438
9439// MobileAppsListResponse: Mobile app List Response
9440type MobileAppsListResponse struct {
9441	// Kind: Identifies what kind of resource this is. Value: the fixed
9442	// string "dfareporting#mobileAppsListResponse".
9443	Kind string `json:"kind,omitempty"`
9444
9445	// MobileApps: Mobile apps collection.
9446	MobileApps []*MobileApp `json:"mobileApps,omitempty"`
9447
9448	// NextPageToken: Pagination token to be used for the next list
9449	// operation.
9450	NextPageToken string `json:"nextPageToken,omitempty"`
9451
9452	// ServerResponse contains the HTTP response code and headers from the
9453	// server.
9454	googleapi.ServerResponse `json:"-"`
9455
9456	// ForceSendFields is a list of field names (e.g. "Kind") to
9457	// unconditionally include in API requests. By default, fields with
9458	// empty or default values are omitted from API requests. However, any
9459	// non-pointer, non-interface field appearing in ForceSendFields will be
9460	// sent to the server regardless of whether the field is empty or not.
9461	// This may be used to include empty fields in Patch requests.
9462	ForceSendFields []string `json:"-"`
9463
9464	// NullFields is a list of field names (e.g. "Kind") to include in API
9465	// requests with the JSON null value. By default, fields with empty
9466	// values are omitted from API requests. However, any field with an
9467	// empty value appearing in NullFields will be sent to the server as
9468	// null. It is an error if a field in this list has a non-empty value.
9469	// This may be used to include null fields in Patch requests.
9470	NullFields []string `json:"-"`
9471}
9472
9473func (s *MobileAppsListResponse) MarshalJSON() ([]byte, error) {
9474	type NoMethod MobileAppsListResponse
9475	raw := NoMethod(*s)
9476	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9477}
9478
9479// MobileCarrier: Contains information about a mobile carrier that can
9480// be targeted by ads.
9481type MobileCarrier struct {
9482	// CountryCode: Country code of the country to which this mobile carrier
9483	// belongs.
9484	CountryCode string `json:"countryCode,omitempty"`
9485
9486	// CountryDartId: DART ID of the country to which this mobile carrier
9487	// belongs.
9488	CountryDartId int64 `json:"countryDartId,omitempty,string"`
9489
9490	// Id: ID of this mobile carrier.
9491	Id int64 `json:"id,omitempty,string"`
9492
9493	// Kind: Identifies what kind of resource this is. Value: the fixed
9494	// string "dfareporting#mobileCarrier".
9495	Kind string `json:"kind,omitempty"`
9496
9497	// Name: Name of this mobile carrier.
9498	Name string `json:"name,omitempty"`
9499
9500	// ServerResponse contains the HTTP response code and headers from the
9501	// server.
9502	googleapi.ServerResponse `json:"-"`
9503
9504	// ForceSendFields is a list of field names (e.g. "CountryCode") to
9505	// unconditionally include in API requests. By default, fields with
9506	// empty or default values are omitted from API requests. However, any
9507	// non-pointer, non-interface field appearing in ForceSendFields will be
9508	// sent to the server regardless of whether the field is empty or not.
9509	// This may be used to include empty fields in Patch requests.
9510	ForceSendFields []string `json:"-"`
9511
9512	// NullFields is a list of field names (e.g. "CountryCode") to include
9513	// in API requests with the JSON null value. By default, fields with
9514	// empty values are omitted from API requests. However, any field with
9515	// an empty value appearing in NullFields will be sent to the server as
9516	// null. It is an error if a field in this list has a non-empty value.
9517	// This may be used to include null fields in Patch requests.
9518	NullFields []string `json:"-"`
9519}
9520
9521func (s *MobileCarrier) MarshalJSON() ([]byte, error) {
9522	type NoMethod MobileCarrier
9523	raw := NoMethod(*s)
9524	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9525}
9526
9527// MobileCarriersListResponse: Mobile Carrier List Response
9528type MobileCarriersListResponse struct {
9529	// Kind: Identifies what kind of resource this is. Value: the fixed
9530	// string "dfareporting#mobileCarriersListResponse".
9531	Kind string `json:"kind,omitempty"`
9532
9533	// MobileCarriers: Mobile carrier collection.
9534	MobileCarriers []*MobileCarrier `json:"mobileCarriers,omitempty"`
9535
9536	// ServerResponse contains the HTTP response code and headers from the
9537	// server.
9538	googleapi.ServerResponse `json:"-"`
9539
9540	// ForceSendFields is a list of field names (e.g. "Kind") to
9541	// unconditionally include in API requests. By default, fields with
9542	// empty or default values are omitted from API requests. However, any
9543	// non-pointer, non-interface field appearing in ForceSendFields will be
9544	// sent to the server regardless of whether the field is empty or not.
9545	// This may be used to include empty fields in Patch requests.
9546	ForceSendFields []string `json:"-"`
9547
9548	// NullFields is a list of field names (e.g. "Kind") to include in API
9549	// requests with the JSON null value. By default, fields with empty
9550	// values are omitted from API requests. However, any field with an
9551	// empty value appearing in NullFields will be sent to the server as
9552	// null. It is an error if a field in this list has a non-empty value.
9553	// This may be used to include null fields in Patch requests.
9554	NullFields []string `json:"-"`
9555}
9556
9557func (s *MobileCarriersListResponse) MarshalJSON() ([]byte, error) {
9558	type NoMethod MobileCarriersListResponse
9559	raw := NoMethod(*s)
9560	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9561}
9562
9563// ObaIcon: Online Behavioral Advertiser icon.
9564type ObaIcon struct {
9565	// IconClickThroughUrl: URL to redirect to when an OBA icon is clicked.
9566	IconClickThroughUrl string `json:"iconClickThroughUrl,omitempty"`
9567
9568	// IconClickTrackingUrl: URL to track click when an OBA icon is clicked.
9569	IconClickTrackingUrl string `json:"iconClickTrackingUrl,omitempty"`
9570
9571	// IconViewTrackingUrl: URL to track view when an OBA icon is clicked.
9572	IconViewTrackingUrl string `json:"iconViewTrackingUrl,omitempty"`
9573
9574	// Program: Identifies the industry initiative that the icon supports.
9575	// For example, AdChoices.
9576	Program string `json:"program,omitempty"`
9577
9578	// ResourceUrl: OBA icon resource URL. Campaign Manager only supports
9579	// image and JavaScript icons. Learn more
9580	ResourceUrl string `json:"resourceUrl,omitempty"`
9581
9582	// Size: OBA icon size.
9583	Size *Size `json:"size,omitempty"`
9584
9585	// XPosition: OBA icon x coordinate position. Accepted values are left
9586	// or right.
9587	XPosition string `json:"xPosition,omitempty"`
9588
9589	// YPosition: OBA icon y coordinate position. Accepted values are top or
9590	// bottom.
9591	YPosition string `json:"yPosition,omitempty"`
9592
9593	// ForceSendFields is a list of field names (e.g. "IconClickThroughUrl")
9594	// to unconditionally include in API requests. By default, fields with
9595	// empty or default values are omitted from API requests. However, any
9596	// non-pointer, non-interface field appearing in ForceSendFields will be
9597	// sent to the server regardless of whether the field is empty or not.
9598	// This may be used to include empty fields in Patch requests.
9599	ForceSendFields []string `json:"-"`
9600
9601	// NullFields is a list of field names (e.g. "IconClickThroughUrl") to
9602	// include in API requests with the JSON null value. By default, fields
9603	// with empty values are omitted from API requests. However, any field
9604	// with an empty value appearing in NullFields will be sent to the
9605	// server as null. It is an error if a field in this list has a
9606	// non-empty value. This may be used to include null fields in Patch
9607	// requests.
9608	NullFields []string `json:"-"`
9609}
9610
9611func (s *ObaIcon) MarshalJSON() ([]byte, error) {
9612	type NoMethod ObaIcon
9613	raw := NoMethod(*s)
9614	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9615}
9616
9617// ObjectFilter: Object Filter.
9618type ObjectFilter struct {
9619	// Kind: Identifies what kind of resource this is. Value: the fixed
9620	// string "dfareporting#objectFilter".
9621	Kind string `json:"kind,omitempty"`
9622
9623	// ObjectIds: Applicable when status is ASSIGNED. The user has access to
9624	// objects with these object IDs.
9625	ObjectIds googleapi.Int64s `json:"objectIds,omitempty"`
9626
9627	// Status: Status of the filter. NONE means the user has access to none
9628	// of the objects. ALL means the user has access to all objects.
9629	// ASSIGNED means the user has access to the objects with IDs in the
9630	// objectIds list.
9631	//
9632	// Possible values:
9633	//   "NONE"
9634	//   "ASSIGNED"
9635	//   "ALL"
9636	Status string `json:"status,omitempty"`
9637
9638	// ForceSendFields is a list of field names (e.g. "Kind") to
9639	// unconditionally include in API requests. By default, fields with
9640	// empty or default values are omitted from API requests. However, any
9641	// non-pointer, non-interface field appearing in ForceSendFields will be
9642	// sent to the server regardless of whether the field is empty or not.
9643	// This may be used to include empty fields in Patch requests.
9644	ForceSendFields []string `json:"-"`
9645
9646	// NullFields is a list of field names (e.g. "Kind") to include in API
9647	// requests with the JSON null value. By default, fields with empty
9648	// values are omitted from API requests. However, any field with an
9649	// empty value appearing in NullFields will be sent to the server as
9650	// null. It is an error if a field in this list has a non-empty value.
9651	// This may be used to include null fields in Patch requests.
9652	NullFields []string `json:"-"`
9653}
9654
9655func (s *ObjectFilter) MarshalJSON() ([]byte, error) {
9656	type NoMethod ObjectFilter
9657	raw := NoMethod(*s)
9658	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9659}
9660
9661// OffsetPosition: Offset Position.
9662type OffsetPosition struct {
9663	// Left: Offset distance from left side of an asset or a window.
9664	Left int64 `json:"left,omitempty"`
9665
9666	// Top: Offset distance from top side of an asset or a window.
9667	Top int64 `json:"top,omitempty"`
9668
9669	// ForceSendFields is a list of field names (e.g. "Left") to
9670	// unconditionally include in API requests. By default, fields with
9671	// empty or default values are omitted from API requests. However, any
9672	// non-pointer, non-interface field appearing in ForceSendFields will be
9673	// sent to the server regardless of whether the field is empty or not.
9674	// This may be used to include empty fields in Patch requests.
9675	ForceSendFields []string `json:"-"`
9676
9677	// NullFields is a list of field names (e.g. "Left") to include in API
9678	// requests with the JSON null value. By default, fields with empty
9679	// values are omitted from API requests. However, any field with an
9680	// empty value appearing in NullFields will be sent to the server as
9681	// null. It is an error if a field in this list has a non-empty value.
9682	// This may be used to include null fields in Patch requests.
9683	NullFields []string `json:"-"`
9684}
9685
9686func (s *OffsetPosition) MarshalJSON() ([]byte, error) {
9687	type NoMethod OffsetPosition
9688	raw := NoMethod(*s)
9689	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9690}
9691
9692// OmnitureSettings: Omniture Integration Settings.
9693type OmnitureSettings struct {
9694	// OmnitureCostDataEnabled: Whether placement cost data will be sent to
9695	// Omniture. This property can be enabled only if
9696	// omnitureIntegrationEnabled is true.
9697	OmnitureCostDataEnabled bool `json:"omnitureCostDataEnabled,omitempty"`
9698
9699	// OmnitureIntegrationEnabled: Whether Omniture integration is enabled.
9700	// This property can be enabled only when the "Advanced Ad Serving"
9701	// account setting is enabled.
9702	OmnitureIntegrationEnabled bool `json:"omnitureIntegrationEnabled,omitempty"`
9703
9704	// ForceSendFields is a list of field names (e.g.
9705	// "OmnitureCostDataEnabled") to unconditionally include in API
9706	// requests. By default, fields with empty or default values are omitted
9707	// from API requests. However, any non-pointer, non-interface field
9708	// appearing in ForceSendFields will be sent to the server regardless of
9709	// whether the field is empty or not. This may be used to include empty
9710	// fields in Patch requests.
9711	ForceSendFields []string `json:"-"`
9712
9713	// NullFields is a list of field names (e.g. "OmnitureCostDataEnabled")
9714	// to include in API requests with the JSON null value. By default,
9715	// fields with empty values are omitted from API requests. However, any
9716	// field with an empty value appearing in NullFields will be sent to the
9717	// server as null. It is an error if a field in this list has a
9718	// non-empty value. This may be used to include null fields in Patch
9719	// requests.
9720	NullFields []string `json:"-"`
9721}
9722
9723func (s *OmnitureSettings) MarshalJSON() ([]byte, error) {
9724	type NoMethod OmnitureSettings
9725	raw := NoMethod(*s)
9726	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9727}
9728
9729// OperatingSystem: Contains information about an operating system that
9730// can be targeted by ads.
9731type OperatingSystem struct {
9732	// DartId: DART ID of this operating system. This is the ID used for
9733	// targeting.
9734	DartId int64 `json:"dartId,omitempty,string"`
9735
9736	// Desktop: Whether this operating system is for desktop.
9737	Desktop bool `json:"desktop,omitempty"`
9738
9739	// Kind: Identifies what kind of resource this is. Value: the fixed
9740	// string "dfareporting#operatingSystem".
9741	Kind string `json:"kind,omitempty"`
9742
9743	// Mobile: Whether this operating system is for mobile.
9744	Mobile bool `json:"mobile,omitempty"`
9745
9746	// Name: Name of this operating system.
9747	Name string `json:"name,omitempty"`
9748
9749	// ServerResponse contains the HTTP response code and headers from the
9750	// server.
9751	googleapi.ServerResponse `json:"-"`
9752
9753	// ForceSendFields is a list of field names (e.g. "DartId") to
9754	// unconditionally include in API requests. By default, fields with
9755	// empty or default values are omitted from API requests. However, any
9756	// non-pointer, non-interface field appearing in ForceSendFields will be
9757	// sent to the server regardless of whether the field is empty or not.
9758	// This may be used to include empty fields in Patch requests.
9759	ForceSendFields []string `json:"-"`
9760
9761	// NullFields is a list of field names (e.g. "DartId") to include in API
9762	// requests with the JSON null value. By default, fields with empty
9763	// values are omitted from API requests. However, any field with an
9764	// empty value appearing in NullFields will be sent to the server as
9765	// null. It is an error if a field in this list has a non-empty value.
9766	// This may be used to include null fields in Patch requests.
9767	NullFields []string `json:"-"`
9768}
9769
9770func (s *OperatingSystem) MarshalJSON() ([]byte, error) {
9771	type NoMethod OperatingSystem
9772	raw := NoMethod(*s)
9773	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9774}
9775
9776// OperatingSystemVersion: Contains information about a particular
9777// version of an operating system that can be targeted by ads.
9778type OperatingSystemVersion struct {
9779	// Id: ID of this operating system version.
9780	Id int64 `json:"id,omitempty,string"`
9781
9782	// Kind: Identifies what kind of resource this is. Value: the fixed
9783	// string "dfareporting#operatingSystemVersion".
9784	Kind string `json:"kind,omitempty"`
9785
9786	// MajorVersion: Major version (leftmost number) of this operating
9787	// system version.
9788	MajorVersion string `json:"majorVersion,omitempty"`
9789
9790	// MinorVersion: Minor version (number after the first dot) of this
9791	// operating system version.
9792	MinorVersion string `json:"minorVersion,omitempty"`
9793
9794	// Name: Name of this operating system version.
9795	Name string `json:"name,omitempty"`
9796
9797	// OperatingSystem: Operating system of this operating system version.
9798	OperatingSystem *OperatingSystem `json:"operatingSystem,omitempty"`
9799
9800	// ServerResponse contains the HTTP response code and headers from the
9801	// server.
9802	googleapi.ServerResponse `json:"-"`
9803
9804	// ForceSendFields is a list of field names (e.g. "Id") to
9805	// unconditionally include in API requests. By default, fields with
9806	// empty or default values are omitted from API requests. However, any
9807	// non-pointer, non-interface field appearing in ForceSendFields will be
9808	// sent to the server regardless of whether the field is empty or not.
9809	// This may be used to include empty fields in Patch requests.
9810	ForceSendFields []string `json:"-"`
9811
9812	// NullFields is a list of field names (e.g. "Id") to include in API
9813	// requests with the JSON null value. By default, fields with empty
9814	// values are omitted from API requests. However, any field with an
9815	// empty value appearing in NullFields will be sent to the server as
9816	// null. It is an error if a field in this list has a non-empty value.
9817	// This may be used to include null fields in Patch requests.
9818	NullFields []string `json:"-"`
9819}
9820
9821func (s *OperatingSystemVersion) MarshalJSON() ([]byte, error) {
9822	type NoMethod OperatingSystemVersion
9823	raw := NoMethod(*s)
9824	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9825}
9826
9827// OperatingSystemVersionsListResponse: Operating System Version List
9828// Response
9829type OperatingSystemVersionsListResponse struct {
9830	// Kind: Identifies what kind of resource this is. Value: the fixed
9831	// string "dfareporting#operatingSystemVersionsListResponse".
9832	Kind string `json:"kind,omitempty"`
9833
9834	// OperatingSystemVersions: Operating system version collection.
9835	OperatingSystemVersions []*OperatingSystemVersion `json:"operatingSystemVersions,omitempty"`
9836
9837	// ServerResponse contains the HTTP response code and headers from the
9838	// server.
9839	googleapi.ServerResponse `json:"-"`
9840
9841	// ForceSendFields is a list of field names (e.g. "Kind") to
9842	// unconditionally include in API requests. By default, fields with
9843	// empty or default values are omitted from API requests. However, any
9844	// non-pointer, non-interface field appearing in ForceSendFields will be
9845	// sent to the server regardless of whether the field is empty or not.
9846	// This may be used to include empty fields in Patch requests.
9847	ForceSendFields []string `json:"-"`
9848
9849	// NullFields is a list of field names (e.g. "Kind") to include in API
9850	// requests with the JSON null value. By default, fields with empty
9851	// values are omitted from API requests. However, any field with an
9852	// empty value appearing in NullFields will be sent to the server as
9853	// null. It is an error if a field in this list has a non-empty value.
9854	// This may be used to include null fields in Patch requests.
9855	NullFields []string `json:"-"`
9856}
9857
9858func (s *OperatingSystemVersionsListResponse) MarshalJSON() ([]byte, error) {
9859	type NoMethod OperatingSystemVersionsListResponse
9860	raw := NoMethod(*s)
9861	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9862}
9863
9864// OperatingSystemsListResponse: Operating System List Response
9865type OperatingSystemsListResponse struct {
9866	// Kind: Identifies what kind of resource this is. Value: the fixed
9867	// string "dfareporting#operatingSystemsListResponse".
9868	Kind string `json:"kind,omitempty"`
9869
9870	// OperatingSystems: Operating system collection.
9871	OperatingSystems []*OperatingSystem `json:"operatingSystems,omitempty"`
9872
9873	// ServerResponse contains the HTTP response code and headers from the
9874	// server.
9875	googleapi.ServerResponse `json:"-"`
9876
9877	// ForceSendFields is a list of field names (e.g. "Kind") to
9878	// unconditionally include in API requests. By default, fields with
9879	// empty or default values are omitted from API requests. However, any
9880	// non-pointer, non-interface field appearing in ForceSendFields will be
9881	// sent to the server regardless of whether the field is empty or not.
9882	// This may be used to include empty fields in Patch requests.
9883	ForceSendFields []string `json:"-"`
9884
9885	// NullFields is a list of field names (e.g. "Kind") to include in API
9886	// requests with the JSON null value. By default, fields with empty
9887	// values are omitted from API requests. However, any field with an
9888	// empty value appearing in NullFields will be sent to the server as
9889	// null. It is an error if a field in this list has a non-empty value.
9890	// This may be used to include null fields in Patch requests.
9891	NullFields []string `json:"-"`
9892}
9893
9894func (s *OperatingSystemsListResponse) MarshalJSON() ([]byte, error) {
9895	type NoMethod OperatingSystemsListResponse
9896	raw := NoMethod(*s)
9897	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9898}
9899
9900// OptimizationActivity: Creative optimization activity.
9901type OptimizationActivity struct {
9902	// FloodlightActivityId: Floodlight activity ID of this optimization
9903	// activity. This is a required field.
9904	FloodlightActivityId int64 `json:"floodlightActivityId,omitempty,string"`
9905
9906	// FloodlightActivityIdDimensionValue: Dimension value for the ID of the
9907	// floodlight activity. This is a read-only, auto-generated field.
9908	FloodlightActivityIdDimensionValue *DimensionValue `json:"floodlightActivityIdDimensionValue,omitempty"`
9909
9910	// Weight: Weight associated with this optimization. The weight assigned
9911	// will be understood in proportion to the weights assigned to the other
9912	// optimization activities. Value must be greater than or equal to 1.
9913	Weight int64 `json:"weight,omitempty"`
9914
9915	// ForceSendFields is a list of field names (e.g.
9916	// "FloodlightActivityId") to unconditionally include in API requests.
9917	// By default, fields with empty or default values are omitted from API
9918	// requests. However, any non-pointer, non-interface field appearing in
9919	// ForceSendFields will be sent to the server regardless of whether the
9920	// field is empty or not. This may be used to include empty fields in
9921	// Patch requests.
9922	ForceSendFields []string `json:"-"`
9923
9924	// NullFields is a list of field names (e.g. "FloodlightActivityId") to
9925	// include in API requests with the JSON null value. By default, fields
9926	// with empty values are omitted from API requests. However, any field
9927	// with an empty value appearing in NullFields will be sent to the
9928	// server as null. It is an error if a field in this list has a
9929	// non-empty value. This may be used to include null fields in Patch
9930	// requests.
9931	NullFields []string `json:"-"`
9932}
9933
9934func (s *OptimizationActivity) MarshalJSON() ([]byte, error) {
9935	type NoMethod OptimizationActivity
9936	raw := NoMethod(*s)
9937	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9938}
9939
9940// Order: Describes properties of a Planning order.
9941type Order struct {
9942	// AccountId: Account ID of this order.
9943	AccountId int64 `json:"accountId,omitempty,string"`
9944
9945	// AdvertiserId: Advertiser ID of this order.
9946	AdvertiserId int64 `json:"advertiserId,omitempty,string"`
9947
9948	// ApproverUserProfileIds: IDs for users that have to approve documents
9949	// created for this order.
9950	ApproverUserProfileIds googleapi.Int64s `json:"approverUserProfileIds,omitempty"`
9951
9952	// BuyerInvoiceId: Buyer invoice ID associated with this order.
9953	BuyerInvoiceId string `json:"buyerInvoiceId,omitempty"`
9954
9955	// BuyerOrganizationName: Name of the buyer organization.
9956	BuyerOrganizationName string `json:"buyerOrganizationName,omitempty"`
9957
9958	// Comments: Comments in this order.
9959	Comments string `json:"comments,omitempty"`
9960
9961	// Contacts: Contacts for this order.
9962	Contacts []*OrderContact `json:"contacts,omitempty"`
9963
9964	// Id: ID of this order. This is a read-only, auto-generated field.
9965	Id int64 `json:"id,omitempty,string"`
9966
9967	// Kind: Identifies what kind of resource this is. Value: the fixed
9968	// string "dfareporting#order".
9969	Kind string `json:"kind,omitempty"`
9970
9971	// LastModifiedInfo: Information about the most recent modification of
9972	// this order.
9973	LastModifiedInfo *LastModifiedInfo `json:"lastModifiedInfo,omitempty"`
9974
9975	// Name: Name of this order.
9976	Name string `json:"name,omitempty"`
9977
9978	// Notes: Notes of this order.
9979	Notes string `json:"notes,omitempty"`
9980
9981	// PlanningTermId: ID of the terms and conditions template used in this
9982	// order.
9983	PlanningTermId int64 `json:"planningTermId,omitempty,string"`
9984
9985	// ProjectId: Project ID of this order.
9986	ProjectId int64 `json:"projectId,omitempty,string"`
9987
9988	// SellerOrderId: Seller order ID associated with this order.
9989	SellerOrderId string `json:"sellerOrderId,omitempty"`
9990
9991	// SellerOrganizationName: Name of the seller organization.
9992	SellerOrganizationName string `json:"sellerOrganizationName,omitempty"`
9993
9994	// SiteId: Site IDs this order is associated with.
9995	SiteId googleapi.Int64s `json:"siteId,omitempty"`
9996
9997	// SiteNames: Free-form site names this order is associated with.
9998	SiteNames []string `json:"siteNames,omitempty"`
9999
10000	// SubaccountId: Subaccount ID of this order.
10001	SubaccountId int64 `json:"subaccountId,omitempty,string"`
10002
10003	// TermsAndConditions: Terms and conditions of this order.
10004	TermsAndConditions string `json:"termsAndConditions,omitempty"`
10005
10006	// ServerResponse contains the HTTP response code and headers from the
10007	// server.
10008	googleapi.ServerResponse `json:"-"`
10009
10010	// ForceSendFields is a list of field names (e.g. "AccountId") to
10011	// unconditionally include in API requests. By default, fields with
10012	// empty or default values are omitted from API requests. However, any
10013	// non-pointer, non-interface field appearing in ForceSendFields will be
10014	// sent to the server regardless of whether the field is empty or not.
10015	// This may be used to include empty fields in Patch requests.
10016	ForceSendFields []string `json:"-"`
10017
10018	// NullFields is a list of field names (e.g. "AccountId") to include in
10019	// API requests with the JSON null value. By default, fields with empty
10020	// values are omitted from API requests. However, any field with an
10021	// empty value appearing in NullFields will be sent to the server as
10022	// null. It is an error if a field in this list has a non-empty value.
10023	// This may be used to include null fields in Patch requests.
10024	NullFields []string `json:"-"`
10025}
10026
10027func (s *Order) MarshalJSON() ([]byte, error) {
10028	type NoMethod Order
10029	raw := NoMethod(*s)
10030	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10031}
10032
10033// OrderContact: Contact of an order.
10034type OrderContact struct {
10035	// ContactInfo: Free-form information about this contact. It could be
10036	// any information related to this contact in addition to type, title,
10037	// name, and signature user profile ID.
10038	ContactInfo string `json:"contactInfo,omitempty"`
10039
10040	// ContactName: Name of this contact.
10041	ContactName string `json:"contactName,omitempty"`
10042
10043	// ContactTitle: Title of this contact.
10044	ContactTitle string `json:"contactTitle,omitempty"`
10045
10046	// ContactType: Type of this contact.
10047	//
10048	// Possible values:
10049	//   "PLANNING_ORDER_CONTACT_BUYER_CONTACT"
10050	//   "PLANNING_ORDER_CONTACT_BUYER_BILLING_CONTACT"
10051	//   "PLANNING_ORDER_CONTACT_SELLER_CONTACT"
10052	ContactType string `json:"contactType,omitempty"`
10053
10054	// SignatureUserProfileId: ID of the user profile containing the
10055	// signature that will be embedded into order documents.
10056	SignatureUserProfileId int64 `json:"signatureUserProfileId,omitempty,string"`
10057
10058	// ForceSendFields is a list of field names (e.g. "ContactInfo") to
10059	// unconditionally include in API requests. By default, fields with
10060	// empty or default values are omitted from API requests. However, any
10061	// non-pointer, non-interface field appearing in ForceSendFields will be
10062	// sent to the server regardless of whether the field is empty or not.
10063	// This may be used to include empty fields in Patch requests.
10064	ForceSendFields []string `json:"-"`
10065
10066	// NullFields is a list of field names (e.g. "ContactInfo") to include
10067	// in API requests with the JSON null value. By default, fields with
10068	// empty values are omitted from API requests. However, any field with
10069	// an empty value appearing in NullFields will be sent to the server as
10070	// null. It is an error if a field in this list has a non-empty value.
10071	// This may be used to include null fields in Patch requests.
10072	NullFields []string `json:"-"`
10073}
10074
10075func (s *OrderContact) MarshalJSON() ([]byte, error) {
10076	type NoMethod OrderContact
10077	raw := NoMethod(*s)
10078	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10079}
10080
10081// OrderDocument: Contains properties of a Planning order document.
10082type OrderDocument struct {
10083	// AccountId: Account ID of this order document.
10084	AccountId int64 `json:"accountId,omitempty,string"`
10085
10086	// AdvertiserId: Advertiser ID of this order document.
10087	AdvertiserId int64 `json:"advertiserId,omitempty,string"`
10088
10089	// AmendedOrderDocumentId: The amended order document ID of this order
10090	// document. An order document can be created by optionally amending
10091	// another order document so that the change history can be preserved.
10092	AmendedOrderDocumentId int64 `json:"amendedOrderDocumentId,omitempty,string"`
10093
10094	// ApprovedByUserProfileIds: IDs of users who have approved this order
10095	// document.
10096	ApprovedByUserProfileIds googleapi.Int64s `json:"approvedByUserProfileIds,omitempty"`
10097
10098	// Cancelled: Whether this order document is cancelled.
10099	Cancelled bool `json:"cancelled,omitempty"`
10100
10101	// CreatedInfo: Information about the creation of this order document.
10102	CreatedInfo *LastModifiedInfo `json:"createdInfo,omitempty"`
10103
10104	EffectiveDate string `json:"effectiveDate,omitempty"`
10105
10106	// Id: ID of this order document.
10107	Id int64 `json:"id,omitempty,string"`
10108
10109	// Kind: Identifies what kind of resource this is. Value: the fixed
10110	// string "dfareporting#orderDocument".
10111	Kind string `json:"kind,omitempty"`
10112
10113	// LastSentRecipients: List of email addresses that received the last
10114	// sent document.
10115	LastSentRecipients []string `json:"lastSentRecipients,omitempty"`
10116
10117	LastSentTime string `json:"lastSentTime,omitempty"`
10118
10119	// OrderId: ID of the order from which this order document is created.
10120	OrderId int64 `json:"orderId,omitempty,string"`
10121
10122	// ProjectId: Project ID of this order document.
10123	ProjectId int64 `json:"projectId,omitempty,string"`
10124
10125	// Signed: Whether this order document has been signed.
10126	Signed bool `json:"signed,omitempty"`
10127
10128	// SubaccountId: Subaccount ID of this order document.
10129	SubaccountId int64 `json:"subaccountId,omitempty,string"`
10130
10131	// Title: Title of this order document.
10132	Title string `json:"title,omitempty"`
10133
10134	// Type: Type of this order document
10135	//
10136	// Possible values:
10137	//   "PLANNING_ORDER_TYPE_INSERTION_ORDER"
10138	//   "PLANNING_ORDER_TYPE_CHANGE_ORDER"
10139	Type string `json:"type,omitempty"`
10140
10141	// ServerResponse contains the HTTP response code and headers from the
10142	// server.
10143	googleapi.ServerResponse `json:"-"`
10144
10145	// ForceSendFields is a list of field names (e.g. "AccountId") to
10146	// unconditionally include in API requests. By default, fields with
10147	// empty or default values are omitted from API requests. However, any
10148	// non-pointer, non-interface field appearing in ForceSendFields will be
10149	// sent to the server regardless of whether the field is empty or not.
10150	// This may be used to include empty fields in Patch requests.
10151	ForceSendFields []string `json:"-"`
10152
10153	// NullFields is a list of field names (e.g. "AccountId") to include in
10154	// API requests with the JSON null value. By default, fields with empty
10155	// values are omitted from API requests. However, any field with an
10156	// empty value appearing in NullFields will be sent to the server as
10157	// null. It is an error if a field in this list has a non-empty value.
10158	// This may be used to include null fields in Patch requests.
10159	NullFields []string `json:"-"`
10160}
10161
10162func (s *OrderDocument) MarshalJSON() ([]byte, error) {
10163	type NoMethod OrderDocument
10164	raw := NoMethod(*s)
10165	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10166}
10167
10168// OrderDocumentsListResponse: Order document List Response
10169type OrderDocumentsListResponse struct {
10170	// Kind: Identifies what kind of resource this is. Value: the fixed
10171	// string "dfareporting#orderDocumentsListResponse".
10172	Kind string `json:"kind,omitempty"`
10173
10174	// NextPageToken: Pagination token to be used for the next list
10175	// operation.
10176	NextPageToken string `json:"nextPageToken,omitempty"`
10177
10178	// OrderDocuments: Order document collection
10179	OrderDocuments []*OrderDocument `json:"orderDocuments,omitempty"`
10180
10181	// ServerResponse contains the HTTP response code and headers from the
10182	// server.
10183	googleapi.ServerResponse `json:"-"`
10184
10185	// ForceSendFields is a list of field names (e.g. "Kind") to
10186	// unconditionally include in API requests. By default, fields with
10187	// empty or default values are omitted from API requests. However, any
10188	// non-pointer, non-interface field appearing in ForceSendFields will be
10189	// sent to the server regardless of whether the field is empty or not.
10190	// This may be used to include empty fields in Patch requests.
10191	ForceSendFields []string `json:"-"`
10192
10193	// NullFields is a list of field names (e.g. "Kind") to include in API
10194	// requests with the JSON null value. By default, fields with empty
10195	// values are omitted from API requests. However, any field with an
10196	// empty value appearing in NullFields will be sent to the server as
10197	// null. It is an error if a field in this list has a non-empty value.
10198	// This may be used to include null fields in Patch requests.
10199	NullFields []string `json:"-"`
10200}
10201
10202func (s *OrderDocumentsListResponse) MarshalJSON() ([]byte, error) {
10203	type NoMethod OrderDocumentsListResponse
10204	raw := NoMethod(*s)
10205	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10206}
10207
10208// OrdersListResponse: Order List Response
10209type OrdersListResponse struct {
10210	// Kind: Identifies what kind of resource this is. Value: the fixed
10211	// string "dfareporting#ordersListResponse".
10212	Kind string `json:"kind,omitempty"`
10213
10214	// NextPageToken: Pagination token to be used for the next list
10215	// operation.
10216	NextPageToken string `json:"nextPageToken,omitempty"`
10217
10218	// Orders: Order collection.
10219	Orders []*Order `json:"orders,omitempty"`
10220
10221	// ServerResponse contains the HTTP response code and headers from the
10222	// server.
10223	googleapi.ServerResponse `json:"-"`
10224
10225	// ForceSendFields is a list of field names (e.g. "Kind") to
10226	// unconditionally include in API requests. By default, fields with
10227	// empty or default values are omitted from API requests. However, any
10228	// non-pointer, non-interface field appearing in ForceSendFields will be
10229	// sent to the server regardless of whether the field is empty or not.
10230	// This may be used to include empty fields in Patch requests.
10231	ForceSendFields []string `json:"-"`
10232
10233	// NullFields is a list of field names (e.g. "Kind") to include in API
10234	// requests with the JSON null value. By default, fields with empty
10235	// values are omitted from API requests. However, any field with an
10236	// empty value appearing in NullFields will be sent to the server as
10237	// null. It is an error if a field in this list has a non-empty value.
10238	// This may be used to include null fields in Patch requests.
10239	NullFields []string `json:"-"`
10240}
10241
10242func (s *OrdersListResponse) MarshalJSON() ([]byte, error) {
10243	type NoMethod OrdersListResponse
10244	raw := NoMethod(*s)
10245	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10246}
10247
10248// PathFilter: Represents a DfaReporting path filter.
10249type PathFilter struct {
10250	// EventFilters: Event filters in path report.
10251	EventFilters []*EventFilter `json:"eventFilters,omitempty"`
10252
10253	// Kind: The kind of resource this is, in this case
10254	// dfareporting#pathFilter.
10255	Kind string `json:"kind,omitempty"`
10256
10257	// PathMatchPosition: Determines how the 'value' field is matched when
10258	// filtering. If not specified, defaults to EXACT. If set to
10259	// WILDCARD_EXPRESSION, '*' is allowed as a placeholder for variable
10260	// length character sequences, and it can be escaped with a backslash.
10261	// Note, only paid search dimensions ('dfa:paidSearch*') allow a
10262	// matchType other than EXACT.
10263	//
10264	// Possible values:
10265	//   "PATH_MATCH_POSITION_UNSPECIFIED"
10266	//   "ANY"
10267	//   "FIRST"
10268	//   "LAST"
10269	PathMatchPosition string `json:"pathMatchPosition,omitempty"`
10270
10271	// ForceSendFields is a list of field names (e.g. "EventFilters") to
10272	// unconditionally include in API requests. By default, fields with
10273	// empty or default values are omitted from API requests. However, any
10274	// non-pointer, non-interface field appearing in ForceSendFields will be
10275	// sent to the server regardless of whether the field is empty or not.
10276	// This may be used to include empty fields in Patch requests.
10277	ForceSendFields []string `json:"-"`
10278
10279	// NullFields is a list of field names (e.g. "EventFilters") to include
10280	// in API requests with the JSON null value. By default, fields with
10281	// empty values are omitted from API requests. However, any field with
10282	// an empty value appearing in NullFields will be sent to the server as
10283	// null. It is an error if a field in this list has a non-empty value.
10284	// This may be used to include null fields in Patch requests.
10285	NullFields []string `json:"-"`
10286}
10287
10288func (s *PathFilter) MarshalJSON() ([]byte, error) {
10289	type NoMethod PathFilter
10290	raw := NoMethod(*s)
10291	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10292}
10293
10294// PathReportCompatibleFields: Represents fields that are compatible to
10295// be selected for a report of type "PATH".
10296type PathReportCompatibleFields struct {
10297	// ChannelGroupings: Dimensions which are compatible to be selected in
10298	// the "channelGroupings" section of the report.
10299	ChannelGroupings []*Dimension `json:"channelGroupings,omitempty"`
10300
10301	// Dimensions: Dimensions which are compatible to be selected in the
10302	// "dimensions" section of the report.
10303	Dimensions []*Dimension `json:"dimensions,omitempty"`
10304
10305	// Kind: The kind of resource this is, in this case
10306	// dfareporting#pathReportCompatibleFields.
10307	Kind string `json:"kind,omitempty"`
10308
10309	// Metrics: Metrics which are compatible to be selected in the
10310	// "metricNames" section of the report.
10311	Metrics []*Metric `json:"metrics,omitempty"`
10312
10313	// PathFilters: Dimensions which are compatible to be selected in the
10314	// "pathFilters" section of the report.
10315	PathFilters []*Dimension `json:"pathFilters,omitempty"`
10316
10317	// ForceSendFields is a list of field names (e.g. "ChannelGroupings") to
10318	// unconditionally include in API requests. By default, fields with
10319	// empty or default values are omitted from API requests. However, any
10320	// non-pointer, non-interface field appearing in ForceSendFields will be
10321	// sent to the server regardless of whether the field is empty or not.
10322	// This may be used to include empty fields in Patch requests.
10323	ForceSendFields []string `json:"-"`
10324
10325	// NullFields is a list of field names (e.g. "ChannelGroupings") to
10326	// include in API requests with the JSON null value. By default, fields
10327	// with empty values are omitted from API requests. However, any field
10328	// with an empty value appearing in NullFields will be sent to the
10329	// server as null. It is an error if a field in this list has a
10330	// non-empty value. This may be used to include null fields in Patch
10331	// requests.
10332	NullFields []string `json:"-"`
10333}
10334
10335func (s *PathReportCompatibleFields) MarshalJSON() ([]byte, error) {
10336	type NoMethod PathReportCompatibleFields
10337	raw := NoMethod(*s)
10338	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10339}
10340
10341// PathReportDimensionValue: Represents a PathReportDimensionValue
10342// resource.
10343type PathReportDimensionValue struct {
10344	// DimensionName: The name of the dimension.
10345	DimensionName string `json:"dimensionName,omitempty"`
10346
10347	// Ids: The possible ID's associated with the value if available.
10348	Ids []string `json:"ids,omitempty"`
10349
10350	// Kind: The kind of resource this is, in this case
10351	// dfareporting#pathReportDimensionValue.
10352	Kind string `json:"kind,omitempty"`
10353
10354	// MatchType: Determines how the 'value' field is matched when
10355	// filtering. If not specified, defaults to EXACT. If set to
10356	// WILDCARD_EXPRESSION, '*' is allowed as a placeholder for variable
10357	// length character sequences, and it can be escaped with a backslash.
10358	// Note, only paid search dimensions ('dfa:paidSearch*') allow a
10359	// matchType other than EXACT.
10360	//
10361	// Possible values:
10362	//   "EXACT"
10363	//   "BEGINS_WITH"
10364	//   "CONTAINS"
10365	//   "WILDCARD_EXPRESSION"
10366	MatchType string `json:"matchType,omitempty"`
10367
10368	// Values: The possible values of the dimension.
10369	Values []string `json:"values,omitempty"`
10370
10371	// ForceSendFields is a list of field names (e.g. "DimensionName") to
10372	// unconditionally include in API requests. By default, fields with
10373	// empty or default values are omitted from API requests. However, any
10374	// non-pointer, non-interface field appearing in ForceSendFields will be
10375	// sent to the server regardless of whether the field is empty or not.
10376	// This may be used to include empty fields in Patch requests.
10377	ForceSendFields []string `json:"-"`
10378
10379	// NullFields is a list of field names (e.g. "DimensionName") to include
10380	// in API requests with the JSON null value. By default, fields with
10381	// empty values are omitted from API requests. However, any field with
10382	// an empty value appearing in NullFields will be sent to the server as
10383	// null. It is an error if a field in this list has a non-empty value.
10384	// This may be used to include null fields in Patch requests.
10385	NullFields []string `json:"-"`
10386}
10387
10388func (s *PathReportDimensionValue) MarshalJSON() ([]byte, error) {
10389	type NoMethod PathReportDimensionValue
10390	raw := NoMethod(*s)
10391	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10392}
10393
10394// PathToConversionReportCompatibleFields: Represents fields that are
10395// compatible to be selected for a report of type "PATH_TO_CONVERSION".
10396type PathToConversionReportCompatibleFields struct {
10397	// ConversionDimensions: Conversion dimensions which are compatible to
10398	// be selected in the "conversionDimensions" section of the report.
10399	ConversionDimensions []*Dimension `json:"conversionDimensions,omitempty"`
10400
10401	// CustomFloodlightVariables: Custom floodlight variables which are
10402	// compatible to be selected in the "customFloodlightVariables" section
10403	// of the report.
10404	CustomFloodlightVariables []*Dimension `json:"customFloodlightVariables,omitempty"`
10405
10406	// Kind: The kind of resource this is, in this case
10407	// dfareporting#pathToConversionReportCompatibleFields.
10408	Kind string `json:"kind,omitempty"`
10409
10410	// Metrics: Metrics which are compatible to be selected in the
10411	// "metricNames" section of the report.
10412	Metrics []*Metric `json:"metrics,omitempty"`
10413
10414	// PerInteractionDimensions: Per-interaction dimensions which are
10415	// compatible to be selected in the "perInteractionDimensions" section
10416	// of the report.
10417	PerInteractionDimensions []*Dimension `json:"perInteractionDimensions,omitempty"`
10418
10419	// ForceSendFields is a list of field names (e.g.
10420	// "ConversionDimensions") to unconditionally include in API requests.
10421	// By default, fields with empty or default values are omitted from API
10422	// requests. However, any non-pointer, non-interface field appearing in
10423	// ForceSendFields will be sent to the server regardless of whether the
10424	// field is empty or not. This may be used to include empty fields in
10425	// Patch requests.
10426	ForceSendFields []string `json:"-"`
10427
10428	// NullFields is a list of field names (e.g. "ConversionDimensions") to
10429	// include in API requests with the JSON null value. By default, fields
10430	// with empty values are omitted from API requests. However, any field
10431	// with an empty value appearing in NullFields will be sent to the
10432	// server as null. It is an error if a field in this list has a
10433	// non-empty value. This may be used to include null fields in Patch
10434	// requests.
10435	NullFields []string `json:"-"`
10436}
10437
10438func (s *PathToConversionReportCompatibleFields) MarshalJSON() ([]byte, error) {
10439	type NoMethod PathToConversionReportCompatibleFields
10440	raw := NoMethod(*s)
10441	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10442}
10443
10444// Placement: Contains properties of a placement.
10445type Placement struct {
10446	// AccountId: Account ID of this placement. This field can be left
10447	// blank.
10448	AccountId int64 `json:"accountId,omitempty,string"`
10449
10450	// AdBlockingOptOut: Whether this placement opts out of ad blocking.
10451	// When true, ad blocking is disabled for this placement. When false,
10452	// the campaign and site settings take effect.
10453	AdBlockingOptOut bool `json:"adBlockingOptOut,omitempty"`
10454
10455	// AdditionalSizes: Additional sizes associated with this placement.
10456	// When inserting or updating a placement, only the size ID field is
10457	// used.
10458	AdditionalSizes []*Size `json:"additionalSizes,omitempty"`
10459
10460	// AdvertiserId: Advertiser ID of this placement. This field can be left
10461	// blank.
10462	AdvertiserId int64 `json:"advertiserId,omitempty,string"`
10463
10464	// AdvertiserIdDimensionValue: Dimension value for the ID of the
10465	// advertiser. This is a read-only, auto-generated field.
10466	AdvertiserIdDimensionValue *DimensionValue `json:"advertiserIdDimensionValue,omitempty"`
10467
10468	// Archived: Whether this placement is archived.
10469	Archived bool `json:"archived,omitempty"`
10470
10471	// CampaignId: Campaign ID of this placement. This field is a required
10472	// field on insertion.
10473	CampaignId int64 `json:"campaignId,omitempty,string"`
10474
10475	// CampaignIdDimensionValue: Dimension value for the ID of the campaign.
10476	// This is a read-only, auto-generated field.
10477	CampaignIdDimensionValue *DimensionValue `json:"campaignIdDimensionValue,omitempty"`
10478
10479	// Comment: Comments for this placement.
10480	Comment string `json:"comment,omitempty"`
10481
10482	// Compatibility: Placement compatibility. DISPLAY and
10483	// DISPLAY_INTERSTITIAL refer to rendering on desktop, on mobile devices
10484	// or in mobile apps for regular or interstitial ads respectively. APP
10485	// and APP_INTERSTITIAL are no longer allowed for new placement
10486	// insertions. Instead, use DISPLAY or DISPLAY_INTERSTITIAL.
10487	// IN_STREAM_VIDEO refers to rendering in in-stream video ads developed
10488	// with the VAST standard. This field is required on insertion.
10489	//
10490	// Possible values:
10491	//   "DISPLAY"
10492	//   "DISPLAY_INTERSTITIAL"
10493	//   "APP"
10494	//   "APP_INTERSTITIAL"
10495	//   "IN_STREAM_VIDEO"
10496	//   "IN_STREAM_AUDIO"
10497	Compatibility string `json:"compatibility,omitempty"`
10498
10499	// ContentCategoryId: ID of the content category assigned to this
10500	// placement.
10501	ContentCategoryId int64 `json:"contentCategoryId,omitempty,string"`
10502
10503	// CreateInfo: Information about the creation of this placement. This is
10504	// a read-only field.
10505	CreateInfo *LastModifiedInfo `json:"createInfo,omitempty"`
10506
10507	// DirectorySiteId: Directory site ID of this placement. On insert, you
10508	// must set either this field or the siteId field to specify the site
10509	// associated with this placement. This is a required field that is
10510	// read-only after insertion.
10511	DirectorySiteId int64 `json:"directorySiteId,omitempty,string"`
10512
10513	// DirectorySiteIdDimensionValue: Dimension value for the ID of the
10514	// directory site. This is a read-only, auto-generated field.
10515	DirectorySiteIdDimensionValue *DimensionValue `json:"directorySiteIdDimensionValue,omitempty"`
10516
10517	// ExternalId: External ID for this placement.
10518	ExternalId string `json:"externalId,omitempty"`
10519
10520	// Id: ID of this placement. This is a read-only, auto-generated field.
10521	Id int64 `json:"id,omitempty,string"`
10522
10523	// IdDimensionValue: Dimension value for the ID of this placement. This
10524	// is a read-only, auto-generated field.
10525	IdDimensionValue *DimensionValue `json:"idDimensionValue,omitempty"`
10526
10527	// KeyName: Key name of this placement. This is a read-only,
10528	// auto-generated field.
10529	KeyName string `json:"keyName,omitempty"`
10530
10531	// Kind: Identifies what kind of resource this is. Value: the fixed
10532	// string "dfareporting#placement".
10533	Kind string `json:"kind,omitempty"`
10534
10535	// LastModifiedInfo: Information about the most recent modification of
10536	// this placement. This is a read-only field.
10537	LastModifiedInfo *LastModifiedInfo `json:"lastModifiedInfo,omitempty"`
10538
10539	// LookbackConfiguration: Lookback window settings for this placement.
10540	LookbackConfiguration *LookbackConfiguration `json:"lookbackConfiguration,omitempty"`
10541
10542	// Name: Name of this placement.This is a required field and must be
10543	// less than or equal to 256 characters long.
10544	Name string `json:"name,omitempty"`
10545
10546	// PaymentApproved: Whether payment was approved for this placement.
10547	// This is a read-only field relevant only to publisher-paid placements.
10548	PaymentApproved bool `json:"paymentApproved,omitempty"`
10549
10550	// PaymentSource: Payment source for this placement. This is a required
10551	// field that is read-only after insertion.
10552	//
10553	// Possible values:
10554	//   "PLACEMENT_AGENCY_PAID"
10555	//   "PLACEMENT_PUBLISHER_PAID"
10556	PaymentSource string `json:"paymentSource,omitempty"`
10557
10558	// PlacementGroupId: ID of this placement's group, if applicable.
10559	PlacementGroupId int64 `json:"placementGroupId,omitempty,string"`
10560
10561	// PlacementGroupIdDimensionValue: Dimension value for the ID of the
10562	// placement group. This is a read-only, auto-generated field.
10563	PlacementGroupIdDimensionValue *DimensionValue `json:"placementGroupIdDimensionValue,omitempty"`
10564
10565	// PlacementStrategyId: ID of the placement strategy assigned to this
10566	// placement.
10567	PlacementStrategyId int64 `json:"placementStrategyId,omitempty,string"`
10568
10569	// PricingSchedule: Pricing schedule of this placement. This field is
10570	// required on insertion, specifically subfields startDate, endDate and
10571	// pricingType.
10572	PricingSchedule *PricingSchedule `json:"pricingSchedule,omitempty"`
10573
10574	// Primary: Whether this placement is the primary placement of a
10575	// roadblock (placement group). You cannot change this field from true
10576	// to false. Setting this field to true will automatically set the
10577	// primary field on the original primary placement of the roadblock to
10578	// false, and it will automatically set the roadblock's
10579	// primaryPlacementId field to the ID of this placement.
10580	Primary bool `json:"primary,omitempty"`
10581
10582	// PublisherUpdateInfo: Information about the last publisher update.
10583	// This is a read-only field.
10584	PublisherUpdateInfo *LastModifiedInfo `json:"publisherUpdateInfo,omitempty"`
10585
10586	// SiteId: Site ID associated with this placement. On insert, you must
10587	// set either this field or the directorySiteId field to specify the
10588	// site associated with this placement. This is a required field that is
10589	// read-only after insertion.
10590	SiteId int64 `json:"siteId,omitempty,string"`
10591
10592	// SiteIdDimensionValue: Dimension value for the ID of the site. This is
10593	// a read-only, auto-generated field.
10594	SiteIdDimensionValue *DimensionValue `json:"siteIdDimensionValue,omitempty"`
10595
10596	// Size: Size associated with this placement. When inserting or updating
10597	// a placement, only the size ID field is used. This field is required
10598	// on insertion.
10599	Size *Size `json:"size,omitempty"`
10600
10601	// SslRequired: Whether creatives assigned to this placement must be
10602	// SSL-compliant.
10603	SslRequired bool `json:"sslRequired,omitempty"`
10604
10605	// Status: Third-party placement status.
10606	//
10607	// Possible values:
10608	//   "PENDING_REVIEW"
10609	//   "PAYMENT_ACCEPTED"
10610	//   "PAYMENT_REJECTED"
10611	//   "ACKNOWLEDGE_REJECTION"
10612	//   "ACKNOWLEDGE_ACCEPTANCE"
10613	//   "DRAFT"
10614	Status string `json:"status,omitempty"`
10615
10616	// SubaccountId: Subaccount ID of this placement. This field can be left
10617	// blank.
10618	SubaccountId int64 `json:"subaccountId,omitempty,string"`
10619
10620	// TagFormats: Tag formats to generate for this placement. This field is
10621	// required on insertion. Acceptable values are: -
10622	// "PLACEMENT_TAG_STANDARD" - "PLACEMENT_TAG_IFRAME_JAVASCRIPT" -
10623	// "PLACEMENT_TAG_IFRAME_ILAYER" - "PLACEMENT_TAG_INTERNAL_REDIRECT" -
10624	// "PLACEMENT_TAG_JAVASCRIPT" -
10625	// "PLACEMENT_TAG_INTERSTITIAL_IFRAME_JAVASCRIPT" -
10626	// "PLACEMENT_TAG_INTERSTITIAL_INTERNAL_REDIRECT" -
10627	// "PLACEMENT_TAG_INTERSTITIAL_JAVASCRIPT" -
10628	// "PLACEMENT_TAG_CLICK_COMMANDS" -
10629	// "PLACEMENT_TAG_INSTREAM_VIDEO_PREFETCH" -
10630	// "PLACEMENT_TAG_INSTREAM_VIDEO_PREFETCH_VAST_3" -
10631	// "PLACEMENT_TAG_INSTREAM_VIDEO_PREFETCH_VAST_4" -
10632	// "PLACEMENT_TAG_TRACKING" - "PLACEMENT_TAG_TRACKING_IFRAME" -
10633	// "PLACEMENT_TAG_TRACKING_JAVASCRIPT"
10634	//
10635	// Possible values:
10636	//   "PLACEMENT_TAG_STANDARD"
10637	//   "PLACEMENT_TAG_IFRAME_JAVASCRIPT"
10638	//   "PLACEMENT_TAG_IFRAME_ILAYER"
10639	//   "PLACEMENT_TAG_INTERNAL_REDIRECT"
10640	//   "PLACEMENT_TAG_JAVASCRIPT"
10641	//   "PLACEMENT_TAG_INTERSTITIAL_IFRAME_JAVASCRIPT"
10642	//   "PLACEMENT_TAG_INTERSTITIAL_INTERNAL_REDIRECT"
10643	//   "PLACEMENT_TAG_INTERSTITIAL_JAVASCRIPT"
10644	//   "PLACEMENT_TAG_CLICK_COMMANDS"
10645	//   "PLACEMENT_TAG_INSTREAM_VIDEO_PREFETCH"
10646	//   "PLACEMENT_TAG_TRACKING"
10647	//   "PLACEMENT_TAG_TRACKING_IFRAME"
10648	//   "PLACEMENT_TAG_TRACKING_JAVASCRIPT"
10649	//   "PLACEMENT_TAG_INSTREAM_VIDEO_PREFETCH_VAST_3"
10650	//   "PLACEMENT_TAG_IFRAME_JAVASCRIPT_LEGACY"
10651	//   "PLACEMENT_TAG_JAVASCRIPT_LEGACY"
10652	//   "PLACEMENT_TAG_INTERSTITIAL_IFRAME_JAVASCRIPT_LEGACY"
10653	//   "PLACEMENT_TAG_INTERSTITIAL_JAVASCRIPT_LEGACY"
10654	//   "PLACEMENT_TAG_INSTREAM_VIDEO_PREFETCH_VAST_4"
10655	TagFormats []string `json:"tagFormats,omitempty"`
10656
10657	// TagSetting: Tag settings for this placement.
10658	TagSetting *TagSetting `json:"tagSetting,omitempty"`
10659
10660	// VideoActiveViewOptOut: Whether Verification and ActiveView are
10661	// disabled for in-stream video creatives for this placement. The same
10662	// setting videoActiveViewOptOut exists on the site level -- the opt out
10663	// occurs if either of these settings are true. These settings are
10664	// distinct from DirectorySites.settings.activeViewOptOut or
10665	// Sites.siteSettings.activeViewOptOut which only apply to display ads.
10666	// However, Accounts.activeViewOptOut opts out both video traffic, as
10667	// well as display ads, from Verification and ActiveView.
10668	VideoActiveViewOptOut bool `json:"videoActiveViewOptOut,omitempty"`
10669
10670	// VideoSettings: A collection of settings which affect video creatives
10671	// served through this placement. Applicable to placements with
10672	// IN_STREAM_VIDEO compatibility.
10673	VideoSettings *VideoSettings `json:"videoSettings,omitempty"`
10674
10675	// VpaidAdapterChoice: VPAID adapter setting for this placement.
10676	// Controls which VPAID format the measurement adapter will use for
10677	// in-stream video creatives assigned to this placement. *Note:* Flash
10678	// is no longer supported. This field now defaults to HTML5 when the
10679	// following values are provided: FLASH, BOTH.
10680	//
10681	// Possible values:
10682	//   "DEFAULT"
10683	//   "FLASH"
10684	//   "HTML5"
10685	//   "BOTH"
10686	VpaidAdapterChoice string `json:"vpaidAdapterChoice,omitempty"`
10687
10688	// ServerResponse contains the HTTP response code and headers from the
10689	// server.
10690	googleapi.ServerResponse `json:"-"`
10691
10692	// ForceSendFields is a list of field names (e.g. "AccountId") to
10693	// unconditionally include in API requests. By default, fields with
10694	// empty or default values are omitted from API requests. However, any
10695	// non-pointer, non-interface field appearing in ForceSendFields will be
10696	// sent to the server regardless of whether the field is empty or not.
10697	// This may be used to include empty fields in Patch requests.
10698	ForceSendFields []string `json:"-"`
10699
10700	// NullFields is a list of field names (e.g. "AccountId") to include in
10701	// API requests with the JSON null value. By default, fields with empty
10702	// values are omitted from API requests. However, any field with an
10703	// empty value appearing in NullFields will be sent to the server as
10704	// null. It is an error if a field in this list has a non-empty value.
10705	// This may be used to include null fields in Patch requests.
10706	NullFields []string `json:"-"`
10707}
10708
10709func (s *Placement) MarshalJSON() ([]byte, error) {
10710	type NoMethod Placement
10711	raw := NoMethod(*s)
10712	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10713}
10714
10715// PlacementAssignment: Placement Assignment.
10716type PlacementAssignment struct {
10717	// Active: Whether this placement assignment is active. When true, the
10718	// placement will be included in the ad's rotation.
10719	Active bool `json:"active,omitempty"`
10720
10721	// PlacementId: ID of the placement to be assigned. This is a required
10722	// field.
10723	PlacementId int64 `json:"placementId,omitempty,string"`
10724
10725	// PlacementIdDimensionValue: Dimension value for the ID of the
10726	// placement. This is a read-only, auto-generated field.
10727	PlacementIdDimensionValue *DimensionValue `json:"placementIdDimensionValue,omitempty"`
10728
10729	// SslRequired: Whether the placement to be assigned requires SSL. This
10730	// is a read-only field that is auto-generated when the ad is inserted
10731	// or updated.
10732	SslRequired bool `json:"sslRequired,omitempty"`
10733
10734	// ForceSendFields is a list of field names (e.g. "Active") to
10735	// unconditionally include in API requests. By default, fields with
10736	// empty or default values are omitted from API requests. However, any
10737	// non-pointer, non-interface field appearing in ForceSendFields will be
10738	// sent to the server regardless of whether the field is empty or not.
10739	// This may be used to include empty fields in Patch requests.
10740	ForceSendFields []string `json:"-"`
10741
10742	// NullFields is a list of field names (e.g. "Active") to include in API
10743	// requests with the JSON null value. By default, fields with empty
10744	// values are omitted from API requests. However, any field with an
10745	// empty value appearing in NullFields will be sent to the server as
10746	// null. It is an error if a field in this list has a non-empty value.
10747	// This may be used to include null fields in Patch requests.
10748	NullFields []string `json:"-"`
10749}
10750
10751func (s *PlacementAssignment) MarshalJSON() ([]byte, error) {
10752	type NoMethod PlacementAssignment
10753	raw := NoMethod(*s)
10754	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10755}
10756
10757// PlacementGroup: Contains properties of a package or roadblock.
10758type PlacementGroup struct {
10759	// AccountId: Account ID of this placement group. This is a read-only
10760	// field that can be left blank.
10761	AccountId int64 `json:"accountId,omitempty,string"`
10762
10763	// AdvertiserId: Advertiser ID of this placement group. This is a
10764	// required field on insertion.
10765	AdvertiserId int64 `json:"advertiserId,omitempty,string"`
10766
10767	// AdvertiserIdDimensionValue: Dimension value for the ID of the
10768	// advertiser. This is a read-only, auto-generated field.
10769	AdvertiserIdDimensionValue *DimensionValue `json:"advertiserIdDimensionValue,omitempty"`
10770
10771	// Archived: Whether this placement group is archived.
10772	Archived bool `json:"archived,omitempty"`
10773
10774	// CampaignId: Campaign ID of this placement group. This field is
10775	// required on insertion.
10776	CampaignId int64 `json:"campaignId,omitempty,string"`
10777
10778	// CampaignIdDimensionValue: Dimension value for the ID of the campaign.
10779	// This is a read-only, auto-generated field.
10780	CampaignIdDimensionValue *DimensionValue `json:"campaignIdDimensionValue,omitempty"`
10781
10782	// ChildPlacementIds: IDs of placements which are assigned to this
10783	// placement group. This is a read-only, auto-generated field.
10784	ChildPlacementIds googleapi.Int64s `json:"childPlacementIds,omitempty"`
10785
10786	// Comment: Comments for this placement group.
10787	Comment string `json:"comment,omitempty"`
10788
10789	// ContentCategoryId: ID of the content category assigned to this
10790	// placement group.
10791	ContentCategoryId int64 `json:"contentCategoryId,omitempty,string"`
10792
10793	// CreateInfo: Information about the creation of this placement group.
10794	// This is a read-only field.
10795	CreateInfo *LastModifiedInfo `json:"createInfo,omitempty"`
10796
10797	// DirectorySiteId: Directory site ID associated with this placement
10798	// group. On insert, you must set either this field or the site_id field
10799	// to specify the site associated with this placement group. This is a
10800	// required field that is read-only after insertion.
10801	DirectorySiteId int64 `json:"directorySiteId,omitempty,string"`
10802
10803	// DirectorySiteIdDimensionValue: Dimension value for the ID of the
10804	// directory site. This is a read-only, auto-generated field.
10805	DirectorySiteIdDimensionValue *DimensionValue `json:"directorySiteIdDimensionValue,omitempty"`
10806
10807	// ExternalId: External ID for this placement.
10808	ExternalId string `json:"externalId,omitempty"`
10809
10810	// Id: ID of this placement group. This is a read-only, auto-generated
10811	// field.
10812	Id int64 `json:"id,omitempty,string"`
10813
10814	// IdDimensionValue: Dimension value for the ID of this placement group.
10815	// This is a read-only, auto-generated field.
10816	IdDimensionValue *DimensionValue `json:"idDimensionValue,omitempty"`
10817
10818	// Kind: Identifies what kind of resource this is. Value: the fixed
10819	// string "dfareporting#placementGroup".
10820	Kind string `json:"kind,omitempty"`
10821
10822	// LastModifiedInfo: Information about the most recent modification of
10823	// this placement group. This is a read-only field.
10824	LastModifiedInfo *LastModifiedInfo `json:"lastModifiedInfo,omitempty"`
10825
10826	// Name: Name of this placement group. This is a required field and must
10827	// be less than 256 characters long.
10828	Name string `json:"name,omitempty"`
10829
10830	// PlacementGroupType: Type of this placement group. A package is a
10831	// simple group of placements that acts as a single pricing point for a
10832	// group of tags. A roadblock is a group of placements that not only
10833	// acts as a single pricing point, but also assumes that all the tags in
10834	// it will be served at the same time. A roadblock requires one of its
10835	// assigned placements to be marked as primary for reporting. This field
10836	// is required on insertion.
10837	//
10838	// Possible values:
10839	//   "PLACEMENT_PACKAGE"
10840	//   "PLACEMENT_ROADBLOCK"
10841	PlacementGroupType string `json:"placementGroupType,omitempty"`
10842
10843	// PlacementStrategyId: ID of the placement strategy assigned to this
10844	// placement group.
10845	PlacementStrategyId int64 `json:"placementStrategyId,omitempty,string"`
10846
10847	// PricingSchedule: Pricing schedule of this placement group. This field
10848	// is required on insertion.
10849	PricingSchedule *PricingSchedule `json:"pricingSchedule,omitempty"`
10850
10851	// PrimaryPlacementId: ID of the primary placement, used to calculate
10852	// the media cost of a roadblock (placement group). Modifying this field
10853	// will automatically modify the primary field on all affected roadblock
10854	// child placements.
10855	PrimaryPlacementId int64 `json:"primaryPlacementId,omitempty,string"`
10856
10857	// PrimaryPlacementIdDimensionValue: Dimension value for the ID of the
10858	// primary placement. This is a read-only, auto-generated field.
10859	PrimaryPlacementIdDimensionValue *DimensionValue `json:"primaryPlacementIdDimensionValue,omitempty"`
10860
10861	// SiteId: Site ID associated with this placement group. On insert, you
10862	// must set either this field or the directorySiteId field to specify
10863	// the site associated with this placement group. This is a required
10864	// field that is read-only after insertion.
10865	SiteId int64 `json:"siteId,omitempty,string"`
10866
10867	// SiteIdDimensionValue: Dimension value for the ID of the site. This is
10868	// a read-only, auto-generated field.
10869	SiteIdDimensionValue *DimensionValue `json:"siteIdDimensionValue,omitempty"`
10870
10871	// SubaccountId: Subaccount ID of this placement group. This is a
10872	// read-only field that can be left blank.
10873	SubaccountId int64 `json:"subaccountId,omitempty,string"`
10874
10875	// ServerResponse contains the HTTP response code and headers from the
10876	// server.
10877	googleapi.ServerResponse `json:"-"`
10878
10879	// ForceSendFields is a list of field names (e.g. "AccountId") to
10880	// unconditionally include in API requests. By default, fields with
10881	// empty or default values are omitted from API requests. However, any
10882	// non-pointer, non-interface field appearing in ForceSendFields will be
10883	// sent to the server regardless of whether the field is empty or not.
10884	// This may be used to include empty fields in Patch requests.
10885	ForceSendFields []string `json:"-"`
10886
10887	// NullFields is a list of field names (e.g. "AccountId") to include in
10888	// API requests with the JSON null value. By default, fields with empty
10889	// values are omitted from API requests. However, any field with an
10890	// empty value appearing in NullFields will be sent to the server as
10891	// null. It is an error if a field in this list has a non-empty value.
10892	// This may be used to include null fields in Patch requests.
10893	NullFields []string `json:"-"`
10894}
10895
10896func (s *PlacementGroup) MarshalJSON() ([]byte, error) {
10897	type NoMethod PlacementGroup
10898	raw := NoMethod(*s)
10899	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10900}
10901
10902// PlacementGroupsListResponse: Placement Group List Response
10903type PlacementGroupsListResponse struct {
10904	// Kind: Identifies what kind of resource this is. Value: the fixed
10905	// string "dfareporting#placementGroupsListResponse".
10906	Kind string `json:"kind,omitempty"`
10907
10908	// NextPageToken: Pagination token to be used for the next list
10909	// operation.
10910	NextPageToken string `json:"nextPageToken,omitempty"`
10911
10912	// PlacementGroups: Placement group collection.
10913	PlacementGroups []*PlacementGroup `json:"placementGroups,omitempty"`
10914
10915	// ServerResponse contains the HTTP response code and headers from the
10916	// server.
10917	googleapi.ServerResponse `json:"-"`
10918
10919	// ForceSendFields is a list of field names (e.g. "Kind") to
10920	// unconditionally include in API requests. By default, fields with
10921	// empty or default values are omitted from API requests. However, any
10922	// non-pointer, non-interface field appearing in ForceSendFields will be
10923	// sent to the server regardless of whether the field is empty or not.
10924	// This may be used to include empty fields in Patch requests.
10925	ForceSendFields []string `json:"-"`
10926
10927	// NullFields is a list of field names (e.g. "Kind") to include in API
10928	// requests with the JSON null value. By default, fields with empty
10929	// values are omitted from API requests. However, any field with an
10930	// empty value appearing in NullFields will be sent to the server as
10931	// null. It is an error if a field in this list has a non-empty value.
10932	// This may be used to include null fields in Patch requests.
10933	NullFields []string `json:"-"`
10934}
10935
10936func (s *PlacementGroupsListResponse) MarshalJSON() ([]byte, error) {
10937	type NoMethod PlacementGroupsListResponse
10938	raw := NoMethod(*s)
10939	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10940}
10941
10942// PlacementStrategiesListResponse: Placement Strategy List Response
10943type PlacementStrategiesListResponse struct {
10944	// Kind: Identifies what kind of resource this is. Value: the fixed
10945	// string "dfareporting#placementStrategiesListResponse".
10946	Kind string `json:"kind,omitempty"`
10947
10948	// NextPageToken: Pagination token to be used for the next list
10949	// operation.
10950	NextPageToken string `json:"nextPageToken,omitempty"`
10951
10952	// PlacementStrategies: Placement strategy collection.
10953	PlacementStrategies []*PlacementStrategy `json:"placementStrategies,omitempty"`
10954
10955	// ServerResponse contains the HTTP response code and headers from the
10956	// server.
10957	googleapi.ServerResponse `json:"-"`
10958
10959	// ForceSendFields is a list of field names (e.g. "Kind") to
10960	// unconditionally include in API requests. By default, fields with
10961	// empty or default values are omitted from API requests. However, any
10962	// non-pointer, non-interface field appearing in ForceSendFields will be
10963	// sent to the server regardless of whether the field is empty or not.
10964	// This may be used to include empty fields in Patch requests.
10965	ForceSendFields []string `json:"-"`
10966
10967	// NullFields is a list of field names (e.g. "Kind") to include in API
10968	// requests with the JSON null value. By default, fields with empty
10969	// values are omitted from API requests. However, any field with an
10970	// empty value appearing in NullFields will be sent to the server as
10971	// null. It is an error if a field in this list has a non-empty value.
10972	// This may be used to include null fields in Patch requests.
10973	NullFields []string `json:"-"`
10974}
10975
10976func (s *PlacementStrategiesListResponse) MarshalJSON() ([]byte, error) {
10977	type NoMethod PlacementStrategiesListResponse
10978	raw := NoMethod(*s)
10979	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10980}
10981
10982// PlacementStrategy: Contains properties of a placement strategy.
10983type PlacementStrategy struct {
10984	// AccountId: Account ID of this placement strategy.This is a read-only
10985	// field that can be left blank.
10986	AccountId int64 `json:"accountId,omitempty,string"`
10987
10988	// Id: ID of this placement strategy. This is a read-only,
10989	// auto-generated field.
10990	Id int64 `json:"id,omitempty,string"`
10991
10992	// Kind: Identifies what kind of resource this is. Value: the fixed
10993	// string "dfareporting#placementStrategy".
10994	Kind string `json:"kind,omitempty"`
10995
10996	// Name: Name of this placement strategy. This is a required field. It
10997	// must be less than 256 characters long and unique among placement
10998	// strategies of the same account.
10999	Name string `json:"name,omitempty"`
11000
11001	// ServerResponse contains the HTTP response code and headers from the
11002	// server.
11003	googleapi.ServerResponse `json:"-"`
11004
11005	// ForceSendFields is a list of field names (e.g. "AccountId") to
11006	// unconditionally include in API requests. By default, fields with
11007	// empty or default values are omitted from API requests. However, any
11008	// non-pointer, non-interface field appearing in ForceSendFields will be
11009	// sent to the server regardless of whether the field is empty or not.
11010	// This may be used to include empty fields in Patch requests.
11011	ForceSendFields []string `json:"-"`
11012
11013	// NullFields is a list of field names (e.g. "AccountId") to include in
11014	// API requests with the JSON null value. By default, fields with empty
11015	// values are omitted from API requests. However, any field with an
11016	// empty value appearing in NullFields will be sent to the server as
11017	// null. It is an error if a field in this list has a non-empty value.
11018	// This may be used to include null fields in Patch requests.
11019	NullFields []string `json:"-"`
11020}
11021
11022func (s *PlacementStrategy) MarshalJSON() ([]byte, error) {
11023	type NoMethod PlacementStrategy
11024	raw := NoMethod(*s)
11025	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11026}
11027
11028// PlacementTag: Placement Tag
11029type PlacementTag struct {
11030	// PlacementId: Placement ID
11031	PlacementId int64 `json:"placementId,omitempty,string"`
11032
11033	// TagDatas: Tags generated for this placement.
11034	TagDatas []*TagData `json:"tagDatas,omitempty"`
11035
11036	// ForceSendFields is a list of field names (e.g. "PlacementId") to
11037	// unconditionally include in API requests. By default, fields with
11038	// empty or default values are omitted from API requests. However, any
11039	// non-pointer, non-interface field appearing in ForceSendFields will be
11040	// sent to the server regardless of whether the field is empty or not.
11041	// This may be used to include empty fields in Patch requests.
11042	ForceSendFields []string `json:"-"`
11043
11044	// NullFields is a list of field names (e.g. "PlacementId") to include
11045	// in API requests with the JSON null value. By default, fields with
11046	// empty values are omitted from API requests. However, any field with
11047	// an empty value appearing in NullFields will be sent to the server as
11048	// null. It is an error if a field in this list has a non-empty value.
11049	// This may be used to include null fields in Patch requests.
11050	NullFields []string `json:"-"`
11051}
11052
11053func (s *PlacementTag) MarshalJSON() ([]byte, error) {
11054	type NoMethod PlacementTag
11055	raw := NoMethod(*s)
11056	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11057}
11058
11059// PlacementsGenerateTagsResponse: Placement GenerateTags Response
11060type PlacementsGenerateTagsResponse struct {
11061	// Kind: Identifies what kind of resource this is. Value: the fixed
11062	// string "dfareporting#placementsGenerateTagsResponse".
11063	Kind string `json:"kind,omitempty"`
11064
11065	// PlacementTags: Set of generated tags for the specified placements.
11066	PlacementTags []*PlacementTag `json:"placementTags,omitempty"`
11067
11068	// ServerResponse contains the HTTP response code and headers from the
11069	// server.
11070	googleapi.ServerResponse `json:"-"`
11071
11072	// ForceSendFields is a list of field names (e.g. "Kind") to
11073	// unconditionally include in API requests. By default, fields with
11074	// empty or default values are omitted from API requests. However, any
11075	// non-pointer, non-interface field appearing in ForceSendFields will be
11076	// sent to the server regardless of whether the field is empty or not.
11077	// This may be used to include empty fields in Patch requests.
11078	ForceSendFields []string `json:"-"`
11079
11080	// NullFields is a list of field names (e.g. "Kind") to include in API
11081	// requests with the JSON null value. By default, fields with empty
11082	// values are omitted from API requests. However, any field with an
11083	// empty value appearing in NullFields will be sent to the server as
11084	// null. It is an error if a field in this list has a non-empty value.
11085	// This may be used to include null fields in Patch requests.
11086	NullFields []string `json:"-"`
11087}
11088
11089func (s *PlacementsGenerateTagsResponse) MarshalJSON() ([]byte, error) {
11090	type NoMethod PlacementsGenerateTagsResponse
11091	raw := NoMethod(*s)
11092	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11093}
11094
11095// PlacementsListResponse: Placement List Response
11096type PlacementsListResponse struct {
11097	// Kind: Identifies what kind of resource this is. Value: the fixed
11098	// string "dfareporting#placementsListResponse".
11099	Kind string `json:"kind,omitempty"`
11100
11101	// NextPageToken: Pagination token to be used for the next list
11102	// operation.
11103	NextPageToken string `json:"nextPageToken,omitempty"`
11104
11105	// Placements: Placement collection.
11106	Placements []*Placement `json:"placements,omitempty"`
11107
11108	// ServerResponse contains the HTTP response code and headers from the
11109	// server.
11110	googleapi.ServerResponse `json:"-"`
11111
11112	// ForceSendFields is a list of field names (e.g. "Kind") to
11113	// unconditionally include in API requests. By default, fields with
11114	// empty or default values are omitted from API requests. However, any
11115	// non-pointer, non-interface field appearing in ForceSendFields will be
11116	// sent to the server regardless of whether the field is empty or not.
11117	// This may be used to include empty fields in Patch requests.
11118	ForceSendFields []string `json:"-"`
11119
11120	// NullFields is a list of field names (e.g. "Kind") to include in API
11121	// requests with the JSON null value. By default, fields with empty
11122	// values are omitted from API requests. However, any field with an
11123	// empty value appearing in NullFields will be sent to the server as
11124	// null. It is an error if a field in this list has a non-empty value.
11125	// This may be used to include null fields in Patch requests.
11126	NullFields []string `json:"-"`
11127}
11128
11129func (s *PlacementsListResponse) MarshalJSON() ([]byte, error) {
11130	type NoMethod PlacementsListResponse
11131	raw := NoMethod(*s)
11132	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11133}
11134
11135// PlatformType: Contains information about a platform type that can be
11136// targeted by ads.
11137type PlatformType struct {
11138	// Id: ID of this platform type.
11139	Id int64 `json:"id,omitempty,string"`
11140
11141	// Kind: Identifies what kind of resource this is. Value: the fixed
11142	// string "dfareporting#platformType".
11143	Kind string `json:"kind,omitempty"`
11144
11145	// Name: Name of this platform type.
11146	Name string `json:"name,omitempty"`
11147
11148	// ServerResponse contains the HTTP response code and headers from the
11149	// server.
11150	googleapi.ServerResponse `json:"-"`
11151
11152	// ForceSendFields is a list of field names (e.g. "Id") to
11153	// unconditionally include in API requests. By default, fields with
11154	// empty or default values are omitted from API requests. However, any
11155	// non-pointer, non-interface field appearing in ForceSendFields will be
11156	// sent to the server regardless of whether the field is empty or not.
11157	// This may be used to include empty fields in Patch requests.
11158	ForceSendFields []string `json:"-"`
11159
11160	// NullFields is a list of field names (e.g. "Id") to include in API
11161	// requests with the JSON null value. By default, fields with empty
11162	// values are omitted from API requests. However, any field with an
11163	// empty value appearing in NullFields will be sent to the server as
11164	// null. It is an error if a field in this list has a non-empty value.
11165	// This may be used to include null fields in Patch requests.
11166	NullFields []string `json:"-"`
11167}
11168
11169func (s *PlatformType) MarshalJSON() ([]byte, error) {
11170	type NoMethod PlatformType
11171	raw := NoMethod(*s)
11172	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11173}
11174
11175// PlatformTypesListResponse: Platform Type List Response
11176type PlatformTypesListResponse struct {
11177	// Kind: Identifies what kind of resource this is. Value: the fixed
11178	// string "dfareporting#platformTypesListResponse".
11179	Kind string `json:"kind,omitempty"`
11180
11181	// PlatformTypes: Platform type collection.
11182	PlatformTypes []*PlatformType `json:"platformTypes,omitempty"`
11183
11184	// ServerResponse contains the HTTP response code and headers from the
11185	// server.
11186	googleapi.ServerResponse `json:"-"`
11187
11188	// ForceSendFields is a list of field names (e.g. "Kind") to
11189	// unconditionally include in API requests. By default, fields with
11190	// empty or default values are omitted from API requests. However, any
11191	// non-pointer, non-interface field appearing in ForceSendFields will be
11192	// sent to the server regardless of whether the field is empty or not.
11193	// This may be used to include empty fields in Patch requests.
11194	ForceSendFields []string `json:"-"`
11195
11196	// NullFields is a list of field names (e.g. "Kind") to include in API
11197	// requests with the JSON null value. By default, fields with empty
11198	// values are omitted from API requests. However, any field with an
11199	// empty value appearing in NullFields will be sent to the server as
11200	// null. It is an error if a field in this list has a non-empty value.
11201	// This may be used to include null fields in Patch requests.
11202	NullFields []string `json:"-"`
11203}
11204
11205func (s *PlatformTypesListResponse) MarshalJSON() ([]byte, error) {
11206	type NoMethod PlatformTypesListResponse
11207	raw := NoMethod(*s)
11208	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11209}
11210
11211// PopupWindowProperties: Popup Window Properties.
11212type PopupWindowProperties struct {
11213	// Dimension: Popup dimension for a creative. This is a read-only field.
11214	// Applicable to the following creative types: all RICH_MEDIA and all
11215	// VPAID
11216	Dimension *Size `json:"dimension,omitempty"`
11217
11218	// Offset: Upper-left corner coordinates of the popup window. Applicable
11219	// if positionType is COORDINATES.
11220	Offset *OffsetPosition `json:"offset,omitempty"`
11221
11222	// PositionType: Popup window position either centered or at specific
11223	// coordinate.
11224	//
11225	// Possible values:
11226	//   "CENTER"
11227	//   "COORDINATES"
11228	PositionType string `json:"positionType,omitempty"`
11229
11230	// ShowAddressBar: Whether to display the browser address bar.
11231	ShowAddressBar bool `json:"showAddressBar,omitempty"`
11232
11233	// ShowMenuBar: Whether to display the browser menu bar.
11234	ShowMenuBar bool `json:"showMenuBar,omitempty"`
11235
11236	// ShowScrollBar: Whether to display the browser scroll bar.
11237	ShowScrollBar bool `json:"showScrollBar,omitempty"`
11238
11239	// ShowStatusBar: Whether to display the browser status bar.
11240	ShowStatusBar bool `json:"showStatusBar,omitempty"`
11241
11242	// ShowToolBar: Whether to display the browser tool bar.
11243	ShowToolBar bool `json:"showToolBar,omitempty"`
11244
11245	// Title: Title of popup window.
11246	Title string `json:"title,omitempty"`
11247
11248	// ForceSendFields is a list of field names (e.g. "Dimension") to
11249	// unconditionally include in API requests. By default, fields with
11250	// empty or default values are omitted from API requests. However, any
11251	// non-pointer, non-interface field appearing in ForceSendFields will be
11252	// sent to the server regardless of whether the field is empty or not.
11253	// This may be used to include empty fields in Patch requests.
11254	ForceSendFields []string `json:"-"`
11255
11256	// NullFields is a list of field names (e.g. "Dimension") to include in
11257	// API requests with the JSON null value. By default, fields with empty
11258	// values are omitted from API requests. However, any field with an
11259	// empty value appearing in NullFields will be sent to the server as
11260	// null. It is an error if a field in this list has a non-empty value.
11261	// This may be used to include null fields in Patch requests.
11262	NullFields []string `json:"-"`
11263}
11264
11265func (s *PopupWindowProperties) MarshalJSON() ([]byte, error) {
11266	type NoMethod PopupWindowProperties
11267	raw := NoMethod(*s)
11268	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11269}
11270
11271// PostalCode: Contains information about a postal code that can be
11272// targeted by ads.
11273type PostalCode struct {
11274	// Code: Postal code. This is equivalent to the id field.
11275	Code string `json:"code,omitempty"`
11276
11277	// CountryCode: Country code of the country to which this postal code
11278	// belongs.
11279	CountryCode string `json:"countryCode,omitempty"`
11280
11281	// CountryDartId: DART ID of the country to which this postal code
11282	// belongs.
11283	CountryDartId int64 `json:"countryDartId,omitempty,string"`
11284
11285	// Id: ID of this postal code.
11286	Id string `json:"id,omitempty"`
11287
11288	// Kind: Identifies what kind of resource this is. Value: the fixed
11289	// string "dfareporting#postalCode".
11290	Kind string `json:"kind,omitempty"`
11291
11292	// ServerResponse contains the HTTP response code and headers from the
11293	// server.
11294	googleapi.ServerResponse `json:"-"`
11295
11296	// ForceSendFields is a list of field names (e.g. "Code") to
11297	// unconditionally include in API requests. By default, fields with
11298	// empty or default values are omitted from API requests. However, any
11299	// non-pointer, non-interface field appearing in ForceSendFields will be
11300	// sent to the server regardless of whether the field is empty or not.
11301	// This may be used to include empty fields in Patch requests.
11302	ForceSendFields []string `json:"-"`
11303
11304	// NullFields is a list of field names (e.g. "Code") to include in API
11305	// requests with the JSON null value. By default, fields with empty
11306	// values are omitted from API requests. However, any field with an
11307	// empty value appearing in NullFields will be sent to the server as
11308	// null. It is an error if a field in this list has a non-empty value.
11309	// This may be used to include null fields in Patch requests.
11310	NullFields []string `json:"-"`
11311}
11312
11313func (s *PostalCode) MarshalJSON() ([]byte, error) {
11314	type NoMethod PostalCode
11315	raw := NoMethod(*s)
11316	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11317}
11318
11319// PostalCodesListResponse: Postal Code List Response
11320type PostalCodesListResponse struct {
11321	// Kind: Identifies what kind of resource this is. Value: the fixed
11322	// string "dfareporting#postalCodesListResponse".
11323	Kind string `json:"kind,omitempty"`
11324
11325	// PostalCodes: Postal code collection.
11326	PostalCodes []*PostalCode `json:"postalCodes,omitempty"`
11327
11328	// ServerResponse contains the HTTP response code and headers from the
11329	// server.
11330	googleapi.ServerResponse `json:"-"`
11331
11332	// ForceSendFields is a list of field names (e.g. "Kind") to
11333	// unconditionally include in API requests. By default, fields with
11334	// empty or default values are omitted from API requests. However, any
11335	// non-pointer, non-interface field appearing in ForceSendFields will be
11336	// sent to the server regardless of whether the field is empty or not.
11337	// This may be used to include empty fields in Patch requests.
11338	ForceSendFields []string `json:"-"`
11339
11340	// NullFields is a list of field names (e.g. "Kind") to include in API
11341	// requests with the JSON null value. By default, fields with empty
11342	// values are omitted from API requests. However, any field with an
11343	// empty value appearing in NullFields will be sent to the server as
11344	// null. It is an error if a field in this list has a non-empty value.
11345	// This may be used to include null fields in Patch requests.
11346	NullFields []string `json:"-"`
11347}
11348
11349func (s *PostalCodesListResponse) MarshalJSON() ([]byte, error) {
11350	type NoMethod PostalCodesListResponse
11351	raw := NoMethod(*s)
11352	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11353}
11354
11355// Pricing: Pricing Information
11356type Pricing struct {
11357	// CapCostType: Cap cost type of this inventory item.
11358	//
11359	// Possible values:
11360	//   "PLANNING_PLACEMENT_CAP_COST_TYPE_NONE"
11361	//   "PLANNING_PLACEMENT_CAP_COST_TYPE_MONTHLY"
11362	//   "PLANNING_PLACEMENT_CAP_COST_TYPE_CUMULATIVE"
11363	CapCostType string `json:"capCostType,omitempty"`
11364
11365	EndDate string `json:"endDate,omitempty"`
11366
11367	// Flights: Flights of this inventory item. A flight (a.k.a. pricing
11368	// period) represents the inventory item pricing information for a
11369	// specific period of time.
11370	Flights []*Flight `json:"flights,omitempty"`
11371
11372	// GroupType: Group type of this inventory item if it represents a
11373	// placement group. Is null otherwise. There are two type of placement
11374	// groups: PLANNING_PLACEMENT_GROUP_TYPE_PACKAGE is a simple group of
11375	// inventory items that acts as a single pricing point for a group of
11376	// tags. PLANNING_PLACEMENT_GROUP_TYPE_ROADBLOCK is a group of inventory
11377	// items that not only acts as a single pricing point, but also assumes
11378	// that all the tags in it will be served at the same time. A roadblock
11379	// requires one of its assigned inventory items to be marked as primary.
11380	//
11381	// Possible values:
11382	//   "PLANNING_PLACEMENT_GROUP_TYPE_PACKAGE"
11383	//   "PLANNING_PLACEMENT_GROUP_TYPE_ROADBLOCK"
11384	GroupType string `json:"groupType,omitempty"`
11385
11386	// PricingType: Pricing type of this inventory item.
11387	//
11388	// Possible values:
11389	//   "PLANNING_PLACEMENT_PRICING_TYPE_IMPRESSIONS"
11390	//   "PLANNING_PLACEMENT_PRICING_TYPE_CPM"
11391	//   "PLANNING_PLACEMENT_PRICING_TYPE_CLICKS"
11392	//   "PLANNING_PLACEMENT_PRICING_TYPE_CPC"
11393	//   "PLANNING_PLACEMENT_PRICING_TYPE_CPA"
11394	//   "PLANNING_PLACEMENT_PRICING_TYPE_FLAT_RATE_IMPRESSIONS"
11395	//   "PLANNING_PLACEMENT_PRICING_TYPE_FLAT_RATE_CLICKS"
11396	//   "PLANNING_PLACEMENT_PRICING_TYPE_CPM_ACTIVEVIEW"
11397	PricingType string `json:"pricingType,omitempty"`
11398
11399	StartDate string `json:"startDate,omitempty"`
11400
11401	// ForceSendFields is a list of field names (e.g. "CapCostType") to
11402	// unconditionally include in API requests. By default, fields with
11403	// empty or default values are omitted from API requests. However, any
11404	// non-pointer, non-interface field appearing in ForceSendFields will be
11405	// sent to the server regardless of whether the field is empty or not.
11406	// This may be used to include empty fields in Patch requests.
11407	ForceSendFields []string `json:"-"`
11408
11409	// NullFields is a list of field names (e.g. "CapCostType") to include
11410	// in API requests with the JSON null value. By default, fields with
11411	// empty values are omitted from API requests. However, any field with
11412	// an empty value appearing in NullFields will be sent to the server as
11413	// null. It is an error if a field in this list has a non-empty value.
11414	// This may be used to include null fields in Patch requests.
11415	NullFields []string `json:"-"`
11416}
11417
11418func (s *Pricing) MarshalJSON() ([]byte, error) {
11419	type NoMethod Pricing
11420	raw := NoMethod(*s)
11421	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11422}
11423
11424// PricingSchedule: Pricing Schedule
11425type PricingSchedule struct {
11426	// CapCostOption: Placement cap cost option.
11427	//
11428	// Possible values:
11429	//   "CAP_COST_NONE"
11430	//   "CAP_COST_MONTHLY"
11431	//   "CAP_COST_CUMULATIVE"
11432	CapCostOption string `json:"capCostOption,omitempty"`
11433
11434	EndDate string `json:"endDate,omitempty"`
11435
11436	// Flighted: Whether this placement is flighted. If true, pricing
11437	// periods will be computed automatically.
11438	Flighted bool `json:"flighted,omitempty"`
11439
11440	// FloodlightActivityId: Floodlight activity ID associated with this
11441	// placement. This field should be set when placement pricing type is
11442	// set to PRICING_TYPE_CPA.
11443	FloodlightActivityId int64 `json:"floodlightActivityId,omitempty,string"`
11444
11445	// PricingPeriods: Pricing periods for this placement.
11446	PricingPeriods []*PricingSchedulePricingPeriod `json:"pricingPeriods,omitempty"`
11447
11448	// PricingType: Placement pricing type. This field is required on
11449	// insertion.
11450	//
11451	// Possible values:
11452	//   "PRICING_TYPE_CPM"
11453	//   "PRICING_TYPE_CPC"
11454	//   "PRICING_TYPE_CPA"
11455	//   "PRICING_TYPE_FLAT_RATE_IMPRESSIONS"
11456	//   "PRICING_TYPE_FLAT_RATE_CLICKS"
11457	//   "PRICING_TYPE_CPM_ACTIVEVIEW"
11458	PricingType string `json:"pricingType,omitempty"`
11459
11460	StartDate string `json:"startDate,omitempty"`
11461
11462	TestingStartDate string `json:"testingStartDate,omitempty"`
11463
11464	// ForceSendFields is a list of field names (e.g. "CapCostOption") to
11465	// unconditionally include in API requests. By default, fields with
11466	// empty or default values are omitted from API requests. However, any
11467	// non-pointer, non-interface field appearing in ForceSendFields will be
11468	// sent to the server regardless of whether the field is empty or not.
11469	// This may be used to include empty fields in Patch requests.
11470	ForceSendFields []string `json:"-"`
11471
11472	// NullFields is a list of field names (e.g. "CapCostOption") to include
11473	// in API requests with the JSON null value. By default, fields with
11474	// empty values are omitted from API requests. However, any field with
11475	// an empty value appearing in NullFields will be sent to the server as
11476	// null. It is an error if a field in this list has a non-empty value.
11477	// This may be used to include null fields in Patch requests.
11478	NullFields []string `json:"-"`
11479}
11480
11481func (s *PricingSchedule) MarshalJSON() ([]byte, error) {
11482	type NoMethod PricingSchedule
11483	raw := NoMethod(*s)
11484	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11485}
11486
11487// PricingSchedulePricingPeriod: Pricing Period
11488type PricingSchedulePricingPeriod struct {
11489	EndDate string `json:"endDate,omitempty"`
11490
11491	// PricingComment: Comments for this pricing period.
11492	PricingComment string `json:"pricingComment,omitempty"`
11493
11494	// RateOrCostNanos: Rate or cost of this pricing period in nanos (i.e.,
11495	// multipled by 1000000000). Acceptable values are 0 to
11496	// 1000000000000000000, inclusive.
11497	RateOrCostNanos int64 `json:"rateOrCostNanos,omitempty,string"`
11498
11499	StartDate string `json:"startDate,omitempty"`
11500
11501	// Units: Units of this pricing period. Acceptable values are 0 to
11502	// 10000000000, inclusive.
11503	Units int64 `json:"units,omitempty,string"`
11504
11505	// ForceSendFields is a list of field names (e.g. "EndDate") to
11506	// unconditionally include in API requests. By default, fields with
11507	// empty or default values are omitted from API requests. However, any
11508	// non-pointer, non-interface field appearing in ForceSendFields will be
11509	// sent to the server regardless of whether the field is empty or not.
11510	// This may be used to include empty fields in Patch requests.
11511	ForceSendFields []string `json:"-"`
11512
11513	// NullFields is a list of field names (e.g. "EndDate") to include in
11514	// API requests with the JSON null value. By default, fields with empty
11515	// values are omitted from API requests. However, any field with an
11516	// empty value appearing in NullFields will be sent to the server as
11517	// null. It is an error if a field in this list has a non-empty value.
11518	// This may be used to include null fields in Patch requests.
11519	NullFields []string `json:"-"`
11520}
11521
11522func (s *PricingSchedulePricingPeriod) MarshalJSON() ([]byte, error) {
11523	type NoMethod PricingSchedulePricingPeriod
11524	raw := NoMethod(*s)
11525	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11526}
11527
11528// Project: Contains properties of a Planning project.
11529type Project struct {
11530	// AccountId: Account ID of this project.
11531	AccountId int64 `json:"accountId,omitempty,string"`
11532
11533	// AdvertiserId: Advertiser ID of this project.
11534	AdvertiserId int64 `json:"advertiserId,omitempty,string"`
11535
11536	// AudienceAgeGroup: Audience age group of this project.
11537	//
11538	// Possible values:
11539	//   "PLANNING_AUDIENCE_AGE_18_24"
11540	//   "PLANNING_AUDIENCE_AGE_25_34"
11541	//   "PLANNING_AUDIENCE_AGE_35_44"
11542	//   "PLANNING_AUDIENCE_AGE_45_54"
11543	//   "PLANNING_AUDIENCE_AGE_55_64"
11544	//   "PLANNING_AUDIENCE_AGE_65_OR_MORE"
11545	//   "PLANNING_AUDIENCE_AGE_UNKNOWN"
11546	AudienceAgeGroup string `json:"audienceAgeGroup,omitempty"`
11547
11548	// AudienceGender: Audience gender of this project.
11549	//
11550	// Possible values:
11551	//   "PLANNING_AUDIENCE_GENDER_MALE"
11552	//   "PLANNING_AUDIENCE_GENDER_FEMALE"
11553	AudienceGender string `json:"audienceGender,omitempty"`
11554
11555	// Budget: Budget of this project in the currency specified by the
11556	// current account. The value stored in this field represents only the
11557	// non-fractional amount. For example, for USD, the smallest value that
11558	// can be represented by this field is 1 US dollar.
11559	Budget int64 `json:"budget,omitempty,string"`
11560
11561	// ClientBillingCode: Client billing code of this project.
11562	ClientBillingCode string `json:"clientBillingCode,omitempty"`
11563
11564	// ClientName: Name of the project client.
11565	ClientName string `json:"clientName,omitempty"`
11566
11567	EndDate string `json:"endDate,omitempty"`
11568
11569	// Id: ID of this project. This is a read-only, auto-generated field.
11570	Id int64 `json:"id,omitempty,string"`
11571
11572	// Kind: Identifies what kind of resource this is. Value: the fixed
11573	// string "dfareporting#project".
11574	Kind string `json:"kind,omitempty"`
11575
11576	// LastModifiedInfo: Information about the most recent modification of
11577	// this project.
11578	LastModifiedInfo *LastModifiedInfo `json:"lastModifiedInfo,omitempty"`
11579
11580	// Name: Name of this project.
11581	Name string `json:"name,omitempty"`
11582
11583	// Overview: Overview of this project.
11584	Overview string `json:"overview,omitempty"`
11585
11586	StartDate string `json:"startDate,omitempty"`
11587
11588	// SubaccountId: Subaccount ID of this project.
11589	SubaccountId int64 `json:"subaccountId,omitempty,string"`
11590
11591	// TargetClicks: Number of clicks that the advertiser is targeting.
11592	TargetClicks int64 `json:"targetClicks,omitempty,string"`
11593
11594	// TargetConversions: Number of conversions that the advertiser is
11595	// targeting.
11596	TargetConversions int64 `json:"targetConversions,omitempty,string"`
11597
11598	// TargetCpaNanos: CPA that the advertiser is targeting.
11599	TargetCpaNanos int64 `json:"targetCpaNanos,omitempty,string"`
11600
11601	// TargetCpcNanos: CPC that the advertiser is targeting.
11602	TargetCpcNanos int64 `json:"targetCpcNanos,omitempty,string"`
11603
11604	// TargetCpmActiveViewNanos: vCPM from Active View that the advertiser
11605	// is targeting.
11606	TargetCpmActiveViewNanos int64 `json:"targetCpmActiveViewNanos,omitempty,string"`
11607
11608	// TargetCpmNanos: CPM that the advertiser is targeting.
11609	TargetCpmNanos int64 `json:"targetCpmNanos,omitempty,string"`
11610
11611	// TargetImpressions: Number of impressions that the advertiser is
11612	// targeting.
11613	TargetImpressions int64 `json:"targetImpressions,omitempty,string"`
11614
11615	// ServerResponse contains the HTTP response code and headers from the
11616	// server.
11617	googleapi.ServerResponse `json:"-"`
11618
11619	// ForceSendFields is a list of field names (e.g. "AccountId") to
11620	// unconditionally include in API requests. By default, fields with
11621	// empty or default values are omitted from API requests. However, any
11622	// non-pointer, non-interface field appearing in ForceSendFields will be
11623	// sent to the server regardless of whether the field is empty or not.
11624	// This may be used to include empty fields in Patch requests.
11625	ForceSendFields []string `json:"-"`
11626
11627	// NullFields is a list of field names (e.g. "AccountId") to include in
11628	// API requests with the JSON null value. By default, fields with empty
11629	// values are omitted from API requests. However, any field with an
11630	// empty value appearing in NullFields will be sent to the server as
11631	// null. It is an error if a field in this list has a non-empty value.
11632	// This may be used to include null fields in Patch requests.
11633	NullFields []string `json:"-"`
11634}
11635
11636func (s *Project) MarshalJSON() ([]byte, error) {
11637	type NoMethod Project
11638	raw := NoMethod(*s)
11639	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11640}
11641
11642// ProjectsListResponse: Project List Response
11643type ProjectsListResponse struct {
11644	// Kind: Identifies what kind of resource this is. Value: the fixed
11645	// string "dfareporting#projectsListResponse".
11646	Kind string `json:"kind,omitempty"`
11647
11648	// NextPageToken: Pagination token to be used for the next list
11649	// operation.
11650	NextPageToken string `json:"nextPageToken,omitempty"`
11651
11652	// Projects: Project collection.
11653	Projects []*Project `json:"projects,omitempty"`
11654
11655	// ServerResponse contains the HTTP response code and headers from the
11656	// server.
11657	googleapi.ServerResponse `json:"-"`
11658
11659	// ForceSendFields is a list of field names (e.g. "Kind") to
11660	// unconditionally include in API requests. By default, fields with
11661	// empty or default values are omitted from API requests. However, any
11662	// non-pointer, non-interface field appearing in ForceSendFields will be
11663	// sent to the server regardless of whether the field is empty or not.
11664	// This may be used to include empty fields in Patch requests.
11665	ForceSendFields []string `json:"-"`
11666
11667	// NullFields is a list of field names (e.g. "Kind") to include in API
11668	// requests with the JSON null value. By default, fields with empty
11669	// values are omitted from API requests. However, any field with an
11670	// empty value appearing in NullFields will be sent to the server as
11671	// null. It is an error if a field in this list has a non-empty value.
11672	// This may be used to include null fields in Patch requests.
11673	NullFields []string `json:"-"`
11674}
11675
11676func (s *ProjectsListResponse) MarshalJSON() ([]byte, error) {
11677	type NoMethod ProjectsListResponse
11678	raw := NoMethod(*s)
11679	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11680}
11681
11682// ReachReportCompatibleFields: Represents fields that are compatible to
11683// be selected for a report of type "REACH".
11684type ReachReportCompatibleFields struct {
11685	// DimensionFilters: Dimensions which are compatible to be selected in
11686	// the "dimensionFilters" section of the report.
11687	DimensionFilters []*Dimension `json:"dimensionFilters,omitempty"`
11688
11689	// Dimensions: Dimensions which are compatible to be selected in the
11690	// "dimensions" section of the report.
11691	Dimensions []*Dimension `json:"dimensions,omitempty"`
11692
11693	// Kind: The kind of resource this is, in this case
11694	// dfareporting#reachReportCompatibleFields.
11695	Kind string `json:"kind,omitempty"`
11696
11697	// Metrics: Metrics which are compatible to be selected in the
11698	// "metricNames" section of the report.
11699	Metrics []*Metric `json:"metrics,omitempty"`
11700
11701	// PivotedActivityMetrics: Metrics which are compatible to be selected
11702	// as activity metrics to pivot on in the "activities" section of the
11703	// report.
11704	PivotedActivityMetrics []*Metric `json:"pivotedActivityMetrics,omitempty"`
11705
11706	// ReachByFrequencyMetrics: Metrics which are compatible to be selected
11707	// in the "reachByFrequencyMetricNames" section of the report.
11708	ReachByFrequencyMetrics []*Metric `json:"reachByFrequencyMetrics,omitempty"`
11709
11710	// ForceSendFields is a list of field names (e.g. "DimensionFilters") to
11711	// unconditionally include in API requests. By default, fields with
11712	// empty or default values are omitted from API requests. However, any
11713	// non-pointer, non-interface field appearing in ForceSendFields will be
11714	// sent to the server regardless of whether the field is empty or not.
11715	// This may be used to include empty fields in Patch requests.
11716	ForceSendFields []string `json:"-"`
11717
11718	// NullFields is a list of field names (e.g. "DimensionFilters") to
11719	// include in API requests with the JSON null value. By default, fields
11720	// with empty values are omitted from API requests. However, any field
11721	// with an empty value appearing in NullFields will be sent to the
11722	// server as null. It is an error if a field in this list has a
11723	// non-empty value. This may be used to include null fields in Patch
11724	// requests.
11725	NullFields []string `json:"-"`
11726}
11727
11728func (s *ReachReportCompatibleFields) MarshalJSON() ([]byte, error) {
11729	type NoMethod ReachReportCompatibleFields
11730	raw := NoMethod(*s)
11731	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11732}
11733
11734// Recipient: Represents a recipient.
11735type Recipient struct {
11736	// DeliveryType: The delivery type for the recipient.
11737	//
11738	// Possible values:
11739	//   "LINK"
11740	//   "ATTACHMENT"
11741	DeliveryType string `json:"deliveryType,omitempty"`
11742
11743	// Email: The email address of the recipient.
11744	Email string `json:"email,omitempty"`
11745
11746	// Kind: The kind of resource this is, in this case
11747	// dfareporting#recipient.
11748	Kind string `json:"kind,omitempty"`
11749
11750	// ForceSendFields is a list of field names (e.g. "DeliveryType") to
11751	// unconditionally include in API requests. By default, fields with
11752	// empty or default values are omitted from API requests. However, any
11753	// non-pointer, non-interface field appearing in ForceSendFields will be
11754	// sent to the server regardless of whether the field is empty or not.
11755	// This may be used to include empty fields in Patch requests.
11756	ForceSendFields []string `json:"-"`
11757
11758	// NullFields is a list of field names (e.g. "DeliveryType") to include
11759	// in API requests with the JSON null value. By default, fields with
11760	// empty values are omitted from API requests. However, any field with
11761	// an empty value appearing in NullFields will be sent to the server as
11762	// null. It is an error if a field in this list has a non-empty value.
11763	// This may be used to include null fields in Patch requests.
11764	NullFields []string `json:"-"`
11765}
11766
11767func (s *Recipient) MarshalJSON() ([]byte, error) {
11768	type NoMethod Recipient
11769	raw := NoMethod(*s)
11770	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11771}
11772
11773// Region: Contains information about a region that can be targeted by
11774// ads.
11775type Region struct {
11776	// CountryCode: Country code of the country to which this region
11777	// belongs.
11778	CountryCode string `json:"countryCode,omitempty"`
11779
11780	// CountryDartId: DART ID of the country to which this region belongs.
11781	CountryDartId int64 `json:"countryDartId,omitempty,string"`
11782
11783	// DartId: DART ID of this region.
11784	DartId int64 `json:"dartId,omitempty,string"`
11785
11786	// Kind: Identifies what kind of resource this is. Value: the fixed
11787	// string "dfareporting#region".
11788	Kind string `json:"kind,omitempty"`
11789
11790	// Name: Name of this region.
11791	Name string `json:"name,omitempty"`
11792
11793	// RegionCode: Region code.
11794	RegionCode string `json:"regionCode,omitempty"`
11795
11796	// ForceSendFields is a list of field names (e.g. "CountryCode") to
11797	// unconditionally include in API requests. By default, fields with
11798	// empty or default values are omitted from API requests. However, any
11799	// non-pointer, non-interface field appearing in ForceSendFields will be
11800	// sent to the server regardless of whether the field is empty or not.
11801	// This may be used to include empty fields in Patch requests.
11802	ForceSendFields []string `json:"-"`
11803
11804	// NullFields is a list of field names (e.g. "CountryCode") to include
11805	// in API requests with the JSON null value. By default, fields with
11806	// empty values are omitted from API requests. However, any field with
11807	// an empty value appearing in NullFields will be sent to the server as
11808	// null. It is an error if a field in this list has a non-empty value.
11809	// This may be used to include null fields in Patch requests.
11810	NullFields []string `json:"-"`
11811}
11812
11813func (s *Region) MarshalJSON() ([]byte, error) {
11814	type NoMethod Region
11815	raw := NoMethod(*s)
11816	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11817}
11818
11819// RegionsListResponse: Region List Response
11820type RegionsListResponse struct {
11821	// Kind: Identifies what kind of resource this is. Value: the fixed
11822	// string "dfareporting#regionsListResponse".
11823	Kind string `json:"kind,omitempty"`
11824
11825	// Regions: Region collection.
11826	Regions []*Region `json:"regions,omitempty"`
11827
11828	// ServerResponse contains the HTTP response code and headers from the
11829	// server.
11830	googleapi.ServerResponse `json:"-"`
11831
11832	// ForceSendFields is a list of field names (e.g. "Kind") to
11833	// unconditionally include in API requests. By default, fields with
11834	// empty or default values are omitted from API requests. However, any
11835	// non-pointer, non-interface field appearing in ForceSendFields will be
11836	// sent to the server regardless of whether the field is empty or not.
11837	// This may be used to include empty fields in Patch requests.
11838	ForceSendFields []string `json:"-"`
11839
11840	// NullFields is a list of field names (e.g. "Kind") to include in API
11841	// requests with the JSON null value. By default, fields with empty
11842	// values are omitted from API requests. However, any field with an
11843	// empty value appearing in NullFields will be sent to the server as
11844	// null. It is an error if a field in this list has a non-empty value.
11845	// This may be used to include null fields in Patch requests.
11846	NullFields []string `json:"-"`
11847}
11848
11849func (s *RegionsListResponse) MarshalJSON() ([]byte, error) {
11850	type NoMethod RegionsListResponse
11851	raw := NoMethod(*s)
11852	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11853}
11854
11855// RemarketingList: Contains properties of a remarketing list.
11856// Remarketing enables you to create lists of users who have performed
11857// specific actions on a site, then target ads to members of those
11858// lists. This resource can be used to manage remarketing lists that are
11859// owned by your advertisers. To see all remarketing lists that are
11860// visible to your advertisers, including those that are shared to your
11861// advertiser or account, use the TargetableRemarketingLists resource.
11862type RemarketingList struct {
11863	// AccountId: Account ID of this remarketing list. This is a read-only,
11864	// auto-generated field that is only returned in GET requests.
11865	AccountId int64 `json:"accountId,omitempty,string"`
11866
11867	// Active: Whether this remarketing list is active.
11868	Active bool `json:"active,omitempty"`
11869
11870	// AdvertiserId: Dimension value for the advertiser ID that owns this
11871	// remarketing list. This is a required field.
11872	AdvertiserId int64 `json:"advertiserId,omitempty,string"`
11873
11874	// AdvertiserIdDimensionValue: Dimension value for the ID of the
11875	// advertiser. This is a read-only, auto-generated field.
11876	AdvertiserIdDimensionValue *DimensionValue `json:"advertiserIdDimensionValue,omitempty"`
11877
11878	// Description: Remarketing list description.
11879	Description string `json:"description,omitempty"`
11880
11881	// Id: Remarketing list ID. This is a read-only, auto-generated field.
11882	Id int64 `json:"id,omitempty,string"`
11883
11884	// Kind: Identifies what kind of resource this is. Value: the fixed
11885	// string "dfareporting#remarketingList".
11886	Kind string `json:"kind,omitempty"`
11887
11888	// LifeSpan: Number of days that a user should remain in the remarketing
11889	// list without an impression. Acceptable values are 1 to 540,
11890	// inclusive.
11891	LifeSpan int64 `json:"lifeSpan,omitempty,string"`
11892
11893	// ListPopulationRule: Rule used to populate the remarketing list with
11894	// users.
11895	ListPopulationRule *ListPopulationRule `json:"listPopulationRule,omitempty"`
11896
11897	// ListSize: Number of users currently in the list. This is a read-only
11898	// field.
11899	ListSize int64 `json:"listSize,omitempty,string"`
11900
11901	// ListSource: Product from which this remarketing list was originated.
11902	//
11903	// Possible values:
11904	//   "REMARKETING_LIST_SOURCE_OTHER"
11905	//   "REMARKETING_LIST_SOURCE_ADX"
11906	//   "REMARKETING_LIST_SOURCE_DFP"
11907	//   "REMARKETING_LIST_SOURCE_XFP"
11908	//   "REMARKETING_LIST_SOURCE_DFA"
11909	//   "REMARKETING_LIST_SOURCE_GA"
11910	//   "REMARKETING_LIST_SOURCE_YOUTUBE"
11911	//   "REMARKETING_LIST_SOURCE_DBM"
11912	//   "REMARKETING_LIST_SOURCE_GPLUS"
11913	//   "REMARKETING_LIST_SOURCE_DMP"
11914	//   "REMARKETING_LIST_SOURCE_PLAY_STORE"
11915	ListSource string `json:"listSource,omitempty"`
11916
11917	// Name: Name of the remarketing list. This is a required field. Must be
11918	// no greater than 128 characters long.
11919	Name string `json:"name,omitempty"`
11920
11921	// SubaccountId: Subaccount ID of this remarketing list. This is a
11922	// read-only, auto-generated field that is only returned in GET
11923	// requests.
11924	SubaccountId int64 `json:"subaccountId,omitempty,string"`
11925
11926	// ServerResponse contains the HTTP response code and headers from the
11927	// server.
11928	googleapi.ServerResponse `json:"-"`
11929
11930	// ForceSendFields is a list of field names (e.g. "AccountId") to
11931	// unconditionally include in API requests. By default, fields with
11932	// empty or default values are omitted from API requests. However, any
11933	// non-pointer, non-interface field appearing in ForceSendFields will be
11934	// sent to the server regardless of whether the field is empty or not.
11935	// This may be used to include empty fields in Patch requests.
11936	ForceSendFields []string `json:"-"`
11937
11938	// NullFields is a list of field names (e.g. "AccountId") to include in
11939	// API requests with the JSON null value. By default, fields with empty
11940	// values are omitted from API requests. However, any field with an
11941	// empty value appearing in NullFields will be sent to the server as
11942	// null. It is an error if a field in this list has a non-empty value.
11943	// This may be used to include null fields in Patch requests.
11944	NullFields []string `json:"-"`
11945}
11946
11947func (s *RemarketingList) MarshalJSON() ([]byte, error) {
11948	type NoMethod RemarketingList
11949	raw := NoMethod(*s)
11950	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11951}
11952
11953// RemarketingListShare: Contains properties of a remarketing list's
11954// sharing information. Sharing allows other accounts or advertisers to
11955// target to your remarketing lists. This resource can be used to manage
11956// remarketing list sharing to other accounts and advertisers.
11957type RemarketingListShare struct {
11958	// Kind: Identifies what kind of resource this is. Value: the fixed
11959	// string "dfareporting#remarketingListShare".
11960	Kind string `json:"kind,omitempty"`
11961
11962	// RemarketingListId: Remarketing list ID. This is a read-only,
11963	// auto-generated field.
11964	RemarketingListId int64 `json:"remarketingListId,omitempty,string"`
11965
11966	// SharedAccountIds: Accounts that the remarketing list is shared with.
11967	SharedAccountIds googleapi.Int64s `json:"sharedAccountIds,omitempty"`
11968
11969	// SharedAdvertiserIds: Advertisers that the remarketing list is shared
11970	// with.
11971	SharedAdvertiserIds googleapi.Int64s `json:"sharedAdvertiserIds,omitempty"`
11972
11973	// ServerResponse contains the HTTP response code and headers from the
11974	// server.
11975	googleapi.ServerResponse `json:"-"`
11976
11977	// ForceSendFields is a list of field names (e.g. "Kind") to
11978	// unconditionally include in API requests. By default, fields with
11979	// empty or default values are omitted from API requests. However, any
11980	// non-pointer, non-interface field appearing in ForceSendFields will be
11981	// sent to the server regardless of whether the field is empty or not.
11982	// This may be used to include empty fields in Patch requests.
11983	ForceSendFields []string `json:"-"`
11984
11985	// NullFields is a list of field names (e.g. "Kind") to include in API
11986	// requests with the JSON null value. By default, fields with empty
11987	// values are omitted from API requests. However, any field with an
11988	// empty value appearing in NullFields will be sent to the server as
11989	// null. It is an error if a field in this list has a non-empty value.
11990	// This may be used to include null fields in Patch requests.
11991	NullFields []string `json:"-"`
11992}
11993
11994func (s *RemarketingListShare) MarshalJSON() ([]byte, error) {
11995	type NoMethod RemarketingListShare
11996	raw := NoMethod(*s)
11997	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11998}
11999
12000// RemarketingListsListResponse: Remarketing list response
12001type RemarketingListsListResponse struct {
12002	// Kind: Identifies what kind of resource this is. Value: the fixed
12003	// string "dfareporting#remarketingListsListResponse".
12004	Kind string `json:"kind,omitempty"`
12005
12006	// NextPageToken: Pagination token to be used for the next list
12007	// operation.
12008	NextPageToken string `json:"nextPageToken,omitempty"`
12009
12010	// RemarketingLists: Remarketing list collection.
12011	RemarketingLists []*RemarketingList `json:"remarketingLists,omitempty"`
12012
12013	// ServerResponse contains the HTTP response code and headers from the
12014	// server.
12015	googleapi.ServerResponse `json:"-"`
12016
12017	// ForceSendFields is a list of field names (e.g. "Kind") to
12018	// unconditionally include in API requests. By default, fields with
12019	// empty or default values are omitted from API requests. However, any
12020	// non-pointer, non-interface field appearing in ForceSendFields will be
12021	// sent to the server regardless of whether the field is empty or not.
12022	// This may be used to include empty fields in Patch requests.
12023	ForceSendFields []string `json:"-"`
12024
12025	// NullFields is a list of field names (e.g. "Kind") to include in API
12026	// requests with the JSON null value. By default, fields with empty
12027	// values are omitted from API requests. However, any field with an
12028	// empty value appearing in NullFields will be sent to the server as
12029	// null. It is an error if a field in this list has a non-empty value.
12030	// This may be used to include null fields in Patch requests.
12031	NullFields []string `json:"-"`
12032}
12033
12034func (s *RemarketingListsListResponse) MarshalJSON() ([]byte, error) {
12035	type NoMethod RemarketingListsListResponse
12036	raw := NoMethod(*s)
12037	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12038}
12039
12040// Report: Represents a Report resource.
12041type Report struct {
12042	// AccountId: The account ID to which this report belongs.
12043	AccountId int64 `json:"accountId,omitempty,string"`
12044
12045	// Criteria: The report criteria for a report of type "STANDARD".
12046	Criteria *ReportCriteria `json:"criteria,omitempty"`
12047
12048	// CrossDimensionReachCriteria: The report criteria for a report of type
12049	// "CROSS_DIMENSION_REACH".
12050	CrossDimensionReachCriteria *ReportCrossDimensionReachCriteria `json:"crossDimensionReachCriteria,omitempty"`
12051
12052	// Delivery: The report's email delivery settings.
12053	Delivery *ReportDelivery `json:"delivery,omitempty"`
12054
12055	// Etag: The eTag of this response for caching purposes.
12056	Etag string `json:"etag,omitempty"`
12057
12058	// FileName: The filename used when generating report files for this
12059	// report.
12060	FileName string `json:"fileName,omitempty"`
12061
12062	// FloodlightCriteria: The report criteria for a report of type
12063	// "FLOODLIGHT".
12064	FloodlightCriteria *ReportFloodlightCriteria `json:"floodlightCriteria,omitempty"`
12065
12066	// Format: The output format of the report. If not specified, default
12067	// format is "CSV". Note that the actual format in the completed report
12068	// file might differ if for instance the report's size exceeds the
12069	// format's capabilities. "CSV" will then be the fallback format.
12070	//
12071	// Possible values:
12072	//   "CSV"
12073	//   "EXCEL"
12074	Format string `json:"format,omitempty"`
12075
12076	// Id: The unique ID identifying this report resource.
12077	Id int64 `json:"id,omitempty,string"`
12078
12079	// Kind: The kind of resource this is, in this case dfareporting#report.
12080	Kind string `json:"kind,omitempty"`
12081
12082	// LastModifiedTime: The timestamp (in milliseconds since epoch) of when
12083	// this report was last modified.
12084	LastModifiedTime uint64 `json:"lastModifiedTime,omitempty,string"`
12085
12086	// Name: The name of the report.
12087	Name string `json:"name,omitempty"`
12088
12089	// OwnerProfileId: The user profile id of the owner of this report.
12090	OwnerProfileId int64 `json:"ownerProfileId,omitempty,string"`
12091
12092	// PathAttributionCriteria: The report criteria for a report of type
12093	// "PATH_ATTRIBUTION".
12094	PathAttributionCriteria *ReportPathAttributionCriteria `json:"pathAttributionCriteria,omitempty"`
12095
12096	// PathCriteria: The report criteria for a report of type "PATH".
12097	PathCriteria *ReportPathCriteria `json:"pathCriteria,omitempty"`
12098
12099	// PathToConversionCriteria: The report criteria for a report of type
12100	// "PATH_TO_CONVERSION".
12101	PathToConversionCriteria *ReportPathToConversionCriteria `json:"pathToConversionCriteria,omitempty"`
12102
12103	// ReachCriteria: The report criteria for a report of type "REACH".
12104	ReachCriteria *ReportReachCriteria `json:"reachCriteria,omitempty"`
12105
12106	// Schedule: The report's schedule. Can only be set if the report's
12107	// 'dateRange' is a relative date range and the relative date range is
12108	// not "TODAY".
12109	Schedule *ReportSchedule `json:"schedule,omitempty"`
12110
12111	// SubAccountId: The subaccount ID to which this report belongs if
12112	// applicable.
12113	SubAccountId int64 `json:"subAccountId,omitempty,string"`
12114
12115	// Type: The type of the report.
12116	//
12117	// Possible values:
12118	//   "STANDARD"
12119	//   "REACH"
12120	//   "PATH_TO_CONVERSION"
12121	//   "CROSS_DIMENSION_REACH"
12122	//   "FLOODLIGHT"
12123	//   "PATH"
12124	//   "PATH_ATTRIBUTION"
12125	Type string `json:"type,omitempty"`
12126
12127	// ServerResponse contains the HTTP response code and headers from the
12128	// server.
12129	googleapi.ServerResponse `json:"-"`
12130
12131	// ForceSendFields is a list of field names (e.g. "AccountId") to
12132	// unconditionally include in API requests. By default, fields with
12133	// empty or default values are omitted from API requests. However, any
12134	// non-pointer, non-interface field appearing in ForceSendFields will be
12135	// sent to the server regardless of whether the field is empty or not.
12136	// This may be used to include empty fields in Patch requests.
12137	ForceSendFields []string `json:"-"`
12138
12139	// NullFields is a list of field names (e.g. "AccountId") to include in
12140	// API requests with the JSON null value. By default, fields with empty
12141	// values are omitted from API requests. However, any field with an
12142	// empty value appearing in NullFields will be sent to the server as
12143	// null. It is an error if a field in this list has a non-empty value.
12144	// This may be used to include null fields in Patch requests.
12145	NullFields []string `json:"-"`
12146}
12147
12148func (s *Report) MarshalJSON() ([]byte, error) {
12149	type NoMethod Report
12150	raw := NoMethod(*s)
12151	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12152}
12153
12154// ReportCriteria: The report criteria for a report of type "STANDARD".
12155type ReportCriteria struct {
12156	// Activities: Activity group.
12157	Activities *Activities `json:"activities,omitempty"`
12158
12159	// CustomRichMediaEvents: Custom Rich Media Events group.
12160	CustomRichMediaEvents *CustomRichMediaEvents `json:"customRichMediaEvents,omitempty"`
12161
12162	// DateRange: The date range for which this report should be run.
12163	DateRange *DateRange `json:"dateRange,omitempty"`
12164
12165	// DimensionFilters: The list of filters on which dimensions are
12166	// filtered. Filters for different dimensions are ANDed, filters for the
12167	// same dimension are grouped together and ORed.
12168	DimensionFilters []*DimensionValue `json:"dimensionFilters,omitempty"`
12169
12170	// Dimensions: The list of standard dimensions the report should
12171	// include.
12172	Dimensions []*SortedDimension `json:"dimensions,omitempty"`
12173
12174	// MetricNames: The list of names of metrics the report should include.
12175	MetricNames []string `json:"metricNames,omitempty"`
12176
12177	// ForceSendFields is a list of field names (e.g. "Activities") to
12178	// unconditionally include in API requests. By default, fields with
12179	// empty or default values are omitted from API requests. However, any
12180	// non-pointer, non-interface field appearing in ForceSendFields will be
12181	// sent to the server regardless of whether the field is empty or not.
12182	// This may be used to include empty fields in Patch requests.
12183	ForceSendFields []string `json:"-"`
12184
12185	// NullFields is a list of field names (e.g. "Activities") to include in
12186	// API requests with the JSON null value. By default, fields with empty
12187	// values are omitted from API requests. However, any field with an
12188	// empty value appearing in NullFields will be sent to the server as
12189	// null. It is an error if a field in this list has a non-empty value.
12190	// This may be used to include null fields in Patch requests.
12191	NullFields []string `json:"-"`
12192}
12193
12194func (s *ReportCriteria) MarshalJSON() ([]byte, error) {
12195	type NoMethod ReportCriteria
12196	raw := NoMethod(*s)
12197	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12198}
12199
12200// ReportCrossDimensionReachCriteria: The report criteria for a report
12201// of type "CROSS_DIMENSION_REACH".
12202type ReportCrossDimensionReachCriteria struct {
12203	// Breakdown: The list of dimensions the report should include.
12204	Breakdown []*SortedDimension `json:"breakdown,omitempty"`
12205
12206	// DateRange: The date range this report should be run for.
12207	DateRange *DateRange `json:"dateRange,omitempty"`
12208
12209	// Dimension: The dimension option.
12210	//
12211	// Possible values:
12212	//   "ADVERTISER"
12213	//   "CAMPAIGN"
12214	//   "SITE_BY_ADVERTISER"
12215	//   "SITE_BY_CAMPAIGN"
12216	Dimension string `json:"dimension,omitempty"`
12217
12218	// DimensionFilters: The list of filters on which dimensions are
12219	// filtered.
12220	DimensionFilters []*DimensionValue `json:"dimensionFilters,omitempty"`
12221
12222	// MetricNames: The list of names of metrics the report should include.
12223	MetricNames []string `json:"metricNames,omitempty"`
12224
12225	// OverlapMetricNames: The list of names of overlap metrics the report
12226	// should include.
12227	OverlapMetricNames []string `json:"overlapMetricNames,omitempty"`
12228
12229	// Pivoted: Whether the report is pivoted or not. Defaults to true.
12230	Pivoted bool `json:"pivoted,omitempty"`
12231
12232	// ForceSendFields is a list of field names (e.g. "Breakdown") to
12233	// unconditionally include in API requests. By default, fields with
12234	// empty or default values are omitted from API requests. However, any
12235	// non-pointer, non-interface field appearing in ForceSendFields will be
12236	// sent to the server regardless of whether the field is empty or not.
12237	// This may be used to include empty fields in Patch requests.
12238	ForceSendFields []string `json:"-"`
12239
12240	// NullFields is a list of field names (e.g. "Breakdown") to include in
12241	// API requests with the JSON null value. By default, fields with empty
12242	// values are omitted from API requests. However, any field with an
12243	// empty value appearing in NullFields will be sent to the server as
12244	// null. It is an error if a field in this list has a non-empty value.
12245	// This may be used to include null fields in Patch requests.
12246	NullFields []string `json:"-"`
12247}
12248
12249func (s *ReportCrossDimensionReachCriteria) MarshalJSON() ([]byte, error) {
12250	type NoMethod ReportCrossDimensionReachCriteria
12251	raw := NoMethod(*s)
12252	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12253}
12254
12255// ReportDelivery: The report's email delivery settings.
12256type ReportDelivery struct {
12257	// EmailOwner: Whether the report should be emailed to the report owner.
12258	EmailOwner bool `json:"emailOwner,omitempty"`
12259
12260	// EmailOwnerDeliveryType: The type of delivery for the owner to
12261	// receive, if enabled.
12262	//
12263	// Possible values:
12264	//   "LINK"
12265	//   "ATTACHMENT"
12266	EmailOwnerDeliveryType string `json:"emailOwnerDeliveryType,omitempty"`
12267
12268	// Message: The message to be sent with each email.
12269	Message string `json:"message,omitempty"`
12270
12271	// Recipients: The list of recipients to which to email the report.
12272	Recipients []*Recipient `json:"recipients,omitempty"`
12273
12274	// ForceSendFields is a list of field names (e.g. "EmailOwner") to
12275	// unconditionally include in API requests. By default, fields with
12276	// empty or default values are omitted from API requests. However, any
12277	// non-pointer, non-interface field appearing in ForceSendFields will be
12278	// sent to the server regardless of whether the field is empty or not.
12279	// This may be used to include empty fields in Patch requests.
12280	ForceSendFields []string `json:"-"`
12281
12282	// NullFields is a list of field names (e.g. "EmailOwner") to include in
12283	// API requests with the JSON null value. By default, fields with empty
12284	// values are omitted from API requests. However, any field with an
12285	// empty value appearing in NullFields will be sent to the server as
12286	// null. It is an error if a field in this list has a non-empty value.
12287	// This may be used to include null fields in Patch requests.
12288	NullFields []string `json:"-"`
12289}
12290
12291func (s *ReportDelivery) MarshalJSON() ([]byte, error) {
12292	type NoMethod ReportDelivery
12293	raw := NoMethod(*s)
12294	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12295}
12296
12297// ReportFloodlightCriteria: The report criteria for a report of type
12298// "FLOODLIGHT".
12299type ReportFloodlightCriteria struct {
12300	// CustomRichMediaEvents: The list of custom rich media events to
12301	// include.
12302	CustomRichMediaEvents []*DimensionValue `json:"customRichMediaEvents,omitempty"`
12303
12304	// DateRange: The date range this report should be run for.
12305	DateRange *DateRange `json:"dateRange,omitempty"`
12306
12307	// DimensionFilters: The list of filters on which dimensions are
12308	// filtered. Filters for different dimensions are ANDed, filters for the
12309	// same dimension are grouped together and ORed.
12310	DimensionFilters []*DimensionValue `json:"dimensionFilters,omitempty"`
12311
12312	// Dimensions: The list of dimensions the report should include.
12313	Dimensions []*SortedDimension `json:"dimensions,omitempty"`
12314
12315	// FloodlightConfigId: The floodlight ID for which to show data in this
12316	// report. All advertisers associated with that ID will automatically be
12317	// added. The dimension of the value needs to be
12318	// 'dfa:floodlightConfigId'.
12319	FloodlightConfigId *DimensionValue `json:"floodlightConfigId,omitempty"`
12320
12321	// MetricNames: The list of names of metrics the report should include.
12322	MetricNames []string `json:"metricNames,omitempty"`
12323
12324	// ReportProperties: The properties of the report.
12325	ReportProperties *ReportFloodlightCriteriaReportProperties `json:"reportProperties,omitempty"`
12326
12327	// ForceSendFields is a list of field names (e.g.
12328	// "CustomRichMediaEvents") to unconditionally include in API requests.
12329	// By default, fields with empty or default values are omitted from API
12330	// requests. However, any non-pointer, non-interface field appearing in
12331	// ForceSendFields will be sent to the server regardless of whether the
12332	// field is empty or not. This may be used to include empty fields in
12333	// Patch requests.
12334	ForceSendFields []string `json:"-"`
12335
12336	// NullFields is a list of field names (e.g. "CustomRichMediaEvents") to
12337	// include in API requests with the JSON null value. By default, fields
12338	// with empty values are omitted from API requests. However, any field
12339	// with an empty value appearing in NullFields will be sent to the
12340	// server as null. It is an error if a field in this list has a
12341	// non-empty value. This may be used to include null fields in Patch
12342	// requests.
12343	NullFields []string `json:"-"`
12344}
12345
12346func (s *ReportFloodlightCriteria) MarshalJSON() ([]byte, error) {
12347	type NoMethod ReportFloodlightCriteria
12348	raw := NoMethod(*s)
12349	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12350}
12351
12352// ReportFloodlightCriteriaReportProperties: The properties of the
12353// report.
12354type ReportFloodlightCriteriaReportProperties struct {
12355	// IncludeAttributedIPConversions: Include conversions that have no
12356	// cookie, but do have an exposure path.
12357	IncludeAttributedIPConversions bool `json:"includeAttributedIPConversions,omitempty"`
12358
12359	// IncludeUnattributedCookieConversions: Include conversions of users
12360	// with a DoubleClick cookie but without an exposure. That means the
12361	// user did not click or see an ad from the advertiser within the
12362	// Floodlight group, or that the interaction happened outside the
12363	// lookback window.
12364	IncludeUnattributedCookieConversions bool `json:"includeUnattributedCookieConversions,omitempty"`
12365
12366	// IncludeUnattributedIPConversions: Include conversions that have no
12367	// associated cookies and no exposures. It’s therefore impossible to
12368	// know how the user was exposed to your ads during the lookback window
12369	// prior to a conversion.
12370	IncludeUnattributedIPConversions bool `json:"includeUnattributedIPConversions,omitempty"`
12371
12372	// ForceSendFields is a list of field names (e.g.
12373	// "IncludeAttributedIPConversions") to unconditionally include in API
12374	// requests. By default, fields with empty or default values are omitted
12375	// from API requests. However, any non-pointer, non-interface field
12376	// appearing in ForceSendFields will be sent to the server regardless of
12377	// whether the field is empty or not. This may be used to include empty
12378	// fields in Patch requests.
12379	ForceSendFields []string `json:"-"`
12380
12381	// NullFields is a list of field names (e.g.
12382	// "IncludeAttributedIPConversions") to include in API requests with the
12383	// JSON null value. By default, fields with empty values are omitted
12384	// from API requests. However, any field with an empty value appearing
12385	// in NullFields will be sent to the server as null. It is an error if a
12386	// field in this list has a non-empty value. This may be used to include
12387	// null fields in Patch requests.
12388	NullFields []string `json:"-"`
12389}
12390
12391func (s *ReportFloodlightCriteriaReportProperties) MarshalJSON() ([]byte, error) {
12392	type NoMethod ReportFloodlightCriteriaReportProperties
12393	raw := NoMethod(*s)
12394	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12395}
12396
12397// ReportPathAttributionCriteria: The report criteria for a report of
12398// type "PATH_ATTRIBUTION".
12399type ReportPathAttributionCriteria struct {
12400	// ActivityFilters: The list of 'dfa:activity' values to filter on.
12401	ActivityFilters []*DimensionValue `json:"activityFilters,omitempty"`
12402
12403	// CustomChannelGrouping: Channel Grouping.
12404	CustomChannelGrouping *ChannelGrouping `json:"customChannelGrouping,omitempty"`
12405
12406	// DateRange: The date range this report should be run for.
12407	DateRange *DateRange `json:"dateRange,omitempty"`
12408
12409	// Dimensions: The list of dimensions the report should include.
12410	Dimensions []*SortedDimension `json:"dimensions,omitempty"`
12411
12412	// FloodlightConfigId: The floodlight ID for which to show data in this
12413	// report. All advertisers associated with that ID will automatically be
12414	// added. The dimension of the value needs to be
12415	// 'dfa:floodlightConfigId'.
12416	FloodlightConfigId *DimensionValue `json:"floodlightConfigId,omitempty"`
12417
12418	// MetricNames: The list of names of metrics the report should include.
12419	MetricNames []string `json:"metricNames,omitempty"`
12420
12421	// PathFilters: Path Filters.
12422	PathFilters []*PathFilter `json:"pathFilters,omitempty"`
12423
12424	// ForceSendFields is a list of field names (e.g. "ActivityFilters") to
12425	// unconditionally include in API requests. By default, fields with
12426	// empty or default values are omitted from API requests. However, any
12427	// non-pointer, non-interface field appearing in ForceSendFields will be
12428	// sent to the server regardless of whether the field is empty or not.
12429	// This may be used to include empty fields in Patch requests.
12430	ForceSendFields []string `json:"-"`
12431
12432	// NullFields is a list of field names (e.g. "ActivityFilters") to
12433	// include in API requests with the JSON null value. By default, fields
12434	// with empty values are omitted from API requests. However, any field
12435	// with an empty value appearing in NullFields will be sent to the
12436	// server as null. It is an error if a field in this list has a
12437	// non-empty value. This may be used to include null fields in Patch
12438	// requests.
12439	NullFields []string `json:"-"`
12440}
12441
12442func (s *ReportPathAttributionCriteria) MarshalJSON() ([]byte, error) {
12443	type NoMethod ReportPathAttributionCriteria
12444	raw := NoMethod(*s)
12445	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12446}
12447
12448// ReportPathCriteria: The report criteria for a report of type "PATH".
12449type ReportPathCriteria struct {
12450	// ActivityFilters: The list of 'dfa:activity' values to filter on.
12451	ActivityFilters []*DimensionValue `json:"activityFilters,omitempty"`
12452
12453	// CustomChannelGrouping: Channel Grouping.
12454	CustomChannelGrouping *ChannelGrouping `json:"customChannelGrouping,omitempty"`
12455
12456	// DateRange: The date range this report should be run for.
12457	DateRange *DateRange `json:"dateRange,omitempty"`
12458
12459	// Dimensions: The list of dimensions the report should include.
12460	Dimensions []*SortedDimension `json:"dimensions,omitempty"`
12461
12462	// FloodlightConfigId: The floodlight ID for which to show data in this
12463	// report. All advertisers associated with that ID will automatically be
12464	// added. The dimension of the value needs to be
12465	// 'dfa:floodlightConfigId'.
12466	FloodlightConfigId *DimensionValue `json:"floodlightConfigId,omitempty"`
12467
12468	// MetricNames: The list of names of metrics the report should include.
12469	MetricNames []string `json:"metricNames,omitempty"`
12470
12471	// PathFilters: Path Filters.
12472	PathFilters []*PathFilter `json:"pathFilters,omitempty"`
12473
12474	// ForceSendFields is a list of field names (e.g. "ActivityFilters") to
12475	// unconditionally include in API requests. By default, fields with
12476	// empty or default values are omitted from API requests. However, any
12477	// non-pointer, non-interface field appearing in ForceSendFields will be
12478	// sent to the server regardless of whether the field is empty or not.
12479	// This may be used to include empty fields in Patch requests.
12480	ForceSendFields []string `json:"-"`
12481
12482	// NullFields is a list of field names (e.g. "ActivityFilters") to
12483	// include in API requests with the JSON null value. By default, fields
12484	// with empty values are omitted from API requests. However, any field
12485	// with an empty value appearing in NullFields will be sent to the
12486	// server as null. It is an error if a field in this list has a
12487	// non-empty value. This may be used to include null fields in Patch
12488	// requests.
12489	NullFields []string `json:"-"`
12490}
12491
12492func (s *ReportPathCriteria) MarshalJSON() ([]byte, error) {
12493	type NoMethod ReportPathCriteria
12494	raw := NoMethod(*s)
12495	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12496}
12497
12498// ReportPathToConversionCriteria: The report criteria for a report of
12499// type "PATH_TO_CONVERSION".
12500type ReportPathToConversionCriteria struct {
12501	// ActivityFilters: The list of 'dfa:activity' values to filter on.
12502	ActivityFilters []*DimensionValue `json:"activityFilters,omitempty"`
12503
12504	// ConversionDimensions: The list of conversion dimensions the report
12505	// should include.
12506	ConversionDimensions []*SortedDimension `json:"conversionDimensions,omitempty"`
12507
12508	// CustomFloodlightVariables: The list of custom floodlight variables
12509	// the report should include.
12510	CustomFloodlightVariables []*SortedDimension `json:"customFloodlightVariables,omitempty"`
12511
12512	// CustomRichMediaEvents: The list of custom rich media events to
12513	// include.
12514	CustomRichMediaEvents []*DimensionValue `json:"customRichMediaEvents,omitempty"`
12515
12516	// DateRange: The date range this report should be run for.
12517	DateRange *DateRange `json:"dateRange,omitempty"`
12518
12519	// FloodlightConfigId: The floodlight ID for which to show data in this
12520	// report. All advertisers associated with that ID will automatically be
12521	// added. The dimension of the value needs to be
12522	// 'dfa:floodlightConfigId'.
12523	FloodlightConfigId *DimensionValue `json:"floodlightConfigId,omitempty"`
12524
12525	// MetricNames: The list of names of metrics the report should include.
12526	MetricNames []string `json:"metricNames,omitempty"`
12527
12528	// PerInteractionDimensions: The list of per interaction dimensions the
12529	// report should include.
12530	PerInteractionDimensions []*SortedDimension `json:"perInteractionDimensions,omitempty"`
12531
12532	// ReportProperties: The properties of the report.
12533	ReportProperties *ReportPathToConversionCriteriaReportProperties `json:"reportProperties,omitempty"`
12534
12535	// ForceSendFields is a list of field names (e.g. "ActivityFilters") to
12536	// unconditionally include in API requests. By default, fields with
12537	// empty or default values are omitted from API requests. However, any
12538	// non-pointer, non-interface field appearing in ForceSendFields will be
12539	// sent to the server regardless of whether the field is empty or not.
12540	// This may be used to include empty fields in Patch requests.
12541	ForceSendFields []string `json:"-"`
12542
12543	// NullFields is a list of field names (e.g. "ActivityFilters") to
12544	// include in API requests with the JSON null value. By default, fields
12545	// with empty values are omitted from API requests. However, any field
12546	// with an empty value appearing in NullFields will be sent to the
12547	// server as null. It is an error if a field in this list has a
12548	// non-empty value. This may be used to include null fields in Patch
12549	// requests.
12550	NullFields []string `json:"-"`
12551}
12552
12553func (s *ReportPathToConversionCriteria) MarshalJSON() ([]byte, error) {
12554	type NoMethod ReportPathToConversionCriteria
12555	raw := NoMethod(*s)
12556	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12557}
12558
12559// ReportPathToConversionCriteriaReportProperties: The properties of the
12560// report.
12561type ReportPathToConversionCriteriaReportProperties struct {
12562	// ClicksLookbackWindow: CM360 checks to see if a click interaction
12563	// occurred within the specified period of time before a conversion. By
12564	// default the value is pulled from Floodlight or you can manually enter
12565	// a custom value. Valid values: 1-90.
12566	ClicksLookbackWindow int64 `json:"clicksLookbackWindow,omitempty"`
12567
12568	// ImpressionsLookbackWindow: CM360 checks to see if an impression
12569	// interaction occurred within the specified period of time before a
12570	// conversion. By default the value is pulled from Floodlight or you can
12571	// manually enter a custom value. Valid values: 1-90.
12572	ImpressionsLookbackWindow int64 `json:"impressionsLookbackWindow,omitempty"`
12573
12574	// IncludeAttributedIPConversions: Deprecated: has no effect.
12575	IncludeAttributedIPConversions bool `json:"includeAttributedIPConversions,omitempty"`
12576
12577	// IncludeUnattributedCookieConversions: Include conversions of users
12578	// with a DoubleClick cookie but without an exposure. That means the
12579	// user did not click or see an ad from the advertiser within the
12580	// Floodlight group, or that the interaction happened outside the
12581	// lookback window.
12582	IncludeUnattributedCookieConversions bool `json:"includeUnattributedCookieConversions,omitempty"`
12583
12584	// IncludeUnattributedIPConversions: Include conversions that have no
12585	// associated cookies and no exposures. It’s therefore impossible to
12586	// know how the user was exposed to your ads during the lookback window
12587	// prior to a conversion.
12588	IncludeUnattributedIPConversions bool `json:"includeUnattributedIPConversions,omitempty"`
12589
12590	// MaximumClickInteractions: The maximum number of click interactions to
12591	// include in the report. Advertisers currently paying for E2C reports
12592	// get up to 200 (100 clicks, 100 impressions). If another advertiser in
12593	// your network is paying for E2C, you can have up to 5 total exposures
12594	// per report.
12595	MaximumClickInteractions int64 `json:"maximumClickInteractions,omitempty"`
12596
12597	// MaximumImpressionInteractions: The maximum number of click
12598	// interactions to include in the report. Advertisers currently paying
12599	// for E2C reports get up to 200 (100 clicks, 100 impressions). If
12600	// another advertiser in your network is paying for E2C, you can have up
12601	// to 5 total exposures per report.
12602	MaximumImpressionInteractions int64 `json:"maximumImpressionInteractions,omitempty"`
12603
12604	// MaximumInteractionGap: The maximum amount of time that can take place
12605	// between interactions (clicks or impressions) by the same user. Valid
12606	// values: 1-90.
12607	MaximumInteractionGap int64 `json:"maximumInteractionGap,omitempty"`
12608
12609	// PivotOnInteractionPath: Enable pivoting on interaction path.
12610	PivotOnInteractionPath bool `json:"pivotOnInteractionPath,omitempty"`
12611
12612	// ForceSendFields is a list of field names (e.g.
12613	// "ClicksLookbackWindow") to unconditionally include in API requests.
12614	// By default, fields with empty or default values are omitted from API
12615	// requests. However, any non-pointer, non-interface field appearing in
12616	// ForceSendFields will be sent to the server regardless of whether the
12617	// field is empty or not. This may be used to include empty fields in
12618	// Patch requests.
12619	ForceSendFields []string `json:"-"`
12620
12621	// NullFields is a list of field names (e.g. "ClicksLookbackWindow") to
12622	// include in API requests with the JSON null value. By default, fields
12623	// with empty values are omitted from API requests. However, any field
12624	// with an empty value appearing in NullFields will be sent to the
12625	// server as null. It is an error if a field in this list has a
12626	// non-empty value. This may be used to include null fields in Patch
12627	// requests.
12628	NullFields []string `json:"-"`
12629}
12630
12631func (s *ReportPathToConversionCriteriaReportProperties) MarshalJSON() ([]byte, error) {
12632	type NoMethod ReportPathToConversionCriteriaReportProperties
12633	raw := NoMethod(*s)
12634	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12635}
12636
12637// ReportReachCriteria: The report criteria for a report of type
12638// "REACH".
12639type ReportReachCriteria struct {
12640	// Activities: Activity group.
12641	Activities *Activities `json:"activities,omitempty"`
12642
12643	// CustomRichMediaEvents: Custom Rich Media Events group.
12644	CustomRichMediaEvents *CustomRichMediaEvents `json:"customRichMediaEvents,omitempty"`
12645
12646	// DateRange: The date range this report should be run for.
12647	DateRange *DateRange `json:"dateRange,omitempty"`
12648
12649	// DimensionFilters: The list of filters on which dimensions are
12650	// filtered. Filters for different dimensions are ANDed, filters for the
12651	// same dimension are grouped together and ORed.
12652	DimensionFilters []*DimensionValue `json:"dimensionFilters,omitempty"`
12653
12654	// Dimensions: The list of dimensions the report should include.
12655	Dimensions []*SortedDimension `json:"dimensions,omitempty"`
12656
12657	// EnableAllDimensionCombinations: Whether to enable all reach dimension
12658	// combinations in the report. Defaults to false. If enabled, the date
12659	// range of the report should be within the last 42 days.
12660	EnableAllDimensionCombinations bool `json:"enableAllDimensionCombinations,omitempty"`
12661
12662	// MetricNames: The list of names of metrics the report should include.
12663	MetricNames []string `json:"metricNames,omitempty"`
12664
12665	// ReachByFrequencyMetricNames: The list of names of Reach By Frequency
12666	// metrics the report should include.
12667	ReachByFrequencyMetricNames []string `json:"reachByFrequencyMetricNames,omitempty"`
12668
12669	// ForceSendFields is a list of field names (e.g. "Activities") to
12670	// unconditionally include in API requests. By default, fields with
12671	// empty or default values are omitted from API requests. However, any
12672	// non-pointer, non-interface field appearing in ForceSendFields will be
12673	// sent to the server regardless of whether the field is empty or not.
12674	// This may be used to include empty fields in Patch requests.
12675	ForceSendFields []string `json:"-"`
12676
12677	// NullFields is a list of field names (e.g. "Activities") to include in
12678	// API requests with the JSON null value. By default, fields with empty
12679	// values are omitted from API requests. However, any field with an
12680	// empty value appearing in NullFields will be sent to the server as
12681	// null. It is an error if a field in this list has a non-empty value.
12682	// This may be used to include null fields in Patch requests.
12683	NullFields []string `json:"-"`
12684}
12685
12686func (s *ReportReachCriteria) MarshalJSON() ([]byte, error) {
12687	type NoMethod ReportReachCriteria
12688	raw := NoMethod(*s)
12689	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12690}
12691
12692// ReportSchedule: The report's schedule. Can only be set if the
12693// report's 'dateRange' is a relative date range and the relative date
12694// range is not "TODAY".
12695type ReportSchedule struct {
12696	// Active: Whether the schedule is active or not. Must be set to either
12697	// true or false.
12698	Active bool `json:"active,omitempty"`
12699
12700	// Every: Defines every how many days, weeks or months the report should
12701	// be run. Needs to be set when "repeats" is either "DAILY", "WEEKLY" or
12702	// "MONTHLY".
12703	Every int64 `json:"every,omitempty"`
12704
12705	ExpirationDate string `json:"expirationDate,omitempty"`
12706
12707	// Repeats: The interval for which the report is repeated. Note: -
12708	// "DAILY" also requires field "every" to be set. - "WEEKLY" also
12709	// requires fields "every" and "repeatsOnWeekDays" to be set. -
12710	// "MONTHLY" also requires fields "every" and "runsOnDayOfMonth" to be
12711	// set.
12712	Repeats string `json:"repeats,omitempty"`
12713
12714	// RepeatsOnWeekDays: List of week days "WEEKLY" on which scheduled
12715	// reports should run.
12716	//
12717	// Possible values:
12718	//   "SUNDAY"
12719	//   "MONDAY"
12720	//   "TUESDAY"
12721	//   "WEDNESDAY"
12722	//   "THURSDAY"
12723	//   "FRIDAY"
12724	//   "SATURDAY"
12725	RepeatsOnWeekDays []string `json:"repeatsOnWeekDays,omitempty"`
12726
12727	// RunsOnDayOfMonth: Enum to define for "MONTHLY" scheduled reports
12728	// whether reports should be repeated on the same day of the month as
12729	// "startDate" or the same day of the week of the month. Example: If
12730	// 'startDate' is Monday, April 2nd 2012 (2012-04-02), "DAY_OF_MONTH"
12731	// would run subsequent reports on the 2nd of every Month, and
12732	// "WEEK_OF_MONTH" would run subsequent reports on the first Monday of
12733	// the month.
12734	//
12735	// Possible values:
12736	//   "DAY_OF_MONTH"
12737	//   "WEEK_OF_MONTH"
12738	RunsOnDayOfMonth string `json:"runsOnDayOfMonth,omitempty"`
12739
12740	StartDate string `json:"startDate,omitempty"`
12741
12742	// ForceSendFields is a list of field names (e.g. "Active") to
12743	// unconditionally include in API requests. By default, fields with
12744	// empty or default values are omitted from API requests. However, any
12745	// non-pointer, non-interface field appearing in ForceSendFields will be
12746	// sent to the server regardless of whether the field is empty or not.
12747	// This may be used to include empty fields in Patch requests.
12748	ForceSendFields []string `json:"-"`
12749
12750	// NullFields is a list of field names (e.g. "Active") to include in API
12751	// requests with the JSON null value. By default, fields with empty
12752	// values are omitted from API requests. However, any field with an
12753	// empty value appearing in NullFields will be sent to the server as
12754	// null. It is an error if a field in this list has a non-empty value.
12755	// This may be used to include null fields in Patch requests.
12756	NullFields []string `json:"-"`
12757}
12758
12759func (s *ReportSchedule) MarshalJSON() ([]byte, error) {
12760	type NoMethod ReportSchedule
12761	raw := NoMethod(*s)
12762	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12763}
12764
12765// ReportCompatibleFields: Represents fields that are compatible to be
12766// selected for a report of type "STANDARD".
12767type ReportCompatibleFields struct {
12768	// DimensionFilters: Dimensions which are compatible to be selected in
12769	// the "dimensionFilters" section of the report.
12770	DimensionFilters []*Dimension `json:"dimensionFilters,omitempty"`
12771
12772	// Dimensions: Dimensions which are compatible to be selected in the
12773	// "dimensions" section of the report.
12774	Dimensions []*Dimension `json:"dimensions,omitempty"`
12775
12776	// Kind: The kind of resource this is, in this case
12777	// dfareporting#reportCompatibleFields.
12778	Kind string `json:"kind,omitempty"`
12779
12780	// Metrics: Metrics which are compatible to be selected in the
12781	// "metricNames" section of the report.
12782	Metrics []*Metric `json:"metrics,omitempty"`
12783
12784	// PivotedActivityMetrics: Metrics which are compatible to be selected
12785	// as activity metrics to pivot on in the "activities" section of the
12786	// report.
12787	PivotedActivityMetrics []*Metric `json:"pivotedActivityMetrics,omitempty"`
12788
12789	// ForceSendFields is a list of field names (e.g. "DimensionFilters") to
12790	// unconditionally include in API requests. By default, fields with
12791	// empty or default values are omitted from API requests. However, any
12792	// non-pointer, non-interface field appearing in ForceSendFields will be
12793	// sent to the server regardless of whether the field is empty or not.
12794	// This may be used to include empty fields in Patch requests.
12795	ForceSendFields []string `json:"-"`
12796
12797	// NullFields is a list of field names (e.g. "DimensionFilters") to
12798	// include in API requests with the JSON null value. By default, fields
12799	// with empty values are omitted from API requests. However, any field
12800	// with an empty value appearing in NullFields will be sent to the
12801	// server as null. It is an error if a field in this list has a
12802	// non-empty value. This may be used to include null fields in Patch
12803	// requests.
12804	NullFields []string `json:"-"`
12805}
12806
12807func (s *ReportCompatibleFields) MarshalJSON() ([]byte, error) {
12808	type NoMethod ReportCompatibleFields
12809	raw := NoMethod(*s)
12810	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12811}
12812
12813// ReportList: Represents the list of reports.
12814type ReportList struct {
12815	// Etag: The eTag of this response for caching purposes.
12816	Etag string `json:"etag,omitempty"`
12817
12818	// Items: The reports returned in this response.
12819	Items []*Report `json:"items,omitempty"`
12820
12821	// Kind: The kind of list this is, in this case dfareporting#reportList.
12822	Kind string `json:"kind,omitempty"`
12823
12824	// NextPageToken: Continuation token used to page through reports. To
12825	// retrieve the next page of results, set the next request's "pageToken"
12826	// to the value of this field. The page token is only valid for a
12827	// limited amount of time and should not be persisted.
12828	NextPageToken string `json:"nextPageToken,omitempty"`
12829
12830	// ServerResponse contains the HTTP response code and headers from the
12831	// server.
12832	googleapi.ServerResponse `json:"-"`
12833
12834	// ForceSendFields is a list of field names (e.g. "Etag") to
12835	// unconditionally include in API requests. By default, fields with
12836	// empty or default values are omitted from API requests. However, any
12837	// non-pointer, non-interface field appearing in ForceSendFields will be
12838	// sent to the server regardless of whether the field is empty or not.
12839	// This may be used to include empty fields in Patch requests.
12840	ForceSendFields []string `json:"-"`
12841
12842	// NullFields is a list of field names (e.g. "Etag") to include in API
12843	// requests with the JSON null value. By default, fields with empty
12844	// values are omitted from API requests. However, any field with an
12845	// empty value appearing in NullFields will be sent to the server as
12846	// null. It is an error if a field in this list has a non-empty value.
12847	// This may be used to include null fields in Patch requests.
12848	NullFields []string `json:"-"`
12849}
12850
12851func (s *ReportList) MarshalJSON() ([]byte, error) {
12852	type NoMethod ReportList
12853	raw := NoMethod(*s)
12854	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12855}
12856
12857// ReportsConfiguration: Reporting Configuration
12858type ReportsConfiguration struct {
12859	// ExposureToConversionEnabled: Whether the exposure to conversion
12860	// report is enabled. This report shows detailed pathway information on
12861	// up to 10 of the most recent ad exposures seen by a user before
12862	// converting.
12863	ExposureToConversionEnabled bool `json:"exposureToConversionEnabled,omitempty"`
12864
12865	// LookbackConfiguration: Default lookback windows for new advertisers
12866	// in this account.
12867	LookbackConfiguration *LookbackConfiguration `json:"lookbackConfiguration,omitempty"`
12868
12869	// ReportGenerationTimeZoneId: Report generation time zone ID of this
12870	// account. This is a required field that can only be changed by a
12871	// superuser. Acceptable values are: - "1" for "America/New_York" - "2"
12872	// for "Europe/London" - "3" for "Europe/Paris" - "4" for
12873	// "Africa/Johannesburg" - "5" for "Asia/Jerusalem" - "6" for
12874	// "Asia/Shanghai" - "7" for "Asia/Hong_Kong" - "8" for "Asia/Tokyo" -
12875	// "9" for "Australia/Sydney" - "10" for "Asia/Dubai" - "11" for
12876	// "America/Los_Angeles" - "12" for "Pacific/Auckland" - "13" for
12877	// "America/Sao_Paulo" - "16" for "America/Asuncion" - "17" for
12878	// "America/Chicago" - "18" for "America/Denver" - "19" for
12879	// "America/St_Johns" - "20" for "Asia/Dhaka" - "21" for "Asia/Jakarta"
12880	// - "22" for "Asia/Kabul" - "23" for "Asia/Karachi" - "24" for
12881	// "Asia/Calcutta" - "25" for "Asia/Pyongyang" - "26" for "Asia/Rangoon"
12882	// - "27" for "Atlantic/Cape_Verde" - "28" for "Atlantic/South_Georgia"
12883	// - "29" for "Australia/Adelaide" - "30" for "Australia/Lord_Howe" -
12884	// "31" for "Europe/Moscow" - "32" for "Pacific/Kiritimati" - "35" for
12885	// "Pacific/Norfolk" - "36" for "Pacific/Tongatapu"
12886	ReportGenerationTimeZoneId int64 `json:"reportGenerationTimeZoneId,omitempty,string"`
12887
12888	// ForceSendFields is a list of field names (e.g.
12889	// "ExposureToConversionEnabled") to unconditionally include in API
12890	// requests. By default, fields with empty or default values are omitted
12891	// from API requests. However, any non-pointer, non-interface field
12892	// appearing in ForceSendFields will be sent to the server regardless of
12893	// whether the field is empty or not. This may be used to include empty
12894	// fields in Patch requests.
12895	ForceSendFields []string `json:"-"`
12896
12897	// NullFields is a list of field names (e.g.
12898	// "ExposureToConversionEnabled") to include in API requests with the
12899	// JSON null value. By default, fields with empty values are omitted
12900	// from API requests. However, any field with an empty value appearing
12901	// in NullFields will be sent to the server as null. It is an error if a
12902	// field in this list has a non-empty value. This may be used to include
12903	// null fields in Patch requests.
12904	NullFields []string `json:"-"`
12905}
12906
12907func (s *ReportsConfiguration) MarshalJSON() ([]byte, error) {
12908	type NoMethod ReportsConfiguration
12909	raw := NoMethod(*s)
12910	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12911}
12912
12913// RichMediaExitOverride: Rich Media Exit Override.
12914type RichMediaExitOverride struct {
12915	// ClickThroughUrl: Click-through URL of this rich media exit override.
12916	// Applicable if the enabled field is set to true.
12917	ClickThroughUrl *ClickThroughUrl `json:"clickThroughUrl,omitempty"`
12918
12919	// Enabled: Whether to use the clickThroughUrl. If false, the
12920	// creative-level exit will be used.
12921	Enabled bool `json:"enabled,omitempty"`
12922
12923	// ExitId: ID for the override to refer to a specific exit in the
12924	// creative.
12925	ExitId int64 `json:"exitId,omitempty,string"`
12926
12927	// ForceSendFields is a list of field names (e.g. "ClickThroughUrl") to
12928	// unconditionally include in API requests. By default, fields with
12929	// empty or default values are omitted from API requests. However, any
12930	// non-pointer, non-interface field appearing in ForceSendFields will be
12931	// sent to the server regardless of whether the field is empty or not.
12932	// This may be used to include empty fields in Patch requests.
12933	ForceSendFields []string `json:"-"`
12934
12935	// NullFields is a list of field names (e.g. "ClickThroughUrl") to
12936	// include in API requests with the JSON null value. By default, fields
12937	// with empty values are omitted from API requests. However, any field
12938	// with an empty value appearing in NullFields will be sent to the
12939	// server as null. It is an error if a field in this list has a
12940	// non-empty value. This may be used to include null fields in Patch
12941	// requests.
12942	NullFields []string `json:"-"`
12943}
12944
12945func (s *RichMediaExitOverride) MarshalJSON() ([]byte, error) {
12946	type NoMethod RichMediaExitOverride
12947	raw := NoMethod(*s)
12948	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12949}
12950
12951// Rule: A rule associates an asset with a targeting template for
12952// asset-level targeting. Applicable to INSTREAM_VIDEO creatives.
12953type Rule struct {
12954	// AssetId: A creativeAssets[].id. This should refer to one of the
12955	// parent assets in this creative. This is a required field.
12956	AssetId int64 `json:"assetId,omitempty,string"`
12957
12958	// Name: A user-friendly name for this rule. This is a required field.
12959	Name string `json:"name,omitempty"`
12960
12961	// TargetingTemplateId: A targeting template ID. The targeting from the
12962	// targeting template will be used to determine whether this asset
12963	// should be served. This is a required field.
12964	TargetingTemplateId int64 `json:"targetingTemplateId,omitempty,string"`
12965
12966	// ForceSendFields is a list of field names (e.g. "AssetId") to
12967	// unconditionally include in API requests. By default, fields with
12968	// empty or default values are omitted from API requests. However, any
12969	// non-pointer, non-interface field appearing in ForceSendFields will be
12970	// sent to the server regardless of whether the field is empty or not.
12971	// This may be used to include empty fields in Patch requests.
12972	ForceSendFields []string `json:"-"`
12973
12974	// NullFields is a list of field names (e.g. "AssetId") to include in
12975	// API requests with the JSON null value. By default, fields with empty
12976	// values are omitted from API requests. However, any field with an
12977	// empty value appearing in NullFields will be sent to the server as
12978	// null. It is an error if a field in this list has a non-empty value.
12979	// This may be used to include null fields in Patch requests.
12980	NullFields []string `json:"-"`
12981}
12982
12983func (s *Rule) MarshalJSON() ([]byte, error) {
12984	type NoMethod Rule
12985	raw := NoMethod(*s)
12986	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12987}
12988
12989// Site: Contains properties of a site.
12990type Site struct {
12991	// AccountId: Account ID of this site. This is a read-only field that
12992	// can be left blank.
12993	AccountId int64 `json:"accountId,omitempty,string"`
12994
12995	// Approved: Whether this site is approved.
12996	Approved bool `json:"approved,omitempty"`
12997
12998	// DirectorySiteId: Directory site associated with this site. This is a
12999	// required field that is read-only after insertion.
13000	DirectorySiteId int64 `json:"directorySiteId,omitempty,string"`
13001
13002	// DirectorySiteIdDimensionValue: Dimension value for the ID of the
13003	// directory site. This is a read-only, auto-generated field.
13004	DirectorySiteIdDimensionValue *DimensionValue `json:"directorySiteIdDimensionValue,omitempty"`
13005
13006	// Id: ID of this site. This is a read-only, auto-generated field.
13007	Id int64 `json:"id,omitempty,string"`
13008
13009	// IdDimensionValue: Dimension value for the ID of this site. This is a
13010	// read-only, auto-generated field.
13011	IdDimensionValue *DimensionValue `json:"idDimensionValue,omitempty"`
13012
13013	// KeyName: Key name of this site. This is a read-only, auto-generated
13014	// field.
13015	KeyName string `json:"keyName,omitempty"`
13016
13017	// Kind: Identifies what kind of resource this is. Value: the fixed
13018	// string "dfareporting#site".
13019	Kind string `json:"kind,omitempty"`
13020
13021	// Name: Name of this site.This is a required field. Must be less than
13022	// 128 characters long. If this site is under a subaccount, the name
13023	// must be unique among sites of the same subaccount. Otherwise, this
13024	// site is a top-level site, and the name must be unique among top-level
13025	// sites of the same account.
13026	Name string `json:"name,omitempty"`
13027
13028	// SiteContacts: Site contacts.
13029	SiteContacts []*SiteContact `json:"siteContacts,omitempty"`
13030
13031	// SiteSettings: Site-wide settings.
13032	SiteSettings *SiteSettings `json:"siteSettings,omitempty"`
13033
13034	// SubaccountId: Subaccount ID of this site. This is a read-only field
13035	// that can be left blank.
13036	SubaccountId int64 `json:"subaccountId,omitempty,string"`
13037
13038	// VideoSettings: Default video settings for new placements created
13039	// under this site. This value will be used to populate the
13040	// placements.videoSettings field, when no value is specified for the
13041	// new placement.
13042	VideoSettings *SiteVideoSettings `json:"videoSettings,omitempty"`
13043
13044	// ServerResponse contains the HTTP response code and headers from the
13045	// server.
13046	googleapi.ServerResponse `json:"-"`
13047
13048	// ForceSendFields is a list of field names (e.g. "AccountId") to
13049	// unconditionally include in API requests. By default, fields with
13050	// empty or default values are omitted from API requests. However, any
13051	// non-pointer, non-interface field appearing in ForceSendFields will be
13052	// sent to the server regardless of whether the field is empty or not.
13053	// This may be used to include empty fields in Patch requests.
13054	ForceSendFields []string `json:"-"`
13055
13056	// NullFields is a list of field names (e.g. "AccountId") to include in
13057	// API requests with the JSON null value. By default, fields with empty
13058	// values are omitted from API requests. However, any field with an
13059	// empty value appearing in NullFields will be sent to the server as
13060	// null. It is an error if a field in this list has a non-empty value.
13061	// This may be used to include null fields in Patch requests.
13062	NullFields []string `json:"-"`
13063}
13064
13065func (s *Site) MarshalJSON() ([]byte, error) {
13066	type NoMethod Site
13067	raw := NoMethod(*s)
13068	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13069}
13070
13071// SiteCompanionSetting: Companion Settings
13072type SiteCompanionSetting struct {
13073	// CompanionsDisabled: Whether companions are disabled for this site
13074	// template.
13075	CompanionsDisabled bool `json:"companionsDisabled,omitempty"`
13076
13077	// EnabledSizes: Allowlist of companion sizes to be served via this site
13078	// template. Set this list to null or empty to serve all companion
13079	// sizes.
13080	EnabledSizes []*Size `json:"enabledSizes,omitempty"`
13081
13082	// ImageOnly: Whether to serve only static images as companions.
13083	ImageOnly bool `json:"imageOnly,omitempty"`
13084
13085	// Kind: Identifies what kind of resource this is. Value: the fixed
13086	// string "dfareporting#siteCompanionSetting".
13087	Kind string `json:"kind,omitempty"`
13088
13089	// ForceSendFields is a list of field names (e.g. "CompanionsDisabled")
13090	// to unconditionally include in API requests. By default, fields with
13091	// empty or default values are omitted from API requests. However, any
13092	// non-pointer, non-interface field appearing in ForceSendFields will be
13093	// sent to the server regardless of whether the field is empty or not.
13094	// This may be used to include empty fields in Patch requests.
13095	ForceSendFields []string `json:"-"`
13096
13097	// NullFields is a list of field names (e.g. "CompanionsDisabled") to
13098	// include in API requests with the JSON null value. By default, fields
13099	// with empty values are omitted from API requests. However, any field
13100	// with an empty value appearing in NullFields will be sent to the
13101	// server as null. It is an error if a field in this list has a
13102	// non-empty value. This may be used to include null fields in Patch
13103	// requests.
13104	NullFields []string `json:"-"`
13105}
13106
13107func (s *SiteCompanionSetting) MarshalJSON() ([]byte, error) {
13108	type NoMethod SiteCompanionSetting
13109	raw := NoMethod(*s)
13110	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13111}
13112
13113// SiteContact: Site Contact
13114type SiteContact struct {
13115	// Address: Address of this site contact.
13116	Address string `json:"address,omitempty"`
13117
13118	// ContactType: Site contact type.
13119	//
13120	// Possible values:
13121	//   "SALES_PERSON"
13122	//   "TRAFFICKER"
13123	ContactType string `json:"contactType,omitempty"`
13124
13125	// Email: Email address of this site contact. This is a required field.
13126	Email string `json:"email,omitempty"`
13127
13128	// FirstName: First name of this site contact.
13129	FirstName string `json:"firstName,omitempty"`
13130
13131	// Id: ID of this site contact. This is a read-only, auto-generated
13132	// field.
13133	Id int64 `json:"id,omitempty,string"`
13134
13135	// LastName: Last name of this site contact.
13136	LastName string `json:"lastName,omitempty"`
13137
13138	// Phone: Primary phone number of this site contact.
13139	Phone string `json:"phone,omitempty"`
13140
13141	// Title: Title or designation of this site contact.
13142	Title string `json:"title,omitempty"`
13143
13144	// ForceSendFields is a list of field names (e.g. "Address") to
13145	// unconditionally include in API requests. By default, fields with
13146	// empty or default values are omitted from API requests. However, any
13147	// non-pointer, non-interface field appearing in ForceSendFields will be
13148	// sent to the server regardless of whether the field is empty or not.
13149	// This may be used to include empty fields in Patch requests.
13150	ForceSendFields []string `json:"-"`
13151
13152	// NullFields is a list of field names (e.g. "Address") to include in
13153	// API requests with the JSON null value. By default, fields with empty
13154	// values are omitted from API requests. However, any field with an
13155	// empty value appearing in NullFields will be sent to the server as
13156	// null. It is an error if a field in this list has a non-empty value.
13157	// This may be used to include null fields in Patch requests.
13158	NullFields []string `json:"-"`
13159}
13160
13161func (s *SiteContact) MarshalJSON() ([]byte, error) {
13162	type NoMethod SiteContact
13163	raw := NoMethod(*s)
13164	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13165}
13166
13167// SiteSettings: Site Settings
13168type SiteSettings struct {
13169	// ActiveViewOptOut: Whether active view creatives are disabled for this
13170	// site.
13171	ActiveViewOptOut bool `json:"activeViewOptOut,omitempty"`
13172
13173	// AdBlockingOptOut: Whether this site opts out of ad blocking. When
13174	// true, ad blocking is disabled for all placements under the site,
13175	// regardless of the individual placement settings. When false, the
13176	// campaign and placement settings take effect.
13177	AdBlockingOptOut bool `json:"adBlockingOptOut,omitempty"`
13178
13179	// DisableNewCookie: Whether new cookies are disabled for this site.
13180	DisableNewCookie bool `json:"disableNewCookie,omitempty"`
13181
13182	// TagSetting: Configuration settings for dynamic and image floodlight
13183	// tags.
13184	TagSetting *TagSetting `json:"tagSetting,omitempty"`
13185
13186	// VideoActiveViewOptOutTemplate: Whether Verification and ActiveView
13187	// for in-stream video creatives are disabled by default for new
13188	// placements created under this site. This value will be used to
13189	// populate the placement.videoActiveViewOptOut field, when no value is
13190	// specified for the new placement.
13191	VideoActiveViewOptOutTemplate bool `json:"videoActiveViewOptOutTemplate,omitempty"`
13192
13193	// VpaidAdapterChoiceTemplate: Default VPAID adapter setting for new
13194	// placements created under this site. This value will be used to
13195	// populate the placements.vpaidAdapterChoice field, when no value is
13196	// specified for the new placement. Controls which VPAID format the
13197	// measurement adapter will use for in-stream video creatives assigned
13198	// to the placement. The publisher's specifications will typically
13199	// determine this setting. For VPAID creatives, the adapter format will
13200	// match the VPAID format (HTML5 VPAID creatives use the HTML5 adapter).
13201	// *Note:* Flash is no longer supported. This field now defaults to
13202	// HTML5 when the following values are provided: FLASH, BOTH.
13203	//
13204	// Possible values:
13205	//   "DEFAULT"
13206	//   "FLASH"
13207	//   "HTML5"
13208	//   "BOTH"
13209	VpaidAdapterChoiceTemplate string `json:"vpaidAdapterChoiceTemplate,omitempty"`
13210
13211	// ForceSendFields is a list of field names (e.g. "ActiveViewOptOut") to
13212	// unconditionally include in API requests. By default, fields with
13213	// empty or default values are omitted from API requests. However, any
13214	// non-pointer, non-interface field appearing in ForceSendFields will be
13215	// sent to the server regardless of whether the field is empty or not.
13216	// This may be used to include empty fields in Patch requests.
13217	ForceSendFields []string `json:"-"`
13218
13219	// NullFields is a list of field names (e.g. "ActiveViewOptOut") to
13220	// include in API requests with the JSON null value. By default, fields
13221	// with empty values are omitted from API requests. However, any field
13222	// with an empty value appearing in NullFields will be sent to the
13223	// server as null. It is an error if a field in this list has a
13224	// non-empty value. This may be used to include null fields in Patch
13225	// requests.
13226	NullFields []string `json:"-"`
13227}
13228
13229func (s *SiteSettings) MarshalJSON() ([]byte, error) {
13230	type NoMethod SiteSettings
13231	raw := NoMethod(*s)
13232	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13233}
13234
13235// SiteSkippableSetting: Skippable Settings
13236type SiteSkippableSetting struct {
13237	// Kind: Identifies what kind of resource this is. Value: the fixed
13238	// string "dfareporting#siteSkippableSetting".
13239	Kind string `json:"kind,omitempty"`
13240
13241	// ProgressOffset: Amount of time to play videos served to this site
13242	// template before counting a view. Applicable when skippable is true.
13243	ProgressOffset *VideoOffset `json:"progressOffset,omitempty"`
13244
13245	// SkipOffset: Amount of time to play videos served to this site before
13246	// the skip button should appear. Applicable when skippable is true.
13247	SkipOffset *VideoOffset `json:"skipOffset,omitempty"`
13248
13249	// Skippable: Whether the user can skip creatives served to this site.
13250	// This will act as default for new placements created under this site.
13251	Skippable bool `json:"skippable,omitempty"`
13252
13253	// ForceSendFields is a list of field names (e.g. "Kind") to
13254	// unconditionally include in API requests. By default, fields with
13255	// empty or default values are omitted from API requests. However, any
13256	// non-pointer, non-interface field appearing in ForceSendFields will be
13257	// sent to the server regardless of whether the field is empty or not.
13258	// This may be used to include empty fields in Patch requests.
13259	ForceSendFields []string `json:"-"`
13260
13261	// NullFields is a list of field names (e.g. "Kind") to include in API
13262	// requests with the JSON null value. By default, fields with empty
13263	// values are omitted from API requests. However, any field with an
13264	// empty value appearing in NullFields will be sent to the server as
13265	// null. It is an error if a field in this list has a non-empty value.
13266	// This may be used to include null fields in Patch requests.
13267	NullFields []string `json:"-"`
13268}
13269
13270func (s *SiteSkippableSetting) MarshalJSON() ([]byte, error) {
13271	type NoMethod SiteSkippableSetting
13272	raw := NoMethod(*s)
13273	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13274}
13275
13276// SiteTranscodeSetting: Transcode Settings
13277type SiteTranscodeSetting struct {
13278	// EnabledVideoFormats: Allowlist of video formats to be served to this
13279	// site template. Set this list to null or empty to serve all video
13280	// formats.
13281	EnabledVideoFormats []int64 `json:"enabledVideoFormats,omitempty"`
13282
13283	// Kind: Identifies what kind of resource this is. Value: the fixed
13284	// string "dfareporting#siteTranscodeSetting".
13285	Kind string `json:"kind,omitempty"`
13286
13287	// ForceSendFields is a list of field names (e.g. "EnabledVideoFormats")
13288	// to unconditionally include in API requests. By default, fields with
13289	// empty or default values are omitted from API requests. However, any
13290	// non-pointer, non-interface field appearing in ForceSendFields will be
13291	// sent to the server regardless of whether the field is empty or not.
13292	// This may be used to include empty fields in Patch requests.
13293	ForceSendFields []string `json:"-"`
13294
13295	// NullFields is a list of field names (e.g. "EnabledVideoFormats") to
13296	// include in API requests with the JSON null value. By default, fields
13297	// with empty values are omitted from API requests. However, any field
13298	// with an empty value appearing in NullFields will be sent to the
13299	// server as null. It is an error if a field in this list has a
13300	// non-empty value. This may be used to include null fields in Patch
13301	// requests.
13302	NullFields []string `json:"-"`
13303}
13304
13305func (s *SiteTranscodeSetting) MarshalJSON() ([]byte, error) {
13306	type NoMethod SiteTranscodeSetting
13307	raw := NoMethod(*s)
13308	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13309}
13310
13311// SiteVideoSettings: Video Settings
13312type SiteVideoSettings struct {
13313	// CompanionSettings: Settings for the companion creatives of video
13314	// creatives served to this site.
13315	CompanionSettings *SiteCompanionSetting `json:"companionSettings,omitempty"`
13316
13317	// Kind: Identifies what kind of resource this is. Value: the fixed
13318	// string "dfareporting#siteVideoSettings".
13319	Kind string `json:"kind,omitempty"`
13320
13321	// ObaEnabled: Whether OBA icons are enabled for this placement.
13322	ObaEnabled bool `json:"obaEnabled,omitempty"`
13323
13324	// ObaSettings: Settings for the OBA icon of video creatives served to
13325	// this site. This will act as default for new placements created under
13326	// this site.
13327	ObaSettings *ObaIcon `json:"obaSettings,omitempty"`
13328
13329	// Orientation: Orientation of a site template used for video. This will
13330	// act as default for new placements created under this site.
13331	//
13332	// Possible values:
13333	//   "ANY"
13334	//   "LANDSCAPE"
13335	//   "PORTRAIT"
13336	Orientation string `json:"orientation,omitempty"`
13337
13338	// SkippableSettings: Settings for the skippability of video creatives
13339	// served to this site. This will act as default for new placements
13340	// created under this site.
13341	SkippableSettings *SiteSkippableSetting `json:"skippableSettings,omitempty"`
13342
13343	// TranscodeSettings: Settings for the transcodes of video creatives
13344	// served to this site. This will act as default for new placements
13345	// created under this site.
13346	TranscodeSettings *SiteTranscodeSetting `json:"transcodeSettings,omitempty"`
13347
13348	// ForceSendFields is a list of field names (e.g. "CompanionSettings")
13349	// to unconditionally include in API requests. By default, fields with
13350	// empty or default values are omitted from API requests. However, any
13351	// non-pointer, non-interface field appearing in ForceSendFields will be
13352	// sent to the server regardless of whether the field is empty or not.
13353	// This may be used to include empty fields in Patch requests.
13354	ForceSendFields []string `json:"-"`
13355
13356	// NullFields is a list of field names (e.g. "CompanionSettings") to
13357	// include in API requests with the JSON null value. By default, fields
13358	// with empty values are omitted from API requests. However, any field
13359	// with an empty value appearing in NullFields will be sent to the
13360	// server as null. It is an error if a field in this list has a
13361	// non-empty value. This may be used to include null fields in Patch
13362	// requests.
13363	NullFields []string `json:"-"`
13364}
13365
13366func (s *SiteVideoSettings) MarshalJSON() ([]byte, error) {
13367	type NoMethod SiteVideoSettings
13368	raw := NoMethod(*s)
13369	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13370}
13371
13372// SitesListResponse: Site List Response
13373type SitesListResponse struct {
13374	// Kind: Identifies what kind of resource this is. Value: the fixed
13375	// string "dfareporting#sitesListResponse".
13376	Kind string `json:"kind,omitempty"`
13377
13378	// NextPageToken: Pagination token to be used for the next list
13379	// operation.
13380	NextPageToken string `json:"nextPageToken,omitempty"`
13381
13382	// Sites: Site collection.
13383	Sites []*Site `json:"sites,omitempty"`
13384
13385	// ServerResponse contains the HTTP response code and headers from the
13386	// server.
13387	googleapi.ServerResponse `json:"-"`
13388
13389	// ForceSendFields is a list of field names (e.g. "Kind") to
13390	// unconditionally include in API requests. By default, fields with
13391	// empty or default values are omitted from API requests. However, any
13392	// non-pointer, non-interface field appearing in ForceSendFields will be
13393	// sent to the server regardless of whether the field is empty or not.
13394	// This may be used to include empty fields in Patch requests.
13395	ForceSendFields []string `json:"-"`
13396
13397	// NullFields is a list of field names (e.g. "Kind") to include in API
13398	// requests with the JSON null value. By default, fields with empty
13399	// values are omitted from API requests. However, any field with an
13400	// empty value appearing in NullFields will be sent to the server as
13401	// null. It is an error if a field in this list has a non-empty value.
13402	// This may be used to include null fields in Patch requests.
13403	NullFields []string `json:"-"`
13404}
13405
13406func (s *SitesListResponse) MarshalJSON() ([]byte, error) {
13407	type NoMethod SitesListResponse
13408	raw := NoMethod(*s)
13409	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13410}
13411
13412// Size: Represents the dimensions of ads, placements, creatives, or
13413// creative assets.
13414type Size struct {
13415	// Height: Height of this size. Acceptable values are 0 to 32767,
13416	// inclusive.
13417	Height int64 `json:"height,omitempty"`
13418
13419	// Iab: IAB standard size. This is a read-only, auto-generated field.
13420	Iab bool `json:"iab,omitempty"`
13421
13422	// Id: ID of this size. This is a read-only, auto-generated field.
13423	Id int64 `json:"id,omitempty,string"`
13424
13425	// Kind: Identifies what kind of resource this is. Value: the fixed
13426	// string "dfareporting#size".
13427	Kind string `json:"kind,omitempty"`
13428
13429	// Width: Width of this size. Acceptable values are 0 to 32767,
13430	// inclusive.
13431	Width int64 `json:"width,omitempty"`
13432
13433	// ServerResponse contains the HTTP response code and headers from the
13434	// server.
13435	googleapi.ServerResponse `json:"-"`
13436
13437	// ForceSendFields is a list of field names (e.g. "Height") to
13438	// unconditionally include in API requests. By default, fields with
13439	// empty or default values are omitted from API requests. However, any
13440	// non-pointer, non-interface field appearing in ForceSendFields will be
13441	// sent to the server regardless of whether the field is empty or not.
13442	// This may be used to include empty fields in Patch requests.
13443	ForceSendFields []string `json:"-"`
13444
13445	// NullFields is a list of field names (e.g. "Height") to include in API
13446	// requests with the JSON null value. By default, fields with empty
13447	// values are omitted from API requests. However, any field with an
13448	// empty value appearing in NullFields will be sent to the server as
13449	// null. It is an error if a field in this list has a non-empty value.
13450	// This may be used to include null fields in Patch requests.
13451	NullFields []string `json:"-"`
13452}
13453
13454func (s *Size) MarshalJSON() ([]byte, error) {
13455	type NoMethod Size
13456	raw := NoMethod(*s)
13457	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13458}
13459
13460// SizesListResponse: Size List Response
13461type SizesListResponse struct {
13462	// Kind: Identifies what kind of resource this is. Value: the fixed
13463	// string "dfareporting#sizesListResponse".
13464	Kind string `json:"kind,omitempty"`
13465
13466	// Sizes: Size collection.
13467	Sizes []*Size `json:"sizes,omitempty"`
13468
13469	// ServerResponse contains the HTTP response code and headers from the
13470	// server.
13471	googleapi.ServerResponse `json:"-"`
13472
13473	// ForceSendFields is a list of field names (e.g. "Kind") to
13474	// unconditionally include in API requests. By default, fields with
13475	// empty or default values are omitted from API requests. However, any
13476	// non-pointer, non-interface field appearing in ForceSendFields will be
13477	// sent to the server regardless of whether the field is empty or not.
13478	// This may be used to include empty fields in Patch requests.
13479	ForceSendFields []string `json:"-"`
13480
13481	// NullFields is a list of field names (e.g. "Kind") to include in API
13482	// requests with the JSON null value. By default, fields with empty
13483	// values are omitted from API requests. However, any field with an
13484	// empty value appearing in NullFields will be sent to the server as
13485	// null. It is an error if a field in this list has a non-empty value.
13486	// This may be used to include null fields in Patch requests.
13487	NullFields []string `json:"-"`
13488}
13489
13490func (s *SizesListResponse) MarshalJSON() ([]byte, error) {
13491	type NoMethod SizesListResponse
13492	raw := NoMethod(*s)
13493	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13494}
13495
13496// SkippableSetting: Skippable Settings
13497type SkippableSetting struct {
13498	// Kind: Identifies what kind of resource this is. Value: the fixed
13499	// string "dfareporting#skippableSetting".
13500	Kind string `json:"kind,omitempty"`
13501
13502	// ProgressOffset: Amount of time to play videos served to this
13503	// placement before counting a view. Applicable when skippable is true.
13504	ProgressOffset *VideoOffset `json:"progressOffset,omitempty"`
13505
13506	// SkipOffset: Amount of time to play videos served to this placement
13507	// before the skip button should appear. Applicable when skippable is
13508	// true.
13509	SkipOffset *VideoOffset `json:"skipOffset,omitempty"`
13510
13511	// Skippable: Whether the user can skip creatives served to this
13512	// placement.
13513	Skippable bool `json:"skippable,omitempty"`
13514
13515	// ForceSendFields is a list of field names (e.g. "Kind") to
13516	// unconditionally include in API requests. By default, fields with
13517	// empty or default values are omitted from API requests. However, any
13518	// non-pointer, non-interface field appearing in ForceSendFields will be
13519	// sent to the server regardless of whether the field is empty or not.
13520	// This may be used to include empty fields in Patch requests.
13521	ForceSendFields []string `json:"-"`
13522
13523	// NullFields is a list of field names (e.g. "Kind") to include in API
13524	// requests with the JSON null value. By default, fields with empty
13525	// values are omitted from API requests. However, any field with an
13526	// empty value appearing in NullFields will be sent to the server as
13527	// null. It is an error if a field in this list has a non-empty value.
13528	// This may be used to include null fields in Patch requests.
13529	NullFields []string `json:"-"`
13530}
13531
13532func (s *SkippableSetting) MarshalJSON() ([]byte, error) {
13533	type NoMethod SkippableSetting
13534	raw := NoMethod(*s)
13535	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13536}
13537
13538// SortedDimension: Represents a sorted dimension.
13539type SortedDimension struct {
13540	// Kind: The kind of resource this is, in this case
13541	// dfareporting#sortedDimension.
13542	Kind string `json:"kind,omitempty"`
13543
13544	// Name: The name of the dimension.
13545	Name string `json:"name,omitempty"`
13546
13547	// SortOrder: An optional sort order for the dimension column.
13548	//
13549	// Possible values:
13550	//   "ASCENDING"
13551	//   "DESCENDING"
13552	SortOrder string `json:"sortOrder,omitempty"`
13553
13554	// ForceSendFields is a list of field names (e.g. "Kind") to
13555	// unconditionally include in API requests. By default, fields with
13556	// empty or default values are omitted from API requests. However, any
13557	// non-pointer, non-interface field appearing in ForceSendFields will be
13558	// sent to the server regardless of whether the field is empty or not.
13559	// This may be used to include empty fields in Patch requests.
13560	ForceSendFields []string `json:"-"`
13561
13562	// NullFields is a list of field names (e.g. "Kind") to include in API
13563	// requests with the JSON null value. By default, fields with empty
13564	// values are omitted from API requests. However, any field with an
13565	// empty value appearing in NullFields will be sent to the server as
13566	// null. It is an error if a field in this list has a non-empty value.
13567	// This may be used to include null fields in Patch requests.
13568	NullFields []string `json:"-"`
13569}
13570
13571func (s *SortedDimension) MarshalJSON() ([]byte, error) {
13572	type NoMethod SortedDimension
13573	raw := NoMethod(*s)
13574	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13575}
13576
13577// Subaccount: Contains properties of a Campaign Manager subaccount.
13578type Subaccount struct {
13579	// AccountId: ID of the account that contains this subaccount. This is a
13580	// read-only field that can be left blank.
13581	AccountId int64 `json:"accountId,omitempty,string"`
13582
13583	// AvailablePermissionIds: IDs of the available user role permissions
13584	// for this subaccount.
13585	AvailablePermissionIds googleapi.Int64s `json:"availablePermissionIds,omitempty"`
13586
13587	// Id: ID of this subaccount. This is a read-only, auto-generated field.
13588	Id int64 `json:"id,omitempty,string"`
13589
13590	// Kind: Identifies what kind of resource this is. Value: the fixed
13591	// string "dfareporting#subaccount".
13592	Kind string `json:"kind,omitempty"`
13593
13594	// Name: Name of this subaccount. This is a required field. Must be less
13595	// than 128 characters long and be unique among subaccounts of the same
13596	// account.
13597	Name string `json:"name,omitempty"`
13598
13599	// ServerResponse contains the HTTP response code and headers from the
13600	// server.
13601	googleapi.ServerResponse `json:"-"`
13602
13603	// ForceSendFields is a list of field names (e.g. "AccountId") to
13604	// unconditionally include in API requests. By default, fields with
13605	// empty or default values are omitted from API requests. However, any
13606	// non-pointer, non-interface field appearing in ForceSendFields will be
13607	// sent to the server regardless of whether the field is empty or not.
13608	// This may be used to include empty fields in Patch requests.
13609	ForceSendFields []string `json:"-"`
13610
13611	// NullFields is a list of field names (e.g. "AccountId") to include in
13612	// API requests with the JSON null value. By default, fields with empty
13613	// values are omitted from API requests. However, any field with an
13614	// empty value appearing in NullFields will be sent to the server as
13615	// null. It is an error if a field in this list has a non-empty value.
13616	// This may be used to include null fields in Patch requests.
13617	NullFields []string `json:"-"`
13618}
13619
13620func (s *Subaccount) MarshalJSON() ([]byte, error) {
13621	type NoMethod Subaccount
13622	raw := NoMethod(*s)
13623	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13624}
13625
13626// SubaccountsListResponse: Subaccount List Response
13627type SubaccountsListResponse struct {
13628	// Kind: Identifies what kind of resource this is. Value: the fixed
13629	// string "dfareporting#subaccountsListResponse".
13630	Kind string `json:"kind,omitempty"`
13631
13632	// NextPageToken: Pagination token to be used for the next list
13633	// operation.
13634	NextPageToken string `json:"nextPageToken,omitempty"`
13635
13636	// Subaccounts: Subaccount collection.
13637	Subaccounts []*Subaccount `json:"subaccounts,omitempty"`
13638
13639	// ServerResponse contains the HTTP response code and headers from the
13640	// server.
13641	googleapi.ServerResponse `json:"-"`
13642
13643	// ForceSendFields is a list of field names (e.g. "Kind") to
13644	// unconditionally include in API requests. By default, fields with
13645	// empty or default values are omitted from API requests. However, any
13646	// non-pointer, non-interface field appearing in ForceSendFields will be
13647	// sent to the server regardless of whether the field is empty or not.
13648	// This may be used to include empty fields in Patch requests.
13649	ForceSendFields []string `json:"-"`
13650
13651	// NullFields is a list of field names (e.g. "Kind") to include in API
13652	// requests with the JSON null value. By default, fields with empty
13653	// values are omitted from API requests. However, any field with an
13654	// empty value appearing in NullFields will be sent to the server as
13655	// null. It is an error if a field in this list has a non-empty value.
13656	// This may be used to include null fields in Patch requests.
13657	NullFields []string `json:"-"`
13658}
13659
13660func (s *SubaccountsListResponse) MarshalJSON() ([]byte, error) {
13661	type NoMethod SubaccountsListResponse
13662	raw := NoMethod(*s)
13663	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13664}
13665
13666// TagData: Placement Tag Data
13667type TagData struct {
13668	// AdId: Ad associated with this placement tag. Applicable only when
13669	// format is PLACEMENT_TAG_TRACKING.
13670	AdId int64 `json:"adId,omitempty,string"`
13671
13672	// ClickTag: Tag string to record a click.
13673	ClickTag string `json:"clickTag,omitempty"`
13674
13675	// CreativeId: Creative associated with this placement tag. Applicable
13676	// only when format is PLACEMENT_TAG_TRACKING.
13677	CreativeId int64 `json:"creativeId,omitempty,string"`
13678
13679	// Format: TagData tag format of this tag.
13680	//
13681	// Possible values:
13682	//   "PLACEMENT_TAG_STANDARD"
13683	//   "PLACEMENT_TAG_IFRAME_JAVASCRIPT"
13684	//   "PLACEMENT_TAG_IFRAME_ILAYER"
13685	//   "PLACEMENT_TAG_INTERNAL_REDIRECT"
13686	//   "PLACEMENT_TAG_JAVASCRIPT"
13687	//   "PLACEMENT_TAG_INTERSTITIAL_IFRAME_JAVASCRIPT"
13688	//   "PLACEMENT_TAG_INTERSTITIAL_INTERNAL_REDIRECT"
13689	//   "PLACEMENT_TAG_INTERSTITIAL_JAVASCRIPT"
13690	//   "PLACEMENT_TAG_CLICK_COMMANDS"
13691	//   "PLACEMENT_TAG_INSTREAM_VIDEO_PREFETCH"
13692	//   "PLACEMENT_TAG_TRACKING"
13693	//   "PLACEMENT_TAG_TRACKING_IFRAME"
13694	//   "PLACEMENT_TAG_TRACKING_JAVASCRIPT"
13695	//   "PLACEMENT_TAG_INSTREAM_VIDEO_PREFETCH_VAST_3"
13696	//   "PLACEMENT_TAG_IFRAME_JAVASCRIPT_LEGACY"
13697	//   "PLACEMENT_TAG_JAVASCRIPT_LEGACY"
13698	//   "PLACEMENT_TAG_INTERSTITIAL_IFRAME_JAVASCRIPT_LEGACY"
13699	//   "PLACEMENT_TAG_INTERSTITIAL_JAVASCRIPT_LEGACY"
13700	//   "PLACEMENT_TAG_INSTREAM_VIDEO_PREFETCH_VAST_4"
13701	Format string `json:"format,omitempty"`
13702
13703	// ImpressionTag: Tag string for serving an ad.
13704	ImpressionTag string `json:"impressionTag,omitempty"`
13705
13706	// ForceSendFields is a list of field names (e.g. "AdId") to
13707	// unconditionally include in API requests. By default, fields with
13708	// empty or default values are omitted from API requests. However, any
13709	// non-pointer, non-interface field appearing in ForceSendFields will be
13710	// sent to the server regardless of whether the field is empty or not.
13711	// This may be used to include empty fields in Patch requests.
13712	ForceSendFields []string `json:"-"`
13713
13714	// NullFields is a list of field names (e.g. "AdId") to include in API
13715	// requests with the JSON null value. By default, fields with empty
13716	// values are omitted from API requests. However, any field with an
13717	// empty value appearing in NullFields will be sent to the server as
13718	// null. It is an error if a field in this list has a non-empty value.
13719	// This may be used to include null fields in Patch requests.
13720	NullFields []string `json:"-"`
13721}
13722
13723func (s *TagData) MarshalJSON() ([]byte, error) {
13724	type NoMethod TagData
13725	raw := NoMethod(*s)
13726	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13727}
13728
13729// TagSetting: Tag Settings
13730type TagSetting struct {
13731	// AdditionalKeyValues: Additional key-values to be included in tags.
13732	// Each key-value pair must be of the form key=value, and pairs must be
13733	// separated by a semicolon (;). Keys and values must not contain
13734	// commas. For example, id=2;color=red is a valid value for this field.
13735	AdditionalKeyValues string `json:"additionalKeyValues,omitempty"`
13736
13737	// IncludeClickThroughUrls: Whether static landing page URLs should be
13738	// included in the tags. This setting applies only to placements.
13739	IncludeClickThroughUrls bool `json:"includeClickThroughUrls,omitempty"`
13740
13741	// IncludeClickTracking: Whether click-tracking string should be
13742	// included in the tags.
13743	IncludeClickTracking bool `json:"includeClickTracking,omitempty"`
13744
13745	// KeywordOption: Option specifying how keywords are embedded in ad
13746	// tags. This setting can be used to specify whether keyword
13747	// placeholders are inserted in placement tags for this site. Publishers
13748	// can then add keywords to those placeholders.
13749	//
13750	// Possible values:
13751	//   "PLACEHOLDER_WITH_LIST_OF_KEYWORDS"
13752	//   "IGNORE"
13753	//   "GENERATE_SEPARATE_TAG_FOR_EACH_KEYWORD"
13754	KeywordOption string `json:"keywordOption,omitempty"`
13755
13756	// ForceSendFields is a list of field names (e.g. "AdditionalKeyValues")
13757	// to unconditionally include in API requests. By default, fields with
13758	// empty or default values are omitted from API requests. However, any
13759	// non-pointer, non-interface field appearing in ForceSendFields will be
13760	// sent to the server regardless of whether the field is empty or not.
13761	// This may be used to include empty fields in Patch requests.
13762	ForceSendFields []string `json:"-"`
13763
13764	// NullFields is a list of field names (e.g. "AdditionalKeyValues") to
13765	// include in API requests with the JSON null value. By default, fields
13766	// with empty values are omitted from API requests. However, any field
13767	// with an empty value appearing in NullFields will be sent to the
13768	// server as null. It is an error if a field in this list has a
13769	// non-empty value. This may be used to include null fields in Patch
13770	// requests.
13771	NullFields []string `json:"-"`
13772}
13773
13774func (s *TagSetting) MarshalJSON() ([]byte, error) {
13775	type NoMethod TagSetting
13776	raw := NoMethod(*s)
13777	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13778}
13779
13780// TagSettings: Dynamic and Image Tag Settings.
13781type TagSettings struct {
13782	// DynamicTagEnabled: Whether dynamic floodlight tags are enabled.
13783	DynamicTagEnabled bool `json:"dynamicTagEnabled,omitempty"`
13784
13785	// ImageTagEnabled: Whether image tags are enabled.
13786	ImageTagEnabled bool `json:"imageTagEnabled,omitempty"`
13787
13788	// ForceSendFields is a list of field names (e.g. "DynamicTagEnabled")
13789	// to unconditionally include in API requests. By default, fields with
13790	// empty or default values are omitted from API requests. However, any
13791	// non-pointer, non-interface field appearing in ForceSendFields will be
13792	// sent to the server regardless of whether the field is empty or not.
13793	// This may be used to include empty fields in Patch requests.
13794	ForceSendFields []string `json:"-"`
13795
13796	// NullFields is a list of field names (e.g. "DynamicTagEnabled") to
13797	// include in API requests with the JSON null value. By default, fields
13798	// with empty values are omitted from API requests. However, any field
13799	// with an empty value appearing in NullFields will be sent to the
13800	// server as null. It is an error if a field in this list has a
13801	// non-empty value. This may be used to include null fields in Patch
13802	// requests.
13803	NullFields []string `json:"-"`
13804}
13805
13806func (s *TagSettings) MarshalJSON() ([]byte, error) {
13807	type NoMethod TagSettings
13808	raw := NoMethod(*s)
13809	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13810}
13811
13812// TargetWindow: Target Window.
13813type TargetWindow struct {
13814	// CustomHtml: User-entered value.
13815	CustomHtml string `json:"customHtml,omitempty"`
13816
13817	// TargetWindowOption: Type of browser window for which the backup image
13818	// of the flash creative can be displayed.
13819	//
13820	// Possible values:
13821	//   "NEW_WINDOW"
13822	//   "CURRENT_WINDOW"
13823	//   "CUSTOM"
13824	TargetWindowOption string `json:"targetWindowOption,omitempty"`
13825
13826	// ForceSendFields is a list of field names (e.g. "CustomHtml") to
13827	// unconditionally include in API requests. By default, fields with
13828	// empty or default values are omitted from API requests. However, any
13829	// non-pointer, non-interface field appearing in ForceSendFields will be
13830	// sent to the server regardless of whether the field is empty or not.
13831	// This may be used to include empty fields in Patch requests.
13832	ForceSendFields []string `json:"-"`
13833
13834	// NullFields is a list of field names (e.g. "CustomHtml") to include in
13835	// API requests with the JSON null value. By default, fields with empty
13836	// values are omitted from API requests. However, any field with an
13837	// empty value appearing in NullFields will be sent to the server as
13838	// null. It is an error if a field in this list has a non-empty value.
13839	// This may be used to include null fields in Patch requests.
13840	NullFields []string `json:"-"`
13841}
13842
13843func (s *TargetWindow) MarshalJSON() ([]byte, error) {
13844	type NoMethod TargetWindow
13845	raw := NoMethod(*s)
13846	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13847}
13848
13849// TargetableRemarketingList: Contains properties of a targetable
13850// remarketing list. Remarketing enables you to create lists of users
13851// who have performed specific actions on a site, then target ads to
13852// members of those lists. This resource is a read-only view of a
13853// remarketing list to be used to faciliate targeting ads to specific
13854// lists. Remarketing lists that are owned by your advertisers and those
13855// that are shared to your advertisers or account are accessible via
13856// this resource. To manage remarketing lists that are owned by your
13857// advertisers, use the RemarketingLists resource.
13858type TargetableRemarketingList struct {
13859	// AccountId: Account ID of this remarketing list. This is a read-only,
13860	// auto-generated field that is only returned in GET requests.
13861	AccountId int64 `json:"accountId,omitempty,string"`
13862
13863	// Active: Whether this targetable remarketing list is active.
13864	Active bool `json:"active,omitempty"`
13865
13866	// AdvertiserId: Dimension value for the advertiser ID that owns this
13867	// targetable remarketing list.
13868	AdvertiserId int64 `json:"advertiserId,omitempty,string"`
13869
13870	// AdvertiserIdDimensionValue: Dimension value for the ID of the
13871	// advertiser.
13872	AdvertiserIdDimensionValue *DimensionValue `json:"advertiserIdDimensionValue,omitempty"`
13873
13874	// Description: Targetable remarketing list description.
13875	Description string `json:"description,omitempty"`
13876
13877	// Id: Targetable remarketing list ID.
13878	Id int64 `json:"id,omitempty,string"`
13879
13880	// Kind: Identifies what kind of resource this is. Value: the fixed
13881	// string "dfareporting#targetableRemarketingList".
13882	Kind string `json:"kind,omitempty"`
13883
13884	// LifeSpan: Number of days that a user should remain in the targetable
13885	// remarketing list without an impression.
13886	LifeSpan int64 `json:"lifeSpan,omitempty,string"`
13887
13888	// ListSize: Number of users currently in the list. This is a read-only
13889	// field.
13890	ListSize int64 `json:"listSize,omitempty,string"`
13891
13892	// ListSource: Product from which this targetable remarketing list was
13893	// originated.
13894	//
13895	// Possible values:
13896	//   "REMARKETING_LIST_SOURCE_OTHER"
13897	//   "REMARKETING_LIST_SOURCE_ADX"
13898	//   "REMARKETING_LIST_SOURCE_DFP"
13899	//   "REMARKETING_LIST_SOURCE_XFP"
13900	//   "REMARKETING_LIST_SOURCE_DFA"
13901	//   "REMARKETING_LIST_SOURCE_GA"
13902	//   "REMARKETING_LIST_SOURCE_YOUTUBE"
13903	//   "REMARKETING_LIST_SOURCE_DBM"
13904	//   "REMARKETING_LIST_SOURCE_GPLUS"
13905	//   "REMARKETING_LIST_SOURCE_DMP"
13906	//   "REMARKETING_LIST_SOURCE_PLAY_STORE"
13907	ListSource string `json:"listSource,omitempty"`
13908
13909	// Name: Name of the targetable remarketing list. Is no greater than 128
13910	// characters long.
13911	Name string `json:"name,omitempty"`
13912
13913	// SubaccountId: Subaccount ID of this remarketing list. This is a
13914	// read-only, auto-generated field that is only returned in GET
13915	// requests.
13916	SubaccountId int64 `json:"subaccountId,omitempty,string"`
13917
13918	// ServerResponse contains the HTTP response code and headers from the
13919	// server.
13920	googleapi.ServerResponse `json:"-"`
13921
13922	// ForceSendFields is a list of field names (e.g. "AccountId") to
13923	// unconditionally include in API requests. By default, fields with
13924	// empty or default values are omitted from API requests. However, any
13925	// non-pointer, non-interface field appearing in ForceSendFields will be
13926	// sent to the server regardless of whether the field is empty or not.
13927	// This may be used to include empty fields in Patch requests.
13928	ForceSendFields []string `json:"-"`
13929
13930	// NullFields is a list of field names (e.g. "AccountId") to include in
13931	// API requests with the JSON null value. By default, fields with empty
13932	// values are omitted from API requests. However, any field with an
13933	// empty value appearing in NullFields will be sent to the server as
13934	// null. It is an error if a field in this list has a non-empty value.
13935	// This may be used to include null fields in Patch requests.
13936	NullFields []string `json:"-"`
13937}
13938
13939func (s *TargetableRemarketingList) MarshalJSON() ([]byte, error) {
13940	type NoMethod TargetableRemarketingList
13941	raw := NoMethod(*s)
13942	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13943}
13944
13945// TargetableRemarketingListsListResponse: Targetable remarketing list
13946// response
13947type TargetableRemarketingListsListResponse struct {
13948	// Kind: Identifies what kind of resource this is. Value: the fixed
13949	// string "dfareporting#targetableRemarketingListsListResponse".
13950	Kind string `json:"kind,omitempty"`
13951
13952	// NextPageToken: Pagination token to be used for the next list
13953	// operation.
13954	NextPageToken string `json:"nextPageToken,omitempty"`
13955
13956	// TargetableRemarketingLists: Targetable remarketing list collection.
13957	TargetableRemarketingLists []*TargetableRemarketingList `json:"targetableRemarketingLists,omitempty"`
13958
13959	// ServerResponse contains the HTTP response code and headers from the
13960	// server.
13961	googleapi.ServerResponse `json:"-"`
13962
13963	// ForceSendFields is a list of field names (e.g. "Kind") to
13964	// unconditionally include in API requests. By default, fields with
13965	// empty or default values are omitted from API requests. However, any
13966	// non-pointer, non-interface field appearing in ForceSendFields will be
13967	// sent to the server regardless of whether the field is empty or not.
13968	// This may be used to include empty fields in Patch requests.
13969	ForceSendFields []string `json:"-"`
13970
13971	// NullFields is a list of field names (e.g. "Kind") to include in API
13972	// requests with the JSON null value. By default, fields with empty
13973	// values are omitted from API requests. However, any field with an
13974	// empty value appearing in NullFields will be sent to the server as
13975	// null. It is an error if a field in this list has a non-empty value.
13976	// This may be used to include null fields in Patch requests.
13977	NullFields []string `json:"-"`
13978}
13979
13980func (s *TargetableRemarketingListsListResponse) MarshalJSON() ([]byte, error) {
13981	type NoMethod TargetableRemarketingListsListResponse
13982	raw := NoMethod(*s)
13983	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13984}
13985
13986// TargetingTemplate: Contains properties of a targeting template. A
13987// targeting template encapsulates targeting information which can be
13988// reused across multiple ads.
13989type TargetingTemplate struct {
13990	// AccountId: Account ID of this targeting template. This field, if left
13991	// unset, will be auto-generated on insert and is read-only after
13992	// insert.
13993	AccountId int64 `json:"accountId,omitempty,string"`
13994
13995	// AdvertiserId: Advertiser ID of this targeting template. This is a
13996	// required field on insert and is read-only after insert.
13997	AdvertiserId int64 `json:"advertiserId,omitempty,string"`
13998
13999	// AdvertiserIdDimensionValue: Dimension value for the ID of the
14000	// advertiser. This is a read-only, auto-generated field.
14001	AdvertiserIdDimensionValue *DimensionValue `json:"advertiserIdDimensionValue,omitempty"`
14002
14003	// DayPartTargeting: Time and day targeting criteria.
14004	DayPartTargeting *DayPartTargeting `json:"dayPartTargeting,omitempty"`
14005
14006	// GeoTargeting: Geographical targeting criteria.
14007	GeoTargeting *GeoTargeting `json:"geoTargeting,omitempty"`
14008
14009	// Id: ID of this targeting template. This is a read-only,
14010	// auto-generated field.
14011	Id int64 `json:"id,omitempty,string"`
14012
14013	// KeyValueTargetingExpression: Key-value targeting criteria.
14014	KeyValueTargetingExpression *KeyValueTargetingExpression `json:"keyValueTargetingExpression,omitempty"`
14015
14016	// Kind: Identifies what kind of resource this is. Value: the fixed
14017	// string "dfareporting#targetingTemplate".
14018	Kind string `json:"kind,omitempty"`
14019
14020	// LanguageTargeting: Language targeting criteria.
14021	LanguageTargeting *LanguageTargeting `json:"languageTargeting,omitempty"`
14022
14023	// ListTargetingExpression: Remarketing list targeting criteria.
14024	ListTargetingExpression *ListTargetingExpression `json:"listTargetingExpression,omitempty"`
14025
14026	// Name: Name of this targeting template. This field is required. It
14027	// must be less than 256 characters long and unique within an
14028	// advertiser.
14029	Name string `json:"name,omitempty"`
14030
14031	// SubaccountId: Subaccount ID of this targeting template. This field,
14032	// if left unset, will be auto-generated on insert and is read-only
14033	// after insert.
14034	SubaccountId int64 `json:"subaccountId,omitempty,string"`
14035
14036	// TechnologyTargeting: Technology platform targeting criteria.
14037	TechnologyTargeting *TechnologyTargeting `json:"technologyTargeting,omitempty"`
14038
14039	// ServerResponse contains the HTTP response code and headers from the
14040	// server.
14041	googleapi.ServerResponse `json:"-"`
14042
14043	// ForceSendFields is a list of field names (e.g. "AccountId") to
14044	// unconditionally include in API requests. By default, fields with
14045	// empty or default values are omitted from API requests. However, any
14046	// non-pointer, non-interface field appearing in ForceSendFields will be
14047	// sent to the server regardless of whether the field is empty or not.
14048	// This may be used to include empty fields in Patch requests.
14049	ForceSendFields []string `json:"-"`
14050
14051	// NullFields is a list of field names (e.g. "AccountId") to include in
14052	// API requests with the JSON null value. By default, fields with empty
14053	// values are omitted from API requests. However, any field with an
14054	// empty value appearing in NullFields will be sent to the server as
14055	// null. It is an error if a field in this list has a non-empty value.
14056	// This may be used to include null fields in Patch requests.
14057	NullFields []string `json:"-"`
14058}
14059
14060func (s *TargetingTemplate) MarshalJSON() ([]byte, error) {
14061	type NoMethod TargetingTemplate
14062	raw := NoMethod(*s)
14063	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14064}
14065
14066// TargetingTemplatesListResponse: Targeting Template List Response
14067type TargetingTemplatesListResponse struct {
14068	// Kind: Identifies what kind of resource this is. Value: the fixed
14069	// string "dfareporting#targetingTemplatesListResponse".
14070	Kind string `json:"kind,omitempty"`
14071
14072	// NextPageToken: Pagination token to be used for the next list
14073	// operation.
14074	NextPageToken string `json:"nextPageToken,omitempty"`
14075
14076	// TargetingTemplates: Targeting template collection.
14077	TargetingTemplates []*TargetingTemplate `json:"targetingTemplates,omitempty"`
14078
14079	// ServerResponse contains the HTTP response code and headers from the
14080	// server.
14081	googleapi.ServerResponse `json:"-"`
14082
14083	// ForceSendFields is a list of field names (e.g. "Kind") to
14084	// unconditionally include in API requests. By default, fields with
14085	// empty or default values are omitted from API requests. However, any
14086	// non-pointer, non-interface field appearing in ForceSendFields will be
14087	// sent to the server regardless of whether the field is empty or not.
14088	// This may be used to include empty fields in Patch requests.
14089	ForceSendFields []string `json:"-"`
14090
14091	// NullFields is a list of field names (e.g. "Kind") to include in API
14092	// requests with the JSON null value. By default, fields with empty
14093	// values are omitted from API requests. However, any field with an
14094	// empty value appearing in NullFields will be sent to the server as
14095	// null. It is an error if a field in this list has a non-empty value.
14096	// This may be used to include null fields in Patch requests.
14097	NullFields []string `json:"-"`
14098}
14099
14100func (s *TargetingTemplatesListResponse) MarshalJSON() ([]byte, error) {
14101	type NoMethod TargetingTemplatesListResponse
14102	raw := NoMethod(*s)
14103	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14104}
14105
14106// TechnologyTargeting: Technology Targeting.
14107type TechnologyTargeting struct {
14108	// Browsers: Browsers that this ad targets. For each browser either set
14109	// browserVersionId or dartId along with the version numbers. If both
14110	// are specified, only browserVersionId will be used. The other fields
14111	// are populated automatically when the ad is inserted or updated.
14112	Browsers []*Browser `json:"browsers,omitempty"`
14113
14114	// ConnectionTypes: Connection types that this ad targets. For each
14115	// connection type only id is required. The other fields are populated
14116	// automatically when the ad is inserted or updated.
14117	ConnectionTypes []*ConnectionType `json:"connectionTypes,omitempty"`
14118
14119	// MobileCarriers: Mobile carriers that this ad targets. For each mobile
14120	// carrier only id is required, and the other fields are populated
14121	// automatically when the ad is inserted or updated. If targeting a
14122	// mobile carrier, do not set targeting for any zip codes.
14123	MobileCarriers []*MobileCarrier `json:"mobileCarriers,omitempty"`
14124
14125	// OperatingSystemVersions: Operating system versions that this ad
14126	// targets. To target all versions, use operatingSystems. For each
14127	// operating system version, only id is required. The other fields are
14128	// populated automatically when the ad is inserted or updated. If
14129	// targeting an operating system version, do not set targeting for the
14130	// corresponding operating system in operatingSystems.
14131	OperatingSystemVersions []*OperatingSystemVersion `json:"operatingSystemVersions,omitempty"`
14132
14133	// OperatingSystems: Operating systems that this ad targets. To target
14134	// specific versions, use operatingSystemVersions. For each operating
14135	// system only dartId is required. The other fields are populated
14136	// automatically when the ad is inserted or updated. If targeting an
14137	// operating system, do not set targeting for operating system versions
14138	// for the same operating system.
14139	OperatingSystems []*OperatingSystem `json:"operatingSystems,omitempty"`
14140
14141	// PlatformTypes: Platform types that this ad targets. For example,
14142	// desktop, mobile, or tablet. For each platform type, only id is
14143	// required, and the other fields are populated automatically when the
14144	// ad is inserted or updated.
14145	PlatformTypes []*PlatformType `json:"platformTypes,omitempty"`
14146
14147	// ForceSendFields is a list of field names (e.g. "Browsers") to
14148	// unconditionally include in API requests. By default, fields with
14149	// empty or default values are omitted from API requests. However, any
14150	// non-pointer, non-interface field appearing in ForceSendFields will be
14151	// sent to the server regardless of whether the field is empty or not.
14152	// This may be used to include empty fields in Patch requests.
14153	ForceSendFields []string `json:"-"`
14154
14155	// NullFields is a list of field names (e.g. "Browsers") to include in
14156	// API requests with the JSON null value. By default, fields with empty
14157	// values are omitted from API requests. However, any field with an
14158	// empty value appearing in NullFields will be sent to the server as
14159	// null. It is an error if a field in this list has a non-empty value.
14160	// This may be used to include null fields in Patch requests.
14161	NullFields []string `json:"-"`
14162}
14163
14164func (s *TechnologyTargeting) MarshalJSON() ([]byte, error) {
14165	type NoMethod TechnologyTargeting
14166	raw := NoMethod(*s)
14167	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14168}
14169
14170// ThirdPartyAuthenticationToken: Third Party Authentication Token
14171type ThirdPartyAuthenticationToken struct {
14172	// Name: Name of the third-party authentication token.
14173	Name string `json:"name,omitempty"`
14174
14175	// Value: Value of the third-party authentication token. This is a
14176	// read-only, auto-generated field.
14177	Value string `json:"value,omitempty"`
14178
14179	// ForceSendFields is a list of field names (e.g. "Name") to
14180	// unconditionally include in API requests. By default, fields with
14181	// empty or default values are omitted from API requests. However, any
14182	// non-pointer, non-interface field appearing in ForceSendFields will be
14183	// sent to the server regardless of whether the field is empty or not.
14184	// This may be used to include empty fields in Patch requests.
14185	ForceSendFields []string `json:"-"`
14186
14187	// NullFields is a list of field names (e.g. "Name") to include in API
14188	// requests with the JSON null value. By default, fields with empty
14189	// values are omitted from API requests. However, any field with an
14190	// empty value appearing in NullFields will be sent to the server as
14191	// null. It is an error if a field in this list has a non-empty value.
14192	// This may be used to include null fields in Patch requests.
14193	NullFields []string `json:"-"`
14194}
14195
14196func (s *ThirdPartyAuthenticationToken) MarshalJSON() ([]byte, error) {
14197	type NoMethod ThirdPartyAuthenticationToken
14198	raw := NoMethod(*s)
14199	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14200}
14201
14202// ThirdPartyTrackingUrl: Third-party Tracking URL.
14203type ThirdPartyTrackingUrl struct {
14204	// ThirdPartyUrlType: Third-party URL type for in-stream video and
14205	// in-stream audio creatives.
14206	//
14207	// Possible values:
14208	//   "IMPRESSION"
14209	//   "CLICK_TRACKING"
14210	//   "VIDEO_START"
14211	//   "VIDEO_FIRST_QUARTILE"
14212	//   "VIDEO_MIDPOINT"
14213	//   "VIDEO_THIRD_QUARTILE"
14214	//   "VIDEO_COMPLETE"
14215	//   "VIDEO_MUTE"
14216	//   "VIDEO_PAUSE"
14217	//   "VIDEO_REWIND"
14218	//   "VIDEO_FULLSCREEN"
14219	//   "VIDEO_STOP"
14220	//   "VIDEO_CUSTOM"
14221	//   "SURVEY"
14222	//   "RICH_MEDIA_IMPRESSION"
14223	//   "RICH_MEDIA_RM_IMPRESSION"
14224	//   "RICH_MEDIA_BACKUP_IMPRESSION"
14225	//   "VIDEO_SKIP"
14226	//   "VIDEO_PROGRESS"
14227	ThirdPartyUrlType string `json:"thirdPartyUrlType,omitempty"`
14228
14229	// Url: URL for the specified third-party URL type.
14230	Url string `json:"url,omitempty"`
14231
14232	// ForceSendFields is a list of field names (e.g. "ThirdPartyUrlType")
14233	// to unconditionally include in API requests. By default, fields with
14234	// empty or default values are omitted from API requests. However, any
14235	// non-pointer, non-interface field appearing in ForceSendFields will be
14236	// sent to the server regardless of whether the field is empty or not.
14237	// This may be used to include empty fields in Patch requests.
14238	ForceSendFields []string `json:"-"`
14239
14240	// NullFields is a list of field names (e.g. "ThirdPartyUrlType") to
14241	// include in API requests with the JSON null value. By default, fields
14242	// with empty values are omitted from API requests. However, any field
14243	// with an empty value appearing in NullFields will be sent to the
14244	// server as null. It is an error if a field in this list has a
14245	// non-empty value. This may be used to include null fields in Patch
14246	// requests.
14247	NullFields []string `json:"-"`
14248}
14249
14250func (s *ThirdPartyTrackingUrl) MarshalJSON() ([]byte, error) {
14251	type NoMethod ThirdPartyTrackingUrl
14252	raw := NoMethod(*s)
14253	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14254}
14255
14256// TranscodeSetting: Transcode Settings
14257type TranscodeSetting struct {
14258	// EnabledVideoFormats: Allowlist of video formats to be served to this
14259	// placement. Set this list to null or empty to serve all video formats.
14260	EnabledVideoFormats []int64 `json:"enabledVideoFormats,omitempty"`
14261
14262	// Kind: Identifies what kind of resource this is. Value: the fixed
14263	// string "dfareporting#transcodeSetting".
14264	Kind string `json:"kind,omitempty"`
14265
14266	// ForceSendFields is a list of field names (e.g. "EnabledVideoFormats")
14267	// to unconditionally include in API requests. By default, fields with
14268	// empty or default values are omitted from API requests. However, any
14269	// non-pointer, non-interface field appearing in ForceSendFields will be
14270	// sent to the server regardless of whether the field is empty or not.
14271	// This may be used to include empty fields in Patch requests.
14272	ForceSendFields []string `json:"-"`
14273
14274	// NullFields is a list of field names (e.g. "EnabledVideoFormats") to
14275	// include in API requests with the JSON null value. By default, fields
14276	// with empty values are omitted from API requests. However, any field
14277	// with an empty value appearing in NullFields will be sent to the
14278	// server as null. It is an error if a field in this list has a
14279	// non-empty value. This may be used to include null fields in Patch
14280	// requests.
14281	NullFields []string `json:"-"`
14282}
14283
14284func (s *TranscodeSetting) MarshalJSON() ([]byte, error) {
14285	type NoMethod TranscodeSetting
14286	raw := NoMethod(*s)
14287	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14288}
14289
14290// UniversalAdId: A Universal Ad ID as per the VAST 4.0 spec. Applicable
14291// to the following creative types: INSTREAM_AUDIO, INSTREAM_VIDEO and
14292// VPAID.
14293type UniversalAdId struct {
14294	// Registry: Registry used for the Ad ID value.
14295	//
14296	// Possible values:
14297	//   "OTHER"
14298	//   "AD_ID_OFFICIAL"
14299	//   "CLEARCAST"
14300	//   "DCM"
14301	Registry string `json:"registry,omitempty"`
14302
14303	// Value: ID value for this creative. Only alphanumeric characters and
14304	// the following symbols are valid: "_/\-". Maximum length is 64
14305	// characters. Read only when registry is DCM.
14306	Value string `json:"value,omitempty"`
14307
14308	// ForceSendFields is a list of field names (e.g. "Registry") to
14309	// unconditionally include in API requests. By default, fields with
14310	// empty or default values are omitted from API requests. However, any
14311	// non-pointer, non-interface field appearing in ForceSendFields will be
14312	// sent to the server regardless of whether the field is empty or not.
14313	// This may be used to include empty fields in Patch requests.
14314	ForceSendFields []string `json:"-"`
14315
14316	// NullFields is a list of field names (e.g. "Registry") to include in
14317	// API requests with the JSON null value. By default, fields with empty
14318	// values are omitted from API requests. However, any field with an
14319	// empty value appearing in NullFields will be sent to the server as
14320	// null. It is an error if a field in this list has a non-empty value.
14321	// This may be used to include null fields in Patch requests.
14322	NullFields []string `json:"-"`
14323}
14324
14325func (s *UniversalAdId) MarshalJSON() ([]byte, error) {
14326	type NoMethod UniversalAdId
14327	raw := NoMethod(*s)
14328	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14329}
14330
14331// UserDefinedVariableConfiguration: User Defined Variable
14332// configuration.
14333type UserDefinedVariableConfiguration struct {
14334	// DataType: Data type for the variable. This is a required field.
14335	//
14336	// Possible values:
14337	//   "STRING"
14338	//   "NUMBER"
14339	DataType string `json:"dataType,omitempty"`
14340
14341	// ReportName: User-friendly name for the variable which will appear in
14342	// reports. This is a required field, must be less than 64 characters
14343	// long, and cannot contain the following characters: ""<>".
14344	ReportName string `json:"reportName,omitempty"`
14345
14346	// VariableType: Variable name in the tag. This is a required field.
14347	//
14348	// Possible values:
14349	//   "U1"
14350	//   "U2"
14351	//   "U3"
14352	//   "U4"
14353	//   "U5"
14354	//   "U6"
14355	//   "U7"
14356	//   "U8"
14357	//   "U9"
14358	//   "U10"
14359	//   "U11"
14360	//   "U12"
14361	//   "U13"
14362	//   "U14"
14363	//   "U15"
14364	//   "U16"
14365	//   "U17"
14366	//   "U18"
14367	//   "U19"
14368	//   "U20"
14369	//   "U21"
14370	//   "U22"
14371	//   "U23"
14372	//   "U24"
14373	//   "U25"
14374	//   "U26"
14375	//   "U27"
14376	//   "U28"
14377	//   "U29"
14378	//   "U30"
14379	//   "U31"
14380	//   "U32"
14381	//   "U33"
14382	//   "U34"
14383	//   "U35"
14384	//   "U36"
14385	//   "U37"
14386	//   "U38"
14387	//   "U39"
14388	//   "U40"
14389	//   "U41"
14390	//   "U42"
14391	//   "U43"
14392	//   "U44"
14393	//   "U45"
14394	//   "U46"
14395	//   "U47"
14396	//   "U48"
14397	//   "U49"
14398	//   "U50"
14399	//   "U51"
14400	//   "U52"
14401	//   "U53"
14402	//   "U54"
14403	//   "U55"
14404	//   "U56"
14405	//   "U57"
14406	//   "U58"
14407	//   "U59"
14408	//   "U60"
14409	//   "U61"
14410	//   "U62"
14411	//   "U63"
14412	//   "U64"
14413	//   "U65"
14414	//   "U66"
14415	//   "U67"
14416	//   "U68"
14417	//   "U69"
14418	//   "U70"
14419	//   "U71"
14420	//   "U72"
14421	//   "U73"
14422	//   "U74"
14423	//   "U75"
14424	//   "U76"
14425	//   "U77"
14426	//   "U78"
14427	//   "U79"
14428	//   "U80"
14429	//   "U81"
14430	//   "U82"
14431	//   "U83"
14432	//   "U84"
14433	//   "U85"
14434	//   "U86"
14435	//   "U87"
14436	//   "U88"
14437	//   "U89"
14438	//   "U90"
14439	//   "U91"
14440	//   "U92"
14441	//   "U93"
14442	//   "U94"
14443	//   "U95"
14444	//   "U96"
14445	//   "U97"
14446	//   "U98"
14447	//   "U99"
14448	//   "U100"
14449	VariableType string `json:"variableType,omitempty"`
14450
14451	// ForceSendFields is a list of field names (e.g. "DataType") to
14452	// unconditionally include in API requests. By default, fields with
14453	// empty or default values are omitted from API requests. However, any
14454	// non-pointer, non-interface field appearing in ForceSendFields will be
14455	// sent to the server regardless of whether the field is empty or not.
14456	// This may be used to include empty fields in Patch requests.
14457	ForceSendFields []string `json:"-"`
14458
14459	// NullFields is a list of field names (e.g. "DataType") to include in
14460	// API requests with the JSON null value. By default, fields with empty
14461	// values are omitted from API requests. However, any field with an
14462	// empty value appearing in NullFields will be sent to the server as
14463	// null. It is an error if a field in this list has a non-empty value.
14464	// This may be used to include null fields in Patch requests.
14465	NullFields []string `json:"-"`
14466}
14467
14468func (s *UserDefinedVariableConfiguration) MarshalJSON() ([]byte, error) {
14469	type NoMethod UserDefinedVariableConfiguration
14470	raw := NoMethod(*s)
14471	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14472}
14473
14474// UserProfile: A UserProfile resource lets you list all DFA user
14475// profiles that are associated with a Google user account. The
14476// profile_id needs to be specified in other API requests.
14477type UserProfile struct {
14478	// AccountId: The account ID to which this profile belongs.
14479	AccountId int64 `json:"accountId,omitempty,string"`
14480
14481	// AccountName: The account name this profile belongs to.
14482	AccountName string `json:"accountName,omitempty"`
14483
14484	// Etag: Etag of this resource.
14485	Etag string `json:"etag,omitempty"`
14486
14487	// Kind: Identifies what kind of resource this is. Value: the fixed
14488	// string "dfareporting#userProfile".
14489	Kind string `json:"kind,omitempty"`
14490
14491	// ProfileId: The unique ID of the user profile.
14492	ProfileId int64 `json:"profileId,omitempty,string"`
14493
14494	// SubAccountId: The sub account ID this profile belongs to if
14495	// applicable.
14496	SubAccountId int64 `json:"subAccountId,omitempty,string"`
14497
14498	// SubAccountName: The sub account name this profile belongs to if
14499	// applicable.
14500	SubAccountName string `json:"subAccountName,omitempty"`
14501
14502	// UserName: The user name.
14503	UserName string `json:"userName,omitempty"`
14504
14505	// ServerResponse contains the HTTP response code and headers from the
14506	// server.
14507	googleapi.ServerResponse `json:"-"`
14508
14509	// ForceSendFields is a list of field names (e.g. "AccountId") to
14510	// unconditionally include in API requests. By default, fields with
14511	// empty or default values are omitted from API requests. However, any
14512	// non-pointer, non-interface field appearing in ForceSendFields will be
14513	// sent to the server regardless of whether the field is empty or not.
14514	// This may be used to include empty fields in Patch requests.
14515	ForceSendFields []string `json:"-"`
14516
14517	// NullFields is a list of field names (e.g. "AccountId") to include in
14518	// API requests with the JSON null value. By default, fields with empty
14519	// values are omitted from API requests. However, any field with an
14520	// empty value appearing in NullFields will be sent to the server as
14521	// null. It is an error if a field in this list has a non-empty value.
14522	// This may be used to include null fields in Patch requests.
14523	NullFields []string `json:"-"`
14524}
14525
14526func (s *UserProfile) MarshalJSON() ([]byte, error) {
14527	type NoMethod UserProfile
14528	raw := NoMethod(*s)
14529	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14530}
14531
14532// UserProfileList: Represents the list of user profiles.
14533type UserProfileList struct {
14534	// Etag: Etag of this resource.
14535	Etag string `json:"etag,omitempty"`
14536
14537	// Items: The user profiles returned in this response.
14538	Items []*UserProfile `json:"items,omitempty"`
14539
14540	// Kind: Identifies what kind of resource this is. Value: the fixed
14541	// string "dfareporting#userProfileList".
14542	Kind string `json:"kind,omitempty"`
14543
14544	// ServerResponse contains the HTTP response code and headers from the
14545	// server.
14546	googleapi.ServerResponse `json:"-"`
14547
14548	// ForceSendFields is a list of field names (e.g. "Etag") to
14549	// unconditionally include in API requests. By default, fields with
14550	// empty or default values are omitted from API requests. However, any
14551	// non-pointer, non-interface field appearing in ForceSendFields will be
14552	// sent to the server regardless of whether the field is empty or not.
14553	// This may be used to include empty fields in Patch requests.
14554	ForceSendFields []string `json:"-"`
14555
14556	// NullFields is a list of field names (e.g. "Etag") to include in API
14557	// requests with the JSON null value. By default, fields with empty
14558	// values are omitted from API requests. However, any field with an
14559	// empty value appearing in NullFields will be sent to the server as
14560	// null. It is an error if a field in this list has a non-empty value.
14561	// This may be used to include null fields in Patch requests.
14562	NullFields []string `json:"-"`
14563}
14564
14565func (s *UserProfileList) MarshalJSON() ([]byte, error) {
14566	type NoMethod UserProfileList
14567	raw := NoMethod(*s)
14568	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14569}
14570
14571// UserRole: Contains properties of auser role, which is used to manage
14572// user access.
14573type UserRole struct {
14574	// AccountId: Account ID of this user role. This is a read-only field
14575	// that can be left blank.
14576	AccountId int64 `json:"accountId,omitempty,string"`
14577
14578	// DefaultUserRole: Whether this is a default user role. Default user
14579	// roles are created by the system for the account/subaccount and cannot
14580	// be modified or deleted. Each default user role comes with a basic set
14581	// of preassigned permissions.
14582	DefaultUserRole bool `json:"defaultUserRole,omitempty"`
14583
14584	// Id: ID of this user role. This is a read-only, auto-generated field.
14585	Id int64 `json:"id,omitempty,string"`
14586
14587	// Kind: Identifies what kind of resource this is. Value: the fixed
14588	// string "dfareporting#userRole".
14589	Kind string `json:"kind,omitempty"`
14590
14591	// Name: Name of this user role. This is a required field. Must be less
14592	// than 256 characters long. If this user role is under a subaccount,
14593	// the name must be unique among sites of the same subaccount.
14594	// Otherwise, this user role is a top-level user role, and the name must
14595	// be unique among top-level user roles of the same account.
14596	Name string `json:"name,omitempty"`
14597
14598	// ParentUserRoleId: ID of the user role that this user role is based on
14599	// or copied from. This is a required field.
14600	ParentUserRoleId int64 `json:"parentUserRoleId,omitempty,string"`
14601
14602	// Permissions: List of permissions associated with this user role.
14603	Permissions []*UserRolePermission `json:"permissions,omitempty"`
14604
14605	// SubaccountId: Subaccount ID of this user role. This is a read-only
14606	// field that can be left blank.
14607	SubaccountId int64 `json:"subaccountId,omitempty,string"`
14608
14609	// ServerResponse contains the HTTP response code and headers from the
14610	// server.
14611	googleapi.ServerResponse `json:"-"`
14612
14613	// ForceSendFields is a list of field names (e.g. "AccountId") to
14614	// unconditionally include in API requests. By default, fields with
14615	// empty or default values are omitted from API requests. However, any
14616	// non-pointer, non-interface field appearing in ForceSendFields will be
14617	// sent to the server regardless of whether the field is empty or not.
14618	// This may be used to include empty fields in Patch requests.
14619	ForceSendFields []string `json:"-"`
14620
14621	// NullFields is a list of field names (e.g. "AccountId") to include in
14622	// API requests with the JSON null value. By default, fields with empty
14623	// values are omitted from API requests. However, any field with an
14624	// empty value appearing in NullFields will be sent to the server as
14625	// null. It is an error if a field in this list has a non-empty value.
14626	// This may be used to include null fields in Patch requests.
14627	NullFields []string `json:"-"`
14628}
14629
14630func (s *UserRole) MarshalJSON() ([]byte, error) {
14631	type NoMethod UserRole
14632	raw := NoMethod(*s)
14633	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14634}
14635
14636// UserRolePermission: Contains properties of a user role permission.
14637type UserRolePermission struct {
14638	// Availability: Levels of availability for a user role permission.
14639	//
14640	// Possible values:
14641	//   "NOT_AVAILABLE_BY_DEFAULT"
14642	//   "ACCOUNT_BY_DEFAULT"
14643	//   "SUBACCOUNT_AND_ACCOUNT_BY_DEFAULT"
14644	//   "ACCOUNT_ALWAYS"
14645	//   "SUBACCOUNT_AND_ACCOUNT_ALWAYS"
14646	//   "USER_PROFILE_ONLY"
14647	Availability string `json:"availability,omitempty"`
14648
14649	// Id: ID of this user role permission.
14650	Id int64 `json:"id,omitempty,string"`
14651
14652	// Kind: Identifies what kind of resource this is. Value: the fixed
14653	// string "dfareporting#userRolePermission".
14654	Kind string `json:"kind,omitempty"`
14655
14656	// Name: Name of this user role permission.
14657	Name string `json:"name,omitempty"`
14658
14659	// PermissionGroupId: ID of the permission group that this user role
14660	// permission belongs to.
14661	PermissionGroupId int64 `json:"permissionGroupId,omitempty,string"`
14662
14663	// ServerResponse contains the HTTP response code and headers from the
14664	// server.
14665	googleapi.ServerResponse `json:"-"`
14666
14667	// ForceSendFields is a list of field names (e.g. "Availability") to
14668	// unconditionally include in API requests. By default, fields with
14669	// empty or default values are omitted from API requests. However, any
14670	// non-pointer, non-interface field appearing in ForceSendFields will be
14671	// sent to the server regardless of whether the field is empty or not.
14672	// This may be used to include empty fields in Patch requests.
14673	ForceSendFields []string `json:"-"`
14674
14675	// NullFields is a list of field names (e.g. "Availability") to include
14676	// in API requests with the JSON null value. By default, fields with
14677	// empty values are omitted from API requests. However, any field with
14678	// an empty value appearing in NullFields will be sent to the server as
14679	// null. It is an error if a field in this list has a non-empty value.
14680	// This may be used to include null fields in Patch requests.
14681	NullFields []string `json:"-"`
14682}
14683
14684func (s *UserRolePermission) MarshalJSON() ([]byte, error) {
14685	type NoMethod UserRolePermission
14686	raw := NoMethod(*s)
14687	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14688}
14689
14690// UserRolePermissionGroup: Represents a grouping of related user role
14691// permissions.
14692type UserRolePermissionGroup struct {
14693	// Id: ID of this user role permission.
14694	Id int64 `json:"id,omitempty,string"`
14695
14696	// Kind: Identifies what kind of resource this is. Value: the fixed
14697	// string "dfareporting#userRolePermissionGroup".
14698	Kind string `json:"kind,omitempty"`
14699
14700	// Name: Name of this user role permission group.
14701	Name string `json:"name,omitempty"`
14702
14703	// ServerResponse contains the HTTP response code and headers from the
14704	// server.
14705	googleapi.ServerResponse `json:"-"`
14706
14707	// ForceSendFields is a list of field names (e.g. "Id") to
14708	// unconditionally include in API requests. By default, fields with
14709	// empty or default values are omitted from API requests. However, any
14710	// non-pointer, non-interface field appearing in ForceSendFields will be
14711	// sent to the server regardless of whether the field is empty or not.
14712	// This may be used to include empty fields in Patch requests.
14713	ForceSendFields []string `json:"-"`
14714
14715	// NullFields is a list of field names (e.g. "Id") to include in API
14716	// requests with the JSON null value. By default, fields with empty
14717	// values are omitted from API requests. However, any field with an
14718	// empty value appearing in NullFields will be sent to the server as
14719	// null. It is an error if a field in this list has a non-empty value.
14720	// This may be used to include null fields in Patch requests.
14721	NullFields []string `json:"-"`
14722}
14723
14724func (s *UserRolePermissionGroup) MarshalJSON() ([]byte, error) {
14725	type NoMethod UserRolePermissionGroup
14726	raw := NoMethod(*s)
14727	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14728}
14729
14730// UserRolePermissionGroupsListResponse: User Role Permission Group List
14731// Response
14732type UserRolePermissionGroupsListResponse struct {
14733	// Kind: Identifies what kind of resource this is. Value: the fixed
14734	// string "dfareporting#userRolePermissionGroupsListResponse".
14735	Kind string `json:"kind,omitempty"`
14736
14737	// UserRolePermissionGroups: User role permission group collection.
14738	UserRolePermissionGroups []*UserRolePermissionGroup `json:"userRolePermissionGroups,omitempty"`
14739
14740	// ServerResponse contains the HTTP response code and headers from the
14741	// server.
14742	googleapi.ServerResponse `json:"-"`
14743
14744	// ForceSendFields is a list of field names (e.g. "Kind") to
14745	// unconditionally include in API requests. By default, fields with
14746	// empty or default values are omitted from API requests. However, any
14747	// non-pointer, non-interface field appearing in ForceSendFields will be
14748	// sent to the server regardless of whether the field is empty or not.
14749	// This may be used to include empty fields in Patch requests.
14750	ForceSendFields []string `json:"-"`
14751
14752	// NullFields is a list of field names (e.g. "Kind") to include in API
14753	// requests with the JSON null value. By default, fields with empty
14754	// values are omitted from API requests. However, any field with an
14755	// empty value appearing in NullFields will be sent to the server as
14756	// null. It is an error if a field in this list has a non-empty value.
14757	// This may be used to include null fields in Patch requests.
14758	NullFields []string `json:"-"`
14759}
14760
14761func (s *UserRolePermissionGroupsListResponse) MarshalJSON() ([]byte, error) {
14762	type NoMethod UserRolePermissionGroupsListResponse
14763	raw := NoMethod(*s)
14764	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14765}
14766
14767// UserRolePermissionsListResponse: User Role Permission List Response
14768type UserRolePermissionsListResponse struct {
14769	// Kind: Identifies what kind of resource this is. Value: the fixed
14770	// string "dfareporting#userRolePermissionsListResponse".
14771	Kind string `json:"kind,omitempty"`
14772
14773	// UserRolePermissions: User role permission collection.
14774	UserRolePermissions []*UserRolePermission `json:"userRolePermissions,omitempty"`
14775
14776	// ServerResponse contains the HTTP response code and headers from the
14777	// server.
14778	googleapi.ServerResponse `json:"-"`
14779
14780	// ForceSendFields is a list of field names (e.g. "Kind") to
14781	// unconditionally include in API requests. By default, fields with
14782	// empty or default values are omitted from API requests. However, any
14783	// non-pointer, non-interface field appearing in ForceSendFields will be
14784	// sent to the server regardless of whether the field is empty or not.
14785	// This may be used to include empty fields in Patch requests.
14786	ForceSendFields []string `json:"-"`
14787
14788	// NullFields is a list of field names (e.g. "Kind") to include in API
14789	// requests with the JSON null value. By default, fields with empty
14790	// values are omitted from API requests. However, any field with an
14791	// empty value appearing in NullFields will be sent to the server as
14792	// null. It is an error if a field in this list has a non-empty value.
14793	// This may be used to include null fields in Patch requests.
14794	NullFields []string `json:"-"`
14795}
14796
14797func (s *UserRolePermissionsListResponse) MarshalJSON() ([]byte, error) {
14798	type NoMethod UserRolePermissionsListResponse
14799	raw := NoMethod(*s)
14800	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14801}
14802
14803// UserRolesListResponse: User Role List Response
14804type UserRolesListResponse struct {
14805	// Kind: Identifies what kind of resource this is. Value: the fixed
14806	// string "dfareporting#userRolesListResponse".
14807	Kind string `json:"kind,omitempty"`
14808
14809	// NextPageToken: Pagination token to be used for the next list
14810	// operation.
14811	NextPageToken string `json:"nextPageToken,omitempty"`
14812
14813	// UserRoles: User role collection.
14814	UserRoles []*UserRole `json:"userRoles,omitempty"`
14815
14816	// ServerResponse contains the HTTP response code and headers from the
14817	// server.
14818	googleapi.ServerResponse `json:"-"`
14819
14820	// ForceSendFields is a list of field names (e.g. "Kind") to
14821	// unconditionally include in API requests. By default, fields with
14822	// empty or default values are omitted from API requests. However, any
14823	// non-pointer, non-interface field appearing in ForceSendFields will be
14824	// sent to the server regardless of whether the field is empty or not.
14825	// This may be used to include empty fields in Patch requests.
14826	ForceSendFields []string `json:"-"`
14827
14828	// NullFields is a list of field names (e.g. "Kind") to include in API
14829	// requests with the JSON null value. By default, fields with empty
14830	// values are omitted from API requests. However, any field with an
14831	// empty value appearing in NullFields will be sent to the server as
14832	// null. It is an error if a field in this list has a non-empty value.
14833	// This may be used to include null fields in Patch requests.
14834	NullFields []string `json:"-"`
14835}
14836
14837func (s *UserRolesListResponse) MarshalJSON() ([]byte, error) {
14838	type NoMethod UserRolesListResponse
14839	raw := NoMethod(*s)
14840	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14841}
14842
14843// VideoFormat: Contains information about supported video formats.
14844type VideoFormat struct {
14845	// FileType: File type of the video format.
14846	//
14847	// Possible values:
14848	//   "FLV"
14849	//   "THREEGPP"
14850	//   "MP4"
14851	//   "WEBM"
14852	//   "M3U8"
14853	FileType string `json:"fileType,omitempty"`
14854
14855	// Id: ID of the video format.
14856	Id int64 `json:"id,omitempty"`
14857
14858	// Kind: Identifies what kind of resource this is. Value: the fixed
14859	// string "dfareporting#videoFormat".
14860	Kind string `json:"kind,omitempty"`
14861
14862	// Resolution: The resolution of this video format.
14863	Resolution *Size `json:"resolution,omitempty"`
14864
14865	// TargetBitRate: The target bit rate of this video format.
14866	TargetBitRate int64 `json:"targetBitRate,omitempty"`
14867
14868	// ServerResponse contains the HTTP response code and headers from the
14869	// server.
14870	googleapi.ServerResponse `json:"-"`
14871
14872	// ForceSendFields is a list of field names (e.g. "FileType") to
14873	// unconditionally include in API requests. By default, fields with
14874	// empty or default values are omitted from API requests. However, any
14875	// non-pointer, non-interface field appearing in ForceSendFields will be
14876	// sent to the server regardless of whether the field is empty or not.
14877	// This may be used to include empty fields in Patch requests.
14878	ForceSendFields []string `json:"-"`
14879
14880	// NullFields is a list of field names (e.g. "FileType") to include in
14881	// API requests with the JSON null value. By default, fields with empty
14882	// values are omitted from API requests. However, any field with an
14883	// empty value appearing in NullFields will be sent to the server as
14884	// null. It is an error if a field in this list has a non-empty value.
14885	// This may be used to include null fields in Patch requests.
14886	NullFields []string `json:"-"`
14887}
14888
14889func (s *VideoFormat) MarshalJSON() ([]byte, error) {
14890	type NoMethod VideoFormat
14891	raw := NoMethod(*s)
14892	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14893}
14894
14895// VideoFormatsListResponse: Video Format List Response
14896type VideoFormatsListResponse struct {
14897	// Kind: Identifies what kind of resource this is. Value: the fixed
14898	// string "dfareporting#videoFormatsListResponse".
14899	Kind string `json:"kind,omitempty"`
14900
14901	// VideoFormats: Video format collection.
14902	VideoFormats []*VideoFormat `json:"videoFormats,omitempty"`
14903
14904	// ServerResponse contains the HTTP response code and headers from the
14905	// server.
14906	googleapi.ServerResponse `json:"-"`
14907
14908	// ForceSendFields is a list of field names (e.g. "Kind") to
14909	// unconditionally include in API requests. By default, fields with
14910	// empty or default values are omitted from API requests. However, any
14911	// non-pointer, non-interface field appearing in ForceSendFields will be
14912	// sent to the server regardless of whether the field is empty or not.
14913	// This may be used to include empty fields in Patch requests.
14914	ForceSendFields []string `json:"-"`
14915
14916	// NullFields is a list of field names (e.g. "Kind") to include in API
14917	// requests with the JSON null value. By default, fields with empty
14918	// values are omitted from API requests. However, any field with an
14919	// empty value appearing in NullFields will be sent to the server as
14920	// null. It is an error if a field in this list has a non-empty value.
14921	// This may be used to include null fields in Patch requests.
14922	NullFields []string `json:"-"`
14923}
14924
14925func (s *VideoFormatsListResponse) MarshalJSON() ([]byte, error) {
14926	type NoMethod VideoFormatsListResponse
14927	raw := NoMethod(*s)
14928	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14929}
14930
14931// VideoOffset: Video Offset
14932type VideoOffset struct {
14933	// OffsetPercentage: Duration, as a percentage of video duration. Do not
14934	// set when offsetSeconds is set. Acceptable values are 0 to 100,
14935	// inclusive.
14936	OffsetPercentage int64 `json:"offsetPercentage,omitempty"`
14937
14938	// OffsetSeconds: Duration, in seconds. Do not set when offsetPercentage
14939	// is set. Acceptable values are 0 to 86399, inclusive.
14940	OffsetSeconds int64 `json:"offsetSeconds,omitempty"`
14941
14942	// ForceSendFields is a list of field names (e.g. "OffsetPercentage") to
14943	// unconditionally include in API requests. By default, fields with
14944	// empty or default values are omitted from API requests. However, any
14945	// non-pointer, non-interface field appearing in ForceSendFields will be
14946	// sent to the server regardless of whether the field is empty or not.
14947	// This may be used to include empty fields in Patch requests.
14948	ForceSendFields []string `json:"-"`
14949
14950	// NullFields is a list of field names (e.g. "OffsetPercentage") to
14951	// include in API requests with the JSON null value. By default, fields
14952	// with empty values are omitted from API requests. However, any field
14953	// with an empty value appearing in NullFields will be sent to the
14954	// server as null. It is an error if a field in this list has a
14955	// non-empty value. This may be used to include null fields in Patch
14956	// requests.
14957	NullFields []string `json:"-"`
14958}
14959
14960func (s *VideoOffset) MarshalJSON() ([]byte, error) {
14961	type NoMethod VideoOffset
14962	raw := NoMethod(*s)
14963	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14964}
14965
14966// VideoSettings: Video Settings
14967type VideoSettings struct {
14968	// CompanionSettings: Settings for the companion creatives of video
14969	// creatives served to this placement.
14970	CompanionSettings *CompanionSetting `json:"companionSettings,omitempty"`
14971
14972	// Kind: Identifies what kind of resource this is. Value: the fixed
14973	// string "dfareporting#videoSettings".
14974	Kind string `json:"kind,omitempty"`
14975
14976	// ObaEnabled: Whether OBA icons are enabled for this placement.
14977	ObaEnabled bool `json:"obaEnabled,omitempty"`
14978
14979	// ObaSettings: Settings for the OBA icon of video creatives served to
14980	// this placement. If this object is provided, the creative-level OBA
14981	// settings will be overridden.
14982	ObaSettings *ObaIcon `json:"obaSettings,omitempty"`
14983
14984	// Orientation: Orientation of a video placement. If this value is set,
14985	// placement will return assets matching the specified orientation.
14986	//
14987	// Possible values:
14988	//   "ANY"
14989	//   "LANDSCAPE"
14990	//   "PORTRAIT"
14991	Orientation string `json:"orientation,omitempty"`
14992
14993	// SkippableSettings: Settings for the skippability of video creatives
14994	// served to this placement. If this object is provided, the
14995	// creative-level skippable settings will be overridden.
14996	SkippableSettings *SkippableSetting `json:"skippableSettings,omitempty"`
14997
14998	// TranscodeSettings: Settings for the transcodes of video creatives
14999	// served to this placement. If this object is provided, the
15000	// creative-level transcode settings will be overridden.
15001	TranscodeSettings *TranscodeSetting `json:"transcodeSettings,omitempty"`
15002
15003	// ForceSendFields is a list of field names (e.g. "CompanionSettings")
15004	// to unconditionally include in API requests. By default, fields with
15005	// empty or default values are omitted from API requests. However, any
15006	// non-pointer, non-interface field appearing in ForceSendFields will be
15007	// sent to the server regardless of whether the field is empty or not.
15008	// This may be used to include empty fields in Patch requests.
15009	ForceSendFields []string `json:"-"`
15010
15011	// NullFields is a list of field names (e.g. "CompanionSettings") to
15012	// include in API requests with the JSON null value. By default, fields
15013	// with empty values are omitted from API requests. However, any field
15014	// with an empty value appearing in NullFields will be sent to the
15015	// server as null. It is an error if a field in this list has a
15016	// non-empty value. This may be used to include null fields in Patch
15017	// requests.
15018	NullFields []string `json:"-"`
15019}
15020
15021func (s *VideoSettings) MarshalJSON() ([]byte, error) {
15022	type NoMethod VideoSettings
15023	raw := NoMethod(*s)
15024	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
15025}
15026
15027// method id "dfareporting.accountActiveAdSummaries.get":
15028
15029type AccountActiveAdSummariesGetCall struct {
15030	s                *Service
15031	profileId        int64
15032	summaryAccountId int64
15033	urlParams_       gensupport.URLParams
15034	ifNoneMatch_     string
15035	ctx_             context.Context
15036	header_          http.Header
15037}
15038
15039// Get: Gets the account's active ad summary by account ID.
15040//
15041// - profileId: User profile ID associated with this request.
15042// - summaryAccountId: Account ID.
15043func (r *AccountActiveAdSummariesService) Get(profileId int64, summaryAccountId int64) *AccountActiveAdSummariesGetCall {
15044	c := &AccountActiveAdSummariesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
15045	c.profileId = profileId
15046	c.summaryAccountId = summaryAccountId
15047	return c
15048}
15049
15050// Fields allows partial responses to be retrieved. See
15051// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
15052// for more information.
15053func (c *AccountActiveAdSummariesGetCall) Fields(s ...googleapi.Field) *AccountActiveAdSummariesGetCall {
15054	c.urlParams_.Set("fields", googleapi.CombineFields(s))
15055	return c
15056}
15057
15058// IfNoneMatch sets the optional parameter which makes the operation
15059// fail if the object's ETag matches the given value. This is useful for
15060// getting updates only after the object has changed since the last
15061// request. Use googleapi.IsNotModified to check whether the response
15062// error from Do is the result of In-None-Match.
15063func (c *AccountActiveAdSummariesGetCall) IfNoneMatch(entityTag string) *AccountActiveAdSummariesGetCall {
15064	c.ifNoneMatch_ = entityTag
15065	return c
15066}
15067
15068// Context sets the context to be used in this call's Do method. Any
15069// pending HTTP request will be aborted if the provided context is
15070// canceled.
15071func (c *AccountActiveAdSummariesGetCall) Context(ctx context.Context) *AccountActiveAdSummariesGetCall {
15072	c.ctx_ = ctx
15073	return c
15074}
15075
15076// Header returns an http.Header that can be modified by the caller to
15077// add HTTP headers to the request.
15078func (c *AccountActiveAdSummariesGetCall) Header() http.Header {
15079	if c.header_ == nil {
15080		c.header_ = make(http.Header)
15081	}
15082	return c.header_
15083}
15084
15085func (c *AccountActiveAdSummariesGetCall) doRequest(alt string) (*http.Response, error) {
15086	reqHeaders := make(http.Header)
15087	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
15088	for k, v := range c.header_ {
15089		reqHeaders[k] = v
15090	}
15091	reqHeaders.Set("User-Agent", c.s.userAgent())
15092	if c.ifNoneMatch_ != "" {
15093		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
15094	}
15095	var body io.Reader = nil
15096	c.urlParams_.Set("alt", alt)
15097	c.urlParams_.Set("prettyPrint", "false")
15098	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/accountActiveAdSummaries/{summaryAccountId}")
15099	urls += "?" + c.urlParams_.Encode()
15100	req, err := http.NewRequest("GET", urls, body)
15101	if err != nil {
15102		return nil, err
15103	}
15104	req.Header = reqHeaders
15105	googleapi.Expand(req.URL, map[string]string{
15106		"profileId":        strconv.FormatInt(c.profileId, 10),
15107		"summaryAccountId": strconv.FormatInt(c.summaryAccountId, 10),
15108	})
15109	return gensupport.SendRequest(c.ctx_, c.s.client, req)
15110}
15111
15112// Do executes the "dfareporting.accountActiveAdSummaries.get" call.
15113// Exactly one of *AccountActiveAdSummary or error will be non-nil. Any
15114// non-2xx status code is an error. Response headers are in either
15115// *AccountActiveAdSummary.ServerResponse.Header or (if a response was
15116// returned at all) in error.(*googleapi.Error).Header. Use
15117// googleapi.IsNotModified to check whether the returned error was
15118// because http.StatusNotModified was returned.
15119func (c *AccountActiveAdSummariesGetCall) Do(opts ...googleapi.CallOption) (*AccountActiveAdSummary, error) {
15120	gensupport.SetOptions(c.urlParams_, opts...)
15121	res, err := c.doRequest("json")
15122	if res != nil && res.StatusCode == http.StatusNotModified {
15123		if res.Body != nil {
15124			res.Body.Close()
15125		}
15126		return nil, &googleapi.Error{
15127			Code:   res.StatusCode,
15128			Header: res.Header,
15129		}
15130	}
15131	if err != nil {
15132		return nil, err
15133	}
15134	defer googleapi.CloseBody(res)
15135	if err := googleapi.CheckResponse(res); err != nil {
15136		return nil, err
15137	}
15138	ret := &AccountActiveAdSummary{
15139		ServerResponse: googleapi.ServerResponse{
15140			Header:         res.Header,
15141			HTTPStatusCode: res.StatusCode,
15142		},
15143	}
15144	target := &ret
15145	if err := gensupport.DecodeResponse(target, res); err != nil {
15146		return nil, err
15147	}
15148	return ret, nil
15149	// {
15150	//   "description": "Gets the account's active ad summary by account ID.",
15151	//   "flatPath": "userprofiles/{profileId}/accountActiveAdSummaries/{summaryAccountId}",
15152	//   "httpMethod": "GET",
15153	//   "id": "dfareporting.accountActiveAdSummaries.get",
15154	//   "parameterOrder": [
15155	//     "profileId",
15156	//     "summaryAccountId"
15157	//   ],
15158	//   "parameters": {
15159	//     "profileId": {
15160	//       "description": "User profile ID associated with this request.",
15161	//       "format": "int64",
15162	//       "location": "path",
15163	//       "required": true,
15164	//       "type": "string"
15165	//     },
15166	//     "summaryAccountId": {
15167	//       "description": "Account ID.",
15168	//       "format": "int64",
15169	//       "location": "path",
15170	//       "required": true,
15171	//       "type": "string"
15172	//     }
15173	//   },
15174	//   "path": "userprofiles/{profileId}/accountActiveAdSummaries/{summaryAccountId}",
15175	//   "response": {
15176	//     "$ref": "AccountActiveAdSummary"
15177	//   },
15178	//   "scopes": [
15179	//     "https://www.googleapis.com/auth/dfatrafficking"
15180	//   ]
15181	// }
15182
15183}
15184
15185// method id "dfareporting.accountPermissionGroups.get":
15186
15187type AccountPermissionGroupsGetCall struct {
15188	s            *Service
15189	profileId    int64
15190	id           int64
15191	urlParams_   gensupport.URLParams
15192	ifNoneMatch_ string
15193	ctx_         context.Context
15194	header_      http.Header
15195}
15196
15197// Get: Gets one account permission group by ID.
15198//
15199// - id: Account permission group ID.
15200// - profileId: User profile ID associated with this request.
15201func (r *AccountPermissionGroupsService) Get(profileId int64, id int64) *AccountPermissionGroupsGetCall {
15202	c := &AccountPermissionGroupsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
15203	c.profileId = profileId
15204	c.id = id
15205	return c
15206}
15207
15208// Fields allows partial responses to be retrieved. See
15209// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
15210// for more information.
15211func (c *AccountPermissionGroupsGetCall) Fields(s ...googleapi.Field) *AccountPermissionGroupsGetCall {
15212	c.urlParams_.Set("fields", googleapi.CombineFields(s))
15213	return c
15214}
15215
15216// IfNoneMatch sets the optional parameter which makes the operation
15217// fail if the object's ETag matches the given value. This is useful for
15218// getting updates only after the object has changed since the last
15219// request. Use googleapi.IsNotModified to check whether the response
15220// error from Do is the result of In-None-Match.
15221func (c *AccountPermissionGroupsGetCall) IfNoneMatch(entityTag string) *AccountPermissionGroupsGetCall {
15222	c.ifNoneMatch_ = entityTag
15223	return c
15224}
15225
15226// Context sets the context to be used in this call's Do method. Any
15227// pending HTTP request will be aborted if the provided context is
15228// canceled.
15229func (c *AccountPermissionGroupsGetCall) Context(ctx context.Context) *AccountPermissionGroupsGetCall {
15230	c.ctx_ = ctx
15231	return c
15232}
15233
15234// Header returns an http.Header that can be modified by the caller to
15235// add HTTP headers to the request.
15236func (c *AccountPermissionGroupsGetCall) Header() http.Header {
15237	if c.header_ == nil {
15238		c.header_ = make(http.Header)
15239	}
15240	return c.header_
15241}
15242
15243func (c *AccountPermissionGroupsGetCall) doRequest(alt string) (*http.Response, error) {
15244	reqHeaders := make(http.Header)
15245	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
15246	for k, v := range c.header_ {
15247		reqHeaders[k] = v
15248	}
15249	reqHeaders.Set("User-Agent", c.s.userAgent())
15250	if c.ifNoneMatch_ != "" {
15251		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
15252	}
15253	var body io.Reader = nil
15254	c.urlParams_.Set("alt", alt)
15255	c.urlParams_.Set("prettyPrint", "false")
15256	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/accountPermissionGroups/{id}")
15257	urls += "?" + c.urlParams_.Encode()
15258	req, err := http.NewRequest("GET", urls, body)
15259	if err != nil {
15260		return nil, err
15261	}
15262	req.Header = reqHeaders
15263	googleapi.Expand(req.URL, map[string]string{
15264		"profileId": strconv.FormatInt(c.profileId, 10),
15265		"id":        strconv.FormatInt(c.id, 10),
15266	})
15267	return gensupport.SendRequest(c.ctx_, c.s.client, req)
15268}
15269
15270// Do executes the "dfareporting.accountPermissionGroups.get" call.
15271// Exactly one of *AccountPermissionGroup or error will be non-nil. Any
15272// non-2xx status code is an error. Response headers are in either
15273// *AccountPermissionGroup.ServerResponse.Header or (if a response was
15274// returned at all) in error.(*googleapi.Error).Header. Use
15275// googleapi.IsNotModified to check whether the returned error was
15276// because http.StatusNotModified was returned.
15277func (c *AccountPermissionGroupsGetCall) Do(opts ...googleapi.CallOption) (*AccountPermissionGroup, error) {
15278	gensupport.SetOptions(c.urlParams_, opts...)
15279	res, err := c.doRequest("json")
15280	if res != nil && res.StatusCode == http.StatusNotModified {
15281		if res.Body != nil {
15282			res.Body.Close()
15283		}
15284		return nil, &googleapi.Error{
15285			Code:   res.StatusCode,
15286			Header: res.Header,
15287		}
15288	}
15289	if err != nil {
15290		return nil, err
15291	}
15292	defer googleapi.CloseBody(res)
15293	if err := googleapi.CheckResponse(res); err != nil {
15294		return nil, err
15295	}
15296	ret := &AccountPermissionGroup{
15297		ServerResponse: googleapi.ServerResponse{
15298			Header:         res.Header,
15299			HTTPStatusCode: res.StatusCode,
15300		},
15301	}
15302	target := &ret
15303	if err := gensupport.DecodeResponse(target, res); err != nil {
15304		return nil, err
15305	}
15306	return ret, nil
15307	// {
15308	//   "description": "Gets one account permission group by ID.",
15309	//   "flatPath": "userprofiles/{profileId}/accountPermissionGroups/{id}",
15310	//   "httpMethod": "GET",
15311	//   "id": "dfareporting.accountPermissionGroups.get",
15312	//   "parameterOrder": [
15313	//     "profileId",
15314	//     "id"
15315	//   ],
15316	//   "parameters": {
15317	//     "id": {
15318	//       "description": "Account permission group ID.",
15319	//       "format": "int64",
15320	//       "location": "path",
15321	//       "required": true,
15322	//       "type": "string"
15323	//     },
15324	//     "profileId": {
15325	//       "description": "User profile ID associated with this request.",
15326	//       "format": "int64",
15327	//       "location": "path",
15328	//       "required": true,
15329	//       "type": "string"
15330	//     }
15331	//   },
15332	//   "path": "userprofiles/{profileId}/accountPermissionGroups/{id}",
15333	//   "response": {
15334	//     "$ref": "AccountPermissionGroup"
15335	//   },
15336	//   "scopes": [
15337	//     "https://www.googleapis.com/auth/dfatrafficking"
15338	//   ]
15339	// }
15340
15341}
15342
15343// method id "dfareporting.accountPermissionGroups.list":
15344
15345type AccountPermissionGroupsListCall struct {
15346	s            *Service
15347	profileId    int64
15348	urlParams_   gensupport.URLParams
15349	ifNoneMatch_ string
15350	ctx_         context.Context
15351	header_      http.Header
15352}
15353
15354// List: Retrieves the list of account permission groups.
15355//
15356// - profileId: User profile ID associated with this request.
15357func (r *AccountPermissionGroupsService) List(profileId int64) *AccountPermissionGroupsListCall {
15358	c := &AccountPermissionGroupsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
15359	c.profileId = profileId
15360	return c
15361}
15362
15363// Fields allows partial responses to be retrieved. See
15364// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
15365// for more information.
15366func (c *AccountPermissionGroupsListCall) Fields(s ...googleapi.Field) *AccountPermissionGroupsListCall {
15367	c.urlParams_.Set("fields", googleapi.CombineFields(s))
15368	return c
15369}
15370
15371// IfNoneMatch sets the optional parameter which makes the operation
15372// fail if the object's ETag matches the given value. This is useful for
15373// getting updates only after the object has changed since the last
15374// request. Use googleapi.IsNotModified to check whether the response
15375// error from Do is the result of In-None-Match.
15376func (c *AccountPermissionGroupsListCall) IfNoneMatch(entityTag string) *AccountPermissionGroupsListCall {
15377	c.ifNoneMatch_ = entityTag
15378	return c
15379}
15380
15381// Context sets the context to be used in this call's Do method. Any
15382// pending HTTP request will be aborted if the provided context is
15383// canceled.
15384func (c *AccountPermissionGroupsListCall) Context(ctx context.Context) *AccountPermissionGroupsListCall {
15385	c.ctx_ = ctx
15386	return c
15387}
15388
15389// Header returns an http.Header that can be modified by the caller to
15390// add HTTP headers to the request.
15391func (c *AccountPermissionGroupsListCall) Header() http.Header {
15392	if c.header_ == nil {
15393		c.header_ = make(http.Header)
15394	}
15395	return c.header_
15396}
15397
15398func (c *AccountPermissionGroupsListCall) doRequest(alt string) (*http.Response, error) {
15399	reqHeaders := make(http.Header)
15400	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
15401	for k, v := range c.header_ {
15402		reqHeaders[k] = v
15403	}
15404	reqHeaders.Set("User-Agent", c.s.userAgent())
15405	if c.ifNoneMatch_ != "" {
15406		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
15407	}
15408	var body io.Reader = nil
15409	c.urlParams_.Set("alt", alt)
15410	c.urlParams_.Set("prettyPrint", "false")
15411	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/accountPermissionGroups")
15412	urls += "?" + c.urlParams_.Encode()
15413	req, err := http.NewRequest("GET", urls, body)
15414	if err != nil {
15415		return nil, err
15416	}
15417	req.Header = reqHeaders
15418	googleapi.Expand(req.URL, map[string]string{
15419		"profileId": strconv.FormatInt(c.profileId, 10),
15420	})
15421	return gensupport.SendRequest(c.ctx_, c.s.client, req)
15422}
15423
15424// Do executes the "dfareporting.accountPermissionGroups.list" call.
15425// Exactly one of *AccountPermissionGroupsListResponse or error will be
15426// non-nil. Any non-2xx status code is an error. Response headers are in
15427// either *AccountPermissionGroupsListResponse.ServerResponse.Header or
15428// (if a response was returned at all) in
15429// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
15430// whether the returned error was because http.StatusNotModified was
15431// returned.
15432func (c *AccountPermissionGroupsListCall) Do(opts ...googleapi.CallOption) (*AccountPermissionGroupsListResponse, error) {
15433	gensupport.SetOptions(c.urlParams_, opts...)
15434	res, err := c.doRequest("json")
15435	if res != nil && res.StatusCode == http.StatusNotModified {
15436		if res.Body != nil {
15437			res.Body.Close()
15438		}
15439		return nil, &googleapi.Error{
15440			Code:   res.StatusCode,
15441			Header: res.Header,
15442		}
15443	}
15444	if err != nil {
15445		return nil, err
15446	}
15447	defer googleapi.CloseBody(res)
15448	if err := googleapi.CheckResponse(res); err != nil {
15449		return nil, err
15450	}
15451	ret := &AccountPermissionGroupsListResponse{
15452		ServerResponse: googleapi.ServerResponse{
15453			Header:         res.Header,
15454			HTTPStatusCode: res.StatusCode,
15455		},
15456	}
15457	target := &ret
15458	if err := gensupport.DecodeResponse(target, res); err != nil {
15459		return nil, err
15460	}
15461	return ret, nil
15462	// {
15463	//   "description": "Retrieves the list of account permission groups.",
15464	//   "flatPath": "userprofiles/{profileId}/accountPermissionGroups",
15465	//   "httpMethod": "GET",
15466	//   "id": "dfareporting.accountPermissionGroups.list",
15467	//   "parameterOrder": [
15468	//     "profileId"
15469	//   ],
15470	//   "parameters": {
15471	//     "profileId": {
15472	//       "description": "User profile ID associated with this request.",
15473	//       "format": "int64",
15474	//       "location": "path",
15475	//       "required": true,
15476	//       "type": "string"
15477	//     }
15478	//   },
15479	//   "path": "userprofiles/{profileId}/accountPermissionGroups",
15480	//   "response": {
15481	//     "$ref": "AccountPermissionGroupsListResponse"
15482	//   },
15483	//   "scopes": [
15484	//     "https://www.googleapis.com/auth/dfatrafficking"
15485	//   ]
15486	// }
15487
15488}
15489
15490// method id "dfareporting.accountPermissions.get":
15491
15492type AccountPermissionsGetCall struct {
15493	s            *Service
15494	profileId    int64
15495	id           int64
15496	urlParams_   gensupport.URLParams
15497	ifNoneMatch_ string
15498	ctx_         context.Context
15499	header_      http.Header
15500}
15501
15502// Get: Gets one account permission by ID.
15503//
15504// - id: Account permission ID.
15505// - profileId: User profile ID associated with this request.
15506func (r *AccountPermissionsService) Get(profileId int64, id int64) *AccountPermissionsGetCall {
15507	c := &AccountPermissionsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
15508	c.profileId = profileId
15509	c.id = id
15510	return c
15511}
15512
15513// Fields allows partial responses to be retrieved. See
15514// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
15515// for more information.
15516func (c *AccountPermissionsGetCall) Fields(s ...googleapi.Field) *AccountPermissionsGetCall {
15517	c.urlParams_.Set("fields", googleapi.CombineFields(s))
15518	return c
15519}
15520
15521// IfNoneMatch sets the optional parameter which makes the operation
15522// fail if the object's ETag matches the given value. This is useful for
15523// getting updates only after the object has changed since the last
15524// request. Use googleapi.IsNotModified to check whether the response
15525// error from Do is the result of In-None-Match.
15526func (c *AccountPermissionsGetCall) IfNoneMatch(entityTag string) *AccountPermissionsGetCall {
15527	c.ifNoneMatch_ = entityTag
15528	return c
15529}
15530
15531// Context sets the context to be used in this call's Do method. Any
15532// pending HTTP request will be aborted if the provided context is
15533// canceled.
15534func (c *AccountPermissionsGetCall) Context(ctx context.Context) *AccountPermissionsGetCall {
15535	c.ctx_ = ctx
15536	return c
15537}
15538
15539// Header returns an http.Header that can be modified by the caller to
15540// add HTTP headers to the request.
15541func (c *AccountPermissionsGetCall) Header() http.Header {
15542	if c.header_ == nil {
15543		c.header_ = make(http.Header)
15544	}
15545	return c.header_
15546}
15547
15548func (c *AccountPermissionsGetCall) doRequest(alt string) (*http.Response, error) {
15549	reqHeaders := make(http.Header)
15550	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
15551	for k, v := range c.header_ {
15552		reqHeaders[k] = v
15553	}
15554	reqHeaders.Set("User-Agent", c.s.userAgent())
15555	if c.ifNoneMatch_ != "" {
15556		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
15557	}
15558	var body io.Reader = nil
15559	c.urlParams_.Set("alt", alt)
15560	c.urlParams_.Set("prettyPrint", "false")
15561	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/accountPermissions/{id}")
15562	urls += "?" + c.urlParams_.Encode()
15563	req, err := http.NewRequest("GET", urls, body)
15564	if err != nil {
15565		return nil, err
15566	}
15567	req.Header = reqHeaders
15568	googleapi.Expand(req.URL, map[string]string{
15569		"profileId": strconv.FormatInt(c.profileId, 10),
15570		"id":        strconv.FormatInt(c.id, 10),
15571	})
15572	return gensupport.SendRequest(c.ctx_, c.s.client, req)
15573}
15574
15575// Do executes the "dfareporting.accountPermissions.get" call.
15576// Exactly one of *AccountPermission or error will be non-nil. Any
15577// non-2xx status code is an error. Response headers are in either
15578// *AccountPermission.ServerResponse.Header or (if a response was
15579// returned at all) in error.(*googleapi.Error).Header. Use
15580// googleapi.IsNotModified to check whether the returned error was
15581// because http.StatusNotModified was returned.
15582func (c *AccountPermissionsGetCall) Do(opts ...googleapi.CallOption) (*AccountPermission, error) {
15583	gensupport.SetOptions(c.urlParams_, opts...)
15584	res, err := c.doRequest("json")
15585	if res != nil && res.StatusCode == http.StatusNotModified {
15586		if res.Body != nil {
15587			res.Body.Close()
15588		}
15589		return nil, &googleapi.Error{
15590			Code:   res.StatusCode,
15591			Header: res.Header,
15592		}
15593	}
15594	if err != nil {
15595		return nil, err
15596	}
15597	defer googleapi.CloseBody(res)
15598	if err := googleapi.CheckResponse(res); err != nil {
15599		return nil, err
15600	}
15601	ret := &AccountPermission{
15602		ServerResponse: googleapi.ServerResponse{
15603			Header:         res.Header,
15604			HTTPStatusCode: res.StatusCode,
15605		},
15606	}
15607	target := &ret
15608	if err := gensupport.DecodeResponse(target, res); err != nil {
15609		return nil, err
15610	}
15611	return ret, nil
15612	// {
15613	//   "description": "Gets one account permission by ID.",
15614	//   "flatPath": "userprofiles/{profileId}/accountPermissions/{id}",
15615	//   "httpMethod": "GET",
15616	//   "id": "dfareporting.accountPermissions.get",
15617	//   "parameterOrder": [
15618	//     "profileId",
15619	//     "id"
15620	//   ],
15621	//   "parameters": {
15622	//     "id": {
15623	//       "description": "Account permission ID.",
15624	//       "format": "int64",
15625	//       "location": "path",
15626	//       "required": true,
15627	//       "type": "string"
15628	//     },
15629	//     "profileId": {
15630	//       "description": "User profile ID associated with this request.",
15631	//       "format": "int64",
15632	//       "location": "path",
15633	//       "required": true,
15634	//       "type": "string"
15635	//     }
15636	//   },
15637	//   "path": "userprofiles/{profileId}/accountPermissions/{id}",
15638	//   "response": {
15639	//     "$ref": "AccountPermission"
15640	//   },
15641	//   "scopes": [
15642	//     "https://www.googleapis.com/auth/dfatrafficking"
15643	//   ]
15644	// }
15645
15646}
15647
15648// method id "dfareporting.accountPermissions.list":
15649
15650type AccountPermissionsListCall struct {
15651	s            *Service
15652	profileId    int64
15653	urlParams_   gensupport.URLParams
15654	ifNoneMatch_ string
15655	ctx_         context.Context
15656	header_      http.Header
15657}
15658
15659// List: Retrieves the list of account permissions.
15660//
15661// - profileId: User profile ID associated with this request.
15662func (r *AccountPermissionsService) List(profileId int64) *AccountPermissionsListCall {
15663	c := &AccountPermissionsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
15664	c.profileId = profileId
15665	return c
15666}
15667
15668// Fields allows partial responses to be retrieved. See
15669// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
15670// for more information.
15671func (c *AccountPermissionsListCall) Fields(s ...googleapi.Field) *AccountPermissionsListCall {
15672	c.urlParams_.Set("fields", googleapi.CombineFields(s))
15673	return c
15674}
15675
15676// IfNoneMatch sets the optional parameter which makes the operation
15677// fail if the object's ETag matches the given value. This is useful for
15678// getting updates only after the object has changed since the last
15679// request. Use googleapi.IsNotModified to check whether the response
15680// error from Do is the result of In-None-Match.
15681func (c *AccountPermissionsListCall) IfNoneMatch(entityTag string) *AccountPermissionsListCall {
15682	c.ifNoneMatch_ = entityTag
15683	return c
15684}
15685
15686// Context sets the context to be used in this call's Do method. Any
15687// pending HTTP request will be aborted if the provided context is
15688// canceled.
15689func (c *AccountPermissionsListCall) Context(ctx context.Context) *AccountPermissionsListCall {
15690	c.ctx_ = ctx
15691	return c
15692}
15693
15694// Header returns an http.Header that can be modified by the caller to
15695// add HTTP headers to the request.
15696func (c *AccountPermissionsListCall) Header() http.Header {
15697	if c.header_ == nil {
15698		c.header_ = make(http.Header)
15699	}
15700	return c.header_
15701}
15702
15703func (c *AccountPermissionsListCall) doRequest(alt string) (*http.Response, error) {
15704	reqHeaders := make(http.Header)
15705	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
15706	for k, v := range c.header_ {
15707		reqHeaders[k] = v
15708	}
15709	reqHeaders.Set("User-Agent", c.s.userAgent())
15710	if c.ifNoneMatch_ != "" {
15711		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
15712	}
15713	var body io.Reader = nil
15714	c.urlParams_.Set("alt", alt)
15715	c.urlParams_.Set("prettyPrint", "false")
15716	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/accountPermissions")
15717	urls += "?" + c.urlParams_.Encode()
15718	req, err := http.NewRequest("GET", urls, body)
15719	if err != nil {
15720		return nil, err
15721	}
15722	req.Header = reqHeaders
15723	googleapi.Expand(req.URL, map[string]string{
15724		"profileId": strconv.FormatInt(c.profileId, 10),
15725	})
15726	return gensupport.SendRequest(c.ctx_, c.s.client, req)
15727}
15728
15729// Do executes the "dfareporting.accountPermissions.list" call.
15730// Exactly one of *AccountPermissionsListResponse or error will be
15731// non-nil. Any non-2xx status code is an error. Response headers are in
15732// either *AccountPermissionsListResponse.ServerResponse.Header or (if a
15733// response was returned at all) in error.(*googleapi.Error).Header. Use
15734// googleapi.IsNotModified to check whether the returned error was
15735// because http.StatusNotModified was returned.
15736func (c *AccountPermissionsListCall) Do(opts ...googleapi.CallOption) (*AccountPermissionsListResponse, error) {
15737	gensupport.SetOptions(c.urlParams_, opts...)
15738	res, err := c.doRequest("json")
15739	if res != nil && res.StatusCode == http.StatusNotModified {
15740		if res.Body != nil {
15741			res.Body.Close()
15742		}
15743		return nil, &googleapi.Error{
15744			Code:   res.StatusCode,
15745			Header: res.Header,
15746		}
15747	}
15748	if err != nil {
15749		return nil, err
15750	}
15751	defer googleapi.CloseBody(res)
15752	if err := googleapi.CheckResponse(res); err != nil {
15753		return nil, err
15754	}
15755	ret := &AccountPermissionsListResponse{
15756		ServerResponse: googleapi.ServerResponse{
15757			Header:         res.Header,
15758			HTTPStatusCode: res.StatusCode,
15759		},
15760	}
15761	target := &ret
15762	if err := gensupport.DecodeResponse(target, res); err != nil {
15763		return nil, err
15764	}
15765	return ret, nil
15766	// {
15767	//   "description": "Retrieves the list of account permissions.",
15768	//   "flatPath": "userprofiles/{profileId}/accountPermissions",
15769	//   "httpMethod": "GET",
15770	//   "id": "dfareporting.accountPermissions.list",
15771	//   "parameterOrder": [
15772	//     "profileId"
15773	//   ],
15774	//   "parameters": {
15775	//     "profileId": {
15776	//       "description": "User profile ID associated with this request.",
15777	//       "format": "int64",
15778	//       "location": "path",
15779	//       "required": true,
15780	//       "type": "string"
15781	//     }
15782	//   },
15783	//   "path": "userprofiles/{profileId}/accountPermissions",
15784	//   "response": {
15785	//     "$ref": "AccountPermissionsListResponse"
15786	//   },
15787	//   "scopes": [
15788	//     "https://www.googleapis.com/auth/dfatrafficking"
15789	//   ]
15790	// }
15791
15792}
15793
15794// method id "dfareporting.accountUserProfiles.get":
15795
15796type AccountUserProfilesGetCall struct {
15797	s            *Service
15798	profileId    int64
15799	id           int64
15800	urlParams_   gensupport.URLParams
15801	ifNoneMatch_ string
15802	ctx_         context.Context
15803	header_      http.Header
15804}
15805
15806// Get: Gets one account user profile by ID.
15807//
15808// - id: User profile ID.
15809// - profileId: User profile ID associated with this request.
15810func (r *AccountUserProfilesService) Get(profileId int64, id int64) *AccountUserProfilesGetCall {
15811	c := &AccountUserProfilesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
15812	c.profileId = profileId
15813	c.id = id
15814	return c
15815}
15816
15817// Fields allows partial responses to be retrieved. See
15818// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
15819// for more information.
15820func (c *AccountUserProfilesGetCall) Fields(s ...googleapi.Field) *AccountUserProfilesGetCall {
15821	c.urlParams_.Set("fields", googleapi.CombineFields(s))
15822	return c
15823}
15824
15825// IfNoneMatch sets the optional parameter which makes the operation
15826// fail if the object's ETag matches the given value. This is useful for
15827// getting updates only after the object has changed since the last
15828// request. Use googleapi.IsNotModified to check whether the response
15829// error from Do is the result of In-None-Match.
15830func (c *AccountUserProfilesGetCall) IfNoneMatch(entityTag string) *AccountUserProfilesGetCall {
15831	c.ifNoneMatch_ = entityTag
15832	return c
15833}
15834
15835// Context sets the context to be used in this call's Do method. Any
15836// pending HTTP request will be aborted if the provided context is
15837// canceled.
15838func (c *AccountUserProfilesGetCall) Context(ctx context.Context) *AccountUserProfilesGetCall {
15839	c.ctx_ = ctx
15840	return c
15841}
15842
15843// Header returns an http.Header that can be modified by the caller to
15844// add HTTP headers to the request.
15845func (c *AccountUserProfilesGetCall) Header() http.Header {
15846	if c.header_ == nil {
15847		c.header_ = make(http.Header)
15848	}
15849	return c.header_
15850}
15851
15852func (c *AccountUserProfilesGetCall) doRequest(alt string) (*http.Response, error) {
15853	reqHeaders := make(http.Header)
15854	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
15855	for k, v := range c.header_ {
15856		reqHeaders[k] = v
15857	}
15858	reqHeaders.Set("User-Agent", c.s.userAgent())
15859	if c.ifNoneMatch_ != "" {
15860		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
15861	}
15862	var body io.Reader = nil
15863	c.urlParams_.Set("alt", alt)
15864	c.urlParams_.Set("prettyPrint", "false")
15865	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/accountUserProfiles/{id}")
15866	urls += "?" + c.urlParams_.Encode()
15867	req, err := http.NewRequest("GET", urls, body)
15868	if err != nil {
15869		return nil, err
15870	}
15871	req.Header = reqHeaders
15872	googleapi.Expand(req.URL, map[string]string{
15873		"profileId": strconv.FormatInt(c.profileId, 10),
15874		"id":        strconv.FormatInt(c.id, 10),
15875	})
15876	return gensupport.SendRequest(c.ctx_, c.s.client, req)
15877}
15878
15879// Do executes the "dfareporting.accountUserProfiles.get" call.
15880// Exactly one of *AccountUserProfile or error will be non-nil. Any
15881// non-2xx status code is an error. Response headers are in either
15882// *AccountUserProfile.ServerResponse.Header or (if a response was
15883// returned at all) in error.(*googleapi.Error).Header. Use
15884// googleapi.IsNotModified to check whether the returned error was
15885// because http.StatusNotModified was returned.
15886func (c *AccountUserProfilesGetCall) Do(opts ...googleapi.CallOption) (*AccountUserProfile, error) {
15887	gensupport.SetOptions(c.urlParams_, opts...)
15888	res, err := c.doRequest("json")
15889	if res != nil && res.StatusCode == http.StatusNotModified {
15890		if res.Body != nil {
15891			res.Body.Close()
15892		}
15893		return nil, &googleapi.Error{
15894			Code:   res.StatusCode,
15895			Header: res.Header,
15896		}
15897	}
15898	if err != nil {
15899		return nil, err
15900	}
15901	defer googleapi.CloseBody(res)
15902	if err := googleapi.CheckResponse(res); err != nil {
15903		return nil, err
15904	}
15905	ret := &AccountUserProfile{
15906		ServerResponse: googleapi.ServerResponse{
15907			Header:         res.Header,
15908			HTTPStatusCode: res.StatusCode,
15909		},
15910	}
15911	target := &ret
15912	if err := gensupport.DecodeResponse(target, res); err != nil {
15913		return nil, err
15914	}
15915	return ret, nil
15916	// {
15917	//   "description": "Gets one account user profile by ID.",
15918	//   "flatPath": "userprofiles/{profileId}/accountUserProfiles/{id}",
15919	//   "httpMethod": "GET",
15920	//   "id": "dfareporting.accountUserProfiles.get",
15921	//   "parameterOrder": [
15922	//     "profileId",
15923	//     "id"
15924	//   ],
15925	//   "parameters": {
15926	//     "id": {
15927	//       "description": "User profile ID.",
15928	//       "format": "int64",
15929	//       "location": "path",
15930	//       "required": true,
15931	//       "type": "string"
15932	//     },
15933	//     "profileId": {
15934	//       "description": "User profile ID associated with this request.",
15935	//       "format": "int64",
15936	//       "location": "path",
15937	//       "required": true,
15938	//       "type": "string"
15939	//     }
15940	//   },
15941	//   "path": "userprofiles/{profileId}/accountUserProfiles/{id}",
15942	//   "response": {
15943	//     "$ref": "AccountUserProfile"
15944	//   },
15945	//   "scopes": [
15946	//     "https://www.googleapis.com/auth/dfatrafficking"
15947	//   ]
15948	// }
15949
15950}
15951
15952// method id "dfareporting.accountUserProfiles.insert":
15953
15954type AccountUserProfilesInsertCall struct {
15955	s                  *Service
15956	profileId          int64
15957	accountuserprofile *AccountUserProfile
15958	urlParams_         gensupport.URLParams
15959	ctx_               context.Context
15960	header_            http.Header
15961}
15962
15963// Insert: Inserts a new account user profile.
15964//
15965// - profileId: User profile ID associated with this request.
15966func (r *AccountUserProfilesService) Insert(profileId int64, accountuserprofile *AccountUserProfile) *AccountUserProfilesInsertCall {
15967	c := &AccountUserProfilesInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
15968	c.profileId = profileId
15969	c.accountuserprofile = accountuserprofile
15970	return c
15971}
15972
15973// Fields allows partial responses to be retrieved. See
15974// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
15975// for more information.
15976func (c *AccountUserProfilesInsertCall) Fields(s ...googleapi.Field) *AccountUserProfilesInsertCall {
15977	c.urlParams_.Set("fields", googleapi.CombineFields(s))
15978	return c
15979}
15980
15981// Context sets the context to be used in this call's Do method. Any
15982// pending HTTP request will be aborted if the provided context is
15983// canceled.
15984func (c *AccountUserProfilesInsertCall) Context(ctx context.Context) *AccountUserProfilesInsertCall {
15985	c.ctx_ = ctx
15986	return c
15987}
15988
15989// Header returns an http.Header that can be modified by the caller to
15990// add HTTP headers to the request.
15991func (c *AccountUserProfilesInsertCall) Header() http.Header {
15992	if c.header_ == nil {
15993		c.header_ = make(http.Header)
15994	}
15995	return c.header_
15996}
15997
15998func (c *AccountUserProfilesInsertCall) doRequest(alt string) (*http.Response, error) {
15999	reqHeaders := make(http.Header)
16000	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
16001	for k, v := range c.header_ {
16002		reqHeaders[k] = v
16003	}
16004	reqHeaders.Set("User-Agent", c.s.userAgent())
16005	var body io.Reader = nil
16006	body, err := googleapi.WithoutDataWrapper.JSONReader(c.accountuserprofile)
16007	if err != nil {
16008		return nil, err
16009	}
16010	reqHeaders.Set("Content-Type", "application/json")
16011	c.urlParams_.Set("alt", alt)
16012	c.urlParams_.Set("prettyPrint", "false")
16013	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/accountUserProfiles")
16014	urls += "?" + c.urlParams_.Encode()
16015	req, err := http.NewRequest("POST", urls, body)
16016	if err != nil {
16017		return nil, err
16018	}
16019	req.Header = reqHeaders
16020	googleapi.Expand(req.URL, map[string]string{
16021		"profileId": strconv.FormatInt(c.profileId, 10),
16022	})
16023	return gensupport.SendRequest(c.ctx_, c.s.client, req)
16024}
16025
16026// Do executes the "dfareporting.accountUserProfiles.insert" call.
16027// Exactly one of *AccountUserProfile or error will be non-nil. Any
16028// non-2xx status code is an error. Response headers are in either
16029// *AccountUserProfile.ServerResponse.Header or (if a response was
16030// returned at all) in error.(*googleapi.Error).Header. Use
16031// googleapi.IsNotModified to check whether the returned error was
16032// because http.StatusNotModified was returned.
16033func (c *AccountUserProfilesInsertCall) Do(opts ...googleapi.CallOption) (*AccountUserProfile, error) {
16034	gensupport.SetOptions(c.urlParams_, opts...)
16035	res, err := c.doRequest("json")
16036	if res != nil && res.StatusCode == http.StatusNotModified {
16037		if res.Body != nil {
16038			res.Body.Close()
16039		}
16040		return nil, &googleapi.Error{
16041			Code:   res.StatusCode,
16042			Header: res.Header,
16043		}
16044	}
16045	if err != nil {
16046		return nil, err
16047	}
16048	defer googleapi.CloseBody(res)
16049	if err := googleapi.CheckResponse(res); err != nil {
16050		return nil, err
16051	}
16052	ret := &AccountUserProfile{
16053		ServerResponse: googleapi.ServerResponse{
16054			Header:         res.Header,
16055			HTTPStatusCode: res.StatusCode,
16056		},
16057	}
16058	target := &ret
16059	if err := gensupport.DecodeResponse(target, res); err != nil {
16060		return nil, err
16061	}
16062	return ret, nil
16063	// {
16064	//   "description": "Inserts a new account user profile.",
16065	//   "flatPath": "userprofiles/{profileId}/accountUserProfiles",
16066	//   "httpMethod": "POST",
16067	//   "id": "dfareporting.accountUserProfiles.insert",
16068	//   "parameterOrder": [
16069	//     "profileId"
16070	//   ],
16071	//   "parameters": {
16072	//     "profileId": {
16073	//       "description": "User profile ID associated with this request.",
16074	//       "format": "int64",
16075	//       "location": "path",
16076	//       "required": true,
16077	//       "type": "string"
16078	//     }
16079	//   },
16080	//   "path": "userprofiles/{profileId}/accountUserProfiles",
16081	//   "request": {
16082	//     "$ref": "AccountUserProfile"
16083	//   },
16084	//   "response": {
16085	//     "$ref": "AccountUserProfile"
16086	//   },
16087	//   "scopes": [
16088	//     "https://www.googleapis.com/auth/dfatrafficking"
16089	//   ]
16090	// }
16091
16092}
16093
16094// method id "dfareporting.accountUserProfiles.list":
16095
16096type AccountUserProfilesListCall struct {
16097	s            *Service
16098	profileId    int64
16099	urlParams_   gensupport.URLParams
16100	ifNoneMatch_ string
16101	ctx_         context.Context
16102	header_      http.Header
16103}
16104
16105// List: Retrieves a list of account user profiles, possibly filtered.
16106// This method supports paging.
16107//
16108// - profileId: User profile ID associated with this request.
16109func (r *AccountUserProfilesService) List(profileId int64) *AccountUserProfilesListCall {
16110	c := &AccountUserProfilesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
16111	c.profileId = profileId
16112	return c
16113}
16114
16115// Active sets the optional parameter "active": Select only active user
16116// profiles.
16117func (c *AccountUserProfilesListCall) Active(active bool) *AccountUserProfilesListCall {
16118	c.urlParams_.Set("active", fmt.Sprint(active))
16119	return c
16120}
16121
16122// Ids sets the optional parameter "ids": Select only user profiles with
16123// these IDs.
16124func (c *AccountUserProfilesListCall) Ids(ids ...int64) *AccountUserProfilesListCall {
16125	var ids_ []string
16126	for _, v := range ids {
16127		ids_ = append(ids_, fmt.Sprint(v))
16128	}
16129	c.urlParams_.SetMulti("ids", ids_)
16130	return c
16131}
16132
16133// MaxResults sets the optional parameter "maxResults": Maximum number
16134// of results to return.
16135func (c *AccountUserProfilesListCall) MaxResults(maxResults int64) *AccountUserProfilesListCall {
16136	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
16137	return c
16138}
16139
16140// PageToken sets the optional parameter "pageToken": Value of the
16141// nextPageToken from the previous result page.
16142func (c *AccountUserProfilesListCall) PageToken(pageToken string) *AccountUserProfilesListCall {
16143	c.urlParams_.Set("pageToken", pageToken)
16144	return c
16145}
16146
16147// SearchString sets the optional parameter "searchString": Allows
16148// searching for objects by name, ID or email. Wildcards (*) are
16149// allowed. For example, "user profile*2015" will return objects with
16150// names like "user profile June 2015", "user profile April 2015", or
16151// simply "user profile 2015". Most of the searches also add wildcards
16152// implicitly at the start and the end of the search string. For
16153// example, a search string of "user profile" will match objects with
16154// name "my user profile", "user profile 2015", or simply "user
16155// profile".
16156func (c *AccountUserProfilesListCall) SearchString(searchString string) *AccountUserProfilesListCall {
16157	c.urlParams_.Set("searchString", searchString)
16158	return c
16159}
16160
16161// SortField sets the optional parameter "sortField": Field by which to
16162// sort the list.
16163//
16164// Possible values:
16165//   "ID" (default)
16166//   "NAME"
16167func (c *AccountUserProfilesListCall) SortField(sortField string) *AccountUserProfilesListCall {
16168	c.urlParams_.Set("sortField", sortField)
16169	return c
16170}
16171
16172// SortOrder sets the optional parameter "sortOrder": Order of sorted
16173// results.
16174//
16175// Possible values:
16176//   "ASCENDING" (default)
16177//   "DESCENDING"
16178func (c *AccountUserProfilesListCall) SortOrder(sortOrder string) *AccountUserProfilesListCall {
16179	c.urlParams_.Set("sortOrder", sortOrder)
16180	return c
16181}
16182
16183// SubaccountId sets the optional parameter "subaccountId": Select only
16184// user profiles with the specified subaccount ID.
16185func (c *AccountUserProfilesListCall) SubaccountId(subaccountId int64) *AccountUserProfilesListCall {
16186	c.urlParams_.Set("subaccountId", fmt.Sprint(subaccountId))
16187	return c
16188}
16189
16190// UserRoleId sets the optional parameter "userRoleId": Select only user
16191// profiles with the specified user role ID.
16192func (c *AccountUserProfilesListCall) UserRoleId(userRoleId int64) *AccountUserProfilesListCall {
16193	c.urlParams_.Set("userRoleId", fmt.Sprint(userRoleId))
16194	return c
16195}
16196
16197// Fields allows partial responses to be retrieved. See
16198// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
16199// for more information.
16200func (c *AccountUserProfilesListCall) Fields(s ...googleapi.Field) *AccountUserProfilesListCall {
16201	c.urlParams_.Set("fields", googleapi.CombineFields(s))
16202	return c
16203}
16204
16205// IfNoneMatch sets the optional parameter which makes the operation
16206// fail if the object's ETag matches the given value. This is useful for
16207// getting updates only after the object has changed since the last
16208// request. Use googleapi.IsNotModified to check whether the response
16209// error from Do is the result of In-None-Match.
16210func (c *AccountUserProfilesListCall) IfNoneMatch(entityTag string) *AccountUserProfilesListCall {
16211	c.ifNoneMatch_ = entityTag
16212	return c
16213}
16214
16215// Context sets the context to be used in this call's Do method. Any
16216// pending HTTP request will be aborted if the provided context is
16217// canceled.
16218func (c *AccountUserProfilesListCall) Context(ctx context.Context) *AccountUserProfilesListCall {
16219	c.ctx_ = ctx
16220	return c
16221}
16222
16223// Header returns an http.Header that can be modified by the caller to
16224// add HTTP headers to the request.
16225func (c *AccountUserProfilesListCall) Header() http.Header {
16226	if c.header_ == nil {
16227		c.header_ = make(http.Header)
16228	}
16229	return c.header_
16230}
16231
16232func (c *AccountUserProfilesListCall) doRequest(alt string) (*http.Response, error) {
16233	reqHeaders := make(http.Header)
16234	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
16235	for k, v := range c.header_ {
16236		reqHeaders[k] = v
16237	}
16238	reqHeaders.Set("User-Agent", c.s.userAgent())
16239	if c.ifNoneMatch_ != "" {
16240		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
16241	}
16242	var body io.Reader = nil
16243	c.urlParams_.Set("alt", alt)
16244	c.urlParams_.Set("prettyPrint", "false")
16245	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/accountUserProfiles")
16246	urls += "?" + c.urlParams_.Encode()
16247	req, err := http.NewRequest("GET", urls, body)
16248	if err != nil {
16249		return nil, err
16250	}
16251	req.Header = reqHeaders
16252	googleapi.Expand(req.URL, map[string]string{
16253		"profileId": strconv.FormatInt(c.profileId, 10),
16254	})
16255	return gensupport.SendRequest(c.ctx_, c.s.client, req)
16256}
16257
16258// Do executes the "dfareporting.accountUserProfiles.list" call.
16259// Exactly one of *AccountUserProfilesListResponse or error will be
16260// non-nil. Any non-2xx status code is an error. Response headers are in
16261// either *AccountUserProfilesListResponse.ServerResponse.Header or (if
16262// a response was returned at all) in error.(*googleapi.Error).Header.
16263// Use googleapi.IsNotModified to check whether the returned error was
16264// because http.StatusNotModified was returned.
16265func (c *AccountUserProfilesListCall) Do(opts ...googleapi.CallOption) (*AccountUserProfilesListResponse, error) {
16266	gensupport.SetOptions(c.urlParams_, opts...)
16267	res, err := c.doRequest("json")
16268	if res != nil && res.StatusCode == http.StatusNotModified {
16269		if res.Body != nil {
16270			res.Body.Close()
16271		}
16272		return nil, &googleapi.Error{
16273			Code:   res.StatusCode,
16274			Header: res.Header,
16275		}
16276	}
16277	if err != nil {
16278		return nil, err
16279	}
16280	defer googleapi.CloseBody(res)
16281	if err := googleapi.CheckResponse(res); err != nil {
16282		return nil, err
16283	}
16284	ret := &AccountUserProfilesListResponse{
16285		ServerResponse: googleapi.ServerResponse{
16286			Header:         res.Header,
16287			HTTPStatusCode: res.StatusCode,
16288		},
16289	}
16290	target := &ret
16291	if err := gensupport.DecodeResponse(target, res); err != nil {
16292		return nil, err
16293	}
16294	return ret, nil
16295	// {
16296	//   "description": "Retrieves a list of account user profiles, possibly filtered. This method supports paging.",
16297	//   "flatPath": "userprofiles/{profileId}/accountUserProfiles",
16298	//   "httpMethod": "GET",
16299	//   "id": "dfareporting.accountUserProfiles.list",
16300	//   "parameterOrder": [
16301	//     "profileId"
16302	//   ],
16303	//   "parameters": {
16304	//     "active": {
16305	//       "description": "Select only active user profiles.",
16306	//       "location": "query",
16307	//       "type": "boolean"
16308	//     },
16309	//     "ids": {
16310	//       "description": "Select only user profiles with these IDs.",
16311	//       "format": "int64",
16312	//       "location": "query",
16313	//       "repeated": true,
16314	//       "type": "string"
16315	//     },
16316	//     "maxResults": {
16317	//       "default": "1000",
16318	//       "description": "Maximum number of results to return.",
16319	//       "format": "int32",
16320	//       "location": "query",
16321	//       "maximum": "1000",
16322	//       "minimum": "0",
16323	//       "type": "integer"
16324	//     },
16325	//     "pageToken": {
16326	//       "description": "Value of the nextPageToken from the previous result page.",
16327	//       "location": "query",
16328	//       "type": "string"
16329	//     },
16330	//     "profileId": {
16331	//       "description": "User profile ID associated with this request.",
16332	//       "format": "int64",
16333	//       "location": "path",
16334	//       "required": true,
16335	//       "type": "string"
16336	//     },
16337	//     "searchString": {
16338	//       "description": "Allows searching for objects by name, ID or email. Wildcards (*) are allowed. For example, \"user profile*2015\" will return objects with names like \"user profile June 2015\", \"user profile April 2015\", or simply \"user profile 2015\". Most of the searches also add wildcards implicitly at the start and the end of the search string. For example, a search string of \"user profile\" will match objects with name \"my user profile\", \"user profile 2015\", or simply \"user profile\".",
16339	//       "location": "query",
16340	//       "type": "string"
16341	//     },
16342	//     "sortField": {
16343	//       "default": "ID",
16344	//       "description": "Field by which to sort the list.",
16345	//       "enum": [
16346	//         "ID",
16347	//         "NAME"
16348	//       ],
16349	//       "enumDescriptions": [
16350	//         "",
16351	//         ""
16352	//       ],
16353	//       "location": "query",
16354	//       "type": "string"
16355	//     },
16356	//     "sortOrder": {
16357	//       "default": "ASCENDING",
16358	//       "description": "Order of sorted results.",
16359	//       "enum": [
16360	//         "ASCENDING",
16361	//         "DESCENDING"
16362	//       ],
16363	//       "enumDescriptions": [
16364	//         "",
16365	//         ""
16366	//       ],
16367	//       "location": "query",
16368	//       "type": "string"
16369	//     },
16370	//     "subaccountId": {
16371	//       "description": "Select only user profiles with the specified subaccount ID.",
16372	//       "format": "int64",
16373	//       "location": "query",
16374	//       "type": "string"
16375	//     },
16376	//     "userRoleId": {
16377	//       "description": "Select only user profiles with the specified user role ID.",
16378	//       "format": "int64",
16379	//       "location": "query",
16380	//       "type": "string"
16381	//     }
16382	//   },
16383	//   "path": "userprofiles/{profileId}/accountUserProfiles",
16384	//   "response": {
16385	//     "$ref": "AccountUserProfilesListResponse"
16386	//   },
16387	//   "scopes": [
16388	//     "https://www.googleapis.com/auth/dfatrafficking"
16389	//   ]
16390	// }
16391
16392}
16393
16394// Pages invokes f for each page of results.
16395// A non-nil error returned from f will halt the iteration.
16396// The provided context supersedes any context provided to the Context method.
16397func (c *AccountUserProfilesListCall) Pages(ctx context.Context, f func(*AccountUserProfilesListResponse) error) error {
16398	c.ctx_ = ctx
16399	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
16400	for {
16401		x, err := c.Do()
16402		if err != nil {
16403			return err
16404		}
16405		if err := f(x); err != nil {
16406			return err
16407		}
16408		if x.NextPageToken == "" {
16409			return nil
16410		}
16411		c.PageToken(x.NextPageToken)
16412	}
16413}
16414
16415// method id "dfareporting.accountUserProfiles.patch":
16416
16417type AccountUserProfilesPatchCall struct {
16418	s                  *Service
16419	profileId          int64
16420	accountuserprofile *AccountUserProfile
16421	urlParams_         gensupport.URLParams
16422	ctx_               context.Context
16423	header_            http.Header
16424}
16425
16426// Patch: Updates an existing account user profile. This method supports
16427// patch semantics.
16428//
16429// - id: AccountUserProfile ID.
16430// - profileId: User profile ID associated with this request.
16431func (r *AccountUserProfilesService) Patch(profileId int64, id int64, accountuserprofile *AccountUserProfile) *AccountUserProfilesPatchCall {
16432	c := &AccountUserProfilesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
16433	c.profileId = profileId
16434	c.urlParams_.Set("id", fmt.Sprint(id))
16435	c.accountuserprofile = accountuserprofile
16436	return c
16437}
16438
16439// Fields allows partial responses to be retrieved. See
16440// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
16441// for more information.
16442func (c *AccountUserProfilesPatchCall) Fields(s ...googleapi.Field) *AccountUserProfilesPatchCall {
16443	c.urlParams_.Set("fields", googleapi.CombineFields(s))
16444	return c
16445}
16446
16447// Context sets the context to be used in this call's Do method. Any
16448// pending HTTP request will be aborted if the provided context is
16449// canceled.
16450func (c *AccountUserProfilesPatchCall) Context(ctx context.Context) *AccountUserProfilesPatchCall {
16451	c.ctx_ = ctx
16452	return c
16453}
16454
16455// Header returns an http.Header that can be modified by the caller to
16456// add HTTP headers to the request.
16457func (c *AccountUserProfilesPatchCall) Header() http.Header {
16458	if c.header_ == nil {
16459		c.header_ = make(http.Header)
16460	}
16461	return c.header_
16462}
16463
16464func (c *AccountUserProfilesPatchCall) doRequest(alt string) (*http.Response, error) {
16465	reqHeaders := make(http.Header)
16466	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
16467	for k, v := range c.header_ {
16468		reqHeaders[k] = v
16469	}
16470	reqHeaders.Set("User-Agent", c.s.userAgent())
16471	var body io.Reader = nil
16472	body, err := googleapi.WithoutDataWrapper.JSONReader(c.accountuserprofile)
16473	if err != nil {
16474		return nil, err
16475	}
16476	reqHeaders.Set("Content-Type", "application/json")
16477	c.urlParams_.Set("alt", alt)
16478	c.urlParams_.Set("prettyPrint", "false")
16479	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/accountUserProfiles")
16480	urls += "?" + c.urlParams_.Encode()
16481	req, err := http.NewRequest("PATCH", urls, body)
16482	if err != nil {
16483		return nil, err
16484	}
16485	req.Header = reqHeaders
16486	googleapi.Expand(req.URL, map[string]string{
16487		"profileId": strconv.FormatInt(c.profileId, 10),
16488	})
16489	return gensupport.SendRequest(c.ctx_, c.s.client, req)
16490}
16491
16492// Do executes the "dfareporting.accountUserProfiles.patch" call.
16493// Exactly one of *AccountUserProfile or error will be non-nil. Any
16494// non-2xx status code is an error. Response headers are in either
16495// *AccountUserProfile.ServerResponse.Header or (if a response was
16496// returned at all) in error.(*googleapi.Error).Header. Use
16497// googleapi.IsNotModified to check whether the returned error was
16498// because http.StatusNotModified was returned.
16499func (c *AccountUserProfilesPatchCall) Do(opts ...googleapi.CallOption) (*AccountUserProfile, error) {
16500	gensupport.SetOptions(c.urlParams_, opts...)
16501	res, err := c.doRequest("json")
16502	if res != nil && res.StatusCode == http.StatusNotModified {
16503		if res.Body != nil {
16504			res.Body.Close()
16505		}
16506		return nil, &googleapi.Error{
16507			Code:   res.StatusCode,
16508			Header: res.Header,
16509		}
16510	}
16511	if err != nil {
16512		return nil, err
16513	}
16514	defer googleapi.CloseBody(res)
16515	if err := googleapi.CheckResponse(res); err != nil {
16516		return nil, err
16517	}
16518	ret := &AccountUserProfile{
16519		ServerResponse: googleapi.ServerResponse{
16520			Header:         res.Header,
16521			HTTPStatusCode: res.StatusCode,
16522		},
16523	}
16524	target := &ret
16525	if err := gensupport.DecodeResponse(target, res); err != nil {
16526		return nil, err
16527	}
16528	return ret, nil
16529	// {
16530	//   "description": "Updates an existing account user profile. This method supports patch semantics.",
16531	//   "flatPath": "userprofiles/{profileId}/accountUserProfiles",
16532	//   "httpMethod": "PATCH",
16533	//   "id": "dfareporting.accountUserProfiles.patch",
16534	//   "parameterOrder": [
16535	//     "profileId",
16536	//     "id"
16537	//   ],
16538	//   "parameters": {
16539	//     "id": {
16540	//       "description": "AccountUserProfile ID.",
16541	//       "format": "int64",
16542	//       "location": "query",
16543	//       "required": true,
16544	//       "type": "string"
16545	//     },
16546	//     "profileId": {
16547	//       "description": "User profile ID associated with this request.",
16548	//       "format": "int64",
16549	//       "location": "path",
16550	//       "required": true,
16551	//       "type": "string"
16552	//     }
16553	//   },
16554	//   "path": "userprofiles/{profileId}/accountUserProfiles",
16555	//   "request": {
16556	//     "$ref": "AccountUserProfile"
16557	//   },
16558	//   "response": {
16559	//     "$ref": "AccountUserProfile"
16560	//   },
16561	//   "scopes": [
16562	//     "https://www.googleapis.com/auth/dfatrafficking"
16563	//   ]
16564	// }
16565
16566}
16567
16568// method id "dfareporting.accountUserProfiles.update":
16569
16570type AccountUserProfilesUpdateCall struct {
16571	s                  *Service
16572	profileId          int64
16573	accountuserprofile *AccountUserProfile
16574	urlParams_         gensupport.URLParams
16575	ctx_               context.Context
16576	header_            http.Header
16577}
16578
16579// Update: Updates an existing account user profile.
16580//
16581// - profileId: User profile ID associated with this request.
16582func (r *AccountUserProfilesService) Update(profileId int64, accountuserprofile *AccountUserProfile) *AccountUserProfilesUpdateCall {
16583	c := &AccountUserProfilesUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
16584	c.profileId = profileId
16585	c.accountuserprofile = accountuserprofile
16586	return c
16587}
16588
16589// Fields allows partial responses to be retrieved. See
16590// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
16591// for more information.
16592func (c *AccountUserProfilesUpdateCall) Fields(s ...googleapi.Field) *AccountUserProfilesUpdateCall {
16593	c.urlParams_.Set("fields", googleapi.CombineFields(s))
16594	return c
16595}
16596
16597// Context sets the context to be used in this call's Do method. Any
16598// pending HTTP request will be aborted if the provided context is
16599// canceled.
16600func (c *AccountUserProfilesUpdateCall) Context(ctx context.Context) *AccountUserProfilesUpdateCall {
16601	c.ctx_ = ctx
16602	return c
16603}
16604
16605// Header returns an http.Header that can be modified by the caller to
16606// add HTTP headers to the request.
16607func (c *AccountUserProfilesUpdateCall) Header() http.Header {
16608	if c.header_ == nil {
16609		c.header_ = make(http.Header)
16610	}
16611	return c.header_
16612}
16613
16614func (c *AccountUserProfilesUpdateCall) doRequest(alt string) (*http.Response, error) {
16615	reqHeaders := make(http.Header)
16616	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
16617	for k, v := range c.header_ {
16618		reqHeaders[k] = v
16619	}
16620	reqHeaders.Set("User-Agent", c.s.userAgent())
16621	var body io.Reader = nil
16622	body, err := googleapi.WithoutDataWrapper.JSONReader(c.accountuserprofile)
16623	if err != nil {
16624		return nil, err
16625	}
16626	reqHeaders.Set("Content-Type", "application/json")
16627	c.urlParams_.Set("alt", alt)
16628	c.urlParams_.Set("prettyPrint", "false")
16629	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/accountUserProfiles")
16630	urls += "?" + c.urlParams_.Encode()
16631	req, err := http.NewRequest("PUT", urls, body)
16632	if err != nil {
16633		return nil, err
16634	}
16635	req.Header = reqHeaders
16636	googleapi.Expand(req.URL, map[string]string{
16637		"profileId": strconv.FormatInt(c.profileId, 10),
16638	})
16639	return gensupport.SendRequest(c.ctx_, c.s.client, req)
16640}
16641
16642// Do executes the "dfareporting.accountUserProfiles.update" call.
16643// Exactly one of *AccountUserProfile or error will be non-nil. Any
16644// non-2xx status code is an error. Response headers are in either
16645// *AccountUserProfile.ServerResponse.Header or (if a response was
16646// returned at all) in error.(*googleapi.Error).Header. Use
16647// googleapi.IsNotModified to check whether the returned error was
16648// because http.StatusNotModified was returned.
16649func (c *AccountUserProfilesUpdateCall) Do(opts ...googleapi.CallOption) (*AccountUserProfile, error) {
16650	gensupport.SetOptions(c.urlParams_, opts...)
16651	res, err := c.doRequest("json")
16652	if res != nil && res.StatusCode == http.StatusNotModified {
16653		if res.Body != nil {
16654			res.Body.Close()
16655		}
16656		return nil, &googleapi.Error{
16657			Code:   res.StatusCode,
16658			Header: res.Header,
16659		}
16660	}
16661	if err != nil {
16662		return nil, err
16663	}
16664	defer googleapi.CloseBody(res)
16665	if err := googleapi.CheckResponse(res); err != nil {
16666		return nil, err
16667	}
16668	ret := &AccountUserProfile{
16669		ServerResponse: googleapi.ServerResponse{
16670			Header:         res.Header,
16671			HTTPStatusCode: res.StatusCode,
16672		},
16673	}
16674	target := &ret
16675	if err := gensupport.DecodeResponse(target, res); err != nil {
16676		return nil, err
16677	}
16678	return ret, nil
16679	// {
16680	//   "description": "Updates an existing account user profile.",
16681	//   "flatPath": "userprofiles/{profileId}/accountUserProfiles",
16682	//   "httpMethod": "PUT",
16683	//   "id": "dfareporting.accountUserProfiles.update",
16684	//   "parameterOrder": [
16685	//     "profileId"
16686	//   ],
16687	//   "parameters": {
16688	//     "profileId": {
16689	//       "description": "User profile ID associated with this request.",
16690	//       "format": "int64",
16691	//       "location": "path",
16692	//       "required": true,
16693	//       "type": "string"
16694	//     }
16695	//   },
16696	//   "path": "userprofiles/{profileId}/accountUserProfiles",
16697	//   "request": {
16698	//     "$ref": "AccountUserProfile"
16699	//   },
16700	//   "response": {
16701	//     "$ref": "AccountUserProfile"
16702	//   },
16703	//   "scopes": [
16704	//     "https://www.googleapis.com/auth/dfatrafficking"
16705	//   ]
16706	// }
16707
16708}
16709
16710// method id "dfareporting.accounts.get":
16711
16712type AccountsGetCall struct {
16713	s            *Service
16714	profileId    int64
16715	id           int64
16716	urlParams_   gensupport.URLParams
16717	ifNoneMatch_ string
16718	ctx_         context.Context
16719	header_      http.Header
16720}
16721
16722// Get: Gets one account by ID.
16723//
16724// - id: Account ID.
16725// - profileId: User profile ID associated with this request.
16726func (r *AccountsService) Get(profileId int64, id int64) *AccountsGetCall {
16727	c := &AccountsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
16728	c.profileId = profileId
16729	c.id = id
16730	return c
16731}
16732
16733// Fields allows partial responses to be retrieved. See
16734// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
16735// for more information.
16736func (c *AccountsGetCall) Fields(s ...googleapi.Field) *AccountsGetCall {
16737	c.urlParams_.Set("fields", googleapi.CombineFields(s))
16738	return c
16739}
16740
16741// IfNoneMatch sets the optional parameter which makes the operation
16742// fail if the object's ETag matches the given value. This is useful for
16743// getting updates only after the object has changed since the last
16744// request. Use googleapi.IsNotModified to check whether the response
16745// error from Do is the result of In-None-Match.
16746func (c *AccountsGetCall) IfNoneMatch(entityTag string) *AccountsGetCall {
16747	c.ifNoneMatch_ = entityTag
16748	return c
16749}
16750
16751// Context sets the context to be used in this call's Do method. Any
16752// pending HTTP request will be aborted if the provided context is
16753// canceled.
16754func (c *AccountsGetCall) Context(ctx context.Context) *AccountsGetCall {
16755	c.ctx_ = ctx
16756	return c
16757}
16758
16759// Header returns an http.Header that can be modified by the caller to
16760// add HTTP headers to the request.
16761func (c *AccountsGetCall) Header() http.Header {
16762	if c.header_ == nil {
16763		c.header_ = make(http.Header)
16764	}
16765	return c.header_
16766}
16767
16768func (c *AccountsGetCall) doRequest(alt string) (*http.Response, error) {
16769	reqHeaders := make(http.Header)
16770	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
16771	for k, v := range c.header_ {
16772		reqHeaders[k] = v
16773	}
16774	reqHeaders.Set("User-Agent", c.s.userAgent())
16775	if c.ifNoneMatch_ != "" {
16776		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
16777	}
16778	var body io.Reader = nil
16779	c.urlParams_.Set("alt", alt)
16780	c.urlParams_.Set("prettyPrint", "false")
16781	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/accounts/{id}")
16782	urls += "?" + c.urlParams_.Encode()
16783	req, err := http.NewRequest("GET", urls, body)
16784	if err != nil {
16785		return nil, err
16786	}
16787	req.Header = reqHeaders
16788	googleapi.Expand(req.URL, map[string]string{
16789		"profileId": strconv.FormatInt(c.profileId, 10),
16790		"id":        strconv.FormatInt(c.id, 10),
16791	})
16792	return gensupport.SendRequest(c.ctx_, c.s.client, req)
16793}
16794
16795// Do executes the "dfareporting.accounts.get" call.
16796// Exactly one of *Account or error will be non-nil. Any non-2xx status
16797// code is an error. Response headers are in either
16798// *Account.ServerResponse.Header or (if a response was returned at all)
16799// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to
16800// check whether the returned error was because http.StatusNotModified
16801// was returned.
16802func (c *AccountsGetCall) Do(opts ...googleapi.CallOption) (*Account, error) {
16803	gensupport.SetOptions(c.urlParams_, opts...)
16804	res, err := c.doRequest("json")
16805	if res != nil && res.StatusCode == http.StatusNotModified {
16806		if res.Body != nil {
16807			res.Body.Close()
16808		}
16809		return nil, &googleapi.Error{
16810			Code:   res.StatusCode,
16811			Header: res.Header,
16812		}
16813	}
16814	if err != nil {
16815		return nil, err
16816	}
16817	defer googleapi.CloseBody(res)
16818	if err := googleapi.CheckResponse(res); err != nil {
16819		return nil, err
16820	}
16821	ret := &Account{
16822		ServerResponse: googleapi.ServerResponse{
16823			Header:         res.Header,
16824			HTTPStatusCode: res.StatusCode,
16825		},
16826	}
16827	target := &ret
16828	if err := gensupport.DecodeResponse(target, res); err != nil {
16829		return nil, err
16830	}
16831	return ret, nil
16832	// {
16833	//   "description": "Gets one account by ID.",
16834	//   "flatPath": "userprofiles/{profileId}/accounts/{id}",
16835	//   "httpMethod": "GET",
16836	//   "id": "dfareporting.accounts.get",
16837	//   "parameterOrder": [
16838	//     "profileId",
16839	//     "id"
16840	//   ],
16841	//   "parameters": {
16842	//     "id": {
16843	//       "description": "Account ID.",
16844	//       "format": "int64",
16845	//       "location": "path",
16846	//       "required": true,
16847	//       "type": "string"
16848	//     },
16849	//     "profileId": {
16850	//       "description": "User profile ID associated with this request.",
16851	//       "format": "int64",
16852	//       "location": "path",
16853	//       "required": true,
16854	//       "type": "string"
16855	//     }
16856	//   },
16857	//   "path": "userprofiles/{profileId}/accounts/{id}",
16858	//   "response": {
16859	//     "$ref": "Account"
16860	//   },
16861	//   "scopes": [
16862	//     "https://www.googleapis.com/auth/dfatrafficking"
16863	//   ]
16864	// }
16865
16866}
16867
16868// method id "dfareporting.accounts.list":
16869
16870type AccountsListCall struct {
16871	s            *Service
16872	profileId    int64
16873	urlParams_   gensupport.URLParams
16874	ifNoneMatch_ string
16875	ctx_         context.Context
16876	header_      http.Header
16877}
16878
16879// List: Retrieves the list of accounts, possibly filtered. This method
16880// supports paging.
16881//
16882// - profileId: User profile ID associated with this request.
16883func (r *AccountsService) List(profileId int64) *AccountsListCall {
16884	c := &AccountsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
16885	c.profileId = profileId
16886	return c
16887}
16888
16889// Active sets the optional parameter "active": Select only active
16890// accounts. Don't set this field to select both active and non-active
16891// accounts.
16892func (c *AccountsListCall) Active(active bool) *AccountsListCall {
16893	c.urlParams_.Set("active", fmt.Sprint(active))
16894	return c
16895}
16896
16897// Ids sets the optional parameter "ids": Select only accounts with
16898// these IDs.
16899func (c *AccountsListCall) Ids(ids ...int64) *AccountsListCall {
16900	var ids_ []string
16901	for _, v := range ids {
16902		ids_ = append(ids_, fmt.Sprint(v))
16903	}
16904	c.urlParams_.SetMulti("ids", ids_)
16905	return c
16906}
16907
16908// MaxResults sets the optional parameter "maxResults": Maximum number
16909// of results to return.
16910func (c *AccountsListCall) MaxResults(maxResults int64) *AccountsListCall {
16911	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
16912	return c
16913}
16914
16915// PageToken sets the optional parameter "pageToken": Value of the
16916// nextPageToken from the previous result page.
16917func (c *AccountsListCall) PageToken(pageToken string) *AccountsListCall {
16918	c.urlParams_.Set("pageToken", pageToken)
16919	return c
16920}
16921
16922// SearchString sets the optional parameter "searchString": Allows
16923// searching for objects by name or ID. Wildcards (*) are allowed. For
16924// example, "account*2015" will return objects with names like "account
16925// June 2015", "account April 2015", or simply "account 2015". Most of
16926// the searches also add wildcards implicitly at the start and the end
16927// of the search string. For example, a search string of "account" will
16928// match objects with name "my account", "account 2015", or simply
16929// "account".
16930func (c *AccountsListCall) SearchString(searchString string) *AccountsListCall {
16931	c.urlParams_.Set("searchString", searchString)
16932	return c
16933}
16934
16935// SortField sets the optional parameter "sortField": Field by which to
16936// sort the list.
16937//
16938// Possible values:
16939//   "ID" (default)
16940//   "NAME"
16941func (c *AccountsListCall) SortField(sortField string) *AccountsListCall {
16942	c.urlParams_.Set("sortField", sortField)
16943	return c
16944}
16945
16946// SortOrder sets the optional parameter "sortOrder": Order of sorted
16947// results.
16948//
16949// Possible values:
16950//   "ASCENDING" (default)
16951//   "DESCENDING"
16952func (c *AccountsListCall) SortOrder(sortOrder string) *AccountsListCall {
16953	c.urlParams_.Set("sortOrder", sortOrder)
16954	return c
16955}
16956
16957// Fields allows partial responses to be retrieved. See
16958// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
16959// for more information.
16960func (c *AccountsListCall) Fields(s ...googleapi.Field) *AccountsListCall {
16961	c.urlParams_.Set("fields", googleapi.CombineFields(s))
16962	return c
16963}
16964
16965// IfNoneMatch sets the optional parameter which makes the operation
16966// fail if the object's ETag matches the given value. This is useful for
16967// getting updates only after the object has changed since the last
16968// request. Use googleapi.IsNotModified to check whether the response
16969// error from Do is the result of In-None-Match.
16970func (c *AccountsListCall) IfNoneMatch(entityTag string) *AccountsListCall {
16971	c.ifNoneMatch_ = entityTag
16972	return c
16973}
16974
16975// Context sets the context to be used in this call's Do method. Any
16976// pending HTTP request will be aborted if the provided context is
16977// canceled.
16978func (c *AccountsListCall) Context(ctx context.Context) *AccountsListCall {
16979	c.ctx_ = ctx
16980	return c
16981}
16982
16983// Header returns an http.Header that can be modified by the caller to
16984// add HTTP headers to the request.
16985func (c *AccountsListCall) Header() http.Header {
16986	if c.header_ == nil {
16987		c.header_ = make(http.Header)
16988	}
16989	return c.header_
16990}
16991
16992func (c *AccountsListCall) doRequest(alt string) (*http.Response, error) {
16993	reqHeaders := make(http.Header)
16994	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
16995	for k, v := range c.header_ {
16996		reqHeaders[k] = v
16997	}
16998	reqHeaders.Set("User-Agent", c.s.userAgent())
16999	if c.ifNoneMatch_ != "" {
17000		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
17001	}
17002	var body io.Reader = nil
17003	c.urlParams_.Set("alt", alt)
17004	c.urlParams_.Set("prettyPrint", "false")
17005	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/accounts")
17006	urls += "?" + c.urlParams_.Encode()
17007	req, err := http.NewRequest("GET", urls, body)
17008	if err != nil {
17009		return nil, err
17010	}
17011	req.Header = reqHeaders
17012	googleapi.Expand(req.URL, map[string]string{
17013		"profileId": strconv.FormatInt(c.profileId, 10),
17014	})
17015	return gensupport.SendRequest(c.ctx_, c.s.client, req)
17016}
17017
17018// Do executes the "dfareporting.accounts.list" call.
17019// Exactly one of *AccountsListResponse or error will be non-nil. Any
17020// non-2xx status code is an error. Response headers are in either
17021// *AccountsListResponse.ServerResponse.Header or (if a response was
17022// returned at all) in error.(*googleapi.Error).Header. Use
17023// googleapi.IsNotModified to check whether the returned error was
17024// because http.StatusNotModified was returned.
17025func (c *AccountsListCall) Do(opts ...googleapi.CallOption) (*AccountsListResponse, error) {
17026	gensupport.SetOptions(c.urlParams_, opts...)
17027	res, err := c.doRequest("json")
17028	if res != nil && res.StatusCode == http.StatusNotModified {
17029		if res.Body != nil {
17030			res.Body.Close()
17031		}
17032		return nil, &googleapi.Error{
17033			Code:   res.StatusCode,
17034			Header: res.Header,
17035		}
17036	}
17037	if err != nil {
17038		return nil, err
17039	}
17040	defer googleapi.CloseBody(res)
17041	if err := googleapi.CheckResponse(res); err != nil {
17042		return nil, err
17043	}
17044	ret := &AccountsListResponse{
17045		ServerResponse: googleapi.ServerResponse{
17046			Header:         res.Header,
17047			HTTPStatusCode: res.StatusCode,
17048		},
17049	}
17050	target := &ret
17051	if err := gensupport.DecodeResponse(target, res); err != nil {
17052		return nil, err
17053	}
17054	return ret, nil
17055	// {
17056	//   "description": "Retrieves the list of accounts, possibly filtered. This method supports paging.",
17057	//   "flatPath": "userprofiles/{profileId}/accounts",
17058	//   "httpMethod": "GET",
17059	//   "id": "dfareporting.accounts.list",
17060	//   "parameterOrder": [
17061	//     "profileId"
17062	//   ],
17063	//   "parameters": {
17064	//     "active": {
17065	//       "description": "Select only active accounts. Don't set this field to select both active and non-active accounts.",
17066	//       "location": "query",
17067	//       "type": "boolean"
17068	//     },
17069	//     "ids": {
17070	//       "description": "Select only accounts with these IDs.",
17071	//       "format": "int64",
17072	//       "location": "query",
17073	//       "repeated": true,
17074	//       "type": "string"
17075	//     },
17076	//     "maxResults": {
17077	//       "default": "1000",
17078	//       "description": "Maximum number of results to return.",
17079	//       "format": "int32",
17080	//       "location": "query",
17081	//       "maximum": "1000",
17082	//       "minimum": "0",
17083	//       "type": "integer"
17084	//     },
17085	//     "pageToken": {
17086	//       "description": "Value of the nextPageToken from the previous result page.",
17087	//       "location": "query",
17088	//       "type": "string"
17089	//     },
17090	//     "profileId": {
17091	//       "description": "User profile ID associated with this request.",
17092	//       "format": "int64",
17093	//       "location": "path",
17094	//       "required": true,
17095	//       "type": "string"
17096	//     },
17097	//     "searchString": {
17098	//       "description": "Allows searching for objects by name or ID. Wildcards (*) are allowed. For example, \"account*2015\" will return objects with names like \"account June 2015\", \"account April 2015\", or simply \"account 2015\". Most of the searches also add wildcards implicitly at the start and the end of the search string. For example, a search string of \"account\" will match objects with name \"my account\", \"account 2015\", or simply \"account\".",
17099	//       "location": "query",
17100	//       "type": "string"
17101	//     },
17102	//     "sortField": {
17103	//       "default": "ID",
17104	//       "description": "Field by which to sort the list.",
17105	//       "enum": [
17106	//         "ID",
17107	//         "NAME"
17108	//       ],
17109	//       "enumDescriptions": [
17110	//         "",
17111	//         ""
17112	//       ],
17113	//       "location": "query",
17114	//       "type": "string"
17115	//     },
17116	//     "sortOrder": {
17117	//       "default": "ASCENDING",
17118	//       "description": "Order of sorted results.",
17119	//       "enum": [
17120	//         "ASCENDING",
17121	//         "DESCENDING"
17122	//       ],
17123	//       "enumDescriptions": [
17124	//         "",
17125	//         ""
17126	//       ],
17127	//       "location": "query",
17128	//       "type": "string"
17129	//     }
17130	//   },
17131	//   "path": "userprofiles/{profileId}/accounts",
17132	//   "response": {
17133	//     "$ref": "AccountsListResponse"
17134	//   },
17135	//   "scopes": [
17136	//     "https://www.googleapis.com/auth/dfatrafficking"
17137	//   ]
17138	// }
17139
17140}
17141
17142// Pages invokes f for each page of results.
17143// A non-nil error returned from f will halt the iteration.
17144// The provided context supersedes any context provided to the Context method.
17145func (c *AccountsListCall) Pages(ctx context.Context, f func(*AccountsListResponse) error) error {
17146	c.ctx_ = ctx
17147	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
17148	for {
17149		x, err := c.Do()
17150		if err != nil {
17151			return err
17152		}
17153		if err := f(x); err != nil {
17154			return err
17155		}
17156		if x.NextPageToken == "" {
17157			return nil
17158		}
17159		c.PageToken(x.NextPageToken)
17160	}
17161}
17162
17163// method id "dfareporting.accounts.patch":
17164
17165type AccountsPatchCall struct {
17166	s          *Service
17167	profileId  int64
17168	account    *Account
17169	urlParams_ gensupport.URLParams
17170	ctx_       context.Context
17171	header_    http.Header
17172}
17173
17174// Patch: Updates an existing account. This method supports patch
17175// semantics.
17176//
17177// - id: Account ID.
17178// - profileId: User profile ID associated with this request.
17179func (r *AccountsService) Patch(profileId int64, id int64, account *Account) *AccountsPatchCall {
17180	c := &AccountsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
17181	c.profileId = profileId
17182	c.urlParams_.Set("id", fmt.Sprint(id))
17183	c.account = account
17184	return c
17185}
17186
17187// Fields allows partial responses to be retrieved. See
17188// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
17189// for more information.
17190func (c *AccountsPatchCall) Fields(s ...googleapi.Field) *AccountsPatchCall {
17191	c.urlParams_.Set("fields", googleapi.CombineFields(s))
17192	return c
17193}
17194
17195// Context sets the context to be used in this call's Do method. Any
17196// pending HTTP request will be aborted if the provided context is
17197// canceled.
17198func (c *AccountsPatchCall) Context(ctx context.Context) *AccountsPatchCall {
17199	c.ctx_ = ctx
17200	return c
17201}
17202
17203// Header returns an http.Header that can be modified by the caller to
17204// add HTTP headers to the request.
17205func (c *AccountsPatchCall) Header() http.Header {
17206	if c.header_ == nil {
17207		c.header_ = make(http.Header)
17208	}
17209	return c.header_
17210}
17211
17212func (c *AccountsPatchCall) doRequest(alt string) (*http.Response, error) {
17213	reqHeaders := make(http.Header)
17214	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
17215	for k, v := range c.header_ {
17216		reqHeaders[k] = v
17217	}
17218	reqHeaders.Set("User-Agent", c.s.userAgent())
17219	var body io.Reader = nil
17220	body, err := googleapi.WithoutDataWrapper.JSONReader(c.account)
17221	if err != nil {
17222		return nil, err
17223	}
17224	reqHeaders.Set("Content-Type", "application/json")
17225	c.urlParams_.Set("alt", alt)
17226	c.urlParams_.Set("prettyPrint", "false")
17227	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/accounts")
17228	urls += "?" + c.urlParams_.Encode()
17229	req, err := http.NewRequest("PATCH", urls, body)
17230	if err != nil {
17231		return nil, err
17232	}
17233	req.Header = reqHeaders
17234	googleapi.Expand(req.URL, map[string]string{
17235		"profileId": strconv.FormatInt(c.profileId, 10),
17236	})
17237	return gensupport.SendRequest(c.ctx_, c.s.client, req)
17238}
17239
17240// Do executes the "dfareporting.accounts.patch" call.
17241// Exactly one of *Account or error will be non-nil. Any non-2xx status
17242// code is an error. Response headers are in either
17243// *Account.ServerResponse.Header or (if a response was returned at all)
17244// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to
17245// check whether the returned error was because http.StatusNotModified
17246// was returned.
17247func (c *AccountsPatchCall) Do(opts ...googleapi.CallOption) (*Account, error) {
17248	gensupport.SetOptions(c.urlParams_, opts...)
17249	res, err := c.doRequest("json")
17250	if res != nil && res.StatusCode == http.StatusNotModified {
17251		if res.Body != nil {
17252			res.Body.Close()
17253		}
17254		return nil, &googleapi.Error{
17255			Code:   res.StatusCode,
17256			Header: res.Header,
17257		}
17258	}
17259	if err != nil {
17260		return nil, err
17261	}
17262	defer googleapi.CloseBody(res)
17263	if err := googleapi.CheckResponse(res); err != nil {
17264		return nil, err
17265	}
17266	ret := &Account{
17267		ServerResponse: googleapi.ServerResponse{
17268			Header:         res.Header,
17269			HTTPStatusCode: res.StatusCode,
17270		},
17271	}
17272	target := &ret
17273	if err := gensupport.DecodeResponse(target, res); err != nil {
17274		return nil, err
17275	}
17276	return ret, nil
17277	// {
17278	//   "description": "Updates an existing account. This method supports patch semantics.",
17279	//   "flatPath": "userprofiles/{profileId}/accounts",
17280	//   "httpMethod": "PATCH",
17281	//   "id": "dfareporting.accounts.patch",
17282	//   "parameterOrder": [
17283	//     "profileId",
17284	//     "id"
17285	//   ],
17286	//   "parameters": {
17287	//     "id": {
17288	//       "description": "Account ID.",
17289	//       "format": "int64",
17290	//       "location": "query",
17291	//       "required": true,
17292	//       "type": "string"
17293	//     },
17294	//     "profileId": {
17295	//       "description": "User profile ID associated with this request.",
17296	//       "format": "int64",
17297	//       "location": "path",
17298	//       "required": true,
17299	//       "type": "string"
17300	//     }
17301	//   },
17302	//   "path": "userprofiles/{profileId}/accounts",
17303	//   "request": {
17304	//     "$ref": "Account"
17305	//   },
17306	//   "response": {
17307	//     "$ref": "Account"
17308	//   },
17309	//   "scopes": [
17310	//     "https://www.googleapis.com/auth/dfatrafficking"
17311	//   ]
17312	// }
17313
17314}
17315
17316// method id "dfareporting.accounts.update":
17317
17318type AccountsUpdateCall struct {
17319	s          *Service
17320	profileId  int64
17321	account    *Account
17322	urlParams_ gensupport.URLParams
17323	ctx_       context.Context
17324	header_    http.Header
17325}
17326
17327// Update: Updates an existing account.
17328//
17329// - profileId: User profile ID associated with this request.
17330func (r *AccountsService) Update(profileId int64, account *Account) *AccountsUpdateCall {
17331	c := &AccountsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
17332	c.profileId = profileId
17333	c.account = account
17334	return c
17335}
17336
17337// Fields allows partial responses to be retrieved. See
17338// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
17339// for more information.
17340func (c *AccountsUpdateCall) Fields(s ...googleapi.Field) *AccountsUpdateCall {
17341	c.urlParams_.Set("fields", googleapi.CombineFields(s))
17342	return c
17343}
17344
17345// Context sets the context to be used in this call's Do method. Any
17346// pending HTTP request will be aborted if the provided context is
17347// canceled.
17348func (c *AccountsUpdateCall) Context(ctx context.Context) *AccountsUpdateCall {
17349	c.ctx_ = ctx
17350	return c
17351}
17352
17353// Header returns an http.Header that can be modified by the caller to
17354// add HTTP headers to the request.
17355func (c *AccountsUpdateCall) Header() http.Header {
17356	if c.header_ == nil {
17357		c.header_ = make(http.Header)
17358	}
17359	return c.header_
17360}
17361
17362func (c *AccountsUpdateCall) doRequest(alt string) (*http.Response, error) {
17363	reqHeaders := make(http.Header)
17364	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
17365	for k, v := range c.header_ {
17366		reqHeaders[k] = v
17367	}
17368	reqHeaders.Set("User-Agent", c.s.userAgent())
17369	var body io.Reader = nil
17370	body, err := googleapi.WithoutDataWrapper.JSONReader(c.account)
17371	if err != nil {
17372		return nil, err
17373	}
17374	reqHeaders.Set("Content-Type", "application/json")
17375	c.urlParams_.Set("alt", alt)
17376	c.urlParams_.Set("prettyPrint", "false")
17377	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/accounts")
17378	urls += "?" + c.urlParams_.Encode()
17379	req, err := http.NewRequest("PUT", urls, body)
17380	if err != nil {
17381		return nil, err
17382	}
17383	req.Header = reqHeaders
17384	googleapi.Expand(req.URL, map[string]string{
17385		"profileId": strconv.FormatInt(c.profileId, 10),
17386	})
17387	return gensupport.SendRequest(c.ctx_, c.s.client, req)
17388}
17389
17390// Do executes the "dfareporting.accounts.update" call.
17391// Exactly one of *Account or error will be non-nil. Any non-2xx status
17392// code is an error. Response headers are in either
17393// *Account.ServerResponse.Header or (if a response was returned at all)
17394// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to
17395// check whether the returned error was because http.StatusNotModified
17396// was returned.
17397func (c *AccountsUpdateCall) Do(opts ...googleapi.CallOption) (*Account, error) {
17398	gensupport.SetOptions(c.urlParams_, opts...)
17399	res, err := c.doRequest("json")
17400	if res != nil && res.StatusCode == http.StatusNotModified {
17401		if res.Body != nil {
17402			res.Body.Close()
17403		}
17404		return nil, &googleapi.Error{
17405			Code:   res.StatusCode,
17406			Header: res.Header,
17407		}
17408	}
17409	if err != nil {
17410		return nil, err
17411	}
17412	defer googleapi.CloseBody(res)
17413	if err := googleapi.CheckResponse(res); err != nil {
17414		return nil, err
17415	}
17416	ret := &Account{
17417		ServerResponse: googleapi.ServerResponse{
17418			Header:         res.Header,
17419			HTTPStatusCode: res.StatusCode,
17420		},
17421	}
17422	target := &ret
17423	if err := gensupport.DecodeResponse(target, res); err != nil {
17424		return nil, err
17425	}
17426	return ret, nil
17427	// {
17428	//   "description": "Updates an existing account.",
17429	//   "flatPath": "userprofiles/{profileId}/accounts",
17430	//   "httpMethod": "PUT",
17431	//   "id": "dfareporting.accounts.update",
17432	//   "parameterOrder": [
17433	//     "profileId"
17434	//   ],
17435	//   "parameters": {
17436	//     "profileId": {
17437	//       "description": "User profile ID associated with this request.",
17438	//       "format": "int64",
17439	//       "location": "path",
17440	//       "required": true,
17441	//       "type": "string"
17442	//     }
17443	//   },
17444	//   "path": "userprofiles/{profileId}/accounts",
17445	//   "request": {
17446	//     "$ref": "Account"
17447	//   },
17448	//   "response": {
17449	//     "$ref": "Account"
17450	//   },
17451	//   "scopes": [
17452	//     "https://www.googleapis.com/auth/dfatrafficking"
17453	//   ]
17454	// }
17455
17456}
17457
17458// method id "dfareporting.ads.get":
17459
17460type AdsGetCall struct {
17461	s            *Service
17462	profileId    int64
17463	id           int64
17464	urlParams_   gensupport.URLParams
17465	ifNoneMatch_ string
17466	ctx_         context.Context
17467	header_      http.Header
17468}
17469
17470// Get: Gets one ad by ID.
17471//
17472// - id: Ad ID.
17473// - profileId: User profile ID associated with this request.
17474func (r *AdsService) Get(profileId int64, id int64) *AdsGetCall {
17475	c := &AdsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
17476	c.profileId = profileId
17477	c.id = id
17478	return c
17479}
17480
17481// Fields allows partial responses to be retrieved. See
17482// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
17483// for more information.
17484func (c *AdsGetCall) Fields(s ...googleapi.Field) *AdsGetCall {
17485	c.urlParams_.Set("fields", googleapi.CombineFields(s))
17486	return c
17487}
17488
17489// IfNoneMatch sets the optional parameter which makes the operation
17490// fail if the object's ETag matches the given value. This is useful for
17491// getting updates only after the object has changed since the last
17492// request. Use googleapi.IsNotModified to check whether the response
17493// error from Do is the result of In-None-Match.
17494func (c *AdsGetCall) IfNoneMatch(entityTag string) *AdsGetCall {
17495	c.ifNoneMatch_ = entityTag
17496	return c
17497}
17498
17499// Context sets the context to be used in this call's Do method. Any
17500// pending HTTP request will be aborted if the provided context is
17501// canceled.
17502func (c *AdsGetCall) Context(ctx context.Context) *AdsGetCall {
17503	c.ctx_ = ctx
17504	return c
17505}
17506
17507// Header returns an http.Header that can be modified by the caller to
17508// add HTTP headers to the request.
17509func (c *AdsGetCall) Header() http.Header {
17510	if c.header_ == nil {
17511		c.header_ = make(http.Header)
17512	}
17513	return c.header_
17514}
17515
17516func (c *AdsGetCall) doRequest(alt string) (*http.Response, error) {
17517	reqHeaders := make(http.Header)
17518	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
17519	for k, v := range c.header_ {
17520		reqHeaders[k] = v
17521	}
17522	reqHeaders.Set("User-Agent", c.s.userAgent())
17523	if c.ifNoneMatch_ != "" {
17524		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
17525	}
17526	var body io.Reader = nil
17527	c.urlParams_.Set("alt", alt)
17528	c.urlParams_.Set("prettyPrint", "false")
17529	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/ads/{id}")
17530	urls += "?" + c.urlParams_.Encode()
17531	req, err := http.NewRequest("GET", urls, body)
17532	if err != nil {
17533		return nil, err
17534	}
17535	req.Header = reqHeaders
17536	googleapi.Expand(req.URL, map[string]string{
17537		"profileId": strconv.FormatInt(c.profileId, 10),
17538		"id":        strconv.FormatInt(c.id, 10),
17539	})
17540	return gensupport.SendRequest(c.ctx_, c.s.client, req)
17541}
17542
17543// Do executes the "dfareporting.ads.get" call.
17544// Exactly one of *Ad or error will be non-nil. Any non-2xx status code
17545// is an error. Response headers are in either *Ad.ServerResponse.Header
17546// or (if a response was returned at all) in
17547// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
17548// whether the returned error was because http.StatusNotModified was
17549// returned.
17550func (c *AdsGetCall) Do(opts ...googleapi.CallOption) (*Ad, error) {
17551	gensupport.SetOptions(c.urlParams_, opts...)
17552	res, err := c.doRequest("json")
17553	if res != nil && res.StatusCode == http.StatusNotModified {
17554		if res.Body != nil {
17555			res.Body.Close()
17556		}
17557		return nil, &googleapi.Error{
17558			Code:   res.StatusCode,
17559			Header: res.Header,
17560		}
17561	}
17562	if err != nil {
17563		return nil, err
17564	}
17565	defer googleapi.CloseBody(res)
17566	if err := googleapi.CheckResponse(res); err != nil {
17567		return nil, err
17568	}
17569	ret := &Ad{
17570		ServerResponse: googleapi.ServerResponse{
17571			Header:         res.Header,
17572			HTTPStatusCode: res.StatusCode,
17573		},
17574	}
17575	target := &ret
17576	if err := gensupport.DecodeResponse(target, res); err != nil {
17577		return nil, err
17578	}
17579	return ret, nil
17580	// {
17581	//   "description": "Gets one ad by ID.",
17582	//   "flatPath": "userprofiles/{profileId}/ads/{id}",
17583	//   "httpMethod": "GET",
17584	//   "id": "dfareporting.ads.get",
17585	//   "parameterOrder": [
17586	//     "profileId",
17587	//     "id"
17588	//   ],
17589	//   "parameters": {
17590	//     "id": {
17591	//       "description": "Ad ID.",
17592	//       "format": "int64",
17593	//       "location": "path",
17594	//       "required": true,
17595	//       "type": "string"
17596	//     },
17597	//     "profileId": {
17598	//       "description": "User profile ID associated with this request.",
17599	//       "format": "int64",
17600	//       "location": "path",
17601	//       "required": true,
17602	//       "type": "string"
17603	//     }
17604	//   },
17605	//   "path": "userprofiles/{profileId}/ads/{id}",
17606	//   "response": {
17607	//     "$ref": "Ad"
17608	//   },
17609	//   "scopes": [
17610	//     "https://www.googleapis.com/auth/dfatrafficking"
17611	//   ]
17612	// }
17613
17614}
17615
17616// method id "dfareporting.ads.insert":
17617
17618type AdsInsertCall struct {
17619	s          *Service
17620	profileId  int64
17621	ad         *Ad
17622	urlParams_ gensupport.URLParams
17623	ctx_       context.Context
17624	header_    http.Header
17625}
17626
17627// Insert: Inserts a new ad.
17628//
17629// - profileId: User profile ID associated with this request.
17630func (r *AdsService) Insert(profileId int64, ad *Ad) *AdsInsertCall {
17631	c := &AdsInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
17632	c.profileId = profileId
17633	c.ad = ad
17634	return c
17635}
17636
17637// Fields allows partial responses to be retrieved. See
17638// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
17639// for more information.
17640func (c *AdsInsertCall) Fields(s ...googleapi.Field) *AdsInsertCall {
17641	c.urlParams_.Set("fields", googleapi.CombineFields(s))
17642	return c
17643}
17644
17645// Context sets the context to be used in this call's Do method. Any
17646// pending HTTP request will be aborted if the provided context is
17647// canceled.
17648func (c *AdsInsertCall) Context(ctx context.Context) *AdsInsertCall {
17649	c.ctx_ = ctx
17650	return c
17651}
17652
17653// Header returns an http.Header that can be modified by the caller to
17654// add HTTP headers to the request.
17655func (c *AdsInsertCall) Header() http.Header {
17656	if c.header_ == nil {
17657		c.header_ = make(http.Header)
17658	}
17659	return c.header_
17660}
17661
17662func (c *AdsInsertCall) doRequest(alt string) (*http.Response, error) {
17663	reqHeaders := make(http.Header)
17664	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
17665	for k, v := range c.header_ {
17666		reqHeaders[k] = v
17667	}
17668	reqHeaders.Set("User-Agent", c.s.userAgent())
17669	var body io.Reader = nil
17670	body, err := googleapi.WithoutDataWrapper.JSONReader(c.ad)
17671	if err != nil {
17672		return nil, err
17673	}
17674	reqHeaders.Set("Content-Type", "application/json")
17675	c.urlParams_.Set("alt", alt)
17676	c.urlParams_.Set("prettyPrint", "false")
17677	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/ads")
17678	urls += "?" + c.urlParams_.Encode()
17679	req, err := http.NewRequest("POST", urls, body)
17680	if err != nil {
17681		return nil, err
17682	}
17683	req.Header = reqHeaders
17684	googleapi.Expand(req.URL, map[string]string{
17685		"profileId": strconv.FormatInt(c.profileId, 10),
17686	})
17687	return gensupport.SendRequest(c.ctx_, c.s.client, req)
17688}
17689
17690// Do executes the "dfareporting.ads.insert" call.
17691// Exactly one of *Ad or error will be non-nil. Any non-2xx status code
17692// is an error. Response headers are in either *Ad.ServerResponse.Header
17693// or (if a response was returned at all) in
17694// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
17695// whether the returned error was because http.StatusNotModified was
17696// returned.
17697func (c *AdsInsertCall) Do(opts ...googleapi.CallOption) (*Ad, error) {
17698	gensupport.SetOptions(c.urlParams_, opts...)
17699	res, err := c.doRequest("json")
17700	if res != nil && res.StatusCode == http.StatusNotModified {
17701		if res.Body != nil {
17702			res.Body.Close()
17703		}
17704		return nil, &googleapi.Error{
17705			Code:   res.StatusCode,
17706			Header: res.Header,
17707		}
17708	}
17709	if err != nil {
17710		return nil, err
17711	}
17712	defer googleapi.CloseBody(res)
17713	if err := googleapi.CheckResponse(res); err != nil {
17714		return nil, err
17715	}
17716	ret := &Ad{
17717		ServerResponse: googleapi.ServerResponse{
17718			Header:         res.Header,
17719			HTTPStatusCode: res.StatusCode,
17720		},
17721	}
17722	target := &ret
17723	if err := gensupport.DecodeResponse(target, res); err != nil {
17724		return nil, err
17725	}
17726	return ret, nil
17727	// {
17728	//   "description": "Inserts a new ad.",
17729	//   "flatPath": "userprofiles/{profileId}/ads",
17730	//   "httpMethod": "POST",
17731	//   "id": "dfareporting.ads.insert",
17732	//   "parameterOrder": [
17733	//     "profileId"
17734	//   ],
17735	//   "parameters": {
17736	//     "profileId": {
17737	//       "description": "User profile ID associated with this request.",
17738	//       "format": "int64",
17739	//       "location": "path",
17740	//       "required": true,
17741	//       "type": "string"
17742	//     }
17743	//   },
17744	//   "path": "userprofiles/{profileId}/ads",
17745	//   "request": {
17746	//     "$ref": "Ad"
17747	//   },
17748	//   "response": {
17749	//     "$ref": "Ad"
17750	//   },
17751	//   "scopes": [
17752	//     "https://www.googleapis.com/auth/dfatrafficking"
17753	//   ]
17754	// }
17755
17756}
17757
17758// method id "dfareporting.ads.list":
17759
17760type AdsListCall struct {
17761	s            *Service
17762	profileId    int64
17763	urlParams_   gensupport.URLParams
17764	ifNoneMatch_ string
17765	ctx_         context.Context
17766	header_      http.Header
17767}
17768
17769// List: Retrieves a list of ads, possibly filtered. This method
17770// supports paging.
17771//
17772// - profileId: User profile ID associated with this request.
17773func (r *AdsService) List(profileId int64) *AdsListCall {
17774	c := &AdsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
17775	c.profileId = profileId
17776	return c
17777}
17778
17779// Active sets the optional parameter "active": Select only active ads.
17780func (c *AdsListCall) Active(active bool) *AdsListCall {
17781	c.urlParams_.Set("active", fmt.Sprint(active))
17782	return c
17783}
17784
17785// AdvertiserId sets the optional parameter "advertiserId": Select only
17786// ads with this advertiser ID.
17787func (c *AdsListCall) AdvertiserId(advertiserId int64) *AdsListCall {
17788	c.urlParams_.Set("advertiserId", fmt.Sprint(advertiserId))
17789	return c
17790}
17791
17792// Archived sets the optional parameter "archived": Select only archived
17793// ads.
17794func (c *AdsListCall) Archived(archived bool) *AdsListCall {
17795	c.urlParams_.Set("archived", fmt.Sprint(archived))
17796	return c
17797}
17798
17799// AudienceSegmentIds sets the optional parameter "audienceSegmentIds":
17800// Select only ads with these audience segment IDs.
17801func (c *AdsListCall) AudienceSegmentIds(audienceSegmentIds ...int64) *AdsListCall {
17802	var audienceSegmentIds_ []string
17803	for _, v := range audienceSegmentIds {
17804		audienceSegmentIds_ = append(audienceSegmentIds_, fmt.Sprint(v))
17805	}
17806	c.urlParams_.SetMulti("audienceSegmentIds", audienceSegmentIds_)
17807	return c
17808}
17809
17810// CampaignIds sets the optional parameter "campaignIds": Select only
17811// ads with these campaign IDs.
17812func (c *AdsListCall) CampaignIds(campaignIds ...int64) *AdsListCall {
17813	var campaignIds_ []string
17814	for _, v := range campaignIds {
17815		campaignIds_ = append(campaignIds_, fmt.Sprint(v))
17816	}
17817	c.urlParams_.SetMulti("campaignIds", campaignIds_)
17818	return c
17819}
17820
17821// Compatibility sets the optional parameter "compatibility": Select
17822// default ads with the specified compatibility. Applicable when type is
17823// AD_SERVING_DEFAULT_AD. DISPLAY and DISPLAY_INTERSTITIAL refer to
17824// rendering either on desktop or on mobile devices for regular or
17825// interstitial ads, respectively. APP and APP_INTERSTITIAL are for
17826// rendering in mobile apps. IN_STREAM_VIDEO refers to rendering an
17827// in-stream video ads developed with the VAST standard.
17828//
17829// Possible values:
17830//   "DISPLAY"
17831//   "DISPLAY_INTERSTITIAL"
17832//   "APP"
17833//   "APP_INTERSTITIAL"
17834//   "IN_STREAM_VIDEO"
17835//   "IN_STREAM_AUDIO"
17836func (c *AdsListCall) Compatibility(compatibility string) *AdsListCall {
17837	c.urlParams_.Set("compatibility", compatibility)
17838	return c
17839}
17840
17841// CreativeIds sets the optional parameter "creativeIds": Select only
17842// ads with these creative IDs assigned.
17843func (c *AdsListCall) CreativeIds(creativeIds ...int64) *AdsListCall {
17844	var creativeIds_ []string
17845	for _, v := range creativeIds {
17846		creativeIds_ = append(creativeIds_, fmt.Sprint(v))
17847	}
17848	c.urlParams_.SetMulti("creativeIds", creativeIds_)
17849	return c
17850}
17851
17852// CreativeOptimizationConfigurationIds sets the optional parameter
17853// "creativeOptimizationConfigurationIds": Select only ads with these
17854// creative optimization configuration IDs.
17855func (c *AdsListCall) CreativeOptimizationConfigurationIds(creativeOptimizationConfigurationIds ...int64) *AdsListCall {
17856	var creativeOptimizationConfigurationIds_ []string
17857	for _, v := range creativeOptimizationConfigurationIds {
17858		creativeOptimizationConfigurationIds_ = append(creativeOptimizationConfigurationIds_, fmt.Sprint(v))
17859	}
17860	c.urlParams_.SetMulti("creativeOptimizationConfigurationIds", creativeOptimizationConfigurationIds_)
17861	return c
17862}
17863
17864// DynamicClickTracker sets the optional parameter
17865// "dynamicClickTracker": Select only dynamic click trackers. Applicable
17866// when type is AD_SERVING_CLICK_TRACKER. If true, select dynamic click
17867// trackers. If false, select static click trackers. Leave unset to
17868// select both.
17869func (c *AdsListCall) DynamicClickTracker(dynamicClickTracker bool) *AdsListCall {
17870	c.urlParams_.Set("dynamicClickTracker", fmt.Sprint(dynamicClickTracker))
17871	return c
17872}
17873
17874// Ids sets the optional parameter "ids": Select only ads with these
17875// IDs.
17876func (c *AdsListCall) Ids(ids ...int64) *AdsListCall {
17877	var ids_ []string
17878	for _, v := range ids {
17879		ids_ = append(ids_, fmt.Sprint(v))
17880	}
17881	c.urlParams_.SetMulti("ids", ids_)
17882	return c
17883}
17884
17885// LandingPageIds sets the optional parameter "landingPageIds": Select
17886// only ads with these landing page IDs.
17887func (c *AdsListCall) LandingPageIds(landingPageIds ...int64) *AdsListCall {
17888	var landingPageIds_ []string
17889	for _, v := range landingPageIds {
17890		landingPageIds_ = append(landingPageIds_, fmt.Sprint(v))
17891	}
17892	c.urlParams_.SetMulti("landingPageIds", landingPageIds_)
17893	return c
17894}
17895
17896// MaxResults sets the optional parameter "maxResults": Maximum number
17897// of results to return.
17898func (c *AdsListCall) MaxResults(maxResults int64) *AdsListCall {
17899	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
17900	return c
17901}
17902
17903// OverriddenEventTagId sets the optional parameter
17904// "overriddenEventTagId": Select only ads with this event tag override
17905// ID.
17906func (c *AdsListCall) OverriddenEventTagId(overriddenEventTagId int64) *AdsListCall {
17907	c.urlParams_.Set("overriddenEventTagId", fmt.Sprint(overriddenEventTagId))
17908	return c
17909}
17910
17911// PageToken sets the optional parameter "pageToken": Value of the
17912// nextPageToken from the previous result page.
17913func (c *AdsListCall) PageToken(pageToken string) *AdsListCall {
17914	c.urlParams_.Set("pageToken", pageToken)
17915	return c
17916}
17917
17918// PlacementIds sets the optional parameter "placementIds": Select only
17919// ads with these placement IDs assigned.
17920func (c *AdsListCall) PlacementIds(placementIds ...int64) *AdsListCall {
17921	var placementIds_ []string
17922	for _, v := range placementIds {
17923		placementIds_ = append(placementIds_, fmt.Sprint(v))
17924	}
17925	c.urlParams_.SetMulti("placementIds", placementIds_)
17926	return c
17927}
17928
17929// RemarketingListIds sets the optional parameter "remarketingListIds":
17930// Select only ads whose list targeting expression use these remarketing
17931// list IDs.
17932func (c *AdsListCall) RemarketingListIds(remarketingListIds ...int64) *AdsListCall {
17933	var remarketingListIds_ []string
17934	for _, v := range remarketingListIds {
17935		remarketingListIds_ = append(remarketingListIds_, fmt.Sprint(v))
17936	}
17937	c.urlParams_.SetMulti("remarketingListIds", remarketingListIds_)
17938	return c
17939}
17940
17941// SearchString sets the optional parameter "searchString": Allows
17942// searching for objects by name or ID. Wildcards (*) are allowed. For
17943// example, "ad*2015" will return objects with names like "ad June
17944// 2015", "ad April 2015", or simply "ad 2015". Most of the searches
17945// also add wildcards implicitly at the start and the end of the search
17946// string. For example, a search string of "ad" will match objects with
17947// name "my ad", "ad 2015", or simply "ad".
17948func (c *AdsListCall) SearchString(searchString string) *AdsListCall {
17949	c.urlParams_.Set("searchString", searchString)
17950	return c
17951}
17952
17953// SizeIds sets the optional parameter "sizeIds": Select only ads with
17954// these size IDs.
17955func (c *AdsListCall) SizeIds(sizeIds ...int64) *AdsListCall {
17956	var sizeIds_ []string
17957	for _, v := range sizeIds {
17958		sizeIds_ = append(sizeIds_, fmt.Sprint(v))
17959	}
17960	c.urlParams_.SetMulti("sizeIds", sizeIds_)
17961	return c
17962}
17963
17964// SortField sets the optional parameter "sortField": Field by which to
17965// sort the list.
17966//
17967// Possible values:
17968//   "ID" (default)
17969//   "NAME"
17970func (c *AdsListCall) SortField(sortField string) *AdsListCall {
17971	c.urlParams_.Set("sortField", sortField)
17972	return c
17973}
17974
17975// SortOrder sets the optional parameter "sortOrder": Order of sorted
17976// results.
17977//
17978// Possible values:
17979//   "ASCENDING" (default)
17980//   "DESCENDING"
17981func (c *AdsListCall) SortOrder(sortOrder string) *AdsListCall {
17982	c.urlParams_.Set("sortOrder", sortOrder)
17983	return c
17984}
17985
17986// SslCompliant sets the optional parameter "sslCompliant": Select only
17987// ads that are SSL-compliant.
17988func (c *AdsListCall) SslCompliant(sslCompliant bool) *AdsListCall {
17989	c.urlParams_.Set("sslCompliant", fmt.Sprint(sslCompliant))
17990	return c
17991}
17992
17993// SslRequired sets the optional parameter "sslRequired": Select only
17994// ads that require SSL.
17995func (c *AdsListCall) SslRequired(sslRequired bool) *AdsListCall {
17996	c.urlParams_.Set("sslRequired", fmt.Sprint(sslRequired))
17997	return c
17998}
17999
18000// Type sets the optional parameter "type": Select only ads with these
18001// types.
18002//
18003// Possible values:
18004//   "AD_SERVING_STANDARD_AD"
18005//   "AD_SERVING_DEFAULT_AD"
18006//   "AD_SERVING_CLICK_TRACKER"
18007//   "AD_SERVING_TRACKING"
18008//   "AD_SERVING_BRAND_SAFE_AD"
18009func (c *AdsListCall) Type(type_ ...string) *AdsListCall {
18010	c.urlParams_.SetMulti("type", append([]string{}, type_...))
18011	return c
18012}
18013
18014// Fields allows partial responses to be retrieved. See
18015// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
18016// for more information.
18017func (c *AdsListCall) Fields(s ...googleapi.Field) *AdsListCall {
18018	c.urlParams_.Set("fields", googleapi.CombineFields(s))
18019	return c
18020}
18021
18022// IfNoneMatch sets the optional parameter which makes the operation
18023// fail if the object's ETag matches the given value. This is useful for
18024// getting updates only after the object has changed since the last
18025// request. Use googleapi.IsNotModified to check whether the response
18026// error from Do is the result of In-None-Match.
18027func (c *AdsListCall) IfNoneMatch(entityTag string) *AdsListCall {
18028	c.ifNoneMatch_ = entityTag
18029	return c
18030}
18031
18032// Context sets the context to be used in this call's Do method. Any
18033// pending HTTP request will be aborted if the provided context is
18034// canceled.
18035func (c *AdsListCall) Context(ctx context.Context) *AdsListCall {
18036	c.ctx_ = ctx
18037	return c
18038}
18039
18040// Header returns an http.Header that can be modified by the caller to
18041// add HTTP headers to the request.
18042func (c *AdsListCall) Header() http.Header {
18043	if c.header_ == nil {
18044		c.header_ = make(http.Header)
18045	}
18046	return c.header_
18047}
18048
18049func (c *AdsListCall) doRequest(alt string) (*http.Response, error) {
18050	reqHeaders := make(http.Header)
18051	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
18052	for k, v := range c.header_ {
18053		reqHeaders[k] = v
18054	}
18055	reqHeaders.Set("User-Agent", c.s.userAgent())
18056	if c.ifNoneMatch_ != "" {
18057		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
18058	}
18059	var body io.Reader = nil
18060	c.urlParams_.Set("alt", alt)
18061	c.urlParams_.Set("prettyPrint", "false")
18062	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/ads")
18063	urls += "?" + c.urlParams_.Encode()
18064	req, err := http.NewRequest("GET", urls, body)
18065	if err != nil {
18066		return nil, err
18067	}
18068	req.Header = reqHeaders
18069	googleapi.Expand(req.URL, map[string]string{
18070		"profileId": strconv.FormatInt(c.profileId, 10),
18071	})
18072	return gensupport.SendRequest(c.ctx_, c.s.client, req)
18073}
18074
18075// Do executes the "dfareporting.ads.list" call.
18076// Exactly one of *AdsListResponse or error will be non-nil. Any non-2xx
18077// status code is an error. Response headers are in either
18078// *AdsListResponse.ServerResponse.Header or (if a response was returned
18079// at all) in error.(*googleapi.Error).Header. Use
18080// googleapi.IsNotModified to check whether the returned error was
18081// because http.StatusNotModified was returned.
18082func (c *AdsListCall) Do(opts ...googleapi.CallOption) (*AdsListResponse, error) {
18083	gensupport.SetOptions(c.urlParams_, opts...)
18084	res, err := c.doRequest("json")
18085	if res != nil && res.StatusCode == http.StatusNotModified {
18086		if res.Body != nil {
18087			res.Body.Close()
18088		}
18089		return nil, &googleapi.Error{
18090			Code:   res.StatusCode,
18091			Header: res.Header,
18092		}
18093	}
18094	if err != nil {
18095		return nil, err
18096	}
18097	defer googleapi.CloseBody(res)
18098	if err := googleapi.CheckResponse(res); err != nil {
18099		return nil, err
18100	}
18101	ret := &AdsListResponse{
18102		ServerResponse: googleapi.ServerResponse{
18103			Header:         res.Header,
18104			HTTPStatusCode: res.StatusCode,
18105		},
18106	}
18107	target := &ret
18108	if err := gensupport.DecodeResponse(target, res); err != nil {
18109		return nil, err
18110	}
18111	return ret, nil
18112	// {
18113	//   "description": "Retrieves a list of ads, possibly filtered. This method supports paging.",
18114	//   "flatPath": "userprofiles/{profileId}/ads",
18115	//   "httpMethod": "GET",
18116	//   "id": "dfareporting.ads.list",
18117	//   "parameterOrder": [
18118	//     "profileId"
18119	//   ],
18120	//   "parameters": {
18121	//     "active": {
18122	//       "description": "Select only active ads.",
18123	//       "location": "query",
18124	//       "type": "boolean"
18125	//     },
18126	//     "advertiserId": {
18127	//       "description": "Select only ads with this advertiser ID.",
18128	//       "format": "int64",
18129	//       "location": "query",
18130	//       "type": "string"
18131	//     },
18132	//     "archived": {
18133	//       "description": "Select only archived ads.",
18134	//       "location": "query",
18135	//       "type": "boolean"
18136	//     },
18137	//     "audienceSegmentIds": {
18138	//       "description": "Select only ads with these audience segment IDs.",
18139	//       "format": "int64",
18140	//       "location": "query",
18141	//       "repeated": true,
18142	//       "type": "string"
18143	//     },
18144	//     "campaignIds": {
18145	//       "description": "Select only ads with these campaign IDs.",
18146	//       "format": "int64",
18147	//       "location": "query",
18148	//       "repeated": true,
18149	//       "type": "string"
18150	//     },
18151	//     "compatibility": {
18152	//       "description": "Select default ads with the specified compatibility. Applicable when type is AD_SERVING_DEFAULT_AD. DISPLAY and DISPLAY_INTERSTITIAL refer to rendering either on desktop or on mobile devices for regular or interstitial ads, respectively. APP and APP_INTERSTITIAL are for rendering in mobile apps. IN_STREAM_VIDEO refers to rendering an in-stream video ads developed with the VAST standard.",
18153	//       "enum": [
18154	//         "DISPLAY",
18155	//         "DISPLAY_INTERSTITIAL",
18156	//         "APP",
18157	//         "APP_INTERSTITIAL",
18158	//         "IN_STREAM_VIDEO",
18159	//         "IN_STREAM_AUDIO"
18160	//       ],
18161	//       "enumDescriptions": [
18162	//         "",
18163	//         "",
18164	//         "",
18165	//         "",
18166	//         "",
18167	//         ""
18168	//       ],
18169	//       "location": "query",
18170	//       "type": "string"
18171	//     },
18172	//     "creativeIds": {
18173	//       "description": "Select only ads with these creative IDs assigned.",
18174	//       "format": "int64",
18175	//       "location": "query",
18176	//       "repeated": true,
18177	//       "type": "string"
18178	//     },
18179	//     "creativeOptimizationConfigurationIds": {
18180	//       "description": "Select only ads with these creative optimization configuration IDs.",
18181	//       "format": "int64",
18182	//       "location": "query",
18183	//       "repeated": true,
18184	//       "type": "string"
18185	//     },
18186	//     "dynamicClickTracker": {
18187	//       "description": "Select only dynamic click trackers. Applicable when type is AD_SERVING_CLICK_TRACKER. If true, select dynamic click trackers. If false, select static click trackers. Leave unset to select both.",
18188	//       "location": "query",
18189	//       "type": "boolean"
18190	//     },
18191	//     "ids": {
18192	//       "description": "Select only ads with these IDs.",
18193	//       "format": "int64",
18194	//       "location": "query",
18195	//       "repeated": true,
18196	//       "type": "string"
18197	//     },
18198	//     "landingPageIds": {
18199	//       "description": "Select only ads with these landing page IDs.",
18200	//       "format": "int64",
18201	//       "location": "query",
18202	//       "repeated": true,
18203	//       "type": "string"
18204	//     },
18205	//     "maxResults": {
18206	//       "default": "1000",
18207	//       "description": "Maximum number of results to return.",
18208	//       "format": "int32",
18209	//       "location": "query",
18210	//       "maximum": "1000",
18211	//       "minimum": "0",
18212	//       "type": "integer"
18213	//     },
18214	//     "overriddenEventTagId": {
18215	//       "description": "Select only ads with this event tag override ID.",
18216	//       "format": "int64",
18217	//       "location": "query",
18218	//       "type": "string"
18219	//     },
18220	//     "pageToken": {
18221	//       "description": "Value of the nextPageToken from the previous result page.",
18222	//       "location": "query",
18223	//       "type": "string"
18224	//     },
18225	//     "placementIds": {
18226	//       "description": "Select only ads with these placement IDs assigned.",
18227	//       "format": "int64",
18228	//       "location": "query",
18229	//       "repeated": true,
18230	//       "type": "string"
18231	//     },
18232	//     "profileId": {
18233	//       "description": "User profile ID associated with this request.",
18234	//       "format": "int64",
18235	//       "location": "path",
18236	//       "required": true,
18237	//       "type": "string"
18238	//     },
18239	//     "remarketingListIds": {
18240	//       "description": "Select only ads whose list targeting expression use these remarketing list IDs.",
18241	//       "format": "int64",
18242	//       "location": "query",
18243	//       "repeated": true,
18244	//       "type": "string"
18245	//     },
18246	//     "searchString": {
18247	//       "description": "Allows searching for objects by name or ID. Wildcards (*) are allowed. For example, \"ad*2015\" will return objects with names like \"ad June 2015\", \"ad April 2015\", or simply \"ad 2015\". Most of the searches also add wildcards implicitly at the start and the end of the search string. For example, a search string of \"ad\" will match objects with name \"my ad\", \"ad 2015\", or simply \"ad\".",
18248	//       "location": "query",
18249	//       "type": "string"
18250	//     },
18251	//     "sizeIds": {
18252	//       "description": "Select only ads with these size IDs.",
18253	//       "format": "int64",
18254	//       "location": "query",
18255	//       "repeated": true,
18256	//       "type": "string"
18257	//     },
18258	//     "sortField": {
18259	//       "default": "ID",
18260	//       "description": "Field by which to sort the list.",
18261	//       "enum": [
18262	//         "ID",
18263	//         "NAME"
18264	//       ],
18265	//       "enumDescriptions": [
18266	//         "",
18267	//         ""
18268	//       ],
18269	//       "location": "query",
18270	//       "type": "string"
18271	//     },
18272	//     "sortOrder": {
18273	//       "default": "ASCENDING",
18274	//       "description": "Order of sorted results.",
18275	//       "enum": [
18276	//         "ASCENDING",
18277	//         "DESCENDING"
18278	//       ],
18279	//       "enumDescriptions": [
18280	//         "",
18281	//         ""
18282	//       ],
18283	//       "location": "query",
18284	//       "type": "string"
18285	//     },
18286	//     "sslCompliant": {
18287	//       "description": "Select only ads that are SSL-compliant.",
18288	//       "location": "query",
18289	//       "type": "boolean"
18290	//     },
18291	//     "sslRequired": {
18292	//       "description": "Select only ads that require SSL.",
18293	//       "location": "query",
18294	//       "type": "boolean"
18295	//     },
18296	//     "type": {
18297	//       "description": "Select only ads with these types.",
18298	//       "enum": [
18299	//         "AD_SERVING_STANDARD_AD",
18300	//         "AD_SERVING_DEFAULT_AD",
18301	//         "AD_SERVING_CLICK_TRACKER",
18302	//         "AD_SERVING_TRACKING",
18303	//         "AD_SERVING_BRAND_SAFE_AD"
18304	//       ],
18305	//       "enumDescriptions": [
18306	//         "",
18307	//         "",
18308	//         "",
18309	//         "",
18310	//         ""
18311	//       ],
18312	//       "location": "query",
18313	//       "repeated": true,
18314	//       "type": "string"
18315	//     }
18316	//   },
18317	//   "path": "userprofiles/{profileId}/ads",
18318	//   "response": {
18319	//     "$ref": "AdsListResponse"
18320	//   },
18321	//   "scopes": [
18322	//     "https://www.googleapis.com/auth/dfatrafficking"
18323	//   ]
18324	// }
18325
18326}
18327
18328// Pages invokes f for each page of results.
18329// A non-nil error returned from f will halt the iteration.
18330// The provided context supersedes any context provided to the Context method.
18331func (c *AdsListCall) Pages(ctx context.Context, f func(*AdsListResponse) error) error {
18332	c.ctx_ = ctx
18333	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
18334	for {
18335		x, err := c.Do()
18336		if err != nil {
18337			return err
18338		}
18339		if err := f(x); err != nil {
18340			return err
18341		}
18342		if x.NextPageToken == "" {
18343			return nil
18344		}
18345		c.PageToken(x.NextPageToken)
18346	}
18347}
18348
18349// method id "dfareporting.ads.patch":
18350
18351type AdsPatchCall struct {
18352	s          *Service
18353	profileId  int64
18354	ad         *Ad
18355	urlParams_ gensupport.URLParams
18356	ctx_       context.Context
18357	header_    http.Header
18358}
18359
18360// Patch: Updates an existing ad. This method supports patch semantics.
18361//
18362// - id: Ad ID.
18363// - profileId: User profile ID associated with this request.
18364func (r *AdsService) Patch(profileId int64, id int64, ad *Ad) *AdsPatchCall {
18365	c := &AdsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
18366	c.profileId = profileId
18367	c.urlParams_.Set("id", fmt.Sprint(id))
18368	c.ad = ad
18369	return c
18370}
18371
18372// Fields allows partial responses to be retrieved. See
18373// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
18374// for more information.
18375func (c *AdsPatchCall) Fields(s ...googleapi.Field) *AdsPatchCall {
18376	c.urlParams_.Set("fields", googleapi.CombineFields(s))
18377	return c
18378}
18379
18380// Context sets the context to be used in this call's Do method. Any
18381// pending HTTP request will be aborted if the provided context is
18382// canceled.
18383func (c *AdsPatchCall) Context(ctx context.Context) *AdsPatchCall {
18384	c.ctx_ = ctx
18385	return c
18386}
18387
18388// Header returns an http.Header that can be modified by the caller to
18389// add HTTP headers to the request.
18390func (c *AdsPatchCall) Header() http.Header {
18391	if c.header_ == nil {
18392		c.header_ = make(http.Header)
18393	}
18394	return c.header_
18395}
18396
18397func (c *AdsPatchCall) doRequest(alt string) (*http.Response, error) {
18398	reqHeaders := make(http.Header)
18399	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
18400	for k, v := range c.header_ {
18401		reqHeaders[k] = v
18402	}
18403	reqHeaders.Set("User-Agent", c.s.userAgent())
18404	var body io.Reader = nil
18405	body, err := googleapi.WithoutDataWrapper.JSONReader(c.ad)
18406	if err != nil {
18407		return nil, err
18408	}
18409	reqHeaders.Set("Content-Type", "application/json")
18410	c.urlParams_.Set("alt", alt)
18411	c.urlParams_.Set("prettyPrint", "false")
18412	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/ads")
18413	urls += "?" + c.urlParams_.Encode()
18414	req, err := http.NewRequest("PATCH", urls, body)
18415	if err != nil {
18416		return nil, err
18417	}
18418	req.Header = reqHeaders
18419	googleapi.Expand(req.URL, map[string]string{
18420		"profileId": strconv.FormatInt(c.profileId, 10),
18421	})
18422	return gensupport.SendRequest(c.ctx_, c.s.client, req)
18423}
18424
18425// Do executes the "dfareporting.ads.patch" call.
18426// Exactly one of *Ad or error will be non-nil. Any non-2xx status code
18427// is an error. Response headers are in either *Ad.ServerResponse.Header
18428// or (if a response was returned at all) in
18429// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
18430// whether the returned error was because http.StatusNotModified was
18431// returned.
18432func (c *AdsPatchCall) Do(opts ...googleapi.CallOption) (*Ad, error) {
18433	gensupport.SetOptions(c.urlParams_, opts...)
18434	res, err := c.doRequest("json")
18435	if res != nil && res.StatusCode == http.StatusNotModified {
18436		if res.Body != nil {
18437			res.Body.Close()
18438		}
18439		return nil, &googleapi.Error{
18440			Code:   res.StatusCode,
18441			Header: res.Header,
18442		}
18443	}
18444	if err != nil {
18445		return nil, err
18446	}
18447	defer googleapi.CloseBody(res)
18448	if err := googleapi.CheckResponse(res); err != nil {
18449		return nil, err
18450	}
18451	ret := &Ad{
18452		ServerResponse: googleapi.ServerResponse{
18453			Header:         res.Header,
18454			HTTPStatusCode: res.StatusCode,
18455		},
18456	}
18457	target := &ret
18458	if err := gensupport.DecodeResponse(target, res); err != nil {
18459		return nil, err
18460	}
18461	return ret, nil
18462	// {
18463	//   "description": "Updates an existing ad. This method supports patch semantics.",
18464	//   "flatPath": "userprofiles/{profileId}/ads",
18465	//   "httpMethod": "PATCH",
18466	//   "id": "dfareporting.ads.patch",
18467	//   "parameterOrder": [
18468	//     "profileId",
18469	//     "id"
18470	//   ],
18471	//   "parameters": {
18472	//     "id": {
18473	//       "description": "Ad ID.",
18474	//       "format": "int64",
18475	//       "location": "query",
18476	//       "required": true,
18477	//       "type": "string"
18478	//     },
18479	//     "profileId": {
18480	//       "description": "User profile ID associated with this request.",
18481	//       "format": "int64",
18482	//       "location": "path",
18483	//       "required": true,
18484	//       "type": "string"
18485	//     }
18486	//   },
18487	//   "path": "userprofiles/{profileId}/ads",
18488	//   "request": {
18489	//     "$ref": "Ad"
18490	//   },
18491	//   "response": {
18492	//     "$ref": "Ad"
18493	//   },
18494	//   "scopes": [
18495	//     "https://www.googleapis.com/auth/dfatrafficking"
18496	//   ]
18497	// }
18498
18499}
18500
18501// method id "dfareporting.ads.update":
18502
18503type AdsUpdateCall struct {
18504	s          *Service
18505	profileId  int64
18506	ad         *Ad
18507	urlParams_ gensupport.URLParams
18508	ctx_       context.Context
18509	header_    http.Header
18510}
18511
18512// Update: Updates an existing ad.
18513//
18514// - profileId: User profile ID associated with this request.
18515func (r *AdsService) Update(profileId int64, ad *Ad) *AdsUpdateCall {
18516	c := &AdsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
18517	c.profileId = profileId
18518	c.ad = ad
18519	return c
18520}
18521
18522// Fields allows partial responses to be retrieved. See
18523// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
18524// for more information.
18525func (c *AdsUpdateCall) Fields(s ...googleapi.Field) *AdsUpdateCall {
18526	c.urlParams_.Set("fields", googleapi.CombineFields(s))
18527	return c
18528}
18529
18530// Context sets the context to be used in this call's Do method. Any
18531// pending HTTP request will be aborted if the provided context is
18532// canceled.
18533func (c *AdsUpdateCall) Context(ctx context.Context) *AdsUpdateCall {
18534	c.ctx_ = ctx
18535	return c
18536}
18537
18538// Header returns an http.Header that can be modified by the caller to
18539// add HTTP headers to the request.
18540func (c *AdsUpdateCall) Header() http.Header {
18541	if c.header_ == nil {
18542		c.header_ = make(http.Header)
18543	}
18544	return c.header_
18545}
18546
18547func (c *AdsUpdateCall) doRequest(alt string) (*http.Response, error) {
18548	reqHeaders := make(http.Header)
18549	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
18550	for k, v := range c.header_ {
18551		reqHeaders[k] = v
18552	}
18553	reqHeaders.Set("User-Agent", c.s.userAgent())
18554	var body io.Reader = nil
18555	body, err := googleapi.WithoutDataWrapper.JSONReader(c.ad)
18556	if err != nil {
18557		return nil, err
18558	}
18559	reqHeaders.Set("Content-Type", "application/json")
18560	c.urlParams_.Set("alt", alt)
18561	c.urlParams_.Set("prettyPrint", "false")
18562	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/ads")
18563	urls += "?" + c.urlParams_.Encode()
18564	req, err := http.NewRequest("PUT", urls, body)
18565	if err != nil {
18566		return nil, err
18567	}
18568	req.Header = reqHeaders
18569	googleapi.Expand(req.URL, map[string]string{
18570		"profileId": strconv.FormatInt(c.profileId, 10),
18571	})
18572	return gensupport.SendRequest(c.ctx_, c.s.client, req)
18573}
18574
18575// Do executes the "dfareporting.ads.update" call.
18576// Exactly one of *Ad or error will be non-nil. Any non-2xx status code
18577// is an error. Response headers are in either *Ad.ServerResponse.Header
18578// or (if a response was returned at all) in
18579// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
18580// whether the returned error was because http.StatusNotModified was
18581// returned.
18582func (c *AdsUpdateCall) Do(opts ...googleapi.CallOption) (*Ad, error) {
18583	gensupport.SetOptions(c.urlParams_, opts...)
18584	res, err := c.doRequest("json")
18585	if res != nil && res.StatusCode == http.StatusNotModified {
18586		if res.Body != nil {
18587			res.Body.Close()
18588		}
18589		return nil, &googleapi.Error{
18590			Code:   res.StatusCode,
18591			Header: res.Header,
18592		}
18593	}
18594	if err != nil {
18595		return nil, err
18596	}
18597	defer googleapi.CloseBody(res)
18598	if err := googleapi.CheckResponse(res); err != nil {
18599		return nil, err
18600	}
18601	ret := &Ad{
18602		ServerResponse: googleapi.ServerResponse{
18603			Header:         res.Header,
18604			HTTPStatusCode: res.StatusCode,
18605		},
18606	}
18607	target := &ret
18608	if err := gensupport.DecodeResponse(target, res); err != nil {
18609		return nil, err
18610	}
18611	return ret, nil
18612	// {
18613	//   "description": "Updates an existing ad.",
18614	//   "flatPath": "userprofiles/{profileId}/ads",
18615	//   "httpMethod": "PUT",
18616	//   "id": "dfareporting.ads.update",
18617	//   "parameterOrder": [
18618	//     "profileId"
18619	//   ],
18620	//   "parameters": {
18621	//     "profileId": {
18622	//       "description": "User profile ID associated with this request.",
18623	//       "format": "int64",
18624	//       "location": "path",
18625	//       "required": true,
18626	//       "type": "string"
18627	//     }
18628	//   },
18629	//   "path": "userprofiles/{profileId}/ads",
18630	//   "request": {
18631	//     "$ref": "Ad"
18632	//   },
18633	//   "response": {
18634	//     "$ref": "Ad"
18635	//   },
18636	//   "scopes": [
18637	//     "https://www.googleapis.com/auth/dfatrafficking"
18638	//   ]
18639	// }
18640
18641}
18642
18643// method id "dfareporting.advertiserGroups.delete":
18644
18645type AdvertiserGroupsDeleteCall struct {
18646	s          *Service
18647	profileId  int64
18648	id         int64
18649	urlParams_ gensupport.URLParams
18650	ctx_       context.Context
18651	header_    http.Header
18652}
18653
18654// Delete: Deletes an existing advertiser group.
18655//
18656// - id: Advertiser group ID.
18657// - profileId: User profile ID associated with this request.
18658func (r *AdvertiserGroupsService) Delete(profileId int64, id int64) *AdvertiserGroupsDeleteCall {
18659	c := &AdvertiserGroupsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
18660	c.profileId = profileId
18661	c.id = id
18662	return c
18663}
18664
18665// Fields allows partial responses to be retrieved. See
18666// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
18667// for more information.
18668func (c *AdvertiserGroupsDeleteCall) Fields(s ...googleapi.Field) *AdvertiserGroupsDeleteCall {
18669	c.urlParams_.Set("fields", googleapi.CombineFields(s))
18670	return c
18671}
18672
18673// Context sets the context to be used in this call's Do method. Any
18674// pending HTTP request will be aborted if the provided context is
18675// canceled.
18676func (c *AdvertiserGroupsDeleteCall) Context(ctx context.Context) *AdvertiserGroupsDeleteCall {
18677	c.ctx_ = ctx
18678	return c
18679}
18680
18681// Header returns an http.Header that can be modified by the caller to
18682// add HTTP headers to the request.
18683func (c *AdvertiserGroupsDeleteCall) Header() http.Header {
18684	if c.header_ == nil {
18685		c.header_ = make(http.Header)
18686	}
18687	return c.header_
18688}
18689
18690func (c *AdvertiserGroupsDeleteCall) doRequest(alt string) (*http.Response, error) {
18691	reqHeaders := make(http.Header)
18692	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
18693	for k, v := range c.header_ {
18694		reqHeaders[k] = v
18695	}
18696	reqHeaders.Set("User-Agent", c.s.userAgent())
18697	var body io.Reader = nil
18698	c.urlParams_.Set("alt", alt)
18699	c.urlParams_.Set("prettyPrint", "false")
18700	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/advertiserGroups/{id}")
18701	urls += "?" + c.urlParams_.Encode()
18702	req, err := http.NewRequest("DELETE", urls, body)
18703	if err != nil {
18704		return nil, err
18705	}
18706	req.Header = reqHeaders
18707	googleapi.Expand(req.URL, map[string]string{
18708		"profileId": strconv.FormatInt(c.profileId, 10),
18709		"id":        strconv.FormatInt(c.id, 10),
18710	})
18711	return gensupport.SendRequest(c.ctx_, c.s.client, req)
18712}
18713
18714// Do executes the "dfareporting.advertiserGroups.delete" call.
18715func (c *AdvertiserGroupsDeleteCall) Do(opts ...googleapi.CallOption) error {
18716	gensupport.SetOptions(c.urlParams_, opts...)
18717	res, err := c.doRequest("json")
18718	if err != nil {
18719		return err
18720	}
18721	defer googleapi.CloseBody(res)
18722	if err := googleapi.CheckResponse(res); err != nil {
18723		return err
18724	}
18725	return nil
18726	// {
18727	//   "description": "Deletes an existing advertiser group.",
18728	//   "flatPath": "userprofiles/{profileId}/advertiserGroups/{id}",
18729	//   "httpMethod": "DELETE",
18730	//   "id": "dfareporting.advertiserGroups.delete",
18731	//   "parameterOrder": [
18732	//     "profileId",
18733	//     "id"
18734	//   ],
18735	//   "parameters": {
18736	//     "id": {
18737	//       "description": "Advertiser group ID.",
18738	//       "format": "int64",
18739	//       "location": "path",
18740	//       "required": true,
18741	//       "type": "string"
18742	//     },
18743	//     "profileId": {
18744	//       "description": "User profile ID associated with this request.",
18745	//       "format": "int64",
18746	//       "location": "path",
18747	//       "required": true,
18748	//       "type": "string"
18749	//     }
18750	//   },
18751	//   "path": "userprofiles/{profileId}/advertiserGroups/{id}",
18752	//   "scopes": [
18753	//     "https://www.googleapis.com/auth/dfatrafficking"
18754	//   ]
18755	// }
18756
18757}
18758
18759// method id "dfareporting.advertiserGroups.get":
18760
18761type AdvertiserGroupsGetCall struct {
18762	s            *Service
18763	profileId    int64
18764	id           int64
18765	urlParams_   gensupport.URLParams
18766	ifNoneMatch_ string
18767	ctx_         context.Context
18768	header_      http.Header
18769}
18770
18771// Get: Gets one advertiser group by ID.
18772//
18773// - id: Advertiser group ID.
18774// - profileId: User profile ID associated with this request.
18775func (r *AdvertiserGroupsService) Get(profileId int64, id int64) *AdvertiserGroupsGetCall {
18776	c := &AdvertiserGroupsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
18777	c.profileId = profileId
18778	c.id = id
18779	return c
18780}
18781
18782// Fields allows partial responses to be retrieved. See
18783// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
18784// for more information.
18785func (c *AdvertiserGroupsGetCall) Fields(s ...googleapi.Field) *AdvertiserGroupsGetCall {
18786	c.urlParams_.Set("fields", googleapi.CombineFields(s))
18787	return c
18788}
18789
18790// IfNoneMatch sets the optional parameter which makes the operation
18791// fail if the object's ETag matches the given value. This is useful for
18792// getting updates only after the object has changed since the last
18793// request. Use googleapi.IsNotModified to check whether the response
18794// error from Do is the result of In-None-Match.
18795func (c *AdvertiserGroupsGetCall) IfNoneMatch(entityTag string) *AdvertiserGroupsGetCall {
18796	c.ifNoneMatch_ = entityTag
18797	return c
18798}
18799
18800// Context sets the context to be used in this call's Do method. Any
18801// pending HTTP request will be aborted if the provided context is
18802// canceled.
18803func (c *AdvertiserGroupsGetCall) Context(ctx context.Context) *AdvertiserGroupsGetCall {
18804	c.ctx_ = ctx
18805	return c
18806}
18807
18808// Header returns an http.Header that can be modified by the caller to
18809// add HTTP headers to the request.
18810func (c *AdvertiserGroupsGetCall) Header() http.Header {
18811	if c.header_ == nil {
18812		c.header_ = make(http.Header)
18813	}
18814	return c.header_
18815}
18816
18817func (c *AdvertiserGroupsGetCall) doRequest(alt string) (*http.Response, error) {
18818	reqHeaders := make(http.Header)
18819	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
18820	for k, v := range c.header_ {
18821		reqHeaders[k] = v
18822	}
18823	reqHeaders.Set("User-Agent", c.s.userAgent())
18824	if c.ifNoneMatch_ != "" {
18825		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
18826	}
18827	var body io.Reader = nil
18828	c.urlParams_.Set("alt", alt)
18829	c.urlParams_.Set("prettyPrint", "false")
18830	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/advertiserGroups/{id}")
18831	urls += "?" + c.urlParams_.Encode()
18832	req, err := http.NewRequest("GET", urls, body)
18833	if err != nil {
18834		return nil, err
18835	}
18836	req.Header = reqHeaders
18837	googleapi.Expand(req.URL, map[string]string{
18838		"profileId": strconv.FormatInt(c.profileId, 10),
18839		"id":        strconv.FormatInt(c.id, 10),
18840	})
18841	return gensupport.SendRequest(c.ctx_, c.s.client, req)
18842}
18843
18844// Do executes the "dfareporting.advertiserGroups.get" call.
18845// Exactly one of *AdvertiserGroup or error will be non-nil. Any non-2xx
18846// status code is an error. Response headers are in either
18847// *AdvertiserGroup.ServerResponse.Header or (if a response was returned
18848// at all) in error.(*googleapi.Error).Header. Use
18849// googleapi.IsNotModified to check whether the returned error was
18850// because http.StatusNotModified was returned.
18851func (c *AdvertiserGroupsGetCall) Do(opts ...googleapi.CallOption) (*AdvertiserGroup, error) {
18852	gensupport.SetOptions(c.urlParams_, opts...)
18853	res, err := c.doRequest("json")
18854	if res != nil && res.StatusCode == http.StatusNotModified {
18855		if res.Body != nil {
18856			res.Body.Close()
18857		}
18858		return nil, &googleapi.Error{
18859			Code:   res.StatusCode,
18860			Header: res.Header,
18861		}
18862	}
18863	if err != nil {
18864		return nil, err
18865	}
18866	defer googleapi.CloseBody(res)
18867	if err := googleapi.CheckResponse(res); err != nil {
18868		return nil, err
18869	}
18870	ret := &AdvertiserGroup{
18871		ServerResponse: googleapi.ServerResponse{
18872			Header:         res.Header,
18873			HTTPStatusCode: res.StatusCode,
18874		},
18875	}
18876	target := &ret
18877	if err := gensupport.DecodeResponse(target, res); err != nil {
18878		return nil, err
18879	}
18880	return ret, nil
18881	// {
18882	//   "description": "Gets one advertiser group by ID.",
18883	//   "flatPath": "userprofiles/{profileId}/advertiserGroups/{id}",
18884	//   "httpMethod": "GET",
18885	//   "id": "dfareporting.advertiserGroups.get",
18886	//   "parameterOrder": [
18887	//     "profileId",
18888	//     "id"
18889	//   ],
18890	//   "parameters": {
18891	//     "id": {
18892	//       "description": "Advertiser group ID.",
18893	//       "format": "int64",
18894	//       "location": "path",
18895	//       "required": true,
18896	//       "type": "string"
18897	//     },
18898	//     "profileId": {
18899	//       "description": "User profile ID associated with this request.",
18900	//       "format": "int64",
18901	//       "location": "path",
18902	//       "required": true,
18903	//       "type": "string"
18904	//     }
18905	//   },
18906	//   "path": "userprofiles/{profileId}/advertiserGroups/{id}",
18907	//   "response": {
18908	//     "$ref": "AdvertiserGroup"
18909	//   },
18910	//   "scopes": [
18911	//     "https://www.googleapis.com/auth/dfatrafficking"
18912	//   ]
18913	// }
18914
18915}
18916
18917// method id "dfareporting.advertiserGroups.insert":
18918
18919type AdvertiserGroupsInsertCall struct {
18920	s               *Service
18921	profileId       int64
18922	advertisergroup *AdvertiserGroup
18923	urlParams_      gensupport.URLParams
18924	ctx_            context.Context
18925	header_         http.Header
18926}
18927
18928// Insert: Inserts a new advertiser group.
18929//
18930// - profileId: User profile ID associated with this request.
18931func (r *AdvertiserGroupsService) Insert(profileId int64, advertisergroup *AdvertiserGroup) *AdvertiserGroupsInsertCall {
18932	c := &AdvertiserGroupsInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
18933	c.profileId = profileId
18934	c.advertisergroup = advertisergroup
18935	return c
18936}
18937
18938// Fields allows partial responses to be retrieved. See
18939// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
18940// for more information.
18941func (c *AdvertiserGroupsInsertCall) Fields(s ...googleapi.Field) *AdvertiserGroupsInsertCall {
18942	c.urlParams_.Set("fields", googleapi.CombineFields(s))
18943	return c
18944}
18945
18946// Context sets the context to be used in this call's Do method. Any
18947// pending HTTP request will be aborted if the provided context is
18948// canceled.
18949func (c *AdvertiserGroupsInsertCall) Context(ctx context.Context) *AdvertiserGroupsInsertCall {
18950	c.ctx_ = ctx
18951	return c
18952}
18953
18954// Header returns an http.Header that can be modified by the caller to
18955// add HTTP headers to the request.
18956func (c *AdvertiserGroupsInsertCall) Header() http.Header {
18957	if c.header_ == nil {
18958		c.header_ = make(http.Header)
18959	}
18960	return c.header_
18961}
18962
18963func (c *AdvertiserGroupsInsertCall) doRequest(alt string) (*http.Response, error) {
18964	reqHeaders := make(http.Header)
18965	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
18966	for k, v := range c.header_ {
18967		reqHeaders[k] = v
18968	}
18969	reqHeaders.Set("User-Agent", c.s.userAgent())
18970	var body io.Reader = nil
18971	body, err := googleapi.WithoutDataWrapper.JSONReader(c.advertisergroup)
18972	if err != nil {
18973		return nil, err
18974	}
18975	reqHeaders.Set("Content-Type", "application/json")
18976	c.urlParams_.Set("alt", alt)
18977	c.urlParams_.Set("prettyPrint", "false")
18978	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/advertiserGroups")
18979	urls += "?" + c.urlParams_.Encode()
18980	req, err := http.NewRequest("POST", urls, body)
18981	if err != nil {
18982		return nil, err
18983	}
18984	req.Header = reqHeaders
18985	googleapi.Expand(req.URL, map[string]string{
18986		"profileId": strconv.FormatInt(c.profileId, 10),
18987	})
18988	return gensupport.SendRequest(c.ctx_, c.s.client, req)
18989}
18990
18991// Do executes the "dfareporting.advertiserGroups.insert" call.
18992// Exactly one of *AdvertiserGroup or error will be non-nil. Any non-2xx
18993// status code is an error. Response headers are in either
18994// *AdvertiserGroup.ServerResponse.Header or (if a response was returned
18995// at all) in error.(*googleapi.Error).Header. Use
18996// googleapi.IsNotModified to check whether the returned error was
18997// because http.StatusNotModified was returned.
18998func (c *AdvertiserGroupsInsertCall) Do(opts ...googleapi.CallOption) (*AdvertiserGroup, error) {
18999	gensupport.SetOptions(c.urlParams_, opts...)
19000	res, err := c.doRequest("json")
19001	if res != nil && res.StatusCode == http.StatusNotModified {
19002		if res.Body != nil {
19003			res.Body.Close()
19004		}
19005		return nil, &googleapi.Error{
19006			Code:   res.StatusCode,
19007			Header: res.Header,
19008		}
19009	}
19010	if err != nil {
19011		return nil, err
19012	}
19013	defer googleapi.CloseBody(res)
19014	if err := googleapi.CheckResponse(res); err != nil {
19015		return nil, err
19016	}
19017	ret := &AdvertiserGroup{
19018		ServerResponse: googleapi.ServerResponse{
19019			Header:         res.Header,
19020			HTTPStatusCode: res.StatusCode,
19021		},
19022	}
19023	target := &ret
19024	if err := gensupport.DecodeResponse(target, res); err != nil {
19025		return nil, err
19026	}
19027	return ret, nil
19028	// {
19029	//   "description": "Inserts a new advertiser group.",
19030	//   "flatPath": "userprofiles/{profileId}/advertiserGroups",
19031	//   "httpMethod": "POST",
19032	//   "id": "dfareporting.advertiserGroups.insert",
19033	//   "parameterOrder": [
19034	//     "profileId"
19035	//   ],
19036	//   "parameters": {
19037	//     "profileId": {
19038	//       "description": "User profile ID associated with this request.",
19039	//       "format": "int64",
19040	//       "location": "path",
19041	//       "required": true,
19042	//       "type": "string"
19043	//     }
19044	//   },
19045	//   "path": "userprofiles/{profileId}/advertiserGroups",
19046	//   "request": {
19047	//     "$ref": "AdvertiserGroup"
19048	//   },
19049	//   "response": {
19050	//     "$ref": "AdvertiserGroup"
19051	//   },
19052	//   "scopes": [
19053	//     "https://www.googleapis.com/auth/dfatrafficking"
19054	//   ]
19055	// }
19056
19057}
19058
19059// method id "dfareporting.advertiserGroups.list":
19060
19061type AdvertiserGroupsListCall struct {
19062	s            *Service
19063	profileId    int64
19064	urlParams_   gensupport.URLParams
19065	ifNoneMatch_ string
19066	ctx_         context.Context
19067	header_      http.Header
19068}
19069
19070// List: Retrieves a list of advertiser groups, possibly filtered. This
19071// method supports paging.
19072//
19073// - profileId: User profile ID associated with this request.
19074func (r *AdvertiserGroupsService) List(profileId int64) *AdvertiserGroupsListCall {
19075	c := &AdvertiserGroupsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
19076	c.profileId = profileId
19077	return c
19078}
19079
19080// Ids sets the optional parameter "ids": Select only advertiser groups
19081// with these IDs.
19082func (c *AdvertiserGroupsListCall) Ids(ids ...int64) *AdvertiserGroupsListCall {
19083	var ids_ []string
19084	for _, v := range ids {
19085		ids_ = append(ids_, fmt.Sprint(v))
19086	}
19087	c.urlParams_.SetMulti("ids", ids_)
19088	return c
19089}
19090
19091// MaxResults sets the optional parameter "maxResults": Maximum number
19092// of results to return.
19093func (c *AdvertiserGroupsListCall) MaxResults(maxResults int64) *AdvertiserGroupsListCall {
19094	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
19095	return c
19096}
19097
19098// PageToken sets the optional parameter "pageToken": Value of the
19099// nextPageToken from the previous result page.
19100func (c *AdvertiserGroupsListCall) PageToken(pageToken string) *AdvertiserGroupsListCall {
19101	c.urlParams_.Set("pageToken", pageToken)
19102	return c
19103}
19104
19105// SearchString sets the optional parameter "searchString": Allows
19106// searching for objects by name or ID. Wildcards (*) are allowed. For
19107// example, "advertiser*2015" will return objects with names like
19108// "advertiser group June 2015", "advertiser group April 2015", or
19109// simply "advertiser group 2015". Most of the searches also add
19110// wildcards implicitly at the start and the end of the search string.
19111// For example, a search string of "advertisergroup" will match objects
19112// with name "my advertisergroup", "advertisergroup 2015", or simply
19113// "advertisergroup".
19114func (c *AdvertiserGroupsListCall) SearchString(searchString string) *AdvertiserGroupsListCall {
19115	c.urlParams_.Set("searchString", searchString)
19116	return c
19117}
19118
19119// SortField sets the optional parameter "sortField": Field by which to
19120// sort the list.
19121//
19122// Possible values:
19123//   "ID" (default)
19124//   "NAME"
19125func (c *AdvertiserGroupsListCall) SortField(sortField string) *AdvertiserGroupsListCall {
19126	c.urlParams_.Set("sortField", sortField)
19127	return c
19128}
19129
19130// SortOrder sets the optional parameter "sortOrder": Order of sorted
19131// results.
19132//
19133// Possible values:
19134//   "ASCENDING" (default)
19135//   "DESCENDING"
19136func (c *AdvertiserGroupsListCall) SortOrder(sortOrder string) *AdvertiserGroupsListCall {
19137	c.urlParams_.Set("sortOrder", sortOrder)
19138	return c
19139}
19140
19141// Fields allows partial responses to be retrieved. See
19142// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
19143// for more information.
19144func (c *AdvertiserGroupsListCall) Fields(s ...googleapi.Field) *AdvertiserGroupsListCall {
19145	c.urlParams_.Set("fields", googleapi.CombineFields(s))
19146	return c
19147}
19148
19149// IfNoneMatch sets the optional parameter which makes the operation
19150// fail if the object's ETag matches the given value. This is useful for
19151// getting updates only after the object has changed since the last
19152// request. Use googleapi.IsNotModified to check whether the response
19153// error from Do is the result of In-None-Match.
19154func (c *AdvertiserGroupsListCall) IfNoneMatch(entityTag string) *AdvertiserGroupsListCall {
19155	c.ifNoneMatch_ = entityTag
19156	return c
19157}
19158
19159// Context sets the context to be used in this call's Do method. Any
19160// pending HTTP request will be aborted if the provided context is
19161// canceled.
19162func (c *AdvertiserGroupsListCall) Context(ctx context.Context) *AdvertiserGroupsListCall {
19163	c.ctx_ = ctx
19164	return c
19165}
19166
19167// Header returns an http.Header that can be modified by the caller to
19168// add HTTP headers to the request.
19169func (c *AdvertiserGroupsListCall) Header() http.Header {
19170	if c.header_ == nil {
19171		c.header_ = make(http.Header)
19172	}
19173	return c.header_
19174}
19175
19176func (c *AdvertiserGroupsListCall) doRequest(alt string) (*http.Response, error) {
19177	reqHeaders := make(http.Header)
19178	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
19179	for k, v := range c.header_ {
19180		reqHeaders[k] = v
19181	}
19182	reqHeaders.Set("User-Agent", c.s.userAgent())
19183	if c.ifNoneMatch_ != "" {
19184		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
19185	}
19186	var body io.Reader = nil
19187	c.urlParams_.Set("alt", alt)
19188	c.urlParams_.Set("prettyPrint", "false")
19189	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/advertiserGroups")
19190	urls += "?" + c.urlParams_.Encode()
19191	req, err := http.NewRequest("GET", urls, body)
19192	if err != nil {
19193		return nil, err
19194	}
19195	req.Header = reqHeaders
19196	googleapi.Expand(req.URL, map[string]string{
19197		"profileId": strconv.FormatInt(c.profileId, 10),
19198	})
19199	return gensupport.SendRequest(c.ctx_, c.s.client, req)
19200}
19201
19202// Do executes the "dfareporting.advertiserGroups.list" call.
19203// Exactly one of *AdvertiserGroupsListResponse or error will be
19204// non-nil. Any non-2xx status code is an error. Response headers are in
19205// either *AdvertiserGroupsListResponse.ServerResponse.Header or (if a
19206// response was returned at all) in error.(*googleapi.Error).Header. Use
19207// googleapi.IsNotModified to check whether the returned error was
19208// because http.StatusNotModified was returned.
19209func (c *AdvertiserGroupsListCall) Do(opts ...googleapi.CallOption) (*AdvertiserGroupsListResponse, error) {
19210	gensupport.SetOptions(c.urlParams_, opts...)
19211	res, err := c.doRequest("json")
19212	if res != nil && res.StatusCode == http.StatusNotModified {
19213		if res.Body != nil {
19214			res.Body.Close()
19215		}
19216		return nil, &googleapi.Error{
19217			Code:   res.StatusCode,
19218			Header: res.Header,
19219		}
19220	}
19221	if err != nil {
19222		return nil, err
19223	}
19224	defer googleapi.CloseBody(res)
19225	if err := googleapi.CheckResponse(res); err != nil {
19226		return nil, err
19227	}
19228	ret := &AdvertiserGroupsListResponse{
19229		ServerResponse: googleapi.ServerResponse{
19230			Header:         res.Header,
19231			HTTPStatusCode: res.StatusCode,
19232		},
19233	}
19234	target := &ret
19235	if err := gensupport.DecodeResponse(target, res); err != nil {
19236		return nil, err
19237	}
19238	return ret, nil
19239	// {
19240	//   "description": "Retrieves a list of advertiser groups, possibly filtered. This method supports paging.",
19241	//   "flatPath": "userprofiles/{profileId}/advertiserGroups",
19242	//   "httpMethod": "GET",
19243	//   "id": "dfareporting.advertiserGroups.list",
19244	//   "parameterOrder": [
19245	//     "profileId"
19246	//   ],
19247	//   "parameters": {
19248	//     "ids": {
19249	//       "description": "Select only advertiser groups with these IDs.",
19250	//       "format": "int64",
19251	//       "location": "query",
19252	//       "repeated": true,
19253	//       "type": "string"
19254	//     },
19255	//     "maxResults": {
19256	//       "default": "1000",
19257	//       "description": "Maximum number of results to return.",
19258	//       "format": "int32",
19259	//       "location": "query",
19260	//       "maximum": "1000",
19261	//       "minimum": "0",
19262	//       "type": "integer"
19263	//     },
19264	//     "pageToken": {
19265	//       "description": "Value of the nextPageToken from the previous result page.",
19266	//       "location": "query",
19267	//       "type": "string"
19268	//     },
19269	//     "profileId": {
19270	//       "description": "User profile ID associated with this request.",
19271	//       "format": "int64",
19272	//       "location": "path",
19273	//       "required": true,
19274	//       "type": "string"
19275	//     },
19276	//     "searchString": {
19277	//       "description": "Allows searching for objects by name or ID. Wildcards (*) are allowed. For example, \"advertiser*2015\" will return objects with names like \"advertiser group June 2015\", \"advertiser group April 2015\", or simply \"advertiser group 2015\". Most of the searches also add wildcards implicitly at the start and the end of the search string. For example, a search string of \"advertisergroup\" will match objects with name \"my advertisergroup\", \"advertisergroup 2015\", or simply \"advertisergroup\".",
19278	//       "location": "query",
19279	//       "type": "string"
19280	//     },
19281	//     "sortField": {
19282	//       "default": "ID",
19283	//       "description": "Field by which to sort the list.",
19284	//       "enum": [
19285	//         "ID",
19286	//         "NAME"
19287	//       ],
19288	//       "enumDescriptions": [
19289	//         "",
19290	//         ""
19291	//       ],
19292	//       "location": "query",
19293	//       "type": "string"
19294	//     },
19295	//     "sortOrder": {
19296	//       "default": "ASCENDING",
19297	//       "description": "Order of sorted results.",
19298	//       "enum": [
19299	//         "ASCENDING",
19300	//         "DESCENDING"
19301	//       ],
19302	//       "enumDescriptions": [
19303	//         "",
19304	//         ""
19305	//       ],
19306	//       "location": "query",
19307	//       "type": "string"
19308	//     }
19309	//   },
19310	//   "path": "userprofiles/{profileId}/advertiserGroups",
19311	//   "response": {
19312	//     "$ref": "AdvertiserGroupsListResponse"
19313	//   },
19314	//   "scopes": [
19315	//     "https://www.googleapis.com/auth/dfatrafficking"
19316	//   ]
19317	// }
19318
19319}
19320
19321// Pages invokes f for each page of results.
19322// A non-nil error returned from f will halt the iteration.
19323// The provided context supersedes any context provided to the Context method.
19324func (c *AdvertiserGroupsListCall) Pages(ctx context.Context, f func(*AdvertiserGroupsListResponse) error) error {
19325	c.ctx_ = ctx
19326	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
19327	for {
19328		x, err := c.Do()
19329		if err != nil {
19330			return err
19331		}
19332		if err := f(x); err != nil {
19333			return err
19334		}
19335		if x.NextPageToken == "" {
19336			return nil
19337		}
19338		c.PageToken(x.NextPageToken)
19339	}
19340}
19341
19342// method id "dfareporting.advertiserGroups.patch":
19343
19344type AdvertiserGroupsPatchCall struct {
19345	s               *Service
19346	profileId       int64
19347	advertisergroup *AdvertiserGroup
19348	urlParams_      gensupport.URLParams
19349	ctx_            context.Context
19350	header_         http.Header
19351}
19352
19353// Patch: Updates an existing advertiser group. This method supports
19354// patch semantics.
19355//
19356// - id: AdvertiserGroup ID.
19357// - profileId: User profile ID associated with this request.
19358func (r *AdvertiserGroupsService) Patch(profileId int64, id int64, advertisergroup *AdvertiserGroup) *AdvertiserGroupsPatchCall {
19359	c := &AdvertiserGroupsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
19360	c.profileId = profileId
19361	c.urlParams_.Set("id", fmt.Sprint(id))
19362	c.advertisergroup = advertisergroup
19363	return c
19364}
19365
19366// Fields allows partial responses to be retrieved. See
19367// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
19368// for more information.
19369func (c *AdvertiserGroupsPatchCall) Fields(s ...googleapi.Field) *AdvertiserGroupsPatchCall {
19370	c.urlParams_.Set("fields", googleapi.CombineFields(s))
19371	return c
19372}
19373
19374// Context sets the context to be used in this call's Do method. Any
19375// pending HTTP request will be aborted if the provided context is
19376// canceled.
19377func (c *AdvertiserGroupsPatchCall) Context(ctx context.Context) *AdvertiserGroupsPatchCall {
19378	c.ctx_ = ctx
19379	return c
19380}
19381
19382// Header returns an http.Header that can be modified by the caller to
19383// add HTTP headers to the request.
19384func (c *AdvertiserGroupsPatchCall) Header() http.Header {
19385	if c.header_ == nil {
19386		c.header_ = make(http.Header)
19387	}
19388	return c.header_
19389}
19390
19391func (c *AdvertiserGroupsPatchCall) doRequest(alt string) (*http.Response, error) {
19392	reqHeaders := make(http.Header)
19393	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
19394	for k, v := range c.header_ {
19395		reqHeaders[k] = v
19396	}
19397	reqHeaders.Set("User-Agent", c.s.userAgent())
19398	var body io.Reader = nil
19399	body, err := googleapi.WithoutDataWrapper.JSONReader(c.advertisergroup)
19400	if err != nil {
19401		return nil, err
19402	}
19403	reqHeaders.Set("Content-Type", "application/json")
19404	c.urlParams_.Set("alt", alt)
19405	c.urlParams_.Set("prettyPrint", "false")
19406	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/advertiserGroups")
19407	urls += "?" + c.urlParams_.Encode()
19408	req, err := http.NewRequest("PATCH", urls, body)
19409	if err != nil {
19410		return nil, err
19411	}
19412	req.Header = reqHeaders
19413	googleapi.Expand(req.URL, map[string]string{
19414		"profileId": strconv.FormatInt(c.profileId, 10),
19415	})
19416	return gensupport.SendRequest(c.ctx_, c.s.client, req)
19417}
19418
19419// Do executes the "dfareporting.advertiserGroups.patch" call.
19420// Exactly one of *AdvertiserGroup or error will be non-nil. Any non-2xx
19421// status code is an error. Response headers are in either
19422// *AdvertiserGroup.ServerResponse.Header or (if a response was returned
19423// at all) in error.(*googleapi.Error).Header. Use
19424// googleapi.IsNotModified to check whether the returned error was
19425// because http.StatusNotModified was returned.
19426func (c *AdvertiserGroupsPatchCall) Do(opts ...googleapi.CallOption) (*AdvertiserGroup, error) {
19427	gensupport.SetOptions(c.urlParams_, opts...)
19428	res, err := c.doRequest("json")
19429	if res != nil && res.StatusCode == http.StatusNotModified {
19430		if res.Body != nil {
19431			res.Body.Close()
19432		}
19433		return nil, &googleapi.Error{
19434			Code:   res.StatusCode,
19435			Header: res.Header,
19436		}
19437	}
19438	if err != nil {
19439		return nil, err
19440	}
19441	defer googleapi.CloseBody(res)
19442	if err := googleapi.CheckResponse(res); err != nil {
19443		return nil, err
19444	}
19445	ret := &AdvertiserGroup{
19446		ServerResponse: googleapi.ServerResponse{
19447			Header:         res.Header,
19448			HTTPStatusCode: res.StatusCode,
19449		},
19450	}
19451	target := &ret
19452	if err := gensupport.DecodeResponse(target, res); err != nil {
19453		return nil, err
19454	}
19455	return ret, nil
19456	// {
19457	//   "description": "Updates an existing advertiser group. This method supports patch semantics.",
19458	//   "flatPath": "userprofiles/{profileId}/advertiserGroups",
19459	//   "httpMethod": "PATCH",
19460	//   "id": "dfareporting.advertiserGroups.patch",
19461	//   "parameterOrder": [
19462	//     "profileId",
19463	//     "id"
19464	//   ],
19465	//   "parameters": {
19466	//     "id": {
19467	//       "description": "AdvertiserGroup ID.",
19468	//       "format": "int64",
19469	//       "location": "query",
19470	//       "required": true,
19471	//       "type": "string"
19472	//     },
19473	//     "profileId": {
19474	//       "description": "User profile ID associated with this request.",
19475	//       "format": "int64",
19476	//       "location": "path",
19477	//       "required": true,
19478	//       "type": "string"
19479	//     }
19480	//   },
19481	//   "path": "userprofiles/{profileId}/advertiserGroups",
19482	//   "request": {
19483	//     "$ref": "AdvertiserGroup"
19484	//   },
19485	//   "response": {
19486	//     "$ref": "AdvertiserGroup"
19487	//   },
19488	//   "scopes": [
19489	//     "https://www.googleapis.com/auth/dfatrafficking"
19490	//   ]
19491	// }
19492
19493}
19494
19495// method id "dfareporting.advertiserGroups.update":
19496
19497type AdvertiserGroupsUpdateCall struct {
19498	s               *Service
19499	profileId       int64
19500	advertisergroup *AdvertiserGroup
19501	urlParams_      gensupport.URLParams
19502	ctx_            context.Context
19503	header_         http.Header
19504}
19505
19506// Update: Updates an existing advertiser group.
19507//
19508// - profileId: User profile ID associated with this request.
19509func (r *AdvertiserGroupsService) Update(profileId int64, advertisergroup *AdvertiserGroup) *AdvertiserGroupsUpdateCall {
19510	c := &AdvertiserGroupsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
19511	c.profileId = profileId
19512	c.advertisergroup = advertisergroup
19513	return c
19514}
19515
19516// Fields allows partial responses to be retrieved. See
19517// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
19518// for more information.
19519func (c *AdvertiserGroupsUpdateCall) Fields(s ...googleapi.Field) *AdvertiserGroupsUpdateCall {
19520	c.urlParams_.Set("fields", googleapi.CombineFields(s))
19521	return c
19522}
19523
19524// Context sets the context to be used in this call's Do method. Any
19525// pending HTTP request will be aborted if the provided context is
19526// canceled.
19527func (c *AdvertiserGroupsUpdateCall) Context(ctx context.Context) *AdvertiserGroupsUpdateCall {
19528	c.ctx_ = ctx
19529	return c
19530}
19531
19532// Header returns an http.Header that can be modified by the caller to
19533// add HTTP headers to the request.
19534func (c *AdvertiserGroupsUpdateCall) Header() http.Header {
19535	if c.header_ == nil {
19536		c.header_ = make(http.Header)
19537	}
19538	return c.header_
19539}
19540
19541func (c *AdvertiserGroupsUpdateCall) doRequest(alt string) (*http.Response, error) {
19542	reqHeaders := make(http.Header)
19543	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
19544	for k, v := range c.header_ {
19545		reqHeaders[k] = v
19546	}
19547	reqHeaders.Set("User-Agent", c.s.userAgent())
19548	var body io.Reader = nil
19549	body, err := googleapi.WithoutDataWrapper.JSONReader(c.advertisergroup)
19550	if err != nil {
19551		return nil, err
19552	}
19553	reqHeaders.Set("Content-Type", "application/json")
19554	c.urlParams_.Set("alt", alt)
19555	c.urlParams_.Set("prettyPrint", "false")
19556	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/advertiserGroups")
19557	urls += "?" + c.urlParams_.Encode()
19558	req, err := http.NewRequest("PUT", urls, body)
19559	if err != nil {
19560		return nil, err
19561	}
19562	req.Header = reqHeaders
19563	googleapi.Expand(req.URL, map[string]string{
19564		"profileId": strconv.FormatInt(c.profileId, 10),
19565	})
19566	return gensupport.SendRequest(c.ctx_, c.s.client, req)
19567}
19568
19569// Do executes the "dfareporting.advertiserGroups.update" call.
19570// Exactly one of *AdvertiserGroup or error will be non-nil. Any non-2xx
19571// status code is an error. Response headers are in either
19572// *AdvertiserGroup.ServerResponse.Header or (if a response was returned
19573// at all) in error.(*googleapi.Error).Header. Use
19574// googleapi.IsNotModified to check whether the returned error was
19575// because http.StatusNotModified was returned.
19576func (c *AdvertiserGroupsUpdateCall) Do(opts ...googleapi.CallOption) (*AdvertiserGroup, error) {
19577	gensupport.SetOptions(c.urlParams_, opts...)
19578	res, err := c.doRequest("json")
19579	if res != nil && res.StatusCode == http.StatusNotModified {
19580		if res.Body != nil {
19581			res.Body.Close()
19582		}
19583		return nil, &googleapi.Error{
19584			Code:   res.StatusCode,
19585			Header: res.Header,
19586		}
19587	}
19588	if err != nil {
19589		return nil, err
19590	}
19591	defer googleapi.CloseBody(res)
19592	if err := googleapi.CheckResponse(res); err != nil {
19593		return nil, err
19594	}
19595	ret := &AdvertiserGroup{
19596		ServerResponse: googleapi.ServerResponse{
19597			Header:         res.Header,
19598			HTTPStatusCode: res.StatusCode,
19599		},
19600	}
19601	target := &ret
19602	if err := gensupport.DecodeResponse(target, res); err != nil {
19603		return nil, err
19604	}
19605	return ret, nil
19606	// {
19607	//   "description": "Updates an existing advertiser group.",
19608	//   "flatPath": "userprofiles/{profileId}/advertiserGroups",
19609	//   "httpMethod": "PUT",
19610	//   "id": "dfareporting.advertiserGroups.update",
19611	//   "parameterOrder": [
19612	//     "profileId"
19613	//   ],
19614	//   "parameters": {
19615	//     "profileId": {
19616	//       "description": "User profile ID associated with this request.",
19617	//       "format": "int64",
19618	//       "location": "path",
19619	//       "required": true,
19620	//       "type": "string"
19621	//     }
19622	//   },
19623	//   "path": "userprofiles/{profileId}/advertiserGroups",
19624	//   "request": {
19625	//     "$ref": "AdvertiserGroup"
19626	//   },
19627	//   "response": {
19628	//     "$ref": "AdvertiserGroup"
19629	//   },
19630	//   "scopes": [
19631	//     "https://www.googleapis.com/auth/dfatrafficking"
19632	//   ]
19633	// }
19634
19635}
19636
19637// method id "dfareporting.advertiserLandingPages.get":
19638
19639type AdvertiserLandingPagesGetCall struct {
19640	s            *Service
19641	profileId    int64
19642	id           int64
19643	urlParams_   gensupport.URLParams
19644	ifNoneMatch_ string
19645	ctx_         context.Context
19646	header_      http.Header
19647}
19648
19649// Get: Gets one landing page by ID.
19650//
19651// - id: Landing page ID.
19652// - profileId: User profile ID associated with this request.
19653func (r *AdvertiserLandingPagesService) Get(profileId int64, id int64) *AdvertiserLandingPagesGetCall {
19654	c := &AdvertiserLandingPagesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
19655	c.profileId = profileId
19656	c.id = id
19657	return c
19658}
19659
19660// Fields allows partial responses to be retrieved. See
19661// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
19662// for more information.
19663func (c *AdvertiserLandingPagesGetCall) Fields(s ...googleapi.Field) *AdvertiserLandingPagesGetCall {
19664	c.urlParams_.Set("fields", googleapi.CombineFields(s))
19665	return c
19666}
19667
19668// IfNoneMatch sets the optional parameter which makes the operation
19669// fail if the object's ETag matches the given value. This is useful for
19670// getting updates only after the object has changed since the last
19671// request. Use googleapi.IsNotModified to check whether the response
19672// error from Do is the result of In-None-Match.
19673func (c *AdvertiserLandingPagesGetCall) IfNoneMatch(entityTag string) *AdvertiserLandingPagesGetCall {
19674	c.ifNoneMatch_ = entityTag
19675	return c
19676}
19677
19678// Context sets the context to be used in this call's Do method. Any
19679// pending HTTP request will be aborted if the provided context is
19680// canceled.
19681func (c *AdvertiserLandingPagesGetCall) Context(ctx context.Context) *AdvertiserLandingPagesGetCall {
19682	c.ctx_ = ctx
19683	return c
19684}
19685
19686// Header returns an http.Header that can be modified by the caller to
19687// add HTTP headers to the request.
19688func (c *AdvertiserLandingPagesGetCall) Header() http.Header {
19689	if c.header_ == nil {
19690		c.header_ = make(http.Header)
19691	}
19692	return c.header_
19693}
19694
19695func (c *AdvertiserLandingPagesGetCall) doRequest(alt string) (*http.Response, error) {
19696	reqHeaders := make(http.Header)
19697	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
19698	for k, v := range c.header_ {
19699		reqHeaders[k] = v
19700	}
19701	reqHeaders.Set("User-Agent", c.s.userAgent())
19702	if c.ifNoneMatch_ != "" {
19703		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
19704	}
19705	var body io.Reader = nil
19706	c.urlParams_.Set("alt", alt)
19707	c.urlParams_.Set("prettyPrint", "false")
19708	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/advertiserLandingPages/{id}")
19709	urls += "?" + c.urlParams_.Encode()
19710	req, err := http.NewRequest("GET", urls, body)
19711	if err != nil {
19712		return nil, err
19713	}
19714	req.Header = reqHeaders
19715	googleapi.Expand(req.URL, map[string]string{
19716		"profileId": strconv.FormatInt(c.profileId, 10),
19717		"id":        strconv.FormatInt(c.id, 10),
19718	})
19719	return gensupport.SendRequest(c.ctx_, c.s.client, req)
19720}
19721
19722// Do executes the "dfareporting.advertiserLandingPages.get" call.
19723// Exactly one of *LandingPage or error will be non-nil. Any non-2xx
19724// status code is an error. Response headers are in either
19725// *LandingPage.ServerResponse.Header or (if a response was returned at
19726// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
19727// to check whether the returned error was because
19728// http.StatusNotModified was returned.
19729func (c *AdvertiserLandingPagesGetCall) Do(opts ...googleapi.CallOption) (*LandingPage, error) {
19730	gensupport.SetOptions(c.urlParams_, opts...)
19731	res, err := c.doRequest("json")
19732	if res != nil && res.StatusCode == http.StatusNotModified {
19733		if res.Body != nil {
19734			res.Body.Close()
19735		}
19736		return nil, &googleapi.Error{
19737			Code:   res.StatusCode,
19738			Header: res.Header,
19739		}
19740	}
19741	if err != nil {
19742		return nil, err
19743	}
19744	defer googleapi.CloseBody(res)
19745	if err := googleapi.CheckResponse(res); err != nil {
19746		return nil, err
19747	}
19748	ret := &LandingPage{
19749		ServerResponse: googleapi.ServerResponse{
19750			Header:         res.Header,
19751			HTTPStatusCode: res.StatusCode,
19752		},
19753	}
19754	target := &ret
19755	if err := gensupport.DecodeResponse(target, res); err != nil {
19756		return nil, err
19757	}
19758	return ret, nil
19759	// {
19760	//   "description": "Gets one landing page by ID.",
19761	//   "flatPath": "userprofiles/{profileId}/advertiserLandingPages/{id}",
19762	//   "httpMethod": "GET",
19763	//   "id": "dfareporting.advertiserLandingPages.get",
19764	//   "parameterOrder": [
19765	//     "profileId",
19766	//     "id"
19767	//   ],
19768	//   "parameters": {
19769	//     "id": {
19770	//       "description": "Landing page ID.",
19771	//       "format": "int64",
19772	//       "location": "path",
19773	//       "required": true,
19774	//       "type": "string"
19775	//     },
19776	//     "profileId": {
19777	//       "description": "User profile ID associated with this request.",
19778	//       "format": "int64",
19779	//       "location": "path",
19780	//       "required": true,
19781	//       "type": "string"
19782	//     }
19783	//   },
19784	//   "path": "userprofiles/{profileId}/advertiserLandingPages/{id}",
19785	//   "response": {
19786	//     "$ref": "LandingPage"
19787	//   },
19788	//   "scopes": [
19789	//     "https://www.googleapis.com/auth/dfatrafficking"
19790	//   ]
19791	// }
19792
19793}
19794
19795// method id "dfareporting.advertiserLandingPages.insert":
19796
19797type AdvertiserLandingPagesInsertCall struct {
19798	s           *Service
19799	profileId   int64
19800	landingpage *LandingPage
19801	urlParams_  gensupport.URLParams
19802	ctx_        context.Context
19803	header_     http.Header
19804}
19805
19806// Insert: Inserts a new landing page.
19807//
19808// - profileId: User profile ID associated with this request.
19809func (r *AdvertiserLandingPagesService) Insert(profileId int64, landingpage *LandingPage) *AdvertiserLandingPagesInsertCall {
19810	c := &AdvertiserLandingPagesInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
19811	c.profileId = profileId
19812	c.landingpage = landingpage
19813	return c
19814}
19815
19816// Fields allows partial responses to be retrieved. See
19817// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
19818// for more information.
19819func (c *AdvertiserLandingPagesInsertCall) Fields(s ...googleapi.Field) *AdvertiserLandingPagesInsertCall {
19820	c.urlParams_.Set("fields", googleapi.CombineFields(s))
19821	return c
19822}
19823
19824// Context sets the context to be used in this call's Do method. Any
19825// pending HTTP request will be aborted if the provided context is
19826// canceled.
19827func (c *AdvertiserLandingPagesInsertCall) Context(ctx context.Context) *AdvertiserLandingPagesInsertCall {
19828	c.ctx_ = ctx
19829	return c
19830}
19831
19832// Header returns an http.Header that can be modified by the caller to
19833// add HTTP headers to the request.
19834func (c *AdvertiserLandingPagesInsertCall) Header() http.Header {
19835	if c.header_ == nil {
19836		c.header_ = make(http.Header)
19837	}
19838	return c.header_
19839}
19840
19841func (c *AdvertiserLandingPagesInsertCall) doRequest(alt string) (*http.Response, error) {
19842	reqHeaders := make(http.Header)
19843	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
19844	for k, v := range c.header_ {
19845		reqHeaders[k] = v
19846	}
19847	reqHeaders.Set("User-Agent", c.s.userAgent())
19848	var body io.Reader = nil
19849	body, err := googleapi.WithoutDataWrapper.JSONReader(c.landingpage)
19850	if err != nil {
19851		return nil, err
19852	}
19853	reqHeaders.Set("Content-Type", "application/json")
19854	c.urlParams_.Set("alt", alt)
19855	c.urlParams_.Set("prettyPrint", "false")
19856	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/advertiserLandingPages")
19857	urls += "?" + c.urlParams_.Encode()
19858	req, err := http.NewRequest("POST", urls, body)
19859	if err != nil {
19860		return nil, err
19861	}
19862	req.Header = reqHeaders
19863	googleapi.Expand(req.URL, map[string]string{
19864		"profileId": strconv.FormatInt(c.profileId, 10),
19865	})
19866	return gensupport.SendRequest(c.ctx_, c.s.client, req)
19867}
19868
19869// Do executes the "dfareporting.advertiserLandingPages.insert" call.
19870// Exactly one of *LandingPage or error will be non-nil. Any non-2xx
19871// status code is an error. Response headers are in either
19872// *LandingPage.ServerResponse.Header or (if a response was returned at
19873// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
19874// to check whether the returned error was because
19875// http.StatusNotModified was returned.
19876func (c *AdvertiserLandingPagesInsertCall) Do(opts ...googleapi.CallOption) (*LandingPage, error) {
19877	gensupport.SetOptions(c.urlParams_, opts...)
19878	res, err := c.doRequest("json")
19879	if res != nil && res.StatusCode == http.StatusNotModified {
19880		if res.Body != nil {
19881			res.Body.Close()
19882		}
19883		return nil, &googleapi.Error{
19884			Code:   res.StatusCode,
19885			Header: res.Header,
19886		}
19887	}
19888	if err != nil {
19889		return nil, err
19890	}
19891	defer googleapi.CloseBody(res)
19892	if err := googleapi.CheckResponse(res); err != nil {
19893		return nil, err
19894	}
19895	ret := &LandingPage{
19896		ServerResponse: googleapi.ServerResponse{
19897			Header:         res.Header,
19898			HTTPStatusCode: res.StatusCode,
19899		},
19900	}
19901	target := &ret
19902	if err := gensupport.DecodeResponse(target, res); err != nil {
19903		return nil, err
19904	}
19905	return ret, nil
19906	// {
19907	//   "description": "Inserts a new landing page.",
19908	//   "flatPath": "userprofiles/{profileId}/advertiserLandingPages",
19909	//   "httpMethod": "POST",
19910	//   "id": "dfareporting.advertiserLandingPages.insert",
19911	//   "parameterOrder": [
19912	//     "profileId"
19913	//   ],
19914	//   "parameters": {
19915	//     "profileId": {
19916	//       "description": "User profile ID associated with this request.",
19917	//       "format": "int64",
19918	//       "location": "path",
19919	//       "required": true,
19920	//       "type": "string"
19921	//     }
19922	//   },
19923	//   "path": "userprofiles/{profileId}/advertiserLandingPages",
19924	//   "request": {
19925	//     "$ref": "LandingPage"
19926	//   },
19927	//   "response": {
19928	//     "$ref": "LandingPage"
19929	//   },
19930	//   "scopes": [
19931	//     "https://www.googleapis.com/auth/dfatrafficking"
19932	//   ]
19933	// }
19934
19935}
19936
19937// method id "dfareporting.advertiserLandingPages.list":
19938
19939type AdvertiserLandingPagesListCall struct {
19940	s            *Service
19941	profileId    int64
19942	urlParams_   gensupport.URLParams
19943	ifNoneMatch_ string
19944	ctx_         context.Context
19945	header_      http.Header
19946}
19947
19948// List: Retrieves a list of landing pages.
19949//
19950// - profileId: User profile ID associated with this request.
19951func (r *AdvertiserLandingPagesService) List(profileId int64) *AdvertiserLandingPagesListCall {
19952	c := &AdvertiserLandingPagesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
19953	c.profileId = profileId
19954	return c
19955}
19956
19957// AdvertiserIds sets the optional parameter "advertiserIds": Select
19958// only landing pages that belong to these advertisers.
19959func (c *AdvertiserLandingPagesListCall) AdvertiserIds(advertiserIds ...int64) *AdvertiserLandingPagesListCall {
19960	var advertiserIds_ []string
19961	for _, v := range advertiserIds {
19962		advertiserIds_ = append(advertiserIds_, fmt.Sprint(v))
19963	}
19964	c.urlParams_.SetMulti("advertiserIds", advertiserIds_)
19965	return c
19966}
19967
19968// Archived sets the optional parameter "archived": Select only archived
19969// landing pages. Don't set this field to select both archived and
19970// non-archived landing pages.
19971func (c *AdvertiserLandingPagesListCall) Archived(archived bool) *AdvertiserLandingPagesListCall {
19972	c.urlParams_.Set("archived", fmt.Sprint(archived))
19973	return c
19974}
19975
19976// CampaignIds sets the optional parameter "campaignIds": Select only
19977// landing pages that are associated with these campaigns.
19978func (c *AdvertiserLandingPagesListCall) CampaignIds(campaignIds ...int64) *AdvertiserLandingPagesListCall {
19979	var campaignIds_ []string
19980	for _, v := range campaignIds {
19981		campaignIds_ = append(campaignIds_, fmt.Sprint(v))
19982	}
19983	c.urlParams_.SetMulti("campaignIds", campaignIds_)
19984	return c
19985}
19986
19987// Ids sets the optional parameter "ids": Select only landing pages with
19988// these IDs.
19989func (c *AdvertiserLandingPagesListCall) Ids(ids ...int64) *AdvertiserLandingPagesListCall {
19990	var ids_ []string
19991	for _, v := range ids {
19992		ids_ = append(ids_, fmt.Sprint(v))
19993	}
19994	c.urlParams_.SetMulti("ids", ids_)
19995	return c
19996}
19997
19998// MaxResults sets the optional parameter "maxResults": Maximum number
19999// of results to return.
20000func (c *AdvertiserLandingPagesListCall) MaxResults(maxResults int64) *AdvertiserLandingPagesListCall {
20001	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
20002	return c
20003}
20004
20005// PageToken sets the optional parameter "pageToken": Value of the
20006// nextPageToken from the previous result page.
20007func (c *AdvertiserLandingPagesListCall) PageToken(pageToken string) *AdvertiserLandingPagesListCall {
20008	c.urlParams_.Set("pageToken", pageToken)
20009	return c
20010}
20011
20012// SearchString sets the optional parameter "searchString": Allows
20013// searching for landing pages by name or ID. Wildcards (*) are allowed.
20014// For example, "landingpage*2017" will return landing pages with names
20015// like "landingpage July 2017", "landingpage March 2017", or simply
20016// "landingpage 2017". Most of the searches also add wildcards
20017// implicitly at the start and the end of the search string. For
20018// example, a search string of "landingpage" will match campaigns with
20019// name "my landingpage", "landingpage 2015", or simply "landingpage".
20020func (c *AdvertiserLandingPagesListCall) SearchString(searchString string) *AdvertiserLandingPagesListCall {
20021	c.urlParams_.Set("searchString", searchString)
20022	return c
20023}
20024
20025// SortField sets the optional parameter "sortField": Field by which to
20026// sort the list.
20027//
20028// Possible values:
20029//   "ID" (default)
20030//   "NAME"
20031func (c *AdvertiserLandingPagesListCall) SortField(sortField string) *AdvertiserLandingPagesListCall {
20032	c.urlParams_.Set("sortField", sortField)
20033	return c
20034}
20035
20036// SortOrder sets the optional parameter "sortOrder": Order of sorted
20037// results.
20038//
20039// Possible values:
20040//   "ASCENDING" (default)
20041//   "DESCENDING"
20042func (c *AdvertiserLandingPagesListCall) SortOrder(sortOrder string) *AdvertiserLandingPagesListCall {
20043	c.urlParams_.Set("sortOrder", sortOrder)
20044	return c
20045}
20046
20047// SubaccountId sets the optional parameter "subaccountId": Select only
20048// landing pages that belong to this subaccount.
20049func (c *AdvertiserLandingPagesListCall) SubaccountId(subaccountId int64) *AdvertiserLandingPagesListCall {
20050	c.urlParams_.Set("subaccountId", fmt.Sprint(subaccountId))
20051	return c
20052}
20053
20054// Fields allows partial responses to be retrieved. See
20055// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
20056// for more information.
20057func (c *AdvertiserLandingPagesListCall) Fields(s ...googleapi.Field) *AdvertiserLandingPagesListCall {
20058	c.urlParams_.Set("fields", googleapi.CombineFields(s))
20059	return c
20060}
20061
20062// IfNoneMatch sets the optional parameter which makes the operation
20063// fail if the object's ETag matches the given value. This is useful for
20064// getting updates only after the object has changed since the last
20065// request. Use googleapi.IsNotModified to check whether the response
20066// error from Do is the result of In-None-Match.
20067func (c *AdvertiserLandingPagesListCall) IfNoneMatch(entityTag string) *AdvertiserLandingPagesListCall {
20068	c.ifNoneMatch_ = entityTag
20069	return c
20070}
20071
20072// Context sets the context to be used in this call's Do method. Any
20073// pending HTTP request will be aborted if the provided context is
20074// canceled.
20075func (c *AdvertiserLandingPagesListCall) Context(ctx context.Context) *AdvertiserLandingPagesListCall {
20076	c.ctx_ = ctx
20077	return c
20078}
20079
20080// Header returns an http.Header that can be modified by the caller to
20081// add HTTP headers to the request.
20082func (c *AdvertiserLandingPagesListCall) Header() http.Header {
20083	if c.header_ == nil {
20084		c.header_ = make(http.Header)
20085	}
20086	return c.header_
20087}
20088
20089func (c *AdvertiserLandingPagesListCall) doRequest(alt string) (*http.Response, error) {
20090	reqHeaders := make(http.Header)
20091	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
20092	for k, v := range c.header_ {
20093		reqHeaders[k] = v
20094	}
20095	reqHeaders.Set("User-Agent", c.s.userAgent())
20096	if c.ifNoneMatch_ != "" {
20097		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
20098	}
20099	var body io.Reader = nil
20100	c.urlParams_.Set("alt", alt)
20101	c.urlParams_.Set("prettyPrint", "false")
20102	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/advertiserLandingPages")
20103	urls += "?" + c.urlParams_.Encode()
20104	req, err := http.NewRequest("GET", urls, body)
20105	if err != nil {
20106		return nil, err
20107	}
20108	req.Header = reqHeaders
20109	googleapi.Expand(req.URL, map[string]string{
20110		"profileId": strconv.FormatInt(c.profileId, 10),
20111	})
20112	return gensupport.SendRequest(c.ctx_, c.s.client, req)
20113}
20114
20115// Do executes the "dfareporting.advertiserLandingPages.list" call.
20116// Exactly one of *AdvertiserLandingPagesListResponse or error will be
20117// non-nil. Any non-2xx status code is an error. Response headers are in
20118// either *AdvertiserLandingPagesListResponse.ServerResponse.Header or
20119// (if a response was returned at all) in
20120// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
20121// whether the returned error was because http.StatusNotModified was
20122// returned.
20123func (c *AdvertiserLandingPagesListCall) Do(opts ...googleapi.CallOption) (*AdvertiserLandingPagesListResponse, error) {
20124	gensupport.SetOptions(c.urlParams_, opts...)
20125	res, err := c.doRequest("json")
20126	if res != nil && res.StatusCode == http.StatusNotModified {
20127		if res.Body != nil {
20128			res.Body.Close()
20129		}
20130		return nil, &googleapi.Error{
20131			Code:   res.StatusCode,
20132			Header: res.Header,
20133		}
20134	}
20135	if err != nil {
20136		return nil, err
20137	}
20138	defer googleapi.CloseBody(res)
20139	if err := googleapi.CheckResponse(res); err != nil {
20140		return nil, err
20141	}
20142	ret := &AdvertiserLandingPagesListResponse{
20143		ServerResponse: googleapi.ServerResponse{
20144			Header:         res.Header,
20145			HTTPStatusCode: res.StatusCode,
20146		},
20147	}
20148	target := &ret
20149	if err := gensupport.DecodeResponse(target, res); err != nil {
20150		return nil, err
20151	}
20152	return ret, nil
20153	// {
20154	//   "description": "Retrieves a list of landing pages.",
20155	//   "flatPath": "userprofiles/{profileId}/advertiserLandingPages",
20156	//   "httpMethod": "GET",
20157	//   "id": "dfareporting.advertiserLandingPages.list",
20158	//   "parameterOrder": [
20159	//     "profileId"
20160	//   ],
20161	//   "parameters": {
20162	//     "advertiserIds": {
20163	//       "description": "Select only landing pages that belong to these advertisers.",
20164	//       "format": "int64",
20165	//       "location": "query",
20166	//       "repeated": true,
20167	//       "type": "string"
20168	//     },
20169	//     "archived": {
20170	//       "description": "Select only archived landing pages. Don't set this field to select both archived and non-archived landing pages.",
20171	//       "location": "query",
20172	//       "type": "boolean"
20173	//     },
20174	//     "campaignIds": {
20175	//       "description": "Select only landing pages that are associated with these campaigns.",
20176	//       "format": "int64",
20177	//       "location": "query",
20178	//       "repeated": true,
20179	//       "type": "string"
20180	//     },
20181	//     "ids": {
20182	//       "description": "Select only landing pages with these IDs.",
20183	//       "format": "int64",
20184	//       "location": "query",
20185	//       "repeated": true,
20186	//       "type": "string"
20187	//     },
20188	//     "maxResults": {
20189	//       "default": "1000",
20190	//       "description": "Maximum number of results to return.",
20191	//       "format": "int32",
20192	//       "location": "query",
20193	//       "maximum": "1000",
20194	//       "minimum": "0",
20195	//       "type": "integer"
20196	//     },
20197	//     "pageToken": {
20198	//       "description": "Value of the nextPageToken from the previous result page.",
20199	//       "location": "query",
20200	//       "type": "string"
20201	//     },
20202	//     "profileId": {
20203	//       "description": "User profile ID associated with this request.",
20204	//       "format": "int64",
20205	//       "location": "path",
20206	//       "required": true,
20207	//       "type": "string"
20208	//     },
20209	//     "searchString": {
20210	//       "description": "Allows searching for landing pages by name or ID. Wildcards (*) are allowed. For example, \"landingpage*2017\" will return landing pages with names like \"landingpage July 2017\", \"landingpage March 2017\", or simply \"landingpage 2017\". Most of the searches also add wildcards implicitly at the start and the end of the search string. For example, a search string of \"landingpage\" will match campaigns with name \"my landingpage\", \"landingpage 2015\", or simply \"landingpage\".",
20211	//       "location": "query",
20212	//       "type": "string"
20213	//     },
20214	//     "sortField": {
20215	//       "default": "ID",
20216	//       "description": "Field by which to sort the list.",
20217	//       "enum": [
20218	//         "ID",
20219	//         "NAME"
20220	//       ],
20221	//       "enumDescriptions": [
20222	//         "",
20223	//         ""
20224	//       ],
20225	//       "location": "query",
20226	//       "type": "string"
20227	//     },
20228	//     "sortOrder": {
20229	//       "default": "ASCENDING",
20230	//       "description": "Order of sorted results.",
20231	//       "enum": [
20232	//         "ASCENDING",
20233	//         "DESCENDING"
20234	//       ],
20235	//       "enumDescriptions": [
20236	//         "",
20237	//         ""
20238	//       ],
20239	//       "location": "query",
20240	//       "type": "string"
20241	//     },
20242	//     "subaccountId": {
20243	//       "description": "Select only landing pages that belong to this subaccount.",
20244	//       "format": "int64",
20245	//       "location": "query",
20246	//       "type": "string"
20247	//     }
20248	//   },
20249	//   "path": "userprofiles/{profileId}/advertiserLandingPages",
20250	//   "response": {
20251	//     "$ref": "AdvertiserLandingPagesListResponse"
20252	//   },
20253	//   "scopes": [
20254	//     "https://www.googleapis.com/auth/dfatrafficking"
20255	//   ]
20256	// }
20257
20258}
20259
20260// Pages invokes f for each page of results.
20261// A non-nil error returned from f will halt the iteration.
20262// The provided context supersedes any context provided to the Context method.
20263func (c *AdvertiserLandingPagesListCall) Pages(ctx context.Context, f func(*AdvertiserLandingPagesListResponse) error) error {
20264	c.ctx_ = ctx
20265	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
20266	for {
20267		x, err := c.Do()
20268		if err != nil {
20269			return err
20270		}
20271		if err := f(x); err != nil {
20272			return err
20273		}
20274		if x.NextPageToken == "" {
20275			return nil
20276		}
20277		c.PageToken(x.NextPageToken)
20278	}
20279}
20280
20281// method id "dfareporting.advertiserLandingPages.patch":
20282
20283type AdvertiserLandingPagesPatchCall struct {
20284	s           *Service
20285	profileId   int64
20286	landingpage *LandingPage
20287	urlParams_  gensupport.URLParams
20288	ctx_        context.Context
20289	header_     http.Header
20290}
20291
20292// Patch: Updates an existing advertiser landing page. This method
20293// supports patch semantics.
20294//
20295// - id: LandingPage ID.
20296// - profileId: User profile ID associated with this request.
20297func (r *AdvertiserLandingPagesService) Patch(profileId int64, id int64, landingpage *LandingPage) *AdvertiserLandingPagesPatchCall {
20298	c := &AdvertiserLandingPagesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
20299	c.profileId = profileId
20300	c.urlParams_.Set("id", fmt.Sprint(id))
20301	c.landingpage = landingpage
20302	return c
20303}
20304
20305// Fields allows partial responses to be retrieved. See
20306// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
20307// for more information.
20308func (c *AdvertiserLandingPagesPatchCall) Fields(s ...googleapi.Field) *AdvertiserLandingPagesPatchCall {
20309	c.urlParams_.Set("fields", googleapi.CombineFields(s))
20310	return c
20311}
20312
20313// Context sets the context to be used in this call's Do method. Any
20314// pending HTTP request will be aborted if the provided context is
20315// canceled.
20316func (c *AdvertiserLandingPagesPatchCall) Context(ctx context.Context) *AdvertiserLandingPagesPatchCall {
20317	c.ctx_ = ctx
20318	return c
20319}
20320
20321// Header returns an http.Header that can be modified by the caller to
20322// add HTTP headers to the request.
20323func (c *AdvertiserLandingPagesPatchCall) Header() http.Header {
20324	if c.header_ == nil {
20325		c.header_ = make(http.Header)
20326	}
20327	return c.header_
20328}
20329
20330func (c *AdvertiserLandingPagesPatchCall) doRequest(alt string) (*http.Response, error) {
20331	reqHeaders := make(http.Header)
20332	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
20333	for k, v := range c.header_ {
20334		reqHeaders[k] = v
20335	}
20336	reqHeaders.Set("User-Agent", c.s.userAgent())
20337	var body io.Reader = nil
20338	body, err := googleapi.WithoutDataWrapper.JSONReader(c.landingpage)
20339	if err != nil {
20340		return nil, err
20341	}
20342	reqHeaders.Set("Content-Type", "application/json")
20343	c.urlParams_.Set("alt", alt)
20344	c.urlParams_.Set("prettyPrint", "false")
20345	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/advertiserLandingPages")
20346	urls += "?" + c.urlParams_.Encode()
20347	req, err := http.NewRequest("PATCH", urls, body)
20348	if err != nil {
20349		return nil, err
20350	}
20351	req.Header = reqHeaders
20352	googleapi.Expand(req.URL, map[string]string{
20353		"profileId": strconv.FormatInt(c.profileId, 10),
20354	})
20355	return gensupport.SendRequest(c.ctx_, c.s.client, req)
20356}
20357
20358// Do executes the "dfareporting.advertiserLandingPages.patch" call.
20359// Exactly one of *LandingPage or error will be non-nil. Any non-2xx
20360// status code is an error. Response headers are in either
20361// *LandingPage.ServerResponse.Header or (if a response was returned at
20362// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
20363// to check whether the returned error was because
20364// http.StatusNotModified was returned.
20365func (c *AdvertiserLandingPagesPatchCall) Do(opts ...googleapi.CallOption) (*LandingPage, error) {
20366	gensupport.SetOptions(c.urlParams_, opts...)
20367	res, err := c.doRequest("json")
20368	if res != nil && res.StatusCode == http.StatusNotModified {
20369		if res.Body != nil {
20370			res.Body.Close()
20371		}
20372		return nil, &googleapi.Error{
20373			Code:   res.StatusCode,
20374			Header: res.Header,
20375		}
20376	}
20377	if err != nil {
20378		return nil, err
20379	}
20380	defer googleapi.CloseBody(res)
20381	if err := googleapi.CheckResponse(res); err != nil {
20382		return nil, err
20383	}
20384	ret := &LandingPage{
20385		ServerResponse: googleapi.ServerResponse{
20386			Header:         res.Header,
20387			HTTPStatusCode: res.StatusCode,
20388		},
20389	}
20390	target := &ret
20391	if err := gensupport.DecodeResponse(target, res); err != nil {
20392		return nil, err
20393	}
20394	return ret, nil
20395	// {
20396	//   "description": "Updates an existing advertiser landing page. This method supports patch semantics.",
20397	//   "flatPath": "userprofiles/{profileId}/advertiserLandingPages",
20398	//   "httpMethod": "PATCH",
20399	//   "id": "dfareporting.advertiserLandingPages.patch",
20400	//   "parameterOrder": [
20401	//     "profileId",
20402	//     "id"
20403	//   ],
20404	//   "parameters": {
20405	//     "id": {
20406	//       "description": "LandingPage ID.",
20407	//       "format": "int64",
20408	//       "location": "query",
20409	//       "required": true,
20410	//       "type": "string"
20411	//     },
20412	//     "profileId": {
20413	//       "description": "User profile ID associated with this request.",
20414	//       "format": "int64",
20415	//       "location": "path",
20416	//       "required": true,
20417	//       "type": "string"
20418	//     }
20419	//   },
20420	//   "path": "userprofiles/{profileId}/advertiserLandingPages",
20421	//   "request": {
20422	//     "$ref": "LandingPage"
20423	//   },
20424	//   "response": {
20425	//     "$ref": "LandingPage"
20426	//   },
20427	//   "scopes": [
20428	//     "https://www.googleapis.com/auth/dfatrafficking"
20429	//   ]
20430	// }
20431
20432}
20433
20434// method id "dfareporting.advertiserLandingPages.update":
20435
20436type AdvertiserLandingPagesUpdateCall struct {
20437	s           *Service
20438	profileId   int64
20439	landingpage *LandingPage
20440	urlParams_  gensupport.URLParams
20441	ctx_        context.Context
20442	header_     http.Header
20443}
20444
20445// Update: Updates an existing landing page.
20446//
20447// - profileId: User profile ID associated with this request.
20448func (r *AdvertiserLandingPagesService) Update(profileId int64, landingpage *LandingPage) *AdvertiserLandingPagesUpdateCall {
20449	c := &AdvertiserLandingPagesUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
20450	c.profileId = profileId
20451	c.landingpage = landingpage
20452	return c
20453}
20454
20455// Fields allows partial responses to be retrieved. See
20456// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
20457// for more information.
20458func (c *AdvertiserLandingPagesUpdateCall) Fields(s ...googleapi.Field) *AdvertiserLandingPagesUpdateCall {
20459	c.urlParams_.Set("fields", googleapi.CombineFields(s))
20460	return c
20461}
20462
20463// Context sets the context to be used in this call's Do method. Any
20464// pending HTTP request will be aborted if the provided context is
20465// canceled.
20466func (c *AdvertiserLandingPagesUpdateCall) Context(ctx context.Context) *AdvertiserLandingPagesUpdateCall {
20467	c.ctx_ = ctx
20468	return c
20469}
20470
20471// Header returns an http.Header that can be modified by the caller to
20472// add HTTP headers to the request.
20473func (c *AdvertiserLandingPagesUpdateCall) Header() http.Header {
20474	if c.header_ == nil {
20475		c.header_ = make(http.Header)
20476	}
20477	return c.header_
20478}
20479
20480func (c *AdvertiserLandingPagesUpdateCall) doRequest(alt string) (*http.Response, error) {
20481	reqHeaders := make(http.Header)
20482	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
20483	for k, v := range c.header_ {
20484		reqHeaders[k] = v
20485	}
20486	reqHeaders.Set("User-Agent", c.s.userAgent())
20487	var body io.Reader = nil
20488	body, err := googleapi.WithoutDataWrapper.JSONReader(c.landingpage)
20489	if err != nil {
20490		return nil, err
20491	}
20492	reqHeaders.Set("Content-Type", "application/json")
20493	c.urlParams_.Set("alt", alt)
20494	c.urlParams_.Set("prettyPrint", "false")
20495	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/advertiserLandingPages")
20496	urls += "?" + c.urlParams_.Encode()
20497	req, err := http.NewRequest("PUT", urls, body)
20498	if err != nil {
20499		return nil, err
20500	}
20501	req.Header = reqHeaders
20502	googleapi.Expand(req.URL, map[string]string{
20503		"profileId": strconv.FormatInt(c.profileId, 10),
20504	})
20505	return gensupport.SendRequest(c.ctx_, c.s.client, req)
20506}
20507
20508// Do executes the "dfareporting.advertiserLandingPages.update" call.
20509// Exactly one of *LandingPage or error will be non-nil. Any non-2xx
20510// status code is an error. Response headers are in either
20511// *LandingPage.ServerResponse.Header or (if a response was returned at
20512// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
20513// to check whether the returned error was because
20514// http.StatusNotModified was returned.
20515func (c *AdvertiserLandingPagesUpdateCall) Do(opts ...googleapi.CallOption) (*LandingPage, error) {
20516	gensupport.SetOptions(c.urlParams_, opts...)
20517	res, err := c.doRequest("json")
20518	if res != nil && res.StatusCode == http.StatusNotModified {
20519		if res.Body != nil {
20520			res.Body.Close()
20521		}
20522		return nil, &googleapi.Error{
20523			Code:   res.StatusCode,
20524			Header: res.Header,
20525		}
20526	}
20527	if err != nil {
20528		return nil, err
20529	}
20530	defer googleapi.CloseBody(res)
20531	if err := googleapi.CheckResponse(res); err != nil {
20532		return nil, err
20533	}
20534	ret := &LandingPage{
20535		ServerResponse: googleapi.ServerResponse{
20536			Header:         res.Header,
20537			HTTPStatusCode: res.StatusCode,
20538		},
20539	}
20540	target := &ret
20541	if err := gensupport.DecodeResponse(target, res); err != nil {
20542		return nil, err
20543	}
20544	return ret, nil
20545	// {
20546	//   "description": "Updates an existing landing page.",
20547	//   "flatPath": "userprofiles/{profileId}/advertiserLandingPages",
20548	//   "httpMethod": "PUT",
20549	//   "id": "dfareporting.advertiserLandingPages.update",
20550	//   "parameterOrder": [
20551	//     "profileId"
20552	//   ],
20553	//   "parameters": {
20554	//     "profileId": {
20555	//       "description": "User profile ID associated with this request.",
20556	//       "format": "int64",
20557	//       "location": "path",
20558	//       "required": true,
20559	//       "type": "string"
20560	//     }
20561	//   },
20562	//   "path": "userprofiles/{profileId}/advertiserLandingPages",
20563	//   "request": {
20564	//     "$ref": "LandingPage"
20565	//   },
20566	//   "response": {
20567	//     "$ref": "LandingPage"
20568	//   },
20569	//   "scopes": [
20570	//     "https://www.googleapis.com/auth/dfatrafficking"
20571	//   ]
20572	// }
20573
20574}
20575
20576// method id "dfareporting.advertisers.get":
20577
20578type AdvertisersGetCall struct {
20579	s            *Service
20580	profileId    int64
20581	id           int64
20582	urlParams_   gensupport.URLParams
20583	ifNoneMatch_ string
20584	ctx_         context.Context
20585	header_      http.Header
20586}
20587
20588// Get: Gets one advertiser by ID.
20589//
20590// - id: Advertiser ID.
20591// - profileId: User profile ID associated with this request.
20592func (r *AdvertisersService) Get(profileId int64, id int64) *AdvertisersGetCall {
20593	c := &AdvertisersGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
20594	c.profileId = profileId
20595	c.id = id
20596	return c
20597}
20598
20599// Fields allows partial responses to be retrieved. See
20600// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
20601// for more information.
20602func (c *AdvertisersGetCall) Fields(s ...googleapi.Field) *AdvertisersGetCall {
20603	c.urlParams_.Set("fields", googleapi.CombineFields(s))
20604	return c
20605}
20606
20607// IfNoneMatch sets the optional parameter which makes the operation
20608// fail if the object's ETag matches the given value. This is useful for
20609// getting updates only after the object has changed since the last
20610// request. Use googleapi.IsNotModified to check whether the response
20611// error from Do is the result of In-None-Match.
20612func (c *AdvertisersGetCall) IfNoneMatch(entityTag string) *AdvertisersGetCall {
20613	c.ifNoneMatch_ = entityTag
20614	return c
20615}
20616
20617// Context sets the context to be used in this call's Do method. Any
20618// pending HTTP request will be aborted if the provided context is
20619// canceled.
20620func (c *AdvertisersGetCall) Context(ctx context.Context) *AdvertisersGetCall {
20621	c.ctx_ = ctx
20622	return c
20623}
20624
20625// Header returns an http.Header that can be modified by the caller to
20626// add HTTP headers to the request.
20627func (c *AdvertisersGetCall) Header() http.Header {
20628	if c.header_ == nil {
20629		c.header_ = make(http.Header)
20630	}
20631	return c.header_
20632}
20633
20634func (c *AdvertisersGetCall) doRequest(alt string) (*http.Response, error) {
20635	reqHeaders := make(http.Header)
20636	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
20637	for k, v := range c.header_ {
20638		reqHeaders[k] = v
20639	}
20640	reqHeaders.Set("User-Agent", c.s.userAgent())
20641	if c.ifNoneMatch_ != "" {
20642		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
20643	}
20644	var body io.Reader = nil
20645	c.urlParams_.Set("alt", alt)
20646	c.urlParams_.Set("prettyPrint", "false")
20647	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/advertisers/{id}")
20648	urls += "?" + c.urlParams_.Encode()
20649	req, err := http.NewRequest("GET", urls, body)
20650	if err != nil {
20651		return nil, err
20652	}
20653	req.Header = reqHeaders
20654	googleapi.Expand(req.URL, map[string]string{
20655		"profileId": strconv.FormatInt(c.profileId, 10),
20656		"id":        strconv.FormatInt(c.id, 10),
20657	})
20658	return gensupport.SendRequest(c.ctx_, c.s.client, req)
20659}
20660
20661// Do executes the "dfareporting.advertisers.get" call.
20662// Exactly one of *Advertiser or error will be non-nil. Any non-2xx
20663// status code is an error. Response headers are in either
20664// *Advertiser.ServerResponse.Header or (if a response was returned at
20665// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
20666// to check whether the returned error was because
20667// http.StatusNotModified was returned.
20668func (c *AdvertisersGetCall) Do(opts ...googleapi.CallOption) (*Advertiser, error) {
20669	gensupport.SetOptions(c.urlParams_, opts...)
20670	res, err := c.doRequest("json")
20671	if res != nil && res.StatusCode == http.StatusNotModified {
20672		if res.Body != nil {
20673			res.Body.Close()
20674		}
20675		return nil, &googleapi.Error{
20676			Code:   res.StatusCode,
20677			Header: res.Header,
20678		}
20679	}
20680	if err != nil {
20681		return nil, err
20682	}
20683	defer googleapi.CloseBody(res)
20684	if err := googleapi.CheckResponse(res); err != nil {
20685		return nil, err
20686	}
20687	ret := &Advertiser{
20688		ServerResponse: googleapi.ServerResponse{
20689			Header:         res.Header,
20690			HTTPStatusCode: res.StatusCode,
20691		},
20692	}
20693	target := &ret
20694	if err := gensupport.DecodeResponse(target, res); err != nil {
20695		return nil, err
20696	}
20697	return ret, nil
20698	// {
20699	//   "description": "Gets one advertiser by ID.",
20700	//   "flatPath": "userprofiles/{profileId}/advertisers/{id}",
20701	//   "httpMethod": "GET",
20702	//   "id": "dfareporting.advertisers.get",
20703	//   "parameterOrder": [
20704	//     "profileId",
20705	//     "id"
20706	//   ],
20707	//   "parameters": {
20708	//     "id": {
20709	//       "description": "Advertiser ID.",
20710	//       "format": "int64",
20711	//       "location": "path",
20712	//       "required": true,
20713	//       "type": "string"
20714	//     },
20715	//     "profileId": {
20716	//       "description": "User profile ID associated with this request.",
20717	//       "format": "int64",
20718	//       "location": "path",
20719	//       "required": true,
20720	//       "type": "string"
20721	//     }
20722	//   },
20723	//   "path": "userprofiles/{profileId}/advertisers/{id}",
20724	//   "response": {
20725	//     "$ref": "Advertiser"
20726	//   },
20727	//   "scopes": [
20728	//     "https://www.googleapis.com/auth/dfatrafficking"
20729	//   ]
20730	// }
20731
20732}
20733
20734// method id "dfareporting.advertisers.insert":
20735
20736type AdvertisersInsertCall struct {
20737	s          *Service
20738	profileId  int64
20739	advertiser *Advertiser
20740	urlParams_ gensupport.URLParams
20741	ctx_       context.Context
20742	header_    http.Header
20743}
20744
20745// Insert: Inserts a new advertiser.
20746//
20747// - profileId: User profile ID associated with this request.
20748func (r *AdvertisersService) Insert(profileId int64, advertiser *Advertiser) *AdvertisersInsertCall {
20749	c := &AdvertisersInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
20750	c.profileId = profileId
20751	c.advertiser = advertiser
20752	return c
20753}
20754
20755// Fields allows partial responses to be retrieved. See
20756// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
20757// for more information.
20758func (c *AdvertisersInsertCall) Fields(s ...googleapi.Field) *AdvertisersInsertCall {
20759	c.urlParams_.Set("fields", googleapi.CombineFields(s))
20760	return c
20761}
20762
20763// Context sets the context to be used in this call's Do method. Any
20764// pending HTTP request will be aborted if the provided context is
20765// canceled.
20766func (c *AdvertisersInsertCall) Context(ctx context.Context) *AdvertisersInsertCall {
20767	c.ctx_ = ctx
20768	return c
20769}
20770
20771// Header returns an http.Header that can be modified by the caller to
20772// add HTTP headers to the request.
20773func (c *AdvertisersInsertCall) Header() http.Header {
20774	if c.header_ == nil {
20775		c.header_ = make(http.Header)
20776	}
20777	return c.header_
20778}
20779
20780func (c *AdvertisersInsertCall) doRequest(alt string) (*http.Response, error) {
20781	reqHeaders := make(http.Header)
20782	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
20783	for k, v := range c.header_ {
20784		reqHeaders[k] = v
20785	}
20786	reqHeaders.Set("User-Agent", c.s.userAgent())
20787	var body io.Reader = nil
20788	body, err := googleapi.WithoutDataWrapper.JSONReader(c.advertiser)
20789	if err != nil {
20790		return nil, err
20791	}
20792	reqHeaders.Set("Content-Type", "application/json")
20793	c.urlParams_.Set("alt", alt)
20794	c.urlParams_.Set("prettyPrint", "false")
20795	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/advertisers")
20796	urls += "?" + c.urlParams_.Encode()
20797	req, err := http.NewRequest("POST", urls, body)
20798	if err != nil {
20799		return nil, err
20800	}
20801	req.Header = reqHeaders
20802	googleapi.Expand(req.URL, map[string]string{
20803		"profileId": strconv.FormatInt(c.profileId, 10),
20804	})
20805	return gensupport.SendRequest(c.ctx_, c.s.client, req)
20806}
20807
20808// Do executes the "dfareporting.advertisers.insert" call.
20809// Exactly one of *Advertiser or error will be non-nil. Any non-2xx
20810// status code is an error. Response headers are in either
20811// *Advertiser.ServerResponse.Header or (if a response was returned at
20812// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
20813// to check whether the returned error was because
20814// http.StatusNotModified was returned.
20815func (c *AdvertisersInsertCall) Do(opts ...googleapi.CallOption) (*Advertiser, error) {
20816	gensupport.SetOptions(c.urlParams_, opts...)
20817	res, err := c.doRequest("json")
20818	if res != nil && res.StatusCode == http.StatusNotModified {
20819		if res.Body != nil {
20820			res.Body.Close()
20821		}
20822		return nil, &googleapi.Error{
20823			Code:   res.StatusCode,
20824			Header: res.Header,
20825		}
20826	}
20827	if err != nil {
20828		return nil, err
20829	}
20830	defer googleapi.CloseBody(res)
20831	if err := googleapi.CheckResponse(res); err != nil {
20832		return nil, err
20833	}
20834	ret := &Advertiser{
20835		ServerResponse: googleapi.ServerResponse{
20836			Header:         res.Header,
20837			HTTPStatusCode: res.StatusCode,
20838		},
20839	}
20840	target := &ret
20841	if err := gensupport.DecodeResponse(target, res); err != nil {
20842		return nil, err
20843	}
20844	return ret, nil
20845	// {
20846	//   "description": "Inserts a new advertiser.",
20847	//   "flatPath": "userprofiles/{profileId}/advertisers",
20848	//   "httpMethod": "POST",
20849	//   "id": "dfareporting.advertisers.insert",
20850	//   "parameterOrder": [
20851	//     "profileId"
20852	//   ],
20853	//   "parameters": {
20854	//     "profileId": {
20855	//       "description": "User profile ID associated with this request.",
20856	//       "format": "int64",
20857	//       "location": "path",
20858	//       "required": true,
20859	//       "type": "string"
20860	//     }
20861	//   },
20862	//   "path": "userprofiles/{profileId}/advertisers",
20863	//   "request": {
20864	//     "$ref": "Advertiser"
20865	//   },
20866	//   "response": {
20867	//     "$ref": "Advertiser"
20868	//   },
20869	//   "scopes": [
20870	//     "https://www.googleapis.com/auth/dfatrafficking"
20871	//   ]
20872	// }
20873
20874}
20875
20876// method id "dfareporting.advertisers.list":
20877
20878type AdvertisersListCall struct {
20879	s            *Service
20880	profileId    int64
20881	urlParams_   gensupport.URLParams
20882	ifNoneMatch_ string
20883	ctx_         context.Context
20884	header_      http.Header
20885}
20886
20887// List: Retrieves a list of advertisers, possibly filtered. This method
20888// supports paging.
20889//
20890// - profileId: User profile ID associated with this request.
20891func (r *AdvertisersService) List(profileId int64) *AdvertisersListCall {
20892	c := &AdvertisersListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
20893	c.profileId = profileId
20894	return c
20895}
20896
20897// AdvertiserGroupIds sets the optional parameter "advertiserGroupIds":
20898// Select only advertisers with these advertiser group IDs.
20899func (c *AdvertisersListCall) AdvertiserGroupIds(advertiserGroupIds ...int64) *AdvertisersListCall {
20900	var advertiserGroupIds_ []string
20901	for _, v := range advertiserGroupIds {
20902		advertiserGroupIds_ = append(advertiserGroupIds_, fmt.Sprint(v))
20903	}
20904	c.urlParams_.SetMulti("advertiserGroupIds", advertiserGroupIds_)
20905	return c
20906}
20907
20908// FloodlightConfigurationIds sets the optional parameter
20909// "floodlightConfigurationIds": Select only advertisers with these
20910// floodlight configuration IDs.
20911func (c *AdvertisersListCall) FloodlightConfigurationIds(floodlightConfigurationIds ...int64) *AdvertisersListCall {
20912	var floodlightConfigurationIds_ []string
20913	for _, v := range floodlightConfigurationIds {
20914		floodlightConfigurationIds_ = append(floodlightConfigurationIds_, fmt.Sprint(v))
20915	}
20916	c.urlParams_.SetMulti("floodlightConfigurationIds", floodlightConfigurationIds_)
20917	return c
20918}
20919
20920// Ids sets the optional parameter "ids": Select only advertisers with
20921// these IDs.
20922func (c *AdvertisersListCall) Ids(ids ...int64) *AdvertisersListCall {
20923	var ids_ []string
20924	for _, v := range ids {
20925		ids_ = append(ids_, fmt.Sprint(v))
20926	}
20927	c.urlParams_.SetMulti("ids", ids_)
20928	return c
20929}
20930
20931// IncludeAdvertisersWithoutGroupsOnly sets the optional parameter
20932// "includeAdvertisersWithoutGroupsOnly": Select only advertisers which
20933// do not belong to any advertiser group.
20934func (c *AdvertisersListCall) IncludeAdvertisersWithoutGroupsOnly(includeAdvertisersWithoutGroupsOnly bool) *AdvertisersListCall {
20935	c.urlParams_.Set("includeAdvertisersWithoutGroupsOnly", fmt.Sprint(includeAdvertisersWithoutGroupsOnly))
20936	return c
20937}
20938
20939// MaxResults sets the optional parameter "maxResults": Maximum number
20940// of results to return.
20941func (c *AdvertisersListCall) MaxResults(maxResults int64) *AdvertisersListCall {
20942	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
20943	return c
20944}
20945
20946// OnlyParent sets the optional parameter "onlyParent": Select only
20947// advertisers which use another advertiser's floodlight configuration.
20948func (c *AdvertisersListCall) OnlyParent(onlyParent bool) *AdvertisersListCall {
20949	c.urlParams_.Set("onlyParent", fmt.Sprint(onlyParent))
20950	return c
20951}
20952
20953// PageToken sets the optional parameter "pageToken": Value of the
20954// nextPageToken from the previous result page.
20955func (c *AdvertisersListCall) PageToken(pageToken string) *AdvertisersListCall {
20956	c.urlParams_.Set("pageToken", pageToken)
20957	return c
20958}
20959
20960// SearchString sets the optional parameter "searchString": Allows
20961// searching for objects by name or ID. Wildcards (*) are allowed. For
20962// example, "advertiser*2015" will return objects with names like
20963// "advertiser June 2015", "advertiser April 2015", or simply
20964// "advertiser 2015". Most of the searches also add wildcards implicitly
20965// at the start and the end of the search string. For example, a search
20966// string of "advertiser" will match objects with name "my advertiser",
20967// "advertiser 2015", or simply "advertiser" .
20968func (c *AdvertisersListCall) SearchString(searchString string) *AdvertisersListCall {
20969	c.urlParams_.Set("searchString", searchString)
20970	return c
20971}
20972
20973// SortField sets the optional parameter "sortField": Field by which to
20974// sort the list.
20975//
20976// Possible values:
20977//   "ID" (default)
20978//   "NAME"
20979func (c *AdvertisersListCall) SortField(sortField string) *AdvertisersListCall {
20980	c.urlParams_.Set("sortField", sortField)
20981	return c
20982}
20983
20984// SortOrder sets the optional parameter "sortOrder": Order of sorted
20985// results.
20986//
20987// Possible values:
20988//   "ASCENDING" (default)
20989//   "DESCENDING"
20990func (c *AdvertisersListCall) SortOrder(sortOrder string) *AdvertisersListCall {
20991	c.urlParams_.Set("sortOrder", sortOrder)
20992	return c
20993}
20994
20995// Status sets the optional parameter "status": Select only advertisers
20996// with the specified status.
20997//
20998// Possible values:
20999//   "APPROVED"
21000//   "ON_HOLD"
21001func (c *AdvertisersListCall) Status(status string) *AdvertisersListCall {
21002	c.urlParams_.Set("status", status)
21003	return c
21004}
21005
21006// SubaccountId sets the optional parameter "subaccountId": Select only
21007// advertisers with these subaccount IDs.
21008func (c *AdvertisersListCall) SubaccountId(subaccountId int64) *AdvertisersListCall {
21009	c.urlParams_.Set("subaccountId", fmt.Sprint(subaccountId))
21010	return c
21011}
21012
21013// Fields allows partial responses to be retrieved. See
21014// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
21015// for more information.
21016func (c *AdvertisersListCall) Fields(s ...googleapi.Field) *AdvertisersListCall {
21017	c.urlParams_.Set("fields", googleapi.CombineFields(s))
21018	return c
21019}
21020
21021// IfNoneMatch sets the optional parameter which makes the operation
21022// fail if the object's ETag matches the given value. This is useful for
21023// getting updates only after the object has changed since the last
21024// request. Use googleapi.IsNotModified to check whether the response
21025// error from Do is the result of In-None-Match.
21026func (c *AdvertisersListCall) IfNoneMatch(entityTag string) *AdvertisersListCall {
21027	c.ifNoneMatch_ = entityTag
21028	return c
21029}
21030
21031// Context sets the context to be used in this call's Do method. Any
21032// pending HTTP request will be aborted if the provided context is
21033// canceled.
21034func (c *AdvertisersListCall) Context(ctx context.Context) *AdvertisersListCall {
21035	c.ctx_ = ctx
21036	return c
21037}
21038
21039// Header returns an http.Header that can be modified by the caller to
21040// add HTTP headers to the request.
21041func (c *AdvertisersListCall) Header() http.Header {
21042	if c.header_ == nil {
21043		c.header_ = make(http.Header)
21044	}
21045	return c.header_
21046}
21047
21048func (c *AdvertisersListCall) doRequest(alt string) (*http.Response, error) {
21049	reqHeaders := make(http.Header)
21050	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
21051	for k, v := range c.header_ {
21052		reqHeaders[k] = v
21053	}
21054	reqHeaders.Set("User-Agent", c.s.userAgent())
21055	if c.ifNoneMatch_ != "" {
21056		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
21057	}
21058	var body io.Reader = nil
21059	c.urlParams_.Set("alt", alt)
21060	c.urlParams_.Set("prettyPrint", "false")
21061	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/advertisers")
21062	urls += "?" + c.urlParams_.Encode()
21063	req, err := http.NewRequest("GET", urls, body)
21064	if err != nil {
21065		return nil, err
21066	}
21067	req.Header = reqHeaders
21068	googleapi.Expand(req.URL, map[string]string{
21069		"profileId": strconv.FormatInt(c.profileId, 10),
21070	})
21071	return gensupport.SendRequest(c.ctx_, c.s.client, req)
21072}
21073
21074// Do executes the "dfareporting.advertisers.list" call.
21075// Exactly one of *AdvertisersListResponse or error will be non-nil. Any
21076// non-2xx status code is an error. Response headers are in either
21077// *AdvertisersListResponse.ServerResponse.Header or (if a response was
21078// returned at all) in error.(*googleapi.Error).Header. Use
21079// googleapi.IsNotModified to check whether the returned error was
21080// because http.StatusNotModified was returned.
21081func (c *AdvertisersListCall) Do(opts ...googleapi.CallOption) (*AdvertisersListResponse, error) {
21082	gensupport.SetOptions(c.urlParams_, opts...)
21083	res, err := c.doRequest("json")
21084	if res != nil && res.StatusCode == http.StatusNotModified {
21085		if res.Body != nil {
21086			res.Body.Close()
21087		}
21088		return nil, &googleapi.Error{
21089			Code:   res.StatusCode,
21090			Header: res.Header,
21091		}
21092	}
21093	if err != nil {
21094		return nil, err
21095	}
21096	defer googleapi.CloseBody(res)
21097	if err := googleapi.CheckResponse(res); err != nil {
21098		return nil, err
21099	}
21100	ret := &AdvertisersListResponse{
21101		ServerResponse: googleapi.ServerResponse{
21102			Header:         res.Header,
21103			HTTPStatusCode: res.StatusCode,
21104		},
21105	}
21106	target := &ret
21107	if err := gensupport.DecodeResponse(target, res); err != nil {
21108		return nil, err
21109	}
21110	return ret, nil
21111	// {
21112	//   "description": "Retrieves a list of advertisers, possibly filtered. This method supports paging.",
21113	//   "flatPath": "userprofiles/{profileId}/advertisers",
21114	//   "httpMethod": "GET",
21115	//   "id": "dfareporting.advertisers.list",
21116	//   "parameterOrder": [
21117	//     "profileId"
21118	//   ],
21119	//   "parameters": {
21120	//     "advertiserGroupIds": {
21121	//       "description": "Select only advertisers with these advertiser group IDs.",
21122	//       "format": "int64",
21123	//       "location": "query",
21124	//       "repeated": true,
21125	//       "type": "string"
21126	//     },
21127	//     "floodlightConfigurationIds": {
21128	//       "description": "Select only advertisers with these floodlight configuration IDs.",
21129	//       "format": "int64",
21130	//       "location": "query",
21131	//       "repeated": true,
21132	//       "type": "string"
21133	//     },
21134	//     "ids": {
21135	//       "description": "Select only advertisers with these IDs.",
21136	//       "format": "int64",
21137	//       "location": "query",
21138	//       "repeated": true,
21139	//       "type": "string"
21140	//     },
21141	//     "includeAdvertisersWithoutGroupsOnly": {
21142	//       "description": "Select only advertisers which do not belong to any advertiser group.",
21143	//       "location": "query",
21144	//       "type": "boolean"
21145	//     },
21146	//     "maxResults": {
21147	//       "default": "1000",
21148	//       "description": "Maximum number of results to return.",
21149	//       "format": "int32",
21150	//       "location": "query",
21151	//       "maximum": "1000",
21152	//       "minimum": "0",
21153	//       "type": "integer"
21154	//     },
21155	//     "onlyParent": {
21156	//       "description": "Select only advertisers which use another advertiser's floodlight configuration.",
21157	//       "location": "query",
21158	//       "type": "boolean"
21159	//     },
21160	//     "pageToken": {
21161	//       "description": "Value of the nextPageToken from the previous result page.",
21162	//       "location": "query",
21163	//       "type": "string"
21164	//     },
21165	//     "profileId": {
21166	//       "description": "User profile ID associated with this request.",
21167	//       "format": "int64",
21168	//       "location": "path",
21169	//       "required": true,
21170	//       "type": "string"
21171	//     },
21172	//     "searchString": {
21173	//       "description": "Allows searching for objects by name or ID. Wildcards (*) are allowed. For example, \"advertiser*2015\" will return objects with names like \"advertiser June 2015\", \"advertiser April 2015\", or simply \"advertiser 2015\". Most of the searches also add wildcards implicitly at the start and the end of the search string. For example, a search string of \"advertiser\" will match objects with name \"my advertiser\", \"advertiser 2015\", or simply \"advertiser\" .",
21174	//       "location": "query",
21175	//       "type": "string"
21176	//     },
21177	//     "sortField": {
21178	//       "default": "ID",
21179	//       "description": "Field by which to sort the list.",
21180	//       "enum": [
21181	//         "ID",
21182	//         "NAME"
21183	//       ],
21184	//       "enumDescriptions": [
21185	//         "",
21186	//         ""
21187	//       ],
21188	//       "location": "query",
21189	//       "type": "string"
21190	//     },
21191	//     "sortOrder": {
21192	//       "default": "ASCENDING",
21193	//       "description": "Order of sorted results.",
21194	//       "enum": [
21195	//         "ASCENDING",
21196	//         "DESCENDING"
21197	//       ],
21198	//       "enumDescriptions": [
21199	//         "",
21200	//         ""
21201	//       ],
21202	//       "location": "query",
21203	//       "type": "string"
21204	//     },
21205	//     "status": {
21206	//       "description": "Select only advertisers with the specified status.",
21207	//       "enum": [
21208	//         "APPROVED",
21209	//         "ON_HOLD"
21210	//       ],
21211	//       "enumDescriptions": [
21212	//         "",
21213	//         ""
21214	//       ],
21215	//       "location": "query",
21216	//       "type": "string"
21217	//     },
21218	//     "subaccountId": {
21219	//       "description": "Select only advertisers with these subaccount IDs.",
21220	//       "format": "int64",
21221	//       "location": "query",
21222	//       "type": "string"
21223	//     }
21224	//   },
21225	//   "path": "userprofiles/{profileId}/advertisers",
21226	//   "response": {
21227	//     "$ref": "AdvertisersListResponse"
21228	//   },
21229	//   "scopes": [
21230	//     "https://www.googleapis.com/auth/dfatrafficking"
21231	//   ]
21232	// }
21233
21234}
21235
21236// Pages invokes f for each page of results.
21237// A non-nil error returned from f will halt the iteration.
21238// The provided context supersedes any context provided to the Context method.
21239func (c *AdvertisersListCall) Pages(ctx context.Context, f func(*AdvertisersListResponse) error) error {
21240	c.ctx_ = ctx
21241	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
21242	for {
21243		x, err := c.Do()
21244		if err != nil {
21245			return err
21246		}
21247		if err := f(x); err != nil {
21248			return err
21249		}
21250		if x.NextPageToken == "" {
21251			return nil
21252		}
21253		c.PageToken(x.NextPageToken)
21254	}
21255}
21256
21257// method id "dfareporting.advertisers.patch":
21258
21259type AdvertisersPatchCall struct {
21260	s          *Service
21261	profileId  int64
21262	advertiser *Advertiser
21263	urlParams_ gensupport.URLParams
21264	ctx_       context.Context
21265	header_    http.Header
21266}
21267
21268// Patch: Updates an existing advertiser. This method supports patch
21269// semantics.
21270//
21271// - id: Advertiser ID.
21272// - profileId: User profile ID associated with this request.
21273func (r *AdvertisersService) Patch(profileId int64, id int64, advertiser *Advertiser) *AdvertisersPatchCall {
21274	c := &AdvertisersPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
21275	c.profileId = profileId
21276	c.urlParams_.Set("id", fmt.Sprint(id))
21277	c.advertiser = advertiser
21278	return c
21279}
21280
21281// Fields allows partial responses to be retrieved. See
21282// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
21283// for more information.
21284func (c *AdvertisersPatchCall) Fields(s ...googleapi.Field) *AdvertisersPatchCall {
21285	c.urlParams_.Set("fields", googleapi.CombineFields(s))
21286	return c
21287}
21288
21289// Context sets the context to be used in this call's Do method. Any
21290// pending HTTP request will be aborted if the provided context is
21291// canceled.
21292func (c *AdvertisersPatchCall) Context(ctx context.Context) *AdvertisersPatchCall {
21293	c.ctx_ = ctx
21294	return c
21295}
21296
21297// Header returns an http.Header that can be modified by the caller to
21298// add HTTP headers to the request.
21299func (c *AdvertisersPatchCall) Header() http.Header {
21300	if c.header_ == nil {
21301		c.header_ = make(http.Header)
21302	}
21303	return c.header_
21304}
21305
21306func (c *AdvertisersPatchCall) doRequest(alt string) (*http.Response, error) {
21307	reqHeaders := make(http.Header)
21308	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
21309	for k, v := range c.header_ {
21310		reqHeaders[k] = v
21311	}
21312	reqHeaders.Set("User-Agent", c.s.userAgent())
21313	var body io.Reader = nil
21314	body, err := googleapi.WithoutDataWrapper.JSONReader(c.advertiser)
21315	if err != nil {
21316		return nil, err
21317	}
21318	reqHeaders.Set("Content-Type", "application/json")
21319	c.urlParams_.Set("alt", alt)
21320	c.urlParams_.Set("prettyPrint", "false")
21321	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/advertisers")
21322	urls += "?" + c.urlParams_.Encode()
21323	req, err := http.NewRequest("PATCH", urls, body)
21324	if err != nil {
21325		return nil, err
21326	}
21327	req.Header = reqHeaders
21328	googleapi.Expand(req.URL, map[string]string{
21329		"profileId": strconv.FormatInt(c.profileId, 10),
21330	})
21331	return gensupport.SendRequest(c.ctx_, c.s.client, req)
21332}
21333
21334// Do executes the "dfareporting.advertisers.patch" call.
21335// Exactly one of *Advertiser or error will be non-nil. Any non-2xx
21336// status code is an error. Response headers are in either
21337// *Advertiser.ServerResponse.Header or (if a response was returned at
21338// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
21339// to check whether the returned error was because
21340// http.StatusNotModified was returned.
21341func (c *AdvertisersPatchCall) Do(opts ...googleapi.CallOption) (*Advertiser, error) {
21342	gensupport.SetOptions(c.urlParams_, opts...)
21343	res, err := c.doRequest("json")
21344	if res != nil && res.StatusCode == http.StatusNotModified {
21345		if res.Body != nil {
21346			res.Body.Close()
21347		}
21348		return nil, &googleapi.Error{
21349			Code:   res.StatusCode,
21350			Header: res.Header,
21351		}
21352	}
21353	if err != nil {
21354		return nil, err
21355	}
21356	defer googleapi.CloseBody(res)
21357	if err := googleapi.CheckResponse(res); err != nil {
21358		return nil, err
21359	}
21360	ret := &Advertiser{
21361		ServerResponse: googleapi.ServerResponse{
21362			Header:         res.Header,
21363			HTTPStatusCode: res.StatusCode,
21364		},
21365	}
21366	target := &ret
21367	if err := gensupport.DecodeResponse(target, res); err != nil {
21368		return nil, err
21369	}
21370	return ret, nil
21371	// {
21372	//   "description": "Updates an existing advertiser. This method supports patch semantics.",
21373	//   "flatPath": "userprofiles/{profileId}/advertisers",
21374	//   "httpMethod": "PATCH",
21375	//   "id": "dfareporting.advertisers.patch",
21376	//   "parameterOrder": [
21377	//     "profileId",
21378	//     "id"
21379	//   ],
21380	//   "parameters": {
21381	//     "id": {
21382	//       "description": "Advertiser ID.",
21383	//       "format": "int64",
21384	//       "location": "query",
21385	//       "required": true,
21386	//       "type": "string"
21387	//     },
21388	//     "profileId": {
21389	//       "description": "User profile ID associated with this request.",
21390	//       "format": "int64",
21391	//       "location": "path",
21392	//       "required": true,
21393	//       "type": "string"
21394	//     }
21395	//   },
21396	//   "path": "userprofiles/{profileId}/advertisers",
21397	//   "request": {
21398	//     "$ref": "Advertiser"
21399	//   },
21400	//   "response": {
21401	//     "$ref": "Advertiser"
21402	//   },
21403	//   "scopes": [
21404	//     "https://www.googleapis.com/auth/dfatrafficking"
21405	//   ]
21406	// }
21407
21408}
21409
21410// method id "dfareporting.advertisers.update":
21411
21412type AdvertisersUpdateCall struct {
21413	s          *Service
21414	profileId  int64
21415	advertiser *Advertiser
21416	urlParams_ gensupport.URLParams
21417	ctx_       context.Context
21418	header_    http.Header
21419}
21420
21421// Update: Updates an existing advertiser.
21422//
21423// - profileId: User profile ID associated with this request.
21424func (r *AdvertisersService) Update(profileId int64, advertiser *Advertiser) *AdvertisersUpdateCall {
21425	c := &AdvertisersUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
21426	c.profileId = profileId
21427	c.advertiser = advertiser
21428	return c
21429}
21430
21431// Fields allows partial responses to be retrieved. See
21432// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
21433// for more information.
21434func (c *AdvertisersUpdateCall) Fields(s ...googleapi.Field) *AdvertisersUpdateCall {
21435	c.urlParams_.Set("fields", googleapi.CombineFields(s))
21436	return c
21437}
21438
21439// Context sets the context to be used in this call's Do method. Any
21440// pending HTTP request will be aborted if the provided context is
21441// canceled.
21442func (c *AdvertisersUpdateCall) Context(ctx context.Context) *AdvertisersUpdateCall {
21443	c.ctx_ = ctx
21444	return c
21445}
21446
21447// Header returns an http.Header that can be modified by the caller to
21448// add HTTP headers to the request.
21449func (c *AdvertisersUpdateCall) Header() http.Header {
21450	if c.header_ == nil {
21451		c.header_ = make(http.Header)
21452	}
21453	return c.header_
21454}
21455
21456func (c *AdvertisersUpdateCall) doRequest(alt string) (*http.Response, error) {
21457	reqHeaders := make(http.Header)
21458	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
21459	for k, v := range c.header_ {
21460		reqHeaders[k] = v
21461	}
21462	reqHeaders.Set("User-Agent", c.s.userAgent())
21463	var body io.Reader = nil
21464	body, err := googleapi.WithoutDataWrapper.JSONReader(c.advertiser)
21465	if err != nil {
21466		return nil, err
21467	}
21468	reqHeaders.Set("Content-Type", "application/json")
21469	c.urlParams_.Set("alt", alt)
21470	c.urlParams_.Set("prettyPrint", "false")
21471	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/advertisers")
21472	urls += "?" + c.urlParams_.Encode()
21473	req, err := http.NewRequest("PUT", urls, body)
21474	if err != nil {
21475		return nil, err
21476	}
21477	req.Header = reqHeaders
21478	googleapi.Expand(req.URL, map[string]string{
21479		"profileId": strconv.FormatInt(c.profileId, 10),
21480	})
21481	return gensupport.SendRequest(c.ctx_, c.s.client, req)
21482}
21483
21484// Do executes the "dfareporting.advertisers.update" call.
21485// Exactly one of *Advertiser or error will be non-nil. Any non-2xx
21486// status code is an error. Response headers are in either
21487// *Advertiser.ServerResponse.Header or (if a response was returned at
21488// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
21489// to check whether the returned error was because
21490// http.StatusNotModified was returned.
21491func (c *AdvertisersUpdateCall) Do(opts ...googleapi.CallOption) (*Advertiser, error) {
21492	gensupport.SetOptions(c.urlParams_, opts...)
21493	res, err := c.doRequest("json")
21494	if res != nil && res.StatusCode == http.StatusNotModified {
21495		if res.Body != nil {
21496			res.Body.Close()
21497		}
21498		return nil, &googleapi.Error{
21499			Code:   res.StatusCode,
21500			Header: res.Header,
21501		}
21502	}
21503	if err != nil {
21504		return nil, err
21505	}
21506	defer googleapi.CloseBody(res)
21507	if err := googleapi.CheckResponse(res); err != nil {
21508		return nil, err
21509	}
21510	ret := &Advertiser{
21511		ServerResponse: googleapi.ServerResponse{
21512			Header:         res.Header,
21513			HTTPStatusCode: res.StatusCode,
21514		},
21515	}
21516	target := &ret
21517	if err := gensupport.DecodeResponse(target, res); err != nil {
21518		return nil, err
21519	}
21520	return ret, nil
21521	// {
21522	//   "description": "Updates an existing advertiser.",
21523	//   "flatPath": "userprofiles/{profileId}/advertisers",
21524	//   "httpMethod": "PUT",
21525	//   "id": "dfareporting.advertisers.update",
21526	//   "parameterOrder": [
21527	//     "profileId"
21528	//   ],
21529	//   "parameters": {
21530	//     "profileId": {
21531	//       "description": "User profile ID associated with this request.",
21532	//       "format": "int64",
21533	//       "location": "path",
21534	//       "required": true,
21535	//       "type": "string"
21536	//     }
21537	//   },
21538	//   "path": "userprofiles/{profileId}/advertisers",
21539	//   "request": {
21540	//     "$ref": "Advertiser"
21541	//   },
21542	//   "response": {
21543	//     "$ref": "Advertiser"
21544	//   },
21545	//   "scopes": [
21546	//     "https://www.googleapis.com/auth/dfatrafficking"
21547	//   ]
21548	// }
21549
21550}
21551
21552// method id "dfareporting.browsers.list":
21553
21554type BrowsersListCall struct {
21555	s            *Service
21556	profileId    int64
21557	urlParams_   gensupport.URLParams
21558	ifNoneMatch_ string
21559	ctx_         context.Context
21560	header_      http.Header
21561}
21562
21563// List: Retrieves a list of browsers.
21564//
21565// - profileId: User profile ID associated with this request.
21566func (r *BrowsersService) List(profileId int64) *BrowsersListCall {
21567	c := &BrowsersListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
21568	c.profileId = profileId
21569	return c
21570}
21571
21572// Fields allows partial responses to be retrieved. See
21573// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
21574// for more information.
21575func (c *BrowsersListCall) Fields(s ...googleapi.Field) *BrowsersListCall {
21576	c.urlParams_.Set("fields", googleapi.CombineFields(s))
21577	return c
21578}
21579
21580// IfNoneMatch sets the optional parameter which makes the operation
21581// fail if the object's ETag matches the given value. This is useful for
21582// getting updates only after the object has changed since the last
21583// request. Use googleapi.IsNotModified to check whether the response
21584// error from Do is the result of In-None-Match.
21585func (c *BrowsersListCall) IfNoneMatch(entityTag string) *BrowsersListCall {
21586	c.ifNoneMatch_ = entityTag
21587	return c
21588}
21589
21590// Context sets the context to be used in this call's Do method. Any
21591// pending HTTP request will be aborted if the provided context is
21592// canceled.
21593func (c *BrowsersListCall) Context(ctx context.Context) *BrowsersListCall {
21594	c.ctx_ = ctx
21595	return c
21596}
21597
21598// Header returns an http.Header that can be modified by the caller to
21599// add HTTP headers to the request.
21600func (c *BrowsersListCall) Header() http.Header {
21601	if c.header_ == nil {
21602		c.header_ = make(http.Header)
21603	}
21604	return c.header_
21605}
21606
21607func (c *BrowsersListCall) doRequest(alt string) (*http.Response, error) {
21608	reqHeaders := make(http.Header)
21609	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
21610	for k, v := range c.header_ {
21611		reqHeaders[k] = v
21612	}
21613	reqHeaders.Set("User-Agent", c.s.userAgent())
21614	if c.ifNoneMatch_ != "" {
21615		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
21616	}
21617	var body io.Reader = nil
21618	c.urlParams_.Set("alt", alt)
21619	c.urlParams_.Set("prettyPrint", "false")
21620	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/browsers")
21621	urls += "?" + c.urlParams_.Encode()
21622	req, err := http.NewRequest("GET", urls, body)
21623	if err != nil {
21624		return nil, err
21625	}
21626	req.Header = reqHeaders
21627	googleapi.Expand(req.URL, map[string]string{
21628		"profileId": strconv.FormatInt(c.profileId, 10),
21629	})
21630	return gensupport.SendRequest(c.ctx_, c.s.client, req)
21631}
21632
21633// Do executes the "dfareporting.browsers.list" call.
21634// Exactly one of *BrowsersListResponse or error will be non-nil. Any
21635// non-2xx status code is an error. Response headers are in either
21636// *BrowsersListResponse.ServerResponse.Header or (if a response was
21637// returned at all) in error.(*googleapi.Error).Header. Use
21638// googleapi.IsNotModified to check whether the returned error was
21639// because http.StatusNotModified was returned.
21640func (c *BrowsersListCall) Do(opts ...googleapi.CallOption) (*BrowsersListResponse, error) {
21641	gensupport.SetOptions(c.urlParams_, opts...)
21642	res, err := c.doRequest("json")
21643	if res != nil && res.StatusCode == http.StatusNotModified {
21644		if res.Body != nil {
21645			res.Body.Close()
21646		}
21647		return nil, &googleapi.Error{
21648			Code:   res.StatusCode,
21649			Header: res.Header,
21650		}
21651	}
21652	if err != nil {
21653		return nil, err
21654	}
21655	defer googleapi.CloseBody(res)
21656	if err := googleapi.CheckResponse(res); err != nil {
21657		return nil, err
21658	}
21659	ret := &BrowsersListResponse{
21660		ServerResponse: googleapi.ServerResponse{
21661			Header:         res.Header,
21662			HTTPStatusCode: res.StatusCode,
21663		},
21664	}
21665	target := &ret
21666	if err := gensupport.DecodeResponse(target, res); err != nil {
21667		return nil, err
21668	}
21669	return ret, nil
21670	// {
21671	//   "description": "Retrieves a list of browsers.",
21672	//   "flatPath": "userprofiles/{profileId}/browsers",
21673	//   "httpMethod": "GET",
21674	//   "id": "dfareporting.browsers.list",
21675	//   "parameterOrder": [
21676	//     "profileId"
21677	//   ],
21678	//   "parameters": {
21679	//     "profileId": {
21680	//       "description": "User profile ID associated with this request.",
21681	//       "format": "int64",
21682	//       "location": "path",
21683	//       "required": true,
21684	//       "type": "string"
21685	//     }
21686	//   },
21687	//   "path": "userprofiles/{profileId}/browsers",
21688	//   "response": {
21689	//     "$ref": "BrowsersListResponse"
21690	//   },
21691	//   "scopes": [
21692	//     "https://www.googleapis.com/auth/dfatrafficking"
21693	//   ]
21694	// }
21695
21696}
21697
21698// method id "dfareporting.campaignCreativeAssociations.insert":
21699
21700type CampaignCreativeAssociationsInsertCall struct {
21701	s                           *Service
21702	profileId                   int64
21703	campaignId                  int64
21704	campaigncreativeassociation *CampaignCreativeAssociation
21705	urlParams_                  gensupport.URLParams
21706	ctx_                        context.Context
21707	header_                     http.Header
21708}
21709
21710// Insert: Associates a creative with the specified campaign. This
21711// method creates a default ad with dimensions matching the creative in
21712// the campaign if such a default ad does not exist already.
21713//
21714// - campaignId: Campaign ID in this association.
21715// - profileId: User profile ID associated with this request.
21716func (r *CampaignCreativeAssociationsService) Insert(profileId int64, campaignId int64, campaigncreativeassociation *CampaignCreativeAssociation) *CampaignCreativeAssociationsInsertCall {
21717	c := &CampaignCreativeAssociationsInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
21718	c.profileId = profileId
21719	c.campaignId = campaignId
21720	c.campaigncreativeassociation = campaigncreativeassociation
21721	return c
21722}
21723
21724// Fields allows partial responses to be retrieved. See
21725// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
21726// for more information.
21727func (c *CampaignCreativeAssociationsInsertCall) Fields(s ...googleapi.Field) *CampaignCreativeAssociationsInsertCall {
21728	c.urlParams_.Set("fields", googleapi.CombineFields(s))
21729	return c
21730}
21731
21732// Context sets the context to be used in this call's Do method. Any
21733// pending HTTP request will be aborted if the provided context is
21734// canceled.
21735func (c *CampaignCreativeAssociationsInsertCall) Context(ctx context.Context) *CampaignCreativeAssociationsInsertCall {
21736	c.ctx_ = ctx
21737	return c
21738}
21739
21740// Header returns an http.Header that can be modified by the caller to
21741// add HTTP headers to the request.
21742func (c *CampaignCreativeAssociationsInsertCall) Header() http.Header {
21743	if c.header_ == nil {
21744		c.header_ = make(http.Header)
21745	}
21746	return c.header_
21747}
21748
21749func (c *CampaignCreativeAssociationsInsertCall) doRequest(alt string) (*http.Response, error) {
21750	reqHeaders := make(http.Header)
21751	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
21752	for k, v := range c.header_ {
21753		reqHeaders[k] = v
21754	}
21755	reqHeaders.Set("User-Agent", c.s.userAgent())
21756	var body io.Reader = nil
21757	body, err := googleapi.WithoutDataWrapper.JSONReader(c.campaigncreativeassociation)
21758	if err != nil {
21759		return nil, err
21760	}
21761	reqHeaders.Set("Content-Type", "application/json")
21762	c.urlParams_.Set("alt", alt)
21763	c.urlParams_.Set("prettyPrint", "false")
21764	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/campaigns/{campaignId}/campaignCreativeAssociations")
21765	urls += "?" + c.urlParams_.Encode()
21766	req, err := http.NewRequest("POST", urls, body)
21767	if err != nil {
21768		return nil, err
21769	}
21770	req.Header = reqHeaders
21771	googleapi.Expand(req.URL, map[string]string{
21772		"profileId":  strconv.FormatInt(c.profileId, 10),
21773		"campaignId": strconv.FormatInt(c.campaignId, 10),
21774	})
21775	return gensupport.SendRequest(c.ctx_, c.s.client, req)
21776}
21777
21778// Do executes the "dfareporting.campaignCreativeAssociations.insert" call.
21779// Exactly one of *CampaignCreativeAssociation or error will be non-nil.
21780// Any non-2xx status code is an error. Response headers are in either
21781// *CampaignCreativeAssociation.ServerResponse.Header or (if a response
21782// was returned at all) in error.(*googleapi.Error).Header. Use
21783// googleapi.IsNotModified to check whether the returned error was
21784// because http.StatusNotModified was returned.
21785func (c *CampaignCreativeAssociationsInsertCall) Do(opts ...googleapi.CallOption) (*CampaignCreativeAssociation, error) {
21786	gensupport.SetOptions(c.urlParams_, opts...)
21787	res, err := c.doRequest("json")
21788	if res != nil && res.StatusCode == http.StatusNotModified {
21789		if res.Body != nil {
21790			res.Body.Close()
21791		}
21792		return nil, &googleapi.Error{
21793			Code:   res.StatusCode,
21794			Header: res.Header,
21795		}
21796	}
21797	if err != nil {
21798		return nil, err
21799	}
21800	defer googleapi.CloseBody(res)
21801	if err := googleapi.CheckResponse(res); err != nil {
21802		return nil, err
21803	}
21804	ret := &CampaignCreativeAssociation{
21805		ServerResponse: googleapi.ServerResponse{
21806			Header:         res.Header,
21807			HTTPStatusCode: res.StatusCode,
21808		},
21809	}
21810	target := &ret
21811	if err := gensupport.DecodeResponse(target, res); err != nil {
21812		return nil, err
21813	}
21814	return ret, nil
21815	// {
21816	//   "description": "Associates a creative with the specified campaign. This method creates a default ad with dimensions matching the creative in the campaign if such a default ad does not exist already.",
21817	//   "flatPath": "userprofiles/{profileId}/campaigns/{campaignId}/campaignCreativeAssociations",
21818	//   "httpMethod": "POST",
21819	//   "id": "dfareporting.campaignCreativeAssociations.insert",
21820	//   "parameterOrder": [
21821	//     "profileId",
21822	//     "campaignId"
21823	//   ],
21824	//   "parameters": {
21825	//     "campaignId": {
21826	//       "description": "Campaign ID in this association.",
21827	//       "format": "int64",
21828	//       "location": "path",
21829	//       "required": true,
21830	//       "type": "string"
21831	//     },
21832	//     "profileId": {
21833	//       "description": "User profile ID associated with this request.",
21834	//       "format": "int64",
21835	//       "location": "path",
21836	//       "required": true,
21837	//       "type": "string"
21838	//     }
21839	//   },
21840	//   "path": "userprofiles/{profileId}/campaigns/{campaignId}/campaignCreativeAssociations",
21841	//   "request": {
21842	//     "$ref": "CampaignCreativeAssociation"
21843	//   },
21844	//   "response": {
21845	//     "$ref": "CampaignCreativeAssociation"
21846	//   },
21847	//   "scopes": [
21848	//     "https://www.googleapis.com/auth/dfatrafficking"
21849	//   ]
21850	// }
21851
21852}
21853
21854// method id "dfareporting.campaignCreativeAssociations.list":
21855
21856type CampaignCreativeAssociationsListCall struct {
21857	s            *Service
21858	profileId    int64
21859	campaignId   int64
21860	urlParams_   gensupport.URLParams
21861	ifNoneMatch_ string
21862	ctx_         context.Context
21863	header_      http.Header
21864}
21865
21866// List: Retrieves the list of creative IDs associated with the
21867// specified campaign. This method supports paging.
21868//
21869// - campaignId: Campaign ID in this association.
21870// - profileId: User profile ID associated with this request.
21871func (r *CampaignCreativeAssociationsService) List(profileId int64, campaignId int64) *CampaignCreativeAssociationsListCall {
21872	c := &CampaignCreativeAssociationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
21873	c.profileId = profileId
21874	c.campaignId = campaignId
21875	return c
21876}
21877
21878// MaxResults sets the optional parameter "maxResults": Maximum number
21879// of results to return.
21880func (c *CampaignCreativeAssociationsListCall) MaxResults(maxResults int64) *CampaignCreativeAssociationsListCall {
21881	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
21882	return c
21883}
21884
21885// PageToken sets the optional parameter "pageToken": Value of the
21886// nextPageToken from the previous result page.
21887func (c *CampaignCreativeAssociationsListCall) PageToken(pageToken string) *CampaignCreativeAssociationsListCall {
21888	c.urlParams_.Set("pageToken", pageToken)
21889	return c
21890}
21891
21892// SortOrder sets the optional parameter "sortOrder": Order of sorted
21893// results.
21894//
21895// Possible values:
21896//   "ASCENDING" (default)
21897//   "DESCENDING"
21898func (c *CampaignCreativeAssociationsListCall) SortOrder(sortOrder string) *CampaignCreativeAssociationsListCall {
21899	c.urlParams_.Set("sortOrder", sortOrder)
21900	return c
21901}
21902
21903// Fields allows partial responses to be retrieved. See
21904// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
21905// for more information.
21906func (c *CampaignCreativeAssociationsListCall) Fields(s ...googleapi.Field) *CampaignCreativeAssociationsListCall {
21907	c.urlParams_.Set("fields", googleapi.CombineFields(s))
21908	return c
21909}
21910
21911// IfNoneMatch sets the optional parameter which makes the operation
21912// fail if the object's ETag matches the given value. This is useful for
21913// getting updates only after the object has changed since the last
21914// request. Use googleapi.IsNotModified to check whether the response
21915// error from Do is the result of In-None-Match.
21916func (c *CampaignCreativeAssociationsListCall) IfNoneMatch(entityTag string) *CampaignCreativeAssociationsListCall {
21917	c.ifNoneMatch_ = entityTag
21918	return c
21919}
21920
21921// Context sets the context to be used in this call's Do method. Any
21922// pending HTTP request will be aborted if the provided context is
21923// canceled.
21924func (c *CampaignCreativeAssociationsListCall) Context(ctx context.Context) *CampaignCreativeAssociationsListCall {
21925	c.ctx_ = ctx
21926	return c
21927}
21928
21929// Header returns an http.Header that can be modified by the caller to
21930// add HTTP headers to the request.
21931func (c *CampaignCreativeAssociationsListCall) Header() http.Header {
21932	if c.header_ == nil {
21933		c.header_ = make(http.Header)
21934	}
21935	return c.header_
21936}
21937
21938func (c *CampaignCreativeAssociationsListCall) doRequest(alt string) (*http.Response, error) {
21939	reqHeaders := make(http.Header)
21940	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
21941	for k, v := range c.header_ {
21942		reqHeaders[k] = v
21943	}
21944	reqHeaders.Set("User-Agent", c.s.userAgent())
21945	if c.ifNoneMatch_ != "" {
21946		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
21947	}
21948	var body io.Reader = nil
21949	c.urlParams_.Set("alt", alt)
21950	c.urlParams_.Set("prettyPrint", "false")
21951	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/campaigns/{campaignId}/campaignCreativeAssociations")
21952	urls += "?" + c.urlParams_.Encode()
21953	req, err := http.NewRequest("GET", urls, body)
21954	if err != nil {
21955		return nil, err
21956	}
21957	req.Header = reqHeaders
21958	googleapi.Expand(req.URL, map[string]string{
21959		"profileId":  strconv.FormatInt(c.profileId, 10),
21960		"campaignId": strconv.FormatInt(c.campaignId, 10),
21961	})
21962	return gensupport.SendRequest(c.ctx_, c.s.client, req)
21963}
21964
21965// Do executes the "dfareporting.campaignCreativeAssociations.list" call.
21966// Exactly one of *CampaignCreativeAssociationsListResponse or error
21967// will be non-nil. Any non-2xx status code is an error. Response
21968// headers are in either
21969// *CampaignCreativeAssociationsListResponse.ServerResponse.Header or
21970// (if a response was returned at all) in
21971// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
21972// whether the returned error was because http.StatusNotModified was
21973// returned.
21974func (c *CampaignCreativeAssociationsListCall) Do(opts ...googleapi.CallOption) (*CampaignCreativeAssociationsListResponse, error) {
21975	gensupport.SetOptions(c.urlParams_, opts...)
21976	res, err := c.doRequest("json")
21977	if res != nil && res.StatusCode == http.StatusNotModified {
21978		if res.Body != nil {
21979			res.Body.Close()
21980		}
21981		return nil, &googleapi.Error{
21982			Code:   res.StatusCode,
21983			Header: res.Header,
21984		}
21985	}
21986	if err != nil {
21987		return nil, err
21988	}
21989	defer googleapi.CloseBody(res)
21990	if err := googleapi.CheckResponse(res); err != nil {
21991		return nil, err
21992	}
21993	ret := &CampaignCreativeAssociationsListResponse{
21994		ServerResponse: googleapi.ServerResponse{
21995			Header:         res.Header,
21996			HTTPStatusCode: res.StatusCode,
21997		},
21998	}
21999	target := &ret
22000	if err := gensupport.DecodeResponse(target, res); err != nil {
22001		return nil, err
22002	}
22003	return ret, nil
22004	// {
22005	//   "description": "Retrieves the list of creative IDs associated with the specified campaign. This method supports paging.",
22006	//   "flatPath": "userprofiles/{profileId}/campaigns/{campaignId}/campaignCreativeAssociations",
22007	//   "httpMethod": "GET",
22008	//   "id": "dfareporting.campaignCreativeAssociations.list",
22009	//   "parameterOrder": [
22010	//     "profileId",
22011	//     "campaignId"
22012	//   ],
22013	//   "parameters": {
22014	//     "campaignId": {
22015	//       "description": "Campaign ID in this association.",
22016	//       "format": "int64",
22017	//       "location": "path",
22018	//       "required": true,
22019	//       "type": "string"
22020	//     },
22021	//     "maxResults": {
22022	//       "default": "1000",
22023	//       "description": "Maximum number of results to return.",
22024	//       "format": "int32",
22025	//       "location": "query",
22026	//       "maximum": "1000",
22027	//       "minimum": "0",
22028	//       "type": "integer"
22029	//     },
22030	//     "pageToken": {
22031	//       "description": "Value of the nextPageToken from the previous result page.",
22032	//       "location": "query",
22033	//       "type": "string"
22034	//     },
22035	//     "profileId": {
22036	//       "description": "User profile ID associated with this request.",
22037	//       "format": "int64",
22038	//       "location": "path",
22039	//       "required": true,
22040	//       "type": "string"
22041	//     },
22042	//     "sortOrder": {
22043	//       "default": "ASCENDING",
22044	//       "description": "Order of sorted results.",
22045	//       "enum": [
22046	//         "ASCENDING",
22047	//         "DESCENDING"
22048	//       ],
22049	//       "enumDescriptions": [
22050	//         "",
22051	//         ""
22052	//       ],
22053	//       "location": "query",
22054	//       "type": "string"
22055	//     }
22056	//   },
22057	//   "path": "userprofiles/{profileId}/campaigns/{campaignId}/campaignCreativeAssociations",
22058	//   "response": {
22059	//     "$ref": "CampaignCreativeAssociationsListResponse"
22060	//   },
22061	//   "scopes": [
22062	//     "https://www.googleapis.com/auth/dfatrafficking"
22063	//   ]
22064	// }
22065
22066}
22067
22068// Pages invokes f for each page of results.
22069// A non-nil error returned from f will halt the iteration.
22070// The provided context supersedes any context provided to the Context method.
22071func (c *CampaignCreativeAssociationsListCall) Pages(ctx context.Context, f func(*CampaignCreativeAssociationsListResponse) error) error {
22072	c.ctx_ = ctx
22073	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
22074	for {
22075		x, err := c.Do()
22076		if err != nil {
22077			return err
22078		}
22079		if err := f(x); err != nil {
22080			return err
22081		}
22082		if x.NextPageToken == "" {
22083			return nil
22084		}
22085		c.PageToken(x.NextPageToken)
22086	}
22087}
22088
22089// method id "dfareporting.campaigns.get":
22090
22091type CampaignsGetCall struct {
22092	s            *Service
22093	profileId    int64
22094	id           int64
22095	urlParams_   gensupport.URLParams
22096	ifNoneMatch_ string
22097	ctx_         context.Context
22098	header_      http.Header
22099}
22100
22101// Get: Gets one campaign by ID.
22102//
22103// - id: Campaign ID.
22104// - profileId: User profile ID associated with this request.
22105func (r *CampaignsService) Get(profileId int64, id int64) *CampaignsGetCall {
22106	c := &CampaignsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
22107	c.profileId = profileId
22108	c.id = id
22109	return c
22110}
22111
22112// Fields allows partial responses to be retrieved. See
22113// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
22114// for more information.
22115func (c *CampaignsGetCall) Fields(s ...googleapi.Field) *CampaignsGetCall {
22116	c.urlParams_.Set("fields", googleapi.CombineFields(s))
22117	return c
22118}
22119
22120// IfNoneMatch sets the optional parameter which makes the operation
22121// fail if the object's ETag matches the given value. This is useful for
22122// getting updates only after the object has changed since the last
22123// request. Use googleapi.IsNotModified to check whether the response
22124// error from Do is the result of In-None-Match.
22125func (c *CampaignsGetCall) IfNoneMatch(entityTag string) *CampaignsGetCall {
22126	c.ifNoneMatch_ = entityTag
22127	return c
22128}
22129
22130// Context sets the context to be used in this call's Do method. Any
22131// pending HTTP request will be aborted if the provided context is
22132// canceled.
22133func (c *CampaignsGetCall) Context(ctx context.Context) *CampaignsGetCall {
22134	c.ctx_ = ctx
22135	return c
22136}
22137
22138// Header returns an http.Header that can be modified by the caller to
22139// add HTTP headers to the request.
22140func (c *CampaignsGetCall) Header() http.Header {
22141	if c.header_ == nil {
22142		c.header_ = make(http.Header)
22143	}
22144	return c.header_
22145}
22146
22147func (c *CampaignsGetCall) doRequest(alt string) (*http.Response, error) {
22148	reqHeaders := make(http.Header)
22149	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
22150	for k, v := range c.header_ {
22151		reqHeaders[k] = v
22152	}
22153	reqHeaders.Set("User-Agent", c.s.userAgent())
22154	if c.ifNoneMatch_ != "" {
22155		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
22156	}
22157	var body io.Reader = nil
22158	c.urlParams_.Set("alt", alt)
22159	c.urlParams_.Set("prettyPrint", "false")
22160	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/campaigns/{id}")
22161	urls += "?" + c.urlParams_.Encode()
22162	req, err := http.NewRequest("GET", urls, body)
22163	if err != nil {
22164		return nil, err
22165	}
22166	req.Header = reqHeaders
22167	googleapi.Expand(req.URL, map[string]string{
22168		"profileId": strconv.FormatInt(c.profileId, 10),
22169		"id":        strconv.FormatInt(c.id, 10),
22170	})
22171	return gensupport.SendRequest(c.ctx_, c.s.client, req)
22172}
22173
22174// Do executes the "dfareporting.campaigns.get" call.
22175// Exactly one of *Campaign or error will be non-nil. Any non-2xx status
22176// code is an error. Response headers are in either
22177// *Campaign.ServerResponse.Header or (if a response was returned at
22178// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
22179// to check whether the returned error was because
22180// http.StatusNotModified was returned.
22181func (c *CampaignsGetCall) Do(opts ...googleapi.CallOption) (*Campaign, error) {
22182	gensupport.SetOptions(c.urlParams_, opts...)
22183	res, err := c.doRequest("json")
22184	if res != nil && res.StatusCode == http.StatusNotModified {
22185		if res.Body != nil {
22186			res.Body.Close()
22187		}
22188		return nil, &googleapi.Error{
22189			Code:   res.StatusCode,
22190			Header: res.Header,
22191		}
22192	}
22193	if err != nil {
22194		return nil, err
22195	}
22196	defer googleapi.CloseBody(res)
22197	if err := googleapi.CheckResponse(res); err != nil {
22198		return nil, err
22199	}
22200	ret := &Campaign{
22201		ServerResponse: googleapi.ServerResponse{
22202			Header:         res.Header,
22203			HTTPStatusCode: res.StatusCode,
22204		},
22205	}
22206	target := &ret
22207	if err := gensupport.DecodeResponse(target, res); err != nil {
22208		return nil, err
22209	}
22210	return ret, nil
22211	// {
22212	//   "description": "Gets one campaign by ID.",
22213	//   "flatPath": "userprofiles/{profileId}/campaigns/{id}",
22214	//   "httpMethod": "GET",
22215	//   "id": "dfareporting.campaigns.get",
22216	//   "parameterOrder": [
22217	//     "profileId",
22218	//     "id"
22219	//   ],
22220	//   "parameters": {
22221	//     "id": {
22222	//       "description": "Campaign ID.",
22223	//       "format": "int64",
22224	//       "location": "path",
22225	//       "required": true,
22226	//       "type": "string"
22227	//     },
22228	//     "profileId": {
22229	//       "description": "User profile ID associated with this request.",
22230	//       "format": "int64",
22231	//       "location": "path",
22232	//       "required": true,
22233	//       "type": "string"
22234	//     }
22235	//   },
22236	//   "path": "userprofiles/{profileId}/campaigns/{id}",
22237	//   "response": {
22238	//     "$ref": "Campaign"
22239	//   },
22240	//   "scopes": [
22241	//     "https://www.googleapis.com/auth/dfatrafficking"
22242	//   ]
22243	// }
22244
22245}
22246
22247// method id "dfareporting.campaigns.insert":
22248
22249type CampaignsInsertCall struct {
22250	s          *Service
22251	profileId  int64
22252	campaign   *Campaign
22253	urlParams_ gensupport.URLParams
22254	ctx_       context.Context
22255	header_    http.Header
22256}
22257
22258// Insert: Inserts a new campaign.
22259//
22260// - profileId: User profile ID associated with this request.
22261func (r *CampaignsService) Insert(profileId int64, campaign *Campaign) *CampaignsInsertCall {
22262	c := &CampaignsInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
22263	c.profileId = profileId
22264	c.campaign = campaign
22265	return c
22266}
22267
22268// Fields allows partial responses to be retrieved. See
22269// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
22270// for more information.
22271func (c *CampaignsInsertCall) Fields(s ...googleapi.Field) *CampaignsInsertCall {
22272	c.urlParams_.Set("fields", googleapi.CombineFields(s))
22273	return c
22274}
22275
22276// Context sets the context to be used in this call's Do method. Any
22277// pending HTTP request will be aborted if the provided context is
22278// canceled.
22279func (c *CampaignsInsertCall) Context(ctx context.Context) *CampaignsInsertCall {
22280	c.ctx_ = ctx
22281	return c
22282}
22283
22284// Header returns an http.Header that can be modified by the caller to
22285// add HTTP headers to the request.
22286func (c *CampaignsInsertCall) Header() http.Header {
22287	if c.header_ == nil {
22288		c.header_ = make(http.Header)
22289	}
22290	return c.header_
22291}
22292
22293func (c *CampaignsInsertCall) doRequest(alt string) (*http.Response, error) {
22294	reqHeaders := make(http.Header)
22295	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
22296	for k, v := range c.header_ {
22297		reqHeaders[k] = v
22298	}
22299	reqHeaders.Set("User-Agent", c.s.userAgent())
22300	var body io.Reader = nil
22301	body, err := googleapi.WithoutDataWrapper.JSONReader(c.campaign)
22302	if err != nil {
22303		return nil, err
22304	}
22305	reqHeaders.Set("Content-Type", "application/json")
22306	c.urlParams_.Set("alt", alt)
22307	c.urlParams_.Set("prettyPrint", "false")
22308	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/campaigns")
22309	urls += "?" + c.urlParams_.Encode()
22310	req, err := http.NewRequest("POST", urls, body)
22311	if err != nil {
22312		return nil, err
22313	}
22314	req.Header = reqHeaders
22315	googleapi.Expand(req.URL, map[string]string{
22316		"profileId": strconv.FormatInt(c.profileId, 10),
22317	})
22318	return gensupport.SendRequest(c.ctx_, c.s.client, req)
22319}
22320
22321// Do executes the "dfareporting.campaigns.insert" call.
22322// Exactly one of *Campaign or error will be non-nil. Any non-2xx status
22323// code is an error. Response headers are in either
22324// *Campaign.ServerResponse.Header or (if a response was returned at
22325// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
22326// to check whether the returned error was because
22327// http.StatusNotModified was returned.
22328func (c *CampaignsInsertCall) Do(opts ...googleapi.CallOption) (*Campaign, error) {
22329	gensupport.SetOptions(c.urlParams_, opts...)
22330	res, err := c.doRequest("json")
22331	if res != nil && res.StatusCode == http.StatusNotModified {
22332		if res.Body != nil {
22333			res.Body.Close()
22334		}
22335		return nil, &googleapi.Error{
22336			Code:   res.StatusCode,
22337			Header: res.Header,
22338		}
22339	}
22340	if err != nil {
22341		return nil, err
22342	}
22343	defer googleapi.CloseBody(res)
22344	if err := googleapi.CheckResponse(res); err != nil {
22345		return nil, err
22346	}
22347	ret := &Campaign{
22348		ServerResponse: googleapi.ServerResponse{
22349			Header:         res.Header,
22350			HTTPStatusCode: res.StatusCode,
22351		},
22352	}
22353	target := &ret
22354	if err := gensupport.DecodeResponse(target, res); err != nil {
22355		return nil, err
22356	}
22357	return ret, nil
22358	// {
22359	//   "description": "Inserts a new campaign.",
22360	//   "flatPath": "userprofiles/{profileId}/campaigns",
22361	//   "httpMethod": "POST",
22362	//   "id": "dfareporting.campaigns.insert",
22363	//   "parameterOrder": [
22364	//     "profileId"
22365	//   ],
22366	//   "parameters": {
22367	//     "profileId": {
22368	//       "description": "User profile ID associated with this request.",
22369	//       "format": "int64",
22370	//       "location": "path",
22371	//       "required": true,
22372	//       "type": "string"
22373	//     }
22374	//   },
22375	//   "path": "userprofiles/{profileId}/campaigns",
22376	//   "request": {
22377	//     "$ref": "Campaign"
22378	//   },
22379	//   "response": {
22380	//     "$ref": "Campaign"
22381	//   },
22382	//   "scopes": [
22383	//     "https://www.googleapis.com/auth/dfatrafficking"
22384	//   ]
22385	// }
22386
22387}
22388
22389// method id "dfareporting.campaigns.list":
22390
22391type CampaignsListCall struct {
22392	s            *Service
22393	profileId    int64
22394	urlParams_   gensupport.URLParams
22395	ifNoneMatch_ string
22396	ctx_         context.Context
22397	header_      http.Header
22398}
22399
22400// List: Retrieves a list of campaigns, possibly filtered. This method
22401// supports paging.
22402//
22403// - profileId: User profile ID associated with this request.
22404func (r *CampaignsService) List(profileId int64) *CampaignsListCall {
22405	c := &CampaignsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
22406	c.profileId = profileId
22407	return c
22408}
22409
22410// AdvertiserGroupIds sets the optional parameter "advertiserGroupIds":
22411// Select only campaigns whose advertisers belong to these advertiser
22412// groups.
22413func (c *CampaignsListCall) AdvertiserGroupIds(advertiserGroupIds ...int64) *CampaignsListCall {
22414	var advertiserGroupIds_ []string
22415	for _, v := range advertiserGroupIds {
22416		advertiserGroupIds_ = append(advertiserGroupIds_, fmt.Sprint(v))
22417	}
22418	c.urlParams_.SetMulti("advertiserGroupIds", advertiserGroupIds_)
22419	return c
22420}
22421
22422// AdvertiserIds sets the optional parameter "advertiserIds": Select
22423// only campaigns that belong to these advertisers.
22424func (c *CampaignsListCall) AdvertiserIds(advertiserIds ...int64) *CampaignsListCall {
22425	var advertiserIds_ []string
22426	for _, v := range advertiserIds {
22427		advertiserIds_ = append(advertiserIds_, fmt.Sprint(v))
22428	}
22429	c.urlParams_.SetMulti("advertiserIds", advertiserIds_)
22430	return c
22431}
22432
22433// Archived sets the optional parameter "archived": Select only archived
22434// campaigns. Don't set this field to select both archived and
22435// non-archived campaigns.
22436func (c *CampaignsListCall) Archived(archived bool) *CampaignsListCall {
22437	c.urlParams_.Set("archived", fmt.Sprint(archived))
22438	return c
22439}
22440
22441// AtLeastOneOptimizationActivity sets the optional parameter
22442// "atLeastOneOptimizationActivity": Select only campaigns that have at
22443// least one optimization activity.
22444func (c *CampaignsListCall) AtLeastOneOptimizationActivity(atLeastOneOptimizationActivity bool) *CampaignsListCall {
22445	c.urlParams_.Set("atLeastOneOptimizationActivity", fmt.Sprint(atLeastOneOptimizationActivity))
22446	return c
22447}
22448
22449// ExcludedIds sets the optional parameter "excludedIds": Exclude
22450// campaigns with these IDs.
22451func (c *CampaignsListCall) ExcludedIds(excludedIds ...int64) *CampaignsListCall {
22452	var excludedIds_ []string
22453	for _, v := range excludedIds {
22454		excludedIds_ = append(excludedIds_, fmt.Sprint(v))
22455	}
22456	c.urlParams_.SetMulti("excludedIds", excludedIds_)
22457	return c
22458}
22459
22460// Ids sets the optional parameter "ids": Select only campaigns with
22461// these IDs.
22462func (c *CampaignsListCall) Ids(ids ...int64) *CampaignsListCall {
22463	var ids_ []string
22464	for _, v := range ids {
22465		ids_ = append(ids_, fmt.Sprint(v))
22466	}
22467	c.urlParams_.SetMulti("ids", ids_)
22468	return c
22469}
22470
22471// MaxResults sets the optional parameter "maxResults": Maximum number
22472// of results to return.
22473func (c *CampaignsListCall) MaxResults(maxResults int64) *CampaignsListCall {
22474	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
22475	return c
22476}
22477
22478// OverriddenEventTagId sets the optional parameter
22479// "overriddenEventTagId": Select only campaigns that have overridden
22480// this event tag ID.
22481func (c *CampaignsListCall) OverriddenEventTagId(overriddenEventTagId int64) *CampaignsListCall {
22482	c.urlParams_.Set("overriddenEventTagId", fmt.Sprint(overriddenEventTagId))
22483	return c
22484}
22485
22486// PageToken sets the optional parameter "pageToken": Value of the
22487// nextPageToken from the previous result page.
22488func (c *CampaignsListCall) PageToken(pageToken string) *CampaignsListCall {
22489	c.urlParams_.Set("pageToken", pageToken)
22490	return c
22491}
22492
22493// SearchString sets the optional parameter "searchString": Allows
22494// searching for campaigns by name or ID. Wildcards (*) are allowed. For
22495// example, "campaign*2015" will return campaigns with names like
22496// "campaign June 2015", "campaign April 2015", or simply "campaign
22497// 2015". Most of the searches also add wildcards implicitly at the
22498// start and the end of the search string. For example, a search string
22499// of "campaign" will match campaigns with name "my campaign", "campaign
22500// 2015", or simply "campaign".
22501func (c *CampaignsListCall) SearchString(searchString string) *CampaignsListCall {
22502	c.urlParams_.Set("searchString", searchString)
22503	return c
22504}
22505
22506// SortField sets the optional parameter "sortField": Field by which to
22507// sort the list.
22508//
22509// Possible values:
22510//   "ID" (default)
22511//   "NAME"
22512func (c *CampaignsListCall) SortField(sortField string) *CampaignsListCall {
22513	c.urlParams_.Set("sortField", sortField)
22514	return c
22515}
22516
22517// SortOrder sets the optional parameter "sortOrder": Order of sorted
22518// results.
22519//
22520// Possible values:
22521//   "ASCENDING" (default)
22522//   "DESCENDING"
22523func (c *CampaignsListCall) SortOrder(sortOrder string) *CampaignsListCall {
22524	c.urlParams_.Set("sortOrder", sortOrder)
22525	return c
22526}
22527
22528// SubaccountId sets the optional parameter "subaccountId": Select only
22529// campaigns that belong to this subaccount.
22530func (c *CampaignsListCall) SubaccountId(subaccountId int64) *CampaignsListCall {
22531	c.urlParams_.Set("subaccountId", fmt.Sprint(subaccountId))
22532	return c
22533}
22534
22535// Fields allows partial responses to be retrieved. See
22536// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
22537// for more information.
22538func (c *CampaignsListCall) Fields(s ...googleapi.Field) *CampaignsListCall {
22539	c.urlParams_.Set("fields", googleapi.CombineFields(s))
22540	return c
22541}
22542
22543// IfNoneMatch sets the optional parameter which makes the operation
22544// fail if the object's ETag matches the given value. This is useful for
22545// getting updates only after the object has changed since the last
22546// request. Use googleapi.IsNotModified to check whether the response
22547// error from Do is the result of In-None-Match.
22548func (c *CampaignsListCall) IfNoneMatch(entityTag string) *CampaignsListCall {
22549	c.ifNoneMatch_ = entityTag
22550	return c
22551}
22552
22553// Context sets the context to be used in this call's Do method. Any
22554// pending HTTP request will be aborted if the provided context is
22555// canceled.
22556func (c *CampaignsListCall) Context(ctx context.Context) *CampaignsListCall {
22557	c.ctx_ = ctx
22558	return c
22559}
22560
22561// Header returns an http.Header that can be modified by the caller to
22562// add HTTP headers to the request.
22563func (c *CampaignsListCall) Header() http.Header {
22564	if c.header_ == nil {
22565		c.header_ = make(http.Header)
22566	}
22567	return c.header_
22568}
22569
22570func (c *CampaignsListCall) doRequest(alt string) (*http.Response, error) {
22571	reqHeaders := make(http.Header)
22572	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
22573	for k, v := range c.header_ {
22574		reqHeaders[k] = v
22575	}
22576	reqHeaders.Set("User-Agent", c.s.userAgent())
22577	if c.ifNoneMatch_ != "" {
22578		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
22579	}
22580	var body io.Reader = nil
22581	c.urlParams_.Set("alt", alt)
22582	c.urlParams_.Set("prettyPrint", "false")
22583	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/campaigns")
22584	urls += "?" + c.urlParams_.Encode()
22585	req, err := http.NewRequest("GET", urls, body)
22586	if err != nil {
22587		return nil, err
22588	}
22589	req.Header = reqHeaders
22590	googleapi.Expand(req.URL, map[string]string{
22591		"profileId": strconv.FormatInt(c.profileId, 10),
22592	})
22593	return gensupport.SendRequest(c.ctx_, c.s.client, req)
22594}
22595
22596// Do executes the "dfareporting.campaigns.list" call.
22597// Exactly one of *CampaignsListResponse or error will be non-nil. Any
22598// non-2xx status code is an error. Response headers are in either
22599// *CampaignsListResponse.ServerResponse.Header or (if a response was
22600// returned at all) in error.(*googleapi.Error).Header. Use
22601// googleapi.IsNotModified to check whether the returned error was
22602// because http.StatusNotModified was returned.
22603func (c *CampaignsListCall) Do(opts ...googleapi.CallOption) (*CampaignsListResponse, error) {
22604	gensupport.SetOptions(c.urlParams_, opts...)
22605	res, err := c.doRequest("json")
22606	if res != nil && res.StatusCode == http.StatusNotModified {
22607		if res.Body != nil {
22608			res.Body.Close()
22609		}
22610		return nil, &googleapi.Error{
22611			Code:   res.StatusCode,
22612			Header: res.Header,
22613		}
22614	}
22615	if err != nil {
22616		return nil, err
22617	}
22618	defer googleapi.CloseBody(res)
22619	if err := googleapi.CheckResponse(res); err != nil {
22620		return nil, err
22621	}
22622	ret := &CampaignsListResponse{
22623		ServerResponse: googleapi.ServerResponse{
22624			Header:         res.Header,
22625			HTTPStatusCode: res.StatusCode,
22626		},
22627	}
22628	target := &ret
22629	if err := gensupport.DecodeResponse(target, res); err != nil {
22630		return nil, err
22631	}
22632	return ret, nil
22633	// {
22634	//   "description": "Retrieves a list of campaigns, possibly filtered. This method supports paging.",
22635	//   "flatPath": "userprofiles/{profileId}/campaigns",
22636	//   "httpMethod": "GET",
22637	//   "id": "dfareporting.campaigns.list",
22638	//   "parameterOrder": [
22639	//     "profileId"
22640	//   ],
22641	//   "parameters": {
22642	//     "advertiserGroupIds": {
22643	//       "description": "Select only campaigns whose advertisers belong to these advertiser groups.",
22644	//       "format": "int64",
22645	//       "location": "query",
22646	//       "repeated": true,
22647	//       "type": "string"
22648	//     },
22649	//     "advertiserIds": {
22650	//       "description": "Select only campaigns that belong to these advertisers.",
22651	//       "format": "int64",
22652	//       "location": "query",
22653	//       "repeated": true,
22654	//       "type": "string"
22655	//     },
22656	//     "archived": {
22657	//       "description": "Select only archived campaigns. Don't set this field to select both archived and non-archived campaigns.",
22658	//       "location": "query",
22659	//       "type": "boolean"
22660	//     },
22661	//     "atLeastOneOptimizationActivity": {
22662	//       "description": "Select only campaigns that have at least one optimization activity.",
22663	//       "location": "query",
22664	//       "type": "boolean"
22665	//     },
22666	//     "excludedIds": {
22667	//       "description": "Exclude campaigns with these IDs.",
22668	//       "format": "int64",
22669	//       "location": "query",
22670	//       "repeated": true,
22671	//       "type": "string"
22672	//     },
22673	//     "ids": {
22674	//       "description": "Select only campaigns with these IDs.",
22675	//       "format": "int64",
22676	//       "location": "query",
22677	//       "repeated": true,
22678	//       "type": "string"
22679	//     },
22680	//     "maxResults": {
22681	//       "default": "1000",
22682	//       "description": "Maximum number of results to return.",
22683	//       "format": "int32",
22684	//       "location": "query",
22685	//       "maximum": "1000",
22686	//       "minimum": "0",
22687	//       "type": "integer"
22688	//     },
22689	//     "overriddenEventTagId": {
22690	//       "description": "Select only campaigns that have overridden this event tag ID.",
22691	//       "format": "int64",
22692	//       "location": "query",
22693	//       "type": "string"
22694	//     },
22695	//     "pageToken": {
22696	//       "description": "Value of the nextPageToken from the previous result page.",
22697	//       "location": "query",
22698	//       "type": "string"
22699	//     },
22700	//     "profileId": {
22701	//       "description": "User profile ID associated with this request.",
22702	//       "format": "int64",
22703	//       "location": "path",
22704	//       "required": true,
22705	//       "type": "string"
22706	//     },
22707	//     "searchString": {
22708	//       "description": "Allows searching for campaigns by name or ID. Wildcards (*) are allowed. For example, \"campaign*2015\" will return campaigns with names like \"campaign June 2015\", \"campaign April 2015\", or simply \"campaign 2015\". Most of the searches also add wildcards implicitly at the start and the end of the search string. For example, a search string of \"campaign\" will match campaigns with name \"my campaign\", \"campaign 2015\", or simply \"campaign\".",
22709	//       "location": "query",
22710	//       "type": "string"
22711	//     },
22712	//     "sortField": {
22713	//       "default": "ID",
22714	//       "description": "Field by which to sort the list.",
22715	//       "enum": [
22716	//         "ID",
22717	//         "NAME"
22718	//       ],
22719	//       "enumDescriptions": [
22720	//         "",
22721	//         ""
22722	//       ],
22723	//       "location": "query",
22724	//       "type": "string"
22725	//     },
22726	//     "sortOrder": {
22727	//       "default": "ASCENDING",
22728	//       "description": "Order of sorted results.",
22729	//       "enum": [
22730	//         "ASCENDING",
22731	//         "DESCENDING"
22732	//       ],
22733	//       "enumDescriptions": [
22734	//         "",
22735	//         ""
22736	//       ],
22737	//       "location": "query",
22738	//       "type": "string"
22739	//     },
22740	//     "subaccountId": {
22741	//       "description": "Select only campaigns that belong to this subaccount.",
22742	//       "format": "int64",
22743	//       "location": "query",
22744	//       "type": "string"
22745	//     }
22746	//   },
22747	//   "path": "userprofiles/{profileId}/campaigns",
22748	//   "response": {
22749	//     "$ref": "CampaignsListResponse"
22750	//   },
22751	//   "scopes": [
22752	//     "https://www.googleapis.com/auth/dfatrafficking"
22753	//   ]
22754	// }
22755
22756}
22757
22758// Pages invokes f for each page of results.
22759// A non-nil error returned from f will halt the iteration.
22760// The provided context supersedes any context provided to the Context method.
22761func (c *CampaignsListCall) Pages(ctx context.Context, f func(*CampaignsListResponse) error) error {
22762	c.ctx_ = ctx
22763	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
22764	for {
22765		x, err := c.Do()
22766		if err != nil {
22767			return err
22768		}
22769		if err := f(x); err != nil {
22770			return err
22771		}
22772		if x.NextPageToken == "" {
22773			return nil
22774		}
22775		c.PageToken(x.NextPageToken)
22776	}
22777}
22778
22779// method id "dfareporting.campaigns.patch":
22780
22781type CampaignsPatchCall struct {
22782	s          *Service
22783	profileId  int64
22784	campaign   *Campaign
22785	urlParams_ gensupport.URLParams
22786	ctx_       context.Context
22787	header_    http.Header
22788}
22789
22790// Patch: Updates an existing campaign. This method supports patch
22791// semantics.
22792//
22793// - id: Campaign ID.
22794// - profileId: User profile ID associated with this request.
22795func (r *CampaignsService) Patch(profileId int64, id int64, campaign *Campaign) *CampaignsPatchCall {
22796	c := &CampaignsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
22797	c.profileId = profileId
22798	c.urlParams_.Set("id", fmt.Sprint(id))
22799	c.campaign = campaign
22800	return c
22801}
22802
22803// Fields allows partial responses to be retrieved. See
22804// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
22805// for more information.
22806func (c *CampaignsPatchCall) Fields(s ...googleapi.Field) *CampaignsPatchCall {
22807	c.urlParams_.Set("fields", googleapi.CombineFields(s))
22808	return c
22809}
22810
22811// Context sets the context to be used in this call's Do method. Any
22812// pending HTTP request will be aborted if the provided context is
22813// canceled.
22814func (c *CampaignsPatchCall) Context(ctx context.Context) *CampaignsPatchCall {
22815	c.ctx_ = ctx
22816	return c
22817}
22818
22819// Header returns an http.Header that can be modified by the caller to
22820// add HTTP headers to the request.
22821func (c *CampaignsPatchCall) Header() http.Header {
22822	if c.header_ == nil {
22823		c.header_ = make(http.Header)
22824	}
22825	return c.header_
22826}
22827
22828func (c *CampaignsPatchCall) doRequest(alt string) (*http.Response, error) {
22829	reqHeaders := make(http.Header)
22830	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
22831	for k, v := range c.header_ {
22832		reqHeaders[k] = v
22833	}
22834	reqHeaders.Set("User-Agent", c.s.userAgent())
22835	var body io.Reader = nil
22836	body, err := googleapi.WithoutDataWrapper.JSONReader(c.campaign)
22837	if err != nil {
22838		return nil, err
22839	}
22840	reqHeaders.Set("Content-Type", "application/json")
22841	c.urlParams_.Set("alt", alt)
22842	c.urlParams_.Set("prettyPrint", "false")
22843	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/campaigns")
22844	urls += "?" + c.urlParams_.Encode()
22845	req, err := http.NewRequest("PATCH", urls, body)
22846	if err != nil {
22847		return nil, err
22848	}
22849	req.Header = reqHeaders
22850	googleapi.Expand(req.URL, map[string]string{
22851		"profileId": strconv.FormatInt(c.profileId, 10),
22852	})
22853	return gensupport.SendRequest(c.ctx_, c.s.client, req)
22854}
22855
22856// Do executes the "dfareporting.campaigns.patch" call.
22857// Exactly one of *Campaign or error will be non-nil. Any non-2xx status
22858// code is an error. Response headers are in either
22859// *Campaign.ServerResponse.Header or (if a response was returned at
22860// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
22861// to check whether the returned error was because
22862// http.StatusNotModified was returned.
22863func (c *CampaignsPatchCall) Do(opts ...googleapi.CallOption) (*Campaign, error) {
22864	gensupport.SetOptions(c.urlParams_, opts...)
22865	res, err := c.doRequest("json")
22866	if res != nil && res.StatusCode == http.StatusNotModified {
22867		if res.Body != nil {
22868			res.Body.Close()
22869		}
22870		return nil, &googleapi.Error{
22871			Code:   res.StatusCode,
22872			Header: res.Header,
22873		}
22874	}
22875	if err != nil {
22876		return nil, err
22877	}
22878	defer googleapi.CloseBody(res)
22879	if err := googleapi.CheckResponse(res); err != nil {
22880		return nil, err
22881	}
22882	ret := &Campaign{
22883		ServerResponse: googleapi.ServerResponse{
22884			Header:         res.Header,
22885			HTTPStatusCode: res.StatusCode,
22886		},
22887	}
22888	target := &ret
22889	if err := gensupport.DecodeResponse(target, res); err != nil {
22890		return nil, err
22891	}
22892	return ret, nil
22893	// {
22894	//   "description": "Updates an existing campaign. This method supports patch semantics.",
22895	//   "flatPath": "userprofiles/{profileId}/campaigns",
22896	//   "httpMethod": "PATCH",
22897	//   "id": "dfareporting.campaigns.patch",
22898	//   "parameterOrder": [
22899	//     "profileId",
22900	//     "id"
22901	//   ],
22902	//   "parameters": {
22903	//     "id": {
22904	//       "description": "Campaign ID.",
22905	//       "format": "int64",
22906	//       "location": "query",
22907	//       "required": true,
22908	//       "type": "string"
22909	//     },
22910	//     "profileId": {
22911	//       "description": "User profile ID associated with this request.",
22912	//       "format": "int64",
22913	//       "location": "path",
22914	//       "required": true,
22915	//       "type": "string"
22916	//     }
22917	//   },
22918	//   "path": "userprofiles/{profileId}/campaigns",
22919	//   "request": {
22920	//     "$ref": "Campaign"
22921	//   },
22922	//   "response": {
22923	//     "$ref": "Campaign"
22924	//   },
22925	//   "scopes": [
22926	//     "https://www.googleapis.com/auth/dfatrafficking"
22927	//   ]
22928	// }
22929
22930}
22931
22932// method id "dfareporting.campaigns.update":
22933
22934type CampaignsUpdateCall struct {
22935	s          *Service
22936	profileId  int64
22937	campaign   *Campaign
22938	urlParams_ gensupport.URLParams
22939	ctx_       context.Context
22940	header_    http.Header
22941}
22942
22943// Update: Updates an existing campaign.
22944//
22945// - profileId: User profile ID associated with this request.
22946func (r *CampaignsService) Update(profileId int64, campaign *Campaign) *CampaignsUpdateCall {
22947	c := &CampaignsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
22948	c.profileId = profileId
22949	c.campaign = campaign
22950	return c
22951}
22952
22953// Fields allows partial responses to be retrieved. See
22954// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
22955// for more information.
22956func (c *CampaignsUpdateCall) Fields(s ...googleapi.Field) *CampaignsUpdateCall {
22957	c.urlParams_.Set("fields", googleapi.CombineFields(s))
22958	return c
22959}
22960
22961// Context sets the context to be used in this call's Do method. Any
22962// pending HTTP request will be aborted if the provided context is
22963// canceled.
22964func (c *CampaignsUpdateCall) Context(ctx context.Context) *CampaignsUpdateCall {
22965	c.ctx_ = ctx
22966	return c
22967}
22968
22969// Header returns an http.Header that can be modified by the caller to
22970// add HTTP headers to the request.
22971func (c *CampaignsUpdateCall) Header() http.Header {
22972	if c.header_ == nil {
22973		c.header_ = make(http.Header)
22974	}
22975	return c.header_
22976}
22977
22978func (c *CampaignsUpdateCall) doRequest(alt string) (*http.Response, error) {
22979	reqHeaders := make(http.Header)
22980	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
22981	for k, v := range c.header_ {
22982		reqHeaders[k] = v
22983	}
22984	reqHeaders.Set("User-Agent", c.s.userAgent())
22985	var body io.Reader = nil
22986	body, err := googleapi.WithoutDataWrapper.JSONReader(c.campaign)
22987	if err != nil {
22988		return nil, err
22989	}
22990	reqHeaders.Set("Content-Type", "application/json")
22991	c.urlParams_.Set("alt", alt)
22992	c.urlParams_.Set("prettyPrint", "false")
22993	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/campaigns")
22994	urls += "?" + c.urlParams_.Encode()
22995	req, err := http.NewRequest("PUT", urls, body)
22996	if err != nil {
22997		return nil, err
22998	}
22999	req.Header = reqHeaders
23000	googleapi.Expand(req.URL, map[string]string{
23001		"profileId": strconv.FormatInt(c.profileId, 10),
23002	})
23003	return gensupport.SendRequest(c.ctx_, c.s.client, req)
23004}
23005
23006// Do executes the "dfareporting.campaigns.update" call.
23007// Exactly one of *Campaign or error will be non-nil. Any non-2xx status
23008// code is an error. Response headers are in either
23009// *Campaign.ServerResponse.Header or (if a response was returned at
23010// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
23011// to check whether the returned error was because
23012// http.StatusNotModified was returned.
23013func (c *CampaignsUpdateCall) Do(opts ...googleapi.CallOption) (*Campaign, error) {
23014	gensupport.SetOptions(c.urlParams_, opts...)
23015	res, err := c.doRequest("json")
23016	if res != nil && res.StatusCode == http.StatusNotModified {
23017		if res.Body != nil {
23018			res.Body.Close()
23019		}
23020		return nil, &googleapi.Error{
23021			Code:   res.StatusCode,
23022			Header: res.Header,
23023		}
23024	}
23025	if err != nil {
23026		return nil, err
23027	}
23028	defer googleapi.CloseBody(res)
23029	if err := googleapi.CheckResponse(res); err != nil {
23030		return nil, err
23031	}
23032	ret := &Campaign{
23033		ServerResponse: googleapi.ServerResponse{
23034			Header:         res.Header,
23035			HTTPStatusCode: res.StatusCode,
23036		},
23037	}
23038	target := &ret
23039	if err := gensupport.DecodeResponse(target, res); err != nil {
23040		return nil, err
23041	}
23042	return ret, nil
23043	// {
23044	//   "description": "Updates an existing campaign.",
23045	//   "flatPath": "userprofiles/{profileId}/campaigns",
23046	//   "httpMethod": "PUT",
23047	//   "id": "dfareporting.campaigns.update",
23048	//   "parameterOrder": [
23049	//     "profileId"
23050	//   ],
23051	//   "parameters": {
23052	//     "profileId": {
23053	//       "description": "User profile ID associated with this request.",
23054	//       "format": "int64",
23055	//       "location": "path",
23056	//       "required": true,
23057	//       "type": "string"
23058	//     }
23059	//   },
23060	//   "path": "userprofiles/{profileId}/campaigns",
23061	//   "request": {
23062	//     "$ref": "Campaign"
23063	//   },
23064	//   "response": {
23065	//     "$ref": "Campaign"
23066	//   },
23067	//   "scopes": [
23068	//     "https://www.googleapis.com/auth/dfatrafficking"
23069	//   ]
23070	// }
23071
23072}
23073
23074// method id "dfareporting.changeLogs.get":
23075
23076type ChangeLogsGetCall struct {
23077	s            *Service
23078	profileId    int64
23079	id           int64
23080	urlParams_   gensupport.URLParams
23081	ifNoneMatch_ string
23082	ctx_         context.Context
23083	header_      http.Header
23084}
23085
23086// Get: Gets one change log by ID.
23087//
23088// - id: Change log ID.
23089// - profileId: User profile ID associated with this request.
23090func (r *ChangeLogsService) Get(profileId int64, id int64) *ChangeLogsGetCall {
23091	c := &ChangeLogsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
23092	c.profileId = profileId
23093	c.id = id
23094	return c
23095}
23096
23097// Fields allows partial responses to be retrieved. See
23098// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
23099// for more information.
23100func (c *ChangeLogsGetCall) Fields(s ...googleapi.Field) *ChangeLogsGetCall {
23101	c.urlParams_.Set("fields", googleapi.CombineFields(s))
23102	return c
23103}
23104
23105// IfNoneMatch sets the optional parameter which makes the operation
23106// fail if the object's ETag matches the given value. This is useful for
23107// getting updates only after the object has changed since the last
23108// request. Use googleapi.IsNotModified to check whether the response
23109// error from Do is the result of In-None-Match.
23110func (c *ChangeLogsGetCall) IfNoneMatch(entityTag string) *ChangeLogsGetCall {
23111	c.ifNoneMatch_ = entityTag
23112	return c
23113}
23114
23115// Context sets the context to be used in this call's Do method. Any
23116// pending HTTP request will be aborted if the provided context is
23117// canceled.
23118func (c *ChangeLogsGetCall) Context(ctx context.Context) *ChangeLogsGetCall {
23119	c.ctx_ = ctx
23120	return c
23121}
23122
23123// Header returns an http.Header that can be modified by the caller to
23124// add HTTP headers to the request.
23125func (c *ChangeLogsGetCall) Header() http.Header {
23126	if c.header_ == nil {
23127		c.header_ = make(http.Header)
23128	}
23129	return c.header_
23130}
23131
23132func (c *ChangeLogsGetCall) doRequest(alt string) (*http.Response, error) {
23133	reqHeaders := make(http.Header)
23134	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
23135	for k, v := range c.header_ {
23136		reqHeaders[k] = v
23137	}
23138	reqHeaders.Set("User-Agent", c.s.userAgent())
23139	if c.ifNoneMatch_ != "" {
23140		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
23141	}
23142	var body io.Reader = nil
23143	c.urlParams_.Set("alt", alt)
23144	c.urlParams_.Set("prettyPrint", "false")
23145	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/changeLogs/{id}")
23146	urls += "?" + c.urlParams_.Encode()
23147	req, err := http.NewRequest("GET", urls, body)
23148	if err != nil {
23149		return nil, err
23150	}
23151	req.Header = reqHeaders
23152	googleapi.Expand(req.URL, map[string]string{
23153		"profileId": strconv.FormatInt(c.profileId, 10),
23154		"id":        strconv.FormatInt(c.id, 10),
23155	})
23156	return gensupport.SendRequest(c.ctx_, c.s.client, req)
23157}
23158
23159// Do executes the "dfareporting.changeLogs.get" call.
23160// Exactly one of *ChangeLog or error will be non-nil. Any non-2xx
23161// status code is an error. Response headers are in either
23162// *ChangeLog.ServerResponse.Header or (if a response was returned at
23163// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
23164// to check whether the returned error was because
23165// http.StatusNotModified was returned.
23166func (c *ChangeLogsGetCall) Do(opts ...googleapi.CallOption) (*ChangeLog, error) {
23167	gensupport.SetOptions(c.urlParams_, opts...)
23168	res, err := c.doRequest("json")
23169	if res != nil && res.StatusCode == http.StatusNotModified {
23170		if res.Body != nil {
23171			res.Body.Close()
23172		}
23173		return nil, &googleapi.Error{
23174			Code:   res.StatusCode,
23175			Header: res.Header,
23176		}
23177	}
23178	if err != nil {
23179		return nil, err
23180	}
23181	defer googleapi.CloseBody(res)
23182	if err := googleapi.CheckResponse(res); err != nil {
23183		return nil, err
23184	}
23185	ret := &ChangeLog{
23186		ServerResponse: googleapi.ServerResponse{
23187			Header:         res.Header,
23188			HTTPStatusCode: res.StatusCode,
23189		},
23190	}
23191	target := &ret
23192	if err := gensupport.DecodeResponse(target, res); err != nil {
23193		return nil, err
23194	}
23195	return ret, nil
23196	// {
23197	//   "description": "Gets one change log by ID.",
23198	//   "flatPath": "userprofiles/{profileId}/changeLogs/{id}",
23199	//   "httpMethod": "GET",
23200	//   "id": "dfareporting.changeLogs.get",
23201	//   "parameterOrder": [
23202	//     "profileId",
23203	//     "id"
23204	//   ],
23205	//   "parameters": {
23206	//     "id": {
23207	//       "description": "Change log ID.",
23208	//       "format": "int64",
23209	//       "location": "path",
23210	//       "required": true,
23211	//       "type": "string"
23212	//     },
23213	//     "profileId": {
23214	//       "description": "User profile ID associated with this request.",
23215	//       "format": "int64",
23216	//       "location": "path",
23217	//       "required": true,
23218	//       "type": "string"
23219	//     }
23220	//   },
23221	//   "path": "userprofiles/{profileId}/changeLogs/{id}",
23222	//   "response": {
23223	//     "$ref": "ChangeLog"
23224	//   },
23225	//   "scopes": [
23226	//     "https://www.googleapis.com/auth/dfatrafficking"
23227	//   ]
23228	// }
23229
23230}
23231
23232// method id "dfareporting.changeLogs.list":
23233
23234type ChangeLogsListCall struct {
23235	s            *Service
23236	profileId    int64
23237	urlParams_   gensupport.URLParams
23238	ifNoneMatch_ string
23239	ctx_         context.Context
23240	header_      http.Header
23241}
23242
23243// List: Retrieves a list of change logs. This method supports paging.
23244//
23245// - profileId: User profile ID associated with this request.
23246func (r *ChangeLogsService) List(profileId int64) *ChangeLogsListCall {
23247	c := &ChangeLogsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
23248	c.profileId = profileId
23249	return c
23250}
23251
23252// Action sets the optional parameter "action": Select only change logs
23253// with the specified action.
23254//
23255// Possible values:
23256//   "ACTION_CREATE"
23257//   "ACTION_UPDATE"
23258//   "ACTION_DELETE"
23259//   "ACTION_ENABLE"
23260//   "ACTION_DISABLE"
23261//   "ACTION_ADD"
23262//   "ACTION_REMOVE"
23263//   "ACTION_MARK_AS_DEFAULT"
23264//   "ACTION_ASSOCIATE"
23265//   "ACTION_ASSIGN"
23266//   "ACTION_UNASSIGN"
23267//   "ACTION_SEND"
23268//   "ACTION_LINK"
23269//   "ACTION_UNLINK"
23270//   "ACTION_PUSH"
23271//   "ACTION_EMAIL_TAGS"
23272//   "ACTION_SHARE"
23273func (c *ChangeLogsListCall) Action(action string) *ChangeLogsListCall {
23274	c.urlParams_.Set("action", action)
23275	return c
23276}
23277
23278// Ids sets the optional parameter "ids": Select only change logs with
23279// these IDs.
23280func (c *ChangeLogsListCall) Ids(ids ...int64) *ChangeLogsListCall {
23281	var ids_ []string
23282	for _, v := range ids {
23283		ids_ = append(ids_, fmt.Sprint(v))
23284	}
23285	c.urlParams_.SetMulti("ids", ids_)
23286	return c
23287}
23288
23289// MaxChangeTime sets the optional parameter "maxChangeTime": Select
23290// only change logs whose change time is before the specified
23291// maxChangeTime.The time should be formatted as an RFC3339 date/time
23292// string. For example, for 10:54 PM on July 18th, 2015, in the
23293// America/New York time zone, the format is
23294// "2015-07-18T22:54:00-04:00". In other words, the year, month, day,
23295// the letter T, the hour (24-hour clock system), minute, second, and
23296// then the time zone offset.
23297func (c *ChangeLogsListCall) MaxChangeTime(maxChangeTime string) *ChangeLogsListCall {
23298	c.urlParams_.Set("maxChangeTime", maxChangeTime)
23299	return c
23300}
23301
23302// MaxResults sets the optional parameter "maxResults": Maximum number
23303// of results to return.
23304func (c *ChangeLogsListCall) MaxResults(maxResults int64) *ChangeLogsListCall {
23305	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
23306	return c
23307}
23308
23309// MinChangeTime sets the optional parameter "minChangeTime": Select
23310// only change logs whose change time is after the specified
23311// minChangeTime.The time should be formatted as an RFC3339 date/time
23312// string. For example, for 10:54 PM on July 18th, 2015, in the
23313// America/New York time zone, the format is
23314// "2015-07-18T22:54:00-04:00". In other words, the year, month, day,
23315// the letter T, the hour (24-hour clock system), minute, second, and
23316// then the time zone offset.
23317func (c *ChangeLogsListCall) MinChangeTime(minChangeTime string) *ChangeLogsListCall {
23318	c.urlParams_.Set("minChangeTime", minChangeTime)
23319	return c
23320}
23321
23322// ObjectIds sets the optional parameter "objectIds": Select only change
23323// logs with these object IDs.
23324func (c *ChangeLogsListCall) ObjectIds(objectIds ...int64) *ChangeLogsListCall {
23325	var objectIds_ []string
23326	for _, v := range objectIds {
23327		objectIds_ = append(objectIds_, fmt.Sprint(v))
23328	}
23329	c.urlParams_.SetMulti("objectIds", objectIds_)
23330	return c
23331}
23332
23333// ObjectType sets the optional parameter "objectType": Select only
23334// change logs with the specified object type.
23335//
23336// Possible values:
23337//   "OBJECT_ADVERTISER"
23338//   "OBJECT_FLOODLIGHT_CONFIGURATION"
23339//   "OBJECT_AD"
23340//   "OBJECT_FLOODLIGHT_ACTVITY"
23341//   "OBJECT_CAMPAIGN"
23342//   "OBJECT_FLOODLIGHT_ACTIVITY_GROUP"
23343//   "OBJECT_CREATIVE"
23344//   "OBJECT_PLACEMENT"
23345//   "OBJECT_DFA_SITE"
23346//   "OBJECT_USER_ROLE"
23347//   "OBJECT_USER_PROFILE"
23348//   "OBJECT_ADVERTISER_GROUP"
23349//   "OBJECT_ACCOUNT"
23350//   "OBJECT_SUBACCOUNT"
23351//   "OBJECT_RICHMEDIA_CREATIVE"
23352//   "OBJECT_INSTREAM_CREATIVE"
23353//   "OBJECT_MEDIA_ORDER"
23354//   "OBJECT_CONTENT_CATEGORY"
23355//   "OBJECT_PLACEMENT_STRATEGY"
23356//   "OBJECT_SD_SITE"
23357//   "OBJECT_SIZE"
23358//   "OBJECT_CREATIVE_GROUP"
23359//   "OBJECT_CREATIVE_ASSET"
23360//   "OBJECT_USER_PROFILE_FILTER"
23361//   "OBJECT_LANDING_PAGE"
23362//   "OBJECT_CREATIVE_FIELD"
23363//   "OBJECT_REMARKETING_LIST"
23364//   "OBJECT_PROVIDED_LIST_CLIENT"
23365//   "OBJECT_EVENT_TAG"
23366//   "OBJECT_CREATIVE_BUNDLE"
23367//   "OBJECT_BILLING_ACCOUNT_GROUP"
23368//   "OBJECT_BILLING_FEATURE"
23369//   "OBJECT_RATE_CARD"
23370//   "OBJECT_ACCOUNT_BILLING_FEATURE"
23371//   "OBJECT_BILLING_MINIMUM_FEE"
23372//   "OBJECT_BILLING_PROFILE"
23373//   "OBJECT_PLAYSTORE_LINK"
23374//   "OBJECT_TARGETING_TEMPLATE"
23375//   "OBJECT_SEARCH_LIFT_STUDY"
23376//   "OBJECT_FLOODLIGHT_DV360_LINK"
23377func (c *ChangeLogsListCall) ObjectType(objectType string) *ChangeLogsListCall {
23378	c.urlParams_.Set("objectType", objectType)
23379	return c
23380}
23381
23382// PageToken sets the optional parameter "pageToken": Value of the
23383// nextPageToken from the previous result page.
23384func (c *ChangeLogsListCall) PageToken(pageToken string) *ChangeLogsListCall {
23385	c.urlParams_.Set("pageToken", pageToken)
23386	return c
23387}
23388
23389// SearchString sets the optional parameter "searchString": Select only
23390// change logs whose object ID, user name, old or new values match the
23391// search string.
23392func (c *ChangeLogsListCall) SearchString(searchString string) *ChangeLogsListCall {
23393	c.urlParams_.Set("searchString", searchString)
23394	return c
23395}
23396
23397// UserProfileIds sets the optional parameter "userProfileIds": Select
23398// only change logs with these user profile IDs.
23399func (c *ChangeLogsListCall) UserProfileIds(userProfileIds ...int64) *ChangeLogsListCall {
23400	var userProfileIds_ []string
23401	for _, v := range userProfileIds {
23402		userProfileIds_ = append(userProfileIds_, fmt.Sprint(v))
23403	}
23404	c.urlParams_.SetMulti("userProfileIds", userProfileIds_)
23405	return c
23406}
23407
23408// Fields allows partial responses to be retrieved. See
23409// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
23410// for more information.
23411func (c *ChangeLogsListCall) Fields(s ...googleapi.Field) *ChangeLogsListCall {
23412	c.urlParams_.Set("fields", googleapi.CombineFields(s))
23413	return c
23414}
23415
23416// IfNoneMatch sets the optional parameter which makes the operation
23417// fail if the object's ETag matches the given value. This is useful for
23418// getting updates only after the object has changed since the last
23419// request. Use googleapi.IsNotModified to check whether the response
23420// error from Do is the result of In-None-Match.
23421func (c *ChangeLogsListCall) IfNoneMatch(entityTag string) *ChangeLogsListCall {
23422	c.ifNoneMatch_ = entityTag
23423	return c
23424}
23425
23426// Context sets the context to be used in this call's Do method. Any
23427// pending HTTP request will be aborted if the provided context is
23428// canceled.
23429func (c *ChangeLogsListCall) Context(ctx context.Context) *ChangeLogsListCall {
23430	c.ctx_ = ctx
23431	return c
23432}
23433
23434// Header returns an http.Header that can be modified by the caller to
23435// add HTTP headers to the request.
23436func (c *ChangeLogsListCall) Header() http.Header {
23437	if c.header_ == nil {
23438		c.header_ = make(http.Header)
23439	}
23440	return c.header_
23441}
23442
23443func (c *ChangeLogsListCall) doRequest(alt string) (*http.Response, error) {
23444	reqHeaders := make(http.Header)
23445	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
23446	for k, v := range c.header_ {
23447		reqHeaders[k] = v
23448	}
23449	reqHeaders.Set("User-Agent", c.s.userAgent())
23450	if c.ifNoneMatch_ != "" {
23451		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
23452	}
23453	var body io.Reader = nil
23454	c.urlParams_.Set("alt", alt)
23455	c.urlParams_.Set("prettyPrint", "false")
23456	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/changeLogs")
23457	urls += "?" + c.urlParams_.Encode()
23458	req, err := http.NewRequest("GET", urls, body)
23459	if err != nil {
23460		return nil, err
23461	}
23462	req.Header = reqHeaders
23463	googleapi.Expand(req.URL, map[string]string{
23464		"profileId": strconv.FormatInt(c.profileId, 10),
23465	})
23466	return gensupport.SendRequest(c.ctx_, c.s.client, req)
23467}
23468
23469// Do executes the "dfareporting.changeLogs.list" call.
23470// Exactly one of *ChangeLogsListResponse or error will be non-nil. Any
23471// non-2xx status code is an error. Response headers are in either
23472// *ChangeLogsListResponse.ServerResponse.Header or (if a response was
23473// returned at all) in error.(*googleapi.Error).Header. Use
23474// googleapi.IsNotModified to check whether the returned error was
23475// because http.StatusNotModified was returned.
23476func (c *ChangeLogsListCall) Do(opts ...googleapi.CallOption) (*ChangeLogsListResponse, error) {
23477	gensupport.SetOptions(c.urlParams_, opts...)
23478	res, err := c.doRequest("json")
23479	if res != nil && res.StatusCode == http.StatusNotModified {
23480		if res.Body != nil {
23481			res.Body.Close()
23482		}
23483		return nil, &googleapi.Error{
23484			Code:   res.StatusCode,
23485			Header: res.Header,
23486		}
23487	}
23488	if err != nil {
23489		return nil, err
23490	}
23491	defer googleapi.CloseBody(res)
23492	if err := googleapi.CheckResponse(res); err != nil {
23493		return nil, err
23494	}
23495	ret := &ChangeLogsListResponse{
23496		ServerResponse: googleapi.ServerResponse{
23497			Header:         res.Header,
23498			HTTPStatusCode: res.StatusCode,
23499		},
23500	}
23501	target := &ret
23502	if err := gensupport.DecodeResponse(target, res); err != nil {
23503		return nil, err
23504	}
23505	return ret, nil
23506	// {
23507	//   "description": "Retrieves a list of change logs. This method supports paging.",
23508	//   "flatPath": "userprofiles/{profileId}/changeLogs",
23509	//   "httpMethod": "GET",
23510	//   "id": "dfareporting.changeLogs.list",
23511	//   "parameterOrder": [
23512	//     "profileId"
23513	//   ],
23514	//   "parameters": {
23515	//     "action": {
23516	//       "description": "Select only change logs with the specified action.",
23517	//       "enum": [
23518	//         "ACTION_CREATE",
23519	//         "ACTION_UPDATE",
23520	//         "ACTION_DELETE",
23521	//         "ACTION_ENABLE",
23522	//         "ACTION_DISABLE",
23523	//         "ACTION_ADD",
23524	//         "ACTION_REMOVE",
23525	//         "ACTION_MARK_AS_DEFAULT",
23526	//         "ACTION_ASSOCIATE",
23527	//         "ACTION_ASSIGN",
23528	//         "ACTION_UNASSIGN",
23529	//         "ACTION_SEND",
23530	//         "ACTION_LINK",
23531	//         "ACTION_UNLINK",
23532	//         "ACTION_PUSH",
23533	//         "ACTION_EMAIL_TAGS",
23534	//         "ACTION_SHARE"
23535	//       ],
23536	//       "enumDescriptions": [
23537	//         "",
23538	//         "",
23539	//         "",
23540	//         "",
23541	//         "",
23542	//         "",
23543	//         "",
23544	//         "",
23545	//         "",
23546	//         "",
23547	//         "",
23548	//         "",
23549	//         "",
23550	//         "",
23551	//         "",
23552	//         "",
23553	//         ""
23554	//       ],
23555	//       "location": "query",
23556	//       "type": "string"
23557	//     },
23558	//     "ids": {
23559	//       "description": "Select only change logs with these IDs.",
23560	//       "format": "int64",
23561	//       "location": "query",
23562	//       "repeated": true,
23563	//       "type": "string"
23564	//     },
23565	//     "maxChangeTime": {
23566	//       "description": "Select only change logs whose change time is before the specified maxChangeTime.The time should be formatted as an RFC3339 date/time string. For example, for 10:54 PM on July 18th, 2015, in the America/New York time zone, the format is \"2015-07-18T22:54:00-04:00\". In other words, the year, month, day, the letter T, the hour (24-hour clock system), minute, second, and then the time zone offset.",
23567	//       "location": "query",
23568	//       "type": "string"
23569	//     },
23570	//     "maxResults": {
23571	//       "default": "1000",
23572	//       "description": "Maximum number of results to return.",
23573	//       "format": "int32",
23574	//       "location": "query",
23575	//       "maximum": "1000",
23576	//       "minimum": "0",
23577	//       "type": "integer"
23578	//     },
23579	//     "minChangeTime": {
23580	//       "description": "Select only change logs whose change time is after the specified minChangeTime.The time should be formatted as an RFC3339 date/time string. For example, for 10:54 PM on July 18th, 2015, in the America/New York time zone, the format is \"2015-07-18T22:54:00-04:00\". In other words, the year, month, day, the letter T, the hour (24-hour clock system), minute, second, and then the time zone offset.",
23581	//       "location": "query",
23582	//       "type": "string"
23583	//     },
23584	//     "objectIds": {
23585	//       "description": "Select only change logs with these object IDs.",
23586	//       "format": "int64",
23587	//       "location": "query",
23588	//       "repeated": true,
23589	//       "type": "string"
23590	//     },
23591	//     "objectType": {
23592	//       "description": "Select only change logs with the specified object type.",
23593	//       "enum": [
23594	//         "OBJECT_ADVERTISER",
23595	//         "OBJECT_FLOODLIGHT_CONFIGURATION",
23596	//         "OBJECT_AD",
23597	//         "OBJECT_FLOODLIGHT_ACTVITY",
23598	//         "OBJECT_CAMPAIGN",
23599	//         "OBJECT_FLOODLIGHT_ACTIVITY_GROUP",
23600	//         "OBJECT_CREATIVE",
23601	//         "OBJECT_PLACEMENT",
23602	//         "OBJECT_DFA_SITE",
23603	//         "OBJECT_USER_ROLE",
23604	//         "OBJECT_USER_PROFILE",
23605	//         "OBJECT_ADVERTISER_GROUP",
23606	//         "OBJECT_ACCOUNT",
23607	//         "OBJECT_SUBACCOUNT",
23608	//         "OBJECT_RICHMEDIA_CREATIVE",
23609	//         "OBJECT_INSTREAM_CREATIVE",
23610	//         "OBJECT_MEDIA_ORDER",
23611	//         "OBJECT_CONTENT_CATEGORY",
23612	//         "OBJECT_PLACEMENT_STRATEGY",
23613	//         "OBJECT_SD_SITE",
23614	//         "OBJECT_SIZE",
23615	//         "OBJECT_CREATIVE_GROUP",
23616	//         "OBJECT_CREATIVE_ASSET",
23617	//         "OBJECT_USER_PROFILE_FILTER",
23618	//         "OBJECT_LANDING_PAGE",
23619	//         "OBJECT_CREATIVE_FIELD",
23620	//         "OBJECT_REMARKETING_LIST",
23621	//         "OBJECT_PROVIDED_LIST_CLIENT",
23622	//         "OBJECT_EVENT_TAG",
23623	//         "OBJECT_CREATIVE_BUNDLE",
23624	//         "OBJECT_BILLING_ACCOUNT_GROUP",
23625	//         "OBJECT_BILLING_FEATURE",
23626	//         "OBJECT_RATE_CARD",
23627	//         "OBJECT_ACCOUNT_BILLING_FEATURE",
23628	//         "OBJECT_BILLING_MINIMUM_FEE",
23629	//         "OBJECT_BILLING_PROFILE",
23630	//         "OBJECT_PLAYSTORE_LINK",
23631	//         "OBJECT_TARGETING_TEMPLATE",
23632	//         "OBJECT_SEARCH_LIFT_STUDY",
23633	//         "OBJECT_FLOODLIGHT_DV360_LINK"
23634	//       ],
23635	//       "enumDescriptions": [
23636	//         "",
23637	//         "",
23638	//         "",
23639	//         "",
23640	//         "",
23641	//         "",
23642	//         "",
23643	//         "",
23644	//         "",
23645	//         "",
23646	//         "",
23647	//         "",
23648	//         "",
23649	//         "",
23650	//         "",
23651	//         "",
23652	//         "",
23653	//         "",
23654	//         "",
23655	//         "",
23656	//         "",
23657	//         "",
23658	//         "",
23659	//         "",
23660	//         "",
23661	//         "",
23662	//         "",
23663	//         "",
23664	//         "",
23665	//         "",
23666	//         "",
23667	//         "",
23668	//         "",
23669	//         "",
23670	//         "",
23671	//         "",
23672	//         "",
23673	//         "",
23674	//         "",
23675	//         ""
23676	//       ],
23677	//       "location": "query",
23678	//       "type": "string"
23679	//     },
23680	//     "pageToken": {
23681	//       "description": "Value of the nextPageToken from the previous result page.",
23682	//       "location": "query",
23683	//       "type": "string"
23684	//     },
23685	//     "profileId": {
23686	//       "description": "User profile ID associated with this request.",
23687	//       "format": "int64",
23688	//       "location": "path",
23689	//       "required": true,
23690	//       "type": "string"
23691	//     },
23692	//     "searchString": {
23693	//       "description": "Select only change logs whose object ID, user name, old or new values match the search string.",
23694	//       "location": "query",
23695	//       "type": "string"
23696	//     },
23697	//     "userProfileIds": {
23698	//       "description": "Select only change logs with these user profile IDs.",
23699	//       "format": "int64",
23700	//       "location": "query",
23701	//       "repeated": true,
23702	//       "type": "string"
23703	//     }
23704	//   },
23705	//   "path": "userprofiles/{profileId}/changeLogs",
23706	//   "response": {
23707	//     "$ref": "ChangeLogsListResponse"
23708	//   },
23709	//   "scopes": [
23710	//     "https://www.googleapis.com/auth/dfatrafficking"
23711	//   ]
23712	// }
23713
23714}
23715
23716// Pages invokes f for each page of results.
23717// A non-nil error returned from f will halt the iteration.
23718// The provided context supersedes any context provided to the Context method.
23719func (c *ChangeLogsListCall) Pages(ctx context.Context, f func(*ChangeLogsListResponse) error) error {
23720	c.ctx_ = ctx
23721	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
23722	for {
23723		x, err := c.Do()
23724		if err != nil {
23725			return err
23726		}
23727		if err := f(x); err != nil {
23728			return err
23729		}
23730		if x.NextPageToken == "" {
23731			return nil
23732		}
23733		c.PageToken(x.NextPageToken)
23734	}
23735}
23736
23737// method id "dfareporting.cities.list":
23738
23739type CitiesListCall struct {
23740	s            *Service
23741	profileId    int64
23742	urlParams_   gensupport.URLParams
23743	ifNoneMatch_ string
23744	ctx_         context.Context
23745	header_      http.Header
23746}
23747
23748// List: Retrieves a list of cities, possibly filtered.
23749//
23750// - profileId: User profile ID associated with this request.
23751func (r *CitiesService) List(profileId int64) *CitiesListCall {
23752	c := &CitiesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
23753	c.profileId = profileId
23754	return c
23755}
23756
23757// CountryDartIds sets the optional parameter "countryDartIds": Select
23758// only cities from these countries.
23759func (c *CitiesListCall) CountryDartIds(countryDartIds ...int64) *CitiesListCall {
23760	var countryDartIds_ []string
23761	for _, v := range countryDartIds {
23762		countryDartIds_ = append(countryDartIds_, fmt.Sprint(v))
23763	}
23764	c.urlParams_.SetMulti("countryDartIds", countryDartIds_)
23765	return c
23766}
23767
23768// DartIds sets the optional parameter "dartIds": Select only cities
23769// with these DART IDs.
23770func (c *CitiesListCall) DartIds(dartIds ...int64) *CitiesListCall {
23771	var dartIds_ []string
23772	for _, v := range dartIds {
23773		dartIds_ = append(dartIds_, fmt.Sprint(v))
23774	}
23775	c.urlParams_.SetMulti("dartIds", dartIds_)
23776	return c
23777}
23778
23779// NamePrefix sets the optional parameter "namePrefix": Select only
23780// cities with names starting with this prefix.
23781func (c *CitiesListCall) NamePrefix(namePrefix string) *CitiesListCall {
23782	c.urlParams_.Set("namePrefix", namePrefix)
23783	return c
23784}
23785
23786// RegionDartIds sets the optional parameter "regionDartIds": Select
23787// only cities from these regions.
23788func (c *CitiesListCall) RegionDartIds(regionDartIds ...int64) *CitiesListCall {
23789	var regionDartIds_ []string
23790	for _, v := range regionDartIds {
23791		regionDartIds_ = append(regionDartIds_, fmt.Sprint(v))
23792	}
23793	c.urlParams_.SetMulti("regionDartIds", regionDartIds_)
23794	return c
23795}
23796
23797// Fields allows partial responses to be retrieved. See
23798// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
23799// for more information.
23800func (c *CitiesListCall) Fields(s ...googleapi.Field) *CitiesListCall {
23801	c.urlParams_.Set("fields", googleapi.CombineFields(s))
23802	return c
23803}
23804
23805// IfNoneMatch sets the optional parameter which makes the operation
23806// fail if the object's ETag matches the given value. This is useful for
23807// getting updates only after the object has changed since the last
23808// request. Use googleapi.IsNotModified to check whether the response
23809// error from Do is the result of In-None-Match.
23810func (c *CitiesListCall) IfNoneMatch(entityTag string) *CitiesListCall {
23811	c.ifNoneMatch_ = entityTag
23812	return c
23813}
23814
23815// Context sets the context to be used in this call's Do method. Any
23816// pending HTTP request will be aborted if the provided context is
23817// canceled.
23818func (c *CitiesListCall) Context(ctx context.Context) *CitiesListCall {
23819	c.ctx_ = ctx
23820	return c
23821}
23822
23823// Header returns an http.Header that can be modified by the caller to
23824// add HTTP headers to the request.
23825func (c *CitiesListCall) Header() http.Header {
23826	if c.header_ == nil {
23827		c.header_ = make(http.Header)
23828	}
23829	return c.header_
23830}
23831
23832func (c *CitiesListCall) doRequest(alt string) (*http.Response, error) {
23833	reqHeaders := make(http.Header)
23834	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
23835	for k, v := range c.header_ {
23836		reqHeaders[k] = v
23837	}
23838	reqHeaders.Set("User-Agent", c.s.userAgent())
23839	if c.ifNoneMatch_ != "" {
23840		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
23841	}
23842	var body io.Reader = nil
23843	c.urlParams_.Set("alt", alt)
23844	c.urlParams_.Set("prettyPrint", "false")
23845	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/cities")
23846	urls += "?" + c.urlParams_.Encode()
23847	req, err := http.NewRequest("GET", urls, body)
23848	if err != nil {
23849		return nil, err
23850	}
23851	req.Header = reqHeaders
23852	googleapi.Expand(req.URL, map[string]string{
23853		"profileId": strconv.FormatInt(c.profileId, 10),
23854	})
23855	return gensupport.SendRequest(c.ctx_, c.s.client, req)
23856}
23857
23858// Do executes the "dfareporting.cities.list" call.
23859// Exactly one of *CitiesListResponse or error will be non-nil. Any
23860// non-2xx status code is an error. Response headers are in either
23861// *CitiesListResponse.ServerResponse.Header or (if a response was
23862// returned at all) in error.(*googleapi.Error).Header. Use
23863// googleapi.IsNotModified to check whether the returned error was
23864// because http.StatusNotModified was returned.
23865func (c *CitiesListCall) Do(opts ...googleapi.CallOption) (*CitiesListResponse, error) {
23866	gensupport.SetOptions(c.urlParams_, opts...)
23867	res, err := c.doRequest("json")
23868	if res != nil && res.StatusCode == http.StatusNotModified {
23869		if res.Body != nil {
23870			res.Body.Close()
23871		}
23872		return nil, &googleapi.Error{
23873			Code:   res.StatusCode,
23874			Header: res.Header,
23875		}
23876	}
23877	if err != nil {
23878		return nil, err
23879	}
23880	defer googleapi.CloseBody(res)
23881	if err := googleapi.CheckResponse(res); err != nil {
23882		return nil, err
23883	}
23884	ret := &CitiesListResponse{
23885		ServerResponse: googleapi.ServerResponse{
23886			Header:         res.Header,
23887			HTTPStatusCode: res.StatusCode,
23888		},
23889	}
23890	target := &ret
23891	if err := gensupport.DecodeResponse(target, res); err != nil {
23892		return nil, err
23893	}
23894	return ret, nil
23895	// {
23896	//   "description": "Retrieves a list of cities, possibly filtered.",
23897	//   "flatPath": "userprofiles/{profileId}/cities",
23898	//   "httpMethod": "GET",
23899	//   "id": "dfareporting.cities.list",
23900	//   "parameterOrder": [
23901	//     "profileId"
23902	//   ],
23903	//   "parameters": {
23904	//     "countryDartIds": {
23905	//       "description": "Select only cities from these countries.",
23906	//       "format": "int64",
23907	//       "location": "query",
23908	//       "repeated": true,
23909	//       "type": "string"
23910	//     },
23911	//     "dartIds": {
23912	//       "description": "Select only cities with these DART IDs.",
23913	//       "format": "int64",
23914	//       "location": "query",
23915	//       "repeated": true,
23916	//       "type": "string"
23917	//     },
23918	//     "namePrefix": {
23919	//       "description": "Select only cities with names starting with this prefix.",
23920	//       "location": "query",
23921	//       "type": "string"
23922	//     },
23923	//     "profileId": {
23924	//       "description": "User profile ID associated with this request.",
23925	//       "format": "int64",
23926	//       "location": "path",
23927	//       "required": true,
23928	//       "type": "string"
23929	//     },
23930	//     "regionDartIds": {
23931	//       "description": "Select only cities from these regions.",
23932	//       "format": "int64",
23933	//       "location": "query",
23934	//       "repeated": true,
23935	//       "type": "string"
23936	//     }
23937	//   },
23938	//   "path": "userprofiles/{profileId}/cities",
23939	//   "response": {
23940	//     "$ref": "CitiesListResponse"
23941	//   },
23942	//   "scopes": [
23943	//     "https://www.googleapis.com/auth/dfatrafficking"
23944	//   ]
23945	// }
23946
23947}
23948
23949// method id "dfareporting.connectionTypes.get":
23950
23951type ConnectionTypesGetCall struct {
23952	s            *Service
23953	profileId    int64
23954	id           int64
23955	urlParams_   gensupport.URLParams
23956	ifNoneMatch_ string
23957	ctx_         context.Context
23958	header_      http.Header
23959}
23960
23961// Get: Gets one connection type by ID.
23962//
23963// - id: Connection type ID.
23964// - profileId: User profile ID associated with this request.
23965func (r *ConnectionTypesService) Get(profileId int64, id int64) *ConnectionTypesGetCall {
23966	c := &ConnectionTypesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
23967	c.profileId = profileId
23968	c.id = id
23969	return c
23970}
23971
23972// Fields allows partial responses to be retrieved. See
23973// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
23974// for more information.
23975func (c *ConnectionTypesGetCall) Fields(s ...googleapi.Field) *ConnectionTypesGetCall {
23976	c.urlParams_.Set("fields", googleapi.CombineFields(s))
23977	return c
23978}
23979
23980// IfNoneMatch sets the optional parameter which makes the operation
23981// fail if the object's ETag matches the given value. This is useful for
23982// getting updates only after the object has changed since the last
23983// request. Use googleapi.IsNotModified to check whether the response
23984// error from Do is the result of In-None-Match.
23985func (c *ConnectionTypesGetCall) IfNoneMatch(entityTag string) *ConnectionTypesGetCall {
23986	c.ifNoneMatch_ = entityTag
23987	return c
23988}
23989
23990// Context sets the context to be used in this call's Do method. Any
23991// pending HTTP request will be aborted if the provided context is
23992// canceled.
23993func (c *ConnectionTypesGetCall) Context(ctx context.Context) *ConnectionTypesGetCall {
23994	c.ctx_ = ctx
23995	return c
23996}
23997
23998// Header returns an http.Header that can be modified by the caller to
23999// add HTTP headers to the request.
24000func (c *ConnectionTypesGetCall) Header() http.Header {
24001	if c.header_ == nil {
24002		c.header_ = make(http.Header)
24003	}
24004	return c.header_
24005}
24006
24007func (c *ConnectionTypesGetCall) doRequest(alt string) (*http.Response, error) {
24008	reqHeaders := make(http.Header)
24009	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
24010	for k, v := range c.header_ {
24011		reqHeaders[k] = v
24012	}
24013	reqHeaders.Set("User-Agent", c.s.userAgent())
24014	if c.ifNoneMatch_ != "" {
24015		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
24016	}
24017	var body io.Reader = nil
24018	c.urlParams_.Set("alt", alt)
24019	c.urlParams_.Set("prettyPrint", "false")
24020	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/connectionTypes/{id}")
24021	urls += "?" + c.urlParams_.Encode()
24022	req, err := http.NewRequest("GET", urls, body)
24023	if err != nil {
24024		return nil, err
24025	}
24026	req.Header = reqHeaders
24027	googleapi.Expand(req.URL, map[string]string{
24028		"profileId": strconv.FormatInt(c.profileId, 10),
24029		"id":        strconv.FormatInt(c.id, 10),
24030	})
24031	return gensupport.SendRequest(c.ctx_, c.s.client, req)
24032}
24033
24034// Do executes the "dfareporting.connectionTypes.get" call.
24035// Exactly one of *ConnectionType or error will be non-nil. Any non-2xx
24036// status code is an error. Response headers are in either
24037// *ConnectionType.ServerResponse.Header or (if a response was returned
24038// at all) in error.(*googleapi.Error).Header. Use
24039// googleapi.IsNotModified to check whether the returned error was
24040// because http.StatusNotModified was returned.
24041func (c *ConnectionTypesGetCall) Do(opts ...googleapi.CallOption) (*ConnectionType, error) {
24042	gensupport.SetOptions(c.urlParams_, opts...)
24043	res, err := c.doRequest("json")
24044	if res != nil && res.StatusCode == http.StatusNotModified {
24045		if res.Body != nil {
24046			res.Body.Close()
24047		}
24048		return nil, &googleapi.Error{
24049			Code:   res.StatusCode,
24050			Header: res.Header,
24051		}
24052	}
24053	if err != nil {
24054		return nil, err
24055	}
24056	defer googleapi.CloseBody(res)
24057	if err := googleapi.CheckResponse(res); err != nil {
24058		return nil, err
24059	}
24060	ret := &ConnectionType{
24061		ServerResponse: googleapi.ServerResponse{
24062			Header:         res.Header,
24063			HTTPStatusCode: res.StatusCode,
24064		},
24065	}
24066	target := &ret
24067	if err := gensupport.DecodeResponse(target, res); err != nil {
24068		return nil, err
24069	}
24070	return ret, nil
24071	// {
24072	//   "description": "Gets one connection type by ID.",
24073	//   "flatPath": "userprofiles/{profileId}/connectionTypes/{id}",
24074	//   "httpMethod": "GET",
24075	//   "id": "dfareporting.connectionTypes.get",
24076	//   "parameterOrder": [
24077	//     "profileId",
24078	//     "id"
24079	//   ],
24080	//   "parameters": {
24081	//     "id": {
24082	//       "description": "Connection type ID.",
24083	//       "format": "int64",
24084	//       "location": "path",
24085	//       "required": true,
24086	//       "type": "string"
24087	//     },
24088	//     "profileId": {
24089	//       "description": "User profile ID associated with this request.",
24090	//       "format": "int64",
24091	//       "location": "path",
24092	//       "required": true,
24093	//       "type": "string"
24094	//     }
24095	//   },
24096	//   "path": "userprofiles/{profileId}/connectionTypes/{id}",
24097	//   "response": {
24098	//     "$ref": "ConnectionType"
24099	//   },
24100	//   "scopes": [
24101	//     "https://www.googleapis.com/auth/dfatrafficking"
24102	//   ]
24103	// }
24104
24105}
24106
24107// method id "dfareporting.connectionTypes.list":
24108
24109type ConnectionTypesListCall struct {
24110	s            *Service
24111	profileId    int64
24112	urlParams_   gensupport.URLParams
24113	ifNoneMatch_ string
24114	ctx_         context.Context
24115	header_      http.Header
24116}
24117
24118// List: Retrieves a list of connection types.
24119//
24120// - profileId: User profile ID associated with this request.
24121func (r *ConnectionTypesService) List(profileId int64) *ConnectionTypesListCall {
24122	c := &ConnectionTypesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
24123	c.profileId = profileId
24124	return c
24125}
24126
24127// Fields allows partial responses to be retrieved. See
24128// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
24129// for more information.
24130func (c *ConnectionTypesListCall) Fields(s ...googleapi.Field) *ConnectionTypesListCall {
24131	c.urlParams_.Set("fields", googleapi.CombineFields(s))
24132	return c
24133}
24134
24135// IfNoneMatch sets the optional parameter which makes the operation
24136// fail if the object's ETag matches the given value. This is useful for
24137// getting updates only after the object has changed since the last
24138// request. Use googleapi.IsNotModified to check whether the response
24139// error from Do is the result of In-None-Match.
24140func (c *ConnectionTypesListCall) IfNoneMatch(entityTag string) *ConnectionTypesListCall {
24141	c.ifNoneMatch_ = entityTag
24142	return c
24143}
24144
24145// Context sets the context to be used in this call's Do method. Any
24146// pending HTTP request will be aborted if the provided context is
24147// canceled.
24148func (c *ConnectionTypesListCall) Context(ctx context.Context) *ConnectionTypesListCall {
24149	c.ctx_ = ctx
24150	return c
24151}
24152
24153// Header returns an http.Header that can be modified by the caller to
24154// add HTTP headers to the request.
24155func (c *ConnectionTypesListCall) Header() http.Header {
24156	if c.header_ == nil {
24157		c.header_ = make(http.Header)
24158	}
24159	return c.header_
24160}
24161
24162func (c *ConnectionTypesListCall) doRequest(alt string) (*http.Response, error) {
24163	reqHeaders := make(http.Header)
24164	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
24165	for k, v := range c.header_ {
24166		reqHeaders[k] = v
24167	}
24168	reqHeaders.Set("User-Agent", c.s.userAgent())
24169	if c.ifNoneMatch_ != "" {
24170		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
24171	}
24172	var body io.Reader = nil
24173	c.urlParams_.Set("alt", alt)
24174	c.urlParams_.Set("prettyPrint", "false")
24175	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/connectionTypes")
24176	urls += "?" + c.urlParams_.Encode()
24177	req, err := http.NewRequest("GET", urls, body)
24178	if err != nil {
24179		return nil, err
24180	}
24181	req.Header = reqHeaders
24182	googleapi.Expand(req.URL, map[string]string{
24183		"profileId": strconv.FormatInt(c.profileId, 10),
24184	})
24185	return gensupport.SendRequest(c.ctx_, c.s.client, req)
24186}
24187
24188// Do executes the "dfareporting.connectionTypes.list" call.
24189// Exactly one of *ConnectionTypesListResponse or error will be non-nil.
24190// Any non-2xx status code is an error. Response headers are in either
24191// *ConnectionTypesListResponse.ServerResponse.Header or (if a response
24192// was returned at all) in error.(*googleapi.Error).Header. Use
24193// googleapi.IsNotModified to check whether the returned error was
24194// because http.StatusNotModified was returned.
24195func (c *ConnectionTypesListCall) Do(opts ...googleapi.CallOption) (*ConnectionTypesListResponse, error) {
24196	gensupport.SetOptions(c.urlParams_, opts...)
24197	res, err := c.doRequest("json")
24198	if res != nil && res.StatusCode == http.StatusNotModified {
24199		if res.Body != nil {
24200			res.Body.Close()
24201		}
24202		return nil, &googleapi.Error{
24203			Code:   res.StatusCode,
24204			Header: res.Header,
24205		}
24206	}
24207	if err != nil {
24208		return nil, err
24209	}
24210	defer googleapi.CloseBody(res)
24211	if err := googleapi.CheckResponse(res); err != nil {
24212		return nil, err
24213	}
24214	ret := &ConnectionTypesListResponse{
24215		ServerResponse: googleapi.ServerResponse{
24216			Header:         res.Header,
24217			HTTPStatusCode: res.StatusCode,
24218		},
24219	}
24220	target := &ret
24221	if err := gensupport.DecodeResponse(target, res); err != nil {
24222		return nil, err
24223	}
24224	return ret, nil
24225	// {
24226	//   "description": "Retrieves a list of connection types.",
24227	//   "flatPath": "userprofiles/{profileId}/connectionTypes",
24228	//   "httpMethod": "GET",
24229	//   "id": "dfareporting.connectionTypes.list",
24230	//   "parameterOrder": [
24231	//     "profileId"
24232	//   ],
24233	//   "parameters": {
24234	//     "profileId": {
24235	//       "description": "User profile ID associated with this request.",
24236	//       "format": "int64",
24237	//       "location": "path",
24238	//       "required": true,
24239	//       "type": "string"
24240	//     }
24241	//   },
24242	//   "path": "userprofiles/{profileId}/connectionTypes",
24243	//   "response": {
24244	//     "$ref": "ConnectionTypesListResponse"
24245	//   },
24246	//   "scopes": [
24247	//     "https://www.googleapis.com/auth/dfatrafficking"
24248	//   ]
24249	// }
24250
24251}
24252
24253// method id "dfareporting.contentCategories.delete":
24254
24255type ContentCategoriesDeleteCall struct {
24256	s          *Service
24257	profileId  int64
24258	id         int64
24259	urlParams_ gensupport.URLParams
24260	ctx_       context.Context
24261	header_    http.Header
24262}
24263
24264// Delete: Deletes an existing content category.
24265//
24266// - id: Content category ID.
24267// - profileId: User profile ID associated with this request.
24268func (r *ContentCategoriesService) Delete(profileId int64, id int64) *ContentCategoriesDeleteCall {
24269	c := &ContentCategoriesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
24270	c.profileId = profileId
24271	c.id = id
24272	return c
24273}
24274
24275// Fields allows partial responses to be retrieved. See
24276// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
24277// for more information.
24278func (c *ContentCategoriesDeleteCall) Fields(s ...googleapi.Field) *ContentCategoriesDeleteCall {
24279	c.urlParams_.Set("fields", googleapi.CombineFields(s))
24280	return c
24281}
24282
24283// Context sets the context to be used in this call's Do method. Any
24284// pending HTTP request will be aborted if the provided context is
24285// canceled.
24286func (c *ContentCategoriesDeleteCall) Context(ctx context.Context) *ContentCategoriesDeleteCall {
24287	c.ctx_ = ctx
24288	return c
24289}
24290
24291// Header returns an http.Header that can be modified by the caller to
24292// add HTTP headers to the request.
24293func (c *ContentCategoriesDeleteCall) Header() http.Header {
24294	if c.header_ == nil {
24295		c.header_ = make(http.Header)
24296	}
24297	return c.header_
24298}
24299
24300func (c *ContentCategoriesDeleteCall) doRequest(alt string) (*http.Response, error) {
24301	reqHeaders := make(http.Header)
24302	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
24303	for k, v := range c.header_ {
24304		reqHeaders[k] = v
24305	}
24306	reqHeaders.Set("User-Agent", c.s.userAgent())
24307	var body io.Reader = nil
24308	c.urlParams_.Set("alt", alt)
24309	c.urlParams_.Set("prettyPrint", "false")
24310	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/contentCategories/{id}")
24311	urls += "?" + c.urlParams_.Encode()
24312	req, err := http.NewRequest("DELETE", urls, body)
24313	if err != nil {
24314		return nil, err
24315	}
24316	req.Header = reqHeaders
24317	googleapi.Expand(req.URL, map[string]string{
24318		"profileId": strconv.FormatInt(c.profileId, 10),
24319		"id":        strconv.FormatInt(c.id, 10),
24320	})
24321	return gensupport.SendRequest(c.ctx_, c.s.client, req)
24322}
24323
24324// Do executes the "dfareporting.contentCategories.delete" call.
24325func (c *ContentCategoriesDeleteCall) Do(opts ...googleapi.CallOption) error {
24326	gensupport.SetOptions(c.urlParams_, opts...)
24327	res, err := c.doRequest("json")
24328	if err != nil {
24329		return err
24330	}
24331	defer googleapi.CloseBody(res)
24332	if err := googleapi.CheckResponse(res); err != nil {
24333		return err
24334	}
24335	return nil
24336	// {
24337	//   "description": "Deletes an existing content category.",
24338	//   "flatPath": "userprofiles/{profileId}/contentCategories/{id}",
24339	//   "httpMethod": "DELETE",
24340	//   "id": "dfareporting.contentCategories.delete",
24341	//   "parameterOrder": [
24342	//     "profileId",
24343	//     "id"
24344	//   ],
24345	//   "parameters": {
24346	//     "id": {
24347	//       "description": "Content category ID.",
24348	//       "format": "int64",
24349	//       "location": "path",
24350	//       "required": true,
24351	//       "type": "string"
24352	//     },
24353	//     "profileId": {
24354	//       "description": "User profile ID associated with this request.",
24355	//       "format": "int64",
24356	//       "location": "path",
24357	//       "required": true,
24358	//       "type": "string"
24359	//     }
24360	//   },
24361	//   "path": "userprofiles/{profileId}/contentCategories/{id}",
24362	//   "scopes": [
24363	//     "https://www.googleapis.com/auth/dfatrafficking"
24364	//   ]
24365	// }
24366
24367}
24368
24369// method id "dfareporting.contentCategories.get":
24370
24371type ContentCategoriesGetCall struct {
24372	s            *Service
24373	profileId    int64
24374	id           int64
24375	urlParams_   gensupport.URLParams
24376	ifNoneMatch_ string
24377	ctx_         context.Context
24378	header_      http.Header
24379}
24380
24381// Get: Gets one content category by ID.
24382//
24383// - id: Content category ID.
24384// - profileId: User profile ID associated with this request.
24385func (r *ContentCategoriesService) Get(profileId int64, id int64) *ContentCategoriesGetCall {
24386	c := &ContentCategoriesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
24387	c.profileId = profileId
24388	c.id = id
24389	return c
24390}
24391
24392// Fields allows partial responses to be retrieved. See
24393// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
24394// for more information.
24395func (c *ContentCategoriesGetCall) Fields(s ...googleapi.Field) *ContentCategoriesGetCall {
24396	c.urlParams_.Set("fields", googleapi.CombineFields(s))
24397	return c
24398}
24399
24400// IfNoneMatch sets the optional parameter which makes the operation
24401// fail if the object's ETag matches the given value. This is useful for
24402// getting updates only after the object has changed since the last
24403// request. Use googleapi.IsNotModified to check whether the response
24404// error from Do is the result of In-None-Match.
24405func (c *ContentCategoriesGetCall) IfNoneMatch(entityTag string) *ContentCategoriesGetCall {
24406	c.ifNoneMatch_ = entityTag
24407	return c
24408}
24409
24410// Context sets the context to be used in this call's Do method. Any
24411// pending HTTP request will be aborted if the provided context is
24412// canceled.
24413func (c *ContentCategoriesGetCall) Context(ctx context.Context) *ContentCategoriesGetCall {
24414	c.ctx_ = ctx
24415	return c
24416}
24417
24418// Header returns an http.Header that can be modified by the caller to
24419// add HTTP headers to the request.
24420func (c *ContentCategoriesGetCall) Header() http.Header {
24421	if c.header_ == nil {
24422		c.header_ = make(http.Header)
24423	}
24424	return c.header_
24425}
24426
24427func (c *ContentCategoriesGetCall) doRequest(alt string) (*http.Response, error) {
24428	reqHeaders := make(http.Header)
24429	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
24430	for k, v := range c.header_ {
24431		reqHeaders[k] = v
24432	}
24433	reqHeaders.Set("User-Agent", c.s.userAgent())
24434	if c.ifNoneMatch_ != "" {
24435		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
24436	}
24437	var body io.Reader = nil
24438	c.urlParams_.Set("alt", alt)
24439	c.urlParams_.Set("prettyPrint", "false")
24440	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/contentCategories/{id}")
24441	urls += "?" + c.urlParams_.Encode()
24442	req, err := http.NewRequest("GET", urls, body)
24443	if err != nil {
24444		return nil, err
24445	}
24446	req.Header = reqHeaders
24447	googleapi.Expand(req.URL, map[string]string{
24448		"profileId": strconv.FormatInt(c.profileId, 10),
24449		"id":        strconv.FormatInt(c.id, 10),
24450	})
24451	return gensupport.SendRequest(c.ctx_, c.s.client, req)
24452}
24453
24454// Do executes the "dfareporting.contentCategories.get" call.
24455// Exactly one of *ContentCategory or error will be non-nil. Any non-2xx
24456// status code is an error. Response headers are in either
24457// *ContentCategory.ServerResponse.Header or (if a response was returned
24458// at all) in error.(*googleapi.Error).Header. Use
24459// googleapi.IsNotModified to check whether the returned error was
24460// because http.StatusNotModified was returned.
24461func (c *ContentCategoriesGetCall) Do(opts ...googleapi.CallOption) (*ContentCategory, error) {
24462	gensupport.SetOptions(c.urlParams_, opts...)
24463	res, err := c.doRequest("json")
24464	if res != nil && res.StatusCode == http.StatusNotModified {
24465		if res.Body != nil {
24466			res.Body.Close()
24467		}
24468		return nil, &googleapi.Error{
24469			Code:   res.StatusCode,
24470			Header: res.Header,
24471		}
24472	}
24473	if err != nil {
24474		return nil, err
24475	}
24476	defer googleapi.CloseBody(res)
24477	if err := googleapi.CheckResponse(res); err != nil {
24478		return nil, err
24479	}
24480	ret := &ContentCategory{
24481		ServerResponse: googleapi.ServerResponse{
24482			Header:         res.Header,
24483			HTTPStatusCode: res.StatusCode,
24484		},
24485	}
24486	target := &ret
24487	if err := gensupport.DecodeResponse(target, res); err != nil {
24488		return nil, err
24489	}
24490	return ret, nil
24491	// {
24492	//   "description": "Gets one content category by ID.",
24493	//   "flatPath": "userprofiles/{profileId}/contentCategories/{id}",
24494	//   "httpMethod": "GET",
24495	//   "id": "dfareporting.contentCategories.get",
24496	//   "parameterOrder": [
24497	//     "profileId",
24498	//     "id"
24499	//   ],
24500	//   "parameters": {
24501	//     "id": {
24502	//       "description": "Content category ID.",
24503	//       "format": "int64",
24504	//       "location": "path",
24505	//       "required": true,
24506	//       "type": "string"
24507	//     },
24508	//     "profileId": {
24509	//       "description": "User profile ID associated with this request.",
24510	//       "format": "int64",
24511	//       "location": "path",
24512	//       "required": true,
24513	//       "type": "string"
24514	//     }
24515	//   },
24516	//   "path": "userprofiles/{profileId}/contentCategories/{id}",
24517	//   "response": {
24518	//     "$ref": "ContentCategory"
24519	//   },
24520	//   "scopes": [
24521	//     "https://www.googleapis.com/auth/dfatrafficking"
24522	//   ]
24523	// }
24524
24525}
24526
24527// method id "dfareporting.contentCategories.insert":
24528
24529type ContentCategoriesInsertCall struct {
24530	s               *Service
24531	profileId       int64
24532	contentcategory *ContentCategory
24533	urlParams_      gensupport.URLParams
24534	ctx_            context.Context
24535	header_         http.Header
24536}
24537
24538// Insert: Inserts a new content category.
24539//
24540// - profileId: User profile ID associated with this request.
24541func (r *ContentCategoriesService) Insert(profileId int64, contentcategory *ContentCategory) *ContentCategoriesInsertCall {
24542	c := &ContentCategoriesInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
24543	c.profileId = profileId
24544	c.contentcategory = contentcategory
24545	return c
24546}
24547
24548// Fields allows partial responses to be retrieved. See
24549// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
24550// for more information.
24551func (c *ContentCategoriesInsertCall) Fields(s ...googleapi.Field) *ContentCategoriesInsertCall {
24552	c.urlParams_.Set("fields", googleapi.CombineFields(s))
24553	return c
24554}
24555
24556// Context sets the context to be used in this call's Do method. Any
24557// pending HTTP request will be aborted if the provided context is
24558// canceled.
24559func (c *ContentCategoriesInsertCall) Context(ctx context.Context) *ContentCategoriesInsertCall {
24560	c.ctx_ = ctx
24561	return c
24562}
24563
24564// Header returns an http.Header that can be modified by the caller to
24565// add HTTP headers to the request.
24566func (c *ContentCategoriesInsertCall) Header() http.Header {
24567	if c.header_ == nil {
24568		c.header_ = make(http.Header)
24569	}
24570	return c.header_
24571}
24572
24573func (c *ContentCategoriesInsertCall) doRequest(alt string) (*http.Response, error) {
24574	reqHeaders := make(http.Header)
24575	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
24576	for k, v := range c.header_ {
24577		reqHeaders[k] = v
24578	}
24579	reqHeaders.Set("User-Agent", c.s.userAgent())
24580	var body io.Reader = nil
24581	body, err := googleapi.WithoutDataWrapper.JSONReader(c.contentcategory)
24582	if err != nil {
24583		return nil, err
24584	}
24585	reqHeaders.Set("Content-Type", "application/json")
24586	c.urlParams_.Set("alt", alt)
24587	c.urlParams_.Set("prettyPrint", "false")
24588	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/contentCategories")
24589	urls += "?" + c.urlParams_.Encode()
24590	req, err := http.NewRequest("POST", urls, body)
24591	if err != nil {
24592		return nil, err
24593	}
24594	req.Header = reqHeaders
24595	googleapi.Expand(req.URL, map[string]string{
24596		"profileId": strconv.FormatInt(c.profileId, 10),
24597	})
24598	return gensupport.SendRequest(c.ctx_, c.s.client, req)
24599}
24600
24601// Do executes the "dfareporting.contentCategories.insert" call.
24602// Exactly one of *ContentCategory or error will be non-nil. Any non-2xx
24603// status code is an error. Response headers are in either
24604// *ContentCategory.ServerResponse.Header or (if a response was returned
24605// at all) in error.(*googleapi.Error).Header. Use
24606// googleapi.IsNotModified to check whether the returned error was
24607// because http.StatusNotModified was returned.
24608func (c *ContentCategoriesInsertCall) Do(opts ...googleapi.CallOption) (*ContentCategory, error) {
24609	gensupport.SetOptions(c.urlParams_, opts...)
24610	res, err := c.doRequest("json")
24611	if res != nil && res.StatusCode == http.StatusNotModified {
24612		if res.Body != nil {
24613			res.Body.Close()
24614		}
24615		return nil, &googleapi.Error{
24616			Code:   res.StatusCode,
24617			Header: res.Header,
24618		}
24619	}
24620	if err != nil {
24621		return nil, err
24622	}
24623	defer googleapi.CloseBody(res)
24624	if err := googleapi.CheckResponse(res); err != nil {
24625		return nil, err
24626	}
24627	ret := &ContentCategory{
24628		ServerResponse: googleapi.ServerResponse{
24629			Header:         res.Header,
24630			HTTPStatusCode: res.StatusCode,
24631		},
24632	}
24633	target := &ret
24634	if err := gensupport.DecodeResponse(target, res); err != nil {
24635		return nil, err
24636	}
24637	return ret, nil
24638	// {
24639	//   "description": "Inserts a new content category.",
24640	//   "flatPath": "userprofiles/{profileId}/contentCategories",
24641	//   "httpMethod": "POST",
24642	//   "id": "dfareporting.contentCategories.insert",
24643	//   "parameterOrder": [
24644	//     "profileId"
24645	//   ],
24646	//   "parameters": {
24647	//     "profileId": {
24648	//       "description": "User profile ID associated with this request.",
24649	//       "format": "int64",
24650	//       "location": "path",
24651	//       "required": true,
24652	//       "type": "string"
24653	//     }
24654	//   },
24655	//   "path": "userprofiles/{profileId}/contentCategories",
24656	//   "request": {
24657	//     "$ref": "ContentCategory"
24658	//   },
24659	//   "response": {
24660	//     "$ref": "ContentCategory"
24661	//   },
24662	//   "scopes": [
24663	//     "https://www.googleapis.com/auth/dfatrafficking"
24664	//   ]
24665	// }
24666
24667}
24668
24669// method id "dfareporting.contentCategories.list":
24670
24671type ContentCategoriesListCall struct {
24672	s            *Service
24673	profileId    int64
24674	urlParams_   gensupport.URLParams
24675	ifNoneMatch_ string
24676	ctx_         context.Context
24677	header_      http.Header
24678}
24679
24680// List: Retrieves a list of content categories, possibly filtered. This
24681// method supports paging.
24682//
24683// - profileId: User profile ID associated with this request.
24684func (r *ContentCategoriesService) List(profileId int64) *ContentCategoriesListCall {
24685	c := &ContentCategoriesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
24686	c.profileId = profileId
24687	return c
24688}
24689
24690// Ids sets the optional parameter "ids": Select only content categories
24691// with these IDs.
24692func (c *ContentCategoriesListCall) Ids(ids ...int64) *ContentCategoriesListCall {
24693	var ids_ []string
24694	for _, v := range ids {
24695		ids_ = append(ids_, fmt.Sprint(v))
24696	}
24697	c.urlParams_.SetMulti("ids", ids_)
24698	return c
24699}
24700
24701// MaxResults sets the optional parameter "maxResults": Maximum number
24702// of results to return.
24703func (c *ContentCategoriesListCall) MaxResults(maxResults int64) *ContentCategoriesListCall {
24704	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
24705	return c
24706}
24707
24708// PageToken sets the optional parameter "pageToken": Value of the
24709// nextPageToken from the previous result page.
24710func (c *ContentCategoriesListCall) PageToken(pageToken string) *ContentCategoriesListCall {
24711	c.urlParams_.Set("pageToken", pageToken)
24712	return c
24713}
24714
24715// SearchString sets the optional parameter "searchString": Allows
24716// searching for objects by name or ID. Wildcards (*) are allowed. For
24717// example, "contentcategory*2015" will return objects with names like
24718// "contentcategory June 2015", "contentcategory April 2015", or simply
24719// "contentcategory 2015". Most of the searches also add wildcards
24720// implicitly at the start and the end of the search string. For
24721// example, a search string of "contentcategory" will match objects with
24722// name "my contentcategory", "contentcategory 2015", or simply
24723// "contentcategory".
24724func (c *ContentCategoriesListCall) SearchString(searchString string) *ContentCategoriesListCall {
24725	c.urlParams_.Set("searchString", searchString)
24726	return c
24727}
24728
24729// SortField sets the optional parameter "sortField": Field by which to
24730// sort the list.
24731//
24732// Possible values:
24733//   "ID" (default)
24734//   "NAME"
24735func (c *ContentCategoriesListCall) SortField(sortField string) *ContentCategoriesListCall {
24736	c.urlParams_.Set("sortField", sortField)
24737	return c
24738}
24739
24740// SortOrder sets the optional parameter "sortOrder": Order of sorted
24741// results.
24742//
24743// Possible values:
24744//   "ASCENDING" (default)
24745//   "DESCENDING"
24746func (c *ContentCategoriesListCall) SortOrder(sortOrder string) *ContentCategoriesListCall {
24747	c.urlParams_.Set("sortOrder", sortOrder)
24748	return c
24749}
24750
24751// Fields allows partial responses to be retrieved. See
24752// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
24753// for more information.
24754func (c *ContentCategoriesListCall) Fields(s ...googleapi.Field) *ContentCategoriesListCall {
24755	c.urlParams_.Set("fields", googleapi.CombineFields(s))
24756	return c
24757}
24758
24759// IfNoneMatch sets the optional parameter which makes the operation
24760// fail if the object's ETag matches the given value. This is useful for
24761// getting updates only after the object has changed since the last
24762// request. Use googleapi.IsNotModified to check whether the response
24763// error from Do is the result of In-None-Match.
24764func (c *ContentCategoriesListCall) IfNoneMatch(entityTag string) *ContentCategoriesListCall {
24765	c.ifNoneMatch_ = entityTag
24766	return c
24767}
24768
24769// Context sets the context to be used in this call's Do method. Any
24770// pending HTTP request will be aborted if the provided context is
24771// canceled.
24772func (c *ContentCategoriesListCall) Context(ctx context.Context) *ContentCategoriesListCall {
24773	c.ctx_ = ctx
24774	return c
24775}
24776
24777// Header returns an http.Header that can be modified by the caller to
24778// add HTTP headers to the request.
24779func (c *ContentCategoriesListCall) Header() http.Header {
24780	if c.header_ == nil {
24781		c.header_ = make(http.Header)
24782	}
24783	return c.header_
24784}
24785
24786func (c *ContentCategoriesListCall) doRequest(alt string) (*http.Response, error) {
24787	reqHeaders := make(http.Header)
24788	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
24789	for k, v := range c.header_ {
24790		reqHeaders[k] = v
24791	}
24792	reqHeaders.Set("User-Agent", c.s.userAgent())
24793	if c.ifNoneMatch_ != "" {
24794		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
24795	}
24796	var body io.Reader = nil
24797	c.urlParams_.Set("alt", alt)
24798	c.urlParams_.Set("prettyPrint", "false")
24799	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/contentCategories")
24800	urls += "?" + c.urlParams_.Encode()
24801	req, err := http.NewRequest("GET", urls, body)
24802	if err != nil {
24803		return nil, err
24804	}
24805	req.Header = reqHeaders
24806	googleapi.Expand(req.URL, map[string]string{
24807		"profileId": strconv.FormatInt(c.profileId, 10),
24808	})
24809	return gensupport.SendRequest(c.ctx_, c.s.client, req)
24810}
24811
24812// Do executes the "dfareporting.contentCategories.list" call.
24813// Exactly one of *ContentCategoriesListResponse or error will be
24814// non-nil. Any non-2xx status code is an error. Response headers are in
24815// either *ContentCategoriesListResponse.ServerResponse.Header or (if a
24816// response was returned at all) in error.(*googleapi.Error).Header. Use
24817// googleapi.IsNotModified to check whether the returned error was
24818// because http.StatusNotModified was returned.
24819func (c *ContentCategoriesListCall) Do(opts ...googleapi.CallOption) (*ContentCategoriesListResponse, error) {
24820	gensupport.SetOptions(c.urlParams_, opts...)
24821	res, err := c.doRequest("json")
24822	if res != nil && res.StatusCode == http.StatusNotModified {
24823		if res.Body != nil {
24824			res.Body.Close()
24825		}
24826		return nil, &googleapi.Error{
24827			Code:   res.StatusCode,
24828			Header: res.Header,
24829		}
24830	}
24831	if err != nil {
24832		return nil, err
24833	}
24834	defer googleapi.CloseBody(res)
24835	if err := googleapi.CheckResponse(res); err != nil {
24836		return nil, err
24837	}
24838	ret := &ContentCategoriesListResponse{
24839		ServerResponse: googleapi.ServerResponse{
24840			Header:         res.Header,
24841			HTTPStatusCode: res.StatusCode,
24842		},
24843	}
24844	target := &ret
24845	if err := gensupport.DecodeResponse(target, res); err != nil {
24846		return nil, err
24847	}
24848	return ret, nil
24849	// {
24850	//   "description": "Retrieves a list of content categories, possibly filtered. This method supports paging.",
24851	//   "flatPath": "userprofiles/{profileId}/contentCategories",
24852	//   "httpMethod": "GET",
24853	//   "id": "dfareporting.contentCategories.list",
24854	//   "parameterOrder": [
24855	//     "profileId"
24856	//   ],
24857	//   "parameters": {
24858	//     "ids": {
24859	//       "description": "Select only content categories with these IDs.",
24860	//       "format": "int64",
24861	//       "location": "query",
24862	//       "repeated": true,
24863	//       "type": "string"
24864	//     },
24865	//     "maxResults": {
24866	//       "default": "1000",
24867	//       "description": "Maximum number of results to return.",
24868	//       "format": "int32",
24869	//       "location": "query",
24870	//       "maximum": "1000",
24871	//       "minimum": "0",
24872	//       "type": "integer"
24873	//     },
24874	//     "pageToken": {
24875	//       "description": "Value of the nextPageToken from the previous result page.",
24876	//       "location": "query",
24877	//       "type": "string"
24878	//     },
24879	//     "profileId": {
24880	//       "description": "User profile ID associated with this request.",
24881	//       "format": "int64",
24882	//       "location": "path",
24883	//       "required": true,
24884	//       "type": "string"
24885	//     },
24886	//     "searchString": {
24887	//       "description": "Allows searching for objects by name or ID. Wildcards (*) are allowed. For example, \"contentcategory*2015\" will return objects with names like \"contentcategory June 2015\", \"contentcategory April 2015\", or simply \"contentcategory 2015\". Most of the searches also add wildcards implicitly at the start and the end of the search string. For example, a search string of \"contentcategory\" will match objects with name \"my contentcategory\", \"contentcategory 2015\", or simply \"contentcategory\".",
24888	//       "location": "query",
24889	//       "type": "string"
24890	//     },
24891	//     "sortField": {
24892	//       "default": "ID",
24893	//       "description": "Field by which to sort the list.",
24894	//       "enum": [
24895	//         "ID",
24896	//         "NAME"
24897	//       ],
24898	//       "enumDescriptions": [
24899	//         "",
24900	//         ""
24901	//       ],
24902	//       "location": "query",
24903	//       "type": "string"
24904	//     },
24905	//     "sortOrder": {
24906	//       "default": "ASCENDING",
24907	//       "description": "Order of sorted results.",
24908	//       "enum": [
24909	//         "ASCENDING",
24910	//         "DESCENDING"
24911	//       ],
24912	//       "enumDescriptions": [
24913	//         "",
24914	//         ""
24915	//       ],
24916	//       "location": "query",
24917	//       "type": "string"
24918	//     }
24919	//   },
24920	//   "path": "userprofiles/{profileId}/contentCategories",
24921	//   "response": {
24922	//     "$ref": "ContentCategoriesListResponse"
24923	//   },
24924	//   "scopes": [
24925	//     "https://www.googleapis.com/auth/dfatrafficking"
24926	//   ]
24927	// }
24928
24929}
24930
24931// Pages invokes f for each page of results.
24932// A non-nil error returned from f will halt the iteration.
24933// The provided context supersedes any context provided to the Context method.
24934func (c *ContentCategoriesListCall) Pages(ctx context.Context, f func(*ContentCategoriesListResponse) error) error {
24935	c.ctx_ = ctx
24936	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
24937	for {
24938		x, err := c.Do()
24939		if err != nil {
24940			return err
24941		}
24942		if err := f(x); err != nil {
24943			return err
24944		}
24945		if x.NextPageToken == "" {
24946			return nil
24947		}
24948		c.PageToken(x.NextPageToken)
24949	}
24950}
24951
24952// method id "dfareporting.contentCategories.patch":
24953
24954type ContentCategoriesPatchCall struct {
24955	s               *Service
24956	profileId       int64
24957	contentcategory *ContentCategory
24958	urlParams_      gensupport.URLParams
24959	ctx_            context.Context
24960	header_         http.Header
24961}
24962
24963// Patch: Updates an existing content category. This method supports
24964// patch semantics.
24965//
24966// - id: ContentCategory ID.
24967// - profileId: User profile ID associated with this request.
24968func (r *ContentCategoriesService) Patch(profileId int64, id int64, contentcategory *ContentCategory) *ContentCategoriesPatchCall {
24969	c := &ContentCategoriesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
24970	c.profileId = profileId
24971	c.urlParams_.Set("id", fmt.Sprint(id))
24972	c.contentcategory = contentcategory
24973	return c
24974}
24975
24976// Fields allows partial responses to be retrieved. See
24977// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
24978// for more information.
24979func (c *ContentCategoriesPatchCall) Fields(s ...googleapi.Field) *ContentCategoriesPatchCall {
24980	c.urlParams_.Set("fields", googleapi.CombineFields(s))
24981	return c
24982}
24983
24984// Context sets the context to be used in this call's Do method. Any
24985// pending HTTP request will be aborted if the provided context is
24986// canceled.
24987func (c *ContentCategoriesPatchCall) Context(ctx context.Context) *ContentCategoriesPatchCall {
24988	c.ctx_ = ctx
24989	return c
24990}
24991
24992// Header returns an http.Header that can be modified by the caller to
24993// add HTTP headers to the request.
24994func (c *ContentCategoriesPatchCall) Header() http.Header {
24995	if c.header_ == nil {
24996		c.header_ = make(http.Header)
24997	}
24998	return c.header_
24999}
25000
25001func (c *ContentCategoriesPatchCall) doRequest(alt string) (*http.Response, error) {
25002	reqHeaders := make(http.Header)
25003	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
25004	for k, v := range c.header_ {
25005		reqHeaders[k] = v
25006	}
25007	reqHeaders.Set("User-Agent", c.s.userAgent())
25008	var body io.Reader = nil
25009	body, err := googleapi.WithoutDataWrapper.JSONReader(c.contentcategory)
25010	if err != nil {
25011		return nil, err
25012	}
25013	reqHeaders.Set("Content-Type", "application/json")
25014	c.urlParams_.Set("alt", alt)
25015	c.urlParams_.Set("prettyPrint", "false")
25016	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/contentCategories")
25017	urls += "?" + c.urlParams_.Encode()
25018	req, err := http.NewRequest("PATCH", urls, body)
25019	if err != nil {
25020		return nil, err
25021	}
25022	req.Header = reqHeaders
25023	googleapi.Expand(req.URL, map[string]string{
25024		"profileId": strconv.FormatInt(c.profileId, 10),
25025	})
25026	return gensupport.SendRequest(c.ctx_, c.s.client, req)
25027}
25028
25029// Do executes the "dfareporting.contentCategories.patch" call.
25030// Exactly one of *ContentCategory or error will be non-nil. Any non-2xx
25031// status code is an error. Response headers are in either
25032// *ContentCategory.ServerResponse.Header or (if a response was returned
25033// at all) in error.(*googleapi.Error).Header. Use
25034// googleapi.IsNotModified to check whether the returned error was
25035// because http.StatusNotModified was returned.
25036func (c *ContentCategoriesPatchCall) Do(opts ...googleapi.CallOption) (*ContentCategory, error) {
25037	gensupport.SetOptions(c.urlParams_, opts...)
25038	res, err := c.doRequest("json")
25039	if res != nil && res.StatusCode == http.StatusNotModified {
25040		if res.Body != nil {
25041			res.Body.Close()
25042		}
25043		return nil, &googleapi.Error{
25044			Code:   res.StatusCode,
25045			Header: res.Header,
25046		}
25047	}
25048	if err != nil {
25049		return nil, err
25050	}
25051	defer googleapi.CloseBody(res)
25052	if err := googleapi.CheckResponse(res); err != nil {
25053		return nil, err
25054	}
25055	ret := &ContentCategory{
25056		ServerResponse: googleapi.ServerResponse{
25057			Header:         res.Header,
25058			HTTPStatusCode: res.StatusCode,
25059		},
25060	}
25061	target := &ret
25062	if err := gensupport.DecodeResponse(target, res); err != nil {
25063		return nil, err
25064	}
25065	return ret, nil
25066	// {
25067	//   "description": "Updates an existing content category. This method supports patch semantics.",
25068	//   "flatPath": "userprofiles/{profileId}/contentCategories",
25069	//   "httpMethod": "PATCH",
25070	//   "id": "dfareporting.contentCategories.patch",
25071	//   "parameterOrder": [
25072	//     "profileId",
25073	//     "id"
25074	//   ],
25075	//   "parameters": {
25076	//     "id": {
25077	//       "description": "ContentCategory ID.",
25078	//       "format": "int64",
25079	//       "location": "query",
25080	//       "required": true,
25081	//       "type": "string"
25082	//     },
25083	//     "profileId": {
25084	//       "description": "User profile ID associated with this request.",
25085	//       "format": "int64",
25086	//       "location": "path",
25087	//       "required": true,
25088	//       "type": "string"
25089	//     }
25090	//   },
25091	//   "path": "userprofiles/{profileId}/contentCategories",
25092	//   "request": {
25093	//     "$ref": "ContentCategory"
25094	//   },
25095	//   "response": {
25096	//     "$ref": "ContentCategory"
25097	//   },
25098	//   "scopes": [
25099	//     "https://www.googleapis.com/auth/dfatrafficking"
25100	//   ]
25101	// }
25102
25103}
25104
25105// method id "dfareporting.contentCategories.update":
25106
25107type ContentCategoriesUpdateCall struct {
25108	s               *Service
25109	profileId       int64
25110	contentcategory *ContentCategory
25111	urlParams_      gensupport.URLParams
25112	ctx_            context.Context
25113	header_         http.Header
25114}
25115
25116// Update: Updates an existing content category.
25117//
25118// - profileId: User profile ID associated with this request.
25119func (r *ContentCategoriesService) Update(profileId int64, contentcategory *ContentCategory) *ContentCategoriesUpdateCall {
25120	c := &ContentCategoriesUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
25121	c.profileId = profileId
25122	c.contentcategory = contentcategory
25123	return c
25124}
25125
25126// Fields allows partial responses to be retrieved. See
25127// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
25128// for more information.
25129func (c *ContentCategoriesUpdateCall) Fields(s ...googleapi.Field) *ContentCategoriesUpdateCall {
25130	c.urlParams_.Set("fields", googleapi.CombineFields(s))
25131	return c
25132}
25133
25134// Context sets the context to be used in this call's Do method. Any
25135// pending HTTP request will be aborted if the provided context is
25136// canceled.
25137func (c *ContentCategoriesUpdateCall) Context(ctx context.Context) *ContentCategoriesUpdateCall {
25138	c.ctx_ = ctx
25139	return c
25140}
25141
25142// Header returns an http.Header that can be modified by the caller to
25143// add HTTP headers to the request.
25144func (c *ContentCategoriesUpdateCall) Header() http.Header {
25145	if c.header_ == nil {
25146		c.header_ = make(http.Header)
25147	}
25148	return c.header_
25149}
25150
25151func (c *ContentCategoriesUpdateCall) doRequest(alt string) (*http.Response, error) {
25152	reqHeaders := make(http.Header)
25153	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
25154	for k, v := range c.header_ {
25155		reqHeaders[k] = v
25156	}
25157	reqHeaders.Set("User-Agent", c.s.userAgent())
25158	var body io.Reader = nil
25159	body, err := googleapi.WithoutDataWrapper.JSONReader(c.contentcategory)
25160	if err != nil {
25161		return nil, err
25162	}
25163	reqHeaders.Set("Content-Type", "application/json")
25164	c.urlParams_.Set("alt", alt)
25165	c.urlParams_.Set("prettyPrint", "false")
25166	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/contentCategories")
25167	urls += "?" + c.urlParams_.Encode()
25168	req, err := http.NewRequest("PUT", urls, body)
25169	if err != nil {
25170		return nil, err
25171	}
25172	req.Header = reqHeaders
25173	googleapi.Expand(req.URL, map[string]string{
25174		"profileId": strconv.FormatInt(c.profileId, 10),
25175	})
25176	return gensupport.SendRequest(c.ctx_, c.s.client, req)
25177}
25178
25179// Do executes the "dfareporting.contentCategories.update" call.
25180// Exactly one of *ContentCategory or error will be non-nil. Any non-2xx
25181// status code is an error. Response headers are in either
25182// *ContentCategory.ServerResponse.Header or (if a response was returned
25183// at all) in error.(*googleapi.Error).Header. Use
25184// googleapi.IsNotModified to check whether the returned error was
25185// because http.StatusNotModified was returned.
25186func (c *ContentCategoriesUpdateCall) Do(opts ...googleapi.CallOption) (*ContentCategory, error) {
25187	gensupport.SetOptions(c.urlParams_, opts...)
25188	res, err := c.doRequest("json")
25189	if res != nil && res.StatusCode == http.StatusNotModified {
25190		if res.Body != nil {
25191			res.Body.Close()
25192		}
25193		return nil, &googleapi.Error{
25194			Code:   res.StatusCode,
25195			Header: res.Header,
25196		}
25197	}
25198	if err != nil {
25199		return nil, err
25200	}
25201	defer googleapi.CloseBody(res)
25202	if err := googleapi.CheckResponse(res); err != nil {
25203		return nil, err
25204	}
25205	ret := &ContentCategory{
25206		ServerResponse: googleapi.ServerResponse{
25207			Header:         res.Header,
25208			HTTPStatusCode: res.StatusCode,
25209		},
25210	}
25211	target := &ret
25212	if err := gensupport.DecodeResponse(target, res); err != nil {
25213		return nil, err
25214	}
25215	return ret, nil
25216	// {
25217	//   "description": "Updates an existing content category.",
25218	//   "flatPath": "userprofiles/{profileId}/contentCategories",
25219	//   "httpMethod": "PUT",
25220	//   "id": "dfareporting.contentCategories.update",
25221	//   "parameterOrder": [
25222	//     "profileId"
25223	//   ],
25224	//   "parameters": {
25225	//     "profileId": {
25226	//       "description": "User profile ID associated with this request.",
25227	//       "format": "int64",
25228	//       "location": "path",
25229	//       "required": true,
25230	//       "type": "string"
25231	//     }
25232	//   },
25233	//   "path": "userprofiles/{profileId}/contentCategories",
25234	//   "request": {
25235	//     "$ref": "ContentCategory"
25236	//   },
25237	//   "response": {
25238	//     "$ref": "ContentCategory"
25239	//   },
25240	//   "scopes": [
25241	//     "https://www.googleapis.com/auth/dfatrafficking"
25242	//   ]
25243	// }
25244
25245}
25246
25247// method id "dfareporting.conversions.batchinsert":
25248
25249type ConversionsBatchinsertCall struct {
25250	s                             *Service
25251	profileId                     int64
25252	conversionsbatchinsertrequest *ConversionsBatchInsertRequest
25253	urlParams_                    gensupport.URLParams
25254	ctx_                          context.Context
25255	header_                       http.Header
25256}
25257
25258// Batchinsert: Inserts conversions.
25259//
25260// - profileId: User profile ID associated with this request.
25261func (r *ConversionsService) Batchinsert(profileId int64, conversionsbatchinsertrequest *ConversionsBatchInsertRequest) *ConversionsBatchinsertCall {
25262	c := &ConversionsBatchinsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
25263	c.profileId = profileId
25264	c.conversionsbatchinsertrequest = conversionsbatchinsertrequest
25265	return c
25266}
25267
25268// Fields allows partial responses to be retrieved. See
25269// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
25270// for more information.
25271func (c *ConversionsBatchinsertCall) Fields(s ...googleapi.Field) *ConversionsBatchinsertCall {
25272	c.urlParams_.Set("fields", googleapi.CombineFields(s))
25273	return c
25274}
25275
25276// Context sets the context to be used in this call's Do method. Any
25277// pending HTTP request will be aborted if the provided context is
25278// canceled.
25279func (c *ConversionsBatchinsertCall) Context(ctx context.Context) *ConversionsBatchinsertCall {
25280	c.ctx_ = ctx
25281	return c
25282}
25283
25284// Header returns an http.Header that can be modified by the caller to
25285// add HTTP headers to the request.
25286func (c *ConversionsBatchinsertCall) Header() http.Header {
25287	if c.header_ == nil {
25288		c.header_ = make(http.Header)
25289	}
25290	return c.header_
25291}
25292
25293func (c *ConversionsBatchinsertCall) doRequest(alt string) (*http.Response, error) {
25294	reqHeaders := make(http.Header)
25295	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
25296	for k, v := range c.header_ {
25297		reqHeaders[k] = v
25298	}
25299	reqHeaders.Set("User-Agent", c.s.userAgent())
25300	var body io.Reader = nil
25301	body, err := googleapi.WithoutDataWrapper.JSONReader(c.conversionsbatchinsertrequest)
25302	if err != nil {
25303		return nil, err
25304	}
25305	reqHeaders.Set("Content-Type", "application/json")
25306	c.urlParams_.Set("alt", alt)
25307	c.urlParams_.Set("prettyPrint", "false")
25308	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/conversions/batchinsert")
25309	urls += "?" + c.urlParams_.Encode()
25310	req, err := http.NewRequest("POST", urls, body)
25311	if err != nil {
25312		return nil, err
25313	}
25314	req.Header = reqHeaders
25315	googleapi.Expand(req.URL, map[string]string{
25316		"profileId": strconv.FormatInt(c.profileId, 10),
25317	})
25318	return gensupport.SendRequest(c.ctx_, c.s.client, req)
25319}
25320
25321// Do executes the "dfareporting.conversions.batchinsert" call.
25322// Exactly one of *ConversionsBatchInsertResponse or error will be
25323// non-nil. Any non-2xx status code is an error. Response headers are in
25324// either *ConversionsBatchInsertResponse.ServerResponse.Header or (if a
25325// response was returned at all) in error.(*googleapi.Error).Header. Use
25326// googleapi.IsNotModified to check whether the returned error was
25327// because http.StatusNotModified was returned.
25328func (c *ConversionsBatchinsertCall) Do(opts ...googleapi.CallOption) (*ConversionsBatchInsertResponse, error) {
25329	gensupport.SetOptions(c.urlParams_, opts...)
25330	res, err := c.doRequest("json")
25331	if res != nil && res.StatusCode == http.StatusNotModified {
25332		if res.Body != nil {
25333			res.Body.Close()
25334		}
25335		return nil, &googleapi.Error{
25336			Code:   res.StatusCode,
25337			Header: res.Header,
25338		}
25339	}
25340	if err != nil {
25341		return nil, err
25342	}
25343	defer googleapi.CloseBody(res)
25344	if err := googleapi.CheckResponse(res); err != nil {
25345		return nil, err
25346	}
25347	ret := &ConversionsBatchInsertResponse{
25348		ServerResponse: googleapi.ServerResponse{
25349			Header:         res.Header,
25350			HTTPStatusCode: res.StatusCode,
25351		},
25352	}
25353	target := &ret
25354	if err := gensupport.DecodeResponse(target, res); err != nil {
25355		return nil, err
25356	}
25357	return ret, nil
25358	// {
25359	//   "description": "Inserts conversions.",
25360	//   "flatPath": "userprofiles/{profileId}/conversions/batchinsert",
25361	//   "httpMethod": "POST",
25362	//   "id": "dfareporting.conversions.batchinsert",
25363	//   "parameterOrder": [
25364	//     "profileId"
25365	//   ],
25366	//   "parameters": {
25367	//     "profileId": {
25368	//       "description": "User profile ID associated with this request.",
25369	//       "format": "int64",
25370	//       "location": "path",
25371	//       "required": true,
25372	//       "type": "string"
25373	//     }
25374	//   },
25375	//   "path": "userprofiles/{profileId}/conversions/batchinsert",
25376	//   "request": {
25377	//     "$ref": "ConversionsBatchInsertRequest"
25378	//   },
25379	//   "response": {
25380	//     "$ref": "ConversionsBatchInsertResponse"
25381	//   },
25382	//   "scopes": [
25383	//     "https://www.googleapis.com/auth/ddmconversions"
25384	//   ]
25385	// }
25386
25387}
25388
25389// method id "dfareporting.conversions.batchupdate":
25390
25391type ConversionsBatchupdateCall struct {
25392	s                             *Service
25393	profileId                     int64
25394	conversionsbatchupdaterequest *ConversionsBatchUpdateRequest
25395	urlParams_                    gensupport.URLParams
25396	ctx_                          context.Context
25397	header_                       http.Header
25398}
25399
25400// Batchupdate: Updates existing conversions.
25401//
25402// - profileId: User profile ID associated with this request.
25403func (r *ConversionsService) Batchupdate(profileId int64, conversionsbatchupdaterequest *ConversionsBatchUpdateRequest) *ConversionsBatchupdateCall {
25404	c := &ConversionsBatchupdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
25405	c.profileId = profileId
25406	c.conversionsbatchupdaterequest = conversionsbatchupdaterequest
25407	return c
25408}
25409
25410// Fields allows partial responses to be retrieved. See
25411// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
25412// for more information.
25413func (c *ConversionsBatchupdateCall) Fields(s ...googleapi.Field) *ConversionsBatchupdateCall {
25414	c.urlParams_.Set("fields", googleapi.CombineFields(s))
25415	return c
25416}
25417
25418// Context sets the context to be used in this call's Do method. Any
25419// pending HTTP request will be aborted if the provided context is
25420// canceled.
25421func (c *ConversionsBatchupdateCall) Context(ctx context.Context) *ConversionsBatchupdateCall {
25422	c.ctx_ = ctx
25423	return c
25424}
25425
25426// Header returns an http.Header that can be modified by the caller to
25427// add HTTP headers to the request.
25428func (c *ConversionsBatchupdateCall) Header() http.Header {
25429	if c.header_ == nil {
25430		c.header_ = make(http.Header)
25431	}
25432	return c.header_
25433}
25434
25435func (c *ConversionsBatchupdateCall) doRequest(alt string) (*http.Response, error) {
25436	reqHeaders := make(http.Header)
25437	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
25438	for k, v := range c.header_ {
25439		reqHeaders[k] = v
25440	}
25441	reqHeaders.Set("User-Agent", c.s.userAgent())
25442	var body io.Reader = nil
25443	body, err := googleapi.WithoutDataWrapper.JSONReader(c.conversionsbatchupdaterequest)
25444	if err != nil {
25445		return nil, err
25446	}
25447	reqHeaders.Set("Content-Type", "application/json")
25448	c.urlParams_.Set("alt", alt)
25449	c.urlParams_.Set("prettyPrint", "false")
25450	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/conversions/batchupdate")
25451	urls += "?" + c.urlParams_.Encode()
25452	req, err := http.NewRequest("POST", urls, body)
25453	if err != nil {
25454		return nil, err
25455	}
25456	req.Header = reqHeaders
25457	googleapi.Expand(req.URL, map[string]string{
25458		"profileId": strconv.FormatInt(c.profileId, 10),
25459	})
25460	return gensupport.SendRequest(c.ctx_, c.s.client, req)
25461}
25462
25463// Do executes the "dfareporting.conversions.batchupdate" call.
25464// Exactly one of *ConversionsBatchUpdateResponse or error will be
25465// non-nil. Any non-2xx status code is an error. Response headers are in
25466// either *ConversionsBatchUpdateResponse.ServerResponse.Header or (if a
25467// response was returned at all) in error.(*googleapi.Error).Header. Use
25468// googleapi.IsNotModified to check whether the returned error was
25469// because http.StatusNotModified was returned.
25470func (c *ConversionsBatchupdateCall) Do(opts ...googleapi.CallOption) (*ConversionsBatchUpdateResponse, error) {
25471	gensupport.SetOptions(c.urlParams_, opts...)
25472	res, err := c.doRequest("json")
25473	if res != nil && res.StatusCode == http.StatusNotModified {
25474		if res.Body != nil {
25475			res.Body.Close()
25476		}
25477		return nil, &googleapi.Error{
25478			Code:   res.StatusCode,
25479			Header: res.Header,
25480		}
25481	}
25482	if err != nil {
25483		return nil, err
25484	}
25485	defer googleapi.CloseBody(res)
25486	if err := googleapi.CheckResponse(res); err != nil {
25487		return nil, err
25488	}
25489	ret := &ConversionsBatchUpdateResponse{
25490		ServerResponse: googleapi.ServerResponse{
25491			Header:         res.Header,
25492			HTTPStatusCode: res.StatusCode,
25493		},
25494	}
25495	target := &ret
25496	if err := gensupport.DecodeResponse(target, res); err != nil {
25497		return nil, err
25498	}
25499	return ret, nil
25500	// {
25501	//   "description": "Updates existing conversions.",
25502	//   "flatPath": "userprofiles/{profileId}/conversions/batchupdate",
25503	//   "httpMethod": "POST",
25504	//   "id": "dfareporting.conversions.batchupdate",
25505	//   "parameterOrder": [
25506	//     "profileId"
25507	//   ],
25508	//   "parameters": {
25509	//     "profileId": {
25510	//       "description": "User profile ID associated with this request.",
25511	//       "format": "int64",
25512	//       "location": "path",
25513	//       "required": true,
25514	//       "type": "string"
25515	//     }
25516	//   },
25517	//   "path": "userprofiles/{profileId}/conversions/batchupdate",
25518	//   "request": {
25519	//     "$ref": "ConversionsBatchUpdateRequest"
25520	//   },
25521	//   "response": {
25522	//     "$ref": "ConversionsBatchUpdateResponse"
25523	//   },
25524	//   "scopes": [
25525	//     "https://www.googleapis.com/auth/ddmconversions"
25526	//   ]
25527	// }
25528
25529}
25530
25531// method id "dfareporting.countries.get":
25532
25533type CountriesGetCall struct {
25534	s            *Service
25535	profileId    int64
25536	dartId       int64
25537	urlParams_   gensupport.URLParams
25538	ifNoneMatch_ string
25539	ctx_         context.Context
25540	header_      http.Header
25541}
25542
25543// Get: Gets one country by ID.
25544//
25545// - dartId: Country DART ID.
25546// - profileId: User profile ID associated with this request.
25547func (r *CountriesService) Get(profileId int64, dartId int64) *CountriesGetCall {
25548	c := &CountriesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
25549	c.profileId = profileId
25550	c.dartId = dartId
25551	return c
25552}
25553
25554// Fields allows partial responses to be retrieved. See
25555// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
25556// for more information.
25557func (c *CountriesGetCall) Fields(s ...googleapi.Field) *CountriesGetCall {
25558	c.urlParams_.Set("fields", googleapi.CombineFields(s))
25559	return c
25560}
25561
25562// IfNoneMatch sets the optional parameter which makes the operation
25563// fail if the object's ETag matches the given value. This is useful for
25564// getting updates only after the object has changed since the last
25565// request. Use googleapi.IsNotModified to check whether the response
25566// error from Do is the result of In-None-Match.
25567func (c *CountriesGetCall) IfNoneMatch(entityTag string) *CountriesGetCall {
25568	c.ifNoneMatch_ = entityTag
25569	return c
25570}
25571
25572// Context sets the context to be used in this call's Do method. Any
25573// pending HTTP request will be aborted if the provided context is
25574// canceled.
25575func (c *CountriesGetCall) Context(ctx context.Context) *CountriesGetCall {
25576	c.ctx_ = ctx
25577	return c
25578}
25579
25580// Header returns an http.Header that can be modified by the caller to
25581// add HTTP headers to the request.
25582func (c *CountriesGetCall) Header() http.Header {
25583	if c.header_ == nil {
25584		c.header_ = make(http.Header)
25585	}
25586	return c.header_
25587}
25588
25589func (c *CountriesGetCall) doRequest(alt string) (*http.Response, error) {
25590	reqHeaders := make(http.Header)
25591	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
25592	for k, v := range c.header_ {
25593		reqHeaders[k] = v
25594	}
25595	reqHeaders.Set("User-Agent", c.s.userAgent())
25596	if c.ifNoneMatch_ != "" {
25597		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
25598	}
25599	var body io.Reader = nil
25600	c.urlParams_.Set("alt", alt)
25601	c.urlParams_.Set("prettyPrint", "false")
25602	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/countries/{dartId}")
25603	urls += "?" + c.urlParams_.Encode()
25604	req, err := http.NewRequest("GET", urls, body)
25605	if err != nil {
25606		return nil, err
25607	}
25608	req.Header = reqHeaders
25609	googleapi.Expand(req.URL, map[string]string{
25610		"profileId": strconv.FormatInt(c.profileId, 10),
25611		"dartId":    strconv.FormatInt(c.dartId, 10),
25612	})
25613	return gensupport.SendRequest(c.ctx_, c.s.client, req)
25614}
25615
25616// Do executes the "dfareporting.countries.get" call.
25617// Exactly one of *Country or error will be non-nil. Any non-2xx status
25618// code is an error. Response headers are in either
25619// *Country.ServerResponse.Header or (if a response was returned at all)
25620// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to
25621// check whether the returned error was because http.StatusNotModified
25622// was returned.
25623func (c *CountriesGetCall) Do(opts ...googleapi.CallOption) (*Country, error) {
25624	gensupport.SetOptions(c.urlParams_, opts...)
25625	res, err := c.doRequest("json")
25626	if res != nil && res.StatusCode == http.StatusNotModified {
25627		if res.Body != nil {
25628			res.Body.Close()
25629		}
25630		return nil, &googleapi.Error{
25631			Code:   res.StatusCode,
25632			Header: res.Header,
25633		}
25634	}
25635	if err != nil {
25636		return nil, err
25637	}
25638	defer googleapi.CloseBody(res)
25639	if err := googleapi.CheckResponse(res); err != nil {
25640		return nil, err
25641	}
25642	ret := &Country{
25643		ServerResponse: googleapi.ServerResponse{
25644			Header:         res.Header,
25645			HTTPStatusCode: res.StatusCode,
25646		},
25647	}
25648	target := &ret
25649	if err := gensupport.DecodeResponse(target, res); err != nil {
25650		return nil, err
25651	}
25652	return ret, nil
25653	// {
25654	//   "description": "Gets one country by ID.",
25655	//   "flatPath": "userprofiles/{profileId}/countries/{dartId}",
25656	//   "httpMethod": "GET",
25657	//   "id": "dfareporting.countries.get",
25658	//   "parameterOrder": [
25659	//     "profileId",
25660	//     "dartId"
25661	//   ],
25662	//   "parameters": {
25663	//     "dartId": {
25664	//       "description": "Country DART ID.",
25665	//       "format": "int64",
25666	//       "location": "path",
25667	//       "required": true,
25668	//       "type": "string"
25669	//     },
25670	//     "profileId": {
25671	//       "description": "User profile ID associated with this request.",
25672	//       "format": "int64",
25673	//       "location": "path",
25674	//       "required": true,
25675	//       "type": "string"
25676	//     }
25677	//   },
25678	//   "path": "userprofiles/{profileId}/countries/{dartId}",
25679	//   "response": {
25680	//     "$ref": "Country"
25681	//   },
25682	//   "scopes": [
25683	//     "https://www.googleapis.com/auth/dfatrafficking"
25684	//   ]
25685	// }
25686
25687}
25688
25689// method id "dfareporting.countries.list":
25690
25691type CountriesListCall struct {
25692	s            *Service
25693	profileId    int64
25694	urlParams_   gensupport.URLParams
25695	ifNoneMatch_ string
25696	ctx_         context.Context
25697	header_      http.Header
25698}
25699
25700// List: Retrieves a list of countries.
25701//
25702// - profileId: User profile ID associated with this request.
25703func (r *CountriesService) List(profileId int64) *CountriesListCall {
25704	c := &CountriesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
25705	c.profileId = profileId
25706	return c
25707}
25708
25709// Fields allows partial responses to be retrieved. See
25710// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
25711// for more information.
25712func (c *CountriesListCall) Fields(s ...googleapi.Field) *CountriesListCall {
25713	c.urlParams_.Set("fields", googleapi.CombineFields(s))
25714	return c
25715}
25716
25717// IfNoneMatch sets the optional parameter which makes the operation
25718// fail if the object's ETag matches the given value. This is useful for
25719// getting updates only after the object has changed since the last
25720// request. Use googleapi.IsNotModified to check whether the response
25721// error from Do is the result of In-None-Match.
25722func (c *CountriesListCall) IfNoneMatch(entityTag string) *CountriesListCall {
25723	c.ifNoneMatch_ = entityTag
25724	return c
25725}
25726
25727// Context sets the context to be used in this call's Do method. Any
25728// pending HTTP request will be aborted if the provided context is
25729// canceled.
25730func (c *CountriesListCall) Context(ctx context.Context) *CountriesListCall {
25731	c.ctx_ = ctx
25732	return c
25733}
25734
25735// Header returns an http.Header that can be modified by the caller to
25736// add HTTP headers to the request.
25737func (c *CountriesListCall) Header() http.Header {
25738	if c.header_ == nil {
25739		c.header_ = make(http.Header)
25740	}
25741	return c.header_
25742}
25743
25744func (c *CountriesListCall) doRequest(alt string) (*http.Response, error) {
25745	reqHeaders := make(http.Header)
25746	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
25747	for k, v := range c.header_ {
25748		reqHeaders[k] = v
25749	}
25750	reqHeaders.Set("User-Agent", c.s.userAgent())
25751	if c.ifNoneMatch_ != "" {
25752		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
25753	}
25754	var body io.Reader = nil
25755	c.urlParams_.Set("alt", alt)
25756	c.urlParams_.Set("prettyPrint", "false")
25757	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/countries")
25758	urls += "?" + c.urlParams_.Encode()
25759	req, err := http.NewRequest("GET", urls, body)
25760	if err != nil {
25761		return nil, err
25762	}
25763	req.Header = reqHeaders
25764	googleapi.Expand(req.URL, map[string]string{
25765		"profileId": strconv.FormatInt(c.profileId, 10),
25766	})
25767	return gensupport.SendRequest(c.ctx_, c.s.client, req)
25768}
25769
25770// Do executes the "dfareporting.countries.list" call.
25771// Exactly one of *CountriesListResponse or error will be non-nil. Any
25772// non-2xx status code is an error. Response headers are in either
25773// *CountriesListResponse.ServerResponse.Header or (if a response was
25774// returned at all) in error.(*googleapi.Error).Header. Use
25775// googleapi.IsNotModified to check whether the returned error was
25776// because http.StatusNotModified was returned.
25777func (c *CountriesListCall) Do(opts ...googleapi.CallOption) (*CountriesListResponse, error) {
25778	gensupport.SetOptions(c.urlParams_, opts...)
25779	res, err := c.doRequest("json")
25780	if res != nil && res.StatusCode == http.StatusNotModified {
25781		if res.Body != nil {
25782			res.Body.Close()
25783		}
25784		return nil, &googleapi.Error{
25785			Code:   res.StatusCode,
25786			Header: res.Header,
25787		}
25788	}
25789	if err != nil {
25790		return nil, err
25791	}
25792	defer googleapi.CloseBody(res)
25793	if err := googleapi.CheckResponse(res); err != nil {
25794		return nil, err
25795	}
25796	ret := &CountriesListResponse{
25797		ServerResponse: googleapi.ServerResponse{
25798			Header:         res.Header,
25799			HTTPStatusCode: res.StatusCode,
25800		},
25801	}
25802	target := &ret
25803	if err := gensupport.DecodeResponse(target, res); err != nil {
25804		return nil, err
25805	}
25806	return ret, nil
25807	// {
25808	//   "description": "Retrieves a list of countries.",
25809	//   "flatPath": "userprofiles/{profileId}/countries",
25810	//   "httpMethod": "GET",
25811	//   "id": "dfareporting.countries.list",
25812	//   "parameterOrder": [
25813	//     "profileId"
25814	//   ],
25815	//   "parameters": {
25816	//     "profileId": {
25817	//       "description": "User profile ID associated with this request.",
25818	//       "format": "int64",
25819	//       "location": "path",
25820	//       "required": true,
25821	//       "type": "string"
25822	//     }
25823	//   },
25824	//   "path": "userprofiles/{profileId}/countries",
25825	//   "response": {
25826	//     "$ref": "CountriesListResponse"
25827	//   },
25828	//   "scopes": [
25829	//     "https://www.googleapis.com/auth/dfatrafficking"
25830	//   ]
25831	// }
25832
25833}
25834
25835// method id "dfareporting.creativeAssets.insert":
25836
25837type CreativeAssetsInsertCall struct {
25838	s                     *Service
25839	profileId             int64
25840	advertiserId          int64
25841	creativeassetmetadata *CreativeAssetMetadata
25842	urlParams_            gensupport.URLParams
25843	mediaInfo_            *gensupport.MediaInfo
25844	ctx_                  context.Context
25845	header_               http.Header
25846}
25847
25848// Insert: Inserts a new creative asset.
25849//
25850// - advertiserId: Advertiser ID of this creative. This is a required
25851//   field.
25852// - profileId: User profile ID associated with this request.
25853func (r *CreativeAssetsService) Insert(profileId int64, advertiserId int64, creativeassetmetadata *CreativeAssetMetadata) *CreativeAssetsInsertCall {
25854	c := &CreativeAssetsInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
25855	c.profileId = profileId
25856	c.advertiserId = advertiserId
25857	c.creativeassetmetadata = creativeassetmetadata
25858	return c
25859}
25860
25861// Media specifies the media to upload in one or more chunks. The chunk
25862// size may be controlled by supplying a MediaOption generated by
25863// googleapi.ChunkSize. The chunk size defaults to
25864// googleapi.DefaultUploadChunkSize.The Content-Type header used in the
25865// upload request will be determined by sniffing the contents of r,
25866// unless a MediaOption generated by googleapi.ContentType is
25867// supplied.
25868// At most one of Media and ResumableMedia may be set.
25869func (c *CreativeAssetsInsertCall) Media(r io.Reader, options ...googleapi.MediaOption) *CreativeAssetsInsertCall {
25870	c.mediaInfo_ = gensupport.NewInfoFromMedia(r, options)
25871	return c
25872}
25873
25874// ResumableMedia specifies the media to upload in chunks and can be
25875// canceled with ctx.
25876//
25877// Deprecated: use Media instead.
25878//
25879// At most one of Media and ResumableMedia may be set. mediaType
25880// identifies the MIME media type of the upload, such as "image/png". If
25881// mediaType is "", it will be auto-detected. The provided ctx will
25882// supersede any context previously provided to the Context method.
25883func (c *CreativeAssetsInsertCall) ResumableMedia(ctx context.Context, r io.ReaderAt, size int64, mediaType string) *CreativeAssetsInsertCall {
25884	c.ctx_ = ctx
25885	c.mediaInfo_ = gensupport.NewInfoFromResumableMedia(r, size, mediaType)
25886	return c
25887}
25888
25889// ProgressUpdater provides a callback function that will be called
25890// after every chunk. It should be a low-latency function in order to
25891// not slow down the upload operation. This should only be called when
25892// using ResumableMedia (as opposed to Media).
25893func (c *CreativeAssetsInsertCall) ProgressUpdater(pu googleapi.ProgressUpdater) *CreativeAssetsInsertCall {
25894	c.mediaInfo_.SetProgressUpdater(pu)
25895	return c
25896}
25897
25898// Fields allows partial responses to be retrieved. See
25899// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
25900// for more information.
25901func (c *CreativeAssetsInsertCall) Fields(s ...googleapi.Field) *CreativeAssetsInsertCall {
25902	c.urlParams_.Set("fields", googleapi.CombineFields(s))
25903	return c
25904}
25905
25906// Context sets the context to be used in this call's Do method. Any
25907// pending HTTP request will be aborted if the provided context is
25908// canceled.
25909// This context will supersede any context previously provided to the
25910// ResumableMedia method.
25911func (c *CreativeAssetsInsertCall) Context(ctx context.Context) *CreativeAssetsInsertCall {
25912	c.ctx_ = ctx
25913	return c
25914}
25915
25916// Header returns an http.Header that can be modified by the caller to
25917// add HTTP headers to the request.
25918func (c *CreativeAssetsInsertCall) Header() http.Header {
25919	if c.header_ == nil {
25920		c.header_ = make(http.Header)
25921	}
25922	return c.header_
25923}
25924
25925func (c *CreativeAssetsInsertCall) doRequest(alt string) (*http.Response, error) {
25926	reqHeaders := make(http.Header)
25927	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
25928	for k, v := range c.header_ {
25929		reqHeaders[k] = v
25930	}
25931	reqHeaders.Set("User-Agent", c.s.userAgent())
25932	var body io.Reader = nil
25933	body, err := googleapi.WithoutDataWrapper.JSONReader(c.creativeassetmetadata)
25934	if err != nil {
25935		return nil, err
25936	}
25937	reqHeaders.Set("Content-Type", "application/json")
25938	c.urlParams_.Set("alt", alt)
25939	c.urlParams_.Set("prettyPrint", "false")
25940	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeAssets/{advertiserId}/creativeAssets")
25941	if c.mediaInfo_ != nil {
25942		urls = googleapi.ResolveRelative(c.s.BasePath, "/upload/dfareporting/v3.4/userprofiles/{profileId}/creativeAssets/{advertiserId}/creativeAssets")
25943		c.urlParams_.Set("uploadType", c.mediaInfo_.UploadType())
25944	}
25945	if body == nil {
25946		body = new(bytes.Buffer)
25947		reqHeaders.Set("Content-Type", "application/json")
25948	}
25949	body, getBody, cleanup := c.mediaInfo_.UploadRequest(reqHeaders, body)
25950	defer cleanup()
25951	urls += "?" + c.urlParams_.Encode()
25952	req, err := http.NewRequest("POST", urls, body)
25953	if err != nil {
25954		return nil, err
25955	}
25956	req.Header = reqHeaders
25957	req.GetBody = getBody
25958	googleapi.Expand(req.URL, map[string]string{
25959		"profileId":    strconv.FormatInt(c.profileId, 10),
25960		"advertiserId": strconv.FormatInt(c.advertiserId, 10),
25961	})
25962	return gensupport.SendRequest(c.ctx_, c.s.client, req)
25963}
25964
25965// Do executes the "dfareporting.creativeAssets.insert" call.
25966// Exactly one of *CreativeAssetMetadata or error will be non-nil. Any
25967// non-2xx status code is an error. Response headers are in either
25968// *CreativeAssetMetadata.ServerResponse.Header or (if a response was
25969// returned at all) in error.(*googleapi.Error).Header. Use
25970// googleapi.IsNotModified to check whether the returned error was
25971// because http.StatusNotModified was returned.
25972func (c *CreativeAssetsInsertCall) Do(opts ...googleapi.CallOption) (*CreativeAssetMetadata, error) {
25973	gensupport.SetOptions(c.urlParams_, opts...)
25974	res, err := c.doRequest("json")
25975	if res != nil && res.StatusCode == http.StatusNotModified {
25976		if res.Body != nil {
25977			res.Body.Close()
25978		}
25979		return nil, &googleapi.Error{
25980			Code:   res.StatusCode,
25981			Header: res.Header,
25982		}
25983	}
25984	if err != nil {
25985		return nil, err
25986	}
25987	defer googleapi.CloseBody(res)
25988	if err := googleapi.CheckResponse(res); err != nil {
25989		return nil, err
25990	}
25991	rx := c.mediaInfo_.ResumableUpload(res.Header.Get("Location"))
25992	if rx != nil {
25993		rx.Client = c.s.client
25994		rx.UserAgent = c.s.userAgent()
25995		ctx := c.ctx_
25996		if ctx == nil {
25997			ctx = context.TODO()
25998		}
25999		res, err = rx.Upload(ctx)
26000		if err != nil {
26001			return nil, err
26002		}
26003		defer res.Body.Close()
26004		if err := googleapi.CheckResponse(res); err != nil {
26005			return nil, err
26006		}
26007	}
26008	ret := &CreativeAssetMetadata{
26009		ServerResponse: googleapi.ServerResponse{
26010			Header:         res.Header,
26011			HTTPStatusCode: res.StatusCode,
26012		},
26013	}
26014	target := &ret
26015	if err := gensupport.DecodeResponse(target, res); err != nil {
26016		return nil, err
26017	}
26018	return ret, nil
26019	// {
26020	//   "description": "Inserts a new creative asset.",
26021	//   "flatPath": "userprofiles/{profileId}/creativeAssets/{advertiserId}/creativeAssets",
26022	//   "httpMethod": "POST",
26023	//   "id": "dfareporting.creativeAssets.insert",
26024	//   "mediaUpload": {
26025	//     "accept": [
26026	//       "*/*"
26027	//     ],
26028	//     "maxSize": "1073741824",
26029	//     "protocols": {
26030	//       "simple": {
26031	//         "multipart": true,
26032	//         "path": "/upload/dfareporting/v3.4/userprofiles/{profileId}/creativeAssets/{advertiserId}/creativeAssets"
26033	//       }
26034	//     }
26035	//   },
26036	//   "parameterOrder": [
26037	//     "profileId",
26038	//     "advertiserId"
26039	//   ],
26040	//   "parameters": {
26041	//     "advertiserId": {
26042	//       "description": "Advertiser ID of this creative. This is a required field.",
26043	//       "format": "int64",
26044	//       "location": "path",
26045	//       "required": true,
26046	//       "type": "string"
26047	//     },
26048	//     "profileId": {
26049	//       "description": "User profile ID associated with this request.",
26050	//       "format": "int64",
26051	//       "location": "path",
26052	//       "required": true,
26053	//       "type": "string"
26054	//     }
26055	//   },
26056	//   "path": "userprofiles/{profileId}/creativeAssets/{advertiserId}/creativeAssets",
26057	//   "request": {
26058	//     "$ref": "CreativeAssetMetadata"
26059	//   },
26060	//   "response": {
26061	//     "$ref": "CreativeAssetMetadata"
26062	//   },
26063	//   "scopes": [
26064	//     "https://www.googleapis.com/auth/dfatrafficking"
26065	//   ],
26066	//   "supportsMediaUpload": true
26067	// }
26068
26069}
26070
26071// method id "dfareporting.creativeFieldValues.delete":
26072
26073type CreativeFieldValuesDeleteCall struct {
26074	s               *Service
26075	profileId       int64
26076	creativeFieldId int64
26077	id              int64
26078	urlParams_      gensupport.URLParams
26079	ctx_            context.Context
26080	header_         http.Header
26081}
26082
26083// Delete: Deletes an existing creative field value.
26084//
26085// - creativeFieldId: Creative field ID for this creative field value.
26086// - id: Creative Field Value ID.
26087// - profileId: User profile ID associated with this request.
26088func (r *CreativeFieldValuesService) Delete(profileId int64, creativeFieldId int64, id int64) *CreativeFieldValuesDeleteCall {
26089	c := &CreativeFieldValuesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
26090	c.profileId = profileId
26091	c.creativeFieldId = creativeFieldId
26092	c.id = id
26093	return c
26094}
26095
26096// Fields allows partial responses to be retrieved. See
26097// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
26098// for more information.
26099func (c *CreativeFieldValuesDeleteCall) Fields(s ...googleapi.Field) *CreativeFieldValuesDeleteCall {
26100	c.urlParams_.Set("fields", googleapi.CombineFields(s))
26101	return c
26102}
26103
26104// Context sets the context to be used in this call's Do method. Any
26105// pending HTTP request will be aborted if the provided context is
26106// canceled.
26107func (c *CreativeFieldValuesDeleteCall) Context(ctx context.Context) *CreativeFieldValuesDeleteCall {
26108	c.ctx_ = ctx
26109	return c
26110}
26111
26112// Header returns an http.Header that can be modified by the caller to
26113// add HTTP headers to the request.
26114func (c *CreativeFieldValuesDeleteCall) Header() http.Header {
26115	if c.header_ == nil {
26116		c.header_ = make(http.Header)
26117	}
26118	return c.header_
26119}
26120
26121func (c *CreativeFieldValuesDeleteCall) doRequest(alt string) (*http.Response, error) {
26122	reqHeaders := make(http.Header)
26123	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
26124	for k, v := range c.header_ {
26125		reqHeaders[k] = v
26126	}
26127	reqHeaders.Set("User-Agent", c.s.userAgent())
26128	var body io.Reader = nil
26129	c.urlParams_.Set("alt", alt)
26130	c.urlParams_.Set("prettyPrint", "false")
26131	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeFields/{creativeFieldId}/creativeFieldValues/{id}")
26132	urls += "?" + c.urlParams_.Encode()
26133	req, err := http.NewRequest("DELETE", urls, body)
26134	if err != nil {
26135		return nil, err
26136	}
26137	req.Header = reqHeaders
26138	googleapi.Expand(req.URL, map[string]string{
26139		"profileId":       strconv.FormatInt(c.profileId, 10),
26140		"creativeFieldId": strconv.FormatInt(c.creativeFieldId, 10),
26141		"id":              strconv.FormatInt(c.id, 10),
26142	})
26143	return gensupport.SendRequest(c.ctx_, c.s.client, req)
26144}
26145
26146// Do executes the "dfareporting.creativeFieldValues.delete" call.
26147func (c *CreativeFieldValuesDeleteCall) Do(opts ...googleapi.CallOption) error {
26148	gensupport.SetOptions(c.urlParams_, opts...)
26149	res, err := c.doRequest("json")
26150	if err != nil {
26151		return err
26152	}
26153	defer googleapi.CloseBody(res)
26154	if err := googleapi.CheckResponse(res); err != nil {
26155		return err
26156	}
26157	return nil
26158	// {
26159	//   "description": "Deletes an existing creative field value.",
26160	//   "flatPath": "userprofiles/{profileId}/creativeFields/{creativeFieldId}/creativeFieldValues/{id}",
26161	//   "httpMethod": "DELETE",
26162	//   "id": "dfareporting.creativeFieldValues.delete",
26163	//   "parameterOrder": [
26164	//     "profileId",
26165	//     "creativeFieldId",
26166	//     "id"
26167	//   ],
26168	//   "parameters": {
26169	//     "creativeFieldId": {
26170	//       "description": "Creative field ID for this creative field value.",
26171	//       "format": "int64",
26172	//       "location": "path",
26173	//       "required": true,
26174	//       "type": "string"
26175	//     },
26176	//     "id": {
26177	//       "description": "Creative Field Value ID",
26178	//       "format": "int64",
26179	//       "location": "path",
26180	//       "required": true,
26181	//       "type": "string"
26182	//     },
26183	//     "profileId": {
26184	//       "description": "User profile ID associated with this request.",
26185	//       "format": "int64",
26186	//       "location": "path",
26187	//       "required": true,
26188	//       "type": "string"
26189	//     }
26190	//   },
26191	//   "path": "userprofiles/{profileId}/creativeFields/{creativeFieldId}/creativeFieldValues/{id}",
26192	//   "scopes": [
26193	//     "https://www.googleapis.com/auth/dfatrafficking"
26194	//   ]
26195	// }
26196
26197}
26198
26199// method id "dfareporting.creativeFieldValues.get":
26200
26201type CreativeFieldValuesGetCall struct {
26202	s               *Service
26203	profileId       int64
26204	creativeFieldId int64
26205	id              int64
26206	urlParams_      gensupport.URLParams
26207	ifNoneMatch_    string
26208	ctx_            context.Context
26209	header_         http.Header
26210}
26211
26212// Get: Gets one creative field value by ID.
26213//
26214// - creativeFieldId: Creative field ID for this creative field value.
26215// - id: Creative Field Value ID.
26216// - profileId: User profile ID associated with this request.
26217func (r *CreativeFieldValuesService) Get(profileId int64, creativeFieldId int64, id int64) *CreativeFieldValuesGetCall {
26218	c := &CreativeFieldValuesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
26219	c.profileId = profileId
26220	c.creativeFieldId = creativeFieldId
26221	c.id = id
26222	return c
26223}
26224
26225// Fields allows partial responses to be retrieved. See
26226// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
26227// for more information.
26228func (c *CreativeFieldValuesGetCall) Fields(s ...googleapi.Field) *CreativeFieldValuesGetCall {
26229	c.urlParams_.Set("fields", googleapi.CombineFields(s))
26230	return c
26231}
26232
26233// IfNoneMatch sets the optional parameter which makes the operation
26234// fail if the object's ETag matches the given value. This is useful for
26235// getting updates only after the object has changed since the last
26236// request. Use googleapi.IsNotModified to check whether the response
26237// error from Do is the result of In-None-Match.
26238func (c *CreativeFieldValuesGetCall) IfNoneMatch(entityTag string) *CreativeFieldValuesGetCall {
26239	c.ifNoneMatch_ = entityTag
26240	return c
26241}
26242
26243// Context sets the context to be used in this call's Do method. Any
26244// pending HTTP request will be aborted if the provided context is
26245// canceled.
26246func (c *CreativeFieldValuesGetCall) Context(ctx context.Context) *CreativeFieldValuesGetCall {
26247	c.ctx_ = ctx
26248	return c
26249}
26250
26251// Header returns an http.Header that can be modified by the caller to
26252// add HTTP headers to the request.
26253func (c *CreativeFieldValuesGetCall) Header() http.Header {
26254	if c.header_ == nil {
26255		c.header_ = make(http.Header)
26256	}
26257	return c.header_
26258}
26259
26260func (c *CreativeFieldValuesGetCall) doRequest(alt string) (*http.Response, error) {
26261	reqHeaders := make(http.Header)
26262	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
26263	for k, v := range c.header_ {
26264		reqHeaders[k] = v
26265	}
26266	reqHeaders.Set("User-Agent", c.s.userAgent())
26267	if c.ifNoneMatch_ != "" {
26268		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
26269	}
26270	var body io.Reader = nil
26271	c.urlParams_.Set("alt", alt)
26272	c.urlParams_.Set("prettyPrint", "false")
26273	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeFields/{creativeFieldId}/creativeFieldValues/{id}")
26274	urls += "?" + c.urlParams_.Encode()
26275	req, err := http.NewRequest("GET", urls, body)
26276	if err != nil {
26277		return nil, err
26278	}
26279	req.Header = reqHeaders
26280	googleapi.Expand(req.URL, map[string]string{
26281		"profileId":       strconv.FormatInt(c.profileId, 10),
26282		"creativeFieldId": strconv.FormatInt(c.creativeFieldId, 10),
26283		"id":              strconv.FormatInt(c.id, 10),
26284	})
26285	return gensupport.SendRequest(c.ctx_, c.s.client, req)
26286}
26287
26288// Do executes the "dfareporting.creativeFieldValues.get" call.
26289// Exactly one of *CreativeFieldValue or error will be non-nil. Any
26290// non-2xx status code is an error. Response headers are in either
26291// *CreativeFieldValue.ServerResponse.Header or (if a response was
26292// returned at all) in error.(*googleapi.Error).Header. Use
26293// googleapi.IsNotModified to check whether the returned error was
26294// because http.StatusNotModified was returned.
26295func (c *CreativeFieldValuesGetCall) Do(opts ...googleapi.CallOption) (*CreativeFieldValue, error) {
26296	gensupport.SetOptions(c.urlParams_, opts...)
26297	res, err := c.doRequest("json")
26298	if res != nil && res.StatusCode == http.StatusNotModified {
26299		if res.Body != nil {
26300			res.Body.Close()
26301		}
26302		return nil, &googleapi.Error{
26303			Code:   res.StatusCode,
26304			Header: res.Header,
26305		}
26306	}
26307	if err != nil {
26308		return nil, err
26309	}
26310	defer googleapi.CloseBody(res)
26311	if err := googleapi.CheckResponse(res); err != nil {
26312		return nil, err
26313	}
26314	ret := &CreativeFieldValue{
26315		ServerResponse: googleapi.ServerResponse{
26316			Header:         res.Header,
26317			HTTPStatusCode: res.StatusCode,
26318		},
26319	}
26320	target := &ret
26321	if err := gensupport.DecodeResponse(target, res); err != nil {
26322		return nil, err
26323	}
26324	return ret, nil
26325	// {
26326	//   "description": "Gets one creative field value by ID.",
26327	//   "flatPath": "userprofiles/{profileId}/creativeFields/{creativeFieldId}/creativeFieldValues/{id}",
26328	//   "httpMethod": "GET",
26329	//   "id": "dfareporting.creativeFieldValues.get",
26330	//   "parameterOrder": [
26331	//     "profileId",
26332	//     "creativeFieldId",
26333	//     "id"
26334	//   ],
26335	//   "parameters": {
26336	//     "creativeFieldId": {
26337	//       "description": "Creative field ID for this creative field value.",
26338	//       "format": "int64",
26339	//       "location": "path",
26340	//       "required": true,
26341	//       "type": "string"
26342	//     },
26343	//     "id": {
26344	//       "description": "Creative Field Value ID",
26345	//       "format": "int64",
26346	//       "location": "path",
26347	//       "required": true,
26348	//       "type": "string"
26349	//     },
26350	//     "profileId": {
26351	//       "description": "User profile ID associated with this request.",
26352	//       "format": "int64",
26353	//       "location": "path",
26354	//       "required": true,
26355	//       "type": "string"
26356	//     }
26357	//   },
26358	//   "path": "userprofiles/{profileId}/creativeFields/{creativeFieldId}/creativeFieldValues/{id}",
26359	//   "response": {
26360	//     "$ref": "CreativeFieldValue"
26361	//   },
26362	//   "scopes": [
26363	//     "https://www.googleapis.com/auth/dfatrafficking"
26364	//   ]
26365	// }
26366
26367}
26368
26369// method id "dfareporting.creativeFieldValues.insert":
26370
26371type CreativeFieldValuesInsertCall struct {
26372	s                  *Service
26373	profileId          int64
26374	creativeFieldId    int64
26375	creativefieldvalue *CreativeFieldValue
26376	urlParams_         gensupport.URLParams
26377	ctx_               context.Context
26378	header_            http.Header
26379}
26380
26381// Insert: Inserts a new creative field value.
26382//
26383// - creativeFieldId: Creative field ID for this creative field value.
26384// - profileId: User profile ID associated with this request.
26385func (r *CreativeFieldValuesService) Insert(profileId int64, creativeFieldId int64, creativefieldvalue *CreativeFieldValue) *CreativeFieldValuesInsertCall {
26386	c := &CreativeFieldValuesInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
26387	c.profileId = profileId
26388	c.creativeFieldId = creativeFieldId
26389	c.creativefieldvalue = creativefieldvalue
26390	return c
26391}
26392
26393// Fields allows partial responses to be retrieved. See
26394// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
26395// for more information.
26396func (c *CreativeFieldValuesInsertCall) Fields(s ...googleapi.Field) *CreativeFieldValuesInsertCall {
26397	c.urlParams_.Set("fields", googleapi.CombineFields(s))
26398	return c
26399}
26400
26401// Context sets the context to be used in this call's Do method. Any
26402// pending HTTP request will be aborted if the provided context is
26403// canceled.
26404func (c *CreativeFieldValuesInsertCall) Context(ctx context.Context) *CreativeFieldValuesInsertCall {
26405	c.ctx_ = ctx
26406	return c
26407}
26408
26409// Header returns an http.Header that can be modified by the caller to
26410// add HTTP headers to the request.
26411func (c *CreativeFieldValuesInsertCall) Header() http.Header {
26412	if c.header_ == nil {
26413		c.header_ = make(http.Header)
26414	}
26415	return c.header_
26416}
26417
26418func (c *CreativeFieldValuesInsertCall) doRequest(alt string) (*http.Response, error) {
26419	reqHeaders := make(http.Header)
26420	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
26421	for k, v := range c.header_ {
26422		reqHeaders[k] = v
26423	}
26424	reqHeaders.Set("User-Agent", c.s.userAgent())
26425	var body io.Reader = nil
26426	body, err := googleapi.WithoutDataWrapper.JSONReader(c.creativefieldvalue)
26427	if err != nil {
26428		return nil, err
26429	}
26430	reqHeaders.Set("Content-Type", "application/json")
26431	c.urlParams_.Set("alt", alt)
26432	c.urlParams_.Set("prettyPrint", "false")
26433	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeFields/{creativeFieldId}/creativeFieldValues")
26434	urls += "?" + c.urlParams_.Encode()
26435	req, err := http.NewRequest("POST", urls, body)
26436	if err != nil {
26437		return nil, err
26438	}
26439	req.Header = reqHeaders
26440	googleapi.Expand(req.URL, map[string]string{
26441		"profileId":       strconv.FormatInt(c.profileId, 10),
26442		"creativeFieldId": strconv.FormatInt(c.creativeFieldId, 10),
26443	})
26444	return gensupport.SendRequest(c.ctx_, c.s.client, req)
26445}
26446
26447// Do executes the "dfareporting.creativeFieldValues.insert" call.
26448// Exactly one of *CreativeFieldValue or error will be non-nil. Any
26449// non-2xx status code is an error. Response headers are in either
26450// *CreativeFieldValue.ServerResponse.Header or (if a response was
26451// returned at all) in error.(*googleapi.Error).Header. Use
26452// googleapi.IsNotModified to check whether the returned error was
26453// because http.StatusNotModified was returned.
26454func (c *CreativeFieldValuesInsertCall) Do(opts ...googleapi.CallOption) (*CreativeFieldValue, error) {
26455	gensupport.SetOptions(c.urlParams_, opts...)
26456	res, err := c.doRequest("json")
26457	if res != nil && res.StatusCode == http.StatusNotModified {
26458		if res.Body != nil {
26459			res.Body.Close()
26460		}
26461		return nil, &googleapi.Error{
26462			Code:   res.StatusCode,
26463			Header: res.Header,
26464		}
26465	}
26466	if err != nil {
26467		return nil, err
26468	}
26469	defer googleapi.CloseBody(res)
26470	if err := googleapi.CheckResponse(res); err != nil {
26471		return nil, err
26472	}
26473	ret := &CreativeFieldValue{
26474		ServerResponse: googleapi.ServerResponse{
26475			Header:         res.Header,
26476			HTTPStatusCode: res.StatusCode,
26477		},
26478	}
26479	target := &ret
26480	if err := gensupport.DecodeResponse(target, res); err != nil {
26481		return nil, err
26482	}
26483	return ret, nil
26484	// {
26485	//   "description": "Inserts a new creative field value.",
26486	//   "flatPath": "userprofiles/{profileId}/creativeFields/{creativeFieldId}/creativeFieldValues",
26487	//   "httpMethod": "POST",
26488	//   "id": "dfareporting.creativeFieldValues.insert",
26489	//   "parameterOrder": [
26490	//     "profileId",
26491	//     "creativeFieldId"
26492	//   ],
26493	//   "parameters": {
26494	//     "creativeFieldId": {
26495	//       "description": "Creative field ID for this creative field value.",
26496	//       "format": "int64",
26497	//       "location": "path",
26498	//       "required": true,
26499	//       "type": "string"
26500	//     },
26501	//     "profileId": {
26502	//       "description": "User profile ID associated with this request.",
26503	//       "format": "int64",
26504	//       "location": "path",
26505	//       "required": true,
26506	//       "type": "string"
26507	//     }
26508	//   },
26509	//   "path": "userprofiles/{profileId}/creativeFields/{creativeFieldId}/creativeFieldValues",
26510	//   "request": {
26511	//     "$ref": "CreativeFieldValue"
26512	//   },
26513	//   "response": {
26514	//     "$ref": "CreativeFieldValue"
26515	//   },
26516	//   "scopes": [
26517	//     "https://www.googleapis.com/auth/dfatrafficking"
26518	//   ]
26519	// }
26520
26521}
26522
26523// method id "dfareporting.creativeFieldValues.list":
26524
26525type CreativeFieldValuesListCall struct {
26526	s               *Service
26527	profileId       int64
26528	creativeFieldId int64
26529	urlParams_      gensupport.URLParams
26530	ifNoneMatch_    string
26531	ctx_            context.Context
26532	header_         http.Header
26533}
26534
26535// List: Retrieves a list of creative field values, possibly filtered.
26536// This method supports paging.
26537//
26538// - creativeFieldId: Creative field ID for this creative field value.
26539// - profileId: User profile ID associated with this request.
26540func (r *CreativeFieldValuesService) List(profileId int64, creativeFieldId int64) *CreativeFieldValuesListCall {
26541	c := &CreativeFieldValuesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
26542	c.profileId = profileId
26543	c.creativeFieldId = creativeFieldId
26544	return c
26545}
26546
26547// Ids sets the optional parameter "ids": Select only creative field
26548// values with these IDs.
26549func (c *CreativeFieldValuesListCall) Ids(ids ...int64) *CreativeFieldValuesListCall {
26550	var ids_ []string
26551	for _, v := range ids {
26552		ids_ = append(ids_, fmt.Sprint(v))
26553	}
26554	c.urlParams_.SetMulti("ids", ids_)
26555	return c
26556}
26557
26558// MaxResults sets the optional parameter "maxResults": Maximum number
26559// of results to return.
26560func (c *CreativeFieldValuesListCall) MaxResults(maxResults int64) *CreativeFieldValuesListCall {
26561	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
26562	return c
26563}
26564
26565// PageToken sets the optional parameter "pageToken": Value of the
26566// nextPageToken from the previous result page.
26567func (c *CreativeFieldValuesListCall) PageToken(pageToken string) *CreativeFieldValuesListCall {
26568	c.urlParams_.Set("pageToken", pageToken)
26569	return c
26570}
26571
26572// SearchString sets the optional parameter "searchString": Allows
26573// searching for creative field values by their values. Wildcards (e.g.
26574// *) are not allowed.
26575func (c *CreativeFieldValuesListCall) SearchString(searchString string) *CreativeFieldValuesListCall {
26576	c.urlParams_.Set("searchString", searchString)
26577	return c
26578}
26579
26580// SortField sets the optional parameter "sortField": Field by which to
26581// sort the list.
26582//
26583// Possible values:
26584//   "ID" (default)
26585//   "VALUE"
26586func (c *CreativeFieldValuesListCall) SortField(sortField string) *CreativeFieldValuesListCall {
26587	c.urlParams_.Set("sortField", sortField)
26588	return c
26589}
26590
26591// SortOrder sets the optional parameter "sortOrder": Order of sorted
26592// results.
26593//
26594// Possible values:
26595//   "ASCENDING" (default)
26596//   "DESCENDING"
26597func (c *CreativeFieldValuesListCall) SortOrder(sortOrder string) *CreativeFieldValuesListCall {
26598	c.urlParams_.Set("sortOrder", sortOrder)
26599	return c
26600}
26601
26602// Fields allows partial responses to be retrieved. See
26603// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
26604// for more information.
26605func (c *CreativeFieldValuesListCall) Fields(s ...googleapi.Field) *CreativeFieldValuesListCall {
26606	c.urlParams_.Set("fields", googleapi.CombineFields(s))
26607	return c
26608}
26609
26610// IfNoneMatch sets the optional parameter which makes the operation
26611// fail if the object's ETag matches the given value. This is useful for
26612// getting updates only after the object has changed since the last
26613// request. Use googleapi.IsNotModified to check whether the response
26614// error from Do is the result of In-None-Match.
26615func (c *CreativeFieldValuesListCall) IfNoneMatch(entityTag string) *CreativeFieldValuesListCall {
26616	c.ifNoneMatch_ = entityTag
26617	return c
26618}
26619
26620// Context sets the context to be used in this call's Do method. Any
26621// pending HTTP request will be aborted if the provided context is
26622// canceled.
26623func (c *CreativeFieldValuesListCall) Context(ctx context.Context) *CreativeFieldValuesListCall {
26624	c.ctx_ = ctx
26625	return c
26626}
26627
26628// Header returns an http.Header that can be modified by the caller to
26629// add HTTP headers to the request.
26630func (c *CreativeFieldValuesListCall) Header() http.Header {
26631	if c.header_ == nil {
26632		c.header_ = make(http.Header)
26633	}
26634	return c.header_
26635}
26636
26637func (c *CreativeFieldValuesListCall) doRequest(alt string) (*http.Response, error) {
26638	reqHeaders := make(http.Header)
26639	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
26640	for k, v := range c.header_ {
26641		reqHeaders[k] = v
26642	}
26643	reqHeaders.Set("User-Agent", c.s.userAgent())
26644	if c.ifNoneMatch_ != "" {
26645		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
26646	}
26647	var body io.Reader = nil
26648	c.urlParams_.Set("alt", alt)
26649	c.urlParams_.Set("prettyPrint", "false")
26650	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeFields/{creativeFieldId}/creativeFieldValues")
26651	urls += "?" + c.urlParams_.Encode()
26652	req, err := http.NewRequest("GET", urls, body)
26653	if err != nil {
26654		return nil, err
26655	}
26656	req.Header = reqHeaders
26657	googleapi.Expand(req.URL, map[string]string{
26658		"profileId":       strconv.FormatInt(c.profileId, 10),
26659		"creativeFieldId": strconv.FormatInt(c.creativeFieldId, 10),
26660	})
26661	return gensupport.SendRequest(c.ctx_, c.s.client, req)
26662}
26663
26664// Do executes the "dfareporting.creativeFieldValues.list" call.
26665// Exactly one of *CreativeFieldValuesListResponse or error will be
26666// non-nil. Any non-2xx status code is an error. Response headers are in
26667// either *CreativeFieldValuesListResponse.ServerResponse.Header or (if
26668// a response was returned at all) in error.(*googleapi.Error).Header.
26669// Use googleapi.IsNotModified to check whether the returned error was
26670// because http.StatusNotModified was returned.
26671func (c *CreativeFieldValuesListCall) Do(opts ...googleapi.CallOption) (*CreativeFieldValuesListResponse, error) {
26672	gensupport.SetOptions(c.urlParams_, opts...)
26673	res, err := c.doRequest("json")
26674	if res != nil && res.StatusCode == http.StatusNotModified {
26675		if res.Body != nil {
26676			res.Body.Close()
26677		}
26678		return nil, &googleapi.Error{
26679			Code:   res.StatusCode,
26680			Header: res.Header,
26681		}
26682	}
26683	if err != nil {
26684		return nil, err
26685	}
26686	defer googleapi.CloseBody(res)
26687	if err := googleapi.CheckResponse(res); err != nil {
26688		return nil, err
26689	}
26690	ret := &CreativeFieldValuesListResponse{
26691		ServerResponse: googleapi.ServerResponse{
26692			Header:         res.Header,
26693			HTTPStatusCode: res.StatusCode,
26694		},
26695	}
26696	target := &ret
26697	if err := gensupport.DecodeResponse(target, res); err != nil {
26698		return nil, err
26699	}
26700	return ret, nil
26701	// {
26702	//   "description": "Retrieves a list of creative field values, possibly filtered. This method supports paging.",
26703	//   "flatPath": "userprofiles/{profileId}/creativeFields/{creativeFieldId}/creativeFieldValues",
26704	//   "httpMethod": "GET",
26705	//   "id": "dfareporting.creativeFieldValues.list",
26706	//   "parameterOrder": [
26707	//     "profileId",
26708	//     "creativeFieldId"
26709	//   ],
26710	//   "parameters": {
26711	//     "creativeFieldId": {
26712	//       "description": "Creative field ID for this creative field value.",
26713	//       "format": "int64",
26714	//       "location": "path",
26715	//       "required": true,
26716	//       "type": "string"
26717	//     },
26718	//     "ids": {
26719	//       "description": "Select only creative field values with these IDs.",
26720	//       "format": "int64",
26721	//       "location": "query",
26722	//       "repeated": true,
26723	//       "type": "string"
26724	//     },
26725	//     "maxResults": {
26726	//       "default": "1000",
26727	//       "description": "Maximum number of results to return.",
26728	//       "format": "int32",
26729	//       "location": "query",
26730	//       "maximum": "1000",
26731	//       "minimum": "0",
26732	//       "type": "integer"
26733	//     },
26734	//     "pageToken": {
26735	//       "description": "Value of the nextPageToken from the previous result page.",
26736	//       "location": "query",
26737	//       "type": "string"
26738	//     },
26739	//     "profileId": {
26740	//       "description": "User profile ID associated with this request.",
26741	//       "format": "int64",
26742	//       "location": "path",
26743	//       "required": true,
26744	//       "type": "string"
26745	//     },
26746	//     "searchString": {
26747	//       "description": "Allows searching for creative field values by their values. Wildcards (e.g. *) are not allowed.",
26748	//       "location": "query",
26749	//       "type": "string"
26750	//     },
26751	//     "sortField": {
26752	//       "default": "ID",
26753	//       "description": "Field by which to sort the list.",
26754	//       "enum": [
26755	//         "ID",
26756	//         "VALUE"
26757	//       ],
26758	//       "enumDescriptions": [
26759	//         "",
26760	//         ""
26761	//       ],
26762	//       "location": "query",
26763	//       "type": "string"
26764	//     },
26765	//     "sortOrder": {
26766	//       "default": "ASCENDING",
26767	//       "description": "Order of sorted results.",
26768	//       "enum": [
26769	//         "ASCENDING",
26770	//         "DESCENDING"
26771	//       ],
26772	//       "enumDescriptions": [
26773	//         "",
26774	//         ""
26775	//       ],
26776	//       "location": "query",
26777	//       "type": "string"
26778	//     }
26779	//   },
26780	//   "path": "userprofiles/{profileId}/creativeFields/{creativeFieldId}/creativeFieldValues",
26781	//   "response": {
26782	//     "$ref": "CreativeFieldValuesListResponse"
26783	//   },
26784	//   "scopes": [
26785	//     "https://www.googleapis.com/auth/dfatrafficking"
26786	//   ]
26787	// }
26788
26789}
26790
26791// Pages invokes f for each page of results.
26792// A non-nil error returned from f will halt the iteration.
26793// The provided context supersedes any context provided to the Context method.
26794func (c *CreativeFieldValuesListCall) Pages(ctx context.Context, f func(*CreativeFieldValuesListResponse) error) error {
26795	c.ctx_ = ctx
26796	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
26797	for {
26798		x, err := c.Do()
26799		if err != nil {
26800			return err
26801		}
26802		if err := f(x); err != nil {
26803			return err
26804		}
26805		if x.NextPageToken == "" {
26806			return nil
26807		}
26808		c.PageToken(x.NextPageToken)
26809	}
26810}
26811
26812// method id "dfareporting.creativeFieldValues.patch":
26813
26814type CreativeFieldValuesPatchCall struct {
26815	s                  *Service
26816	profileId          int64
26817	creativeFieldId    int64
26818	creativefieldvalue *CreativeFieldValue
26819	urlParams_         gensupport.URLParams
26820	ctx_               context.Context
26821	header_            http.Header
26822}
26823
26824// Patch: Updates an existing creative field value. This method supports
26825// patch semantics.
26826//
26827// - creativeFieldId: CreativeField ID.
26828// - id: CreativeFieldValue ID.
26829// - profileId: User profile ID associated with this request.
26830func (r *CreativeFieldValuesService) Patch(profileId int64, creativeFieldId int64, id int64, creativefieldvalue *CreativeFieldValue) *CreativeFieldValuesPatchCall {
26831	c := &CreativeFieldValuesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
26832	c.profileId = profileId
26833	c.creativeFieldId = creativeFieldId
26834	c.urlParams_.Set("id", fmt.Sprint(id))
26835	c.creativefieldvalue = creativefieldvalue
26836	return c
26837}
26838
26839// Fields allows partial responses to be retrieved. See
26840// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
26841// for more information.
26842func (c *CreativeFieldValuesPatchCall) Fields(s ...googleapi.Field) *CreativeFieldValuesPatchCall {
26843	c.urlParams_.Set("fields", googleapi.CombineFields(s))
26844	return c
26845}
26846
26847// Context sets the context to be used in this call's Do method. Any
26848// pending HTTP request will be aborted if the provided context is
26849// canceled.
26850func (c *CreativeFieldValuesPatchCall) Context(ctx context.Context) *CreativeFieldValuesPatchCall {
26851	c.ctx_ = ctx
26852	return c
26853}
26854
26855// Header returns an http.Header that can be modified by the caller to
26856// add HTTP headers to the request.
26857func (c *CreativeFieldValuesPatchCall) Header() http.Header {
26858	if c.header_ == nil {
26859		c.header_ = make(http.Header)
26860	}
26861	return c.header_
26862}
26863
26864func (c *CreativeFieldValuesPatchCall) doRequest(alt string) (*http.Response, error) {
26865	reqHeaders := make(http.Header)
26866	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
26867	for k, v := range c.header_ {
26868		reqHeaders[k] = v
26869	}
26870	reqHeaders.Set("User-Agent", c.s.userAgent())
26871	var body io.Reader = nil
26872	body, err := googleapi.WithoutDataWrapper.JSONReader(c.creativefieldvalue)
26873	if err != nil {
26874		return nil, err
26875	}
26876	reqHeaders.Set("Content-Type", "application/json")
26877	c.urlParams_.Set("alt", alt)
26878	c.urlParams_.Set("prettyPrint", "false")
26879	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeFields/{creativeFieldId}/creativeFieldValues")
26880	urls += "?" + c.urlParams_.Encode()
26881	req, err := http.NewRequest("PATCH", urls, body)
26882	if err != nil {
26883		return nil, err
26884	}
26885	req.Header = reqHeaders
26886	googleapi.Expand(req.URL, map[string]string{
26887		"profileId":       strconv.FormatInt(c.profileId, 10),
26888		"creativeFieldId": strconv.FormatInt(c.creativeFieldId, 10),
26889	})
26890	return gensupport.SendRequest(c.ctx_, c.s.client, req)
26891}
26892
26893// Do executes the "dfareporting.creativeFieldValues.patch" call.
26894// Exactly one of *CreativeFieldValue or error will be non-nil. Any
26895// non-2xx status code is an error. Response headers are in either
26896// *CreativeFieldValue.ServerResponse.Header or (if a response was
26897// returned at all) in error.(*googleapi.Error).Header. Use
26898// googleapi.IsNotModified to check whether the returned error was
26899// because http.StatusNotModified was returned.
26900func (c *CreativeFieldValuesPatchCall) Do(opts ...googleapi.CallOption) (*CreativeFieldValue, error) {
26901	gensupport.SetOptions(c.urlParams_, opts...)
26902	res, err := c.doRequest("json")
26903	if res != nil && res.StatusCode == http.StatusNotModified {
26904		if res.Body != nil {
26905			res.Body.Close()
26906		}
26907		return nil, &googleapi.Error{
26908			Code:   res.StatusCode,
26909			Header: res.Header,
26910		}
26911	}
26912	if err != nil {
26913		return nil, err
26914	}
26915	defer googleapi.CloseBody(res)
26916	if err := googleapi.CheckResponse(res); err != nil {
26917		return nil, err
26918	}
26919	ret := &CreativeFieldValue{
26920		ServerResponse: googleapi.ServerResponse{
26921			Header:         res.Header,
26922			HTTPStatusCode: res.StatusCode,
26923		},
26924	}
26925	target := &ret
26926	if err := gensupport.DecodeResponse(target, res); err != nil {
26927		return nil, err
26928	}
26929	return ret, nil
26930	// {
26931	//   "description": "Updates an existing creative field value. This method supports patch semantics.",
26932	//   "flatPath": "userprofiles/{profileId}/creativeFields/{creativeFieldId}/creativeFieldValues",
26933	//   "httpMethod": "PATCH",
26934	//   "id": "dfareporting.creativeFieldValues.patch",
26935	//   "parameterOrder": [
26936	//     "profileId",
26937	//     "creativeFieldId",
26938	//     "id"
26939	//   ],
26940	//   "parameters": {
26941	//     "creativeFieldId": {
26942	//       "description": "CreativeField ID.",
26943	//       "format": "int64",
26944	//       "location": "path",
26945	//       "required": true,
26946	//       "type": "string"
26947	//     },
26948	//     "id": {
26949	//       "description": "CreativeFieldValue ID.",
26950	//       "format": "int64",
26951	//       "location": "query",
26952	//       "required": true,
26953	//       "type": "string"
26954	//     },
26955	//     "profileId": {
26956	//       "description": "User profile ID associated with this request.",
26957	//       "format": "int64",
26958	//       "location": "path",
26959	//       "required": true,
26960	//       "type": "string"
26961	//     }
26962	//   },
26963	//   "path": "userprofiles/{profileId}/creativeFields/{creativeFieldId}/creativeFieldValues",
26964	//   "request": {
26965	//     "$ref": "CreativeFieldValue"
26966	//   },
26967	//   "response": {
26968	//     "$ref": "CreativeFieldValue"
26969	//   },
26970	//   "scopes": [
26971	//     "https://www.googleapis.com/auth/dfatrafficking"
26972	//   ]
26973	// }
26974
26975}
26976
26977// method id "dfareporting.creativeFieldValues.update":
26978
26979type CreativeFieldValuesUpdateCall struct {
26980	s                  *Service
26981	profileId          int64
26982	creativeFieldId    int64
26983	creativefieldvalue *CreativeFieldValue
26984	urlParams_         gensupport.URLParams
26985	ctx_               context.Context
26986	header_            http.Header
26987}
26988
26989// Update: Updates an existing creative field value.
26990//
26991// - creativeFieldId: Creative field ID for this creative field value.
26992// - profileId: User profile ID associated with this request.
26993func (r *CreativeFieldValuesService) Update(profileId int64, creativeFieldId int64, creativefieldvalue *CreativeFieldValue) *CreativeFieldValuesUpdateCall {
26994	c := &CreativeFieldValuesUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
26995	c.profileId = profileId
26996	c.creativeFieldId = creativeFieldId
26997	c.creativefieldvalue = creativefieldvalue
26998	return c
26999}
27000
27001// Fields allows partial responses to be retrieved. See
27002// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
27003// for more information.
27004func (c *CreativeFieldValuesUpdateCall) Fields(s ...googleapi.Field) *CreativeFieldValuesUpdateCall {
27005	c.urlParams_.Set("fields", googleapi.CombineFields(s))
27006	return c
27007}
27008
27009// Context sets the context to be used in this call's Do method. Any
27010// pending HTTP request will be aborted if the provided context is
27011// canceled.
27012func (c *CreativeFieldValuesUpdateCall) Context(ctx context.Context) *CreativeFieldValuesUpdateCall {
27013	c.ctx_ = ctx
27014	return c
27015}
27016
27017// Header returns an http.Header that can be modified by the caller to
27018// add HTTP headers to the request.
27019func (c *CreativeFieldValuesUpdateCall) Header() http.Header {
27020	if c.header_ == nil {
27021		c.header_ = make(http.Header)
27022	}
27023	return c.header_
27024}
27025
27026func (c *CreativeFieldValuesUpdateCall) doRequest(alt string) (*http.Response, error) {
27027	reqHeaders := make(http.Header)
27028	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
27029	for k, v := range c.header_ {
27030		reqHeaders[k] = v
27031	}
27032	reqHeaders.Set("User-Agent", c.s.userAgent())
27033	var body io.Reader = nil
27034	body, err := googleapi.WithoutDataWrapper.JSONReader(c.creativefieldvalue)
27035	if err != nil {
27036		return nil, err
27037	}
27038	reqHeaders.Set("Content-Type", "application/json")
27039	c.urlParams_.Set("alt", alt)
27040	c.urlParams_.Set("prettyPrint", "false")
27041	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeFields/{creativeFieldId}/creativeFieldValues")
27042	urls += "?" + c.urlParams_.Encode()
27043	req, err := http.NewRequest("PUT", urls, body)
27044	if err != nil {
27045		return nil, err
27046	}
27047	req.Header = reqHeaders
27048	googleapi.Expand(req.URL, map[string]string{
27049		"profileId":       strconv.FormatInt(c.profileId, 10),
27050		"creativeFieldId": strconv.FormatInt(c.creativeFieldId, 10),
27051	})
27052	return gensupport.SendRequest(c.ctx_, c.s.client, req)
27053}
27054
27055// Do executes the "dfareporting.creativeFieldValues.update" call.
27056// Exactly one of *CreativeFieldValue or error will be non-nil. Any
27057// non-2xx status code is an error. Response headers are in either
27058// *CreativeFieldValue.ServerResponse.Header or (if a response was
27059// returned at all) in error.(*googleapi.Error).Header. Use
27060// googleapi.IsNotModified to check whether the returned error was
27061// because http.StatusNotModified was returned.
27062func (c *CreativeFieldValuesUpdateCall) Do(opts ...googleapi.CallOption) (*CreativeFieldValue, error) {
27063	gensupport.SetOptions(c.urlParams_, opts...)
27064	res, err := c.doRequest("json")
27065	if res != nil && res.StatusCode == http.StatusNotModified {
27066		if res.Body != nil {
27067			res.Body.Close()
27068		}
27069		return nil, &googleapi.Error{
27070			Code:   res.StatusCode,
27071			Header: res.Header,
27072		}
27073	}
27074	if err != nil {
27075		return nil, err
27076	}
27077	defer googleapi.CloseBody(res)
27078	if err := googleapi.CheckResponse(res); err != nil {
27079		return nil, err
27080	}
27081	ret := &CreativeFieldValue{
27082		ServerResponse: googleapi.ServerResponse{
27083			Header:         res.Header,
27084			HTTPStatusCode: res.StatusCode,
27085		},
27086	}
27087	target := &ret
27088	if err := gensupport.DecodeResponse(target, res); err != nil {
27089		return nil, err
27090	}
27091	return ret, nil
27092	// {
27093	//   "description": "Updates an existing creative field value.",
27094	//   "flatPath": "userprofiles/{profileId}/creativeFields/{creativeFieldId}/creativeFieldValues",
27095	//   "httpMethod": "PUT",
27096	//   "id": "dfareporting.creativeFieldValues.update",
27097	//   "parameterOrder": [
27098	//     "profileId",
27099	//     "creativeFieldId"
27100	//   ],
27101	//   "parameters": {
27102	//     "creativeFieldId": {
27103	//       "description": "Creative field ID for this creative field value.",
27104	//       "format": "int64",
27105	//       "location": "path",
27106	//       "required": true,
27107	//       "type": "string"
27108	//     },
27109	//     "profileId": {
27110	//       "description": "User profile ID associated with this request.",
27111	//       "format": "int64",
27112	//       "location": "path",
27113	//       "required": true,
27114	//       "type": "string"
27115	//     }
27116	//   },
27117	//   "path": "userprofiles/{profileId}/creativeFields/{creativeFieldId}/creativeFieldValues",
27118	//   "request": {
27119	//     "$ref": "CreativeFieldValue"
27120	//   },
27121	//   "response": {
27122	//     "$ref": "CreativeFieldValue"
27123	//   },
27124	//   "scopes": [
27125	//     "https://www.googleapis.com/auth/dfatrafficking"
27126	//   ]
27127	// }
27128
27129}
27130
27131// method id "dfareporting.creativeFields.delete":
27132
27133type CreativeFieldsDeleteCall struct {
27134	s          *Service
27135	profileId  int64
27136	id         int64
27137	urlParams_ gensupport.URLParams
27138	ctx_       context.Context
27139	header_    http.Header
27140}
27141
27142// Delete: Deletes an existing creative field.
27143//
27144// - id: Creative Field ID.
27145// - profileId: User profile ID associated with this request.
27146func (r *CreativeFieldsService) Delete(profileId int64, id int64) *CreativeFieldsDeleteCall {
27147	c := &CreativeFieldsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
27148	c.profileId = profileId
27149	c.id = id
27150	return c
27151}
27152
27153// Fields allows partial responses to be retrieved. See
27154// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
27155// for more information.
27156func (c *CreativeFieldsDeleteCall) Fields(s ...googleapi.Field) *CreativeFieldsDeleteCall {
27157	c.urlParams_.Set("fields", googleapi.CombineFields(s))
27158	return c
27159}
27160
27161// Context sets the context to be used in this call's Do method. Any
27162// pending HTTP request will be aborted if the provided context is
27163// canceled.
27164func (c *CreativeFieldsDeleteCall) Context(ctx context.Context) *CreativeFieldsDeleteCall {
27165	c.ctx_ = ctx
27166	return c
27167}
27168
27169// Header returns an http.Header that can be modified by the caller to
27170// add HTTP headers to the request.
27171func (c *CreativeFieldsDeleteCall) Header() http.Header {
27172	if c.header_ == nil {
27173		c.header_ = make(http.Header)
27174	}
27175	return c.header_
27176}
27177
27178func (c *CreativeFieldsDeleteCall) doRequest(alt string) (*http.Response, error) {
27179	reqHeaders := make(http.Header)
27180	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
27181	for k, v := range c.header_ {
27182		reqHeaders[k] = v
27183	}
27184	reqHeaders.Set("User-Agent", c.s.userAgent())
27185	var body io.Reader = nil
27186	c.urlParams_.Set("alt", alt)
27187	c.urlParams_.Set("prettyPrint", "false")
27188	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeFields/{id}")
27189	urls += "?" + c.urlParams_.Encode()
27190	req, err := http.NewRequest("DELETE", urls, body)
27191	if err != nil {
27192		return nil, err
27193	}
27194	req.Header = reqHeaders
27195	googleapi.Expand(req.URL, map[string]string{
27196		"profileId": strconv.FormatInt(c.profileId, 10),
27197		"id":        strconv.FormatInt(c.id, 10),
27198	})
27199	return gensupport.SendRequest(c.ctx_, c.s.client, req)
27200}
27201
27202// Do executes the "dfareporting.creativeFields.delete" call.
27203func (c *CreativeFieldsDeleteCall) Do(opts ...googleapi.CallOption) error {
27204	gensupport.SetOptions(c.urlParams_, opts...)
27205	res, err := c.doRequest("json")
27206	if err != nil {
27207		return err
27208	}
27209	defer googleapi.CloseBody(res)
27210	if err := googleapi.CheckResponse(res); err != nil {
27211		return err
27212	}
27213	return nil
27214	// {
27215	//   "description": "Deletes an existing creative field.",
27216	//   "flatPath": "userprofiles/{profileId}/creativeFields/{id}",
27217	//   "httpMethod": "DELETE",
27218	//   "id": "dfareporting.creativeFields.delete",
27219	//   "parameterOrder": [
27220	//     "profileId",
27221	//     "id"
27222	//   ],
27223	//   "parameters": {
27224	//     "id": {
27225	//       "description": "Creative Field ID",
27226	//       "format": "int64",
27227	//       "location": "path",
27228	//       "required": true,
27229	//       "type": "string"
27230	//     },
27231	//     "profileId": {
27232	//       "description": "User profile ID associated with this request.",
27233	//       "format": "int64",
27234	//       "location": "path",
27235	//       "required": true,
27236	//       "type": "string"
27237	//     }
27238	//   },
27239	//   "path": "userprofiles/{profileId}/creativeFields/{id}",
27240	//   "scopes": [
27241	//     "https://www.googleapis.com/auth/dfatrafficking"
27242	//   ]
27243	// }
27244
27245}
27246
27247// method id "dfareporting.creativeFields.get":
27248
27249type CreativeFieldsGetCall struct {
27250	s            *Service
27251	profileId    int64
27252	id           int64
27253	urlParams_   gensupport.URLParams
27254	ifNoneMatch_ string
27255	ctx_         context.Context
27256	header_      http.Header
27257}
27258
27259// Get: Gets one creative field by ID.
27260//
27261// - id: Creative Field ID.
27262// - profileId: User profile ID associated with this request.
27263func (r *CreativeFieldsService) Get(profileId int64, id int64) *CreativeFieldsGetCall {
27264	c := &CreativeFieldsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
27265	c.profileId = profileId
27266	c.id = id
27267	return c
27268}
27269
27270// Fields allows partial responses to be retrieved. See
27271// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
27272// for more information.
27273func (c *CreativeFieldsGetCall) Fields(s ...googleapi.Field) *CreativeFieldsGetCall {
27274	c.urlParams_.Set("fields", googleapi.CombineFields(s))
27275	return c
27276}
27277
27278// IfNoneMatch sets the optional parameter which makes the operation
27279// fail if the object's ETag matches the given value. This is useful for
27280// getting updates only after the object has changed since the last
27281// request. Use googleapi.IsNotModified to check whether the response
27282// error from Do is the result of In-None-Match.
27283func (c *CreativeFieldsGetCall) IfNoneMatch(entityTag string) *CreativeFieldsGetCall {
27284	c.ifNoneMatch_ = entityTag
27285	return c
27286}
27287
27288// Context sets the context to be used in this call's Do method. Any
27289// pending HTTP request will be aborted if the provided context is
27290// canceled.
27291func (c *CreativeFieldsGetCall) Context(ctx context.Context) *CreativeFieldsGetCall {
27292	c.ctx_ = ctx
27293	return c
27294}
27295
27296// Header returns an http.Header that can be modified by the caller to
27297// add HTTP headers to the request.
27298func (c *CreativeFieldsGetCall) Header() http.Header {
27299	if c.header_ == nil {
27300		c.header_ = make(http.Header)
27301	}
27302	return c.header_
27303}
27304
27305func (c *CreativeFieldsGetCall) doRequest(alt string) (*http.Response, error) {
27306	reqHeaders := make(http.Header)
27307	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
27308	for k, v := range c.header_ {
27309		reqHeaders[k] = v
27310	}
27311	reqHeaders.Set("User-Agent", c.s.userAgent())
27312	if c.ifNoneMatch_ != "" {
27313		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
27314	}
27315	var body io.Reader = nil
27316	c.urlParams_.Set("alt", alt)
27317	c.urlParams_.Set("prettyPrint", "false")
27318	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeFields/{id}")
27319	urls += "?" + c.urlParams_.Encode()
27320	req, err := http.NewRequest("GET", urls, body)
27321	if err != nil {
27322		return nil, err
27323	}
27324	req.Header = reqHeaders
27325	googleapi.Expand(req.URL, map[string]string{
27326		"profileId": strconv.FormatInt(c.profileId, 10),
27327		"id":        strconv.FormatInt(c.id, 10),
27328	})
27329	return gensupport.SendRequest(c.ctx_, c.s.client, req)
27330}
27331
27332// Do executes the "dfareporting.creativeFields.get" call.
27333// Exactly one of *CreativeField or error will be non-nil. Any non-2xx
27334// status code is an error. Response headers are in either
27335// *CreativeField.ServerResponse.Header or (if a response was returned
27336// at all) in error.(*googleapi.Error).Header. Use
27337// googleapi.IsNotModified to check whether the returned error was
27338// because http.StatusNotModified was returned.
27339func (c *CreativeFieldsGetCall) Do(opts ...googleapi.CallOption) (*CreativeField, error) {
27340	gensupport.SetOptions(c.urlParams_, opts...)
27341	res, err := c.doRequest("json")
27342	if res != nil && res.StatusCode == http.StatusNotModified {
27343		if res.Body != nil {
27344			res.Body.Close()
27345		}
27346		return nil, &googleapi.Error{
27347			Code:   res.StatusCode,
27348			Header: res.Header,
27349		}
27350	}
27351	if err != nil {
27352		return nil, err
27353	}
27354	defer googleapi.CloseBody(res)
27355	if err := googleapi.CheckResponse(res); err != nil {
27356		return nil, err
27357	}
27358	ret := &CreativeField{
27359		ServerResponse: googleapi.ServerResponse{
27360			Header:         res.Header,
27361			HTTPStatusCode: res.StatusCode,
27362		},
27363	}
27364	target := &ret
27365	if err := gensupport.DecodeResponse(target, res); err != nil {
27366		return nil, err
27367	}
27368	return ret, nil
27369	// {
27370	//   "description": "Gets one creative field by ID.",
27371	//   "flatPath": "userprofiles/{profileId}/creativeFields/{id}",
27372	//   "httpMethod": "GET",
27373	//   "id": "dfareporting.creativeFields.get",
27374	//   "parameterOrder": [
27375	//     "profileId",
27376	//     "id"
27377	//   ],
27378	//   "parameters": {
27379	//     "id": {
27380	//       "description": "Creative Field ID",
27381	//       "format": "int64",
27382	//       "location": "path",
27383	//       "required": true,
27384	//       "type": "string"
27385	//     },
27386	//     "profileId": {
27387	//       "description": "User profile ID associated with this request.",
27388	//       "format": "int64",
27389	//       "location": "path",
27390	//       "required": true,
27391	//       "type": "string"
27392	//     }
27393	//   },
27394	//   "path": "userprofiles/{profileId}/creativeFields/{id}",
27395	//   "response": {
27396	//     "$ref": "CreativeField"
27397	//   },
27398	//   "scopes": [
27399	//     "https://www.googleapis.com/auth/dfatrafficking"
27400	//   ]
27401	// }
27402
27403}
27404
27405// method id "dfareporting.creativeFields.insert":
27406
27407type CreativeFieldsInsertCall struct {
27408	s             *Service
27409	profileId     int64
27410	creativefield *CreativeField
27411	urlParams_    gensupport.URLParams
27412	ctx_          context.Context
27413	header_       http.Header
27414}
27415
27416// Insert: Inserts a new creative field.
27417//
27418// - profileId: User profile ID associated with this request.
27419func (r *CreativeFieldsService) Insert(profileId int64, creativefield *CreativeField) *CreativeFieldsInsertCall {
27420	c := &CreativeFieldsInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
27421	c.profileId = profileId
27422	c.creativefield = creativefield
27423	return c
27424}
27425
27426// Fields allows partial responses to be retrieved. See
27427// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
27428// for more information.
27429func (c *CreativeFieldsInsertCall) Fields(s ...googleapi.Field) *CreativeFieldsInsertCall {
27430	c.urlParams_.Set("fields", googleapi.CombineFields(s))
27431	return c
27432}
27433
27434// Context sets the context to be used in this call's Do method. Any
27435// pending HTTP request will be aborted if the provided context is
27436// canceled.
27437func (c *CreativeFieldsInsertCall) Context(ctx context.Context) *CreativeFieldsInsertCall {
27438	c.ctx_ = ctx
27439	return c
27440}
27441
27442// Header returns an http.Header that can be modified by the caller to
27443// add HTTP headers to the request.
27444func (c *CreativeFieldsInsertCall) Header() http.Header {
27445	if c.header_ == nil {
27446		c.header_ = make(http.Header)
27447	}
27448	return c.header_
27449}
27450
27451func (c *CreativeFieldsInsertCall) doRequest(alt string) (*http.Response, error) {
27452	reqHeaders := make(http.Header)
27453	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
27454	for k, v := range c.header_ {
27455		reqHeaders[k] = v
27456	}
27457	reqHeaders.Set("User-Agent", c.s.userAgent())
27458	var body io.Reader = nil
27459	body, err := googleapi.WithoutDataWrapper.JSONReader(c.creativefield)
27460	if err != nil {
27461		return nil, err
27462	}
27463	reqHeaders.Set("Content-Type", "application/json")
27464	c.urlParams_.Set("alt", alt)
27465	c.urlParams_.Set("prettyPrint", "false")
27466	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeFields")
27467	urls += "?" + c.urlParams_.Encode()
27468	req, err := http.NewRequest("POST", urls, body)
27469	if err != nil {
27470		return nil, err
27471	}
27472	req.Header = reqHeaders
27473	googleapi.Expand(req.URL, map[string]string{
27474		"profileId": strconv.FormatInt(c.profileId, 10),
27475	})
27476	return gensupport.SendRequest(c.ctx_, c.s.client, req)
27477}
27478
27479// Do executes the "dfareporting.creativeFields.insert" call.
27480// Exactly one of *CreativeField or error will be non-nil. Any non-2xx
27481// status code is an error. Response headers are in either
27482// *CreativeField.ServerResponse.Header or (if a response was returned
27483// at all) in error.(*googleapi.Error).Header. Use
27484// googleapi.IsNotModified to check whether the returned error was
27485// because http.StatusNotModified was returned.
27486func (c *CreativeFieldsInsertCall) Do(opts ...googleapi.CallOption) (*CreativeField, error) {
27487	gensupport.SetOptions(c.urlParams_, opts...)
27488	res, err := c.doRequest("json")
27489	if res != nil && res.StatusCode == http.StatusNotModified {
27490		if res.Body != nil {
27491			res.Body.Close()
27492		}
27493		return nil, &googleapi.Error{
27494			Code:   res.StatusCode,
27495			Header: res.Header,
27496		}
27497	}
27498	if err != nil {
27499		return nil, err
27500	}
27501	defer googleapi.CloseBody(res)
27502	if err := googleapi.CheckResponse(res); err != nil {
27503		return nil, err
27504	}
27505	ret := &CreativeField{
27506		ServerResponse: googleapi.ServerResponse{
27507			Header:         res.Header,
27508			HTTPStatusCode: res.StatusCode,
27509		},
27510	}
27511	target := &ret
27512	if err := gensupport.DecodeResponse(target, res); err != nil {
27513		return nil, err
27514	}
27515	return ret, nil
27516	// {
27517	//   "description": "Inserts a new creative field.",
27518	//   "flatPath": "userprofiles/{profileId}/creativeFields",
27519	//   "httpMethod": "POST",
27520	//   "id": "dfareporting.creativeFields.insert",
27521	//   "parameterOrder": [
27522	//     "profileId"
27523	//   ],
27524	//   "parameters": {
27525	//     "profileId": {
27526	//       "description": "User profile ID associated with this request.",
27527	//       "format": "int64",
27528	//       "location": "path",
27529	//       "required": true,
27530	//       "type": "string"
27531	//     }
27532	//   },
27533	//   "path": "userprofiles/{profileId}/creativeFields",
27534	//   "request": {
27535	//     "$ref": "CreativeField"
27536	//   },
27537	//   "response": {
27538	//     "$ref": "CreativeField"
27539	//   },
27540	//   "scopes": [
27541	//     "https://www.googleapis.com/auth/dfatrafficking"
27542	//   ]
27543	// }
27544
27545}
27546
27547// method id "dfareporting.creativeFields.list":
27548
27549type CreativeFieldsListCall struct {
27550	s            *Service
27551	profileId    int64
27552	urlParams_   gensupport.URLParams
27553	ifNoneMatch_ string
27554	ctx_         context.Context
27555	header_      http.Header
27556}
27557
27558// List: Retrieves a list of creative fields, possibly filtered. This
27559// method supports paging.
27560//
27561// - profileId: User profile ID associated with this request.
27562func (r *CreativeFieldsService) List(profileId int64) *CreativeFieldsListCall {
27563	c := &CreativeFieldsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
27564	c.profileId = profileId
27565	return c
27566}
27567
27568// AdvertiserIds sets the optional parameter "advertiserIds": Select
27569// only creative fields that belong to these advertisers.
27570func (c *CreativeFieldsListCall) AdvertiserIds(advertiserIds ...int64) *CreativeFieldsListCall {
27571	var advertiserIds_ []string
27572	for _, v := range advertiserIds {
27573		advertiserIds_ = append(advertiserIds_, fmt.Sprint(v))
27574	}
27575	c.urlParams_.SetMulti("advertiserIds", advertiserIds_)
27576	return c
27577}
27578
27579// Ids sets the optional parameter "ids": Select only creative fields
27580// with these IDs.
27581func (c *CreativeFieldsListCall) Ids(ids ...int64) *CreativeFieldsListCall {
27582	var ids_ []string
27583	for _, v := range ids {
27584		ids_ = append(ids_, fmt.Sprint(v))
27585	}
27586	c.urlParams_.SetMulti("ids", ids_)
27587	return c
27588}
27589
27590// MaxResults sets the optional parameter "maxResults": Maximum number
27591// of results to return.
27592func (c *CreativeFieldsListCall) MaxResults(maxResults int64) *CreativeFieldsListCall {
27593	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
27594	return c
27595}
27596
27597// PageToken sets the optional parameter "pageToken": Value of the
27598// nextPageToken from the previous result page.
27599func (c *CreativeFieldsListCall) PageToken(pageToken string) *CreativeFieldsListCall {
27600	c.urlParams_.Set("pageToken", pageToken)
27601	return c
27602}
27603
27604// SearchString sets the optional parameter "searchString": Allows
27605// searching for creative fields by name or ID. Wildcards (*) are
27606// allowed. For example, "creativefield*2015" will return creative
27607// fields with names like "creativefield June 2015", "creativefield
27608// April 2015", or simply "creativefield 2015". Most of the searches
27609// also add wild-cards implicitly at the start and the end of the search
27610// string. For example, a search string of "creativefield" will match
27611// creative fields with the name "my creativefield", "creativefield
27612// 2015", or simply "creativefield".
27613func (c *CreativeFieldsListCall) SearchString(searchString string) *CreativeFieldsListCall {
27614	c.urlParams_.Set("searchString", searchString)
27615	return c
27616}
27617
27618// SortField sets the optional parameter "sortField": Field by which to
27619// sort the list.
27620//
27621// Possible values:
27622//   "ID" (default)
27623//   "NAME"
27624func (c *CreativeFieldsListCall) SortField(sortField string) *CreativeFieldsListCall {
27625	c.urlParams_.Set("sortField", sortField)
27626	return c
27627}
27628
27629// SortOrder sets the optional parameter "sortOrder": Order of sorted
27630// results.
27631//
27632// Possible values:
27633//   "ASCENDING" (default)
27634//   "DESCENDING"
27635func (c *CreativeFieldsListCall) SortOrder(sortOrder string) *CreativeFieldsListCall {
27636	c.urlParams_.Set("sortOrder", sortOrder)
27637	return c
27638}
27639
27640// Fields allows partial responses to be retrieved. See
27641// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
27642// for more information.
27643func (c *CreativeFieldsListCall) Fields(s ...googleapi.Field) *CreativeFieldsListCall {
27644	c.urlParams_.Set("fields", googleapi.CombineFields(s))
27645	return c
27646}
27647
27648// IfNoneMatch sets the optional parameter which makes the operation
27649// fail if the object's ETag matches the given value. This is useful for
27650// getting updates only after the object has changed since the last
27651// request. Use googleapi.IsNotModified to check whether the response
27652// error from Do is the result of In-None-Match.
27653func (c *CreativeFieldsListCall) IfNoneMatch(entityTag string) *CreativeFieldsListCall {
27654	c.ifNoneMatch_ = entityTag
27655	return c
27656}
27657
27658// Context sets the context to be used in this call's Do method. Any
27659// pending HTTP request will be aborted if the provided context is
27660// canceled.
27661func (c *CreativeFieldsListCall) Context(ctx context.Context) *CreativeFieldsListCall {
27662	c.ctx_ = ctx
27663	return c
27664}
27665
27666// Header returns an http.Header that can be modified by the caller to
27667// add HTTP headers to the request.
27668func (c *CreativeFieldsListCall) Header() http.Header {
27669	if c.header_ == nil {
27670		c.header_ = make(http.Header)
27671	}
27672	return c.header_
27673}
27674
27675func (c *CreativeFieldsListCall) doRequest(alt string) (*http.Response, error) {
27676	reqHeaders := make(http.Header)
27677	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
27678	for k, v := range c.header_ {
27679		reqHeaders[k] = v
27680	}
27681	reqHeaders.Set("User-Agent", c.s.userAgent())
27682	if c.ifNoneMatch_ != "" {
27683		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
27684	}
27685	var body io.Reader = nil
27686	c.urlParams_.Set("alt", alt)
27687	c.urlParams_.Set("prettyPrint", "false")
27688	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeFields")
27689	urls += "?" + c.urlParams_.Encode()
27690	req, err := http.NewRequest("GET", urls, body)
27691	if err != nil {
27692		return nil, err
27693	}
27694	req.Header = reqHeaders
27695	googleapi.Expand(req.URL, map[string]string{
27696		"profileId": strconv.FormatInt(c.profileId, 10),
27697	})
27698	return gensupport.SendRequest(c.ctx_, c.s.client, req)
27699}
27700
27701// Do executes the "dfareporting.creativeFields.list" call.
27702// Exactly one of *CreativeFieldsListResponse or error will be non-nil.
27703// Any non-2xx status code is an error. Response headers are in either
27704// *CreativeFieldsListResponse.ServerResponse.Header or (if a response
27705// was returned at all) in error.(*googleapi.Error).Header. Use
27706// googleapi.IsNotModified to check whether the returned error was
27707// because http.StatusNotModified was returned.
27708func (c *CreativeFieldsListCall) Do(opts ...googleapi.CallOption) (*CreativeFieldsListResponse, error) {
27709	gensupport.SetOptions(c.urlParams_, opts...)
27710	res, err := c.doRequest("json")
27711	if res != nil && res.StatusCode == http.StatusNotModified {
27712		if res.Body != nil {
27713			res.Body.Close()
27714		}
27715		return nil, &googleapi.Error{
27716			Code:   res.StatusCode,
27717			Header: res.Header,
27718		}
27719	}
27720	if err != nil {
27721		return nil, err
27722	}
27723	defer googleapi.CloseBody(res)
27724	if err := googleapi.CheckResponse(res); err != nil {
27725		return nil, err
27726	}
27727	ret := &CreativeFieldsListResponse{
27728		ServerResponse: googleapi.ServerResponse{
27729			Header:         res.Header,
27730			HTTPStatusCode: res.StatusCode,
27731		},
27732	}
27733	target := &ret
27734	if err := gensupport.DecodeResponse(target, res); err != nil {
27735		return nil, err
27736	}
27737	return ret, nil
27738	// {
27739	//   "description": "Retrieves a list of creative fields, possibly filtered. This method supports paging.",
27740	//   "flatPath": "userprofiles/{profileId}/creativeFields",
27741	//   "httpMethod": "GET",
27742	//   "id": "dfareporting.creativeFields.list",
27743	//   "parameterOrder": [
27744	//     "profileId"
27745	//   ],
27746	//   "parameters": {
27747	//     "advertiserIds": {
27748	//       "description": "Select only creative fields that belong to these advertisers.",
27749	//       "format": "int64",
27750	//       "location": "query",
27751	//       "repeated": true,
27752	//       "type": "string"
27753	//     },
27754	//     "ids": {
27755	//       "description": "Select only creative fields with these IDs.",
27756	//       "format": "int64",
27757	//       "location": "query",
27758	//       "repeated": true,
27759	//       "type": "string"
27760	//     },
27761	//     "maxResults": {
27762	//       "default": "1000",
27763	//       "description": "Maximum number of results to return.",
27764	//       "format": "int32",
27765	//       "location": "query",
27766	//       "maximum": "1000",
27767	//       "minimum": "0",
27768	//       "type": "integer"
27769	//     },
27770	//     "pageToken": {
27771	//       "description": "Value of the nextPageToken from the previous result page.",
27772	//       "location": "query",
27773	//       "type": "string"
27774	//     },
27775	//     "profileId": {
27776	//       "description": "User profile ID associated with this request.",
27777	//       "format": "int64",
27778	//       "location": "path",
27779	//       "required": true,
27780	//       "type": "string"
27781	//     },
27782	//     "searchString": {
27783	//       "description": "Allows searching for creative fields by name or ID. Wildcards (*) are allowed. For example, \"creativefield*2015\" will return creative fields with names like \"creativefield June 2015\", \"creativefield April 2015\", or simply \"creativefield 2015\". Most of the searches also add wild-cards implicitly at the start and the end of the search string. For example, a search string of \"creativefield\" will match creative fields with the name \"my creativefield\", \"creativefield 2015\", or simply \"creativefield\".",
27784	//       "location": "query",
27785	//       "type": "string"
27786	//     },
27787	//     "sortField": {
27788	//       "default": "ID",
27789	//       "description": "Field by which to sort the list.",
27790	//       "enum": [
27791	//         "ID",
27792	//         "NAME"
27793	//       ],
27794	//       "enumDescriptions": [
27795	//         "",
27796	//         ""
27797	//       ],
27798	//       "location": "query",
27799	//       "type": "string"
27800	//     },
27801	//     "sortOrder": {
27802	//       "default": "ASCENDING",
27803	//       "description": "Order of sorted results.",
27804	//       "enum": [
27805	//         "ASCENDING",
27806	//         "DESCENDING"
27807	//       ],
27808	//       "enumDescriptions": [
27809	//         "",
27810	//         ""
27811	//       ],
27812	//       "location": "query",
27813	//       "type": "string"
27814	//     }
27815	//   },
27816	//   "path": "userprofiles/{profileId}/creativeFields",
27817	//   "response": {
27818	//     "$ref": "CreativeFieldsListResponse"
27819	//   },
27820	//   "scopes": [
27821	//     "https://www.googleapis.com/auth/dfatrafficking"
27822	//   ]
27823	// }
27824
27825}
27826
27827// Pages invokes f for each page of results.
27828// A non-nil error returned from f will halt the iteration.
27829// The provided context supersedes any context provided to the Context method.
27830func (c *CreativeFieldsListCall) Pages(ctx context.Context, f func(*CreativeFieldsListResponse) error) error {
27831	c.ctx_ = ctx
27832	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
27833	for {
27834		x, err := c.Do()
27835		if err != nil {
27836			return err
27837		}
27838		if err := f(x); err != nil {
27839			return err
27840		}
27841		if x.NextPageToken == "" {
27842			return nil
27843		}
27844		c.PageToken(x.NextPageToken)
27845	}
27846}
27847
27848// method id "dfareporting.creativeFields.patch":
27849
27850type CreativeFieldsPatchCall struct {
27851	s             *Service
27852	profileId     int64
27853	creativefield *CreativeField
27854	urlParams_    gensupport.URLParams
27855	ctx_          context.Context
27856	header_       http.Header
27857}
27858
27859// Patch: Updates an existing creative field. This method supports patch
27860// semantics.
27861//
27862// - id: CreativeField ID.
27863// - profileId: User profile ID associated with this request.
27864func (r *CreativeFieldsService) Patch(profileId int64, id int64, creativefield *CreativeField) *CreativeFieldsPatchCall {
27865	c := &CreativeFieldsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
27866	c.profileId = profileId
27867	c.urlParams_.Set("id", fmt.Sprint(id))
27868	c.creativefield = creativefield
27869	return c
27870}
27871
27872// Fields allows partial responses to be retrieved. See
27873// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
27874// for more information.
27875func (c *CreativeFieldsPatchCall) Fields(s ...googleapi.Field) *CreativeFieldsPatchCall {
27876	c.urlParams_.Set("fields", googleapi.CombineFields(s))
27877	return c
27878}
27879
27880// Context sets the context to be used in this call's Do method. Any
27881// pending HTTP request will be aborted if the provided context is
27882// canceled.
27883func (c *CreativeFieldsPatchCall) Context(ctx context.Context) *CreativeFieldsPatchCall {
27884	c.ctx_ = ctx
27885	return c
27886}
27887
27888// Header returns an http.Header that can be modified by the caller to
27889// add HTTP headers to the request.
27890func (c *CreativeFieldsPatchCall) Header() http.Header {
27891	if c.header_ == nil {
27892		c.header_ = make(http.Header)
27893	}
27894	return c.header_
27895}
27896
27897func (c *CreativeFieldsPatchCall) doRequest(alt string) (*http.Response, error) {
27898	reqHeaders := make(http.Header)
27899	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
27900	for k, v := range c.header_ {
27901		reqHeaders[k] = v
27902	}
27903	reqHeaders.Set("User-Agent", c.s.userAgent())
27904	var body io.Reader = nil
27905	body, err := googleapi.WithoutDataWrapper.JSONReader(c.creativefield)
27906	if err != nil {
27907		return nil, err
27908	}
27909	reqHeaders.Set("Content-Type", "application/json")
27910	c.urlParams_.Set("alt", alt)
27911	c.urlParams_.Set("prettyPrint", "false")
27912	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeFields")
27913	urls += "?" + c.urlParams_.Encode()
27914	req, err := http.NewRequest("PATCH", urls, body)
27915	if err != nil {
27916		return nil, err
27917	}
27918	req.Header = reqHeaders
27919	googleapi.Expand(req.URL, map[string]string{
27920		"profileId": strconv.FormatInt(c.profileId, 10),
27921	})
27922	return gensupport.SendRequest(c.ctx_, c.s.client, req)
27923}
27924
27925// Do executes the "dfareporting.creativeFields.patch" call.
27926// Exactly one of *CreativeField or error will be non-nil. Any non-2xx
27927// status code is an error. Response headers are in either
27928// *CreativeField.ServerResponse.Header or (if a response was returned
27929// at all) in error.(*googleapi.Error).Header. Use
27930// googleapi.IsNotModified to check whether the returned error was
27931// because http.StatusNotModified was returned.
27932func (c *CreativeFieldsPatchCall) Do(opts ...googleapi.CallOption) (*CreativeField, error) {
27933	gensupport.SetOptions(c.urlParams_, opts...)
27934	res, err := c.doRequest("json")
27935	if res != nil && res.StatusCode == http.StatusNotModified {
27936		if res.Body != nil {
27937			res.Body.Close()
27938		}
27939		return nil, &googleapi.Error{
27940			Code:   res.StatusCode,
27941			Header: res.Header,
27942		}
27943	}
27944	if err != nil {
27945		return nil, err
27946	}
27947	defer googleapi.CloseBody(res)
27948	if err := googleapi.CheckResponse(res); err != nil {
27949		return nil, err
27950	}
27951	ret := &CreativeField{
27952		ServerResponse: googleapi.ServerResponse{
27953			Header:         res.Header,
27954			HTTPStatusCode: res.StatusCode,
27955		},
27956	}
27957	target := &ret
27958	if err := gensupport.DecodeResponse(target, res); err != nil {
27959		return nil, err
27960	}
27961	return ret, nil
27962	// {
27963	//   "description": "Updates an existing creative field. This method supports patch semantics.",
27964	//   "flatPath": "userprofiles/{profileId}/creativeFields",
27965	//   "httpMethod": "PATCH",
27966	//   "id": "dfareporting.creativeFields.patch",
27967	//   "parameterOrder": [
27968	//     "profileId",
27969	//     "id"
27970	//   ],
27971	//   "parameters": {
27972	//     "id": {
27973	//       "description": "CreativeField ID.",
27974	//       "format": "int64",
27975	//       "location": "query",
27976	//       "required": true,
27977	//       "type": "string"
27978	//     },
27979	//     "profileId": {
27980	//       "description": "User profile ID associated with this request.",
27981	//       "format": "int64",
27982	//       "location": "path",
27983	//       "required": true,
27984	//       "type": "string"
27985	//     }
27986	//   },
27987	//   "path": "userprofiles/{profileId}/creativeFields",
27988	//   "request": {
27989	//     "$ref": "CreativeField"
27990	//   },
27991	//   "response": {
27992	//     "$ref": "CreativeField"
27993	//   },
27994	//   "scopes": [
27995	//     "https://www.googleapis.com/auth/dfatrafficking"
27996	//   ]
27997	// }
27998
27999}
28000
28001// method id "dfareporting.creativeFields.update":
28002
28003type CreativeFieldsUpdateCall struct {
28004	s             *Service
28005	profileId     int64
28006	creativefield *CreativeField
28007	urlParams_    gensupport.URLParams
28008	ctx_          context.Context
28009	header_       http.Header
28010}
28011
28012// Update: Updates an existing creative field.
28013//
28014// - profileId: User profile ID associated with this request.
28015func (r *CreativeFieldsService) Update(profileId int64, creativefield *CreativeField) *CreativeFieldsUpdateCall {
28016	c := &CreativeFieldsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
28017	c.profileId = profileId
28018	c.creativefield = creativefield
28019	return c
28020}
28021
28022// Fields allows partial responses to be retrieved. See
28023// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
28024// for more information.
28025func (c *CreativeFieldsUpdateCall) Fields(s ...googleapi.Field) *CreativeFieldsUpdateCall {
28026	c.urlParams_.Set("fields", googleapi.CombineFields(s))
28027	return c
28028}
28029
28030// Context sets the context to be used in this call's Do method. Any
28031// pending HTTP request will be aborted if the provided context is
28032// canceled.
28033func (c *CreativeFieldsUpdateCall) Context(ctx context.Context) *CreativeFieldsUpdateCall {
28034	c.ctx_ = ctx
28035	return c
28036}
28037
28038// Header returns an http.Header that can be modified by the caller to
28039// add HTTP headers to the request.
28040func (c *CreativeFieldsUpdateCall) Header() http.Header {
28041	if c.header_ == nil {
28042		c.header_ = make(http.Header)
28043	}
28044	return c.header_
28045}
28046
28047func (c *CreativeFieldsUpdateCall) doRequest(alt string) (*http.Response, error) {
28048	reqHeaders := make(http.Header)
28049	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
28050	for k, v := range c.header_ {
28051		reqHeaders[k] = v
28052	}
28053	reqHeaders.Set("User-Agent", c.s.userAgent())
28054	var body io.Reader = nil
28055	body, err := googleapi.WithoutDataWrapper.JSONReader(c.creativefield)
28056	if err != nil {
28057		return nil, err
28058	}
28059	reqHeaders.Set("Content-Type", "application/json")
28060	c.urlParams_.Set("alt", alt)
28061	c.urlParams_.Set("prettyPrint", "false")
28062	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeFields")
28063	urls += "?" + c.urlParams_.Encode()
28064	req, err := http.NewRequest("PUT", urls, body)
28065	if err != nil {
28066		return nil, err
28067	}
28068	req.Header = reqHeaders
28069	googleapi.Expand(req.URL, map[string]string{
28070		"profileId": strconv.FormatInt(c.profileId, 10),
28071	})
28072	return gensupport.SendRequest(c.ctx_, c.s.client, req)
28073}
28074
28075// Do executes the "dfareporting.creativeFields.update" call.
28076// Exactly one of *CreativeField or error will be non-nil. Any non-2xx
28077// status code is an error. Response headers are in either
28078// *CreativeField.ServerResponse.Header or (if a response was returned
28079// at all) in error.(*googleapi.Error).Header. Use
28080// googleapi.IsNotModified to check whether the returned error was
28081// because http.StatusNotModified was returned.
28082func (c *CreativeFieldsUpdateCall) Do(opts ...googleapi.CallOption) (*CreativeField, error) {
28083	gensupport.SetOptions(c.urlParams_, opts...)
28084	res, err := c.doRequest("json")
28085	if res != nil && res.StatusCode == http.StatusNotModified {
28086		if res.Body != nil {
28087			res.Body.Close()
28088		}
28089		return nil, &googleapi.Error{
28090			Code:   res.StatusCode,
28091			Header: res.Header,
28092		}
28093	}
28094	if err != nil {
28095		return nil, err
28096	}
28097	defer googleapi.CloseBody(res)
28098	if err := googleapi.CheckResponse(res); err != nil {
28099		return nil, err
28100	}
28101	ret := &CreativeField{
28102		ServerResponse: googleapi.ServerResponse{
28103			Header:         res.Header,
28104			HTTPStatusCode: res.StatusCode,
28105		},
28106	}
28107	target := &ret
28108	if err := gensupport.DecodeResponse(target, res); err != nil {
28109		return nil, err
28110	}
28111	return ret, nil
28112	// {
28113	//   "description": "Updates an existing creative field.",
28114	//   "flatPath": "userprofiles/{profileId}/creativeFields",
28115	//   "httpMethod": "PUT",
28116	//   "id": "dfareporting.creativeFields.update",
28117	//   "parameterOrder": [
28118	//     "profileId"
28119	//   ],
28120	//   "parameters": {
28121	//     "profileId": {
28122	//       "description": "User profile ID associated with this request.",
28123	//       "format": "int64",
28124	//       "location": "path",
28125	//       "required": true,
28126	//       "type": "string"
28127	//     }
28128	//   },
28129	//   "path": "userprofiles/{profileId}/creativeFields",
28130	//   "request": {
28131	//     "$ref": "CreativeField"
28132	//   },
28133	//   "response": {
28134	//     "$ref": "CreativeField"
28135	//   },
28136	//   "scopes": [
28137	//     "https://www.googleapis.com/auth/dfatrafficking"
28138	//   ]
28139	// }
28140
28141}
28142
28143// method id "dfareporting.creativeGroups.get":
28144
28145type CreativeGroupsGetCall struct {
28146	s            *Service
28147	profileId    int64
28148	id           int64
28149	urlParams_   gensupport.URLParams
28150	ifNoneMatch_ string
28151	ctx_         context.Context
28152	header_      http.Header
28153}
28154
28155// Get: Gets one creative group by ID.
28156//
28157// - id: Creative group ID.
28158// - profileId: User profile ID associated with this request.
28159func (r *CreativeGroupsService) Get(profileId int64, id int64) *CreativeGroupsGetCall {
28160	c := &CreativeGroupsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
28161	c.profileId = profileId
28162	c.id = id
28163	return c
28164}
28165
28166// Fields allows partial responses to be retrieved. See
28167// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
28168// for more information.
28169func (c *CreativeGroupsGetCall) Fields(s ...googleapi.Field) *CreativeGroupsGetCall {
28170	c.urlParams_.Set("fields", googleapi.CombineFields(s))
28171	return c
28172}
28173
28174// IfNoneMatch sets the optional parameter which makes the operation
28175// fail if the object's ETag matches the given value. This is useful for
28176// getting updates only after the object has changed since the last
28177// request. Use googleapi.IsNotModified to check whether the response
28178// error from Do is the result of In-None-Match.
28179func (c *CreativeGroupsGetCall) IfNoneMatch(entityTag string) *CreativeGroupsGetCall {
28180	c.ifNoneMatch_ = entityTag
28181	return c
28182}
28183
28184// Context sets the context to be used in this call's Do method. Any
28185// pending HTTP request will be aborted if the provided context is
28186// canceled.
28187func (c *CreativeGroupsGetCall) Context(ctx context.Context) *CreativeGroupsGetCall {
28188	c.ctx_ = ctx
28189	return c
28190}
28191
28192// Header returns an http.Header that can be modified by the caller to
28193// add HTTP headers to the request.
28194func (c *CreativeGroupsGetCall) Header() http.Header {
28195	if c.header_ == nil {
28196		c.header_ = make(http.Header)
28197	}
28198	return c.header_
28199}
28200
28201func (c *CreativeGroupsGetCall) doRequest(alt string) (*http.Response, error) {
28202	reqHeaders := make(http.Header)
28203	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
28204	for k, v := range c.header_ {
28205		reqHeaders[k] = v
28206	}
28207	reqHeaders.Set("User-Agent", c.s.userAgent())
28208	if c.ifNoneMatch_ != "" {
28209		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
28210	}
28211	var body io.Reader = nil
28212	c.urlParams_.Set("alt", alt)
28213	c.urlParams_.Set("prettyPrint", "false")
28214	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeGroups/{id}")
28215	urls += "?" + c.urlParams_.Encode()
28216	req, err := http.NewRequest("GET", urls, body)
28217	if err != nil {
28218		return nil, err
28219	}
28220	req.Header = reqHeaders
28221	googleapi.Expand(req.URL, map[string]string{
28222		"profileId": strconv.FormatInt(c.profileId, 10),
28223		"id":        strconv.FormatInt(c.id, 10),
28224	})
28225	return gensupport.SendRequest(c.ctx_, c.s.client, req)
28226}
28227
28228// Do executes the "dfareporting.creativeGroups.get" call.
28229// Exactly one of *CreativeGroup or error will be non-nil. Any non-2xx
28230// status code is an error. Response headers are in either
28231// *CreativeGroup.ServerResponse.Header or (if a response was returned
28232// at all) in error.(*googleapi.Error).Header. Use
28233// googleapi.IsNotModified to check whether the returned error was
28234// because http.StatusNotModified was returned.
28235func (c *CreativeGroupsGetCall) Do(opts ...googleapi.CallOption) (*CreativeGroup, error) {
28236	gensupport.SetOptions(c.urlParams_, opts...)
28237	res, err := c.doRequest("json")
28238	if res != nil && res.StatusCode == http.StatusNotModified {
28239		if res.Body != nil {
28240			res.Body.Close()
28241		}
28242		return nil, &googleapi.Error{
28243			Code:   res.StatusCode,
28244			Header: res.Header,
28245		}
28246	}
28247	if err != nil {
28248		return nil, err
28249	}
28250	defer googleapi.CloseBody(res)
28251	if err := googleapi.CheckResponse(res); err != nil {
28252		return nil, err
28253	}
28254	ret := &CreativeGroup{
28255		ServerResponse: googleapi.ServerResponse{
28256			Header:         res.Header,
28257			HTTPStatusCode: res.StatusCode,
28258		},
28259	}
28260	target := &ret
28261	if err := gensupport.DecodeResponse(target, res); err != nil {
28262		return nil, err
28263	}
28264	return ret, nil
28265	// {
28266	//   "description": "Gets one creative group by ID.",
28267	//   "flatPath": "userprofiles/{profileId}/creativeGroups/{id}",
28268	//   "httpMethod": "GET",
28269	//   "id": "dfareporting.creativeGroups.get",
28270	//   "parameterOrder": [
28271	//     "profileId",
28272	//     "id"
28273	//   ],
28274	//   "parameters": {
28275	//     "id": {
28276	//       "description": "Creative group ID.",
28277	//       "format": "int64",
28278	//       "location": "path",
28279	//       "required": true,
28280	//       "type": "string"
28281	//     },
28282	//     "profileId": {
28283	//       "description": "User profile ID associated with this request.",
28284	//       "format": "int64",
28285	//       "location": "path",
28286	//       "required": true,
28287	//       "type": "string"
28288	//     }
28289	//   },
28290	//   "path": "userprofiles/{profileId}/creativeGroups/{id}",
28291	//   "response": {
28292	//     "$ref": "CreativeGroup"
28293	//   },
28294	//   "scopes": [
28295	//     "https://www.googleapis.com/auth/dfatrafficking"
28296	//   ]
28297	// }
28298
28299}
28300
28301// method id "dfareporting.creativeGroups.insert":
28302
28303type CreativeGroupsInsertCall struct {
28304	s             *Service
28305	profileId     int64
28306	creativegroup *CreativeGroup
28307	urlParams_    gensupport.URLParams
28308	ctx_          context.Context
28309	header_       http.Header
28310}
28311
28312// Insert: Inserts a new creative group.
28313//
28314// - profileId: User profile ID associated with this request.
28315func (r *CreativeGroupsService) Insert(profileId int64, creativegroup *CreativeGroup) *CreativeGroupsInsertCall {
28316	c := &CreativeGroupsInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
28317	c.profileId = profileId
28318	c.creativegroup = creativegroup
28319	return c
28320}
28321
28322// Fields allows partial responses to be retrieved. See
28323// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
28324// for more information.
28325func (c *CreativeGroupsInsertCall) Fields(s ...googleapi.Field) *CreativeGroupsInsertCall {
28326	c.urlParams_.Set("fields", googleapi.CombineFields(s))
28327	return c
28328}
28329
28330// Context sets the context to be used in this call's Do method. Any
28331// pending HTTP request will be aborted if the provided context is
28332// canceled.
28333func (c *CreativeGroupsInsertCall) Context(ctx context.Context) *CreativeGroupsInsertCall {
28334	c.ctx_ = ctx
28335	return c
28336}
28337
28338// Header returns an http.Header that can be modified by the caller to
28339// add HTTP headers to the request.
28340func (c *CreativeGroupsInsertCall) Header() http.Header {
28341	if c.header_ == nil {
28342		c.header_ = make(http.Header)
28343	}
28344	return c.header_
28345}
28346
28347func (c *CreativeGroupsInsertCall) doRequest(alt string) (*http.Response, error) {
28348	reqHeaders := make(http.Header)
28349	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
28350	for k, v := range c.header_ {
28351		reqHeaders[k] = v
28352	}
28353	reqHeaders.Set("User-Agent", c.s.userAgent())
28354	var body io.Reader = nil
28355	body, err := googleapi.WithoutDataWrapper.JSONReader(c.creativegroup)
28356	if err != nil {
28357		return nil, err
28358	}
28359	reqHeaders.Set("Content-Type", "application/json")
28360	c.urlParams_.Set("alt", alt)
28361	c.urlParams_.Set("prettyPrint", "false")
28362	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeGroups")
28363	urls += "?" + c.urlParams_.Encode()
28364	req, err := http.NewRequest("POST", urls, body)
28365	if err != nil {
28366		return nil, err
28367	}
28368	req.Header = reqHeaders
28369	googleapi.Expand(req.URL, map[string]string{
28370		"profileId": strconv.FormatInt(c.profileId, 10),
28371	})
28372	return gensupport.SendRequest(c.ctx_, c.s.client, req)
28373}
28374
28375// Do executes the "dfareporting.creativeGroups.insert" call.
28376// Exactly one of *CreativeGroup or error will be non-nil. Any non-2xx
28377// status code is an error. Response headers are in either
28378// *CreativeGroup.ServerResponse.Header or (if a response was returned
28379// at all) in error.(*googleapi.Error).Header. Use
28380// googleapi.IsNotModified to check whether the returned error was
28381// because http.StatusNotModified was returned.
28382func (c *CreativeGroupsInsertCall) Do(opts ...googleapi.CallOption) (*CreativeGroup, error) {
28383	gensupport.SetOptions(c.urlParams_, opts...)
28384	res, err := c.doRequest("json")
28385	if res != nil && res.StatusCode == http.StatusNotModified {
28386		if res.Body != nil {
28387			res.Body.Close()
28388		}
28389		return nil, &googleapi.Error{
28390			Code:   res.StatusCode,
28391			Header: res.Header,
28392		}
28393	}
28394	if err != nil {
28395		return nil, err
28396	}
28397	defer googleapi.CloseBody(res)
28398	if err := googleapi.CheckResponse(res); err != nil {
28399		return nil, err
28400	}
28401	ret := &CreativeGroup{
28402		ServerResponse: googleapi.ServerResponse{
28403			Header:         res.Header,
28404			HTTPStatusCode: res.StatusCode,
28405		},
28406	}
28407	target := &ret
28408	if err := gensupport.DecodeResponse(target, res); err != nil {
28409		return nil, err
28410	}
28411	return ret, nil
28412	// {
28413	//   "description": "Inserts a new creative group.",
28414	//   "flatPath": "userprofiles/{profileId}/creativeGroups",
28415	//   "httpMethod": "POST",
28416	//   "id": "dfareporting.creativeGroups.insert",
28417	//   "parameterOrder": [
28418	//     "profileId"
28419	//   ],
28420	//   "parameters": {
28421	//     "profileId": {
28422	//       "description": "User profile ID associated with this request.",
28423	//       "format": "int64",
28424	//       "location": "path",
28425	//       "required": true,
28426	//       "type": "string"
28427	//     }
28428	//   },
28429	//   "path": "userprofiles/{profileId}/creativeGroups",
28430	//   "request": {
28431	//     "$ref": "CreativeGroup"
28432	//   },
28433	//   "response": {
28434	//     "$ref": "CreativeGroup"
28435	//   },
28436	//   "scopes": [
28437	//     "https://www.googleapis.com/auth/dfatrafficking"
28438	//   ]
28439	// }
28440
28441}
28442
28443// method id "dfareporting.creativeGroups.list":
28444
28445type CreativeGroupsListCall struct {
28446	s            *Service
28447	profileId    int64
28448	urlParams_   gensupport.URLParams
28449	ifNoneMatch_ string
28450	ctx_         context.Context
28451	header_      http.Header
28452}
28453
28454// List: Retrieves a list of creative groups, possibly filtered. This
28455// method supports paging.
28456//
28457// - profileId: User profile ID associated with this request.
28458func (r *CreativeGroupsService) List(profileId int64) *CreativeGroupsListCall {
28459	c := &CreativeGroupsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
28460	c.profileId = profileId
28461	return c
28462}
28463
28464// AdvertiserIds sets the optional parameter "advertiserIds": Select
28465// only creative groups that belong to these advertisers.
28466func (c *CreativeGroupsListCall) AdvertiserIds(advertiserIds ...int64) *CreativeGroupsListCall {
28467	var advertiserIds_ []string
28468	for _, v := range advertiserIds {
28469		advertiserIds_ = append(advertiserIds_, fmt.Sprint(v))
28470	}
28471	c.urlParams_.SetMulti("advertiserIds", advertiserIds_)
28472	return c
28473}
28474
28475// GroupNumber sets the optional parameter "groupNumber": Select only
28476// creative groups that belong to this subgroup.
28477func (c *CreativeGroupsListCall) GroupNumber(groupNumber int64) *CreativeGroupsListCall {
28478	c.urlParams_.Set("groupNumber", fmt.Sprint(groupNumber))
28479	return c
28480}
28481
28482// Ids sets the optional parameter "ids": Select only creative groups
28483// with these IDs.
28484func (c *CreativeGroupsListCall) Ids(ids ...int64) *CreativeGroupsListCall {
28485	var ids_ []string
28486	for _, v := range ids {
28487		ids_ = append(ids_, fmt.Sprint(v))
28488	}
28489	c.urlParams_.SetMulti("ids", ids_)
28490	return c
28491}
28492
28493// MaxResults sets the optional parameter "maxResults": Maximum number
28494// of results to return.
28495func (c *CreativeGroupsListCall) MaxResults(maxResults int64) *CreativeGroupsListCall {
28496	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
28497	return c
28498}
28499
28500// PageToken sets the optional parameter "pageToken": Value of the
28501// nextPageToken from the previous result page.
28502func (c *CreativeGroupsListCall) PageToken(pageToken string) *CreativeGroupsListCall {
28503	c.urlParams_.Set("pageToken", pageToken)
28504	return c
28505}
28506
28507// SearchString sets the optional parameter "searchString": Allows
28508// searching for creative groups by name or ID. Wildcards (*) are
28509// allowed. For example, "creativegroup*2015" will return creative
28510// groups with names like "creativegroup June 2015", "creativegroup
28511// April 2015", or simply "creativegroup 2015". Most of the searches
28512// also add wild-cards implicitly at the start and the end of the search
28513// string. For example, a search string of "creativegroup" will match
28514// creative groups with the name "my creativegroup", "creativegroup
28515// 2015", or simply "creativegroup".
28516func (c *CreativeGroupsListCall) SearchString(searchString string) *CreativeGroupsListCall {
28517	c.urlParams_.Set("searchString", searchString)
28518	return c
28519}
28520
28521// SortField sets the optional parameter "sortField": Field by which to
28522// sort the list.
28523//
28524// Possible values:
28525//   "ID" (default)
28526//   "NAME"
28527func (c *CreativeGroupsListCall) SortField(sortField string) *CreativeGroupsListCall {
28528	c.urlParams_.Set("sortField", sortField)
28529	return c
28530}
28531
28532// SortOrder sets the optional parameter "sortOrder": Order of sorted
28533// results.
28534//
28535// Possible values:
28536//   "ASCENDING" (default)
28537//   "DESCENDING"
28538func (c *CreativeGroupsListCall) SortOrder(sortOrder string) *CreativeGroupsListCall {
28539	c.urlParams_.Set("sortOrder", sortOrder)
28540	return c
28541}
28542
28543// Fields allows partial responses to be retrieved. See
28544// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
28545// for more information.
28546func (c *CreativeGroupsListCall) Fields(s ...googleapi.Field) *CreativeGroupsListCall {
28547	c.urlParams_.Set("fields", googleapi.CombineFields(s))
28548	return c
28549}
28550
28551// IfNoneMatch sets the optional parameter which makes the operation
28552// fail if the object's ETag matches the given value. This is useful for
28553// getting updates only after the object has changed since the last
28554// request. Use googleapi.IsNotModified to check whether the response
28555// error from Do is the result of In-None-Match.
28556func (c *CreativeGroupsListCall) IfNoneMatch(entityTag string) *CreativeGroupsListCall {
28557	c.ifNoneMatch_ = entityTag
28558	return c
28559}
28560
28561// Context sets the context to be used in this call's Do method. Any
28562// pending HTTP request will be aborted if the provided context is
28563// canceled.
28564func (c *CreativeGroupsListCall) Context(ctx context.Context) *CreativeGroupsListCall {
28565	c.ctx_ = ctx
28566	return c
28567}
28568
28569// Header returns an http.Header that can be modified by the caller to
28570// add HTTP headers to the request.
28571func (c *CreativeGroupsListCall) Header() http.Header {
28572	if c.header_ == nil {
28573		c.header_ = make(http.Header)
28574	}
28575	return c.header_
28576}
28577
28578func (c *CreativeGroupsListCall) doRequest(alt string) (*http.Response, error) {
28579	reqHeaders := make(http.Header)
28580	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
28581	for k, v := range c.header_ {
28582		reqHeaders[k] = v
28583	}
28584	reqHeaders.Set("User-Agent", c.s.userAgent())
28585	if c.ifNoneMatch_ != "" {
28586		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
28587	}
28588	var body io.Reader = nil
28589	c.urlParams_.Set("alt", alt)
28590	c.urlParams_.Set("prettyPrint", "false")
28591	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeGroups")
28592	urls += "?" + c.urlParams_.Encode()
28593	req, err := http.NewRequest("GET", urls, body)
28594	if err != nil {
28595		return nil, err
28596	}
28597	req.Header = reqHeaders
28598	googleapi.Expand(req.URL, map[string]string{
28599		"profileId": strconv.FormatInt(c.profileId, 10),
28600	})
28601	return gensupport.SendRequest(c.ctx_, c.s.client, req)
28602}
28603
28604// Do executes the "dfareporting.creativeGroups.list" call.
28605// Exactly one of *CreativeGroupsListResponse or error will be non-nil.
28606// Any non-2xx status code is an error. Response headers are in either
28607// *CreativeGroupsListResponse.ServerResponse.Header or (if a response
28608// was returned at all) in error.(*googleapi.Error).Header. Use
28609// googleapi.IsNotModified to check whether the returned error was
28610// because http.StatusNotModified was returned.
28611func (c *CreativeGroupsListCall) Do(opts ...googleapi.CallOption) (*CreativeGroupsListResponse, error) {
28612	gensupport.SetOptions(c.urlParams_, opts...)
28613	res, err := c.doRequest("json")
28614	if res != nil && res.StatusCode == http.StatusNotModified {
28615		if res.Body != nil {
28616			res.Body.Close()
28617		}
28618		return nil, &googleapi.Error{
28619			Code:   res.StatusCode,
28620			Header: res.Header,
28621		}
28622	}
28623	if err != nil {
28624		return nil, err
28625	}
28626	defer googleapi.CloseBody(res)
28627	if err := googleapi.CheckResponse(res); err != nil {
28628		return nil, err
28629	}
28630	ret := &CreativeGroupsListResponse{
28631		ServerResponse: googleapi.ServerResponse{
28632			Header:         res.Header,
28633			HTTPStatusCode: res.StatusCode,
28634		},
28635	}
28636	target := &ret
28637	if err := gensupport.DecodeResponse(target, res); err != nil {
28638		return nil, err
28639	}
28640	return ret, nil
28641	// {
28642	//   "description": "Retrieves a list of creative groups, possibly filtered. This method supports paging.",
28643	//   "flatPath": "userprofiles/{profileId}/creativeGroups",
28644	//   "httpMethod": "GET",
28645	//   "id": "dfareporting.creativeGroups.list",
28646	//   "parameterOrder": [
28647	//     "profileId"
28648	//   ],
28649	//   "parameters": {
28650	//     "advertiserIds": {
28651	//       "description": "Select only creative groups that belong to these advertisers.",
28652	//       "format": "int64",
28653	//       "location": "query",
28654	//       "repeated": true,
28655	//       "type": "string"
28656	//     },
28657	//     "groupNumber": {
28658	//       "description": "Select only creative groups that belong to this subgroup.",
28659	//       "format": "int32",
28660	//       "location": "query",
28661	//       "maximum": "2",
28662	//       "minimum": "1",
28663	//       "type": "integer"
28664	//     },
28665	//     "ids": {
28666	//       "description": "Select only creative groups with these IDs.",
28667	//       "format": "int64",
28668	//       "location": "query",
28669	//       "repeated": true,
28670	//       "type": "string"
28671	//     },
28672	//     "maxResults": {
28673	//       "default": "1000",
28674	//       "description": "Maximum number of results to return.",
28675	//       "format": "int32",
28676	//       "location": "query",
28677	//       "maximum": "1000",
28678	//       "minimum": "0",
28679	//       "type": "integer"
28680	//     },
28681	//     "pageToken": {
28682	//       "description": "Value of the nextPageToken from the previous result page.",
28683	//       "location": "query",
28684	//       "type": "string"
28685	//     },
28686	//     "profileId": {
28687	//       "description": "User profile ID associated with this request.",
28688	//       "format": "int64",
28689	//       "location": "path",
28690	//       "required": true,
28691	//       "type": "string"
28692	//     },
28693	//     "searchString": {
28694	//       "description": "Allows searching for creative groups by name or ID. Wildcards (*) are allowed. For example, \"creativegroup*2015\" will return creative groups with names like \"creativegroup June 2015\", \"creativegroup April 2015\", or simply \"creativegroup 2015\". Most of the searches also add wild-cards implicitly at the start and the end of the search string. For example, a search string of \"creativegroup\" will match creative groups with the name \"my creativegroup\", \"creativegroup 2015\", or simply \"creativegroup\".",
28695	//       "location": "query",
28696	//       "type": "string"
28697	//     },
28698	//     "sortField": {
28699	//       "default": "ID",
28700	//       "description": "Field by which to sort the list.",
28701	//       "enum": [
28702	//         "ID",
28703	//         "NAME"
28704	//       ],
28705	//       "enumDescriptions": [
28706	//         "",
28707	//         ""
28708	//       ],
28709	//       "location": "query",
28710	//       "type": "string"
28711	//     },
28712	//     "sortOrder": {
28713	//       "default": "ASCENDING",
28714	//       "description": "Order of sorted results.",
28715	//       "enum": [
28716	//         "ASCENDING",
28717	//         "DESCENDING"
28718	//       ],
28719	//       "enumDescriptions": [
28720	//         "",
28721	//         ""
28722	//       ],
28723	//       "location": "query",
28724	//       "type": "string"
28725	//     }
28726	//   },
28727	//   "path": "userprofiles/{profileId}/creativeGroups",
28728	//   "response": {
28729	//     "$ref": "CreativeGroupsListResponse"
28730	//   },
28731	//   "scopes": [
28732	//     "https://www.googleapis.com/auth/dfatrafficking"
28733	//   ]
28734	// }
28735
28736}
28737
28738// Pages invokes f for each page of results.
28739// A non-nil error returned from f will halt the iteration.
28740// The provided context supersedes any context provided to the Context method.
28741func (c *CreativeGroupsListCall) Pages(ctx context.Context, f func(*CreativeGroupsListResponse) error) error {
28742	c.ctx_ = ctx
28743	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
28744	for {
28745		x, err := c.Do()
28746		if err != nil {
28747			return err
28748		}
28749		if err := f(x); err != nil {
28750			return err
28751		}
28752		if x.NextPageToken == "" {
28753			return nil
28754		}
28755		c.PageToken(x.NextPageToken)
28756	}
28757}
28758
28759// method id "dfareporting.creativeGroups.patch":
28760
28761type CreativeGroupsPatchCall struct {
28762	s             *Service
28763	profileId     int64
28764	creativegroup *CreativeGroup
28765	urlParams_    gensupport.URLParams
28766	ctx_          context.Context
28767	header_       http.Header
28768}
28769
28770// Patch: Updates an existing creative group. This method supports patch
28771// semantics.
28772//
28773// - id: CreativeGroup ID.
28774// - profileId: User profile ID associated with this request.
28775func (r *CreativeGroupsService) Patch(profileId int64, id int64, creativegroup *CreativeGroup) *CreativeGroupsPatchCall {
28776	c := &CreativeGroupsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
28777	c.profileId = profileId
28778	c.urlParams_.Set("id", fmt.Sprint(id))
28779	c.creativegroup = creativegroup
28780	return c
28781}
28782
28783// Fields allows partial responses to be retrieved. See
28784// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
28785// for more information.
28786func (c *CreativeGroupsPatchCall) Fields(s ...googleapi.Field) *CreativeGroupsPatchCall {
28787	c.urlParams_.Set("fields", googleapi.CombineFields(s))
28788	return c
28789}
28790
28791// Context sets the context to be used in this call's Do method. Any
28792// pending HTTP request will be aborted if the provided context is
28793// canceled.
28794func (c *CreativeGroupsPatchCall) Context(ctx context.Context) *CreativeGroupsPatchCall {
28795	c.ctx_ = ctx
28796	return c
28797}
28798
28799// Header returns an http.Header that can be modified by the caller to
28800// add HTTP headers to the request.
28801func (c *CreativeGroupsPatchCall) Header() http.Header {
28802	if c.header_ == nil {
28803		c.header_ = make(http.Header)
28804	}
28805	return c.header_
28806}
28807
28808func (c *CreativeGroupsPatchCall) doRequest(alt string) (*http.Response, error) {
28809	reqHeaders := make(http.Header)
28810	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
28811	for k, v := range c.header_ {
28812		reqHeaders[k] = v
28813	}
28814	reqHeaders.Set("User-Agent", c.s.userAgent())
28815	var body io.Reader = nil
28816	body, err := googleapi.WithoutDataWrapper.JSONReader(c.creativegroup)
28817	if err != nil {
28818		return nil, err
28819	}
28820	reqHeaders.Set("Content-Type", "application/json")
28821	c.urlParams_.Set("alt", alt)
28822	c.urlParams_.Set("prettyPrint", "false")
28823	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeGroups")
28824	urls += "?" + c.urlParams_.Encode()
28825	req, err := http.NewRequest("PATCH", urls, body)
28826	if err != nil {
28827		return nil, err
28828	}
28829	req.Header = reqHeaders
28830	googleapi.Expand(req.URL, map[string]string{
28831		"profileId": strconv.FormatInt(c.profileId, 10),
28832	})
28833	return gensupport.SendRequest(c.ctx_, c.s.client, req)
28834}
28835
28836// Do executes the "dfareporting.creativeGroups.patch" call.
28837// Exactly one of *CreativeGroup or error will be non-nil. Any non-2xx
28838// status code is an error. Response headers are in either
28839// *CreativeGroup.ServerResponse.Header or (if a response was returned
28840// at all) in error.(*googleapi.Error).Header. Use
28841// googleapi.IsNotModified to check whether the returned error was
28842// because http.StatusNotModified was returned.
28843func (c *CreativeGroupsPatchCall) Do(opts ...googleapi.CallOption) (*CreativeGroup, error) {
28844	gensupport.SetOptions(c.urlParams_, opts...)
28845	res, err := c.doRequest("json")
28846	if res != nil && res.StatusCode == http.StatusNotModified {
28847		if res.Body != nil {
28848			res.Body.Close()
28849		}
28850		return nil, &googleapi.Error{
28851			Code:   res.StatusCode,
28852			Header: res.Header,
28853		}
28854	}
28855	if err != nil {
28856		return nil, err
28857	}
28858	defer googleapi.CloseBody(res)
28859	if err := googleapi.CheckResponse(res); err != nil {
28860		return nil, err
28861	}
28862	ret := &CreativeGroup{
28863		ServerResponse: googleapi.ServerResponse{
28864			Header:         res.Header,
28865			HTTPStatusCode: res.StatusCode,
28866		},
28867	}
28868	target := &ret
28869	if err := gensupport.DecodeResponse(target, res); err != nil {
28870		return nil, err
28871	}
28872	return ret, nil
28873	// {
28874	//   "description": "Updates an existing creative group. This method supports patch semantics.",
28875	//   "flatPath": "userprofiles/{profileId}/creativeGroups",
28876	//   "httpMethod": "PATCH",
28877	//   "id": "dfareporting.creativeGroups.patch",
28878	//   "parameterOrder": [
28879	//     "profileId",
28880	//     "id"
28881	//   ],
28882	//   "parameters": {
28883	//     "id": {
28884	//       "description": "CreativeGroup ID.",
28885	//       "format": "int64",
28886	//       "location": "query",
28887	//       "required": true,
28888	//       "type": "string"
28889	//     },
28890	//     "profileId": {
28891	//       "description": "User profile ID associated with this request.",
28892	//       "format": "int64",
28893	//       "location": "path",
28894	//       "required": true,
28895	//       "type": "string"
28896	//     }
28897	//   },
28898	//   "path": "userprofiles/{profileId}/creativeGroups",
28899	//   "request": {
28900	//     "$ref": "CreativeGroup"
28901	//   },
28902	//   "response": {
28903	//     "$ref": "CreativeGroup"
28904	//   },
28905	//   "scopes": [
28906	//     "https://www.googleapis.com/auth/dfatrafficking"
28907	//   ]
28908	// }
28909
28910}
28911
28912// method id "dfareporting.creativeGroups.update":
28913
28914type CreativeGroupsUpdateCall struct {
28915	s             *Service
28916	profileId     int64
28917	creativegroup *CreativeGroup
28918	urlParams_    gensupport.URLParams
28919	ctx_          context.Context
28920	header_       http.Header
28921}
28922
28923// Update: Updates an existing creative group.
28924//
28925// - profileId: User profile ID associated with this request.
28926func (r *CreativeGroupsService) Update(profileId int64, creativegroup *CreativeGroup) *CreativeGroupsUpdateCall {
28927	c := &CreativeGroupsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
28928	c.profileId = profileId
28929	c.creativegroup = creativegroup
28930	return c
28931}
28932
28933// Fields allows partial responses to be retrieved. See
28934// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
28935// for more information.
28936func (c *CreativeGroupsUpdateCall) Fields(s ...googleapi.Field) *CreativeGroupsUpdateCall {
28937	c.urlParams_.Set("fields", googleapi.CombineFields(s))
28938	return c
28939}
28940
28941// Context sets the context to be used in this call's Do method. Any
28942// pending HTTP request will be aborted if the provided context is
28943// canceled.
28944func (c *CreativeGroupsUpdateCall) Context(ctx context.Context) *CreativeGroupsUpdateCall {
28945	c.ctx_ = ctx
28946	return c
28947}
28948
28949// Header returns an http.Header that can be modified by the caller to
28950// add HTTP headers to the request.
28951func (c *CreativeGroupsUpdateCall) Header() http.Header {
28952	if c.header_ == nil {
28953		c.header_ = make(http.Header)
28954	}
28955	return c.header_
28956}
28957
28958func (c *CreativeGroupsUpdateCall) doRequest(alt string) (*http.Response, error) {
28959	reqHeaders := make(http.Header)
28960	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
28961	for k, v := range c.header_ {
28962		reqHeaders[k] = v
28963	}
28964	reqHeaders.Set("User-Agent", c.s.userAgent())
28965	var body io.Reader = nil
28966	body, err := googleapi.WithoutDataWrapper.JSONReader(c.creativegroup)
28967	if err != nil {
28968		return nil, err
28969	}
28970	reqHeaders.Set("Content-Type", "application/json")
28971	c.urlParams_.Set("alt", alt)
28972	c.urlParams_.Set("prettyPrint", "false")
28973	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creativeGroups")
28974	urls += "?" + c.urlParams_.Encode()
28975	req, err := http.NewRequest("PUT", urls, body)
28976	if err != nil {
28977		return nil, err
28978	}
28979	req.Header = reqHeaders
28980	googleapi.Expand(req.URL, map[string]string{
28981		"profileId": strconv.FormatInt(c.profileId, 10),
28982	})
28983	return gensupport.SendRequest(c.ctx_, c.s.client, req)
28984}
28985
28986// Do executes the "dfareporting.creativeGroups.update" call.
28987// Exactly one of *CreativeGroup or error will be non-nil. Any non-2xx
28988// status code is an error. Response headers are in either
28989// *CreativeGroup.ServerResponse.Header or (if a response was returned
28990// at all) in error.(*googleapi.Error).Header. Use
28991// googleapi.IsNotModified to check whether the returned error was
28992// because http.StatusNotModified was returned.
28993func (c *CreativeGroupsUpdateCall) Do(opts ...googleapi.CallOption) (*CreativeGroup, error) {
28994	gensupport.SetOptions(c.urlParams_, opts...)
28995	res, err := c.doRequest("json")
28996	if res != nil && res.StatusCode == http.StatusNotModified {
28997		if res.Body != nil {
28998			res.Body.Close()
28999		}
29000		return nil, &googleapi.Error{
29001			Code:   res.StatusCode,
29002			Header: res.Header,
29003		}
29004	}
29005	if err != nil {
29006		return nil, err
29007	}
29008	defer googleapi.CloseBody(res)
29009	if err := googleapi.CheckResponse(res); err != nil {
29010		return nil, err
29011	}
29012	ret := &CreativeGroup{
29013		ServerResponse: googleapi.ServerResponse{
29014			Header:         res.Header,
29015			HTTPStatusCode: res.StatusCode,
29016		},
29017	}
29018	target := &ret
29019	if err := gensupport.DecodeResponse(target, res); err != nil {
29020		return nil, err
29021	}
29022	return ret, nil
29023	// {
29024	//   "description": "Updates an existing creative group.",
29025	//   "flatPath": "userprofiles/{profileId}/creativeGroups",
29026	//   "httpMethod": "PUT",
29027	//   "id": "dfareporting.creativeGroups.update",
29028	//   "parameterOrder": [
29029	//     "profileId"
29030	//   ],
29031	//   "parameters": {
29032	//     "profileId": {
29033	//       "description": "User profile ID associated with this request.",
29034	//       "format": "int64",
29035	//       "location": "path",
29036	//       "required": true,
29037	//       "type": "string"
29038	//     }
29039	//   },
29040	//   "path": "userprofiles/{profileId}/creativeGroups",
29041	//   "request": {
29042	//     "$ref": "CreativeGroup"
29043	//   },
29044	//   "response": {
29045	//     "$ref": "CreativeGroup"
29046	//   },
29047	//   "scopes": [
29048	//     "https://www.googleapis.com/auth/dfatrafficking"
29049	//   ]
29050	// }
29051
29052}
29053
29054// method id "dfareporting.creatives.get":
29055
29056type CreativesGetCall struct {
29057	s            *Service
29058	profileId    int64
29059	id           int64
29060	urlParams_   gensupport.URLParams
29061	ifNoneMatch_ string
29062	ctx_         context.Context
29063	header_      http.Header
29064}
29065
29066// Get: Gets one creative by ID.
29067//
29068// - id: Creative ID.
29069// - profileId: User profile ID associated with this request.
29070func (r *CreativesService) Get(profileId int64, id int64) *CreativesGetCall {
29071	c := &CreativesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
29072	c.profileId = profileId
29073	c.id = id
29074	return c
29075}
29076
29077// Fields allows partial responses to be retrieved. See
29078// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
29079// for more information.
29080func (c *CreativesGetCall) Fields(s ...googleapi.Field) *CreativesGetCall {
29081	c.urlParams_.Set("fields", googleapi.CombineFields(s))
29082	return c
29083}
29084
29085// IfNoneMatch sets the optional parameter which makes the operation
29086// fail if the object's ETag matches the given value. This is useful for
29087// getting updates only after the object has changed since the last
29088// request. Use googleapi.IsNotModified to check whether the response
29089// error from Do is the result of In-None-Match.
29090func (c *CreativesGetCall) IfNoneMatch(entityTag string) *CreativesGetCall {
29091	c.ifNoneMatch_ = entityTag
29092	return c
29093}
29094
29095// Context sets the context to be used in this call's Do method. Any
29096// pending HTTP request will be aborted if the provided context is
29097// canceled.
29098func (c *CreativesGetCall) Context(ctx context.Context) *CreativesGetCall {
29099	c.ctx_ = ctx
29100	return c
29101}
29102
29103// Header returns an http.Header that can be modified by the caller to
29104// add HTTP headers to the request.
29105func (c *CreativesGetCall) Header() http.Header {
29106	if c.header_ == nil {
29107		c.header_ = make(http.Header)
29108	}
29109	return c.header_
29110}
29111
29112func (c *CreativesGetCall) doRequest(alt string) (*http.Response, error) {
29113	reqHeaders := make(http.Header)
29114	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
29115	for k, v := range c.header_ {
29116		reqHeaders[k] = v
29117	}
29118	reqHeaders.Set("User-Agent", c.s.userAgent())
29119	if c.ifNoneMatch_ != "" {
29120		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
29121	}
29122	var body io.Reader = nil
29123	c.urlParams_.Set("alt", alt)
29124	c.urlParams_.Set("prettyPrint", "false")
29125	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creatives/{id}")
29126	urls += "?" + c.urlParams_.Encode()
29127	req, err := http.NewRequest("GET", urls, body)
29128	if err != nil {
29129		return nil, err
29130	}
29131	req.Header = reqHeaders
29132	googleapi.Expand(req.URL, map[string]string{
29133		"profileId": strconv.FormatInt(c.profileId, 10),
29134		"id":        strconv.FormatInt(c.id, 10),
29135	})
29136	return gensupport.SendRequest(c.ctx_, c.s.client, req)
29137}
29138
29139// Do executes the "dfareporting.creatives.get" call.
29140// Exactly one of *Creative or error will be non-nil. Any non-2xx status
29141// code is an error. Response headers are in either
29142// *Creative.ServerResponse.Header or (if a response was returned at
29143// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
29144// to check whether the returned error was because
29145// http.StatusNotModified was returned.
29146func (c *CreativesGetCall) Do(opts ...googleapi.CallOption) (*Creative, error) {
29147	gensupport.SetOptions(c.urlParams_, opts...)
29148	res, err := c.doRequest("json")
29149	if res != nil && res.StatusCode == http.StatusNotModified {
29150		if res.Body != nil {
29151			res.Body.Close()
29152		}
29153		return nil, &googleapi.Error{
29154			Code:   res.StatusCode,
29155			Header: res.Header,
29156		}
29157	}
29158	if err != nil {
29159		return nil, err
29160	}
29161	defer googleapi.CloseBody(res)
29162	if err := googleapi.CheckResponse(res); err != nil {
29163		return nil, err
29164	}
29165	ret := &Creative{
29166		ServerResponse: googleapi.ServerResponse{
29167			Header:         res.Header,
29168			HTTPStatusCode: res.StatusCode,
29169		},
29170	}
29171	target := &ret
29172	if err := gensupport.DecodeResponse(target, res); err != nil {
29173		return nil, err
29174	}
29175	return ret, nil
29176	// {
29177	//   "description": "Gets one creative by ID.",
29178	//   "flatPath": "userprofiles/{profileId}/creatives/{id}",
29179	//   "httpMethod": "GET",
29180	//   "id": "dfareporting.creatives.get",
29181	//   "parameterOrder": [
29182	//     "profileId",
29183	//     "id"
29184	//   ],
29185	//   "parameters": {
29186	//     "id": {
29187	//       "description": "Creative ID.",
29188	//       "format": "int64",
29189	//       "location": "path",
29190	//       "required": true,
29191	//       "type": "string"
29192	//     },
29193	//     "profileId": {
29194	//       "description": "User profile ID associated with this request.",
29195	//       "format": "int64",
29196	//       "location": "path",
29197	//       "required": true,
29198	//       "type": "string"
29199	//     }
29200	//   },
29201	//   "path": "userprofiles/{profileId}/creatives/{id}",
29202	//   "response": {
29203	//     "$ref": "Creative"
29204	//   },
29205	//   "scopes": [
29206	//     "https://www.googleapis.com/auth/dfatrafficking"
29207	//   ]
29208	// }
29209
29210}
29211
29212// method id "dfareporting.creatives.insert":
29213
29214type CreativesInsertCall struct {
29215	s          *Service
29216	profileId  int64
29217	creative   *Creative
29218	urlParams_ gensupport.URLParams
29219	ctx_       context.Context
29220	header_    http.Header
29221}
29222
29223// Insert: Inserts a new creative.
29224//
29225// - profileId: User profile ID associated with this request.
29226func (r *CreativesService) Insert(profileId int64, creative *Creative) *CreativesInsertCall {
29227	c := &CreativesInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
29228	c.profileId = profileId
29229	c.creative = creative
29230	return c
29231}
29232
29233// Fields allows partial responses to be retrieved. See
29234// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
29235// for more information.
29236func (c *CreativesInsertCall) Fields(s ...googleapi.Field) *CreativesInsertCall {
29237	c.urlParams_.Set("fields", googleapi.CombineFields(s))
29238	return c
29239}
29240
29241// Context sets the context to be used in this call's Do method. Any
29242// pending HTTP request will be aborted if the provided context is
29243// canceled.
29244func (c *CreativesInsertCall) Context(ctx context.Context) *CreativesInsertCall {
29245	c.ctx_ = ctx
29246	return c
29247}
29248
29249// Header returns an http.Header that can be modified by the caller to
29250// add HTTP headers to the request.
29251func (c *CreativesInsertCall) Header() http.Header {
29252	if c.header_ == nil {
29253		c.header_ = make(http.Header)
29254	}
29255	return c.header_
29256}
29257
29258func (c *CreativesInsertCall) doRequest(alt string) (*http.Response, error) {
29259	reqHeaders := make(http.Header)
29260	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
29261	for k, v := range c.header_ {
29262		reqHeaders[k] = v
29263	}
29264	reqHeaders.Set("User-Agent", c.s.userAgent())
29265	var body io.Reader = nil
29266	body, err := googleapi.WithoutDataWrapper.JSONReader(c.creative)
29267	if err != nil {
29268		return nil, err
29269	}
29270	reqHeaders.Set("Content-Type", "application/json")
29271	c.urlParams_.Set("alt", alt)
29272	c.urlParams_.Set("prettyPrint", "false")
29273	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creatives")
29274	urls += "?" + c.urlParams_.Encode()
29275	req, err := http.NewRequest("POST", urls, body)
29276	if err != nil {
29277		return nil, err
29278	}
29279	req.Header = reqHeaders
29280	googleapi.Expand(req.URL, map[string]string{
29281		"profileId": strconv.FormatInt(c.profileId, 10),
29282	})
29283	return gensupport.SendRequest(c.ctx_, c.s.client, req)
29284}
29285
29286// Do executes the "dfareporting.creatives.insert" call.
29287// Exactly one of *Creative or error will be non-nil. Any non-2xx status
29288// code is an error. Response headers are in either
29289// *Creative.ServerResponse.Header or (if a response was returned at
29290// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
29291// to check whether the returned error was because
29292// http.StatusNotModified was returned.
29293func (c *CreativesInsertCall) Do(opts ...googleapi.CallOption) (*Creative, error) {
29294	gensupport.SetOptions(c.urlParams_, opts...)
29295	res, err := c.doRequest("json")
29296	if res != nil && res.StatusCode == http.StatusNotModified {
29297		if res.Body != nil {
29298			res.Body.Close()
29299		}
29300		return nil, &googleapi.Error{
29301			Code:   res.StatusCode,
29302			Header: res.Header,
29303		}
29304	}
29305	if err != nil {
29306		return nil, err
29307	}
29308	defer googleapi.CloseBody(res)
29309	if err := googleapi.CheckResponse(res); err != nil {
29310		return nil, err
29311	}
29312	ret := &Creative{
29313		ServerResponse: googleapi.ServerResponse{
29314			Header:         res.Header,
29315			HTTPStatusCode: res.StatusCode,
29316		},
29317	}
29318	target := &ret
29319	if err := gensupport.DecodeResponse(target, res); err != nil {
29320		return nil, err
29321	}
29322	return ret, nil
29323	// {
29324	//   "description": "Inserts a new creative.",
29325	//   "flatPath": "userprofiles/{profileId}/creatives",
29326	//   "httpMethod": "POST",
29327	//   "id": "dfareporting.creatives.insert",
29328	//   "parameterOrder": [
29329	//     "profileId"
29330	//   ],
29331	//   "parameters": {
29332	//     "profileId": {
29333	//       "description": "User profile ID associated with this request.",
29334	//       "format": "int64",
29335	//       "location": "path",
29336	//       "required": true,
29337	//       "type": "string"
29338	//     }
29339	//   },
29340	//   "path": "userprofiles/{profileId}/creatives",
29341	//   "request": {
29342	//     "$ref": "Creative"
29343	//   },
29344	//   "response": {
29345	//     "$ref": "Creative"
29346	//   },
29347	//   "scopes": [
29348	//     "https://www.googleapis.com/auth/dfatrafficking"
29349	//   ]
29350	// }
29351
29352}
29353
29354// method id "dfareporting.creatives.list":
29355
29356type CreativesListCall struct {
29357	s            *Service
29358	profileId    int64
29359	urlParams_   gensupport.URLParams
29360	ifNoneMatch_ string
29361	ctx_         context.Context
29362	header_      http.Header
29363}
29364
29365// List: Retrieves a list of creatives, possibly filtered. This method
29366// supports paging.
29367//
29368// - profileId: User profile ID associated with this request.
29369func (r *CreativesService) List(profileId int64) *CreativesListCall {
29370	c := &CreativesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
29371	c.profileId = profileId
29372	return c
29373}
29374
29375// Active sets the optional parameter "active": Select only active
29376// creatives. Leave blank to select active and inactive creatives.
29377func (c *CreativesListCall) Active(active bool) *CreativesListCall {
29378	c.urlParams_.Set("active", fmt.Sprint(active))
29379	return c
29380}
29381
29382// AdvertiserId sets the optional parameter "advertiserId": Select only
29383// creatives with this advertiser ID.
29384func (c *CreativesListCall) AdvertiserId(advertiserId int64) *CreativesListCall {
29385	c.urlParams_.Set("advertiserId", fmt.Sprint(advertiserId))
29386	return c
29387}
29388
29389// Archived sets the optional parameter "archived": Select only archived
29390// creatives. Leave blank to select archived and unarchived creatives.
29391func (c *CreativesListCall) Archived(archived bool) *CreativesListCall {
29392	c.urlParams_.Set("archived", fmt.Sprint(archived))
29393	return c
29394}
29395
29396// CampaignId sets the optional parameter "campaignId": Select only
29397// creatives with this campaign ID.
29398func (c *CreativesListCall) CampaignId(campaignId int64) *CreativesListCall {
29399	c.urlParams_.Set("campaignId", fmt.Sprint(campaignId))
29400	return c
29401}
29402
29403// CompanionCreativeIds sets the optional parameter
29404// "companionCreativeIds": Select only in-stream video creatives with
29405// these companion IDs.
29406func (c *CreativesListCall) CompanionCreativeIds(companionCreativeIds ...int64) *CreativesListCall {
29407	var companionCreativeIds_ []string
29408	for _, v := range companionCreativeIds {
29409		companionCreativeIds_ = append(companionCreativeIds_, fmt.Sprint(v))
29410	}
29411	c.urlParams_.SetMulti("companionCreativeIds", companionCreativeIds_)
29412	return c
29413}
29414
29415// CreativeFieldIds sets the optional parameter "creativeFieldIds":
29416// Select only creatives with these creative field IDs.
29417func (c *CreativesListCall) CreativeFieldIds(creativeFieldIds ...int64) *CreativesListCall {
29418	var creativeFieldIds_ []string
29419	for _, v := range creativeFieldIds {
29420		creativeFieldIds_ = append(creativeFieldIds_, fmt.Sprint(v))
29421	}
29422	c.urlParams_.SetMulti("creativeFieldIds", creativeFieldIds_)
29423	return c
29424}
29425
29426// Ids sets the optional parameter "ids": Select only creatives with
29427// these IDs.
29428func (c *CreativesListCall) Ids(ids ...int64) *CreativesListCall {
29429	var ids_ []string
29430	for _, v := range ids {
29431		ids_ = append(ids_, fmt.Sprint(v))
29432	}
29433	c.urlParams_.SetMulti("ids", ids_)
29434	return c
29435}
29436
29437// MaxResults sets the optional parameter "maxResults": Maximum number
29438// of results to return.
29439func (c *CreativesListCall) MaxResults(maxResults int64) *CreativesListCall {
29440	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
29441	return c
29442}
29443
29444// PageToken sets the optional parameter "pageToken": Value of the
29445// nextPageToken from the previous result page.
29446func (c *CreativesListCall) PageToken(pageToken string) *CreativesListCall {
29447	c.urlParams_.Set("pageToken", pageToken)
29448	return c
29449}
29450
29451// RenderingIds sets the optional parameter "renderingIds": Select only
29452// creatives with these rendering IDs.
29453func (c *CreativesListCall) RenderingIds(renderingIds ...int64) *CreativesListCall {
29454	var renderingIds_ []string
29455	for _, v := range renderingIds {
29456		renderingIds_ = append(renderingIds_, fmt.Sprint(v))
29457	}
29458	c.urlParams_.SetMulti("renderingIds", renderingIds_)
29459	return c
29460}
29461
29462// SearchString sets the optional parameter "searchString": Allows
29463// searching for objects by name or ID. Wildcards (*) are allowed. For
29464// example, "creative*2015" will return objects with names like
29465// "creative June 2015", "creative April 2015", or simply "creative
29466// 2015". Most of the searches also add wildcards implicitly at the
29467// start and the end of the search string. For example, a search string
29468// of "creative" will match objects with name "my creative", "creative
29469// 2015", or simply "creative".
29470func (c *CreativesListCall) SearchString(searchString string) *CreativesListCall {
29471	c.urlParams_.Set("searchString", searchString)
29472	return c
29473}
29474
29475// SizeIds sets the optional parameter "sizeIds": Select only creatives
29476// with these size IDs.
29477func (c *CreativesListCall) SizeIds(sizeIds ...int64) *CreativesListCall {
29478	var sizeIds_ []string
29479	for _, v := range sizeIds {
29480		sizeIds_ = append(sizeIds_, fmt.Sprint(v))
29481	}
29482	c.urlParams_.SetMulti("sizeIds", sizeIds_)
29483	return c
29484}
29485
29486// SortField sets the optional parameter "sortField": Field by which to
29487// sort the list.
29488//
29489// Possible values:
29490//   "ID" (default)
29491//   "NAME"
29492func (c *CreativesListCall) SortField(sortField string) *CreativesListCall {
29493	c.urlParams_.Set("sortField", sortField)
29494	return c
29495}
29496
29497// SortOrder sets the optional parameter "sortOrder": Order of sorted
29498// results.
29499//
29500// Possible values:
29501//   "ASCENDING" (default)
29502//   "DESCENDING"
29503func (c *CreativesListCall) SortOrder(sortOrder string) *CreativesListCall {
29504	c.urlParams_.Set("sortOrder", sortOrder)
29505	return c
29506}
29507
29508// StudioCreativeId sets the optional parameter "studioCreativeId":
29509// Select only creatives corresponding to this Studio creative ID.
29510func (c *CreativesListCall) StudioCreativeId(studioCreativeId int64) *CreativesListCall {
29511	c.urlParams_.Set("studioCreativeId", fmt.Sprint(studioCreativeId))
29512	return c
29513}
29514
29515// Types sets the optional parameter "types": Select only creatives with
29516// these creative types.
29517//
29518// Possible values:
29519//   "IMAGE"
29520//   "DISPLAY_REDIRECT"
29521//   "CUSTOM_DISPLAY"
29522//   "INTERNAL_REDIRECT"
29523//   "CUSTOM_DISPLAY_INTERSTITIAL"
29524//   "INTERSTITIAL_INTERNAL_REDIRECT"
29525//   "TRACKING_TEXT"
29526//   "RICH_MEDIA_DISPLAY_BANNER"
29527//   "RICH_MEDIA_INPAGE_FLOATING"
29528//   "RICH_MEDIA_IM_EXPAND"
29529//   "RICH_MEDIA_DISPLAY_EXPANDING"
29530//   "RICH_MEDIA_DISPLAY_INTERSTITIAL"
29531//   "RICH_MEDIA_DISPLAY_MULTI_FLOATING_INTERSTITIAL"
29532//   "RICH_MEDIA_MOBILE_IN_APP"
29533//   "FLASH_INPAGE"
29534//   "INSTREAM_VIDEO"
29535//   "VPAID_LINEAR_VIDEO"
29536//   "VPAID_NON_LINEAR_VIDEO"
29537//   "INSTREAM_VIDEO_REDIRECT"
29538//   "RICH_MEDIA_PEEL_DOWN"
29539//   "HTML5_BANNER"
29540//   "DISPLAY"
29541//   "DISPLAY_IMAGE_GALLERY"
29542//   "BRAND_SAFE_DEFAULT_INSTREAM_VIDEO"
29543//   "INSTREAM_AUDIO"
29544func (c *CreativesListCall) Types(types ...string) *CreativesListCall {
29545	c.urlParams_.SetMulti("types", append([]string{}, types...))
29546	return c
29547}
29548
29549// Fields allows partial responses to be retrieved. See
29550// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
29551// for more information.
29552func (c *CreativesListCall) Fields(s ...googleapi.Field) *CreativesListCall {
29553	c.urlParams_.Set("fields", googleapi.CombineFields(s))
29554	return c
29555}
29556
29557// IfNoneMatch sets the optional parameter which makes the operation
29558// fail if the object's ETag matches the given value. This is useful for
29559// getting updates only after the object has changed since the last
29560// request. Use googleapi.IsNotModified to check whether the response
29561// error from Do is the result of In-None-Match.
29562func (c *CreativesListCall) IfNoneMatch(entityTag string) *CreativesListCall {
29563	c.ifNoneMatch_ = entityTag
29564	return c
29565}
29566
29567// Context sets the context to be used in this call's Do method. Any
29568// pending HTTP request will be aborted if the provided context is
29569// canceled.
29570func (c *CreativesListCall) Context(ctx context.Context) *CreativesListCall {
29571	c.ctx_ = ctx
29572	return c
29573}
29574
29575// Header returns an http.Header that can be modified by the caller to
29576// add HTTP headers to the request.
29577func (c *CreativesListCall) Header() http.Header {
29578	if c.header_ == nil {
29579		c.header_ = make(http.Header)
29580	}
29581	return c.header_
29582}
29583
29584func (c *CreativesListCall) doRequest(alt string) (*http.Response, error) {
29585	reqHeaders := make(http.Header)
29586	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
29587	for k, v := range c.header_ {
29588		reqHeaders[k] = v
29589	}
29590	reqHeaders.Set("User-Agent", c.s.userAgent())
29591	if c.ifNoneMatch_ != "" {
29592		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
29593	}
29594	var body io.Reader = nil
29595	c.urlParams_.Set("alt", alt)
29596	c.urlParams_.Set("prettyPrint", "false")
29597	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creatives")
29598	urls += "?" + c.urlParams_.Encode()
29599	req, err := http.NewRequest("GET", urls, body)
29600	if err != nil {
29601		return nil, err
29602	}
29603	req.Header = reqHeaders
29604	googleapi.Expand(req.URL, map[string]string{
29605		"profileId": strconv.FormatInt(c.profileId, 10),
29606	})
29607	return gensupport.SendRequest(c.ctx_, c.s.client, req)
29608}
29609
29610// Do executes the "dfareporting.creatives.list" call.
29611// Exactly one of *CreativesListResponse or error will be non-nil. Any
29612// non-2xx status code is an error. Response headers are in either
29613// *CreativesListResponse.ServerResponse.Header or (if a response was
29614// returned at all) in error.(*googleapi.Error).Header. Use
29615// googleapi.IsNotModified to check whether the returned error was
29616// because http.StatusNotModified was returned.
29617func (c *CreativesListCall) Do(opts ...googleapi.CallOption) (*CreativesListResponse, error) {
29618	gensupport.SetOptions(c.urlParams_, opts...)
29619	res, err := c.doRequest("json")
29620	if res != nil && res.StatusCode == http.StatusNotModified {
29621		if res.Body != nil {
29622			res.Body.Close()
29623		}
29624		return nil, &googleapi.Error{
29625			Code:   res.StatusCode,
29626			Header: res.Header,
29627		}
29628	}
29629	if err != nil {
29630		return nil, err
29631	}
29632	defer googleapi.CloseBody(res)
29633	if err := googleapi.CheckResponse(res); err != nil {
29634		return nil, err
29635	}
29636	ret := &CreativesListResponse{
29637		ServerResponse: googleapi.ServerResponse{
29638			Header:         res.Header,
29639			HTTPStatusCode: res.StatusCode,
29640		},
29641	}
29642	target := &ret
29643	if err := gensupport.DecodeResponse(target, res); err != nil {
29644		return nil, err
29645	}
29646	return ret, nil
29647	// {
29648	//   "description": "Retrieves a list of creatives, possibly filtered. This method supports paging.",
29649	//   "flatPath": "userprofiles/{profileId}/creatives",
29650	//   "httpMethod": "GET",
29651	//   "id": "dfareporting.creatives.list",
29652	//   "parameterOrder": [
29653	//     "profileId"
29654	//   ],
29655	//   "parameters": {
29656	//     "active": {
29657	//       "description": "Select only active creatives. Leave blank to select active and inactive creatives.",
29658	//       "location": "query",
29659	//       "type": "boolean"
29660	//     },
29661	//     "advertiserId": {
29662	//       "description": "Select only creatives with this advertiser ID.",
29663	//       "format": "int64",
29664	//       "location": "query",
29665	//       "type": "string"
29666	//     },
29667	//     "archived": {
29668	//       "description": "Select only archived creatives. Leave blank to select archived and unarchived creatives.",
29669	//       "location": "query",
29670	//       "type": "boolean"
29671	//     },
29672	//     "campaignId": {
29673	//       "description": "Select only creatives with this campaign ID.",
29674	//       "format": "int64",
29675	//       "location": "query",
29676	//       "type": "string"
29677	//     },
29678	//     "companionCreativeIds": {
29679	//       "description": "Select only in-stream video creatives with these companion IDs.",
29680	//       "format": "int64",
29681	//       "location": "query",
29682	//       "repeated": true,
29683	//       "type": "string"
29684	//     },
29685	//     "creativeFieldIds": {
29686	//       "description": "Select only creatives with these creative field IDs.",
29687	//       "format": "int64",
29688	//       "location": "query",
29689	//       "repeated": true,
29690	//       "type": "string"
29691	//     },
29692	//     "ids": {
29693	//       "description": "Select only creatives with these IDs.",
29694	//       "format": "int64",
29695	//       "location": "query",
29696	//       "repeated": true,
29697	//       "type": "string"
29698	//     },
29699	//     "maxResults": {
29700	//       "default": "1000",
29701	//       "description": "Maximum number of results to return.",
29702	//       "format": "int32",
29703	//       "location": "query",
29704	//       "maximum": "1000",
29705	//       "minimum": "0",
29706	//       "type": "integer"
29707	//     },
29708	//     "pageToken": {
29709	//       "description": "Value of the nextPageToken from the previous result page.",
29710	//       "location": "query",
29711	//       "type": "string"
29712	//     },
29713	//     "profileId": {
29714	//       "description": "User profile ID associated with this request.",
29715	//       "format": "int64",
29716	//       "location": "path",
29717	//       "required": true,
29718	//       "type": "string"
29719	//     },
29720	//     "renderingIds": {
29721	//       "description": "Select only creatives with these rendering IDs.",
29722	//       "format": "int64",
29723	//       "location": "query",
29724	//       "repeated": true,
29725	//       "type": "string"
29726	//     },
29727	//     "searchString": {
29728	//       "description": "Allows searching for objects by name or ID. Wildcards (*) are allowed. For example, \"creative*2015\" will return objects with names like \"creative June 2015\", \"creative April 2015\", or simply \"creative 2015\". Most of the searches also add wildcards implicitly at the start and the end of the search string. For example, a search string of \"creative\" will match objects with name \"my creative\", \"creative 2015\", or simply \"creative\".",
29729	//       "location": "query",
29730	//       "type": "string"
29731	//     },
29732	//     "sizeIds": {
29733	//       "description": "Select only creatives with these size IDs.",
29734	//       "format": "int64",
29735	//       "location": "query",
29736	//       "repeated": true,
29737	//       "type": "string"
29738	//     },
29739	//     "sortField": {
29740	//       "default": "ID",
29741	//       "description": "Field by which to sort the list.",
29742	//       "enum": [
29743	//         "ID",
29744	//         "NAME"
29745	//       ],
29746	//       "enumDescriptions": [
29747	//         "",
29748	//         ""
29749	//       ],
29750	//       "location": "query",
29751	//       "type": "string"
29752	//     },
29753	//     "sortOrder": {
29754	//       "default": "ASCENDING",
29755	//       "description": "Order of sorted results.",
29756	//       "enum": [
29757	//         "ASCENDING",
29758	//         "DESCENDING"
29759	//       ],
29760	//       "enumDescriptions": [
29761	//         "",
29762	//         ""
29763	//       ],
29764	//       "location": "query",
29765	//       "type": "string"
29766	//     },
29767	//     "studioCreativeId": {
29768	//       "description": "Select only creatives corresponding to this Studio creative ID.",
29769	//       "format": "int64",
29770	//       "location": "query",
29771	//       "type": "string"
29772	//     },
29773	//     "types": {
29774	//       "description": "Select only creatives with these creative types.",
29775	//       "enum": [
29776	//         "IMAGE",
29777	//         "DISPLAY_REDIRECT",
29778	//         "CUSTOM_DISPLAY",
29779	//         "INTERNAL_REDIRECT",
29780	//         "CUSTOM_DISPLAY_INTERSTITIAL",
29781	//         "INTERSTITIAL_INTERNAL_REDIRECT",
29782	//         "TRACKING_TEXT",
29783	//         "RICH_MEDIA_DISPLAY_BANNER",
29784	//         "RICH_MEDIA_INPAGE_FLOATING",
29785	//         "RICH_MEDIA_IM_EXPAND",
29786	//         "RICH_MEDIA_DISPLAY_EXPANDING",
29787	//         "RICH_MEDIA_DISPLAY_INTERSTITIAL",
29788	//         "RICH_MEDIA_DISPLAY_MULTI_FLOATING_INTERSTITIAL",
29789	//         "RICH_MEDIA_MOBILE_IN_APP",
29790	//         "FLASH_INPAGE",
29791	//         "INSTREAM_VIDEO",
29792	//         "VPAID_LINEAR_VIDEO",
29793	//         "VPAID_NON_LINEAR_VIDEO",
29794	//         "INSTREAM_VIDEO_REDIRECT",
29795	//         "RICH_MEDIA_PEEL_DOWN",
29796	//         "HTML5_BANNER",
29797	//         "DISPLAY",
29798	//         "DISPLAY_IMAGE_GALLERY",
29799	//         "BRAND_SAFE_DEFAULT_INSTREAM_VIDEO",
29800	//         "INSTREAM_AUDIO"
29801	//       ],
29802	//       "enumDescriptions": [
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	//       "location": "query",
29830	//       "repeated": true,
29831	//       "type": "string"
29832	//     }
29833	//   },
29834	//   "path": "userprofiles/{profileId}/creatives",
29835	//   "response": {
29836	//     "$ref": "CreativesListResponse"
29837	//   },
29838	//   "scopes": [
29839	//     "https://www.googleapis.com/auth/dfatrafficking"
29840	//   ]
29841	// }
29842
29843}
29844
29845// Pages invokes f for each page of results.
29846// A non-nil error returned from f will halt the iteration.
29847// The provided context supersedes any context provided to the Context method.
29848func (c *CreativesListCall) Pages(ctx context.Context, f func(*CreativesListResponse) error) error {
29849	c.ctx_ = ctx
29850	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
29851	for {
29852		x, err := c.Do()
29853		if err != nil {
29854			return err
29855		}
29856		if err := f(x); err != nil {
29857			return err
29858		}
29859		if x.NextPageToken == "" {
29860			return nil
29861		}
29862		c.PageToken(x.NextPageToken)
29863	}
29864}
29865
29866// method id "dfareporting.creatives.patch":
29867
29868type CreativesPatchCall struct {
29869	s          *Service
29870	profileId  int64
29871	creative   *Creative
29872	urlParams_ gensupport.URLParams
29873	ctx_       context.Context
29874	header_    http.Header
29875}
29876
29877// Patch: Updates an existing creative. This method supports patch
29878// semantics.
29879//
29880// - id: Creative ID.
29881// - profileId: User profile ID associated with this request.
29882func (r *CreativesService) Patch(profileId int64, id int64, creative *Creative) *CreativesPatchCall {
29883	c := &CreativesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
29884	c.profileId = profileId
29885	c.urlParams_.Set("id", fmt.Sprint(id))
29886	c.creative = creative
29887	return c
29888}
29889
29890// Fields allows partial responses to be retrieved. See
29891// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
29892// for more information.
29893func (c *CreativesPatchCall) Fields(s ...googleapi.Field) *CreativesPatchCall {
29894	c.urlParams_.Set("fields", googleapi.CombineFields(s))
29895	return c
29896}
29897
29898// Context sets the context to be used in this call's Do method. Any
29899// pending HTTP request will be aborted if the provided context is
29900// canceled.
29901func (c *CreativesPatchCall) Context(ctx context.Context) *CreativesPatchCall {
29902	c.ctx_ = ctx
29903	return c
29904}
29905
29906// Header returns an http.Header that can be modified by the caller to
29907// add HTTP headers to the request.
29908func (c *CreativesPatchCall) Header() http.Header {
29909	if c.header_ == nil {
29910		c.header_ = make(http.Header)
29911	}
29912	return c.header_
29913}
29914
29915func (c *CreativesPatchCall) doRequest(alt string) (*http.Response, error) {
29916	reqHeaders := make(http.Header)
29917	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
29918	for k, v := range c.header_ {
29919		reqHeaders[k] = v
29920	}
29921	reqHeaders.Set("User-Agent", c.s.userAgent())
29922	var body io.Reader = nil
29923	body, err := googleapi.WithoutDataWrapper.JSONReader(c.creative)
29924	if err != nil {
29925		return nil, err
29926	}
29927	reqHeaders.Set("Content-Type", "application/json")
29928	c.urlParams_.Set("alt", alt)
29929	c.urlParams_.Set("prettyPrint", "false")
29930	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creatives")
29931	urls += "?" + c.urlParams_.Encode()
29932	req, err := http.NewRequest("PATCH", urls, body)
29933	if err != nil {
29934		return nil, err
29935	}
29936	req.Header = reqHeaders
29937	googleapi.Expand(req.URL, map[string]string{
29938		"profileId": strconv.FormatInt(c.profileId, 10),
29939	})
29940	return gensupport.SendRequest(c.ctx_, c.s.client, req)
29941}
29942
29943// Do executes the "dfareporting.creatives.patch" call.
29944// Exactly one of *Creative or error will be non-nil. Any non-2xx status
29945// code is an error. Response headers are in either
29946// *Creative.ServerResponse.Header or (if a response was returned at
29947// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
29948// to check whether the returned error was because
29949// http.StatusNotModified was returned.
29950func (c *CreativesPatchCall) Do(opts ...googleapi.CallOption) (*Creative, error) {
29951	gensupport.SetOptions(c.urlParams_, opts...)
29952	res, err := c.doRequest("json")
29953	if res != nil && res.StatusCode == http.StatusNotModified {
29954		if res.Body != nil {
29955			res.Body.Close()
29956		}
29957		return nil, &googleapi.Error{
29958			Code:   res.StatusCode,
29959			Header: res.Header,
29960		}
29961	}
29962	if err != nil {
29963		return nil, err
29964	}
29965	defer googleapi.CloseBody(res)
29966	if err := googleapi.CheckResponse(res); err != nil {
29967		return nil, err
29968	}
29969	ret := &Creative{
29970		ServerResponse: googleapi.ServerResponse{
29971			Header:         res.Header,
29972			HTTPStatusCode: res.StatusCode,
29973		},
29974	}
29975	target := &ret
29976	if err := gensupport.DecodeResponse(target, res); err != nil {
29977		return nil, err
29978	}
29979	return ret, nil
29980	// {
29981	//   "description": "Updates an existing creative. This method supports patch semantics.",
29982	//   "flatPath": "userprofiles/{profileId}/creatives",
29983	//   "httpMethod": "PATCH",
29984	//   "id": "dfareporting.creatives.patch",
29985	//   "parameterOrder": [
29986	//     "profileId",
29987	//     "id"
29988	//   ],
29989	//   "parameters": {
29990	//     "id": {
29991	//       "description": "Creative ID.",
29992	//       "format": "int64",
29993	//       "location": "query",
29994	//       "required": true,
29995	//       "type": "string"
29996	//     },
29997	//     "profileId": {
29998	//       "description": "User profile ID associated with this request.",
29999	//       "format": "int64",
30000	//       "location": "path",
30001	//       "required": true,
30002	//       "type": "string"
30003	//     }
30004	//   },
30005	//   "path": "userprofiles/{profileId}/creatives",
30006	//   "request": {
30007	//     "$ref": "Creative"
30008	//   },
30009	//   "response": {
30010	//     "$ref": "Creative"
30011	//   },
30012	//   "scopes": [
30013	//     "https://www.googleapis.com/auth/dfatrafficking"
30014	//   ]
30015	// }
30016
30017}
30018
30019// method id "dfareporting.creatives.update":
30020
30021type CreativesUpdateCall struct {
30022	s          *Service
30023	profileId  int64
30024	creative   *Creative
30025	urlParams_ gensupport.URLParams
30026	ctx_       context.Context
30027	header_    http.Header
30028}
30029
30030// Update: Updates an existing creative.
30031//
30032// - profileId: User profile ID associated with this request.
30033func (r *CreativesService) Update(profileId int64, creative *Creative) *CreativesUpdateCall {
30034	c := &CreativesUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
30035	c.profileId = profileId
30036	c.creative = creative
30037	return c
30038}
30039
30040// Fields allows partial responses to be retrieved. See
30041// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
30042// for more information.
30043func (c *CreativesUpdateCall) Fields(s ...googleapi.Field) *CreativesUpdateCall {
30044	c.urlParams_.Set("fields", googleapi.CombineFields(s))
30045	return c
30046}
30047
30048// Context sets the context to be used in this call's Do method. Any
30049// pending HTTP request will be aborted if the provided context is
30050// canceled.
30051func (c *CreativesUpdateCall) Context(ctx context.Context) *CreativesUpdateCall {
30052	c.ctx_ = ctx
30053	return c
30054}
30055
30056// Header returns an http.Header that can be modified by the caller to
30057// add HTTP headers to the request.
30058func (c *CreativesUpdateCall) Header() http.Header {
30059	if c.header_ == nil {
30060		c.header_ = make(http.Header)
30061	}
30062	return c.header_
30063}
30064
30065func (c *CreativesUpdateCall) doRequest(alt string) (*http.Response, error) {
30066	reqHeaders := make(http.Header)
30067	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
30068	for k, v := range c.header_ {
30069		reqHeaders[k] = v
30070	}
30071	reqHeaders.Set("User-Agent", c.s.userAgent())
30072	var body io.Reader = nil
30073	body, err := googleapi.WithoutDataWrapper.JSONReader(c.creative)
30074	if err != nil {
30075		return nil, err
30076	}
30077	reqHeaders.Set("Content-Type", "application/json")
30078	c.urlParams_.Set("alt", alt)
30079	c.urlParams_.Set("prettyPrint", "false")
30080	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/creatives")
30081	urls += "?" + c.urlParams_.Encode()
30082	req, err := http.NewRequest("PUT", urls, body)
30083	if err != nil {
30084		return nil, err
30085	}
30086	req.Header = reqHeaders
30087	googleapi.Expand(req.URL, map[string]string{
30088		"profileId": strconv.FormatInt(c.profileId, 10),
30089	})
30090	return gensupport.SendRequest(c.ctx_, c.s.client, req)
30091}
30092
30093// Do executes the "dfareporting.creatives.update" call.
30094// Exactly one of *Creative or error will be non-nil. Any non-2xx status
30095// code is an error. Response headers are in either
30096// *Creative.ServerResponse.Header or (if a response was returned at
30097// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
30098// to check whether the returned error was because
30099// http.StatusNotModified was returned.
30100func (c *CreativesUpdateCall) Do(opts ...googleapi.CallOption) (*Creative, error) {
30101	gensupport.SetOptions(c.urlParams_, opts...)
30102	res, err := c.doRequest("json")
30103	if res != nil && res.StatusCode == http.StatusNotModified {
30104		if res.Body != nil {
30105			res.Body.Close()
30106		}
30107		return nil, &googleapi.Error{
30108			Code:   res.StatusCode,
30109			Header: res.Header,
30110		}
30111	}
30112	if err != nil {
30113		return nil, err
30114	}
30115	defer googleapi.CloseBody(res)
30116	if err := googleapi.CheckResponse(res); err != nil {
30117		return nil, err
30118	}
30119	ret := &Creative{
30120		ServerResponse: googleapi.ServerResponse{
30121			Header:         res.Header,
30122			HTTPStatusCode: res.StatusCode,
30123		},
30124	}
30125	target := &ret
30126	if err := gensupport.DecodeResponse(target, res); err != nil {
30127		return nil, err
30128	}
30129	return ret, nil
30130	// {
30131	//   "description": "Updates an existing creative.",
30132	//   "flatPath": "userprofiles/{profileId}/creatives",
30133	//   "httpMethod": "PUT",
30134	//   "id": "dfareporting.creatives.update",
30135	//   "parameterOrder": [
30136	//     "profileId"
30137	//   ],
30138	//   "parameters": {
30139	//     "profileId": {
30140	//       "description": "User profile ID associated with this request.",
30141	//       "format": "int64",
30142	//       "location": "path",
30143	//       "required": true,
30144	//       "type": "string"
30145	//     }
30146	//   },
30147	//   "path": "userprofiles/{profileId}/creatives",
30148	//   "request": {
30149	//     "$ref": "Creative"
30150	//   },
30151	//   "response": {
30152	//     "$ref": "Creative"
30153	//   },
30154	//   "scopes": [
30155	//     "https://www.googleapis.com/auth/dfatrafficking"
30156	//   ]
30157	// }
30158
30159}
30160
30161// method id "dfareporting.customEvents.batchinsert":
30162
30163type CustomEventsBatchinsertCall struct {
30164	s                              *Service
30165	profileId                      int64
30166	customeventsbatchinsertrequest *CustomEventsBatchInsertRequest
30167	urlParams_                     gensupport.URLParams
30168	ctx_                           context.Context
30169	header_                        http.Header
30170}
30171
30172// Batchinsert: Inserts custom events.
30173//
30174// - profileId: User profile ID associated with this request.
30175func (r *CustomEventsService) Batchinsert(profileId int64, customeventsbatchinsertrequest *CustomEventsBatchInsertRequest) *CustomEventsBatchinsertCall {
30176	c := &CustomEventsBatchinsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
30177	c.profileId = profileId
30178	c.customeventsbatchinsertrequest = customeventsbatchinsertrequest
30179	return c
30180}
30181
30182// Fields allows partial responses to be retrieved. See
30183// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
30184// for more information.
30185func (c *CustomEventsBatchinsertCall) Fields(s ...googleapi.Field) *CustomEventsBatchinsertCall {
30186	c.urlParams_.Set("fields", googleapi.CombineFields(s))
30187	return c
30188}
30189
30190// Context sets the context to be used in this call's Do method. Any
30191// pending HTTP request will be aborted if the provided context is
30192// canceled.
30193func (c *CustomEventsBatchinsertCall) Context(ctx context.Context) *CustomEventsBatchinsertCall {
30194	c.ctx_ = ctx
30195	return c
30196}
30197
30198// Header returns an http.Header that can be modified by the caller to
30199// add HTTP headers to the request.
30200func (c *CustomEventsBatchinsertCall) Header() http.Header {
30201	if c.header_ == nil {
30202		c.header_ = make(http.Header)
30203	}
30204	return c.header_
30205}
30206
30207func (c *CustomEventsBatchinsertCall) doRequest(alt string) (*http.Response, error) {
30208	reqHeaders := make(http.Header)
30209	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
30210	for k, v := range c.header_ {
30211		reqHeaders[k] = v
30212	}
30213	reqHeaders.Set("User-Agent", c.s.userAgent())
30214	var body io.Reader = nil
30215	body, err := googleapi.WithoutDataWrapper.JSONReader(c.customeventsbatchinsertrequest)
30216	if err != nil {
30217		return nil, err
30218	}
30219	reqHeaders.Set("Content-Type", "application/json")
30220	c.urlParams_.Set("alt", alt)
30221	c.urlParams_.Set("prettyPrint", "false")
30222	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/customEvents/batchinsert")
30223	urls += "?" + c.urlParams_.Encode()
30224	req, err := http.NewRequest("POST", urls, body)
30225	if err != nil {
30226		return nil, err
30227	}
30228	req.Header = reqHeaders
30229	googleapi.Expand(req.URL, map[string]string{
30230		"profileId": strconv.FormatInt(c.profileId, 10),
30231	})
30232	return gensupport.SendRequest(c.ctx_, c.s.client, req)
30233}
30234
30235// Do executes the "dfareporting.customEvents.batchinsert" call.
30236// Exactly one of *CustomEventsBatchInsertResponse or error will be
30237// non-nil. Any non-2xx status code is an error. Response headers are in
30238// either *CustomEventsBatchInsertResponse.ServerResponse.Header or (if
30239// a response was returned at all) in error.(*googleapi.Error).Header.
30240// Use googleapi.IsNotModified to check whether the returned error was
30241// because http.StatusNotModified was returned.
30242func (c *CustomEventsBatchinsertCall) Do(opts ...googleapi.CallOption) (*CustomEventsBatchInsertResponse, error) {
30243	gensupport.SetOptions(c.urlParams_, opts...)
30244	res, err := c.doRequest("json")
30245	if res != nil && res.StatusCode == http.StatusNotModified {
30246		if res.Body != nil {
30247			res.Body.Close()
30248		}
30249		return nil, &googleapi.Error{
30250			Code:   res.StatusCode,
30251			Header: res.Header,
30252		}
30253	}
30254	if err != nil {
30255		return nil, err
30256	}
30257	defer googleapi.CloseBody(res)
30258	if err := googleapi.CheckResponse(res); err != nil {
30259		return nil, err
30260	}
30261	ret := &CustomEventsBatchInsertResponse{
30262		ServerResponse: googleapi.ServerResponse{
30263			Header:         res.Header,
30264			HTTPStatusCode: res.StatusCode,
30265		},
30266	}
30267	target := &ret
30268	if err := gensupport.DecodeResponse(target, res); err != nil {
30269		return nil, err
30270	}
30271	return ret, nil
30272	// {
30273	//   "description": "Inserts custom events.",
30274	//   "flatPath": "userprofiles/{profileId}/customEvents/batchinsert",
30275	//   "httpMethod": "POST",
30276	//   "id": "dfareporting.customEvents.batchinsert",
30277	//   "parameterOrder": [
30278	//     "profileId"
30279	//   ],
30280	//   "parameters": {
30281	//     "profileId": {
30282	//       "description": "User profile ID associated with this request.",
30283	//       "format": "int64",
30284	//       "location": "path",
30285	//       "required": true,
30286	//       "type": "string"
30287	//     }
30288	//   },
30289	//   "path": "userprofiles/{profileId}/customEvents/batchinsert",
30290	//   "request": {
30291	//     "$ref": "CustomEventsBatchInsertRequest"
30292	//   },
30293	//   "response": {
30294	//     "$ref": "CustomEventsBatchInsertResponse"
30295	//   },
30296	//   "scopes": [
30297	//     "https://www.googleapis.com/auth/ddmconversions"
30298	//   ]
30299	// }
30300
30301}
30302
30303// method id "dfareporting.dimensionValues.query":
30304
30305type DimensionValuesQueryCall struct {
30306	s                     *Service
30307	profileId             int64
30308	dimensionvaluerequest *DimensionValueRequest
30309	urlParams_            gensupport.URLParams
30310	ctx_                  context.Context
30311	header_               http.Header
30312}
30313
30314// Query: Retrieves list of report dimension values for a list of
30315// filters.
30316//
30317// - profileId: The Campaign Manager 360 user profile ID.
30318func (r *DimensionValuesService) Query(profileId int64, dimensionvaluerequest *DimensionValueRequest) *DimensionValuesQueryCall {
30319	c := &DimensionValuesQueryCall{s: r.s, urlParams_: make(gensupport.URLParams)}
30320	c.profileId = profileId
30321	c.dimensionvaluerequest = dimensionvaluerequest
30322	return c
30323}
30324
30325// MaxResults sets the optional parameter "maxResults": Maximum number
30326// of results to return.
30327func (c *DimensionValuesQueryCall) MaxResults(maxResults int64) *DimensionValuesQueryCall {
30328	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
30329	return c
30330}
30331
30332// PageToken sets the optional parameter "pageToken": The value of the
30333// nextToken from the previous result page.
30334func (c *DimensionValuesQueryCall) PageToken(pageToken string) *DimensionValuesQueryCall {
30335	c.urlParams_.Set("pageToken", pageToken)
30336	return c
30337}
30338
30339// Fields allows partial responses to be retrieved. See
30340// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
30341// for more information.
30342func (c *DimensionValuesQueryCall) Fields(s ...googleapi.Field) *DimensionValuesQueryCall {
30343	c.urlParams_.Set("fields", googleapi.CombineFields(s))
30344	return c
30345}
30346
30347// Context sets the context to be used in this call's Do method. Any
30348// pending HTTP request will be aborted if the provided context is
30349// canceled.
30350func (c *DimensionValuesQueryCall) Context(ctx context.Context) *DimensionValuesQueryCall {
30351	c.ctx_ = ctx
30352	return c
30353}
30354
30355// Header returns an http.Header that can be modified by the caller to
30356// add HTTP headers to the request.
30357func (c *DimensionValuesQueryCall) Header() http.Header {
30358	if c.header_ == nil {
30359		c.header_ = make(http.Header)
30360	}
30361	return c.header_
30362}
30363
30364func (c *DimensionValuesQueryCall) doRequest(alt string) (*http.Response, error) {
30365	reqHeaders := make(http.Header)
30366	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
30367	for k, v := range c.header_ {
30368		reqHeaders[k] = v
30369	}
30370	reqHeaders.Set("User-Agent", c.s.userAgent())
30371	var body io.Reader = nil
30372	body, err := googleapi.WithoutDataWrapper.JSONReader(c.dimensionvaluerequest)
30373	if err != nil {
30374		return nil, err
30375	}
30376	reqHeaders.Set("Content-Type", "application/json")
30377	c.urlParams_.Set("alt", alt)
30378	c.urlParams_.Set("prettyPrint", "false")
30379	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/dimensionvalues/query")
30380	urls += "?" + c.urlParams_.Encode()
30381	req, err := http.NewRequest("POST", urls, body)
30382	if err != nil {
30383		return nil, err
30384	}
30385	req.Header = reqHeaders
30386	googleapi.Expand(req.URL, map[string]string{
30387		"profileId": strconv.FormatInt(c.profileId, 10),
30388	})
30389	return gensupport.SendRequest(c.ctx_, c.s.client, req)
30390}
30391
30392// Do executes the "dfareporting.dimensionValues.query" call.
30393// Exactly one of *DimensionValueList or error will be non-nil. Any
30394// non-2xx status code is an error. Response headers are in either
30395// *DimensionValueList.ServerResponse.Header or (if a response was
30396// returned at all) in error.(*googleapi.Error).Header. Use
30397// googleapi.IsNotModified to check whether the returned error was
30398// because http.StatusNotModified was returned.
30399func (c *DimensionValuesQueryCall) Do(opts ...googleapi.CallOption) (*DimensionValueList, error) {
30400	gensupport.SetOptions(c.urlParams_, opts...)
30401	res, err := c.doRequest("json")
30402	if res != nil && res.StatusCode == http.StatusNotModified {
30403		if res.Body != nil {
30404			res.Body.Close()
30405		}
30406		return nil, &googleapi.Error{
30407			Code:   res.StatusCode,
30408			Header: res.Header,
30409		}
30410	}
30411	if err != nil {
30412		return nil, err
30413	}
30414	defer googleapi.CloseBody(res)
30415	if err := googleapi.CheckResponse(res); err != nil {
30416		return nil, err
30417	}
30418	ret := &DimensionValueList{
30419		ServerResponse: googleapi.ServerResponse{
30420			Header:         res.Header,
30421			HTTPStatusCode: res.StatusCode,
30422		},
30423	}
30424	target := &ret
30425	if err := gensupport.DecodeResponse(target, res); err != nil {
30426		return nil, err
30427	}
30428	return ret, nil
30429	// {
30430	//   "description": "Retrieves list of report dimension values for a list of filters.",
30431	//   "flatPath": "userprofiles/{profileId}/dimensionvalues/query",
30432	//   "httpMethod": "POST",
30433	//   "id": "dfareporting.dimensionValues.query",
30434	//   "parameterOrder": [
30435	//     "profileId"
30436	//   ],
30437	//   "parameters": {
30438	//     "maxResults": {
30439	//       "default": "100",
30440	//       "description": "Maximum number of results to return.",
30441	//       "format": "int32",
30442	//       "location": "query",
30443	//       "maximum": "100",
30444	//       "minimum": "0",
30445	//       "type": "integer"
30446	//     },
30447	//     "pageToken": {
30448	//       "description": "The value of the nextToken from the previous result page.",
30449	//       "location": "query",
30450	//       "type": "string"
30451	//     },
30452	//     "profileId": {
30453	//       "description": "The Campaign Manager 360 user profile ID.",
30454	//       "format": "int64",
30455	//       "location": "path",
30456	//       "required": true,
30457	//       "type": "string"
30458	//     }
30459	//   },
30460	//   "path": "userprofiles/{profileId}/dimensionvalues/query",
30461	//   "request": {
30462	//     "$ref": "DimensionValueRequest"
30463	//   },
30464	//   "response": {
30465	//     "$ref": "DimensionValueList"
30466	//   },
30467	//   "scopes": [
30468	//     "https://www.googleapis.com/auth/dfareporting"
30469	//   ]
30470	// }
30471
30472}
30473
30474// Pages invokes f for each page of results.
30475// A non-nil error returned from f will halt the iteration.
30476// The provided context supersedes any context provided to the Context method.
30477func (c *DimensionValuesQueryCall) Pages(ctx context.Context, f func(*DimensionValueList) error) error {
30478	c.ctx_ = ctx
30479	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
30480	for {
30481		x, err := c.Do()
30482		if err != nil {
30483			return err
30484		}
30485		if err := f(x); err != nil {
30486			return err
30487		}
30488		if x.NextPageToken == "" {
30489			return nil
30490		}
30491		c.PageToken(x.NextPageToken)
30492	}
30493}
30494
30495// method id "dfareporting.directorySites.get":
30496
30497type DirectorySitesGetCall struct {
30498	s            *Service
30499	profileId    int64
30500	id           int64
30501	urlParams_   gensupport.URLParams
30502	ifNoneMatch_ string
30503	ctx_         context.Context
30504	header_      http.Header
30505}
30506
30507// Get: Gets one directory site by ID.
30508//
30509// - id: Directory site ID.
30510// - profileId: User profile ID associated with this request.
30511func (r *DirectorySitesService) Get(profileId int64, id int64) *DirectorySitesGetCall {
30512	c := &DirectorySitesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
30513	c.profileId = profileId
30514	c.id = id
30515	return c
30516}
30517
30518// Fields allows partial responses to be retrieved. See
30519// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
30520// for more information.
30521func (c *DirectorySitesGetCall) Fields(s ...googleapi.Field) *DirectorySitesGetCall {
30522	c.urlParams_.Set("fields", googleapi.CombineFields(s))
30523	return c
30524}
30525
30526// IfNoneMatch sets the optional parameter which makes the operation
30527// fail if the object's ETag matches the given value. This is useful for
30528// getting updates only after the object has changed since the last
30529// request. Use googleapi.IsNotModified to check whether the response
30530// error from Do is the result of In-None-Match.
30531func (c *DirectorySitesGetCall) IfNoneMatch(entityTag string) *DirectorySitesGetCall {
30532	c.ifNoneMatch_ = entityTag
30533	return c
30534}
30535
30536// Context sets the context to be used in this call's Do method. Any
30537// pending HTTP request will be aborted if the provided context is
30538// canceled.
30539func (c *DirectorySitesGetCall) Context(ctx context.Context) *DirectorySitesGetCall {
30540	c.ctx_ = ctx
30541	return c
30542}
30543
30544// Header returns an http.Header that can be modified by the caller to
30545// add HTTP headers to the request.
30546func (c *DirectorySitesGetCall) Header() http.Header {
30547	if c.header_ == nil {
30548		c.header_ = make(http.Header)
30549	}
30550	return c.header_
30551}
30552
30553func (c *DirectorySitesGetCall) doRequest(alt string) (*http.Response, error) {
30554	reqHeaders := make(http.Header)
30555	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
30556	for k, v := range c.header_ {
30557		reqHeaders[k] = v
30558	}
30559	reqHeaders.Set("User-Agent", c.s.userAgent())
30560	if c.ifNoneMatch_ != "" {
30561		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
30562	}
30563	var body io.Reader = nil
30564	c.urlParams_.Set("alt", alt)
30565	c.urlParams_.Set("prettyPrint", "false")
30566	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/directorySites/{id}")
30567	urls += "?" + c.urlParams_.Encode()
30568	req, err := http.NewRequest("GET", urls, body)
30569	if err != nil {
30570		return nil, err
30571	}
30572	req.Header = reqHeaders
30573	googleapi.Expand(req.URL, map[string]string{
30574		"profileId": strconv.FormatInt(c.profileId, 10),
30575		"id":        strconv.FormatInt(c.id, 10),
30576	})
30577	return gensupport.SendRequest(c.ctx_, c.s.client, req)
30578}
30579
30580// Do executes the "dfareporting.directorySites.get" call.
30581// Exactly one of *DirectorySite or error will be non-nil. Any non-2xx
30582// status code is an error. Response headers are in either
30583// *DirectorySite.ServerResponse.Header or (if a response was returned
30584// at all) in error.(*googleapi.Error).Header. Use
30585// googleapi.IsNotModified to check whether the returned error was
30586// because http.StatusNotModified was returned.
30587func (c *DirectorySitesGetCall) Do(opts ...googleapi.CallOption) (*DirectorySite, error) {
30588	gensupport.SetOptions(c.urlParams_, opts...)
30589	res, err := c.doRequest("json")
30590	if res != nil && res.StatusCode == http.StatusNotModified {
30591		if res.Body != nil {
30592			res.Body.Close()
30593		}
30594		return nil, &googleapi.Error{
30595			Code:   res.StatusCode,
30596			Header: res.Header,
30597		}
30598	}
30599	if err != nil {
30600		return nil, err
30601	}
30602	defer googleapi.CloseBody(res)
30603	if err := googleapi.CheckResponse(res); err != nil {
30604		return nil, err
30605	}
30606	ret := &DirectorySite{
30607		ServerResponse: googleapi.ServerResponse{
30608			Header:         res.Header,
30609			HTTPStatusCode: res.StatusCode,
30610		},
30611	}
30612	target := &ret
30613	if err := gensupport.DecodeResponse(target, res); err != nil {
30614		return nil, err
30615	}
30616	return ret, nil
30617	// {
30618	//   "description": "Gets one directory site by ID.",
30619	//   "flatPath": "userprofiles/{profileId}/directorySites/{id}",
30620	//   "httpMethod": "GET",
30621	//   "id": "dfareporting.directorySites.get",
30622	//   "parameterOrder": [
30623	//     "profileId",
30624	//     "id"
30625	//   ],
30626	//   "parameters": {
30627	//     "id": {
30628	//       "description": "Directory site ID.",
30629	//       "format": "int64",
30630	//       "location": "path",
30631	//       "required": true,
30632	//       "type": "string"
30633	//     },
30634	//     "profileId": {
30635	//       "description": "User profile ID associated with this request.",
30636	//       "format": "int64",
30637	//       "location": "path",
30638	//       "required": true,
30639	//       "type": "string"
30640	//     }
30641	//   },
30642	//   "path": "userprofiles/{profileId}/directorySites/{id}",
30643	//   "response": {
30644	//     "$ref": "DirectorySite"
30645	//   },
30646	//   "scopes": [
30647	//     "https://www.googleapis.com/auth/dfatrafficking"
30648	//   ]
30649	// }
30650
30651}
30652
30653// method id "dfareporting.directorySites.insert":
30654
30655type DirectorySitesInsertCall struct {
30656	s             *Service
30657	profileId     int64
30658	directorysite *DirectorySite
30659	urlParams_    gensupport.URLParams
30660	ctx_          context.Context
30661	header_       http.Header
30662}
30663
30664// Insert: Inserts a new directory site.
30665//
30666// - profileId: User profile ID associated with this request.
30667func (r *DirectorySitesService) Insert(profileId int64, directorysite *DirectorySite) *DirectorySitesInsertCall {
30668	c := &DirectorySitesInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
30669	c.profileId = profileId
30670	c.directorysite = directorysite
30671	return c
30672}
30673
30674// Fields allows partial responses to be retrieved. See
30675// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
30676// for more information.
30677func (c *DirectorySitesInsertCall) Fields(s ...googleapi.Field) *DirectorySitesInsertCall {
30678	c.urlParams_.Set("fields", googleapi.CombineFields(s))
30679	return c
30680}
30681
30682// Context sets the context to be used in this call's Do method. Any
30683// pending HTTP request will be aborted if the provided context is
30684// canceled.
30685func (c *DirectorySitesInsertCall) Context(ctx context.Context) *DirectorySitesInsertCall {
30686	c.ctx_ = ctx
30687	return c
30688}
30689
30690// Header returns an http.Header that can be modified by the caller to
30691// add HTTP headers to the request.
30692func (c *DirectorySitesInsertCall) Header() http.Header {
30693	if c.header_ == nil {
30694		c.header_ = make(http.Header)
30695	}
30696	return c.header_
30697}
30698
30699func (c *DirectorySitesInsertCall) doRequest(alt string) (*http.Response, error) {
30700	reqHeaders := make(http.Header)
30701	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
30702	for k, v := range c.header_ {
30703		reqHeaders[k] = v
30704	}
30705	reqHeaders.Set("User-Agent", c.s.userAgent())
30706	var body io.Reader = nil
30707	body, err := googleapi.WithoutDataWrapper.JSONReader(c.directorysite)
30708	if err != nil {
30709		return nil, err
30710	}
30711	reqHeaders.Set("Content-Type", "application/json")
30712	c.urlParams_.Set("alt", alt)
30713	c.urlParams_.Set("prettyPrint", "false")
30714	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/directorySites")
30715	urls += "?" + c.urlParams_.Encode()
30716	req, err := http.NewRequest("POST", urls, body)
30717	if err != nil {
30718		return nil, err
30719	}
30720	req.Header = reqHeaders
30721	googleapi.Expand(req.URL, map[string]string{
30722		"profileId": strconv.FormatInt(c.profileId, 10),
30723	})
30724	return gensupport.SendRequest(c.ctx_, c.s.client, req)
30725}
30726
30727// Do executes the "dfareporting.directorySites.insert" call.
30728// Exactly one of *DirectorySite or error will be non-nil. Any non-2xx
30729// status code is an error. Response headers are in either
30730// *DirectorySite.ServerResponse.Header or (if a response was returned
30731// at all) in error.(*googleapi.Error).Header. Use
30732// googleapi.IsNotModified to check whether the returned error was
30733// because http.StatusNotModified was returned.
30734func (c *DirectorySitesInsertCall) Do(opts ...googleapi.CallOption) (*DirectorySite, error) {
30735	gensupport.SetOptions(c.urlParams_, opts...)
30736	res, err := c.doRequest("json")
30737	if res != nil && res.StatusCode == http.StatusNotModified {
30738		if res.Body != nil {
30739			res.Body.Close()
30740		}
30741		return nil, &googleapi.Error{
30742			Code:   res.StatusCode,
30743			Header: res.Header,
30744		}
30745	}
30746	if err != nil {
30747		return nil, err
30748	}
30749	defer googleapi.CloseBody(res)
30750	if err := googleapi.CheckResponse(res); err != nil {
30751		return nil, err
30752	}
30753	ret := &DirectorySite{
30754		ServerResponse: googleapi.ServerResponse{
30755			Header:         res.Header,
30756			HTTPStatusCode: res.StatusCode,
30757		},
30758	}
30759	target := &ret
30760	if err := gensupport.DecodeResponse(target, res); err != nil {
30761		return nil, err
30762	}
30763	return ret, nil
30764	// {
30765	//   "description": "Inserts a new directory site.",
30766	//   "flatPath": "userprofiles/{profileId}/directorySites",
30767	//   "httpMethod": "POST",
30768	//   "id": "dfareporting.directorySites.insert",
30769	//   "parameterOrder": [
30770	//     "profileId"
30771	//   ],
30772	//   "parameters": {
30773	//     "profileId": {
30774	//       "description": "User profile ID associated with this request.",
30775	//       "format": "int64",
30776	//       "location": "path",
30777	//       "required": true,
30778	//       "type": "string"
30779	//     }
30780	//   },
30781	//   "path": "userprofiles/{profileId}/directorySites",
30782	//   "request": {
30783	//     "$ref": "DirectorySite"
30784	//   },
30785	//   "response": {
30786	//     "$ref": "DirectorySite"
30787	//   },
30788	//   "scopes": [
30789	//     "https://www.googleapis.com/auth/dfatrafficking"
30790	//   ]
30791	// }
30792
30793}
30794
30795// method id "dfareporting.directorySites.list":
30796
30797type DirectorySitesListCall struct {
30798	s            *Service
30799	profileId    int64
30800	urlParams_   gensupport.URLParams
30801	ifNoneMatch_ string
30802	ctx_         context.Context
30803	header_      http.Header
30804}
30805
30806// List: Retrieves a list of directory sites, possibly filtered. This
30807// method supports paging.
30808//
30809// - profileId: User profile ID associated with this request.
30810func (r *DirectorySitesService) List(profileId int64) *DirectorySitesListCall {
30811	c := &DirectorySitesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
30812	c.profileId = profileId
30813	return c
30814}
30815
30816// AcceptsInStreamVideoPlacements sets the optional parameter
30817// "acceptsInStreamVideoPlacements": This search filter is no longer
30818// supported and will have no effect on the results returned.
30819func (c *DirectorySitesListCall) AcceptsInStreamVideoPlacements(acceptsInStreamVideoPlacements bool) *DirectorySitesListCall {
30820	c.urlParams_.Set("acceptsInStreamVideoPlacements", fmt.Sprint(acceptsInStreamVideoPlacements))
30821	return c
30822}
30823
30824// AcceptsInterstitialPlacements sets the optional parameter
30825// "acceptsInterstitialPlacements": This search filter is no longer
30826// supported and will have no effect on the results returned.
30827func (c *DirectorySitesListCall) AcceptsInterstitialPlacements(acceptsInterstitialPlacements bool) *DirectorySitesListCall {
30828	c.urlParams_.Set("acceptsInterstitialPlacements", fmt.Sprint(acceptsInterstitialPlacements))
30829	return c
30830}
30831
30832// AcceptsPublisherPaidPlacements sets the optional parameter
30833// "acceptsPublisherPaidPlacements": Select only directory sites that
30834// accept publisher paid placements. This field can be left blank.
30835func (c *DirectorySitesListCall) AcceptsPublisherPaidPlacements(acceptsPublisherPaidPlacements bool) *DirectorySitesListCall {
30836	c.urlParams_.Set("acceptsPublisherPaidPlacements", fmt.Sprint(acceptsPublisherPaidPlacements))
30837	return c
30838}
30839
30840// Active sets the optional parameter "active": Select only active
30841// directory sites. Leave blank to retrieve both active and inactive
30842// directory sites.
30843func (c *DirectorySitesListCall) Active(active bool) *DirectorySitesListCall {
30844	c.urlParams_.Set("active", fmt.Sprint(active))
30845	return c
30846}
30847
30848// DfpNetworkCode sets the optional parameter "dfpNetworkCode": Select
30849// only directory sites with this Ad Manager network code.
30850func (c *DirectorySitesListCall) DfpNetworkCode(dfpNetworkCode string) *DirectorySitesListCall {
30851	c.urlParams_.Set("dfpNetworkCode", dfpNetworkCode)
30852	return c
30853}
30854
30855// Ids sets the optional parameter "ids": Select only directory sites
30856// with these IDs.
30857func (c *DirectorySitesListCall) Ids(ids ...int64) *DirectorySitesListCall {
30858	var ids_ []string
30859	for _, v := range ids {
30860		ids_ = append(ids_, fmt.Sprint(v))
30861	}
30862	c.urlParams_.SetMulti("ids", ids_)
30863	return c
30864}
30865
30866// MaxResults sets the optional parameter "maxResults": Maximum number
30867// of results to return.
30868func (c *DirectorySitesListCall) MaxResults(maxResults int64) *DirectorySitesListCall {
30869	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
30870	return c
30871}
30872
30873// PageToken sets the optional parameter "pageToken": Value of the
30874// nextPageToken from the previous result page.
30875func (c *DirectorySitesListCall) PageToken(pageToken string) *DirectorySitesListCall {
30876	c.urlParams_.Set("pageToken", pageToken)
30877	return c
30878}
30879
30880// SearchString sets the optional parameter "searchString": Allows
30881// searching for objects by name, ID or URL. Wildcards (*) are allowed.
30882// For example, "directory site*2015" will return objects with names
30883// like "directory site June 2015", "directory site April 2015", or
30884// simply "directory site 2015". Most of the searches also add wildcards
30885// implicitly at the start and the end of the search string. For
30886// example, a search string of "directory site" will match objects with
30887// name "my directory site", "directory site 2015" or simply, "directory
30888// site".
30889func (c *DirectorySitesListCall) SearchString(searchString string) *DirectorySitesListCall {
30890	c.urlParams_.Set("searchString", searchString)
30891	return c
30892}
30893
30894// SortField sets the optional parameter "sortField": Field by which to
30895// sort the list.
30896//
30897// Possible values:
30898//   "ID" (default)
30899//   "NAME"
30900func (c *DirectorySitesListCall) SortField(sortField string) *DirectorySitesListCall {
30901	c.urlParams_.Set("sortField", sortField)
30902	return c
30903}
30904
30905// SortOrder sets the optional parameter "sortOrder": Order of sorted
30906// results.
30907//
30908// Possible values:
30909//   "ASCENDING" (default)
30910//   "DESCENDING"
30911func (c *DirectorySitesListCall) SortOrder(sortOrder string) *DirectorySitesListCall {
30912	c.urlParams_.Set("sortOrder", sortOrder)
30913	return c
30914}
30915
30916// Fields allows partial responses to be retrieved. See
30917// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
30918// for more information.
30919func (c *DirectorySitesListCall) Fields(s ...googleapi.Field) *DirectorySitesListCall {
30920	c.urlParams_.Set("fields", googleapi.CombineFields(s))
30921	return c
30922}
30923
30924// IfNoneMatch sets the optional parameter which makes the operation
30925// fail if the object's ETag matches the given value. This is useful for
30926// getting updates only after the object has changed since the last
30927// request. Use googleapi.IsNotModified to check whether the response
30928// error from Do is the result of In-None-Match.
30929func (c *DirectorySitesListCall) IfNoneMatch(entityTag string) *DirectorySitesListCall {
30930	c.ifNoneMatch_ = entityTag
30931	return c
30932}
30933
30934// Context sets the context to be used in this call's Do method. Any
30935// pending HTTP request will be aborted if the provided context is
30936// canceled.
30937func (c *DirectorySitesListCall) Context(ctx context.Context) *DirectorySitesListCall {
30938	c.ctx_ = ctx
30939	return c
30940}
30941
30942// Header returns an http.Header that can be modified by the caller to
30943// add HTTP headers to the request.
30944func (c *DirectorySitesListCall) Header() http.Header {
30945	if c.header_ == nil {
30946		c.header_ = make(http.Header)
30947	}
30948	return c.header_
30949}
30950
30951func (c *DirectorySitesListCall) doRequest(alt string) (*http.Response, error) {
30952	reqHeaders := make(http.Header)
30953	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
30954	for k, v := range c.header_ {
30955		reqHeaders[k] = v
30956	}
30957	reqHeaders.Set("User-Agent", c.s.userAgent())
30958	if c.ifNoneMatch_ != "" {
30959		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
30960	}
30961	var body io.Reader = nil
30962	c.urlParams_.Set("alt", alt)
30963	c.urlParams_.Set("prettyPrint", "false")
30964	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/directorySites")
30965	urls += "?" + c.urlParams_.Encode()
30966	req, err := http.NewRequest("GET", urls, body)
30967	if err != nil {
30968		return nil, err
30969	}
30970	req.Header = reqHeaders
30971	googleapi.Expand(req.URL, map[string]string{
30972		"profileId": strconv.FormatInt(c.profileId, 10),
30973	})
30974	return gensupport.SendRequest(c.ctx_, c.s.client, req)
30975}
30976
30977// Do executes the "dfareporting.directorySites.list" call.
30978// Exactly one of *DirectorySitesListResponse or error will be non-nil.
30979// Any non-2xx status code is an error. Response headers are in either
30980// *DirectorySitesListResponse.ServerResponse.Header or (if a response
30981// was returned at all) in error.(*googleapi.Error).Header. Use
30982// googleapi.IsNotModified to check whether the returned error was
30983// because http.StatusNotModified was returned.
30984func (c *DirectorySitesListCall) Do(opts ...googleapi.CallOption) (*DirectorySitesListResponse, error) {
30985	gensupport.SetOptions(c.urlParams_, opts...)
30986	res, err := c.doRequest("json")
30987	if res != nil && res.StatusCode == http.StatusNotModified {
30988		if res.Body != nil {
30989			res.Body.Close()
30990		}
30991		return nil, &googleapi.Error{
30992			Code:   res.StatusCode,
30993			Header: res.Header,
30994		}
30995	}
30996	if err != nil {
30997		return nil, err
30998	}
30999	defer googleapi.CloseBody(res)
31000	if err := googleapi.CheckResponse(res); err != nil {
31001		return nil, err
31002	}
31003	ret := &DirectorySitesListResponse{
31004		ServerResponse: googleapi.ServerResponse{
31005			Header:         res.Header,
31006			HTTPStatusCode: res.StatusCode,
31007		},
31008	}
31009	target := &ret
31010	if err := gensupport.DecodeResponse(target, res); err != nil {
31011		return nil, err
31012	}
31013	return ret, nil
31014	// {
31015	//   "description": "Retrieves a list of directory sites, possibly filtered. This method supports paging.",
31016	//   "flatPath": "userprofiles/{profileId}/directorySites",
31017	//   "httpMethod": "GET",
31018	//   "id": "dfareporting.directorySites.list",
31019	//   "parameterOrder": [
31020	//     "profileId"
31021	//   ],
31022	//   "parameters": {
31023	//     "acceptsInStreamVideoPlacements": {
31024	//       "description": "This search filter is no longer supported and will have no effect on the results returned.",
31025	//       "location": "query",
31026	//       "type": "boolean"
31027	//     },
31028	//     "acceptsInterstitialPlacements": {
31029	//       "description": "This search filter is no longer supported and will have no effect on the results returned.",
31030	//       "location": "query",
31031	//       "type": "boolean"
31032	//     },
31033	//     "acceptsPublisherPaidPlacements": {
31034	//       "description": "Select only directory sites that accept publisher paid placements. This field can be left blank.",
31035	//       "location": "query",
31036	//       "type": "boolean"
31037	//     },
31038	//     "active": {
31039	//       "description": "Select only active directory sites. Leave blank to retrieve both active and inactive directory sites.",
31040	//       "location": "query",
31041	//       "type": "boolean"
31042	//     },
31043	//     "dfpNetworkCode": {
31044	//       "description": "Select only directory sites with this Ad Manager network code.",
31045	//       "location": "query",
31046	//       "type": "string"
31047	//     },
31048	//     "ids": {
31049	//       "description": "Select only directory sites with these IDs.",
31050	//       "format": "int64",
31051	//       "location": "query",
31052	//       "repeated": true,
31053	//       "type": "string"
31054	//     },
31055	//     "maxResults": {
31056	//       "default": "1000",
31057	//       "description": "Maximum number of results to return.",
31058	//       "format": "int32",
31059	//       "location": "query",
31060	//       "maximum": "1000",
31061	//       "minimum": "0",
31062	//       "type": "integer"
31063	//     },
31064	//     "pageToken": {
31065	//       "description": "Value of the nextPageToken from the previous result page.",
31066	//       "location": "query",
31067	//       "type": "string"
31068	//     },
31069	//     "profileId": {
31070	//       "description": "User profile ID associated with this request.",
31071	//       "format": "int64",
31072	//       "location": "path",
31073	//       "required": true,
31074	//       "type": "string"
31075	//     },
31076	//     "searchString": {
31077	//       "description": "Allows searching for objects by name, ID or URL. Wildcards (*) are allowed. For example, \"directory site*2015\" will return objects with names like \"directory site June 2015\", \"directory site April 2015\", or simply \"directory site 2015\". Most of the searches also add wildcards implicitly at the start and the end of the search string. For example, a search string of \"directory site\" will match objects with name \"my directory site\", \"directory site 2015\" or simply, \"directory site\".",
31078	//       "location": "query",
31079	//       "type": "string"
31080	//     },
31081	//     "sortField": {
31082	//       "default": "ID",
31083	//       "description": "Field by which to sort the list.",
31084	//       "enum": [
31085	//         "ID",
31086	//         "NAME"
31087	//       ],
31088	//       "enumDescriptions": [
31089	//         "",
31090	//         ""
31091	//       ],
31092	//       "location": "query",
31093	//       "type": "string"
31094	//     },
31095	//     "sortOrder": {
31096	//       "default": "ASCENDING",
31097	//       "description": "Order of sorted results.",
31098	//       "enum": [
31099	//         "ASCENDING",
31100	//         "DESCENDING"
31101	//       ],
31102	//       "enumDescriptions": [
31103	//         "",
31104	//         ""
31105	//       ],
31106	//       "location": "query",
31107	//       "type": "string"
31108	//     }
31109	//   },
31110	//   "path": "userprofiles/{profileId}/directorySites",
31111	//   "response": {
31112	//     "$ref": "DirectorySitesListResponse"
31113	//   },
31114	//   "scopes": [
31115	//     "https://www.googleapis.com/auth/dfatrafficking"
31116	//   ]
31117	// }
31118
31119}
31120
31121// Pages invokes f for each page of results.
31122// A non-nil error returned from f will halt the iteration.
31123// The provided context supersedes any context provided to the Context method.
31124func (c *DirectorySitesListCall) Pages(ctx context.Context, f func(*DirectorySitesListResponse) error) error {
31125	c.ctx_ = ctx
31126	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
31127	for {
31128		x, err := c.Do()
31129		if err != nil {
31130			return err
31131		}
31132		if err := f(x); err != nil {
31133			return err
31134		}
31135		if x.NextPageToken == "" {
31136			return nil
31137		}
31138		c.PageToken(x.NextPageToken)
31139	}
31140}
31141
31142// method id "dfareporting.dynamicTargetingKeys.delete":
31143
31144type DynamicTargetingKeysDeleteCall struct {
31145	s          *Service
31146	profileId  int64
31147	objectId   int64
31148	urlParams_ gensupport.URLParams
31149	ctx_       context.Context
31150	header_    http.Header
31151}
31152
31153// Delete: Deletes an existing dynamic targeting key.
31154//
31155// - name: Name of this dynamic targeting key. This is a required field.
31156//   Must be less than 256 characters long and cannot contain commas.
31157//   All characters are converted to lowercase.
31158// - objectId: ID of the object of this dynamic targeting key. This is a
31159//   required field.
31160// - objectType: Type of the object of this dynamic targeting key. This
31161//   is a required field.
31162// - profileId: User profile ID associated with this request.
31163func (r *DynamicTargetingKeysService) Delete(profileId int64, objectId int64, name string, objectType string) *DynamicTargetingKeysDeleteCall {
31164	c := &DynamicTargetingKeysDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
31165	c.profileId = profileId
31166	c.objectId = objectId
31167	c.urlParams_.Set("name", name)
31168	c.urlParams_.Set("objectType", objectType)
31169	return c
31170}
31171
31172// Fields allows partial responses to be retrieved. See
31173// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
31174// for more information.
31175func (c *DynamicTargetingKeysDeleteCall) Fields(s ...googleapi.Field) *DynamicTargetingKeysDeleteCall {
31176	c.urlParams_.Set("fields", googleapi.CombineFields(s))
31177	return c
31178}
31179
31180// Context sets the context to be used in this call's Do method. Any
31181// pending HTTP request will be aborted if the provided context is
31182// canceled.
31183func (c *DynamicTargetingKeysDeleteCall) Context(ctx context.Context) *DynamicTargetingKeysDeleteCall {
31184	c.ctx_ = ctx
31185	return c
31186}
31187
31188// Header returns an http.Header that can be modified by the caller to
31189// add HTTP headers to the request.
31190func (c *DynamicTargetingKeysDeleteCall) Header() http.Header {
31191	if c.header_ == nil {
31192		c.header_ = make(http.Header)
31193	}
31194	return c.header_
31195}
31196
31197func (c *DynamicTargetingKeysDeleteCall) doRequest(alt string) (*http.Response, error) {
31198	reqHeaders := make(http.Header)
31199	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
31200	for k, v := range c.header_ {
31201		reqHeaders[k] = v
31202	}
31203	reqHeaders.Set("User-Agent", c.s.userAgent())
31204	var body io.Reader = nil
31205	c.urlParams_.Set("alt", alt)
31206	c.urlParams_.Set("prettyPrint", "false")
31207	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/dynamicTargetingKeys/{objectId}")
31208	urls += "?" + c.urlParams_.Encode()
31209	req, err := http.NewRequest("DELETE", urls, body)
31210	if err != nil {
31211		return nil, err
31212	}
31213	req.Header = reqHeaders
31214	googleapi.Expand(req.URL, map[string]string{
31215		"profileId": strconv.FormatInt(c.profileId, 10),
31216		"objectId":  strconv.FormatInt(c.objectId, 10),
31217	})
31218	return gensupport.SendRequest(c.ctx_, c.s.client, req)
31219}
31220
31221// Do executes the "dfareporting.dynamicTargetingKeys.delete" call.
31222func (c *DynamicTargetingKeysDeleteCall) Do(opts ...googleapi.CallOption) error {
31223	gensupport.SetOptions(c.urlParams_, opts...)
31224	res, err := c.doRequest("json")
31225	if err != nil {
31226		return err
31227	}
31228	defer googleapi.CloseBody(res)
31229	if err := googleapi.CheckResponse(res); err != nil {
31230		return err
31231	}
31232	return nil
31233	// {
31234	//   "description": "Deletes an existing dynamic targeting key.",
31235	//   "flatPath": "userprofiles/{profileId}/dynamicTargetingKeys/{objectId}",
31236	//   "httpMethod": "DELETE",
31237	//   "id": "dfareporting.dynamicTargetingKeys.delete",
31238	//   "parameterOrder": [
31239	//     "profileId",
31240	//     "objectId",
31241	//     "name",
31242	//     "objectType"
31243	//   ],
31244	//   "parameters": {
31245	//     "name": {
31246	//       "description": "Name of this dynamic targeting key. This is a required field. Must be less than 256 characters long and cannot contain commas. All characters are converted to lowercase.",
31247	//       "location": "query",
31248	//       "required": true,
31249	//       "type": "string"
31250	//     },
31251	//     "objectId": {
31252	//       "description": "ID of the object of this dynamic targeting key. This is a required field.",
31253	//       "format": "int64",
31254	//       "location": "path",
31255	//       "required": true,
31256	//       "type": "string"
31257	//     },
31258	//     "objectType": {
31259	//       "description": "Type of the object of this dynamic targeting key. This is a required field.",
31260	//       "enum": [
31261	//         "OBJECT_ADVERTISER",
31262	//         "OBJECT_AD",
31263	//         "OBJECT_CREATIVE",
31264	//         "OBJECT_PLACEMENT"
31265	//       ],
31266	//       "enumDescriptions": [
31267	//         "",
31268	//         "",
31269	//         "",
31270	//         ""
31271	//       ],
31272	//       "location": "query",
31273	//       "required": true,
31274	//       "type": "string"
31275	//     },
31276	//     "profileId": {
31277	//       "description": "User profile ID associated with this request.",
31278	//       "format": "int64",
31279	//       "location": "path",
31280	//       "required": true,
31281	//       "type": "string"
31282	//     }
31283	//   },
31284	//   "path": "userprofiles/{profileId}/dynamicTargetingKeys/{objectId}",
31285	//   "scopes": [
31286	//     "https://www.googleapis.com/auth/dfatrafficking"
31287	//   ]
31288	// }
31289
31290}
31291
31292// method id "dfareporting.dynamicTargetingKeys.insert":
31293
31294type DynamicTargetingKeysInsertCall struct {
31295	s                   *Service
31296	profileId           int64
31297	dynamictargetingkey *DynamicTargetingKey
31298	urlParams_          gensupport.URLParams
31299	ctx_                context.Context
31300	header_             http.Header
31301}
31302
31303// Insert: Inserts a new dynamic targeting key. Keys must be created at
31304// the advertiser level before being assigned to the advertiser's ads,
31305// creatives, or placements. There is a maximum of 1000 keys per
31306// advertiser, out of which a maximum of 20 keys can be assigned per ad,
31307// creative, or placement.
31308//
31309// - profileId: User profile ID associated with this request.
31310func (r *DynamicTargetingKeysService) Insert(profileId int64, dynamictargetingkey *DynamicTargetingKey) *DynamicTargetingKeysInsertCall {
31311	c := &DynamicTargetingKeysInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
31312	c.profileId = profileId
31313	c.dynamictargetingkey = dynamictargetingkey
31314	return c
31315}
31316
31317// Fields allows partial responses to be retrieved. See
31318// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
31319// for more information.
31320func (c *DynamicTargetingKeysInsertCall) Fields(s ...googleapi.Field) *DynamicTargetingKeysInsertCall {
31321	c.urlParams_.Set("fields", googleapi.CombineFields(s))
31322	return c
31323}
31324
31325// Context sets the context to be used in this call's Do method. Any
31326// pending HTTP request will be aborted if the provided context is
31327// canceled.
31328func (c *DynamicTargetingKeysInsertCall) Context(ctx context.Context) *DynamicTargetingKeysInsertCall {
31329	c.ctx_ = ctx
31330	return c
31331}
31332
31333// Header returns an http.Header that can be modified by the caller to
31334// add HTTP headers to the request.
31335func (c *DynamicTargetingKeysInsertCall) Header() http.Header {
31336	if c.header_ == nil {
31337		c.header_ = make(http.Header)
31338	}
31339	return c.header_
31340}
31341
31342func (c *DynamicTargetingKeysInsertCall) doRequest(alt string) (*http.Response, error) {
31343	reqHeaders := make(http.Header)
31344	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
31345	for k, v := range c.header_ {
31346		reqHeaders[k] = v
31347	}
31348	reqHeaders.Set("User-Agent", c.s.userAgent())
31349	var body io.Reader = nil
31350	body, err := googleapi.WithoutDataWrapper.JSONReader(c.dynamictargetingkey)
31351	if err != nil {
31352		return nil, err
31353	}
31354	reqHeaders.Set("Content-Type", "application/json")
31355	c.urlParams_.Set("alt", alt)
31356	c.urlParams_.Set("prettyPrint", "false")
31357	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/dynamicTargetingKeys")
31358	urls += "?" + c.urlParams_.Encode()
31359	req, err := http.NewRequest("POST", urls, body)
31360	if err != nil {
31361		return nil, err
31362	}
31363	req.Header = reqHeaders
31364	googleapi.Expand(req.URL, map[string]string{
31365		"profileId": strconv.FormatInt(c.profileId, 10),
31366	})
31367	return gensupport.SendRequest(c.ctx_, c.s.client, req)
31368}
31369
31370// Do executes the "dfareporting.dynamicTargetingKeys.insert" call.
31371// Exactly one of *DynamicTargetingKey or error will be non-nil. Any
31372// non-2xx status code is an error. Response headers are in either
31373// *DynamicTargetingKey.ServerResponse.Header or (if a response was
31374// returned at all) in error.(*googleapi.Error).Header. Use
31375// googleapi.IsNotModified to check whether the returned error was
31376// because http.StatusNotModified was returned.
31377func (c *DynamicTargetingKeysInsertCall) Do(opts ...googleapi.CallOption) (*DynamicTargetingKey, error) {
31378	gensupport.SetOptions(c.urlParams_, opts...)
31379	res, err := c.doRequest("json")
31380	if res != nil && res.StatusCode == http.StatusNotModified {
31381		if res.Body != nil {
31382			res.Body.Close()
31383		}
31384		return nil, &googleapi.Error{
31385			Code:   res.StatusCode,
31386			Header: res.Header,
31387		}
31388	}
31389	if err != nil {
31390		return nil, err
31391	}
31392	defer googleapi.CloseBody(res)
31393	if err := googleapi.CheckResponse(res); err != nil {
31394		return nil, err
31395	}
31396	ret := &DynamicTargetingKey{
31397		ServerResponse: googleapi.ServerResponse{
31398			Header:         res.Header,
31399			HTTPStatusCode: res.StatusCode,
31400		},
31401	}
31402	target := &ret
31403	if err := gensupport.DecodeResponse(target, res); err != nil {
31404		return nil, err
31405	}
31406	return ret, nil
31407	// {
31408	//   "description": "Inserts a new dynamic targeting key. Keys must be created at the advertiser level before being assigned to the advertiser's ads, creatives, or placements. There is a maximum of 1000 keys per advertiser, out of which a maximum of 20 keys can be assigned per ad, creative, or placement.",
31409	//   "flatPath": "userprofiles/{profileId}/dynamicTargetingKeys",
31410	//   "httpMethod": "POST",
31411	//   "id": "dfareporting.dynamicTargetingKeys.insert",
31412	//   "parameterOrder": [
31413	//     "profileId"
31414	//   ],
31415	//   "parameters": {
31416	//     "profileId": {
31417	//       "description": "User profile ID associated with this request.",
31418	//       "format": "int64",
31419	//       "location": "path",
31420	//       "required": true,
31421	//       "type": "string"
31422	//     }
31423	//   },
31424	//   "path": "userprofiles/{profileId}/dynamicTargetingKeys",
31425	//   "request": {
31426	//     "$ref": "DynamicTargetingKey"
31427	//   },
31428	//   "response": {
31429	//     "$ref": "DynamicTargetingKey"
31430	//   },
31431	//   "scopes": [
31432	//     "https://www.googleapis.com/auth/dfatrafficking"
31433	//   ]
31434	// }
31435
31436}
31437
31438// method id "dfareporting.dynamicTargetingKeys.list":
31439
31440type DynamicTargetingKeysListCall struct {
31441	s            *Service
31442	profileId    int64
31443	urlParams_   gensupport.URLParams
31444	ifNoneMatch_ string
31445	ctx_         context.Context
31446	header_      http.Header
31447}
31448
31449// List: Retrieves a list of dynamic targeting keys.
31450//
31451// - profileId: User profile ID associated with this request.
31452func (r *DynamicTargetingKeysService) List(profileId int64) *DynamicTargetingKeysListCall {
31453	c := &DynamicTargetingKeysListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
31454	c.profileId = profileId
31455	return c
31456}
31457
31458// AdvertiserId sets the optional parameter "advertiserId": Select only
31459// dynamic targeting keys whose object has this advertiser ID.
31460func (c *DynamicTargetingKeysListCall) AdvertiserId(advertiserId int64) *DynamicTargetingKeysListCall {
31461	c.urlParams_.Set("advertiserId", fmt.Sprint(advertiserId))
31462	return c
31463}
31464
31465// Names sets the optional parameter "names": Select only dynamic
31466// targeting keys exactly matching these names.
31467func (c *DynamicTargetingKeysListCall) Names(names ...string) *DynamicTargetingKeysListCall {
31468	c.urlParams_.SetMulti("names", append([]string{}, names...))
31469	return c
31470}
31471
31472// ObjectId sets the optional parameter "objectId": Select only dynamic
31473// targeting keys with this object ID.
31474func (c *DynamicTargetingKeysListCall) ObjectId(objectId int64) *DynamicTargetingKeysListCall {
31475	c.urlParams_.Set("objectId", fmt.Sprint(objectId))
31476	return c
31477}
31478
31479// ObjectType sets the optional parameter "objectType": Select only
31480// dynamic targeting keys with this object type.
31481//
31482// Possible values:
31483//   "OBJECT_ADVERTISER"
31484//   "OBJECT_AD"
31485//   "OBJECT_CREATIVE"
31486//   "OBJECT_PLACEMENT"
31487func (c *DynamicTargetingKeysListCall) ObjectType(objectType string) *DynamicTargetingKeysListCall {
31488	c.urlParams_.Set("objectType", objectType)
31489	return c
31490}
31491
31492// Fields allows partial responses to be retrieved. See
31493// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
31494// for more information.
31495func (c *DynamicTargetingKeysListCall) Fields(s ...googleapi.Field) *DynamicTargetingKeysListCall {
31496	c.urlParams_.Set("fields", googleapi.CombineFields(s))
31497	return c
31498}
31499
31500// IfNoneMatch sets the optional parameter which makes the operation
31501// fail if the object's ETag matches the given value. This is useful for
31502// getting updates only after the object has changed since the last
31503// request. Use googleapi.IsNotModified to check whether the response
31504// error from Do is the result of In-None-Match.
31505func (c *DynamicTargetingKeysListCall) IfNoneMatch(entityTag string) *DynamicTargetingKeysListCall {
31506	c.ifNoneMatch_ = entityTag
31507	return c
31508}
31509
31510// Context sets the context to be used in this call's Do method. Any
31511// pending HTTP request will be aborted if the provided context is
31512// canceled.
31513func (c *DynamicTargetingKeysListCall) Context(ctx context.Context) *DynamicTargetingKeysListCall {
31514	c.ctx_ = ctx
31515	return c
31516}
31517
31518// Header returns an http.Header that can be modified by the caller to
31519// add HTTP headers to the request.
31520func (c *DynamicTargetingKeysListCall) Header() http.Header {
31521	if c.header_ == nil {
31522		c.header_ = make(http.Header)
31523	}
31524	return c.header_
31525}
31526
31527func (c *DynamicTargetingKeysListCall) doRequest(alt string) (*http.Response, error) {
31528	reqHeaders := make(http.Header)
31529	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
31530	for k, v := range c.header_ {
31531		reqHeaders[k] = v
31532	}
31533	reqHeaders.Set("User-Agent", c.s.userAgent())
31534	if c.ifNoneMatch_ != "" {
31535		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
31536	}
31537	var body io.Reader = nil
31538	c.urlParams_.Set("alt", alt)
31539	c.urlParams_.Set("prettyPrint", "false")
31540	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/dynamicTargetingKeys")
31541	urls += "?" + c.urlParams_.Encode()
31542	req, err := http.NewRequest("GET", urls, body)
31543	if err != nil {
31544		return nil, err
31545	}
31546	req.Header = reqHeaders
31547	googleapi.Expand(req.URL, map[string]string{
31548		"profileId": strconv.FormatInt(c.profileId, 10),
31549	})
31550	return gensupport.SendRequest(c.ctx_, c.s.client, req)
31551}
31552
31553// Do executes the "dfareporting.dynamicTargetingKeys.list" call.
31554// Exactly one of *DynamicTargetingKeysListResponse or error will be
31555// non-nil. Any non-2xx status code is an error. Response headers are in
31556// either *DynamicTargetingKeysListResponse.ServerResponse.Header or (if
31557// a response was returned at all) in error.(*googleapi.Error).Header.
31558// Use googleapi.IsNotModified to check whether the returned error was
31559// because http.StatusNotModified was returned.
31560func (c *DynamicTargetingKeysListCall) Do(opts ...googleapi.CallOption) (*DynamicTargetingKeysListResponse, error) {
31561	gensupport.SetOptions(c.urlParams_, opts...)
31562	res, err := c.doRequest("json")
31563	if res != nil && res.StatusCode == http.StatusNotModified {
31564		if res.Body != nil {
31565			res.Body.Close()
31566		}
31567		return nil, &googleapi.Error{
31568			Code:   res.StatusCode,
31569			Header: res.Header,
31570		}
31571	}
31572	if err != nil {
31573		return nil, err
31574	}
31575	defer googleapi.CloseBody(res)
31576	if err := googleapi.CheckResponse(res); err != nil {
31577		return nil, err
31578	}
31579	ret := &DynamicTargetingKeysListResponse{
31580		ServerResponse: googleapi.ServerResponse{
31581			Header:         res.Header,
31582			HTTPStatusCode: res.StatusCode,
31583		},
31584	}
31585	target := &ret
31586	if err := gensupport.DecodeResponse(target, res); err != nil {
31587		return nil, err
31588	}
31589	return ret, nil
31590	// {
31591	//   "description": "Retrieves a list of dynamic targeting keys.",
31592	//   "flatPath": "userprofiles/{profileId}/dynamicTargetingKeys",
31593	//   "httpMethod": "GET",
31594	//   "id": "dfareporting.dynamicTargetingKeys.list",
31595	//   "parameterOrder": [
31596	//     "profileId"
31597	//   ],
31598	//   "parameters": {
31599	//     "advertiserId": {
31600	//       "description": "Select only dynamic targeting keys whose object has this advertiser ID.",
31601	//       "format": "int64",
31602	//       "location": "query",
31603	//       "type": "string"
31604	//     },
31605	//     "names": {
31606	//       "description": "Select only dynamic targeting keys exactly matching these names.",
31607	//       "location": "query",
31608	//       "repeated": true,
31609	//       "type": "string"
31610	//     },
31611	//     "objectId": {
31612	//       "description": "Select only dynamic targeting keys with this object ID.",
31613	//       "format": "int64",
31614	//       "location": "query",
31615	//       "type": "string"
31616	//     },
31617	//     "objectType": {
31618	//       "description": "Select only dynamic targeting keys with this object type.",
31619	//       "enum": [
31620	//         "OBJECT_ADVERTISER",
31621	//         "OBJECT_AD",
31622	//         "OBJECT_CREATIVE",
31623	//         "OBJECT_PLACEMENT"
31624	//       ],
31625	//       "enumDescriptions": [
31626	//         "",
31627	//         "",
31628	//         "",
31629	//         ""
31630	//       ],
31631	//       "location": "query",
31632	//       "type": "string"
31633	//     },
31634	//     "profileId": {
31635	//       "description": "User profile ID associated with this request.",
31636	//       "format": "int64",
31637	//       "location": "path",
31638	//       "required": true,
31639	//       "type": "string"
31640	//     }
31641	//   },
31642	//   "path": "userprofiles/{profileId}/dynamicTargetingKeys",
31643	//   "response": {
31644	//     "$ref": "DynamicTargetingKeysListResponse"
31645	//   },
31646	//   "scopes": [
31647	//     "https://www.googleapis.com/auth/dfatrafficking"
31648	//   ]
31649	// }
31650
31651}
31652
31653// method id "dfareporting.eventTags.delete":
31654
31655type EventTagsDeleteCall struct {
31656	s          *Service
31657	profileId  int64
31658	id         int64
31659	urlParams_ gensupport.URLParams
31660	ctx_       context.Context
31661	header_    http.Header
31662}
31663
31664// Delete: Deletes an existing event tag.
31665//
31666// - id: Event tag ID.
31667// - profileId: User profile ID associated with this request.
31668func (r *EventTagsService) Delete(profileId int64, id int64) *EventTagsDeleteCall {
31669	c := &EventTagsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
31670	c.profileId = profileId
31671	c.id = id
31672	return c
31673}
31674
31675// Fields allows partial responses to be retrieved. See
31676// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
31677// for more information.
31678func (c *EventTagsDeleteCall) Fields(s ...googleapi.Field) *EventTagsDeleteCall {
31679	c.urlParams_.Set("fields", googleapi.CombineFields(s))
31680	return c
31681}
31682
31683// Context sets the context to be used in this call's Do method. Any
31684// pending HTTP request will be aborted if the provided context is
31685// canceled.
31686func (c *EventTagsDeleteCall) Context(ctx context.Context) *EventTagsDeleteCall {
31687	c.ctx_ = ctx
31688	return c
31689}
31690
31691// Header returns an http.Header that can be modified by the caller to
31692// add HTTP headers to the request.
31693func (c *EventTagsDeleteCall) Header() http.Header {
31694	if c.header_ == nil {
31695		c.header_ = make(http.Header)
31696	}
31697	return c.header_
31698}
31699
31700func (c *EventTagsDeleteCall) doRequest(alt string) (*http.Response, error) {
31701	reqHeaders := make(http.Header)
31702	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
31703	for k, v := range c.header_ {
31704		reqHeaders[k] = v
31705	}
31706	reqHeaders.Set("User-Agent", c.s.userAgent())
31707	var body io.Reader = nil
31708	c.urlParams_.Set("alt", alt)
31709	c.urlParams_.Set("prettyPrint", "false")
31710	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/eventTags/{id}")
31711	urls += "?" + c.urlParams_.Encode()
31712	req, err := http.NewRequest("DELETE", urls, body)
31713	if err != nil {
31714		return nil, err
31715	}
31716	req.Header = reqHeaders
31717	googleapi.Expand(req.URL, map[string]string{
31718		"profileId": strconv.FormatInt(c.profileId, 10),
31719		"id":        strconv.FormatInt(c.id, 10),
31720	})
31721	return gensupport.SendRequest(c.ctx_, c.s.client, req)
31722}
31723
31724// Do executes the "dfareporting.eventTags.delete" call.
31725func (c *EventTagsDeleteCall) Do(opts ...googleapi.CallOption) error {
31726	gensupport.SetOptions(c.urlParams_, opts...)
31727	res, err := c.doRequest("json")
31728	if err != nil {
31729		return err
31730	}
31731	defer googleapi.CloseBody(res)
31732	if err := googleapi.CheckResponse(res); err != nil {
31733		return err
31734	}
31735	return nil
31736	// {
31737	//   "description": "Deletes an existing event tag.",
31738	//   "flatPath": "userprofiles/{profileId}/eventTags/{id}",
31739	//   "httpMethod": "DELETE",
31740	//   "id": "dfareporting.eventTags.delete",
31741	//   "parameterOrder": [
31742	//     "profileId",
31743	//     "id"
31744	//   ],
31745	//   "parameters": {
31746	//     "id": {
31747	//       "description": "Event tag ID.",
31748	//       "format": "int64",
31749	//       "location": "path",
31750	//       "required": true,
31751	//       "type": "string"
31752	//     },
31753	//     "profileId": {
31754	//       "description": "User profile ID associated with this request.",
31755	//       "format": "int64",
31756	//       "location": "path",
31757	//       "required": true,
31758	//       "type": "string"
31759	//     }
31760	//   },
31761	//   "path": "userprofiles/{profileId}/eventTags/{id}",
31762	//   "scopes": [
31763	//     "https://www.googleapis.com/auth/dfatrafficking"
31764	//   ]
31765	// }
31766
31767}
31768
31769// method id "dfareporting.eventTags.get":
31770
31771type EventTagsGetCall struct {
31772	s            *Service
31773	profileId    int64
31774	id           int64
31775	urlParams_   gensupport.URLParams
31776	ifNoneMatch_ string
31777	ctx_         context.Context
31778	header_      http.Header
31779}
31780
31781// Get: Gets one event tag by ID.
31782//
31783// - id: Event tag ID.
31784// - profileId: User profile ID associated with this request.
31785func (r *EventTagsService) Get(profileId int64, id int64) *EventTagsGetCall {
31786	c := &EventTagsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
31787	c.profileId = profileId
31788	c.id = id
31789	return c
31790}
31791
31792// Fields allows partial responses to be retrieved. See
31793// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
31794// for more information.
31795func (c *EventTagsGetCall) Fields(s ...googleapi.Field) *EventTagsGetCall {
31796	c.urlParams_.Set("fields", googleapi.CombineFields(s))
31797	return c
31798}
31799
31800// IfNoneMatch sets the optional parameter which makes the operation
31801// fail if the object's ETag matches the given value. This is useful for
31802// getting updates only after the object has changed since the last
31803// request. Use googleapi.IsNotModified to check whether the response
31804// error from Do is the result of In-None-Match.
31805func (c *EventTagsGetCall) IfNoneMatch(entityTag string) *EventTagsGetCall {
31806	c.ifNoneMatch_ = entityTag
31807	return c
31808}
31809
31810// Context sets the context to be used in this call's Do method. Any
31811// pending HTTP request will be aborted if the provided context is
31812// canceled.
31813func (c *EventTagsGetCall) Context(ctx context.Context) *EventTagsGetCall {
31814	c.ctx_ = ctx
31815	return c
31816}
31817
31818// Header returns an http.Header that can be modified by the caller to
31819// add HTTP headers to the request.
31820func (c *EventTagsGetCall) Header() http.Header {
31821	if c.header_ == nil {
31822		c.header_ = make(http.Header)
31823	}
31824	return c.header_
31825}
31826
31827func (c *EventTagsGetCall) doRequest(alt string) (*http.Response, error) {
31828	reqHeaders := make(http.Header)
31829	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
31830	for k, v := range c.header_ {
31831		reqHeaders[k] = v
31832	}
31833	reqHeaders.Set("User-Agent", c.s.userAgent())
31834	if c.ifNoneMatch_ != "" {
31835		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
31836	}
31837	var body io.Reader = nil
31838	c.urlParams_.Set("alt", alt)
31839	c.urlParams_.Set("prettyPrint", "false")
31840	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/eventTags/{id}")
31841	urls += "?" + c.urlParams_.Encode()
31842	req, err := http.NewRequest("GET", urls, body)
31843	if err != nil {
31844		return nil, err
31845	}
31846	req.Header = reqHeaders
31847	googleapi.Expand(req.URL, map[string]string{
31848		"profileId": strconv.FormatInt(c.profileId, 10),
31849		"id":        strconv.FormatInt(c.id, 10),
31850	})
31851	return gensupport.SendRequest(c.ctx_, c.s.client, req)
31852}
31853
31854// Do executes the "dfareporting.eventTags.get" call.
31855// Exactly one of *EventTag or error will be non-nil. Any non-2xx status
31856// code is an error. Response headers are in either
31857// *EventTag.ServerResponse.Header or (if a response was returned at
31858// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
31859// to check whether the returned error was because
31860// http.StatusNotModified was returned.
31861func (c *EventTagsGetCall) Do(opts ...googleapi.CallOption) (*EventTag, error) {
31862	gensupport.SetOptions(c.urlParams_, opts...)
31863	res, err := c.doRequest("json")
31864	if res != nil && res.StatusCode == http.StatusNotModified {
31865		if res.Body != nil {
31866			res.Body.Close()
31867		}
31868		return nil, &googleapi.Error{
31869			Code:   res.StatusCode,
31870			Header: res.Header,
31871		}
31872	}
31873	if err != nil {
31874		return nil, err
31875	}
31876	defer googleapi.CloseBody(res)
31877	if err := googleapi.CheckResponse(res); err != nil {
31878		return nil, err
31879	}
31880	ret := &EventTag{
31881		ServerResponse: googleapi.ServerResponse{
31882			Header:         res.Header,
31883			HTTPStatusCode: res.StatusCode,
31884		},
31885	}
31886	target := &ret
31887	if err := gensupport.DecodeResponse(target, res); err != nil {
31888		return nil, err
31889	}
31890	return ret, nil
31891	// {
31892	//   "description": "Gets one event tag by ID.",
31893	//   "flatPath": "userprofiles/{profileId}/eventTags/{id}",
31894	//   "httpMethod": "GET",
31895	//   "id": "dfareporting.eventTags.get",
31896	//   "parameterOrder": [
31897	//     "profileId",
31898	//     "id"
31899	//   ],
31900	//   "parameters": {
31901	//     "id": {
31902	//       "description": "Event tag ID.",
31903	//       "format": "int64",
31904	//       "location": "path",
31905	//       "required": true,
31906	//       "type": "string"
31907	//     },
31908	//     "profileId": {
31909	//       "description": "User profile ID associated with this request.",
31910	//       "format": "int64",
31911	//       "location": "path",
31912	//       "required": true,
31913	//       "type": "string"
31914	//     }
31915	//   },
31916	//   "path": "userprofiles/{profileId}/eventTags/{id}",
31917	//   "response": {
31918	//     "$ref": "EventTag"
31919	//   },
31920	//   "scopes": [
31921	//     "https://www.googleapis.com/auth/dfatrafficking"
31922	//   ]
31923	// }
31924
31925}
31926
31927// method id "dfareporting.eventTags.insert":
31928
31929type EventTagsInsertCall struct {
31930	s          *Service
31931	profileId  int64
31932	eventtag   *EventTag
31933	urlParams_ gensupport.URLParams
31934	ctx_       context.Context
31935	header_    http.Header
31936}
31937
31938// Insert: Inserts a new event tag.
31939//
31940// - profileId: User profile ID associated with this request.
31941func (r *EventTagsService) Insert(profileId int64, eventtag *EventTag) *EventTagsInsertCall {
31942	c := &EventTagsInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
31943	c.profileId = profileId
31944	c.eventtag = eventtag
31945	return c
31946}
31947
31948// Fields allows partial responses to be retrieved. See
31949// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
31950// for more information.
31951func (c *EventTagsInsertCall) Fields(s ...googleapi.Field) *EventTagsInsertCall {
31952	c.urlParams_.Set("fields", googleapi.CombineFields(s))
31953	return c
31954}
31955
31956// Context sets the context to be used in this call's Do method. Any
31957// pending HTTP request will be aborted if the provided context is
31958// canceled.
31959func (c *EventTagsInsertCall) Context(ctx context.Context) *EventTagsInsertCall {
31960	c.ctx_ = ctx
31961	return c
31962}
31963
31964// Header returns an http.Header that can be modified by the caller to
31965// add HTTP headers to the request.
31966func (c *EventTagsInsertCall) Header() http.Header {
31967	if c.header_ == nil {
31968		c.header_ = make(http.Header)
31969	}
31970	return c.header_
31971}
31972
31973func (c *EventTagsInsertCall) doRequest(alt string) (*http.Response, error) {
31974	reqHeaders := make(http.Header)
31975	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
31976	for k, v := range c.header_ {
31977		reqHeaders[k] = v
31978	}
31979	reqHeaders.Set("User-Agent", c.s.userAgent())
31980	var body io.Reader = nil
31981	body, err := googleapi.WithoutDataWrapper.JSONReader(c.eventtag)
31982	if err != nil {
31983		return nil, err
31984	}
31985	reqHeaders.Set("Content-Type", "application/json")
31986	c.urlParams_.Set("alt", alt)
31987	c.urlParams_.Set("prettyPrint", "false")
31988	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/eventTags")
31989	urls += "?" + c.urlParams_.Encode()
31990	req, err := http.NewRequest("POST", urls, body)
31991	if err != nil {
31992		return nil, err
31993	}
31994	req.Header = reqHeaders
31995	googleapi.Expand(req.URL, map[string]string{
31996		"profileId": strconv.FormatInt(c.profileId, 10),
31997	})
31998	return gensupport.SendRequest(c.ctx_, c.s.client, req)
31999}
32000
32001// Do executes the "dfareporting.eventTags.insert" call.
32002// Exactly one of *EventTag or error will be non-nil. Any non-2xx status
32003// code is an error. Response headers are in either
32004// *EventTag.ServerResponse.Header or (if a response was returned at
32005// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
32006// to check whether the returned error was because
32007// http.StatusNotModified was returned.
32008func (c *EventTagsInsertCall) Do(opts ...googleapi.CallOption) (*EventTag, error) {
32009	gensupport.SetOptions(c.urlParams_, opts...)
32010	res, err := c.doRequest("json")
32011	if res != nil && res.StatusCode == http.StatusNotModified {
32012		if res.Body != nil {
32013			res.Body.Close()
32014		}
32015		return nil, &googleapi.Error{
32016			Code:   res.StatusCode,
32017			Header: res.Header,
32018		}
32019	}
32020	if err != nil {
32021		return nil, err
32022	}
32023	defer googleapi.CloseBody(res)
32024	if err := googleapi.CheckResponse(res); err != nil {
32025		return nil, err
32026	}
32027	ret := &EventTag{
32028		ServerResponse: googleapi.ServerResponse{
32029			Header:         res.Header,
32030			HTTPStatusCode: res.StatusCode,
32031		},
32032	}
32033	target := &ret
32034	if err := gensupport.DecodeResponse(target, res); err != nil {
32035		return nil, err
32036	}
32037	return ret, nil
32038	// {
32039	//   "description": "Inserts a new event tag.",
32040	//   "flatPath": "userprofiles/{profileId}/eventTags",
32041	//   "httpMethod": "POST",
32042	//   "id": "dfareporting.eventTags.insert",
32043	//   "parameterOrder": [
32044	//     "profileId"
32045	//   ],
32046	//   "parameters": {
32047	//     "profileId": {
32048	//       "description": "User profile ID associated with this request.",
32049	//       "format": "int64",
32050	//       "location": "path",
32051	//       "required": true,
32052	//       "type": "string"
32053	//     }
32054	//   },
32055	//   "path": "userprofiles/{profileId}/eventTags",
32056	//   "request": {
32057	//     "$ref": "EventTag"
32058	//   },
32059	//   "response": {
32060	//     "$ref": "EventTag"
32061	//   },
32062	//   "scopes": [
32063	//     "https://www.googleapis.com/auth/dfatrafficking"
32064	//   ]
32065	// }
32066
32067}
32068
32069// method id "dfareporting.eventTags.list":
32070
32071type EventTagsListCall struct {
32072	s            *Service
32073	profileId    int64
32074	urlParams_   gensupport.URLParams
32075	ifNoneMatch_ string
32076	ctx_         context.Context
32077	header_      http.Header
32078}
32079
32080// List: Retrieves a list of event tags, possibly filtered.
32081//
32082// - profileId: User profile ID associated with this request.
32083func (r *EventTagsService) List(profileId int64) *EventTagsListCall {
32084	c := &EventTagsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
32085	c.profileId = profileId
32086	return c
32087}
32088
32089// AdId sets the optional parameter "adId": Select only event tags that
32090// belong to this ad.
32091func (c *EventTagsListCall) AdId(adId int64) *EventTagsListCall {
32092	c.urlParams_.Set("adId", fmt.Sprint(adId))
32093	return c
32094}
32095
32096// AdvertiserId sets the optional parameter "advertiserId": Select only
32097// event tags that belong to this advertiser.
32098func (c *EventTagsListCall) AdvertiserId(advertiserId int64) *EventTagsListCall {
32099	c.urlParams_.Set("advertiserId", fmt.Sprint(advertiserId))
32100	return c
32101}
32102
32103// CampaignId sets the optional parameter "campaignId": Select only
32104// event tags that belong to this campaign.
32105func (c *EventTagsListCall) CampaignId(campaignId int64) *EventTagsListCall {
32106	c.urlParams_.Set("campaignId", fmt.Sprint(campaignId))
32107	return c
32108}
32109
32110// DefinitionsOnly sets the optional parameter "definitionsOnly":
32111// Examine only the specified campaign or advertiser's event tags for
32112// matching selector criteria. When set to false, the parent advertiser
32113// and parent campaign of the specified ad or campaign is examined as
32114// well. In addition, when set to false, the status field is examined as
32115// well, along with the enabledByDefault field. This parameter can not
32116// be set to true when adId is specified as ads do not define their own
32117// even tags.
32118func (c *EventTagsListCall) DefinitionsOnly(definitionsOnly bool) *EventTagsListCall {
32119	c.urlParams_.Set("definitionsOnly", fmt.Sprint(definitionsOnly))
32120	return c
32121}
32122
32123// Enabled sets the optional parameter "enabled": Select only enabled
32124// event tags. What is considered enabled or disabled depends on the
32125// definitionsOnly parameter. When definitionsOnly is set to true, only
32126// the specified advertiser or campaign's event tags' enabledByDefault
32127// field is examined. When definitionsOnly is set to false, the
32128// specified ad or specified campaign's parent advertiser's or parent
32129// campaign's event tags' enabledByDefault and status fields are
32130// examined as well.
32131func (c *EventTagsListCall) Enabled(enabled bool) *EventTagsListCall {
32132	c.urlParams_.Set("enabled", fmt.Sprint(enabled))
32133	return c
32134}
32135
32136// EventTagTypes sets the optional parameter "eventTagTypes": Select
32137// only event tags with the specified event tag types. Event tag types
32138// can be used to specify whether to use a third-party pixel, a
32139// third-party JavaScript URL, or a third-party click-through URL for
32140// either impression or click tracking.
32141//
32142// Possible values:
32143//   "IMPRESSION_IMAGE_EVENT_TAG"
32144//   "IMPRESSION_JAVASCRIPT_EVENT_TAG"
32145//   "CLICK_THROUGH_EVENT_TAG"
32146func (c *EventTagsListCall) EventTagTypes(eventTagTypes ...string) *EventTagsListCall {
32147	c.urlParams_.SetMulti("eventTagTypes", append([]string{}, eventTagTypes...))
32148	return c
32149}
32150
32151// Ids sets the optional parameter "ids": Select only event tags with
32152// these IDs.
32153func (c *EventTagsListCall) Ids(ids ...int64) *EventTagsListCall {
32154	var ids_ []string
32155	for _, v := range ids {
32156		ids_ = append(ids_, fmt.Sprint(v))
32157	}
32158	c.urlParams_.SetMulti("ids", ids_)
32159	return c
32160}
32161
32162// SearchString sets the optional parameter "searchString": Allows
32163// searching for objects by name or ID. Wildcards (*) are allowed. For
32164// example, "eventtag*2015" will return objects with names like
32165// "eventtag June 2015", "eventtag April 2015", or simply "eventtag
32166// 2015". Most of the searches also add wildcards implicitly at the
32167// start and the end of the search string. For example, a search string
32168// of "eventtag" will match objects with name "my eventtag", "eventtag
32169// 2015", or simply "eventtag".
32170func (c *EventTagsListCall) SearchString(searchString string) *EventTagsListCall {
32171	c.urlParams_.Set("searchString", searchString)
32172	return c
32173}
32174
32175// SortField sets the optional parameter "sortField": Field by which to
32176// sort the list.
32177//
32178// Possible values:
32179//   "ID" (default)
32180//   "NAME"
32181func (c *EventTagsListCall) SortField(sortField string) *EventTagsListCall {
32182	c.urlParams_.Set("sortField", sortField)
32183	return c
32184}
32185
32186// SortOrder sets the optional parameter "sortOrder": Order of sorted
32187// results.
32188//
32189// Possible values:
32190//   "ASCENDING" (default)
32191//   "DESCENDING"
32192func (c *EventTagsListCall) SortOrder(sortOrder string) *EventTagsListCall {
32193	c.urlParams_.Set("sortOrder", sortOrder)
32194	return c
32195}
32196
32197// Fields allows partial responses to be retrieved. See
32198// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
32199// for more information.
32200func (c *EventTagsListCall) Fields(s ...googleapi.Field) *EventTagsListCall {
32201	c.urlParams_.Set("fields", googleapi.CombineFields(s))
32202	return c
32203}
32204
32205// IfNoneMatch sets the optional parameter which makes the operation
32206// fail if the object's ETag matches the given value. This is useful for
32207// getting updates only after the object has changed since the last
32208// request. Use googleapi.IsNotModified to check whether the response
32209// error from Do is the result of In-None-Match.
32210func (c *EventTagsListCall) IfNoneMatch(entityTag string) *EventTagsListCall {
32211	c.ifNoneMatch_ = entityTag
32212	return c
32213}
32214
32215// Context sets the context to be used in this call's Do method. Any
32216// pending HTTP request will be aborted if the provided context is
32217// canceled.
32218func (c *EventTagsListCall) Context(ctx context.Context) *EventTagsListCall {
32219	c.ctx_ = ctx
32220	return c
32221}
32222
32223// Header returns an http.Header that can be modified by the caller to
32224// add HTTP headers to the request.
32225func (c *EventTagsListCall) Header() http.Header {
32226	if c.header_ == nil {
32227		c.header_ = make(http.Header)
32228	}
32229	return c.header_
32230}
32231
32232func (c *EventTagsListCall) doRequest(alt string) (*http.Response, error) {
32233	reqHeaders := make(http.Header)
32234	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
32235	for k, v := range c.header_ {
32236		reqHeaders[k] = v
32237	}
32238	reqHeaders.Set("User-Agent", c.s.userAgent())
32239	if c.ifNoneMatch_ != "" {
32240		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
32241	}
32242	var body io.Reader = nil
32243	c.urlParams_.Set("alt", alt)
32244	c.urlParams_.Set("prettyPrint", "false")
32245	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/eventTags")
32246	urls += "?" + c.urlParams_.Encode()
32247	req, err := http.NewRequest("GET", urls, body)
32248	if err != nil {
32249		return nil, err
32250	}
32251	req.Header = reqHeaders
32252	googleapi.Expand(req.URL, map[string]string{
32253		"profileId": strconv.FormatInt(c.profileId, 10),
32254	})
32255	return gensupport.SendRequest(c.ctx_, c.s.client, req)
32256}
32257
32258// Do executes the "dfareporting.eventTags.list" call.
32259// Exactly one of *EventTagsListResponse or error will be non-nil. Any
32260// non-2xx status code is an error. Response headers are in either
32261// *EventTagsListResponse.ServerResponse.Header or (if a response was
32262// returned at all) in error.(*googleapi.Error).Header. Use
32263// googleapi.IsNotModified to check whether the returned error was
32264// because http.StatusNotModified was returned.
32265func (c *EventTagsListCall) Do(opts ...googleapi.CallOption) (*EventTagsListResponse, error) {
32266	gensupport.SetOptions(c.urlParams_, opts...)
32267	res, err := c.doRequest("json")
32268	if res != nil && res.StatusCode == http.StatusNotModified {
32269		if res.Body != nil {
32270			res.Body.Close()
32271		}
32272		return nil, &googleapi.Error{
32273			Code:   res.StatusCode,
32274			Header: res.Header,
32275		}
32276	}
32277	if err != nil {
32278		return nil, err
32279	}
32280	defer googleapi.CloseBody(res)
32281	if err := googleapi.CheckResponse(res); err != nil {
32282		return nil, err
32283	}
32284	ret := &EventTagsListResponse{
32285		ServerResponse: googleapi.ServerResponse{
32286			Header:         res.Header,
32287			HTTPStatusCode: res.StatusCode,
32288		},
32289	}
32290	target := &ret
32291	if err := gensupport.DecodeResponse(target, res); err != nil {
32292		return nil, err
32293	}
32294	return ret, nil
32295	// {
32296	//   "description": "Retrieves a list of event tags, possibly filtered.",
32297	//   "flatPath": "userprofiles/{profileId}/eventTags",
32298	//   "httpMethod": "GET",
32299	//   "id": "dfareporting.eventTags.list",
32300	//   "parameterOrder": [
32301	//     "profileId"
32302	//   ],
32303	//   "parameters": {
32304	//     "adId": {
32305	//       "description": "Select only event tags that belong to this ad.",
32306	//       "format": "int64",
32307	//       "location": "query",
32308	//       "type": "string"
32309	//     },
32310	//     "advertiserId": {
32311	//       "description": "Select only event tags that belong to this advertiser.",
32312	//       "format": "int64",
32313	//       "location": "query",
32314	//       "type": "string"
32315	//     },
32316	//     "campaignId": {
32317	//       "description": "Select only event tags that belong to this campaign.",
32318	//       "format": "int64",
32319	//       "location": "query",
32320	//       "type": "string"
32321	//     },
32322	//     "definitionsOnly": {
32323	//       "description": "Examine only the specified campaign or advertiser's event tags for matching selector criteria. When set to false, the parent advertiser and parent campaign of the specified ad or campaign is examined as well. In addition, when set to false, the status field is examined as well, along with the enabledByDefault field. This parameter can not be set to true when adId is specified as ads do not define their own even tags.",
32324	//       "location": "query",
32325	//       "type": "boolean"
32326	//     },
32327	//     "enabled": {
32328	//       "description": "Select only enabled event tags. What is considered enabled or disabled depends on the definitionsOnly parameter. When definitionsOnly is set to true, only the specified advertiser or campaign's event tags' enabledByDefault field is examined. When definitionsOnly is set to false, the specified ad or specified campaign's parent advertiser's or parent campaign's event tags' enabledByDefault and status fields are examined as well.",
32329	//       "location": "query",
32330	//       "type": "boolean"
32331	//     },
32332	//     "eventTagTypes": {
32333	//       "description": "Select only event tags with the specified event tag types. Event tag types can be used to specify whether to use a third-party pixel, a third-party JavaScript URL, or a third-party click-through URL for either impression or click tracking.",
32334	//       "enum": [
32335	//         "IMPRESSION_IMAGE_EVENT_TAG",
32336	//         "IMPRESSION_JAVASCRIPT_EVENT_TAG",
32337	//         "CLICK_THROUGH_EVENT_TAG"
32338	//       ],
32339	//       "enumDescriptions": [
32340	//         "",
32341	//         "",
32342	//         ""
32343	//       ],
32344	//       "location": "query",
32345	//       "repeated": true,
32346	//       "type": "string"
32347	//     },
32348	//     "ids": {
32349	//       "description": "Select only event tags with these IDs.",
32350	//       "format": "int64",
32351	//       "location": "query",
32352	//       "repeated": true,
32353	//       "type": "string"
32354	//     },
32355	//     "profileId": {
32356	//       "description": "User profile ID associated with this request.",
32357	//       "format": "int64",
32358	//       "location": "path",
32359	//       "required": true,
32360	//       "type": "string"
32361	//     },
32362	//     "searchString": {
32363	//       "description": "Allows searching for objects by name or ID. Wildcards (*) are allowed. For example, \"eventtag*2015\" will return objects with names like \"eventtag June 2015\", \"eventtag April 2015\", or simply \"eventtag 2015\". Most of the searches also add wildcards implicitly at the start and the end of the search string. For example, a search string of \"eventtag\" will match objects with name \"my eventtag\", \"eventtag 2015\", or simply \"eventtag\".",
32364	//       "location": "query",
32365	//       "type": "string"
32366	//     },
32367	//     "sortField": {
32368	//       "default": "ID",
32369	//       "description": "Field by which to sort the list.",
32370	//       "enum": [
32371	//         "ID",
32372	//         "NAME"
32373	//       ],
32374	//       "enumDescriptions": [
32375	//         "",
32376	//         ""
32377	//       ],
32378	//       "location": "query",
32379	//       "type": "string"
32380	//     },
32381	//     "sortOrder": {
32382	//       "default": "ASCENDING",
32383	//       "description": "Order of sorted results.",
32384	//       "enum": [
32385	//         "ASCENDING",
32386	//         "DESCENDING"
32387	//       ],
32388	//       "enumDescriptions": [
32389	//         "",
32390	//         ""
32391	//       ],
32392	//       "location": "query",
32393	//       "type": "string"
32394	//     }
32395	//   },
32396	//   "path": "userprofiles/{profileId}/eventTags",
32397	//   "response": {
32398	//     "$ref": "EventTagsListResponse"
32399	//   },
32400	//   "scopes": [
32401	//     "https://www.googleapis.com/auth/dfatrafficking"
32402	//   ]
32403	// }
32404
32405}
32406
32407// method id "dfareporting.eventTags.patch":
32408
32409type EventTagsPatchCall struct {
32410	s          *Service
32411	profileId  int64
32412	eventtag   *EventTag
32413	urlParams_ gensupport.URLParams
32414	ctx_       context.Context
32415	header_    http.Header
32416}
32417
32418// Patch: Updates an existing event tag. This method supports patch
32419// semantics.
32420//
32421// - id: EventTag ID.
32422// - profileId: User profile ID associated with this request.
32423func (r *EventTagsService) Patch(profileId int64, id int64, eventtag *EventTag) *EventTagsPatchCall {
32424	c := &EventTagsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
32425	c.profileId = profileId
32426	c.urlParams_.Set("id", fmt.Sprint(id))
32427	c.eventtag = eventtag
32428	return c
32429}
32430
32431// Fields allows partial responses to be retrieved. See
32432// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
32433// for more information.
32434func (c *EventTagsPatchCall) Fields(s ...googleapi.Field) *EventTagsPatchCall {
32435	c.urlParams_.Set("fields", googleapi.CombineFields(s))
32436	return c
32437}
32438
32439// Context sets the context to be used in this call's Do method. Any
32440// pending HTTP request will be aborted if the provided context is
32441// canceled.
32442func (c *EventTagsPatchCall) Context(ctx context.Context) *EventTagsPatchCall {
32443	c.ctx_ = ctx
32444	return c
32445}
32446
32447// Header returns an http.Header that can be modified by the caller to
32448// add HTTP headers to the request.
32449func (c *EventTagsPatchCall) Header() http.Header {
32450	if c.header_ == nil {
32451		c.header_ = make(http.Header)
32452	}
32453	return c.header_
32454}
32455
32456func (c *EventTagsPatchCall) doRequest(alt string) (*http.Response, error) {
32457	reqHeaders := make(http.Header)
32458	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
32459	for k, v := range c.header_ {
32460		reqHeaders[k] = v
32461	}
32462	reqHeaders.Set("User-Agent", c.s.userAgent())
32463	var body io.Reader = nil
32464	body, err := googleapi.WithoutDataWrapper.JSONReader(c.eventtag)
32465	if err != nil {
32466		return nil, err
32467	}
32468	reqHeaders.Set("Content-Type", "application/json")
32469	c.urlParams_.Set("alt", alt)
32470	c.urlParams_.Set("prettyPrint", "false")
32471	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/eventTags")
32472	urls += "?" + c.urlParams_.Encode()
32473	req, err := http.NewRequest("PATCH", urls, body)
32474	if err != nil {
32475		return nil, err
32476	}
32477	req.Header = reqHeaders
32478	googleapi.Expand(req.URL, map[string]string{
32479		"profileId": strconv.FormatInt(c.profileId, 10),
32480	})
32481	return gensupport.SendRequest(c.ctx_, c.s.client, req)
32482}
32483
32484// Do executes the "dfareporting.eventTags.patch" call.
32485// Exactly one of *EventTag or error will be non-nil. Any non-2xx status
32486// code is an error. Response headers are in either
32487// *EventTag.ServerResponse.Header or (if a response was returned at
32488// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
32489// to check whether the returned error was because
32490// http.StatusNotModified was returned.
32491func (c *EventTagsPatchCall) Do(opts ...googleapi.CallOption) (*EventTag, error) {
32492	gensupport.SetOptions(c.urlParams_, opts...)
32493	res, err := c.doRequest("json")
32494	if res != nil && res.StatusCode == http.StatusNotModified {
32495		if res.Body != nil {
32496			res.Body.Close()
32497		}
32498		return nil, &googleapi.Error{
32499			Code:   res.StatusCode,
32500			Header: res.Header,
32501		}
32502	}
32503	if err != nil {
32504		return nil, err
32505	}
32506	defer googleapi.CloseBody(res)
32507	if err := googleapi.CheckResponse(res); err != nil {
32508		return nil, err
32509	}
32510	ret := &EventTag{
32511		ServerResponse: googleapi.ServerResponse{
32512			Header:         res.Header,
32513			HTTPStatusCode: res.StatusCode,
32514		},
32515	}
32516	target := &ret
32517	if err := gensupport.DecodeResponse(target, res); err != nil {
32518		return nil, err
32519	}
32520	return ret, nil
32521	// {
32522	//   "description": "Updates an existing event tag. This method supports patch semantics.",
32523	//   "flatPath": "userprofiles/{profileId}/eventTags",
32524	//   "httpMethod": "PATCH",
32525	//   "id": "dfareporting.eventTags.patch",
32526	//   "parameterOrder": [
32527	//     "profileId",
32528	//     "id"
32529	//   ],
32530	//   "parameters": {
32531	//     "id": {
32532	//       "description": "EventTag ID.",
32533	//       "format": "int64",
32534	//       "location": "query",
32535	//       "required": true,
32536	//       "type": "string"
32537	//     },
32538	//     "profileId": {
32539	//       "description": "User profile ID associated with this request.",
32540	//       "format": "int64",
32541	//       "location": "path",
32542	//       "required": true,
32543	//       "type": "string"
32544	//     }
32545	//   },
32546	//   "path": "userprofiles/{profileId}/eventTags",
32547	//   "request": {
32548	//     "$ref": "EventTag"
32549	//   },
32550	//   "response": {
32551	//     "$ref": "EventTag"
32552	//   },
32553	//   "scopes": [
32554	//     "https://www.googleapis.com/auth/dfatrafficking"
32555	//   ]
32556	// }
32557
32558}
32559
32560// method id "dfareporting.eventTags.update":
32561
32562type EventTagsUpdateCall struct {
32563	s          *Service
32564	profileId  int64
32565	eventtag   *EventTag
32566	urlParams_ gensupport.URLParams
32567	ctx_       context.Context
32568	header_    http.Header
32569}
32570
32571// Update: Updates an existing event tag.
32572//
32573// - profileId: User profile ID associated with this request.
32574func (r *EventTagsService) Update(profileId int64, eventtag *EventTag) *EventTagsUpdateCall {
32575	c := &EventTagsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
32576	c.profileId = profileId
32577	c.eventtag = eventtag
32578	return c
32579}
32580
32581// Fields allows partial responses to be retrieved. See
32582// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
32583// for more information.
32584func (c *EventTagsUpdateCall) Fields(s ...googleapi.Field) *EventTagsUpdateCall {
32585	c.urlParams_.Set("fields", googleapi.CombineFields(s))
32586	return c
32587}
32588
32589// Context sets the context to be used in this call's Do method. Any
32590// pending HTTP request will be aborted if the provided context is
32591// canceled.
32592func (c *EventTagsUpdateCall) Context(ctx context.Context) *EventTagsUpdateCall {
32593	c.ctx_ = ctx
32594	return c
32595}
32596
32597// Header returns an http.Header that can be modified by the caller to
32598// add HTTP headers to the request.
32599func (c *EventTagsUpdateCall) Header() http.Header {
32600	if c.header_ == nil {
32601		c.header_ = make(http.Header)
32602	}
32603	return c.header_
32604}
32605
32606func (c *EventTagsUpdateCall) doRequest(alt string) (*http.Response, error) {
32607	reqHeaders := make(http.Header)
32608	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
32609	for k, v := range c.header_ {
32610		reqHeaders[k] = v
32611	}
32612	reqHeaders.Set("User-Agent", c.s.userAgent())
32613	var body io.Reader = nil
32614	body, err := googleapi.WithoutDataWrapper.JSONReader(c.eventtag)
32615	if err != nil {
32616		return nil, err
32617	}
32618	reqHeaders.Set("Content-Type", "application/json")
32619	c.urlParams_.Set("alt", alt)
32620	c.urlParams_.Set("prettyPrint", "false")
32621	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/eventTags")
32622	urls += "?" + c.urlParams_.Encode()
32623	req, err := http.NewRequest("PUT", urls, body)
32624	if err != nil {
32625		return nil, err
32626	}
32627	req.Header = reqHeaders
32628	googleapi.Expand(req.URL, map[string]string{
32629		"profileId": strconv.FormatInt(c.profileId, 10),
32630	})
32631	return gensupport.SendRequest(c.ctx_, c.s.client, req)
32632}
32633
32634// Do executes the "dfareporting.eventTags.update" call.
32635// Exactly one of *EventTag or error will be non-nil. Any non-2xx status
32636// code is an error. Response headers are in either
32637// *EventTag.ServerResponse.Header or (if a response was returned at
32638// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
32639// to check whether the returned error was because
32640// http.StatusNotModified was returned.
32641func (c *EventTagsUpdateCall) Do(opts ...googleapi.CallOption) (*EventTag, error) {
32642	gensupport.SetOptions(c.urlParams_, opts...)
32643	res, err := c.doRequest("json")
32644	if res != nil && res.StatusCode == http.StatusNotModified {
32645		if res.Body != nil {
32646			res.Body.Close()
32647		}
32648		return nil, &googleapi.Error{
32649			Code:   res.StatusCode,
32650			Header: res.Header,
32651		}
32652	}
32653	if err != nil {
32654		return nil, err
32655	}
32656	defer googleapi.CloseBody(res)
32657	if err := googleapi.CheckResponse(res); err != nil {
32658		return nil, err
32659	}
32660	ret := &EventTag{
32661		ServerResponse: googleapi.ServerResponse{
32662			Header:         res.Header,
32663			HTTPStatusCode: res.StatusCode,
32664		},
32665	}
32666	target := &ret
32667	if err := gensupport.DecodeResponse(target, res); err != nil {
32668		return nil, err
32669	}
32670	return ret, nil
32671	// {
32672	//   "description": "Updates an existing event tag.",
32673	//   "flatPath": "userprofiles/{profileId}/eventTags",
32674	//   "httpMethod": "PUT",
32675	//   "id": "dfareporting.eventTags.update",
32676	//   "parameterOrder": [
32677	//     "profileId"
32678	//   ],
32679	//   "parameters": {
32680	//     "profileId": {
32681	//       "description": "User profile ID associated with this request.",
32682	//       "format": "int64",
32683	//       "location": "path",
32684	//       "required": true,
32685	//       "type": "string"
32686	//     }
32687	//   },
32688	//   "path": "userprofiles/{profileId}/eventTags",
32689	//   "request": {
32690	//     "$ref": "EventTag"
32691	//   },
32692	//   "response": {
32693	//     "$ref": "EventTag"
32694	//   },
32695	//   "scopes": [
32696	//     "https://www.googleapis.com/auth/dfatrafficking"
32697	//   ]
32698	// }
32699
32700}
32701
32702// method id "dfareporting.files.get":
32703
32704type FilesGetCall struct {
32705	s            *Service
32706	reportId     int64
32707	fileId       int64
32708	urlParams_   gensupport.URLParams
32709	ifNoneMatch_ string
32710	ctx_         context.Context
32711	header_      http.Header
32712}
32713
32714// Get: Retrieves a report file by its report ID and file ID. This
32715// method supports media download.
32716//
32717// - fileId: The ID of the report file.
32718// - reportId: The ID of the report.
32719func (r *FilesService) Get(reportId int64, fileId int64) *FilesGetCall {
32720	c := &FilesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
32721	c.reportId = reportId
32722	c.fileId = fileId
32723	return c
32724}
32725
32726// Fields allows partial responses to be retrieved. See
32727// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
32728// for more information.
32729func (c *FilesGetCall) Fields(s ...googleapi.Field) *FilesGetCall {
32730	c.urlParams_.Set("fields", googleapi.CombineFields(s))
32731	return c
32732}
32733
32734// IfNoneMatch sets the optional parameter which makes the operation
32735// fail if the object's ETag matches the given value. This is useful for
32736// getting updates only after the object has changed since the last
32737// request. Use googleapi.IsNotModified to check whether the response
32738// error from Do is the result of In-None-Match.
32739func (c *FilesGetCall) IfNoneMatch(entityTag string) *FilesGetCall {
32740	c.ifNoneMatch_ = entityTag
32741	return c
32742}
32743
32744// Context sets the context to be used in this call's Do and Download
32745// methods. Any pending HTTP request will be aborted if the provided
32746// context is canceled.
32747func (c *FilesGetCall) Context(ctx context.Context) *FilesGetCall {
32748	c.ctx_ = ctx
32749	return c
32750}
32751
32752// Header returns an http.Header that can be modified by the caller to
32753// add HTTP headers to the request.
32754func (c *FilesGetCall) Header() http.Header {
32755	if c.header_ == nil {
32756		c.header_ = make(http.Header)
32757	}
32758	return c.header_
32759}
32760
32761func (c *FilesGetCall) doRequest(alt string) (*http.Response, error) {
32762	reqHeaders := make(http.Header)
32763	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
32764	for k, v := range c.header_ {
32765		reqHeaders[k] = v
32766	}
32767	reqHeaders.Set("User-Agent", c.s.userAgent())
32768	if c.ifNoneMatch_ != "" {
32769		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
32770	}
32771	var body io.Reader = nil
32772	c.urlParams_.Set("alt", alt)
32773	c.urlParams_.Set("prettyPrint", "false")
32774	urls := googleapi.ResolveRelative(c.s.BasePath, "reports/{reportId}/files/{fileId}")
32775	urls += "?" + c.urlParams_.Encode()
32776	req, err := http.NewRequest("GET", urls, body)
32777	if err != nil {
32778		return nil, err
32779	}
32780	req.Header = reqHeaders
32781	googleapi.Expand(req.URL, map[string]string{
32782		"reportId": strconv.FormatInt(c.reportId, 10),
32783		"fileId":   strconv.FormatInt(c.fileId, 10),
32784	})
32785	return gensupport.SendRequest(c.ctx_, c.s.client, req)
32786}
32787
32788// Download fetches the API endpoint's "media" value, instead of the normal
32789// API response value. If the returned error is nil, the Response is guaranteed to
32790// have a 2xx status code. Callers must close the Response.Body as usual.
32791func (c *FilesGetCall) Download(opts ...googleapi.CallOption) (*http.Response, error) {
32792	gensupport.SetOptions(c.urlParams_, opts...)
32793	res, err := c.doRequest("media")
32794	if err != nil {
32795		return nil, err
32796	}
32797	if err := googleapi.CheckResponse(res); err != nil {
32798		res.Body.Close()
32799		return nil, err
32800	}
32801	return res, nil
32802}
32803
32804// Do executes the "dfareporting.files.get" call.
32805// Exactly one of *File or error will be non-nil. Any non-2xx status
32806// code is an error. Response headers are in either
32807// *File.ServerResponse.Header or (if a response was returned at all) in
32808// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
32809// whether the returned error was because http.StatusNotModified was
32810// returned.
32811func (c *FilesGetCall) Do(opts ...googleapi.CallOption) (*File, error) {
32812	gensupport.SetOptions(c.urlParams_, opts...)
32813	res, err := c.doRequest("json")
32814	if res != nil && res.StatusCode == http.StatusNotModified {
32815		if res.Body != nil {
32816			res.Body.Close()
32817		}
32818		return nil, &googleapi.Error{
32819			Code:   res.StatusCode,
32820			Header: res.Header,
32821		}
32822	}
32823	if err != nil {
32824		return nil, err
32825	}
32826	defer googleapi.CloseBody(res)
32827	if err := googleapi.CheckResponse(res); err != nil {
32828		return nil, err
32829	}
32830	ret := &File{
32831		ServerResponse: googleapi.ServerResponse{
32832			Header:         res.Header,
32833			HTTPStatusCode: res.StatusCode,
32834		},
32835	}
32836	target := &ret
32837	if err := gensupport.DecodeResponse(target, res); err != nil {
32838		return nil, err
32839	}
32840	return ret, nil
32841	// {
32842	//   "description": "Retrieves a report file by its report ID and file ID. This method supports media download.",
32843	//   "flatPath": "reports/{reportId}/files/{fileId}",
32844	//   "httpMethod": "GET",
32845	//   "id": "dfareporting.files.get",
32846	//   "parameterOrder": [
32847	//     "reportId",
32848	//     "fileId"
32849	//   ],
32850	//   "parameters": {
32851	//     "fileId": {
32852	//       "description": "The ID of the report file.",
32853	//       "format": "int64",
32854	//       "location": "path",
32855	//       "required": true,
32856	//       "type": "string"
32857	//     },
32858	//     "reportId": {
32859	//       "description": "The ID of the report.",
32860	//       "format": "int64",
32861	//       "location": "path",
32862	//       "required": true,
32863	//       "type": "string"
32864	//     }
32865	//   },
32866	//   "path": "reports/{reportId}/files/{fileId}",
32867	//   "response": {
32868	//     "$ref": "File"
32869	//   },
32870	//   "scopes": [
32871	//     "https://www.googleapis.com/auth/dfareporting"
32872	//   ],
32873	//   "supportsMediaDownload": true
32874	// }
32875
32876}
32877
32878// method id "dfareporting.files.list":
32879
32880type FilesListCall struct {
32881	s            *Service
32882	profileId    int64
32883	urlParams_   gensupport.URLParams
32884	ifNoneMatch_ string
32885	ctx_         context.Context
32886	header_      http.Header
32887}
32888
32889// List: Lists files for a user profile.
32890//
32891// - profileId: The Campaign Manager 360 user profile ID.
32892func (r *FilesService) List(profileId int64) *FilesListCall {
32893	c := &FilesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
32894	c.profileId = profileId
32895	return c
32896}
32897
32898// MaxResults sets the optional parameter "maxResults": Maximum number
32899// of results to return.
32900func (c *FilesListCall) MaxResults(maxResults int64) *FilesListCall {
32901	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
32902	return c
32903}
32904
32905// PageToken sets the optional parameter "pageToken": The value of the
32906// nextToken from the previous result page.
32907func (c *FilesListCall) PageToken(pageToken string) *FilesListCall {
32908	c.urlParams_.Set("pageToken", pageToken)
32909	return c
32910}
32911
32912// Scope sets the optional parameter "scope": The scope that defines
32913// which results are returned.
32914//
32915// Possible values:
32916//   "ALL" - All files in account.
32917//   "MINE" (default) - My files.
32918//   "SHARED_WITH_ME" - Files shared with me.
32919func (c *FilesListCall) Scope(scope string) *FilesListCall {
32920	c.urlParams_.Set("scope", scope)
32921	return c
32922}
32923
32924// SortField sets the optional parameter "sortField": The field by which
32925// to sort the list.
32926//
32927// Possible values:
32928//   "ID" - Sort by file ID.
32929//   "LAST_MODIFIED_TIME" (default) - Sort by 'lastmodifiedAt' field.
32930func (c *FilesListCall) SortField(sortField string) *FilesListCall {
32931	c.urlParams_.Set("sortField", sortField)
32932	return c
32933}
32934
32935// SortOrder sets the optional parameter "sortOrder": Order of sorted
32936// results.
32937//
32938// Possible values:
32939//   "ASCENDING" - Ascending order.
32940//   "DESCENDING" (default) - Descending order.
32941func (c *FilesListCall) SortOrder(sortOrder string) *FilesListCall {
32942	c.urlParams_.Set("sortOrder", sortOrder)
32943	return c
32944}
32945
32946// Fields allows partial responses to be retrieved. See
32947// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
32948// for more information.
32949func (c *FilesListCall) Fields(s ...googleapi.Field) *FilesListCall {
32950	c.urlParams_.Set("fields", googleapi.CombineFields(s))
32951	return c
32952}
32953
32954// IfNoneMatch sets the optional parameter which makes the operation
32955// fail if the object's ETag matches the given value. This is useful for
32956// getting updates only after the object has changed since the last
32957// request. Use googleapi.IsNotModified to check whether the response
32958// error from Do is the result of In-None-Match.
32959func (c *FilesListCall) IfNoneMatch(entityTag string) *FilesListCall {
32960	c.ifNoneMatch_ = entityTag
32961	return c
32962}
32963
32964// Context sets the context to be used in this call's Do method. Any
32965// pending HTTP request will be aborted if the provided context is
32966// canceled.
32967func (c *FilesListCall) Context(ctx context.Context) *FilesListCall {
32968	c.ctx_ = ctx
32969	return c
32970}
32971
32972// Header returns an http.Header that can be modified by the caller to
32973// add HTTP headers to the request.
32974func (c *FilesListCall) Header() http.Header {
32975	if c.header_ == nil {
32976		c.header_ = make(http.Header)
32977	}
32978	return c.header_
32979}
32980
32981func (c *FilesListCall) doRequest(alt string) (*http.Response, error) {
32982	reqHeaders := make(http.Header)
32983	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
32984	for k, v := range c.header_ {
32985		reqHeaders[k] = v
32986	}
32987	reqHeaders.Set("User-Agent", c.s.userAgent())
32988	if c.ifNoneMatch_ != "" {
32989		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
32990	}
32991	var body io.Reader = nil
32992	c.urlParams_.Set("alt", alt)
32993	c.urlParams_.Set("prettyPrint", "false")
32994	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/files")
32995	urls += "?" + c.urlParams_.Encode()
32996	req, err := http.NewRequest("GET", urls, body)
32997	if err != nil {
32998		return nil, err
32999	}
33000	req.Header = reqHeaders
33001	googleapi.Expand(req.URL, map[string]string{
33002		"profileId": strconv.FormatInt(c.profileId, 10),
33003	})
33004	return gensupport.SendRequest(c.ctx_, c.s.client, req)
33005}
33006
33007// Do executes the "dfareporting.files.list" call.
33008// Exactly one of *FileList or error will be non-nil. Any non-2xx status
33009// code is an error. Response headers are in either
33010// *FileList.ServerResponse.Header or (if a response was returned at
33011// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
33012// to check whether the returned error was because
33013// http.StatusNotModified was returned.
33014func (c *FilesListCall) Do(opts ...googleapi.CallOption) (*FileList, error) {
33015	gensupport.SetOptions(c.urlParams_, opts...)
33016	res, err := c.doRequest("json")
33017	if res != nil && res.StatusCode == http.StatusNotModified {
33018		if res.Body != nil {
33019			res.Body.Close()
33020		}
33021		return nil, &googleapi.Error{
33022			Code:   res.StatusCode,
33023			Header: res.Header,
33024		}
33025	}
33026	if err != nil {
33027		return nil, err
33028	}
33029	defer googleapi.CloseBody(res)
33030	if err := googleapi.CheckResponse(res); err != nil {
33031		return nil, err
33032	}
33033	ret := &FileList{
33034		ServerResponse: googleapi.ServerResponse{
33035			Header:         res.Header,
33036			HTTPStatusCode: res.StatusCode,
33037		},
33038	}
33039	target := &ret
33040	if err := gensupport.DecodeResponse(target, res); err != nil {
33041		return nil, err
33042	}
33043	return ret, nil
33044	// {
33045	//   "description": "Lists files for a user profile.",
33046	//   "flatPath": "userprofiles/{profileId}/files",
33047	//   "httpMethod": "GET",
33048	//   "id": "dfareporting.files.list",
33049	//   "parameterOrder": [
33050	//     "profileId"
33051	//   ],
33052	//   "parameters": {
33053	//     "maxResults": {
33054	//       "default": "10",
33055	//       "description": "Maximum number of results to return.",
33056	//       "format": "int32",
33057	//       "location": "query",
33058	//       "maximum": "10",
33059	//       "minimum": "0",
33060	//       "type": "integer"
33061	//     },
33062	//     "pageToken": {
33063	//       "description": "The value of the nextToken from the previous result page.",
33064	//       "location": "query",
33065	//       "type": "string"
33066	//     },
33067	//     "profileId": {
33068	//       "description": "The Campaign Manager 360 user profile ID.",
33069	//       "format": "int64",
33070	//       "location": "path",
33071	//       "required": true,
33072	//       "type": "string"
33073	//     },
33074	//     "scope": {
33075	//       "default": "MINE",
33076	//       "description": "The scope that defines which results are returned.",
33077	//       "enum": [
33078	//         "ALL",
33079	//         "MINE",
33080	//         "SHARED_WITH_ME"
33081	//       ],
33082	//       "enumDescriptions": [
33083	//         "All files in account.",
33084	//         "My files.",
33085	//         "Files shared with me."
33086	//       ],
33087	//       "location": "query",
33088	//       "type": "string"
33089	//     },
33090	//     "sortField": {
33091	//       "default": "LAST_MODIFIED_TIME",
33092	//       "description": "The field by which to sort the list.",
33093	//       "enum": [
33094	//         "ID",
33095	//         "LAST_MODIFIED_TIME"
33096	//       ],
33097	//       "enumDescriptions": [
33098	//         "Sort by file ID.",
33099	//         "Sort by 'lastmodifiedAt' field."
33100	//       ],
33101	//       "location": "query",
33102	//       "type": "string"
33103	//     },
33104	//     "sortOrder": {
33105	//       "default": "DESCENDING",
33106	//       "description": "Order of sorted results.",
33107	//       "enum": [
33108	//         "ASCENDING",
33109	//         "DESCENDING"
33110	//       ],
33111	//       "enumDescriptions": [
33112	//         "Ascending order.",
33113	//         "Descending order."
33114	//       ],
33115	//       "location": "query",
33116	//       "type": "string"
33117	//     }
33118	//   },
33119	//   "path": "userprofiles/{profileId}/files",
33120	//   "response": {
33121	//     "$ref": "FileList"
33122	//   },
33123	//   "scopes": [
33124	//     "https://www.googleapis.com/auth/dfareporting"
33125	//   ]
33126	// }
33127
33128}
33129
33130// Pages invokes f for each page of results.
33131// A non-nil error returned from f will halt the iteration.
33132// The provided context supersedes any context provided to the Context method.
33133func (c *FilesListCall) Pages(ctx context.Context, f func(*FileList) error) error {
33134	c.ctx_ = ctx
33135	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
33136	for {
33137		x, err := c.Do()
33138		if err != nil {
33139			return err
33140		}
33141		if err := f(x); err != nil {
33142			return err
33143		}
33144		if x.NextPageToken == "" {
33145			return nil
33146		}
33147		c.PageToken(x.NextPageToken)
33148	}
33149}
33150
33151// method id "dfareporting.floodlightActivities.delete":
33152
33153type FloodlightActivitiesDeleteCall struct {
33154	s          *Service
33155	profileId  int64
33156	id         int64
33157	urlParams_ gensupport.URLParams
33158	ctx_       context.Context
33159	header_    http.Header
33160}
33161
33162// Delete: Deletes an existing floodlight activity.
33163//
33164// - id: Floodlight activity ID.
33165// - profileId: User profile ID associated with this request.
33166func (r *FloodlightActivitiesService) Delete(profileId int64, id int64) *FloodlightActivitiesDeleteCall {
33167	c := &FloodlightActivitiesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
33168	c.profileId = profileId
33169	c.id = id
33170	return c
33171}
33172
33173// Fields allows partial responses to be retrieved. See
33174// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
33175// for more information.
33176func (c *FloodlightActivitiesDeleteCall) Fields(s ...googleapi.Field) *FloodlightActivitiesDeleteCall {
33177	c.urlParams_.Set("fields", googleapi.CombineFields(s))
33178	return c
33179}
33180
33181// Context sets the context to be used in this call's Do method. Any
33182// pending HTTP request will be aborted if the provided context is
33183// canceled.
33184func (c *FloodlightActivitiesDeleteCall) Context(ctx context.Context) *FloodlightActivitiesDeleteCall {
33185	c.ctx_ = ctx
33186	return c
33187}
33188
33189// Header returns an http.Header that can be modified by the caller to
33190// add HTTP headers to the request.
33191func (c *FloodlightActivitiesDeleteCall) Header() http.Header {
33192	if c.header_ == nil {
33193		c.header_ = make(http.Header)
33194	}
33195	return c.header_
33196}
33197
33198func (c *FloodlightActivitiesDeleteCall) doRequest(alt string) (*http.Response, error) {
33199	reqHeaders := make(http.Header)
33200	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
33201	for k, v := range c.header_ {
33202		reqHeaders[k] = v
33203	}
33204	reqHeaders.Set("User-Agent", c.s.userAgent())
33205	var body io.Reader = nil
33206	c.urlParams_.Set("alt", alt)
33207	c.urlParams_.Set("prettyPrint", "false")
33208	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/floodlightActivities/{id}")
33209	urls += "?" + c.urlParams_.Encode()
33210	req, err := http.NewRequest("DELETE", urls, body)
33211	if err != nil {
33212		return nil, err
33213	}
33214	req.Header = reqHeaders
33215	googleapi.Expand(req.URL, map[string]string{
33216		"profileId": strconv.FormatInt(c.profileId, 10),
33217		"id":        strconv.FormatInt(c.id, 10),
33218	})
33219	return gensupport.SendRequest(c.ctx_, c.s.client, req)
33220}
33221
33222// Do executes the "dfareporting.floodlightActivities.delete" call.
33223func (c *FloodlightActivitiesDeleteCall) Do(opts ...googleapi.CallOption) error {
33224	gensupport.SetOptions(c.urlParams_, opts...)
33225	res, err := c.doRequest("json")
33226	if err != nil {
33227		return err
33228	}
33229	defer googleapi.CloseBody(res)
33230	if err := googleapi.CheckResponse(res); err != nil {
33231		return err
33232	}
33233	return nil
33234	// {
33235	//   "description": "Deletes an existing floodlight activity.",
33236	//   "flatPath": "userprofiles/{profileId}/floodlightActivities/{id}",
33237	//   "httpMethod": "DELETE",
33238	//   "id": "dfareporting.floodlightActivities.delete",
33239	//   "parameterOrder": [
33240	//     "profileId",
33241	//     "id"
33242	//   ],
33243	//   "parameters": {
33244	//     "id": {
33245	//       "description": "Floodlight activity ID.",
33246	//       "format": "int64",
33247	//       "location": "path",
33248	//       "required": true,
33249	//       "type": "string"
33250	//     },
33251	//     "profileId": {
33252	//       "description": "User profile ID associated with this request.",
33253	//       "format": "int64",
33254	//       "location": "path",
33255	//       "required": true,
33256	//       "type": "string"
33257	//     }
33258	//   },
33259	//   "path": "userprofiles/{profileId}/floodlightActivities/{id}",
33260	//   "scopes": [
33261	//     "https://www.googleapis.com/auth/dfatrafficking"
33262	//   ]
33263	// }
33264
33265}
33266
33267// method id "dfareporting.floodlightActivities.generatetag":
33268
33269type FloodlightActivitiesGeneratetagCall struct {
33270	s          *Service
33271	profileId  int64
33272	urlParams_ gensupport.URLParams
33273	ctx_       context.Context
33274	header_    http.Header
33275}
33276
33277// Generatetag: Generates a tag for a floodlight activity.
33278//
33279// - profileId: User profile ID associated with this request.
33280func (r *FloodlightActivitiesService) Generatetag(profileId int64) *FloodlightActivitiesGeneratetagCall {
33281	c := &FloodlightActivitiesGeneratetagCall{s: r.s, urlParams_: make(gensupport.URLParams)}
33282	c.profileId = profileId
33283	return c
33284}
33285
33286// FloodlightActivityId sets the optional parameter
33287// "floodlightActivityId": Floodlight activity ID for which we want to
33288// generate a tag.
33289func (c *FloodlightActivitiesGeneratetagCall) FloodlightActivityId(floodlightActivityId int64) *FloodlightActivitiesGeneratetagCall {
33290	c.urlParams_.Set("floodlightActivityId", fmt.Sprint(floodlightActivityId))
33291	return c
33292}
33293
33294// Fields allows partial responses to be retrieved. See
33295// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
33296// for more information.
33297func (c *FloodlightActivitiesGeneratetagCall) Fields(s ...googleapi.Field) *FloodlightActivitiesGeneratetagCall {
33298	c.urlParams_.Set("fields", googleapi.CombineFields(s))
33299	return c
33300}
33301
33302// Context sets the context to be used in this call's Do method. Any
33303// pending HTTP request will be aborted if the provided context is
33304// canceled.
33305func (c *FloodlightActivitiesGeneratetagCall) Context(ctx context.Context) *FloodlightActivitiesGeneratetagCall {
33306	c.ctx_ = ctx
33307	return c
33308}
33309
33310// Header returns an http.Header that can be modified by the caller to
33311// add HTTP headers to the request.
33312func (c *FloodlightActivitiesGeneratetagCall) Header() http.Header {
33313	if c.header_ == nil {
33314		c.header_ = make(http.Header)
33315	}
33316	return c.header_
33317}
33318
33319func (c *FloodlightActivitiesGeneratetagCall) doRequest(alt string) (*http.Response, error) {
33320	reqHeaders := make(http.Header)
33321	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
33322	for k, v := range c.header_ {
33323		reqHeaders[k] = v
33324	}
33325	reqHeaders.Set("User-Agent", c.s.userAgent())
33326	var body io.Reader = nil
33327	c.urlParams_.Set("alt", alt)
33328	c.urlParams_.Set("prettyPrint", "false")
33329	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/floodlightActivities/generatetag")
33330	urls += "?" + c.urlParams_.Encode()
33331	req, err := http.NewRequest("POST", urls, body)
33332	if err != nil {
33333		return nil, err
33334	}
33335	req.Header = reqHeaders
33336	googleapi.Expand(req.URL, map[string]string{
33337		"profileId": strconv.FormatInt(c.profileId, 10),
33338	})
33339	return gensupport.SendRequest(c.ctx_, c.s.client, req)
33340}
33341
33342// Do executes the "dfareporting.floodlightActivities.generatetag" call.
33343// Exactly one of *FloodlightActivitiesGenerateTagResponse or error will
33344// be non-nil. Any non-2xx status code is an error. Response headers are
33345// in either
33346// *FloodlightActivitiesGenerateTagResponse.ServerResponse.Header or (if
33347// a response was returned at all) in error.(*googleapi.Error).Header.
33348// Use googleapi.IsNotModified to check whether the returned error was
33349// because http.StatusNotModified was returned.
33350func (c *FloodlightActivitiesGeneratetagCall) Do(opts ...googleapi.CallOption) (*FloodlightActivitiesGenerateTagResponse, error) {
33351	gensupport.SetOptions(c.urlParams_, opts...)
33352	res, err := c.doRequest("json")
33353	if res != nil && res.StatusCode == http.StatusNotModified {
33354		if res.Body != nil {
33355			res.Body.Close()
33356		}
33357		return nil, &googleapi.Error{
33358			Code:   res.StatusCode,
33359			Header: res.Header,
33360		}
33361	}
33362	if err != nil {
33363		return nil, err
33364	}
33365	defer googleapi.CloseBody(res)
33366	if err := googleapi.CheckResponse(res); err != nil {
33367		return nil, err
33368	}
33369	ret := &FloodlightActivitiesGenerateTagResponse{
33370		ServerResponse: googleapi.ServerResponse{
33371			Header:         res.Header,
33372			HTTPStatusCode: res.StatusCode,
33373		},
33374	}
33375	target := &ret
33376	if err := gensupport.DecodeResponse(target, res); err != nil {
33377		return nil, err
33378	}
33379	return ret, nil
33380	// {
33381	//   "description": "Generates a tag for a floodlight activity.",
33382	//   "flatPath": "userprofiles/{profileId}/floodlightActivities/generatetag",
33383	//   "httpMethod": "POST",
33384	//   "id": "dfareporting.floodlightActivities.generatetag",
33385	//   "parameterOrder": [
33386	//     "profileId"
33387	//   ],
33388	//   "parameters": {
33389	//     "floodlightActivityId": {
33390	//       "description": "Floodlight activity ID for which we want to generate a tag.",
33391	//       "format": "int64",
33392	//       "location": "query",
33393	//       "type": "string"
33394	//     },
33395	//     "profileId": {
33396	//       "description": "User profile ID associated with this request.",
33397	//       "format": "int64",
33398	//       "location": "path",
33399	//       "required": true,
33400	//       "type": "string"
33401	//     }
33402	//   },
33403	//   "path": "userprofiles/{profileId}/floodlightActivities/generatetag",
33404	//   "response": {
33405	//     "$ref": "FloodlightActivitiesGenerateTagResponse"
33406	//   },
33407	//   "scopes": [
33408	//     "https://www.googleapis.com/auth/dfatrafficking"
33409	//   ]
33410	// }
33411
33412}
33413
33414// method id "dfareporting.floodlightActivities.get":
33415
33416type FloodlightActivitiesGetCall struct {
33417	s            *Service
33418	profileId    int64
33419	id           int64
33420	urlParams_   gensupport.URLParams
33421	ifNoneMatch_ string
33422	ctx_         context.Context
33423	header_      http.Header
33424}
33425
33426// Get: Gets one floodlight activity by ID.
33427//
33428// - id: Floodlight activity ID.
33429// - profileId: User profile ID associated with this request.
33430func (r *FloodlightActivitiesService) Get(profileId int64, id int64) *FloodlightActivitiesGetCall {
33431	c := &FloodlightActivitiesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
33432	c.profileId = profileId
33433	c.id = id
33434	return c
33435}
33436
33437// Fields allows partial responses to be retrieved. See
33438// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
33439// for more information.
33440func (c *FloodlightActivitiesGetCall) Fields(s ...googleapi.Field) *FloodlightActivitiesGetCall {
33441	c.urlParams_.Set("fields", googleapi.CombineFields(s))
33442	return c
33443}
33444
33445// IfNoneMatch sets the optional parameter which makes the operation
33446// fail if the object's ETag matches the given value. This is useful for
33447// getting updates only after the object has changed since the last
33448// request. Use googleapi.IsNotModified to check whether the response
33449// error from Do is the result of In-None-Match.
33450func (c *FloodlightActivitiesGetCall) IfNoneMatch(entityTag string) *FloodlightActivitiesGetCall {
33451	c.ifNoneMatch_ = entityTag
33452	return c
33453}
33454
33455// Context sets the context to be used in this call's Do method. Any
33456// pending HTTP request will be aborted if the provided context is
33457// canceled.
33458func (c *FloodlightActivitiesGetCall) Context(ctx context.Context) *FloodlightActivitiesGetCall {
33459	c.ctx_ = ctx
33460	return c
33461}
33462
33463// Header returns an http.Header that can be modified by the caller to
33464// add HTTP headers to the request.
33465func (c *FloodlightActivitiesGetCall) Header() http.Header {
33466	if c.header_ == nil {
33467		c.header_ = make(http.Header)
33468	}
33469	return c.header_
33470}
33471
33472func (c *FloodlightActivitiesGetCall) doRequest(alt string) (*http.Response, error) {
33473	reqHeaders := make(http.Header)
33474	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
33475	for k, v := range c.header_ {
33476		reqHeaders[k] = v
33477	}
33478	reqHeaders.Set("User-Agent", c.s.userAgent())
33479	if c.ifNoneMatch_ != "" {
33480		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
33481	}
33482	var body io.Reader = nil
33483	c.urlParams_.Set("alt", alt)
33484	c.urlParams_.Set("prettyPrint", "false")
33485	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/floodlightActivities/{id}")
33486	urls += "?" + c.urlParams_.Encode()
33487	req, err := http.NewRequest("GET", urls, body)
33488	if err != nil {
33489		return nil, err
33490	}
33491	req.Header = reqHeaders
33492	googleapi.Expand(req.URL, map[string]string{
33493		"profileId": strconv.FormatInt(c.profileId, 10),
33494		"id":        strconv.FormatInt(c.id, 10),
33495	})
33496	return gensupport.SendRequest(c.ctx_, c.s.client, req)
33497}
33498
33499// Do executes the "dfareporting.floodlightActivities.get" call.
33500// Exactly one of *FloodlightActivity or error will be non-nil. Any
33501// non-2xx status code is an error. Response headers are in either
33502// *FloodlightActivity.ServerResponse.Header or (if a response was
33503// returned at all) in error.(*googleapi.Error).Header. Use
33504// googleapi.IsNotModified to check whether the returned error was
33505// because http.StatusNotModified was returned.
33506func (c *FloodlightActivitiesGetCall) Do(opts ...googleapi.CallOption) (*FloodlightActivity, error) {
33507	gensupport.SetOptions(c.urlParams_, opts...)
33508	res, err := c.doRequest("json")
33509	if res != nil && res.StatusCode == http.StatusNotModified {
33510		if res.Body != nil {
33511			res.Body.Close()
33512		}
33513		return nil, &googleapi.Error{
33514			Code:   res.StatusCode,
33515			Header: res.Header,
33516		}
33517	}
33518	if err != nil {
33519		return nil, err
33520	}
33521	defer googleapi.CloseBody(res)
33522	if err := googleapi.CheckResponse(res); err != nil {
33523		return nil, err
33524	}
33525	ret := &FloodlightActivity{
33526		ServerResponse: googleapi.ServerResponse{
33527			Header:         res.Header,
33528			HTTPStatusCode: res.StatusCode,
33529		},
33530	}
33531	target := &ret
33532	if err := gensupport.DecodeResponse(target, res); err != nil {
33533		return nil, err
33534	}
33535	return ret, nil
33536	// {
33537	//   "description": "Gets one floodlight activity by ID.",
33538	//   "flatPath": "userprofiles/{profileId}/floodlightActivities/{id}",
33539	//   "httpMethod": "GET",
33540	//   "id": "dfareporting.floodlightActivities.get",
33541	//   "parameterOrder": [
33542	//     "profileId",
33543	//     "id"
33544	//   ],
33545	//   "parameters": {
33546	//     "id": {
33547	//       "description": "Floodlight activity ID.",
33548	//       "format": "int64",
33549	//       "location": "path",
33550	//       "required": true,
33551	//       "type": "string"
33552	//     },
33553	//     "profileId": {
33554	//       "description": "User profile ID associated with this request.",
33555	//       "format": "int64",
33556	//       "location": "path",
33557	//       "required": true,
33558	//       "type": "string"
33559	//     }
33560	//   },
33561	//   "path": "userprofiles/{profileId}/floodlightActivities/{id}",
33562	//   "response": {
33563	//     "$ref": "FloodlightActivity"
33564	//   },
33565	//   "scopes": [
33566	//     "https://www.googleapis.com/auth/dfatrafficking"
33567	//   ]
33568	// }
33569
33570}
33571
33572// method id "dfareporting.floodlightActivities.insert":
33573
33574type FloodlightActivitiesInsertCall struct {
33575	s                  *Service
33576	profileId          int64
33577	floodlightactivity *FloodlightActivity
33578	urlParams_         gensupport.URLParams
33579	ctx_               context.Context
33580	header_            http.Header
33581}
33582
33583// Insert: Inserts a new floodlight activity.
33584//
33585// - profileId: User profile ID associated with this request.
33586func (r *FloodlightActivitiesService) Insert(profileId int64, floodlightactivity *FloodlightActivity) *FloodlightActivitiesInsertCall {
33587	c := &FloodlightActivitiesInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
33588	c.profileId = profileId
33589	c.floodlightactivity = floodlightactivity
33590	return c
33591}
33592
33593// Fields allows partial responses to be retrieved. See
33594// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
33595// for more information.
33596func (c *FloodlightActivitiesInsertCall) Fields(s ...googleapi.Field) *FloodlightActivitiesInsertCall {
33597	c.urlParams_.Set("fields", googleapi.CombineFields(s))
33598	return c
33599}
33600
33601// Context sets the context to be used in this call's Do method. Any
33602// pending HTTP request will be aborted if the provided context is
33603// canceled.
33604func (c *FloodlightActivitiesInsertCall) Context(ctx context.Context) *FloodlightActivitiesInsertCall {
33605	c.ctx_ = ctx
33606	return c
33607}
33608
33609// Header returns an http.Header that can be modified by the caller to
33610// add HTTP headers to the request.
33611func (c *FloodlightActivitiesInsertCall) Header() http.Header {
33612	if c.header_ == nil {
33613		c.header_ = make(http.Header)
33614	}
33615	return c.header_
33616}
33617
33618func (c *FloodlightActivitiesInsertCall) doRequest(alt string) (*http.Response, error) {
33619	reqHeaders := make(http.Header)
33620	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
33621	for k, v := range c.header_ {
33622		reqHeaders[k] = v
33623	}
33624	reqHeaders.Set("User-Agent", c.s.userAgent())
33625	var body io.Reader = nil
33626	body, err := googleapi.WithoutDataWrapper.JSONReader(c.floodlightactivity)
33627	if err != nil {
33628		return nil, err
33629	}
33630	reqHeaders.Set("Content-Type", "application/json")
33631	c.urlParams_.Set("alt", alt)
33632	c.urlParams_.Set("prettyPrint", "false")
33633	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/floodlightActivities")
33634	urls += "?" + c.urlParams_.Encode()
33635	req, err := http.NewRequest("POST", urls, body)
33636	if err != nil {
33637		return nil, err
33638	}
33639	req.Header = reqHeaders
33640	googleapi.Expand(req.URL, map[string]string{
33641		"profileId": strconv.FormatInt(c.profileId, 10),
33642	})
33643	return gensupport.SendRequest(c.ctx_, c.s.client, req)
33644}
33645
33646// Do executes the "dfareporting.floodlightActivities.insert" call.
33647// Exactly one of *FloodlightActivity or error will be non-nil. Any
33648// non-2xx status code is an error. Response headers are in either
33649// *FloodlightActivity.ServerResponse.Header or (if a response was
33650// returned at all) in error.(*googleapi.Error).Header. Use
33651// googleapi.IsNotModified to check whether the returned error was
33652// because http.StatusNotModified was returned.
33653func (c *FloodlightActivitiesInsertCall) Do(opts ...googleapi.CallOption) (*FloodlightActivity, error) {
33654	gensupport.SetOptions(c.urlParams_, opts...)
33655	res, err := c.doRequest("json")
33656	if res != nil && res.StatusCode == http.StatusNotModified {
33657		if res.Body != nil {
33658			res.Body.Close()
33659		}
33660		return nil, &googleapi.Error{
33661			Code:   res.StatusCode,
33662			Header: res.Header,
33663		}
33664	}
33665	if err != nil {
33666		return nil, err
33667	}
33668	defer googleapi.CloseBody(res)
33669	if err := googleapi.CheckResponse(res); err != nil {
33670		return nil, err
33671	}
33672	ret := &FloodlightActivity{
33673		ServerResponse: googleapi.ServerResponse{
33674			Header:         res.Header,
33675			HTTPStatusCode: res.StatusCode,
33676		},
33677	}
33678	target := &ret
33679	if err := gensupport.DecodeResponse(target, res); err != nil {
33680		return nil, err
33681	}
33682	return ret, nil
33683	// {
33684	//   "description": "Inserts a new floodlight activity.",
33685	//   "flatPath": "userprofiles/{profileId}/floodlightActivities",
33686	//   "httpMethod": "POST",
33687	//   "id": "dfareporting.floodlightActivities.insert",
33688	//   "parameterOrder": [
33689	//     "profileId"
33690	//   ],
33691	//   "parameters": {
33692	//     "profileId": {
33693	//       "description": "User profile ID associated with this request.",
33694	//       "format": "int64",
33695	//       "location": "path",
33696	//       "required": true,
33697	//       "type": "string"
33698	//     }
33699	//   },
33700	//   "path": "userprofiles/{profileId}/floodlightActivities",
33701	//   "request": {
33702	//     "$ref": "FloodlightActivity"
33703	//   },
33704	//   "response": {
33705	//     "$ref": "FloodlightActivity"
33706	//   },
33707	//   "scopes": [
33708	//     "https://www.googleapis.com/auth/dfatrafficking"
33709	//   ]
33710	// }
33711
33712}
33713
33714// method id "dfareporting.floodlightActivities.list":
33715
33716type FloodlightActivitiesListCall struct {
33717	s            *Service
33718	profileId    int64
33719	urlParams_   gensupport.URLParams
33720	ifNoneMatch_ string
33721	ctx_         context.Context
33722	header_      http.Header
33723}
33724
33725// List: Retrieves a list of floodlight activities, possibly filtered.
33726// This method supports paging.
33727//
33728// - profileId: User profile ID associated with this request.
33729func (r *FloodlightActivitiesService) List(profileId int64) *FloodlightActivitiesListCall {
33730	c := &FloodlightActivitiesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
33731	c.profileId = profileId
33732	return c
33733}
33734
33735// AdvertiserId sets the optional parameter "advertiserId": Select only
33736// floodlight activities for the specified advertiser ID. Must specify
33737// either ids, advertiserId, or floodlightConfigurationId for a
33738// non-empty result.
33739func (c *FloodlightActivitiesListCall) AdvertiserId(advertiserId int64) *FloodlightActivitiesListCall {
33740	c.urlParams_.Set("advertiserId", fmt.Sprint(advertiserId))
33741	return c
33742}
33743
33744// FloodlightActivityGroupIds sets the optional parameter
33745// "floodlightActivityGroupIds": Select only floodlight activities with
33746// the specified floodlight activity group IDs.
33747func (c *FloodlightActivitiesListCall) FloodlightActivityGroupIds(floodlightActivityGroupIds ...int64) *FloodlightActivitiesListCall {
33748	var floodlightActivityGroupIds_ []string
33749	for _, v := range floodlightActivityGroupIds {
33750		floodlightActivityGroupIds_ = append(floodlightActivityGroupIds_, fmt.Sprint(v))
33751	}
33752	c.urlParams_.SetMulti("floodlightActivityGroupIds", floodlightActivityGroupIds_)
33753	return c
33754}
33755
33756// FloodlightActivityGroupName sets the optional parameter
33757// "floodlightActivityGroupName": Select only floodlight activities with
33758// the specified floodlight activity group name.
33759func (c *FloodlightActivitiesListCall) FloodlightActivityGroupName(floodlightActivityGroupName string) *FloodlightActivitiesListCall {
33760	c.urlParams_.Set("floodlightActivityGroupName", floodlightActivityGroupName)
33761	return c
33762}
33763
33764// FloodlightActivityGroupTagString sets the optional parameter
33765// "floodlightActivityGroupTagString": Select only floodlight activities
33766// with the specified floodlight activity group tag string.
33767func (c *FloodlightActivitiesListCall) FloodlightActivityGroupTagString(floodlightActivityGroupTagString string) *FloodlightActivitiesListCall {
33768	c.urlParams_.Set("floodlightActivityGroupTagString", floodlightActivityGroupTagString)
33769	return c
33770}
33771
33772// FloodlightActivityGroupType sets the optional parameter
33773// "floodlightActivityGroupType": Select only floodlight activities with
33774// the specified floodlight activity group type.
33775//
33776// Possible values:
33777//   "COUNTER"
33778//   "SALE"
33779func (c *FloodlightActivitiesListCall) FloodlightActivityGroupType(floodlightActivityGroupType string) *FloodlightActivitiesListCall {
33780	c.urlParams_.Set("floodlightActivityGroupType", floodlightActivityGroupType)
33781	return c
33782}
33783
33784// FloodlightConfigurationId sets the optional parameter
33785// "floodlightConfigurationId": Select only floodlight activities for
33786// the specified floodlight configuration ID. Must specify either ids,
33787// advertiserId, or floodlightConfigurationId for a non-empty result.
33788func (c *FloodlightActivitiesListCall) FloodlightConfigurationId(floodlightConfigurationId int64) *FloodlightActivitiesListCall {
33789	c.urlParams_.Set("floodlightConfigurationId", fmt.Sprint(floodlightConfigurationId))
33790	return c
33791}
33792
33793// Ids sets the optional parameter "ids": Select only floodlight
33794// activities with the specified IDs. Must specify either ids,
33795// advertiserId, or floodlightConfigurationId for a non-empty result.
33796func (c *FloodlightActivitiesListCall) Ids(ids ...int64) *FloodlightActivitiesListCall {
33797	var ids_ []string
33798	for _, v := range ids {
33799		ids_ = append(ids_, fmt.Sprint(v))
33800	}
33801	c.urlParams_.SetMulti("ids", ids_)
33802	return c
33803}
33804
33805// MaxResults sets the optional parameter "maxResults": Maximum number
33806// of results to return.
33807func (c *FloodlightActivitiesListCall) MaxResults(maxResults int64) *FloodlightActivitiesListCall {
33808	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
33809	return c
33810}
33811
33812// PageToken sets the optional parameter "pageToken": Value of the
33813// nextPageToken from the previous result page.
33814func (c *FloodlightActivitiesListCall) PageToken(pageToken string) *FloodlightActivitiesListCall {
33815	c.urlParams_.Set("pageToken", pageToken)
33816	return c
33817}
33818
33819// SearchString sets the optional parameter "searchString": Allows
33820// searching for objects by name or ID. Wildcards (*) are allowed. For
33821// example, "floodlightactivity*2015" will return objects with names
33822// like "floodlightactivity June 2015", "floodlightactivity April 2015",
33823// or simply "floodlightactivity 2015". Most of the searches also add
33824// wildcards implicitly at the start and the end of the search string.
33825// For example, a search string of "floodlightactivity" will match
33826// objects with name "my floodlightactivity activity",
33827// "floodlightactivity 2015", or simply "floodlightactivity".
33828func (c *FloodlightActivitiesListCall) SearchString(searchString string) *FloodlightActivitiesListCall {
33829	c.urlParams_.Set("searchString", searchString)
33830	return c
33831}
33832
33833// SortField sets the optional parameter "sortField": Field by which to
33834// sort the list.
33835//
33836// Possible values:
33837//   "ID" (default)
33838//   "NAME"
33839func (c *FloodlightActivitiesListCall) SortField(sortField string) *FloodlightActivitiesListCall {
33840	c.urlParams_.Set("sortField", sortField)
33841	return c
33842}
33843
33844// SortOrder sets the optional parameter "sortOrder": Order of sorted
33845// results.
33846//
33847// Possible values:
33848//   "ASCENDING" (default)
33849//   "DESCENDING"
33850func (c *FloodlightActivitiesListCall) SortOrder(sortOrder string) *FloodlightActivitiesListCall {
33851	c.urlParams_.Set("sortOrder", sortOrder)
33852	return c
33853}
33854
33855// TagString sets the optional parameter "tagString": Select only
33856// floodlight activities with the specified tag string.
33857func (c *FloodlightActivitiesListCall) TagString(tagString string) *FloodlightActivitiesListCall {
33858	c.urlParams_.Set("tagString", tagString)
33859	return c
33860}
33861
33862// Fields allows partial responses to be retrieved. See
33863// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
33864// for more information.
33865func (c *FloodlightActivitiesListCall) Fields(s ...googleapi.Field) *FloodlightActivitiesListCall {
33866	c.urlParams_.Set("fields", googleapi.CombineFields(s))
33867	return c
33868}
33869
33870// IfNoneMatch sets the optional parameter which makes the operation
33871// fail if the object's ETag matches the given value. This is useful for
33872// getting updates only after the object has changed since the last
33873// request. Use googleapi.IsNotModified to check whether the response
33874// error from Do is the result of In-None-Match.
33875func (c *FloodlightActivitiesListCall) IfNoneMatch(entityTag string) *FloodlightActivitiesListCall {
33876	c.ifNoneMatch_ = entityTag
33877	return c
33878}
33879
33880// Context sets the context to be used in this call's Do method. Any
33881// pending HTTP request will be aborted if the provided context is
33882// canceled.
33883func (c *FloodlightActivitiesListCall) Context(ctx context.Context) *FloodlightActivitiesListCall {
33884	c.ctx_ = ctx
33885	return c
33886}
33887
33888// Header returns an http.Header that can be modified by the caller to
33889// add HTTP headers to the request.
33890func (c *FloodlightActivitiesListCall) Header() http.Header {
33891	if c.header_ == nil {
33892		c.header_ = make(http.Header)
33893	}
33894	return c.header_
33895}
33896
33897func (c *FloodlightActivitiesListCall) doRequest(alt string) (*http.Response, error) {
33898	reqHeaders := make(http.Header)
33899	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
33900	for k, v := range c.header_ {
33901		reqHeaders[k] = v
33902	}
33903	reqHeaders.Set("User-Agent", c.s.userAgent())
33904	if c.ifNoneMatch_ != "" {
33905		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
33906	}
33907	var body io.Reader = nil
33908	c.urlParams_.Set("alt", alt)
33909	c.urlParams_.Set("prettyPrint", "false")
33910	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/floodlightActivities")
33911	urls += "?" + c.urlParams_.Encode()
33912	req, err := http.NewRequest("GET", urls, body)
33913	if err != nil {
33914		return nil, err
33915	}
33916	req.Header = reqHeaders
33917	googleapi.Expand(req.URL, map[string]string{
33918		"profileId": strconv.FormatInt(c.profileId, 10),
33919	})
33920	return gensupport.SendRequest(c.ctx_, c.s.client, req)
33921}
33922
33923// Do executes the "dfareporting.floodlightActivities.list" call.
33924// Exactly one of *FloodlightActivitiesListResponse or error will be
33925// non-nil. Any non-2xx status code is an error. Response headers are in
33926// either *FloodlightActivitiesListResponse.ServerResponse.Header or (if
33927// a response was returned at all) in error.(*googleapi.Error).Header.
33928// Use googleapi.IsNotModified to check whether the returned error was
33929// because http.StatusNotModified was returned.
33930func (c *FloodlightActivitiesListCall) Do(opts ...googleapi.CallOption) (*FloodlightActivitiesListResponse, error) {
33931	gensupport.SetOptions(c.urlParams_, opts...)
33932	res, err := c.doRequest("json")
33933	if res != nil && res.StatusCode == http.StatusNotModified {
33934		if res.Body != nil {
33935			res.Body.Close()
33936		}
33937		return nil, &googleapi.Error{
33938			Code:   res.StatusCode,
33939			Header: res.Header,
33940		}
33941	}
33942	if err != nil {
33943		return nil, err
33944	}
33945	defer googleapi.CloseBody(res)
33946	if err := googleapi.CheckResponse(res); err != nil {
33947		return nil, err
33948	}
33949	ret := &FloodlightActivitiesListResponse{
33950		ServerResponse: googleapi.ServerResponse{
33951			Header:         res.Header,
33952			HTTPStatusCode: res.StatusCode,
33953		},
33954	}
33955	target := &ret
33956	if err := gensupport.DecodeResponse(target, res); err != nil {
33957		return nil, err
33958	}
33959	return ret, nil
33960	// {
33961	//   "description": "Retrieves a list of floodlight activities, possibly filtered. This method supports paging.",
33962	//   "flatPath": "userprofiles/{profileId}/floodlightActivities",
33963	//   "httpMethod": "GET",
33964	//   "id": "dfareporting.floodlightActivities.list",
33965	//   "parameterOrder": [
33966	//     "profileId"
33967	//   ],
33968	//   "parameters": {
33969	//     "advertiserId": {
33970	//       "description": "Select only floodlight activities for the specified advertiser ID. Must specify either ids, advertiserId, or floodlightConfigurationId for a non-empty result.",
33971	//       "format": "int64",
33972	//       "location": "query",
33973	//       "type": "string"
33974	//     },
33975	//     "floodlightActivityGroupIds": {
33976	//       "description": "Select only floodlight activities with the specified floodlight activity group IDs.",
33977	//       "format": "int64",
33978	//       "location": "query",
33979	//       "repeated": true,
33980	//       "type": "string"
33981	//     },
33982	//     "floodlightActivityGroupName": {
33983	//       "description": "Select only floodlight activities with the specified floodlight activity group name.",
33984	//       "location": "query",
33985	//       "type": "string"
33986	//     },
33987	//     "floodlightActivityGroupTagString": {
33988	//       "description": "Select only floodlight activities with the specified floodlight activity group tag string.",
33989	//       "location": "query",
33990	//       "type": "string"
33991	//     },
33992	//     "floodlightActivityGroupType": {
33993	//       "description": "Select only floodlight activities with the specified floodlight activity group type.",
33994	//       "enum": [
33995	//         "COUNTER",
33996	//         "SALE"
33997	//       ],
33998	//       "enumDescriptions": [
33999	//         "",
34000	//         ""
34001	//       ],
34002	//       "location": "query",
34003	//       "type": "string"
34004	//     },
34005	//     "floodlightConfigurationId": {
34006	//       "description": "Select only floodlight activities for the specified floodlight configuration ID. Must specify either ids, advertiserId, or floodlightConfigurationId for a non-empty result.",
34007	//       "format": "int64",
34008	//       "location": "query",
34009	//       "type": "string"
34010	//     },
34011	//     "ids": {
34012	//       "description": "Select only floodlight activities with the specified IDs. Must specify either ids, advertiserId, or floodlightConfigurationId for a non-empty result.",
34013	//       "format": "int64",
34014	//       "location": "query",
34015	//       "repeated": true,
34016	//       "type": "string"
34017	//     },
34018	//     "maxResults": {
34019	//       "default": "1000",
34020	//       "description": "Maximum number of results to return.",
34021	//       "format": "int32",
34022	//       "location": "query",
34023	//       "maximum": "1000",
34024	//       "minimum": "0",
34025	//       "type": "integer"
34026	//     },
34027	//     "pageToken": {
34028	//       "description": "Value of the nextPageToken from the previous result page.",
34029	//       "location": "query",
34030	//       "type": "string"
34031	//     },
34032	//     "profileId": {
34033	//       "description": "User profile ID associated with this request.",
34034	//       "format": "int64",
34035	//       "location": "path",
34036	//       "required": true,
34037	//       "type": "string"
34038	//     },
34039	//     "searchString": {
34040	//       "description": "Allows searching for objects by name or ID. Wildcards (*) are allowed. For example, \"floodlightactivity*2015\" will return objects with names like \"floodlightactivity June 2015\", \"floodlightactivity April 2015\", or simply \"floodlightactivity 2015\". Most of the searches also add wildcards implicitly at the start and the end of the search string. For example, a search string of \"floodlightactivity\" will match objects with name \"my floodlightactivity activity\", \"floodlightactivity 2015\", or simply \"floodlightactivity\".",
34041	//       "location": "query",
34042	//       "type": "string"
34043	//     },
34044	//     "sortField": {
34045	//       "default": "ID",
34046	//       "description": "Field by which to sort the list.",
34047	//       "enum": [
34048	//         "ID",
34049	//         "NAME"
34050	//       ],
34051	//       "enumDescriptions": [
34052	//         "",
34053	//         ""
34054	//       ],
34055	//       "location": "query",
34056	//       "type": "string"
34057	//     },
34058	//     "sortOrder": {
34059	//       "default": "ASCENDING",
34060	//       "description": "Order of sorted results.",
34061	//       "enum": [
34062	//         "ASCENDING",
34063	//         "DESCENDING"
34064	//       ],
34065	//       "enumDescriptions": [
34066	//         "",
34067	//         ""
34068	//       ],
34069	//       "location": "query",
34070	//       "type": "string"
34071	//     },
34072	//     "tagString": {
34073	//       "description": "Select only floodlight activities with the specified tag string.",
34074	//       "location": "query",
34075	//       "type": "string"
34076	//     }
34077	//   },
34078	//   "path": "userprofiles/{profileId}/floodlightActivities",
34079	//   "response": {
34080	//     "$ref": "FloodlightActivitiesListResponse"
34081	//   },
34082	//   "scopes": [
34083	//     "https://www.googleapis.com/auth/dfatrafficking"
34084	//   ]
34085	// }
34086
34087}
34088
34089// Pages invokes f for each page of results.
34090// A non-nil error returned from f will halt the iteration.
34091// The provided context supersedes any context provided to the Context method.
34092func (c *FloodlightActivitiesListCall) Pages(ctx context.Context, f func(*FloodlightActivitiesListResponse) error) error {
34093	c.ctx_ = ctx
34094	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
34095	for {
34096		x, err := c.Do()
34097		if err != nil {
34098			return err
34099		}
34100		if err := f(x); err != nil {
34101			return err
34102		}
34103		if x.NextPageToken == "" {
34104			return nil
34105		}
34106		c.PageToken(x.NextPageToken)
34107	}
34108}
34109
34110// method id "dfareporting.floodlightActivities.patch":
34111
34112type FloodlightActivitiesPatchCall struct {
34113	s                  *Service
34114	profileId          int64
34115	floodlightactivity *FloodlightActivity
34116	urlParams_         gensupport.URLParams
34117	ctx_               context.Context
34118	header_            http.Header
34119}
34120
34121// Patch: Updates an existing floodlight activity. This method supports
34122// patch semantics.
34123//
34124// - id: FloodlightActivity ID.
34125// - profileId: User profile ID associated with this request.
34126func (r *FloodlightActivitiesService) Patch(profileId int64, id int64, floodlightactivity *FloodlightActivity) *FloodlightActivitiesPatchCall {
34127	c := &FloodlightActivitiesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
34128	c.profileId = profileId
34129	c.urlParams_.Set("id", fmt.Sprint(id))
34130	c.floodlightactivity = floodlightactivity
34131	return c
34132}
34133
34134// Fields allows partial responses to be retrieved. See
34135// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
34136// for more information.
34137func (c *FloodlightActivitiesPatchCall) Fields(s ...googleapi.Field) *FloodlightActivitiesPatchCall {
34138	c.urlParams_.Set("fields", googleapi.CombineFields(s))
34139	return c
34140}
34141
34142// Context sets the context to be used in this call's Do method. Any
34143// pending HTTP request will be aborted if the provided context is
34144// canceled.
34145func (c *FloodlightActivitiesPatchCall) Context(ctx context.Context) *FloodlightActivitiesPatchCall {
34146	c.ctx_ = ctx
34147	return c
34148}
34149
34150// Header returns an http.Header that can be modified by the caller to
34151// add HTTP headers to the request.
34152func (c *FloodlightActivitiesPatchCall) Header() http.Header {
34153	if c.header_ == nil {
34154		c.header_ = make(http.Header)
34155	}
34156	return c.header_
34157}
34158
34159func (c *FloodlightActivitiesPatchCall) doRequest(alt string) (*http.Response, error) {
34160	reqHeaders := make(http.Header)
34161	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
34162	for k, v := range c.header_ {
34163		reqHeaders[k] = v
34164	}
34165	reqHeaders.Set("User-Agent", c.s.userAgent())
34166	var body io.Reader = nil
34167	body, err := googleapi.WithoutDataWrapper.JSONReader(c.floodlightactivity)
34168	if err != nil {
34169		return nil, err
34170	}
34171	reqHeaders.Set("Content-Type", "application/json")
34172	c.urlParams_.Set("alt", alt)
34173	c.urlParams_.Set("prettyPrint", "false")
34174	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/floodlightActivities")
34175	urls += "?" + c.urlParams_.Encode()
34176	req, err := http.NewRequest("PATCH", urls, body)
34177	if err != nil {
34178		return nil, err
34179	}
34180	req.Header = reqHeaders
34181	googleapi.Expand(req.URL, map[string]string{
34182		"profileId": strconv.FormatInt(c.profileId, 10),
34183	})
34184	return gensupport.SendRequest(c.ctx_, c.s.client, req)
34185}
34186
34187// Do executes the "dfareporting.floodlightActivities.patch" call.
34188// Exactly one of *FloodlightActivity or error will be non-nil. Any
34189// non-2xx status code is an error. Response headers are in either
34190// *FloodlightActivity.ServerResponse.Header or (if a response was
34191// returned at all) in error.(*googleapi.Error).Header. Use
34192// googleapi.IsNotModified to check whether the returned error was
34193// because http.StatusNotModified was returned.
34194func (c *FloodlightActivitiesPatchCall) Do(opts ...googleapi.CallOption) (*FloodlightActivity, error) {
34195	gensupport.SetOptions(c.urlParams_, opts...)
34196	res, err := c.doRequest("json")
34197	if res != nil && res.StatusCode == http.StatusNotModified {
34198		if res.Body != nil {
34199			res.Body.Close()
34200		}
34201		return nil, &googleapi.Error{
34202			Code:   res.StatusCode,
34203			Header: res.Header,
34204		}
34205	}
34206	if err != nil {
34207		return nil, err
34208	}
34209	defer googleapi.CloseBody(res)
34210	if err := googleapi.CheckResponse(res); err != nil {
34211		return nil, err
34212	}
34213	ret := &FloodlightActivity{
34214		ServerResponse: googleapi.ServerResponse{
34215			Header:         res.Header,
34216			HTTPStatusCode: res.StatusCode,
34217		},
34218	}
34219	target := &ret
34220	if err := gensupport.DecodeResponse(target, res); err != nil {
34221		return nil, err
34222	}
34223	return ret, nil
34224	// {
34225	//   "description": "Updates an existing floodlight activity. This method supports patch semantics.",
34226	//   "flatPath": "userprofiles/{profileId}/floodlightActivities",
34227	//   "httpMethod": "PATCH",
34228	//   "id": "dfareporting.floodlightActivities.patch",
34229	//   "parameterOrder": [
34230	//     "profileId",
34231	//     "id"
34232	//   ],
34233	//   "parameters": {
34234	//     "id": {
34235	//       "description": "FloodlightActivity ID.",
34236	//       "format": "int64",
34237	//       "location": "query",
34238	//       "required": true,
34239	//       "type": "string"
34240	//     },
34241	//     "profileId": {
34242	//       "description": "User profile ID associated with this request.",
34243	//       "format": "int64",
34244	//       "location": "path",
34245	//       "required": true,
34246	//       "type": "string"
34247	//     }
34248	//   },
34249	//   "path": "userprofiles/{profileId}/floodlightActivities",
34250	//   "request": {
34251	//     "$ref": "FloodlightActivity"
34252	//   },
34253	//   "response": {
34254	//     "$ref": "FloodlightActivity"
34255	//   },
34256	//   "scopes": [
34257	//     "https://www.googleapis.com/auth/dfatrafficking"
34258	//   ]
34259	// }
34260
34261}
34262
34263// method id "dfareporting.floodlightActivities.update":
34264
34265type FloodlightActivitiesUpdateCall struct {
34266	s                  *Service
34267	profileId          int64
34268	floodlightactivity *FloodlightActivity
34269	urlParams_         gensupport.URLParams
34270	ctx_               context.Context
34271	header_            http.Header
34272}
34273
34274// Update: Updates an existing floodlight activity.
34275//
34276// - profileId: User profile ID associated with this request.
34277func (r *FloodlightActivitiesService) Update(profileId int64, floodlightactivity *FloodlightActivity) *FloodlightActivitiesUpdateCall {
34278	c := &FloodlightActivitiesUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
34279	c.profileId = profileId
34280	c.floodlightactivity = floodlightactivity
34281	return c
34282}
34283
34284// Fields allows partial responses to be retrieved. See
34285// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
34286// for more information.
34287func (c *FloodlightActivitiesUpdateCall) Fields(s ...googleapi.Field) *FloodlightActivitiesUpdateCall {
34288	c.urlParams_.Set("fields", googleapi.CombineFields(s))
34289	return c
34290}
34291
34292// Context sets the context to be used in this call's Do method. Any
34293// pending HTTP request will be aborted if the provided context is
34294// canceled.
34295func (c *FloodlightActivitiesUpdateCall) Context(ctx context.Context) *FloodlightActivitiesUpdateCall {
34296	c.ctx_ = ctx
34297	return c
34298}
34299
34300// Header returns an http.Header that can be modified by the caller to
34301// add HTTP headers to the request.
34302func (c *FloodlightActivitiesUpdateCall) Header() http.Header {
34303	if c.header_ == nil {
34304		c.header_ = make(http.Header)
34305	}
34306	return c.header_
34307}
34308
34309func (c *FloodlightActivitiesUpdateCall) doRequest(alt string) (*http.Response, error) {
34310	reqHeaders := make(http.Header)
34311	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
34312	for k, v := range c.header_ {
34313		reqHeaders[k] = v
34314	}
34315	reqHeaders.Set("User-Agent", c.s.userAgent())
34316	var body io.Reader = nil
34317	body, err := googleapi.WithoutDataWrapper.JSONReader(c.floodlightactivity)
34318	if err != nil {
34319		return nil, err
34320	}
34321	reqHeaders.Set("Content-Type", "application/json")
34322	c.urlParams_.Set("alt", alt)
34323	c.urlParams_.Set("prettyPrint", "false")
34324	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/floodlightActivities")
34325	urls += "?" + c.urlParams_.Encode()
34326	req, err := http.NewRequest("PUT", urls, body)
34327	if err != nil {
34328		return nil, err
34329	}
34330	req.Header = reqHeaders
34331	googleapi.Expand(req.URL, map[string]string{
34332		"profileId": strconv.FormatInt(c.profileId, 10),
34333	})
34334	return gensupport.SendRequest(c.ctx_, c.s.client, req)
34335}
34336
34337// Do executes the "dfareporting.floodlightActivities.update" call.
34338// Exactly one of *FloodlightActivity or error will be non-nil. Any
34339// non-2xx status code is an error. Response headers are in either
34340// *FloodlightActivity.ServerResponse.Header or (if a response was
34341// returned at all) in error.(*googleapi.Error).Header. Use
34342// googleapi.IsNotModified to check whether the returned error was
34343// because http.StatusNotModified was returned.
34344func (c *FloodlightActivitiesUpdateCall) Do(opts ...googleapi.CallOption) (*FloodlightActivity, error) {
34345	gensupport.SetOptions(c.urlParams_, opts...)
34346	res, err := c.doRequest("json")
34347	if res != nil && res.StatusCode == http.StatusNotModified {
34348		if res.Body != nil {
34349			res.Body.Close()
34350		}
34351		return nil, &googleapi.Error{
34352			Code:   res.StatusCode,
34353			Header: res.Header,
34354		}
34355	}
34356	if err != nil {
34357		return nil, err
34358	}
34359	defer googleapi.CloseBody(res)
34360	if err := googleapi.CheckResponse(res); err != nil {
34361		return nil, err
34362	}
34363	ret := &FloodlightActivity{
34364		ServerResponse: googleapi.ServerResponse{
34365			Header:         res.Header,
34366			HTTPStatusCode: res.StatusCode,
34367		},
34368	}
34369	target := &ret
34370	if err := gensupport.DecodeResponse(target, res); err != nil {
34371		return nil, err
34372	}
34373	return ret, nil
34374	// {
34375	//   "description": "Updates an existing floodlight activity.",
34376	//   "flatPath": "userprofiles/{profileId}/floodlightActivities",
34377	//   "httpMethod": "PUT",
34378	//   "id": "dfareporting.floodlightActivities.update",
34379	//   "parameterOrder": [
34380	//     "profileId"
34381	//   ],
34382	//   "parameters": {
34383	//     "profileId": {
34384	//       "description": "User profile ID associated with this request.",
34385	//       "format": "int64",
34386	//       "location": "path",
34387	//       "required": true,
34388	//       "type": "string"
34389	//     }
34390	//   },
34391	//   "path": "userprofiles/{profileId}/floodlightActivities",
34392	//   "request": {
34393	//     "$ref": "FloodlightActivity"
34394	//   },
34395	//   "response": {
34396	//     "$ref": "FloodlightActivity"
34397	//   },
34398	//   "scopes": [
34399	//     "https://www.googleapis.com/auth/dfatrafficking"
34400	//   ]
34401	// }
34402
34403}
34404
34405// method id "dfareporting.floodlightActivityGroups.get":
34406
34407type FloodlightActivityGroupsGetCall struct {
34408	s            *Service
34409	profileId    int64
34410	id           int64
34411	urlParams_   gensupport.URLParams
34412	ifNoneMatch_ string
34413	ctx_         context.Context
34414	header_      http.Header
34415}
34416
34417// Get: Gets one floodlight activity group by ID.
34418//
34419// - id: Floodlight activity Group ID.
34420// - profileId: User profile ID associated with this request.
34421func (r *FloodlightActivityGroupsService) Get(profileId int64, id int64) *FloodlightActivityGroupsGetCall {
34422	c := &FloodlightActivityGroupsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
34423	c.profileId = profileId
34424	c.id = id
34425	return c
34426}
34427
34428// Fields allows partial responses to be retrieved. See
34429// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
34430// for more information.
34431func (c *FloodlightActivityGroupsGetCall) Fields(s ...googleapi.Field) *FloodlightActivityGroupsGetCall {
34432	c.urlParams_.Set("fields", googleapi.CombineFields(s))
34433	return c
34434}
34435
34436// IfNoneMatch sets the optional parameter which makes the operation
34437// fail if the object's ETag matches the given value. This is useful for
34438// getting updates only after the object has changed since the last
34439// request. Use googleapi.IsNotModified to check whether the response
34440// error from Do is the result of In-None-Match.
34441func (c *FloodlightActivityGroupsGetCall) IfNoneMatch(entityTag string) *FloodlightActivityGroupsGetCall {
34442	c.ifNoneMatch_ = entityTag
34443	return c
34444}
34445
34446// Context sets the context to be used in this call's Do method. Any
34447// pending HTTP request will be aborted if the provided context is
34448// canceled.
34449func (c *FloodlightActivityGroupsGetCall) Context(ctx context.Context) *FloodlightActivityGroupsGetCall {
34450	c.ctx_ = ctx
34451	return c
34452}
34453
34454// Header returns an http.Header that can be modified by the caller to
34455// add HTTP headers to the request.
34456func (c *FloodlightActivityGroupsGetCall) Header() http.Header {
34457	if c.header_ == nil {
34458		c.header_ = make(http.Header)
34459	}
34460	return c.header_
34461}
34462
34463func (c *FloodlightActivityGroupsGetCall) doRequest(alt string) (*http.Response, error) {
34464	reqHeaders := make(http.Header)
34465	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
34466	for k, v := range c.header_ {
34467		reqHeaders[k] = v
34468	}
34469	reqHeaders.Set("User-Agent", c.s.userAgent())
34470	if c.ifNoneMatch_ != "" {
34471		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
34472	}
34473	var body io.Reader = nil
34474	c.urlParams_.Set("alt", alt)
34475	c.urlParams_.Set("prettyPrint", "false")
34476	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/floodlightActivityGroups/{id}")
34477	urls += "?" + c.urlParams_.Encode()
34478	req, err := http.NewRequest("GET", urls, body)
34479	if err != nil {
34480		return nil, err
34481	}
34482	req.Header = reqHeaders
34483	googleapi.Expand(req.URL, map[string]string{
34484		"profileId": strconv.FormatInt(c.profileId, 10),
34485		"id":        strconv.FormatInt(c.id, 10),
34486	})
34487	return gensupport.SendRequest(c.ctx_, c.s.client, req)
34488}
34489
34490// Do executes the "dfareporting.floodlightActivityGroups.get" call.
34491// Exactly one of *FloodlightActivityGroup or error will be non-nil. Any
34492// non-2xx status code is an error. Response headers are in either
34493// *FloodlightActivityGroup.ServerResponse.Header or (if a response was
34494// returned at all) in error.(*googleapi.Error).Header. Use
34495// googleapi.IsNotModified to check whether the returned error was
34496// because http.StatusNotModified was returned.
34497func (c *FloodlightActivityGroupsGetCall) Do(opts ...googleapi.CallOption) (*FloodlightActivityGroup, error) {
34498	gensupport.SetOptions(c.urlParams_, opts...)
34499	res, err := c.doRequest("json")
34500	if res != nil && res.StatusCode == http.StatusNotModified {
34501		if res.Body != nil {
34502			res.Body.Close()
34503		}
34504		return nil, &googleapi.Error{
34505			Code:   res.StatusCode,
34506			Header: res.Header,
34507		}
34508	}
34509	if err != nil {
34510		return nil, err
34511	}
34512	defer googleapi.CloseBody(res)
34513	if err := googleapi.CheckResponse(res); err != nil {
34514		return nil, err
34515	}
34516	ret := &FloodlightActivityGroup{
34517		ServerResponse: googleapi.ServerResponse{
34518			Header:         res.Header,
34519			HTTPStatusCode: res.StatusCode,
34520		},
34521	}
34522	target := &ret
34523	if err := gensupport.DecodeResponse(target, res); err != nil {
34524		return nil, err
34525	}
34526	return ret, nil
34527	// {
34528	//   "description": "Gets one floodlight activity group by ID.",
34529	//   "flatPath": "userprofiles/{profileId}/floodlightActivityGroups/{id}",
34530	//   "httpMethod": "GET",
34531	//   "id": "dfareporting.floodlightActivityGroups.get",
34532	//   "parameterOrder": [
34533	//     "profileId",
34534	//     "id"
34535	//   ],
34536	//   "parameters": {
34537	//     "id": {
34538	//       "description": "Floodlight activity Group ID.",
34539	//       "format": "int64",
34540	//       "location": "path",
34541	//       "required": true,
34542	//       "type": "string"
34543	//     },
34544	//     "profileId": {
34545	//       "description": "User profile ID associated with this request.",
34546	//       "format": "int64",
34547	//       "location": "path",
34548	//       "required": true,
34549	//       "type": "string"
34550	//     }
34551	//   },
34552	//   "path": "userprofiles/{profileId}/floodlightActivityGroups/{id}",
34553	//   "response": {
34554	//     "$ref": "FloodlightActivityGroup"
34555	//   },
34556	//   "scopes": [
34557	//     "https://www.googleapis.com/auth/dfatrafficking"
34558	//   ]
34559	// }
34560
34561}
34562
34563// method id "dfareporting.floodlightActivityGroups.insert":
34564
34565type FloodlightActivityGroupsInsertCall struct {
34566	s                       *Service
34567	profileId               int64
34568	floodlightactivitygroup *FloodlightActivityGroup
34569	urlParams_              gensupport.URLParams
34570	ctx_                    context.Context
34571	header_                 http.Header
34572}
34573
34574// Insert: Inserts a new floodlight activity group.
34575//
34576// - profileId: User profile ID associated with this request.
34577func (r *FloodlightActivityGroupsService) Insert(profileId int64, floodlightactivitygroup *FloodlightActivityGroup) *FloodlightActivityGroupsInsertCall {
34578	c := &FloodlightActivityGroupsInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
34579	c.profileId = profileId
34580	c.floodlightactivitygroup = floodlightactivitygroup
34581	return c
34582}
34583
34584// Fields allows partial responses to be retrieved. See
34585// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
34586// for more information.
34587func (c *FloodlightActivityGroupsInsertCall) Fields(s ...googleapi.Field) *FloodlightActivityGroupsInsertCall {
34588	c.urlParams_.Set("fields", googleapi.CombineFields(s))
34589	return c
34590}
34591
34592// Context sets the context to be used in this call's Do method. Any
34593// pending HTTP request will be aborted if the provided context is
34594// canceled.
34595func (c *FloodlightActivityGroupsInsertCall) Context(ctx context.Context) *FloodlightActivityGroupsInsertCall {
34596	c.ctx_ = ctx
34597	return c
34598}
34599
34600// Header returns an http.Header that can be modified by the caller to
34601// add HTTP headers to the request.
34602func (c *FloodlightActivityGroupsInsertCall) Header() http.Header {
34603	if c.header_ == nil {
34604		c.header_ = make(http.Header)
34605	}
34606	return c.header_
34607}
34608
34609func (c *FloodlightActivityGroupsInsertCall) doRequest(alt string) (*http.Response, error) {
34610	reqHeaders := make(http.Header)
34611	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
34612	for k, v := range c.header_ {
34613		reqHeaders[k] = v
34614	}
34615	reqHeaders.Set("User-Agent", c.s.userAgent())
34616	var body io.Reader = nil
34617	body, err := googleapi.WithoutDataWrapper.JSONReader(c.floodlightactivitygroup)
34618	if err != nil {
34619		return nil, err
34620	}
34621	reqHeaders.Set("Content-Type", "application/json")
34622	c.urlParams_.Set("alt", alt)
34623	c.urlParams_.Set("prettyPrint", "false")
34624	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/floodlightActivityGroups")
34625	urls += "?" + c.urlParams_.Encode()
34626	req, err := http.NewRequest("POST", urls, body)
34627	if err != nil {
34628		return nil, err
34629	}
34630	req.Header = reqHeaders
34631	googleapi.Expand(req.URL, map[string]string{
34632		"profileId": strconv.FormatInt(c.profileId, 10),
34633	})
34634	return gensupport.SendRequest(c.ctx_, c.s.client, req)
34635}
34636
34637// Do executes the "dfareporting.floodlightActivityGroups.insert" call.
34638// Exactly one of *FloodlightActivityGroup or error will be non-nil. Any
34639// non-2xx status code is an error. Response headers are in either
34640// *FloodlightActivityGroup.ServerResponse.Header or (if a response was
34641// returned at all) in error.(*googleapi.Error).Header. Use
34642// googleapi.IsNotModified to check whether the returned error was
34643// because http.StatusNotModified was returned.
34644func (c *FloodlightActivityGroupsInsertCall) Do(opts ...googleapi.CallOption) (*FloodlightActivityGroup, error) {
34645	gensupport.SetOptions(c.urlParams_, opts...)
34646	res, err := c.doRequest("json")
34647	if res != nil && res.StatusCode == http.StatusNotModified {
34648		if res.Body != nil {
34649			res.Body.Close()
34650		}
34651		return nil, &googleapi.Error{
34652			Code:   res.StatusCode,
34653			Header: res.Header,
34654		}
34655	}
34656	if err != nil {
34657		return nil, err
34658	}
34659	defer googleapi.CloseBody(res)
34660	if err := googleapi.CheckResponse(res); err != nil {
34661		return nil, err
34662	}
34663	ret := &FloodlightActivityGroup{
34664		ServerResponse: googleapi.ServerResponse{
34665			Header:         res.Header,
34666			HTTPStatusCode: res.StatusCode,
34667		},
34668	}
34669	target := &ret
34670	if err := gensupport.DecodeResponse(target, res); err != nil {
34671		return nil, err
34672	}
34673	return ret, nil
34674	// {
34675	//   "description": "Inserts a new floodlight activity group.",
34676	//   "flatPath": "userprofiles/{profileId}/floodlightActivityGroups",
34677	//   "httpMethod": "POST",
34678	//   "id": "dfareporting.floodlightActivityGroups.insert",
34679	//   "parameterOrder": [
34680	//     "profileId"
34681	//   ],
34682	//   "parameters": {
34683	//     "profileId": {
34684	//       "description": "User profile ID associated with this request.",
34685	//       "format": "int64",
34686	//       "location": "path",
34687	//       "required": true,
34688	//       "type": "string"
34689	//     }
34690	//   },
34691	//   "path": "userprofiles/{profileId}/floodlightActivityGroups",
34692	//   "request": {
34693	//     "$ref": "FloodlightActivityGroup"
34694	//   },
34695	//   "response": {
34696	//     "$ref": "FloodlightActivityGroup"
34697	//   },
34698	//   "scopes": [
34699	//     "https://www.googleapis.com/auth/dfatrafficking"
34700	//   ]
34701	// }
34702
34703}
34704
34705// method id "dfareporting.floodlightActivityGroups.list":
34706
34707type FloodlightActivityGroupsListCall struct {
34708	s            *Service
34709	profileId    int64
34710	urlParams_   gensupport.URLParams
34711	ifNoneMatch_ string
34712	ctx_         context.Context
34713	header_      http.Header
34714}
34715
34716// List: Retrieves a list of floodlight activity groups, possibly
34717// filtered. This method supports paging.
34718//
34719// - profileId: User profile ID associated with this request.
34720func (r *FloodlightActivityGroupsService) List(profileId int64) *FloodlightActivityGroupsListCall {
34721	c := &FloodlightActivityGroupsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
34722	c.profileId = profileId
34723	return c
34724}
34725
34726// AdvertiserId sets the optional parameter "advertiserId": Select only
34727// floodlight activity groups with the specified advertiser ID. Must
34728// specify either advertiserId or floodlightConfigurationId for a
34729// non-empty result.
34730func (c *FloodlightActivityGroupsListCall) AdvertiserId(advertiserId int64) *FloodlightActivityGroupsListCall {
34731	c.urlParams_.Set("advertiserId", fmt.Sprint(advertiserId))
34732	return c
34733}
34734
34735// FloodlightConfigurationId sets the optional parameter
34736// "floodlightConfigurationId": Select only floodlight activity groups
34737// with the specified floodlight configuration ID. Must specify either
34738// advertiserId, or floodlightConfigurationId for a non-empty result.
34739func (c *FloodlightActivityGroupsListCall) FloodlightConfigurationId(floodlightConfigurationId int64) *FloodlightActivityGroupsListCall {
34740	c.urlParams_.Set("floodlightConfigurationId", fmt.Sprint(floodlightConfigurationId))
34741	return c
34742}
34743
34744// Ids sets the optional parameter "ids": Select only floodlight
34745// activity groups with the specified IDs. Must specify either
34746// advertiserId or floodlightConfigurationId for a non-empty result.
34747func (c *FloodlightActivityGroupsListCall) Ids(ids ...int64) *FloodlightActivityGroupsListCall {
34748	var ids_ []string
34749	for _, v := range ids {
34750		ids_ = append(ids_, fmt.Sprint(v))
34751	}
34752	c.urlParams_.SetMulti("ids", ids_)
34753	return c
34754}
34755
34756// MaxResults sets the optional parameter "maxResults": Maximum number
34757// of results to return.
34758func (c *FloodlightActivityGroupsListCall) MaxResults(maxResults int64) *FloodlightActivityGroupsListCall {
34759	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
34760	return c
34761}
34762
34763// PageToken sets the optional parameter "pageToken": Value of the
34764// nextPageToken from the previous result page.
34765func (c *FloodlightActivityGroupsListCall) PageToken(pageToken string) *FloodlightActivityGroupsListCall {
34766	c.urlParams_.Set("pageToken", pageToken)
34767	return c
34768}
34769
34770// SearchString sets the optional parameter "searchString": Allows
34771// searching for objects by name or ID. Wildcards (*) are allowed. For
34772// example, "floodlightactivitygroup*2015" will return objects with
34773// names like "floodlightactivitygroup June 2015",
34774// "floodlightactivitygroup April 2015", or simply
34775// "floodlightactivitygroup 2015". Most of the searches also add
34776// wildcards implicitly at the start and the end of the search string.
34777// For example, a search string of "floodlightactivitygroup" will match
34778// objects with name "my floodlightactivitygroup activity",
34779// "floodlightactivitygroup 2015", or simply "floodlightactivitygroup".
34780func (c *FloodlightActivityGroupsListCall) SearchString(searchString string) *FloodlightActivityGroupsListCall {
34781	c.urlParams_.Set("searchString", searchString)
34782	return c
34783}
34784
34785// SortField sets the optional parameter "sortField": Field by which to
34786// sort the list.
34787//
34788// Possible values:
34789//   "ID" (default)
34790//   "NAME"
34791func (c *FloodlightActivityGroupsListCall) SortField(sortField string) *FloodlightActivityGroupsListCall {
34792	c.urlParams_.Set("sortField", sortField)
34793	return c
34794}
34795
34796// SortOrder sets the optional parameter "sortOrder": Order of sorted
34797// results.
34798//
34799// Possible values:
34800//   "ASCENDING" (default)
34801//   "DESCENDING"
34802func (c *FloodlightActivityGroupsListCall) SortOrder(sortOrder string) *FloodlightActivityGroupsListCall {
34803	c.urlParams_.Set("sortOrder", sortOrder)
34804	return c
34805}
34806
34807// Type sets the optional parameter "type": Select only floodlight
34808// activity groups with the specified floodlight activity group type.
34809//
34810// Possible values:
34811//   "COUNTER"
34812//   "SALE"
34813func (c *FloodlightActivityGroupsListCall) Type(type_ string) *FloodlightActivityGroupsListCall {
34814	c.urlParams_.Set("type", type_)
34815	return c
34816}
34817
34818// Fields allows partial responses to be retrieved. See
34819// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
34820// for more information.
34821func (c *FloodlightActivityGroupsListCall) Fields(s ...googleapi.Field) *FloodlightActivityGroupsListCall {
34822	c.urlParams_.Set("fields", googleapi.CombineFields(s))
34823	return c
34824}
34825
34826// IfNoneMatch sets the optional parameter which makes the operation
34827// fail if the object's ETag matches the given value. This is useful for
34828// getting updates only after the object has changed since the last
34829// request. Use googleapi.IsNotModified to check whether the response
34830// error from Do is the result of In-None-Match.
34831func (c *FloodlightActivityGroupsListCall) IfNoneMatch(entityTag string) *FloodlightActivityGroupsListCall {
34832	c.ifNoneMatch_ = entityTag
34833	return c
34834}
34835
34836// Context sets the context to be used in this call's Do method. Any
34837// pending HTTP request will be aborted if the provided context is
34838// canceled.
34839func (c *FloodlightActivityGroupsListCall) Context(ctx context.Context) *FloodlightActivityGroupsListCall {
34840	c.ctx_ = ctx
34841	return c
34842}
34843
34844// Header returns an http.Header that can be modified by the caller to
34845// add HTTP headers to the request.
34846func (c *FloodlightActivityGroupsListCall) Header() http.Header {
34847	if c.header_ == nil {
34848		c.header_ = make(http.Header)
34849	}
34850	return c.header_
34851}
34852
34853func (c *FloodlightActivityGroupsListCall) doRequest(alt string) (*http.Response, error) {
34854	reqHeaders := make(http.Header)
34855	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
34856	for k, v := range c.header_ {
34857		reqHeaders[k] = v
34858	}
34859	reqHeaders.Set("User-Agent", c.s.userAgent())
34860	if c.ifNoneMatch_ != "" {
34861		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
34862	}
34863	var body io.Reader = nil
34864	c.urlParams_.Set("alt", alt)
34865	c.urlParams_.Set("prettyPrint", "false")
34866	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/floodlightActivityGroups")
34867	urls += "?" + c.urlParams_.Encode()
34868	req, err := http.NewRequest("GET", urls, body)
34869	if err != nil {
34870		return nil, err
34871	}
34872	req.Header = reqHeaders
34873	googleapi.Expand(req.URL, map[string]string{
34874		"profileId": strconv.FormatInt(c.profileId, 10),
34875	})
34876	return gensupport.SendRequest(c.ctx_, c.s.client, req)
34877}
34878
34879// Do executes the "dfareporting.floodlightActivityGroups.list" call.
34880// Exactly one of *FloodlightActivityGroupsListResponse or error will be
34881// non-nil. Any non-2xx status code is an error. Response headers are in
34882// either *FloodlightActivityGroupsListResponse.ServerResponse.Header or
34883// (if a response was returned at all) in
34884// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
34885// whether the returned error was because http.StatusNotModified was
34886// returned.
34887func (c *FloodlightActivityGroupsListCall) Do(opts ...googleapi.CallOption) (*FloodlightActivityGroupsListResponse, error) {
34888	gensupport.SetOptions(c.urlParams_, opts...)
34889	res, err := c.doRequest("json")
34890	if res != nil && res.StatusCode == http.StatusNotModified {
34891		if res.Body != nil {
34892			res.Body.Close()
34893		}
34894		return nil, &googleapi.Error{
34895			Code:   res.StatusCode,
34896			Header: res.Header,
34897		}
34898	}
34899	if err != nil {
34900		return nil, err
34901	}
34902	defer googleapi.CloseBody(res)
34903	if err := googleapi.CheckResponse(res); err != nil {
34904		return nil, err
34905	}
34906	ret := &FloodlightActivityGroupsListResponse{
34907		ServerResponse: googleapi.ServerResponse{
34908			Header:         res.Header,
34909			HTTPStatusCode: res.StatusCode,
34910		},
34911	}
34912	target := &ret
34913	if err := gensupport.DecodeResponse(target, res); err != nil {
34914		return nil, err
34915	}
34916	return ret, nil
34917	// {
34918	//   "description": "Retrieves a list of floodlight activity groups, possibly filtered. This method supports paging.",
34919	//   "flatPath": "userprofiles/{profileId}/floodlightActivityGroups",
34920	//   "httpMethod": "GET",
34921	//   "id": "dfareporting.floodlightActivityGroups.list",
34922	//   "parameterOrder": [
34923	//     "profileId"
34924	//   ],
34925	//   "parameters": {
34926	//     "advertiserId": {
34927	//       "description": "Select only floodlight activity groups with the specified advertiser ID. Must specify either advertiserId or floodlightConfigurationId for a non-empty result.",
34928	//       "format": "int64",
34929	//       "location": "query",
34930	//       "type": "string"
34931	//     },
34932	//     "floodlightConfigurationId": {
34933	//       "description": "Select only floodlight activity groups with the specified floodlight configuration ID. Must specify either advertiserId, or floodlightConfigurationId for a non-empty result.",
34934	//       "format": "int64",
34935	//       "location": "query",
34936	//       "type": "string"
34937	//     },
34938	//     "ids": {
34939	//       "description": "Select only floodlight activity groups with the specified IDs. Must specify either advertiserId or floodlightConfigurationId for a non-empty result.",
34940	//       "format": "int64",
34941	//       "location": "query",
34942	//       "repeated": true,
34943	//       "type": "string"
34944	//     },
34945	//     "maxResults": {
34946	//       "default": "1000",
34947	//       "description": "Maximum number of results to return.",
34948	//       "format": "int32",
34949	//       "location": "query",
34950	//       "maximum": "1000",
34951	//       "minimum": "0",
34952	//       "type": "integer"
34953	//     },
34954	//     "pageToken": {
34955	//       "description": "Value of the nextPageToken from the previous result page.",
34956	//       "location": "query",
34957	//       "type": "string"
34958	//     },
34959	//     "profileId": {
34960	//       "description": "User profile ID associated with this request.",
34961	//       "format": "int64",
34962	//       "location": "path",
34963	//       "required": true,
34964	//       "type": "string"
34965	//     },
34966	//     "searchString": {
34967	//       "description": "Allows searching for objects by name or ID. Wildcards (*) are allowed. For example, \"floodlightactivitygroup*2015\" will return objects with names like \"floodlightactivitygroup June 2015\", \"floodlightactivitygroup April 2015\", or simply \"floodlightactivitygroup 2015\". Most of the searches also add wildcards implicitly at the start and the end of the search string. For example, a search string of \"floodlightactivitygroup\" will match objects with name \"my floodlightactivitygroup activity\", \"floodlightactivitygroup 2015\", or simply \"floodlightactivitygroup\".",
34968	//       "location": "query",
34969	//       "type": "string"
34970	//     },
34971	//     "sortField": {
34972	//       "default": "ID",
34973	//       "description": "Field by which to sort the list.",
34974	//       "enum": [
34975	//         "ID",
34976	//         "NAME"
34977	//       ],
34978	//       "enumDescriptions": [
34979	//         "",
34980	//         ""
34981	//       ],
34982	//       "location": "query",
34983	//       "type": "string"
34984	//     },
34985	//     "sortOrder": {
34986	//       "default": "ASCENDING",
34987	//       "description": "Order of sorted results.",
34988	//       "enum": [
34989	//         "ASCENDING",
34990	//         "DESCENDING"
34991	//       ],
34992	//       "enumDescriptions": [
34993	//         "",
34994	//         ""
34995	//       ],
34996	//       "location": "query",
34997	//       "type": "string"
34998	//     },
34999	//     "type": {
35000	//       "description": "Select only floodlight activity groups with the specified floodlight activity group type.",
35001	//       "enum": [
35002	//         "COUNTER",
35003	//         "SALE"
35004	//       ],
35005	//       "enumDescriptions": [
35006	//         "",
35007	//         ""
35008	//       ],
35009	//       "location": "query",
35010	//       "type": "string"
35011	//     }
35012	//   },
35013	//   "path": "userprofiles/{profileId}/floodlightActivityGroups",
35014	//   "response": {
35015	//     "$ref": "FloodlightActivityGroupsListResponse"
35016	//   },
35017	//   "scopes": [
35018	//     "https://www.googleapis.com/auth/dfatrafficking"
35019	//   ]
35020	// }
35021
35022}
35023
35024// Pages invokes f for each page of results.
35025// A non-nil error returned from f will halt the iteration.
35026// The provided context supersedes any context provided to the Context method.
35027func (c *FloodlightActivityGroupsListCall) Pages(ctx context.Context, f func(*FloodlightActivityGroupsListResponse) error) error {
35028	c.ctx_ = ctx
35029	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
35030	for {
35031		x, err := c.Do()
35032		if err != nil {
35033			return err
35034		}
35035		if err := f(x); err != nil {
35036			return err
35037		}
35038		if x.NextPageToken == "" {
35039			return nil
35040		}
35041		c.PageToken(x.NextPageToken)
35042	}
35043}
35044
35045// method id "dfareporting.floodlightActivityGroups.patch":
35046
35047type FloodlightActivityGroupsPatchCall struct {
35048	s                       *Service
35049	profileId               int64
35050	floodlightactivitygroup *FloodlightActivityGroup
35051	urlParams_              gensupport.URLParams
35052	ctx_                    context.Context
35053	header_                 http.Header
35054}
35055
35056// Patch: Updates an existing floodlight activity group. This method
35057// supports patch semantics.
35058//
35059// - id: FloodlightActivityGroup ID.
35060// - profileId: User profile ID associated with this request.
35061func (r *FloodlightActivityGroupsService) Patch(profileId int64, id int64, floodlightactivitygroup *FloodlightActivityGroup) *FloodlightActivityGroupsPatchCall {
35062	c := &FloodlightActivityGroupsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
35063	c.profileId = profileId
35064	c.urlParams_.Set("id", fmt.Sprint(id))
35065	c.floodlightactivitygroup = floodlightactivitygroup
35066	return c
35067}
35068
35069// Fields allows partial responses to be retrieved. See
35070// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
35071// for more information.
35072func (c *FloodlightActivityGroupsPatchCall) Fields(s ...googleapi.Field) *FloodlightActivityGroupsPatchCall {
35073	c.urlParams_.Set("fields", googleapi.CombineFields(s))
35074	return c
35075}
35076
35077// Context sets the context to be used in this call's Do method. Any
35078// pending HTTP request will be aborted if the provided context is
35079// canceled.
35080func (c *FloodlightActivityGroupsPatchCall) Context(ctx context.Context) *FloodlightActivityGroupsPatchCall {
35081	c.ctx_ = ctx
35082	return c
35083}
35084
35085// Header returns an http.Header that can be modified by the caller to
35086// add HTTP headers to the request.
35087func (c *FloodlightActivityGroupsPatchCall) Header() http.Header {
35088	if c.header_ == nil {
35089		c.header_ = make(http.Header)
35090	}
35091	return c.header_
35092}
35093
35094func (c *FloodlightActivityGroupsPatchCall) doRequest(alt string) (*http.Response, error) {
35095	reqHeaders := make(http.Header)
35096	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
35097	for k, v := range c.header_ {
35098		reqHeaders[k] = v
35099	}
35100	reqHeaders.Set("User-Agent", c.s.userAgent())
35101	var body io.Reader = nil
35102	body, err := googleapi.WithoutDataWrapper.JSONReader(c.floodlightactivitygroup)
35103	if err != nil {
35104		return nil, err
35105	}
35106	reqHeaders.Set("Content-Type", "application/json")
35107	c.urlParams_.Set("alt", alt)
35108	c.urlParams_.Set("prettyPrint", "false")
35109	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/floodlightActivityGroups")
35110	urls += "?" + c.urlParams_.Encode()
35111	req, err := http.NewRequest("PATCH", urls, body)
35112	if err != nil {
35113		return nil, err
35114	}
35115	req.Header = reqHeaders
35116	googleapi.Expand(req.URL, map[string]string{
35117		"profileId": strconv.FormatInt(c.profileId, 10),
35118	})
35119	return gensupport.SendRequest(c.ctx_, c.s.client, req)
35120}
35121
35122// Do executes the "dfareporting.floodlightActivityGroups.patch" call.
35123// Exactly one of *FloodlightActivityGroup or error will be non-nil. Any
35124// non-2xx status code is an error. Response headers are in either
35125// *FloodlightActivityGroup.ServerResponse.Header or (if a response was
35126// returned at all) in error.(*googleapi.Error).Header. Use
35127// googleapi.IsNotModified to check whether the returned error was
35128// because http.StatusNotModified was returned.
35129func (c *FloodlightActivityGroupsPatchCall) Do(opts ...googleapi.CallOption) (*FloodlightActivityGroup, error) {
35130	gensupport.SetOptions(c.urlParams_, opts...)
35131	res, err := c.doRequest("json")
35132	if res != nil && res.StatusCode == http.StatusNotModified {
35133		if res.Body != nil {
35134			res.Body.Close()
35135		}
35136		return nil, &googleapi.Error{
35137			Code:   res.StatusCode,
35138			Header: res.Header,
35139		}
35140	}
35141	if err != nil {
35142		return nil, err
35143	}
35144	defer googleapi.CloseBody(res)
35145	if err := googleapi.CheckResponse(res); err != nil {
35146		return nil, err
35147	}
35148	ret := &FloodlightActivityGroup{
35149		ServerResponse: googleapi.ServerResponse{
35150			Header:         res.Header,
35151			HTTPStatusCode: res.StatusCode,
35152		},
35153	}
35154	target := &ret
35155	if err := gensupport.DecodeResponse(target, res); err != nil {
35156		return nil, err
35157	}
35158	return ret, nil
35159	// {
35160	//   "description": "Updates an existing floodlight activity group. This method supports patch semantics.",
35161	//   "flatPath": "userprofiles/{profileId}/floodlightActivityGroups",
35162	//   "httpMethod": "PATCH",
35163	//   "id": "dfareporting.floodlightActivityGroups.patch",
35164	//   "parameterOrder": [
35165	//     "profileId",
35166	//     "id"
35167	//   ],
35168	//   "parameters": {
35169	//     "id": {
35170	//       "description": "FloodlightActivityGroup ID.",
35171	//       "format": "int64",
35172	//       "location": "query",
35173	//       "required": true,
35174	//       "type": "string"
35175	//     },
35176	//     "profileId": {
35177	//       "description": "User profile ID associated with this request.",
35178	//       "format": "int64",
35179	//       "location": "path",
35180	//       "required": true,
35181	//       "type": "string"
35182	//     }
35183	//   },
35184	//   "path": "userprofiles/{profileId}/floodlightActivityGroups",
35185	//   "request": {
35186	//     "$ref": "FloodlightActivityGroup"
35187	//   },
35188	//   "response": {
35189	//     "$ref": "FloodlightActivityGroup"
35190	//   },
35191	//   "scopes": [
35192	//     "https://www.googleapis.com/auth/dfatrafficking"
35193	//   ]
35194	// }
35195
35196}
35197
35198// method id "dfareporting.floodlightActivityGroups.update":
35199
35200type FloodlightActivityGroupsUpdateCall struct {
35201	s                       *Service
35202	profileId               int64
35203	floodlightactivitygroup *FloodlightActivityGroup
35204	urlParams_              gensupport.URLParams
35205	ctx_                    context.Context
35206	header_                 http.Header
35207}
35208
35209// Update: Updates an existing floodlight activity group.
35210//
35211// - profileId: User profile ID associated with this request.
35212func (r *FloodlightActivityGroupsService) Update(profileId int64, floodlightactivitygroup *FloodlightActivityGroup) *FloodlightActivityGroupsUpdateCall {
35213	c := &FloodlightActivityGroupsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
35214	c.profileId = profileId
35215	c.floodlightactivitygroup = floodlightactivitygroup
35216	return c
35217}
35218
35219// Fields allows partial responses to be retrieved. See
35220// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
35221// for more information.
35222func (c *FloodlightActivityGroupsUpdateCall) Fields(s ...googleapi.Field) *FloodlightActivityGroupsUpdateCall {
35223	c.urlParams_.Set("fields", googleapi.CombineFields(s))
35224	return c
35225}
35226
35227// Context sets the context to be used in this call's Do method. Any
35228// pending HTTP request will be aborted if the provided context is
35229// canceled.
35230func (c *FloodlightActivityGroupsUpdateCall) Context(ctx context.Context) *FloodlightActivityGroupsUpdateCall {
35231	c.ctx_ = ctx
35232	return c
35233}
35234
35235// Header returns an http.Header that can be modified by the caller to
35236// add HTTP headers to the request.
35237func (c *FloodlightActivityGroupsUpdateCall) Header() http.Header {
35238	if c.header_ == nil {
35239		c.header_ = make(http.Header)
35240	}
35241	return c.header_
35242}
35243
35244func (c *FloodlightActivityGroupsUpdateCall) doRequest(alt string) (*http.Response, error) {
35245	reqHeaders := make(http.Header)
35246	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
35247	for k, v := range c.header_ {
35248		reqHeaders[k] = v
35249	}
35250	reqHeaders.Set("User-Agent", c.s.userAgent())
35251	var body io.Reader = nil
35252	body, err := googleapi.WithoutDataWrapper.JSONReader(c.floodlightactivitygroup)
35253	if err != nil {
35254		return nil, err
35255	}
35256	reqHeaders.Set("Content-Type", "application/json")
35257	c.urlParams_.Set("alt", alt)
35258	c.urlParams_.Set("prettyPrint", "false")
35259	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/floodlightActivityGroups")
35260	urls += "?" + c.urlParams_.Encode()
35261	req, err := http.NewRequest("PUT", urls, body)
35262	if err != nil {
35263		return nil, err
35264	}
35265	req.Header = reqHeaders
35266	googleapi.Expand(req.URL, map[string]string{
35267		"profileId": strconv.FormatInt(c.profileId, 10),
35268	})
35269	return gensupport.SendRequest(c.ctx_, c.s.client, req)
35270}
35271
35272// Do executes the "dfareporting.floodlightActivityGroups.update" call.
35273// Exactly one of *FloodlightActivityGroup or error will be non-nil. Any
35274// non-2xx status code is an error. Response headers are in either
35275// *FloodlightActivityGroup.ServerResponse.Header or (if a response was
35276// returned at all) in error.(*googleapi.Error).Header. Use
35277// googleapi.IsNotModified to check whether the returned error was
35278// because http.StatusNotModified was returned.
35279func (c *FloodlightActivityGroupsUpdateCall) Do(opts ...googleapi.CallOption) (*FloodlightActivityGroup, 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 := &FloodlightActivityGroup{
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	//   "description": "Updates an existing floodlight activity group.",
35311	//   "flatPath": "userprofiles/{profileId}/floodlightActivityGroups",
35312	//   "httpMethod": "PUT",
35313	//   "id": "dfareporting.floodlightActivityGroups.update",
35314	//   "parameterOrder": [
35315	//     "profileId"
35316	//   ],
35317	//   "parameters": {
35318	//     "profileId": {
35319	//       "description": "User profile ID associated with this request.",
35320	//       "format": "int64",
35321	//       "location": "path",
35322	//       "required": true,
35323	//       "type": "string"
35324	//     }
35325	//   },
35326	//   "path": "userprofiles/{profileId}/floodlightActivityGroups",
35327	//   "request": {
35328	//     "$ref": "FloodlightActivityGroup"
35329	//   },
35330	//   "response": {
35331	//     "$ref": "FloodlightActivityGroup"
35332	//   },
35333	//   "scopes": [
35334	//     "https://www.googleapis.com/auth/dfatrafficking"
35335	//   ]
35336	// }
35337
35338}
35339
35340// method id "dfareporting.floodlightConfigurations.get":
35341
35342type FloodlightConfigurationsGetCall struct {
35343	s            *Service
35344	profileId    int64
35345	id           int64
35346	urlParams_   gensupport.URLParams
35347	ifNoneMatch_ string
35348	ctx_         context.Context
35349	header_      http.Header
35350}
35351
35352// Get: Gets one floodlight configuration by ID.
35353//
35354// - id: Floodlight configuration ID.
35355// - profileId: User profile ID associated with this request.
35356func (r *FloodlightConfigurationsService) Get(profileId int64, id int64) *FloodlightConfigurationsGetCall {
35357	c := &FloodlightConfigurationsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
35358	c.profileId = profileId
35359	c.id = id
35360	return c
35361}
35362
35363// Fields allows partial responses to be retrieved. See
35364// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
35365// for more information.
35366func (c *FloodlightConfigurationsGetCall) Fields(s ...googleapi.Field) *FloodlightConfigurationsGetCall {
35367	c.urlParams_.Set("fields", googleapi.CombineFields(s))
35368	return c
35369}
35370
35371// IfNoneMatch sets the optional parameter which makes the operation
35372// fail if the object's ETag matches the given value. This is useful for
35373// getting updates only after the object has changed since the last
35374// request. Use googleapi.IsNotModified to check whether the response
35375// error from Do is the result of In-None-Match.
35376func (c *FloodlightConfigurationsGetCall) IfNoneMatch(entityTag string) *FloodlightConfigurationsGetCall {
35377	c.ifNoneMatch_ = entityTag
35378	return c
35379}
35380
35381// Context sets the context to be used in this call's Do method. Any
35382// pending HTTP request will be aborted if the provided context is
35383// canceled.
35384func (c *FloodlightConfigurationsGetCall) Context(ctx context.Context) *FloodlightConfigurationsGetCall {
35385	c.ctx_ = ctx
35386	return c
35387}
35388
35389// Header returns an http.Header that can be modified by the caller to
35390// add HTTP headers to the request.
35391func (c *FloodlightConfigurationsGetCall) Header() http.Header {
35392	if c.header_ == nil {
35393		c.header_ = make(http.Header)
35394	}
35395	return c.header_
35396}
35397
35398func (c *FloodlightConfigurationsGetCall) doRequest(alt string) (*http.Response, error) {
35399	reqHeaders := make(http.Header)
35400	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
35401	for k, v := range c.header_ {
35402		reqHeaders[k] = v
35403	}
35404	reqHeaders.Set("User-Agent", c.s.userAgent())
35405	if c.ifNoneMatch_ != "" {
35406		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
35407	}
35408	var body io.Reader = nil
35409	c.urlParams_.Set("alt", alt)
35410	c.urlParams_.Set("prettyPrint", "false")
35411	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/floodlightConfigurations/{id}")
35412	urls += "?" + c.urlParams_.Encode()
35413	req, err := http.NewRequest("GET", urls, body)
35414	if err != nil {
35415		return nil, err
35416	}
35417	req.Header = reqHeaders
35418	googleapi.Expand(req.URL, map[string]string{
35419		"profileId": strconv.FormatInt(c.profileId, 10),
35420		"id":        strconv.FormatInt(c.id, 10),
35421	})
35422	return gensupport.SendRequest(c.ctx_, c.s.client, req)
35423}
35424
35425// Do executes the "dfareporting.floodlightConfigurations.get" call.
35426// Exactly one of *FloodlightConfiguration or error will be non-nil. Any
35427// non-2xx status code is an error. Response headers are in either
35428// *FloodlightConfiguration.ServerResponse.Header or (if a response was
35429// returned at all) in error.(*googleapi.Error).Header. Use
35430// googleapi.IsNotModified to check whether the returned error was
35431// because http.StatusNotModified was returned.
35432func (c *FloodlightConfigurationsGetCall) Do(opts ...googleapi.CallOption) (*FloodlightConfiguration, error) {
35433	gensupport.SetOptions(c.urlParams_, opts...)
35434	res, err := c.doRequest("json")
35435	if res != nil && res.StatusCode == http.StatusNotModified {
35436		if res.Body != nil {
35437			res.Body.Close()
35438		}
35439		return nil, &googleapi.Error{
35440			Code:   res.StatusCode,
35441			Header: res.Header,
35442		}
35443	}
35444	if err != nil {
35445		return nil, err
35446	}
35447	defer googleapi.CloseBody(res)
35448	if err := googleapi.CheckResponse(res); err != nil {
35449		return nil, err
35450	}
35451	ret := &FloodlightConfiguration{
35452		ServerResponse: googleapi.ServerResponse{
35453			Header:         res.Header,
35454			HTTPStatusCode: res.StatusCode,
35455		},
35456	}
35457	target := &ret
35458	if err := gensupport.DecodeResponse(target, res); err != nil {
35459		return nil, err
35460	}
35461	return ret, nil
35462	// {
35463	//   "description": "Gets one floodlight configuration by ID.",
35464	//   "flatPath": "userprofiles/{profileId}/floodlightConfigurations/{id}",
35465	//   "httpMethod": "GET",
35466	//   "id": "dfareporting.floodlightConfigurations.get",
35467	//   "parameterOrder": [
35468	//     "profileId",
35469	//     "id"
35470	//   ],
35471	//   "parameters": {
35472	//     "id": {
35473	//       "description": "Floodlight configuration ID.",
35474	//       "format": "int64",
35475	//       "location": "path",
35476	//       "required": true,
35477	//       "type": "string"
35478	//     },
35479	//     "profileId": {
35480	//       "description": "User profile ID associated with this request.",
35481	//       "format": "int64",
35482	//       "location": "path",
35483	//       "required": true,
35484	//       "type": "string"
35485	//     }
35486	//   },
35487	//   "path": "userprofiles/{profileId}/floodlightConfigurations/{id}",
35488	//   "response": {
35489	//     "$ref": "FloodlightConfiguration"
35490	//   },
35491	//   "scopes": [
35492	//     "https://www.googleapis.com/auth/dfatrafficking"
35493	//   ]
35494	// }
35495
35496}
35497
35498// method id "dfareporting.floodlightConfigurations.list":
35499
35500type FloodlightConfigurationsListCall struct {
35501	s            *Service
35502	profileId    int64
35503	urlParams_   gensupport.URLParams
35504	ifNoneMatch_ string
35505	ctx_         context.Context
35506	header_      http.Header
35507}
35508
35509// List: Retrieves a list of floodlight configurations, possibly
35510// filtered.
35511//
35512// - profileId: User profile ID associated with this request.
35513func (r *FloodlightConfigurationsService) List(profileId int64) *FloodlightConfigurationsListCall {
35514	c := &FloodlightConfigurationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
35515	c.profileId = profileId
35516	return c
35517}
35518
35519// Ids sets the optional parameter "ids": Set of IDs of floodlight
35520// configurations to retrieve. Required field; otherwise an empty list
35521// will be returned.
35522func (c *FloodlightConfigurationsListCall) Ids(ids ...int64) *FloodlightConfigurationsListCall {
35523	var ids_ []string
35524	for _, v := range ids {
35525		ids_ = append(ids_, fmt.Sprint(v))
35526	}
35527	c.urlParams_.SetMulti("ids", ids_)
35528	return c
35529}
35530
35531// Fields allows partial responses to be retrieved. See
35532// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
35533// for more information.
35534func (c *FloodlightConfigurationsListCall) Fields(s ...googleapi.Field) *FloodlightConfigurationsListCall {
35535	c.urlParams_.Set("fields", googleapi.CombineFields(s))
35536	return c
35537}
35538
35539// IfNoneMatch sets the optional parameter which makes the operation
35540// fail if the object's ETag matches the given value. This is useful for
35541// getting updates only after the object has changed since the last
35542// request. Use googleapi.IsNotModified to check whether the response
35543// error from Do is the result of In-None-Match.
35544func (c *FloodlightConfigurationsListCall) IfNoneMatch(entityTag string) *FloodlightConfigurationsListCall {
35545	c.ifNoneMatch_ = entityTag
35546	return c
35547}
35548
35549// Context sets the context to be used in this call's Do method. Any
35550// pending HTTP request will be aborted if the provided context is
35551// canceled.
35552func (c *FloodlightConfigurationsListCall) Context(ctx context.Context) *FloodlightConfigurationsListCall {
35553	c.ctx_ = ctx
35554	return c
35555}
35556
35557// Header returns an http.Header that can be modified by the caller to
35558// add HTTP headers to the request.
35559func (c *FloodlightConfigurationsListCall) Header() http.Header {
35560	if c.header_ == nil {
35561		c.header_ = make(http.Header)
35562	}
35563	return c.header_
35564}
35565
35566func (c *FloodlightConfigurationsListCall) doRequest(alt string) (*http.Response, error) {
35567	reqHeaders := make(http.Header)
35568	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
35569	for k, v := range c.header_ {
35570		reqHeaders[k] = v
35571	}
35572	reqHeaders.Set("User-Agent", c.s.userAgent())
35573	if c.ifNoneMatch_ != "" {
35574		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
35575	}
35576	var body io.Reader = nil
35577	c.urlParams_.Set("alt", alt)
35578	c.urlParams_.Set("prettyPrint", "false")
35579	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/floodlightConfigurations")
35580	urls += "?" + c.urlParams_.Encode()
35581	req, err := http.NewRequest("GET", urls, body)
35582	if err != nil {
35583		return nil, err
35584	}
35585	req.Header = reqHeaders
35586	googleapi.Expand(req.URL, map[string]string{
35587		"profileId": strconv.FormatInt(c.profileId, 10),
35588	})
35589	return gensupport.SendRequest(c.ctx_, c.s.client, req)
35590}
35591
35592// Do executes the "dfareporting.floodlightConfigurations.list" call.
35593// Exactly one of *FloodlightConfigurationsListResponse or error will be
35594// non-nil. Any non-2xx status code is an error. Response headers are in
35595// either *FloodlightConfigurationsListResponse.ServerResponse.Header or
35596// (if a response was returned at all) in
35597// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
35598// whether the returned error was because http.StatusNotModified was
35599// returned.
35600func (c *FloodlightConfigurationsListCall) Do(opts ...googleapi.CallOption) (*FloodlightConfigurationsListResponse, error) {
35601	gensupport.SetOptions(c.urlParams_, opts...)
35602	res, err := c.doRequest("json")
35603	if res != nil && res.StatusCode == http.StatusNotModified {
35604		if res.Body != nil {
35605			res.Body.Close()
35606		}
35607		return nil, &googleapi.Error{
35608			Code:   res.StatusCode,
35609			Header: res.Header,
35610		}
35611	}
35612	if err != nil {
35613		return nil, err
35614	}
35615	defer googleapi.CloseBody(res)
35616	if err := googleapi.CheckResponse(res); err != nil {
35617		return nil, err
35618	}
35619	ret := &FloodlightConfigurationsListResponse{
35620		ServerResponse: googleapi.ServerResponse{
35621			Header:         res.Header,
35622			HTTPStatusCode: res.StatusCode,
35623		},
35624	}
35625	target := &ret
35626	if err := gensupport.DecodeResponse(target, res); err != nil {
35627		return nil, err
35628	}
35629	return ret, nil
35630	// {
35631	//   "description": "Retrieves a list of floodlight configurations, possibly filtered.",
35632	//   "flatPath": "userprofiles/{profileId}/floodlightConfigurations",
35633	//   "httpMethod": "GET",
35634	//   "id": "dfareporting.floodlightConfigurations.list",
35635	//   "parameterOrder": [
35636	//     "profileId"
35637	//   ],
35638	//   "parameters": {
35639	//     "ids": {
35640	//       "description": "Set of IDs of floodlight configurations to retrieve. Required field; otherwise an empty list will be returned.",
35641	//       "format": "int64",
35642	//       "location": "query",
35643	//       "repeated": true,
35644	//       "type": "string"
35645	//     },
35646	//     "profileId": {
35647	//       "description": "User profile ID associated with this request.",
35648	//       "format": "int64",
35649	//       "location": "path",
35650	//       "required": true,
35651	//       "type": "string"
35652	//     }
35653	//   },
35654	//   "path": "userprofiles/{profileId}/floodlightConfigurations",
35655	//   "response": {
35656	//     "$ref": "FloodlightConfigurationsListResponse"
35657	//   },
35658	//   "scopes": [
35659	//     "https://www.googleapis.com/auth/dfatrafficking"
35660	//   ]
35661	// }
35662
35663}
35664
35665// method id "dfareporting.floodlightConfigurations.patch":
35666
35667type FloodlightConfigurationsPatchCall struct {
35668	s                       *Service
35669	profileId               int64
35670	floodlightconfiguration *FloodlightConfiguration
35671	urlParams_              gensupport.URLParams
35672	ctx_                    context.Context
35673	header_                 http.Header
35674}
35675
35676// Patch: Updates an existing floodlight configuration. This method
35677// supports patch semantics.
35678//
35679// - id: FloodlightConfiguration ID.
35680// - profileId: User profile ID associated with this request.
35681func (r *FloodlightConfigurationsService) Patch(profileId int64, id int64, floodlightconfiguration *FloodlightConfiguration) *FloodlightConfigurationsPatchCall {
35682	c := &FloodlightConfigurationsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
35683	c.profileId = profileId
35684	c.urlParams_.Set("id", fmt.Sprint(id))
35685	c.floodlightconfiguration = floodlightconfiguration
35686	return c
35687}
35688
35689// Fields allows partial responses to be retrieved. See
35690// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
35691// for more information.
35692func (c *FloodlightConfigurationsPatchCall) Fields(s ...googleapi.Field) *FloodlightConfigurationsPatchCall {
35693	c.urlParams_.Set("fields", googleapi.CombineFields(s))
35694	return c
35695}
35696
35697// Context sets the context to be used in this call's Do method. Any
35698// pending HTTP request will be aborted if the provided context is
35699// canceled.
35700func (c *FloodlightConfigurationsPatchCall) Context(ctx context.Context) *FloodlightConfigurationsPatchCall {
35701	c.ctx_ = ctx
35702	return c
35703}
35704
35705// Header returns an http.Header that can be modified by the caller to
35706// add HTTP headers to the request.
35707func (c *FloodlightConfigurationsPatchCall) Header() http.Header {
35708	if c.header_ == nil {
35709		c.header_ = make(http.Header)
35710	}
35711	return c.header_
35712}
35713
35714func (c *FloodlightConfigurationsPatchCall) doRequest(alt string) (*http.Response, error) {
35715	reqHeaders := make(http.Header)
35716	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
35717	for k, v := range c.header_ {
35718		reqHeaders[k] = v
35719	}
35720	reqHeaders.Set("User-Agent", c.s.userAgent())
35721	var body io.Reader = nil
35722	body, err := googleapi.WithoutDataWrapper.JSONReader(c.floodlightconfiguration)
35723	if err != nil {
35724		return nil, err
35725	}
35726	reqHeaders.Set("Content-Type", "application/json")
35727	c.urlParams_.Set("alt", alt)
35728	c.urlParams_.Set("prettyPrint", "false")
35729	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/floodlightConfigurations")
35730	urls += "?" + c.urlParams_.Encode()
35731	req, err := http.NewRequest("PATCH", urls, body)
35732	if err != nil {
35733		return nil, err
35734	}
35735	req.Header = reqHeaders
35736	googleapi.Expand(req.URL, map[string]string{
35737		"profileId": strconv.FormatInt(c.profileId, 10),
35738	})
35739	return gensupport.SendRequest(c.ctx_, c.s.client, req)
35740}
35741
35742// Do executes the "dfareporting.floodlightConfigurations.patch" call.
35743// Exactly one of *FloodlightConfiguration or error will be non-nil. Any
35744// non-2xx status code is an error. Response headers are in either
35745// *FloodlightConfiguration.ServerResponse.Header or (if a response was
35746// returned at all) in error.(*googleapi.Error).Header. Use
35747// googleapi.IsNotModified to check whether the returned error was
35748// because http.StatusNotModified was returned.
35749func (c *FloodlightConfigurationsPatchCall) Do(opts ...googleapi.CallOption) (*FloodlightConfiguration, error) {
35750	gensupport.SetOptions(c.urlParams_, opts...)
35751	res, err := c.doRequest("json")
35752	if res != nil && res.StatusCode == http.StatusNotModified {
35753		if res.Body != nil {
35754			res.Body.Close()
35755		}
35756		return nil, &googleapi.Error{
35757			Code:   res.StatusCode,
35758			Header: res.Header,
35759		}
35760	}
35761	if err != nil {
35762		return nil, err
35763	}
35764	defer googleapi.CloseBody(res)
35765	if err := googleapi.CheckResponse(res); err != nil {
35766		return nil, err
35767	}
35768	ret := &FloodlightConfiguration{
35769		ServerResponse: googleapi.ServerResponse{
35770			Header:         res.Header,
35771			HTTPStatusCode: res.StatusCode,
35772		},
35773	}
35774	target := &ret
35775	if err := gensupport.DecodeResponse(target, res); err != nil {
35776		return nil, err
35777	}
35778	return ret, nil
35779	// {
35780	//   "description": "Updates an existing floodlight configuration. This method supports patch semantics.",
35781	//   "flatPath": "userprofiles/{profileId}/floodlightConfigurations",
35782	//   "httpMethod": "PATCH",
35783	//   "id": "dfareporting.floodlightConfigurations.patch",
35784	//   "parameterOrder": [
35785	//     "profileId",
35786	//     "id"
35787	//   ],
35788	//   "parameters": {
35789	//     "id": {
35790	//       "description": "FloodlightConfiguration ID.",
35791	//       "format": "int64",
35792	//       "location": "query",
35793	//       "required": true,
35794	//       "type": "string"
35795	//     },
35796	//     "profileId": {
35797	//       "description": "User profile ID associated with this request.",
35798	//       "format": "int64",
35799	//       "location": "path",
35800	//       "required": true,
35801	//       "type": "string"
35802	//     }
35803	//   },
35804	//   "path": "userprofiles/{profileId}/floodlightConfigurations",
35805	//   "request": {
35806	//     "$ref": "FloodlightConfiguration"
35807	//   },
35808	//   "response": {
35809	//     "$ref": "FloodlightConfiguration"
35810	//   },
35811	//   "scopes": [
35812	//     "https://www.googleapis.com/auth/dfatrafficking"
35813	//   ]
35814	// }
35815
35816}
35817
35818// method id "dfareporting.floodlightConfigurations.update":
35819
35820type FloodlightConfigurationsUpdateCall struct {
35821	s                       *Service
35822	profileId               int64
35823	floodlightconfiguration *FloodlightConfiguration
35824	urlParams_              gensupport.URLParams
35825	ctx_                    context.Context
35826	header_                 http.Header
35827}
35828
35829// Update: Updates an existing floodlight configuration.
35830//
35831// - profileId: User profile ID associated with this request.
35832func (r *FloodlightConfigurationsService) Update(profileId int64, floodlightconfiguration *FloodlightConfiguration) *FloodlightConfigurationsUpdateCall {
35833	c := &FloodlightConfigurationsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
35834	c.profileId = profileId
35835	c.floodlightconfiguration = floodlightconfiguration
35836	return c
35837}
35838
35839// Fields allows partial responses to be retrieved. See
35840// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
35841// for more information.
35842func (c *FloodlightConfigurationsUpdateCall) Fields(s ...googleapi.Field) *FloodlightConfigurationsUpdateCall {
35843	c.urlParams_.Set("fields", googleapi.CombineFields(s))
35844	return c
35845}
35846
35847// Context sets the context to be used in this call's Do method. Any
35848// pending HTTP request will be aborted if the provided context is
35849// canceled.
35850func (c *FloodlightConfigurationsUpdateCall) Context(ctx context.Context) *FloodlightConfigurationsUpdateCall {
35851	c.ctx_ = ctx
35852	return c
35853}
35854
35855// Header returns an http.Header that can be modified by the caller to
35856// add HTTP headers to the request.
35857func (c *FloodlightConfigurationsUpdateCall) Header() http.Header {
35858	if c.header_ == nil {
35859		c.header_ = make(http.Header)
35860	}
35861	return c.header_
35862}
35863
35864func (c *FloodlightConfigurationsUpdateCall) doRequest(alt string) (*http.Response, error) {
35865	reqHeaders := make(http.Header)
35866	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
35867	for k, v := range c.header_ {
35868		reqHeaders[k] = v
35869	}
35870	reqHeaders.Set("User-Agent", c.s.userAgent())
35871	var body io.Reader = nil
35872	body, err := googleapi.WithoutDataWrapper.JSONReader(c.floodlightconfiguration)
35873	if err != nil {
35874		return nil, err
35875	}
35876	reqHeaders.Set("Content-Type", "application/json")
35877	c.urlParams_.Set("alt", alt)
35878	c.urlParams_.Set("prettyPrint", "false")
35879	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/floodlightConfigurations")
35880	urls += "?" + c.urlParams_.Encode()
35881	req, err := http.NewRequest("PUT", urls, body)
35882	if err != nil {
35883		return nil, err
35884	}
35885	req.Header = reqHeaders
35886	googleapi.Expand(req.URL, map[string]string{
35887		"profileId": strconv.FormatInt(c.profileId, 10),
35888	})
35889	return gensupport.SendRequest(c.ctx_, c.s.client, req)
35890}
35891
35892// Do executes the "dfareporting.floodlightConfigurations.update" call.
35893// Exactly one of *FloodlightConfiguration or error will be non-nil. Any
35894// non-2xx status code is an error. Response headers are in either
35895// *FloodlightConfiguration.ServerResponse.Header or (if a response was
35896// returned at all) in error.(*googleapi.Error).Header. Use
35897// googleapi.IsNotModified to check whether the returned error was
35898// because http.StatusNotModified was returned.
35899func (c *FloodlightConfigurationsUpdateCall) Do(opts ...googleapi.CallOption) (*FloodlightConfiguration, error) {
35900	gensupport.SetOptions(c.urlParams_, opts...)
35901	res, err := c.doRequest("json")
35902	if res != nil && res.StatusCode == http.StatusNotModified {
35903		if res.Body != nil {
35904			res.Body.Close()
35905		}
35906		return nil, &googleapi.Error{
35907			Code:   res.StatusCode,
35908			Header: res.Header,
35909		}
35910	}
35911	if err != nil {
35912		return nil, err
35913	}
35914	defer googleapi.CloseBody(res)
35915	if err := googleapi.CheckResponse(res); err != nil {
35916		return nil, err
35917	}
35918	ret := &FloodlightConfiguration{
35919		ServerResponse: googleapi.ServerResponse{
35920			Header:         res.Header,
35921			HTTPStatusCode: res.StatusCode,
35922		},
35923	}
35924	target := &ret
35925	if err := gensupport.DecodeResponse(target, res); err != nil {
35926		return nil, err
35927	}
35928	return ret, nil
35929	// {
35930	//   "description": "Updates an existing floodlight configuration.",
35931	//   "flatPath": "userprofiles/{profileId}/floodlightConfigurations",
35932	//   "httpMethod": "PUT",
35933	//   "id": "dfareporting.floodlightConfigurations.update",
35934	//   "parameterOrder": [
35935	//     "profileId"
35936	//   ],
35937	//   "parameters": {
35938	//     "profileId": {
35939	//       "description": "User profile ID associated with this request.",
35940	//       "format": "int64",
35941	//       "location": "path",
35942	//       "required": true,
35943	//       "type": "string"
35944	//     }
35945	//   },
35946	//   "path": "userprofiles/{profileId}/floodlightConfigurations",
35947	//   "request": {
35948	//     "$ref": "FloodlightConfiguration"
35949	//   },
35950	//   "response": {
35951	//     "$ref": "FloodlightConfiguration"
35952	//   },
35953	//   "scopes": [
35954	//     "https://www.googleapis.com/auth/dfatrafficking"
35955	//   ]
35956	// }
35957
35958}
35959
35960// method id "dfareporting.inventoryItems.get":
35961
35962type InventoryItemsGetCall struct {
35963	s            *Service
35964	profileId    int64
35965	projectId    int64
35966	id           int64
35967	urlParams_   gensupport.URLParams
35968	ifNoneMatch_ string
35969	ctx_         context.Context
35970	header_      http.Header
35971}
35972
35973// Get: Gets one inventory item by ID.
35974//
35975// - id: Inventory item ID.
35976// - profileId: User profile ID associated with this request.
35977// - projectId: Project ID for order documents.
35978func (r *InventoryItemsService) Get(profileId int64, projectId int64, id int64) *InventoryItemsGetCall {
35979	c := &InventoryItemsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
35980	c.profileId = profileId
35981	c.projectId = projectId
35982	c.id = id
35983	return c
35984}
35985
35986// Fields allows partial responses to be retrieved. See
35987// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
35988// for more information.
35989func (c *InventoryItemsGetCall) Fields(s ...googleapi.Field) *InventoryItemsGetCall {
35990	c.urlParams_.Set("fields", googleapi.CombineFields(s))
35991	return c
35992}
35993
35994// IfNoneMatch sets the optional parameter which makes the operation
35995// fail if the object's ETag matches the given value. This is useful for
35996// getting updates only after the object has changed since the last
35997// request. Use googleapi.IsNotModified to check whether the response
35998// error from Do is the result of In-None-Match.
35999func (c *InventoryItemsGetCall) IfNoneMatch(entityTag string) *InventoryItemsGetCall {
36000	c.ifNoneMatch_ = entityTag
36001	return c
36002}
36003
36004// Context sets the context to be used in this call's Do method. Any
36005// pending HTTP request will be aborted if the provided context is
36006// canceled.
36007func (c *InventoryItemsGetCall) Context(ctx context.Context) *InventoryItemsGetCall {
36008	c.ctx_ = ctx
36009	return c
36010}
36011
36012// Header returns an http.Header that can be modified by the caller to
36013// add HTTP headers to the request.
36014func (c *InventoryItemsGetCall) Header() http.Header {
36015	if c.header_ == nil {
36016		c.header_ = make(http.Header)
36017	}
36018	return c.header_
36019}
36020
36021func (c *InventoryItemsGetCall) doRequest(alt string) (*http.Response, error) {
36022	reqHeaders := make(http.Header)
36023	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
36024	for k, v := range c.header_ {
36025		reqHeaders[k] = v
36026	}
36027	reqHeaders.Set("User-Agent", c.s.userAgent())
36028	if c.ifNoneMatch_ != "" {
36029		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
36030	}
36031	var body io.Reader = nil
36032	c.urlParams_.Set("alt", alt)
36033	c.urlParams_.Set("prettyPrint", "false")
36034	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/projects/{projectId}/inventoryItems/{id}")
36035	urls += "?" + c.urlParams_.Encode()
36036	req, err := http.NewRequest("GET", urls, body)
36037	if err != nil {
36038		return nil, err
36039	}
36040	req.Header = reqHeaders
36041	googleapi.Expand(req.URL, map[string]string{
36042		"profileId": strconv.FormatInt(c.profileId, 10),
36043		"projectId": strconv.FormatInt(c.projectId, 10),
36044		"id":        strconv.FormatInt(c.id, 10),
36045	})
36046	return gensupport.SendRequest(c.ctx_, c.s.client, req)
36047}
36048
36049// Do executes the "dfareporting.inventoryItems.get" call.
36050// Exactly one of *InventoryItem or error will be non-nil. Any non-2xx
36051// status code is an error. Response headers are in either
36052// *InventoryItem.ServerResponse.Header or (if a response was returned
36053// at all) in error.(*googleapi.Error).Header. Use
36054// googleapi.IsNotModified to check whether the returned error was
36055// because http.StatusNotModified was returned.
36056func (c *InventoryItemsGetCall) Do(opts ...googleapi.CallOption) (*InventoryItem, error) {
36057	gensupport.SetOptions(c.urlParams_, opts...)
36058	res, err := c.doRequest("json")
36059	if res != nil && res.StatusCode == http.StatusNotModified {
36060		if res.Body != nil {
36061			res.Body.Close()
36062		}
36063		return nil, &googleapi.Error{
36064			Code:   res.StatusCode,
36065			Header: res.Header,
36066		}
36067	}
36068	if err != nil {
36069		return nil, err
36070	}
36071	defer googleapi.CloseBody(res)
36072	if err := googleapi.CheckResponse(res); err != nil {
36073		return nil, err
36074	}
36075	ret := &InventoryItem{
36076		ServerResponse: googleapi.ServerResponse{
36077			Header:         res.Header,
36078			HTTPStatusCode: res.StatusCode,
36079		},
36080	}
36081	target := &ret
36082	if err := gensupport.DecodeResponse(target, res); err != nil {
36083		return nil, err
36084	}
36085	return ret, nil
36086	// {
36087	//   "description": "Gets one inventory item by ID.",
36088	//   "flatPath": "userprofiles/{profileId}/projects/{projectId}/inventoryItems/{id}",
36089	//   "httpMethod": "GET",
36090	//   "id": "dfareporting.inventoryItems.get",
36091	//   "parameterOrder": [
36092	//     "profileId",
36093	//     "projectId",
36094	//     "id"
36095	//   ],
36096	//   "parameters": {
36097	//     "id": {
36098	//       "description": "Inventory item ID.",
36099	//       "format": "int64",
36100	//       "location": "path",
36101	//       "required": true,
36102	//       "type": "string"
36103	//     },
36104	//     "profileId": {
36105	//       "description": "User profile ID associated with this request.",
36106	//       "format": "int64",
36107	//       "location": "path",
36108	//       "required": true,
36109	//       "type": "string"
36110	//     },
36111	//     "projectId": {
36112	//       "description": "Project ID for order documents.",
36113	//       "format": "int64",
36114	//       "location": "path",
36115	//       "required": true,
36116	//       "type": "string"
36117	//     }
36118	//   },
36119	//   "path": "userprofiles/{profileId}/projects/{projectId}/inventoryItems/{id}",
36120	//   "response": {
36121	//     "$ref": "InventoryItem"
36122	//   },
36123	//   "scopes": [
36124	//     "https://www.googleapis.com/auth/dfatrafficking"
36125	//   ]
36126	// }
36127
36128}
36129
36130// method id "dfareporting.inventoryItems.list":
36131
36132type InventoryItemsListCall struct {
36133	s            *Service
36134	profileId    int64
36135	projectId    int64
36136	urlParams_   gensupport.URLParams
36137	ifNoneMatch_ string
36138	ctx_         context.Context
36139	header_      http.Header
36140}
36141
36142// List: Retrieves a list of inventory items, possibly filtered. This
36143// method supports paging.
36144//
36145// - profileId: User profile ID associated with this request.
36146// - projectId: Project ID for order documents.
36147func (r *InventoryItemsService) List(profileId int64, projectId int64) *InventoryItemsListCall {
36148	c := &InventoryItemsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
36149	c.profileId = profileId
36150	c.projectId = projectId
36151	return c
36152}
36153
36154// Ids sets the optional parameter "ids": Select only inventory items
36155// with these IDs.
36156func (c *InventoryItemsListCall) Ids(ids ...int64) *InventoryItemsListCall {
36157	var ids_ []string
36158	for _, v := range ids {
36159		ids_ = append(ids_, fmt.Sprint(v))
36160	}
36161	c.urlParams_.SetMulti("ids", ids_)
36162	return c
36163}
36164
36165// InPlan sets the optional parameter "inPlan": Select only inventory
36166// items that are in plan.
36167func (c *InventoryItemsListCall) InPlan(inPlan bool) *InventoryItemsListCall {
36168	c.urlParams_.Set("inPlan", fmt.Sprint(inPlan))
36169	return c
36170}
36171
36172// MaxResults sets the optional parameter "maxResults": Maximum number
36173// of results to return.
36174func (c *InventoryItemsListCall) MaxResults(maxResults int64) *InventoryItemsListCall {
36175	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
36176	return c
36177}
36178
36179// OrderId sets the optional parameter "orderId": Select only inventory
36180// items that belong to specified orders.
36181func (c *InventoryItemsListCall) OrderId(orderId ...int64) *InventoryItemsListCall {
36182	var orderId_ []string
36183	for _, v := range orderId {
36184		orderId_ = append(orderId_, fmt.Sprint(v))
36185	}
36186	c.urlParams_.SetMulti("orderId", orderId_)
36187	return c
36188}
36189
36190// PageToken sets the optional parameter "pageToken": Value of the
36191// nextPageToken from the previous result page.
36192func (c *InventoryItemsListCall) PageToken(pageToken string) *InventoryItemsListCall {
36193	c.urlParams_.Set("pageToken", pageToken)
36194	return c
36195}
36196
36197// SiteId sets the optional parameter "siteId": Select only inventory
36198// items that are associated with these sites.
36199func (c *InventoryItemsListCall) SiteId(siteId ...int64) *InventoryItemsListCall {
36200	var siteId_ []string
36201	for _, v := range siteId {
36202		siteId_ = append(siteId_, fmt.Sprint(v))
36203	}
36204	c.urlParams_.SetMulti("siteId", siteId_)
36205	return c
36206}
36207
36208// SortField sets the optional parameter "sortField": Field by which to
36209// sort the list.
36210//
36211// Possible values:
36212//   "ID" (default)
36213//   "NAME"
36214func (c *InventoryItemsListCall) SortField(sortField string) *InventoryItemsListCall {
36215	c.urlParams_.Set("sortField", sortField)
36216	return c
36217}
36218
36219// SortOrder sets the optional parameter "sortOrder": Order of sorted
36220// results.
36221//
36222// Possible values:
36223//   "ASCENDING" (default)
36224//   "DESCENDING"
36225func (c *InventoryItemsListCall) SortOrder(sortOrder string) *InventoryItemsListCall {
36226	c.urlParams_.Set("sortOrder", sortOrder)
36227	return c
36228}
36229
36230// Type sets the optional parameter "type": Select only inventory items
36231// with this type.
36232//
36233// Possible values:
36234//   "PLANNING_PLACEMENT_TYPE_REGULAR"
36235//   "PLANNING_PLACEMENT_TYPE_CREDIT"
36236func (c *InventoryItemsListCall) Type(type_ string) *InventoryItemsListCall {
36237	c.urlParams_.Set("type", type_)
36238	return c
36239}
36240
36241// Fields allows partial responses to be retrieved. See
36242// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
36243// for more information.
36244func (c *InventoryItemsListCall) Fields(s ...googleapi.Field) *InventoryItemsListCall {
36245	c.urlParams_.Set("fields", googleapi.CombineFields(s))
36246	return c
36247}
36248
36249// IfNoneMatch sets the optional parameter which makes the operation
36250// fail if the object's ETag matches the given value. This is useful for
36251// getting updates only after the object has changed since the last
36252// request. Use googleapi.IsNotModified to check whether the response
36253// error from Do is the result of In-None-Match.
36254func (c *InventoryItemsListCall) IfNoneMatch(entityTag string) *InventoryItemsListCall {
36255	c.ifNoneMatch_ = entityTag
36256	return c
36257}
36258
36259// Context sets the context to be used in this call's Do method. Any
36260// pending HTTP request will be aborted if the provided context is
36261// canceled.
36262func (c *InventoryItemsListCall) Context(ctx context.Context) *InventoryItemsListCall {
36263	c.ctx_ = ctx
36264	return c
36265}
36266
36267// Header returns an http.Header that can be modified by the caller to
36268// add HTTP headers to the request.
36269func (c *InventoryItemsListCall) Header() http.Header {
36270	if c.header_ == nil {
36271		c.header_ = make(http.Header)
36272	}
36273	return c.header_
36274}
36275
36276func (c *InventoryItemsListCall) doRequest(alt string) (*http.Response, error) {
36277	reqHeaders := make(http.Header)
36278	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
36279	for k, v := range c.header_ {
36280		reqHeaders[k] = v
36281	}
36282	reqHeaders.Set("User-Agent", c.s.userAgent())
36283	if c.ifNoneMatch_ != "" {
36284		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
36285	}
36286	var body io.Reader = nil
36287	c.urlParams_.Set("alt", alt)
36288	c.urlParams_.Set("prettyPrint", "false")
36289	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/projects/{projectId}/inventoryItems")
36290	urls += "?" + c.urlParams_.Encode()
36291	req, err := http.NewRequest("GET", urls, body)
36292	if err != nil {
36293		return nil, err
36294	}
36295	req.Header = reqHeaders
36296	googleapi.Expand(req.URL, map[string]string{
36297		"profileId": strconv.FormatInt(c.profileId, 10),
36298		"projectId": strconv.FormatInt(c.projectId, 10),
36299	})
36300	return gensupport.SendRequest(c.ctx_, c.s.client, req)
36301}
36302
36303// Do executes the "dfareporting.inventoryItems.list" call.
36304// Exactly one of *InventoryItemsListResponse or error will be non-nil.
36305// Any non-2xx status code is an error. Response headers are in either
36306// *InventoryItemsListResponse.ServerResponse.Header or (if a response
36307// was returned at all) in error.(*googleapi.Error).Header. Use
36308// googleapi.IsNotModified to check whether the returned error was
36309// because http.StatusNotModified was returned.
36310func (c *InventoryItemsListCall) Do(opts ...googleapi.CallOption) (*InventoryItemsListResponse, error) {
36311	gensupport.SetOptions(c.urlParams_, opts...)
36312	res, err := c.doRequest("json")
36313	if res != nil && res.StatusCode == http.StatusNotModified {
36314		if res.Body != nil {
36315			res.Body.Close()
36316		}
36317		return nil, &googleapi.Error{
36318			Code:   res.StatusCode,
36319			Header: res.Header,
36320		}
36321	}
36322	if err != nil {
36323		return nil, err
36324	}
36325	defer googleapi.CloseBody(res)
36326	if err := googleapi.CheckResponse(res); err != nil {
36327		return nil, err
36328	}
36329	ret := &InventoryItemsListResponse{
36330		ServerResponse: googleapi.ServerResponse{
36331			Header:         res.Header,
36332			HTTPStatusCode: res.StatusCode,
36333		},
36334	}
36335	target := &ret
36336	if err := gensupport.DecodeResponse(target, res); err != nil {
36337		return nil, err
36338	}
36339	return ret, nil
36340	// {
36341	//   "description": "Retrieves a list of inventory items, possibly filtered. This method supports paging.",
36342	//   "flatPath": "userprofiles/{profileId}/projects/{projectId}/inventoryItems",
36343	//   "httpMethod": "GET",
36344	//   "id": "dfareporting.inventoryItems.list",
36345	//   "parameterOrder": [
36346	//     "profileId",
36347	//     "projectId"
36348	//   ],
36349	//   "parameters": {
36350	//     "ids": {
36351	//       "description": "Select only inventory items with these IDs.",
36352	//       "format": "int64",
36353	//       "location": "query",
36354	//       "repeated": true,
36355	//       "type": "string"
36356	//     },
36357	//     "inPlan": {
36358	//       "description": "Select only inventory items that are in plan.",
36359	//       "location": "query",
36360	//       "type": "boolean"
36361	//     },
36362	//     "maxResults": {
36363	//       "default": "1000",
36364	//       "description": "Maximum number of results to return.",
36365	//       "format": "int32",
36366	//       "location": "query",
36367	//       "maximum": "1000",
36368	//       "minimum": "0",
36369	//       "type": "integer"
36370	//     },
36371	//     "orderId": {
36372	//       "description": "Select only inventory items that belong to specified orders.",
36373	//       "format": "int64",
36374	//       "location": "query",
36375	//       "repeated": true,
36376	//       "type": "string"
36377	//     },
36378	//     "pageToken": {
36379	//       "description": "Value of the nextPageToken from the previous result page.",
36380	//       "location": "query",
36381	//       "type": "string"
36382	//     },
36383	//     "profileId": {
36384	//       "description": "User profile ID associated with this request.",
36385	//       "format": "int64",
36386	//       "location": "path",
36387	//       "required": true,
36388	//       "type": "string"
36389	//     },
36390	//     "projectId": {
36391	//       "description": "Project ID for order documents.",
36392	//       "format": "int64",
36393	//       "location": "path",
36394	//       "required": true,
36395	//       "type": "string"
36396	//     },
36397	//     "siteId": {
36398	//       "description": "Select only inventory items that are associated with these sites.",
36399	//       "format": "int64",
36400	//       "location": "query",
36401	//       "repeated": true,
36402	//       "type": "string"
36403	//     },
36404	//     "sortField": {
36405	//       "default": "ID",
36406	//       "description": "Field by which to sort the list.",
36407	//       "enum": [
36408	//         "ID",
36409	//         "NAME"
36410	//       ],
36411	//       "enumDescriptions": [
36412	//         "",
36413	//         ""
36414	//       ],
36415	//       "location": "query",
36416	//       "type": "string"
36417	//     },
36418	//     "sortOrder": {
36419	//       "default": "ASCENDING",
36420	//       "description": "Order of sorted results.",
36421	//       "enum": [
36422	//         "ASCENDING",
36423	//         "DESCENDING"
36424	//       ],
36425	//       "enumDescriptions": [
36426	//         "",
36427	//         ""
36428	//       ],
36429	//       "location": "query",
36430	//       "type": "string"
36431	//     },
36432	//     "type": {
36433	//       "description": "Select only inventory items with this type.",
36434	//       "enum": [
36435	//         "PLANNING_PLACEMENT_TYPE_REGULAR",
36436	//         "PLANNING_PLACEMENT_TYPE_CREDIT"
36437	//       ],
36438	//       "enumDescriptions": [
36439	//         "",
36440	//         ""
36441	//       ],
36442	//       "location": "query",
36443	//       "type": "string"
36444	//     }
36445	//   },
36446	//   "path": "userprofiles/{profileId}/projects/{projectId}/inventoryItems",
36447	//   "response": {
36448	//     "$ref": "InventoryItemsListResponse"
36449	//   },
36450	//   "scopes": [
36451	//     "https://www.googleapis.com/auth/dfatrafficking"
36452	//   ]
36453	// }
36454
36455}
36456
36457// Pages invokes f for each page of results.
36458// A non-nil error returned from f will halt the iteration.
36459// The provided context supersedes any context provided to the Context method.
36460func (c *InventoryItemsListCall) Pages(ctx context.Context, f func(*InventoryItemsListResponse) error) error {
36461	c.ctx_ = ctx
36462	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
36463	for {
36464		x, err := c.Do()
36465		if err != nil {
36466			return err
36467		}
36468		if err := f(x); err != nil {
36469			return err
36470		}
36471		if x.NextPageToken == "" {
36472			return nil
36473		}
36474		c.PageToken(x.NextPageToken)
36475	}
36476}
36477
36478// method id "dfareporting.languages.list":
36479
36480type LanguagesListCall struct {
36481	s            *Service
36482	profileId    int64
36483	urlParams_   gensupport.URLParams
36484	ifNoneMatch_ string
36485	ctx_         context.Context
36486	header_      http.Header
36487}
36488
36489// List: Retrieves a list of languages.
36490//
36491// - profileId: User profile ID associated with this request.
36492func (r *LanguagesService) List(profileId int64) *LanguagesListCall {
36493	c := &LanguagesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
36494	c.profileId = profileId
36495	return c
36496}
36497
36498// Fields allows partial responses to be retrieved. See
36499// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
36500// for more information.
36501func (c *LanguagesListCall) Fields(s ...googleapi.Field) *LanguagesListCall {
36502	c.urlParams_.Set("fields", googleapi.CombineFields(s))
36503	return c
36504}
36505
36506// IfNoneMatch sets the optional parameter which makes the operation
36507// fail if the object's ETag matches the given value. This is useful for
36508// getting updates only after the object has changed since the last
36509// request. Use googleapi.IsNotModified to check whether the response
36510// error from Do is the result of In-None-Match.
36511func (c *LanguagesListCall) IfNoneMatch(entityTag string) *LanguagesListCall {
36512	c.ifNoneMatch_ = entityTag
36513	return c
36514}
36515
36516// Context sets the context to be used in this call's Do method. Any
36517// pending HTTP request will be aborted if the provided context is
36518// canceled.
36519func (c *LanguagesListCall) Context(ctx context.Context) *LanguagesListCall {
36520	c.ctx_ = ctx
36521	return c
36522}
36523
36524// Header returns an http.Header that can be modified by the caller to
36525// add HTTP headers to the request.
36526func (c *LanguagesListCall) Header() http.Header {
36527	if c.header_ == nil {
36528		c.header_ = make(http.Header)
36529	}
36530	return c.header_
36531}
36532
36533func (c *LanguagesListCall) doRequest(alt string) (*http.Response, error) {
36534	reqHeaders := make(http.Header)
36535	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
36536	for k, v := range c.header_ {
36537		reqHeaders[k] = v
36538	}
36539	reqHeaders.Set("User-Agent", c.s.userAgent())
36540	if c.ifNoneMatch_ != "" {
36541		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
36542	}
36543	var body io.Reader = nil
36544	c.urlParams_.Set("alt", alt)
36545	c.urlParams_.Set("prettyPrint", "false")
36546	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/languages")
36547	urls += "?" + c.urlParams_.Encode()
36548	req, err := http.NewRequest("GET", urls, body)
36549	if err != nil {
36550		return nil, err
36551	}
36552	req.Header = reqHeaders
36553	googleapi.Expand(req.URL, map[string]string{
36554		"profileId": strconv.FormatInt(c.profileId, 10),
36555	})
36556	return gensupport.SendRequest(c.ctx_, c.s.client, req)
36557}
36558
36559// Do executes the "dfareporting.languages.list" call.
36560// Exactly one of *LanguagesListResponse or error will be non-nil. Any
36561// non-2xx status code is an error. Response headers are in either
36562// *LanguagesListResponse.ServerResponse.Header or (if a response was
36563// returned at all) in error.(*googleapi.Error).Header. Use
36564// googleapi.IsNotModified to check whether the returned error was
36565// because http.StatusNotModified was returned.
36566func (c *LanguagesListCall) Do(opts ...googleapi.CallOption) (*LanguagesListResponse, error) {
36567	gensupport.SetOptions(c.urlParams_, opts...)
36568	res, err := c.doRequest("json")
36569	if res != nil && res.StatusCode == http.StatusNotModified {
36570		if res.Body != nil {
36571			res.Body.Close()
36572		}
36573		return nil, &googleapi.Error{
36574			Code:   res.StatusCode,
36575			Header: res.Header,
36576		}
36577	}
36578	if err != nil {
36579		return nil, err
36580	}
36581	defer googleapi.CloseBody(res)
36582	if err := googleapi.CheckResponse(res); err != nil {
36583		return nil, err
36584	}
36585	ret := &LanguagesListResponse{
36586		ServerResponse: googleapi.ServerResponse{
36587			Header:         res.Header,
36588			HTTPStatusCode: res.StatusCode,
36589		},
36590	}
36591	target := &ret
36592	if err := gensupport.DecodeResponse(target, res); err != nil {
36593		return nil, err
36594	}
36595	return ret, nil
36596	// {
36597	//   "description": "Retrieves a list of languages.",
36598	//   "flatPath": "userprofiles/{profileId}/languages",
36599	//   "httpMethod": "GET",
36600	//   "id": "dfareporting.languages.list",
36601	//   "parameterOrder": [
36602	//     "profileId"
36603	//   ],
36604	//   "parameters": {
36605	//     "profileId": {
36606	//       "description": "User profile ID associated with this request.",
36607	//       "format": "int64",
36608	//       "location": "path",
36609	//       "required": true,
36610	//       "type": "string"
36611	//     }
36612	//   },
36613	//   "path": "userprofiles/{profileId}/languages",
36614	//   "response": {
36615	//     "$ref": "LanguagesListResponse"
36616	//   },
36617	//   "scopes": [
36618	//     "https://www.googleapis.com/auth/dfatrafficking"
36619	//   ]
36620	// }
36621
36622}
36623
36624// method id "dfareporting.metros.list":
36625
36626type MetrosListCall struct {
36627	s            *Service
36628	profileId    int64
36629	urlParams_   gensupport.URLParams
36630	ifNoneMatch_ string
36631	ctx_         context.Context
36632	header_      http.Header
36633}
36634
36635// List: Retrieves a list of metros.
36636//
36637// - profileId: User profile ID associated with this request.
36638func (r *MetrosService) List(profileId int64) *MetrosListCall {
36639	c := &MetrosListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
36640	c.profileId = profileId
36641	return c
36642}
36643
36644// Fields allows partial responses to be retrieved. See
36645// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
36646// for more information.
36647func (c *MetrosListCall) Fields(s ...googleapi.Field) *MetrosListCall {
36648	c.urlParams_.Set("fields", googleapi.CombineFields(s))
36649	return c
36650}
36651
36652// IfNoneMatch sets the optional parameter which makes the operation
36653// fail if the object's ETag matches the given value. This is useful for
36654// getting updates only after the object has changed since the last
36655// request. Use googleapi.IsNotModified to check whether the response
36656// error from Do is the result of In-None-Match.
36657func (c *MetrosListCall) IfNoneMatch(entityTag string) *MetrosListCall {
36658	c.ifNoneMatch_ = entityTag
36659	return c
36660}
36661
36662// Context sets the context to be used in this call's Do method. Any
36663// pending HTTP request will be aborted if the provided context is
36664// canceled.
36665func (c *MetrosListCall) Context(ctx context.Context) *MetrosListCall {
36666	c.ctx_ = ctx
36667	return c
36668}
36669
36670// Header returns an http.Header that can be modified by the caller to
36671// add HTTP headers to the request.
36672func (c *MetrosListCall) Header() http.Header {
36673	if c.header_ == nil {
36674		c.header_ = make(http.Header)
36675	}
36676	return c.header_
36677}
36678
36679func (c *MetrosListCall) doRequest(alt string) (*http.Response, error) {
36680	reqHeaders := make(http.Header)
36681	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
36682	for k, v := range c.header_ {
36683		reqHeaders[k] = v
36684	}
36685	reqHeaders.Set("User-Agent", c.s.userAgent())
36686	if c.ifNoneMatch_ != "" {
36687		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
36688	}
36689	var body io.Reader = nil
36690	c.urlParams_.Set("alt", alt)
36691	c.urlParams_.Set("prettyPrint", "false")
36692	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/metros")
36693	urls += "?" + c.urlParams_.Encode()
36694	req, err := http.NewRequest("GET", urls, body)
36695	if err != nil {
36696		return nil, err
36697	}
36698	req.Header = reqHeaders
36699	googleapi.Expand(req.URL, map[string]string{
36700		"profileId": strconv.FormatInt(c.profileId, 10),
36701	})
36702	return gensupport.SendRequest(c.ctx_, c.s.client, req)
36703}
36704
36705// Do executes the "dfareporting.metros.list" call.
36706// Exactly one of *MetrosListResponse or error will be non-nil. Any
36707// non-2xx status code is an error. Response headers are in either
36708// *MetrosListResponse.ServerResponse.Header or (if a response was
36709// returned at all) in error.(*googleapi.Error).Header. Use
36710// googleapi.IsNotModified to check whether the returned error was
36711// because http.StatusNotModified was returned.
36712func (c *MetrosListCall) Do(opts ...googleapi.CallOption) (*MetrosListResponse, error) {
36713	gensupport.SetOptions(c.urlParams_, opts...)
36714	res, err := c.doRequest("json")
36715	if res != nil && res.StatusCode == http.StatusNotModified {
36716		if res.Body != nil {
36717			res.Body.Close()
36718		}
36719		return nil, &googleapi.Error{
36720			Code:   res.StatusCode,
36721			Header: res.Header,
36722		}
36723	}
36724	if err != nil {
36725		return nil, err
36726	}
36727	defer googleapi.CloseBody(res)
36728	if err := googleapi.CheckResponse(res); err != nil {
36729		return nil, err
36730	}
36731	ret := &MetrosListResponse{
36732		ServerResponse: googleapi.ServerResponse{
36733			Header:         res.Header,
36734			HTTPStatusCode: res.StatusCode,
36735		},
36736	}
36737	target := &ret
36738	if err := gensupport.DecodeResponse(target, res); err != nil {
36739		return nil, err
36740	}
36741	return ret, nil
36742	// {
36743	//   "description": "Retrieves a list of metros.",
36744	//   "flatPath": "userprofiles/{profileId}/metros",
36745	//   "httpMethod": "GET",
36746	//   "id": "dfareporting.metros.list",
36747	//   "parameterOrder": [
36748	//     "profileId"
36749	//   ],
36750	//   "parameters": {
36751	//     "profileId": {
36752	//       "description": "User profile ID associated with this request.",
36753	//       "format": "int64",
36754	//       "location": "path",
36755	//       "required": true,
36756	//       "type": "string"
36757	//     }
36758	//   },
36759	//   "path": "userprofiles/{profileId}/metros",
36760	//   "response": {
36761	//     "$ref": "MetrosListResponse"
36762	//   },
36763	//   "scopes": [
36764	//     "https://www.googleapis.com/auth/dfatrafficking"
36765	//   ]
36766	// }
36767
36768}
36769
36770// method id "dfareporting.mobileApps.get":
36771
36772type MobileAppsGetCall struct {
36773	s            *Service
36774	profileId    int64
36775	id           string
36776	urlParams_   gensupport.URLParams
36777	ifNoneMatch_ string
36778	ctx_         context.Context
36779	header_      http.Header
36780}
36781
36782// Get: Gets one mobile app by ID.
36783//
36784// - id: Mobile app ID.
36785// - profileId: User profile ID associated with this request.
36786func (r *MobileAppsService) Get(profileId int64, id string) *MobileAppsGetCall {
36787	c := &MobileAppsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
36788	c.profileId = profileId
36789	c.id = id
36790	return c
36791}
36792
36793// Fields allows partial responses to be retrieved. See
36794// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
36795// for more information.
36796func (c *MobileAppsGetCall) Fields(s ...googleapi.Field) *MobileAppsGetCall {
36797	c.urlParams_.Set("fields", googleapi.CombineFields(s))
36798	return c
36799}
36800
36801// IfNoneMatch sets the optional parameter which makes the operation
36802// fail if the object's ETag matches the given value. This is useful for
36803// getting updates only after the object has changed since the last
36804// request. Use googleapi.IsNotModified to check whether the response
36805// error from Do is the result of In-None-Match.
36806func (c *MobileAppsGetCall) IfNoneMatch(entityTag string) *MobileAppsGetCall {
36807	c.ifNoneMatch_ = entityTag
36808	return c
36809}
36810
36811// Context sets the context to be used in this call's Do method. Any
36812// pending HTTP request will be aborted if the provided context is
36813// canceled.
36814func (c *MobileAppsGetCall) Context(ctx context.Context) *MobileAppsGetCall {
36815	c.ctx_ = ctx
36816	return c
36817}
36818
36819// Header returns an http.Header that can be modified by the caller to
36820// add HTTP headers to the request.
36821func (c *MobileAppsGetCall) Header() http.Header {
36822	if c.header_ == nil {
36823		c.header_ = make(http.Header)
36824	}
36825	return c.header_
36826}
36827
36828func (c *MobileAppsGetCall) doRequest(alt string) (*http.Response, error) {
36829	reqHeaders := make(http.Header)
36830	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
36831	for k, v := range c.header_ {
36832		reqHeaders[k] = v
36833	}
36834	reqHeaders.Set("User-Agent", c.s.userAgent())
36835	if c.ifNoneMatch_ != "" {
36836		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
36837	}
36838	var body io.Reader = nil
36839	c.urlParams_.Set("alt", alt)
36840	c.urlParams_.Set("prettyPrint", "false")
36841	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/mobileApps/{id}")
36842	urls += "?" + c.urlParams_.Encode()
36843	req, err := http.NewRequest("GET", urls, body)
36844	if err != nil {
36845		return nil, err
36846	}
36847	req.Header = reqHeaders
36848	googleapi.Expand(req.URL, map[string]string{
36849		"profileId": strconv.FormatInt(c.profileId, 10),
36850		"id":        c.id,
36851	})
36852	return gensupport.SendRequest(c.ctx_, c.s.client, req)
36853}
36854
36855// Do executes the "dfareporting.mobileApps.get" call.
36856// Exactly one of *MobileApp or error will be non-nil. Any non-2xx
36857// status code is an error. Response headers are in either
36858// *MobileApp.ServerResponse.Header or (if a response was returned at
36859// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
36860// to check whether the returned error was because
36861// http.StatusNotModified was returned.
36862func (c *MobileAppsGetCall) Do(opts ...googleapi.CallOption) (*MobileApp, error) {
36863	gensupport.SetOptions(c.urlParams_, opts...)
36864	res, err := c.doRequest("json")
36865	if res != nil && res.StatusCode == http.StatusNotModified {
36866		if res.Body != nil {
36867			res.Body.Close()
36868		}
36869		return nil, &googleapi.Error{
36870			Code:   res.StatusCode,
36871			Header: res.Header,
36872		}
36873	}
36874	if err != nil {
36875		return nil, err
36876	}
36877	defer googleapi.CloseBody(res)
36878	if err := googleapi.CheckResponse(res); err != nil {
36879		return nil, err
36880	}
36881	ret := &MobileApp{
36882		ServerResponse: googleapi.ServerResponse{
36883			Header:         res.Header,
36884			HTTPStatusCode: res.StatusCode,
36885		},
36886	}
36887	target := &ret
36888	if err := gensupport.DecodeResponse(target, res); err != nil {
36889		return nil, err
36890	}
36891	return ret, nil
36892	// {
36893	//   "description": "Gets one mobile app by ID.",
36894	//   "flatPath": "userprofiles/{profileId}/mobileApps/{id}",
36895	//   "httpMethod": "GET",
36896	//   "id": "dfareporting.mobileApps.get",
36897	//   "parameterOrder": [
36898	//     "profileId",
36899	//     "id"
36900	//   ],
36901	//   "parameters": {
36902	//     "id": {
36903	//       "description": "Mobile app ID.",
36904	//       "location": "path",
36905	//       "required": true,
36906	//       "type": "string"
36907	//     },
36908	//     "profileId": {
36909	//       "description": "User profile ID associated with this request.",
36910	//       "format": "int64",
36911	//       "location": "path",
36912	//       "required": true,
36913	//       "type": "string"
36914	//     }
36915	//   },
36916	//   "path": "userprofiles/{profileId}/mobileApps/{id}",
36917	//   "response": {
36918	//     "$ref": "MobileApp"
36919	//   },
36920	//   "scopes": [
36921	//     "https://www.googleapis.com/auth/dfatrafficking"
36922	//   ]
36923	// }
36924
36925}
36926
36927// method id "dfareporting.mobileApps.list":
36928
36929type MobileAppsListCall struct {
36930	s            *Service
36931	profileId    int64
36932	urlParams_   gensupport.URLParams
36933	ifNoneMatch_ string
36934	ctx_         context.Context
36935	header_      http.Header
36936}
36937
36938// List: Retrieves list of available mobile apps.
36939//
36940// - profileId: User profile ID associated with this request.
36941func (r *MobileAppsService) List(profileId int64) *MobileAppsListCall {
36942	c := &MobileAppsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
36943	c.profileId = profileId
36944	return c
36945}
36946
36947// Directories sets the optional parameter "directories": Select only
36948// apps from these directories.
36949//
36950// Possible values:
36951//   "UNKNOWN"
36952//   "APPLE_APP_STORE"
36953//   "GOOGLE_PLAY_STORE"
36954func (c *MobileAppsListCall) Directories(directories ...string) *MobileAppsListCall {
36955	c.urlParams_.SetMulti("directories", append([]string{}, directories...))
36956	return c
36957}
36958
36959// Ids sets the optional parameter "ids": Select only apps with these
36960// IDs.
36961func (c *MobileAppsListCall) Ids(ids ...string) *MobileAppsListCall {
36962	c.urlParams_.SetMulti("ids", append([]string{}, ids...))
36963	return c
36964}
36965
36966// MaxResults sets the optional parameter "maxResults": Maximum number
36967// of results to return.
36968func (c *MobileAppsListCall) MaxResults(maxResults int64) *MobileAppsListCall {
36969	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
36970	return c
36971}
36972
36973// PageToken sets the optional parameter "pageToken": Value of the
36974// nextPageToken from the previous result page.
36975func (c *MobileAppsListCall) PageToken(pageToken string) *MobileAppsListCall {
36976	c.urlParams_.Set("pageToken", pageToken)
36977	return c
36978}
36979
36980// SearchString sets the optional parameter "searchString": Allows
36981// searching for objects by name or ID. Wildcards (*) are allowed. For
36982// example, "app*2015" will return objects with names like "app Jan
36983// 2018", "app Jan 2018", or simply "app 2018". Most of the searches
36984// also add wildcards implicitly at the start and the end of the search
36985// string. For example, a search string of "app" will match objects with
36986// name "my app", "app 2018", or simply "app".
36987func (c *MobileAppsListCall) SearchString(searchString string) *MobileAppsListCall {
36988	c.urlParams_.Set("searchString", searchString)
36989	return c
36990}
36991
36992// Fields allows partial responses to be retrieved. See
36993// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
36994// for more information.
36995func (c *MobileAppsListCall) Fields(s ...googleapi.Field) *MobileAppsListCall {
36996	c.urlParams_.Set("fields", googleapi.CombineFields(s))
36997	return c
36998}
36999
37000// IfNoneMatch sets the optional parameter which makes the operation
37001// fail if the object's ETag matches the given value. This is useful for
37002// getting updates only after the object has changed since the last
37003// request. Use googleapi.IsNotModified to check whether the response
37004// error from Do is the result of In-None-Match.
37005func (c *MobileAppsListCall) IfNoneMatch(entityTag string) *MobileAppsListCall {
37006	c.ifNoneMatch_ = entityTag
37007	return c
37008}
37009
37010// Context sets the context to be used in this call's Do method. Any
37011// pending HTTP request will be aborted if the provided context is
37012// canceled.
37013func (c *MobileAppsListCall) Context(ctx context.Context) *MobileAppsListCall {
37014	c.ctx_ = ctx
37015	return c
37016}
37017
37018// Header returns an http.Header that can be modified by the caller to
37019// add HTTP headers to the request.
37020func (c *MobileAppsListCall) Header() http.Header {
37021	if c.header_ == nil {
37022		c.header_ = make(http.Header)
37023	}
37024	return c.header_
37025}
37026
37027func (c *MobileAppsListCall) doRequest(alt string) (*http.Response, error) {
37028	reqHeaders := make(http.Header)
37029	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
37030	for k, v := range c.header_ {
37031		reqHeaders[k] = v
37032	}
37033	reqHeaders.Set("User-Agent", c.s.userAgent())
37034	if c.ifNoneMatch_ != "" {
37035		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
37036	}
37037	var body io.Reader = nil
37038	c.urlParams_.Set("alt", alt)
37039	c.urlParams_.Set("prettyPrint", "false")
37040	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/mobileApps")
37041	urls += "?" + c.urlParams_.Encode()
37042	req, err := http.NewRequest("GET", urls, body)
37043	if err != nil {
37044		return nil, err
37045	}
37046	req.Header = reqHeaders
37047	googleapi.Expand(req.URL, map[string]string{
37048		"profileId": strconv.FormatInt(c.profileId, 10),
37049	})
37050	return gensupport.SendRequest(c.ctx_, c.s.client, req)
37051}
37052
37053// Do executes the "dfareporting.mobileApps.list" call.
37054// Exactly one of *MobileAppsListResponse or error will be non-nil. Any
37055// non-2xx status code is an error. Response headers are in either
37056// *MobileAppsListResponse.ServerResponse.Header or (if a response was
37057// returned at all) in error.(*googleapi.Error).Header. Use
37058// googleapi.IsNotModified to check whether the returned error was
37059// because http.StatusNotModified was returned.
37060func (c *MobileAppsListCall) Do(opts ...googleapi.CallOption) (*MobileAppsListResponse, error) {
37061	gensupport.SetOptions(c.urlParams_, opts...)
37062	res, err := c.doRequest("json")
37063	if res != nil && res.StatusCode == http.StatusNotModified {
37064		if res.Body != nil {
37065			res.Body.Close()
37066		}
37067		return nil, &googleapi.Error{
37068			Code:   res.StatusCode,
37069			Header: res.Header,
37070		}
37071	}
37072	if err != nil {
37073		return nil, err
37074	}
37075	defer googleapi.CloseBody(res)
37076	if err := googleapi.CheckResponse(res); err != nil {
37077		return nil, err
37078	}
37079	ret := &MobileAppsListResponse{
37080		ServerResponse: googleapi.ServerResponse{
37081			Header:         res.Header,
37082			HTTPStatusCode: res.StatusCode,
37083		},
37084	}
37085	target := &ret
37086	if err := gensupport.DecodeResponse(target, res); err != nil {
37087		return nil, err
37088	}
37089	return ret, nil
37090	// {
37091	//   "description": "Retrieves list of available mobile apps.",
37092	//   "flatPath": "userprofiles/{profileId}/mobileApps",
37093	//   "httpMethod": "GET",
37094	//   "id": "dfareporting.mobileApps.list",
37095	//   "parameterOrder": [
37096	//     "profileId"
37097	//   ],
37098	//   "parameters": {
37099	//     "directories": {
37100	//       "description": "Select only apps from these directories.",
37101	//       "enum": [
37102	//         "UNKNOWN",
37103	//         "APPLE_APP_STORE",
37104	//         "GOOGLE_PLAY_STORE"
37105	//       ],
37106	//       "enumDescriptions": [
37107	//         "",
37108	//         "",
37109	//         ""
37110	//       ],
37111	//       "location": "query",
37112	//       "repeated": true,
37113	//       "type": "string"
37114	//     },
37115	//     "ids": {
37116	//       "description": "Select only apps with these IDs.",
37117	//       "location": "query",
37118	//       "repeated": true,
37119	//       "type": "string"
37120	//     },
37121	//     "maxResults": {
37122	//       "default": "1000",
37123	//       "description": "Maximum number of results to return.",
37124	//       "format": "int32",
37125	//       "location": "query",
37126	//       "maximum": "1000",
37127	//       "minimum": "0",
37128	//       "type": "integer"
37129	//     },
37130	//     "pageToken": {
37131	//       "description": "Value of the nextPageToken from the previous result page.",
37132	//       "location": "query",
37133	//       "type": "string"
37134	//     },
37135	//     "profileId": {
37136	//       "description": "User profile ID associated with this request.",
37137	//       "format": "int64",
37138	//       "location": "path",
37139	//       "required": true,
37140	//       "type": "string"
37141	//     },
37142	//     "searchString": {
37143	//       "description": "Allows searching for objects by name or ID. Wildcards (*) are allowed. For example, \"app*2015\" will return objects with names like \"app Jan 2018\", \"app Jan 2018\", or simply \"app 2018\". Most of the searches also add wildcards implicitly at the start and the end of the search string. For example, a search string of \"app\" will match objects with name \"my app\", \"app 2018\", or simply \"app\".",
37144	//       "location": "query",
37145	//       "type": "string"
37146	//     }
37147	//   },
37148	//   "path": "userprofiles/{profileId}/mobileApps",
37149	//   "response": {
37150	//     "$ref": "MobileAppsListResponse"
37151	//   },
37152	//   "scopes": [
37153	//     "https://www.googleapis.com/auth/dfatrafficking"
37154	//   ]
37155	// }
37156
37157}
37158
37159// Pages invokes f for each page of results.
37160// A non-nil error returned from f will halt the iteration.
37161// The provided context supersedes any context provided to the Context method.
37162func (c *MobileAppsListCall) Pages(ctx context.Context, f func(*MobileAppsListResponse) error) error {
37163	c.ctx_ = ctx
37164	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
37165	for {
37166		x, err := c.Do()
37167		if err != nil {
37168			return err
37169		}
37170		if err := f(x); err != nil {
37171			return err
37172		}
37173		if x.NextPageToken == "" {
37174			return nil
37175		}
37176		c.PageToken(x.NextPageToken)
37177	}
37178}
37179
37180// method id "dfareporting.mobileCarriers.get":
37181
37182type MobileCarriersGetCall struct {
37183	s            *Service
37184	profileId    int64
37185	id           int64
37186	urlParams_   gensupport.URLParams
37187	ifNoneMatch_ string
37188	ctx_         context.Context
37189	header_      http.Header
37190}
37191
37192// Get: Gets one mobile carrier by ID.
37193//
37194// - id: Mobile carrier ID.
37195// - profileId: User profile ID associated with this request.
37196func (r *MobileCarriersService) Get(profileId int64, id int64) *MobileCarriersGetCall {
37197	c := &MobileCarriersGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
37198	c.profileId = profileId
37199	c.id = id
37200	return c
37201}
37202
37203// Fields allows partial responses to be retrieved. See
37204// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
37205// for more information.
37206func (c *MobileCarriersGetCall) Fields(s ...googleapi.Field) *MobileCarriersGetCall {
37207	c.urlParams_.Set("fields", googleapi.CombineFields(s))
37208	return c
37209}
37210
37211// IfNoneMatch sets the optional parameter which makes the operation
37212// fail if the object's ETag matches the given value. This is useful for
37213// getting updates only after the object has changed since the last
37214// request. Use googleapi.IsNotModified to check whether the response
37215// error from Do is the result of In-None-Match.
37216func (c *MobileCarriersGetCall) IfNoneMatch(entityTag string) *MobileCarriersGetCall {
37217	c.ifNoneMatch_ = entityTag
37218	return c
37219}
37220
37221// Context sets the context to be used in this call's Do method. Any
37222// pending HTTP request will be aborted if the provided context is
37223// canceled.
37224func (c *MobileCarriersGetCall) Context(ctx context.Context) *MobileCarriersGetCall {
37225	c.ctx_ = ctx
37226	return c
37227}
37228
37229// Header returns an http.Header that can be modified by the caller to
37230// add HTTP headers to the request.
37231func (c *MobileCarriersGetCall) Header() http.Header {
37232	if c.header_ == nil {
37233		c.header_ = make(http.Header)
37234	}
37235	return c.header_
37236}
37237
37238func (c *MobileCarriersGetCall) doRequest(alt string) (*http.Response, error) {
37239	reqHeaders := make(http.Header)
37240	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
37241	for k, v := range c.header_ {
37242		reqHeaders[k] = v
37243	}
37244	reqHeaders.Set("User-Agent", c.s.userAgent())
37245	if c.ifNoneMatch_ != "" {
37246		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
37247	}
37248	var body io.Reader = nil
37249	c.urlParams_.Set("alt", alt)
37250	c.urlParams_.Set("prettyPrint", "false")
37251	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/mobileCarriers/{id}")
37252	urls += "?" + c.urlParams_.Encode()
37253	req, err := http.NewRequest("GET", urls, body)
37254	if err != nil {
37255		return nil, err
37256	}
37257	req.Header = reqHeaders
37258	googleapi.Expand(req.URL, map[string]string{
37259		"profileId": strconv.FormatInt(c.profileId, 10),
37260		"id":        strconv.FormatInt(c.id, 10),
37261	})
37262	return gensupport.SendRequest(c.ctx_, c.s.client, req)
37263}
37264
37265// Do executes the "dfareporting.mobileCarriers.get" call.
37266// Exactly one of *MobileCarrier or error will be non-nil. Any non-2xx
37267// status code is an error. Response headers are in either
37268// *MobileCarrier.ServerResponse.Header or (if a response was returned
37269// at all) in error.(*googleapi.Error).Header. Use
37270// googleapi.IsNotModified to check whether the returned error was
37271// because http.StatusNotModified was returned.
37272func (c *MobileCarriersGetCall) Do(opts ...googleapi.CallOption) (*MobileCarrier, error) {
37273	gensupport.SetOptions(c.urlParams_, opts...)
37274	res, err := c.doRequest("json")
37275	if res != nil && res.StatusCode == http.StatusNotModified {
37276		if res.Body != nil {
37277			res.Body.Close()
37278		}
37279		return nil, &googleapi.Error{
37280			Code:   res.StatusCode,
37281			Header: res.Header,
37282		}
37283	}
37284	if err != nil {
37285		return nil, err
37286	}
37287	defer googleapi.CloseBody(res)
37288	if err := googleapi.CheckResponse(res); err != nil {
37289		return nil, err
37290	}
37291	ret := &MobileCarrier{
37292		ServerResponse: googleapi.ServerResponse{
37293			Header:         res.Header,
37294			HTTPStatusCode: res.StatusCode,
37295		},
37296	}
37297	target := &ret
37298	if err := gensupport.DecodeResponse(target, res); err != nil {
37299		return nil, err
37300	}
37301	return ret, nil
37302	// {
37303	//   "description": "Gets one mobile carrier by ID.",
37304	//   "flatPath": "userprofiles/{profileId}/mobileCarriers/{id}",
37305	//   "httpMethod": "GET",
37306	//   "id": "dfareporting.mobileCarriers.get",
37307	//   "parameterOrder": [
37308	//     "profileId",
37309	//     "id"
37310	//   ],
37311	//   "parameters": {
37312	//     "id": {
37313	//       "description": "Mobile carrier ID.",
37314	//       "format": "int64",
37315	//       "location": "path",
37316	//       "required": true,
37317	//       "type": "string"
37318	//     },
37319	//     "profileId": {
37320	//       "description": "User profile ID associated with this request.",
37321	//       "format": "int64",
37322	//       "location": "path",
37323	//       "required": true,
37324	//       "type": "string"
37325	//     }
37326	//   },
37327	//   "path": "userprofiles/{profileId}/mobileCarriers/{id}",
37328	//   "response": {
37329	//     "$ref": "MobileCarrier"
37330	//   },
37331	//   "scopes": [
37332	//     "https://www.googleapis.com/auth/dfatrafficking"
37333	//   ]
37334	// }
37335
37336}
37337
37338// method id "dfareporting.mobileCarriers.list":
37339
37340type MobileCarriersListCall struct {
37341	s            *Service
37342	profileId    int64
37343	urlParams_   gensupport.URLParams
37344	ifNoneMatch_ string
37345	ctx_         context.Context
37346	header_      http.Header
37347}
37348
37349// List: Retrieves a list of mobile carriers.
37350//
37351// - profileId: User profile ID associated with this request.
37352func (r *MobileCarriersService) List(profileId int64) *MobileCarriersListCall {
37353	c := &MobileCarriersListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
37354	c.profileId = profileId
37355	return c
37356}
37357
37358// Fields allows partial responses to be retrieved. See
37359// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
37360// for more information.
37361func (c *MobileCarriersListCall) Fields(s ...googleapi.Field) *MobileCarriersListCall {
37362	c.urlParams_.Set("fields", googleapi.CombineFields(s))
37363	return c
37364}
37365
37366// IfNoneMatch sets the optional parameter which makes the operation
37367// fail if the object's ETag matches the given value. This is useful for
37368// getting updates only after the object has changed since the last
37369// request. Use googleapi.IsNotModified to check whether the response
37370// error from Do is the result of In-None-Match.
37371func (c *MobileCarriersListCall) IfNoneMatch(entityTag string) *MobileCarriersListCall {
37372	c.ifNoneMatch_ = entityTag
37373	return c
37374}
37375
37376// Context sets the context to be used in this call's Do method. Any
37377// pending HTTP request will be aborted if the provided context is
37378// canceled.
37379func (c *MobileCarriersListCall) Context(ctx context.Context) *MobileCarriersListCall {
37380	c.ctx_ = ctx
37381	return c
37382}
37383
37384// Header returns an http.Header that can be modified by the caller to
37385// add HTTP headers to the request.
37386func (c *MobileCarriersListCall) Header() http.Header {
37387	if c.header_ == nil {
37388		c.header_ = make(http.Header)
37389	}
37390	return c.header_
37391}
37392
37393func (c *MobileCarriersListCall) doRequest(alt string) (*http.Response, error) {
37394	reqHeaders := make(http.Header)
37395	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
37396	for k, v := range c.header_ {
37397		reqHeaders[k] = v
37398	}
37399	reqHeaders.Set("User-Agent", c.s.userAgent())
37400	if c.ifNoneMatch_ != "" {
37401		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
37402	}
37403	var body io.Reader = nil
37404	c.urlParams_.Set("alt", alt)
37405	c.urlParams_.Set("prettyPrint", "false")
37406	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/mobileCarriers")
37407	urls += "?" + c.urlParams_.Encode()
37408	req, err := http.NewRequest("GET", urls, body)
37409	if err != nil {
37410		return nil, err
37411	}
37412	req.Header = reqHeaders
37413	googleapi.Expand(req.URL, map[string]string{
37414		"profileId": strconv.FormatInt(c.profileId, 10),
37415	})
37416	return gensupport.SendRequest(c.ctx_, c.s.client, req)
37417}
37418
37419// Do executes the "dfareporting.mobileCarriers.list" call.
37420// Exactly one of *MobileCarriersListResponse or error will be non-nil.
37421// Any non-2xx status code is an error. Response headers are in either
37422// *MobileCarriersListResponse.ServerResponse.Header or (if a response
37423// was returned at all) in error.(*googleapi.Error).Header. Use
37424// googleapi.IsNotModified to check whether the returned error was
37425// because http.StatusNotModified was returned.
37426func (c *MobileCarriersListCall) Do(opts ...googleapi.CallOption) (*MobileCarriersListResponse, error) {
37427	gensupport.SetOptions(c.urlParams_, opts...)
37428	res, err := c.doRequest("json")
37429	if res != nil && res.StatusCode == http.StatusNotModified {
37430		if res.Body != nil {
37431			res.Body.Close()
37432		}
37433		return nil, &googleapi.Error{
37434			Code:   res.StatusCode,
37435			Header: res.Header,
37436		}
37437	}
37438	if err != nil {
37439		return nil, err
37440	}
37441	defer googleapi.CloseBody(res)
37442	if err := googleapi.CheckResponse(res); err != nil {
37443		return nil, err
37444	}
37445	ret := &MobileCarriersListResponse{
37446		ServerResponse: googleapi.ServerResponse{
37447			Header:         res.Header,
37448			HTTPStatusCode: res.StatusCode,
37449		},
37450	}
37451	target := &ret
37452	if err := gensupport.DecodeResponse(target, res); err != nil {
37453		return nil, err
37454	}
37455	return ret, nil
37456	// {
37457	//   "description": "Retrieves a list of mobile carriers.",
37458	//   "flatPath": "userprofiles/{profileId}/mobileCarriers",
37459	//   "httpMethod": "GET",
37460	//   "id": "dfareporting.mobileCarriers.list",
37461	//   "parameterOrder": [
37462	//     "profileId"
37463	//   ],
37464	//   "parameters": {
37465	//     "profileId": {
37466	//       "description": "User profile ID associated with this request.",
37467	//       "format": "int64",
37468	//       "location": "path",
37469	//       "required": true,
37470	//       "type": "string"
37471	//     }
37472	//   },
37473	//   "path": "userprofiles/{profileId}/mobileCarriers",
37474	//   "response": {
37475	//     "$ref": "MobileCarriersListResponse"
37476	//   },
37477	//   "scopes": [
37478	//     "https://www.googleapis.com/auth/dfatrafficking"
37479	//   ]
37480	// }
37481
37482}
37483
37484// method id "dfareporting.operatingSystemVersions.get":
37485
37486type OperatingSystemVersionsGetCall struct {
37487	s            *Service
37488	profileId    int64
37489	id           int64
37490	urlParams_   gensupport.URLParams
37491	ifNoneMatch_ string
37492	ctx_         context.Context
37493	header_      http.Header
37494}
37495
37496// Get: Gets one operating system version by ID.
37497//
37498// - id: Operating system version ID.
37499// - profileId: User profile ID associated with this request.
37500func (r *OperatingSystemVersionsService) Get(profileId int64, id int64) *OperatingSystemVersionsGetCall {
37501	c := &OperatingSystemVersionsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
37502	c.profileId = profileId
37503	c.id = id
37504	return c
37505}
37506
37507// Fields allows partial responses to be retrieved. See
37508// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
37509// for more information.
37510func (c *OperatingSystemVersionsGetCall) Fields(s ...googleapi.Field) *OperatingSystemVersionsGetCall {
37511	c.urlParams_.Set("fields", googleapi.CombineFields(s))
37512	return c
37513}
37514
37515// IfNoneMatch sets the optional parameter which makes the operation
37516// fail if the object's ETag matches the given value. This is useful for
37517// getting updates only after the object has changed since the last
37518// request. Use googleapi.IsNotModified to check whether the response
37519// error from Do is the result of In-None-Match.
37520func (c *OperatingSystemVersionsGetCall) IfNoneMatch(entityTag string) *OperatingSystemVersionsGetCall {
37521	c.ifNoneMatch_ = entityTag
37522	return c
37523}
37524
37525// Context sets the context to be used in this call's Do method. Any
37526// pending HTTP request will be aborted if the provided context is
37527// canceled.
37528func (c *OperatingSystemVersionsGetCall) Context(ctx context.Context) *OperatingSystemVersionsGetCall {
37529	c.ctx_ = ctx
37530	return c
37531}
37532
37533// Header returns an http.Header that can be modified by the caller to
37534// add HTTP headers to the request.
37535func (c *OperatingSystemVersionsGetCall) Header() http.Header {
37536	if c.header_ == nil {
37537		c.header_ = make(http.Header)
37538	}
37539	return c.header_
37540}
37541
37542func (c *OperatingSystemVersionsGetCall) doRequest(alt string) (*http.Response, error) {
37543	reqHeaders := make(http.Header)
37544	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
37545	for k, v := range c.header_ {
37546		reqHeaders[k] = v
37547	}
37548	reqHeaders.Set("User-Agent", c.s.userAgent())
37549	if c.ifNoneMatch_ != "" {
37550		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
37551	}
37552	var body io.Reader = nil
37553	c.urlParams_.Set("alt", alt)
37554	c.urlParams_.Set("prettyPrint", "false")
37555	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/operatingSystemVersions/{id}")
37556	urls += "?" + c.urlParams_.Encode()
37557	req, err := http.NewRequest("GET", urls, body)
37558	if err != nil {
37559		return nil, err
37560	}
37561	req.Header = reqHeaders
37562	googleapi.Expand(req.URL, map[string]string{
37563		"profileId": strconv.FormatInt(c.profileId, 10),
37564		"id":        strconv.FormatInt(c.id, 10),
37565	})
37566	return gensupport.SendRequest(c.ctx_, c.s.client, req)
37567}
37568
37569// Do executes the "dfareporting.operatingSystemVersions.get" call.
37570// Exactly one of *OperatingSystemVersion or error will be non-nil. Any
37571// non-2xx status code is an error. Response headers are in either
37572// *OperatingSystemVersion.ServerResponse.Header or (if a response was
37573// returned at all) in error.(*googleapi.Error).Header. Use
37574// googleapi.IsNotModified to check whether the returned error was
37575// because http.StatusNotModified was returned.
37576func (c *OperatingSystemVersionsGetCall) Do(opts ...googleapi.CallOption) (*OperatingSystemVersion, error) {
37577	gensupport.SetOptions(c.urlParams_, opts...)
37578	res, err := c.doRequest("json")
37579	if res != nil && res.StatusCode == http.StatusNotModified {
37580		if res.Body != nil {
37581			res.Body.Close()
37582		}
37583		return nil, &googleapi.Error{
37584			Code:   res.StatusCode,
37585			Header: res.Header,
37586		}
37587	}
37588	if err != nil {
37589		return nil, err
37590	}
37591	defer googleapi.CloseBody(res)
37592	if err := googleapi.CheckResponse(res); err != nil {
37593		return nil, err
37594	}
37595	ret := &OperatingSystemVersion{
37596		ServerResponse: googleapi.ServerResponse{
37597			Header:         res.Header,
37598			HTTPStatusCode: res.StatusCode,
37599		},
37600	}
37601	target := &ret
37602	if err := gensupport.DecodeResponse(target, res); err != nil {
37603		return nil, err
37604	}
37605	return ret, nil
37606	// {
37607	//   "description": "Gets one operating system version by ID.",
37608	//   "flatPath": "userprofiles/{profileId}/operatingSystemVersions/{id}",
37609	//   "httpMethod": "GET",
37610	//   "id": "dfareporting.operatingSystemVersions.get",
37611	//   "parameterOrder": [
37612	//     "profileId",
37613	//     "id"
37614	//   ],
37615	//   "parameters": {
37616	//     "id": {
37617	//       "description": "Operating system version ID.",
37618	//       "format": "int64",
37619	//       "location": "path",
37620	//       "required": true,
37621	//       "type": "string"
37622	//     },
37623	//     "profileId": {
37624	//       "description": "User profile ID associated with this request.",
37625	//       "format": "int64",
37626	//       "location": "path",
37627	//       "required": true,
37628	//       "type": "string"
37629	//     }
37630	//   },
37631	//   "path": "userprofiles/{profileId}/operatingSystemVersions/{id}",
37632	//   "response": {
37633	//     "$ref": "OperatingSystemVersion"
37634	//   },
37635	//   "scopes": [
37636	//     "https://www.googleapis.com/auth/dfatrafficking"
37637	//   ]
37638	// }
37639
37640}
37641
37642// method id "dfareporting.operatingSystemVersions.list":
37643
37644type OperatingSystemVersionsListCall struct {
37645	s            *Service
37646	profileId    int64
37647	urlParams_   gensupport.URLParams
37648	ifNoneMatch_ string
37649	ctx_         context.Context
37650	header_      http.Header
37651}
37652
37653// List: Retrieves a list of operating system versions.
37654//
37655// - profileId: User profile ID associated with this request.
37656func (r *OperatingSystemVersionsService) List(profileId int64) *OperatingSystemVersionsListCall {
37657	c := &OperatingSystemVersionsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
37658	c.profileId = profileId
37659	return c
37660}
37661
37662// Fields allows partial responses to be retrieved. See
37663// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
37664// for more information.
37665func (c *OperatingSystemVersionsListCall) Fields(s ...googleapi.Field) *OperatingSystemVersionsListCall {
37666	c.urlParams_.Set("fields", googleapi.CombineFields(s))
37667	return c
37668}
37669
37670// IfNoneMatch sets the optional parameter which makes the operation
37671// fail if the object's ETag matches the given value. This is useful for
37672// getting updates only after the object has changed since the last
37673// request. Use googleapi.IsNotModified to check whether the response
37674// error from Do is the result of In-None-Match.
37675func (c *OperatingSystemVersionsListCall) IfNoneMatch(entityTag string) *OperatingSystemVersionsListCall {
37676	c.ifNoneMatch_ = entityTag
37677	return c
37678}
37679
37680// Context sets the context to be used in this call's Do method. Any
37681// pending HTTP request will be aborted if the provided context is
37682// canceled.
37683func (c *OperatingSystemVersionsListCall) Context(ctx context.Context) *OperatingSystemVersionsListCall {
37684	c.ctx_ = ctx
37685	return c
37686}
37687
37688// Header returns an http.Header that can be modified by the caller to
37689// add HTTP headers to the request.
37690func (c *OperatingSystemVersionsListCall) Header() http.Header {
37691	if c.header_ == nil {
37692		c.header_ = make(http.Header)
37693	}
37694	return c.header_
37695}
37696
37697func (c *OperatingSystemVersionsListCall) doRequest(alt string) (*http.Response, error) {
37698	reqHeaders := make(http.Header)
37699	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
37700	for k, v := range c.header_ {
37701		reqHeaders[k] = v
37702	}
37703	reqHeaders.Set("User-Agent", c.s.userAgent())
37704	if c.ifNoneMatch_ != "" {
37705		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
37706	}
37707	var body io.Reader = nil
37708	c.urlParams_.Set("alt", alt)
37709	c.urlParams_.Set("prettyPrint", "false")
37710	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/operatingSystemVersions")
37711	urls += "?" + c.urlParams_.Encode()
37712	req, err := http.NewRequest("GET", urls, body)
37713	if err != nil {
37714		return nil, err
37715	}
37716	req.Header = reqHeaders
37717	googleapi.Expand(req.URL, map[string]string{
37718		"profileId": strconv.FormatInt(c.profileId, 10),
37719	})
37720	return gensupport.SendRequest(c.ctx_, c.s.client, req)
37721}
37722
37723// Do executes the "dfareporting.operatingSystemVersions.list" call.
37724// Exactly one of *OperatingSystemVersionsListResponse or error will be
37725// non-nil. Any non-2xx status code is an error. Response headers are in
37726// either *OperatingSystemVersionsListResponse.ServerResponse.Header or
37727// (if a response was returned at all) in
37728// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
37729// whether the returned error was because http.StatusNotModified was
37730// returned.
37731func (c *OperatingSystemVersionsListCall) Do(opts ...googleapi.CallOption) (*OperatingSystemVersionsListResponse, error) {
37732	gensupport.SetOptions(c.urlParams_, opts...)
37733	res, err := c.doRequest("json")
37734	if res != nil && res.StatusCode == http.StatusNotModified {
37735		if res.Body != nil {
37736			res.Body.Close()
37737		}
37738		return nil, &googleapi.Error{
37739			Code:   res.StatusCode,
37740			Header: res.Header,
37741		}
37742	}
37743	if err != nil {
37744		return nil, err
37745	}
37746	defer googleapi.CloseBody(res)
37747	if err := googleapi.CheckResponse(res); err != nil {
37748		return nil, err
37749	}
37750	ret := &OperatingSystemVersionsListResponse{
37751		ServerResponse: googleapi.ServerResponse{
37752			Header:         res.Header,
37753			HTTPStatusCode: res.StatusCode,
37754		},
37755	}
37756	target := &ret
37757	if err := gensupport.DecodeResponse(target, res); err != nil {
37758		return nil, err
37759	}
37760	return ret, nil
37761	// {
37762	//   "description": "Retrieves a list of operating system versions.",
37763	//   "flatPath": "userprofiles/{profileId}/operatingSystemVersions",
37764	//   "httpMethod": "GET",
37765	//   "id": "dfareporting.operatingSystemVersions.list",
37766	//   "parameterOrder": [
37767	//     "profileId"
37768	//   ],
37769	//   "parameters": {
37770	//     "profileId": {
37771	//       "description": "User profile ID associated with this request.",
37772	//       "format": "int64",
37773	//       "location": "path",
37774	//       "required": true,
37775	//       "type": "string"
37776	//     }
37777	//   },
37778	//   "path": "userprofiles/{profileId}/operatingSystemVersions",
37779	//   "response": {
37780	//     "$ref": "OperatingSystemVersionsListResponse"
37781	//   },
37782	//   "scopes": [
37783	//     "https://www.googleapis.com/auth/dfatrafficking"
37784	//   ]
37785	// }
37786
37787}
37788
37789// method id "dfareporting.operatingSystems.get":
37790
37791type OperatingSystemsGetCall struct {
37792	s            *Service
37793	profileId    int64
37794	dartId       int64
37795	urlParams_   gensupport.URLParams
37796	ifNoneMatch_ string
37797	ctx_         context.Context
37798	header_      http.Header
37799}
37800
37801// Get: Gets one operating system by DART ID.
37802//
37803// - dartId: Operating system DART ID.
37804// - profileId: User profile ID associated with this request.
37805func (r *OperatingSystemsService) Get(profileId int64, dartId int64) *OperatingSystemsGetCall {
37806	c := &OperatingSystemsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
37807	c.profileId = profileId
37808	c.dartId = dartId
37809	return c
37810}
37811
37812// Fields allows partial responses to be retrieved. See
37813// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
37814// for more information.
37815func (c *OperatingSystemsGetCall) Fields(s ...googleapi.Field) *OperatingSystemsGetCall {
37816	c.urlParams_.Set("fields", googleapi.CombineFields(s))
37817	return c
37818}
37819
37820// IfNoneMatch sets the optional parameter which makes the operation
37821// fail if the object's ETag matches the given value. This is useful for
37822// getting updates only after the object has changed since the last
37823// request. Use googleapi.IsNotModified to check whether the response
37824// error from Do is the result of In-None-Match.
37825func (c *OperatingSystemsGetCall) IfNoneMatch(entityTag string) *OperatingSystemsGetCall {
37826	c.ifNoneMatch_ = entityTag
37827	return c
37828}
37829
37830// Context sets the context to be used in this call's Do method. Any
37831// pending HTTP request will be aborted if the provided context is
37832// canceled.
37833func (c *OperatingSystemsGetCall) Context(ctx context.Context) *OperatingSystemsGetCall {
37834	c.ctx_ = ctx
37835	return c
37836}
37837
37838// Header returns an http.Header that can be modified by the caller to
37839// add HTTP headers to the request.
37840func (c *OperatingSystemsGetCall) Header() http.Header {
37841	if c.header_ == nil {
37842		c.header_ = make(http.Header)
37843	}
37844	return c.header_
37845}
37846
37847func (c *OperatingSystemsGetCall) doRequest(alt string) (*http.Response, error) {
37848	reqHeaders := make(http.Header)
37849	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
37850	for k, v := range c.header_ {
37851		reqHeaders[k] = v
37852	}
37853	reqHeaders.Set("User-Agent", c.s.userAgent())
37854	if c.ifNoneMatch_ != "" {
37855		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
37856	}
37857	var body io.Reader = nil
37858	c.urlParams_.Set("alt", alt)
37859	c.urlParams_.Set("prettyPrint", "false")
37860	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/operatingSystems/{dartId}")
37861	urls += "?" + c.urlParams_.Encode()
37862	req, err := http.NewRequest("GET", urls, body)
37863	if err != nil {
37864		return nil, err
37865	}
37866	req.Header = reqHeaders
37867	googleapi.Expand(req.URL, map[string]string{
37868		"profileId": strconv.FormatInt(c.profileId, 10),
37869		"dartId":    strconv.FormatInt(c.dartId, 10),
37870	})
37871	return gensupport.SendRequest(c.ctx_, c.s.client, req)
37872}
37873
37874// Do executes the "dfareporting.operatingSystems.get" call.
37875// Exactly one of *OperatingSystem or error will be non-nil. Any non-2xx
37876// status code is an error. Response headers are in either
37877// *OperatingSystem.ServerResponse.Header or (if a response was returned
37878// at all) in error.(*googleapi.Error).Header. Use
37879// googleapi.IsNotModified to check whether the returned error was
37880// because http.StatusNotModified was returned.
37881func (c *OperatingSystemsGetCall) Do(opts ...googleapi.CallOption) (*OperatingSystem, error) {
37882	gensupport.SetOptions(c.urlParams_, opts...)
37883	res, err := c.doRequest("json")
37884	if res != nil && res.StatusCode == http.StatusNotModified {
37885		if res.Body != nil {
37886			res.Body.Close()
37887		}
37888		return nil, &googleapi.Error{
37889			Code:   res.StatusCode,
37890			Header: res.Header,
37891		}
37892	}
37893	if err != nil {
37894		return nil, err
37895	}
37896	defer googleapi.CloseBody(res)
37897	if err := googleapi.CheckResponse(res); err != nil {
37898		return nil, err
37899	}
37900	ret := &OperatingSystem{
37901		ServerResponse: googleapi.ServerResponse{
37902			Header:         res.Header,
37903			HTTPStatusCode: res.StatusCode,
37904		},
37905	}
37906	target := &ret
37907	if err := gensupport.DecodeResponse(target, res); err != nil {
37908		return nil, err
37909	}
37910	return ret, nil
37911	// {
37912	//   "description": "Gets one operating system by DART ID.",
37913	//   "flatPath": "userprofiles/{profileId}/operatingSystems/{dartId}",
37914	//   "httpMethod": "GET",
37915	//   "id": "dfareporting.operatingSystems.get",
37916	//   "parameterOrder": [
37917	//     "profileId",
37918	//     "dartId"
37919	//   ],
37920	//   "parameters": {
37921	//     "dartId": {
37922	//       "description": "Operating system DART ID.",
37923	//       "format": "int64",
37924	//       "location": "path",
37925	//       "required": true,
37926	//       "type": "string"
37927	//     },
37928	//     "profileId": {
37929	//       "description": "User profile ID associated with this request.",
37930	//       "format": "int64",
37931	//       "location": "path",
37932	//       "required": true,
37933	//       "type": "string"
37934	//     }
37935	//   },
37936	//   "path": "userprofiles/{profileId}/operatingSystems/{dartId}",
37937	//   "response": {
37938	//     "$ref": "OperatingSystem"
37939	//   },
37940	//   "scopes": [
37941	//     "https://www.googleapis.com/auth/dfatrafficking"
37942	//   ]
37943	// }
37944
37945}
37946
37947// method id "dfareporting.operatingSystems.list":
37948
37949type OperatingSystemsListCall struct {
37950	s            *Service
37951	profileId    int64
37952	urlParams_   gensupport.URLParams
37953	ifNoneMatch_ string
37954	ctx_         context.Context
37955	header_      http.Header
37956}
37957
37958// List: Retrieves a list of operating systems.
37959//
37960// - profileId: User profile ID associated with this request.
37961func (r *OperatingSystemsService) List(profileId int64) *OperatingSystemsListCall {
37962	c := &OperatingSystemsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
37963	c.profileId = profileId
37964	return c
37965}
37966
37967// Fields allows partial responses to be retrieved. See
37968// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
37969// for more information.
37970func (c *OperatingSystemsListCall) Fields(s ...googleapi.Field) *OperatingSystemsListCall {
37971	c.urlParams_.Set("fields", googleapi.CombineFields(s))
37972	return c
37973}
37974
37975// IfNoneMatch sets the optional parameter which makes the operation
37976// fail if the object's ETag matches the given value. This is useful for
37977// getting updates only after the object has changed since the last
37978// request. Use googleapi.IsNotModified to check whether the response
37979// error from Do is the result of In-None-Match.
37980func (c *OperatingSystemsListCall) IfNoneMatch(entityTag string) *OperatingSystemsListCall {
37981	c.ifNoneMatch_ = entityTag
37982	return c
37983}
37984
37985// Context sets the context to be used in this call's Do method. Any
37986// pending HTTP request will be aborted if the provided context is
37987// canceled.
37988func (c *OperatingSystemsListCall) Context(ctx context.Context) *OperatingSystemsListCall {
37989	c.ctx_ = ctx
37990	return c
37991}
37992
37993// Header returns an http.Header that can be modified by the caller to
37994// add HTTP headers to the request.
37995func (c *OperatingSystemsListCall) Header() http.Header {
37996	if c.header_ == nil {
37997		c.header_ = make(http.Header)
37998	}
37999	return c.header_
38000}
38001
38002func (c *OperatingSystemsListCall) doRequest(alt string) (*http.Response, error) {
38003	reqHeaders := make(http.Header)
38004	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
38005	for k, v := range c.header_ {
38006		reqHeaders[k] = v
38007	}
38008	reqHeaders.Set("User-Agent", c.s.userAgent())
38009	if c.ifNoneMatch_ != "" {
38010		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
38011	}
38012	var body io.Reader = nil
38013	c.urlParams_.Set("alt", alt)
38014	c.urlParams_.Set("prettyPrint", "false")
38015	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/operatingSystems")
38016	urls += "?" + c.urlParams_.Encode()
38017	req, err := http.NewRequest("GET", urls, body)
38018	if err != nil {
38019		return nil, err
38020	}
38021	req.Header = reqHeaders
38022	googleapi.Expand(req.URL, map[string]string{
38023		"profileId": strconv.FormatInt(c.profileId, 10),
38024	})
38025	return gensupport.SendRequest(c.ctx_, c.s.client, req)
38026}
38027
38028// Do executes the "dfareporting.operatingSystems.list" call.
38029// Exactly one of *OperatingSystemsListResponse or error will be
38030// non-nil. Any non-2xx status code is an error. Response headers are in
38031// either *OperatingSystemsListResponse.ServerResponse.Header or (if a
38032// response was returned at all) in error.(*googleapi.Error).Header. Use
38033// googleapi.IsNotModified to check whether the returned error was
38034// because http.StatusNotModified was returned.
38035func (c *OperatingSystemsListCall) Do(opts ...googleapi.CallOption) (*OperatingSystemsListResponse, error) {
38036	gensupport.SetOptions(c.urlParams_, opts...)
38037	res, err := c.doRequest("json")
38038	if res != nil && res.StatusCode == http.StatusNotModified {
38039		if res.Body != nil {
38040			res.Body.Close()
38041		}
38042		return nil, &googleapi.Error{
38043			Code:   res.StatusCode,
38044			Header: res.Header,
38045		}
38046	}
38047	if err != nil {
38048		return nil, err
38049	}
38050	defer googleapi.CloseBody(res)
38051	if err := googleapi.CheckResponse(res); err != nil {
38052		return nil, err
38053	}
38054	ret := &OperatingSystemsListResponse{
38055		ServerResponse: googleapi.ServerResponse{
38056			Header:         res.Header,
38057			HTTPStatusCode: res.StatusCode,
38058		},
38059	}
38060	target := &ret
38061	if err := gensupport.DecodeResponse(target, res); err != nil {
38062		return nil, err
38063	}
38064	return ret, nil
38065	// {
38066	//   "description": "Retrieves a list of operating systems.",
38067	//   "flatPath": "userprofiles/{profileId}/operatingSystems",
38068	//   "httpMethod": "GET",
38069	//   "id": "dfareporting.operatingSystems.list",
38070	//   "parameterOrder": [
38071	//     "profileId"
38072	//   ],
38073	//   "parameters": {
38074	//     "profileId": {
38075	//       "description": "User profile ID associated with this request.",
38076	//       "format": "int64",
38077	//       "location": "path",
38078	//       "required": true,
38079	//       "type": "string"
38080	//     }
38081	//   },
38082	//   "path": "userprofiles/{profileId}/operatingSystems",
38083	//   "response": {
38084	//     "$ref": "OperatingSystemsListResponse"
38085	//   },
38086	//   "scopes": [
38087	//     "https://www.googleapis.com/auth/dfatrafficking"
38088	//   ]
38089	// }
38090
38091}
38092
38093// method id "dfareporting.orderDocuments.get":
38094
38095type OrderDocumentsGetCall struct {
38096	s            *Service
38097	profileId    int64
38098	projectId    int64
38099	id           int64
38100	urlParams_   gensupport.URLParams
38101	ifNoneMatch_ string
38102	ctx_         context.Context
38103	header_      http.Header
38104}
38105
38106// Get: Gets one order document by ID.
38107//
38108// - id: Order document ID.
38109// - profileId: User profile ID associated with this request.
38110// - projectId: Project ID for order documents.
38111func (r *OrderDocumentsService) Get(profileId int64, projectId int64, id int64) *OrderDocumentsGetCall {
38112	c := &OrderDocumentsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
38113	c.profileId = profileId
38114	c.projectId = projectId
38115	c.id = id
38116	return c
38117}
38118
38119// Fields allows partial responses to be retrieved. See
38120// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
38121// for more information.
38122func (c *OrderDocumentsGetCall) Fields(s ...googleapi.Field) *OrderDocumentsGetCall {
38123	c.urlParams_.Set("fields", googleapi.CombineFields(s))
38124	return c
38125}
38126
38127// IfNoneMatch sets the optional parameter which makes the operation
38128// fail if the object's ETag matches the given value. This is useful for
38129// getting updates only after the object has changed since the last
38130// request. Use googleapi.IsNotModified to check whether the response
38131// error from Do is the result of In-None-Match.
38132func (c *OrderDocumentsGetCall) IfNoneMatch(entityTag string) *OrderDocumentsGetCall {
38133	c.ifNoneMatch_ = entityTag
38134	return c
38135}
38136
38137// Context sets the context to be used in this call's Do method. Any
38138// pending HTTP request will be aborted if the provided context is
38139// canceled.
38140func (c *OrderDocumentsGetCall) Context(ctx context.Context) *OrderDocumentsGetCall {
38141	c.ctx_ = ctx
38142	return c
38143}
38144
38145// Header returns an http.Header that can be modified by the caller to
38146// add HTTP headers to the request.
38147func (c *OrderDocumentsGetCall) Header() http.Header {
38148	if c.header_ == nil {
38149		c.header_ = make(http.Header)
38150	}
38151	return c.header_
38152}
38153
38154func (c *OrderDocumentsGetCall) doRequest(alt string) (*http.Response, error) {
38155	reqHeaders := make(http.Header)
38156	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
38157	for k, v := range c.header_ {
38158		reqHeaders[k] = v
38159	}
38160	reqHeaders.Set("User-Agent", c.s.userAgent())
38161	if c.ifNoneMatch_ != "" {
38162		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
38163	}
38164	var body io.Reader = nil
38165	c.urlParams_.Set("alt", alt)
38166	c.urlParams_.Set("prettyPrint", "false")
38167	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/projects/{projectId}/orderDocuments/{id}")
38168	urls += "?" + c.urlParams_.Encode()
38169	req, err := http.NewRequest("GET", urls, body)
38170	if err != nil {
38171		return nil, err
38172	}
38173	req.Header = reqHeaders
38174	googleapi.Expand(req.URL, map[string]string{
38175		"profileId": strconv.FormatInt(c.profileId, 10),
38176		"projectId": strconv.FormatInt(c.projectId, 10),
38177		"id":        strconv.FormatInt(c.id, 10),
38178	})
38179	return gensupport.SendRequest(c.ctx_, c.s.client, req)
38180}
38181
38182// Do executes the "dfareporting.orderDocuments.get" call.
38183// Exactly one of *OrderDocument or error will be non-nil. Any non-2xx
38184// status code is an error. Response headers are in either
38185// *OrderDocument.ServerResponse.Header or (if a response was returned
38186// at all) in error.(*googleapi.Error).Header. Use
38187// googleapi.IsNotModified to check whether the returned error was
38188// because http.StatusNotModified was returned.
38189func (c *OrderDocumentsGetCall) Do(opts ...googleapi.CallOption) (*OrderDocument, 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 := &OrderDocument{
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	//   "description": "Gets one order document by ID.",
38221	//   "flatPath": "userprofiles/{profileId}/projects/{projectId}/orderDocuments/{id}",
38222	//   "httpMethod": "GET",
38223	//   "id": "dfareporting.orderDocuments.get",
38224	//   "parameterOrder": [
38225	//     "profileId",
38226	//     "projectId",
38227	//     "id"
38228	//   ],
38229	//   "parameters": {
38230	//     "id": {
38231	//       "description": "Order document ID.",
38232	//       "format": "int64",
38233	//       "location": "path",
38234	//       "required": true,
38235	//       "type": "string"
38236	//     },
38237	//     "profileId": {
38238	//       "description": "User profile ID associated with this request.",
38239	//       "format": "int64",
38240	//       "location": "path",
38241	//       "required": true,
38242	//       "type": "string"
38243	//     },
38244	//     "projectId": {
38245	//       "description": "Project ID for order documents.",
38246	//       "format": "int64",
38247	//       "location": "path",
38248	//       "required": true,
38249	//       "type": "string"
38250	//     }
38251	//   },
38252	//   "path": "userprofiles/{profileId}/projects/{projectId}/orderDocuments/{id}",
38253	//   "response": {
38254	//     "$ref": "OrderDocument"
38255	//   },
38256	//   "scopes": [
38257	//     "https://www.googleapis.com/auth/dfatrafficking"
38258	//   ]
38259	// }
38260
38261}
38262
38263// method id "dfareporting.orderDocuments.list":
38264
38265type OrderDocumentsListCall struct {
38266	s            *Service
38267	profileId    int64
38268	projectId    int64
38269	urlParams_   gensupport.URLParams
38270	ifNoneMatch_ string
38271	ctx_         context.Context
38272	header_      http.Header
38273}
38274
38275// List: Retrieves a list of order documents, possibly filtered. This
38276// method supports paging.
38277//
38278// - profileId: User profile ID associated with this request.
38279// - projectId: Project ID for order documents.
38280func (r *OrderDocumentsService) List(profileId int64, projectId int64) *OrderDocumentsListCall {
38281	c := &OrderDocumentsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
38282	c.profileId = profileId
38283	c.projectId = projectId
38284	return c
38285}
38286
38287// Approved sets the optional parameter "approved": Select only order
38288// documents that have been approved by at least one user.
38289func (c *OrderDocumentsListCall) Approved(approved bool) *OrderDocumentsListCall {
38290	c.urlParams_.Set("approved", fmt.Sprint(approved))
38291	return c
38292}
38293
38294// Ids sets the optional parameter "ids": Select only order documents
38295// with these IDs.
38296func (c *OrderDocumentsListCall) Ids(ids ...int64) *OrderDocumentsListCall {
38297	var ids_ []string
38298	for _, v := range ids {
38299		ids_ = append(ids_, fmt.Sprint(v))
38300	}
38301	c.urlParams_.SetMulti("ids", ids_)
38302	return c
38303}
38304
38305// MaxResults sets the optional parameter "maxResults": Maximum number
38306// of results to return.
38307func (c *OrderDocumentsListCall) MaxResults(maxResults int64) *OrderDocumentsListCall {
38308	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
38309	return c
38310}
38311
38312// OrderId sets the optional parameter "orderId": Select only order
38313// documents for specified orders.
38314func (c *OrderDocumentsListCall) OrderId(orderId ...int64) *OrderDocumentsListCall {
38315	var orderId_ []string
38316	for _, v := range orderId {
38317		orderId_ = append(orderId_, fmt.Sprint(v))
38318	}
38319	c.urlParams_.SetMulti("orderId", orderId_)
38320	return c
38321}
38322
38323// PageToken sets the optional parameter "pageToken": Value of the
38324// nextPageToken from the previous result page.
38325func (c *OrderDocumentsListCall) PageToken(pageToken string) *OrderDocumentsListCall {
38326	c.urlParams_.Set("pageToken", pageToken)
38327	return c
38328}
38329
38330// SearchString sets the optional parameter "searchString": Allows
38331// searching for order documents by name or ID. Wildcards (*) are
38332// allowed. For example, "orderdocument*2015" will return order
38333// documents with names like "orderdocument June 2015", "orderdocument
38334// April 2015", or simply "orderdocument 2015". Most of the searches
38335// also add wildcards implicitly at the start and the end of the search
38336// string. For example, a search string of "orderdocument" will match
38337// order documents with name "my orderdocument", "orderdocument 2015",
38338// or simply "orderdocument".
38339func (c *OrderDocumentsListCall) SearchString(searchString string) *OrderDocumentsListCall {
38340	c.urlParams_.Set("searchString", searchString)
38341	return c
38342}
38343
38344// SiteId sets the optional parameter "siteId": Select only order
38345// documents that are associated with these sites.
38346func (c *OrderDocumentsListCall) SiteId(siteId ...int64) *OrderDocumentsListCall {
38347	var siteId_ []string
38348	for _, v := range siteId {
38349		siteId_ = append(siteId_, fmt.Sprint(v))
38350	}
38351	c.urlParams_.SetMulti("siteId", siteId_)
38352	return c
38353}
38354
38355// SortField sets the optional parameter "sortField": Field by which to
38356// sort the list.
38357//
38358// Possible values:
38359//   "ID" (default)
38360//   "NAME"
38361func (c *OrderDocumentsListCall) SortField(sortField string) *OrderDocumentsListCall {
38362	c.urlParams_.Set("sortField", sortField)
38363	return c
38364}
38365
38366// SortOrder sets the optional parameter "sortOrder": Order of sorted
38367// results.
38368//
38369// Possible values:
38370//   "ASCENDING" (default)
38371//   "DESCENDING"
38372func (c *OrderDocumentsListCall) SortOrder(sortOrder string) *OrderDocumentsListCall {
38373	c.urlParams_.Set("sortOrder", sortOrder)
38374	return c
38375}
38376
38377// Fields allows partial responses to be retrieved. See
38378// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
38379// for more information.
38380func (c *OrderDocumentsListCall) Fields(s ...googleapi.Field) *OrderDocumentsListCall {
38381	c.urlParams_.Set("fields", googleapi.CombineFields(s))
38382	return c
38383}
38384
38385// IfNoneMatch sets the optional parameter which makes the operation
38386// fail if the object's ETag matches the given value. This is useful for
38387// getting updates only after the object has changed since the last
38388// request. Use googleapi.IsNotModified to check whether the response
38389// error from Do is the result of In-None-Match.
38390func (c *OrderDocumentsListCall) IfNoneMatch(entityTag string) *OrderDocumentsListCall {
38391	c.ifNoneMatch_ = entityTag
38392	return c
38393}
38394
38395// Context sets the context to be used in this call's Do method. Any
38396// pending HTTP request will be aborted if the provided context is
38397// canceled.
38398func (c *OrderDocumentsListCall) Context(ctx context.Context) *OrderDocumentsListCall {
38399	c.ctx_ = ctx
38400	return c
38401}
38402
38403// Header returns an http.Header that can be modified by the caller to
38404// add HTTP headers to the request.
38405func (c *OrderDocumentsListCall) Header() http.Header {
38406	if c.header_ == nil {
38407		c.header_ = make(http.Header)
38408	}
38409	return c.header_
38410}
38411
38412func (c *OrderDocumentsListCall) doRequest(alt string) (*http.Response, error) {
38413	reqHeaders := make(http.Header)
38414	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
38415	for k, v := range c.header_ {
38416		reqHeaders[k] = v
38417	}
38418	reqHeaders.Set("User-Agent", c.s.userAgent())
38419	if c.ifNoneMatch_ != "" {
38420		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
38421	}
38422	var body io.Reader = nil
38423	c.urlParams_.Set("alt", alt)
38424	c.urlParams_.Set("prettyPrint", "false")
38425	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/projects/{projectId}/orderDocuments")
38426	urls += "?" + c.urlParams_.Encode()
38427	req, err := http.NewRequest("GET", urls, body)
38428	if err != nil {
38429		return nil, err
38430	}
38431	req.Header = reqHeaders
38432	googleapi.Expand(req.URL, map[string]string{
38433		"profileId": strconv.FormatInt(c.profileId, 10),
38434		"projectId": strconv.FormatInt(c.projectId, 10),
38435	})
38436	return gensupport.SendRequest(c.ctx_, c.s.client, req)
38437}
38438
38439// Do executes the "dfareporting.orderDocuments.list" call.
38440// Exactly one of *OrderDocumentsListResponse or error will be non-nil.
38441// Any non-2xx status code is an error. Response headers are in either
38442// *OrderDocumentsListResponse.ServerResponse.Header or (if a response
38443// was returned at all) in error.(*googleapi.Error).Header. Use
38444// googleapi.IsNotModified to check whether the returned error was
38445// because http.StatusNotModified was returned.
38446func (c *OrderDocumentsListCall) Do(opts ...googleapi.CallOption) (*OrderDocumentsListResponse, error) {
38447	gensupport.SetOptions(c.urlParams_, opts...)
38448	res, err := c.doRequest("json")
38449	if res != nil && res.StatusCode == http.StatusNotModified {
38450		if res.Body != nil {
38451			res.Body.Close()
38452		}
38453		return nil, &googleapi.Error{
38454			Code:   res.StatusCode,
38455			Header: res.Header,
38456		}
38457	}
38458	if err != nil {
38459		return nil, err
38460	}
38461	defer googleapi.CloseBody(res)
38462	if err := googleapi.CheckResponse(res); err != nil {
38463		return nil, err
38464	}
38465	ret := &OrderDocumentsListResponse{
38466		ServerResponse: googleapi.ServerResponse{
38467			Header:         res.Header,
38468			HTTPStatusCode: res.StatusCode,
38469		},
38470	}
38471	target := &ret
38472	if err := gensupport.DecodeResponse(target, res); err != nil {
38473		return nil, err
38474	}
38475	return ret, nil
38476	// {
38477	//   "description": "Retrieves a list of order documents, possibly filtered. This method supports paging.",
38478	//   "flatPath": "userprofiles/{profileId}/projects/{projectId}/orderDocuments",
38479	//   "httpMethod": "GET",
38480	//   "id": "dfareporting.orderDocuments.list",
38481	//   "parameterOrder": [
38482	//     "profileId",
38483	//     "projectId"
38484	//   ],
38485	//   "parameters": {
38486	//     "approved": {
38487	//       "description": "Select only order documents that have been approved by at least one user.",
38488	//       "location": "query",
38489	//       "type": "boolean"
38490	//     },
38491	//     "ids": {
38492	//       "description": "Select only order documents with these IDs.",
38493	//       "format": "int64",
38494	//       "location": "query",
38495	//       "repeated": true,
38496	//       "type": "string"
38497	//     },
38498	//     "maxResults": {
38499	//       "default": "1000",
38500	//       "description": "Maximum number of results to return.",
38501	//       "format": "int32",
38502	//       "location": "query",
38503	//       "maximum": "1000",
38504	//       "minimum": "0",
38505	//       "type": "integer"
38506	//     },
38507	//     "orderId": {
38508	//       "description": "Select only order documents for specified orders.",
38509	//       "format": "int64",
38510	//       "location": "query",
38511	//       "repeated": true,
38512	//       "type": "string"
38513	//     },
38514	//     "pageToken": {
38515	//       "description": "Value of the nextPageToken from the previous result page.",
38516	//       "location": "query",
38517	//       "type": "string"
38518	//     },
38519	//     "profileId": {
38520	//       "description": "User profile ID associated with this request.",
38521	//       "format": "int64",
38522	//       "location": "path",
38523	//       "required": true,
38524	//       "type": "string"
38525	//     },
38526	//     "projectId": {
38527	//       "description": "Project ID for order documents.",
38528	//       "format": "int64",
38529	//       "location": "path",
38530	//       "required": true,
38531	//       "type": "string"
38532	//     },
38533	//     "searchString": {
38534	//       "description": "Allows searching for order documents by name or ID. Wildcards (*) are allowed. For example, \"orderdocument*2015\" will return order documents with names like \"orderdocument June 2015\", \"orderdocument April 2015\", or simply \"orderdocument 2015\". Most of the searches also add wildcards implicitly at the start and the end of the search string. For example, a search string of \"orderdocument\" will match order documents with name \"my orderdocument\", \"orderdocument 2015\", or simply \"orderdocument\".",
38535	//       "location": "query",
38536	//       "type": "string"
38537	//     },
38538	//     "siteId": {
38539	//       "description": "Select only order documents that are associated with these sites.",
38540	//       "format": "int64",
38541	//       "location": "query",
38542	//       "repeated": true,
38543	//       "type": "string"
38544	//     },
38545	//     "sortField": {
38546	//       "default": "ID",
38547	//       "description": "Field by which to sort the list.",
38548	//       "enum": [
38549	//         "ID",
38550	//         "NAME"
38551	//       ],
38552	//       "enumDescriptions": [
38553	//         "",
38554	//         ""
38555	//       ],
38556	//       "location": "query",
38557	//       "type": "string"
38558	//     },
38559	//     "sortOrder": {
38560	//       "default": "ASCENDING",
38561	//       "description": "Order of sorted results.",
38562	//       "enum": [
38563	//         "ASCENDING",
38564	//         "DESCENDING"
38565	//       ],
38566	//       "enumDescriptions": [
38567	//         "",
38568	//         ""
38569	//       ],
38570	//       "location": "query",
38571	//       "type": "string"
38572	//     }
38573	//   },
38574	//   "path": "userprofiles/{profileId}/projects/{projectId}/orderDocuments",
38575	//   "response": {
38576	//     "$ref": "OrderDocumentsListResponse"
38577	//   },
38578	//   "scopes": [
38579	//     "https://www.googleapis.com/auth/dfatrafficking"
38580	//   ]
38581	// }
38582
38583}
38584
38585// Pages invokes f for each page of results.
38586// A non-nil error returned from f will halt the iteration.
38587// The provided context supersedes any context provided to the Context method.
38588func (c *OrderDocumentsListCall) Pages(ctx context.Context, f func(*OrderDocumentsListResponse) error) error {
38589	c.ctx_ = ctx
38590	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
38591	for {
38592		x, err := c.Do()
38593		if err != nil {
38594			return err
38595		}
38596		if err := f(x); err != nil {
38597			return err
38598		}
38599		if x.NextPageToken == "" {
38600			return nil
38601		}
38602		c.PageToken(x.NextPageToken)
38603	}
38604}
38605
38606// method id "dfareporting.orders.get":
38607
38608type OrdersGetCall struct {
38609	s            *Service
38610	profileId    int64
38611	projectId    int64
38612	id           int64
38613	urlParams_   gensupport.URLParams
38614	ifNoneMatch_ string
38615	ctx_         context.Context
38616	header_      http.Header
38617}
38618
38619// Get: Gets one order by ID.
38620//
38621// - id: Order ID.
38622// - profileId: User profile ID associated with this request.
38623// - projectId: Project ID for orders.
38624func (r *OrdersService) Get(profileId int64, projectId int64, id int64) *OrdersGetCall {
38625	c := &OrdersGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
38626	c.profileId = profileId
38627	c.projectId = projectId
38628	c.id = id
38629	return c
38630}
38631
38632// Fields allows partial responses to be retrieved. See
38633// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
38634// for more information.
38635func (c *OrdersGetCall) Fields(s ...googleapi.Field) *OrdersGetCall {
38636	c.urlParams_.Set("fields", googleapi.CombineFields(s))
38637	return c
38638}
38639
38640// IfNoneMatch sets the optional parameter which makes the operation
38641// fail if the object's ETag matches the given value. This is useful for
38642// getting updates only after the object has changed since the last
38643// request. Use googleapi.IsNotModified to check whether the response
38644// error from Do is the result of In-None-Match.
38645func (c *OrdersGetCall) IfNoneMatch(entityTag string) *OrdersGetCall {
38646	c.ifNoneMatch_ = entityTag
38647	return c
38648}
38649
38650// Context sets the context to be used in this call's Do method. Any
38651// pending HTTP request will be aborted if the provided context is
38652// canceled.
38653func (c *OrdersGetCall) Context(ctx context.Context) *OrdersGetCall {
38654	c.ctx_ = ctx
38655	return c
38656}
38657
38658// Header returns an http.Header that can be modified by the caller to
38659// add HTTP headers to the request.
38660func (c *OrdersGetCall) Header() http.Header {
38661	if c.header_ == nil {
38662		c.header_ = make(http.Header)
38663	}
38664	return c.header_
38665}
38666
38667func (c *OrdersGetCall) doRequest(alt string) (*http.Response, error) {
38668	reqHeaders := make(http.Header)
38669	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
38670	for k, v := range c.header_ {
38671		reqHeaders[k] = v
38672	}
38673	reqHeaders.Set("User-Agent", c.s.userAgent())
38674	if c.ifNoneMatch_ != "" {
38675		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
38676	}
38677	var body io.Reader = nil
38678	c.urlParams_.Set("alt", alt)
38679	c.urlParams_.Set("prettyPrint", "false")
38680	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/projects/{projectId}/orders/{id}")
38681	urls += "?" + c.urlParams_.Encode()
38682	req, err := http.NewRequest("GET", urls, body)
38683	if err != nil {
38684		return nil, err
38685	}
38686	req.Header = reqHeaders
38687	googleapi.Expand(req.URL, map[string]string{
38688		"profileId": strconv.FormatInt(c.profileId, 10),
38689		"projectId": strconv.FormatInt(c.projectId, 10),
38690		"id":        strconv.FormatInt(c.id, 10),
38691	})
38692	return gensupport.SendRequest(c.ctx_, c.s.client, req)
38693}
38694
38695// Do executes the "dfareporting.orders.get" call.
38696// Exactly one of *Order or error will be non-nil. Any non-2xx status
38697// code is an error. Response headers are in either
38698// *Order.ServerResponse.Header or (if a response was returned at all)
38699// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to
38700// check whether the returned error was because http.StatusNotModified
38701// was returned.
38702func (c *OrdersGetCall) Do(opts ...googleapi.CallOption) (*Order, error) {
38703	gensupport.SetOptions(c.urlParams_, opts...)
38704	res, err := c.doRequest("json")
38705	if res != nil && res.StatusCode == http.StatusNotModified {
38706		if res.Body != nil {
38707			res.Body.Close()
38708		}
38709		return nil, &googleapi.Error{
38710			Code:   res.StatusCode,
38711			Header: res.Header,
38712		}
38713	}
38714	if err != nil {
38715		return nil, err
38716	}
38717	defer googleapi.CloseBody(res)
38718	if err := googleapi.CheckResponse(res); err != nil {
38719		return nil, err
38720	}
38721	ret := &Order{
38722		ServerResponse: googleapi.ServerResponse{
38723			Header:         res.Header,
38724			HTTPStatusCode: res.StatusCode,
38725		},
38726	}
38727	target := &ret
38728	if err := gensupport.DecodeResponse(target, res); err != nil {
38729		return nil, err
38730	}
38731	return ret, nil
38732	// {
38733	//   "description": "Gets one order by ID.",
38734	//   "flatPath": "userprofiles/{profileId}/projects/{projectId}/orders/{id}",
38735	//   "httpMethod": "GET",
38736	//   "id": "dfareporting.orders.get",
38737	//   "parameterOrder": [
38738	//     "profileId",
38739	//     "projectId",
38740	//     "id"
38741	//   ],
38742	//   "parameters": {
38743	//     "id": {
38744	//       "description": "Order ID.",
38745	//       "format": "int64",
38746	//       "location": "path",
38747	//       "required": true,
38748	//       "type": "string"
38749	//     },
38750	//     "profileId": {
38751	//       "description": "User profile ID associated with this request.",
38752	//       "format": "int64",
38753	//       "location": "path",
38754	//       "required": true,
38755	//       "type": "string"
38756	//     },
38757	//     "projectId": {
38758	//       "description": "Project ID for orders.",
38759	//       "format": "int64",
38760	//       "location": "path",
38761	//       "required": true,
38762	//       "type": "string"
38763	//     }
38764	//   },
38765	//   "path": "userprofiles/{profileId}/projects/{projectId}/orders/{id}",
38766	//   "response": {
38767	//     "$ref": "Order"
38768	//   },
38769	//   "scopes": [
38770	//     "https://www.googleapis.com/auth/dfatrafficking"
38771	//   ]
38772	// }
38773
38774}
38775
38776// method id "dfareporting.orders.list":
38777
38778type OrdersListCall struct {
38779	s            *Service
38780	profileId    int64
38781	projectId    int64
38782	urlParams_   gensupport.URLParams
38783	ifNoneMatch_ string
38784	ctx_         context.Context
38785	header_      http.Header
38786}
38787
38788// List: Retrieves a list of orders, possibly filtered. This method
38789// supports paging.
38790//
38791// - profileId: User profile ID associated with this request.
38792// - projectId: Project ID for orders.
38793func (r *OrdersService) List(profileId int64, projectId int64) *OrdersListCall {
38794	c := &OrdersListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
38795	c.profileId = profileId
38796	c.projectId = projectId
38797	return c
38798}
38799
38800// Ids sets the optional parameter "ids": Select only orders with these
38801// IDs.
38802func (c *OrdersListCall) Ids(ids ...int64) *OrdersListCall {
38803	var ids_ []string
38804	for _, v := range ids {
38805		ids_ = append(ids_, fmt.Sprint(v))
38806	}
38807	c.urlParams_.SetMulti("ids", ids_)
38808	return c
38809}
38810
38811// MaxResults sets the optional parameter "maxResults": Maximum number
38812// of results to return.
38813func (c *OrdersListCall) MaxResults(maxResults int64) *OrdersListCall {
38814	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
38815	return c
38816}
38817
38818// PageToken sets the optional parameter "pageToken": Value of the
38819// nextPageToken from the previous result page.
38820func (c *OrdersListCall) PageToken(pageToken string) *OrdersListCall {
38821	c.urlParams_.Set("pageToken", pageToken)
38822	return c
38823}
38824
38825// SearchString sets the optional parameter "searchString": Allows
38826// searching for orders by name or ID. Wildcards (*) are allowed. For
38827// example, "order*2015" will return orders with names like "order June
38828// 2015", "order April 2015", or simply "order 2015". Most of the
38829// searches also add wildcards implicitly at the start and the end of
38830// the search string. For example, a search string of "order" will match
38831// orders with name "my order", "order 2015", or simply "order".
38832func (c *OrdersListCall) SearchString(searchString string) *OrdersListCall {
38833	c.urlParams_.Set("searchString", searchString)
38834	return c
38835}
38836
38837// SiteId sets the optional parameter "siteId": Select only orders that
38838// are associated with these site IDs.
38839func (c *OrdersListCall) SiteId(siteId ...int64) *OrdersListCall {
38840	var siteId_ []string
38841	for _, v := range siteId {
38842		siteId_ = append(siteId_, fmt.Sprint(v))
38843	}
38844	c.urlParams_.SetMulti("siteId", siteId_)
38845	return c
38846}
38847
38848// SortField sets the optional parameter "sortField": Field by which to
38849// sort the list.
38850//
38851// Possible values:
38852//   "ID" (default)
38853//   "NAME"
38854func (c *OrdersListCall) SortField(sortField string) *OrdersListCall {
38855	c.urlParams_.Set("sortField", sortField)
38856	return c
38857}
38858
38859// SortOrder sets the optional parameter "sortOrder": Order of sorted
38860// results.
38861//
38862// Possible values:
38863//   "ASCENDING" (default)
38864//   "DESCENDING"
38865func (c *OrdersListCall) SortOrder(sortOrder string) *OrdersListCall {
38866	c.urlParams_.Set("sortOrder", sortOrder)
38867	return c
38868}
38869
38870// Fields allows partial responses to be retrieved. See
38871// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
38872// for more information.
38873func (c *OrdersListCall) Fields(s ...googleapi.Field) *OrdersListCall {
38874	c.urlParams_.Set("fields", googleapi.CombineFields(s))
38875	return c
38876}
38877
38878// IfNoneMatch sets the optional parameter which makes the operation
38879// fail if the object's ETag matches the given value. This is useful for
38880// getting updates only after the object has changed since the last
38881// request. Use googleapi.IsNotModified to check whether the response
38882// error from Do is the result of In-None-Match.
38883func (c *OrdersListCall) IfNoneMatch(entityTag string) *OrdersListCall {
38884	c.ifNoneMatch_ = entityTag
38885	return c
38886}
38887
38888// Context sets the context to be used in this call's Do method. Any
38889// pending HTTP request will be aborted if the provided context is
38890// canceled.
38891func (c *OrdersListCall) Context(ctx context.Context) *OrdersListCall {
38892	c.ctx_ = ctx
38893	return c
38894}
38895
38896// Header returns an http.Header that can be modified by the caller to
38897// add HTTP headers to the request.
38898func (c *OrdersListCall) Header() http.Header {
38899	if c.header_ == nil {
38900		c.header_ = make(http.Header)
38901	}
38902	return c.header_
38903}
38904
38905func (c *OrdersListCall) doRequest(alt string) (*http.Response, error) {
38906	reqHeaders := make(http.Header)
38907	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
38908	for k, v := range c.header_ {
38909		reqHeaders[k] = v
38910	}
38911	reqHeaders.Set("User-Agent", c.s.userAgent())
38912	if c.ifNoneMatch_ != "" {
38913		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
38914	}
38915	var body io.Reader = nil
38916	c.urlParams_.Set("alt", alt)
38917	c.urlParams_.Set("prettyPrint", "false")
38918	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/projects/{projectId}/orders")
38919	urls += "?" + c.urlParams_.Encode()
38920	req, err := http.NewRequest("GET", urls, body)
38921	if err != nil {
38922		return nil, err
38923	}
38924	req.Header = reqHeaders
38925	googleapi.Expand(req.URL, map[string]string{
38926		"profileId": strconv.FormatInt(c.profileId, 10),
38927		"projectId": strconv.FormatInt(c.projectId, 10),
38928	})
38929	return gensupport.SendRequest(c.ctx_, c.s.client, req)
38930}
38931
38932// Do executes the "dfareporting.orders.list" call.
38933// Exactly one of *OrdersListResponse or error will be non-nil. Any
38934// non-2xx status code is an error. Response headers are in either
38935// *OrdersListResponse.ServerResponse.Header or (if a response was
38936// returned at all) in error.(*googleapi.Error).Header. Use
38937// googleapi.IsNotModified to check whether the returned error was
38938// because http.StatusNotModified was returned.
38939func (c *OrdersListCall) Do(opts ...googleapi.CallOption) (*OrdersListResponse, error) {
38940	gensupport.SetOptions(c.urlParams_, opts...)
38941	res, err := c.doRequest("json")
38942	if res != nil && res.StatusCode == http.StatusNotModified {
38943		if res.Body != nil {
38944			res.Body.Close()
38945		}
38946		return nil, &googleapi.Error{
38947			Code:   res.StatusCode,
38948			Header: res.Header,
38949		}
38950	}
38951	if err != nil {
38952		return nil, err
38953	}
38954	defer googleapi.CloseBody(res)
38955	if err := googleapi.CheckResponse(res); err != nil {
38956		return nil, err
38957	}
38958	ret := &OrdersListResponse{
38959		ServerResponse: googleapi.ServerResponse{
38960			Header:         res.Header,
38961			HTTPStatusCode: res.StatusCode,
38962		},
38963	}
38964	target := &ret
38965	if err := gensupport.DecodeResponse(target, res); err != nil {
38966		return nil, err
38967	}
38968	return ret, nil
38969	// {
38970	//   "description": "Retrieves a list of orders, possibly filtered. This method supports paging.",
38971	//   "flatPath": "userprofiles/{profileId}/projects/{projectId}/orders",
38972	//   "httpMethod": "GET",
38973	//   "id": "dfareporting.orders.list",
38974	//   "parameterOrder": [
38975	//     "profileId",
38976	//     "projectId"
38977	//   ],
38978	//   "parameters": {
38979	//     "ids": {
38980	//       "description": "Select only orders with these IDs.",
38981	//       "format": "int64",
38982	//       "location": "query",
38983	//       "repeated": true,
38984	//       "type": "string"
38985	//     },
38986	//     "maxResults": {
38987	//       "default": "1000",
38988	//       "description": "Maximum number of results to return.",
38989	//       "format": "int32",
38990	//       "location": "query",
38991	//       "maximum": "1000",
38992	//       "minimum": "0",
38993	//       "type": "integer"
38994	//     },
38995	//     "pageToken": {
38996	//       "description": "Value of the nextPageToken from the previous result page.",
38997	//       "location": "query",
38998	//       "type": "string"
38999	//     },
39000	//     "profileId": {
39001	//       "description": "User profile ID associated with this request.",
39002	//       "format": "int64",
39003	//       "location": "path",
39004	//       "required": true,
39005	//       "type": "string"
39006	//     },
39007	//     "projectId": {
39008	//       "description": "Project ID for orders.",
39009	//       "format": "int64",
39010	//       "location": "path",
39011	//       "required": true,
39012	//       "type": "string"
39013	//     },
39014	//     "searchString": {
39015	//       "description": "Allows searching for orders by name or ID. Wildcards (*) are allowed. For example, \"order*2015\" will return orders with names like \"order June 2015\", \"order April 2015\", or simply \"order 2015\". Most of the searches also add wildcards implicitly at the start and the end of the search string. For example, a search string of \"order\" will match orders with name \"my order\", \"order 2015\", or simply \"order\".",
39016	//       "location": "query",
39017	//       "type": "string"
39018	//     },
39019	//     "siteId": {
39020	//       "description": "Select only orders that are associated with these site IDs.",
39021	//       "format": "int64",
39022	//       "location": "query",
39023	//       "repeated": true,
39024	//       "type": "string"
39025	//     },
39026	//     "sortField": {
39027	//       "default": "ID",
39028	//       "description": "Field by which to sort the list.",
39029	//       "enum": [
39030	//         "ID",
39031	//         "NAME"
39032	//       ],
39033	//       "enumDescriptions": [
39034	//         "",
39035	//         ""
39036	//       ],
39037	//       "location": "query",
39038	//       "type": "string"
39039	//     },
39040	//     "sortOrder": {
39041	//       "default": "ASCENDING",
39042	//       "description": "Order of sorted results.",
39043	//       "enum": [
39044	//         "ASCENDING",
39045	//         "DESCENDING"
39046	//       ],
39047	//       "enumDescriptions": [
39048	//         "",
39049	//         ""
39050	//       ],
39051	//       "location": "query",
39052	//       "type": "string"
39053	//     }
39054	//   },
39055	//   "path": "userprofiles/{profileId}/projects/{projectId}/orders",
39056	//   "response": {
39057	//     "$ref": "OrdersListResponse"
39058	//   },
39059	//   "scopes": [
39060	//     "https://www.googleapis.com/auth/dfatrafficking"
39061	//   ]
39062	// }
39063
39064}
39065
39066// Pages invokes f for each page of results.
39067// A non-nil error returned from f will halt the iteration.
39068// The provided context supersedes any context provided to the Context method.
39069func (c *OrdersListCall) Pages(ctx context.Context, f func(*OrdersListResponse) error) error {
39070	c.ctx_ = ctx
39071	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
39072	for {
39073		x, err := c.Do()
39074		if err != nil {
39075			return err
39076		}
39077		if err := f(x); err != nil {
39078			return err
39079		}
39080		if x.NextPageToken == "" {
39081			return nil
39082		}
39083		c.PageToken(x.NextPageToken)
39084	}
39085}
39086
39087// method id "dfareporting.placementGroups.get":
39088
39089type PlacementGroupsGetCall struct {
39090	s            *Service
39091	profileId    int64
39092	id           int64
39093	urlParams_   gensupport.URLParams
39094	ifNoneMatch_ string
39095	ctx_         context.Context
39096	header_      http.Header
39097}
39098
39099// Get: Gets one placement group by ID.
39100//
39101// - id: Placement group ID.
39102// - profileId: User profile ID associated with this request.
39103func (r *PlacementGroupsService) Get(profileId int64, id int64) *PlacementGroupsGetCall {
39104	c := &PlacementGroupsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
39105	c.profileId = profileId
39106	c.id = id
39107	return c
39108}
39109
39110// Fields allows partial responses to be retrieved. See
39111// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
39112// for more information.
39113func (c *PlacementGroupsGetCall) Fields(s ...googleapi.Field) *PlacementGroupsGetCall {
39114	c.urlParams_.Set("fields", googleapi.CombineFields(s))
39115	return c
39116}
39117
39118// IfNoneMatch sets the optional parameter which makes the operation
39119// fail if the object's ETag matches the given value. This is useful for
39120// getting updates only after the object has changed since the last
39121// request. Use googleapi.IsNotModified to check whether the response
39122// error from Do is the result of In-None-Match.
39123func (c *PlacementGroupsGetCall) IfNoneMatch(entityTag string) *PlacementGroupsGetCall {
39124	c.ifNoneMatch_ = entityTag
39125	return c
39126}
39127
39128// Context sets the context to be used in this call's Do method. Any
39129// pending HTTP request will be aborted if the provided context is
39130// canceled.
39131func (c *PlacementGroupsGetCall) Context(ctx context.Context) *PlacementGroupsGetCall {
39132	c.ctx_ = ctx
39133	return c
39134}
39135
39136// Header returns an http.Header that can be modified by the caller to
39137// add HTTP headers to the request.
39138func (c *PlacementGroupsGetCall) Header() http.Header {
39139	if c.header_ == nil {
39140		c.header_ = make(http.Header)
39141	}
39142	return c.header_
39143}
39144
39145func (c *PlacementGroupsGetCall) doRequest(alt string) (*http.Response, error) {
39146	reqHeaders := make(http.Header)
39147	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
39148	for k, v := range c.header_ {
39149		reqHeaders[k] = v
39150	}
39151	reqHeaders.Set("User-Agent", c.s.userAgent())
39152	if c.ifNoneMatch_ != "" {
39153		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
39154	}
39155	var body io.Reader = nil
39156	c.urlParams_.Set("alt", alt)
39157	c.urlParams_.Set("prettyPrint", "false")
39158	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/placementGroups/{id}")
39159	urls += "?" + c.urlParams_.Encode()
39160	req, err := http.NewRequest("GET", urls, body)
39161	if err != nil {
39162		return nil, err
39163	}
39164	req.Header = reqHeaders
39165	googleapi.Expand(req.URL, map[string]string{
39166		"profileId": strconv.FormatInt(c.profileId, 10),
39167		"id":        strconv.FormatInt(c.id, 10),
39168	})
39169	return gensupport.SendRequest(c.ctx_, c.s.client, req)
39170}
39171
39172// Do executes the "dfareporting.placementGroups.get" call.
39173// Exactly one of *PlacementGroup or error will be non-nil. Any non-2xx
39174// status code is an error. Response headers are in either
39175// *PlacementGroup.ServerResponse.Header or (if a response was returned
39176// at all) in error.(*googleapi.Error).Header. Use
39177// googleapi.IsNotModified to check whether the returned error was
39178// because http.StatusNotModified was returned.
39179func (c *PlacementGroupsGetCall) Do(opts ...googleapi.CallOption) (*PlacementGroup, error) {
39180	gensupport.SetOptions(c.urlParams_, opts...)
39181	res, err := c.doRequest("json")
39182	if res != nil && res.StatusCode == http.StatusNotModified {
39183		if res.Body != nil {
39184			res.Body.Close()
39185		}
39186		return nil, &googleapi.Error{
39187			Code:   res.StatusCode,
39188			Header: res.Header,
39189		}
39190	}
39191	if err != nil {
39192		return nil, err
39193	}
39194	defer googleapi.CloseBody(res)
39195	if err := googleapi.CheckResponse(res); err != nil {
39196		return nil, err
39197	}
39198	ret := &PlacementGroup{
39199		ServerResponse: googleapi.ServerResponse{
39200			Header:         res.Header,
39201			HTTPStatusCode: res.StatusCode,
39202		},
39203	}
39204	target := &ret
39205	if err := gensupport.DecodeResponse(target, res); err != nil {
39206		return nil, err
39207	}
39208	return ret, nil
39209	// {
39210	//   "description": "Gets one placement group by ID.",
39211	//   "flatPath": "userprofiles/{profileId}/placementGroups/{id}",
39212	//   "httpMethod": "GET",
39213	//   "id": "dfareporting.placementGroups.get",
39214	//   "parameterOrder": [
39215	//     "profileId",
39216	//     "id"
39217	//   ],
39218	//   "parameters": {
39219	//     "id": {
39220	//       "description": "Placement group ID.",
39221	//       "format": "int64",
39222	//       "location": "path",
39223	//       "required": true,
39224	//       "type": "string"
39225	//     },
39226	//     "profileId": {
39227	//       "description": "User profile ID associated with this request.",
39228	//       "format": "int64",
39229	//       "location": "path",
39230	//       "required": true,
39231	//       "type": "string"
39232	//     }
39233	//   },
39234	//   "path": "userprofiles/{profileId}/placementGroups/{id}",
39235	//   "response": {
39236	//     "$ref": "PlacementGroup"
39237	//   },
39238	//   "scopes": [
39239	//     "https://www.googleapis.com/auth/dfatrafficking"
39240	//   ]
39241	// }
39242
39243}
39244
39245// method id "dfareporting.placementGroups.insert":
39246
39247type PlacementGroupsInsertCall struct {
39248	s              *Service
39249	profileId      int64
39250	placementgroup *PlacementGroup
39251	urlParams_     gensupport.URLParams
39252	ctx_           context.Context
39253	header_        http.Header
39254}
39255
39256// Insert: Inserts a new placement group.
39257//
39258// - profileId: User profile ID associated with this request.
39259func (r *PlacementGroupsService) Insert(profileId int64, placementgroup *PlacementGroup) *PlacementGroupsInsertCall {
39260	c := &PlacementGroupsInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
39261	c.profileId = profileId
39262	c.placementgroup = placementgroup
39263	return c
39264}
39265
39266// Fields allows partial responses to be retrieved. See
39267// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
39268// for more information.
39269func (c *PlacementGroupsInsertCall) Fields(s ...googleapi.Field) *PlacementGroupsInsertCall {
39270	c.urlParams_.Set("fields", googleapi.CombineFields(s))
39271	return c
39272}
39273
39274// Context sets the context to be used in this call's Do method. Any
39275// pending HTTP request will be aborted if the provided context is
39276// canceled.
39277func (c *PlacementGroupsInsertCall) Context(ctx context.Context) *PlacementGroupsInsertCall {
39278	c.ctx_ = ctx
39279	return c
39280}
39281
39282// Header returns an http.Header that can be modified by the caller to
39283// add HTTP headers to the request.
39284func (c *PlacementGroupsInsertCall) Header() http.Header {
39285	if c.header_ == nil {
39286		c.header_ = make(http.Header)
39287	}
39288	return c.header_
39289}
39290
39291func (c *PlacementGroupsInsertCall) doRequest(alt string) (*http.Response, error) {
39292	reqHeaders := make(http.Header)
39293	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
39294	for k, v := range c.header_ {
39295		reqHeaders[k] = v
39296	}
39297	reqHeaders.Set("User-Agent", c.s.userAgent())
39298	var body io.Reader = nil
39299	body, err := googleapi.WithoutDataWrapper.JSONReader(c.placementgroup)
39300	if err != nil {
39301		return nil, err
39302	}
39303	reqHeaders.Set("Content-Type", "application/json")
39304	c.urlParams_.Set("alt", alt)
39305	c.urlParams_.Set("prettyPrint", "false")
39306	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/placementGroups")
39307	urls += "?" + c.urlParams_.Encode()
39308	req, err := http.NewRequest("POST", urls, body)
39309	if err != nil {
39310		return nil, err
39311	}
39312	req.Header = reqHeaders
39313	googleapi.Expand(req.URL, map[string]string{
39314		"profileId": strconv.FormatInt(c.profileId, 10),
39315	})
39316	return gensupport.SendRequest(c.ctx_, c.s.client, req)
39317}
39318
39319// Do executes the "dfareporting.placementGroups.insert" call.
39320// Exactly one of *PlacementGroup or error will be non-nil. Any non-2xx
39321// status code is an error. Response headers are in either
39322// *PlacementGroup.ServerResponse.Header or (if a response was returned
39323// at all) in error.(*googleapi.Error).Header. Use
39324// googleapi.IsNotModified to check whether the returned error was
39325// because http.StatusNotModified was returned.
39326func (c *PlacementGroupsInsertCall) Do(opts ...googleapi.CallOption) (*PlacementGroup, error) {
39327	gensupport.SetOptions(c.urlParams_, opts...)
39328	res, err := c.doRequest("json")
39329	if res != nil && res.StatusCode == http.StatusNotModified {
39330		if res.Body != nil {
39331			res.Body.Close()
39332		}
39333		return nil, &googleapi.Error{
39334			Code:   res.StatusCode,
39335			Header: res.Header,
39336		}
39337	}
39338	if err != nil {
39339		return nil, err
39340	}
39341	defer googleapi.CloseBody(res)
39342	if err := googleapi.CheckResponse(res); err != nil {
39343		return nil, err
39344	}
39345	ret := &PlacementGroup{
39346		ServerResponse: googleapi.ServerResponse{
39347			Header:         res.Header,
39348			HTTPStatusCode: res.StatusCode,
39349		},
39350	}
39351	target := &ret
39352	if err := gensupport.DecodeResponse(target, res); err != nil {
39353		return nil, err
39354	}
39355	return ret, nil
39356	// {
39357	//   "description": "Inserts a new placement group.",
39358	//   "flatPath": "userprofiles/{profileId}/placementGroups",
39359	//   "httpMethod": "POST",
39360	//   "id": "dfareporting.placementGroups.insert",
39361	//   "parameterOrder": [
39362	//     "profileId"
39363	//   ],
39364	//   "parameters": {
39365	//     "profileId": {
39366	//       "description": "User profile ID associated with this request.",
39367	//       "format": "int64",
39368	//       "location": "path",
39369	//       "required": true,
39370	//       "type": "string"
39371	//     }
39372	//   },
39373	//   "path": "userprofiles/{profileId}/placementGroups",
39374	//   "request": {
39375	//     "$ref": "PlacementGroup"
39376	//   },
39377	//   "response": {
39378	//     "$ref": "PlacementGroup"
39379	//   },
39380	//   "scopes": [
39381	//     "https://www.googleapis.com/auth/dfatrafficking"
39382	//   ]
39383	// }
39384
39385}
39386
39387// method id "dfareporting.placementGroups.list":
39388
39389type PlacementGroupsListCall struct {
39390	s            *Service
39391	profileId    int64
39392	urlParams_   gensupport.URLParams
39393	ifNoneMatch_ string
39394	ctx_         context.Context
39395	header_      http.Header
39396}
39397
39398// List: Retrieves a list of placement groups, possibly filtered. This
39399// method supports paging.
39400//
39401// - profileId: User profile ID associated with this request.
39402func (r *PlacementGroupsService) List(profileId int64) *PlacementGroupsListCall {
39403	c := &PlacementGroupsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
39404	c.profileId = profileId
39405	return c
39406}
39407
39408// AdvertiserIds sets the optional parameter "advertiserIds": Select
39409// only placement groups that belong to these advertisers.
39410func (c *PlacementGroupsListCall) AdvertiserIds(advertiserIds ...int64) *PlacementGroupsListCall {
39411	var advertiserIds_ []string
39412	for _, v := range advertiserIds {
39413		advertiserIds_ = append(advertiserIds_, fmt.Sprint(v))
39414	}
39415	c.urlParams_.SetMulti("advertiserIds", advertiserIds_)
39416	return c
39417}
39418
39419// Archived sets the optional parameter "archived": Select only archived
39420// placements. Don't set this field to select both archived and
39421// non-archived placements.
39422func (c *PlacementGroupsListCall) Archived(archived bool) *PlacementGroupsListCall {
39423	c.urlParams_.Set("archived", fmt.Sprint(archived))
39424	return c
39425}
39426
39427// CampaignIds sets the optional parameter "campaignIds": Select only
39428// placement groups that belong to these campaigns.
39429func (c *PlacementGroupsListCall) CampaignIds(campaignIds ...int64) *PlacementGroupsListCall {
39430	var campaignIds_ []string
39431	for _, v := range campaignIds {
39432		campaignIds_ = append(campaignIds_, fmt.Sprint(v))
39433	}
39434	c.urlParams_.SetMulti("campaignIds", campaignIds_)
39435	return c
39436}
39437
39438// ContentCategoryIds sets the optional parameter "contentCategoryIds":
39439// Select only placement groups that are associated with these content
39440// categories.
39441func (c *PlacementGroupsListCall) ContentCategoryIds(contentCategoryIds ...int64) *PlacementGroupsListCall {
39442	var contentCategoryIds_ []string
39443	for _, v := range contentCategoryIds {
39444		contentCategoryIds_ = append(contentCategoryIds_, fmt.Sprint(v))
39445	}
39446	c.urlParams_.SetMulti("contentCategoryIds", contentCategoryIds_)
39447	return c
39448}
39449
39450// DirectorySiteIds sets the optional parameter "directorySiteIds":
39451// Select only placement groups that are associated with these directory
39452// sites.
39453func (c *PlacementGroupsListCall) DirectorySiteIds(directorySiteIds ...int64) *PlacementGroupsListCall {
39454	var directorySiteIds_ []string
39455	for _, v := range directorySiteIds {
39456		directorySiteIds_ = append(directorySiteIds_, fmt.Sprint(v))
39457	}
39458	c.urlParams_.SetMulti("directorySiteIds", directorySiteIds_)
39459	return c
39460}
39461
39462// Ids sets the optional parameter "ids": Select only placement groups
39463// with these IDs.
39464func (c *PlacementGroupsListCall) Ids(ids ...int64) *PlacementGroupsListCall {
39465	var ids_ []string
39466	for _, v := range ids {
39467		ids_ = append(ids_, fmt.Sprint(v))
39468	}
39469	c.urlParams_.SetMulti("ids", ids_)
39470	return c
39471}
39472
39473// MaxEndDate sets the optional parameter "maxEndDate": Select only
39474// placements or placement groups whose end date is on or before the
39475// specified maxEndDate. The date should be formatted as "yyyy-MM-dd".
39476func (c *PlacementGroupsListCall) MaxEndDate(maxEndDate string) *PlacementGroupsListCall {
39477	c.urlParams_.Set("maxEndDate", maxEndDate)
39478	return c
39479}
39480
39481// MaxResults sets the optional parameter "maxResults": Maximum number
39482// of results to return.
39483func (c *PlacementGroupsListCall) MaxResults(maxResults int64) *PlacementGroupsListCall {
39484	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
39485	return c
39486}
39487
39488// MaxStartDate sets the optional parameter "maxStartDate": Select only
39489// placements or placement groups whose start date is on or before the
39490// specified maxStartDate. The date should be formatted as "yyyy-MM-dd".
39491func (c *PlacementGroupsListCall) MaxStartDate(maxStartDate string) *PlacementGroupsListCall {
39492	c.urlParams_.Set("maxStartDate", maxStartDate)
39493	return c
39494}
39495
39496// MinEndDate sets the optional parameter "minEndDate": Select only
39497// placements or placement groups whose end date is on or after the
39498// specified minEndDate. The date should be formatted as "yyyy-MM-dd".
39499func (c *PlacementGroupsListCall) MinEndDate(minEndDate string) *PlacementGroupsListCall {
39500	c.urlParams_.Set("minEndDate", minEndDate)
39501	return c
39502}
39503
39504// MinStartDate sets the optional parameter "minStartDate": Select only
39505// placements or placement groups whose start date is on or after the
39506// specified minStartDate. The date should be formatted as "yyyy-MM-dd".
39507func (c *PlacementGroupsListCall) MinStartDate(minStartDate string) *PlacementGroupsListCall {
39508	c.urlParams_.Set("minStartDate", minStartDate)
39509	return c
39510}
39511
39512// PageToken sets the optional parameter "pageToken": Value of the
39513// nextPageToken from the previous result page.
39514func (c *PlacementGroupsListCall) PageToken(pageToken string) *PlacementGroupsListCall {
39515	c.urlParams_.Set("pageToken", pageToken)
39516	return c
39517}
39518
39519// PlacementGroupType sets the optional parameter "placementGroupType":
39520// Select only placement groups belonging with this group type. A
39521// package is a simple group of placements that acts as a single pricing
39522// point for a group of tags. A roadblock is a group of placements that
39523// not only acts as a single pricing point but also assumes that all the
39524// tags in it will be served at the same time. A roadblock requires one
39525// of its assigned placements to be marked as primary for reporting.
39526//
39527// Possible values:
39528//   "PLACEMENT_PACKAGE"
39529//   "PLACEMENT_ROADBLOCK"
39530func (c *PlacementGroupsListCall) PlacementGroupType(placementGroupType string) *PlacementGroupsListCall {
39531	c.urlParams_.Set("placementGroupType", placementGroupType)
39532	return c
39533}
39534
39535// PlacementStrategyIds sets the optional parameter
39536// "placementStrategyIds": Select only placement groups that are
39537// associated with these placement strategies.
39538func (c *PlacementGroupsListCall) PlacementStrategyIds(placementStrategyIds ...int64) *PlacementGroupsListCall {
39539	var placementStrategyIds_ []string
39540	for _, v := range placementStrategyIds {
39541		placementStrategyIds_ = append(placementStrategyIds_, fmt.Sprint(v))
39542	}
39543	c.urlParams_.SetMulti("placementStrategyIds", placementStrategyIds_)
39544	return c
39545}
39546
39547// PricingTypes sets the optional parameter "pricingTypes": Select only
39548// placement groups with these pricing types.
39549//
39550// Possible values:
39551//   "PRICING_TYPE_CPM"
39552//   "PRICING_TYPE_CPC"
39553//   "PRICING_TYPE_CPA"
39554//   "PRICING_TYPE_FLAT_RATE_IMPRESSIONS"
39555//   "PRICING_TYPE_FLAT_RATE_CLICKS"
39556//   "PRICING_TYPE_CPM_ACTIVEVIEW"
39557func (c *PlacementGroupsListCall) PricingTypes(pricingTypes ...string) *PlacementGroupsListCall {
39558	c.urlParams_.SetMulti("pricingTypes", append([]string{}, pricingTypes...))
39559	return c
39560}
39561
39562// SearchString sets the optional parameter "searchString": Allows
39563// searching for placement groups by name or ID. Wildcards (*) are
39564// allowed. For example, "placement*2015" will return placement groups
39565// with names like "placement group June 2015", "placement group May
39566// 2015", or simply "placements 2015". Most of the searches also add
39567// wildcards implicitly at the start and the end of the search string.
39568// For example, a search string of "placementgroup" will match placement
39569// groups with name "my placementgroup", "placementgroup 2015", or
39570// simply "placementgroup".
39571func (c *PlacementGroupsListCall) SearchString(searchString string) *PlacementGroupsListCall {
39572	c.urlParams_.Set("searchString", searchString)
39573	return c
39574}
39575
39576// SiteIds sets the optional parameter "siteIds": Select only placement
39577// groups that are associated with these sites.
39578func (c *PlacementGroupsListCall) SiteIds(siteIds ...int64) *PlacementGroupsListCall {
39579	var siteIds_ []string
39580	for _, v := range siteIds {
39581		siteIds_ = append(siteIds_, fmt.Sprint(v))
39582	}
39583	c.urlParams_.SetMulti("siteIds", siteIds_)
39584	return c
39585}
39586
39587// SortField sets the optional parameter "sortField": Field by which to
39588// sort the list.
39589//
39590// Possible values:
39591//   "ID" (default)
39592//   "NAME"
39593func (c *PlacementGroupsListCall) SortField(sortField string) *PlacementGroupsListCall {
39594	c.urlParams_.Set("sortField", sortField)
39595	return c
39596}
39597
39598// SortOrder sets the optional parameter "sortOrder": Order of sorted
39599// results.
39600//
39601// Possible values:
39602//   "ASCENDING" (default)
39603//   "DESCENDING"
39604func (c *PlacementGroupsListCall) SortOrder(sortOrder string) *PlacementGroupsListCall {
39605	c.urlParams_.Set("sortOrder", sortOrder)
39606	return c
39607}
39608
39609// Fields allows partial responses to be retrieved. See
39610// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
39611// for more information.
39612func (c *PlacementGroupsListCall) Fields(s ...googleapi.Field) *PlacementGroupsListCall {
39613	c.urlParams_.Set("fields", googleapi.CombineFields(s))
39614	return c
39615}
39616
39617// IfNoneMatch sets the optional parameter which makes the operation
39618// fail if the object's ETag matches the given value. This is useful for
39619// getting updates only after the object has changed since the last
39620// request. Use googleapi.IsNotModified to check whether the response
39621// error from Do is the result of In-None-Match.
39622func (c *PlacementGroupsListCall) IfNoneMatch(entityTag string) *PlacementGroupsListCall {
39623	c.ifNoneMatch_ = entityTag
39624	return c
39625}
39626
39627// Context sets the context to be used in this call's Do method. Any
39628// pending HTTP request will be aborted if the provided context is
39629// canceled.
39630func (c *PlacementGroupsListCall) Context(ctx context.Context) *PlacementGroupsListCall {
39631	c.ctx_ = ctx
39632	return c
39633}
39634
39635// Header returns an http.Header that can be modified by the caller to
39636// add HTTP headers to the request.
39637func (c *PlacementGroupsListCall) Header() http.Header {
39638	if c.header_ == nil {
39639		c.header_ = make(http.Header)
39640	}
39641	return c.header_
39642}
39643
39644func (c *PlacementGroupsListCall) doRequest(alt string) (*http.Response, error) {
39645	reqHeaders := make(http.Header)
39646	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
39647	for k, v := range c.header_ {
39648		reqHeaders[k] = v
39649	}
39650	reqHeaders.Set("User-Agent", c.s.userAgent())
39651	if c.ifNoneMatch_ != "" {
39652		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
39653	}
39654	var body io.Reader = nil
39655	c.urlParams_.Set("alt", alt)
39656	c.urlParams_.Set("prettyPrint", "false")
39657	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/placementGroups")
39658	urls += "?" + c.urlParams_.Encode()
39659	req, err := http.NewRequest("GET", urls, body)
39660	if err != nil {
39661		return nil, err
39662	}
39663	req.Header = reqHeaders
39664	googleapi.Expand(req.URL, map[string]string{
39665		"profileId": strconv.FormatInt(c.profileId, 10),
39666	})
39667	return gensupport.SendRequest(c.ctx_, c.s.client, req)
39668}
39669
39670// Do executes the "dfareporting.placementGroups.list" call.
39671// Exactly one of *PlacementGroupsListResponse or error will be non-nil.
39672// Any non-2xx status code is an error. Response headers are in either
39673// *PlacementGroupsListResponse.ServerResponse.Header or (if a response
39674// was returned at all) in error.(*googleapi.Error).Header. Use
39675// googleapi.IsNotModified to check whether the returned error was
39676// because http.StatusNotModified was returned.
39677func (c *PlacementGroupsListCall) Do(opts ...googleapi.CallOption) (*PlacementGroupsListResponse, error) {
39678	gensupport.SetOptions(c.urlParams_, opts...)
39679	res, err := c.doRequest("json")
39680	if res != nil && res.StatusCode == http.StatusNotModified {
39681		if res.Body != nil {
39682			res.Body.Close()
39683		}
39684		return nil, &googleapi.Error{
39685			Code:   res.StatusCode,
39686			Header: res.Header,
39687		}
39688	}
39689	if err != nil {
39690		return nil, err
39691	}
39692	defer googleapi.CloseBody(res)
39693	if err := googleapi.CheckResponse(res); err != nil {
39694		return nil, err
39695	}
39696	ret := &PlacementGroupsListResponse{
39697		ServerResponse: googleapi.ServerResponse{
39698			Header:         res.Header,
39699			HTTPStatusCode: res.StatusCode,
39700		},
39701	}
39702	target := &ret
39703	if err := gensupport.DecodeResponse(target, res); err != nil {
39704		return nil, err
39705	}
39706	return ret, nil
39707	// {
39708	//   "description": "Retrieves a list of placement groups, possibly filtered. This method supports paging.",
39709	//   "flatPath": "userprofiles/{profileId}/placementGroups",
39710	//   "httpMethod": "GET",
39711	//   "id": "dfareporting.placementGroups.list",
39712	//   "parameterOrder": [
39713	//     "profileId"
39714	//   ],
39715	//   "parameters": {
39716	//     "advertiserIds": {
39717	//       "description": "Select only placement groups that belong to these advertisers.",
39718	//       "format": "int64",
39719	//       "location": "query",
39720	//       "repeated": true,
39721	//       "type": "string"
39722	//     },
39723	//     "archived": {
39724	//       "description": "Select only archived placements. Don't set this field to select both archived and non-archived placements.",
39725	//       "location": "query",
39726	//       "type": "boolean"
39727	//     },
39728	//     "campaignIds": {
39729	//       "description": "Select only placement groups that belong to these campaigns.",
39730	//       "format": "int64",
39731	//       "location": "query",
39732	//       "repeated": true,
39733	//       "type": "string"
39734	//     },
39735	//     "contentCategoryIds": {
39736	//       "description": "Select only placement groups that are associated with these content categories.",
39737	//       "format": "int64",
39738	//       "location": "query",
39739	//       "repeated": true,
39740	//       "type": "string"
39741	//     },
39742	//     "directorySiteIds": {
39743	//       "description": "Select only placement groups that are associated with these directory sites.",
39744	//       "format": "int64",
39745	//       "location": "query",
39746	//       "repeated": true,
39747	//       "type": "string"
39748	//     },
39749	//     "ids": {
39750	//       "description": "Select only placement groups with these IDs.",
39751	//       "format": "int64",
39752	//       "location": "query",
39753	//       "repeated": true,
39754	//       "type": "string"
39755	//     },
39756	//     "maxEndDate": {
39757	//       "description": "Select only placements or placement groups whose end date is on or before the specified maxEndDate. The date should be formatted as \"yyyy-MM-dd\".",
39758	//       "location": "query",
39759	//       "type": "string"
39760	//     },
39761	//     "maxResults": {
39762	//       "default": "800",
39763	//       "description": "Maximum number of results to return.",
39764	//       "format": "int32",
39765	//       "location": "query",
39766	//       "maximum": "800",
39767	//       "minimum": "0",
39768	//       "type": "integer"
39769	//     },
39770	//     "maxStartDate": {
39771	//       "description": "Select only placements or placement groups whose start date is on or before the specified maxStartDate. The date should be formatted as \"yyyy-MM-dd\".",
39772	//       "location": "query",
39773	//       "type": "string"
39774	//     },
39775	//     "minEndDate": {
39776	//       "description": "Select only placements or placement groups whose end date is on or after the specified minEndDate. The date should be formatted as \"yyyy-MM-dd\".",
39777	//       "location": "query",
39778	//       "type": "string"
39779	//     },
39780	//     "minStartDate": {
39781	//       "description": "Select only placements or placement groups whose start date is on or after the specified minStartDate. The date should be formatted as \"yyyy-MM-dd\".",
39782	//       "location": "query",
39783	//       "type": "string"
39784	//     },
39785	//     "pageToken": {
39786	//       "description": "Value of the nextPageToken from the previous result page.",
39787	//       "location": "query",
39788	//       "type": "string"
39789	//     },
39790	//     "placementGroupType": {
39791	//       "description": "Select only placement groups belonging with this group type. A package is a simple group of placements that acts as a single pricing point for a group of tags. A roadblock is a group of placements that not only acts as a single pricing point but also assumes that all the tags in it will be served at the same time. A roadblock requires one of its assigned placements to be marked as primary for reporting.",
39792	//       "enum": [
39793	//         "PLACEMENT_PACKAGE",
39794	//         "PLACEMENT_ROADBLOCK"
39795	//       ],
39796	//       "enumDescriptions": [
39797	//         "",
39798	//         ""
39799	//       ],
39800	//       "location": "query",
39801	//       "type": "string"
39802	//     },
39803	//     "placementStrategyIds": {
39804	//       "description": "Select only placement groups that are associated with these placement strategies.",
39805	//       "format": "int64",
39806	//       "location": "query",
39807	//       "repeated": true,
39808	//       "type": "string"
39809	//     },
39810	//     "pricingTypes": {
39811	//       "description": "Select only placement groups with these pricing types.",
39812	//       "enum": [
39813	//         "PRICING_TYPE_CPM",
39814	//         "PRICING_TYPE_CPC",
39815	//         "PRICING_TYPE_CPA",
39816	//         "PRICING_TYPE_FLAT_RATE_IMPRESSIONS",
39817	//         "PRICING_TYPE_FLAT_RATE_CLICKS",
39818	//         "PRICING_TYPE_CPM_ACTIVEVIEW"
39819	//       ],
39820	//       "enumDescriptions": [
39821	//         "",
39822	//         "",
39823	//         "",
39824	//         "",
39825	//         "",
39826	//         ""
39827	//       ],
39828	//       "location": "query",
39829	//       "repeated": true,
39830	//       "type": "string"
39831	//     },
39832	//     "profileId": {
39833	//       "description": "User profile ID associated with this request.",
39834	//       "format": "int64",
39835	//       "location": "path",
39836	//       "required": true,
39837	//       "type": "string"
39838	//     },
39839	//     "searchString": {
39840	//       "description": "Allows searching for placement groups by name or ID. Wildcards (*) are allowed. For example, \"placement*2015\" will return placement groups with names like \"placement group June 2015\", \"placement group May 2015\", or simply \"placements 2015\". Most of the searches also add wildcards implicitly at the start and the end of the search string. For example, a search string of \"placementgroup\" will match placement groups with name \"my placementgroup\", \"placementgroup 2015\", or simply \"placementgroup\".",
39841	//       "location": "query",
39842	//       "type": "string"
39843	//     },
39844	//     "siteIds": {
39845	//       "description": "Select only placement groups that are associated with these sites.",
39846	//       "format": "int64",
39847	//       "location": "query",
39848	//       "repeated": true,
39849	//       "type": "string"
39850	//     },
39851	//     "sortField": {
39852	//       "default": "ID",
39853	//       "description": "Field by which to sort the list.",
39854	//       "enum": [
39855	//         "ID",
39856	//         "NAME"
39857	//       ],
39858	//       "enumDescriptions": [
39859	//         "",
39860	//         ""
39861	//       ],
39862	//       "location": "query",
39863	//       "type": "string"
39864	//     },
39865	//     "sortOrder": {
39866	//       "default": "ASCENDING",
39867	//       "description": "Order of sorted results.",
39868	//       "enum": [
39869	//         "ASCENDING",
39870	//         "DESCENDING"
39871	//       ],
39872	//       "enumDescriptions": [
39873	//         "",
39874	//         ""
39875	//       ],
39876	//       "location": "query",
39877	//       "type": "string"
39878	//     }
39879	//   },
39880	//   "path": "userprofiles/{profileId}/placementGroups",
39881	//   "response": {
39882	//     "$ref": "PlacementGroupsListResponse"
39883	//   },
39884	//   "scopes": [
39885	//     "https://www.googleapis.com/auth/dfatrafficking"
39886	//   ]
39887	// }
39888
39889}
39890
39891// Pages invokes f for each page of results.
39892// A non-nil error returned from f will halt the iteration.
39893// The provided context supersedes any context provided to the Context method.
39894func (c *PlacementGroupsListCall) Pages(ctx context.Context, f func(*PlacementGroupsListResponse) error) error {
39895	c.ctx_ = ctx
39896	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
39897	for {
39898		x, err := c.Do()
39899		if err != nil {
39900			return err
39901		}
39902		if err := f(x); err != nil {
39903			return err
39904		}
39905		if x.NextPageToken == "" {
39906			return nil
39907		}
39908		c.PageToken(x.NextPageToken)
39909	}
39910}
39911
39912// method id "dfareporting.placementGroups.patch":
39913
39914type PlacementGroupsPatchCall struct {
39915	s              *Service
39916	profileId      int64
39917	placementgroup *PlacementGroup
39918	urlParams_     gensupport.URLParams
39919	ctx_           context.Context
39920	header_        http.Header
39921}
39922
39923// Patch: Updates an existing placement group. This method supports
39924// patch semantics.
39925//
39926// - id: PlacementGroup ID.
39927// - profileId: User profile ID associated with this request.
39928func (r *PlacementGroupsService) Patch(profileId int64, id int64, placementgroup *PlacementGroup) *PlacementGroupsPatchCall {
39929	c := &PlacementGroupsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
39930	c.profileId = profileId
39931	c.urlParams_.Set("id", fmt.Sprint(id))
39932	c.placementgroup = placementgroup
39933	return c
39934}
39935
39936// Fields allows partial responses to be retrieved. See
39937// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
39938// for more information.
39939func (c *PlacementGroupsPatchCall) Fields(s ...googleapi.Field) *PlacementGroupsPatchCall {
39940	c.urlParams_.Set("fields", googleapi.CombineFields(s))
39941	return c
39942}
39943
39944// Context sets the context to be used in this call's Do method. Any
39945// pending HTTP request will be aborted if the provided context is
39946// canceled.
39947func (c *PlacementGroupsPatchCall) Context(ctx context.Context) *PlacementGroupsPatchCall {
39948	c.ctx_ = ctx
39949	return c
39950}
39951
39952// Header returns an http.Header that can be modified by the caller to
39953// add HTTP headers to the request.
39954func (c *PlacementGroupsPatchCall) Header() http.Header {
39955	if c.header_ == nil {
39956		c.header_ = make(http.Header)
39957	}
39958	return c.header_
39959}
39960
39961func (c *PlacementGroupsPatchCall) doRequest(alt string) (*http.Response, error) {
39962	reqHeaders := make(http.Header)
39963	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
39964	for k, v := range c.header_ {
39965		reqHeaders[k] = v
39966	}
39967	reqHeaders.Set("User-Agent", c.s.userAgent())
39968	var body io.Reader = nil
39969	body, err := googleapi.WithoutDataWrapper.JSONReader(c.placementgroup)
39970	if err != nil {
39971		return nil, err
39972	}
39973	reqHeaders.Set("Content-Type", "application/json")
39974	c.urlParams_.Set("alt", alt)
39975	c.urlParams_.Set("prettyPrint", "false")
39976	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/placementGroups")
39977	urls += "?" + c.urlParams_.Encode()
39978	req, err := http.NewRequest("PATCH", urls, body)
39979	if err != nil {
39980		return nil, err
39981	}
39982	req.Header = reqHeaders
39983	googleapi.Expand(req.URL, map[string]string{
39984		"profileId": strconv.FormatInt(c.profileId, 10),
39985	})
39986	return gensupport.SendRequest(c.ctx_, c.s.client, req)
39987}
39988
39989// Do executes the "dfareporting.placementGroups.patch" call.
39990// Exactly one of *PlacementGroup or error will be non-nil. Any non-2xx
39991// status code is an error. Response headers are in either
39992// *PlacementGroup.ServerResponse.Header or (if a response was returned
39993// at all) in error.(*googleapi.Error).Header. Use
39994// googleapi.IsNotModified to check whether the returned error was
39995// because http.StatusNotModified was returned.
39996func (c *PlacementGroupsPatchCall) Do(opts ...googleapi.CallOption) (*PlacementGroup, error) {
39997	gensupport.SetOptions(c.urlParams_, opts...)
39998	res, err := c.doRequest("json")
39999	if res != nil && res.StatusCode == http.StatusNotModified {
40000		if res.Body != nil {
40001			res.Body.Close()
40002		}
40003		return nil, &googleapi.Error{
40004			Code:   res.StatusCode,
40005			Header: res.Header,
40006		}
40007	}
40008	if err != nil {
40009		return nil, err
40010	}
40011	defer googleapi.CloseBody(res)
40012	if err := googleapi.CheckResponse(res); err != nil {
40013		return nil, err
40014	}
40015	ret := &PlacementGroup{
40016		ServerResponse: googleapi.ServerResponse{
40017			Header:         res.Header,
40018			HTTPStatusCode: res.StatusCode,
40019		},
40020	}
40021	target := &ret
40022	if err := gensupport.DecodeResponse(target, res); err != nil {
40023		return nil, err
40024	}
40025	return ret, nil
40026	// {
40027	//   "description": "Updates an existing placement group. This method supports patch semantics.",
40028	//   "flatPath": "userprofiles/{profileId}/placementGroups",
40029	//   "httpMethod": "PATCH",
40030	//   "id": "dfareporting.placementGroups.patch",
40031	//   "parameterOrder": [
40032	//     "profileId",
40033	//     "id"
40034	//   ],
40035	//   "parameters": {
40036	//     "id": {
40037	//       "description": "PlacementGroup ID.",
40038	//       "format": "int64",
40039	//       "location": "query",
40040	//       "required": true,
40041	//       "type": "string"
40042	//     },
40043	//     "profileId": {
40044	//       "description": "User profile ID associated with this request.",
40045	//       "format": "int64",
40046	//       "location": "path",
40047	//       "required": true,
40048	//       "type": "string"
40049	//     }
40050	//   },
40051	//   "path": "userprofiles/{profileId}/placementGroups",
40052	//   "request": {
40053	//     "$ref": "PlacementGroup"
40054	//   },
40055	//   "response": {
40056	//     "$ref": "PlacementGroup"
40057	//   },
40058	//   "scopes": [
40059	//     "https://www.googleapis.com/auth/dfatrafficking"
40060	//   ]
40061	// }
40062
40063}
40064
40065// method id "dfareporting.placementGroups.update":
40066
40067type PlacementGroupsUpdateCall struct {
40068	s              *Service
40069	profileId      int64
40070	placementgroup *PlacementGroup
40071	urlParams_     gensupport.URLParams
40072	ctx_           context.Context
40073	header_        http.Header
40074}
40075
40076// Update: Updates an existing placement group.
40077//
40078// - profileId: User profile ID associated with this request.
40079func (r *PlacementGroupsService) Update(profileId int64, placementgroup *PlacementGroup) *PlacementGroupsUpdateCall {
40080	c := &PlacementGroupsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
40081	c.profileId = profileId
40082	c.placementgroup = placementgroup
40083	return c
40084}
40085
40086// Fields allows partial responses to be retrieved. See
40087// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
40088// for more information.
40089func (c *PlacementGroupsUpdateCall) Fields(s ...googleapi.Field) *PlacementGroupsUpdateCall {
40090	c.urlParams_.Set("fields", googleapi.CombineFields(s))
40091	return c
40092}
40093
40094// Context sets the context to be used in this call's Do method. Any
40095// pending HTTP request will be aborted if the provided context is
40096// canceled.
40097func (c *PlacementGroupsUpdateCall) Context(ctx context.Context) *PlacementGroupsUpdateCall {
40098	c.ctx_ = ctx
40099	return c
40100}
40101
40102// Header returns an http.Header that can be modified by the caller to
40103// add HTTP headers to the request.
40104func (c *PlacementGroupsUpdateCall) Header() http.Header {
40105	if c.header_ == nil {
40106		c.header_ = make(http.Header)
40107	}
40108	return c.header_
40109}
40110
40111func (c *PlacementGroupsUpdateCall) doRequest(alt string) (*http.Response, error) {
40112	reqHeaders := make(http.Header)
40113	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
40114	for k, v := range c.header_ {
40115		reqHeaders[k] = v
40116	}
40117	reqHeaders.Set("User-Agent", c.s.userAgent())
40118	var body io.Reader = nil
40119	body, err := googleapi.WithoutDataWrapper.JSONReader(c.placementgroup)
40120	if err != nil {
40121		return nil, err
40122	}
40123	reqHeaders.Set("Content-Type", "application/json")
40124	c.urlParams_.Set("alt", alt)
40125	c.urlParams_.Set("prettyPrint", "false")
40126	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/placementGroups")
40127	urls += "?" + c.urlParams_.Encode()
40128	req, err := http.NewRequest("PUT", urls, body)
40129	if err != nil {
40130		return nil, err
40131	}
40132	req.Header = reqHeaders
40133	googleapi.Expand(req.URL, map[string]string{
40134		"profileId": strconv.FormatInt(c.profileId, 10),
40135	})
40136	return gensupport.SendRequest(c.ctx_, c.s.client, req)
40137}
40138
40139// Do executes the "dfareporting.placementGroups.update" call.
40140// Exactly one of *PlacementGroup or error will be non-nil. Any non-2xx
40141// status code is an error. Response headers are in either
40142// *PlacementGroup.ServerResponse.Header or (if a response was returned
40143// at all) in error.(*googleapi.Error).Header. Use
40144// googleapi.IsNotModified to check whether the returned error was
40145// because http.StatusNotModified was returned.
40146func (c *PlacementGroupsUpdateCall) Do(opts ...googleapi.CallOption) (*PlacementGroup, error) {
40147	gensupport.SetOptions(c.urlParams_, opts...)
40148	res, err := c.doRequest("json")
40149	if res != nil && res.StatusCode == http.StatusNotModified {
40150		if res.Body != nil {
40151			res.Body.Close()
40152		}
40153		return nil, &googleapi.Error{
40154			Code:   res.StatusCode,
40155			Header: res.Header,
40156		}
40157	}
40158	if err != nil {
40159		return nil, err
40160	}
40161	defer googleapi.CloseBody(res)
40162	if err := googleapi.CheckResponse(res); err != nil {
40163		return nil, err
40164	}
40165	ret := &PlacementGroup{
40166		ServerResponse: googleapi.ServerResponse{
40167			Header:         res.Header,
40168			HTTPStatusCode: res.StatusCode,
40169		},
40170	}
40171	target := &ret
40172	if err := gensupport.DecodeResponse(target, res); err != nil {
40173		return nil, err
40174	}
40175	return ret, nil
40176	// {
40177	//   "description": "Updates an existing placement group.",
40178	//   "flatPath": "userprofiles/{profileId}/placementGroups",
40179	//   "httpMethod": "PUT",
40180	//   "id": "dfareporting.placementGroups.update",
40181	//   "parameterOrder": [
40182	//     "profileId"
40183	//   ],
40184	//   "parameters": {
40185	//     "profileId": {
40186	//       "description": "User profile ID associated with this request.",
40187	//       "format": "int64",
40188	//       "location": "path",
40189	//       "required": true,
40190	//       "type": "string"
40191	//     }
40192	//   },
40193	//   "path": "userprofiles/{profileId}/placementGroups",
40194	//   "request": {
40195	//     "$ref": "PlacementGroup"
40196	//   },
40197	//   "response": {
40198	//     "$ref": "PlacementGroup"
40199	//   },
40200	//   "scopes": [
40201	//     "https://www.googleapis.com/auth/dfatrafficking"
40202	//   ]
40203	// }
40204
40205}
40206
40207// method id "dfareporting.placementStrategies.delete":
40208
40209type PlacementStrategiesDeleteCall struct {
40210	s          *Service
40211	profileId  int64
40212	id         int64
40213	urlParams_ gensupport.URLParams
40214	ctx_       context.Context
40215	header_    http.Header
40216}
40217
40218// Delete: Deletes an existing placement strategy.
40219//
40220// - id: Placement strategy ID.
40221// - profileId: User profile ID associated with this request.
40222func (r *PlacementStrategiesService) Delete(profileId int64, id int64) *PlacementStrategiesDeleteCall {
40223	c := &PlacementStrategiesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
40224	c.profileId = profileId
40225	c.id = id
40226	return c
40227}
40228
40229// Fields allows partial responses to be retrieved. See
40230// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
40231// for more information.
40232func (c *PlacementStrategiesDeleteCall) Fields(s ...googleapi.Field) *PlacementStrategiesDeleteCall {
40233	c.urlParams_.Set("fields", googleapi.CombineFields(s))
40234	return c
40235}
40236
40237// Context sets the context to be used in this call's Do method. Any
40238// pending HTTP request will be aborted if the provided context is
40239// canceled.
40240func (c *PlacementStrategiesDeleteCall) Context(ctx context.Context) *PlacementStrategiesDeleteCall {
40241	c.ctx_ = ctx
40242	return c
40243}
40244
40245// Header returns an http.Header that can be modified by the caller to
40246// add HTTP headers to the request.
40247func (c *PlacementStrategiesDeleteCall) Header() http.Header {
40248	if c.header_ == nil {
40249		c.header_ = make(http.Header)
40250	}
40251	return c.header_
40252}
40253
40254func (c *PlacementStrategiesDeleteCall) doRequest(alt string) (*http.Response, error) {
40255	reqHeaders := make(http.Header)
40256	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
40257	for k, v := range c.header_ {
40258		reqHeaders[k] = v
40259	}
40260	reqHeaders.Set("User-Agent", c.s.userAgent())
40261	var body io.Reader = nil
40262	c.urlParams_.Set("alt", alt)
40263	c.urlParams_.Set("prettyPrint", "false")
40264	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/placementStrategies/{id}")
40265	urls += "?" + c.urlParams_.Encode()
40266	req, err := http.NewRequest("DELETE", urls, body)
40267	if err != nil {
40268		return nil, err
40269	}
40270	req.Header = reqHeaders
40271	googleapi.Expand(req.URL, map[string]string{
40272		"profileId": strconv.FormatInt(c.profileId, 10),
40273		"id":        strconv.FormatInt(c.id, 10),
40274	})
40275	return gensupport.SendRequest(c.ctx_, c.s.client, req)
40276}
40277
40278// Do executes the "dfareporting.placementStrategies.delete" call.
40279func (c *PlacementStrategiesDeleteCall) Do(opts ...googleapi.CallOption) error {
40280	gensupport.SetOptions(c.urlParams_, opts...)
40281	res, err := c.doRequest("json")
40282	if err != nil {
40283		return err
40284	}
40285	defer googleapi.CloseBody(res)
40286	if err := googleapi.CheckResponse(res); err != nil {
40287		return err
40288	}
40289	return nil
40290	// {
40291	//   "description": "Deletes an existing placement strategy.",
40292	//   "flatPath": "userprofiles/{profileId}/placementStrategies/{id}",
40293	//   "httpMethod": "DELETE",
40294	//   "id": "dfareporting.placementStrategies.delete",
40295	//   "parameterOrder": [
40296	//     "profileId",
40297	//     "id"
40298	//   ],
40299	//   "parameters": {
40300	//     "id": {
40301	//       "description": "Placement strategy ID.",
40302	//       "format": "int64",
40303	//       "location": "path",
40304	//       "required": true,
40305	//       "type": "string"
40306	//     },
40307	//     "profileId": {
40308	//       "description": "User profile ID associated with this request.",
40309	//       "format": "int64",
40310	//       "location": "path",
40311	//       "required": true,
40312	//       "type": "string"
40313	//     }
40314	//   },
40315	//   "path": "userprofiles/{profileId}/placementStrategies/{id}",
40316	//   "scopes": [
40317	//     "https://www.googleapis.com/auth/dfatrafficking"
40318	//   ]
40319	// }
40320
40321}
40322
40323// method id "dfareporting.placementStrategies.get":
40324
40325type PlacementStrategiesGetCall struct {
40326	s            *Service
40327	profileId    int64
40328	id           int64
40329	urlParams_   gensupport.URLParams
40330	ifNoneMatch_ string
40331	ctx_         context.Context
40332	header_      http.Header
40333}
40334
40335// Get: Gets one placement strategy by ID.
40336//
40337// - id: Placement strategy ID.
40338// - profileId: User profile ID associated with this request.
40339func (r *PlacementStrategiesService) Get(profileId int64, id int64) *PlacementStrategiesGetCall {
40340	c := &PlacementStrategiesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
40341	c.profileId = profileId
40342	c.id = id
40343	return c
40344}
40345
40346// Fields allows partial responses to be retrieved. See
40347// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
40348// for more information.
40349func (c *PlacementStrategiesGetCall) Fields(s ...googleapi.Field) *PlacementStrategiesGetCall {
40350	c.urlParams_.Set("fields", googleapi.CombineFields(s))
40351	return c
40352}
40353
40354// IfNoneMatch sets the optional parameter which makes the operation
40355// fail if the object's ETag matches the given value. This is useful for
40356// getting updates only after the object has changed since the last
40357// request. Use googleapi.IsNotModified to check whether the response
40358// error from Do is the result of In-None-Match.
40359func (c *PlacementStrategiesGetCall) IfNoneMatch(entityTag string) *PlacementStrategiesGetCall {
40360	c.ifNoneMatch_ = entityTag
40361	return c
40362}
40363
40364// Context sets the context to be used in this call's Do method. Any
40365// pending HTTP request will be aborted if the provided context is
40366// canceled.
40367func (c *PlacementStrategiesGetCall) Context(ctx context.Context) *PlacementStrategiesGetCall {
40368	c.ctx_ = ctx
40369	return c
40370}
40371
40372// Header returns an http.Header that can be modified by the caller to
40373// add HTTP headers to the request.
40374func (c *PlacementStrategiesGetCall) Header() http.Header {
40375	if c.header_ == nil {
40376		c.header_ = make(http.Header)
40377	}
40378	return c.header_
40379}
40380
40381func (c *PlacementStrategiesGetCall) doRequest(alt string) (*http.Response, error) {
40382	reqHeaders := make(http.Header)
40383	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
40384	for k, v := range c.header_ {
40385		reqHeaders[k] = v
40386	}
40387	reqHeaders.Set("User-Agent", c.s.userAgent())
40388	if c.ifNoneMatch_ != "" {
40389		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
40390	}
40391	var body io.Reader = nil
40392	c.urlParams_.Set("alt", alt)
40393	c.urlParams_.Set("prettyPrint", "false")
40394	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/placementStrategies/{id}")
40395	urls += "?" + c.urlParams_.Encode()
40396	req, err := http.NewRequest("GET", urls, body)
40397	if err != nil {
40398		return nil, err
40399	}
40400	req.Header = reqHeaders
40401	googleapi.Expand(req.URL, map[string]string{
40402		"profileId": strconv.FormatInt(c.profileId, 10),
40403		"id":        strconv.FormatInt(c.id, 10),
40404	})
40405	return gensupport.SendRequest(c.ctx_, c.s.client, req)
40406}
40407
40408// Do executes the "dfareporting.placementStrategies.get" call.
40409// Exactly one of *PlacementStrategy or error will be non-nil. Any
40410// non-2xx status code is an error. Response headers are in either
40411// *PlacementStrategy.ServerResponse.Header or (if a response was
40412// returned at all) in error.(*googleapi.Error).Header. Use
40413// googleapi.IsNotModified to check whether the returned error was
40414// because http.StatusNotModified was returned.
40415func (c *PlacementStrategiesGetCall) Do(opts ...googleapi.CallOption) (*PlacementStrategy, error) {
40416	gensupport.SetOptions(c.urlParams_, opts...)
40417	res, err := c.doRequest("json")
40418	if res != nil && res.StatusCode == http.StatusNotModified {
40419		if res.Body != nil {
40420			res.Body.Close()
40421		}
40422		return nil, &googleapi.Error{
40423			Code:   res.StatusCode,
40424			Header: res.Header,
40425		}
40426	}
40427	if err != nil {
40428		return nil, err
40429	}
40430	defer googleapi.CloseBody(res)
40431	if err := googleapi.CheckResponse(res); err != nil {
40432		return nil, err
40433	}
40434	ret := &PlacementStrategy{
40435		ServerResponse: googleapi.ServerResponse{
40436			Header:         res.Header,
40437			HTTPStatusCode: res.StatusCode,
40438		},
40439	}
40440	target := &ret
40441	if err := gensupport.DecodeResponse(target, res); err != nil {
40442		return nil, err
40443	}
40444	return ret, nil
40445	// {
40446	//   "description": "Gets one placement strategy by ID.",
40447	//   "flatPath": "userprofiles/{profileId}/placementStrategies/{id}",
40448	//   "httpMethod": "GET",
40449	//   "id": "dfareporting.placementStrategies.get",
40450	//   "parameterOrder": [
40451	//     "profileId",
40452	//     "id"
40453	//   ],
40454	//   "parameters": {
40455	//     "id": {
40456	//       "description": "Placement strategy ID.",
40457	//       "format": "int64",
40458	//       "location": "path",
40459	//       "required": true,
40460	//       "type": "string"
40461	//     },
40462	//     "profileId": {
40463	//       "description": "User profile ID associated with this request.",
40464	//       "format": "int64",
40465	//       "location": "path",
40466	//       "required": true,
40467	//       "type": "string"
40468	//     }
40469	//   },
40470	//   "path": "userprofiles/{profileId}/placementStrategies/{id}",
40471	//   "response": {
40472	//     "$ref": "PlacementStrategy"
40473	//   },
40474	//   "scopes": [
40475	//     "https://www.googleapis.com/auth/dfatrafficking"
40476	//   ]
40477	// }
40478
40479}
40480
40481// method id "dfareporting.placementStrategies.insert":
40482
40483type PlacementStrategiesInsertCall struct {
40484	s                 *Service
40485	profileId         int64
40486	placementstrategy *PlacementStrategy
40487	urlParams_        gensupport.URLParams
40488	ctx_              context.Context
40489	header_           http.Header
40490}
40491
40492// Insert: Inserts a new placement strategy.
40493//
40494// - profileId: User profile ID associated with this request.
40495func (r *PlacementStrategiesService) Insert(profileId int64, placementstrategy *PlacementStrategy) *PlacementStrategiesInsertCall {
40496	c := &PlacementStrategiesInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
40497	c.profileId = profileId
40498	c.placementstrategy = placementstrategy
40499	return c
40500}
40501
40502// Fields allows partial responses to be retrieved. See
40503// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
40504// for more information.
40505func (c *PlacementStrategiesInsertCall) Fields(s ...googleapi.Field) *PlacementStrategiesInsertCall {
40506	c.urlParams_.Set("fields", googleapi.CombineFields(s))
40507	return c
40508}
40509
40510// Context sets the context to be used in this call's Do method. Any
40511// pending HTTP request will be aborted if the provided context is
40512// canceled.
40513func (c *PlacementStrategiesInsertCall) Context(ctx context.Context) *PlacementStrategiesInsertCall {
40514	c.ctx_ = ctx
40515	return c
40516}
40517
40518// Header returns an http.Header that can be modified by the caller to
40519// add HTTP headers to the request.
40520func (c *PlacementStrategiesInsertCall) Header() http.Header {
40521	if c.header_ == nil {
40522		c.header_ = make(http.Header)
40523	}
40524	return c.header_
40525}
40526
40527func (c *PlacementStrategiesInsertCall) doRequest(alt string) (*http.Response, error) {
40528	reqHeaders := make(http.Header)
40529	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
40530	for k, v := range c.header_ {
40531		reqHeaders[k] = v
40532	}
40533	reqHeaders.Set("User-Agent", c.s.userAgent())
40534	var body io.Reader = nil
40535	body, err := googleapi.WithoutDataWrapper.JSONReader(c.placementstrategy)
40536	if err != nil {
40537		return nil, err
40538	}
40539	reqHeaders.Set("Content-Type", "application/json")
40540	c.urlParams_.Set("alt", alt)
40541	c.urlParams_.Set("prettyPrint", "false")
40542	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/placementStrategies")
40543	urls += "?" + c.urlParams_.Encode()
40544	req, err := http.NewRequest("POST", urls, body)
40545	if err != nil {
40546		return nil, err
40547	}
40548	req.Header = reqHeaders
40549	googleapi.Expand(req.URL, map[string]string{
40550		"profileId": strconv.FormatInt(c.profileId, 10),
40551	})
40552	return gensupport.SendRequest(c.ctx_, c.s.client, req)
40553}
40554
40555// Do executes the "dfareporting.placementStrategies.insert" call.
40556// Exactly one of *PlacementStrategy or error will be non-nil. Any
40557// non-2xx status code is an error. Response headers are in either
40558// *PlacementStrategy.ServerResponse.Header or (if a response was
40559// returned at all) in error.(*googleapi.Error).Header. Use
40560// googleapi.IsNotModified to check whether the returned error was
40561// because http.StatusNotModified was returned.
40562func (c *PlacementStrategiesInsertCall) Do(opts ...googleapi.CallOption) (*PlacementStrategy, error) {
40563	gensupport.SetOptions(c.urlParams_, opts...)
40564	res, err := c.doRequest("json")
40565	if res != nil && res.StatusCode == http.StatusNotModified {
40566		if res.Body != nil {
40567			res.Body.Close()
40568		}
40569		return nil, &googleapi.Error{
40570			Code:   res.StatusCode,
40571			Header: res.Header,
40572		}
40573	}
40574	if err != nil {
40575		return nil, err
40576	}
40577	defer googleapi.CloseBody(res)
40578	if err := googleapi.CheckResponse(res); err != nil {
40579		return nil, err
40580	}
40581	ret := &PlacementStrategy{
40582		ServerResponse: googleapi.ServerResponse{
40583			Header:         res.Header,
40584			HTTPStatusCode: res.StatusCode,
40585		},
40586	}
40587	target := &ret
40588	if err := gensupport.DecodeResponse(target, res); err != nil {
40589		return nil, err
40590	}
40591	return ret, nil
40592	// {
40593	//   "description": "Inserts a new placement strategy.",
40594	//   "flatPath": "userprofiles/{profileId}/placementStrategies",
40595	//   "httpMethod": "POST",
40596	//   "id": "dfareporting.placementStrategies.insert",
40597	//   "parameterOrder": [
40598	//     "profileId"
40599	//   ],
40600	//   "parameters": {
40601	//     "profileId": {
40602	//       "description": "User profile ID associated with this request.",
40603	//       "format": "int64",
40604	//       "location": "path",
40605	//       "required": true,
40606	//       "type": "string"
40607	//     }
40608	//   },
40609	//   "path": "userprofiles/{profileId}/placementStrategies",
40610	//   "request": {
40611	//     "$ref": "PlacementStrategy"
40612	//   },
40613	//   "response": {
40614	//     "$ref": "PlacementStrategy"
40615	//   },
40616	//   "scopes": [
40617	//     "https://www.googleapis.com/auth/dfatrafficking"
40618	//   ]
40619	// }
40620
40621}
40622
40623// method id "dfareporting.placementStrategies.list":
40624
40625type PlacementStrategiesListCall struct {
40626	s            *Service
40627	profileId    int64
40628	urlParams_   gensupport.URLParams
40629	ifNoneMatch_ string
40630	ctx_         context.Context
40631	header_      http.Header
40632}
40633
40634// List: Retrieves a list of placement strategies, possibly filtered.
40635// This method supports paging.
40636//
40637// - profileId: User profile ID associated with this request.
40638func (r *PlacementStrategiesService) List(profileId int64) *PlacementStrategiesListCall {
40639	c := &PlacementStrategiesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
40640	c.profileId = profileId
40641	return c
40642}
40643
40644// Ids sets the optional parameter "ids": Select only placement
40645// strategies with these IDs.
40646func (c *PlacementStrategiesListCall) Ids(ids ...int64) *PlacementStrategiesListCall {
40647	var ids_ []string
40648	for _, v := range ids {
40649		ids_ = append(ids_, fmt.Sprint(v))
40650	}
40651	c.urlParams_.SetMulti("ids", ids_)
40652	return c
40653}
40654
40655// MaxResults sets the optional parameter "maxResults": Maximum number
40656// of results to return.
40657func (c *PlacementStrategiesListCall) MaxResults(maxResults int64) *PlacementStrategiesListCall {
40658	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
40659	return c
40660}
40661
40662// PageToken sets the optional parameter "pageToken": Value of the
40663// nextPageToken from the previous result page.
40664func (c *PlacementStrategiesListCall) PageToken(pageToken string) *PlacementStrategiesListCall {
40665	c.urlParams_.Set("pageToken", pageToken)
40666	return c
40667}
40668
40669// SearchString sets the optional parameter "searchString": Allows
40670// searching for objects by name or ID. Wildcards (*) are allowed. For
40671// example, "placementstrategy*2015" will return objects with names like
40672// "placementstrategy June 2015", "placementstrategy April 2015", or
40673// simply "placementstrategy 2015". Most of the searches also add
40674// wildcards implicitly at the start and the end of the search string.
40675// For example, a search string of "placementstrategy" will match
40676// objects with name "my placementstrategy", "placementstrategy 2015",
40677// or simply "placementstrategy".
40678func (c *PlacementStrategiesListCall) SearchString(searchString string) *PlacementStrategiesListCall {
40679	c.urlParams_.Set("searchString", searchString)
40680	return c
40681}
40682
40683// SortField sets the optional parameter "sortField": Field by which to
40684// sort the list.
40685//
40686// Possible values:
40687//   "ID" (default)
40688//   "NAME"
40689func (c *PlacementStrategiesListCall) SortField(sortField string) *PlacementStrategiesListCall {
40690	c.urlParams_.Set("sortField", sortField)
40691	return c
40692}
40693
40694// SortOrder sets the optional parameter "sortOrder": Order of sorted
40695// results.
40696//
40697// Possible values:
40698//   "ASCENDING" (default)
40699//   "DESCENDING"
40700func (c *PlacementStrategiesListCall) SortOrder(sortOrder string) *PlacementStrategiesListCall {
40701	c.urlParams_.Set("sortOrder", sortOrder)
40702	return c
40703}
40704
40705// Fields allows partial responses to be retrieved. See
40706// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
40707// for more information.
40708func (c *PlacementStrategiesListCall) Fields(s ...googleapi.Field) *PlacementStrategiesListCall {
40709	c.urlParams_.Set("fields", googleapi.CombineFields(s))
40710	return c
40711}
40712
40713// IfNoneMatch sets the optional parameter which makes the operation
40714// fail if the object's ETag matches the given value. This is useful for
40715// getting updates only after the object has changed since the last
40716// request. Use googleapi.IsNotModified to check whether the response
40717// error from Do is the result of In-None-Match.
40718func (c *PlacementStrategiesListCall) IfNoneMatch(entityTag string) *PlacementStrategiesListCall {
40719	c.ifNoneMatch_ = entityTag
40720	return c
40721}
40722
40723// Context sets the context to be used in this call's Do method. Any
40724// pending HTTP request will be aborted if the provided context is
40725// canceled.
40726func (c *PlacementStrategiesListCall) Context(ctx context.Context) *PlacementStrategiesListCall {
40727	c.ctx_ = ctx
40728	return c
40729}
40730
40731// Header returns an http.Header that can be modified by the caller to
40732// add HTTP headers to the request.
40733func (c *PlacementStrategiesListCall) Header() http.Header {
40734	if c.header_ == nil {
40735		c.header_ = make(http.Header)
40736	}
40737	return c.header_
40738}
40739
40740func (c *PlacementStrategiesListCall) doRequest(alt string) (*http.Response, error) {
40741	reqHeaders := make(http.Header)
40742	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
40743	for k, v := range c.header_ {
40744		reqHeaders[k] = v
40745	}
40746	reqHeaders.Set("User-Agent", c.s.userAgent())
40747	if c.ifNoneMatch_ != "" {
40748		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
40749	}
40750	var body io.Reader = nil
40751	c.urlParams_.Set("alt", alt)
40752	c.urlParams_.Set("prettyPrint", "false")
40753	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/placementStrategies")
40754	urls += "?" + c.urlParams_.Encode()
40755	req, err := http.NewRequest("GET", urls, body)
40756	if err != nil {
40757		return nil, err
40758	}
40759	req.Header = reqHeaders
40760	googleapi.Expand(req.URL, map[string]string{
40761		"profileId": strconv.FormatInt(c.profileId, 10),
40762	})
40763	return gensupport.SendRequest(c.ctx_, c.s.client, req)
40764}
40765
40766// Do executes the "dfareporting.placementStrategies.list" call.
40767// Exactly one of *PlacementStrategiesListResponse or error will be
40768// non-nil. Any non-2xx status code is an error. Response headers are in
40769// either *PlacementStrategiesListResponse.ServerResponse.Header or (if
40770// a response was returned at all) in error.(*googleapi.Error).Header.
40771// Use googleapi.IsNotModified to check whether the returned error was
40772// because http.StatusNotModified was returned.
40773func (c *PlacementStrategiesListCall) Do(opts ...googleapi.CallOption) (*PlacementStrategiesListResponse, error) {
40774	gensupport.SetOptions(c.urlParams_, opts...)
40775	res, err := c.doRequest("json")
40776	if res != nil && res.StatusCode == http.StatusNotModified {
40777		if res.Body != nil {
40778			res.Body.Close()
40779		}
40780		return nil, &googleapi.Error{
40781			Code:   res.StatusCode,
40782			Header: res.Header,
40783		}
40784	}
40785	if err != nil {
40786		return nil, err
40787	}
40788	defer googleapi.CloseBody(res)
40789	if err := googleapi.CheckResponse(res); err != nil {
40790		return nil, err
40791	}
40792	ret := &PlacementStrategiesListResponse{
40793		ServerResponse: googleapi.ServerResponse{
40794			Header:         res.Header,
40795			HTTPStatusCode: res.StatusCode,
40796		},
40797	}
40798	target := &ret
40799	if err := gensupport.DecodeResponse(target, res); err != nil {
40800		return nil, err
40801	}
40802	return ret, nil
40803	// {
40804	//   "description": "Retrieves a list of placement strategies, possibly filtered. This method supports paging.",
40805	//   "flatPath": "userprofiles/{profileId}/placementStrategies",
40806	//   "httpMethod": "GET",
40807	//   "id": "dfareporting.placementStrategies.list",
40808	//   "parameterOrder": [
40809	//     "profileId"
40810	//   ],
40811	//   "parameters": {
40812	//     "ids": {
40813	//       "description": "Select only placement strategies with these IDs.",
40814	//       "format": "int64",
40815	//       "location": "query",
40816	//       "repeated": true,
40817	//       "type": "string"
40818	//     },
40819	//     "maxResults": {
40820	//       "default": "1000",
40821	//       "description": "Maximum number of results to return.",
40822	//       "format": "int32",
40823	//       "location": "query",
40824	//       "maximum": "1000",
40825	//       "minimum": "0",
40826	//       "type": "integer"
40827	//     },
40828	//     "pageToken": {
40829	//       "description": "Value of the nextPageToken from the previous result page.",
40830	//       "location": "query",
40831	//       "type": "string"
40832	//     },
40833	//     "profileId": {
40834	//       "description": "User profile ID associated with this request.",
40835	//       "format": "int64",
40836	//       "location": "path",
40837	//       "required": true,
40838	//       "type": "string"
40839	//     },
40840	//     "searchString": {
40841	//       "description": "Allows searching for objects by name or ID. Wildcards (*) are allowed. For example, \"placementstrategy*2015\" will return objects with names like \"placementstrategy June 2015\", \"placementstrategy April 2015\", or simply \"placementstrategy 2015\". Most of the searches also add wildcards implicitly at the start and the end of the search string. For example, a search string of \"placementstrategy\" will match objects with name \"my placementstrategy\", \"placementstrategy 2015\", or simply \"placementstrategy\".",
40842	//       "location": "query",
40843	//       "type": "string"
40844	//     },
40845	//     "sortField": {
40846	//       "default": "ID",
40847	//       "description": "Field by which to sort the list.",
40848	//       "enum": [
40849	//         "ID",
40850	//         "NAME"
40851	//       ],
40852	//       "enumDescriptions": [
40853	//         "",
40854	//         ""
40855	//       ],
40856	//       "location": "query",
40857	//       "type": "string"
40858	//     },
40859	//     "sortOrder": {
40860	//       "default": "ASCENDING",
40861	//       "description": "Order of sorted results.",
40862	//       "enum": [
40863	//         "ASCENDING",
40864	//         "DESCENDING"
40865	//       ],
40866	//       "enumDescriptions": [
40867	//         "",
40868	//         ""
40869	//       ],
40870	//       "location": "query",
40871	//       "type": "string"
40872	//     }
40873	//   },
40874	//   "path": "userprofiles/{profileId}/placementStrategies",
40875	//   "response": {
40876	//     "$ref": "PlacementStrategiesListResponse"
40877	//   },
40878	//   "scopes": [
40879	//     "https://www.googleapis.com/auth/dfatrafficking"
40880	//   ]
40881	// }
40882
40883}
40884
40885// Pages invokes f for each page of results.
40886// A non-nil error returned from f will halt the iteration.
40887// The provided context supersedes any context provided to the Context method.
40888func (c *PlacementStrategiesListCall) Pages(ctx context.Context, f func(*PlacementStrategiesListResponse) error) error {
40889	c.ctx_ = ctx
40890	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
40891	for {
40892		x, err := c.Do()
40893		if err != nil {
40894			return err
40895		}
40896		if err := f(x); err != nil {
40897			return err
40898		}
40899		if x.NextPageToken == "" {
40900			return nil
40901		}
40902		c.PageToken(x.NextPageToken)
40903	}
40904}
40905
40906// method id "dfareporting.placementStrategies.patch":
40907
40908type PlacementStrategiesPatchCall struct {
40909	s                 *Service
40910	profileId         int64
40911	placementstrategy *PlacementStrategy
40912	urlParams_        gensupport.URLParams
40913	ctx_              context.Context
40914	header_           http.Header
40915}
40916
40917// Patch: Updates an existing placement strategy. This method supports
40918// patch semantics.
40919//
40920// - id: PlacementStrategy ID.
40921// - profileId: User profile ID associated with this request.
40922func (r *PlacementStrategiesService) Patch(profileId int64, id int64, placementstrategy *PlacementStrategy) *PlacementStrategiesPatchCall {
40923	c := &PlacementStrategiesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
40924	c.profileId = profileId
40925	c.urlParams_.Set("id", fmt.Sprint(id))
40926	c.placementstrategy = placementstrategy
40927	return c
40928}
40929
40930// Fields allows partial responses to be retrieved. See
40931// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
40932// for more information.
40933func (c *PlacementStrategiesPatchCall) Fields(s ...googleapi.Field) *PlacementStrategiesPatchCall {
40934	c.urlParams_.Set("fields", googleapi.CombineFields(s))
40935	return c
40936}
40937
40938// Context sets the context to be used in this call's Do method. Any
40939// pending HTTP request will be aborted if the provided context is
40940// canceled.
40941func (c *PlacementStrategiesPatchCall) Context(ctx context.Context) *PlacementStrategiesPatchCall {
40942	c.ctx_ = ctx
40943	return c
40944}
40945
40946// Header returns an http.Header that can be modified by the caller to
40947// add HTTP headers to the request.
40948func (c *PlacementStrategiesPatchCall) Header() http.Header {
40949	if c.header_ == nil {
40950		c.header_ = make(http.Header)
40951	}
40952	return c.header_
40953}
40954
40955func (c *PlacementStrategiesPatchCall) doRequest(alt string) (*http.Response, error) {
40956	reqHeaders := make(http.Header)
40957	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
40958	for k, v := range c.header_ {
40959		reqHeaders[k] = v
40960	}
40961	reqHeaders.Set("User-Agent", c.s.userAgent())
40962	var body io.Reader = nil
40963	body, err := googleapi.WithoutDataWrapper.JSONReader(c.placementstrategy)
40964	if err != nil {
40965		return nil, err
40966	}
40967	reqHeaders.Set("Content-Type", "application/json")
40968	c.urlParams_.Set("alt", alt)
40969	c.urlParams_.Set("prettyPrint", "false")
40970	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/placementStrategies")
40971	urls += "?" + c.urlParams_.Encode()
40972	req, err := http.NewRequest("PATCH", urls, body)
40973	if err != nil {
40974		return nil, err
40975	}
40976	req.Header = reqHeaders
40977	googleapi.Expand(req.URL, map[string]string{
40978		"profileId": strconv.FormatInt(c.profileId, 10),
40979	})
40980	return gensupport.SendRequest(c.ctx_, c.s.client, req)
40981}
40982
40983// Do executes the "dfareporting.placementStrategies.patch" call.
40984// Exactly one of *PlacementStrategy or error will be non-nil. Any
40985// non-2xx status code is an error. Response headers are in either
40986// *PlacementStrategy.ServerResponse.Header or (if a response was
40987// returned at all) in error.(*googleapi.Error).Header. Use
40988// googleapi.IsNotModified to check whether the returned error was
40989// because http.StatusNotModified was returned.
40990func (c *PlacementStrategiesPatchCall) Do(opts ...googleapi.CallOption) (*PlacementStrategy, error) {
40991	gensupport.SetOptions(c.urlParams_, opts...)
40992	res, err := c.doRequest("json")
40993	if res != nil && res.StatusCode == http.StatusNotModified {
40994		if res.Body != nil {
40995			res.Body.Close()
40996		}
40997		return nil, &googleapi.Error{
40998			Code:   res.StatusCode,
40999			Header: res.Header,
41000		}
41001	}
41002	if err != nil {
41003		return nil, err
41004	}
41005	defer googleapi.CloseBody(res)
41006	if err := googleapi.CheckResponse(res); err != nil {
41007		return nil, err
41008	}
41009	ret := &PlacementStrategy{
41010		ServerResponse: googleapi.ServerResponse{
41011			Header:         res.Header,
41012			HTTPStatusCode: res.StatusCode,
41013		},
41014	}
41015	target := &ret
41016	if err := gensupport.DecodeResponse(target, res); err != nil {
41017		return nil, err
41018	}
41019	return ret, nil
41020	// {
41021	//   "description": "Updates an existing placement strategy. This method supports patch semantics.",
41022	//   "flatPath": "userprofiles/{profileId}/placementStrategies",
41023	//   "httpMethod": "PATCH",
41024	//   "id": "dfareporting.placementStrategies.patch",
41025	//   "parameterOrder": [
41026	//     "profileId",
41027	//     "id"
41028	//   ],
41029	//   "parameters": {
41030	//     "id": {
41031	//       "description": "PlacementStrategy ID.",
41032	//       "format": "int64",
41033	//       "location": "query",
41034	//       "required": true,
41035	//       "type": "string"
41036	//     },
41037	//     "profileId": {
41038	//       "description": "User profile ID associated with this request.",
41039	//       "format": "int64",
41040	//       "location": "path",
41041	//       "required": true,
41042	//       "type": "string"
41043	//     }
41044	//   },
41045	//   "path": "userprofiles/{profileId}/placementStrategies",
41046	//   "request": {
41047	//     "$ref": "PlacementStrategy"
41048	//   },
41049	//   "response": {
41050	//     "$ref": "PlacementStrategy"
41051	//   },
41052	//   "scopes": [
41053	//     "https://www.googleapis.com/auth/dfatrafficking"
41054	//   ]
41055	// }
41056
41057}
41058
41059// method id "dfareporting.placementStrategies.update":
41060
41061type PlacementStrategiesUpdateCall struct {
41062	s                 *Service
41063	profileId         int64
41064	placementstrategy *PlacementStrategy
41065	urlParams_        gensupport.URLParams
41066	ctx_              context.Context
41067	header_           http.Header
41068}
41069
41070// Update: Updates an existing placement strategy.
41071//
41072// - profileId: User profile ID associated with this request.
41073func (r *PlacementStrategiesService) Update(profileId int64, placementstrategy *PlacementStrategy) *PlacementStrategiesUpdateCall {
41074	c := &PlacementStrategiesUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
41075	c.profileId = profileId
41076	c.placementstrategy = placementstrategy
41077	return c
41078}
41079
41080// Fields allows partial responses to be retrieved. See
41081// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
41082// for more information.
41083func (c *PlacementStrategiesUpdateCall) Fields(s ...googleapi.Field) *PlacementStrategiesUpdateCall {
41084	c.urlParams_.Set("fields", googleapi.CombineFields(s))
41085	return c
41086}
41087
41088// Context sets the context to be used in this call's Do method. Any
41089// pending HTTP request will be aborted if the provided context is
41090// canceled.
41091func (c *PlacementStrategiesUpdateCall) Context(ctx context.Context) *PlacementStrategiesUpdateCall {
41092	c.ctx_ = ctx
41093	return c
41094}
41095
41096// Header returns an http.Header that can be modified by the caller to
41097// add HTTP headers to the request.
41098func (c *PlacementStrategiesUpdateCall) Header() http.Header {
41099	if c.header_ == nil {
41100		c.header_ = make(http.Header)
41101	}
41102	return c.header_
41103}
41104
41105func (c *PlacementStrategiesUpdateCall) doRequest(alt string) (*http.Response, error) {
41106	reqHeaders := make(http.Header)
41107	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
41108	for k, v := range c.header_ {
41109		reqHeaders[k] = v
41110	}
41111	reqHeaders.Set("User-Agent", c.s.userAgent())
41112	var body io.Reader = nil
41113	body, err := googleapi.WithoutDataWrapper.JSONReader(c.placementstrategy)
41114	if err != nil {
41115		return nil, err
41116	}
41117	reqHeaders.Set("Content-Type", "application/json")
41118	c.urlParams_.Set("alt", alt)
41119	c.urlParams_.Set("prettyPrint", "false")
41120	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/placementStrategies")
41121	urls += "?" + c.urlParams_.Encode()
41122	req, err := http.NewRequest("PUT", urls, body)
41123	if err != nil {
41124		return nil, err
41125	}
41126	req.Header = reqHeaders
41127	googleapi.Expand(req.URL, map[string]string{
41128		"profileId": strconv.FormatInt(c.profileId, 10),
41129	})
41130	return gensupport.SendRequest(c.ctx_, c.s.client, req)
41131}
41132
41133// Do executes the "dfareporting.placementStrategies.update" call.
41134// Exactly one of *PlacementStrategy or error will be non-nil. Any
41135// non-2xx status code is an error. Response headers are in either
41136// *PlacementStrategy.ServerResponse.Header or (if a response was
41137// returned at all) in error.(*googleapi.Error).Header. Use
41138// googleapi.IsNotModified to check whether the returned error was
41139// because http.StatusNotModified was returned.
41140func (c *PlacementStrategiesUpdateCall) Do(opts ...googleapi.CallOption) (*PlacementStrategy, error) {
41141	gensupport.SetOptions(c.urlParams_, opts...)
41142	res, err := c.doRequest("json")
41143	if res != nil && res.StatusCode == http.StatusNotModified {
41144		if res.Body != nil {
41145			res.Body.Close()
41146		}
41147		return nil, &googleapi.Error{
41148			Code:   res.StatusCode,
41149			Header: res.Header,
41150		}
41151	}
41152	if err != nil {
41153		return nil, err
41154	}
41155	defer googleapi.CloseBody(res)
41156	if err := googleapi.CheckResponse(res); err != nil {
41157		return nil, err
41158	}
41159	ret := &PlacementStrategy{
41160		ServerResponse: googleapi.ServerResponse{
41161			Header:         res.Header,
41162			HTTPStatusCode: res.StatusCode,
41163		},
41164	}
41165	target := &ret
41166	if err := gensupport.DecodeResponse(target, res); err != nil {
41167		return nil, err
41168	}
41169	return ret, nil
41170	// {
41171	//   "description": "Updates an existing placement strategy.",
41172	//   "flatPath": "userprofiles/{profileId}/placementStrategies",
41173	//   "httpMethod": "PUT",
41174	//   "id": "dfareporting.placementStrategies.update",
41175	//   "parameterOrder": [
41176	//     "profileId"
41177	//   ],
41178	//   "parameters": {
41179	//     "profileId": {
41180	//       "description": "User profile ID associated with this request.",
41181	//       "format": "int64",
41182	//       "location": "path",
41183	//       "required": true,
41184	//       "type": "string"
41185	//     }
41186	//   },
41187	//   "path": "userprofiles/{profileId}/placementStrategies",
41188	//   "request": {
41189	//     "$ref": "PlacementStrategy"
41190	//   },
41191	//   "response": {
41192	//     "$ref": "PlacementStrategy"
41193	//   },
41194	//   "scopes": [
41195	//     "https://www.googleapis.com/auth/dfatrafficking"
41196	//   ]
41197	// }
41198
41199}
41200
41201// method id "dfareporting.placements.generatetags":
41202
41203type PlacementsGeneratetagsCall struct {
41204	s          *Service
41205	profileId  int64
41206	urlParams_ gensupport.URLParams
41207	ctx_       context.Context
41208	header_    http.Header
41209}
41210
41211// Generatetags: Generates tags for a placement.
41212//
41213// - profileId: User profile ID associated with this request.
41214func (r *PlacementsService) Generatetags(profileId int64) *PlacementsGeneratetagsCall {
41215	c := &PlacementsGeneratetagsCall{s: r.s, urlParams_: make(gensupport.URLParams)}
41216	c.profileId = profileId
41217	return c
41218}
41219
41220// CampaignId sets the optional parameter "campaignId": Generate
41221// placements belonging to this campaign. This is a required field.
41222func (c *PlacementsGeneratetagsCall) CampaignId(campaignId int64) *PlacementsGeneratetagsCall {
41223	c.urlParams_.Set("campaignId", fmt.Sprint(campaignId))
41224	return c
41225}
41226
41227// PlacementIds sets the optional parameter "placementIds": Generate
41228// tags for these placements.
41229func (c *PlacementsGeneratetagsCall) PlacementIds(placementIds ...int64) *PlacementsGeneratetagsCall {
41230	var placementIds_ []string
41231	for _, v := range placementIds {
41232		placementIds_ = append(placementIds_, fmt.Sprint(v))
41233	}
41234	c.urlParams_.SetMulti("placementIds", placementIds_)
41235	return c
41236}
41237
41238// TagFormats sets the optional parameter "tagFormats": Tag formats to
41239// generate for these placements. *Note:* PLACEMENT_TAG_STANDARD can
41240// only be generated for 1x1 placements.
41241//
41242// Possible values:
41243//   "PLACEMENT_TAG_STANDARD"
41244//   "PLACEMENT_TAG_IFRAME_JAVASCRIPT"
41245//   "PLACEMENT_TAG_IFRAME_ILAYER"
41246//   "PLACEMENT_TAG_INTERNAL_REDIRECT"
41247//   "PLACEMENT_TAG_JAVASCRIPT"
41248//   "PLACEMENT_TAG_INTERSTITIAL_IFRAME_JAVASCRIPT"
41249//   "PLACEMENT_TAG_INTERSTITIAL_INTERNAL_REDIRECT"
41250//   "PLACEMENT_TAG_INTERSTITIAL_JAVASCRIPT"
41251//   "PLACEMENT_TAG_CLICK_COMMANDS"
41252//   "PLACEMENT_TAG_INSTREAM_VIDEO_PREFETCH"
41253//   "PLACEMENT_TAG_TRACKING"
41254//   "PLACEMENT_TAG_TRACKING_IFRAME"
41255//   "PLACEMENT_TAG_TRACKING_JAVASCRIPT"
41256//   "PLACEMENT_TAG_INSTREAM_VIDEO_PREFETCH_VAST_3"
41257//   "PLACEMENT_TAG_IFRAME_JAVASCRIPT_LEGACY"
41258//   "PLACEMENT_TAG_JAVASCRIPT_LEGACY"
41259//   "PLACEMENT_TAG_INTERSTITIAL_IFRAME_JAVASCRIPT_LEGACY"
41260//   "PLACEMENT_TAG_INTERSTITIAL_JAVASCRIPT_LEGACY"
41261//   "PLACEMENT_TAG_INSTREAM_VIDEO_PREFETCH_VAST_4"
41262func (c *PlacementsGeneratetagsCall) TagFormats(tagFormats ...string) *PlacementsGeneratetagsCall {
41263	c.urlParams_.SetMulti("tagFormats", append([]string{}, tagFormats...))
41264	return c
41265}
41266
41267// Fields allows partial responses to be retrieved. See
41268// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
41269// for more information.
41270func (c *PlacementsGeneratetagsCall) Fields(s ...googleapi.Field) *PlacementsGeneratetagsCall {
41271	c.urlParams_.Set("fields", googleapi.CombineFields(s))
41272	return c
41273}
41274
41275// Context sets the context to be used in this call's Do method. Any
41276// pending HTTP request will be aborted if the provided context is
41277// canceled.
41278func (c *PlacementsGeneratetagsCall) Context(ctx context.Context) *PlacementsGeneratetagsCall {
41279	c.ctx_ = ctx
41280	return c
41281}
41282
41283// Header returns an http.Header that can be modified by the caller to
41284// add HTTP headers to the request.
41285func (c *PlacementsGeneratetagsCall) Header() http.Header {
41286	if c.header_ == nil {
41287		c.header_ = make(http.Header)
41288	}
41289	return c.header_
41290}
41291
41292func (c *PlacementsGeneratetagsCall) doRequest(alt string) (*http.Response, error) {
41293	reqHeaders := make(http.Header)
41294	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
41295	for k, v := range c.header_ {
41296		reqHeaders[k] = v
41297	}
41298	reqHeaders.Set("User-Agent", c.s.userAgent())
41299	var body io.Reader = nil
41300	c.urlParams_.Set("alt", alt)
41301	c.urlParams_.Set("prettyPrint", "false")
41302	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/placements/generatetags")
41303	urls += "?" + c.urlParams_.Encode()
41304	req, err := http.NewRequest("POST", urls, body)
41305	if err != nil {
41306		return nil, err
41307	}
41308	req.Header = reqHeaders
41309	googleapi.Expand(req.URL, map[string]string{
41310		"profileId": strconv.FormatInt(c.profileId, 10),
41311	})
41312	return gensupport.SendRequest(c.ctx_, c.s.client, req)
41313}
41314
41315// Do executes the "dfareporting.placements.generatetags" call.
41316// Exactly one of *PlacementsGenerateTagsResponse or error will be
41317// non-nil. Any non-2xx status code is an error. Response headers are in
41318// either *PlacementsGenerateTagsResponse.ServerResponse.Header or (if a
41319// response was returned at all) in error.(*googleapi.Error).Header. Use
41320// googleapi.IsNotModified to check whether the returned error was
41321// because http.StatusNotModified was returned.
41322func (c *PlacementsGeneratetagsCall) Do(opts ...googleapi.CallOption) (*PlacementsGenerateTagsResponse, error) {
41323	gensupport.SetOptions(c.urlParams_, opts...)
41324	res, err := c.doRequest("json")
41325	if res != nil && res.StatusCode == http.StatusNotModified {
41326		if res.Body != nil {
41327			res.Body.Close()
41328		}
41329		return nil, &googleapi.Error{
41330			Code:   res.StatusCode,
41331			Header: res.Header,
41332		}
41333	}
41334	if err != nil {
41335		return nil, err
41336	}
41337	defer googleapi.CloseBody(res)
41338	if err := googleapi.CheckResponse(res); err != nil {
41339		return nil, err
41340	}
41341	ret := &PlacementsGenerateTagsResponse{
41342		ServerResponse: googleapi.ServerResponse{
41343			Header:         res.Header,
41344			HTTPStatusCode: res.StatusCode,
41345		},
41346	}
41347	target := &ret
41348	if err := gensupport.DecodeResponse(target, res); err != nil {
41349		return nil, err
41350	}
41351	return ret, nil
41352	// {
41353	//   "description": "Generates tags for a placement.",
41354	//   "flatPath": "userprofiles/{profileId}/placements/generatetags",
41355	//   "httpMethod": "POST",
41356	//   "id": "dfareporting.placements.generatetags",
41357	//   "parameterOrder": [
41358	//     "profileId"
41359	//   ],
41360	//   "parameters": {
41361	//     "campaignId": {
41362	//       "description": "Generate placements belonging to this campaign. This is a required field.",
41363	//       "format": "int64",
41364	//       "location": "query",
41365	//       "type": "string"
41366	//     },
41367	//     "placementIds": {
41368	//       "description": "Generate tags for these placements.",
41369	//       "format": "int64",
41370	//       "location": "query",
41371	//       "repeated": true,
41372	//       "type": "string"
41373	//     },
41374	//     "profileId": {
41375	//       "description": "User profile ID associated with this request.",
41376	//       "format": "int64",
41377	//       "location": "path",
41378	//       "required": true,
41379	//       "type": "string"
41380	//     },
41381	//     "tagFormats": {
41382	//       "description": "Tag formats to generate for these placements. *Note:* PLACEMENT_TAG_STANDARD can only be generated for 1x1 placements.",
41383	//       "enum": [
41384	//         "PLACEMENT_TAG_STANDARD",
41385	//         "PLACEMENT_TAG_IFRAME_JAVASCRIPT",
41386	//         "PLACEMENT_TAG_IFRAME_ILAYER",
41387	//         "PLACEMENT_TAG_INTERNAL_REDIRECT",
41388	//         "PLACEMENT_TAG_JAVASCRIPT",
41389	//         "PLACEMENT_TAG_INTERSTITIAL_IFRAME_JAVASCRIPT",
41390	//         "PLACEMENT_TAG_INTERSTITIAL_INTERNAL_REDIRECT",
41391	//         "PLACEMENT_TAG_INTERSTITIAL_JAVASCRIPT",
41392	//         "PLACEMENT_TAG_CLICK_COMMANDS",
41393	//         "PLACEMENT_TAG_INSTREAM_VIDEO_PREFETCH",
41394	//         "PLACEMENT_TAG_TRACKING",
41395	//         "PLACEMENT_TAG_TRACKING_IFRAME",
41396	//         "PLACEMENT_TAG_TRACKING_JAVASCRIPT",
41397	//         "PLACEMENT_TAG_INSTREAM_VIDEO_PREFETCH_VAST_3",
41398	//         "PLACEMENT_TAG_IFRAME_JAVASCRIPT_LEGACY",
41399	//         "PLACEMENT_TAG_JAVASCRIPT_LEGACY",
41400	//         "PLACEMENT_TAG_INTERSTITIAL_IFRAME_JAVASCRIPT_LEGACY",
41401	//         "PLACEMENT_TAG_INTERSTITIAL_JAVASCRIPT_LEGACY",
41402	//         "PLACEMENT_TAG_INSTREAM_VIDEO_PREFETCH_VAST_4"
41403	//       ],
41404	//       "enumDescriptions": [
41405	//         "",
41406	//         "",
41407	//         "",
41408	//         "",
41409	//         "",
41410	//         "",
41411	//         "",
41412	//         "",
41413	//         "",
41414	//         "",
41415	//         "",
41416	//         "",
41417	//         "",
41418	//         "",
41419	//         "",
41420	//         "",
41421	//         "",
41422	//         "",
41423	//         ""
41424	//       ],
41425	//       "location": "query",
41426	//       "repeated": true,
41427	//       "type": "string"
41428	//     }
41429	//   },
41430	//   "path": "userprofiles/{profileId}/placements/generatetags",
41431	//   "response": {
41432	//     "$ref": "PlacementsGenerateTagsResponse"
41433	//   },
41434	//   "scopes": [
41435	//     "https://www.googleapis.com/auth/dfatrafficking"
41436	//   ]
41437	// }
41438
41439}
41440
41441// method id "dfareporting.placements.get":
41442
41443type PlacementsGetCall struct {
41444	s            *Service
41445	profileId    int64
41446	id           int64
41447	urlParams_   gensupport.URLParams
41448	ifNoneMatch_ string
41449	ctx_         context.Context
41450	header_      http.Header
41451}
41452
41453// Get: Gets one placement by ID.
41454//
41455// - id: Placement ID.
41456// - profileId: User profile ID associated with this request.
41457func (r *PlacementsService) Get(profileId int64, id int64) *PlacementsGetCall {
41458	c := &PlacementsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
41459	c.profileId = profileId
41460	c.id = id
41461	return c
41462}
41463
41464// Fields allows partial responses to be retrieved. See
41465// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
41466// for more information.
41467func (c *PlacementsGetCall) Fields(s ...googleapi.Field) *PlacementsGetCall {
41468	c.urlParams_.Set("fields", googleapi.CombineFields(s))
41469	return c
41470}
41471
41472// IfNoneMatch sets the optional parameter which makes the operation
41473// fail if the object's ETag matches the given value. This is useful for
41474// getting updates only after the object has changed since the last
41475// request. Use googleapi.IsNotModified to check whether the response
41476// error from Do is the result of In-None-Match.
41477func (c *PlacementsGetCall) IfNoneMatch(entityTag string) *PlacementsGetCall {
41478	c.ifNoneMatch_ = entityTag
41479	return c
41480}
41481
41482// Context sets the context to be used in this call's Do method. Any
41483// pending HTTP request will be aborted if the provided context is
41484// canceled.
41485func (c *PlacementsGetCall) Context(ctx context.Context) *PlacementsGetCall {
41486	c.ctx_ = ctx
41487	return c
41488}
41489
41490// Header returns an http.Header that can be modified by the caller to
41491// add HTTP headers to the request.
41492func (c *PlacementsGetCall) Header() http.Header {
41493	if c.header_ == nil {
41494		c.header_ = make(http.Header)
41495	}
41496	return c.header_
41497}
41498
41499func (c *PlacementsGetCall) doRequest(alt string) (*http.Response, error) {
41500	reqHeaders := make(http.Header)
41501	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
41502	for k, v := range c.header_ {
41503		reqHeaders[k] = v
41504	}
41505	reqHeaders.Set("User-Agent", c.s.userAgent())
41506	if c.ifNoneMatch_ != "" {
41507		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
41508	}
41509	var body io.Reader = nil
41510	c.urlParams_.Set("alt", alt)
41511	c.urlParams_.Set("prettyPrint", "false")
41512	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/placements/{id}")
41513	urls += "?" + c.urlParams_.Encode()
41514	req, err := http.NewRequest("GET", urls, body)
41515	if err != nil {
41516		return nil, err
41517	}
41518	req.Header = reqHeaders
41519	googleapi.Expand(req.URL, map[string]string{
41520		"profileId": strconv.FormatInt(c.profileId, 10),
41521		"id":        strconv.FormatInt(c.id, 10),
41522	})
41523	return gensupport.SendRequest(c.ctx_, c.s.client, req)
41524}
41525
41526// Do executes the "dfareporting.placements.get" call.
41527// Exactly one of *Placement or error will be non-nil. Any non-2xx
41528// status code is an error. Response headers are in either
41529// *Placement.ServerResponse.Header or (if a response was returned at
41530// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
41531// to check whether the returned error was because
41532// http.StatusNotModified was returned.
41533func (c *PlacementsGetCall) Do(opts ...googleapi.CallOption) (*Placement, error) {
41534	gensupport.SetOptions(c.urlParams_, opts...)
41535	res, err := c.doRequest("json")
41536	if res != nil && res.StatusCode == http.StatusNotModified {
41537		if res.Body != nil {
41538			res.Body.Close()
41539		}
41540		return nil, &googleapi.Error{
41541			Code:   res.StatusCode,
41542			Header: res.Header,
41543		}
41544	}
41545	if err != nil {
41546		return nil, err
41547	}
41548	defer googleapi.CloseBody(res)
41549	if err := googleapi.CheckResponse(res); err != nil {
41550		return nil, err
41551	}
41552	ret := &Placement{
41553		ServerResponse: googleapi.ServerResponse{
41554			Header:         res.Header,
41555			HTTPStatusCode: res.StatusCode,
41556		},
41557	}
41558	target := &ret
41559	if err := gensupport.DecodeResponse(target, res); err != nil {
41560		return nil, err
41561	}
41562	return ret, nil
41563	// {
41564	//   "description": "Gets one placement by ID.",
41565	//   "flatPath": "userprofiles/{profileId}/placements/{id}",
41566	//   "httpMethod": "GET",
41567	//   "id": "dfareporting.placements.get",
41568	//   "parameterOrder": [
41569	//     "profileId",
41570	//     "id"
41571	//   ],
41572	//   "parameters": {
41573	//     "id": {
41574	//       "description": "Placement ID.",
41575	//       "format": "int64",
41576	//       "location": "path",
41577	//       "required": true,
41578	//       "type": "string"
41579	//     },
41580	//     "profileId": {
41581	//       "description": "User profile ID associated with this request.",
41582	//       "format": "int64",
41583	//       "location": "path",
41584	//       "required": true,
41585	//       "type": "string"
41586	//     }
41587	//   },
41588	//   "path": "userprofiles/{profileId}/placements/{id}",
41589	//   "response": {
41590	//     "$ref": "Placement"
41591	//   },
41592	//   "scopes": [
41593	//     "https://www.googleapis.com/auth/dfatrafficking"
41594	//   ]
41595	// }
41596
41597}
41598
41599// method id "dfareporting.placements.insert":
41600
41601type PlacementsInsertCall struct {
41602	s          *Service
41603	profileId  int64
41604	placement  *Placement
41605	urlParams_ gensupport.URLParams
41606	ctx_       context.Context
41607	header_    http.Header
41608}
41609
41610// Insert: Inserts a new placement.
41611//
41612// - profileId: User profile ID associated with this request.
41613func (r *PlacementsService) Insert(profileId int64, placement *Placement) *PlacementsInsertCall {
41614	c := &PlacementsInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
41615	c.profileId = profileId
41616	c.placement = placement
41617	return c
41618}
41619
41620// Fields allows partial responses to be retrieved. See
41621// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
41622// for more information.
41623func (c *PlacementsInsertCall) Fields(s ...googleapi.Field) *PlacementsInsertCall {
41624	c.urlParams_.Set("fields", googleapi.CombineFields(s))
41625	return c
41626}
41627
41628// Context sets the context to be used in this call's Do method. Any
41629// pending HTTP request will be aborted if the provided context is
41630// canceled.
41631func (c *PlacementsInsertCall) Context(ctx context.Context) *PlacementsInsertCall {
41632	c.ctx_ = ctx
41633	return c
41634}
41635
41636// Header returns an http.Header that can be modified by the caller to
41637// add HTTP headers to the request.
41638func (c *PlacementsInsertCall) Header() http.Header {
41639	if c.header_ == nil {
41640		c.header_ = make(http.Header)
41641	}
41642	return c.header_
41643}
41644
41645func (c *PlacementsInsertCall) doRequest(alt string) (*http.Response, error) {
41646	reqHeaders := make(http.Header)
41647	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
41648	for k, v := range c.header_ {
41649		reqHeaders[k] = v
41650	}
41651	reqHeaders.Set("User-Agent", c.s.userAgent())
41652	var body io.Reader = nil
41653	body, err := googleapi.WithoutDataWrapper.JSONReader(c.placement)
41654	if err != nil {
41655		return nil, err
41656	}
41657	reqHeaders.Set("Content-Type", "application/json")
41658	c.urlParams_.Set("alt", alt)
41659	c.urlParams_.Set("prettyPrint", "false")
41660	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/placements")
41661	urls += "?" + c.urlParams_.Encode()
41662	req, err := http.NewRequest("POST", urls, body)
41663	if err != nil {
41664		return nil, err
41665	}
41666	req.Header = reqHeaders
41667	googleapi.Expand(req.URL, map[string]string{
41668		"profileId": strconv.FormatInt(c.profileId, 10),
41669	})
41670	return gensupport.SendRequest(c.ctx_, c.s.client, req)
41671}
41672
41673// Do executes the "dfareporting.placements.insert" call.
41674// Exactly one of *Placement or error will be non-nil. Any non-2xx
41675// status code is an error. Response headers are in either
41676// *Placement.ServerResponse.Header or (if a response was returned at
41677// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
41678// to check whether the returned error was because
41679// http.StatusNotModified was returned.
41680func (c *PlacementsInsertCall) Do(opts ...googleapi.CallOption) (*Placement, error) {
41681	gensupport.SetOptions(c.urlParams_, opts...)
41682	res, err := c.doRequest("json")
41683	if res != nil && res.StatusCode == http.StatusNotModified {
41684		if res.Body != nil {
41685			res.Body.Close()
41686		}
41687		return nil, &googleapi.Error{
41688			Code:   res.StatusCode,
41689			Header: res.Header,
41690		}
41691	}
41692	if err != nil {
41693		return nil, err
41694	}
41695	defer googleapi.CloseBody(res)
41696	if err := googleapi.CheckResponse(res); err != nil {
41697		return nil, err
41698	}
41699	ret := &Placement{
41700		ServerResponse: googleapi.ServerResponse{
41701			Header:         res.Header,
41702			HTTPStatusCode: res.StatusCode,
41703		},
41704	}
41705	target := &ret
41706	if err := gensupport.DecodeResponse(target, res); err != nil {
41707		return nil, err
41708	}
41709	return ret, nil
41710	// {
41711	//   "description": "Inserts a new placement.",
41712	//   "flatPath": "userprofiles/{profileId}/placements",
41713	//   "httpMethod": "POST",
41714	//   "id": "dfareporting.placements.insert",
41715	//   "parameterOrder": [
41716	//     "profileId"
41717	//   ],
41718	//   "parameters": {
41719	//     "profileId": {
41720	//       "description": "User profile ID associated with this request.",
41721	//       "format": "int64",
41722	//       "location": "path",
41723	//       "required": true,
41724	//       "type": "string"
41725	//     }
41726	//   },
41727	//   "path": "userprofiles/{profileId}/placements",
41728	//   "request": {
41729	//     "$ref": "Placement"
41730	//   },
41731	//   "response": {
41732	//     "$ref": "Placement"
41733	//   },
41734	//   "scopes": [
41735	//     "https://www.googleapis.com/auth/dfatrafficking"
41736	//   ]
41737	// }
41738
41739}
41740
41741// method id "dfareporting.placements.list":
41742
41743type PlacementsListCall struct {
41744	s            *Service
41745	profileId    int64
41746	urlParams_   gensupport.URLParams
41747	ifNoneMatch_ string
41748	ctx_         context.Context
41749	header_      http.Header
41750}
41751
41752// List: Retrieves a list of placements, possibly filtered. This method
41753// supports paging.
41754//
41755// - profileId: User profile ID associated with this request.
41756func (r *PlacementsService) List(profileId int64) *PlacementsListCall {
41757	c := &PlacementsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
41758	c.profileId = profileId
41759	return c
41760}
41761
41762// AdvertiserIds sets the optional parameter "advertiserIds": Select
41763// only placements that belong to these advertisers.
41764func (c *PlacementsListCall) AdvertiserIds(advertiserIds ...int64) *PlacementsListCall {
41765	var advertiserIds_ []string
41766	for _, v := range advertiserIds {
41767		advertiserIds_ = append(advertiserIds_, fmt.Sprint(v))
41768	}
41769	c.urlParams_.SetMulti("advertiserIds", advertiserIds_)
41770	return c
41771}
41772
41773// Archived sets the optional parameter "archived": Select only archived
41774// placements. Don't set this field to select both archived and
41775// non-archived placements.
41776func (c *PlacementsListCall) Archived(archived bool) *PlacementsListCall {
41777	c.urlParams_.Set("archived", fmt.Sprint(archived))
41778	return c
41779}
41780
41781// CampaignIds sets the optional parameter "campaignIds": Select only
41782// placements that belong to these campaigns.
41783func (c *PlacementsListCall) CampaignIds(campaignIds ...int64) *PlacementsListCall {
41784	var campaignIds_ []string
41785	for _, v := range campaignIds {
41786		campaignIds_ = append(campaignIds_, fmt.Sprint(v))
41787	}
41788	c.urlParams_.SetMulti("campaignIds", campaignIds_)
41789	return c
41790}
41791
41792// Compatibilities sets the optional parameter "compatibilities": Select
41793// only placements that are associated with these compatibilities.
41794// DISPLAY and DISPLAY_INTERSTITIAL refer to rendering either on desktop
41795// or on mobile devices for regular or interstitial ads respectively.
41796// APP and APP_INTERSTITIAL are for rendering in mobile apps.
41797// IN_STREAM_VIDEO refers to rendering in in-stream video ads developed
41798// with the VAST standard.
41799//
41800// Possible values:
41801//   "DISPLAY"
41802//   "DISPLAY_INTERSTITIAL"
41803//   "APP"
41804//   "APP_INTERSTITIAL"
41805//   "IN_STREAM_VIDEO"
41806//   "IN_STREAM_AUDIO"
41807func (c *PlacementsListCall) Compatibilities(compatibilities ...string) *PlacementsListCall {
41808	c.urlParams_.SetMulti("compatibilities", append([]string{}, compatibilities...))
41809	return c
41810}
41811
41812// ContentCategoryIds sets the optional parameter "contentCategoryIds":
41813// Select only placements that are associated with these content
41814// categories.
41815func (c *PlacementsListCall) ContentCategoryIds(contentCategoryIds ...int64) *PlacementsListCall {
41816	var contentCategoryIds_ []string
41817	for _, v := range contentCategoryIds {
41818		contentCategoryIds_ = append(contentCategoryIds_, fmt.Sprint(v))
41819	}
41820	c.urlParams_.SetMulti("contentCategoryIds", contentCategoryIds_)
41821	return c
41822}
41823
41824// DirectorySiteIds sets the optional parameter "directorySiteIds":
41825// Select only placements that are associated with these directory
41826// sites.
41827func (c *PlacementsListCall) DirectorySiteIds(directorySiteIds ...int64) *PlacementsListCall {
41828	var directorySiteIds_ []string
41829	for _, v := range directorySiteIds {
41830		directorySiteIds_ = append(directorySiteIds_, fmt.Sprint(v))
41831	}
41832	c.urlParams_.SetMulti("directorySiteIds", directorySiteIds_)
41833	return c
41834}
41835
41836// GroupIds sets the optional parameter "groupIds": Select only
41837// placements that belong to these placement groups.
41838func (c *PlacementsListCall) GroupIds(groupIds ...int64) *PlacementsListCall {
41839	var groupIds_ []string
41840	for _, v := range groupIds {
41841		groupIds_ = append(groupIds_, fmt.Sprint(v))
41842	}
41843	c.urlParams_.SetMulti("groupIds", groupIds_)
41844	return c
41845}
41846
41847// Ids sets the optional parameter "ids": Select only placements with
41848// these IDs.
41849func (c *PlacementsListCall) Ids(ids ...int64) *PlacementsListCall {
41850	var ids_ []string
41851	for _, v := range ids {
41852		ids_ = append(ids_, fmt.Sprint(v))
41853	}
41854	c.urlParams_.SetMulti("ids", ids_)
41855	return c
41856}
41857
41858// MaxEndDate sets the optional parameter "maxEndDate": Select only
41859// placements or placement groups whose end date is on or before the
41860// specified maxEndDate. The date should be formatted as "yyyy-MM-dd".
41861func (c *PlacementsListCall) MaxEndDate(maxEndDate string) *PlacementsListCall {
41862	c.urlParams_.Set("maxEndDate", maxEndDate)
41863	return c
41864}
41865
41866// MaxResults sets the optional parameter "maxResults": Maximum number
41867// of results to return.
41868func (c *PlacementsListCall) MaxResults(maxResults int64) *PlacementsListCall {
41869	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
41870	return c
41871}
41872
41873// MaxStartDate sets the optional parameter "maxStartDate": Select only
41874// placements or placement groups whose start date is on or before the
41875// specified maxStartDate. The date should be formatted as "yyyy-MM-dd".
41876func (c *PlacementsListCall) MaxStartDate(maxStartDate string) *PlacementsListCall {
41877	c.urlParams_.Set("maxStartDate", maxStartDate)
41878	return c
41879}
41880
41881// MinEndDate sets the optional parameter "minEndDate": Select only
41882// placements or placement groups whose end date is on or after the
41883// specified minEndDate. The date should be formatted as "yyyy-MM-dd".
41884func (c *PlacementsListCall) MinEndDate(minEndDate string) *PlacementsListCall {
41885	c.urlParams_.Set("minEndDate", minEndDate)
41886	return c
41887}
41888
41889// MinStartDate sets the optional parameter "minStartDate": Select only
41890// placements or placement groups whose start date is on or after the
41891// specified minStartDate. The date should be formatted as "yyyy-MM-dd".
41892func (c *PlacementsListCall) MinStartDate(minStartDate string) *PlacementsListCall {
41893	c.urlParams_.Set("minStartDate", minStartDate)
41894	return c
41895}
41896
41897// PageToken sets the optional parameter "pageToken": Value of the
41898// nextPageToken from the previous result page.
41899func (c *PlacementsListCall) PageToken(pageToken string) *PlacementsListCall {
41900	c.urlParams_.Set("pageToken", pageToken)
41901	return c
41902}
41903
41904// PaymentSource sets the optional parameter "paymentSource": Select
41905// only placements with this payment source.
41906//
41907// Possible values:
41908//   "PLACEMENT_AGENCY_PAID"
41909//   "PLACEMENT_PUBLISHER_PAID"
41910func (c *PlacementsListCall) PaymentSource(paymentSource string) *PlacementsListCall {
41911	c.urlParams_.Set("paymentSource", paymentSource)
41912	return c
41913}
41914
41915// PlacementStrategyIds sets the optional parameter
41916// "placementStrategyIds": Select only placements that are associated
41917// with these placement strategies.
41918func (c *PlacementsListCall) PlacementStrategyIds(placementStrategyIds ...int64) *PlacementsListCall {
41919	var placementStrategyIds_ []string
41920	for _, v := range placementStrategyIds {
41921		placementStrategyIds_ = append(placementStrategyIds_, fmt.Sprint(v))
41922	}
41923	c.urlParams_.SetMulti("placementStrategyIds", placementStrategyIds_)
41924	return c
41925}
41926
41927// PricingTypes sets the optional parameter "pricingTypes": Select only
41928// placements with these pricing types.
41929//
41930// Possible values:
41931//   "PRICING_TYPE_CPM"
41932//   "PRICING_TYPE_CPC"
41933//   "PRICING_TYPE_CPA"
41934//   "PRICING_TYPE_FLAT_RATE_IMPRESSIONS"
41935//   "PRICING_TYPE_FLAT_RATE_CLICKS"
41936//   "PRICING_TYPE_CPM_ACTIVEVIEW"
41937func (c *PlacementsListCall) PricingTypes(pricingTypes ...string) *PlacementsListCall {
41938	c.urlParams_.SetMulti("pricingTypes", append([]string{}, pricingTypes...))
41939	return c
41940}
41941
41942// SearchString sets the optional parameter "searchString": Allows
41943// searching for placements by name or ID. Wildcards (*) are allowed.
41944// For example, "placement*2015" will return placements with names like
41945// "placement June 2015", "placement May 2015", or simply "placements
41946// 2015". Most of the searches also add wildcards implicitly at the
41947// start and the end of the search string. For example, a search string
41948// of "placement" will match placements with name "my placement",
41949// "placement 2015", or simply "placement" .
41950func (c *PlacementsListCall) SearchString(searchString string) *PlacementsListCall {
41951	c.urlParams_.Set("searchString", searchString)
41952	return c
41953}
41954
41955// SiteIds sets the optional parameter "siteIds": Select only placements
41956// that are associated with these sites.
41957func (c *PlacementsListCall) SiteIds(siteIds ...int64) *PlacementsListCall {
41958	var siteIds_ []string
41959	for _, v := range siteIds {
41960		siteIds_ = append(siteIds_, fmt.Sprint(v))
41961	}
41962	c.urlParams_.SetMulti("siteIds", siteIds_)
41963	return c
41964}
41965
41966// SizeIds sets the optional parameter "sizeIds": Select only placements
41967// that are associated with these sizes.
41968func (c *PlacementsListCall) SizeIds(sizeIds ...int64) *PlacementsListCall {
41969	var sizeIds_ []string
41970	for _, v := range sizeIds {
41971		sizeIds_ = append(sizeIds_, fmt.Sprint(v))
41972	}
41973	c.urlParams_.SetMulti("sizeIds", sizeIds_)
41974	return c
41975}
41976
41977// SortField sets the optional parameter "sortField": Field by which to
41978// sort the list.
41979//
41980// Possible values:
41981//   "ID" (default)
41982//   "NAME"
41983func (c *PlacementsListCall) SortField(sortField string) *PlacementsListCall {
41984	c.urlParams_.Set("sortField", sortField)
41985	return c
41986}
41987
41988// SortOrder sets the optional parameter "sortOrder": Order of sorted
41989// results.
41990//
41991// Possible values:
41992//   "ASCENDING" (default)
41993//   "DESCENDING"
41994func (c *PlacementsListCall) SortOrder(sortOrder string) *PlacementsListCall {
41995	c.urlParams_.Set("sortOrder", sortOrder)
41996	return c
41997}
41998
41999// Fields allows partial responses to be retrieved. See
42000// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
42001// for more information.
42002func (c *PlacementsListCall) Fields(s ...googleapi.Field) *PlacementsListCall {
42003	c.urlParams_.Set("fields", googleapi.CombineFields(s))
42004	return c
42005}
42006
42007// IfNoneMatch sets the optional parameter which makes the operation
42008// fail if the object's ETag matches the given value. This is useful for
42009// getting updates only after the object has changed since the last
42010// request. Use googleapi.IsNotModified to check whether the response
42011// error from Do is the result of In-None-Match.
42012func (c *PlacementsListCall) IfNoneMatch(entityTag string) *PlacementsListCall {
42013	c.ifNoneMatch_ = entityTag
42014	return c
42015}
42016
42017// Context sets the context to be used in this call's Do method. Any
42018// pending HTTP request will be aborted if the provided context is
42019// canceled.
42020func (c *PlacementsListCall) Context(ctx context.Context) *PlacementsListCall {
42021	c.ctx_ = ctx
42022	return c
42023}
42024
42025// Header returns an http.Header that can be modified by the caller to
42026// add HTTP headers to the request.
42027func (c *PlacementsListCall) Header() http.Header {
42028	if c.header_ == nil {
42029		c.header_ = make(http.Header)
42030	}
42031	return c.header_
42032}
42033
42034func (c *PlacementsListCall) doRequest(alt string) (*http.Response, error) {
42035	reqHeaders := make(http.Header)
42036	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
42037	for k, v := range c.header_ {
42038		reqHeaders[k] = v
42039	}
42040	reqHeaders.Set("User-Agent", c.s.userAgent())
42041	if c.ifNoneMatch_ != "" {
42042		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
42043	}
42044	var body io.Reader = nil
42045	c.urlParams_.Set("alt", alt)
42046	c.urlParams_.Set("prettyPrint", "false")
42047	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/placements")
42048	urls += "?" + c.urlParams_.Encode()
42049	req, err := http.NewRequest("GET", urls, body)
42050	if err != nil {
42051		return nil, err
42052	}
42053	req.Header = reqHeaders
42054	googleapi.Expand(req.URL, map[string]string{
42055		"profileId": strconv.FormatInt(c.profileId, 10),
42056	})
42057	return gensupport.SendRequest(c.ctx_, c.s.client, req)
42058}
42059
42060// Do executes the "dfareporting.placements.list" call.
42061// Exactly one of *PlacementsListResponse or error will be non-nil. Any
42062// non-2xx status code is an error. Response headers are in either
42063// *PlacementsListResponse.ServerResponse.Header or (if a response was
42064// returned at all) in error.(*googleapi.Error).Header. Use
42065// googleapi.IsNotModified to check whether the returned error was
42066// because http.StatusNotModified was returned.
42067func (c *PlacementsListCall) Do(opts ...googleapi.CallOption) (*PlacementsListResponse, error) {
42068	gensupport.SetOptions(c.urlParams_, opts...)
42069	res, err := c.doRequest("json")
42070	if res != nil && res.StatusCode == http.StatusNotModified {
42071		if res.Body != nil {
42072			res.Body.Close()
42073		}
42074		return nil, &googleapi.Error{
42075			Code:   res.StatusCode,
42076			Header: res.Header,
42077		}
42078	}
42079	if err != nil {
42080		return nil, err
42081	}
42082	defer googleapi.CloseBody(res)
42083	if err := googleapi.CheckResponse(res); err != nil {
42084		return nil, err
42085	}
42086	ret := &PlacementsListResponse{
42087		ServerResponse: googleapi.ServerResponse{
42088			Header:         res.Header,
42089			HTTPStatusCode: res.StatusCode,
42090		},
42091	}
42092	target := &ret
42093	if err := gensupport.DecodeResponse(target, res); err != nil {
42094		return nil, err
42095	}
42096	return ret, nil
42097	// {
42098	//   "description": "Retrieves a list of placements, possibly filtered. This method supports paging.",
42099	//   "flatPath": "userprofiles/{profileId}/placements",
42100	//   "httpMethod": "GET",
42101	//   "id": "dfareporting.placements.list",
42102	//   "parameterOrder": [
42103	//     "profileId"
42104	//   ],
42105	//   "parameters": {
42106	//     "advertiserIds": {
42107	//       "description": "Select only placements that belong to these advertisers.",
42108	//       "format": "int64",
42109	//       "location": "query",
42110	//       "repeated": true,
42111	//       "type": "string"
42112	//     },
42113	//     "archived": {
42114	//       "description": "Select only archived placements. Don't set this field to select both archived and non-archived placements.",
42115	//       "location": "query",
42116	//       "type": "boolean"
42117	//     },
42118	//     "campaignIds": {
42119	//       "description": "Select only placements that belong to these campaigns.",
42120	//       "format": "int64",
42121	//       "location": "query",
42122	//       "repeated": true,
42123	//       "type": "string"
42124	//     },
42125	//     "compatibilities": {
42126	//       "description": "Select only placements that are associated with these compatibilities. DISPLAY and DISPLAY_INTERSTITIAL refer to rendering either on desktop or on mobile devices for regular or interstitial ads respectively. APP and APP_INTERSTITIAL are for rendering in mobile apps. IN_STREAM_VIDEO refers to rendering in in-stream video ads developed with the VAST standard.",
42127	//       "enum": [
42128	//         "DISPLAY",
42129	//         "DISPLAY_INTERSTITIAL",
42130	//         "APP",
42131	//         "APP_INTERSTITIAL",
42132	//         "IN_STREAM_VIDEO",
42133	//         "IN_STREAM_AUDIO"
42134	//       ],
42135	//       "enumDescriptions": [
42136	//         "",
42137	//         "",
42138	//         "",
42139	//         "",
42140	//         "",
42141	//         ""
42142	//       ],
42143	//       "location": "query",
42144	//       "repeated": true,
42145	//       "type": "string"
42146	//     },
42147	//     "contentCategoryIds": {
42148	//       "description": "Select only placements that are associated with these content categories.",
42149	//       "format": "int64",
42150	//       "location": "query",
42151	//       "repeated": true,
42152	//       "type": "string"
42153	//     },
42154	//     "directorySiteIds": {
42155	//       "description": "Select only placements that are associated with these directory sites.",
42156	//       "format": "int64",
42157	//       "location": "query",
42158	//       "repeated": true,
42159	//       "type": "string"
42160	//     },
42161	//     "groupIds": {
42162	//       "description": "Select only placements that belong to these placement groups.",
42163	//       "format": "int64",
42164	//       "location": "query",
42165	//       "repeated": true,
42166	//       "type": "string"
42167	//     },
42168	//     "ids": {
42169	//       "description": "Select only placements with these IDs.",
42170	//       "format": "int64",
42171	//       "location": "query",
42172	//       "repeated": true,
42173	//       "type": "string"
42174	//     },
42175	//     "maxEndDate": {
42176	//       "description": "Select only placements or placement groups whose end date is on or before the specified maxEndDate. The date should be formatted as \"yyyy-MM-dd\".",
42177	//       "location": "query",
42178	//       "type": "string"
42179	//     },
42180	//     "maxResults": {
42181	//       "default": "1000",
42182	//       "description": "Maximum number of results to return.",
42183	//       "format": "int32",
42184	//       "location": "query",
42185	//       "maximum": "1000",
42186	//       "minimum": "0",
42187	//       "type": "integer"
42188	//     },
42189	//     "maxStartDate": {
42190	//       "description": "Select only placements or placement groups whose start date is on or before the specified maxStartDate. The date should be formatted as \"yyyy-MM-dd\".",
42191	//       "location": "query",
42192	//       "type": "string"
42193	//     },
42194	//     "minEndDate": {
42195	//       "description": "Select only placements or placement groups whose end date is on or after the specified minEndDate. The date should be formatted as \"yyyy-MM-dd\".",
42196	//       "location": "query",
42197	//       "type": "string"
42198	//     },
42199	//     "minStartDate": {
42200	//       "description": "Select only placements or placement groups whose start date is on or after the specified minStartDate. The date should be formatted as \"yyyy-MM-dd\".",
42201	//       "location": "query",
42202	//       "type": "string"
42203	//     },
42204	//     "pageToken": {
42205	//       "description": "Value of the nextPageToken from the previous result page.",
42206	//       "location": "query",
42207	//       "type": "string"
42208	//     },
42209	//     "paymentSource": {
42210	//       "description": "Select only placements with this payment source.",
42211	//       "enum": [
42212	//         "PLACEMENT_AGENCY_PAID",
42213	//         "PLACEMENT_PUBLISHER_PAID"
42214	//       ],
42215	//       "enumDescriptions": [
42216	//         "",
42217	//         ""
42218	//       ],
42219	//       "location": "query",
42220	//       "type": "string"
42221	//     },
42222	//     "placementStrategyIds": {
42223	//       "description": "Select only placements that are associated with these placement strategies.",
42224	//       "format": "int64",
42225	//       "location": "query",
42226	//       "repeated": true,
42227	//       "type": "string"
42228	//     },
42229	//     "pricingTypes": {
42230	//       "description": "Select only placements with these pricing types.",
42231	//       "enum": [
42232	//         "PRICING_TYPE_CPM",
42233	//         "PRICING_TYPE_CPC",
42234	//         "PRICING_TYPE_CPA",
42235	//         "PRICING_TYPE_FLAT_RATE_IMPRESSIONS",
42236	//         "PRICING_TYPE_FLAT_RATE_CLICKS",
42237	//         "PRICING_TYPE_CPM_ACTIVEVIEW"
42238	//       ],
42239	//       "enumDescriptions": [
42240	//         "",
42241	//         "",
42242	//         "",
42243	//         "",
42244	//         "",
42245	//         ""
42246	//       ],
42247	//       "location": "query",
42248	//       "repeated": true,
42249	//       "type": "string"
42250	//     },
42251	//     "profileId": {
42252	//       "description": "User profile ID associated with this request.",
42253	//       "format": "int64",
42254	//       "location": "path",
42255	//       "required": true,
42256	//       "type": "string"
42257	//     },
42258	//     "searchString": {
42259	//       "description": "Allows searching for placements by name or ID. Wildcards (*) are allowed. For example, \"placement*2015\" will return placements with names like \"placement June 2015\", \"placement May 2015\", or simply \"placements 2015\". Most of the searches also add wildcards implicitly at the start and the end of the search string. For example, a search string of \"placement\" will match placements with name \"my placement\", \"placement 2015\", or simply \"placement\" .",
42260	//       "location": "query",
42261	//       "type": "string"
42262	//     },
42263	//     "siteIds": {
42264	//       "description": "Select only placements that are associated with these sites.",
42265	//       "format": "int64",
42266	//       "location": "query",
42267	//       "repeated": true,
42268	//       "type": "string"
42269	//     },
42270	//     "sizeIds": {
42271	//       "description": "Select only placements that are associated with these sizes.",
42272	//       "format": "int64",
42273	//       "location": "query",
42274	//       "repeated": true,
42275	//       "type": "string"
42276	//     },
42277	//     "sortField": {
42278	//       "default": "ID",
42279	//       "description": "Field by which to sort the list.",
42280	//       "enum": [
42281	//         "ID",
42282	//         "NAME"
42283	//       ],
42284	//       "enumDescriptions": [
42285	//         "",
42286	//         ""
42287	//       ],
42288	//       "location": "query",
42289	//       "type": "string"
42290	//     },
42291	//     "sortOrder": {
42292	//       "default": "ASCENDING",
42293	//       "description": "Order of sorted results.",
42294	//       "enum": [
42295	//         "ASCENDING",
42296	//         "DESCENDING"
42297	//       ],
42298	//       "enumDescriptions": [
42299	//         "",
42300	//         ""
42301	//       ],
42302	//       "location": "query",
42303	//       "type": "string"
42304	//     }
42305	//   },
42306	//   "path": "userprofiles/{profileId}/placements",
42307	//   "response": {
42308	//     "$ref": "PlacementsListResponse"
42309	//   },
42310	//   "scopes": [
42311	//     "https://www.googleapis.com/auth/dfatrafficking"
42312	//   ]
42313	// }
42314
42315}
42316
42317// Pages invokes f for each page of results.
42318// A non-nil error returned from f will halt the iteration.
42319// The provided context supersedes any context provided to the Context method.
42320func (c *PlacementsListCall) Pages(ctx context.Context, f func(*PlacementsListResponse) error) error {
42321	c.ctx_ = ctx
42322	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
42323	for {
42324		x, err := c.Do()
42325		if err != nil {
42326			return err
42327		}
42328		if err := f(x); err != nil {
42329			return err
42330		}
42331		if x.NextPageToken == "" {
42332			return nil
42333		}
42334		c.PageToken(x.NextPageToken)
42335	}
42336}
42337
42338// method id "dfareporting.placements.patch":
42339
42340type PlacementsPatchCall struct {
42341	s          *Service
42342	profileId  int64
42343	placement  *Placement
42344	urlParams_ gensupport.URLParams
42345	ctx_       context.Context
42346	header_    http.Header
42347}
42348
42349// Patch: Updates an existing placement. This method supports patch
42350// semantics.
42351//
42352// - id: Placement ID.
42353// - profileId: User profile ID associated with this request.
42354func (r *PlacementsService) Patch(profileId int64, id int64, placement *Placement) *PlacementsPatchCall {
42355	c := &PlacementsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
42356	c.profileId = profileId
42357	c.urlParams_.Set("id", fmt.Sprint(id))
42358	c.placement = placement
42359	return c
42360}
42361
42362// Fields allows partial responses to be retrieved. See
42363// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
42364// for more information.
42365func (c *PlacementsPatchCall) Fields(s ...googleapi.Field) *PlacementsPatchCall {
42366	c.urlParams_.Set("fields", googleapi.CombineFields(s))
42367	return c
42368}
42369
42370// Context sets the context to be used in this call's Do method. Any
42371// pending HTTP request will be aborted if the provided context is
42372// canceled.
42373func (c *PlacementsPatchCall) Context(ctx context.Context) *PlacementsPatchCall {
42374	c.ctx_ = ctx
42375	return c
42376}
42377
42378// Header returns an http.Header that can be modified by the caller to
42379// add HTTP headers to the request.
42380func (c *PlacementsPatchCall) Header() http.Header {
42381	if c.header_ == nil {
42382		c.header_ = make(http.Header)
42383	}
42384	return c.header_
42385}
42386
42387func (c *PlacementsPatchCall) doRequest(alt string) (*http.Response, error) {
42388	reqHeaders := make(http.Header)
42389	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
42390	for k, v := range c.header_ {
42391		reqHeaders[k] = v
42392	}
42393	reqHeaders.Set("User-Agent", c.s.userAgent())
42394	var body io.Reader = nil
42395	body, err := googleapi.WithoutDataWrapper.JSONReader(c.placement)
42396	if err != nil {
42397		return nil, err
42398	}
42399	reqHeaders.Set("Content-Type", "application/json")
42400	c.urlParams_.Set("alt", alt)
42401	c.urlParams_.Set("prettyPrint", "false")
42402	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/placements")
42403	urls += "?" + c.urlParams_.Encode()
42404	req, err := http.NewRequest("PATCH", urls, body)
42405	if err != nil {
42406		return nil, err
42407	}
42408	req.Header = reqHeaders
42409	googleapi.Expand(req.URL, map[string]string{
42410		"profileId": strconv.FormatInt(c.profileId, 10),
42411	})
42412	return gensupport.SendRequest(c.ctx_, c.s.client, req)
42413}
42414
42415// Do executes the "dfareporting.placements.patch" call.
42416// Exactly one of *Placement or error will be non-nil. Any non-2xx
42417// status code is an error. Response headers are in either
42418// *Placement.ServerResponse.Header or (if a response was returned at
42419// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
42420// to check whether the returned error was because
42421// http.StatusNotModified was returned.
42422func (c *PlacementsPatchCall) Do(opts ...googleapi.CallOption) (*Placement, error) {
42423	gensupport.SetOptions(c.urlParams_, opts...)
42424	res, err := c.doRequest("json")
42425	if res != nil && res.StatusCode == http.StatusNotModified {
42426		if res.Body != nil {
42427			res.Body.Close()
42428		}
42429		return nil, &googleapi.Error{
42430			Code:   res.StatusCode,
42431			Header: res.Header,
42432		}
42433	}
42434	if err != nil {
42435		return nil, err
42436	}
42437	defer googleapi.CloseBody(res)
42438	if err := googleapi.CheckResponse(res); err != nil {
42439		return nil, err
42440	}
42441	ret := &Placement{
42442		ServerResponse: googleapi.ServerResponse{
42443			Header:         res.Header,
42444			HTTPStatusCode: res.StatusCode,
42445		},
42446	}
42447	target := &ret
42448	if err := gensupport.DecodeResponse(target, res); err != nil {
42449		return nil, err
42450	}
42451	return ret, nil
42452	// {
42453	//   "description": "Updates an existing placement. This method supports patch semantics.",
42454	//   "flatPath": "userprofiles/{profileId}/placements",
42455	//   "httpMethod": "PATCH",
42456	//   "id": "dfareporting.placements.patch",
42457	//   "parameterOrder": [
42458	//     "profileId",
42459	//     "id"
42460	//   ],
42461	//   "parameters": {
42462	//     "id": {
42463	//       "description": "Placement ID.",
42464	//       "format": "int64",
42465	//       "location": "query",
42466	//       "required": true,
42467	//       "type": "string"
42468	//     },
42469	//     "profileId": {
42470	//       "description": "User profile ID associated with this request.",
42471	//       "format": "int64",
42472	//       "location": "path",
42473	//       "required": true,
42474	//       "type": "string"
42475	//     }
42476	//   },
42477	//   "path": "userprofiles/{profileId}/placements",
42478	//   "request": {
42479	//     "$ref": "Placement"
42480	//   },
42481	//   "response": {
42482	//     "$ref": "Placement"
42483	//   },
42484	//   "scopes": [
42485	//     "https://www.googleapis.com/auth/dfatrafficking"
42486	//   ]
42487	// }
42488
42489}
42490
42491// method id "dfareporting.placements.update":
42492
42493type PlacementsUpdateCall struct {
42494	s          *Service
42495	profileId  int64
42496	placement  *Placement
42497	urlParams_ gensupport.URLParams
42498	ctx_       context.Context
42499	header_    http.Header
42500}
42501
42502// Update: Updates an existing placement.
42503//
42504// - profileId: User profile ID associated with this request.
42505func (r *PlacementsService) Update(profileId int64, placement *Placement) *PlacementsUpdateCall {
42506	c := &PlacementsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
42507	c.profileId = profileId
42508	c.placement = placement
42509	return c
42510}
42511
42512// Fields allows partial responses to be retrieved. See
42513// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
42514// for more information.
42515func (c *PlacementsUpdateCall) Fields(s ...googleapi.Field) *PlacementsUpdateCall {
42516	c.urlParams_.Set("fields", googleapi.CombineFields(s))
42517	return c
42518}
42519
42520// Context sets the context to be used in this call's Do method. Any
42521// pending HTTP request will be aborted if the provided context is
42522// canceled.
42523func (c *PlacementsUpdateCall) Context(ctx context.Context) *PlacementsUpdateCall {
42524	c.ctx_ = ctx
42525	return c
42526}
42527
42528// Header returns an http.Header that can be modified by the caller to
42529// add HTTP headers to the request.
42530func (c *PlacementsUpdateCall) Header() http.Header {
42531	if c.header_ == nil {
42532		c.header_ = make(http.Header)
42533	}
42534	return c.header_
42535}
42536
42537func (c *PlacementsUpdateCall) doRequest(alt string) (*http.Response, error) {
42538	reqHeaders := make(http.Header)
42539	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
42540	for k, v := range c.header_ {
42541		reqHeaders[k] = v
42542	}
42543	reqHeaders.Set("User-Agent", c.s.userAgent())
42544	var body io.Reader = nil
42545	body, err := googleapi.WithoutDataWrapper.JSONReader(c.placement)
42546	if err != nil {
42547		return nil, err
42548	}
42549	reqHeaders.Set("Content-Type", "application/json")
42550	c.urlParams_.Set("alt", alt)
42551	c.urlParams_.Set("prettyPrint", "false")
42552	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/placements")
42553	urls += "?" + c.urlParams_.Encode()
42554	req, err := http.NewRequest("PUT", urls, body)
42555	if err != nil {
42556		return nil, err
42557	}
42558	req.Header = reqHeaders
42559	googleapi.Expand(req.URL, map[string]string{
42560		"profileId": strconv.FormatInt(c.profileId, 10),
42561	})
42562	return gensupport.SendRequest(c.ctx_, c.s.client, req)
42563}
42564
42565// Do executes the "dfareporting.placements.update" call.
42566// Exactly one of *Placement or error will be non-nil. Any non-2xx
42567// status code is an error. Response headers are in either
42568// *Placement.ServerResponse.Header or (if a response was returned at
42569// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
42570// to check whether the returned error was because
42571// http.StatusNotModified was returned.
42572func (c *PlacementsUpdateCall) Do(opts ...googleapi.CallOption) (*Placement, error) {
42573	gensupport.SetOptions(c.urlParams_, opts...)
42574	res, err := c.doRequest("json")
42575	if res != nil && res.StatusCode == http.StatusNotModified {
42576		if res.Body != nil {
42577			res.Body.Close()
42578		}
42579		return nil, &googleapi.Error{
42580			Code:   res.StatusCode,
42581			Header: res.Header,
42582		}
42583	}
42584	if err != nil {
42585		return nil, err
42586	}
42587	defer googleapi.CloseBody(res)
42588	if err := googleapi.CheckResponse(res); err != nil {
42589		return nil, err
42590	}
42591	ret := &Placement{
42592		ServerResponse: googleapi.ServerResponse{
42593			Header:         res.Header,
42594			HTTPStatusCode: res.StatusCode,
42595		},
42596	}
42597	target := &ret
42598	if err := gensupport.DecodeResponse(target, res); err != nil {
42599		return nil, err
42600	}
42601	return ret, nil
42602	// {
42603	//   "description": "Updates an existing placement.",
42604	//   "flatPath": "userprofiles/{profileId}/placements",
42605	//   "httpMethod": "PUT",
42606	//   "id": "dfareporting.placements.update",
42607	//   "parameterOrder": [
42608	//     "profileId"
42609	//   ],
42610	//   "parameters": {
42611	//     "profileId": {
42612	//       "description": "User profile ID associated with this request.",
42613	//       "format": "int64",
42614	//       "location": "path",
42615	//       "required": true,
42616	//       "type": "string"
42617	//     }
42618	//   },
42619	//   "path": "userprofiles/{profileId}/placements",
42620	//   "request": {
42621	//     "$ref": "Placement"
42622	//   },
42623	//   "response": {
42624	//     "$ref": "Placement"
42625	//   },
42626	//   "scopes": [
42627	//     "https://www.googleapis.com/auth/dfatrafficking"
42628	//   ]
42629	// }
42630
42631}
42632
42633// method id "dfareporting.platformTypes.get":
42634
42635type PlatformTypesGetCall struct {
42636	s            *Service
42637	profileId    int64
42638	id           int64
42639	urlParams_   gensupport.URLParams
42640	ifNoneMatch_ string
42641	ctx_         context.Context
42642	header_      http.Header
42643}
42644
42645// Get: Gets one platform type by ID.
42646//
42647// - id: Platform type ID.
42648// - profileId: User profile ID associated with this request.
42649func (r *PlatformTypesService) Get(profileId int64, id int64) *PlatformTypesGetCall {
42650	c := &PlatformTypesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
42651	c.profileId = profileId
42652	c.id = id
42653	return c
42654}
42655
42656// Fields allows partial responses to be retrieved. See
42657// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
42658// for more information.
42659func (c *PlatformTypesGetCall) Fields(s ...googleapi.Field) *PlatformTypesGetCall {
42660	c.urlParams_.Set("fields", googleapi.CombineFields(s))
42661	return c
42662}
42663
42664// IfNoneMatch sets the optional parameter which makes the operation
42665// fail if the object's ETag matches the given value. This is useful for
42666// getting updates only after the object has changed since the last
42667// request. Use googleapi.IsNotModified to check whether the response
42668// error from Do is the result of In-None-Match.
42669func (c *PlatformTypesGetCall) IfNoneMatch(entityTag string) *PlatformTypesGetCall {
42670	c.ifNoneMatch_ = entityTag
42671	return c
42672}
42673
42674// Context sets the context to be used in this call's Do method. Any
42675// pending HTTP request will be aborted if the provided context is
42676// canceled.
42677func (c *PlatformTypesGetCall) Context(ctx context.Context) *PlatformTypesGetCall {
42678	c.ctx_ = ctx
42679	return c
42680}
42681
42682// Header returns an http.Header that can be modified by the caller to
42683// add HTTP headers to the request.
42684func (c *PlatformTypesGetCall) Header() http.Header {
42685	if c.header_ == nil {
42686		c.header_ = make(http.Header)
42687	}
42688	return c.header_
42689}
42690
42691func (c *PlatformTypesGetCall) doRequest(alt string) (*http.Response, error) {
42692	reqHeaders := make(http.Header)
42693	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
42694	for k, v := range c.header_ {
42695		reqHeaders[k] = v
42696	}
42697	reqHeaders.Set("User-Agent", c.s.userAgent())
42698	if c.ifNoneMatch_ != "" {
42699		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
42700	}
42701	var body io.Reader = nil
42702	c.urlParams_.Set("alt", alt)
42703	c.urlParams_.Set("prettyPrint", "false")
42704	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/platformTypes/{id}")
42705	urls += "?" + c.urlParams_.Encode()
42706	req, err := http.NewRequest("GET", urls, body)
42707	if err != nil {
42708		return nil, err
42709	}
42710	req.Header = reqHeaders
42711	googleapi.Expand(req.URL, map[string]string{
42712		"profileId": strconv.FormatInt(c.profileId, 10),
42713		"id":        strconv.FormatInt(c.id, 10),
42714	})
42715	return gensupport.SendRequest(c.ctx_, c.s.client, req)
42716}
42717
42718// Do executes the "dfareporting.platformTypes.get" call.
42719// Exactly one of *PlatformType or error will be non-nil. Any non-2xx
42720// status code is an error. Response headers are in either
42721// *PlatformType.ServerResponse.Header or (if a response was returned at
42722// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
42723// to check whether the returned error was because
42724// http.StatusNotModified was returned.
42725func (c *PlatformTypesGetCall) Do(opts ...googleapi.CallOption) (*PlatformType, error) {
42726	gensupport.SetOptions(c.urlParams_, opts...)
42727	res, err := c.doRequest("json")
42728	if res != nil && res.StatusCode == http.StatusNotModified {
42729		if res.Body != nil {
42730			res.Body.Close()
42731		}
42732		return nil, &googleapi.Error{
42733			Code:   res.StatusCode,
42734			Header: res.Header,
42735		}
42736	}
42737	if err != nil {
42738		return nil, err
42739	}
42740	defer googleapi.CloseBody(res)
42741	if err := googleapi.CheckResponse(res); err != nil {
42742		return nil, err
42743	}
42744	ret := &PlatformType{
42745		ServerResponse: googleapi.ServerResponse{
42746			Header:         res.Header,
42747			HTTPStatusCode: res.StatusCode,
42748		},
42749	}
42750	target := &ret
42751	if err := gensupport.DecodeResponse(target, res); err != nil {
42752		return nil, err
42753	}
42754	return ret, nil
42755	// {
42756	//   "description": "Gets one platform type by ID.",
42757	//   "flatPath": "userprofiles/{profileId}/platformTypes/{id}",
42758	//   "httpMethod": "GET",
42759	//   "id": "dfareporting.platformTypes.get",
42760	//   "parameterOrder": [
42761	//     "profileId",
42762	//     "id"
42763	//   ],
42764	//   "parameters": {
42765	//     "id": {
42766	//       "description": "Platform type ID.",
42767	//       "format": "int64",
42768	//       "location": "path",
42769	//       "required": true,
42770	//       "type": "string"
42771	//     },
42772	//     "profileId": {
42773	//       "description": "User profile ID associated with this request.",
42774	//       "format": "int64",
42775	//       "location": "path",
42776	//       "required": true,
42777	//       "type": "string"
42778	//     }
42779	//   },
42780	//   "path": "userprofiles/{profileId}/platformTypes/{id}",
42781	//   "response": {
42782	//     "$ref": "PlatformType"
42783	//   },
42784	//   "scopes": [
42785	//     "https://www.googleapis.com/auth/dfatrafficking"
42786	//   ]
42787	// }
42788
42789}
42790
42791// method id "dfareporting.platformTypes.list":
42792
42793type PlatformTypesListCall struct {
42794	s            *Service
42795	profileId    int64
42796	urlParams_   gensupport.URLParams
42797	ifNoneMatch_ string
42798	ctx_         context.Context
42799	header_      http.Header
42800}
42801
42802// List: Retrieves a list of platform types.
42803//
42804// - profileId: User profile ID associated with this request.
42805func (r *PlatformTypesService) List(profileId int64) *PlatformTypesListCall {
42806	c := &PlatformTypesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
42807	c.profileId = profileId
42808	return c
42809}
42810
42811// Fields allows partial responses to be retrieved. See
42812// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
42813// for more information.
42814func (c *PlatformTypesListCall) Fields(s ...googleapi.Field) *PlatformTypesListCall {
42815	c.urlParams_.Set("fields", googleapi.CombineFields(s))
42816	return c
42817}
42818
42819// IfNoneMatch sets the optional parameter which makes the operation
42820// fail if the object's ETag matches the given value. This is useful for
42821// getting updates only after the object has changed since the last
42822// request. Use googleapi.IsNotModified to check whether the response
42823// error from Do is the result of In-None-Match.
42824func (c *PlatformTypesListCall) IfNoneMatch(entityTag string) *PlatformTypesListCall {
42825	c.ifNoneMatch_ = entityTag
42826	return c
42827}
42828
42829// Context sets the context to be used in this call's Do method. Any
42830// pending HTTP request will be aborted if the provided context is
42831// canceled.
42832func (c *PlatformTypesListCall) Context(ctx context.Context) *PlatformTypesListCall {
42833	c.ctx_ = ctx
42834	return c
42835}
42836
42837// Header returns an http.Header that can be modified by the caller to
42838// add HTTP headers to the request.
42839func (c *PlatformTypesListCall) Header() http.Header {
42840	if c.header_ == nil {
42841		c.header_ = make(http.Header)
42842	}
42843	return c.header_
42844}
42845
42846func (c *PlatformTypesListCall) doRequest(alt string) (*http.Response, error) {
42847	reqHeaders := make(http.Header)
42848	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
42849	for k, v := range c.header_ {
42850		reqHeaders[k] = v
42851	}
42852	reqHeaders.Set("User-Agent", c.s.userAgent())
42853	if c.ifNoneMatch_ != "" {
42854		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
42855	}
42856	var body io.Reader = nil
42857	c.urlParams_.Set("alt", alt)
42858	c.urlParams_.Set("prettyPrint", "false")
42859	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/platformTypes")
42860	urls += "?" + c.urlParams_.Encode()
42861	req, err := http.NewRequest("GET", urls, body)
42862	if err != nil {
42863		return nil, err
42864	}
42865	req.Header = reqHeaders
42866	googleapi.Expand(req.URL, map[string]string{
42867		"profileId": strconv.FormatInt(c.profileId, 10),
42868	})
42869	return gensupport.SendRequest(c.ctx_, c.s.client, req)
42870}
42871
42872// Do executes the "dfareporting.platformTypes.list" call.
42873// Exactly one of *PlatformTypesListResponse or error will be non-nil.
42874// Any non-2xx status code is an error. Response headers are in either
42875// *PlatformTypesListResponse.ServerResponse.Header or (if a response
42876// was returned at all) in error.(*googleapi.Error).Header. Use
42877// googleapi.IsNotModified to check whether the returned error was
42878// because http.StatusNotModified was returned.
42879func (c *PlatformTypesListCall) Do(opts ...googleapi.CallOption) (*PlatformTypesListResponse, error) {
42880	gensupport.SetOptions(c.urlParams_, opts...)
42881	res, err := c.doRequest("json")
42882	if res != nil && res.StatusCode == http.StatusNotModified {
42883		if res.Body != nil {
42884			res.Body.Close()
42885		}
42886		return nil, &googleapi.Error{
42887			Code:   res.StatusCode,
42888			Header: res.Header,
42889		}
42890	}
42891	if err != nil {
42892		return nil, err
42893	}
42894	defer googleapi.CloseBody(res)
42895	if err := googleapi.CheckResponse(res); err != nil {
42896		return nil, err
42897	}
42898	ret := &PlatformTypesListResponse{
42899		ServerResponse: googleapi.ServerResponse{
42900			Header:         res.Header,
42901			HTTPStatusCode: res.StatusCode,
42902		},
42903	}
42904	target := &ret
42905	if err := gensupport.DecodeResponse(target, res); err != nil {
42906		return nil, err
42907	}
42908	return ret, nil
42909	// {
42910	//   "description": "Retrieves a list of platform types.",
42911	//   "flatPath": "userprofiles/{profileId}/platformTypes",
42912	//   "httpMethod": "GET",
42913	//   "id": "dfareporting.platformTypes.list",
42914	//   "parameterOrder": [
42915	//     "profileId"
42916	//   ],
42917	//   "parameters": {
42918	//     "profileId": {
42919	//       "description": "User profile ID associated with this request.",
42920	//       "format": "int64",
42921	//       "location": "path",
42922	//       "required": true,
42923	//       "type": "string"
42924	//     }
42925	//   },
42926	//   "path": "userprofiles/{profileId}/platformTypes",
42927	//   "response": {
42928	//     "$ref": "PlatformTypesListResponse"
42929	//   },
42930	//   "scopes": [
42931	//     "https://www.googleapis.com/auth/dfatrafficking"
42932	//   ]
42933	// }
42934
42935}
42936
42937// method id "dfareporting.postalCodes.get":
42938
42939type PostalCodesGetCall struct {
42940	s            *Service
42941	profileId    int64
42942	code         string
42943	urlParams_   gensupport.URLParams
42944	ifNoneMatch_ string
42945	ctx_         context.Context
42946	header_      http.Header
42947}
42948
42949// Get: Gets one postal code by ID.
42950//
42951// - code: Postal code ID.
42952// - profileId: User profile ID associated with this request.
42953func (r *PostalCodesService) Get(profileId int64, code string) *PostalCodesGetCall {
42954	c := &PostalCodesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
42955	c.profileId = profileId
42956	c.code = code
42957	return c
42958}
42959
42960// Fields allows partial responses to be retrieved. See
42961// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
42962// for more information.
42963func (c *PostalCodesGetCall) Fields(s ...googleapi.Field) *PostalCodesGetCall {
42964	c.urlParams_.Set("fields", googleapi.CombineFields(s))
42965	return c
42966}
42967
42968// IfNoneMatch sets the optional parameter which makes the operation
42969// fail if the object's ETag matches the given value. This is useful for
42970// getting updates only after the object has changed since the last
42971// request. Use googleapi.IsNotModified to check whether the response
42972// error from Do is the result of In-None-Match.
42973func (c *PostalCodesGetCall) IfNoneMatch(entityTag string) *PostalCodesGetCall {
42974	c.ifNoneMatch_ = entityTag
42975	return c
42976}
42977
42978// Context sets the context to be used in this call's Do method. Any
42979// pending HTTP request will be aborted if the provided context is
42980// canceled.
42981func (c *PostalCodesGetCall) Context(ctx context.Context) *PostalCodesGetCall {
42982	c.ctx_ = ctx
42983	return c
42984}
42985
42986// Header returns an http.Header that can be modified by the caller to
42987// add HTTP headers to the request.
42988func (c *PostalCodesGetCall) Header() http.Header {
42989	if c.header_ == nil {
42990		c.header_ = make(http.Header)
42991	}
42992	return c.header_
42993}
42994
42995func (c *PostalCodesGetCall) doRequest(alt string) (*http.Response, error) {
42996	reqHeaders := make(http.Header)
42997	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
42998	for k, v := range c.header_ {
42999		reqHeaders[k] = v
43000	}
43001	reqHeaders.Set("User-Agent", c.s.userAgent())
43002	if c.ifNoneMatch_ != "" {
43003		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
43004	}
43005	var body io.Reader = nil
43006	c.urlParams_.Set("alt", alt)
43007	c.urlParams_.Set("prettyPrint", "false")
43008	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/postalCodes/{code}")
43009	urls += "?" + c.urlParams_.Encode()
43010	req, err := http.NewRequest("GET", urls, body)
43011	if err != nil {
43012		return nil, err
43013	}
43014	req.Header = reqHeaders
43015	googleapi.Expand(req.URL, map[string]string{
43016		"profileId": strconv.FormatInt(c.profileId, 10),
43017		"code":      c.code,
43018	})
43019	return gensupport.SendRequest(c.ctx_, c.s.client, req)
43020}
43021
43022// Do executes the "dfareporting.postalCodes.get" call.
43023// Exactly one of *PostalCode or error will be non-nil. Any non-2xx
43024// status code is an error. Response headers are in either
43025// *PostalCode.ServerResponse.Header or (if a response was returned at
43026// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
43027// to check whether the returned error was because
43028// http.StatusNotModified was returned.
43029func (c *PostalCodesGetCall) Do(opts ...googleapi.CallOption) (*PostalCode, error) {
43030	gensupport.SetOptions(c.urlParams_, opts...)
43031	res, err := c.doRequest("json")
43032	if res != nil && res.StatusCode == http.StatusNotModified {
43033		if res.Body != nil {
43034			res.Body.Close()
43035		}
43036		return nil, &googleapi.Error{
43037			Code:   res.StatusCode,
43038			Header: res.Header,
43039		}
43040	}
43041	if err != nil {
43042		return nil, err
43043	}
43044	defer googleapi.CloseBody(res)
43045	if err := googleapi.CheckResponse(res); err != nil {
43046		return nil, err
43047	}
43048	ret := &PostalCode{
43049		ServerResponse: googleapi.ServerResponse{
43050			Header:         res.Header,
43051			HTTPStatusCode: res.StatusCode,
43052		},
43053	}
43054	target := &ret
43055	if err := gensupport.DecodeResponse(target, res); err != nil {
43056		return nil, err
43057	}
43058	return ret, nil
43059	// {
43060	//   "description": "Gets one postal code by ID.",
43061	//   "flatPath": "userprofiles/{profileId}/postalCodes/{code}",
43062	//   "httpMethod": "GET",
43063	//   "id": "dfareporting.postalCodes.get",
43064	//   "parameterOrder": [
43065	//     "profileId",
43066	//     "code"
43067	//   ],
43068	//   "parameters": {
43069	//     "code": {
43070	//       "description": "Postal code ID.",
43071	//       "location": "path",
43072	//       "required": true,
43073	//       "type": "string"
43074	//     },
43075	//     "profileId": {
43076	//       "description": "User profile ID associated with this request.",
43077	//       "format": "int64",
43078	//       "location": "path",
43079	//       "required": true,
43080	//       "type": "string"
43081	//     }
43082	//   },
43083	//   "path": "userprofiles/{profileId}/postalCodes/{code}",
43084	//   "response": {
43085	//     "$ref": "PostalCode"
43086	//   },
43087	//   "scopes": [
43088	//     "https://www.googleapis.com/auth/dfatrafficking"
43089	//   ]
43090	// }
43091
43092}
43093
43094// method id "dfareporting.postalCodes.list":
43095
43096type PostalCodesListCall struct {
43097	s            *Service
43098	profileId    int64
43099	urlParams_   gensupport.URLParams
43100	ifNoneMatch_ string
43101	ctx_         context.Context
43102	header_      http.Header
43103}
43104
43105// List: Retrieves a list of postal codes.
43106//
43107// - profileId: User profile ID associated with this request.
43108func (r *PostalCodesService) List(profileId int64) *PostalCodesListCall {
43109	c := &PostalCodesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
43110	c.profileId = profileId
43111	return c
43112}
43113
43114// Fields allows partial responses to be retrieved. See
43115// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
43116// for more information.
43117func (c *PostalCodesListCall) Fields(s ...googleapi.Field) *PostalCodesListCall {
43118	c.urlParams_.Set("fields", googleapi.CombineFields(s))
43119	return c
43120}
43121
43122// IfNoneMatch sets the optional parameter which makes the operation
43123// fail if the object's ETag matches the given value. This is useful for
43124// getting updates only after the object has changed since the last
43125// request. Use googleapi.IsNotModified to check whether the response
43126// error from Do is the result of In-None-Match.
43127func (c *PostalCodesListCall) IfNoneMatch(entityTag string) *PostalCodesListCall {
43128	c.ifNoneMatch_ = entityTag
43129	return c
43130}
43131
43132// Context sets the context to be used in this call's Do method. Any
43133// pending HTTP request will be aborted if the provided context is
43134// canceled.
43135func (c *PostalCodesListCall) Context(ctx context.Context) *PostalCodesListCall {
43136	c.ctx_ = ctx
43137	return c
43138}
43139
43140// Header returns an http.Header that can be modified by the caller to
43141// add HTTP headers to the request.
43142func (c *PostalCodesListCall) Header() http.Header {
43143	if c.header_ == nil {
43144		c.header_ = make(http.Header)
43145	}
43146	return c.header_
43147}
43148
43149func (c *PostalCodesListCall) doRequest(alt string) (*http.Response, error) {
43150	reqHeaders := make(http.Header)
43151	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
43152	for k, v := range c.header_ {
43153		reqHeaders[k] = v
43154	}
43155	reqHeaders.Set("User-Agent", c.s.userAgent())
43156	if c.ifNoneMatch_ != "" {
43157		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
43158	}
43159	var body io.Reader = nil
43160	c.urlParams_.Set("alt", alt)
43161	c.urlParams_.Set("prettyPrint", "false")
43162	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/postalCodes")
43163	urls += "?" + c.urlParams_.Encode()
43164	req, err := http.NewRequest("GET", urls, body)
43165	if err != nil {
43166		return nil, err
43167	}
43168	req.Header = reqHeaders
43169	googleapi.Expand(req.URL, map[string]string{
43170		"profileId": strconv.FormatInt(c.profileId, 10),
43171	})
43172	return gensupport.SendRequest(c.ctx_, c.s.client, req)
43173}
43174
43175// Do executes the "dfareporting.postalCodes.list" call.
43176// Exactly one of *PostalCodesListResponse or error will be non-nil. Any
43177// non-2xx status code is an error. Response headers are in either
43178// *PostalCodesListResponse.ServerResponse.Header or (if a response was
43179// returned at all) in error.(*googleapi.Error).Header. Use
43180// googleapi.IsNotModified to check whether the returned error was
43181// because http.StatusNotModified was returned.
43182func (c *PostalCodesListCall) Do(opts ...googleapi.CallOption) (*PostalCodesListResponse, error) {
43183	gensupport.SetOptions(c.urlParams_, opts...)
43184	res, err := c.doRequest("json")
43185	if res != nil && res.StatusCode == http.StatusNotModified {
43186		if res.Body != nil {
43187			res.Body.Close()
43188		}
43189		return nil, &googleapi.Error{
43190			Code:   res.StatusCode,
43191			Header: res.Header,
43192		}
43193	}
43194	if err != nil {
43195		return nil, err
43196	}
43197	defer googleapi.CloseBody(res)
43198	if err := googleapi.CheckResponse(res); err != nil {
43199		return nil, err
43200	}
43201	ret := &PostalCodesListResponse{
43202		ServerResponse: googleapi.ServerResponse{
43203			Header:         res.Header,
43204			HTTPStatusCode: res.StatusCode,
43205		},
43206	}
43207	target := &ret
43208	if err := gensupport.DecodeResponse(target, res); err != nil {
43209		return nil, err
43210	}
43211	return ret, nil
43212	// {
43213	//   "description": "Retrieves a list of postal codes.",
43214	//   "flatPath": "userprofiles/{profileId}/postalCodes",
43215	//   "httpMethod": "GET",
43216	//   "id": "dfareporting.postalCodes.list",
43217	//   "parameterOrder": [
43218	//     "profileId"
43219	//   ],
43220	//   "parameters": {
43221	//     "profileId": {
43222	//       "description": "User profile ID associated with this request.",
43223	//       "format": "int64",
43224	//       "location": "path",
43225	//       "required": true,
43226	//       "type": "string"
43227	//     }
43228	//   },
43229	//   "path": "userprofiles/{profileId}/postalCodes",
43230	//   "response": {
43231	//     "$ref": "PostalCodesListResponse"
43232	//   },
43233	//   "scopes": [
43234	//     "https://www.googleapis.com/auth/dfatrafficking"
43235	//   ]
43236	// }
43237
43238}
43239
43240// method id "dfareporting.projects.get":
43241
43242type ProjectsGetCall struct {
43243	s            *Service
43244	profileId    int64
43245	id           int64
43246	urlParams_   gensupport.URLParams
43247	ifNoneMatch_ string
43248	ctx_         context.Context
43249	header_      http.Header
43250}
43251
43252// Get: Gets one project by ID.
43253//
43254// - id: Project ID.
43255// - profileId: User profile ID associated with this request.
43256func (r *ProjectsService) Get(profileId int64, id int64) *ProjectsGetCall {
43257	c := &ProjectsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
43258	c.profileId = profileId
43259	c.id = id
43260	return c
43261}
43262
43263// Fields allows partial responses to be retrieved. See
43264// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
43265// for more information.
43266func (c *ProjectsGetCall) Fields(s ...googleapi.Field) *ProjectsGetCall {
43267	c.urlParams_.Set("fields", googleapi.CombineFields(s))
43268	return c
43269}
43270
43271// IfNoneMatch sets the optional parameter which makes the operation
43272// fail if the object's ETag matches the given value. This is useful for
43273// getting updates only after the object has changed since the last
43274// request. Use googleapi.IsNotModified to check whether the response
43275// error from Do is the result of In-None-Match.
43276func (c *ProjectsGetCall) IfNoneMatch(entityTag string) *ProjectsGetCall {
43277	c.ifNoneMatch_ = entityTag
43278	return c
43279}
43280
43281// Context sets the context to be used in this call's Do method. Any
43282// pending HTTP request will be aborted if the provided context is
43283// canceled.
43284func (c *ProjectsGetCall) Context(ctx context.Context) *ProjectsGetCall {
43285	c.ctx_ = ctx
43286	return c
43287}
43288
43289// Header returns an http.Header that can be modified by the caller to
43290// add HTTP headers to the request.
43291func (c *ProjectsGetCall) Header() http.Header {
43292	if c.header_ == nil {
43293		c.header_ = make(http.Header)
43294	}
43295	return c.header_
43296}
43297
43298func (c *ProjectsGetCall) doRequest(alt string) (*http.Response, error) {
43299	reqHeaders := make(http.Header)
43300	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
43301	for k, v := range c.header_ {
43302		reqHeaders[k] = v
43303	}
43304	reqHeaders.Set("User-Agent", c.s.userAgent())
43305	if c.ifNoneMatch_ != "" {
43306		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
43307	}
43308	var body io.Reader = nil
43309	c.urlParams_.Set("alt", alt)
43310	c.urlParams_.Set("prettyPrint", "false")
43311	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/projects/{id}")
43312	urls += "?" + c.urlParams_.Encode()
43313	req, err := http.NewRequest("GET", urls, body)
43314	if err != nil {
43315		return nil, err
43316	}
43317	req.Header = reqHeaders
43318	googleapi.Expand(req.URL, map[string]string{
43319		"profileId": strconv.FormatInt(c.profileId, 10),
43320		"id":        strconv.FormatInt(c.id, 10),
43321	})
43322	return gensupport.SendRequest(c.ctx_, c.s.client, req)
43323}
43324
43325// Do executes the "dfareporting.projects.get" call.
43326// Exactly one of *Project or error will be non-nil. Any non-2xx status
43327// code is an error. Response headers are in either
43328// *Project.ServerResponse.Header or (if a response was returned at all)
43329// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to
43330// check whether the returned error was because http.StatusNotModified
43331// was returned.
43332func (c *ProjectsGetCall) Do(opts ...googleapi.CallOption) (*Project, error) {
43333	gensupport.SetOptions(c.urlParams_, opts...)
43334	res, err := c.doRequest("json")
43335	if res != nil && res.StatusCode == http.StatusNotModified {
43336		if res.Body != nil {
43337			res.Body.Close()
43338		}
43339		return nil, &googleapi.Error{
43340			Code:   res.StatusCode,
43341			Header: res.Header,
43342		}
43343	}
43344	if err != nil {
43345		return nil, err
43346	}
43347	defer googleapi.CloseBody(res)
43348	if err := googleapi.CheckResponse(res); err != nil {
43349		return nil, err
43350	}
43351	ret := &Project{
43352		ServerResponse: googleapi.ServerResponse{
43353			Header:         res.Header,
43354			HTTPStatusCode: res.StatusCode,
43355		},
43356	}
43357	target := &ret
43358	if err := gensupport.DecodeResponse(target, res); err != nil {
43359		return nil, err
43360	}
43361	return ret, nil
43362	// {
43363	//   "description": "Gets one project by ID.",
43364	//   "flatPath": "userprofiles/{profileId}/projects/{id}",
43365	//   "httpMethod": "GET",
43366	//   "id": "dfareporting.projects.get",
43367	//   "parameterOrder": [
43368	//     "profileId",
43369	//     "id"
43370	//   ],
43371	//   "parameters": {
43372	//     "id": {
43373	//       "description": "Project ID.",
43374	//       "format": "int64",
43375	//       "location": "path",
43376	//       "required": true,
43377	//       "type": "string"
43378	//     },
43379	//     "profileId": {
43380	//       "description": "User profile ID associated with this request.",
43381	//       "format": "int64",
43382	//       "location": "path",
43383	//       "required": true,
43384	//       "type": "string"
43385	//     }
43386	//   },
43387	//   "path": "userprofiles/{profileId}/projects/{id}",
43388	//   "response": {
43389	//     "$ref": "Project"
43390	//   },
43391	//   "scopes": [
43392	//     "https://www.googleapis.com/auth/dfatrafficking"
43393	//   ]
43394	// }
43395
43396}
43397
43398// method id "dfareporting.projects.list":
43399
43400type ProjectsListCall struct {
43401	s            *Service
43402	profileId    int64
43403	urlParams_   gensupport.URLParams
43404	ifNoneMatch_ string
43405	ctx_         context.Context
43406	header_      http.Header
43407}
43408
43409// List: Retrieves a list of projects, possibly filtered. This method
43410// supports paging .
43411//
43412// - profileId: User profile ID associated with this request.
43413func (r *ProjectsService) List(profileId int64) *ProjectsListCall {
43414	c := &ProjectsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
43415	c.profileId = profileId
43416	return c
43417}
43418
43419// AdvertiserIds sets the optional parameter "advertiserIds": Select
43420// only projects with these advertiser IDs.
43421func (c *ProjectsListCall) AdvertiserIds(advertiserIds ...int64) *ProjectsListCall {
43422	var advertiserIds_ []string
43423	for _, v := range advertiserIds {
43424		advertiserIds_ = append(advertiserIds_, fmt.Sprint(v))
43425	}
43426	c.urlParams_.SetMulti("advertiserIds", advertiserIds_)
43427	return c
43428}
43429
43430// Ids sets the optional parameter "ids": Select only projects with
43431// these IDs.
43432func (c *ProjectsListCall) Ids(ids ...int64) *ProjectsListCall {
43433	var ids_ []string
43434	for _, v := range ids {
43435		ids_ = append(ids_, fmt.Sprint(v))
43436	}
43437	c.urlParams_.SetMulti("ids", ids_)
43438	return c
43439}
43440
43441// MaxResults sets the optional parameter "maxResults": Maximum number
43442// of results to return.
43443func (c *ProjectsListCall) MaxResults(maxResults int64) *ProjectsListCall {
43444	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
43445	return c
43446}
43447
43448// PageToken sets the optional parameter "pageToken": Value of the
43449// nextPageToken from the previous result page.
43450func (c *ProjectsListCall) PageToken(pageToken string) *ProjectsListCall {
43451	c.urlParams_.Set("pageToken", pageToken)
43452	return c
43453}
43454
43455// SearchString sets the optional parameter "searchString": Allows
43456// searching for projects by name or ID. Wildcards (*) are allowed. For
43457// example, "project*2015" will return projects with names like "project
43458// June 2015", "project April 2015", or simply "project 2015". Most of
43459// the searches also add wildcards implicitly at the start and the end
43460// of the search string. For example, a search string of "project" will
43461// match projects with name "my project", "project 2015", or simply
43462// "project".
43463func (c *ProjectsListCall) SearchString(searchString string) *ProjectsListCall {
43464	c.urlParams_.Set("searchString", searchString)
43465	return c
43466}
43467
43468// SortField sets the optional parameter "sortField": Field by which to
43469// sort the list.
43470//
43471// Possible values:
43472//   "ID" (default)
43473//   "NAME"
43474func (c *ProjectsListCall) SortField(sortField string) *ProjectsListCall {
43475	c.urlParams_.Set("sortField", sortField)
43476	return c
43477}
43478
43479// SortOrder sets the optional parameter "sortOrder": Order of sorted
43480// results.
43481//
43482// Possible values:
43483//   "ASCENDING" (default)
43484//   "DESCENDING"
43485func (c *ProjectsListCall) SortOrder(sortOrder string) *ProjectsListCall {
43486	c.urlParams_.Set("sortOrder", sortOrder)
43487	return c
43488}
43489
43490// Fields allows partial responses to be retrieved. See
43491// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
43492// for more information.
43493func (c *ProjectsListCall) Fields(s ...googleapi.Field) *ProjectsListCall {
43494	c.urlParams_.Set("fields", googleapi.CombineFields(s))
43495	return c
43496}
43497
43498// IfNoneMatch sets the optional parameter which makes the operation
43499// fail if the object's ETag matches the given value. This is useful for
43500// getting updates only after the object has changed since the last
43501// request. Use googleapi.IsNotModified to check whether the response
43502// error from Do is the result of In-None-Match.
43503func (c *ProjectsListCall) IfNoneMatch(entityTag string) *ProjectsListCall {
43504	c.ifNoneMatch_ = entityTag
43505	return c
43506}
43507
43508// Context sets the context to be used in this call's Do method. Any
43509// pending HTTP request will be aborted if the provided context is
43510// canceled.
43511func (c *ProjectsListCall) Context(ctx context.Context) *ProjectsListCall {
43512	c.ctx_ = ctx
43513	return c
43514}
43515
43516// Header returns an http.Header that can be modified by the caller to
43517// add HTTP headers to the request.
43518func (c *ProjectsListCall) Header() http.Header {
43519	if c.header_ == nil {
43520		c.header_ = make(http.Header)
43521	}
43522	return c.header_
43523}
43524
43525func (c *ProjectsListCall) doRequest(alt string) (*http.Response, error) {
43526	reqHeaders := make(http.Header)
43527	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
43528	for k, v := range c.header_ {
43529		reqHeaders[k] = v
43530	}
43531	reqHeaders.Set("User-Agent", c.s.userAgent())
43532	if c.ifNoneMatch_ != "" {
43533		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
43534	}
43535	var body io.Reader = nil
43536	c.urlParams_.Set("alt", alt)
43537	c.urlParams_.Set("prettyPrint", "false")
43538	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/projects")
43539	urls += "?" + c.urlParams_.Encode()
43540	req, err := http.NewRequest("GET", urls, body)
43541	if err != nil {
43542		return nil, err
43543	}
43544	req.Header = reqHeaders
43545	googleapi.Expand(req.URL, map[string]string{
43546		"profileId": strconv.FormatInt(c.profileId, 10),
43547	})
43548	return gensupport.SendRequest(c.ctx_, c.s.client, req)
43549}
43550
43551// Do executes the "dfareporting.projects.list" call.
43552// Exactly one of *ProjectsListResponse or error will be non-nil. Any
43553// non-2xx status code is an error. Response headers are in either
43554// *ProjectsListResponse.ServerResponse.Header or (if a response was
43555// returned at all) in error.(*googleapi.Error).Header. Use
43556// googleapi.IsNotModified to check whether the returned error was
43557// because http.StatusNotModified was returned.
43558func (c *ProjectsListCall) Do(opts ...googleapi.CallOption) (*ProjectsListResponse, error) {
43559	gensupport.SetOptions(c.urlParams_, opts...)
43560	res, err := c.doRequest("json")
43561	if res != nil && res.StatusCode == http.StatusNotModified {
43562		if res.Body != nil {
43563			res.Body.Close()
43564		}
43565		return nil, &googleapi.Error{
43566			Code:   res.StatusCode,
43567			Header: res.Header,
43568		}
43569	}
43570	if err != nil {
43571		return nil, err
43572	}
43573	defer googleapi.CloseBody(res)
43574	if err := googleapi.CheckResponse(res); err != nil {
43575		return nil, err
43576	}
43577	ret := &ProjectsListResponse{
43578		ServerResponse: googleapi.ServerResponse{
43579			Header:         res.Header,
43580			HTTPStatusCode: res.StatusCode,
43581		},
43582	}
43583	target := &ret
43584	if err := gensupport.DecodeResponse(target, res); err != nil {
43585		return nil, err
43586	}
43587	return ret, nil
43588	// {
43589	//   "description": "Retrieves a list of projects, possibly filtered. This method supports paging .",
43590	//   "flatPath": "userprofiles/{profileId}/projects",
43591	//   "httpMethod": "GET",
43592	//   "id": "dfareporting.projects.list",
43593	//   "parameterOrder": [
43594	//     "profileId"
43595	//   ],
43596	//   "parameters": {
43597	//     "advertiserIds": {
43598	//       "description": "Select only projects with these advertiser IDs.",
43599	//       "format": "int64",
43600	//       "location": "query",
43601	//       "repeated": true,
43602	//       "type": "string"
43603	//     },
43604	//     "ids": {
43605	//       "description": "Select only projects with these IDs.",
43606	//       "format": "int64",
43607	//       "location": "query",
43608	//       "repeated": true,
43609	//       "type": "string"
43610	//     },
43611	//     "maxResults": {
43612	//       "default": "1000",
43613	//       "description": "Maximum number of results to return.",
43614	//       "format": "int32",
43615	//       "location": "query",
43616	//       "maximum": "1000",
43617	//       "minimum": "0",
43618	//       "type": "integer"
43619	//     },
43620	//     "pageToken": {
43621	//       "description": "Value of the nextPageToken from the previous result page.",
43622	//       "location": "query",
43623	//       "type": "string"
43624	//     },
43625	//     "profileId": {
43626	//       "description": "User profile ID associated with this request.",
43627	//       "format": "int64",
43628	//       "location": "path",
43629	//       "required": true,
43630	//       "type": "string"
43631	//     },
43632	//     "searchString": {
43633	//       "description": "Allows searching for projects by name or ID. Wildcards (*) are allowed. For example, \"project*2015\" will return projects with names like \"project June 2015\", \"project April 2015\", or simply \"project 2015\". Most of the searches also add wildcards implicitly at the start and the end of the search string. For example, a search string of \"project\" will match projects with name \"my project\", \"project 2015\", or simply \"project\".",
43634	//       "location": "query",
43635	//       "type": "string"
43636	//     },
43637	//     "sortField": {
43638	//       "default": "ID",
43639	//       "description": "Field by which to sort the list.",
43640	//       "enum": [
43641	//         "ID",
43642	//         "NAME"
43643	//       ],
43644	//       "enumDescriptions": [
43645	//         "",
43646	//         ""
43647	//       ],
43648	//       "location": "query",
43649	//       "type": "string"
43650	//     },
43651	//     "sortOrder": {
43652	//       "default": "ASCENDING",
43653	//       "description": "Order of sorted results.",
43654	//       "enum": [
43655	//         "ASCENDING",
43656	//         "DESCENDING"
43657	//       ],
43658	//       "enumDescriptions": [
43659	//         "",
43660	//         ""
43661	//       ],
43662	//       "location": "query",
43663	//       "type": "string"
43664	//     }
43665	//   },
43666	//   "path": "userprofiles/{profileId}/projects",
43667	//   "response": {
43668	//     "$ref": "ProjectsListResponse"
43669	//   },
43670	//   "scopes": [
43671	//     "https://www.googleapis.com/auth/dfatrafficking"
43672	//   ]
43673	// }
43674
43675}
43676
43677// Pages invokes f for each page of results.
43678// A non-nil error returned from f will halt the iteration.
43679// The provided context supersedes any context provided to the Context method.
43680func (c *ProjectsListCall) Pages(ctx context.Context, f func(*ProjectsListResponse) error) error {
43681	c.ctx_ = ctx
43682	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
43683	for {
43684		x, err := c.Do()
43685		if err != nil {
43686			return err
43687		}
43688		if err := f(x); err != nil {
43689			return err
43690		}
43691		if x.NextPageToken == "" {
43692			return nil
43693		}
43694		c.PageToken(x.NextPageToken)
43695	}
43696}
43697
43698// method id "dfareporting.regions.list":
43699
43700type RegionsListCall struct {
43701	s            *Service
43702	profileId    int64
43703	urlParams_   gensupport.URLParams
43704	ifNoneMatch_ string
43705	ctx_         context.Context
43706	header_      http.Header
43707}
43708
43709// List: Retrieves a list of regions.
43710//
43711// - profileId: User profile ID associated with this request.
43712func (r *RegionsService) List(profileId int64) *RegionsListCall {
43713	c := &RegionsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
43714	c.profileId = profileId
43715	return c
43716}
43717
43718// Fields allows partial responses to be retrieved. See
43719// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
43720// for more information.
43721func (c *RegionsListCall) Fields(s ...googleapi.Field) *RegionsListCall {
43722	c.urlParams_.Set("fields", googleapi.CombineFields(s))
43723	return c
43724}
43725
43726// IfNoneMatch sets the optional parameter which makes the operation
43727// fail if the object's ETag matches the given value. This is useful for
43728// getting updates only after the object has changed since the last
43729// request. Use googleapi.IsNotModified to check whether the response
43730// error from Do is the result of In-None-Match.
43731func (c *RegionsListCall) IfNoneMatch(entityTag string) *RegionsListCall {
43732	c.ifNoneMatch_ = entityTag
43733	return c
43734}
43735
43736// Context sets the context to be used in this call's Do method. Any
43737// pending HTTP request will be aborted if the provided context is
43738// canceled.
43739func (c *RegionsListCall) Context(ctx context.Context) *RegionsListCall {
43740	c.ctx_ = ctx
43741	return c
43742}
43743
43744// Header returns an http.Header that can be modified by the caller to
43745// add HTTP headers to the request.
43746func (c *RegionsListCall) Header() http.Header {
43747	if c.header_ == nil {
43748		c.header_ = make(http.Header)
43749	}
43750	return c.header_
43751}
43752
43753func (c *RegionsListCall) doRequest(alt string) (*http.Response, error) {
43754	reqHeaders := make(http.Header)
43755	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
43756	for k, v := range c.header_ {
43757		reqHeaders[k] = v
43758	}
43759	reqHeaders.Set("User-Agent", c.s.userAgent())
43760	if c.ifNoneMatch_ != "" {
43761		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
43762	}
43763	var body io.Reader = nil
43764	c.urlParams_.Set("alt", alt)
43765	c.urlParams_.Set("prettyPrint", "false")
43766	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/regions")
43767	urls += "?" + c.urlParams_.Encode()
43768	req, err := http.NewRequest("GET", urls, body)
43769	if err != nil {
43770		return nil, err
43771	}
43772	req.Header = reqHeaders
43773	googleapi.Expand(req.URL, map[string]string{
43774		"profileId": strconv.FormatInt(c.profileId, 10),
43775	})
43776	return gensupport.SendRequest(c.ctx_, c.s.client, req)
43777}
43778
43779// Do executes the "dfareporting.regions.list" call.
43780// Exactly one of *RegionsListResponse or error will be non-nil. Any
43781// non-2xx status code is an error. Response headers are in either
43782// *RegionsListResponse.ServerResponse.Header or (if a response was
43783// returned at all) in error.(*googleapi.Error).Header. Use
43784// googleapi.IsNotModified to check whether the returned error was
43785// because http.StatusNotModified was returned.
43786func (c *RegionsListCall) Do(opts ...googleapi.CallOption) (*RegionsListResponse, error) {
43787	gensupport.SetOptions(c.urlParams_, opts...)
43788	res, err := c.doRequest("json")
43789	if res != nil && res.StatusCode == http.StatusNotModified {
43790		if res.Body != nil {
43791			res.Body.Close()
43792		}
43793		return nil, &googleapi.Error{
43794			Code:   res.StatusCode,
43795			Header: res.Header,
43796		}
43797	}
43798	if err != nil {
43799		return nil, err
43800	}
43801	defer googleapi.CloseBody(res)
43802	if err := googleapi.CheckResponse(res); err != nil {
43803		return nil, err
43804	}
43805	ret := &RegionsListResponse{
43806		ServerResponse: googleapi.ServerResponse{
43807			Header:         res.Header,
43808			HTTPStatusCode: res.StatusCode,
43809		},
43810	}
43811	target := &ret
43812	if err := gensupport.DecodeResponse(target, res); err != nil {
43813		return nil, err
43814	}
43815	return ret, nil
43816	// {
43817	//   "description": "Retrieves a list of regions.",
43818	//   "flatPath": "userprofiles/{profileId}/regions",
43819	//   "httpMethod": "GET",
43820	//   "id": "dfareporting.regions.list",
43821	//   "parameterOrder": [
43822	//     "profileId"
43823	//   ],
43824	//   "parameters": {
43825	//     "profileId": {
43826	//       "description": "User profile ID associated with this request.",
43827	//       "format": "int64",
43828	//       "location": "path",
43829	//       "required": true,
43830	//       "type": "string"
43831	//     }
43832	//   },
43833	//   "path": "userprofiles/{profileId}/regions",
43834	//   "response": {
43835	//     "$ref": "RegionsListResponse"
43836	//   },
43837	//   "scopes": [
43838	//     "https://www.googleapis.com/auth/dfatrafficking"
43839	//   ]
43840	// }
43841
43842}
43843
43844// method id "dfareporting.remarketingListShares.get":
43845
43846type RemarketingListSharesGetCall struct {
43847	s                 *Service
43848	profileId         int64
43849	remarketingListId int64
43850	urlParams_        gensupport.URLParams
43851	ifNoneMatch_      string
43852	ctx_              context.Context
43853	header_           http.Header
43854}
43855
43856// Get: Gets one remarketing list share by remarketing list ID.
43857//
43858// - profileId: User profile ID associated with this request.
43859// - remarketingListId: Remarketing list ID.
43860func (r *RemarketingListSharesService) Get(profileId int64, remarketingListId int64) *RemarketingListSharesGetCall {
43861	c := &RemarketingListSharesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
43862	c.profileId = profileId
43863	c.remarketingListId = remarketingListId
43864	return c
43865}
43866
43867// Fields allows partial responses to be retrieved. See
43868// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
43869// for more information.
43870func (c *RemarketingListSharesGetCall) Fields(s ...googleapi.Field) *RemarketingListSharesGetCall {
43871	c.urlParams_.Set("fields", googleapi.CombineFields(s))
43872	return c
43873}
43874
43875// IfNoneMatch sets the optional parameter which makes the operation
43876// fail if the object's ETag matches the given value. This is useful for
43877// getting updates only after the object has changed since the last
43878// request. Use googleapi.IsNotModified to check whether the response
43879// error from Do is the result of In-None-Match.
43880func (c *RemarketingListSharesGetCall) IfNoneMatch(entityTag string) *RemarketingListSharesGetCall {
43881	c.ifNoneMatch_ = entityTag
43882	return c
43883}
43884
43885// Context sets the context to be used in this call's Do method. Any
43886// pending HTTP request will be aborted if the provided context is
43887// canceled.
43888func (c *RemarketingListSharesGetCall) Context(ctx context.Context) *RemarketingListSharesGetCall {
43889	c.ctx_ = ctx
43890	return c
43891}
43892
43893// Header returns an http.Header that can be modified by the caller to
43894// add HTTP headers to the request.
43895func (c *RemarketingListSharesGetCall) Header() http.Header {
43896	if c.header_ == nil {
43897		c.header_ = make(http.Header)
43898	}
43899	return c.header_
43900}
43901
43902func (c *RemarketingListSharesGetCall) doRequest(alt string) (*http.Response, error) {
43903	reqHeaders := make(http.Header)
43904	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
43905	for k, v := range c.header_ {
43906		reqHeaders[k] = v
43907	}
43908	reqHeaders.Set("User-Agent", c.s.userAgent())
43909	if c.ifNoneMatch_ != "" {
43910		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
43911	}
43912	var body io.Reader = nil
43913	c.urlParams_.Set("alt", alt)
43914	c.urlParams_.Set("prettyPrint", "false")
43915	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/remarketingListShares/{remarketingListId}")
43916	urls += "?" + c.urlParams_.Encode()
43917	req, err := http.NewRequest("GET", urls, body)
43918	if err != nil {
43919		return nil, err
43920	}
43921	req.Header = reqHeaders
43922	googleapi.Expand(req.URL, map[string]string{
43923		"profileId":         strconv.FormatInt(c.profileId, 10),
43924		"remarketingListId": strconv.FormatInt(c.remarketingListId, 10),
43925	})
43926	return gensupport.SendRequest(c.ctx_, c.s.client, req)
43927}
43928
43929// Do executes the "dfareporting.remarketingListShares.get" call.
43930// Exactly one of *RemarketingListShare or error will be non-nil. Any
43931// non-2xx status code is an error. Response headers are in either
43932// *RemarketingListShare.ServerResponse.Header or (if a response was
43933// returned at all) in error.(*googleapi.Error).Header. Use
43934// googleapi.IsNotModified to check whether the returned error was
43935// because http.StatusNotModified was returned.
43936func (c *RemarketingListSharesGetCall) Do(opts ...googleapi.CallOption) (*RemarketingListShare, error) {
43937	gensupport.SetOptions(c.urlParams_, opts...)
43938	res, err := c.doRequest("json")
43939	if res != nil && res.StatusCode == http.StatusNotModified {
43940		if res.Body != nil {
43941			res.Body.Close()
43942		}
43943		return nil, &googleapi.Error{
43944			Code:   res.StatusCode,
43945			Header: res.Header,
43946		}
43947	}
43948	if err != nil {
43949		return nil, err
43950	}
43951	defer googleapi.CloseBody(res)
43952	if err := googleapi.CheckResponse(res); err != nil {
43953		return nil, err
43954	}
43955	ret := &RemarketingListShare{
43956		ServerResponse: googleapi.ServerResponse{
43957			Header:         res.Header,
43958			HTTPStatusCode: res.StatusCode,
43959		},
43960	}
43961	target := &ret
43962	if err := gensupport.DecodeResponse(target, res); err != nil {
43963		return nil, err
43964	}
43965	return ret, nil
43966	// {
43967	//   "description": "Gets one remarketing list share by remarketing list ID.",
43968	//   "flatPath": "userprofiles/{profileId}/remarketingListShares/{remarketingListId}",
43969	//   "httpMethod": "GET",
43970	//   "id": "dfareporting.remarketingListShares.get",
43971	//   "parameterOrder": [
43972	//     "profileId",
43973	//     "remarketingListId"
43974	//   ],
43975	//   "parameters": {
43976	//     "profileId": {
43977	//       "description": "User profile ID associated with this request.",
43978	//       "format": "int64",
43979	//       "location": "path",
43980	//       "required": true,
43981	//       "type": "string"
43982	//     },
43983	//     "remarketingListId": {
43984	//       "description": "Remarketing list ID.",
43985	//       "format": "int64",
43986	//       "location": "path",
43987	//       "required": true,
43988	//       "type": "string"
43989	//     }
43990	//   },
43991	//   "path": "userprofiles/{profileId}/remarketingListShares/{remarketingListId}",
43992	//   "response": {
43993	//     "$ref": "RemarketingListShare"
43994	//   },
43995	//   "scopes": [
43996	//     "https://www.googleapis.com/auth/dfatrafficking"
43997	//   ]
43998	// }
43999
44000}
44001
44002// method id "dfareporting.remarketingListShares.patch":
44003
44004type RemarketingListSharesPatchCall struct {
44005	s                    *Service
44006	profileId            int64
44007	remarketinglistshare *RemarketingListShare
44008	urlParams_           gensupport.URLParams
44009	ctx_                 context.Context
44010	header_              http.Header
44011}
44012
44013// Patch: Updates an existing remarketing list share. This method
44014// supports patch semantics.
44015//
44016// - id: RemarketingList ID.
44017// - profileId: User profile ID associated with this request.
44018func (r *RemarketingListSharesService) Patch(profileId int64, id int64, remarketinglistshare *RemarketingListShare) *RemarketingListSharesPatchCall {
44019	c := &RemarketingListSharesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
44020	c.profileId = profileId
44021	c.urlParams_.Set("id", fmt.Sprint(id))
44022	c.remarketinglistshare = remarketinglistshare
44023	return c
44024}
44025
44026// Fields allows partial responses to be retrieved. See
44027// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
44028// for more information.
44029func (c *RemarketingListSharesPatchCall) Fields(s ...googleapi.Field) *RemarketingListSharesPatchCall {
44030	c.urlParams_.Set("fields", googleapi.CombineFields(s))
44031	return c
44032}
44033
44034// Context sets the context to be used in this call's Do method. Any
44035// pending HTTP request will be aborted if the provided context is
44036// canceled.
44037func (c *RemarketingListSharesPatchCall) Context(ctx context.Context) *RemarketingListSharesPatchCall {
44038	c.ctx_ = ctx
44039	return c
44040}
44041
44042// Header returns an http.Header that can be modified by the caller to
44043// add HTTP headers to the request.
44044func (c *RemarketingListSharesPatchCall) Header() http.Header {
44045	if c.header_ == nil {
44046		c.header_ = make(http.Header)
44047	}
44048	return c.header_
44049}
44050
44051func (c *RemarketingListSharesPatchCall) doRequest(alt string) (*http.Response, error) {
44052	reqHeaders := make(http.Header)
44053	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
44054	for k, v := range c.header_ {
44055		reqHeaders[k] = v
44056	}
44057	reqHeaders.Set("User-Agent", c.s.userAgent())
44058	var body io.Reader = nil
44059	body, err := googleapi.WithoutDataWrapper.JSONReader(c.remarketinglistshare)
44060	if err != nil {
44061		return nil, err
44062	}
44063	reqHeaders.Set("Content-Type", "application/json")
44064	c.urlParams_.Set("alt", alt)
44065	c.urlParams_.Set("prettyPrint", "false")
44066	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/remarketingListShares")
44067	urls += "?" + c.urlParams_.Encode()
44068	req, err := http.NewRequest("PATCH", urls, body)
44069	if err != nil {
44070		return nil, err
44071	}
44072	req.Header = reqHeaders
44073	googleapi.Expand(req.URL, map[string]string{
44074		"profileId": strconv.FormatInt(c.profileId, 10),
44075	})
44076	return gensupport.SendRequest(c.ctx_, c.s.client, req)
44077}
44078
44079// Do executes the "dfareporting.remarketingListShares.patch" call.
44080// Exactly one of *RemarketingListShare or error will be non-nil. Any
44081// non-2xx status code is an error. Response headers are in either
44082// *RemarketingListShare.ServerResponse.Header or (if a response was
44083// returned at all) in error.(*googleapi.Error).Header. Use
44084// googleapi.IsNotModified to check whether the returned error was
44085// because http.StatusNotModified was returned.
44086func (c *RemarketingListSharesPatchCall) Do(opts ...googleapi.CallOption) (*RemarketingListShare, error) {
44087	gensupport.SetOptions(c.urlParams_, opts...)
44088	res, err := c.doRequest("json")
44089	if res != nil && res.StatusCode == http.StatusNotModified {
44090		if res.Body != nil {
44091			res.Body.Close()
44092		}
44093		return nil, &googleapi.Error{
44094			Code:   res.StatusCode,
44095			Header: res.Header,
44096		}
44097	}
44098	if err != nil {
44099		return nil, err
44100	}
44101	defer googleapi.CloseBody(res)
44102	if err := googleapi.CheckResponse(res); err != nil {
44103		return nil, err
44104	}
44105	ret := &RemarketingListShare{
44106		ServerResponse: googleapi.ServerResponse{
44107			Header:         res.Header,
44108			HTTPStatusCode: res.StatusCode,
44109		},
44110	}
44111	target := &ret
44112	if err := gensupport.DecodeResponse(target, res); err != nil {
44113		return nil, err
44114	}
44115	return ret, nil
44116	// {
44117	//   "description": "Updates an existing remarketing list share. This method supports patch semantics.",
44118	//   "flatPath": "userprofiles/{profileId}/remarketingListShares",
44119	//   "httpMethod": "PATCH",
44120	//   "id": "dfareporting.remarketingListShares.patch",
44121	//   "parameterOrder": [
44122	//     "profileId",
44123	//     "id"
44124	//   ],
44125	//   "parameters": {
44126	//     "id": {
44127	//       "description": "RemarketingList ID.",
44128	//       "format": "int64",
44129	//       "location": "query",
44130	//       "required": true,
44131	//       "type": "string"
44132	//     },
44133	//     "profileId": {
44134	//       "description": "User profile ID associated with this request.",
44135	//       "format": "int64",
44136	//       "location": "path",
44137	//       "required": true,
44138	//       "type": "string"
44139	//     }
44140	//   },
44141	//   "path": "userprofiles/{profileId}/remarketingListShares",
44142	//   "request": {
44143	//     "$ref": "RemarketingListShare"
44144	//   },
44145	//   "response": {
44146	//     "$ref": "RemarketingListShare"
44147	//   },
44148	//   "scopes": [
44149	//     "https://www.googleapis.com/auth/dfatrafficking"
44150	//   ]
44151	// }
44152
44153}
44154
44155// method id "dfareporting.remarketingListShares.update":
44156
44157type RemarketingListSharesUpdateCall struct {
44158	s                    *Service
44159	profileId            int64
44160	remarketinglistshare *RemarketingListShare
44161	urlParams_           gensupport.URLParams
44162	ctx_                 context.Context
44163	header_              http.Header
44164}
44165
44166// Update: Updates an existing remarketing list share.
44167//
44168// - profileId: User profile ID associated with this request.
44169func (r *RemarketingListSharesService) Update(profileId int64, remarketinglistshare *RemarketingListShare) *RemarketingListSharesUpdateCall {
44170	c := &RemarketingListSharesUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
44171	c.profileId = profileId
44172	c.remarketinglistshare = remarketinglistshare
44173	return c
44174}
44175
44176// Fields allows partial responses to be retrieved. See
44177// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
44178// for more information.
44179func (c *RemarketingListSharesUpdateCall) Fields(s ...googleapi.Field) *RemarketingListSharesUpdateCall {
44180	c.urlParams_.Set("fields", googleapi.CombineFields(s))
44181	return c
44182}
44183
44184// Context sets the context to be used in this call's Do method. Any
44185// pending HTTP request will be aborted if the provided context is
44186// canceled.
44187func (c *RemarketingListSharesUpdateCall) Context(ctx context.Context) *RemarketingListSharesUpdateCall {
44188	c.ctx_ = ctx
44189	return c
44190}
44191
44192// Header returns an http.Header that can be modified by the caller to
44193// add HTTP headers to the request.
44194func (c *RemarketingListSharesUpdateCall) Header() http.Header {
44195	if c.header_ == nil {
44196		c.header_ = make(http.Header)
44197	}
44198	return c.header_
44199}
44200
44201func (c *RemarketingListSharesUpdateCall) doRequest(alt string) (*http.Response, error) {
44202	reqHeaders := make(http.Header)
44203	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
44204	for k, v := range c.header_ {
44205		reqHeaders[k] = v
44206	}
44207	reqHeaders.Set("User-Agent", c.s.userAgent())
44208	var body io.Reader = nil
44209	body, err := googleapi.WithoutDataWrapper.JSONReader(c.remarketinglistshare)
44210	if err != nil {
44211		return nil, err
44212	}
44213	reqHeaders.Set("Content-Type", "application/json")
44214	c.urlParams_.Set("alt", alt)
44215	c.urlParams_.Set("prettyPrint", "false")
44216	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/remarketingListShares")
44217	urls += "?" + c.urlParams_.Encode()
44218	req, err := http.NewRequest("PUT", urls, body)
44219	if err != nil {
44220		return nil, err
44221	}
44222	req.Header = reqHeaders
44223	googleapi.Expand(req.URL, map[string]string{
44224		"profileId": strconv.FormatInt(c.profileId, 10),
44225	})
44226	return gensupport.SendRequest(c.ctx_, c.s.client, req)
44227}
44228
44229// Do executes the "dfareporting.remarketingListShares.update" call.
44230// Exactly one of *RemarketingListShare or error will be non-nil. Any
44231// non-2xx status code is an error. Response headers are in either
44232// *RemarketingListShare.ServerResponse.Header or (if a response was
44233// returned at all) in error.(*googleapi.Error).Header. Use
44234// googleapi.IsNotModified to check whether the returned error was
44235// because http.StatusNotModified was returned.
44236func (c *RemarketingListSharesUpdateCall) Do(opts ...googleapi.CallOption) (*RemarketingListShare, error) {
44237	gensupport.SetOptions(c.urlParams_, opts...)
44238	res, err := c.doRequest("json")
44239	if res != nil && res.StatusCode == http.StatusNotModified {
44240		if res.Body != nil {
44241			res.Body.Close()
44242		}
44243		return nil, &googleapi.Error{
44244			Code:   res.StatusCode,
44245			Header: res.Header,
44246		}
44247	}
44248	if err != nil {
44249		return nil, err
44250	}
44251	defer googleapi.CloseBody(res)
44252	if err := googleapi.CheckResponse(res); err != nil {
44253		return nil, err
44254	}
44255	ret := &RemarketingListShare{
44256		ServerResponse: googleapi.ServerResponse{
44257			Header:         res.Header,
44258			HTTPStatusCode: res.StatusCode,
44259		},
44260	}
44261	target := &ret
44262	if err := gensupport.DecodeResponse(target, res); err != nil {
44263		return nil, err
44264	}
44265	return ret, nil
44266	// {
44267	//   "description": "Updates an existing remarketing list share.",
44268	//   "flatPath": "userprofiles/{profileId}/remarketingListShares",
44269	//   "httpMethod": "PUT",
44270	//   "id": "dfareporting.remarketingListShares.update",
44271	//   "parameterOrder": [
44272	//     "profileId"
44273	//   ],
44274	//   "parameters": {
44275	//     "profileId": {
44276	//       "description": "User profile ID associated with this request.",
44277	//       "format": "int64",
44278	//       "location": "path",
44279	//       "required": true,
44280	//       "type": "string"
44281	//     }
44282	//   },
44283	//   "path": "userprofiles/{profileId}/remarketingListShares",
44284	//   "request": {
44285	//     "$ref": "RemarketingListShare"
44286	//   },
44287	//   "response": {
44288	//     "$ref": "RemarketingListShare"
44289	//   },
44290	//   "scopes": [
44291	//     "https://www.googleapis.com/auth/dfatrafficking"
44292	//   ]
44293	// }
44294
44295}
44296
44297// method id "dfareporting.remarketingLists.get":
44298
44299type RemarketingListsGetCall struct {
44300	s            *Service
44301	profileId    int64
44302	id           int64
44303	urlParams_   gensupport.URLParams
44304	ifNoneMatch_ string
44305	ctx_         context.Context
44306	header_      http.Header
44307}
44308
44309// Get: Gets one remarketing list by ID.
44310//
44311// - id: Remarketing list ID.
44312// - profileId: User profile ID associated with this request.
44313func (r *RemarketingListsService) Get(profileId int64, id int64) *RemarketingListsGetCall {
44314	c := &RemarketingListsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
44315	c.profileId = profileId
44316	c.id = id
44317	return c
44318}
44319
44320// Fields allows partial responses to be retrieved. See
44321// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
44322// for more information.
44323func (c *RemarketingListsGetCall) Fields(s ...googleapi.Field) *RemarketingListsGetCall {
44324	c.urlParams_.Set("fields", googleapi.CombineFields(s))
44325	return c
44326}
44327
44328// IfNoneMatch sets the optional parameter which makes the operation
44329// fail if the object's ETag matches the given value. This is useful for
44330// getting updates only after the object has changed since the last
44331// request. Use googleapi.IsNotModified to check whether the response
44332// error from Do is the result of In-None-Match.
44333func (c *RemarketingListsGetCall) IfNoneMatch(entityTag string) *RemarketingListsGetCall {
44334	c.ifNoneMatch_ = entityTag
44335	return c
44336}
44337
44338// Context sets the context to be used in this call's Do method. Any
44339// pending HTTP request will be aborted if the provided context is
44340// canceled.
44341func (c *RemarketingListsGetCall) Context(ctx context.Context) *RemarketingListsGetCall {
44342	c.ctx_ = ctx
44343	return c
44344}
44345
44346// Header returns an http.Header that can be modified by the caller to
44347// add HTTP headers to the request.
44348func (c *RemarketingListsGetCall) Header() http.Header {
44349	if c.header_ == nil {
44350		c.header_ = make(http.Header)
44351	}
44352	return c.header_
44353}
44354
44355func (c *RemarketingListsGetCall) doRequest(alt string) (*http.Response, error) {
44356	reqHeaders := make(http.Header)
44357	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
44358	for k, v := range c.header_ {
44359		reqHeaders[k] = v
44360	}
44361	reqHeaders.Set("User-Agent", c.s.userAgent())
44362	if c.ifNoneMatch_ != "" {
44363		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
44364	}
44365	var body io.Reader = nil
44366	c.urlParams_.Set("alt", alt)
44367	c.urlParams_.Set("prettyPrint", "false")
44368	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/remarketingLists/{id}")
44369	urls += "?" + c.urlParams_.Encode()
44370	req, err := http.NewRequest("GET", urls, body)
44371	if err != nil {
44372		return nil, err
44373	}
44374	req.Header = reqHeaders
44375	googleapi.Expand(req.URL, map[string]string{
44376		"profileId": strconv.FormatInt(c.profileId, 10),
44377		"id":        strconv.FormatInt(c.id, 10),
44378	})
44379	return gensupport.SendRequest(c.ctx_, c.s.client, req)
44380}
44381
44382// Do executes the "dfareporting.remarketingLists.get" call.
44383// Exactly one of *RemarketingList or error will be non-nil. Any non-2xx
44384// status code is an error. Response headers are in either
44385// *RemarketingList.ServerResponse.Header or (if a response was returned
44386// at all) in error.(*googleapi.Error).Header. Use
44387// googleapi.IsNotModified to check whether the returned error was
44388// because http.StatusNotModified was returned.
44389func (c *RemarketingListsGetCall) Do(opts ...googleapi.CallOption) (*RemarketingList, error) {
44390	gensupport.SetOptions(c.urlParams_, opts...)
44391	res, err := c.doRequest("json")
44392	if res != nil && res.StatusCode == http.StatusNotModified {
44393		if res.Body != nil {
44394			res.Body.Close()
44395		}
44396		return nil, &googleapi.Error{
44397			Code:   res.StatusCode,
44398			Header: res.Header,
44399		}
44400	}
44401	if err != nil {
44402		return nil, err
44403	}
44404	defer googleapi.CloseBody(res)
44405	if err := googleapi.CheckResponse(res); err != nil {
44406		return nil, err
44407	}
44408	ret := &RemarketingList{
44409		ServerResponse: googleapi.ServerResponse{
44410			Header:         res.Header,
44411			HTTPStatusCode: res.StatusCode,
44412		},
44413	}
44414	target := &ret
44415	if err := gensupport.DecodeResponse(target, res); err != nil {
44416		return nil, err
44417	}
44418	return ret, nil
44419	// {
44420	//   "description": "Gets one remarketing list by ID.",
44421	//   "flatPath": "userprofiles/{profileId}/remarketingLists/{id}",
44422	//   "httpMethod": "GET",
44423	//   "id": "dfareporting.remarketingLists.get",
44424	//   "parameterOrder": [
44425	//     "profileId",
44426	//     "id"
44427	//   ],
44428	//   "parameters": {
44429	//     "id": {
44430	//       "description": "Remarketing list ID.",
44431	//       "format": "int64",
44432	//       "location": "path",
44433	//       "required": true,
44434	//       "type": "string"
44435	//     },
44436	//     "profileId": {
44437	//       "description": "User profile ID associated with this request.",
44438	//       "format": "int64",
44439	//       "location": "path",
44440	//       "required": true,
44441	//       "type": "string"
44442	//     }
44443	//   },
44444	//   "path": "userprofiles/{profileId}/remarketingLists/{id}",
44445	//   "response": {
44446	//     "$ref": "RemarketingList"
44447	//   },
44448	//   "scopes": [
44449	//     "https://www.googleapis.com/auth/dfatrafficking"
44450	//   ]
44451	// }
44452
44453}
44454
44455// method id "dfareporting.remarketingLists.insert":
44456
44457type RemarketingListsInsertCall struct {
44458	s               *Service
44459	profileId       int64
44460	remarketinglist *RemarketingList
44461	urlParams_      gensupport.URLParams
44462	ctx_            context.Context
44463	header_         http.Header
44464}
44465
44466// Insert: Inserts a new remarketing list.
44467//
44468// - profileId: User profile ID associated with this request.
44469func (r *RemarketingListsService) Insert(profileId int64, remarketinglist *RemarketingList) *RemarketingListsInsertCall {
44470	c := &RemarketingListsInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
44471	c.profileId = profileId
44472	c.remarketinglist = remarketinglist
44473	return c
44474}
44475
44476// Fields allows partial responses to be retrieved. See
44477// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
44478// for more information.
44479func (c *RemarketingListsInsertCall) Fields(s ...googleapi.Field) *RemarketingListsInsertCall {
44480	c.urlParams_.Set("fields", googleapi.CombineFields(s))
44481	return c
44482}
44483
44484// Context sets the context to be used in this call's Do method. Any
44485// pending HTTP request will be aborted if the provided context is
44486// canceled.
44487func (c *RemarketingListsInsertCall) Context(ctx context.Context) *RemarketingListsInsertCall {
44488	c.ctx_ = ctx
44489	return c
44490}
44491
44492// Header returns an http.Header that can be modified by the caller to
44493// add HTTP headers to the request.
44494func (c *RemarketingListsInsertCall) Header() http.Header {
44495	if c.header_ == nil {
44496		c.header_ = make(http.Header)
44497	}
44498	return c.header_
44499}
44500
44501func (c *RemarketingListsInsertCall) doRequest(alt string) (*http.Response, error) {
44502	reqHeaders := make(http.Header)
44503	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
44504	for k, v := range c.header_ {
44505		reqHeaders[k] = v
44506	}
44507	reqHeaders.Set("User-Agent", c.s.userAgent())
44508	var body io.Reader = nil
44509	body, err := googleapi.WithoutDataWrapper.JSONReader(c.remarketinglist)
44510	if err != nil {
44511		return nil, err
44512	}
44513	reqHeaders.Set("Content-Type", "application/json")
44514	c.urlParams_.Set("alt", alt)
44515	c.urlParams_.Set("prettyPrint", "false")
44516	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/remarketingLists")
44517	urls += "?" + c.urlParams_.Encode()
44518	req, err := http.NewRequest("POST", urls, body)
44519	if err != nil {
44520		return nil, err
44521	}
44522	req.Header = reqHeaders
44523	googleapi.Expand(req.URL, map[string]string{
44524		"profileId": strconv.FormatInt(c.profileId, 10),
44525	})
44526	return gensupport.SendRequest(c.ctx_, c.s.client, req)
44527}
44528
44529// Do executes the "dfareporting.remarketingLists.insert" call.
44530// Exactly one of *RemarketingList or error will be non-nil. Any non-2xx
44531// status code is an error. Response headers are in either
44532// *RemarketingList.ServerResponse.Header or (if a response was returned
44533// at all) in error.(*googleapi.Error).Header. Use
44534// googleapi.IsNotModified to check whether the returned error was
44535// because http.StatusNotModified was returned.
44536func (c *RemarketingListsInsertCall) Do(opts ...googleapi.CallOption) (*RemarketingList, error) {
44537	gensupport.SetOptions(c.urlParams_, opts...)
44538	res, err := c.doRequest("json")
44539	if res != nil && res.StatusCode == http.StatusNotModified {
44540		if res.Body != nil {
44541			res.Body.Close()
44542		}
44543		return nil, &googleapi.Error{
44544			Code:   res.StatusCode,
44545			Header: res.Header,
44546		}
44547	}
44548	if err != nil {
44549		return nil, err
44550	}
44551	defer googleapi.CloseBody(res)
44552	if err := googleapi.CheckResponse(res); err != nil {
44553		return nil, err
44554	}
44555	ret := &RemarketingList{
44556		ServerResponse: googleapi.ServerResponse{
44557			Header:         res.Header,
44558			HTTPStatusCode: res.StatusCode,
44559		},
44560	}
44561	target := &ret
44562	if err := gensupport.DecodeResponse(target, res); err != nil {
44563		return nil, err
44564	}
44565	return ret, nil
44566	// {
44567	//   "description": "Inserts a new remarketing list.",
44568	//   "flatPath": "userprofiles/{profileId}/remarketingLists",
44569	//   "httpMethod": "POST",
44570	//   "id": "dfareporting.remarketingLists.insert",
44571	//   "parameterOrder": [
44572	//     "profileId"
44573	//   ],
44574	//   "parameters": {
44575	//     "profileId": {
44576	//       "description": "User profile ID associated with this request.",
44577	//       "format": "int64",
44578	//       "location": "path",
44579	//       "required": true,
44580	//       "type": "string"
44581	//     }
44582	//   },
44583	//   "path": "userprofiles/{profileId}/remarketingLists",
44584	//   "request": {
44585	//     "$ref": "RemarketingList"
44586	//   },
44587	//   "response": {
44588	//     "$ref": "RemarketingList"
44589	//   },
44590	//   "scopes": [
44591	//     "https://www.googleapis.com/auth/dfatrafficking"
44592	//   ]
44593	// }
44594
44595}
44596
44597// method id "dfareporting.remarketingLists.list":
44598
44599type RemarketingListsListCall struct {
44600	s            *Service
44601	profileId    int64
44602	urlParams_   gensupport.URLParams
44603	ifNoneMatch_ string
44604	ctx_         context.Context
44605	header_      http.Header
44606}
44607
44608// List: Retrieves a list of remarketing lists, possibly filtered. This
44609// method supports paging.
44610//
44611// - advertiserId: Select only remarketing lists owned by this
44612//   advertiser.
44613// - profileId: User profile ID associated with this request.
44614func (r *RemarketingListsService) List(profileId int64, advertiserId int64) *RemarketingListsListCall {
44615	c := &RemarketingListsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
44616	c.profileId = profileId
44617	c.urlParams_.Set("advertiserId", fmt.Sprint(advertiserId))
44618	return c
44619}
44620
44621// Active sets the optional parameter "active": Select only active or
44622// only inactive remarketing lists.
44623func (c *RemarketingListsListCall) Active(active bool) *RemarketingListsListCall {
44624	c.urlParams_.Set("active", fmt.Sprint(active))
44625	return c
44626}
44627
44628// FloodlightActivityId sets the optional parameter
44629// "floodlightActivityId": Select only remarketing lists that have this
44630// floodlight activity ID.
44631func (c *RemarketingListsListCall) FloodlightActivityId(floodlightActivityId int64) *RemarketingListsListCall {
44632	c.urlParams_.Set("floodlightActivityId", fmt.Sprint(floodlightActivityId))
44633	return c
44634}
44635
44636// MaxResults sets the optional parameter "maxResults": Maximum number
44637// of results to return.
44638func (c *RemarketingListsListCall) MaxResults(maxResults int64) *RemarketingListsListCall {
44639	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
44640	return c
44641}
44642
44643// Name sets the optional parameter "name": Allows searching for objects
44644// by name or ID. Wildcards (*) are allowed. For example, "remarketing
44645// list*2015" will return objects with names like "remarketing list June
44646// 2015", "remarketing list April 2015", or simply "remarketing list
44647// 2015". Most of the searches also add wildcards implicitly at the
44648// start and the end of the search string. For example, a search string
44649// of "remarketing list" will match objects with name "my remarketing
44650// list", "remarketing list 2015", or simply "remarketing list".
44651func (c *RemarketingListsListCall) Name(name string) *RemarketingListsListCall {
44652	c.urlParams_.Set("name", name)
44653	return c
44654}
44655
44656// PageToken sets the optional parameter "pageToken": Value of the
44657// nextPageToken from the previous result page.
44658func (c *RemarketingListsListCall) PageToken(pageToken string) *RemarketingListsListCall {
44659	c.urlParams_.Set("pageToken", pageToken)
44660	return c
44661}
44662
44663// SortField sets the optional parameter "sortField": Field by which to
44664// sort the list.
44665//
44666// Possible values:
44667//   "ID" (default)
44668//   "NAME"
44669func (c *RemarketingListsListCall) SortField(sortField string) *RemarketingListsListCall {
44670	c.urlParams_.Set("sortField", sortField)
44671	return c
44672}
44673
44674// SortOrder sets the optional parameter "sortOrder": Order of sorted
44675// results.
44676//
44677// Possible values:
44678//   "ASCENDING" (default)
44679//   "DESCENDING"
44680func (c *RemarketingListsListCall) SortOrder(sortOrder string) *RemarketingListsListCall {
44681	c.urlParams_.Set("sortOrder", sortOrder)
44682	return c
44683}
44684
44685// Fields allows partial responses to be retrieved. See
44686// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
44687// for more information.
44688func (c *RemarketingListsListCall) Fields(s ...googleapi.Field) *RemarketingListsListCall {
44689	c.urlParams_.Set("fields", googleapi.CombineFields(s))
44690	return c
44691}
44692
44693// IfNoneMatch sets the optional parameter which makes the operation
44694// fail if the object's ETag matches the given value. This is useful for
44695// getting updates only after the object has changed since the last
44696// request. Use googleapi.IsNotModified to check whether the response
44697// error from Do is the result of In-None-Match.
44698func (c *RemarketingListsListCall) IfNoneMatch(entityTag string) *RemarketingListsListCall {
44699	c.ifNoneMatch_ = entityTag
44700	return c
44701}
44702
44703// Context sets the context to be used in this call's Do method. Any
44704// pending HTTP request will be aborted if the provided context is
44705// canceled.
44706func (c *RemarketingListsListCall) Context(ctx context.Context) *RemarketingListsListCall {
44707	c.ctx_ = ctx
44708	return c
44709}
44710
44711// Header returns an http.Header that can be modified by the caller to
44712// add HTTP headers to the request.
44713func (c *RemarketingListsListCall) Header() http.Header {
44714	if c.header_ == nil {
44715		c.header_ = make(http.Header)
44716	}
44717	return c.header_
44718}
44719
44720func (c *RemarketingListsListCall) doRequest(alt string) (*http.Response, error) {
44721	reqHeaders := make(http.Header)
44722	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
44723	for k, v := range c.header_ {
44724		reqHeaders[k] = v
44725	}
44726	reqHeaders.Set("User-Agent", c.s.userAgent())
44727	if c.ifNoneMatch_ != "" {
44728		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
44729	}
44730	var body io.Reader = nil
44731	c.urlParams_.Set("alt", alt)
44732	c.urlParams_.Set("prettyPrint", "false")
44733	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/remarketingLists")
44734	urls += "?" + c.urlParams_.Encode()
44735	req, err := http.NewRequest("GET", urls, body)
44736	if err != nil {
44737		return nil, err
44738	}
44739	req.Header = reqHeaders
44740	googleapi.Expand(req.URL, map[string]string{
44741		"profileId": strconv.FormatInt(c.profileId, 10),
44742	})
44743	return gensupport.SendRequest(c.ctx_, c.s.client, req)
44744}
44745
44746// Do executes the "dfareporting.remarketingLists.list" call.
44747// Exactly one of *RemarketingListsListResponse or error will be
44748// non-nil. Any non-2xx status code is an error. Response headers are in
44749// either *RemarketingListsListResponse.ServerResponse.Header or (if a
44750// response was returned at all) in error.(*googleapi.Error).Header. Use
44751// googleapi.IsNotModified to check whether the returned error was
44752// because http.StatusNotModified was returned.
44753func (c *RemarketingListsListCall) Do(opts ...googleapi.CallOption) (*RemarketingListsListResponse, error) {
44754	gensupport.SetOptions(c.urlParams_, opts...)
44755	res, err := c.doRequest("json")
44756	if res != nil && res.StatusCode == http.StatusNotModified {
44757		if res.Body != nil {
44758			res.Body.Close()
44759		}
44760		return nil, &googleapi.Error{
44761			Code:   res.StatusCode,
44762			Header: res.Header,
44763		}
44764	}
44765	if err != nil {
44766		return nil, err
44767	}
44768	defer googleapi.CloseBody(res)
44769	if err := googleapi.CheckResponse(res); err != nil {
44770		return nil, err
44771	}
44772	ret := &RemarketingListsListResponse{
44773		ServerResponse: googleapi.ServerResponse{
44774			Header:         res.Header,
44775			HTTPStatusCode: res.StatusCode,
44776		},
44777	}
44778	target := &ret
44779	if err := gensupport.DecodeResponse(target, res); err != nil {
44780		return nil, err
44781	}
44782	return ret, nil
44783	// {
44784	//   "description": "Retrieves a list of remarketing lists, possibly filtered. This method supports paging.",
44785	//   "flatPath": "userprofiles/{profileId}/remarketingLists",
44786	//   "httpMethod": "GET",
44787	//   "id": "dfareporting.remarketingLists.list",
44788	//   "parameterOrder": [
44789	//     "profileId",
44790	//     "advertiserId"
44791	//   ],
44792	//   "parameters": {
44793	//     "active": {
44794	//       "description": "Select only active or only inactive remarketing lists.",
44795	//       "location": "query",
44796	//       "type": "boolean"
44797	//     },
44798	//     "advertiserId": {
44799	//       "description": "Select only remarketing lists owned by this advertiser.",
44800	//       "format": "int64",
44801	//       "location": "query",
44802	//       "required": true,
44803	//       "type": "string"
44804	//     },
44805	//     "floodlightActivityId": {
44806	//       "description": "Select only remarketing lists that have this floodlight activity ID.",
44807	//       "format": "int64",
44808	//       "location": "query",
44809	//       "type": "string"
44810	//     },
44811	//     "maxResults": {
44812	//       "default": "1000",
44813	//       "description": "Maximum number of results to return.",
44814	//       "format": "int32",
44815	//       "location": "query",
44816	//       "maximum": "1000",
44817	//       "minimum": "0",
44818	//       "type": "integer"
44819	//     },
44820	//     "name": {
44821	//       "description": "Allows searching for objects by name or ID. Wildcards (*) are allowed. For example, \"remarketing list*2015\" will return objects with names like \"remarketing list June 2015\", \"remarketing list April 2015\", or simply \"remarketing list 2015\". Most of the searches also add wildcards implicitly at the start and the end of the search string. For example, a search string of \"remarketing list\" will match objects with name \"my remarketing list\", \"remarketing list 2015\", or simply \"remarketing list\".",
44822	//       "location": "query",
44823	//       "type": "string"
44824	//     },
44825	//     "pageToken": {
44826	//       "description": "Value of the nextPageToken from the previous result page.",
44827	//       "location": "query",
44828	//       "type": "string"
44829	//     },
44830	//     "profileId": {
44831	//       "description": "User profile ID associated with this request.",
44832	//       "format": "int64",
44833	//       "location": "path",
44834	//       "required": true,
44835	//       "type": "string"
44836	//     },
44837	//     "sortField": {
44838	//       "default": "ID",
44839	//       "description": "Field by which to sort the list.",
44840	//       "enum": [
44841	//         "ID",
44842	//         "NAME"
44843	//       ],
44844	//       "enumDescriptions": [
44845	//         "",
44846	//         ""
44847	//       ],
44848	//       "location": "query",
44849	//       "type": "string"
44850	//     },
44851	//     "sortOrder": {
44852	//       "default": "ASCENDING",
44853	//       "description": "Order of sorted results.",
44854	//       "enum": [
44855	//         "ASCENDING",
44856	//         "DESCENDING"
44857	//       ],
44858	//       "enumDescriptions": [
44859	//         "",
44860	//         ""
44861	//       ],
44862	//       "location": "query",
44863	//       "type": "string"
44864	//     }
44865	//   },
44866	//   "path": "userprofiles/{profileId}/remarketingLists",
44867	//   "response": {
44868	//     "$ref": "RemarketingListsListResponse"
44869	//   },
44870	//   "scopes": [
44871	//     "https://www.googleapis.com/auth/dfatrafficking"
44872	//   ]
44873	// }
44874
44875}
44876
44877// Pages invokes f for each page of results.
44878// A non-nil error returned from f will halt the iteration.
44879// The provided context supersedes any context provided to the Context method.
44880func (c *RemarketingListsListCall) Pages(ctx context.Context, f func(*RemarketingListsListResponse) error) error {
44881	c.ctx_ = ctx
44882	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
44883	for {
44884		x, err := c.Do()
44885		if err != nil {
44886			return err
44887		}
44888		if err := f(x); err != nil {
44889			return err
44890		}
44891		if x.NextPageToken == "" {
44892			return nil
44893		}
44894		c.PageToken(x.NextPageToken)
44895	}
44896}
44897
44898// method id "dfareporting.remarketingLists.patch":
44899
44900type RemarketingListsPatchCall struct {
44901	s               *Service
44902	profileId       int64
44903	remarketinglist *RemarketingList
44904	urlParams_      gensupport.URLParams
44905	ctx_            context.Context
44906	header_         http.Header
44907}
44908
44909// Patch: Updates an existing remarketing list. This method supports
44910// patch semantics.
44911//
44912// - id: RemarketingList ID.
44913// - profileId: User profile ID associated with this request.
44914func (r *RemarketingListsService) Patch(profileId int64, id int64, remarketinglist *RemarketingList) *RemarketingListsPatchCall {
44915	c := &RemarketingListsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
44916	c.profileId = profileId
44917	c.urlParams_.Set("id", fmt.Sprint(id))
44918	c.remarketinglist = remarketinglist
44919	return c
44920}
44921
44922// Fields allows partial responses to be retrieved. See
44923// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
44924// for more information.
44925func (c *RemarketingListsPatchCall) Fields(s ...googleapi.Field) *RemarketingListsPatchCall {
44926	c.urlParams_.Set("fields", googleapi.CombineFields(s))
44927	return c
44928}
44929
44930// Context sets the context to be used in this call's Do method. Any
44931// pending HTTP request will be aborted if the provided context is
44932// canceled.
44933func (c *RemarketingListsPatchCall) Context(ctx context.Context) *RemarketingListsPatchCall {
44934	c.ctx_ = ctx
44935	return c
44936}
44937
44938// Header returns an http.Header that can be modified by the caller to
44939// add HTTP headers to the request.
44940func (c *RemarketingListsPatchCall) Header() http.Header {
44941	if c.header_ == nil {
44942		c.header_ = make(http.Header)
44943	}
44944	return c.header_
44945}
44946
44947func (c *RemarketingListsPatchCall) doRequest(alt string) (*http.Response, error) {
44948	reqHeaders := make(http.Header)
44949	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
44950	for k, v := range c.header_ {
44951		reqHeaders[k] = v
44952	}
44953	reqHeaders.Set("User-Agent", c.s.userAgent())
44954	var body io.Reader = nil
44955	body, err := googleapi.WithoutDataWrapper.JSONReader(c.remarketinglist)
44956	if err != nil {
44957		return nil, err
44958	}
44959	reqHeaders.Set("Content-Type", "application/json")
44960	c.urlParams_.Set("alt", alt)
44961	c.urlParams_.Set("prettyPrint", "false")
44962	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/remarketingLists")
44963	urls += "?" + c.urlParams_.Encode()
44964	req, err := http.NewRequest("PATCH", urls, body)
44965	if err != nil {
44966		return nil, err
44967	}
44968	req.Header = reqHeaders
44969	googleapi.Expand(req.URL, map[string]string{
44970		"profileId": strconv.FormatInt(c.profileId, 10),
44971	})
44972	return gensupport.SendRequest(c.ctx_, c.s.client, req)
44973}
44974
44975// Do executes the "dfareporting.remarketingLists.patch" call.
44976// Exactly one of *RemarketingList or error will be non-nil. Any non-2xx
44977// status code is an error. Response headers are in either
44978// *RemarketingList.ServerResponse.Header or (if a response was returned
44979// at all) in error.(*googleapi.Error).Header. Use
44980// googleapi.IsNotModified to check whether the returned error was
44981// because http.StatusNotModified was returned.
44982func (c *RemarketingListsPatchCall) Do(opts ...googleapi.CallOption) (*RemarketingList, error) {
44983	gensupport.SetOptions(c.urlParams_, opts...)
44984	res, err := c.doRequest("json")
44985	if res != nil && res.StatusCode == http.StatusNotModified {
44986		if res.Body != nil {
44987			res.Body.Close()
44988		}
44989		return nil, &googleapi.Error{
44990			Code:   res.StatusCode,
44991			Header: res.Header,
44992		}
44993	}
44994	if err != nil {
44995		return nil, err
44996	}
44997	defer googleapi.CloseBody(res)
44998	if err := googleapi.CheckResponse(res); err != nil {
44999		return nil, err
45000	}
45001	ret := &RemarketingList{
45002		ServerResponse: googleapi.ServerResponse{
45003			Header:         res.Header,
45004			HTTPStatusCode: res.StatusCode,
45005		},
45006	}
45007	target := &ret
45008	if err := gensupport.DecodeResponse(target, res); err != nil {
45009		return nil, err
45010	}
45011	return ret, nil
45012	// {
45013	//   "description": "Updates an existing remarketing list. This method supports patch semantics.",
45014	//   "flatPath": "userprofiles/{profileId}/remarketingLists",
45015	//   "httpMethod": "PATCH",
45016	//   "id": "dfareporting.remarketingLists.patch",
45017	//   "parameterOrder": [
45018	//     "profileId",
45019	//     "id"
45020	//   ],
45021	//   "parameters": {
45022	//     "id": {
45023	//       "description": "RemarketingList ID.",
45024	//       "format": "int64",
45025	//       "location": "query",
45026	//       "required": true,
45027	//       "type": "string"
45028	//     },
45029	//     "profileId": {
45030	//       "description": "User profile ID associated with this request.",
45031	//       "format": "int64",
45032	//       "location": "path",
45033	//       "required": true,
45034	//       "type": "string"
45035	//     }
45036	//   },
45037	//   "path": "userprofiles/{profileId}/remarketingLists",
45038	//   "request": {
45039	//     "$ref": "RemarketingList"
45040	//   },
45041	//   "response": {
45042	//     "$ref": "RemarketingList"
45043	//   },
45044	//   "scopes": [
45045	//     "https://www.googleapis.com/auth/dfatrafficking"
45046	//   ]
45047	// }
45048
45049}
45050
45051// method id "dfareporting.remarketingLists.update":
45052
45053type RemarketingListsUpdateCall struct {
45054	s               *Service
45055	profileId       int64
45056	remarketinglist *RemarketingList
45057	urlParams_      gensupport.URLParams
45058	ctx_            context.Context
45059	header_         http.Header
45060}
45061
45062// Update: Updates an existing remarketing list.
45063//
45064// - profileId: User profile ID associated with this request.
45065func (r *RemarketingListsService) Update(profileId int64, remarketinglist *RemarketingList) *RemarketingListsUpdateCall {
45066	c := &RemarketingListsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
45067	c.profileId = profileId
45068	c.remarketinglist = remarketinglist
45069	return c
45070}
45071
45072// Fields allows partial responses to be retrieved. See
45073// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
45074// for more information.
45075func (c *RemarketingListsUpdateCall) Fields(s ...googleapi.Field) *RemarketingListsUpdateCall {
45076	c.urlParams_.Set("fields", googleapi.CombineFields(s))
45077	return c
45078}
45079
45080// Context sets the context to be used in this call's Do method. Any
45081// pending HTTP request will be aborted if the provided context is
45082// canceled.
45083func (c *RemarketingListsUpdateCall) Context(ctx context.Context) *RemarketingListsUpdateCall {
45084	c.ctx_ = ctx
45085	return c
45086}
45087
45088// Header returns an http.Header that can be modified by the caller to
45089// add HTTP headers to the request.
45090func (c *RemarketingListsUpdateCall) Header() http.Header {
45091	if c.header_ == nil {
45092		c.header_ = make(http.Header)
45093	}
45094	return c.header_
45095}
45096
45097func (c *RemarketingListsUpdateCall) doRequest(alt string) (*http.Response, error) {
45098	reqHeaders := make(http.Header)
45099	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
45100	for k, v := range c.header_ {
45101		reqHeaders[k] = v
45102	}
45103	reqHeaders.Set("User-Agent", c.s.userAgent())
45104	var body io.Reader = nil
45105	body, err := googleapi.WithoutDataWrapper.JSONReader(c.remarketinglist)
45106	if err != nil {
45107		return nil, err
45108	}
45109	reqHeaders.Set("Content-Type", "application/json")
45110	c.urlParams_.Set("alt", alt)
45111	c.urlParams_.Set("prettyPrint", "false")
45112	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/remarketingLists")
45113	urls += "?" + c.urlParams_.Encode()
45114	req, err := http.NewRequest("PUT", urls, body)
45115	if err != nil {
45116		return nil, err
45117	}
45118	req.Header = reqHeaders
45119	googleapi.Expand(req.URL, map[string]string{
45120		"profileId": strconv.FormatInt(c.profileId, 10),
45121	})
45122	return gensupport.SendRequest(c.ctx_, c.s.client, req)
45123}
45124
45125// Do executes the "dfareporting.remarketingLists.update" call.
45126// Exactly one of *RemarketingList or error will be non-nil. Any non-2xx
45127// status code is an error. Response headers are in either
45128// *RemarketingList.ServerResponse.Header or (if a response was returned
45129// at all) in error.(*googleapi.Error).Header. Use
45130// googleapi.IsNotModified to check whether the returned error was
45131// because http.StatusNotModified was returned.
45132func (c *RemarketingListsUpdateCall) Do(opts ...googleapi.CallOption) (*RemarketingList, error) {
45133	gensupport.SetOptions(c.urlParams_, opts...)
45134	res, err := c.doRequest("json")
45135	if res != nil && res.StatusCode == http.StatusNotModified {
45136		if res.Body != nil {
45137			res.Body.Close()
45138		}
45139		return nil, &googleapi.Error{
45140			Code:   res.StatusCode,
45141			Header: res.Header,
45142		}
45143	}
45144	if err != nil {
45145		return nil, err
45146	}
45147	defer googleapi.CloseBody(res)
45148	if err := googleapi.CheckResponse(res); err != nil {
45149		return nil, err
45150	}
45151	ret := &RemarketingList{
45152		ServerResponse: googleapi.ServerResponse{
45153			Header:         res.Header,
45154			HTTPStatusCode: res.StatusCode,
45155		},
45156	}
45157	target := &ret
45158	if err := gensupport.DecodeResponse(target, res); err != nil {
45159		return nil, err
45160	}
45161	return ret, nil
45162	// {
45163	//   "description": "Updates an existing remarketing list.",
45164	//   "flatPath": "userprofiles/{profileId}/remarketingLists",
45165	//   "httpMethod": "PUT",
45166	//   "id": "dfareporting.remarketingLists.update",
45167	//   "parameterOrder": [
45168	//     "profileId"
45169	//   ],
45170	//   "parameters": {
45171	//     "profileId": {
45172	//       "description": "User profile ID associated with this request.",
45173	//       "format": "int64",
45174	//       "location": "path",
45175	//       "required": true,
45176	//       "type": "string"
45177	//     }
45178	//   },
45179	//   "path": "userprofiles/{profileId}/remarketingLists",
45180	//   "request": {
45181	//     "$ref": "RemarketingList"
45182	//   },
45183	//   "response": {
45184	//     "$ref": "RemarketingList"
45185	//   },
45186	//   "scopes": [
45187	//     "https://www.googleapis.com/auth/dfatrafficking"
45188	//   ]
45189	// }
45190
45191}
45192
45193// method id "dfareporting.reports.delete":
45194
45195type ReportsDeleteCall struct {
45196	s          *Service
45197	profileId  int64
45198	reportId   int64
45199	urlParams_ gensupport.URLParams
45200	ctx_       context.Context
45201	header_    http.Header
45202}
45203
45204// Delete: Deletes a report by its ID.
45205//
45206// - profileId: The Campaign Manager 360 user profile ID.
45207// - reportId: The ID of the report.
45208func (r *ReportsService) Delete(profileId int64, reportId int64) *ReportsDeleteCall {
45209	c := &ReportsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
45210	c.profileId = profileId
45211	c.reportId = reportId
45212	return c
45213}
45214
45215// Fields allows partial responses to be retrieved. See
45216// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
45217// for more information.
45218func (c *ReportsDeleteCall) Fields(s ...googleapi.Field) *ReportsDeleteCall {
45219	c.urlParams_.Set("fields", googleapi.CombineFields(s))
45220	return c
45221}
45222
45223// Context sets the context to be used in this call's Do method. Any
45224// pending HTTP request will be aborted if the provided context is
45225// canceled.
45226func (c *ReportsDeleteCall) Context(ctx context.Context) *ReportsDeleteCall {
45227	c.ctx_ = ctx
45228	return c
45229}
45230
45231// Header returns an http.Header that can be modified by the caller to
45232// add HTTP headers to the request.
45233func (c *ReportsDeleteCall) Header() http.Header {
45234	if c.header_ == nil {
45235		c.header_ = make(http.Header)
45236	}
45237	return c.header_
45238}
45239
45240func (c *ReportsDeleteCall) doRequest(alt string) (*http.Response, error) {
45241	reqHeaders := make(http.Header)
45242	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
45243	for k, v := range c.header_ {
45244		reqHeaders[k] = v
45245	}
45246	reqHeaders.Set("User-Agent", c.s.userAgent())
45247	var body io.Reader = nil
45248	c.urlParams_.Set("alt", alt)
45249	c.urlParams_.Set("prettyPrint", "false")
45250	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/reports/{reportId}")
45251	urls += "?" + c.urlParams_.Encode()
45252	req, err := http.NewRequest("DELETE", urls, body)
45253	if err != nil {
45254		return nil, err
45255	}
45256	req.Header = reqHeaders
45257	googleapi.Expand(req.URL, map[string]string{
45258		"profileId": strconv.FormatInt(c.profileId, 10),
45259		"reportId":  strconv.FormatInt(c.reportId, 10),
45260	})
45261	return gensupport.SendRequest(c.ctx_, c.s.client, req)
45262}
45263
45264// Do executes the "dfareporting.reports.delete" call.
45265func (c *ReportsDeleteCall) Do(opts ...googleapi.CallOption) error {
45266	gensupport.SetOptions(c.urlParams_, opts...)
45267	res, err := c.doRequest("json")
45268	if err != nil {
45269		return err
45270	}
45271	defer googleapi.CloseBody(res)
45272	if err := googleapi.CheckResponse(res); err != nil {
45273		return err
45274	}
45275	return nil
45276	// {
45277	//   "description": "Deletes a report by its ID.",
45278	//   "flatPath": "userprofiles/{profileId}/reports/{reportId}",
45279	//   "httpMethod": "DELETE",
45280	//   "id": "dfareporting.reports.delete",
45281	//   "parameterOrder": [
45282	//     "profileId",
45283	//     "reportId"
45284	//   ],
45285	//   "parameters": {
45286	//     "profileId": {
45287	//       "description": "The Campaign Manager 360 user profile ID.",
45288	//       "format": "int64",
45289	//       "location": "path",
45290	//       "required": true,
45291	//       "type": "string"
45292	//     },
45293	//     "reportId": {
45294	//       "description": "The ID of the report.",
45295	//       "format": "int64",
45296	//       "location": "path",
45297	//       "required": true,
45298	//       "type": "string"
45299	//     }
45300	//   },
45301	//   "path": "userprofiles/{profileId}/reports/{reportId}",
45302	//   "scopes": [
45303	//     "https://www.googleapis.com/auth/dfareporting"
45304	//   ]
45305	// }
45306
45307}
45308
45309// method id "dfareporting.reports.get":
45310
45311type ReportsGetCall struct {
45312	s            *Service
45313	profileId    int64
45314	reportId     int64
45315	urlParams_   gensupport.URLParams
45316	ifNoneMatch_ string
45317	ctx_         context.Context
45318	header_      http.Header
45319}
45320
45321// Get: Retrieves a report by its ID.
45322//
45323// - profileId: The Campaign Manager 360 user profile ID.
45324// - reportId: The ID of the report.
45325func (r *ReportsService) Get(profileId int64, reportId int64) *ReportsGetCall {
45326	c := &ReportsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
45327	c.profileId = profileId
45328	c.reportId = reportId
45329	return c
45330}
45331
45332// Fields allows partial responses to be retrieved. See
45333// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
45334// for more information.
45335func (c *ReportsGetCall) Fields(s ...googleapi.Field) *ReportsGetCall {
45336	c.urlParams_.Set("fields", googleapi.CombineFields(s))
45337	return c
45338}
45339
45340// IfNoneMatch sets the optional parameter which makes the operation
45341// fail if the object's ETag matches the given value. This is useful for
45342// getting updates only after the object has changed since the last
45343// request. Use googleapi.IsNotModified to check whether the response
45344// error from Do is the result of In-None-Match.
45345func (c *ReportsGetCall) IfNoneMatch(entityTag string) *ReportsGetCall {
45346	c.ifNoneMatch_ = entityTag
45347	return c
45348}
45349
45350// Context sets the context to be used in this call's Do method. Any
45351// pending HTTP request will be aborted if the provided context is
45352// canceled.
45353func (c *ReportsGetCall) Context(ctx context.Context) *ReportsGetCall {
45354	c.ctx_ = ctx
45355	return c
45356}
45357
45358// Header returns an http.Header that can be modified by the caller to
45359// add HTTP headers to the request.
45360func (c *ReportsGetCall) Header() http.Header {
45361	if c.header_ == nil {
45362		c.header_ = make(http.Header)
45363	}
45364	return c.header_
45365}
45366
45367func (c *ReportsGetCall) doRequest(alt string) (*http.Response, error) {
45368	reqHeaders := make(http.Header)
45369	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
45370	for k, v := range c.header_ {
45371		reqHeaders[k] = v
45372	}
45373	reqHeaders.Set("User-Agent", c.s.userAgent())
45374	if c.ifNoneMatch_ != "" {
45375		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
45376	}
45377	var body io.Reader = nil
45378	c.urlParams_.Set("alt", alt)
45379	c.urlParams_.Set("prettyPrint", "false")
45380	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/reports/{reportId}")
45381	urls += "?" + c.urlParams_.Encode()
45382	req, err := http.NewRequest("GET", urls, body)
45383	if err != nil {
45384		return nil, err
45385	}
45386	req.Header = reqHeaders
45387	googleapi.Expand(req.URL, map[string]string{
45388		"profileId": strconv.FormatInt(c.profileId, 10),
45389		"reportId":  strconv.FormatInt(c.reportId, 10),
45390	})
45391	return gensupport.SendRequest(c.ctx_, c.s.client, req)
45392}
45393
45394// Do executes the "dfareporting.reports.get" call.
45395// Exactly one of *Report or error will be non-nil. Any non-2xx status
45396// code is an error. Response headers are in either
45397// *Report.ServerResponse.Header or (if a response was returned at all)
45398// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to
45399// check whether the returned error was because http.StatusNotModified
45400// was returned.
45401func (c *ReportsGetCall) Do(opts ...googleapi.CallOption) (*Report, error) {
45402	gensupport.SetOptions(c.urlParams_, opts...)
45403	res, err := c.doRequest("json")
45404	if res != nil && res.StatusCode == http.StatusNotModified {
45405		if res.Body != nil {
45406			res.Body.Close()
45407		}
45408		return nil, &googleapi.Error{
45409			Code:   res.StatusCode,
45410			Header: res.Header,
45411		}
45412	}
45413	if err != nil {
45414		return nil, err
45415	}
45416	defer googleapi.CloseBody(res)
45417	if err := googleapi.CheckResponse(res); err != nil {
45418		return nil, err
45419	}
45420	ret := &Report{
45421		ServerResponse: googleapi.ServerResponse{
45422			Header:         res.Header,
45423			HTTPStatusCode: res.StatusCode,
45424		},
45425	}
45426	target := &ret
45427	if err := gensupport.DecodeResponse(target, res); err != nil {
45428		return nil, err
45429	}
45430	return ret, nil
45431	// {
45432	//   "description": "Retrieves a report by its ID.",
45433	//   "flatPath": "userprofiles/{profileId}/reports/{reportId}",
45434	//   "httpMethod": "GET",
45435	//   "id": "dfareporting.reports.get",
45436	//   "parameterOrder": [
45437	//     "profileId",
45438	//     "reportId"
45439	//   ],
45440	//   "parameters": {
45441	//     "profileId": {
45442	//       "description": "The Campaign Manager 360 user profile ID.",
45443	//       "format": "int64",
45444	//       "location": "path",
45445	//       "required": true,
45446	//       "type": "string"
45447	//     },
45448	//     "reportId": {
45449	//       "description": "The ID of the report.",
45450	//       "format": "int64",
45451	//       "location": "path",
45452	//       "required": true,
45453	//       "type": "string"
45454	//     }
45455	//   },
45456	//   "path": "userprofiles/{profileId}/reports/{reportId}",
45457	//   "response": {
45458	//     "$ref": "Report"
45459	//   },
45460	//   "scopes": [
45461	//     "https://www.googleapis.com/auth/dfareporting"
45462	//   ]
45463	// }
45464
45465}
45466
45467// method id "dfareporting.reports.insert":
45468
45469type ReportsInsertCall struct {
45470	s          *Service
45471	profileId  int64
45472	report     *Report
45473	urlParams_ gensupport.URLParams
45474	ctx_       context.Context
45475	header_    http.Header
45476}
45477
45478// Insert: Creates a report.
45479//
45480// - profileId: The Campaign Manager 360 user profile ID.
45481func (r *ReportsService) Insert(profileId int64, report *Report) *ReportsInsertCall {
45482	c := &ReportsInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
45483	c.profileId = profileId
45484	c.report = report
45485	return c
45486}
45487
45488// Fields allows partial responses to be retrieved. See
45489// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
45490// for more information.
45491func (c *ReportsInsertCall) Fields(s ...googleapi.Field) *ReportsInsertCall {
45492	c.urlParams_.Set("fields", googleapi.CombineFields(s))
45493	return c
45494}
45495
45496// Context sets the context to be used in this call's Do method. Any
45497// pending HTTP request will be aborted if the provided context is
45498// canceled.
45499func (c *ReportsInsertCall) Context(ctx context.Context) *ReportsInsertCall {
45500	c.ctx_ = ctx
45501	return c
45502}
45503
45504// Header returns an http.Header that can be modified by the caller to
45505// add HTTP headers to the request.
45506func (c *ReportsInsertCall) Header() http.Header {
45507	if c.header_ == nil {
45508		c.header_ = make(http.Header)
45509	}
45510	return c.header_
45511}
45512
45513func (c *ReportsInsertCall) doRequest(alt string) (*http.Response, error) {
45514	reqHeaders := make(http.Header)
45515	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
45516	for k, v := range c.header_ {
45517		reqHeaders[k] = v
45518	}
45519	reqHeaders.Set("User-Agent", c.s.userAgent())
45520	var body io.Reader = nil
45521	body, err := googleapi.WithoutDataWrapper.JSONReader(c.report)
45522	if err != nil {
45523		return nil, err
45524	}
45525	reqHeaders.Set("Content-Type", "application/json")
45526	c.urlParams_.Set("alt", alt)
45527	c.urlParams_.Set("prettyPrint", "false")
45528	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/reports")
45529	urls += "?" + c.urlParams_.Encode()
45530	req, err := http.NewRequest("POST", urls, body)
45531	if err != nil {
45532		return nil, err
45533	}
45534	req.Header = reqHeaders
45535	googleapi.Expand(req.URL, map[string]string{
45536		"profileId": strconv.FormatInt(c.profileId, 10),
45537	})
45538	return gensupport.SendRequest(c.ctx_, c.s.client, req)
45539}
45540
45541// Do executes the "dfareporting.reports.insert" call.
45542// Exactly one of *Report or error will be non-nil. Any non-2xx status
45543// code is an error. Response headers are in either
45544// *Report.ServerResponse.Header or (if a response was returned at all)
45545// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to
45546// check whether the returned error was because http.StatusNotModified
45547// was returned.
45548func (c *ReportsInsertCall) Do(opts ...googleapi.CallOption) (*Report, error) {
45549	gensupport.SetOptions(c.urlParams_, opts...)
45550	res, err := c.doRequest("json")
45551	if res != nil && res.StatusCode == http.StatusNotModified {
45552		if res.Body != nil {
45553			res.Body.Close()
45554		}
45555		return nil, &googleapi.Error{
45556			Code:   res.StatusCode,
45557			Header: res.Header,
45558		}
45559	}
45560	if err != nil {
45561		return nil, err
45562	}
45563	defer googleapi.CloseBody(res)
45564	if err := googleapi.CheckResponse(res); err != nil {
45565		return nil, err
45566	}
45567	ret := &Report{
45568		ServerResponse: googleapi.ServerResponse{
45569			Header:         res.Header,
45570			HTTPStatusCode: res.StatusCode,
45571		},
45572	}
45573	target := &ret
45574	if err := gensupport.DecodeResponse(target, res); err != nil {
45575		return nil, err
45576	}
45577	return ret, nil
45578	// {
45579	//   "description": "Creates a report.",
45580	//   "flatPath": "userprofiles/{profileId}/reports",
45581	//   "httpMethod": "POST",
45582	//   "id": "dfareporting.reports.insert",
45583	//   "parameterOrder": [
45584	//     "profileId"
45585	//   ],
45586	//   "parameters": {
45587	//     "profileId": {
45588	//       "description": "The Campaign Manager 360 user profile ID.",
45589	//       "format": "int64",
45590	//       "location": "path",
45591	//       "required": true,
45592	//       "type": "string"
45593	//     }
45594	//   },
45595	//   "path": "userprofiles/{profileId}/reports",
45596	//   "request": {
45597	//     "$ref": "Report"
45598	//   },
45599	//   "response": {
45600	//     "$ref": "Report"
45601	//   },
45602	//   "scopes": [
45603	//     "https://www.googleapis.com/auth/dfareporting"
45604	//   ]
45605	// }
45606
45607}
45608
45609// method id "dfareporting.reports.list":
45610
45611type ReportsListCall struct {
45612	s            *Service
45613	profileId    int64
45614	urlParams_   gensupport.URLParams
45615	ifNoneMatch_ string
45616	ctx_         context.Context
45617	header_      http.Header
45618}
45619
45620// List: Retrieves list of reports.
45621//
45622// - profileId: The Campaign Manager 360 user profile ID.
45623func (r *ReportsService) List(profileId int64) *ReportsListCall {
45624	c := &ReportsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
45625	c.profileId = profileId
45626	return c
45627}
45628
45629// MaxResults sets the optional parameter "maxResults": Maximum number
45630// of results to return.
45631func (c *ReportsListCall) MaxResults(maxResults int64) *ReportsListCall {
45632	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
45633	return c
45634}
45635
45636// PageToken sets the optional parameter "pageToken": The value of the
45637// nextToken from the previous result page.
45638func (c *ReportsListCall) PageToken(pageToken string) *ReportsListCall {
45639	c.urlParams_.Set("pageToken", pageToken)
45640	return c
45641}
45642
45643// Scope sets the optional parameter "scope": The scope that defines
45644// which results are returned.
45645//
45646// Possible values:
45647//   "ALL" - All reports in account.
45648//   "MINE" (default) - My reports.
45649func (c *ReportsListCall) Scope(scope string) *ReportsListCall {
45650	c.urlParams_.Set("scope", scope)
45651	return c
45652}
45653
45654// SortField sets the optional parameter "sortField": The field by which
45655// to sort the list.
45656//
45657// Possible values:
45658//   "ID" - Sort by report ID.
45659//   "LAST_MODIFIED_TIME" (default) - Sort by 'lastModifiedTime' field.
45660//   "NAME" - Sort by name of reports.
45661func (c *ReportsListCall) SortField(sortField string) *ReportsListCall {
45662	c.urlParams_.Set("sortField", sortField)
45663	return c
45664}
45665
45666// SortOrder sets the optional parameter "sortOrder": Order of sorted
45667// results.
45668//
45669// Possible values:
45670//   "ASCENDING" - Ascending order.
45671//   "DESCENDING" (default) - Descending order.
45672func (c *ReportsListCall) SortOrder(sortOrder string) *ReportsListCall {
45673	c.urlParams_.Set("sortOrder", sortOrder)
45674	return c
45675}
45676
45677// Fields allows partial responses to be retrieved. See
45678// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
45679// for more information.
45680func (c *ReportsListCall) Fields(s ...googleapi.Field) *ReportsListCall {
45681	c.urlParams_.Set("fields", googleapi.CombineFields(s))
45682	return c
45683}
45684
45685// IfNoneMatch sets the optional parameter which makes the operation
45686// fail if the object's ETag matches the given value. This is useful for
45687// getting updates only after the object has changed since the last
45688// request. Use googleapi.IsNotModified to check whether the response
45689// error from Do is the result of In-None-Match.
45690func (c *ReportsListCall) IfNoneMatch(entityTag string) *ReportsListCall {
45691	c.ifNoneMatch_ = entityTag
45692	return c
45693}
45694
45695// Context sets the context to be used in this call's Do method. Any
45696// pending HTTP request will be aborted if the provided context is
45697// canceled.
45698func (c *ReportsListCall) Context(ctx context.Context) *ReportsListCall {
45699	c.ctx_ = ctx
45700	return c
45701}
45702
45703// Header returns an http.Header that can be modified by the caller to
45704// add HTTP headers to the request.
45705func (c *ReportsListCall) Header() http.Header {
45706	if c.header_ == nil {
45707		c.header_ = make(http.Header)
45708	}
45709	return c.header_
45710}
45711
45712func (c *ReportsListCall) doRequest(alt string) (*http.Response, error) {
45713	reqHeaders := make(http.Header)
45714	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
45715	for k, v := range c.header_ {
45716		reqHeaders[k] = v
45717	}
45718	reqHeaders.Set("User-Agent", c.s.userAgent())
45719	if c.ifNoneMatch_ != "" {
45720		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
45721	}
45722	var body io.Reader = nil
45723	c.urlParams_.Set("alt", alt)
45724	c.urlParams_.Set("prettyPrint", "false")
45725	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/reports")
45726	urls += "?" + c.urlParams_.Encode()
45727	req, err := http.NewRequest("GET", urls, body)
45728	if err != nil {
45729		return nil, err
45730	}
45731	req.Header = reqHeaders
45732	googleapi.Expand(req.URL, map[string]string{
45733		"profileId": strconv.FormatInt(c.profileId, 10),
45734	})
45735	return gensupport.SendRequest(c.ctx_, c.s.client, req)
45736}
45737
45738// Do executes the "dfareporting.reports.list" call.
45739// Exactly one of *ReportList or error will be non-nil. Any non-2xx
45740// status code is an error. Response headers are in either
45741// *ReportList.ServerResponse.Header or (if a response was returned at
45742// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
45743// to check whether the returned error was because
45744// http.StatusNotModified was returned.
45745func (c *ReportsListCall) Do(opts ...googleapi.CallOption) (*ReportList, error) {
45746	gensupport.SetOptions(c.urlParams_, opts...)
45747	res, err := c.doRequest("json")
45748	if res != nil && res.StatusCode == http.StatusNotModified {
45749		if res.Body != nil {
45750			res.Body.Close()
45751		}
45752		return nil, &googleapi.Error{
45753			Code:   res.StatusCode,
45754			Header: res.Header,
45755		}
45756	}
45757	if err != nil {
45758		return nil, err
45759	}
45760	defer googleapi.CloseBody(res)
45761	if err := googleapi.CheckResponse(res); err != nil {
45762		return nil, err
45763	}
45764	ret := &ReportList{
45765		ServerResponse: googleapi.ServerResponse{
45766			Header:         res.Header,
45767			HTTPStatusCode: res.StatusCode,
45768		},
45769	}
45770	target := &ret
45771	if err := gensupport.DecodeResponse(target, res); err != nil {
45772		return nil, err
45773	}
45774	return ret, nil
45775	// {
45776	//   "description": "Retrieves list of reports.",
45777	//   "flatPath": "userprofiles/{profileId}/reports",
45778	//   "httpMethod": "GET",
45779	//   "id": "dfareporting.reports.list",
45780	//   "parameterOrder": [
45781	//     "profileId"
45782	//   ],
45783	//   "parameters": {
45784	//     "maxResults": {
45785	//       "default": "10",
45786	//       "description": "Maximum number of results to return.",
45787	//       "format": "int32",
45788	//       "location": "query",
45789	//       "maximum": "10",
45790	//       "minimum": "0",
45791	//       "type": "integer"
45792	//     },
45793	//     "pageToken": {
45794	//       "description": "The value of the nextToken from the previous result page.",
45795	//       "location": "query",
45796	//       "type": "string"
45797	//     },
45798	//     "profileId": {
45799	//       "description": "The Campaign Manager 360 user profile ID.",
45800	//       "format": "int64",
45801	//       "location": "path",
45802	//       "required": true,
45803	//       "type": "string"
45804	//     },
45805	//     "scope": {
45806	//       "default": "MINE",
45807	//       "description": "The scope that defines which results are returned.",
45808	//       "enum": [
45809	//         "ALL",
45810	//         "MINE"
45811	//       ],
45812	//       "enumDescriptions": [
45813	//         "All reports in account.",
45814	//         "My reports."
45815	//       ],
45816	//       "location": "query",
45817	//       "type": "string"
45818	//     },
45819	//     "sortField": {
45820	//       "default": "LAST_MODIFIED_TIME",
45821	//       "description": "The field by which to sort the list.",
45822	//       "enum": [
45823	//         "ID",
45824	//         "LAST_MODIFIED_TIME",
45825	//         "NAME"
45826	//       ],
45827	//       "enumDescriptions": [
45828	//         "Sort by report ID.",
45829	//         "Sort by 'lastModifiedTime' field.",
45830	//         "Sort by name of reports."
45831	//       ],
45832	//       "location": "query",
45833	//       "type": "string"
45834	//     },
45835	//     "sortOrder": {
45836	//       "default": "DESCENDING",
45837	//       "description": "Order of sorted results.",
45838	//       "enum": [
45839	//         "ASCENDING",
45840	//         "DESCENDING"
45841	//       ],
45842	//       "enumDescriptions": [
45843	//         "Ascending order.",
45844	//         "Descending order."
45845	//       ],
45846	//       "location": "query",
45847	//       "type": "string"
45848	//     }
45849	//   },
45850	//   "path": "userprofiles/{profileId}/reports",
45851	//   "response": {
45852	//     "$ref": "ReportList"
45853	//   },
45854	//   "scopes": [
45855	//     "https://www.googleapis.com/auth/dfareporting"
45856	//   ]
45857	// }
45858
45859}
45860
45861// Pages invokes f for each page of results.
45862// A non-nil error returned from f will halt the iteration.
45863// The provided context supersedes any context provided to the Context method.
45864func (c *ReportsListCall) Pages(ctx context.Context, f func(*ReportList) error) error {
45865	c.ctx_ = ctx
45866	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
45867	for {
45868		x, err := c.Do()
45869		if err != nil {
45870			return err
45871		}
45872		if err := f(x); err != nil {
45873			return err
45874		}
45875		if x.NextPageToken == "" {
45876			return nil
45877		}
45878		c.PageToken(x.NextPageToken)
45879	}
45880}
45881
45882// method id "dfareporting.reports.patch":
45883
45884type ReportsPatchCall struct {
45885	s          *Service
45886	profileId  int64
45887	reportId   int64
45888	report     *Report
45889	urlParams_ gensupport.URLParams
45890	ctx_       context.Context
45891	header_    http.Header
45892}
45893
45894// Patch: Updates an existing report. This method supports patch
45895// semantics.
45896//
45897// - profileId: The DFA user profile ID.
45898// - reportId: The ID of the report.
45899func (r *ReportsService) Patch(profileId int64, reportId int64, report *Report) *ReportsPatchCall {
45900	c := &ReportsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
45901	c.profileId = profileId
45902	c.reportId = reportId
45903	c.report = report
45904	return c
45905}
45906
45907// Fields allows partial responses to be retrieved. See
45908// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
45909// for more information.
45910func (c *ReportsPatchCall) Fields(s ...googleapi.Field) *ReportsPatchCall {
45911	c.urlParams_.Set("fields", googleapi.CombineFields(s))
45912	return c
45913}
45914
45915// Context sets the context to be used in this call's Do method. Any
45916// pending HTTP request will be aborted if the provided context is
45917// canceled.
45918func (c *ReportsPatchCall) Context(ctx context.Context) *ReportsPatchCall {
45919	c.ctx_ = ctx
45920	return c
45921}
45922
45923// Header returns an http.Header that can be modified by the caller to
45924// add HTTP headers to the request.
45925func (c *ReportsPatchCall) Header() http.Header {
45926	if c.header_ == nil {
45927		c.header_ = make(http.Header)
45928	}
45929	return c.header_
45930}
45931
45932func (c *ReportsPatchCall) doRequest(alt string) (*http.Response, error) {
45933	reqHeaders := make(http.Header)
45934	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
45935	for k, v := range c.header_ {
45936		reqHeaders[k] = v
45937	}
45938	reqHeaders.Set("User-Agent", c.s.userAgent())
45939	var body io.Reader = nil
45940	body, err := googleapi.WithoutDataWrapper.JSONReader(c.report)
45941	if err != nil {
45942		return nil, err
45943	}
45944	reqHeaders.Set("Content-Type", "application/json")
45945	c.urlParams_.Set("alt", alt)
45946	c.urlParams_.Set("prettyPrint", "false")
45947	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/reports/{reportId}")
45948	urls += "?" + c.urlParams_.Encode()
45949	req, err := http.NewRequest("PATCH", urls, body)
45950	if err != nil {
45951		return nil, err
45952	}
45953	req.Header = reqHeaders
45954	googleapi.Expand(req.URL, map[string]string{
45955		"profileId": strconv.FormatInt(c.profileId, 10),
45956		"reportId":  strconv.FormatInt(c.reportId, 10),
45957	})
45958	return gensupport.SendRequest(c.ctx_, c.s.client, req)
45959}
45960
45961// Do executes the "dfareporting.reports.patch" call.
45962// Exactly one of *Report or error will be non-nil. Any non-2xx status
45963// code is an error. Response headers are in either
45964// *Report.ServerResponse.Header or (if a response was returned at all)
45965// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to
45966// check whether the returned error was because http.StatusNotModified
45967// was returned.
45968func (c *ReportsPatchCall) Do(opts ...googleapi.CallOption) (*Report, error) {
45969	gensupport.SetOptions(c.urlParams_, opts...)
45970	res, err := c.doRequest("json")
45971	if res != nil && res.StatusCode == http.StatusNotModified {
45972		if res.Body != nil {
45973			res.Body.Close()
45974		}
45975		return nil, &googleapi.Error{
45976			Code:   res.StatusCode,
45977			Header: res.Header,
45978		}
45979	}
45980	if err != nil {
45981		return nil, err
45982	}
45983	defer googleapi.CloseBody(res)
45984	if err := googleapi.CheckResponse(res); err != nil {
45985		return nil, err
45986	}
45987	ret := &Report{
45988		ServerResponse: googleapi.ServerResponse{
45989			Header:         res.Header,
45990			HTTPStatusCode: res.StatusCode,
45991		},
45992	}
45993	target := &ret
45994	if err := gensupport.DecodeResponse(target, res); err != nil {
45995		return nil, err
45996	}
45997	return ret, nil
45998	// {
45999	//   "description": "Updates an existing report. This method supports patch semantics.",
46000	//   "flatPath": "userprofiles/{profileId}/reports/{reportId}",
46001	//   "httpMethod": "PATCH",
46002	//   "id": "dfareporting.reports.patch",
46003	//   "parameterOrder": [
46004	//     "profileId",
46005	//     "reportId"
46006	//   ],
46007	//   "parameters": {
46008	//     "profileId": {
46009	//       "description": "The DFA user profile ID.",
46010	//       "format": "int64",
46011	//       "location": "path",
46012	//       "required": true,
46013	//       "type": "string"
46014	//     },
46015	//     "reportId": {
46016	//       "description": "The ID of the report.",
46017	//       "format": "int64",
46018	//       "location": "path",
46019	//       "required": true,
46020	//       "type": "string"
46021	//     }
46022	//   },
46023	//   "path": "userprofiles/{profileId}/reports/{reportId}",
46024	//   "request": {
46025	//     "$ref": "Report"
46026	//   },
46027	//   "response": {
46028	//     "$ref": "Report"
46029	//   },
46030	//   "scopes": [
46031	//     "https://www.googleapis.com/auth/dfareporting"
46032	//   ]
46033	// }
46034
46035}
46036
46037// method id "dfareporting.reports.run":
46038
46039type ReportsRunCall struct {
46040	s          *Service
46041	profileId  int64
46042	reportId   int64
46043	urlParams_ gensupport.URLParams
46044	ctx_       context.Context
46045	header_    http.Header
46046}
46047
46048// Run: Runs a report.
46049//
46050// - profileId: The Campaign Manager 360 user profile ID.
46051// - reportId: The ID of the report.
46052func (r *ReportsService) Run(profileId int64, reportId int64) *ReportsRunCall {
46053	c := &ReportsRunCall{s: r.s, urlParams_: make(gensupport.URLParams)}
46054	c.profileId = profileId
46055	c.reportId = reportId
46056	return c
46057}
46058
46059// Synchronous sets the optional parameter "synchronous": If set and
46060// true, tries to run the report synchronously.
46061func (c *ReportsRunCall) Synchronous(synchronous bool) *ReportsRunCall {
46062	c.urlParams_.Set("synchronous", fmt.Sprint(synchronous))
46063	return c
46064}
46065
46066// Fields allows partial responses to be retrieved. See
46067// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
46068// for more information.
46069func (c *ReportsRunCall) Fields(s ...googleapi.Field) *ReportsRunCall {
46070	c.urlParams_.Set("fields", googleapi.CombineFields(s))
46071	return c
46072}
46073
46074// Context sets the context to be used in this call's Do method. Any
46075// pending HTTP request will be aborted if the provided context is
46076// canceled.
46077func (c *ReportsRunCall) Context(ctx context.Context) *ReportsRunCall {
46078	c.ctx_ = ctx
46079	return c
46080}
46081
46082// Header returns an http.Header that can be modified by the caller to
46083// add HTTP headers to the request.
46084func (c *ReportsRunCall) Header() http.Header {
46085	if c.header_ == nil {
46086		c.header_ = make(http.Header)
46087	}
46088	return c.header_
46089}
46090
46091func (c *ReportsRunCall) doRequest(alt string) (*http.Response, error) {
46092	reqHeaders := make(http.Header)
46093	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
46094	for k, v := range c.header_ {
46095		reqHeaders[k] = v
46096	}
46097	reqHeaders.Set("User-Agent", c.s.userAgent())
46098	var body io.Reader = nil
46099	c.urlParams_.Set("alt", alt)
46100	c.urlParams_.Set("prettyPrint", "false")
46101	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/reports/{reportId}/run")
46102	urls += "?" + c.urlParams_.Encode()
46103	req, err := http.NewRequest("POST", urls, body)
46104	if err != nil {
46105		return nil, err
46106	}
46107	req.Header = reqHeaders
46108	googleapi.Expand(req.URL, map[string]string{
46109		"profileId": strconv.FormatInt(c.profileId, 10),
46110		"reportId":  strconv.FormatInt(c.reportId, 10),
46111	})
46112	return gensupport.SendRequest(c.ctx_, c.s.client, req)
46113}
46114
46115// Do executes the "dfareporting.reports.run" call.
46116// Exactly one of *File or error will be non-nil. Any non-2xx status
46117// code is an error. Response headers are in either
46118// *File.ServerResponse.Header or (if a response was returned at all) in
46119// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
46120// whether the returned error was because http.StatusNotModified was
46121// returned.
46122func (c *ReportsRunCall) Do(opts ...googleapi.CallOption) (*File, error) {
46123	gensupport.SetOptions(c.urlParams_, opts...)
46124	res, err := c.doRequest("json")
46125	if res != nil && res.StatusCode == http.StatusNotModified {
46126		if res.Body != nil {
46127			res.Body.Close()
46128		}
46129		return nil, &googleapi.Error{
46130			Code:   res.StatusCode,
46131			Header: res.Header,
46132		}
46133	}
46134	if err != nil {
46135		return nil, err
46136	}
46137	defer googleapi.CloseBody(res)
46138	if err := googleapi.CheckResponse(res); err != nil {
46139		return nil, err
46140	}
46141	ret := &File{
46142		ServerResponse: googleapi.ServerResponse{
46143			Header:         res.Header,
46144			HTTPStatusCode: res.StatusCode,
46145		},
46146	}
46147	target := &ret
46148	if err := gensupport.DecodeResponse(target, res); err != nil {
46149		return nil, err
46150	}
46151	return ret, nil
46152	// {
46153	//   "description": "Runs a report.",
46154	//   "flatPath": "userprofiles/{profileId}/reports/{reportId}/run",
46155	//   "httpMethod": "POST",
46156	//   "id": "dfareporting.reports.run",
46157	//   "parameterOrder": [
46158	//     "profileId",
46159	//     "reportId"
46160	//   ],
46161	//   "parameters": {
46162	//     "profileId": {
46163	//       "description": "The Campaign Manager 360 user profile ID.",
46164	//       "format": "int64",
46165	//       "location": "path",
46166	//       "required": true,
46167	//       "type": "string"
46168	//     },
46169	//     "reportId": {
46170	//       "description": "The ID of the report.",
46171	//       "format": "int64",
46172	//       "location": "path",
46173	//       "required": true,
46174	//       "type": "string"
46175	//     },
46176	//     "synchronous": {
46177	//       "default": "false",
46178	//       "description": "If set and true, tries to run the report synchronously.",
46179	//       "location": "query",
46180	//       "type": "boolean"
46181	//     }
46182	//   },
46183	//   "path": "userprofiles/{profileId}/reports/{reportId}/run",
46184	//   "response": {
46185	//     "$ref": "File"
46186	//   },
46187	//   "scopes": [
46188	//     "https://www.googleapis.com/auth/dfareporting"
46189	//   ]
46190	// }
46191
46192}
46193
46194// method id "dfareporting.reports.update":
46195
46196type ReportsUpdateCall struct {
46197	s          *Service
46198	profileId  int64
46199	reportId   int64
46200	report     *Report
46201	urlParams_ gensupport.URLParams
46202	ctx_       context.Context
46203	header_    http.Header
46204}
46205
46206// Update: Updates a report.
46207//
46208// - profileId: The Campaign Manager 360 user profile ID.
46209// - reportId: The ID of the report.
46210func (r *ReportsService) Update(profileId int64, reportId int64, report *Report) *ReportsUpdateCall {
46211	c := &ReportsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
46212	c.profileId = profileId
46213	c.reportId = reportId
46214	c.report = report
46215	return c
46216}
46217
46218// Fields allows partial responses to be retrieved. See
46219// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
46220// for more information.
46221func (c *ReportsUpdateCall) Fields(s ...googleapi.Field) *ReportsUpdateCall {
46222	c.urlParams_.Set("fields", googleapi.CombineFields(s))
46223	return c
46224}
46225
46226// Context sets the context to be used in this call's Do method. Any
46227// pending HTTP request will be aborted if the provided context is
46228// canceled.
46229func (c *ReportsUpdateCall) Context(ctx context.Context) *ReportsUpdateCall {
46230	c.ctx_ = ctx
46231	return c
46232}
46233
46234// Header returns an http.Header that can be modified by the caller to
46235// add HTTP headers to the request.
46236func (c *ReportsUpdateCall) Header() http.Header {
46237	if c.header_ == nil {
46238		c.header_ = make(http.Header)
46239	}
46240	return c.header_
46241}
46242
46243func (c *ReportsUpdateCall) doRequest(alt string) (*http.Response, error) {
46244	reqHeaders := make(http.Header)
46245	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
46246	for k, v := range c.header_ {
46247		reqHeaders[k] = v
46248	}
46249	reqHeaders.Set("User-Agent", c.s.userAgent())
46250	var body io.Reader = nil
46251	body, err := googleapi.WithoutDataWrapper.JSONReader(c.report)
46252	if err != nil {
46253		return nil, err
46254	}
46255	reqHeaders.Set("Content-Type", "application/json")
46256	c.urlParams_.Set("alt", alt)
46257	c.urlParams_.Set("prettyPrint", "false")
46258	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/reports/{reportId}")
46259	urls += "?" + c.urlParams_.Encode()
46260	req, err := http.NewRequest("PUT", urls, body)
46261	if err != nil {
46262		return nil, err
46263	}
46264	req.Header = reqHeaders
46265	googleapi.Expand(req.URL, map[string]string{
46266		"profileId": strconv.FormatInt(c.profileId, 10),
46267		"reportId":  strconv.FormatInt(c.reportId, 10),
46268	})
46269	return gensupport.SendRequest(c.ctx_, c.s.client, req)
46270}
46271
46272// Do executes the "dfareporting.reports.update" call.
46273// Exactly one of *Report or error will be non-nil. Any non-2xx status
46274// code is an error. Response headers are in either
46275// *Report.ServerResponse.Header or (if a response was returned at all)
46276// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to
46277// check whether the returned error was because http.StatusNotModified
46278// was returned.
46279func (c *ReportsUpdateCall) Do(opts ...googleapi.CallOption) (*Report, error) {
46280	gensupport.SetOptions(c.urlParams_, opts...)
46281	res, err := c.doRequest("json")
46282	if res != nil && res.StatusCode == http.StatusNotModified {
46283		if res.Body != nil {
46284			res.Body.Close()
46285		}
46286		return nil, &googleapi.Error{
46287			Code:   res.StatusCode,
46288			Header: res.Header,
46289		}
46290	}
46291	if err != nil {
46292		return nil, err
46293	}
46294	defer googleapi.CloseBody(res)
46295	if err := googleapi.CheckResponse(res); err != nil {
46296		return nil, err
46297	}
46298	ret := &Report{
46299		ServerResponse: googleapi.ServerResponse{
46300			Header:         res.Header,
46301			HTTPStatusCode: res.StatusCode,
46302		},
46303	}
46304	target := &ret
46305	if err := gensupport.DecodeResponse(target, res); err != nil {
46306		return nil, err
46307	}
46308	return ret, nil
46309	// {
46310	//   "description": "Updates a report.",
46311	//   "flatPath": "userprofiles/{profileId}/reports/{reportId}",
46312	//   "httpMethod": "PUT",
46313	//   "id": "dfareporting.reports.update",
46314	//   "parameterOrder": [
46315	//     "profileId",
46316	//     "reportId"
46317	//   ],
46318	//   "parameters": {
46319	//     "profileId": {
46320	//       "description": "The Campaign Manager 360 user profile ID.",
46321	//       "format": "int64",
46322	//       "location": "path",
46323	//       "required": true,
46324	//       "type": "string"
46325	//     },
46326	//     "reportId": {
46327	//       "description": "The ID of the report.",
46328	//       "format": "int64",
46329	//       "location": "path",
46330	//       "required": true,
46331	//       "type": "string"
46332	//     }
46333	//   },
46334	//   "path": "userprofiles/{profileId}/reports/{reportId}",
46335	//   "request": {
46336	//     "$ref": "Report"
46337	//   },
46338	//   "response": {
46339	//     "$ref": "Report"
46340	//   },
46341	//   "scopes": [
46342	//     "https://www.googleapis.com/auth/dfareporting"
46343	//   ]
46344	// }
46345
46346}
46347
46348// method id "dfareporting.reports.compatibleFields.query":
46349
46350type ReportsCompatibleFieldsQueryCall struct {
46351	s          *Service
46352	profileId  int64
46353	report     *Report
46354	urlParams_ gensupport.URLParams
46355	ctx_       context.Context
46356	header_    http.Header
46357}
46358
46359// Query: Returns the fields that are compatible to be selected in the
46360// respective sections of a report criteria, given the fields already
46361// selected in the input report and user permissions.
46362//
46363// - profileId: The Campaign Manager 360 user profile ID.
46364func (r *ReportsCompatibleFieldsService) Query(profileId int64, report *Report) *ReportsCompatibleFieldsQueryCall {
46365	c := &ReportsCompatibleFieldsQueryCall{s: r.s, urlParams_: make(gensupport.URLParams)}
46366	c.profileId = profileId
46367	c.report = report
46368	return c
46369}
46370
46371// Fields allows partial responses to be retrieved. See
46372// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
46373// for more information.
46374func (c *ReportsCompatibleFieldsQueryCall) Fields(s ...googleapi.Field) *ReportsCompatibleFieldsQueryCall {
46375	c.urlParams_.Set("fields", googleapi.CombineFields(s))
46376	return c
46377}
46378
46379// Context sets the context to be used in this call's Do method. Any
46380// pending HTTP request will be aborted if the provided context is
46381// canceled.
46382func (c *ReportsCompatibleFieldsQueryCall) Context(ctx context.Context) *ReportsCompatibleFieldsQueryCall {
46383	c.ctx_ = ctx
46384	return c
46385}
46386
46387// Header returns an http.Header that can be modified by the caller to
46388// add HTTP headers to the request.
46389func (c *ReportsCompatibleFieldsQueryCall) Header() http.Header {
46390	if c.header_ == nil {
46391		c.header_ = make(http.Header)
46392	}
46393	return c.header_
46394}
46395
46396func (c *ReportsCompatibleFieldsQueryCall) doRequest(alt string) (*http.Response, error) {
46397	reqHeaders := make(http.Header)
46398	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
46399	for k, v := range c.header_ {
46400		reqHeaders[k] = v
46401	}
46402	reqHeaders.Set("User-Agent", c.s.userAgent())
46403	var body io.Reader = nil
46404	body, err := googleapi.WithoutDataWrapper.JSONReader(c.report)
46405	if err != nil {
46406		return nil, err
46407	}
46408	reqHeaders.Set("Content-Type", "application/json")
46409	c.urlParams_.Set("alt", alt)
46410	c.urlParams_.Set("prettyPrint", "false")
46411	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/reports/compatiblefields/query")
46412	urls += "?" + c.urlParams_.Encode()
46413	req, err := http.NewRequest("POST", urls, body)
46414	if err != nil {
46415		return nil, err
46416	}
46417	req.Header = reqHeaders
46418	googleapi.Expand(req.URL, map[string]string{
46419		"profileId": strconv.FormatInt(c.profileId, 10),
46420	})
46421	return gensupport.SendRequest(c.ctx_, c.s.client, req)
46422}
46423
46424// Do executes the "dfareporting.reports.compatibleFields.query" call.
46425// Exactly one of *CompatibleFields or error will be non-nil. Any
46426// non-2xx status code is an error. Response headers are in either
46427// *CompatibleFields.ServerResponse.Header or (if a response was
46428// returned at all) in error.(*googleapi.Error).Header. Use
46429// googleapi.IsNotModified to check whether the returned error was
46430// because http.StatusNotModified was returned.
46431func (c *ReportsCompatibleFieldsQueryCall) Do(opts ...googleapi.CallOption) (*CompatibleFields, error) {
46432	gensupport.SetOptions(c.urlParams_, opts...)
46433	res, err := c.doRequest("json")
46434	if res != nil && res.StatusCode == http.StatusNotModified {
46435		if res.Body != nil {
46436			res.Body.Close()
46437		}
46438		return nil, &googleapi.Error{
46439			Code:   res.StatusCode,
46440			Header: res.Header,
46441		}
46442	}
46443	if err != nil {
46444		return nil, err
46445	}
46446	defer googleapi.CloseBody(res)
46447	if err := googleapi.CheckResponse(res); err != nil {
46448		return nil, err
46449	}
46450	ret := &CompatibleFields{
46451		ServerResponse: googleapi.ServerResponse{
46452			Header:         res.Header,
46453			HTTPStatusCode: res.StatusCode,
46454		},
46455	}
46456	target := &ret
46457	if err := gensupport.DecodeResponse(target, res); err != nil {
46458		return nil, err
46459	}
46460	return ret, nil
46461	// {
46462	//   "description": "Returns the fields that are compatible to be selected in the respective sections of a report criteria, given the fields already selected in the input report and user permissions.",
46463	//   "flatPath": "userprofiles/{profileId}/reports/compatiblefields/query",
46464	//   "httpMethod": "POST",
46465	//   "id": "dfareporting.reports.compatibleFields.query",
46466	//   "parameterOrder": [
46467	//     "profileId"
46468	//   ],
46469	//   "parameters": {
46470	//     "profileId": {
46471	//       "description": "The Campaign Manager 360 user profile ID.",
46472	//       "format": "int64",
46473	//       "location": "path",
46474	//       "required": true,
46475	//       "type": "string"
46476	//     }
46477	//   },
46478	//   "path": "userprofiles/{profileId}/reports/compatiblefields/query",
46479	//   "request": {
46480	//     "$ref": "Report"
46481	//   },
46482	//   "response": {
46483	//     "$ref": "CompatibleFields"
46484	//   },
46485	//   "scopes": [
46486	//     "https://www.googleapis.com/auth/dfareporting"
46487	//   ]
46488	// }
46489
46490}
46491
46492// method id "dfareporting.reports.files.get":
46493
46494type ReportsFilesGetCall struct {
46495	s            *Service
46496	profileId    int64
46497	reportId     int64
46498	fileId       int64
46499	urlParams_   gensupport.URLParams
46500	ifNoneMatch_ string
46501	ctx_         context.Context
46502	header_      http.Header
46503}
46504
46505// Get: Retrieves a report file by its report ID and file ID. This
46506// method supports media download.
46507//
46508// - fileId: The ID of the report file.
46509// - profileId: The Campaign Manager 360 user profile ID.
46510// - reportId: The ID of the report.
46511func (r *ReportsFilesService) Get(profileId int64, reportId int64, fileId int64) *ReportsFilesGetCall {
46512	c := &ReportsFilesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
46513	c.profileId = profileId
46514	c.reportId = reportId
46515	c.fileId = fileId
46516	return c
46517}
46518
46519// Fields allows partial responses to be retrieved. See
46520// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
46521// for more information.
46522func (c *ReportsFilesGetCall) Fields(s ...googleapi.Field) *ReportsFilesGetCall {
46523	c.urlParams_.Set("fields", googleapi.CombineFields(s))
46524	return c
46525}
46526
46527// IfNoneMatch sets the optional parameter which makes the operation
46528// fail if the object's ETag matches the given value. This is useful for
46529// getting updates only after the object has changed since the last
46530// request. Use googleapi.IsNotModified to check whether the response
46531// error from Do is the result of In-None-Match.
46532func (c *ReportsFilesGetCall) IfNoneMatch(entityTag string) *ReportsFilesGetCall {
46533	c.ifNoneMatch_ = entityTag
46534	return c
46535}
46536
46537// Context sets the context to be used in this call's Do and Download
46538// methods. Any pending HTTP request will be aborted if the provided
46539// context is canceled.
46540func (c *ReportsFilesGetCall) Context(ctx context.Context) *ReportsFilesGetCall {
46541	c.ctx_ = ctx
46542	return c
46543}
46544
46545// Header returns an http.Header that can be modified by the caller to
46546// add HTTP headers to the request.
46547func (c *ReportsFilesGetCall) Header() http.Header {
46548	if c.header_ == nil {
46549		c.header_ = make(http.Header)
46550	}
46551	return c.header_
46552}
46553
46554func (c *ReportsFilesGetCall) doRequest(alt string) (*http.Response, error) {
46555	reqHeaders := make(http.Header)
46556	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
46557	for k, v := range c.header_ {
46558		reqHeaders[k] = v
46559	}
46560	reqHeaders.Set("User-Agent", c.s.userAgent())
46561	if c.ifNoneMatch_ != "" {
46562		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
46563	}
46564	var body io.Reader = nil
46565	c.urlParams_.Set("alt", alt)
46566	c.urlParams_.Set("prettyPrint", "false")
46567	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/reports/{reportId}/files/{fileId}")
46568	urls += "?" + c.urlParams_.Encode()
46569	req, err := http.NewRequest("GET", urls, body)
46570	if err != nil {
46571		return nil, err
46572	}
46573	req.Header = reqHeaders
46574	googleapi.Expand(req.URL, map[string]string{
46575		"profileId": strconv.FormatInt(c.profileId, 10),
46576		"reportId":  strconv.FormatInt(c.reportId, 10),
46577		"fileId":    strconv.FormatInt(c.fileId, 10),
46578	})
46579	return gensupport.SendRequest(c.ctx_, c.s.client, req)
46580}
46581
46582// Download fetches the API endpoint's "media" value, instead of the normal
46583// API response value. If the returned error is nil, the Response is guaranteed to
46584// have a 2xx status code. Callers must close the Response.Body as usual.
46585func (c *ReportsFilesGetCall) Download(opts ...googleapi.CallOption) (*http.Response, error) {
46586	gensupport.SetOptions(c.urlParams_, opts...)
46587	res, err := c.doRequest("media")
46588	if err != nil {
46589		return nil, err
46590	}
46591	if err := googleapi.CheckResponse(res); err != nil {
46592		res.Body.Close()
46593		return nil, err
46594	}
46595	return res, nil
46596}
46597
46598// Do executes the "dfareporting.reports.files.get" call.
46599// Exactly one of *File or error will be non-nil. Any non-2xx status
46600// code is an error. Response headers are in either
46601// *File.ServerResponse.Header or (if a response was returned at all) in
46602// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
46603// whether the returned error was because http.StatusNotModified was
46604// returned.
46605func (c *ReportsFilesGetCall) Do(opts ...googleapi.CallOption) (*File, error) {
46606	gensupport.SetOptions(c.urlParams_, opts...)
46607	res, err := c.doRequest("json")
46608	if res != nil && res.StatusCode == http.StatusNotModified {
46609		if res.Body != nil {
46610			res.Body.Close()
46611		}
46612		return nil, &googleapi.Error{
46613			Code:   res.StatusCode,
46614			Header: res.Header,
46615		}
46616	}
46617	if err != nil {
46618		return nil, err
46619	}
46620	defer googleapi.CloseBody(res)
46621	if err := googleapi.CheckResponse(res); err != nil {
46622		return nil, err
46623	}
46624	ret := &File{
46625		ServerResponse: googleapi.ServerResponse{
46626			Header:         res.Header,
46627			HTTPStatusCode: res.StatusCode,
46628		},
46629	}
46630	target := &ret
46631	if err := gensupport.DecodeResponse(target, res); err != nil {
46632		return nil, err
46633	}
46634	return ret, nil
46635	// {
46636	//   "description": "Retrieves a report file by its report ID and file ID. This method supports media download.",
46637	//   "flatPath": "userprofiles/{profileId}/reports/{reportId}/files/{fileId}",
46638	//   "httpMethod": "GET",
46639	//   "id": "dfareporting.reports.files.get",
46640	//   "parameterOrder": [
46641	//     "profileId",
46642	//     "reportId",
46643	//     "fileId"
46644	//   ],
46645	//   "parameters": {
46646	//     "fileId": {
46647	//       "description": "The ID of the report file.",
46648	//       "format": "int64",
46649	//       "location": "path",
46650	//       "required": true,
46651	//       "type": "string"
46652	//     },
46653	//     "profileId": {
46654	//       "description": "The Campaign Manager 360 user profile ID.",
46655	//       "format": "int64",
46656	//       "location": "path",
46657	//       "required": true,
46658	//       "type": "string"
46659	//     },
46660	//     "reportId": {
46661	//       "description": "The ID of the report.",
46662	//       "format": "int64",
46663	//       "location": "path",
46664	//       "required": true,
46665	//       "type": "string"
46666	//     }
46667	//   },
46668	//   "path": "userprofiles/{profileId}/reports/{reportId}/files/{fileId}",
46669	//   "response": {
46670	//     "$ref": "File"
46671	//   },
46672	//   "scopes": [
46673	//     "https://www.googleapis.com/auth/dfareporting"
46674	//   ],
46675	//   "supportsMediaDownload": true
46676	// }
46677
46678}
46679
46680// method id "dfareporting.reports.files.list":
46681
46682type ReportsFilesListCall struct {
46683	s            *Service
46684	profileId    int64
46685	reportId     int64
46686	urlParams_   gensupport.URLParams
46687	ifNoneMatch_ string
46688	ctx_         context.Context
46689	header_      http.Header
46690}
46691
46692// List: Lists files for a report.
46693//
46694// - profileId: The Campaign Manager 360 user profile ID.
46695// - reportId: The ID of the parent report.
46696func (r *ReportsFilesService) List(profileId int64, reportId int64) *ReportsFilesListCall {
46697	c := &ReportsFilesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
46698	c.profileId = profileId
46699	c.reportId = reportId
46700	return c
46701}
46702
46703// MaxResults sets the optional parameter "maxResults": Maximum number
46704// of results to return.
46705func (c *ReportsFilesListCall) MaxResults(maxResults int64) *ReportsFilesListCall {
46706	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
46707	return c
46708}
46709
46710// PageToken sets the optional parameter "pageToken": The value of the
46711// nextToken from the previous result page.
46712func (c *ReportsFilesListCall) PageToken(pageToken string) *ReportsFilesListCall {
46713	c.urlParams_.Set("pageToken", pageToken)
46714	return c
46715}
46716
46717// SortField sets the optional parameter "sortField": The field by which
46718// to sort the list.
46719//
46720// Possible values:
46721//   "ID"
46722//   "LAST_MODIFIED_TIME" (default)
46723func (c *ReportsFilesListCall) SortField(sortField string) *ReportsFilesListCall {
46724	c.urlParams_.Set("sortField", sortField)
46725	return c
46726}
46727
46728// SortOrder sets the optional parameter "sortOrder": Order of sorted
46729// results.
46730//
46731// Possible values:
46732//   "ASCENDING"
46733//   "DESCENDING" (default)
46734func (c *ReportsFilesListCall) SortOrder(sortOrder string) *ReportsFilesListCall {
46735	c.urlParams_.Set("sortOrder", sortOrder)
46736	return c
46737}
46738
46739// Fields allows partial responses to be retrieved. See
46740// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
46741// for more information.
46742func (c *ReportsFilesListCall) Fields(s ...googleapi.Field) *ReportsFilesListCall {
46743	c.urlParams_.Set("fields", googleapi.CombineFields(s))
46744	return c
46745}
46746
46747// IfNoneMatch sets the optional parameter which makes the operation
46748// fail if the object's ETag matches the given value. This is useful for
46749// getting updates only after the object has changed since the last
46750// request. Use googleapi.IsNotModified to check whether the response
46751// error from Do is the result of In-None-Match.
46752func (c *ReportsFilesListCall) IfNoneMatch(entityTag string) *ReportsFilesListCall {
46753	c.ifNoneMatch_ = entityTag
46754	return c
46755}
46756
46757// Context sets the context to be used in this call's Do method. Any
46758// pending HTTP request will be aborted if the provided context is
46759// canceled.
46760func (c *ReportsFilesListCall) Context(ctx context.Context) *ReportsFilesListCall {
46761	c.ctx_ = ctx
46762	return c
46763}
46764
46765// Header returns an http.Header that can be modified by the caller to
46766// add HTTP headers to the request.
46767func (c *ReportsFilesListCall) Header() http.Header {
46768	if c.header_ == nil {
46769		c.header_ = make(http.Header)
46770	}
46771	return c.header_
46772}
46773
46774func (c *ReportsFilesListCall) doRequest(alt string) (*http.Response, error) {
46775	reqHeaders := make(http.Header)
46776	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
46777	for k, v := range c.header_ {
46778		reqHeaders[k] = v
46779	}
46780	reqHeaders.Set("User-Agent", c.s.userAgent())
46781	if c.ifNoneMatch_ != "" {
46782		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
46783	}
46784	var body io.Reader = nil
46785	c.urlParams_.Set("alt", alt)
46786	c.urlParams_.Set("prettyPrint", "false")
46787	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/reports/{reportId}/files")
46788	urls += "?" + c.urlParams_.Encode()
46789	req, err := http.NewRequest("GET", urls, body)
46790	if err != nil {
46791		return nil, err
46792	}
46793	req.Header = reqHeaders
46794	googleapi.Expand(req.URL, map[string]string{
46795		"profileId": strconv.FormatInt(c.profileId, 10),
46796		"reportId":  strconv.FormatInt(c.reportId, 10),
46797	})
46798	return gensupport.SendRequest(c.ctx_, c.s.client, req)
46799}
46800
46801// Do executes the "dfareporting.reports.files.list" call.
46802// Exactly one of *FileList or error will be non-nil. Any non-2xx status
46803// code is an error. Response headers are in either
46804// *FileList.ServerResponse.Header or (if a response was returned at
46805// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
46806// to check whether the returned error was because
46807// http.StatusNotModified was returned.
46808func (c *ReportsFilesListCall) Do(opts ...googleapi.CallOption) (*FileList, error) {
46809	gensupport.SetOptions(c.urlParams_, opts...)
46810	res, err := c.doRequest("json")
46811	if res != nil && res.StatusCode == http.StatusNotModified {
46812		if res.Body != nil {
46813			res.Body.Close()
46814		}
46815		return nil, &googleapi.Error{
46816			Code:   res.StatusCode,
46817			Header: res.Header,
46818		}
46819	}
46820	if err != nil {
46821		return nil, err
46822	}
46823	defer googleapi.CloseBody(res)
46824	if err := googleapi.CheckResponse(res); err != nil {
46825		return nil, err
46826	}
46827	ret := &FileList{
46828		ServerResponse: googleapi.ServerResponse{
46829			Header:         res.Header,
46830			HTTPStatusCode: res.StatusCode,
46831		},
46832	}
46833	target := &ret
46834	if err := gensupport.DecodeResponse(target, res); err != nil {
46835		return nil, err
46836	}
46837	return ret, nil
46838	// {
46839	//   "description": "Lists files for a report.",
46840	//   "flatPath": "userprofiles/{profileId}/reports/{reportId}/files",
46841	//   "httpMethod": "GET",
46842	//   "id": "dfareporting.reports.files.list",
46843	//   "parameterOrder": [
46844	//     "profileId",
46845	//     "reportId"
46846	//   ],
46847	//   "parameters": {
46848	//     "maxResults": {
46849	//       "default": "10",
46850	//       "description": "Maximum number of results to return.",
46851	//       "format": "int32",
46852	//       "location": "query",
46853	//       "maximum": "10",
46854	//       "minimum": "0",
46855	//       "type": "integer"
46856	//     },
46857	//     "pageToken": {
46858	//       "description": "The value of the nextToken from the previous result page.",
46859	//       "location": "query",
46860	//       "type": "string"
46861	//     },
46862	//     "profileId": {
46863	//       "description": "The Campaign Manager 360 user profile ID.",
46864	//       "format": "int64",
46865	//       "location": "path",
46866	//       "required": true,
46867	//       "type": "string"
46868	//     },
46869	//     "reportId": {
46870	//       "description": "The ID of the parent report.",
46871	//       "format": "int64",
46872	//       "location": "path",
46873	//       "required": true,
46874	//       "type": "string"
46875	//     },
46876	//     "sortField": {
46877	//       "default": "LAST_MODIFIED_TIME",
46878	//       "description": "The field by which to sort the list.",
46879	//       "enum": [
46880	//         "ID",
46881	//         "LAST_MODIFIED_TIME"
46882	//       ],
46883	//       "enumDescriptions": [
46884	//         "",
46885	//         ""
46886	//       ],
46887	//       "location": "query",
46888	//       "type": "string"
46889	//     },
46890	//     "sortOrder": {
46891	//       "default": "DESCENDING",
46892	//       "description": "Order of sorted results.",
46893	//       "enum": [
46894	//         "ASCENDING",
46895	//         "DESCENDING"
46896	//       ],
46897	//       "enumDescriptions": [
46898	//         "",
46899	//         ""
46900	//       ],
46901	//       "location": "query",
46902	//       "type": "string"
46903	//     }
46904	//   },
46905	//   "path": "userprofiles/{profileId}/reports/{reportId}/files",
46906	//   "response": {
46907	//     "$ref": "FileList"
46908	//   },
46909	//   "scopes": [
46910	//     "https://www.googleapis.com/auth/dfareporting"
46911	//   ]
46912	// }
46913
46914}
46915
46916// Pages invokes f for each page of results.
46917// A non-nil error returned from f will halt the iteration.
46918// The provided context supersedes any context provided to the Context method.
46919func (c *ReportsFilesListCall) Pages(ctx context.Context, f func(*FileList) error) error {
46920	c.ctx_ = ctx
46921	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
46922	for {
46923		x, err := c.Do()
46924		if err != nil {
46925			return err
46926		}
46927		if err := f(x); err != nil {
46928			return err
46929		}
46930		if x.NextPageToken == "" {
46931			return nil
46932		}
46933		c.PageToken(x.NextPageToken)
46934	}
46935}
46936
46937// method id "dfareporting.sites.get":
46938
46939type SitesGetCall struct {
46940	s            *Service
46941	profileId    int64
46942	id           int64
46943	urlParams_   gensupport.URLParams
46944	ifNoneMatch_ string
46945	ctx_         context.Context
46946	header_      http.Header
46947}
46948
46949// Get: Gets one site by ID.
46950//
46951// - id: Site ID.
46952// - profileId: User profile ID associated with this request.
46953func (r *SitesService) Get(profileId int64, id int64) *SitesGetCall {
46954	c := &SitesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
46955	c.profileId = profileId
46956	c.id = id
46957	return c
46958}
46959
46960// Fields allows partial responses to be retrieved. See
46961// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
46962// for more information.
46963func (c *SitesGetCall) Fields(s ...googleapi.Field) *SitesGetCall {
46964	c.urlParams_.Set("fields", googleapi.CombineFields(s))
46965	return c
46966}
46967
46968// IfNoneMatch sets the optional parameter which makes the operation
46969// fail if the object's ETag matches the given value. This is useful for
46970// getting updates only after the object has changed since the last
46971// request. Use googleapi.IsNotModified to check whether the response
46972// error from Do is the result of In-None-Match.
46973func (c *SitesGetCall) IfNoneMatch(entityTag string) *SitesGetCall {
46974	c.ifNoneMatch_ = entityTag
46975	return c
46976}
46977
46978// Context sets the context to be used in this call's Do method. Any
46979// pending HTTP request will be aborted if the provided context is
46980// canceled.
46981func (c *SitesGetCall) Context(ctx context.Context) *SitesGetCall {
46982	c.ctx_ = ctx
46983	return c
46984}
46985
46986// Header returns an http.Header that can be modified by the caller to
46987// add HTTP headers to the request.
46988func (c *SitesGetCall) Header() http.Header {
46989	if c.header_ == nil {
46990		c.header_ = make(http.Header)
46991	}
46992	return c.header_
46993}
46994
46995func (c *SitesGetCall) doRequest(alt string) (*http.Response, error) {
46996	reqHeaders := make(http.Header)
46997	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
46998	for k, v := range c.header_ {
46999		reqHeaders[k] = v
47000	}
47001	reqHeaders.Set("User-Agent", c.s.userAgent())
47002	if c.ifNoneMatch_ != "" {
47003		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
47004	}
47005	var body io.Reader = nil
47006	c.urlParams_.Set("alt", alt)
47007	c.urlParams_.Set("prettyPrint", "false")
47008	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/sites/{id}")
47009	urls += "?" + c.urlParams_.Encode()
47010	req, err := http.NewRequest("GET", urls, body)
47011	if err != nil {
47012		return nil, err
47013	}
47014	req.Header = reqHeaders
47015	googleapi.Expand(req.URL, map[string]string{
47016		"profileId": strconv.FormatInt(c.profileId, 10),
47017		"id":        strconv.FormatInt(c.id, 10),
47018	})
47019	return gensupport.SendRequest(c.ctx_, c.s.client, req)
47020}
47021
47022// Do executes the "dfareporting.sites.get" call.
47023// Exactly one of *Site or error will be non-nil. Any non-2xx status
47024// code is an error. Response headers are in either
47025// *Site.ServerResponse.Header or (if a response was returned at all) in
47026// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
47027// whether the returned error was because http.StatusNotModified was
47028// returned.
47029func (c *SitesGetCall) Do(opts ...googleapi.CallOption) (*Site, error) {
47030	gensupport.SetOptions(c.urlParams_, opts...)
47031	res, err := c.doRequest("json")
47032	if res != nil && res.StatusCode == http.StatusNotModified {
47033		if res.Body != nil {
47034			res.Body.Close()
47035		}
47036		return nil, &googleapi.Error{
47037			Code:   res.StatusCode,
47038			Header: res.Header,
47039		}
47040	}
47041	if err != nil {
47042		return nil, err
47043	}
47044	defer googleapi.CloseBody(res)
47045	if err := googleapi.CheckResponse(res); err != nil {
47046		return nil, err
47047	}
47048	ret := &Site{
47049		ServerResponse: googleapi.ServerResponse{
47050			Header:         res.Header,
47051			HTTPStatusCode: res.StatusCode,
47052		},
47053	}
47054	target := &ret
47055	if err := gensupport.DecodeResponse(target, res); err != nil {
47056		return nil, err
47057	}
47058	return ret, nil
47059	// {
47060	//   "description": "Gets one site by ID.",
47061	//   "flatPath": "userprofiles/{profileId}/sites/{id}",
47062	//   "httpMethod": "GET",
47063	//   "id": "dfareporting.sites.get",
47064	//   "parameterOrder": [
47065	//     "profileId",
47066	//     "id"
47067	//   ],
47068	//   "parameters": {
47069	//     "id": {
47070	//       "description": "Site ID.",
47071	//       "format": "int64",
47072	//       "location": "path",
47073	//       "required": true,
47074	//       "type": "string"
47075	//     },
47076	//     "profileId": {
47077	//       "description": "User profile ID associated with this request.",
47078	//       "format": "int64",
47079	//       "location": "path",
47080	//       "required": true,
47081	//       "type": "string"
47082	//     }
47083	//   },
47084	//   "path": "userprofiles/{profileId}/sites/{id}",
47085	//   "response": {
47086	//     "$ref": "Site"
47087	//   },
47088	//   "scopes": [
47089	//     "https://www.googleapis.com/auth/dfatrafficking"
47090	//   ]
47091	// }
47092
47093}
47094
47095// method id "dfareporting.sites.insert":
47096
47097type SitesInsertCall struct {
47098	s          *Service
47099	profileId  int64
47100	site       *Site
47101	urlParams_ gensupport.URLParams
47102	ctx_       context.Context
47103	header_    http.Header
47104}
47105
47106// Insert: Inserts a new site.
47107//
47108// - profileId: User profile ID associated with this request.
47109func (r *SitesService) Insert(profileId int64, site *Site) *SitesInsertCall {
47110	c := &SitesInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
47111	c.profileId = profileId
47112	c.site = site
47113	return c
47114}
47115
47116// Fields allows partial responses to be retrieved. See
47117// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
47118// for more information.
47119func (c *SitesInsertCall) Fields(s ...googleapi.Field) *SitesInsertCall {
47120	c.urlParams_.Set("fields", googleapi.CombineFields(s))
47121	return c
47122}
47123
47124// Context sets the context to be used in this call's Do method. Any
47125// pending HTTP request will be aborted if the provided context is
47126// canceled.
47127func (c *SitesInsertCall) Context(ctx context.Context) *SitesInsertCall {
47128	c.ctx_ = ctx
47129	return c
47130}
47131
47132// Header returns an http.Header that can be modified by the caller to
47133// add HTTP headers to the request.
47134func (c *SitesInsertCall) Header() http.Header {
47135	if c.header_ == nil {
47136		c.header_ = make(http.Header)
47137	}
47138	return c.header_
47139}
47140
47141func (c *SitesInsertCall) doRequest(alt string) (*http.Response, error) {
47142	reqHeaders := make(http.Header)
47143	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
47144	for k, v := range c.header_ {
47145		reqHeaders[k] = v
47146	}
47147	reqHeaders.Set("User-Agent", c.s.userAgent())
47148	var body io.Reader = nil
47149	body, err := googleapi.WithoutDataWrapper.JSONReader(c.site)
47150	if err != nil {
47151		return nil, err
47152	}
47153	reqHeaders.Set("Content-Type", "application/json")
47154	c.urlParams_.Set("alt", alt)
47155	c.urlParams_.Set("prettyPrint", "false")
47156	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/sites")
47157	urls += "?" + c.urlParams_.Encode()
47158	req, err := http.NewRequest("POST", urls, body)
47159	if err != nil {
47160		return nil, err
47161	}
47162	req.Header = reqHeaders
47163	googleapi.Expand(req.URL, map[string]string{
47164		"profileId": strconv.FormatInt(c.profileId, 10),
47165	})
47166	return gensupport.SendRequest(c.ctx_, c.s.client, req)
47167}
47168
47169// Do executes the "dfareporting.sites.insert" call.
47170// Exactly one of *Site or error will be non-nil. Any non-2xx status
47171// code is an error. Response headers are in either
47172// *Site.ServerResponse.Header or (if a response was returned at all) in
47173// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
47174// whether the returned error was because http.StatusNotModified was
47175// returned.
47176func (c *SitesInsertCall) Do(opts ...googleapi.CallOption) (*Site, error) {
47177	gensupport.SetOptions(c.urlParams_, opts...)
47178	res, err := c.doRequest("json")
47179	if res != nil && res.StatusCode == http.StatusNotModified {
47180		if res.Body != nil {
47181			res.Body.Close()
47182		}
47183		return nil, &googleapi.Error{
47184			Code:   res.StatusCode,
47185			Header: res.Header,
47186		}
47187	}
47188	if err != nil {
47189		return nil, err
47190	}
47191	defer googleapi.CloseBody(res)
47192	if err := googleapi.CheckResponse(res); err != nil {
47193		return nil, err
47194	}
47195	ret := &Site{
47196		ServerResponse: googleapi.ServerResponse{
47197			Header:         res.Header,
47198			HTTPStatusCode: res.StatusCode,
47199		},
47200	}
47201	target := &ret
47202	if err := gensupport.DecodeResponse(target, res); err != nil {
47203		return nil, err
47204	}
47205	return ret, nil
47206	// {
47207	//   "description": "Inserts a new site.",
47208	//   "flatPath": "userprofiles/{profileId}/sites",
47209	//   "httpMethod": "POST",
47210	//   "id": "dfareporting.sites.insert",
47211	//   "parameterOrder": [
47212	//     "profileId"
47213	//   ],
47214	//   "parameters": {
47215	//     "profileId": {
47216	//       "description": "User profile ID associated with this request.",
47217	//       "format": "int64",
47218	//       "location": "path",
47219	//       "required": true,
47220	//       "type": "string"
47221	//     }
47222	//   },
47223	//   "path": "userprofiles/{profileId}/sites",
47224	//   "request": {
47225	//     "$ref": "Site"
47226	//   },
47227	//   "response": {
47228	//     "$ref": "Site"
47229	//   },
47230	//   "scopes": [
47231	//     "https://www.googleapis.com/auth/dfatrafficking"
47232	//   ]
47233	// }
47234
47235}
47236
47237// method id "dfareporting.sites.list":
47238
47239type SitesListCall struct {
47240	s            *Service
47241	profileId    int64
47242	urlParams_   gensupport.URLParams
47243	ifNoneMatch_ string
47244	ctx_         context.Context
47245	header_      http.Header
47246}
47247
47248// List: Retrieves a list of sites, possibly filtered. This method
47249// supports paging.
47250//
47251// - profileId: User profile ID associated with this request.
47252func (r *SitesService) List(profileId int64) *SitesListCall {
47253	c := &SitesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
47254	c.profileId = profileId
47255	return c
47256}
47257
47258// AcceptsInStreamVideoPlacements sets the optional parameter
47259// "acceptsInStreamVideoPlacements": This search filter is no longer
47260// supported and will have no effect on the results returned.
47261func (c *SitesListCall) AcceptsInStreamVideoPlacements(acceptsInStreamVideoPlacements bool) *SitesListCall {
47262	c.urlParams_.Set("acceptsInStreamVideoPlacements", fmt.Sprint(acceptsInStreamVideoPlacements))
47263	return c
47264}
47265
47266// AcceptsInterstitialPlacements sets the optional parameter
47267// "acceptsInterstitialPlacements": This search filter is no longer
47268// supported and will have no effect on the results returned.
47269func (c *SitesListCall) AcceptsInterstitialPlacements(acceptsInterstitialPlacements bool) *SitesListCall {
47270	c.urlParams_.Set("acceptsInterstitialPlacements", fmt.Sprint(acceptsInterstitialPlacements))
47271	return c
47272}
47273
47274// AcceptsPublisherPaidPlacements sets the optional parameter
47275// "acceptsPublisherPaidPlacements": Select only sites that accept
47276// publisher paid placements.
47277func (c *SitesListCall) AcceptsPublisherPaidPlacements(acceptsPublisherPaidPlacements bool) *SitesListCall {
47278	c.urlParams_.Set("acceptsPublisherPaidPlacements", fmt.Sprint(acceptsPublisherPaidPlacements))
47279	return c
47280}
47281
47282// AdWordsSite sets the optional parameter "adWordsSite": Select only
47283// AdWords sites.
47284func (c *SitesListCall) AdWordsSite(adWordsSite bool) *SitesListCall {
47285	c.urlParams_.Set("adWordsSite", fmt.Sprint(adWordsSite))
47286	return c
47287}
47288
47289// Approved sets the optional parameter "approved": Select only approved
47290// sites.
47291func (c *SitesListCall) Approved(approved bool) *SitesListCall {
47292	c.urlParams_.Set("approved", fmt.Sprint(approved))
47293	return c
47294}
47295
47296// CampaignIds sets the optional parameter "campaignIds": Select only
47297// sites with these campaign IDs.
47298func (c *SitesListCall) CampaignIds(campaignIds ...int64) *SitesListCall {
47299	var campaignIds_ []string
47300	for _, v := range campaignIds {
47301		campaignIds_ = append(campaignIds_, fmt.Sprint(v))
47302	}
47303	c.urlParams_.SetMulti("campaignIds", campaignIds_)
47304	return c
47305}
47306
47307// DirectorySiteIds sets the optional parameter "directorySiteIds":
47308// Select only sites with these directory site IDs.
47309func (c *SitesListCall) DirectorySiteIds(directorySiteIds ...int64) *SitesListCall {
47310	var directorySiteIds_ []string
47311	for _, v := range directorySiteIds {
47312		directorySiteIds_ = append(directorySiteIds_, fmt.Sprint(v))
47313	}
47314	c.urlParams_.SetMulti("directorySiteIds", directorySiteIds_)
47315	return c
47316}
47317
47318// Ids sets the optional parameter "ids": Select only sites with these
47319// IDs.
47320func (c *SitesListCall) Ids(ids ...int64) *SitesListCall {
47321	var ids_ []string
47322	for _, v := range ids {
47323		ids_ = append(ids_, fmt.Sprint(v))
47324	}
47325	c.urlParams_.SetMulti("ids", ids_)
47326	return c
47327}
47328
47329// MaxResults sets the optional parameter "maxResults": Maximum number
47330// of results to return.
47331func (c *SitesListCall) MaxResults(maxResults int64) *SitesListCall {
47332	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
47333	return c
47334}
47335
47336// PageToken sets the optional parameter "pageToken": Value of the
47337// nextPageToken from the previous result page.
47338func (c *SitesListCall) PageToken(pageToken string) *SitesListCall {
47339	c.urlParams_.Set("pageToken", pageToken)
47340	return c
47341}
47342
47343// SearchString sets the optional parameter "searchString": Allows
47344// searching for objects by name, ID or keyName. Wildcards (*) are
47345// allowed. For example, "site*2015" will return objects with names like
47346// "site June 2015", "site April 2015", or simply "site 2015". Most of
47347// the searches also add wildcards implicitly at the start and the end
47348// of the search string. For example, a search string of "site" will
47349// match objects with name "my site", "site 2015", or simply "site".
47350func (c *SitesListCall) SearchString(searchString string) *SitesListCall {
47351	c.urlParams_.Set("searchString", searchString)
47352	return c
47353}
47354
47355// SortField sets the optional parameter "sortField": Field by which to
47356// sort the list.
47357//
47358// Possible values:
47359//   "ID" (default)
47360//   "NAME"
47361func (c *SitesListCall) SortField(sortField string) *SitesListCall {
47362	c.urlParams_.Set("sortField", sortField)
47363	return c
47364}
47365
47366// SortOrder sets the optional parameter "sortOrder": Order of sorted
47367// results.
47368//
47369// Possible values:
47370//   "ASCENDING" (default)
47371//   "DESCENDING"
47372func (c *SitesListCall) SortOrder(sortOrder string) *SitesListCall {
47373	c.urlParams_.Set("sortOrder", sortOrder)
47374	return c
47375}
47376
47377// SubaccountId sets the optional parameter "subaccountId": Select only
47378// sites with this subaccount ID.
47379func (c *SitesListCall) SubaccountId(subaccountId int64) *SitesListCall {
47380	c.urlParams_.Set("subaccountId", fmt.Sprint(subaccountId))
47381	return c
47382}
47383
47384// UnmappedSite sets the optional parameter "unmappedSite": Select only
47385// sites that have not been mapped to a directory site.
47386func (c *SitesListCall) UnmappedSite(unmappedSite bool) *SitesListCall {
47387	c.urlParams_.Set("unmappedSite", fmt.Sprint(unmappedSite))
47388	return c
47389}
47390
47391// Fields allows partial responses to be retrieved. See
47392// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
47393// for more information.
47394func (c *SitesListCall) Fields(s ...googleapi.Field) *SitesListCall {
47395	c.urlParams_.Set("fields", googleapi.CombineFields(s))
47396	return c
47397}
47398
47399// IfNoneMatch sets the optional parameter which makes the operation
47400// fail if the object's ETag matches the given value. This is useful for
47401// getting updates only after the object has changed since the last
47402// request. Use googleapi.IsNotModified to check whether the response
47403// error from Do is the result of In-None-Match.
47404func (c *SitesListCall) IfNoneMatch(entityTag string) *SitesListCall {
47405	c.ifNoneMatch_ = entityTag
47406	return c
47407}
47408
47409// Context sets the context to be used in this call's Do method. Any
47410// pending HTTP request will be aborted if the provided context is
47411// canceled.
47412func (c *SitesListCall) Context(ctx context.Context) *SitesListCall {
47413	c.ctx_ = ctx
47414	return c
47415}
47416
47417// Header returns an http.Header that can be modified by the caller to
47418// add HTTP headers to the request.
47419func (c *SitesListCall) Header() http.Header {
47420	if c.header_ == nil {
47421		c.header_ = make(http.Header)
47422	}
47423	return c.header_
47424}
47425
47426func (c *SitesListCall) doRequest(alt string) (*http.Response, error) {
47427	reqHeaders := make(http.Header)
47428	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
47429	for k, v := range c.header_ {
47430		reqHeaders[k] = v
47431	}
47432	reqHeaders.Set("User-Agent", c.s.userAgent())
47433	if c.ifNoneMatch_ != "" {
47434		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
47435	}
47436	var body io.Reader = nil
47437	c.urlParams_.Set("alt", alt)
47438	c.urlParams_.Set("prettyPrint", "false")
47439	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/sites")
47440	urls += "?" + c.urlParams_.Encode()
47441	req, err := http.NewRequest("GET", urls, body)
47442	if err != nil {
47443		return nil, err
47444	}
47445	req.Header = reqHeaders
47446	googleapi.Expand(req.URL, map[string]string{
47447		"profileId": strconv.FormatInt(c.profileId, 10),
47448	})
47449	return gensupport.SendRequest(c.ctx_, c.s.client, req)
47450}
47451
47452// Do executes the "dfareporting.sites.list" call.
47453// Exactly one of *SitesListResponse or error will be non-nil. Any
47454// non-2xx status code is an error. Response headers are in either
47455// *SitesListResponse.ServerResponse.Header or (if a response was
47456// returned at all) in error.(*googleapi.Error).Header. Use
47457// googleapi.IsNotModified to check whether the returned error was
47458// because http.StatusNotModified was returned.
47459func (c *SitesListCall) Do(opts ...googleapi.CallOption) (*SitesListResponse, error) {
47460	gensupport.SetOptions(c.urlParams_, opts...)
47461	res, err := c.doRequest("json")
47462	if res != nil && res.StatusCode == http.StatusNotModified {
47463		if res.Body != nil {
47464			res.Body.Close()
47465		}
47466		return nil, &googleapi.Error{
47467			Code:   res.StatusCode,
47468			Header: res.Header,
47469		}
47470	}
47471	if err != nil {
47472		return nil, err
47473	}
47474	defer googleapi.CloseBody(res)
47475	if err := googleapi.CheckResponse(res); err != nil {
47476		return nil, err
47477	}
47478	ret := &SitesListResponse{
47479		ServerResponse: googleapi.ServerResponse{
47480			Header:         res.Header,
47481			HTTPStatusCode: res.StatusCode,
47482		},
47483	}
47484	target := &ret
47485	if err := gensupport.DecodeResponse(target, res); err != nil {
47486		return nil, err
47487	}
47488	return ret, nil
47489	// {
47490	//   "description": "Retrieves a list of sites, possibly filtered. This method supports paging.",
47491	//   "flatPath": "userprofiles/{profileId}/sites",
47492	//   "httpMethod": "GET",
47493	//   "id": "dfareporting.sites.list",
47494	//   "parameterOrder": [
47495	//     "profileId"
47496	//   ],
47497	//   "parameters": {
47498	//     "acceptsInStreamVideoPlacements": {
47499	//       "description": "This search filter is no longer supported and will have no effect on the results returned.",
47500	//       "location": "query",
47501	//       "type": "boolean"
47502	//     },
47503	//     "acceptsInterstitialPlacements": {
47504	//       "description": "This search filter is no longer supported and will have no effect on the results returned.",
47505	//       "location": "query",
47506	//       "type": "boolean"
47507	//     },
47508	//     "acceptsPublisherPaidPlacements": {
47509	//       "description": "Select only sites that accept publisher paid placements.",
47510	//       "location": "query",
47511	//       "type": "boolean"
47512	//     },
47513	//     "adWordsSite": {
47514	//       "description": "Select only AdWords sites.",
47515	//       "location": "query",
47516	//       "type": "boolean"
47517	//     },
47518	//     "approved": {
47519	//       "description": "Select only approved sites.",
47520	//       "location": "query",
47521	//       "type": "boolean"
47522	//     },
47523	//     "campaignIds": {
47524	//       "description": "Select only sites with these campaign IDs.",
47525	//       "format": "int64",
47526	//       "location": "query",
47527	//       "repeated": true,
47528	//       "type": "string"
47529	//     },
47530	//     "directorySiteIds": {
47531	//       "description": "Select only sites with these directory site IDs.",
47532	//       "format": "int64",
47533	//       "location": "query",
47534	//       "repeated": true,
47535	//       "type": "string"
47536	//     },
47537	//     "ids": {
47538	//       "description": "Select only sites with these IDs.",
47539	//       "format": "int64",
47540	//       "location": "query",
47541	//       "repeated": true,
47542	//       "type": "string"
47543	//     },
47544	//     "maxResults": {
47545	//       "default": "1000",
47546	//       "description": "Maximum number of results to return.",
47547	//       "format": "int32",
47548	//       "location": "query",
47549	//       "maximum": "1000",
47550	//       "minimum": "0",
47551	//       "type": "integer"
47552	//     },
47553	//     "pageToken": {
47554	//       "description": "Value of the nextPageToken from the previous result page.",
47555	//       "location": "query",
47556	//       "type": "string"
47557	//     },
47558	//     "profileId": {
47559	//       "description": "User profile ID associated with this request.",
47560	//       "format": "int64",
47561	//       "location": "path",
47562	//       "required": true,
47563	//       "type": "string"
47564	//     },
47565	//     "searchString": {
47566	//       "description": "Allows searching for objects by name, ID or keyName. Wildcards (*) are allowed. For example, \"site*2015\" will return objects with names like \"site June 2015\", \"site April 2015\", or simply \"site 2015\". Most of the searches also add wildcards implicitly at the start and the end of the search string. For example, a search string of \"site\" will match objects with name \"my site\", \"site 2015\", or simply \"site\".",
47567	//       "location": "query",
47568	//       "type": "string"
47569	//     },
47570	//     "sortField": {
47571	//       "default": "ID",
47572	//       "description": "Field by which to sort the list.",
47573	//       "enum": [
47574	//         "ID",
47575	//         "NAME"
47576	//       ],
47577	//       "enumDescriptions": [
47578	//         "",
47579	//         ""
47580	//       ],
47581	//       "location": "query",
47582	//       "type": "string"
47583	//     },
47584	//     "sortOrder": {
47585	//       "default": "ASCENDING",
47586	//       "description": "Order of sorted results.",
47587	//       "enum": [
47588	//         "ASCENDING",
47589	//         "DESCENDING"
47590	//       ],
47591	//       "enumDescriptions": [
47592	//         "",
47593	//         ""
47594	//       ],
47595	//       "location": "query",
47596	//       "type": "string"
47597	//     },
47598	//     "subaccountId": {
47599	//       "description": "Select only sites with this subaccount ID.",
47600	//       "format": "int64",
47601	//       "location": "query",
47602	//       "type": "string"
47603	//     },
47604	//     "unmappedSite": {
47605	//       "description": "Select only sites that have not been mapped to a directory site.",
47606	//       "location": "query",
47607	//       "type": "boolean"
47608	//     }
47609	//   },
47610	//   "path": "userprofiles/{profileId}/sites",
47611	//   "response": {
47612	//     "$ref": "SitesListResponse"
47613	//   },
47614	//   "scopes": [
47615	//     "https://www.googleapis.com/auth/dfatrafficking"
47616	//   ]
47617	// }
47618
47619}
47620
47621// Pages invokes f for each page of results.
47622// A non-nil error returned from f will halt the iteration.
47623// The provided context supersedes any context provided to the Context method.
47624func (c *SitesListCall) Pages(ctx context.Context, f func(*SitesListResponse) error) error {
47625	c.ctx_ = ctx
47626	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
47627	for {
47628		x, err := c.Do()
47629		if err != nil {
47630			return err
47631		}
47632		if err := f(x); err != nil {
47633			return err
47634		}
47635		if x.NextPageToken == "" {
47636			return nil
47637		}
47638		c.PageToken(x.NextPageToken)
47639	}
47640}
47641
47642// method id "dfareporting.sites.patch":
47643
47644type SitesPatchCall struct {
47645	s          *Service
47646	profileId  int64
47647	site       *Site
47648	urlParams_ gensupport.URLParams
47649	ctx_       context.Context
47650	header_    http.Header
47651}
47652
47653// Patch: Updates an existing site. This method supports patch
47654// semantics.
47655//
47656// - id: Site ID.
47657// - profileId: User profile ID associated with this request.
47658func (r *SitesService) Patch(profileId int64, id int64, site *Site) *SitesPatchCall {
47659	c := &SitesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
47660	c.profileId = profileId
47661	c.urlParams_.Set("id", fmt.Sprint(id))
47662	c.site = site
47663	return c
47664}
47665
47666// Fields allows partial responses to be retrieved. See
47667// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
47668// for more information.
47669func (c *SitesPatchCall) Fields(s ...googleapi.Field) *SitesPatchCall {
47670	c.urlParams_.Set("fields", googleapi.CombineFields(s))
47671	return c
47672}
47673
47674// Context sets the context to be used in this call's Do method. Any
47675// pending HTTP request will be aborted if the provided context is
47676// canceled.
47677func (c *SitesPatchCall) Context(ctx context.Context) *SitesPatchCall {
47678	c.ctx_ = ctx
47679	return c
47680}
47681
47682// Header returns an http.Header that can be modified by the caller to
47683// add HTTP headers to the request.
47684func (c *SitesPatchCall) Header() http.Header {
47685	if c.header_ == nil {
47686		c.header_ = make(http.Header)
47687	}
47688	return c.header_
47689}
47690
47691func (c *SitesPatchCall) doRequest(alt string) (*http.Response, error) {
47692	reqHeaders := make(http.Header)
47693	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
47694	for k, v := range c.header_ {
47695		reqHeaders[k] = v
47696	}
47697	reqHeaders.Set("User-Agent", c.s.userAgent())
47698	var body io.Reader = nil
47699	body, err := googleapi.WithoutDataWrapper.JSONReader(c.site)
47700	if err != nil {
47701		return nil, err
47702	}
47703	reqHeaders.Set("Content-Type", "application/json")
47704	c.urlParams_.Set("alt", alt)
47705	c.urlParams_.Set("prettyPrint", "false")
47706	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/sites")
47707	urls += "?" + c.urlParams_.Encode()
47708	req, err := http.NewRequest("PATCH", urls, body)
47709	if err != nil {
47710		return nil, err
47711	}
47712	req.Header = reqHeaders
47713	googleapi.Expand(req.URL, map[string]string{
47714		"profileId": strconv.FormatInt(c.profileId, 10),
47715	})
47716	return gensupport.SendRequest(c.ctx_, c.s.client, req)
47717}
47718
47719// Do executes the "dfareporting.sites.patch" call.
47720// Exactly one of *Site or error will be non-nil. Any non-2xx status
47721// code is an error. Response headers are in either
47722// *Site.ServerResponse.Header or (if a response was returned at all) in
47723// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
47724// whether the returned error was because http.StatusNotModified was
47725// returned.
47726func (c *SitesPatchCall) Do(opts ...googleapi.CallOption) (*Site, error) {
47727	gensupport.SetOptions(c.urlParams_, opts...)
47728	res, err := c.doRequest("json")
47729	if res != nil && res.StatusCode == http.StatusNotModified {
47730		if res.Body != nil {
47731			res.Body.Close()
47732		}
47733		return nil, &googleapi.Error{
47734			Code:   res.StatusCode,
47735			Header: res.Header,
47736		}
47737	}
47738	if err != nil {
47739		return nil, err
47740	}
47741	defer googleapi.CloseBody(res)
47742	if err := googleapi.CheckResponse(res); err != nil {
47743		return nil, err
47744	}
47745	ret := &Site{
47746		ServerResponse: googleapi.ServerResponse{
47747			Header:         res.Header,
47748			HTTPStatusCode: res.StatusCode,
47749		},
47750	}
47751	target := &ret
47752	if err := gensupport.DecodeResponse(target, res); err != nil {
47753		return nil, err
47754	}
47755	return ret, nil
47756	// {
47757	//   "description": "Updates an existing site. This method supports patch semantics.",
47758	//   "flatPath": "userprofiles/{profileId}/sites",
47759	//   "httpMethod": "PATCH",
47760	//   "id": "dfareporting.sites.patch",
47761	//   "parameterOrder": [
47762	//     "profileId",
47763	//     "id"
47764	//   ],
47765	//   "parameters": {
47766	//     "id": {
47767	//       "description": "Site ID.",
47768	//       "format": "int64",
47769	//       "location": "query",
47770	//       "required": true,
47771	//       "type": "string"
47772	//     },
47773	//     "profileId": {
47774	//       "description": "User profile ID associated with this request.",
47775	//       "format": "int64",
47776	//       "location": "path",
47777	//       "required": true,
47778	//       "type": "string"
47779	//     }
47780	//   },
47781	//   "path": "userprofiles/{profileId}/sites",
47782	//   "request": {
47783	//     "$ref": "Site"
47784	//   },
47785	//   "response": {
47786	//     "$ref": "Site"
47787	//   },
47788	//   "scopes": [
47789	//     "https://www.googleapis.com/auth/dfatrafficking"
47790	//   ]
47791	// }
47792
47793}
47794
47795// method id "dfareporting.sites.update":
47796
47797type SitesUpdateCall struct {
47798	s          *Service
47799	profileId  int64
47800	site       *Site
47801	urlParams_ gensupport.URLParams
47802	ctx_       context.Context
47803	header_    http.Header
47804}
47805
47806// Update: Updates an existing site.
47807//
47808// - profileId: User profile ID associated with this request.
47809func (r *SitesService) Update(profileId int64, site *Site) *SitesUpdateCall {
47810	c := &SitesUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
47811	c.profileId = profileId
47812	c.site = site
47813	return c
47814}
47815
47816// Fields allows partial responses to be retrieved. See
47817// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
47818// for more information.
47819func (c *SitesUpdateCall) Fields(s ...googleapi.Field) *SitesUpdateCall {
47820	c.urlParams_.Set("fields", googleapi.CombineFields(s))
47821	return c
47822}
47823
47824// Context sets the context to be used in this call's Do method. Any
47825// pending HTTP request will be aborted if the provided context is
47826// canceled.
47827func (c *SitesUpdateCall) Context(ctx context.Context) *SitesUpdateCall {
47828	c.ctx_ = ctx
47829	return c
47830}
47831
47832// Header returns an http.Header that can be modified by the caller to
47833// add HTTP headers to the request.
47834func (c *SitesUpdateCall) Header() http.Header {
47835	if c.header_ == nil {
47836		c.header_ = make(http.Header)
47837	}
47838	return c.header_
47839}
47840
47841func (c *SitesUpdateCall) doRequest(alt string) (*http.Response, error) {
47842	reqHeaders := make(http.Header)
47843	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
47844	for k, v := range c.header_ {
47845		reqHeaders[k] = v
47846	}
47847	reqHeaders.Set("User-Agent", c.s.userAgent())
47848	var body io.Reader = nil
47849	body, err := googleapi.WithoutDataWrapper.JSONReader(c.site)
47850	if err != nil {
47851		return nil, err
47852	}
47853	reqHeaders.Set("Content-Type", "application/json")
47854	c.urlParams_.Set("alt", alt)
47855	c.urlParams_.Set("prettyPrint", "false")
47856	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/sites")
47857	urls += "?" + c.urlParams_.Encode()
47858	req, err := http.NewRequest("PUT", urls, body)
47859	if err != nil {
47860		return nil, err
47861	}
47862	req.Header = reqHeaders
47863	googleapi.Expand(req.URL, map[string]string{
47864		"profileId": strconv.FormatInt(c.profileId, 10),
47865	})
47866	return gensupport.SendRequest(c.ctx_, c.s.client, req)
47867}
47868
47869// Do executes the "dfareporting.sites.update" call.
47870// Exactly one of *Site or error will be non-nil. Any non-2xx status
47871// code is an error. Response headers are in either
47872// *Site.ServerResponse.Header or (if a response was returned at all) in
47873// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
47874// whether the returned error was because http.StatusNotModified was
47875// returned.
47876func (c *SitesUpdateCall) Do(opts ...googleapi.CallOption) (*Site, error) {
47877	gensupport.SetOptions(c.urlParams_, opts...)
47878	res, err := c.doRequest("json")
47879	if res != nil && res.StatusCode == http.StatusNotModified {
47880		if res.Body != nil {
47881			res.Body.Close()
47882		}
47883		return nil, &googleapi.Error{
47884			Code:   res.StatusCode,
47885			Header: res.Header,
47886		}
47887	}
47888	if err != nil {
47889		return nil, err
47890	}
47891	defer googleapi.CloseBody(res)
47892	if err := googleapi.CheckResponse(res); err != nil {
47893		return nil, err
47894	}
47895	ret := &Site{
47896		ServerResponse: googleapi.ServerResponse{
47897			Header:         res.Header,
47898			HTTPStatusCode: res.StatusCode,
47899		},
47900	}
47901	target := &ret
47902	if err := gensupport.DecodeResponse(target, res); err != nil {
47903		return nil, err
47904	}
47905	return ret, nil
47906	// {
47907	//   "description": "Updates an existing site.",
47908	//   "flatPath": "userprofiles/{profileId}/sites",
47909	//   "httpMethod": "PUT",
47910	//   "id": "dfareporting.sites.update",
47911	//   "parameterOrder": [
47912	//     "profileId"
47913	//   ],
47914	//   "parameters": {
47915	//     "profileId": {
47916	//       "description": "User profile ID associated with this request.",
47917	//       "format": "int64",
47918	//       "location": "path",
47919	//       "required": true,
47920	//       "type": "string"
47921	//     }
47922	//   },
47923	//   "path": "userprofiles/{profileId}/sites",
47924	//   "request": {
47925	//     "$ref": "Site"
47926	//   },
47927	//   "response": {
47928	//     "$ref": "Site"
47929	//   },
47930	//   "scopes": [
47931	//     "https://www.googleapis.com/auth/dfatrafficking"
47932	//   ]
47933	// }
47934
47935}
47936
47937// method id "dfareporting.sizes.get":
47938
47939type SizesGetCall struct {
47940	s            *Service
47941	profileId    int64
47942	id           int64
47943	urlParams_   gensupport.URLParams
47944	ifNoneMatch_ string
47945	ctx_         context.Context
47946	header_      http.Header
47947}
47948
47949// Get: Gets one size by ID.
47950//
47951// - id: Size ID.
47952// - profileId: User profile ID associated with this request.
47953func (r *SizesService) Get(profileId int64, id int64) *SizesGetCall {
47954	c := &SizesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
47955	c.profileId = profileId
47956	c.id = id
47957	return c
47958}
47959
47960// Fields allows partial responses to be retrieved. See
47961// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
47962// for more information.
47963func (c *SizesGetCall) Fields(s ...googleapi.Field) *SizesGetCall {
47964	c.urlParams_.Set("fields", googleapi.CombineFields(s))
47965	return c
47966}
47967
47968// IfNoneMatch sets the optional parameter which makes the operation
47969// fail if the object's ETag matches the given value. This is useful for
47970// getting updates only after the object has changed since the last
47971// request. Use googleapi.IsNotModified to check whether the response
47972// error from Do is the result of In-None-Match.
47973func (c *SizesGetCall) IfNoneMatch(entityTag string) *SizesGetCall {
47974	c.ifNoneMatch_ = entityTag
47975	return c
47976}
47977
47978// Context sets the context to be used in this call's Do method. Any
47979// pending HTTP request will be aborted if the provided context is
47980// canceled.
47981func (c *SizesGetCall) Context(ctx context.Context) *SizesGetCall {
47982	c.ctx_ = ctx
47983	return c
47984}
47985
47986// Header returns an http.Header that can be modified by the caller to
47987// add HTTP headers to the request.
47988func (c *SizesGetCall) Header() http.Header {
47989	if c.header_ == nil {
47990		c.header_ = make(http.Header)
47991	}
47992	return c.header_
47993}
47994
47995func (c *SizesGetCall) doRequest(alt string) (*http.Response, error) {
47996	reqHeaders := make(http.Header)
47997	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
47998	for k, v := range c.header_ {
47999		reqHeaders[k] = v
48000	}
48001	reqHeaders.Set("User-Agent", c.s.userAgent())
48002	if c.ifNoneMatch_ != "" {
48003		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
48004	}
48005	var body io.Reader = nil
48006	c.urlParams_.Set("alt", alt)
48007	c.urlParams_.Set("prettyPrint", "false")
48008	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/sizes/{id}")
48009	urls += "?" + c.urlParams_.Encode()
48010	req, err := http.NewRequest("GET", urls, body)
48011	if err != nil {
48012		return nil, err
48013	}
48014	req.Header = reqHeaders
48015	googleapi.Expand(req.URL, map[string]string{
48016		"profileId": strconv.FormatInt(c.profileId, 10),
48017		"id":        strconv.FormatInt(c.id, 10),
48018	})
48019	return gensupport.SendRequest(c.ctx_, c.s.client, req)
48020}
48021
48022// Do executes the "dfareporting.sizes.get" call.
48023// Exactly one of *Size or error will be non-nil. Any non-2xx status
48024// code is an error. Response headers are in either
48025// *Size.ServerResponse.Header or (if a response was returned at all) in
48026// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
48027// whether the returned error was because http.StatusNotModified was
48028// returned.
48029func (c *SizesGetCall) Do(opts ...googleapi.CallOption) (*Size, error) {
48030	gensupport.SetOptions(c.urlParams_, opts...)
48031	res, err := c.doRequest("json")
48032	if res != nil && res.StatusCode == http.StatusNotModified {
48033		if res.Body != nil {
48034			res.Body.Close()
48035		}
48036		return nil, &googleapi.Error{
48037			Code:   res.StatusCode,
48038			Header: res.Header,
48039		}
48040	}
48041	if err != nil {
48042		return nil, err
48043	}
48044	defer googleapi.CloseBody(res)
48045	if err := googleapi.CheckResponse(res); err != nil {
48046		return nil, err
48047	}
48048	ret := &Size{
48049		ServerResponse: googleapi.ServerResponse{
48050			Header:         res.Header,
48051			HTTPStatusCode: res.StatusCode,
48052		},
48053	}
48054	target := &ret
48055	if err := gensupport.DecodeResponse(target, res); err != nil {
48056		return nil, err
48057	}
48058	return ret, nil
48059	// {
48060	//   "description": "Gets one size by ID.",
48061	//   "flatPath": "userprofiles/{profileId}/sizes/{id}",
48062	//   "httpMethod": "GET",
48063	//   "id": "dfareporting.sizes.get",
48064	//   "parameterOrder": [
48065	//     "profileId",
48066	//     "id"
48067	//   ],
48068	//   "parameters": {
48069	//     "id": {
48070	//       "description": "Size ID.",
48071	//       "format": "int64",
48072	//       "location": "path",
48073	//       "required": true,
48074	//       "type": "string"
48075	//     },
48076	//     "profileId": {
48077	//       "description": "User profile ID associated with this request.",
48078	//       "format": "int64",
48079	//       "location": "path",
48080	//       "required": true,
48081	//       "type": "string"
48082	//     }
48083	//   },
48084	//   "path": "userprofiles/{profileId}/sizes/{id}",
48085	//   "response": {
48086	//     "$ref": "Size"
48087	//   },
48088	//   "scopes": [
48089	//     "https://www.googleapis.com/auth/dfatrafficking"
48090	//   ]
48091	// }
48092
48093}
48094
48095// method id "dfareporting.sizes.insert":
48096
48097type SizesInsertCall struct {
48098	s          *Service
48099	profileId  int64
48100	size       *Size
48101	urlParams_ gensupport.URLParams
48102	ctx_       context.Context
48103	header_    http.Header
48104}
48105
48106// Insert: Inserts a new size.
48107//
48108// - profileId: User profile ID associated with this request.
48109func (r *SizesService) Insert(profileId int64, size *Size) *SizesInsertCall {
48110	c := &SizesInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
48111	c.profileId = profileId
48112	c.size = size
48113	return c
48114}
48115
48116// Fields allows partial responses to be retrieved. See
48117// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
48118// for more information.
48119func (c *SizesInsertCall) Fields(s ...googleapi.Field) *SizesInsertCall {
48120	c.urlParams_.Set("fields", googleapi.CombineFields(s))
48121	return c
48122}
48123
48124// Context sets the context to be used in this call's Do method. Any
48125// pending HTTP request will be aborted if the provided context is
48126// canceled.
48127func (c *SizesInsertCall) Context(ctx context.Context) *SizesInsertCall {
48128	c.ctx_ = ctx
48129	return c
48130}
48131
48132// Header returns an http.Header that can be modified by the caller to
48133// add HTTP headers to the request.
48134func (c *SizesInsertCall) Header() http.Header {
48135	if c.header_ == nil {
48136		c.header_ = make(http.Header)
48137	}
48138	return c.header_
48139}
48140
48141func (c *SizesInsertCall) doRequest(alt string) (*http.Response, error) {
48142	reqHeaders := make(http.Header)
48143	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
48144	for k, v := range c.header_ {
48145		reqHeaders[k] = v
48146	}
48147	reqHeaders.Set("User-Agent", c.s.userAgent())
48148	var body io.Reader = nil
48149	body, err := googleapi.WithoutDataWrapper.JSONReader(c.size)
48150	if err != nil {
48151		return nil, err
48152	}
48153	reqHeaders.Set("Content-Type", "application/json")
48154	c.urlParams_.Set("alt", alt)
48155	c.urlParams_.Set("prettyPrint", "false")
48156	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/sizes")
48157	urls += "?" + c.urlParams_.Encode()
48158	req, err := http.NewRequest("POST", urls, body)
48159	if err != nil {
48160		return nil, err
48161	}
48162	req.Header = reqHeaders
48163	googleapi.Expand(req.URL, map[string]string{
48164		"profileId": strconv.FormatInt(c.profileId, 10),
48165	})
48166	return gensupport.SendRequest(c.ctx_, c.s.client, req)
48167}
48168
48169// Do executes the "dfareporting.sizes.insert" call.
48170// Exactly one of *Size or error will be non-nil. Any non-2xx status
48171// code is an error. Response headers are in either
48172// *Size.ServerResponse.Header or (if a response was returned at all) in
48173// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
48174// whether the returned error was because http.StatusNotModified was
48175// returned.
48176func (c *SizesInsertCall) Do(opts ...googleapi.CallOption) (*Size, error) {
48177	gensupport.SetOptions(c.urlParams_, opts...)
48178	res, err := c.doRequest("json")
48179	if res != nil && res.StatusCode == http.StatusNotModified {
48180		if res.Body != nil {
48181			res.Body.Close()
48182		}
48183		return nil, &googleapi.Error{
48184			Code:   res.StatusCode,
48185			Header: res.Header,
48186		}
48187	}
48188	if err != nil {
48189		return nil, err
48190	}
48191	defer googleapi.CloseBody(res)
48192	if err := googleapi.CheckResponse(res); err != nil {
48193		return nil, err
48194	}
48195	ret := &Size{
48196		ServerResponse: googleapi.ServerResponse{
48197			Header:         res.Header,
48198			HTTPStatusCode: res.StatusCode,
48199		},
48200	}
48201	target := &ret
48202	if err := gensupport.DecodeResponse(target, res); err != nil {
48203		return nil, err
48204	}
48205	return ret, nil
48206	// {
48207	//   "description": "Inserts a new size.",
48208	//   "flatPath": "userprofiles/{profileId}/sizes",
48209	//   "httpMethod": "POST",
48210	//   "id": "dfareporting.sizes.insert",
48211	//   "parameterOrder": [
48212	//     "profileId"
48213	//   ],
48214	//   "parameters": {
48215	//     "profileId": {
48216	//       "description": "User profile ID associated with this request.",
48217	//       "format": "int64",
48218	//       "location": "path",
48219	//       "required": true,
48220	//       "type": "string"
48221	//     }
48222	//   },
48223	//   "path": "userprofiles/{profileId}/sizes",
48224	//   "request": {
48225	//     "$ref": "Size"
48226	//   },
48227	//   "response": {
48228	//     "$ref": "Size"
48229	//   },
48230	//   "scopes": [
48231	//     "https://www.googleapis.com/auth/dfatrafficking"
48232	//   ]
48233	// }
48234
48235}
48236
48237// method id "dfareporting.sizes.list":
48238
48239type SizesListCall struct {
48240	s            *Service
48241	profileId    int64
48242	urlParams_   gensupport.URLParams
48243	ifNoneMatch_ string
48244	ctx_         context.Context
48245	header_      http.Header
48246}
48247
48248// List: Retrieves a list of sizes, possibly filtered. Retrieved sizes
48249// are globally unique and may include values not currently in use by
48250// your account. Due to this, the list of sizes returned by this method
48251// may differ from the list seen in the Trafficking UI.
48252//
48253// - profileId: User profile ID associated with this request.
48254func (r *SizesService) List(profileId int64) *SizesListCall {
48255	c := &SizesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
48256	c.profileId = profileId
48257	return c
48258}
48259
48260// Height sets the optional parameter "height": Select only sizes with
48261// this height.
48262func (c *SizesListCall) Height(height int64) *SizesListCall {
48263	c.urlParams_.Set("height", fmt.Sprint(height))
48264	return c
48265}
48266
48267// IabStandard sets the optional parameter "iabStandard": Select only
48268// IAB standard sizes.
48269func (c *SizesListCall) IabStandard(iabStandard bool) *SizesListCall {
48270	c.urlParams_.Set("iabStandard", fmt.Sprint(iabStandard))
48271	return c
48272}
48273
48274// Ids sets the optional parameter "ids": Select only sizes with these
48275// IDs.
48276func (c *SizesListCall) Ids(ids ...int64) *SizesListCall {
48277	var ids_ []string
48278	for _, v := range ids {
48279		ids_ = append(ids_, fmt.Sprint(v))
48280	}
48281	c.urlParams_.SetMulti("ids", ids_)
48282	return c
48283}
48284
48285// Width sets the optional parameter "width": Select only sizes with
48286// this width.
48287func (c *SizesListCall) Width(width int64) *SizesListCall {
48288	c.urlParams_.Set("width", fmt.Sprint(width))
48289	return c
48290}
48291
48292// Fields allows partial responses to be retrieved. See
48293// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
48294// for more information.
48295func (c *SizesListCall) Fields(s ...googleapi.Field) *SizesListCall {
48296	c.urlParams_.Set("fields", googleapi.CombineFields(s))
48297	return c
48298}
48299
48300// IfNoneMatch sets the optional parameter which makes the operation
48301// fail if the object's ETag matches the given value. This is useful for
48302// getting updates only after the object has changed since the last
48303// request. Use googleapi.IsNotModified to check whether the response
48304// error from Do is the result of In-None-Match.
48305func (c *SizesListCall) IfNoneMatch(entityTag string) *SizesListCall {
48306	c.ifNoneMatch_ = entityTag
48307	return c
48308}
48309
48310// Context sets the context to be used in this call's Do method. Any
48311// pending HTTP request will be aborted if the provided context is
48312// canceled.
48313func (c *SizesListCall) Context(ctx context.Context) *SizesListCall {
48314	c.ctx_ = ctx
48315	return c
48316}
48317
48318// Header returns an http.Header that can be modified by the caller to
48319// add HTTP headers to the request.
48320func (c *SizesListCall) Header() http.Header {
48321	if c.header_ == nil {
48322		c.header_ = make(http.Header)
48323	}
48324	return c.header_
48325}
48326
48327func (c *SizesListCall) doRequest(alt string) (*http.Response, error) {
48328	reqHeaders := make(http.Header)
48329	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
48330	for k, v := range c.header_ {
48331		reqHeaders[k] = v
48332	}
48333	reqHeaders.Set("User-Agent", c.s.userAgent())
48334	if c.ifNoneMatch_ != "" {
48335		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
48336	}
48337	var body io.Reader = nil
48338	c.urlParams_.Set("alt", alt)
48339	c.urlParams_.Set("prettyPrint", "false")
48340	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/sizes")
48341	urls += "?" + c.urlParams_.Encode()
48342	req, err := http.NewRequest("GET", urls, body)
48343	if err != nil {
48344		return nil, err
48345	}
48346	req.Header = reqHeaders
48347	googleapi.Expand(req.URL, map[string]string{
48348		"profileId": strconv.FormatInt(c.profileId, 10),
48349	})
48350	return gensupport.SendRequest(c.ctx_, c.s.client, req)
48351}
48352
48353// Do executes the "dfareporting.sizes.list" call.
48354// Exactly one of *SizesListResponse or error will be non-nil. Any
48355// non-2xx status code is an error. Response headers are in either
48356// *SizesListResponse.ServerResponse.Header or (if a response was
48357// returned at all) in error.(*googleapi.Error).Header. Use
48358// googleapi.IsNotModified to check whether the returned error was
48359// because http.StatusNotModified was returned.
48360func (c *SizesListCall) Do(opts ...googleapi.CallOption) (*SizesListResponse, error) {
48361	gensupport.SetOptions(c.urlParams_, opts...)
48362	res, err := c.doRequest("json")
48363	if res != nil && res.StatusCode == http.StatusNotModified {
48364		if res.Body != nil {
48365			res.Body.Close()
48366		}
48367		return nil, &googleapi.Error{
48368			Code:   res.StatusCode,
48369			Header: res.Header,
48370		}
48371	}
48372	if err != nil {
48373		return nil, err
48374	}
48375	defer googleapi.CloseBody(res)
48376	if err := googleapi.CheckResponse(res); err != nil {
48377		return nil, err
48378	}
48379	ret := &SizesListResponse{
48380		ServerResponse: googleapi.ServerResponse{
48381			Header:         res.Header,
48382			HTTPStatusCode: res.StatusCode,
48383		},
48384	}
48385	target := &ret
48386	if err := gensupport.DecodeResponse(target, res); err != nil {
48387		return nil, err
48388	}
48389	return ret, nil
48390	// {
48391	//   "description": "Retrieves a list of sizes, possibly filtered. Retrieved sizes are globally unique and may include values not currently in use by your account. Due to this, the list of sizes returned by this method may differ from the list seen in the Trafficking UI.",
48392	//   "flatPath": "userprofiles/{profileId}/sizes",
48393	//   "httpMethod": "GET",
48394	//   "id": "dfareporting.sizes.list",
48395	//   "parameterOrder": [
48396	//     "profileId"
48397	//   ],
48398	//   "parameters": {
48399	//     "height": {
48400	//       "description": "Select only sizes with this height.",
48401	//       "format": "int32",
48402	//       "location": "query",
48403	//       "maximum": "32767",
48404	//       "minimum": "0",
48405	//       "type": "integer"
48406	//     },
48407	//     "iabStandard": {
48408	//       "description": "Select only IAB standard sizes.",
48409	//       "location": "query",
48410	//       "type": "boolean"
48411	//     },
48412	//     "ids": {
48413	//       "description": "Select only sizes with these IDs.",
48414	//       "format": "int64",
48415	//       "location": "query",
48416	//       "repeated": true,
48417	//       "type": "string"
48418	//     },
48419	//     "profileId": {
48420	//       "description": "User profile ID associated with this request.",
48421	//       "format": "int64",
48422	//       "location": "path",
48423	//       "required": true,
48424	//       "type": "string"
48425	//     },
48426	//     "width": {
48427	//       "description": "Select only sizes with this width.",
48428	//       "format": "int32",
48429	//       "location": "query",
48430	//       "maximum": "32767",
48431	//       "minimum": "0",
48432	//       "type": "integer"
48433	//     }
48434	//   },
48435	//   "path": "userprofiles/{profileId}/sizes",
48436	//   "response": {
48437	//     "$ref": "SizesListResponse"
48438	//   },
48439	//   "scopes": [
48440	//     "https://www.googleapis.com/auth/dfatrafficking"
48441	//   ]
48442	// }
48443
48444}
48445
48446// method id "dfareporting.subaccounts.get":
48447
48448type SubaccountsGetCall struct {
48449	s            *Service
48450	profileId    int64
48451	id           int64
48452	urlParams_   gensupport.URLParams
48453	ifNoneMatch_ string
48454	ctx_         context.Context
48455	header_      http.Header
48456}
48457
48458// Get: Gets one subaccount by ID.
48459//
48460// - id: Subaccount ID.
48461// - profileId: User profile ID associated with this request.
48462func (r *SubaccountsService) Get(profileId int64, id int64) *SubaccountsGetCall {
48463	c := &SubaccountsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
48464	c.profileId = profileId
48465	c.id = id
48466	return c
48467}
48468
48469// Fields allows partial responses to be retrieved. See
48470// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
48471// for more information.
48472func (c *SubaccountsGetCall) Fields(s ...googleapi.Field) *SubaccountsGetCall {
48473	c.urlParams_.Set("fields", googleapi.CombineFields(s))
48474	return c
48475}
48476
48477// IfNoneMatch sets the optional parameter which makes the operation
48478// fail if the object's ETag matches the given value. This is useful for
48479// getting updates only after the object has changed since the last
48480// request. Use googleapi.IsNotModified to check whether the response
48481// error from Do is the result of In-None-Match.
48482func (c *SubaccountsGetCall) IfNoneMatch(entityTag string) *SubaccountsGetCall {
48483	c.ifNoneMatch_ = entityTag
48484	return c
48485}
48486
48487// Context sets the context to be used in this call's Do method. Any
48488// pending HTTP request will be aborted if the provided context is
48489// canceled.
48490func (c *SubaccountsGetCall) Context(ctx context.Context) *SubaccountsGetCall {
48491	c.ctx_ = ctx
48492	return c
48493}
48494
48495// Header returns an http.Header that can be modified by the caller to
48496// add HTTP headers to the request.
48497func (c *SubaccountsGetCall) Header() http.Header {
48498	if c.header_ == nil {
48499		c.header_ = make(http.Header)
48500	}
48501	return c.header_
48502}
48503
48504func (c *SubaccountsGetCall) doRequest(alt string) (*http.Response, error) {
48505	reqHeaders := make(http.Header)
48506	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
48507	for k, v := range c.header_ {
48508		reqHeaders[k] = v
48509	}
48510	reqHeaders.Set("User-Agent", c.s.userAgent())
48511	if c.ifNoneMatch_ != "" {
48512		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
48513	}
48514	var body io.Reader = nil
48515	c.urlParams_.Set("alt", alt)
48516	c.urlParams_.Set("prettyPrint", "false")
48517	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/subaccounts/{id}")
48518	urls += "?" + c.urlParams_.Encode()
48519	req, err := http.NewRequest("GET", urls, body)
48520	if err != nil {
48521		return nil, err
48522	}
48523	req.Header = reqHeaders
48524	googleapi.Expand(req.URL, map[string]string{
48525		"profileId": strconv.FormatInt(c.profileId, 10),
48526		"id":        strconv.FormatInt(c.id, 10),
48527	})
48528	return gensupport.SendRequest(c.ctx_, c.s.client, req)
48529}
48530
48531// Do executes the "dfareporting.subaccounts.get" call.
48532// Exactly one of *Subaccount or error will be non-nil. Any non-2xx
48533// status code is an error. Response headers are in either
48534// *Subaccount.ServerResponse.Header or (if a response was returned at
48535// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
48536// to check whether the returned error was because
48537// http.StatusNotModified was returned.
48538func (c *SubaccountsGetCall) Do(opts ...googleapi.CallOption) (*Subaccount, error) {
48539	gensupport.SetOptions(c.urlParams_, opts...)
48540	res, err := c.doRequest("json")
48541	if res != nil && res.StatusCode == http.StatusNotModified {
48542		if res.Body != nil {
48543			res.Body.Close()
48544		}
48545		return nil, &googleapi.Error{
48546			Code:   res.StatusCode,
48547			Header: res.Header,
48548		}
48549	}
48550	if err != nil {
48551		return nil, err
48552	}
48553	defer googleapi.CloseBody(res)
48554	if err := googleapi.CheckResponse(res); err != nil {
48555		return nil, err
48556	}
48557	ret := &Subaccount{
48558		ServerResponse: googleapi.ServerResponse{
48559			Header:         res.Header,
48560			HTTPStatusCode: res.StatusCode,
48561		},
48562	}
48563	target := &ret
48564	if err := gensupport.DecodeResponse(target, res); err != nil {
48565		return nil, err
48566	}
48567	return ret, nil
48568	// {
48569	//   "description": "Gets one subaccount by ID.",
48570	//   "flatPath": "userprofiles/{profileId}/subaccounts/{id}",
48571	//   "httpMethod": "GET",
48572	//   "id": "dfareporting.subaccounts.get",
48573	//   "parameterOrder": [
48574	//     "profileId",
48575	//     "id"
48576	//   ],
48577	//   "parameters": {
48578	//     "id": {
48579	//       "description": "Subaccount ID.",
48580	//       "format": "int64",
48581	//       "location": "path",
48582	//       "required": true,
48583	//       "type": "string"
48584	//     },
48585	//     "profileId": {
48586	//       "description": "User profile ID associated with this request.",
48587	//       "format": "int64",
48588	//       "location": "path",
48589	//       "required": true,
48590	//       "type": "string"
48591	//     }
48592	//   },
48593	//   "path": "userprofiles/{profileId}/subaccounts/{id}",
48594	//   "response": {
48595	//     "$ref": "Subaccount"
48596	//   },
48597	//   "scopes": [
48598	//     "https://www.googleapis.com/auth/dfatrafficking"
48599	//   ]
48600	// }
48601
48602}
48603
48604// method id "dfareporting.subaccounts.insert":
48605
48606type SubaccountsInsertCall struct {
48607	s          *Service
48608	profileId  int64
48609	subaccount *Subaccount
48610	urlParams_ gensupport.URLParams
48611	ctx_       context.Context
48612	header_    http.Header
48613}
48614
48615// Insert: Inserts a new subaccount.
48616//
48617// - profileId: User profile ID associated with this request.
48618func (r *SubaccountsService) Insert(profileId int64, subaccount *Subaccount) *SubaccountsInsertCall {
48619	c := &SubaccountsInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
48620	c.profileId = profileId
48621	c.subaccount = subaccount
48622	return c
48623}
48624
48625// Fields allows partial responses to be retrieved. See
48626// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
48627// for more information.
48628func (c *SubaccountsInsertCall) Fields(s ...googleapi.Field) *SubaccountsInsertCall {
48629	c.urlParams_.Set("fields", googleapi.CombineFields(s))
48630	return c
48631}
48632
48633// Context sets the context to be used in this call's Do method. Any
48634// pending HTTP request will be aborted if the provided context is
48635// canceled.
48636func (c *SubaccountsInsertCall) Context(ctx context.Context) *SubaccountsInsertCall {
48637	c.ctx_ = ctx
48638	return c
48639}
48640
48641// Header returns an http.Header that can be modified by the caller to
48642// add HTTP headers to the request.
48643func (c *SubaccountsInsertCall) Header() http.Header {
48644	if c.header_ == nil {
48645		c.header_ = make(http.Header)
48646	}
48647	return c.header_
48648}
48649
48650func (c *SubaccountsInsertCall) doRequest(alt string) (*http.Response, error) {
48651	reqHeaders := make(http.Header)
48652	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
48653	for k, v := range c.header_ {
48654		reqHeaders[k] = v
48655	}
48656	reqHeaders.Set("User-Agent", c.s.userAgent())
48657	var body io.Reader = nil
48658	body, err := googleapi.WithoutDataWrapper.JSONReader(c.subaccount)
48659	if err != nil {
48660		return nil, err
48661	}
48662	reqHeaders.Set("Content-Type", "application/json")
48663	c.urlParams_.Set("alt", alt)
48664	c.urlParams_.Set("prettyPrint", "false")
48665	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/subaccounts")
48666	urls += "?" + c.urlParams_.Encode()
48667	req, err := http.NewRequest("POST", urls, body)
48668	if err != nil {
48669		return nil, err
48670	}
48671	req.Header = reqHeaders
48672	googleapi.Expand(req.URL, map[string]string{
48673		"profileId": strconv.FormatInt(c.profileId, 10),
48674	})
48675	return gensupport.SendRequest(c.ctx_, c.s.client, req)
48676}
48677
48678// Do executes the "dfareporting.subaccounts.insert" call.
48679// Exactly one of *Subaccount or error will be non-nil. Any non-2xx
48680// status code is an error. Response headers are in either
48681// *Subaccount.ServerResponse.Header or (if a response was returned at
48682// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
48683// to check whether the returned error was because
48684// http.StatusNotModified was returned.
48685func (c *SubaccountsInsertCall) Do(opts ...googleapi.CallOption) (*Subaccount, error) {
48686	gensupport.SetOptions(c.urlParams_, opts...)
48687	res, err := c.doRequest("json")
48688	if res != nil && res.StatusCode == http.StatusNotModified {
48689		if res.Body != nil {
48690			res.Body.Close()
48691		}
48692		return nil, &googleapi.Error{
48693			Code:   res.StatusCode,
48694			Header: res.Header,
48695		}
48696	}
48697	if err != nil {
48698		return nil, err
48699	}
48700	defer googleapi.CloseBody(res)
48701	if err := googleapi.CheckResponse(res); err != nil {
48702		return nil, err
48703	}
48704	ret := &Subaccount{
48705		ServerResponse: googleapi.ServerResponse{
48706			Header:         res.Header,
48707			HTTPStatusCode: res.StatusCode,
48708		},
48709	}
48710	target := &ret
48711	if err := gensupport.DecodeResponse(target, res); err != nil {
48712		return nil, err
48713	}
48714	return ret, nil
48715	// {
48716	//   "description": "Inserts a new subaccount.",
48717	//   "flatPath": "userprofiles/{profileId}/subaccounts",
48718	//   "httpMethod": "POST",
48719	//   "id": "dfareporting.subaccounts.insert",
48720	//   "parameterOrder": [
48721	//     "profileId"
48722	//   ],
48723	//   "parameters": {
48724	//     "profileId": {
48725	//       "description": "User profile ID associated with this request.",
48726	//       "format": "int64",
48727	//       "location": "path",
48728	//       "required": true,
48729	//       "type": "string"
48730	//     }
48731	//   },
48732	//   "path": "userprofiles/{profileId}/subaccounts",
48733	//   "request": {
48734	//     "$ref": "Subaccount"
48735	//   },
48736	//   "response": {
48737	//     "$ref": "Subaccount"
48738	//   },
48739	//   "scopes": [
48740	//     "https://www.googleapis.com/auth/dfatrafficking"
48741	//   ]
48742	// }
48743
48744}
48745
48746// method id "dfareporting.subaccounts.list":
48747
48748type SubaccountsListCall struct {
48749	s            *Service
48750	profileId    int64
48751	urlParams_   gensupport.URLParams
48752	ifNoneMatch_ string
48753	ctx_         context.Context
48754	header_      http.Header
48755}
48756
48757// List: Gets a list of subaccounts, possibly filtered. This method
48758// supports paging.
48759//
48760// - profileId: User profile ID associated with this request.
48761func (r *SubaccountsService) List(profileId int64) *SubaccountsListCall {
48762	c := &SubaccountsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
48763	c.profileId = profileId
48764	return c
48765}
48766
48767// Ids sets the optional parameter "ids": Select only subaccounts with
48768// these IDs.
48769func (c *SubaccountsListCall) Ids(ids ...int64) *SubaccountsListCall {
48770	var ids_ []string
48771	for _, v := range ids {
48772		ids_ = append(ids_, fmt.Sprint(v))
48773	}
48774	c.urlParams_.SetMulti("ids", ids_)
48775	return c
48776}
48777
48778// MaxResults sets the optional parameter "maxResults": Maximum number
48779// of results to return.
48780func (c *SubaccountsListCall) MaxResults(maxResults int64) *SubaccountsListCall {
48781	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
48782	return c
48783}
48784
48785// PageToken sets the optional parameter "pageToken": Value of the
48786// nextPageToken from the previous result page.
48787func (c *SubaccountsListCall) PageToken(pageToken string) *SubaccountsListCall {
48788	c.urlParams_.Set("pageToken", pageToken)
48789	return c
48790}
48791
48792// SearchString sets the optional parameter "searchString": Allows
48793// searching for objects by name or ID. Wildcards (*) are allowed. For
48794// example, "subaccount*2015" will return objects with names like
48795// "subaccount June 2015", "subaccount April 2015", or simply
48796// "subaccount 2015". Most of the searches also add wildcards implicitly
48797// at the start and the end of the search string. For example, a search
48798// string of "subaccount" will match objects with name "my subaccount",
48799// "subaccount 2015", or simply "subaccount" .
48800func (c *SubaccountsListCall) SearchString(searchString string) *SubaccountsListCall {
48801	c.urlParams_.Set("searchString", searchString)
48802	return c
48803}
48804
48805// SortField sets the optional parameter "sortField": Field by which to
48806// sort the list.
48807//
48808// Possible values:
48809//   "ID" (default)
48810//   "NAME"
48811func (c *SubaccountsListCall) SortField(sortField string) *SubaccountsListCall {
48812	c.urlParams_.Set("sortField", sortField)
48813	return c
48814}
48815
48816// SortOrder sets the optional parameter "sortOrder": Order of sorted
48817// results.
48818//
48819// Possible values:
48820//   "ASCENDING" (default)
48821//   "DESCENDING"
48822func (c *SubaccountsListCall) SortOrder(sortOrder string) *SubaccountsListCall {
48823	c.urlParams_.Set("sortOrder", sortOrder)
48824	return c
48825}
48826
48827// Fields allows partial responses to be retrieved. See
48828// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
48829// for more information.
48830func (c *SubaccountsListCall) Fields(s ...googleapi.Field) *SubaccountsListCall {
48831	c.urlParams_.Set("fields", googleapi.CombineFields(s))
48832	return c
48833}
48834
48835// IfNoneMatch sets the optional parameter which makes the operation
48836// fail if the object's ETag matches the given value. This is useful for
48837// getting updates only after the object has changed since the last
48838// request. Use googleapi.IsNotModified to check whether the response
48839// error from Do is the result of In-None-Match.
48840func (c *SubaccountsListCall) IfNoneMatch(entityTag string) *SubaccountsListCall {
48841	c.ifNoneMatch_ = entityTag
48842	return c
48843}
48844
48845// Context sets the context to be used in this call's Do method. Any
48846// pending HTTP request will be aborted if the provided context is
48847// canceled.
48848func (c *SubaccountsListCall) Context(ctx context.Context) *SubaccountsListCall {
48849	c.ctx_ = ctx
48850	return c
48851}
48852
48853// Header returns an http.Header that can be modified by the caller to
48854// add HTTP headers to the request.
48855func (c *SubaccountsListCall) Header() http.Header {
48856	if c.header_ == nil {
48857		c.header_ = make(http.Header)
48858	}
48859	return c.header_
48860}
48861
48862func (c *SubaccountsListCall) doRequest(alt string) (*http.Response, error) {
48863	reqHeaders := make(http.Header)
48864	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
48865	for k, v := range c.header_ {
48866		reqHeaders[k] = v
48867	}
48868	reqHeaders.Set("User-Agent", c.s.userAgent())
48869	if c.ifNoneMatch_ != "" {
48870		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
48871	}
48872	var body io.Reader = nil
48873	c.urlParams_.Set("alt", alt)
48874	c.urlParams_.Set("prettyPrint", "false")
48875	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/subaccounts")
48876	urls += "?" + c.urlParams_.Encode()
48877	req, err := http.NewRequest("GET", urls, body)
48878	if err != nil {
48879		return nil, err
48880	}
48881	req.Header = reqHeaders
48882	googleapi.Expand(req.URL, map[string]string{
48883		"profileId": strconv.FormatInt(c.profileId, 10),
48884	})
48885	return gensupport.SendRequest(c.ctx_, c.s.client, req)
48886}
48887
48888// Do executes the "dfareporting.subaccounts.list" call.
48889// Exactly one of *SubaccountsListResponse or error will be non-nil. Any
48890// non-2xx status code is an error. Response headers are in either
48891// *SubaccountsListResponse.ServerResponse.Header or (if a response was
48892// returned at all) in error.(*googleapi.Error).Header. Use
48893// googleapi.IsNotModified to check whether the returned error was
48894// because http.StatusNotModified was returned.
48895func (c *SubaccountsListCall) Do(opts ...googleapi.CallOption) (*SubaccountsListResponse, error) {
48896	gensupport.SetOptions(c.urlParams_, opts...)
48897	res, err := c.doRequest("json")
48898	if res != nil && res.StatusCode == http.StatusNotModified {
48899		if res.Body != nil {
48900			res.Body.Close()
48901		}
48902		return nil, &googleapi.Error{
48903			Code:   res.StatusCode,
48904			Header: res.Header,
48905		}
48906	}
48907	if err != nil {
48908		return nil, err
48909	}
48910	defer googleapi.CloseBody(res)
48911	if err := googleapi.CheckResponse(res); err != nil {
48912		return nil, err
48913	}
48914	ret := &SubaccountsListResponse{
48915		ServerResponse: googleapi.ServerResponse{
48916			Header:         res.Header,
48917			HTTPStatusCode: res.StatusCode,
48918		},
48919	}
48920	target := &ret
48921	if err := gensupport.DecodeResponse(target, res); err != nil {
48922		return nil, err
48923	}
48924	return ret, nil
48925	// {
48926	//   "description": "Gets a list of subaccounts, possibly filtered. This method supports paging.",
48927	//   "flatPath": "userprofiles/{profileId}/subaccounts",
48928	//   "httpMethod": "GET",
48929	//   "id": "dfareporting.subaccounts.list",
48930	//   "parameterOrder": [
48931	//     "profileId"
48932	//   ],
48933	//   "parameters": {
48934	//     "ids": {
48935	//       "description": "Select only subaccounts with these IDs.",
48936	//       "format": "int64",
48937	//       "location": "query",
48938	//       "repeated": true,
48939	//       "type": "string"
48940	//     },
48941	//     "maxResults": {
48942	//       "default": "1000",
48943	//       "description": "Maximum number of results to return.",
48944	//       "format": "int32",
48945	//       "location": "query",
48946	//       "maximum": "1000",
48947	//       "minimum": "0",
48948	//       "type": "integer"
48949	//     },
48950	//     "pageToken": {
48951	//       "description": "Value of the nextPageToken from the previous result page.",
48952	//       "location": "query",
48953	//       "type": "string"
48954	//     },
48955	//     "profileId": {
48956	//       "description": "User profile ID associated with this request.",
48957	//       "format": "int64",
48958	//       "location": "path",
48959	//       "required": true,
48960	//       "type": "string"
48961	//     },
48962	//     "searchString": {
48963	//       "description": "Allows searching for objects by name or ID. Wildcards (*) are allowed. For example, \"subaccount*2015\" will return objects with names like \"subaccount June 2015\", \"subaccount April 2015\", or simply \"subaccount 2015\". Most of the searches also add wildcards implicitly at the start and the end of the search string. For example, a search string of \"subaccount\" will match objects with name \"my subaccount\", \"subaccount 2015\", or simply \"subaccount\" .",
48964	//       "location": "query",
48965	//       "type": "string"
48966	//     },
48967	//     "sortField": {
48968	//       "default": "ID",
48969	//       "description": "Field by which to sort the list.",
48970	//       "enum": [
48971	//         "ID",
48972	//         "NAME"
48973	//       ],
48974	//       "enumDescriptions": [
48975	//         "",
48976	//         ""
48977	//       ],
48978	//       "location": "query",
48979	//       "type": "string"
48980	//     },
48981	//     "sortOrder": {
48982	//       "default": "ASCENDING",
48983	//       "description": "Order of sorted results.",
48984	//       "enum": [
48985	//         "ASCENDING",
48986	//         "DESCENDING"
48987	//       ],
48988	//       "enumDescriptions": [
48989	//         "",
48990	//         ""
48991	//       ],
48992	//       "location": "query",
48993	//       "type": "string"
48994	//     }
48995	//   },
48996	//   "path": "userprofiles/{profileId}/subaccounts",
48997	//   "response": {
48998	//     "$ref": "SubaccountsListResponse"
48999	//   },
49000	//   "scopes": [
49001	//     "https://www.googleapis.com/auth/dfatrafficking"
49002	//   ]
49003	// }
49004
49005}
49006
49007// Pages invokes f for each page of results.
49008// A non-nil error returned from f will halt the iteration.
49009// The provided context supersedes any context provided to the Context method.
49010func (c *SubaccountsListCall) Pages(ctx context.Context, f func(*SubaccountsListResponse) error) error {
49011	c.ctx_ = ctx
49012	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
49013	for {
49014		x, err := c.Do()
49015		if err != nil {
49016			return err
49017		}
49018		if err := f(x); err != nil {
49019			return err
49020		}
49021		if x.NextPageToken == "" {
49022			return nil
49023		}
49024		c.PageToken(x.NextPageToken)
49025	}
49026}
49027
49028// method id "dfareporting.subaccounts.patch":
49029
49030type SubaccountsPatchCall struct {
49031	s          *Service
49032	profileId  int64
49033	subaccount *Subaccount
49034	urlParams_ gensupport.URLParams
49035	ctx_       context.Context
49036	header_    http.Header
49037}
49038
49039// Patch: Updates an existing subaccount. This method supports patch
49040// semantics.
49041//
49042// - id: Subaccount ID.
49043// - profileId: User profile ID associated with this request.
49044func (r *SubaccountsService) Patch(profileId int64, id int64, subaccount *Subaccount) *SubaccountsPatchCall {
49045	c := &SubaccountsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
49046	c.profileId = profileId
49047	c.urlParams_.Set("id", fmt.Sprint(id))
49048	c.subaccount = subaccount
49049	return c
49050}
49051
49052// Fields allows partial responses to be retrieved. See
49053// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
49054// for more information.
49055func (c *SubaccountsPatchCall) Fields(s ...googleapi.Field) *SubaccountsPatchCall {
49056	c.urlParams_.Set("fields", googleapi.CombineFields(s))
49057	return c
49058}
49059
49060// Context sets the context to be used in this call's Do method. Any
49061// pending HTTP request will be aborted if the provided context is
49062// canceled.
49063func (c *SubaccountsPatchCall) Context(ctx context.Context) *SubaccountsPatchCall {
49064	c.ctx_ = ctx
49065	return c
49066}
49067
49068// Header returns an http.Header that can be modified by the caller to
49069// add HTTP headers to the request.
49070func (c *SubaccountsPatchCall) Header() http.Header {
49071	if c.header_ == nil {
49072		c.header_ = make(http.Header)
49073	}
49074	return c.header_
49075}
49076
49077func (c *SubaccountsPatchCall) doRequest(alt string) (*http.Response, error) {
49078	reqHeaders := make(http.Header)
49079	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
49080	for k, v := range c.header_ {
49081		reqHeaders[k] = v
49082	}
49083	reqHeaders.Set("User-Agent", c.s.userAgent())
49084	var body io.Reader = nil
49085	body, err := googleapi.WithoutDataWrapper.JSONReader(c.subaccount)
49086	if err != nil {
49087		return nil, err
49088	}
49089	reqHeaders.Set("Content-Type", "application/json")
49090	c.urlParams_.Set("alt", alt)
49091	c.urlParams_.Set("prettyPrint", "false")
49092	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/subaccounts")
49093	urls += "?" + c.urlParams_.Encode()
49094	req, err := http.NewRequest("PATCH", urls, body)
49095	if err != nil {
49096		return nil, err
49097	}
49098	req.Header = reqHeaders
49099	googleapi.Expand(req.URL, map[string]string{
49100		"profileId": strconv.FormatInt(c.profileId, 10),
49101	})
49102	return gensupport.SendRequest(c.ctx_, c.s.client, req)
49103}
49104
49105// Do executes the "dfareporting.subaccounts.patch" call.
49106// Exactly one of *Subaccount or error will be non-nil. Any non-2xx
49107// status code is an error. Response headers are in either
49108// *Subaccount.ServerResponse.Header or (if a response was returned at
49109// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
49110// to check whether the returned error was because
49111// http.StatusNotModified was returned.
49112func (c *SubaccountsPatchCall) Do(opts ...googleapi.CallOption) (*Subaccount, error) {
49113	gensupport.SetOptions(c.urlParams_, opts...)
49114	res, err := c.doRequest("json")
49115	if res != nil && res.StatusCode == http.StatusNotModified {
49116		if res.Body != nil {
49117			res.Body.Close()
49118		}
49119		return nil, &googleapi.Error{
49120			Code:   res.StatusCode,
49121			Header: res.Header,
49122		}
49123	}
49124	if err != nil {
49125		return nil, err
49126	}
49127	defer googleapi.CloseBody(res)
49128	if err := googleapi.CheckResponse(res); err != nil {
49129		return nil, err
49130	}
49131	ret := &Subaccount{
49132		ServerResponse: googleapi.ServerResponse{
49133			Header:         res.Header,
49134			HTTPStatusCode: res.StatusCode,
49135		},
49136	}
49137	target := &ret
49138	if err := gensupport.DecodeResponse(target, res); err != nil {
49139		return nil, err
49140	}
49141	return ret, nil
49142	// {
49143	//   "description": "Updates an existing subaccount. This method supports patch semantics.",
49144	//   "flatPath": "userprofiles/{profileId}/subaccounts",
49145	//   "httpMethod": "PATCH",
49146	//   "id": "dfareporting.subaccounts.patch",
49147	//   "parameterOrder": [
49148	//     "profileId",
49149	//     "id"
49150	//   ],
49151	//   "parameters": {
49152	//     "id": {
49153	//       "description": "Subaccount ID.",
49154	//       "format": "int64",
49155	//       "location": "query",
49156	//       "required": true,
49157	//       "type": "string"
49158	//     },
49159	//     "profileId": {
49160	//       "description": "User profile ID associated with this request.",
49161	//       "format": "int64",
49162	//       "location": "path",
49163	//       "required": true,
49164	//       "type": "string"
49165	//     }
49166	//   },
49167	//   "path": "userprofiles/{profileId}/subaccounts",
49168	//   "request": {
49169	//     "$ref": "Subaccount"
49170	//   },
49171	//   "response": {
49172	//     "$ref": "Subaccount"
49173	//   },
49174	//   "scopes": [
49175	//     "https://www.googleapis.com/auth/dfatrafficking"
49176	//   ]
49177	// }
49178
49179}
49180
49181// method id "dfareporting.subaccounts.update":
49182
49183type SubaccountsUpdateCall struct {
49184	s          *Service
49185	profileId  int64
49186	subaccount *Subaccount
49187	urlParams_ gensupport.URLParams
49188	ctx_       context.Context
49189	header_    http.Header
49190}
49191
49192// Update: Updates an existing subaccount.
49193//
49194// - profileId: User profile ID associated with this request.
49195func (r *SubaccountsService) Update(profileId int64, subaccount *Subaccount) *SubaccountsUpdateCall {
49196	c := &SubaccountsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
49197	c.profileId = profileId
49198	c.subaccount = subaccount
49199	return c
49200}
49201
49202// Fields allows partial responses to be retrieved. See
49203// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
49204// for more information.
49205func (c *SubaccountsUpdateCall) Fields(s ...googleapi.Field) *SubaccountsUpdateCall {
49206	c.urlParams_.Set("fields", googleapi.CombineFields(s))
49207	return c
49208}
49209
49210// Context sets the context to be used in this call's Do method. Any
49211// pending HTTP request will be aborted if the provided context is
49212// canceled.
49213func (c *SubaccountsUpdateCall) Context(ctx context.Context) *SubaccountsUpdateCall {
49214	c.ctx_ = ctx
49215	return c
49216}
49217
49218// Header returns an http.Header that can be modified by the caller to
49219// add HTTP headers to the request.
49220func (c *SubaccountsUpdateCall) Header() http.Header {
49221	if c.header_ == nil {
49222		c.header_ = make(http.Header)
49223	}
49224	return c.header_
49225}
49226
49227func (c *SubaccountsUpdateCall) doRequest(alt string) (*http.Response, error) {
49228	reqHeaders := make(http.Header)
49229	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
49230	for k, v := range c.header_ {
49231		reqHeaders[k] = v
49232	}
49233	reqHeaders.Set("User-Agent", c.s.userAgent())
49234	var body io.Reader = nil
49235	body, err := googleapi.WithoutDataWrapper.JSONReader(c.subaccount)
49236	if err != nil {
49237		return nil, err
49238	}
49239	reqHeaders.Set("Content-Type", "application/json")
49240	c.urlParams_.Set("alt", alt)
49241	c.urlParams_.Set("prettyPrint", "false")
49242	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/subaccounts")
49243	urls += "?" + c.urlParams_.Encode()
49244	req, err := http.NewRequest("PUT", urls, body)
49245	if err != nil {
49246		return nil, err
49247	}
49248	req.Header = reqHeaders
49249	googleapi.Expand(req.URL, map[string]string{
49250		"profileId": strconv.FormatInt(c.profileId, 10),
49251	})
49252	return gensupport.SendRequest(c.ctx_, c.s.client, req)
49253}
49254
49255// Do executes the "dfareporting.subaccounts.update" call.
49256// Exactly one of *Subaccount or error will be non-nil. Any non-2xx
49257// status code is an error. Response headers are in either
49258// *Subaccount.ServerResponse.Header or (if a response was returned at
49259// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
49260// to check whether the returned error was because
49261// http.StatusNotModified was returned.
49262func (c *SubaccountsUpdateCall) Do(opts ...googleapi.CallOption) (*Subaccount, error) {
49263	gensupport.SetOptions(c.urlParams_, opts...)
49264	res, err := c.doRequest("json")
49265	if res != nil && res.StatusCode == http.StatusNotModified {
49266		if res.Body != nil {
49267			res.Body.Close()
49268		}
49269		return nil, &googleapi.Error{
49270			Code:   res.StatusCode,
49271			Header: res.Header,
49272		}
49273	}
49274	if err != nil {
49275		return nil, err
49276	}
49277	defer googleapi.CloseBody(res)
49278	if err := googleapi.CheckResponse(res); err != nil {
49279		return nil, err
49280	}
49281	ret := &Subaccount{
49282		ServerResponse: googleapi.ServerResponse{
49283			Header:         res.Header,
49284			HTTPStatusCode: res.StatusCode,
49285		},
49286	}
49287	target := &ret
49288	if err := gensupport.DecodeResponse(target, res); err != nil {
49289		return nil, err
49290	}
49291	return ret, nil
49292	// {
49293	//   "description": "Updates an existing subaccount.",
49294	//   "flatPath": "userprofiles/{profileId}/subaccounts",
49295	//   "httpMethod": "PUT",
49296	//   "id": "dfareporting.subaccounts.update",
49297	//   "parameterOrder": [
49298	//     "profileId"
49299	//   ],
49300	//   "parameters": {
49301	//     "profileId": {
49302	//       "description": "User profile ID associated with this request.",
49303	//       "format": "int64",
49304	//       "location": "path",
49305	//       "required": true,
49306	//       "type": "string"
49307	//     }
49308	//   },
49309	//   "path": "userprofiles/{profileId}/subaccounts",
49310	//   "request": {
49311	//     "$ref": "Subaccount"
49312	//   },
49313	//   "response": {
49314	//     "$ref": "Subaccount"
49315	//   },
49316	//   "scopes": [
49317	//     "https://www.googleapis.com/auth/dfatrafficking"
49318	//   ]
49319	// }
49320
49321}
49322
49323// method id "dfareporting.targetableRemarketingLists.get":
49324
49325type TargetableRemarketingListsGetCall struct {
49326	s            *Service
49327	profileId    int64
49328	id           int64
49329	urlParams_   gensupport.URLParams
49330	ifNoneMatch_ string
49331	ctx_         context.Context
49332	header_      http.Header
49333}
49334
49335// Get: Gets one remarketing list by ID.
49336//
49337// - id: Remarketing list ID.
49338// - profileId: User profile ID associated with this request.
49339func (r *TargetableRemarketingListsService) Get(profileId int64, id int64) *TargetableRemarketingListsGetCall {
49340	c := &TargetableRemarketingListsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
49341	c.profileId = profileId
49342	c.id = id
49343	return c
49344}
49345
49346// Fields allows partial responses to be retrieved. See
49347// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
49348// for more information.
49349func (c *TargetableRemarketingListsGetCall) Fields(s ...googleapi.Field) *TargetableRemarketingListsGetCall {
49350	c.urlParams_.Set("fields", googleapi.CombineFields(s))
49351	return c
49352}
49353
49354// IfNoneMatch sets the optional parameter which makes the operation
49355// fail if the object's ETag matches the given value. This is useful for
49356// getting updates only after the object has changed since the last
49357// request. Use googleapi.IsNotModified to check whether the response
49358// error from Do is the result of In-None-Match.
49359func (c *TargetableRemarketingListsGetCall) IfNoneMatch(entityTag string) *TargetableRemarketingListsGetCall {
49360	c.ifNoneMatch_ = entityTag
49361	return c
49362}
49363
49364// Context sets the context to be used in this call's Do method. Any
49365// pending HTTP request will be aborted if the provided context is
49366// canceled.
49367func (c *TargetableRemarketingListsGetCall) Context(ctx context.Context) *TargetableRemarketingListsGetCall {
49368	c.ctx_ = ctx
49369	return c
49370}
49371
49372// Header returns an http.Header that can be modified by the caller to
49373// add HTTP headers to the request.
49374func (c *TargetableRemarketingListsGetCall) Header() http.Header {
49375	if c.header_ == nil {
49376		c.header_ = make(http.Header)
49377	}
49378	return c.header_
49379}
49380
49381func (c *TargetableRemarketingListsGetCall) doRequest(alt string) (*http.Response, error) {
49382	reqHeaders := make(http.Header)
49383	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
49384	for k, v := range c.header_ {
49385		reqHeaders[k] = v
49386	}
49387	reqHeaders.Set("User-Agent", c.s.userAgent())
49388	if c.ifNoneMatch_ != "" {
49389		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
49390	}
49391	var body io.Reader = nil
49392	c.urlParams_.Set("alt", alt)
49393	c.urlParams_.Set("prettyPrint", "false")
49394	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/targetableRemarketingLists/{id}")
49395	urls += "?" + c.urlParams_.Encode()
49396	req, err := http.NewRequest("GET", urls, body)
49397	if err != nil {
49398		return nil, err
49399	}
49400	req.Header = reqHeaders
49401	googleapi.Expand(req.URL, map[string]string{
49402		"profileId": strconv.FormatInt(c.profileId, 10),
49403		"id":        strconv.FormatInt(c.id, 10),
49404	})
49405	return gensupport.SendRequest(c.ctx_, c.s.client, req)
49406}
49407
49408// Do executes the "dfareporting.targetableRemarketingLists.get" call.
49409// Exactly one of *TargetableRemarketingList or error will be non-nil.
49410// Any non-2xx status code is an error. Response headers are in either
49411// *TargetableRemarketingList.ServerResponse.Header or (if a response
49412// was returned at all) in error.(*googleapi.Error).Header. Use
49413// googleapi.IsNotModified to check whether the returned error was
49414// because http.StatusNotModified was returned.
49415func (c *TargetableRemarketingListsGetCall) Do(opts ...googleapi.CallOption) (*TargetableRemarketingList, error) {
49416	gensupport.SetOptions(c.urlParams_, opts...)
49417	res, err := c.doRequest("json")
49418	if res != nil && res.StatusCode == http.StatusNotModified {
49419		if res.Body != nil {
49420			res.Body.Close()
49421		}
49422		return nil, &googleapi.Error{
49423			Code:   res.StatusCode,
49424			Header: res.Header,
49425		}
49426	}
49427	if err != nil {
49428		return nil, err
49429	}
49430	defer googleapi.CloseBody(res)
49431	if err := googleapi.CheckResponse(res); err != nil {
49432		return nil, err
49433	}
49434	ret := &TargetableRemarketingList{
49435		ServerResponse: googleapi.ServerResponse{
49436			Header:         res.Header,
49437			HTTPStatusCode: res.StatusCode,
49438		},
49439	}
49440	target := &ret
49441	if err := gensupport.DecodeResponse(target, res); err != nil {
49442		return nil, err
49443	}
49444	return ret, nil
49445	// {
49446	//   "description": "Gets one remarketing list by ID.",
49447	//   "flatPath": "userprofiles/{profileId}/targetableRemarketingLists/{id}",
49448	//   "httpMethod": "GET",
49449	//   "id": "dfareporting.targetableRemarketingLists.get",
49450	//   "parameterOrder": [
49451	//     "profileId",
49452	//     "id"
49453	//   ],
49454	//   "parameters": {
49455	//     "id": {
49456	//       "description": "Remarketing list ID.",
49457	//       "format": "int64",
49458	//       "location": "path",
49459	//       "required": true,
49460	//       "type": "string"
49461	//     },
49462	//     "profileId": {
49463	//       "description": "User profile ID associated with this request.",
49464	//       "format": "int64",
49465	//       "location": "path",
49466	//       "required": true,
49467	//       "type": "string"
49468	//     }
49469	//   },
49470	//   "path": "userprofiles/{profileId}/targetableRemarketingLists/{id}",
49471	//   "response": {
49472	//     "$ref": "TargetableRemarketingList"
49473	//   },
49474	//   "scopes": [
49475	//     "https://www.googleapis.com/auth/dfatrafficking"
49476	//   ]
49477	// }
49478
49479}
49480
49481// method id "dfareporting.targetableRemarketingLists.list":
49482
49483type TargetableRemarketingListsListCall struct {
49484	s            *Service
49485	profileId    int64
49486	urlParams_   gensupport.URLParams
49487	ifNoneMatch_ string
49488	ctx_         context.Context
49489	header_      http.Header
49490}
49491
49492// List: Retrieves a list of targetable remarketing lists, possibly
49493// filtered. This method supports paging.
49494//
49495// - advertiserId: Select only targetable remarketing lists targetable
49496//   by these advertisers.
49497// - profileId: User profile ID associated with this request.
49498func (r *TargetableRemarketingListsService) List(profileId int64, advertiserId int64) *TargetableRemarketingListsListCall {
49499	c := &TargetableRemarketingListsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
49500	c.profileId = profileId
49501	c.urlParams_.Set("advertiserId", fmt.Sprint(advertiserId))
49502	return c
49503}
49504
49505// Active sets the optional parameter "active": Select only active or
49506// only inactive targetable remarketing lists.
49507func (c *TargetableRemarketingListsListCall) Active(active bool) *TargetableRemarketingListsListCall {
49508	c.urlParams_.Set("active", fmt.Sprint(active))
49509	return c
49510}
49511
49512// MaxResults sets the optional parameter "maxResults": Maximum number
49513// of results to return.
49514func (c *TargetableRemarketingListsListCall) MaxResults(maxResults int64) *TargetableRemarketingListsListCall {
49515	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
49516	return c
49517}
49518
49519// Name sets the optional parameter "name": Allows searching for objects
49520// by name or ID. Wildcards (*) are allowed. For example, "remarketing
49521// list*2015" will return objects with names like "remarketing list June
49522// 2015", "remarketing list April 2015", or simply "remarketing list
49523// 2015". Most of the searches also add wildcards implicitly at the
49524// start and the end of the search string. For example, a search string
49525// of "remarketing list" will match objects with name "my remarketing
49526// list", "remarketing list 2015", or simply "remarketing list".
49527func (c *TargetableRemarketingListsListCall) Name(name string) *TargetableRemarketingListsListCall {
49528	c.urlParams_.Set("name", name)
49529	return c
49530}
49531
49532// PageToken sets the optional parameter "pageToken": Value of the
49533// nextPageToken from the previous result page.
49534func (c *TargetableRemarketingListsListCall) PageToken(pageToken string) *TargetableRemarketingListsListCall {
49535	c.urlParams_.Set("pageToken", pageToken)
49536	return c
49537}
49538
49539// SortField sets the optional parameter "sortField": Field by which to
49540// sort the list.
49541//
49542// Possible values:
49543//   "ID" (default)
49544//   "NAME"
49545func (c *TargetableRemarketingListsListCall) SortField(sortField string) *TargetableRemarketingListsListCall {
49546	c.urlParams_.Set("sortField", sortField)
49547	return c
49548}
49549
49550// SortOrder sets the optional parameter "sortOrder": Order of sorted
49551// results.
49552//
49553// Possible values:
49554//   "ASCENDING" (default)
49555//   "DESCENDING"
49556func (c *TargetableRemarketingListsListCall) SortOrder(sortOrder string) *TargetableRemarketingListsListCall {
49557	c.urlParams_.Set("sortOrder", sortOrder)
49558	return c
49559}
49560
49561// Fields allows partial responses to be retrieved. See
49562// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
49563// for more information.
49564func (c *TargetableRemarketingListsListCall) Fields(s ...googleapi.Field) *TargetableRemarketingListsListCall {
49565	c.urlParams_.Set("fields", googleapi.CombineFields(s))
49566	return c
49567}
49568
49569// IfNoneMatch sets the optional parameter which makes the operation
49570// fail if the object's ETag matches the given value. This is useful for
49571// getting updates only after the object has changed since the last
49572// request. Use googleapi.IsNotModified to check whether the response
49573// error from Do is the result of In-None-Match.
49574func (c *TargetableRemarketingListsListCall) IfNoneMatch(entityTag string) *TargetableRemarketingListsListCall {
49575	c.ifNoneMatch_ = entityTag
49576	return c
49577}
49578
49579// Context sets the context to be used in this call's Do method. Any
49580// pending HTTP request will be aborted if the provided context is
49581// canceled.
49582func (c *TargetableRemarketingListsListCall) Context(ctx context.Context) *TargetableRemarketingListsListCall {
49583	c.ctx_ = ctx
49584	return c
49585}
49586
49587// Header returns an http.Header that can be modified by the caller to
49588// add HTTP headers to the request.
49589func (c *TargetableRemarketingListsListCall) Header() http.Header {
49590	if c.header_ == nil {
49591		c.header_ = make(http.Header)
49592	}
49593	return c.header_
49594}
49595
49596func (c *TargetableRemarketingListsListCall) doRequest(alt string) (*http.Response, error) {
49597	reqHeaders := make(http.Header)
49598	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
49599	for k, v := range c.header_ {
49600		reqHeaders[k] = v
49601	}
49602	reqHeaders.Set("User-Agent", c.s.userAgent())
49603	if c.ifNoneMatch_ != "" {
49604		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
49605	}
49606	var body io.Reader = nil
49607	c.urlParams_.Set("alt", alt)
49608	c.urlParams_.Set("prettyPrint", "false")
49609	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/targetableRemarketingLists")
49610	urls += "?" + c.urlParams_.Encode()
49611	req, err := http.NewRequest("GET", urls, body)
49612	if err != nil {
49613		return nil, err
49614	}
49615	req.Header = reqHeaders
49616	googleapi.Expand(req.URL, map[string]string{
49617		"profileId": strconv.FormatInt(c.profileId, 10),
49618	})
49619	return gensupport.SendRequest(c.ctx_, c.s.client, req)
49620}
49621
49622// Do executes the "dfareporting.targetableRemarketingLists.list" call.
49623// Exactly one of *TargetableRemarketingListsListResponse or error will
49624// be non-nil. Any non-2xx status code is an error. Response headers are
49625// in either
49626// *TargetableRemarketingListsListResponse.ServerResponse.Header or (if
49627// a response was returned at all) in error.(*googleapi.Error).Header.
49628// Use googleapi.IsNotModified to check whether the returned error was
49629// because http.StatusNotModified was returned.
49630func (c *TargetableRemarketingListsListCall) Do(opts ...googleapi.CallOption) (*TargetableRemarketingListsListResponse, error) {
49631	gensupport.SetOptions(c.urlParams_, opts...)
49632	res, err := c.doRequest("json")
49633	if res != nil && res.StatusCode == http.StatusNotModified {
49634		if res.Body != nil {
49635			res.Body.Close()
49636		}
49637		return nil, &googleapi.Error{
49638			Code:   res.StatusCode,
49639			Header: res.Header,
49640		}
49641	}
49642	if err != nil {
49643		return nil, err
49644	}
49645	defer googleapi.CloseBody(res)
49646	if err := googleapi.CheckResponse(res); err != nil {
49647		return nil, err
49648	}
49649	ret := &TargetableRemarketingListsListResponse{
49650		ServerResponse: googleapi.ServerResponse{
49651			Header:         res.Header,
49652			HTTPStatusCode: res.StatusCode,
49653		},
49654	}
49655	target := &ret
49656	if err := gensupport.DecodeResponse(target, res); err != nil {
49657		return nil, err
49658	}
49659	return ret, nil
49660	// {
49661	//   "description": "Retrieves a list of targetable remarketing lists, possibly filtered. This method supports paging.",
49662	//   "flatPath": "userprofiles/{profileId}/targetableRemarketingLists",
49663	//   "httpMethod": "GET",
49664	//   "id": "dfareporting.targetableRemarketingLists.list",
49665	//   "parameterOrder": [
49666	//     "profileId",
49667	//     "advertiserId"
49668	//   ],
49669	//   "parameters": {
49670	//     "active": {
49671	//       "description": "Select only active or only inactive targetable remarketing lists.",
49672	//       "location": "query",
49673	//       "type": "boolean"
49674	//     },
49675	//     "advertiserId": {
49676	//       "description": "Select only targetable remarketing lists targetable by these advertisers.",
49677	//       "format": "int64",
49678	//       "location": "query",
49679	//       "required": true,
49680	//       "type": "string"
49681	//     },
49682	//     "maxResults": {
49683	//       "default": "1000",
49684	//       "description": "Maximum number of results to return.",
49685	//       "format": "int32",
49686	//       "location": "query",
49687	//       "maximum": "1000",
49688	//       "minimum": "0",
49689	//       "type": "integer"
49690	//     },
49691	//     "name": {
49692	//       "description": "Allows searching for objects by name or ID. Wildcards (*) are allowed. For example, \"remarketing list*2015\" will return objects with names like \"remarketing list June 2015\", \"remarketing list April 2015\", or simply \"remarketing list 2015\". Most of the searches also add wildcards implicitly at the start and the end of the search string. For example, a search string of \"remarketing list\" will match objects with name \"my remarketing list\", \"remarketing list 2015\", or simply \"remarketing list\".",
49693	//       "location": "query",
49694	//       "type": "string"
49695	//     },
49696	//     "pageToken": {
49697	//       "description": "Value of the nextPageToken from the previous result page.",
49698	//       "location": "query",
49699	//       "type": "string"
49700	//     },
49701	//     "profileId": {
49702	//       "description": "User profile ID associated with this request.",
49703	//       "format": "int64",
49704	//       "location": "path",
49705	//       "required": true,
49706	//       "type": "string"
49707	//     },
49708	//     "sortField": {
49709	//       "default": "ID",
49710	//       "description": "Field by which to sort the list.",
49711	//       "enum": [
49712	//         "ID",
49713	//         "NAME"
49714	//       ],
49715	//       "enumDescriptions": [
49716	//         "",
49717	//         ""
49718	//       ],
49719	//       "location": "query",
49720	//       "type": "string"
49721	//     },
49722	//     "sortOrder": {
49723	//       "default": "ASCENDING",
49724	//       "description": "Order of sorted results.",
49725	//       "enum": [
49726	//         "ASCENDING",
49727	//         "DESCENDING"
49728	//       ],
49729	//       "enumDescriptions": [
49730	//         "",
49731	//         ""
49732	//       ],
49733	//       "location": "query",
49734	//       "type": "string"
49735	//     }
49736	//   },
49737	//   "path": "userprofiles/{profileId}/targetableRemarketingLists",
49738	//   "response": {
49739	//     "$ref": "TargetableRemarketingListsListResponse"
49740	//   },
49741	//   "scopes": [
49742	//     "https://www.googleapis.com/auth/dfatrafficking"
49743	//   ]
49744	// }
49745
49746}
49747
49748// Pages invokes f for each page of results.
49749// A non-nil error returned from f will halt the iteration.
49750// The provided context supersedes any context provided to the Context method.
49751func (c *TargetableRemarketingListsListCall) Pages(ctx context.Context, f func(*TargetableRemarketingListsListResponse) error) error {
49752	c.ctx_ = ctx
49753	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
49754	for {
49755		x, err := c.Do()
49756		if err != nil {
49757			return err
49758		}
49759		if err := f(x); err != nil {
49760			return err
49761		}
49762		if x.NextPageToken == "" {
49763			return nil
49764		}
49765		c.PageToken(x.NextPageToken)
49766	}
49767}
49768
49769// method id "dfareporting.targetingTemplates.get":
49770
49771type TargetingTemplatesGetCall struct {
49772	s            *Service
49773	profileId    int64
49774	id           int64
49775	urlParams_   gensupport.URLParams
49776	ifNoneMatch_ string
49777	ctx_         context.Context
49778	header_      http.Header
49779}
49780
49781// Get: Gets one targeting template by ID.
49782//
49783// - id: Targeting template ID.
49784// - profileId: User profile ID associated with this request.
49785func (r *TargetingTemplatesService) Get(profileId int64, id int64) *TargetingTemplatesGetCall {
49786	c := &TargetingTemplatesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
49787	c.profileId = profileId
49788	c.id = id
49789	return c
49790}
49791
49792// Fields allows partial responses to be retrieved. See
49793// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
49794// for more information.
49795func (c *TargetingTemplatesGetCall) Fields(s ...googleapi.Field) *TargetingTemplatesGetCall {
49796	c.urlParams_.Set("fields", googleapi.CombineFields(s))
49797	return c
49798}
49799
49800// IfNoneMatch sets the optional parameter which makes the operation
49801// fail if the object's ETag matches the given value. This is useful for
49802// getting updates only after the object has changed since the last
49803// request. Use googleapi.IsNotModified to check whether the response
49804// error from Do is the result of In-None-Match.
49805func (c *TargetingTemplatesGetCall) IfNoneMatch(entityTag string) *TargetingTemplatesGetCall {
49806	c.ifNoneMatch_ = entityTag
49807	return c
49808}
49809
49810// Context sets the context to be used in this call's Do method. Any
49811// pending HTTP request will be aborted if the provided context is
49812// canceled.
49813func (c *TargetingTemplatesGetCall) Context(ctx context.Context) *TargetingTemplatesGetCall {
49814	c.ctx_ = ctx
49815	return c
49816}
49817
49818// Header returns an http.Header that can be modified by the caller to
49819// add HTTP headers to the request.
49820func (c *TargetingTemplatesGetCall) Header() http.Header {
49821	if c.header_ == nil {
49822		c.header_ = make(http.Header)
49823	}
49824	return c.header_
49825}
49826
49827func (c *TargetingTemplatesGetCall) doRequest(alt string) (*http.Response, error) {
49828	reqHeaders := make(http.Header)
49829	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
49830	for k, v := range c.header_ {
49831		reqHeaders[k] = v
49832	}
49833	reqHeaders.Set("User-Agent", c.s.userAgent())
49834	if c.ifNoneMatch_ != "" {
49835		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
49836	}
49837	var body io.Reader = nil
49838	c.urlParams_.Set("alt", alt)
49839	c.urlParams_.Set("prettyPrint", "false")
49840	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/targetingTemplates/{id}")
49841	urls += "?" + c.urlParams_.Encode()
49842	req, err := http.NewRequest("GET", urls, body)
49843	if err != nil {
49844		return nil, err
49845	}
49846	req.Header = reqHeaders
49847	googleapi.Expand(req.URL, map[string]string{
49848		"profileId": strconv.FormatInt(c.profileId, 10),
49849		"id":        strconv.FormatInt(c.id, 10),
49850	})
49851	return gensupport.SendRequest(c.ctx_, c.s.client, req)
49852}
49853
49854// Do executes the "dfareporting.targetingTemplates.get" call.
49855// Exactly one of *TargetingTemplate or error will be non-nil. Any
49856// non-2xx status code is an error. Response headers are in either
49857// *TargetingTemplate.ServerResponse.Header or (if a response was
49858// returned at all) in error.(*googleapi.Error).Header. Use
49859// googleapi.IsNotModified to check whether the returned error was
49860// because http.StatusNotModified was returned.
49861func (c *TargetingTemplatesGetCall) Do(opts ...googleapi.CallOption) (*TargetingTemplate, error) {
49862	gensupport.SetOptions(c.urlParams_, opts...)
49863	res, err := c.doRequest("json")
49864	if res != nil && res.StatusCode == http.StatusNotModified {
49865		if res.Body != nil {
49866			res.Body.Close()
49867		}
49868		return nil, &googleapi.Error{
49869			Code:   res.StatusCode,
49870			Header: res.Header,
49871		}
49872	}
49873	if err != nil {
49874		return nil, err
49875	}
49876	defer googleapi.CloseBody(res)
49877	if err := googleapi.CheckResponse(res); err != nil {
49878		return nil, err
49879	}
49880	ret := &TargetingTemplate{
49881		ServerResponse: googleapi.ServerResponse{
49882			Header:         res.Header,
49883			HTTPStatusCode: res.StatusCode,
49884		},
49885	}
49886	target := &ret
49887	if err := gensupport.DecodeResponse(target, res); err != nil {
49888		return nil, err
49889	}
49890	return ret, nil
49891	// {
49892	//   "description": "Gets one targeting template by ID.",
49893	//   "flatPath": "userprofiles/{profileId}/targetingTemplates/{id}",
49894	//   "httpMethod": "GET",
49895	//   "id": "dfareporting.targetingTemplates.get",
49896	//   "parameterOrder": [
49897	//     "profileId",
49898	//     "id"
49899	//   ],
49900	//   "parameters": {
49901	//     "id": {
49902	//       "description": "Targeting template ID.",
49903	//       "format": "int64",
49904	//       "location": "path",
49905	//       "required": true,
49906	//       "type": "string"
49907	//     },
49908	//     "profileId": {
49909	//       "description": "User profile ID associated with this request.",
49910	//       "format": "int64",
49911	//       "location": "path",
49912	//       "required": true,
49913	//       "type": "string"
49914	//     }
49915	//   },
49916	//   "path": "userprofiles/{profileId}/targetingTemplates/{id}",
49917	//   "response": {
49918	//     "$ref": "TargetingTemplate"
49919	//   },
49920	//   "scopes": [
49921	//     "https://www.googleapis.com/auth/dfatrafficking"
49922	//   ]
49923	// }
49924
49925}
49926
49927// method id "dfareporting.targetingTemplates.insert":
49928
49929type TargetingTemplatesInsertCall struct {
49930	s                 *Service
49931	profileId         int64
49932	targetingtemplate *TargetingTemplate
49933	urlParams_        gensupport.URLParams
49934	ctx_              context.Context
49935	header_           http.Header
49936}
49937
49938// Insert: Inserts a new targeting template.
49939//
49940// - profileId: User profile ID associated with this request.
49941func (r *TargetingTemplatesService) Insert(profileId int64, targetingtemplate *TargetingTemplate) *TargetingTemplatesInsertCall {
49942	c := &TargetingTemplatesInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
49943	c.profileId = profileId
49944	c.targetingtemplate = targetingtemplate
49945	return c
49946}
49947
49948// Fields allows partial responses to be retrieved. See
49949// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
49950// for more information.
49951func (c *TargetingTemplatesInsertCall) Fields(s ...googleapi.Field) *TargetingTemplatesInsertCall {
49952	c.urlParams_.Set("fields", googleapi.CombineFields(s))
49953	return c
49954}
49955
49956// Context sets the context to be used in this call's Do method. Any
49957// pending HTTP request will be aborted if the provided context is
49958// canceled.
49959func (c *TargetingTemplatesInsertCall) Context(ctx context.Context) *TargetingTemplatesInsertCall {
49960	c.ctx_ = ctx
49961	return c
49962}
49963
49964// Header returns an http.Header that can be modified by the caller to
49965// add HTTP headers to the request.
49966func (c *TargetingTemplatesInsertCall) Header() http.Header {
49967	if c.header_ == nil {
49968		c.header_ = make(http.Header)
49969	}
49970	return c.header_
49971}
49972
49973func (c *TargetingTemplatesInsertCall) doRequest(alt string) (*http.Response, error) {
49974	reqHeaders := make(http.Header)
49975	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
49976	for k, v := range c.header_ {
49977		reqHeaders[k] = v
49978	}
49979	reqHeaders.Set("User-Agent", c.s.userAgent())
49980	var body io.Reader = nil
49981	body, err := googleapi.WithoutDataWrapper.JSONReader(c.targetingtemplate)
49982	if err != nil {
49983		return nil, err
49984	}
49985	reqHeaders.Set("Content-Type", "application/json")
49986	c.urlParams_.Set("alt", alt)
49987	c.urlParams_.Set("prettyPrint", "false")
49988	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/targetingTemplates")
49989	urls += "?" + c.urlParams_.Encode()
49990	req, err := http.NewRequest("POST", urls, body)
49991	if err != nil {
49992		return nil, err
49993	}
49994	req.Header = reqHeaders
49995	googleapi.Expand(req.URL, map[string]string{
49996		"profileId": strconv.FormatInt(c.profileId, 10),
49997	})
49998	return gensupport.SendRequest(c.ctx_, c.s.client, req)
49999}
50000
50001// Do executes the "dfareporting.targetingTemplates.insert" call.
50002// Exactly one of *TargetingTemplate or error will be non-nil. Any
50003// non-2xx status code is an error. Response headers are in either
50004// *TargetingTemplate.ServerResponse.Header or (if a response was
50005// returned at all) in error.(*googleapi.Error).Header. Use
50006// googleapi.IsNotModified to check whether the returned error was
50007// because http.StatusNotModified was returned.
50008func (c *TargetingTemplatesInsertCall) Do(opts ...googleapi.CallOption) (*TargetingTemplate, error) {
50009	gensupport.SetOptions(c.urlParams_, opts...)
50010	res, err := c.doRequest("json")
50011	if res != nil && res.StatusCode == http.StatusNotModified {
50012		if res.Body != nil {
50013			res.Body.Close()
50014		}
50015		return nil, &googleapi.Error{
50016			Code:   res.StatusCode,
50017			Header: res.Header,
50018		}
50019	}
50020	if err != nil {
50021		return nil, err
50022	}
50023	defer googleapi.CloseBody(res)
50024	if err := googleapi.CheckResponse(res); err != nil {
50025		return nil, err
50026	}
50027	ret := &TargetingTemplate{
50028		ServerResponse: googleapi.ServerResponse{
50029			Header:         res.Header,
50030			HTTPStatusCode: res.StatusCode,
50031		},
50032	}
50033	target := &ret
50034	if err := gensupport.DecodeResponse(target, res); err != nil {
50035		return nil, err
50036	}
50037	return ret, nil
50038	// {
50039	//   "description": "Inserts a new targeting template.",
50040	//   "flatPath": "userprofiles/{profileId}/targetingTemplates",
50041	//   "httpMethod": "POST",
50042	//   "id": "dfareporting.targetingTemplates.insert",
50043	//   "parameterOrder": [
50044	//     "profileId"
50045	//   ],
50046	//   "parameters": {
50047	//     "profileId": {
50048	//       "description": "User profile ID associated with this request.",
50049	//       "format": "int64",
50050	//       "location": "path",
50051	//       "required": true,
50052	//       "type": "string"
50053	//     }
50054	//   },
50055	//   "path": "userprofiles/{profileId}/targetingTemplates",
50056	//   "request": {
50057	//     "$ref": "TargetingTemplate"
50058	//   },
50059	//   "response": {
50060	//     "$ref": "TargetingTemplate"
50061	//   },
50062	//   "scopes": [
50063	//     "https://www.googleapis.com/auth/dfatrafficking"
50064	//   ]
50065	// }
50066
50067}
50068
50069// method id "dfareporting.targetingTemplates.list":
50070
50071type TargetingTemplatesListCall struct {
50072	s            *Service
50073	profileId    int64
50074	urlParams_   gensupport.URLParams
50075	ifNoneMatch_ string
50076	ctx_         context.Context
50077	header_      http.Header
50078}
50079
50080// List: Retrieves a list of targeting templates, optionally filtered.
50081// This method supports paging.
50082//
50083// - profileId: User profile ID associated with this request.
50084func (r *TargetingTemplatesService) List(profileId int64) *TargetingTemplatesListCall {
50085	c := &TargetingTemplatesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
50086	c.profileId = profileId
50087	return c
50088}
50089
50090// AdvertiserId sets the optional parameter "advertiserId": Select only
50091// targeting templates with this advertiser ID.
50092func (c *TargetingTemplatesListCall) AdvertiserId(advertiserId int64) *TargetingTemplatesListCall {
50093	c.urlParams_.Set("advertiserId", fmt.Sprint(advertiserId))
50094	return c
50095}
50096
50097// Ids sets the optional parameter "ids": Select only targeting
50098// templates with these IDs.
50099func (c *TargetingTemplatesListCall) Ids(ids ...int64) *TargetingTemplatesListCall {
50100	var ids_ []string
50101	for _, v := range ids {
50102		ids_ = append(ids_, fmt.Sprint(v))
50103	}
50104	c.urlParams_.SetMulti("ids", ids_)
50105	return c
50106}
50107
50108// MaxResults sets the optional parameter "maxResults": Maximum number
50109// of results to return.
50110func (c *TargetingTemplatesListCall) MaxResults(maxResults int64) *TargetingTemplatesListCall {
50111	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
50112	return c
50113}
50114
50115// PageToken sets the optional parameter "pageToken": Value of the
50116// nextPageToken from the previous result page.
50117func (c *TargetingTemplatesListCall) PageToken(pageToken string) *TargetingTemplatesListCall {
50118	c.urlParams_.Set("pageToken", pageToken)
50119	return c
50120}
50121
50122// SearchString sets the optional parameter "searchString": Allows
50123// searching for objects by name or ID. Wildcards (*) are allowed. For
50124// example, "template*2015" will return objects with names like
50125// "template June 2015", "template April 2015", or simply "template
50126// 2015". Most of the searches also add wildcards implicitly at the
50127// start and the end of the search string. For example, a search string
50128// of "template" will match objects with name "my template", "template
50129// 2015", or simply "template".
50130func (c *TargetingTemplatesListCall) SearchString(searchString string) *TargetingTemplatesListCall {
50131	c.urlParams_.Set("searchString", searchString)
50132	return c
50133}
50134
50135// SortField sets the optional parameter "sortField": Field by which to
50136// sort the list.
50137//
50138// Possible values:
50139//   "ID" (default)
50140//   "NAME"
50141func (c *TargetingTemplatesListCall) SortField(sortField string) *TargetingTemplatesListCall {
50142	c.urlParams_.Set("sortField", sortField)
50143	return c
50144}
50145
50146// SortOrder sets the optional parameter "sortOrder": Order of sorted
50147// results.
50148//
50149// Possible values:
50150//   "ASCENDING" (default)
50151//   "DESCENDING"
50152func (c *TargetingTemplatesListCall) SortOrder(sortOrder string) *TargetingTemplatesListCall {
50153	c.urlParams_.Set("sortOrder", sortOrder)
50154	return c
50155}
50156
50157// Fields allows partial responses to be retrieved. See
50158// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
50159// for more information.
50160func (c *TargetingTemplatesListCall) Fields(s ...googleapi.Field) *TargetingTemplatesListCall {
50161	c.urlParams_.Set("fields", googleapi.CombineFields(s))
50162	return c
50163}
50164
50165// IfNoneMatch sets the optional parameter which makes the operation
50166// fail if the object's ETag matches the given value. This is useful for
50167// getting updates only after the object has changed since the last
50168// request. Use googleapi.IsNotModified to check whether the response
50169// error from Do is the result of In-None-Match.
50170func (c *TargetingTemplatesListCall) IfNoneMatch(entityTag string) *TargetingTemplatesListCall {
50171	c.ifNoneMatch_ = entityTag
50172	return c
50173}
50174
50175// Context sets the context to be used in this call's Do method. Any
50176// pending HTTP request will be aborted if the provided context is
50177// canceled.
50178func (c *TargetingTemplatesListCall) Context(ctx context.Context) *TargetingTemplatesListCall {
50179	c.ctx_ = ctx
50180	return c
50181}
50182
50183// Header returns an http.Header that can be modified by the caller to
50184// add HTTP headers to the request.
50185func (c *TargetingTemplatesListCall) Header() http.Header {
50186	if c.header_ == nil {
50187		c.header_ = make(http.Header)
50188	}
50189	return c.header_
50190}
50191
50192func (c *TargetingTemplatesListCall) doRequest(alt string) (*http.Response, error) {
50193	reqHeaders := make(http.Header)
50194	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
50195	for k, v := range c.header_ {
50196		reqHeaders[k] = v
50197	}
50198	reqHeaders.Set("User-Agent", c.s.userAgent())
50199	if c.ifNoneMatch_ != "" {
50200		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
50201	}
50202	var body io.Reader = nil
50203	c.urlParams_.Set("alt", alt)
50204	c.urlParams_.Set("prettyPrint", "false")
50205	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/targetingTemplates")
50206	urls += "?" + c.urlParams_.Encode()
50207	req, err := http.NewRequest("GET", urls, body)
50208	if err != nil {
50209		return nil, err
50210	}
50211	req.Header = reqHeaders
50212	googleapi.Expand(req.URL, map[string]string{
50213		"profileId": strconv.FormatInt(c.profileId, 10),
50214	})
50215	return gensupport.SendRequest(c.ctx_, c.s.client, req)
50216}
50217
50218// Do executes the "dfareporting.targetingTemplates.list" call.
50219// Exactly one of *TargetingTemplatesListResponse or error will be
50220// non-nil. Any non-2xx status code is an error. Response headers are in
50221// either *TargetingTemplatesListResponse.ServerResponse.Header or (if a
50222// response was returned at all) in error.(*googleapi.Error).Header. Use
50223// googleapi.IsNotModified to check whether the returned error was
50224// because http.StatusNotModified was returned.
50225func (c *TargetingTemplatesListCall) Do(opts ...googleapi.CallOption) (*TargetingTemplatesListResponse, error) {
50226	gensupport.SetOptions(c.urlParams_, opts...)
50227	res, err := c.doRequest("json")
50228	if res != nil && res.StatusCode == http.StatusNotModified {
50229		if res.Body != nil {
50230			res.Body.Close()
50231		}
50232		return nil, &googleapi.Error{
50233			Code:   res.StatusCode,
50234			Header: res.Header,
50235		}
50236	}
50237	if err != nil {
50238		return nil, err
50239	}
50240	defer googleapi.CloseBody(res)
50241	if err := googleapi.CheckResponse(res); err != nil {
50242		return nil, err
50243	}
50244	ret := &TargetingTemplatesListResponse{
50245		ServerResponse: googleapi.ServerResponse{
50246			Header:         res.Header,
50247			HTTPStatusCode: res.StatusCode,
50248		},
50249	}
50250	target := &ret
50251	if err := gensupport.DecodeResponse(target, res); err != nil {
50252		return nil, err
50253	}
50254	return ret, nil
50255	// {
50256	//   "description": "Retrieves a list of targeting templates, optionally filtered. This method supports paging.",
50257	//   "flatPath": "userprofiles/{profileId}/targetingTemplates",
50258	//   "httpMethod": "GET",
50259	//   "id": "dfareporting.targetingTemplates.list",
50260	//   "parameterOrder": [
50261	//     "profileId"
50262	//   ],
50263	//   "parameters": {
50264	//     "advertiserId": {
50265	//       "description": "Select only targeting templates with this advertiser ID.",
50266	//       "format": "int64",
50267	//       "location": "query",
50268	//       "type": "string"
50269	//     },
50270	//     "ids": {
50271	//       "description": "Select only targeting templates with these IDs.",
50272	//       "format": "int64",
50273	//       "location": "query",
50274	//       "repeated": true,
50275	//       "type": "string"
50276	//     },
50277	//     "maxResults": {
50278	//       "default": "1000",
50279	//       "description": "Maximum number of results to return.",
50280	//       "format": "int32",
50281	//       "location": "query",
50282	//       "maximum": "1000",
50283	//       "minimum": "0",
50284	//       "type": "integer"
50285	//     },
50286	//     "pageToken": {
50287	//       "description": "Value of the nextPageToken from the previous result page.",
50288	//       "location": "query",
50289	//       "type": "string"
50290	//     },
50291	//     "profileId": {
50292	//       "description": "User profile ID associated with this request.",
50293	//       "format": "int64",
50294	//       "location": "path",
50295	//       "required": true,
50296	//       "type": "string"
50297	//     },
50298	//     "searchString": {
50299	//       "description": "Allows searching for objects by name or ID. Wildcards (*) are allowed. For example, \"template*2015\" will return objects with names like \"template June 2015\", \"template April 2015\", or simply \"template 2015\". Most of the searches also add wildcards implicitly at the start and the end of the search string. For example, a search string of \"template\" will match objects with name \"my template\", \"template 2015\", or simply \"template\".",
50300	//       "location": "query",
50301	//       "type": "string"
50302	//     },
50303	//     "sortField": {
50304	//       "default": "ID",
50305	//       "description": "Field by which to sort the list.",
50306	//       "enum": [
50307	//         "ID",
50308	//         "NAME"
50309	//       ],
50310	//       "enumDescriptions": [
50311	//         "",
50312	//         ""
50313	//       ],
50314	//       "location": "query",
50315	//       "type": "string"
50316	//     },
50317	//     "sortOrder": {
50318	//       "default": "ASCENDING",
50319	//       "description": "Order of sorted results.",
50320	//       "enum": [
50321	//         "ASCENDING",
50322	//         "DESCENDING"
50323	//       ],
50324	//       "enumDescriptions": [
50325	//         "",
50326	//         ""
50327	//       ],
50328	//       "location": "query",
50329	//       "type": "string"
50330	//     }
50331	//   },
50332	//   "path": "userprofiles/{profileId}/targetingTemplates",
50333	//   "response": {
50334	//     "$ref": "TargetingTemplatesListResponse"
50335	//   },
50336	//   "scopes": [
50337	//     "https://www.googleapis.com/auth/dfatrafficking"
50338	//   ]
50339	// }
50340
50341}
50342
50343// Pages invokes f for each page of results.
50344// A non-nil error returned from f will halt the iteration.
50345// The provided context supersedes any context provided to the Context method.
50346func (c *TargetingTemplatesListCall) Pages(ctx context.Context, f func(*TargetingTemplatesListResponse) error) error {
50347	c.ctx_ = ctx
50348	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
50349	for {
50350		x, err := c.Do()
50351		if err != nil {
50352			return err
50353		}
50354		if err := f(x); err != nil {
50355			return err
50356		}
50357		if x.NextPageToken == "" {
50358			return nil
50359		}
50360		c.PageToken(x.NextPageToken)
50361	}
50362}
50363
50364// method id "dfareporting.targetingTemplates.patch":
50365
50366type TargetingTemplatesPatchCall struct {
50367	s                 *Service
50368	profileId         int64
50369	targetingtemplate *TargetingTemplate
50370	urlParams_        gensupport.URLParams
50371	ctx_              context.Context
50372	header_           http.Header
50373}
50374
50375// Patch: Updates an existing targeting template. This method supports
50376// patch semantics.
50377//
50378// - id: TargetingTemplate ID.
50379// - profileId: User profile ID associated with this request.
50380func (r *TargetingTemplatesService) Patch(profileId int64, id int64, targetingtemplate *TargetingTemplate) *TargetingTemplatesPatchCall {
50381	c := &TargetingTemplatesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
50382	c.profileId = profileId
50383	c.urlParams_.Set("id", fmt.Sprint(id))
50384	c.targetingtemplate = targetingtemplate
50385	return c
50386}
50387
50388// Fields allows partial responses to be retrieved. See
50389// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
50390// for more information.
50391func (c *TargetingTemplatesPatchCall) Fields(s ...googleapi.Field) *TargetingTemplatesPatchCall {
50392	c.urlParams_.Set("fields", googleapi.CombineFields(s))
50393	return c
50394}
50395
50396// Context sets the context to be used in this call's Do method. Any
50397// pending HTTP request will be aborted if the provided context is
50398// canceled.
50399func (c *TargetingTemplatesPatchCall) Context(ctx context.Context) *TargetingTemplatesPatchCall {
50400	c.ctx_ = ctx
50401	return c
50402}
50403
50404// Header returns an http.Header that can be modified by the caller to
50405// add HTTP headers to the request.
50406func (c *TargetingTemplatesPatchCall) Header() http.Header {
50407	if c.header_ == nil {
50408		c.header_ = make(http.Header)
50409	}
50410	return c.header_
50411}
50412
50413func (c *TargetingTemplatesPatchCall) doRequest(alt string) (*http.Response, error) {
50414	reqHeaders := make(http.Header)
50415	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
50416	for k, v := range c.header_ {
50417		reqHeaders[k] = v
50418	}
50419	reqHeaders.Set("User-Agent", c.s.userAgent())
50420	var body io.Reader = nil
50421	body, err := googleapi.WithoutDataWrapper.JSONReader(c.targetingtemplate)
50422	if err != nil {
50423		return nil, err
50424	}
50425	reqHeaders.Set("Content-Type", "application/json")
50426	c.urlParams_.Set("alt", alt)
50427	c.urlParams_.Set("prettyPrint", "false")
50428	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/targetingTemplates")
50429	urls += "?" + c.urlParams_.Encode()
50430	req, err := http.NewRequest("PATCH", urls, body)
50431	if err != nil {
50432		return nil, err
50433	}
50434	req.Header = reqHeaders
50435	googleapi.Expand(req.URL, map[string]string{
50436		"profileId": strconv.FormatInt(c.profileId, 10),
50437	})
50438	return gensupport.SendRequest(c.ctx_, c.s.client, req)
50439}
50440
50441// Do executes the "dfareporting.targetingTemplates.patch" call.
50442// Exactly one of *TargetingTemplate or error will be non-nil. Any
50443// non-2xx status code is an error. Response headers are in either
50444// *TargetingTemplate.ServerResponse.Header or (if a response was
50445// returned at all) in error.(*googleapi.Error).Header. Use
50446// googleapi.IsNotModified to check whether the returned error was
50447// because http.StatusNotModified was returned.
50448func (c *TargetingTemplatesPatchCall) Do(opts ...googleapi.CallOption) (*TargetingTemplate, error) {
50449	gensupport.SetOptions(c.urlParams_, opts...)
50450	res, err := c.doRequest("json")
50451	if res != nil && res.StatusCode == http.StatusNotModified {
50452		if res.Body != nil {
50453			res.Body.Close()
50454		}
50455		return nil, &googleapi.Error{
50456			Code:   res.StatusCode,
50457			Header: res.Header,
50458		}
50459	}
50460	if err != nil {
50461		return nil, err
50462	}
50463	defer googleapi.CloseBody(res)
50464	if err := googleapi.CheckResponse(res); err != nil {
50465		return nil, err
50466	}
50467	ret := &TargetingTemplate{
50468		ServerResponse: googleapi.ServerResponse{
50469			Header:         res.Header,
50470			HTTPStatusCode: res.StatusCode,
50471		},
50472	}
50473	target := &ret
50474	if err := gensupport.DecodeResponse(target, res); err != nil {
50475		return nil, err
50476	}
50477	return ret, nil
50478	// {
50479	//   "description": "Updates an existing targeting template. This method supports patch semantics.",
50480	//   "flatPath": "userprofiles/{profileId}/targetingTemplates",
50481	//   "httpMethod": "PATCH",
50482	//   "id": "dfareporting.targetingTemplates.patch",
50483	//   "parameterOrder": [
50484	//     "profileId",
50485	//     "id"
50486	//   ],
50487	//   "parameters": {
50488	//     "id": {
50489	//       "description": "TargetingTemplate ID.",
50490	//       "format": "int64",
50491	//       "location": "query",
50492	//       "required": true,
50493	//       "type": "string"
50494	//     },
50495	//     "profileId": {
50496	//       "description": "User profile ID associated with this request.",
50497	//       "format": "int64",
50498	//       "location": "path",
50499	//       "required": true,
50500	//       "type": "string"
50501	//     }
50502	//   },
50503	//   "path": "userprofiles/{profileId}/targetingTemplates",
50504	//   "request": {
50505	//     "$ref": "TargetingTemplate"
50506	//   },
50507	//   "response": {
50508	//     "$ref": "TargetingTemplate"
50509	//   },
50510	//   "scopes": [
50511	//     "https://www.googleapis.com/auth/dfatrafficking"
50512	//   ]
50513	// }
50514
50515}
50516
50517// method id "dfareporting.targetingTemplates.update":
50518
50519type TargetingTemplatesUpdateCall struct {
50520	s                 *Service
50521	profileId         int64
50522	targetingtemplate *TargetingTemplate
50523	urlParams_        gensupport.URLParams
50524	ctx_              context.Context
50525	header_           http.Header
50526}
50527
50528// Update: Updates an existing targeting template.
50529//
50530// - profileId: User profile ID associated with this request.
50531func (r *TargetingTemplatesService) Update(profileId int64, targetingtemplate *TargetingTemplate) *TargetingTemplatesUpdateCall {
50532	c := &TargetingTemplatesUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
50533	c.profileId = profileId
50534	c.targetingtemplate = targetingtemplate
50535	return c
50536}
50537
50538// Fields allows partial responses to be retrieved. See
50539// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
50540// for more information.
50541func (c *TargetingTemplatesUpdateCall) Fields(s ...googleapi.Field) *TargetingTemplatesUpdateCall {
50542	c.urlParams_.Set("fields", googleapi.CombineFields(s))
50543	return c
50544}
50545
50546// Context sets the context to be used in this call's Do method. Any
50547// pending HTTP request will be aborted if the provided context is
50548// canceled.
50549func (c *TargetingTemplatesUpdateCall) Context(ctx context.Context) *TargetingTemplatesUpdateCall {
50550	c.ctx_ = ctx
50551	return c
50552}
50553
50554// Header returns an http.Header that can be modified by the caller to
50555// add HTTP headers to the request.
50556func (c *TargetingTemplatesUpdateCall) Header() http.Header {
50557	if c.header_ == nil {
50558		c.header_ = make(http.Header)
50559	}
50560	return c.header_
50561}
50562
50563func (c *TargetingTemplatesUpdateCall) doRequest(alt string) (*http.Response, error) {
50564	reqHeaders := make(http.Header)
50565	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
50566	for k, v := range c.header_ {
50567		reqHeaders[k] = v
50568	}
50569	reqHeaders.Set("User-Agent", c.s.userAgent())
50570	var body io.Reader = nil
50571	body, err := googleapi.WithoutDataWrapper.JSONReader(c.targetingtemplate)
50572	if err != nil {
50573		return nil, err
50574	}
50575	reqHeaders.Set("Content-Type", "application/json")
50576	c.urlParams_.Set("alt", alt)
50577	c.urlParams_.Set("prettyPrint", "false")
50578	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/targetingTemplates")
50579	urls += "?" + c.urlParams_.Encode()
50580	req, err := http.NewRequest("PUT", urls, body)
50581	if err != nil {
50582		return nil, err
50583	}
50584	req.Header = reqHeaders
50585	googleapi.Expand(req.URL, map[string]string{
50586		"profileId": strconv.FormatInt(c.profileId, 10),
50587	})
50588	return gensupport.SendRequest(c.ctx_, c.s.client, req)
50589}
50590
50591// Do executes the "dfareporting.targetingTemplates.update" call.
50592// Exactly one of *TargetingTemplate or error will be non-nil. Any
50593// non-2xx status code is an error. Response headers are in either
50594// *TargetingTemplate.ServerResponse.Header or (if a response was
50595// returned at all) in error.(*googleapi.Error).Header. Use
50596// googleapi.IsNotModified to check whether the returned error was
50597// because http.StatusNotModified was returned.
50598func (c *TargetingTemplatesUpdateCall) Do(opts ...googleapi.CallOption) (*TargetingTemplate, error) {
50599	gensupport.SetOptions(c.urlParams_, opts...)
50600	res, err := c.doRequest("json")
50601	if res != nil && res.StatusCode == http.StatusNotModified {
50602		if res.Body != nil {
50603			res.Body.Close()
50604		}
50605		return nil, &googleapi.Error{
50606			Code:   res.StatusCode,
50607			Header: res.Header,
50608		}
50609	}
50610	if err != nil {
50611		return nil, err
50612	}
50613	defer googleapi.CloseBody(res)
50614	if err := googleapi.CheckResponse(res); err != nil {
50615		return nil, err
50616	}
50617	ret := &TargetingTemplate{
50618		ServerResponse: googleapi.ServerResponse{
50619			Header:         res.Header,
50620			HTTPStatusCode: res.StatusCode,
50621		},
50622	}
50623	target := &ret
50624	if err := gensupport.DecodeResponse(target, res); err != nil {
50625		return nil, err
50626	}
50627	return ret, nil
50628	// {
50629	//   "description": "Updates an existing targeting template.",
50630	//   "flatPath": "userprofiles/{profileId}/targetingTemplates",
50631	//   "httpMethod": "PUT",
50632	//   "id": "dfareporting.targetingTemplates.update",
50633	//   "parameterOrder": [
50634	//     "profileId"
50635	//   ],
50636	//   "parameters": {
50637	//     "profileId": {
50638	//       "description": "User profile ID associated with this request.",
50639	//       "format": "int64",
50640	//       "location": "path",
50641	//       "required": true,
50642	//       "type": "string"
50643	//     }
50644	//   },
50645	//   "path": "userprofiles/{profileId}/targetingTemplates",
50646	//   "request": {
50647	//     "$ref": "TargetingTemplate"
50648	//   },
50649	//   "response": {
50650	//     "$ref": "TargetingTemplate"
50651	//   },
50652	//   "scopes": [
50653	//     "https://www.googleapis.com/auth/dfatrafficking"
50654	//   ]
50655	// }
50656
50657}
50658
50659// method id "dfareporting.userProfiles.get":
50660
50661type UserProfilesGetCall struct {
50662	s            *Service
50663	profileId    int64
50664	urlParams_   gensupport.URLParams
50665	ifNoneMatch_ string
50666	ctx_         context.Context
50667	header_      http.Header
50668}
50669
50670// Get: Gets one user profile by ID.
50671//
50672// - profileId: The user profile ID.
50673func (r *UserProfilesService) Get(profileId int64) *UserProfilesGetCall {
50674	c := &UserProfilesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
50675	c.profileId = profileId
50676	return c
50677}
50678
50679// Fields allows partial responses to be retrieved. See
50680// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
50681// for more information.
50682func (c *UserProfilesGetCall) Fields(s ...googleapi.Field) *UserProfilesGetCall {
50683	c.urlParams_.Set("fields", googleapi.CombineFields(s))
50684	return c
50685}
50686
50687// IfNoneMatch sets the optional parameter which makes the operation
50688// fail if the object's ETag matches the given value. This is useful for
50689// getting updates only after the object has changed since the last
50690// request. Use googleapi.IsNotModified to check whether the response
50691// error from Do is the result of In-None-Match.
50692func (c *UserProfilesGetCall) IfNoneMatch(entityTag string) *UserProfilesGetCall {
50693	c.ifNoneMatch_ = entityTag
50694	return c
50695}
50696
50697// Context sets the context to be used in this call's Do method. Any
50698// pending HTTP request will be aborted if the provided context is
50699// canceled.
50700func (c *UserProfilesGetCall) Context(ctx context.Context) *UserProfilesGetCall {
50701	c.ctx_ = ctx
50702	return c
50703}
50704
50705// Header returns an http.Header that can be modified by the caller to
50706// add HTTP headers to the request.
50707func (c *UserProfilesGetCall) Header() http.Header {
50708	if c.header_ == nil {
50709		c.header_ = make(http.Header)
50710	}
50711	return c.header_
50712}
50713
50714func (c *UserProfilesGetCall) doRequest(alt string) (*http.Response, error) {
50715	reqHeaders := make(http.Header)
50716	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
50717	for k, v := range c.header_ {
50718		reqHeaders[k] = v
50719	}
50720	reqHeaders.Set("User-Agent", c.s.userAgent())
50721	if c.ifNoneMatch_ != "" {
50722		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
50723	}
50724	var body io.Reader = nil
50725	c.urlParams_.Set("alt", alt)
50726	c.urlParams_.Set("prettyPrint", "false")
50727	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}")
50728	urls += "?" + c.urlParams_.Encode()
50729	req, err := http.NewRequest("GET", urls, body)
50730	if err != nil {
50731		return nil, err
50732	}
50733	req.Header = reqHeaders
50734	googleapi.Expand(req.URL, map[string]string{
50735		"profileId": strconv.FormatInt(c.profileId, 10),
50736	})
50737	return gensupport.SendRequest(c.ctx_, c.s.client, req)
50738}
50739
50740// Do executes the "dfareporting.userProfiles.get" call.
50741// Exactly one of *UserProfile or error will be non-nil. Any non-2xx
50742// status code is an error. Response headers are in either
50743// *UserProfile.ServerResponse.Header or (if a response was returned at
50744// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
50745// to check whether the returned error was because
50746// http.StatusNotModified was returned.
50747func (c *UserProfilesGetCall) Do(opts ...googleapi.CallOption) (*UserProfile, error) {
50748	gensupport.SetOptions(c.urlParams_, opts...)
50749	res, err := c.doRequest("json")
50750	if res != nil && res.StatusCode == http.StatusNotModified {
50751		if res.Body != nil {
50752			res.Body.Close()
50753		}
50754		return nil, &googleapi.Error{
50755			Code:   res.StatusCode,
50756			Header: res.Header,
50757		}
50758	}
50759	if err != nil {
50760		return nil, err
50761	}
50762	defer googleapi.CloseBody(res)
50763	if err := googleapi.CheckResponse(res); err != nil {
50764		return nil, err
50765	}
50766	ret := &UserProfile{
50767		ServerResponse: googleapi.ServerResponse{
50768			Header:         res.Header,
50769			HTTPStatusCode: res.StatusCode,
50770		},
50771	}
50772	target := &ret
50773	if err := gensupport.DecodeResponse(target, res); err != nil {
50774		return nil, err
50775	}
50776	return ret, nil
50777	// {
50778	//   "description": "Gets one user profile by ID.",
50779	//   "flatPath": "userprofiles/{profileId}",
50780	//   "httpMethod": "GET",
50781	//   "id": "dfareporting.userProfiles.get",
50782	//   "parameterOrder": [
50783	//     "profileId"
50784	//   ],
50785	//   "parameters": {
50786	//     "profileId": {
50787	//       "description": "The user profile ID.",
50788	//       "format": "int64",
50789	//       "location": "path",
50790	//       "required": true,
50791	//       "type": "string"
50792	//     }
50793	//   },
50794	//   "path": "userprofiles/{profileId}",
50795	//   "response": {
50796	//     "$ref": "UserProfile"
50797	//   },
50798	//   "scopes": [
50799	//     "https://www.googleapis.com/auth/ddmconversions",
50800	//     "https://www.googleapis.com/auth/dfareporting",
50801	//     "https://www.googleapis.com/auth/dfatrafficking"
50802	//   ]
50803	// }
50804
50805}
50806
50807// method id "dfareporting.userProfiles.list":
50808
50809type UserProfilesListCall struct {
50810	s            *Service
50811	urlParams_   gensupport.URLParams
50812	ifNoneMatch_ string
50813	ctx_         context.Context
50814	header_      http.Header
50815}
50816
50817// List: Retrieves list of user profiles for a user.
50818func (r *UserProfilesService) List() *UserProfilesListCall {
50819	c := &UserProfilesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
50820	return c
50821}
50822
50823// Fields allows partial responses to be retrieved. See
50824// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
50825// for more information.
50826func (c *UserProfilesListCall) Fields(s ...googleapi.Field) *UserProfilesListCall {
50827	c.urlParams_.Set("fields", googleapi.CombineFields(s))
50828	return c
50829}
50830
50831// IfNoneMatch sets the optional parameter which makes the operation
50832// fail if the object's ETag matches the given value. This is useful for
50833// getting updates only after the object has changed since the last
50834// request. Use googleapi.IsNotModified to check whether the response
50835// error from Do is the result of In-None-Match.
50836func (c *UserProfilesListCall) IfNoneMatch(entityTag string) *UserProfilesListCall {
50837	c.ifNoneMatch_ = entityTag
50838	return c
50839}
50840
50841// Context sets the context to be used in this call's Do method. Any
50842// pending HTTP request will be aborted if the provided context is
50843// canceled.
50844func (c *UserProfilesListCall) Context(ctx context.Context) *UserProfilesListCall {
50845	c.ctx_ = ctx
50846	return c
50847}
50848
50849// Header returns an http.Header that can be modified by the caller to
50850// add HTTP headers to the request.
50851func (c *UserProfilesListCall) Header() http.Header {
50852	if c.header_ == nil {
50853		c.header_ = make(http.Header)
50854	}
50855	return c.header_
50856}
50857
50858func (c *UserProfilesListCall) doRequest(alt string) (*http.Response, error) {
50859	reqHeaders := make(http.Header)
50860	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
50861	for k, v := range c.header_ {
50862		reqHeaders[k] = v
50863	}
50864	reqHeaders.Set("User-Agent", c.s.userAgent())
50865	if c.ifNoneMatch_ != "" {
50866		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
50867	}
50868	var body io.Reader = nil
50869	c.urlParams_.Set("alt", alt)
50870	c.urlParams_.Set("prettyPrint", "false")
50871	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles")
50872	urls += "?" + c.urlParams_.Encode()
50873	req, err := http.NewRequest("GET", urls, body)
50874	if err != nil {
50875		return nil, err
50876	}
50877	req.Header = reqHeaders
50878	return gensupport.SendRequest(c.ctx_, c.s.client, req)
50879}
50880
50881// Do executes the "dfareporting.userProfiles.list" call.
50882// Exactly one of *UserProfileList or error will be non-nil. Any non-2xx
50883// status code is an error. Response headers are in either
50884// *UserProfileList.ServerResponse.Header or (if a response was returned
50885// at all) in error.(*googleapi.Error).Header. Use
50886// googleapi.IsNotModified to check whether the returned error was
50887// because http.StatusNotModified was returned.
50888func (c *UserProfilesListCall) Do(opts ...googleapi.CallOption) (*UserProfileList, error) {
50889	gensupport.SetOptions(c.urlParams_, opts...)
50890	res, err := c.doRequest("json")
50891	if res != nil && res.StatusCode == http.StatusNotModified {
50892		if res.Body != nil {
50893			res.Body.Close()
50894		}
50895		return nil, &googleapi.Error{
50896			Code:   res.StatusCode,
50897			Header: res.Header,
50898		}
50899	}
50900	if err != nil {
50901		return nil, err
50902	}
50903	defer googleapi.CloseBody(res)
50904	if err := googleapi.CheckResponse(res); err != nil {
50905		return nil, err
50906	}
50907	ret := &UserProfileList{
50908		ServerResponse: googleapi.ServerResponse{
50909			Header:         res.Header,
50910			HTTPStatusCode: res.StatusCode,
50911		},
50912	}
50913	target := &ret
50914	if err := gensupport.DecodeResponse(target, res); err != nil {
50915		return nil, err
50916	}
50917	return ret, nil
50918	// {
50919	//   "description": "Retrieves list of user profiles for a user.",
50920	//   "flatPath": "userprofiles",
50921	//   "httpMethod": "GET",
50922	//   "id": "dfareporting.userProfiles.list",
50923	//   "parameterOrder": [],
50924	//   "parameters": {},
50925	//   "path": "userprofiles",
50926	//   "response": {
50927	//     "$ref": "UserProfileList"
50928	//   },
50929	//   "scopes": [
50930	//     "https://www.googleapis.com/auth/ddmconversions",
50931	//     "https://www.googleapis.com/auth/dfareporting",
50932	//     "https://www.googleapis.com/auth/dfatrafficking"
50933	//   ]
50934	// }
50935
50936}
50937
50938// method id "dfareporting.userRolePermissionGroups.get":
50939
50940type UserRolePermissionGroupsGetCall struct {
50941	s            *Service
50942	profileId    int64
50943	id           int64
50944	urlParams_   gensupport.URLParams
50945	ifNoneMatch_ string
50946	ctx_         context.Context
50947	header_      http.Header
50948}
50949
50950// Get: Gets one user role permission group by ID.
50951//
50952// - id: User role permission group ID.
50953// - profileId: User profile ID associated with this request.
50954func (r *UserRolePermissionGroupsService) Get(profileId int64, id int64) *UserRolePermissionGroupsGetCall {
50955	c := &UserRolePermissionGroupsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
50956	c.profileId = profileId
50957	c.id = id
50958	return c
50959}
50960
50961// Fields allows partial responses to be retrieved. See
50962// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
50963// for more information.
50964func (c *UserRolePermissionGroupsGetCall) Fields(s ...googleapi.Field) *UserRolePermissionGroupsGetCall {
50965	c.urlParams_.Set("fields", googleapi.CombineFields(s))
50966	return c
50967}
50968
50969// IfNoneMatch sets the optional parameter which makes the operation
50970// fail if the object's ETag matches the given value. This is useful for
50971// getting updates only after the object has changed since the last
50972// request. Use googleapi.IsNotModified to check whether the response
50973// error from Do is the result of In-None-Match.
50974func (c *UserRolePermissionGroupsGetCall) IfNoneMatch(entityTag string) *UserRolePermissionGroupsGetCall {
50975	c.ifNoneMatch_ = entityTag
50976	return c
50977}
50978
50979// Context sets the context to be used in this call's Do method. Any
50980// pending HTTP request will be aborted if the provided context is
50981// canceled.
50982func (c *UserRolePermissionGroupsGetCall) Context(ctx context.Context) *UserRolePermissionGroupsGetCall {
50983	c.ctx_ = ctx
50984	return c
50985}
50986
50987// Header returns an http.Header that can be modified by the caller to
50988// add HTTP headers to the request.
50989func (c *UserRolePermissionGroupsGetCall) Header() http.Header {
50990	if c.header_ == nil {
50991		c.header_ = make(http.Header)
50992	}
50993	return c.header_
50994}
50995
50996func (c *UserRolePermissionGroupsGetCall) doRequest(alt string) (*http.Response, error) {
50997	reqHeaders := make(http.Header)
50998	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
50999	for k, v := range c.header_ {
51000		reqHeaders[k] = v
51001	}
51002	reqHeaders.Set("User-Agent", c.s.userAgent())
51003	if c.ifNoneMatch_ != "" {
51004		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
51005	}
51006	var body io.Reader = nil
51007	c.urlParams_.Set("alt", alt)
51008	c.urlParams_.Set("prettyPrint", "false")
51009	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/userRolePermissionGroups/{id}")
51010	urls += "?" + c.urlParams_.Encode()
51011	req, err := http.NewRequest("GET", urls, body)
51012	if err != nil {
51013		return nil, err
51014	}
51015	req.Header = reqHeaders
51016	googleapi.Expand(req.URL, map[string]string{
51017		"profileId": strconv.FormatInt(c.profileId, 10),
51018		"id":        strconv.FormatInt(c.id, 10),
51019	})
51020	return gensupport.SendRequest(c.ctx_, c.s.client, req)
51021}
51022
51023// Do executes the "dfareporting.userRolePermissionGroups.get" call.
51024// Exactly one of *UserRolePermissionGroup or error will be non-nil. Any
51025// non-2xx status code is an error. Response headers are in either
51026// *UserRolePermissionGroup.ServerResponse.Header or (if a response was
51027// returned at all) in error.(*googleapi.Error).Header. Use
51028// googleapi.IsNotModified to check whether the returned error was
51029// because http.StatusNotModified was returned.
51030func (c *UserRolePermissionGroupsGetCall) Do(opts ...googleapi.CallOption) (*UserRolePermissionGroup, error) {
51031	gensupport.SetOptions(c.urlParams_, opts...)
51032	res, err := c.doRequest("json")
51033	if res != nil && res.StatusCode == http.StatusNotModified {
51034		if res.Body != nil {
51035			res.Body.Close()
51036		}
51037		return nil, &googleapi.Error{
51038			Code:   res.StatusCode,
51039			Header: res.Header,
51040		}
51041	}
51042	if err != nil {
51043		return nil, err
51044	}
51045	defer googleapi.CloseBody(res)
51046	if err := googleapi.CheckResponse(res); err != nil {
51047		return nil, err
51048	}
51049	ret := &UserRolePermissionGroup{
51050		ServerResponse: googleapi.ServerResponse{
51051			Header:         res.Header,
51052			HTTPStatusCode: res.StatusCode,
51053		},
51054	}
51055	target := &ret
51056	if err := gensupport.DecodeResponse(target, res); err != nil {
51057		return nil, err
51058	}
51059	return ret, nil
51060	// {
51061	//   "description": "Gets one user role permission group by ID.",
51062	//   "flatPath": "userprofiles/{profileId}/userRolePermissionGroups/{id}",
51063	//   "httpMethod": "GET",
51064	//   "id": "dfareporting.userRolePermissionGroups.get",
51065	//   "parameterOrder": [
51066	//     "profileId",
51067	//     "id"
51068	//   ],
51069	//   "parameters": {
51070	//     "id": {
51071	//       "description": "User role permission group ID.",
51072	//       "format": "int64",
51073	//       "location": "path",
51074	//       "required": true,
51075	//       "type": "string"
51076	//     },
51077	//     "profileId": {
51078	//       "description": "User profile ID associated with this request.",
51079	//       "format": "int64",
51080	//       "location": "path",
51081	//       "required": true,
51082	//       "type": "string"
51083	//     }
51084	//   },
51085	//   "path": "userprofiles/{profileId}/userRolePermissionGroups/{id}",
51086	//   "response": {
51087	//     "$ref": "UserRolePermissionGroup"
51088	//   },
51089	//   "scopes": [
51090	//     "https://www.googleapis.com/auth/dfatrafficking"
51091	//   ]
51092	// }
51093
51094}
51095
51096// method id "dfareporting.userRolePermissionGroups.list":
51097
51098type UserRolePermissionGroupsListCall struct {
51099	s            *Service
51100	profileId    int64
51101	urlParams_   gensupport.URLParams
51102	ifNoneMatch_ string
51103	ctx_         context.Context
51104	header_      http.Header
51105}
51106
51107// List: Gets a list of all supported user role permission groups.
51108//
51109// - profileId: User profile ID associated with this request.
51110func (r *UserRolePermissionGroupsService) List(profileId int64) *UserRolePermissionGroupsListCall {
51111	c := &UserRolePermissionGroupsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
51112	c.profileId = profileId
51113	return c
51114}
51115
51116// Fields allows partial responses to be retrieved. See
51117// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
51118// for more information.
51119func (c *UserRolePermissionGroupsListCall) Fields(s ...googleapi.Field) *UserRolePermissionGroupsListCall {
51120	c.urlParams_.Set("fields", googleapi.CombineFields(s))
51121	return c
51122}
51123
51124// IfNoneMatch sets the optional parameter which makes the operation
51125// fail if the object's ETag matches the given value. This is useful for
51126// getting updates only after the object has changed since the last
51127// request. Use googleapi.IsNotModified to check whether the response
51128// error from Do is the result of In-None-Match.
51129func (c *UserRolePermissionGroupsListCall) IfNoneMatch(entityTag string) *UserRolePermissionGroupsListCall {
51130	c.ifNoneMatch_ = entityTag
51131	return c
51132}
51133
51134// Context sets the context to be used in this call's Do method. Any
51135// pending HTTP request will be aborted if the provided context is
51136// canceled.
51137func (c *UserRolePermissionGroupsListCall) Context(ctx context.Context) *UserRolePermissionGroupsListCall {
51138	c.ctx_ = ctx
51139	return c
51140}
51141
51142// Header returns an http.Header that can be modified by the caller to
51143// add HTTP headers to the request.
51144func (c *UserRolePermissionGroupsListCall) Header() http.Header {
51145	if c.header_ == nil {
51146		c.header_ = make(http.Header)
51147	}
51148	return c.header_
51149}
51150
51151func (c *UserRolePermissionGroupsListCall) doRequest(alt string) (*http.Response, error) {
51152	reqHeaders := make(http.Header)
51153	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
51154	for k, v := range c.header_ {
51155		reqHeaders[k] = v
51156	}
51157	reqHeaders.Set("User-Agent", c.s.userAgent())
51158	if c.ifNoneMatch_ != "" {
51159		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
51160	}
51161	var body io.Reader = nil
51162	c.urlParams_.Set("alt", alt)
51163	c.urlParams_.Set("prettyPrint", "false")
51164	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/userRolePermissionGroups")
51165	urls += "?" + c.urlParams_.Encode()
51166	req, err := http.NewRequest("GET", urls, body)
51167	if err != nil {
51168		return nil, err
51169	}
51170	req.Header = reqHeaders
51171	googleapi.Expand(req.URL, map[string]string{
51172		"profileId": strconv.FormatInt(c.profileId, 10),
51173	})
51174	return gensupport.SendRequest(c.ctx_, c.s.client, req)
51175}
51176
51177// Do executes the "dfareporting.userRolePermissionGroups.list" call.
51178// Exactly one of *UserRolePermissionGroupsListResponse or error will be
51179// non-nil. Any non-2xx status code is an error. Response headers are in
51180// either *UserRolePermissionGroupsListResponse.ServerResponse.Header or
51181// (if a response was returned at all) in
51182// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
51183// whether the returned error was because http.StatusNotModified was
51184// returned.
51185func (c *UserRolePermissionGroupsListCall) Do(opts ...googleapi.CallOption) (*UserRolePermissionGroupsListResponse, error) {
51186	gensupport.SetOptions(c.urlParams_, opts...)
51187	res, err := c.doRequest("json")
51188	if res != nil && res.StatusCode == http.StatusNotModified {
51189		if res.Body != nil {
51190			res.Body.Close()
51191		}
51192		return nil, &googleapi.Error{
51193			Code:   res.StatusCode,
51194			Header: res.Header,
51195		}
51196	}
51197	if err != nil {
51198		return nil, err
51199	}
51200	defer googleapi.CloseBody(res)
51201	if err := googleapi.CheckResponse(res); err != nil {
51202		return nil, err
51203	}
51204	ret := &UserRolePermissionGroupsListResponse{
51205		ServerResponse: googleapi.ServerResponse{
51206			Header:         res.Header,
51207			HTTPStatusCode: res.StatusCode,
51208		},
51209	}
51210	target := &ret
51211	if err := gensupport.DecodeResponse(target, res); err != nil {
51212		return nil, err
51213	}
51214	return ret, nil
51215	// {
51216	//   "description": "Gets a list of all supported user role permission groups.",
51217	//   "flatPath": "userprofiles/{profileId}/userRolePermissionGroups",
51218	//   "httpMethod": "GET",
51219	//   "id": "dfareporting.userRolePermissionGroups.list",
51220	//   "parameterOrder": [
51221	//     "profileId"
51222	//   ],
51223	//   "parameters": {
51224	//     "profileId": {
51225	//       "description": "User profile ID associated with this request.",
51226	//       "format": "int64",
51227	//       "location": "path",
51228	//       "required": true,
51229	//       "type": "string"
51230	//     }
51231	//   },
51232	//   "path": "userprofiles/{profileId}/userRolePermissionGroups",
51233	//   "response": {
51234	//     "$ref": "UserRolePermissionGroupsListResponse"
51235	//   },
51236	//   "scopes": [
51237	//     "https://www.googleapis.com/auth/dfatrafficking"
51238	//   ]
51239	// }
51240
51241}
51242
51243// method id "dfareporting.userRolePermissions.get":
51244
51245type UserRolePermissionsGetCall struct {
51246	s            *Service
51247	profileId    int64
51248	id           int64
51249	urlParams_   gensupport.URLParams
51250	ifNoneMatch_ string
51251	ctx_         context.Context
51252	header_      http.Header
51253}
51254
51255// Get: Gets one user role permission by ID.
51256//
51257// - id: User role permission ID.
51258// - profileId: User profile ID associated with this request.
51259func (r *UserRolePermissionsService) Get(profileId int64, id int64) *UserRolePermissionsGetCall {
51260	c := &UserRolePermissionsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
51261	c.profileId = profileId
51262	c.id = id
51263	return c
51264}
51265
51266// Fields allows partial responses to be retrieved. See
51267// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
51268// for more information.
51269func (c *UserRolePermissionsGetCall) Fields(s ...googleapi.Field) *UserRolePermissionsGetCall {
51270	c.urlParams_.Set("fields", googleapi.CombineFields(s))
51271	return c
51272}
51273
51274// IfNoneMatch sets the optional parameter which makes the operation
51275// fail if the object's ETag matches the given value. This is useful for
51276// getting updates only after the object has changed since the last
51277// request. Use googleapi.IsNotModified to check whether the response
51278// error from Do is the result of In-None-Match.
51279func (c *UserRolePermissionsGetCall) IfNoneMatch(entityTag string) *UserRolePermissionsGetCall {
51280	c.ifNoneMatch_ = entityTag
51281	return c
51282}
51283
51284// Context sets the context to be used in this call's Do method. Any
51285// pending HTTP request will be aborted if the provided context is
51286// canceled.
51287func (c *UserRolePermissionsGetCall) Context(ctx context.Context) *UserRolePermissionsGetCall {
51288	c.ctx_ = ctx
51289	return c
51290}
51291
51292// Header returns an http.Header that can be modified by the caller to
51293// add HTTP headers to the request.
51294func (c *UserRolePermissionsGetCall) Header() http.Header {
51295	if c.header_ == nil {
51296		c.header_ = make(http.Header)
51297	}
51298	return c.header_
51299}
51300
51301func (c *UserRolePermissionsGetCall) doRequest(alt string) (*http.Response, error) {
51302	reqHeaders := make(http.Header)
51303	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
51304	for k, v := range c.header_ {
51305		reqHeaders[k] = v
51306	}
51307	reqHeaders.Set("User-Agent", c.s.userAgent())
51308	if c.ifNoneMatch_ != "" {
51309		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
51310	}
51311	var body io.Reader = nil
51312	c.urlParams_.Set("alt", alt)
51313	c.urlParams_.Set("prettyPrint", "false")
51314	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/userRolePermissions/{id}")
51315	urls += "?" + c.urlParams_.Encode()
51316	req, err := http.NewRequest("GET", urls, body)
51317	if err != nil {
51318		return nil, err
51319	}
51320	req.Header = reqHeaders
51321	googleapi.Expand(req.URL, map[string]string{
51322		"profileId": strconv.FormatInt(c.profileId, 10),
51323		"id":        strconv.FormatInt(c.id, 10),
51324	})
51325	return gensupport.SendRequest(c.ctx_, c.s.client, req)
51326}
51327
51328// Do executes the "dfareporting.userRolePermissions.get" call.
51329// Exactly one of *UserRolePermission or error will be non-nil. Any
51330// non-2xx status code is an error. Response headers are in either
51331// *UserRolePermission.ServerResponse.Header or (if a response was
51332// returned at all) in error.(*googleapi.Error).Header. Use
51333// googleapi.IsNotModified to check whether the returned error was
51334// because http.StatusNotModified was returned.
51335func (c *UserRolePermissionsGetCall) Do(opts ...googleapi.CallOption) (*UserRolePermission, error) {
51336	gensupport.SetOptions(c.urlParams_, opts...)
51337	res, err := c.doRequest("json")
51338	if res != nil && res.StatusCode == http.StatusNotModified {
51339		if res.Body != nil {
51340			res.Body.Close()
51341		}
51342		return nil, &googleapi.Error{
51343			Code:   res.StatusCode,
51344			Header: res.Header,
51345		}
51346	}
51347	if err != nil {
51348		return nil, err
51349	}
51350	defer googleapi.CloseBody(res)
51351	if err := googleapi.CheckResponse(res); err != nil {
51352		return nil, err
51353	}
51354	ret := &UserRolePermission{
51355		ServerResponse: googleapi.ServerResponse{
51356			Header:         res.Header,
51357			HTTPStatusCode: res.StatusCode,
51358		},
51359	}
51360	target := &ret
51361	if err := gensupport.DecodeResponse(target, res); err != nil {
51362		return nil, err
51363	}
51364	return ret, nil
51365	// {
51366	//   "description": "Gets one user role permission by ID.",
51367	//   "flatPath": "userprofiles/{profileId}/userRolePermissions/{id}",
51368	//   "httpMethod": "GET",
51369	//   "id": "dfareporting.userRolePermissions.get",
51370	//   "parameterOrder": [
51371	//     "profileId",
51372	//     "id"
51373	//   ],
51374	//   "parameters": {
51375	//     "id": {
51376	//       "description": "User role permission ID.",
51377	//       "format": "int64",
51378	//       "location": "path",
51379	//       "required": true,
51380	//       "type": "string"
51381	//     },
51382	//     "profileId": {
51383	//       "description": "User profile ID associated with this request.",
51384	//       "format": "int64",
51385	//       "location": "path",
51386	//       "required": true,
51387	//       "type": "string"
51388	//     }
51389	//   },
51390	//   "path": "userprofiles/{profileId}/userRolePermissions/{id}",
51391	//   "response": {
51392	//     "$ref": "UserRolePermission"
51393	//   },
51394	//   "scopes": [
51395	//     "https://www.googleapis.com/auth/dfatrafficking"
51396	//   ]
51397	// }
51398
51399}
51400
51401// method id "dfareporting.userRolePermissions.list":
51402
51403type UserRolePermissionsListCall struct {
51404	s            *Service
51405	profileId    int64
51406	urlParams_   gensupport.URLParams
51407	ifNoneMatch_ string
51408	ctx_         context.Context
51409	header_      http.Header
51410}
51411
51412// List: Gets a list of user role permissions, possibly filtered.
51413//
51414// - profileId: User profile ID associated with this request.
51415func (r *UserRolePermissionsService) List(profileId int64) *UserRolePermissionsListCall {
51416	c := &UserRolePermissionsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
51417	c.profileId = profileId
51418	return c
51419}
51420
51421// Ids sets the optional parameter "ids": Select only user role
51422// permissions with these IDs.
51423func (c *UserRolePermissionsListCall) Ids(ids ...int64) *UserRolePermissionsListCall {
51424	var ids_ []string
51425	for _, v := range ids {
51426		ids_ = append(ids_, fmt.Sprint(v))
51427	}
51428	c.urlParams_.SetMulti("ids", ids_)
51429	return c
51430}
51431
51432// Fields allows partial responses to be retrieved. See
51433// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
51434// for more information.
51435func (c *UserRolePermissionsListCall) Fields(s ...googleapi.Field) *UserRolePermissionsListCall {
51436	c.urlParams_.Set("fields", googleapi.CombineFields(s))
51437	return c
51438}
51439
51440// IfNoneMatch sets the optional parameter which makes the operation
51441// fail if the object's ETag matches the given value. This is useful for
51442// getting updates only after the object has changed since the last
51443// request. Use googleapi.IsNotModified to check whether the response
51444// error from Do is the result of In-None-Match.
51445func (c *UserRolePermissionsListCall) IfNoneMatch(entityTag string) *UserRolePermissionsListCall {
51446	c.ifNoneMatch_ = entityTag
51447	return c
51448}
51449
51450// Context sets the context to be used in this call's Do method. Any
51451// pending HTTP request will be aborted if the provided context is
51452// canceled.
51453func (c *UserRolePermissionsListCall) Context(ctx context.Context) *UserRolePermissionsListCall {
51454	c.ctx_ = ctx
51455	return c
51456}
51457
51458// Header returns an http.Header that can be modified by the caller to
51459// add HTTP headers to the request.
51460func (c *UserRolePermissionsListCall) Header() http.Header {
51461	if c.header_ == nil {
51462		c.header_ = make(http.Header)
51463	}
51464	return c.header_
51465}
51466
51467func (c *UserRolePermissionsListCall) doRequest(alt string) (*http.Response, error) {
51468	reqHeaders := make(http.Header)
51469	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
51470	for k, v := range c.header_ {
51471		reqHeaders[k] = v
51472	}
51473	reqHeaders.Set("User-Agent", c.s.userAgent())
51474	if c.ifNoneMatch_ != "" {
51475		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
51476	}
51477	var body io.Reader = nil
51478	c.urlParams_.Set("alt", alt)
51479	c.urlParams_.Set("prettyPrint", "false")
51480	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/userRolePermissions")
51481	urls += "?" + c.urlParams_.Encode()
51482	req, err := http.NewRequest("GET", urls, body)
51483	if err != nil {
51484		return nil, err
51485	}
51486	req.Header = reqHeaders
51487	googleapi.Expand(req.URL, map[string]string{
51488		"profileId": strconv.FormatInt(c.profileId, 10),
51489	})
51490	return gensupport.SendRequest(c.ctx_, c.s.client, req)
51491}
51492
51493// Do executes the "dfareporting.userRolePermissions.list" call.
51494// Exactly one of *UserRolePermissionsListResponse or error will be
51495// non-nil. Any non-2xx status code is an error. Response headers are in
51496// either *UserRolePermissionsListResponse.ServerResponse.Header or (if
51497// a response was returned at all) in error.(*googleapi.Error).Header.
51498// Use googleapi.IsNotModified to check whether the returned error was
51499// because http.StatusNotModified was returned.
51500func (c *UserRolePermissionsListCall) Do(opts ...googleapi.CallOption) (*UserRolePermissionsListResponse, error) {
51501	gensupport.SetOptions(c.urlParams_, opts...)
51502	res, err := c.doRequest("json")
51503	if res != nil && res.StatusCode == http.StatusNotModified {
51504		if res.Body != nil {
51505			res.Body.Close()
51506		}
51507		return nil, &googleapi.Error{
51508			Code:   res.StatusCode,
51509			Header: res.Header,
51510		}
51511	}
51512	if err != nil {
51513		return nil, err
51514	}
51515	defer googleapi.CloseBody(res)
51516	if err := googleapi.CheckResponse(res); err != nil {
51517		return nil, err
51518	}
51519	ret := &UserRolePermissionsListResponse{
51520		ServerResponse: googleapi.ServerResponse{
51521			Header:         res.Header,
51522			HTTPStatusCode: res.StatusCode,
51523		},
51524	}
51525	target := &ret
51526	if err := gensupport.DecodeResponse(target, res); err != nil {
51527		return nil, err
51528	}
51529	return ret, nil
51530	// {
51531	//   "description": "Gets a list of user role permissions, possibly filtered.",
51532	//   "flatPath": "userprofiles/{profileId}/userRolePermissions",
51533	//   "httpMethod": "GET",
51534	//   "id": "dfareporting.userRolePermissions.list",
51535	//   "parameterOrder": [
51536	//     "profileId"
51537	//   ],
51538	//   "parameters": {
51539	//     "ids": {
51540	//       "description": "Select only user role permissions with these IDs.",
51541	//       "format": "int64",
51542	//       "location": "query",
51543	//       "repeated": true,
51544	//       "type": "string"
51545	//     },
51546	//     "profileId": {
51547	//       "description": "User profile ID associated with this request.",
51548	//       "format": "int64",
51549	//       "location": "path",
51550	//       "required": true,
51551	//       "type": "string"
51552	//     }
51553	//   },
51554	//   "path": "userprofiles/{profileId}/userRolePermissions",
51555	//   "response": {
51556	//     "$ref": "UserRolePermissionsListResponse"
51557	//   },
51558	//   "scopes": [
51559	//     "https://www.googleapis.com/auth/dfatrafficking"
51560	//   ]
51561	// }
51562
51563}
51564
51565// method id "dfareporting.userRoles.delete":
51566
51567type UserRolesDeleteCall struct {
51568	s          *Service
51569	profileId  int64
51570	id         int64
51571	urlParams_ gensupport.URLParams
51572	ctx_       context.Context
51573	header_    http.Header
51574}
51575
51576// Delete: Deletes an existing user role.
51577//
51578// - id: User role ID.
51579// - profileId: User profile ID associated with this request.
51580func (r *UserRolesService) Delete(profileId int64, id int64) *UserRolesDeleteCall {
51581	c := &UserRolesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
51582	c.profileId = profileId
51583	c.id = id
51584	return c
51585}
51586
51587// Fields allows partial responses to be retrieved. See
51588// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
51589// for more information.
51590func (c *UserRolesDeleteCall) Fields(s ...googleapi.Field) *UserRolesDeleteCall {
51591	c.urlParams_.Set("fields", googleapi.CombineFields(s))
51592	return c
51593}
51594
51595// Context sets the context to be used in this call's Do method. Any
51596// pending HTTP request will be aborted if the provided context is
51597// canceled.
51598func (c *UserRolesDeleteCall) Context(ctx context.Context) *UserRolesDeleteCall {
51599	c.ctx_ = ctx
51600	return c
51601}
51602
51603// Header returns an http.Header that can be modified by the caller to
51604// add HTTP headers to the request.
51605func (c *UserRolesDeleteCall) Header() http.Header {
51606	if c.header_ == nil {
51607		c.header_ = make(http.Header)
51608	}
51609	return c.header_
51610}
51611
51612func (c *UserRolesDeleteCall) doRequest(alt string) (*http.Response, error) {
51613	reqHeaders := make(http.Header)
51614	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
51615	for k, v := range c.header_ {
51616		reqHeaders[k] = v
51617	}
51618	reqHeaders.Set("User-Agent", c.s.userAgent())
51619	var body io.Reader = nil
51620	c.urlParams_.Set("alt", alt)
51621	c.urlParams_.Set("prettyPrint", "false")
51622	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/userRoles/{id}")
51623	urls += "?" + c.urlParams_.Encode()
51624	req, err := http.NewRequest("DELETE", urls, body)
51625	if err != nil {
51626		return nil, err
51627	}
51628	req.Header = reqHeaders
51629	googleapi.Expand(req.URL, map[string]string{
51630		"profileId": strconv.FormatInt(c.profileId, 10),
51631		"id":        strconv.FormatInt(c.id, 10),
51632	})
51633	return gensupport.SendRequest(c.ctx_, c.s.client, req)
51634}
51635
51636// Do executes the "dfareporting.userRoles.delete" call.
51637func (c *UserRolesDeleteCall) Do(opts ...googleapi.CallOption) error {
51638	gensupport.SetOptions(c.urlParams_, opts...)
51639	res, err := c.doRequest("json")
51640	if err != nil {
51641		return err
51642	}
51643	defer googleapi.CloseBody(res)
51644	if err := googleapi.CheckResponse(res); err != nil {
51645		return err
51646	}
51647	return nil
51648	// {
51649	//   "description": "Deletes an existing user role.",
51650	//   "flatPath": "userprofiles/{profileId}/userRoles/{id}",
51651	//   "httpMethod": "DELETE",
51652	//   "id": "dfareporting.userRoles.delete",
51653	//   "parameterOrder": [
51654	//     "profileId",
51655	//     "id"
51656	//   ],
51657	//   "parameters": {
51658	//     "id": {
51659	//       "description": "User role ID.",
51660	//       "format": "int64",
51661	//       "location": "path",
51662	//       "required": true,
51663	//       "type": "string"
51664	//     },
51665	//     "profileId": {
51666	//       "description": "User profile ID associated with this request.",
51667	//       "format": "int64",
51668	//       "location": "path",
51669	//       "required": true,
51670	//       "type": "string"
51671	//     }
51672	//   },
51673	//   "path": "userprofiles/{profileId}/userRoles/{id}",
51674	//   "scopes": [
51675	//     "https://www.googleapis.com/auth/dfatrafficking"
51676	//   ]
51677	// }
51678
51679}
51680
51681// method id "dfareporting.userRoles.get":
51682
51683type UserRolesGetCall struct {
51684	s            *Service
51685	profileId    int64
51686	id           int64
51687	urlParams_   gensupport.URLParams
51688	ifNoneMatch_ string
51689	ctx_         context.Context
51690	header_      http.Header
51691}
51692
51693// Get: Gets one user role by ID.
51694//
51695// - id: User role ID.
51696// - profileId: User profile ID associated with this request.
51697func (r *UserRolesService) Get(profileId int64, id int64) *UserRolesGetCall {
51698	c := &UserRolesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
51699	c.profileId = profileId
51700	c.id = id
51701	return c
51702}
51703
51704// Fields allows partial responses to be retrieved. See
51705// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
51706// for more information.
51707func (c *UserRolesGetCall) Fields(s ...googleapi.Field) *UserRolesGetCall {
51708	c.urlParams_.Set("fields", googleapi.CombineFields(s))
51709	return c
51710}
51711
51712// IfNoneMatch sets the optional parameter which makes the operation
51713// fail if the object's ETag matches the given value. This is useful for
51714// getting updates only after the object has changed since the last
51715// request. Use googleapi.IsNotModified to check whether the response
51716// error from Do is the result of In-None-Match.
51717func (c *UserRolesGetCall) IfNoneMatch(entityTag string) *UserRolesGetCall {
51718	c.ifNoneMatch_ = entityTag
51719	return c
51720}
51721
51722// Context sets the context to be used in this call's Do method. Any
51723// pending HTTP request will be aborted if the provided context is
51724// canceled.
51725func (c *UserRolesGetCall) Context(ctx context.Context) *UserRolesGetCall {
51726	c.ctx_ = ctx
51727	return c
51728}
51729
51730// Header returns an http.Header that can be modified by the caller to
51731// add HTTP headers to the request.
51732func (c *UserRolesGetCall) Header() http.Header {
51733	if c.header_ == nil {
51734		c.header_ = make(http.Header)
51735	}
51736	return c.header_
51737}
51738
51739func (c *UserRolesGetCall) doRequest(alt string) (*http.Response, error) {
51740	reqHeaders := make(http.Header)
51741	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
51742	for k, v := range c.header_ {
51743		reqHeaders[k] = v
51744	}
51745	reqHeaders.Set("User-Agent", c.s.userAgent())
51746	if c.ifNoneMatch_ != "" {
51747		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
51748	}
51749	var body io.Reader = nil
51750	c.urlParams_.Set("alt", alt)
51751	c.urlParams_.Set("prettyPrint", "false")
51752	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/userRoles/{id}")
51753	urls += "?" + c.urlParams_.Encode()
51754	req, err := http.NewRequest("GET", urls, body)
51755	if err != nil {
51756		return nil, err
51757	}
51758	req.Header = reqHeaders
51759	googleapi.Expand(req.URL, map[string]string{
51760		"profileId": strconv.FormatInt(c.profileId, 10),
51761		"id":        strconv.FormatInt(c.id, 10),
51762	})
51763	return gensupport.SendRequest(c.ctx_, c.s.client, req)
51764}
51765
51766// Do executes the "dfareporting.userRoles.get" call.
51767// Exactly one of *UserRole or error will be non-nil. Any non-2xx status
51768// code is an error. Response headers are in either
51769// *UserRole.ServerResponse.Header or (if a response was returned at
51770// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
51771// to check whether the returned error was because
51772// http.StatusNotModified was returned.
51773func (c *UserRolesGetCall) Do(opts ...googleapi.CallOption) (*UserRole, error) {
51774	gensupport.SetOptions(c.urlParams_, opts...)
51775	res, err := c.doRequest("json")
51776	if res != nil && res.StatusCode == http.StatusNotModified {
51777		if res.Body != nil {
51778			res.Body.Close()
51779		}
51780		return nil, &googleapi.Error{
51781			Code:   res.StatusCode,
51782			Header: res.Header,
51783		}
51784	}
51785	if err != nil {
51786		return nil, err
51787	}
51788	defer googleapi.CloseBody(res)
51789	if err := googleapi.CheckResponse(res); err != nil {
51790		return nil, err
51791	}
51792	ret := &UserRole{
51793		ServerResponse: googleapi.ServerResponse{
51794			Header:         res.Header,
51795			HTTPStatusCode: res.StatusCode,
51796		},
51797	}
51798	target := &ret
51799	if err := gensupport.DecodeResponse(target, res); err != nil {
51800		return nil, err
51801	}
51802	return ret, nil
51803	// {
51804	//   "description": "Gets one user role by ID.",
51805	//   "flatPath": "userprofiles/{profileId}/userRoles/{id}",
51806	//   "httpMethod": "GET",
51807	//   "id": "dfareporting.userRoles.get",
51808	//   "parameterOrder": [
51809	//     "profileId",
51810	//     "id"
51811	//   ],
51812	//   "parameters": {
51813	//     "id": {
51814	//       "description": "User role ID.",
51815	//       "format": "int64",
51816	//       "location": "path",
51817	//       "required": true,
51818	//       "type": "string"
51819	//     },
51820	//     "profileId": {
51821	//       "description": "User profile ID associated with this request.",
51822	//       "format": "int64",
51823	//       "location": "path",
51824	//       "required": true,
51825	//       "type": "string"
51826	//     }
51827	//   },
51828	//   "path": "userprofiles/{profileId}/userRoles/{id}",
51829	//   "response": {
51830	//     "$ref": "UserRole"
51831	//   },
51832	//   "scopes": [
51833	//     "https://www.googleapis.com/auth/dfatrafficking"
51834	//   ]
51835	// }
51836
51837}
51838
51839// method id "dfareporting.userRoles.insert":
51840
51841type UserRolesInsertCall struct {
51842	s          *Service
51843	profileId  int64
51844	userrole   *UserRole
51845	urlParams_ gensupport.URLParams
51846	ctx_       context.Context
51847	header_    http.Header
51848}
51849
51850// Insert: Inserts a new user role.
51851//
51852// - profileId: User profile ID associated with this request.
51853func (r *UserRolesService) Insert(profileId int64, userrole *UserRole) *UserRolesInsertCall {
51854	c := &UserRolesInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)}
51855	c.profileId = profileId
51856	c.userrole = userrole
51857	return c
51858}
51859
51860// Fields allows partial responses to be retrieved. See
51861// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
51862// for more information.
51863func (c *UserRolesInsertCall) Fields(s ...googleapi.Field) *UserRolesInsertCall {
51864	c.urlParams_.Set("fields", googleapi.CombineFields(s))
51865	return c
51866}
51867
51868// Context sets the context to be used in this call's Do method. Any
51869// pending HTTP request will be aborted if the provided context is
51870// canceled.
51871func (c *UserRolesInsertCall) Context(ctx context.Context) *UserRolesInsertCall {
51872	c.ctx_ = ctx
51873	return c
51874}
51875
51876// Header returns an http.Header that can be modified by the caller to
51877// add HTTP headers to the request.
51878func (c *UserRolesInsertCall) Header() http.Header {
51879	if c.header_ == nil {
51880		c.header_ = make(http.Header)
51881	}
51882	return c.header_
51883}
51884
51885func (c *UserRolesInsertCall) doRequest(alt string) (*http.Response, error) {
51886	reqHeaders := make(http.Header)
51887	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
51888	for k, v := range c.header_ {
51889		reqHeaders[k] = v
51890	}
51891	reqHeaders.Set("User-Agent", c.s.userAgent())
51892	var body io.Reader = nil
51893	body, err := googleapi.WithoutDataWrapper.JSONReader(c.userrole)
51894	if err != nil {
51895		return nil, err
51896	}
51897	reqHeaders.Set("Content-Type", "application/json")
51898	c.urlParams_.Set("alt", alt)
51899	c.urlParams_.Set("prettyPrint", "false")
51900	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/userRoles")
51901	urls += "?" + c.urlParams_.Encode()
51902	req, err := http.NewRequest("POST", urls, body)
51903	if err != nil {
51904		return nil, err
51905	}
51906	req.Header = reqHeaders
51907	googleapi.Expand(req.URL, map[string]string{
51908		"profileId": strconv.FormatInt(c.profileId, 10),
51909	})
51910	return gensupport.SendRequest(c.ctx_, c.s.client, req)
51911}
51912
51913// Do executes the "dfareporting.userRoles.insert" call.
51914// Exactly one of *UserRole or error will be non-nil. Any non-2xx status
51915// code is an error. Response headers are in either
51916// *UserRole.ServerResponse.Header or (if a response was returned at
51917// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
51918// to check whether the returned error was because
51919// http.StatusNotModified was returned.
51920func (c *UserRolesInsertCall) Do(opts ...googleapi.CallOption) (*UserRole, error) {
51921	gensupport.SetOptions(c.urlParams_, opts...)
51922	res, err := c.doRequest("json")
51923	if res != nil && res.StatusCode == http.StatusNotModified {
51924		if res.Body != nil {
51925			res.Body.Close()
51926		}
51927		return nil, &googleapi.Error{
51928			Code:   res.StatusCode,
51929			Header: res.Header,
51930		}
51931	}
51932	if err != nil {
51933		return nil, err
51934	}
51935	defer googleapi.CloseBody(res)
51936	if err := googleapi.CheckResponse(res); err != nil {
51937		return nil, err
51938	}
51939	ret := &UserRole{
51940		ServerResponse: googleapi.ServerResponse{
51941			Header:         res.Header,
51942			HTTPStatusCode: res.StatusCode,
51943		},
51944	}
51945	target := &ret
51946	if err := gensupport.DecodeResponse(target, res); err != nil {
51947		return nil, err
51948	}
51949	return ret, nil
51950	// {
51951	//   "description": "Inserts a new user role.",
51952	//   "flatPath": "userprofiles/{profileId}/userRoles",
51953	//   "httpMethod": "POST",
51954	//   "id": "dfareporting.userRoles.insert",
51955	//   "parameterOrder": [
51956	//     "profileId"
51957	//   ],
51958	//   "parameters": {
51959	//     "profileId": {
51960	//       "description": "User profile ID associated with this request.",
51961	//       "format": "int64",
51962	//       "location": "path",
51963	//       "required": true,
51964	//       "type": "string"
51965	//     }
51966	//   },
51967	//   "path": "userprofiles/{profileId}/userRoles",
51968	//   "request": {
51969	//     "$ref": "UserRole"
51970	//   },
51971	//   "response": {
51972	//     "$ref": "UserRole"
51973	//   },
51974	//   "scopes": [
51975	//     "https://www.googleapis.com/auth/dfatrafficking"
51976	//   ]
51977	// }
51978
51979}
51980
51981// method id "dfareporting.userRoles.list":
51982
51983type UserRolesListCall struct {
51984	s            *Service
51985	profileId    int64
51986	urlParams_   gensupport.URLParams
51987	ifNoneMatch_ string
51988	ctx_         context.Context
51989	header_      http.Header
51990}
51991
51992// List: Retrieves a list of user roles, possibly filtered. This method
51993// supports paging.
51994//
51995// - profileId: User profile ID associated with this request.
51996func (r *UserRolesService) List(profileId int64) *UserRolesListCall {
51997	c := &UserRolesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
51998	c.profileId = profileId
51999	return c
52000}
52001
52002// AccountUserRoleOnly sets the optional parameter
52003// "accountUserRoleOnly": Select only account level user roles not
52004// associated with any specific subaccount.
52005func (c *UserRolesListCall) AccountUserRoleOnly(accountUserRoleOnly bool) *UserRolesListCall {
52006	c.urlParams_.Set("accountUserRoleOnly", fmt.Sprint(accountUserRoleOnly))
52007	return c
52008}
52009
52010// Ids sets the optional parameter "ids": Select only user roles with
52011// the specified IDs.
52012func (c *UserRolesListCall) Ids(ids ...int64) *UserRolesListCall {
52013	var ids_ []string
52014	for _, v := range ids {
52015		ids_ = append(ids_, fmt.Sprint(v))
52016	}
52017	c.urlParams_.SetMulti("ids", ids_)
52018	return c
52019}
52020
52021// MaxResults sets the optional parameter "maxResults": Maximum number
52022// of results to return.
52023func (c *UserRolesListCall) MaxResults(maxResults int64) *UserRolesListCall {
52024	c.urlParams_.Set("maxResults", fmt.Sprint(maxResults))
52025	return c
52026}
52027
52028// PageToken sets the optional parameter "pageToken": Value of the
52029// nextPageToken from the previous result page.
52030func (c *UserRolesListCall) PageToken(pageToken string) *UserRolesListCall {
52031	c.urlParams_.Set("pageToken", pageToken)
52032	return c
52033}
52034
52035// SearchString sets the optional parameter "searchString": Allows
52036// searching for objects by name or ID. Wildcards (*) are allowed. For
52037// example, "userrole*2015" will return objects with names like
52038// "userrole June 2015", "userrole April 2015", or simply "userrole
52039// 2015". Most of the searches also add wildcards implicitly at the
52040// start and the end of the search string. For example, a search string
52041// of "userrole" will match objects with name "my userrole", "userrole
52042// 2015", or simply "userrole".
52043func (c *UserRolesListCall) SearchString(searchString string) *UserRolesListCall {
52044	c.urlParams_.Set("searchString", searchString)
52045	return c
52046}
52047
52048// SortField sets the optional parameter "sortField": Field by which to
52049// sort the list.
52050//
52051// Possible values:
52052//   "ID" (default)
52053//   "NAME"
52054func (c *UserRolesListCall) SortField(sortField string) *UserRolesListCall {
52055	c.urlParams_.Set("sortField", sortField)
52056	return c
52057}
52058
52059// SortOrder sets the optional parameter "sortOrder": Order of sorted
52060// results.
52061//
52062// Possible values:
52063//   "ASCENDING" (default)
52064//   "DESCENDING"
52065func (c *UserRolesListCall) SortOrder(sortOrder string) *UserRolesListCall {
52066	c.urlParams_.Set("sortOrder", sortOrder)
52067	return c
52068}
52069
52070// SubaccountId sets the optional parameter "subaccountId": Select only
52071// user roles that belong to this subaccount.
52072func (c *UserRolesListCall) SubaccountId(subaccountId int64) *UserRolesListCall {
52073	c.urlParams_.Set("subaccountId", fmt.Sprint(subaccountId))
52074	return c
52075}
52076
52077// Fields allows partial responses to be retrieved. See
52078// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
52079// for more information.
52080func (c *UserRolesListCall) Fields(s ...googleapi.Field) *UserRolesListCall {
52081	c.urlParams_.Set("fields", googleapi.CombineFields(s))
52082	return c
52083}
52084
52085// IfNoneMatch sets the optional parameter which makes the operation
52086// fail if the object's ETag matches the given value. This is useful for
52087// getting updates only after the object has changed since the last
52088// request. Use googleapi.IsNotModified to check whether the response
52089// error from Do is the result of In-None-Match.
52090func (c *UserRolesListCall) IfNoneMatch(entityTag string) *UserRolesListCall {
52091	c.ifNoneMatch_ = entityTag
52092	return c
52093}
52094
52095// Context sets the context to be used in this call's Do method. Any
52096// pending HTTP request will be aborted if the provided context is
52097// canceled.
52098func (c *UserRolesListCall) Context(ctx context.Context) *UserRolesListCall {
52099	c.ctx_ = ctx
52100	return c
52101}
52102
52103// Header returns an http.Header that can be modified by the caller to
52104// add HTTP headers to the request.
52105func (c *UserRolesListCall) Header() http.Header {
52106	if c.header_ == nil {
52107		c.header_ = make(http.Header)
52108	}
52109	return c.header_
52110}
52111
52112func (c *UserRolesListCall) doRequest(alt string) (*http.Response, error) {
52113	reqHeaders := make(http.Header)
52114	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
52115	for k, v := range c.header_ {
52116		reqHeaders[k] = v
52117	}
52118	reqHeaders.Set("User-Agent", c.s.userAgent())
52119	if c.ifNoneMatch_ != "" {
52120		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
52121	}
52122	var body io.Reader = nil
52123	c.urlParams_.Set("alt", alt)
52124	c.urlParams_.Set("prettyPrint", "false")
52125	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/userRoles")
52126	urls += "?" + c.urlParams_.Encode()
52127	req, err := http.NewRequest("GET", urls, body)
52128	if err != nil {
52129		return nil, err
52130	}
52131	req.Header = reqHeaders
52132	googleapi.Expand(req.URL, map[string]string{
52133		"profileId": strconv.FormatInt(c.profileId, 10),
52134	})
52135	return gensupport.SendRequest(c.ctx_, c.s.client, req)
52136}
52137
52138// Do executes the "dfareporting.userRoles.list" call.
52139// Exactly one of *UserRolesListResponse or error will be non-nil. Any
52140// non-2xx status code is an error. Response headers are in either
52141// *UserRolesListResponse.ServerResponse.Header or (if a response was
52142// returned at all) in error.(*googleapi.Error).Header. Use
52143// googleapi.IsNotModified to check whether the returned error was
52144// because http.StatusNotModified was returned.
52145func (c *UserRolesListCall) Do(opts ...googleapi.CallOption) (*UserRolesListResponse, error) {
52146	gensupport.SetOptions(c.urlParams_, opts...)
52147	res, err := c.doRequest("json")
52148	if res != nil && res.StatusCode == http.StatusNotModified {
52149		if res.Body != nil {
52150			res.Body.Close()
52151		}
52152		return nil, &googleapi.Error{
52153			Code:   res.StatusCode,
52154			Header: res.Header,
52155		}
52156	}
52157	if err != nil {
52158		return nil, err
52159	}
52160	defer googleapi.CloseBody(res)
52161	if err := googleapi.CheckResponse(res); err != nil {
52162		return nil, err
52163	}
52164	ret := &UserRolesListResponse{
52165		ServerResponse: googleapi.ServerResponse{
52166			Header:         res.Header,
52167			HTTPStatusCode: res.StatusCode,
52168		},
52169	}
52170	target := &ret
52171	if err := gensupport.DecodeResponse(target, res); err != nil {
52172		return nil, err
52173	}
52174	return ret, nil
52175	// {
52176	//   "description": "Retrieves a list of user roles, possibly filtered. This method supports paging.",
52177	//   "flatPath": "userprofiles/{profileId}/userRoles",
52178	//   "httpMethod": "GET",
52179	//   "id": "dfareporting.userRoles.list",
52180	//   "parameterOrder": [
52181	//     "profileId"
52182	//   ],
52183	//   "parameters": {
52184	//     "accountUserRoleOnly": {
52185	//       "description": "Select only account level user roles not associated with any specific subaccount.",
52186	//       "location": "query",
52187	//       "type": "boolean"
52188	//     },
52189	//     "ids": {
52190	//       "description": "Select only user roles with the specified IDs.",
52191	//       "format": "int64",
52192	//       "location": "query",
52193	//       "repeated": true,
52194	//       "type": "string"
52195	//     },
52196	//     "maxResults": {
52197	//       "default": "1000",
52198	//       "description": "Maximum number of results to return.",
52199	//       "format": "int32",
52200	//       "location": "query",
52201	//       "maximum": "1000",
52202	//       "minimum": "0",
52203	//       "type": "integer"
52204	//     },
52205	//     "pageToken": {
52206	//       "description": "Value of the nextPageToken from the previous result page.",
52207	//       "location": "query",
52208	//       "type": "string"
52209	//     },
52210	//     "profileId": {
52211	//       "description": "User profile ID associated with this request.",
52212	//       "format": "int64",
52213	//       "location": "path",
52214	//       "required": true,
52215	//       "type": "string"
52216	//     },
52217	//     "searchString": {
52218	//       "description": "Allows searching for objects by name or ID. Wildcards (*) are allowed. For example, \"userrole*2015\" will return objects with names like \"userrole June 2015\", \"userrole April 2015\", or simply \"userrole 2015\". Most of the searches also add wildcards implicitly at the start and the end of the search string. For example, a search string of \"userrole\" will match objects with name \"my userrole\", \"userrole 2015\", or simply \"userrole\".",
52219	//       "location": "query",
52220	//       "type": "string"
52221	//     },
52222	//     "sortField": {
52223	//       "default": "ID",
52224	//       "description": "Field by which to sort the list.",
52225	//       "enum": [
52226	//         "ID",
52227	//         "NAME"
52228	//       ],
52229	//       "enumDescriptions": [
52230	//         "",
52231	//         ""
52232	//       ],
52233	//       "location": "query",
52234	//       "type": "string"
52235	//     },
52236	//     "sortOrder": {
52237	//       "default": "ASCENDING",
52238	//       "description": "Order of sorted results.",
52239	//       "enum": [
52240	//         "ASCENDING",
52241	//         "DESCENDING"
52242	//       ],
52243	//       "enumDescriptions": [
52244	//         "",
52245	//         ""
52246	//       ],
52247	//       "location": "query",
52248	//       "type": "string"
52249	//     },
52250	//     "subaccountId": {
52251	//       "description": "Select only user roles that belong to this subaccount.",
52252	//       "format": "int64",
52253	//       "location": "query",
52254	//       "type": "string"
52255	//     }
52256	//   },
52257	//   "path": "userprofiles/{profileId}/userRoles",
52258	//   "response": {
52259	//     "$ref": "UserRolesListResponse"
52260	//   },
52261	//   "scopes": [
52262	//     "https://www.googleapis.com/auth/dfatrafficking"
52263	//   ]
52264	// }
52265
52266}
52267
52268// Pages invokes f for each page of results.
52269// A non-nil error returned from f will halt the iteration.
52270// The provided context supersedes any context provided to the Context method.
52271func (c *UserRolesListCall) Pages(ctx context.Context, f func(*UserRolesListResponse) error) error {
52272	c.ctx_ = ctx
52273	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
52274	for {
52275		x, err := c.Do()
52276		if err != nil {
52277			return err
52278		}
52279		if err := f(x); err != nil {
52280			return err
52281		}
52282		if x.NextPageToken == "" {
52283			return nil
52284		}
52285		c.PageToken(x.NextPageToken)
52286	}
52287}
52288
52289// method id "dfareporting.userRoles.patch":
52290
52291type UserRolesPatchCall struct {
52292	s          *Service
52293	profileId  int64
52294	userrole   *UserRole
52295	urlParams_ gensupport.URLParams
52296	ctx_       context.Context
52297	header_    http.Header
52298}
52299
52300// Patch: Updates an existing user role. This method supports patch
52301// semantics.
52302//
52303// - id: UserRole ID.
52304// - profileId: User profile ID associated with this request.
52305func (r *UserRolesService) Patch(profileId int64, id int64, userrole *UserRole) *UserRolesPatchCall {
52306	c := &UserRolesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
52307	c.profileId = profileId
52308	c.urlParams_.Set("id", fmt.Sprint(id))
52309	c.userrole = userrole
52310	return c
52311}
52312
52313// Fields allows partial responses to be retrieved. See
52314// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
52315// for more information.
52316func (c *UserRolesPatchCall) Fields(s ...googleapi.Field) *UserRolesPatchCall {
52317	c.urlParams_.Set("fields", googleapi.CombineFields(s))
52318	return c
52319}
52320
52321// Context sets the context to be used in this call's Do method. Any
52322// pending HTTP request will be aborted if the provided context is
52323// canceled.
52324func (c *UserRolesPatchCall) Context(ctx context.Context) *UserRolesPatchCall {
52325	c.ctx_ = ctx
52326	return c
52327}
52328
52329// Header returns an http.Header that can be modified by the caller to
52330// add HTTP headers to the request.
52331func (c *UserRolesPatchCall) Header() http.Header {
52332	if c.header_ == nil {
52333		c.header_ = make(http.Header)
52334	}
52335	return c.header_
52336}
52337
52338func (c *UserRolesPatchCall) doRequest(alt string) (*http.Response, error) {
52339	reqHeaders := make(http.Header)
52340	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
52341	for k, v := range c.header_ {
52342		reqHeaders[k] = v
52343	}
52344	reqHeaders.Set("User-Agent", c.s.userAgent())
52345	var body io.Reader = nil
52346	body, err := googleapi.WithoutDataWrapper.JSONReader(c.userrole)
52347	if err != nil {
52348		return nil, err
52349	}
52350	reqHeaders.Set("Content-Type", "application/json")
52351	c.urlParams_.Set("alt", alt)
52352	c.urlParams_.Set("prettyPrint", "false")
52353	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/userRoles")
52354	urls += "?" + c.urlParams_.Encode()
52355	req, err := http.NewRequest("PATCH", urls, body)
52356	if err != nil {
52357		return nil, err
52358	}
52359	req.Header = reqHeaders
52360	googleapi.Expand(req.URL, map[string]string{
52361		"profileId": strconv.FormatInt(c.profileId, 10),
52362	})
52363	return gensupport.SendRequest(c.ctx_, c.s.client, req)
52364}
52365
52366// Do executes the "dfareporting.userRoles.patch" call.
52367// Exactly one of *UserRole or error will be non-nil. Any non-2xx status
52368// code is an error. Response headers are in either
52369// *UserRole.ServerResponse.Header or (if a response was returned at
52370// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
52371// to check whether the returned error was because
52372// http.StatusNotModified was returned.
52373func (c *UserRolesPatchCall) Do(opts ...googleapi.CallOption) (*UserRole, error) {
52374	gensupport.SetOptions(c.urlParams_, opts...)
52375	res, err := c.doRequest("json")
52376	if res != nil && res.StatusCode == http.StatusNotModified {
52377		if res.Body != nil {
52378			res.Body.Close()
52379		}
52380		return nil, &googleapi.Error{
52381			Code:   res.StatusCode,
52382			Header: res.Header,
52383		}
52384	}
52385	if err != nil {
52386		return nil, err
52387	}
52388	defer googleapi.CloseBody(res)
52389	if err := googleapi.CheckResponse(res); err != nil {
52390		return nil, err
52391	}
52392	ret := &UserRole{
52393		ServerResponse: googleapi.ServerResponse{
52394			Header:         res.Header,
52395			HTTPStatusCode: res.StatusCode,
52396		},
52397	}
52398	target := &ret
52399	if err := gensupport.DecodeResponse(target, res); err != nil {
52400		return nil, err
52401	}
52402	return ret, nil
52403	// {
52404	//   "description": "Updates an existing user role. This method supports patch semantics.",
52405	//   "flatPath": "userprofiles/{profileId}/userRoles",
52406	//   "httpMethod": "PATCH",
52407	//   "id": "dfareporting.userRoles.patch",
52408	//   "parameterOrder": [
52409	//     "profileId",
52410	//     "id"
52411	//   ],
52412	//   "parameters": {
52413	//     "id": {
52414	//       "description": "UserRole ID.",
52415	//       "format": "int64",
52416	//       "location": "query",
52417	//       "required": true,
52418	//       "type": "string"
52419	//     },
52420	//     "profileId": {
52421	//       "description": "User profile ID associated with this request.",
52422	//       "format": "int64",
52423	//       "location": "path",
52424	//       "required": true,
52425	//       "type": "string"
52426	//     }
52427	//   },
52428	//   "path": "userprofiles/{profileId}/userRoles",
52429	//   "request": {
52430	//     "$ref": "UserRole"
52431	//   },
52432	//   "response": {
52433	//     "$ref": "UserRole"
52434	//   },
52435	//   "scopes": [
52436	//     "https://www.googleapis.com/auth/dfatrafficking"
52437	//   ]
52438	// }
52439
52440}
52441
52442// method id "dfareporting.userRoles.update":
52443
52444type UserRolesUpdateCall struct {
52445	s          *Service
52446	profileId  int64
52447	userrole   *UserRole
52448	urlParams_ gensupport.URLParams
52449	ctx_       context.Context
52450	header_    http.Header
52451}
52452
52453// Update: Updates an existing user role.
52454//
52455// - profileId: User profile ID associated with this request.
52456func (r *UserRolesService) Update(profileId int64, userrole *UserRole) *UserRolesUpdateCall {
52457	c := &UserRolesUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
52458	c.profileId = profileId
52459	c.userrole = userrole
52460	return c
52461}
52462
52463// Fields allows partial responses to be retrieved. See
52464// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
52465// for more information.
52466func (c *UserRolesUpdateCall) Fields(s ...googleapi.Field) *UserRolesUpdateCall {
52467	c.urlParams_.Set("fields", googleapi.CombineFields(s))
52468	return c
52469}
52470
52471// Context sets the context to be used in this call's Do method. Any
52472// pending HTTP request will be aborted if the provided context is
52473// canceled.
52474func (c *UserRolesUpdateCall) Context(ctx context.Context) *UserRolesUpdateCall {
52475	c.ctx_ = ctx
52476	return c
52477}
52478
52479// Header returns an http.Header that can be modified by the caller to
52480// add HTTP headers to the request.
52481func (c *UserRolesUpdateCall) Header() http.Header {
52482	if c.header_ == nil {
52483		c.header_ = make(http.Header)
52484	}
52485	return c.header_
52486}
52487
52488func (c *UserRolesUpdateCall) doRequest(alt string) (*http.Response, error) {
52489	reqHeaders := make(http.Header)
52490	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
52491	for k, v := range c.header_ {
52492		reqHeaders[k] = v
52493	}
52494	reqHeaders.Set("User-Agent", c.s.userAgent())
52495	var body io.Reader = nil
52496	body, err := googleapi.WithoutDataWrapper.JSONReader(c.userrole)
52497	if err != nil {
52498		return nil, err
52499	}
52500	reqHeaders.Set("Content-Type", "application/json")
52501	c.urlParams_.Set("alt", alt)
52502	c.urlParams_.Set("prettyPrint", "false")
52503	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/userRoles")
52504	urls += "?" + c.urlParams_.Encode()
52505	req, err := http.NewRequest("PUT", urls, body)
52506	if err != nil {
52507		return nil, err
52508	}
52509	req.Header = reqHeaders
52510	googleapi.Expand(req.URL, map[string]string{
52511		"profileId": strconv.FormatInt(c.profileId, 10),
52512	})
52513	return gensupport.SendRequest(c.ctx_, c.s.client, req)
52514}
52515
52516// Do executes the "dfareporting.userRoles.update" call.
52517// Exactly one of *UserRole or error will be non-nil. Any non-2xx status
52518// code is an error. Response headers are in either
52519// *UserRole.ServerResponse.Header or (if a response was returned at
52520// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
52521// to check whether the returned error was because
52522// http.StatusNotModified was returned.
52523func (c *UserRolesUpdateCall) Do(opts ...googleapi.CallOption) (*UserRole, error) {
52524	gensupport.SetOptions(c.urlParams_, opts...)
52525	res, err := c.doRequest("json")
52526	if res != nil && res.StatusCode == http.StatusNotModified {
52527		if res.Body != nil {
52528			res.Body.Close()
52529		}
52530		return nil, &googleapi.Error{
52531			Code:   res.StatusCode,
52532			Header: res.Header,
52533		}
52534	}
52535	if err != nil {
52536		return nil, err
52537	}
52538	defer googleapi.CloseBody(res)
52539	if err := googleapi.CheckResponse(res); err != nil {
52540		return nil, err
52541	}
52542	ret := &UserRole{
52543		ServerResponse: googleapi.ServerResponse{
52544			Header:         res.Header,
52545			HTTPStatusCode: res.StatusCode,
52546		},
52547	}
52548	target := &ret
52549	if err := gensupport.DecodeResponse(target, res); err != nil {
52550		return nil, err
52551	}
52552	return ret, nil
52553	// {
52554	//   "description": "Updates an existing user role.",
52555	//   "flatPath": "userprofiles/{profileId}/userRoles",
52556	//   "httpMethod": "PUT",
52557	//   "id": "dfareporting.userRoles.update",
52558	//   "parameterOrder": [
52559	//     "profileId"
52560	//   ],
52561	//   "parameters": {
52562	//     "profileId": {
52563	//       "description": "User profile ID associated with this request.",
52564	//       "format": "int64",
52565	//       "location": "path",
52566	//       "required": true,
52567	//       "type": "string"
52568	//     }
52569	//   },
52570	//   "path": "userprofiles/{profileId}/userRoles",
52571	//   "request": {
52572	//     "$ref": "UserRole"
52573	//   },
52574	//   "response": {
52575	//     "$ref": "UserRole"
52576	//   },
52577	//   "scopes": [
52578	//     "https://www.googleapis.com/auth/dfatrafficking"
52579	//   ]
52580	// }
52581
52582}
52583
52584// method id "dfareporting.videoFormats.get":
52585
52586type VideoFormatsGetCall struct {
52587	s            *Service
52588	profileId    int64
52589	id           int64
52590	urlParams_   gensupport.URLParams
52591	ifNoneMatch_ string
52592	ctx_         context.Context
52593	header_      http.Header
52594}
52595
52596// Get: Gets one video format by ID.
52597//
52598// - id: Video format ID.
52599// - profileId: User profile ID associated with this request.
52600func (r *VideoFormatsService) Get(profileId int64, id int64) *VideoFormatsGetCall {
52601	c := &VideoFormatsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
52602	c.profileId = profileId
52603	c.id = id
52604	return c
52605}
52606
52607// Fields allows partial responses to be retrieved. See
52608// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
52609// for more information.
52610func (c *VideoFormatsGetCall) Fields(s ...googleapi.Field) *VideoFormatsGetCall {
52611	c.urlParams_.Set("fields", googleapi.CombineFields(s))
52612	return c
52613}
52614
52615// IfNoneMatch sets the optional parameter which makes the operation
52616// fail if the object's ETag matches the given value. This is useful for
52617// getting updates only after the object has changed since the last
52618// request. Use googleapi.IsNotModified to check whether the response
52619// error from Do is the result of In-None-Match.
52620func (c *VideoFormatsGetCall) IfNoneMatch(entityTag string) *VideoFormatsGetCall {
52621	c.ifNoneMatch_ = entityTag
52622	return c
52623}
52624
52625// Context sets the context to be used in this call's Do method. Any
52626// pending HTTP request will be aborted if the provided context is
52627// canceled.
52628func (c *VideoFormatsGetCall) Context(ctx context.Context) *VideoFormatsGetCall {
52629	c.ctx_ = ctx
52630	return c
52631}
52632
52633// Header returns an http.Header that can be modified by the caller to
52634// add HTTP headers to the request.
52635func (c *VideoFormatsGetCall) Header() http.Header {
52636	if c.header_ == nil {
52637		c.header_ = make(http.Header)
52638	}
52639	return c.header_
52640}
52641
52642func (c *VideoFormatsGetCall) doRequest(alt string) (*http.Response, error) {
52643	reqHeaders := make(http.Header)
52644	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
52645	for k, v := range c.header_ {
52646		reqHeaders[k] = v
52647	}
52648	reqHeaders.Set("User-Agent", c.s.userAgent())
52649	if c.ifNoneMatch_ != "" {
52650		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
52651	}
52652	var body io.Reader = nil
52653	c.urlParams_.Set("alt", alt)
52654	c.urlParams_.Set("prettyPrint", "false")
52655	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/videoFormats/{id}")
52656	urls += "?" + c.urlParams_.Encode()
52657	req, err := http.NewRequest("GET", urls, body)
52658	if err != nil {
52659		return nil, err
52660	}
52661	req.Header = reqHeaders
52662	googleapi.Expand(req.URL, map[string]string{
52663		"profileId": strconv.FormatInt(c.profileId, 10),
52664		"id":        strconv.FormatInt(c.id, 10),
52665	})
52666	return gensupport.SendRequest(c.ctx_, c.s.client, req)
52667}
52668
52669// Do executes the "dfareporting.videoFormats.get" call.
52670// Exactly one of *VideoFormat or error will be non-nil. Any non-2xx
52671// status code is an error. Response headers are in either
52672// *VideoFormat.ServerResponse.Header or (if a response was returned at
52673// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
52674// to check whether the returned error was because
52675// http.StatusNotModified was returned.
52676func (c *VideoFormatsGetCall) Do(opts ...googleapi.CallOption) (*VideoFormat, error) {
52677	gensupport.SetOptions(c.urlParams_, opts...)
52678	res, err := c.doRequest("json")
52679	if res != nil && res.StatusCode == http.StatusNotModified {
52680		if res.Body != nil {
52681			res.Body.Close()
52682		}
52683		return nil, &googleapi.Error{
52684			Code:   res.StatusCode,
52685			Header: res.Header,
52686		}
52687	}
52688	if err != nil {
52689		return nil, err
52690	}
52691	defer googleapi.CloseBody(res)
52692	if err := googleapi.CheckResponse(res); err != nil {
52693		return nil, err
52694	}
52695	ret := &VideoFormat{
52696		ServerResponse: googleapi.ServerResponse{
52697			Header:         res.Header,
52698			HTTPStatusCode: res.StatusCode,
52699		},
52700	}
52701	target := &ret
52702	if err := gensupport.DecodeResponse(target, res); err != nil {
52703		return nil, err
52704	}
52705	return ret, nil
52706	// {
52707	//   "description": "Gets one video format by ID.",
52708	//   "flatPath": "userprofiles/{profileId}/videoFormats/{id}",
52709	//   "httpMethod": "GET",
52710	//   "id": "dfareporting.videoFormats.get",
52711	//   "parameterOrder": [
52712	//     "profileId",
52713	//     "id"
52714	//   ],
52715	//   "parameters": {
52716	//     "id": {
52717	//       "description": "Video format ID.",
52718	//       "format": "int32",
52719	//       "location": "path",
52720	//       "required": true,
52721	//       "type": "integer"
52722	//     },
52723	//     "profileId": {
52724	//       "description": "User profile ID associated with this request.",
52725	//       "format": "int64",
52726	//       "location": "path",
52727	//       "required": true,
52728	//       "type": "string"
52729	//     }
52730	//   },
52731	//   "path": "userprofiles/{profileId}/videoFormats/{id}",
52732	//   "response": {
52733	//     "$ref": "VideoFormat"
52734	//   },
52735	//   "scopes": [
52736	//     "https://www.googleapis.com/auth/dfatrafficking"
52737	//   ]
52738	// }
52739
52740}
52741
52742// method id "dfareporting.videoFormats.list":
52743
52744type VideoFormatsListCall struct {
52745	s            *Service
52746	profileId    int64
52747	urlParams_   gensupport.URLParams
52748	ifNoneMatch_ string
52749	ctx_         context.Context
52750	header_      http.Header
52751}
52752
52753// List: Lists available video formats.
52754//
52755// - profileId: User profile ID associated with this request.
52756func (r *VideoFormatsService) List(profileId int64) *VideoFormatsListCall {
52757	c := &VideoFormatsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
52758	c.profileId = profileId
52759	return c
52760}
52761
52762// Fields allows partial responses to be retrieved. See
52763// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
52764// for more information.
52765func (c *VideoFormatsListCall) Fields(s ...googleapi.Field) *VideoFormatsListCall {
52766	c.urlParams_.Set("fields", googleapi.CombineFields(s))
52767	return c
52768}
52769
52770// IfNoneMatch sets the optional parameter which makes the operation
52771// fail if the object's ETag matches the given value. This is useful for
52772// getting updates only after the object has changed since the last
52773// request. Use googleapi.IsNotModified to check whether the response
52774// error from Do is the result of In-None-Match.
52775func (c *VideoFormatsListCall) IfNoneMatch(entityTag string) *VideoFormatsListCall {
52776	c.ifNoneMatch_ = entityTag
52777	return c
52778}
52779
52780// Context sets the context to be used in this call's Do method. Any
52781// pending HTTP request will be aborted if the provided context is
52782// canceled.
52783func (c *VideoFormatsListCall) Context(ctx context.Context) *VideoFormatsListCall {
52784	c.ctx_ = ctx
52785	return c
52786}
52787
52788// Header returns an http.Header that can be modified by the caller to
52789// add HTTP headers to the request.
52790func (c *VideoFormatsListCall) Header() http.Header {
52791	if c.header_ == nil {
52792		c.header_ = make(http.Header)
52793	}
52794	return c.header_
52795}
52796
52797func (c *VideoFormatsListCall) doRequest(alt string) (*http.Response, error) {
52798	reqHeaders := make(http.Header)
52799	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210830")
52800	for k, v := range c.header_ {
52801		reqHeaders[k] = v
52802	}
52803	reqHeaders.Set("User-Agent", c.s.userAgent())
52804	if c.ifNoneMatch_ != "" {
52805		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
52806	}
52807	var body io.Reader = nil
52808	c.urlParams_.Set("alt", alt)
52809	c.urlParams_.Set("prettyPrint", "false")
52810	urls := googleapi.ResolveRelative(c.s.BasePath, "userprofiles/{profileId}/videoFormats")
52811	urls += "?" + c.urlParams_.Encode()
52812	req, err := http.NewRequest("GET", urls, body)
52813	if err != nil {
52814		return nil, err
52815	}
52816	req.Header = reqHeaders
52817	googleapi.Expand(req.URL, map[string]string{
52818		"profileId": strconv.FormatInt(c.profileId, 10),
52819	})
52820	return gensupport.SendRequest(c.ctx_, c.s.client, req)
52821}
52822
52823// Do executes the "dfareporting.videoFormats.list" call.
52824// Exactly one of *VideoFormatsListResponse or error will be non-nil.
52825// Any non-2xx status code is an error. Response headers are in either
52826// *VideoFormatsListResponse.ServerResponse.Header or (if a response was
52827// returned at all) in error.(*googleapi.Error).Header. Use
52828// googleapi.IsNotModified to check whether the returned error was
52829// because http.StatusNotModified was returned.
52830func (c *VideoFormatsListCall) Do(opts ...googleapi.CallOption) (*VideoFormatsListResponse, error) {
52831	gensupport.SetOptions(c.urlParams_, opts...)
52832	res, err := c.doRequest("json")
52833	if res != nil && res.StatusCode == http.StatusNotModified {
52834		if res.Body != nil {
52835			res.Body.Close()
52836		}
52837		return nil, &googleapi.Error{
52838			Code:   res.StatusCode,
52839			Header: res.Header,
52840		}
52841	}
52842	if err != nil {
52843		return nil, err
52844	}
52845	defer googleapi.CloseBody(res)
52846	if err := googleapi.CheckResponse(res); err != nil {
52847		return nil, err
52848	}
52849	ret := &VideoFormatsListResponse{
52850		ServerResponse: googleapi.ServerResponse{
52851			Header:         res.Header,
52852			HTTPStatusCode: res.StatusCode,
52853		},
52854	}
52855	target := &ret
52856	if err := gensupport.DecodeResponse(target, res); err != nil {
52857		return nil, err
52858	}
52859	return ret, nil
52860	// {
52861	//   "description": "Lists available video formats.",
52862	//   "flatPath": "userprofiles/{profileId}/videoFormats",
52863	//   "httpMethod": "GET",
52864	//   "id": "dfareporting.videoFormats.list",
52865	//   "parameterOrder": [
52866	//     "profileId"
52867	//   ],
52868	//   "parameters": {
52869	//     "profileId": {
52870	//       "description": "User profile ID associated with this request.",
52871	//       "format": "int64",
52872	//       "location": "path",
52873	//       "required": true,
52874	//       "type": "string"
52875	//     }
52876	//   },
52877	//   "path": "userprofiles/{profileId}/videoFormats",
52878	//   "response": {
52879	//     "$ref": "VideoFormatsListResponse"
52880	//   },
52881	//   "scopes": [
52882	//     "https://www.googleapis.com/auth/dfatrafficking"
52883	//   ]
52884	// }
52885
52886}
52887